/* STYLES CSS POUR LES NOUVELLES FONCTIONNALITÉS D'AUTO-VALIDATION */
/* À ajouter dans votre fichier feedback.css */

/* === SECTION VALIDATION AUTOMATIQUE === */
.auto-validation-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 1px solid #dee2e6;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.auto-validation-section .section-header h3 {
    color: #495057;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.auto-validation-section .section-header h3 i {
    color: #2c3e50;
}

.section-description {
    color: #6c757d;
    font-size: 14px;
    margin-bottom: 20px;
    font-style: italic;
}

/* === CONTRÔLES DE SEUIL === */
.threshold-control {
    margin-bottom: 20px;
}

.threshold-control label {
    display: block;
    font-weight: 600;
    color: #495057;
    margin-bottom: 12px;
}

.threshold-value {
    color: #3498db;
    font-weight: bold;
    font-size: 16px;
}

.threshold-slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #dee2e6;
    outline: none;
    margin-bottom: 8px;
    appearance: none;
    cursor: pointer;
}

.threshold-slider::-webkit-slider-thumb {
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #3498db;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(111, 66, 193, 0.3);
    transition: all 0.2s ease;
}

.threshold-slider::-webkit-slider-thumb:hover {
    background: #3498db;
    transform: scale(1.1);
}

.threshold-labels {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #6c757d;
    margin-top: 5px;
}

/* === BOUTONS D'AUTO-VALIDATION === */
.auto-validation-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-auto-validate {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 140px;
    justify-content: center;
}

.btn-preview {
    background: #3498db;
    color: white;
}

.btn-preview:hover {
    background: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(23, 162, 184, 0.3);
}

.btn-execute {
    background: #3498db;
    color: white;
}

.btn-execute:hover {
    background: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(111, 66, 193, 0.3);
}

/* === PRÉVISUALISATION DES CANDIDATS === */
.candidates-preview {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 10px;
    margin-top: 20px;
    padding: 20px;
    max-height: 600px;
    overflow-y: auto;
    animation: fadeIn 0.3s ease-in-out;
}

.candidates-preview.hidden {
    display: none;
}

.candidates-summary {
    background: #f8f9fa;
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 16px;
    text-align: center;
    border-left: 4px solid #3498db;
}

.eligible-count {
    color: #3498db;
    font-weight: bold;
    font-size: 18px;
}

/* === GRILLE DES CANDIDATS === */
.candidates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}

.candidate-card {
    border: 2px solid #dee2e6;
    border-radius: 10px;
    padding: 16px;
    background: white;
    transition: all 0.3s ease;
    position: relative;
}

