/* =============================================================================
   style.css — Charte graphique « Classements Tir à l'Arc BFC ».
   -----------------------------------------------------------------------------
   PRINCIPES (cahier des charges §11 « Identité graphique ») :
     - La charte part du LOGO du Comité Régional Bourgogne-Franche-Comté.
     - Le BLEU MARINE porte la structure et les titres.
     - Les BLEUS MOYENS / CLAIRS servent aux interactions et aux fonds.
     - Le JAUNE et le ROUGE (motifs héraldiques du logo) restent des ACCENTS
       ponctuels : jamais un fond dominant, pour garder une interface lisible.
     - Style institutionnel, sportif, orienté données : priorité aux chiffres,
       aux rangs, aux noms et aux tableaux ; très peu de décoration.
     - Les médailles or / argent / bronze sont réservées aux places de podium.

   ACCESSIBILITÉ (cahier des charges §10) :
     - Conception MOBILE FIRST : les styles de base visent le téléphone, les
       « @media (min-width: …) » enrichissent progressivement l'affichage.
     - Toute action tactile mesure au moins 44 x 44 px (--cible-tactile).
     - Contrastes vérifiés conformes WCAG 2.2 AA (4,5:1 texte / 3:1 contrôles).
     - Focus clavier TOUJOURS visible (:focus-visible, anneau de 3 px).
     - Les tableaux se transforment en cartes lisibles sur petit écran.
     - L'information n'est jamais portée par la seule couleur (texte + icône).
   ============================================================================= */

/* =============================================================================
   1. JETONS DE STYLE (« design tokens »)
   Toutes les couleurs, espacements et rayons de l'application sont définis ici.
   Modifier une valeur ici la répercute sur toute l'interface.
   ============================================================================= */
:root {
    /* ---- Bleus marine : structure, en-têtes, titres ---- */
    --navy-900:   #0e2a4e;   /* en-tête du site, bandeaux, titres principaux */
    --navy-800:   #143a69;   /* dégradés, survols de l'en-tête */
    --navy-700:   #1b4b85;   /* bandeaux secondaires */

    /* ---- Bleus moyens / clairs : interactions et fonds ---- */
    --bleu-700:   #175c9b;   /* liens survolés, boutons pressés */
    --bleu-600:   #1d6fb8;   /* couleur d'interaction principale (liens, boutons) */
    --bleu-500:   #3a8dd4;   /* contrôles, bordures actives (usage NON textuel) */
    --bleu-200:   #c7dcf1;   /* bordures douces */
    --bleu-100:   #e4eff9;   /* fonds de mise en avant */
    --bleu-050:   #f2f7fc;   /* fond de page */
    --ciel:       #7fcfef;   /* bleu ciel du logo — décoratif uniquement */

    /* ---- Accents ponctuels (motifs du logo) ---- */
    --jaune:      #f0b400;   /* accent : jamais en fond dominant */
    --jaune-fonce:#8a6100;   /* version lisible sur fond clair (texte) */
    --rouge:      #c8102e;
    --rouge-fonce:#b3000f;   /* version lisible sur fond clair (texte) */
    --vert:       #146c43;   /* validation / présence */

    /* ---- Médailles (réservées aux podiums) ---- */
    --or:         #8a6100;  --or-fond:      #fbf1d2;  --or-bord:     #e9d08a;
    --argent:     #4b5563;  --argent-fond:  #eef0f3;  --argent-bord: #ced3da;
    --bronze:     #7a461f;  --bronze-fond:  #f6e7db;  --bronze-bord: #e2bda0;

    /* ---- Neutres ---- */
    --blanc:      #ffffff;
    --fond:       #f2f7fc;
    --surface:    #ffffff;
    --surface-2:  #f7f9fc;   /* lignes alternées, zones secondaires */
    --bordure:    #d7dee7;
    --bordure-forte: #b6c2d1;
    --texte:      #1f2937;
    --texte-doux: #54606e;

    /* ---- Compatibilité : anciens noms de variables encore référencés ---- */
    --bleu:       #1d6fb8;
    --bleu-fonce: #175c9b;
    --navy:       #0e2a4e;
    --gris-zebre: #f7f9fc;

    /* ---- Rythme, rayons, ombres ---- */
    --cible-tactile: 44px;   /* taille minimale d'une zone cliquable (WCAG 2.2) */
    --r-sm: 6px;
    --r:    10px;
    --r-lg: 14px;
    --radius: 10px;          /* compatibilité */
    --ombre-1: 0 1px 2px rgba(14, 42, 78, .06), 0 1px 3px rgba(14, 42, 78, .08);
    --ombre-2: 0 2px 6px rgba(14, 42, 78, .08), 0 8px 24px rgba(14, 42, 78, .07);
    --ombre:   var(--ombre-1);
    --largeur:  1200px;      /* largeur maximale du contenu */

    /* ---- Typographie ---- */
    --police: "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
    --police-chiffres: "SF Mono", ui-monospace, "Segoe UI Mono", Menlo, Consolas, monospace;
}

/* =============================================================================
   2. BASE
   ============================================================================= */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
    margin: 0;
    font-family: var(--police);
    font-size: 16px;              /* base confortable sur mobile */
    color: var(--texte);
    background: var(--fond);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--bleu-600); text-underline-offset: 2px; }
a:hover { color: var(--bleu-700); }

img { max-width: 100%; height: auto; }

/* --- Focus clavier TOUJOURS visible (exigence d'accessibilité) --- */
:focus-visible {
    outline: 3px solid var(--bleu-500);
    outline-offset: 2px;
    border-radius: 4px;
}
/* Sur fond marine, l'anneau passe en clair pour rester contrasté. */
.site-header :focus-visible, .panel-head :focus-visible {
    outline-color: #ffd66b;
}

/* --- Lien d'évitement (accès direct au contenu au clavier) --- */
.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 200;
    background: var(--jaune); color: #241a00; font-weight: 700;
    padding: 12px 18px; border-radius: 0 0 var(--r) 0; text-decoration: none;
}
.skip-link:focus { left: 0; }

