/* Styles pour la page d'inscription aux concours */

.concours-inscription-container {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.concours-inscription-container h1 {
    color: #14532d;
    margin-bottom: 20px;
    font-weight: 600;
}

.concours-info-section {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.concours-info-section h2 {
    color: #14532d;
    margin-bottom: 15px;
}

.search-section {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.search-section h3 {
    color: #333;
    margin-bottom: 20px;
}

.search-form {
    display: flex;
    gap: 15px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.search-form .form-group {
    flex: 1;
    min-width: 200px;
}

.search-form .form-group:last-child {
    display: flex;
    gap: 10px;
    flex: 2;
}

.search-form input[type="text"] {
    flex: 1;
}

.search-results {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.search-results h3 {
    color: #333;
    margin-bottom: 20px;
}

.archer-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 15px;
    border: 1px solid #dee2e6;
    cursor: pointer;
    transition: all 0.3s;
}

.archer-card:hover {
    background: #e9ecef;
    border-color: #14532d;
}

.archer-card.selected {
    background: #d4edda;
    border-color: #14532d;
    border-width: 2px;
}

.archer-card h4 {
    margin: 0 0 10px 0;
    color: #14532d;
}

.archer-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.archer-info-item {
    display: flex;
    flex-direction: column;
}

.archer-info-item strong {
    font-size: 0.85em;
    color: #666;
    margin-bottom: 3px;
}

.inscriptions-section {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.inscriptions-section h3 {
    color: #333;
    margin-bottom: 20px;
}

.actions-section {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 30px;
}

.actions-section .btn {
    padding: 10px 24px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.3s;
    display: inline-block;
}

.actions-section .btn-secondary {
    background-color: #6c757d;
    color: white;
    border: none;
}

.actions-section .btn-secondary:hover {
    background-color: #5a6268;
    color: white;
}

.archer-summary {
    background: #f8f9fa;
    border-left: 4px solid #14532d;
}

#inscription-form h5,
#inscription-form h6 {
    color: #14532d;
    font-weight: 600;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 8px;
    margin-bottom: 15px;
}

#inscription-form .form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 5px;
}

#inscription-form .form-control:focus,
#inscription-form .form-select:focus {
    border-color: #14532d;
    box-shadow: 0 0 0 0.2rem rgba(20, 83, 45, 0.25);
}

#inscription-form .form-check-input:checked {
    background-color: #14532d;
    border-color: #14532d;
}

/* FORCER les couleurs de piquet - Spécificité maximale */
#inscriptions-table tbody tr[data-piquet="rouge"],
#inscriptions-table tbody tr.piquet-rouge,
table.table tbody tr[data-piquet="rouge"],
table.table tbody tr.piquet-rouge,
table tbody tr[data-piquet="rouge"],
table tbody tr.piquet-rouge {
    background-color: #ffe0e0 !important;
    background: #ffe0e0 !important;
}

#inscriptions-table tbody tr[data-piquet="bleu"],
#inscriptions-table tbody tr.piquet-bleu,
table.table tbody tr[data-piquet="bleu"],
table.table tbody tr.piquet-bleu,
table tbody tr[data-piquet="bleu"],
table tbody tr.piquet-bleu {
    background-color: #e0e8ff !important;
    background: #e0e8ff !important;
}

#inscriptions-table tbody tr[data-piquet="blanc"],
#inscriptions-table tbody tr.piquet-blanc,
table.table tbody tr[data-piquet="blanc"],
table.table tbody tr.piquet-blanc,
table tbody tr[data-piquet="blanc"],
table tbody tr.piquet-blanc {
    background-color: #f5f5f5 !important;
    background: #f5f5f5 !important;
}

/* Centrer l'icône de statut et style du dropdown */
#inscriptions-table .statut-cell {
    text-align: center;
    vertical-align: middle;
}