.candidate-card.eligible {
    border-color: #28a745;
    background: linear-gradient(135deg, #f8fff8, #ffffff);
}

.candidate-card.not-eligible {
    border-color: #ffc107;
    background: linear-gradient(135deg, #fffbf0, #ffffff);
    opacity: 0.8;
}

.candidate-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* === EN-TÊTE DE CARTE CANDIDAT === */
.candidate-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.candidate-status {
    display: flex;
    align-items: center;
    gap: 6px;
}

.candidate-status i.fa-check-circle {
    color: #28a745;
}

.candidate-status i.fa-exclamation-triangle {
    color: #ffc107;
}

.eligibility-score {
    background: #3498db;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
}

.candidate-rating {
    display: flex;
    gap: 2px;
}

/* === CONTENU DE CARTE CANDIDAT === */
.candidate-query {
    font-size: 14px;
    color: #495057;
    margin-bottom: 10px;
    line-height: 1.4;
    font-weight: 500;
}

.candidate-metrics {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.candidate-metrics .metric {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #6c757d;
    background: #f8f9fa;
    padding: 4px 8px;
    border-radius: 4px;
}

/* === PROBLÈMES ET ACTIONS === */
.candidate-issues {
    background: #fff3cd;
    color: #856404;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.candidate-actions {
    border-top: 1px solid #dee2e6;
    padding-top: 12px;
    margin-top: 12px;
}

.candidate-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
    color: #495057;
}

.candidate-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #3498db;
}

/* === ACTIONS DE PRÉVISUALISATION === */
.preview-actions {
    border-top: 2px solid #dee2e6;
    padding-top: 16px;
    text-align: center;
}

.btn-bulk-validate {
    background: linear-gradient(135deg, #28a745, #218838);
    color: white;
    padding: 14px 28px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.btn-bulk-validate:hover {
    background: linear-gradient(135deg, #218838, #1e7e34);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

/* === MÉTRIQUES D'AUTO-VALIDATION === */
.auto-validation-metrics {
    background: linear-gradient(135deg, #e8f4fd, #ffffff);
    border: 1px solid #bee5eb;
    border-radius: 10px;
    padding: 16px;
    margin-top: 16px;
}

.auto-validation-metrics h4 {
    color: #0c5460;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

.metric-item {
    text-align: center;
    padding: 12px;
    background: white;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

.metric-value {
    display: block;
    font-size: 24px;
    font-weight: bold;
    color: #495057;
    margin-bottom: 4px;
}

.metric-value.high-priority {
    color: #ED7470;
    animation: pulse 2s infinite;
}

.metric-value.medium-priority {
    color: #ffc107;
}

.metric-value.low-priority {
    color: #28a745;
}

.metric-label {
    font-size: 12px;
    color: #6c757d;
    text-transform: uppercase;
    font-weight: 600;
}

/* === BOUTON DE VALIDATION RAPIDE === */
.btn-auto-validation {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
    width: 100%;
}

.btn-auto-validation:hover:not(:disabled) {
    background: #ED7470;
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(238, 90, 82, 0.3);
}

.btn-auto-validation:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* === INDICATEUR DE VALIDATION AUTOMATIQUE === */
.validation-indicator {
    background: #3498db;
    color: white;
    padding: 12px 16px;
    border-radius: 8px;
    margin-top: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideDown 0.4s ease-in-out;
    border: 1px solid rgba(255,255,255,0.2);
}

.validation-indicator.hidden {
    display: none;
}

.validation-indicator.show {
    display: flex;
}

.indicator-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.indicator-text {
    font-weight: 600;
    font-size: 14px;
}

/* === HISTORIQUE DES VALIDATIONS === */
.validation-history {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 16px;
    margin-top: 16px;
    border: 1px solid #dee2e6;
}

.history-header h4 {
    color: #495057;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.history-item {
    background: white;
    padding: 12px;
    border-radius: 6px;
    border: 1px solid #dee2e6;
    display: flex;
    align-items: center;
    gap: 12px;
}

.history-rating {
    flex-shrink: 0;
}

.history-content {
    flex: 1;
    min-width: 0;
}

.history-query {
    font-size: 14px;
    color: #495057;
    margin-bottom: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.history-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #6c757d;
}

.auto-badge {
    background: #3498db;
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: bold;
}

.manual-badge {
    background: #3498db;
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: bold;
}

/* === ANIMATIONS === */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* === DIALOG DE CONFIRMATION === */
.confirmation-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease-in-out;
}

.confirmation-dialog {
    background: white;
    border-radius: 12px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.dialog-header h4 {
    margin: 0 0 16px 0;
    color: #495057;
    font-size: 18px;
}

.dialog-content p {
    margin: 0 0 20px 0;
    color: #6c757d;
    line-height: 1.5;
}

.dialog-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.btn-cancel, .btn-confirm {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-cancel {
    background: #6c757d;
    color: white;
}

.btn-cancel:hover {
    background: #5a6268;
}

.btn-confirm {
    background: #3498db;
    color: white;
}

.btn-confirm:hover {
    background: #3498db;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .candidates-grid {
        grid-template-columns: 1fr;
    }
    
    .metrics-grid {
        grid-template-columns: 1fr;
    }
    
    .auto-validation-actions {
        flex-direction: column;
    }
    
    .btn-auto-validate {
        min-width: unset;
    }
}