/* --- Réservé aux lecteurs d'écran --- */
.sr-only {
    position: absolute !important; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* =============================================================================
   3. EN-TÊTE DU SITE (bleu marine = structure)
   ============================================================================= */
.site-header {
    background: linear-gradient(180deg, var(--navy-900) 0%, var(--navy-800) 100%);
    color: #fff;
    position: relative;
    z-index: 40;
}
.site-header .inner {
    max-width: var(--largeur);
    margin: 0 auto;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.site-header .logo {
    display: flex; align-items: center;
    background: #fff; border-radius: 8px; padding: 4px;
    flex: 0 0 auto;
}
.site-header .logo img { height: 44px; width: auto; display: block; }
.site-header .titre { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.site-header .titre .t1 { font-weight: 800; font-size: 1.02rem; color: #fff; line-height: 1.15; letter-spacing: .01em; }
.site-header .titre .t2 { color: var(--bleu-100); font-size: .78rem; line-height: 1.2; }
.site-header .devise { display: none; }

/* Navigation principale : repliée derrière un bouton sur mobile. */
.nav-toggle {
    margin-left: auto;
    min-width: var(--cible-tactile); min-height: var(--cible-tactile);
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    background: rgba(255, 255, 255, .12); color: #fff;
    border: 1px solid rgba(255, 255, 255, .35); border-radius: var(--r-sm);
    font: inherit; font-size: .85rem; font-weight: 700; cursor: pointer; padding: 0 12px;
}
.nav-toggle:hover { background: rgba(255, 255, 255, .22); }
.nav-toggle .bars { font-size: 1.1rem; line-height: 1; }

.site-header nav.principale {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 2px;
    padding: 6px 0 10px;
    border-top: 1px solid rgba(255, 255, 255, .18);
    margin-top: 8px;
}
.site-header nav.principale.ouvert { display: flex; }
.site-header nav.principale a {
    display: flex; align-items: center; gap: 8px;
    min-height: var(--cible-tactile);
    padding: 6px 12px;
    color: var(--bleu-100); text-decoration: none;
    font-weight: 600; font-size: .95rem; border-radius: var(--r-sm);
}
.site-header nav.principale a:hover { background: rgba(255, 255, 255, .14); color: #fff; }
/* Page courante : soulignement jaune + attribut aria-current (jamais la couleur seule). */
.site-header nav.principale a[aria-current="page"] {
    color: #fff; background: rgba(255, 255, 255, .14);
    box-shadow: inset 3px 0 0 var(--jaune);
}
.site-header nav.principale a.admin-link { opacity: .8; font-size: .9rem; }

@media (min-width: 900px) {
    .site-header .inner { padding: 12px 18px; gap: 16px; }
    .site-header .logo img { height: 52px; }
    .site-header .titre .t1 { font-size: 1.15rem; }
    .nav-toggle { display: none; }
    .site-header nav.principale {
        display: flex; flex-direction: row; align-items: center;
        width: auto; margin: 0 0 0 auto; padding: 0; border: 0; gap: 2px;
    }
    .site-header nav.principale a { min-height: 40px; padding: 8px 12px; font-size: .9rem; }
    .site-header nav.principale a[aria-current="page"] {
        box-shadow: inset 0 -3px 0 var(--jaune);
    }
    .site-header .devise {
        display: block; color: var(--ciel); font-size: .72rem; line-height: 1.35;
        text-align: right; text-transform: uppercase; letter-spacing: .08em; font-weight: 700;
        padding-left: 14px; border-left: 1px solid rgba(255, 255, 255, .2);
    }
}

/* --- Bandeau d'environnement (préproduction / développement) ---
   Volontairement très visible : il ne doit jamais y avoir de doute sur le site
   que l'on consulte. Il disparaît totalement en production. */
.bandeau-env {
    margin: 0; padding: 7px 14px; text-align: center;
    background: var(--jaune); color: #241a00;
    font-size: .84rem; font-weight: 600; border-bottom: 2px solid #c99700;
}

/* =============================================================================
   4. FIL D'ARIANE
   ============================================================================= */
.fil-ariane { max-width: var(--largeur); margin: 0 auto; padding: 10px 14px 0; font-size: .82rem; color: var(--texte-doux); }
.fil-ariane ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; }
.fil-ariane li::after { content: "›"; margin-left: 6px; color: var(--bordure-forte); }
.fil-ariane li:last-child::after { content: ""; }
.fil-ariane a { color: var(--bleu-600); }
.fil-ariane [aria-current="page"] { color: var(--texte); font-weight: 600; }

/* =============================================================================
   5. CONTENU PRINCIPAL
   ============================================================================= */
main { max-width: var(--largeur); margin: 16px auto 0; padding: 0 14px 56px; }
@media (min-width: 900px) { main { margin-top: 22px; padding: 0 18px 72px; } }

h1.page-title {
    color: var(--navy-900); font-size: 1.45rem; line-height: 1.2;
    margin: 4px 0 14px; font-weight: 800; letter-spacing: -.01em;
}
@media (min-width: 700px) { h1.page-title { font-size: 1.85rem; } }

/* =============================================================================
   6. BANDEAU D'ACCUEIL (hero)
   ============================================================================= */

/* Voile bleu ciel très discret rappelant les arcs du logo (décoratif). */

/* Barre de recherche globale */

/* =============================================================================
   7. CARTES D'ACCÈS RAPIDE
   ============================================================================= */

/* =============================================================================
   8. PANNEAUX (cartes de contenu)
   ============================================================================= */
.panel {
    background: var(--surface); border: 1px solid var(--bordure); border-radius: var(--r);
    box-shadow: var(--ombre-1); margin-bottom: 18px; overflow: hidden;
}
.panel > .panel-head {
    background: var(--navy-900); color: #fff; padding: 11px 16px;
    font-weight: 700; font-size: .95rem;
    display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; justify-content: space-between;
}
.panel > .panel-head a { color: #cfe3f7; }
.panel > .panel-body { padding: 14px 16px; }
@media (min-width: 700px) { .panel > .panel-body { padding: 16px 18px; } }

/* Grille de panneaux côte à côte (accueil, fiches). */
.colonnes { display: grid; grid-template-columns: 1fr; gap: 18px; align-items: start; }

/* =============================================================================
   9. EN-TÊTE DE FICHE (archer, club, classement)
   ============================================================================= */
.fiche-tete {
    background: var(--surface); border: 1px solid var(--bordure); border-radius: var(--r);
    box-shadow: var(--ombre-1); padding: 16px; margin-bottom: 18px;
    display: flex; flex-wrap: wrap; gap: 14px; align-items: flex-start;
}
.fiche-tete .embleme {
    width: 64px; height: 64px; flex: 0 0 auto; border-radius: var(--r-sm);
    background: var(--bleu-050); border: 1px solid var(--bordure);
    display: flex; align-items: center; justify-content: center; overflow: hidden;
    font-size: 1.5rem; color: var(--navy-700); font-weight: 800;
}
.fiche-tete .embleme img { max-width: 100%; max-height: 100%; object-fit: contain; }
.fiche-tete .ident { flex: 1 1 240px; min-width: 0; }
.fiche-tete .ident h1 { margin: 0; font-size: 1.35rem; color: var(--navy-900); font-weight: 800; line-height: 1.2; }
.fiche-tete .ident .sous { color: var(--texte-doux); font-size: .9rem; margin-top: 3px; }
.fiche-tete .actions-fiche { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }

/* Tuiles de statistiques (chiffres mis en avant). */
.tuiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 14px 0 0; }
@media (min-width: 700px) { .tuiles { grid-template-columns: repeat(4, 1fr); } }
.tuile {
    background: var(--bleu-050); border: 1px solid var(--bleu-200); border-radius: var(--r-sm);
    padding: 10px 12px; text-align: center; text-decoration: none; color: inherit; display: block;
}
a.tuile:hover { background: var(--bleu-100); border-color: var(--bleu-500); }
.tuile .val { display: block; font-size: 1.55rem; font-weight: 800; color: var(--navy-900); line-height: 1.1; }
.tuile .lab { display: block; font-size: .74rem; color: var(--texte-doux); text-transform: uppercase; letter-spacing: .04em; margin-top: 2px; }

/* =============================================================================
   10. ONGLETS (Individuel / Clubs / Disciplines / Historique…)
   ============================================================================= */
.onglets {
    display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 16px;
    border-bottom: 2px solid var(--bordure); padding-bottom: 0;
}
.onglets a {
    display: inline-flex; align-items: center; gap: 6px;
    min-height: var(--cible-tactile); padding: 8px 14px;
    text-decoration: none; color: var(--texte-doux); font-weight: 700; font-size: .92rem;
    border: 2px solid transparent; border-bottom: none; border-radius: var(--r-sm) var(--r-sm) 0 0;
    margin-bottom: -2px;
}
.onglets a:hover { color: var(--navy-900); background: var(--bleu-050); }
/* Onglet actif : couleur + soulignement épais + aria-current (pas la couleur seule). */
.onglets a[aria-current="page"] {
    color: var(--navy-900); background: var(--surface);
    border-color: var(--bordure); border-bottom: 2px solid var(--surface);
    box-shadow: inset 0 3px 0 var(--bleu-600);
}

/* =============================================================================
   11. FILTRES (étiquettes explicites, empilés sur mobile)
   ============================================================================= */
.filtres-barre {
    background: var(--surface); border: 1px solid var(--bordure); border-radius: var(--r);
    box-shadow: var(--ombre-1); padding: 14px; margin-bottom: 18px;
}
.filtres-grille { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 620px) { .filtres-grille { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .filtres-grille { grid-template-columns: repeat(4, 1fr); } }
.filtres-grille .large { grid-column: 1 / -1; }
.champ { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.champ > label {
    font-weight: 700; font-size: .8rem; color: var(--navy-900);
    text-transform: uppercase; letter-spacing: .03em;
}
.champ .aide { font-size: .78rem; color: var(--texte-doux); }
.champ select, .champ input, .champ textarea {
    min-height: var(--cible-tactile);
    width: 100%; padding: 9px 11px; font-size: .95rem; font-family: inherit; color: var(--texte);
    background: #fff; border: 1px solid var(--bordure-forte); border-radius: var(--r-sm);
}
.champ select:hover, .champ input:hover { border-color: var(--bleu-500); }
.filtres-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; align-items: center; }

/* Ancien gabarit de filtres (écrans d'administration) — conservé et harmonisé. */
.filters { display: grid; grid-template-columns: 1fr; gap: 10px 24px; }
@media (min-width: 700px) { .filters { grid-template-columns: repeat(2, minmax(260px, 1fr)); } }
.filters .row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.filters label { min-width: 118px; font-weight: 700; color: var(--navy-900); font-size: .86rem; }
@media (min-width: 700px) { .filters label { text-align: right; } }
.filters select, .filters input[type=text] {
    flex: 1 1 160px; min-height: var(--cible-tactile); padding: 8px 10px;
    border: 1px solid var(--bordure-forte); border-radius: var(--r-sm); background: #fff;
    font-size: .93rem; font-weight: 600; font-family: inherit;
}
.filters .actions { grid-column: 1 / -1; display: flex; justify-content: center; gap: 10px; margin-top: 6px; flex-wrap: wrap; }

/* Rappel des filtres appliqués (chips) — sert aussi aux messages « aucun résultat ». */
.filtres-actifs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; padding: 0; list-style: none; }
.filtres-actifs li {
    background: var(--bleu-100); border: 1px solid var(--bleu-200); color: var(--navy-900);
    border-radius: 999px; padding: 3px 11px; font-size: .8rem; font-weight: 600;
}

/* =============================================================================
   12. BOUTONS (zone cliquable ≥ 44 px)
   ============================================================================= */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    min-height: var(--cible-tactile); padding: 9px 16px;
    cursor: pointer; border: 1px solid var(--bordure-forte); background: #fff;
    color: var(--navy-900); font-weight: 700; font-size: .9rem; font-family: inherit;
    border-radius: var(--r-sm); text-decoration: none; text-align: center;
}
.btn:hover { background: var(--bleu-050); border-color: var(--bleu-500); color: var(--navy-900); }
.btn-primary { background: var(--bleu-600); border-color: var(--bleu-600); color: #fff; }
.btn-primary:hover { background: var(--bleu-700); border-color: var(--bleu-700); color: #fff; }

.btn-danger { background: var(--rouge-fonce); border-color: var(--rouge-fonce); color: #fff; }
.btn-danger:hover { background: #8e000c; color: #fff; }
/* Petit bouton : la hauteur reste tactile sur mobile, elle se réduit sur grand écran. */
.btn-sm { padding: 5px 12px; font-size: .83rem; }
@media (min-width: 900px) { .btn-sm { min-height: 34px; } }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }

/* =============================================================================
   13. TABLEAUX DE DONNÉES
   En-têtes sémantiques (<th scope>), défilement horizontal maîtrisé, et
   ALTERNATIVE EN CARTES sur petit écran (classe .table-cartes).
   ============================================================================= */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }

table.grid { width: 100%; border-collapse: collapse; font-size: .9rem; background: #fff; }
table.grid caption { text-align: left; padding: 8px 10px; color: var(--texte-doux); font-size: .85rem; }
table.grid thead th {
    background: var(--navy-900); color: #fff; text-align: left; padding: 10px;
    font-weight: 700; font-size: .82rem; text-transform: uppercase; letter-spacing: .03em;
    white-space: nowrap; position: sticky; top: 0; z-index: 2;
}
table.grid thead th a { color: #cfe3f7; }
table.grid tbody td { padding: 9px 10px; border-bottom: 1px solid #e9edf3; vertical-align: middle; }
table.grid tbody tr:nth-child(even) { background: var(--surface-2); }
table.grid tbody tr:hover { background: var(--bleu-100); }
table.grid td.num, table.grid th.num { text-align: center; }
table.grid td.rang { font-weight: 800; color: var(--navy-900); text-align: center; font-variant-numeric: tabular-nums; }
table.grid td.moy { font-weight: 800; text-align: center; font-variant-numeric: tabular-nums; color: var(--navy-900); }
table.grid td.score, table.grid th.score { text-align: center; font-variant-numeric: tabular-nums; }
/* Précision secondaire placée sous une valeur de cellule (catégorie sous un nom,
   nom du concours sous un résultat…) : elle passe à la ligne plutôt que de coller
   au texte principal. */
table.grid td > .help { display: block; margin-top: 1px; }

.list-classements tbody tr { cursor: pointer; }
.list-classements .nom { font-weight: 700; color: var(--navy-900); }

/* Nom d'archer / de club mis en avant dans un tableau. */
.nom-archer { font-weight: 700; color: var(--navy-900); }
.nom-archer .prenom { font-weight: 500; color: var(--texte); }

/* --- Alternative en CARTES sur petit écran ---------------------------------
   Le tableau porte la classe .table-cartes et chaque <td> un attribut
   data-label="Intitulé de colonne" : sous 720 px, chaque ligne devient une
   carte lisible, sans défilement horizontal.                                */
@media (max-width: 719px) {
    table.table-cartes { display: block; background: transparent; }
    table.table-cartes thead {
        position: absolute; width: 1px; height: 1px; overflow: hidden;
        clip: rect(0 0 0 0); white-space: nowrap;   /* en-têtes conservés pour les lecteurs d'écran */
    }
    table.table-cartes tbody { display: block; }
    /* Chaque ligne devient une carte. On utilise une colonne flexible pour pouvoir
       remonter la cellule « titre » (le nom, le classement…) en tête de carte,
       quel que soit son rang dans le tableau. */
    table.table-cartes tbody tr {
        display: flex; flex-direction: column; background: #fff !important;
        border: 1px solid var(--bordure); border-radius: var(--r-sm);
        margin-bottom: 10px; padding: 8px 10px; box-shadow: var(--ombre-1);
    }
    table.table-cartes tbody tr:hover { background: #fff !important; }
    table.table-cartes tbody td {
        display: flex; flex-wrap: wrap;
        justify-content: space-between; gap: 2px 12px; align-items: baseline;
        padding: 5px 0; border: 0; border-bottom: 1px dashed #eef1f5; text-align: left !important;
    }
    /* La cellule étant un conteneur flexible, ses enfants deviennent des éléments
       placés CÔTE À CÔTE. Un complément d'information (.help : date, score, lieu…)
       se retrouvait donc comprimé contre le texte principal, et son contenu était
       rogné (« 24/01/202… · score 47… »). On lui donne une ligne entière. */
    table.table-cartes tbody td > .help {
        flex: 1 0 100%; text-align: right; margin-top: 2px;
    }
    /* Un contenu long doit pouvoir se réduire au lieu de déborder de la cellule. */
    table.table-cartes tbody td > * { min-width: 0; overflow-wrap: anywhere; }
    table.table-cartes tbody td:last-child { border-bottom: 0; }
    table.table-cartes tbody td::before {
        content: attr(data-label);
        font-size: .74rem; font-weight: 700; color: var(--texte-doux);
        text-transform: uppercase; letter-spacing: .03em; flex: 0 0 42%;
    }
    table.table-cartes tbody td[data-label=""]::before { content: ""; }

    /* Cellule « titre » : affichée EN TÊTE de la carte (order: -1), en évidence. */
    table.table-cartes tbody td.carte-titre {
        order: -1;
        font-size: 1.02rem; font-weight: 700; color: var(--navy-900);
        border-bottom: 1px solid var(--bordure); padding-bottom: 7px; margin-bottom: 3px;
    }
    table.table-cartes tbody td.carte-titre::before { display: none; }
}

/* --- CLASSEMENT SUR TÉLÉPHONE : une vraie ligne de classement -----------------
   Un classement se lit en colonnes : le rang, le nom, la moyenne. L'empiler en
   carte (comme les autres tableaux) faisait perdre cette lecture et donnait des
   lignes énormes. Sous 720 px, on garde donc UNE LIGNE COMPACTE — rang, archer,
   moyenne — et le reste (licence, club, scores) se déplie avec la flèche.        */

/* La colonne de la flèche n'existe que sur petit écran. */
.col-detail { display: none; }
.btn-detail {
    display: inline-flex; align-items: center; justify-content: center;
    width: 34px; height: 34px; padding: 0;
    background: none; border: 1px solid var(--bordure); border-radius: var(--r-sm);
    color: var(--navy-900); font-size: 1.1rem; line-height: 1; cursor: pointer;
    transition: transform .15s;
}
.btn-detail:hover { background: var(--bleu-050); border-color: var(--bleu-500); }
.aide-mobile { display: none; }

@media (max-width: 719px) {
    .col-detail { display: block; }
    .aide-mobile { display: inline; }

    table.table-classement { display: block; background: transparent; }
    table.table-classement thead {
        position: absolute; width: 1px; height: 1px; overflow: hidden;
        clip: rect(0 0 0 0); white-space: nowrap;   /* conservé pour les lecteurs d'écran */
    }
    table.table-classement tbody { display: block; }

    /* Une ligne = une grille : rang | archer | moyenne | flèche. */
    table.table-classement tbody tr {
        display: grid;
        grid-template-columns: 2.9em 1fr auto 34px;
        align-items: center;
        gap: 4px 8px;
        padding: 5px 8px;
        border-bottom: 1px solid #e9edf3;
        background: #fff;
    }
    table.table-classement tbody tr:nth-child(even) { background: var(--surface-2); }

    /* Les trois informations essentielles, sur la première ligne de la grille. */
    table.table-classement tbody td.rang       { order: 1; padding: 0; text-align: left; }
    table.table-classement tbody td.col-archer { order: 2; padding: 0; min-width: 0; }
    table.table-classement tbody td.moy        { order: 3; padding: 0; font-size: 1.05rem; }
    table.table-classement tbody td.col-detail { order: 4; padding: 0; text-align: right; }

    /* Le nom reste sur une seule ligne, coupé proprement si besoin. Le soulignement
       du lien s'arrête au texte (et non au bord de la colonne). */
    table.table-classement tbody td.col-archer .lien-palmares {
        display: inline-block; max-width: 100%; vertical-align: bottom;
        white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
        font-size: .95rem;
    }

    /* Le détail : replié par défaut, dépliable ligne par ligne. */
    table.table-classement tbody td.detail {
        order: 10; grid-column: 1 / -1; display: none;
        padding: 3px 0 3px 2.9em; border: 0;
        justify-content: space-between; gap: 12px; align-items: baseline;
        font-size: .88rem;
    }
    table.table-classement tbody tr.ouvert td.detail { display: flex; }
    table.table-classement tbody tr.ouvert td.detail:last-of-type { padding-bottom: 8px; }
    table.table-classement tbody td.detail::before {
        content: attr(data-label);
        font-size: .74rem; font-weight: 700; color: var(--texte-doux);
        text-transform: uppercase; letter-spacing: .03em;
    }
    table.table-classement tbody tr.ouvert { background: var(--bleu-050); }
    table.table-classement tbody tr.ouvert .btn-detail { transform: rotate(180deg); }
}

/* =============================================================================
   14. MÉDAILLES ET PODIUMS (réservés aux places 1-2-3)
   ============================================================================= */
.medaille {
    display: inline-flex; align-items: center; justify-content: center; gap: 4px;
    min-width: 2.1em; padding: 2px 8px; border-radius: 999px;
    font-weight: 800; font-size: .82rem; border: 1px solid transparent;
    font-variant-numeric: tabular-nums;
}
.medaille.or     { background: var(--or-fond);     color: var(--or);     border-color: var(--or-bord); }
.medaille.argent { background: var(--argent-fond); color: var(--argent); border-color: var(--argent-bord); }
.medaille.bronze { background: var(--bronze-fond); color: var(--bronze); border-color: var(--bronze-bord); }
/* Le pictogramme est décoratif : le NUMÉRO reste toujours écrit à côté. */
.medaille .pict { font-size: .95em; }

/* Intertitre de saison à l'intérieur d'un tableau (palmarès toutes saisons). */

/* Rang dans un CLASSEMENT : les trois premières places sont mises en évidence,
   MAIS sans médaille — un classement n'est pas un championnat. */
.rang-tete {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 2em; padding: 2px 8px; border-radius: 999px;
    background: var(--navy-900); color: #fff; font-weight: 800; font-size: .85rem;
}

/* Fiche club : classements regroupés discipline → arme → catégorie (cartes). */
.sommaire-disc { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.club-disc { margin: 0 0 22px; scroll-margin-top: 12px; }
.club-disc-titre {
    margin: 0 0 10px; padding: 8px 12px; border-radius: var(--r-sm);
    background: var(--navy-900); color: #fff; font-size: 1.05rem; font-weight: 800;
}
.club-arme-titre {
    margin: 14px 0 8px; font-size: .95rem; color: var(--navy-700); font-weight: 800;
    border-bottom: 2px solid var(--bleu-200); padding-bottom: 3px;
}
.club-cartes { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.club-carte {
    background: var(--surface); border: 1px solid var(--bordure); border-radius: var(--r-sm);
    box-shadow: var(--ombre-1); display: flex; flex-direction: column;
}
.club-carte > header {
    display: flex; justify-content: space-between; align-items: baseline; gap: 8px;
    padding: 8px 12px; background: var(--bleu-100); border-bottom: 1px solid var(--bleu-200);
    border-radius: var(--r-sm) var(--r-sm) 0 0;
}
.club-carte h4 { margin: 0; font-size: .98rem; font-weight: 800; color: var(--navy-900); }
.club-carte-archers { list-style: none; margin: 0; padding: 4px 0; flex: 1; }
.club-carte-archers li {
    display: grid; grid-template-columns: 2.6em 1fr auto; gap: 8px; align-items: center;
    padding: 5px 12px;
}
.club-carte-archers li + li { border-top: 1px solid var(--surface-2); }
.club-carte-archers .rang-club { text-align: center; font-weight: 700; }
.club-carte-archers .nom { min-width: 0; overflow-wrap: anywhere; }
.club-carte-archers .moy { font-weight: 800; color: var(--navy-900); }
.club-carte-lien {
    display: block; padding: 8px 12px; border-top: 1px solid var(--bordure);
    font-size: .85rem; font-weight: 700; text-decoration: none; text-align: right;
}
.club-carte-lien:hover { background: var(--bleu-050); }

/* Fiche club, onglet Archers : un classement = une étiquette. */
.etiquettes-classement { display: flex; flex-wrap: wrap; gap: 6px; }
.etiquette-classement {
    display: inline-flex; flex-wrap: wrap; gap: 2px 8px; align-items: baseline;
    padding: 4px 10px; border-radius: var(--r-sm); text-decoration: none; color: var(--texte);
    background: var(--bleu-050); border: 1px solid var(--bleu-200); font-size: .84rem;
}
.etiquette-classement:hover { border-color: var(--bleu-500); background: var(--bleu-100); }
.etiquette-classement .ec-rang { font-weight: 800; color: var(--navy-900); }

.compteur-medailles { display: flex; flex-wrap: wrap; gap: 10px; }
.compteur-medailles .m {
    flex: 1 1 90px; text-align: center; border-radius: var(--r-sm); padding: 10px 8px;
    border: 1px solid var(--bordure);
}
.compteur-medailles .m .n { display: block; font-size: 1.6rem; font-weight: 800; line-height: 1.1; }
.compteur-medailles .m .l { display: block; font-size: .76rem; text-transform: uppercase; letter-spacing: .04em; }
.compteur-medailles .m.or     { background: var(--or-fond);     border-color: var(--or-bord);     color: var(--or); }
.compteur-medailles .m.argent { background: var(--argent-fond); border-color: var(--argent-bord); color: var(--argent); }
.compteur-medailles .m.bronze { background: var(--bronze-fond); border-color: var(--bronze-bord); color: var(--bronze); }
.compteur-medailles .m.total  { background: var(--bleu-050);    border-color: var(--bleu-200);    color: var(--navy-900); }

/* =============================================================================
   15. BANDEAU D'INFORMATION / BADGES / ÉTIQUETTES
   ============================================================================= */
.result-bar {
    background: var(--bleu-050); border: 1px solid var(--bleu-200); border-radius: var(--r-sm);
    padding: 9px 14px; margin-bottom: 12px; color: var(--texte-doux); font-size: .87rem;
    display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center;
}
.maj {
    background: var(--bleu-100); color: var(--navy-900); border: 1px solid var(--bleu-200);
    border-radius: 999px; padding: 4px 12px; font-size: .82rem; font-weight: 700; display: inline-block;
}

.badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: .78rem; font-weight: 700; border: 1px solid transparent; }
.badge.inscrit { background: #e3f2e8; color: var(--vert); border-color: #b9dcc6; }
.badge.desinscrit { background: #fbe6e8; color: var(--rouge-fonce); border-color: #eeb9be; }
/* Niveau de championnat : chaque niveau a sa teinte, MAIS le libellé est toujours
   écrit en toutes lettres (l'information ne repose jamais sur la seule couleur). */
.badge.niveau { background: var(--bleu-100); color: var(--navy-900); border-color: var(--bleu-200); }
.badge.niveau.n-D, .badge.niveau.n-D-R { background: var(--bleu-050); color: var(--navy-700); border-color: var(--bleu-200); }
.badge.niveau.n-R { background: #e8e4f7; color: #40308a; border-color: #c8bfe9; }
.badge.niveau.n-A, .badge.niveau.n-WFT { background: #e6f2ea; color: var(--vert); border-color: #b9dcc6; }
.badge.niveau.n-N { background: #fdf0d8; color: var(--jaune-fonce); border-color: #eed49a; }
.badge.niveau.n-I, .badge.niveau.n-E, .badge.niveau.n-M { background: #fbe6e8; color: var(--rouge-fonce); border-color: #eeb9be; }
.check-inscrit { color: var(--vert); font-weight: 800; }

.tag {
    display: inline-block; background: var(--bleu-050); border: 1px solid var(--bordure);
    border-radius: 4px; padding: 1px 7px; font-size: .8rem; margin: 1px; color: var(--texte);
}

/* Logo de club (petit, dans les listes ; moyen sur les fiches). */
.logo-club {
    display: inline-flex; align-items: center; justify-content: center;
    width: 26px; height: 26px; flex: 0 0 auto; overflow: hidden;
    background: #fff; border: 1px solid var(--bordure); border-radius: 4px; vertical-align: middle;
}
.logo-club img { max-width: 100%; max-height: 100%; object-fit: contain; }
.cellule-club { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }

/* =============================================================================
   16. MESSAGES (flash + absence de résultat)
   ============================================================================= */
.flash {
    padding: 11px 15px; border-radius: var(--r-sm); margin-bottom: 12px;
    font-weight: 600; border: 1px solid transparent;
}
.flash.success { background: #e3f2e8; color: #14532d; border-color: #b9dcc6; }
.flash.error   { background: #fbe6e8; color: #7f1220; border-color: #eeb9be; }
.flash.info    { background: var(--bleu-100); color: var(--navy-900); border-color: var(--bleu-200); }

/* Message « aucun résultat » UTILE : rappelle les filtres et propose de les élargir. */
.aucun-resultat {
    text-align: center; padding: 26px 18px; color: var(--texte-doux);
    background: var(--bleu-050); border: 1px dashed var(--bleu-200); border-radius: var(--r);
}
.aucun-resultat .pict { font-size: 2rem; display: block; margin-bottom: 6px; }
.aucun-resultat strong { color: var(--navy-900); }
.aucun-resultat .pistes { margin: 12px 0 0; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }

/* =============================================================================
   17. PAGINATION / CHARGEMENT PROGRESSIF
   ============================================================================= */
.pagination { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; justify-content: center; margin: 16px 0 4px; }
.pagination a, .pagination span {
    min-width: var(--cible-tactile); min-height: var(--cible-tactile);
    display: inline-flex; align-items: center; justify-content: center; padding: 4px 12px;
    border: 1px solid var(--bordure-forte); border-radius: var(--r-sm);
    text-decoration: none; color: var(--navy-900); font-weight: 700; font-size: .88rem; background: #fff;
}
.pagination a:hover { background: var(--bleu-050); border-color: var(--bleu-500); }
.pagination [aria-current="page"] { background: var(--bleu-600); border-color: var(--bleu-600); color: #fff; }
.pagination .ellipse { border: 0; background: transparent; min-width: auto; }
.pagination-info { text-align: center; color: var(--texte-doux); font-size: .85rem; margin-top: 8px; }

/* =============================================================================
   18. LIENS PALMARÈS / ÉTATS DE LIGNE
   ============================================================================= */
.lien-palmares {
    color: var(--bleu-600); cursor: pointer; text-decoration: underline; text-underline-offset: 2px;
    background: none; border: 0; font: inherit; padding: 0; text-align: left;
}
.lien-palmares:hover { color: var(--bleu-700); background: var(--bleu-100); border-radius: 3px; }

/* Score non compté (non valide, exclu, hors plage) : atténué + barré + astérisque. */
.score-exclu { color: #6b7280; background: #f6f7f9; }
.score-exclu s { color: var(--rouge-fonce); }

/* Quotas : lignes sélectionnées (le numéro de place reste écrit, pas seulement la couleur). */
table.grid tbody tr.sel-in { background: #e9f5ee; }
table.grid tbody tr.sel-in:nth-child(even) { background: #dff0e7; }
table.grid tbody tr.sel-in td.rang { color: var(--vert); }

/* Accès administration discret depuis le site public. */
.admin-link { opacity: .6; text-decoration: none; }
.admin-link:hover { opacity: 1; }

/* =============================================================================
   18bis. CARTE DES CLUBS
   ============================================================================= */
.carte-clubs {
    height: 380px; width: 100%;
    border: 1px solid var(--bordure); border-radius: var(--r-sm);
    background: var(--bleu-050);
    z-index: 1;                      /* reste sous les menus déroulants du site */
}
@media (min-width: 900px) { .carte-clubs { height: 480px; } }
/* Les bulles d'information reprennent la typographie du site. */
.leaflet-popup-content { font-family: var(--police); font-size: .88rem; line-height: 1.45; }
.leaflet-popup-content a { color: var(--bleu-600); }
.leaflet-container { font-family: var(--police); }

/* =============================================================================
   19. PIED DE PAGE ET PARTENAIRES
   ============================================================================= */
.site-footer { border-top: 3px solid var(--navy-900); background: #fff; margin-top: 44px; }
.sponsors { max-width: var(--largeur); margin: 0 auto; padding: 22px 16px; text-align: center; }
.sponsors h4 { color: var(--texte-doux); font-size: .78rem; letter-spacing: .09em; text-transform: uppercase; margin: 0 0 16px; }
.sponsors .logos { display: flex; flex-wrap: wrap; gap: 20px 34px; justify-content: space-evenly; align-items: center; }
.sponsors .logos > * { flex: 0 1 auto; }
.sponsors .logos img { max-height: 62px; max-width: 200px; object-fit: contain; filter: grayscale(15%); transition: filter .15s; }
.sponsors .logos a:hover img { filter: grayscale(0%); }
.footer-legal {
    text-align: center; color: var(--texte-doux); font-size: .8rem;
    padding: 14px 16px; border-top: 1px solid #eef1f5; background: var(--bleu-050);
}
.footer-legal a { color: var(--bleu-700); }

/* =============================================================================
   20. FENÊTRE MODALE
   ============================================================================= */
.modal-overlay {
    position: fixed; inset: 0; background: rgba(14, 42, 78, .6); display: none;
    align-items: flex-start; justify-content: center; padding: 24px 12px; z-index: 60; overflow-y: auto;
}
.modal-overlay.open { display: flex; }
.modal { background: #fff; border-radius: var(--r); max-width: 900px; width: 100%; box-shadow: 0 18px 50px rgba(14, 42, 78, .35); }
.modal .modal-head {
    background: var(--navy-900); color: #fff; padding: 12px 16px;
    display: flex; justify-content: space-between; align-items: center; gap: 10px;
    border-radius: var(--r) var(--r) 0 0; font-weight: 700;
}
.modal .modal-head .close {
    cursor: pointer; font-size: 1.5rem; line-height: 1; background: none; border: 0; color: #fff;
    min-width: var(--cible-tactile); min-height: var(--cible-tactile);
}
.modal .modal-body { padding: 16px; max-height: 72vh; overflow-y: auto; }
.modal .archer-id { font-size: 1.2rem; font-weight: 800; color: var(--navy-900); line-height: 1.2; }

/* En-tête de la fenêtre palmarès : identité à gauche, accès à la fiche à droite. */
.palmares-entete {
    display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between;
    padding-bottom: 12px; margin-bottom: 4px; border-bottom: 1px solid var(--bordure);
}
.palmares-sous-titre {
    margin: 18px 0 8px; font-size: .95rem; color: var(--navy-900); font-weight: 800;
}
.palmares-repartition { margin: 4px 0 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }

/* Score RETENU pour le calcul du classement (S1, S2, S3) : l'information la plus
   utile du tableau, mise en évidence sans ambiguïté (pastille + ligne teintée). */
.badge-retenu {
    display: inline-block; min-width: 2.1em; padding: 2px 8px; border-radius: 999px;
    background: var(--bleu-600); color: #fff; font-weight: 800; font-size: .76rem;
    letter-spacing: .02em;
}
table.grid tbody tr.ligne-retenue { background: var(--bleu-050); }
table.grid tbody tr.ligne-retenue:nth-child(even) { background: var(--bleu-100); }
table.grid tbody tr.ligne-retenue td[data-label="Score"] { color: var(--navy-900); }

/* =============================================================================
   21. STATISTIQUES ET GRAPHIQUES
   ============================================================================= */
.stat-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 14px 0; }
@media (min-width: 760px) { .stat-cards { grid-template-columns: repeat(4, 1fr); } }
.stat-card {
    background: var(--bleu-050); border: 1px solid var(--bleu-200); border-radius: var(--r-sm);
    padding: 10px 12px; display: flex; flex-direction: column;
}
.stat-card .stat-label {
    color: var(--texte-doux); font-size: .72rem; text-transform: uppercase; letter-spacing: .04em;
    /* Deux lignes réservées : toutes les cartes gardent la même hauteur, même si un
       intitulé est plus long que les autres. */
    min-height: 2.2em; display: flex; align-items: flex-start;
}
.stat-card .stat-val { font-size: 1.5rem; font-weight: 800; color: var(--navy-900); line-height: 1.15; font-variant-numeric: tabular-nums; }
.stat-card .stat-sub { color: var(--texte-doux); font-size: .78rem; margin-top: 2px; }

.palmares-graph { margin: 8px 0 16px; }
.palmares-graph h4 { margin: 0 0 6px; font-size: .85rem; color: var(--navy-900); }
.palmares-graph .spark, .visits-chart .visits-bars {
    width: 100%; height: auto; background: #fbfcfe; border: 1px solid var(--bordure); border-radius: var(--r-sm);
}
.palmares-graph .spark { max-width: 660px; }
.palmares-graph .spark .grid { stroke: #e4eaf1; stroke-width: 1; }
.palmares-graph .spark .line { fill: none; stroke: var(--bleu-600); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.palmares-graph .spark .pt { fill: var(--navy-900); }
.palmares-graph .spark .ax { fill: var(--texte-doux); font-size: 10px; }
.visits-chart .visits-bars { max-width: 780px; }
.visits-chart .visits-bars rect { fill: var(--bleu-600); }
.visits-chart .visits-bars .ax { fill: var(--texte-doux); font-size: 10px; }

/* =============================================================================
   22. FORMULAIRES (administration)
   ============================================================================= */
.help { color: var(--texte-doux); font-size: .86rem; }
.form-grid { display: grid; grid-template-columns: 1fr; gap: 12px 18px; }
@media (min-width: 700px) { .form-grid { grid-template-columns: repeat(2, 1fr); } }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-weight: 700; margin-bottom: 4px; color: var(--navy-900); font-size: .88rem; }
.field input, .field select, .field textarea {
    width: 100%; min-height: var(--cible-tactile); padding: 8px 10px;
    border: 1px solid var(--bordure-forte); border-radius: var(--r-sm);
    font-size: .93rem; font-family: inherit; color: var(--texte); background: #fff;
}
.field textarea { min-height: 90px; }
.field input[type=checkbox], .field input[type=radio] { width: auto; min-height: auto; }

/* Barre d'outils des listes d'administration (filtres + tri). */
.list-toolbar {
    display: flex; flex-wrap: wrap; gap: 10px; align-items: end;
    background: var(--bleu-050); border: 1px solid var(--bleu-200);
    border-radius: var(--r-sm); padding: 10px 12px; margin-bottom: 14px;
}
.list-toolbar label { display: block; font-size: .76rem; font-weight: 700; color: var(--navy-900); text-transform: uppercase; letter-spacing: .03em; }
.list-toolbar select, .list-toolbar input {
    min-height: 40px; padding: 6px 9px; border: 1px solid var(--bordure-forte);
    border-radius: var(--r-sm); font-family: inherit; font-size: .88rem; background: #fff;
}

/* =============================================================================
   23. NAVIGATION D'ADMINISTRATION
   ============================================================================= */
.admin-nav { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.admin-nav > a, .nav-group-btn {
    display: inline-flex; align-items: center; gap: 4px;
    min-height: 40px; padding: 8px 14px; border-radius: var(--r-sm); text-decoration: none;
    background: #fff; border: 1px solid var(--bordure); color: var(--navy-900);
    font-weight: 700; font-size: .87rem; font-family: inherit; line-height: 1.2; cursor: pointer;
}
.admin-nav > a.active, .admin-nav > a:hover, .nav-group-btn:hover { background: var(--bleu-600); color: #fff; border-color: var(--bleu-600); }
.admin-nav > a.nav-ext { margin-left: auto; border-color: var(--bleu-600); color: var(--bleu-600); }
.admin-nav > a.nav-ext:hover { background: var(--bleu-600); color: #fff; }
/* « Mon compte » : poussé à droite ; collé au bouton Ianseo quand celui-ci existe. */
.admin-nav > a.nav-compte { margin-left: auto; }
.admin-nav > a.nav-ext + a.nav-compte { margin-left: 0; }
.admin-nav > a.nav-compte.active { background: var(--navy-900); color: #fff; border-color: var(--navy-900); }
.nav-group { position: relative; }
.nav-group.active > .nav-group-btn { background: var(--navy-900); color: #fff; border-color: var(--navy-900); }
.nav-group-btn .caret { font-size: .7em; margin-left: 2px; opacity: .85; }
/* Pastille d'alerte : un NOMBRE (pas un signe) — le rouge n'est qu'un renfort,
   l'information reste lisible en noir et blanc et annoncée par un lecteur d'écran. */
.nav-badge {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 20px; height: 20px; margin-left: 6px; padding: 0 6px;
    border-radius: 10px; background: var(--rouge-fonce, #b23b3b); color: #fff;
    font-size: .75rem; font-weight: 700; line-height: 1;
}
.nav-group.active > .nav-group-btn .nav-badge,
.admin-nav > a.active .nav-badge, .nav-group-btn:hover .nav-badge,
.nav-group-menu a.active .nav-badge { background: #fff; color: var(--rouge-fonce, #b23b3b); }
.nav-group-menu {
    display: none; position: absolute; top: calc(100% + 6px); left: 0; z-index: 30;
    min-width: 218px; background: #fff; border: 1px solid var(--bordure); border-radius: var(--r);
    box-shadow: var(--ombre-2); padding: 6px;
}
.nav-group-menu::before { content: ""; position: absolute; left: 0; right: 0; top: -10px; height: 10px; }
.nav-group:hover .nav-group-menu, .nav-group:focus-within .nav-group-menu, .nav-group.open .nav-group-menu { display: block; }
.nav-group-menu a {
    display: block; min-height: 40px; padding: 9px 12px; border-radius: var(--r-sm);
    text-decoration: none; color: var(--navy-900); font-weight: 600; font-size: .86rem; white-space: nowrap;
}
.nav-group-menu a:hover { background: var(--bleu-600); color: #fff; }
.nav-group-menu a.active { background: var(--navy-900); color: #fff; }

/* =============================================================================
   24. UTILITAIRES
   ============================================================================= */
.muted { color: var(--texte-doux); }
.text-center { text-align: center; }
.mt { margin-top: 16px; } .mb { margin-bottom: 16px; }
.barre-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.barre-actions.entre { justify-content: space-between; }
.pousse-droite { margin-left: auto; }
.nowrap { white-space: nowrap; }
.chiffres { font-variant-numeric: tabular-nums; }

/* =============================================================================
   25. IMPRESSION
   ============================================================================= */
@media print {
    .site-header, .filtres-barre, .filters, .actions, .btn, .admin-nav, .onglets, .pagination, .fil-ariane { display: none !important; }
    body { background: #fff; }
    .panel { box-shadow: none; border: 1px solid #ccc; }
    table.grid thead th { background: #eee !important; color: #000 !important; }
}

/* =============================================================================
   26. MODE INTÉGRATION (page publique dans une iframe d'un site tiers)
   ============================================================================= */
body.embed { background: #fff; }
body.embed main { margin: 10px auto; padding: 0 12px 14px; }
body.embed .fil-ariane { display: none; }

/* ---- Pages légales -------------------------------------------------------- */
.page-legale { max-width: 820px; }
.page-legale h2 { margin: 1.6em 0 .5em; font-size: 1.25rem; color: var(--navy-900); }
.page-legale h3 { margin: 1.2em 0 .4em; font-size: 1.05rem; }
.page-legale p, .page-legale li { line-height: 1.6; }
.page-legale .liens-legaux { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 2em;
    padding-top: 1em; border-top: 1px solid var(--bordure); }
/* Information obligatoire non encore saisie par le comité. */
mark.a-completer { background: #fdeceb; color: #a94442; padding: 0 4px; border-radius: 3px; }