/* Icônes d'actions côte à côte */
#inscriptions-table td:last-child {
    white-space: nowrap;
}
#inscriptions-table td:last-child .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
#inscriptions-table .statut-dropdown .btn-link {
    cursor: pointer;
}

/* Styles pour les lignes colorées selon la couleur du piquet (disciplines 3D, Nature et Campagne) */
/* Styles pour toutes les tables, avec ou sans table-striped */
#inscriptions-table tbody tr.piquet-rouge,
#inscriptions-table tbody tr.piquet-rouge:nth-child(odd),
#inscriptions-table tbody tr.piquet-rouge:nth-child(even),
table.table tbody tr.piquet-rouge,
table.table tbody tr.piquet-rouge:nth-child(odd),
table.table tbody tr.piquet-rouge:nth-child(even) {
    background-color: #ffe0e0 !important; /* Rouge pastel */
}

#inscriptions-table tbody tr.piquet-bleu,
#inscriptions-table tbody tr.piquet-bleu:nth-child(odd),
#inscriptions-table tbody tr.piquet-bleu:nth-child(even),
table.table tbody tr.piquet-bleu,
table.table tbody tr.piquet-bleu:nth-child(odd),
table.table tbody tr.piquet-bleu:nth-child(even) {
    background-color: #e0e8ff !important; /* Bleu pastel */
}

#inscriptions-table tbody tr.piquet-blanc,
#inscriptions-table tbody tr.piquet-blanc:nth-child(odd),
#inscriptions-table tbody tr.piquet-blanc:nth-child(even),
table.table tbody tr.piquet-blanc,
table.table tbody tr.piquet-blanc:nth-child(odd),
table.table tbody tr.piquet-blanc:nth-child(even) {
    background-color: #f5f5f5 !important; /* Blanc/Gris très clair pastel */
}

/* Assurer que les lignes colorées restent visibles au survol */
#inscriptions-table tbody tr.piquet-rouge:hover,
table.table tbody tr.piquet-rouge:hover {
    background-color: #ffcccc !important;
}

#inscriptions-table tbody tr.piquet-bleu:hover,
table.table tbody tr.piquet-bleu:hover {
    background-color: #ccd9ff !important;
}

#inscriptions-table tbody tr.piquet-blanc:hover,
table.table tbody tr.piquet-blanc:hover {
    background-color: #e8e8e8 !important;
}

/* Styles pour les types de licences non valides */
.licence-invalid,
select.licence-invalid,
select.licence-invalid option {
    color: #dc3545 !important;
    font-weight: 600;
}

.licence-warning,
select.licence-warning,
select.licence-warning option {
    color: #fd7e14 !important;
    font-weight: 600;
}

select.licence-invalid {
    border-color: #dc3545 !important;
}

select.licence-warning {
    border-color: #fd7e14 !important;
}

/* Style pour les catégories sélectionnées automatiquement (catégorie exacte non trouvée) */
.categorie-auto-selected,
select.categorie-auto-selected,
select.categorie-auto-selected option:checked {
    color: #dc3545 !important;
    font-weight: 600;
    background-color: #fff5f5 !important;
}

select.categorie-auto-selected {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

.licence-warning-message {
    font-size: 0.875rem;
    margin-top: 0.25rem;
    padding: 0.5rem;
    border-radius: 0.25rem;
}

.licence-warning-message.invalid {
    color: #721c24;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
}

.licence-warning-message.conditional {
    color: #856404;
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
}

/* Responsive */
@media (max-width: 768px) {
    .search-form {
        flex-direction: column;
    }
    
    .search-form .form-group {
        width: 100%;
    }
    
    .archer-info {
        grid-template-columns: 1fr;
    }
}

/* Style pour les champs invalides (validation email) */
#email.is-invalid {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

#email.is-invalid:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

/* Style pour le champ piquet quand aucun choix ne correspond */
#piquet.is-invalid,
#edit-piquet.is-invalid {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}
#piquet.is-invalid:focus,
#edit-piquet.is-invalid:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}
