/* Kenstrivadeg V2 : noir et blanc du Gwenn-ha-du.
   La couleur ne sert qu'aux classements et aux disciplines. */

@font-face { font-family: 'Big Shoulders'; src: url('/static/fonts/BigShoulders-latin.woff2') format('woff2'); font-weight: 600 900; font-display: swap; }
@font-face { font-family: 'Archivo'; src: url('/static/fonts/Archivo-latin.woff2') format('woff2'); font-weight: 400 700; font-display: swap; }

:root {
  --noir: #0A0A0A; --blanc: #FFFFFF; --gris: #55554F; --filet: #D9D9D4; --fond: #F0F0EC;
  --bagad: #1238D6; --sur-bagad: #FFFFFF; --batterie: #C6F135; --sur-batterie: #0A0A0A;
  --or: #F5C518; --argent: #C3CCD6; --bronze: #D9925B;
  --titre: 'Big Shoulders', Impact, sans-serif; --texte: 'Archivo', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: var(--blanc); color: var(--noir); font-family: var(--texte); font-size: 16px; line-height: 1.45; font-variant-numeric: tabular-nums; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--bagad); outline-offset: 2px; }
.entete :focus-visible, .fiche-tete :focus-visible, .volet.bagad :focus-visible, .rubriques.bagad :focus-visible { outline-color: var(--blanc); }
.volet.batterie :focus-visible, .rubriques.batterie :focus-visible { outline-color: var(--noir); }
main { flex: 1 0 auto; }
main:focus { outline: 0; }
.evitement { position: absolute; left: 8px; top: -60px; z-index: 5; padding: 10px 14px; background: var(--blanc); color: var(--noir); font-weight: 700; }
.evitement:focus { top: 24px; }
h1, h2, h3, .affiche { font-family: var(--titre); font-weight: 900; line-height: .95; text-transform: uppercase; margin: 0; }
h1 { font-size: clamp(52px, 8vw, 112px); }
h2 { font-size: 36px; }
p { margin: 0; }
.visuel-masque { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.discret { color: var(--gris); }
/* Un même contenu peut avoir deux mises en forme : le tableau complet sur ordinateur, une liste sur téléphone. */
@media (min-width: 641px) { .mobile-seul { display: none !important; } }
@media (max-width: 640px) { .bureau-seul { display: none !important; } }

.rayures { height: 18px; background: repeating-linear-gradient(to bottom, var(--noir) 0 2px, var(--blanc) 2px 4px); }

/* En-tête */
.entete { background: var(--noir); color: var(--blanc); }
.entete-ligne { padding: 10px 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; }
.marque { display: flex; align-items: center; gap: 10px; font-family: var(--titre); font-weight: 900; font-size: 34px; line-height: 1; text-transform: uppercase; text-decoration: none; }
.marque svg { display: block; flex: none; }
.disciplines { display: flex; }
.disciplines a { min-height: 44px; padding: 0 16px; display: flex; align-items: center; text-decoration: none; font-family: var(--titre); font-weight: 800; font-size: 22px; text-transform: uppercase; }
.disciplines a[aria-current="true"].bagad { background: var(--bagad); color: var(--sur-bagad); }
.disciplines a[aria-current="true"].batterie { background: var(--batterie); color: var(--sur-batterie); }
.recherche { position: relative; flex: 1 1 220px; display: flex; }
.recherche input { width: 100%; min-height: 44px; padding: 0 14px; border: 2px solid var(--blanc); border-radius: 0; background: transparent; color: var(--blanc); font: 400 15px var(--texte); }
.recherche input::placeholder { color: #D9D9D4; opacity: 1; }
/* Propositions pendant la saisie, voir static/js/recherche.js */
@media (hover: hover) and (min-width: 641px) { .recherche:has(.recherche-raccourci) input:placeholder-shown:not(:focus) { padding-right: 72px; } }
.recherche-raccourci { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); padding: 1px 6px; border: 1px solid #D9D9D4; color: #D9D9D4; font: 600 12px var(--texte); pointer-events: none; }
.recherche input:focus ~ .recherche-raccourci, .recherche input:not(:placeholder-shown) ~ .recherche-raccourci { display: none; }
.propositions { position: absolute; z-index: 20; top: calc(100% + 4px); left: 0; right: 0; max-height: min(70vh, 560px); overflow-y: auto; overscroll-behavior: contain; background: var(--blanc); color: var(--noir); border: 3px solid var(--noir); box-shadow: 0 16px 40px rgb(10 10 10 / .35); }
.propositions-titre { padding: 12px 14px 4px; font-family: var(--titre); font-weight: 800; font-size: 18px; line-height: 1; text-transform: uppercase; color: var(--gris); }
.proposition { min-height: 44px; padding: 6px 14px; display: flex; justify-content: space-between; align-items: center; gap: 14px; text-decoration: none; cursor: pointer; }
.proposition b { font-weight: 600; overflow-wrap: anywhere; }
.proposition span { max-width: 55%; text-align: right; font-size: 14px; color: var(--gris); }
.proposition[aria-selected="true"] { background: var(--fond); box-shadow: inset 4px 0 0 var(--noir); }
.propositions-tout { margin-top: 6px; border-top: 1px solid var(--filet); }
.propositions-tout b { text-decoration: underline; }
.propositions-vide { padding: 14px; color: var(--gris); }
.propositions-aide { padding: 8px 14px; display: flex; flex-wrap: wrap; gap: 4px 16px; border-top: 1px solid var(--filet); font-size: 13px; color: var(--gris); }
.propositions kbd { display: inline-block; min-width: 1.7em; padding: 0 4px; border: 1px solid var(--filet); font: 600 12px var(--texte); text-align: center; }
@media (hover: none) { .recherche-raccourci, .propositions-aide { display: none; } }
.entete-lien { min-height: 44px; display: flex; align-items: center; font-size: 15px; font-weight: 600; }
.loupe { display: none; }
/* Champ de l'accueil sur téléphone, sous le titre */
.recherche-heros { margin-top: 18px; }
.recherche-heros input { min-height: 52px; border-right: 0; }
.recherche-envoi { width: 52px; flex: none; display: flex; align-items: center; justify-content: center; padding: 0; border: 0; background: var(--blanc); color: var(--noir); cursor: pointer; }
.heros :focus-visible { outline-color: var(--blanc); }
.rubriques { padding: 0 24px; display: flex; flex-wrap: wrap; gap: 0 24px; }
.rubriques.bagad { background: var(--bagad); color: var(--sur-bagad); }
.rubriques.batterie { background: var(--batterie); color: var(--sur-batterie); }
.rubriques a { min-height: 44px; display: flex; align-items: center; text-decoration: none; font-family: var(--titre); font-weight: 600; font-size: 20px; text-transform: uppercase; border-bottom: 4px solid transparent; }
.rubriques a[aria-current="page"] { font-weight: 900; border-bottom-color: currentColor; }
/* Sur téléphone (partiels/entete.html) : le logo, puis « Contribuer » sur l'accueil, la loupe ailleurs ;
   le champ dessous quand la loupe l'a déplié, puis les deux disciplines en onglets pleine largeur. */
@media (max-width: 640px) {
  .rayures { height: 10px; }
  .entete-ligne { padding: 6px 16px 0; gap: 0 12px; }
  .marque { flex: 1; min-height: 44px; font-size: 28px; }
  .marque svg { width: 17px; height: 26px; }
  .entete-lien { order: 2; }
  .entete:not(.entete-accueil) .entete-lien { display: none; }
  .loupe { order: 3; width: 44px; height: 44px; flex: none; display: flex; align-items: center; justify-content: center; border: 2px solid var(--blanc); color: var(--blanc); }
  .entete.cherche .loupe { background: var(--blanc); color: var(--noir); }
  .entete-ligne .recherche { order: 4; flex: 1 0 100%; display: none; margin: 6px 0 2px; }
  .recherche input { font-size: 16px; }
  .entete.cherche .recherche, .recherche:has(:target) { display: flex; }
  .recherche-raccourci { display: none; }
  .disciplines { order: 5; flex: 1 0 100%; margin: 8px -16px 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .disciplines a { justify-content: center; }
  .disciplines.sans-discipline .bagad { background: var(--bagad); color: var(--sur-bagad); }
  .disciplines.sans-discipline .batterie { background: var(--batterie); color: var(--sur-batterie); }
  .rubriques { padding: 0 16px; flex-wrap: nowrap; justify-content: space-between; gap: 0 16px; overflow-x: auto; scrollbar-width: none; white-space: nowrap; }
  .rubriques a { flex: none; font-size: 19px; }
}

/* Page */
.contenu { padding: 24px; display: flex; flex-direction: column; gap: 18px; }
.tete { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px 32px; }
.tete p { margin-top: 8px; font-size: 17px; }
.filtres { display: flex; flex-wrap: wrap; align-items: stretch; gap: 8px 12px; }
.bascule { display: flex; flex-wrap: wrap; border: 3px solid var(--noir); }
.bascule a { min-height: 46px; min-width: 64px; padding: 0 14px; display: flex; align-items: center; justify-content: center; text-decoration: none; font-family: var(--titre); font-weight: 800; font-size: 22px; text-transform: uppercase; background: var(--blanc); color: var(--noir); }
.bascule a[aria-current] { background: var(--noir); color: var(--blanc); }
.bascule.grande a { min-height: 52px; min-width: 124px; font-size: 24px; }
.choix { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; }
.choix select { min-height: 52px; padding: 0 10px; border: 3px solid var(--noir); border-radius: 0; background: var(--blanc); color: var(--noir); font: 700 16px var(--texte); }

/* Légende et niveaux */
.legende { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; font-size: 14px; }
.legende span { display: flex; align-items: center; gap: 6px; }
.legende i { width: 20px; height: 20px; display: block; }
.n1 { background: var(--or); color: var(--noir); font-weight: 700; }
.n2 { background: var(--argent); color: var(--noir); font-weight: 700; }
.n3 { background: var(--bronze); color: var(--noir); font-weight: 700; }
.dernier { background: var(--noir); color: var(--blanc); font-weight: 700; }

/* Tableaux */
.cadre { position: relative; border: 3px solid var(--noir); overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
caption { padding: 10px 14px; text-align: left; font-family: var(--titre); font-weight: 900; font-size: 30px; text-transform: uppercase; }
.caption-lien { float: right; margin-top: 8px; font: 600 15px var(--texte); text-transform: none; }
thead th { background: var(--noir); color: var(--blanc); padding: 8px; text-align: left; font-family: var(--titre); font-weight: 800; font-size: 20px; text-transform: uppercase; }
tbody tr { border-bottom: 1px solid var(--noir); }
tbody td { height: 50px; padding: 0 10px; }
td.fort { font-family: var(--titre); font-weight: 900; font-size: 26px; }
td.droite, th.droite { text-align: right; }
td a, th a { text-decoration: none; }
td a:hover, th a:hover { text-decoration: underline; }
td small { font-size: 14px; font-weight: 400; }
.fixe-nom small { display: block; font-size: 13px; line-height: 1.1; }

.resultats { font-size: 14.5px; }
.resultats thead th { text-align: center; }
.resultats th.groupe { border-left: 2px solid var(--blanc); }
.resultats .juges th { background: var(--fond); color: var(--noir); padding: 6px 2px; font: 600 12.5px/1.15 var(--texte); text-transform: none; border-left: 1px solid var(--filet); }
.resultats .juges { border-bottom: 2px solid var(--noir); }
.resultats .juges th.debut { border-left: 2px solid var(--noir); }
.resultats td.valeur { height: 46px; padding: 0 4px; text-align: center; border-left: 1px solid var(--filet); }
.resultats td.valeur.debut, .resultats td.separe { border-left: 2px solid var(--noir); }
.resultats td.separe { padding: 0 8px; text-align: center; }
.fixe-rang { position: sticky; left: 0; z-index: 1; width: 52px; min-width: 52px; padding: 0; text-align: center; background: var(--blanc); font-family: var(--titre); font-weight: 900; font-size: 26px; }
.fixe-nom { position: sticky; left: 52px; z-index: 1; min-width: 232px; background: var(--blanc); white-space: nowrap; font-weight: 600; }
thead .fixe-rang, thead .fixe-nom { z-index: 2; background: var(--noir); font-size: 20px; }
thead .fixe-nom { text-align: left; }
tr.p1 .fixe-rang, tr.p1 .fixe-nom, .rang.n1 { background: var(--or); color: var(--noir); }
tr.p2 .fixe-rang, tr.p2 .fixe-nom, .rang.n2 { background: var(--argent); color: var(--noir); }
tr.p3 .fixe-rang, tr.p3 .fixe-nom, .rang.n3 { background: var(--bronze); color: var(--noir); }
tr.dernier .fixe-rang, tr.dernier .fixe-nom, .rang.dernier { background: var(--noir); color: var(--blanc); }
.rang { width: 60px; padding: 0; text-align: center; font-family: var(--titre); font-weight: 900; font-size: 30px; }
.jauge { display: flex; align-items: center; gap: 10px; }
.jauge i { flex: 1; height: 10px; background: var(--fond); display: block; }
.jauge b { display: block; height: 10px; background: var(--bagad); }
.cumul-detail { display: none; }

/* Une colonne à la fois : le tableau d'une épreuve sur téléphone (partiels/une_colonne.html) */
.une-colonne { display: flex; flex-direction: column; gap: 8px; scroll-margin-top: 12px; }
.uc-etiquette { margin-top: 4px; font-size: 13px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--gris); }
.puces { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
.puce { min-height: 46px; padding: 0 4px; display: flex; align-items: center; justify-content: center; text-align: center; border: 3px solid var(--noir); background: var(--blanc); color: var(--noir); text-decoration: none; font-family: var(--titre); font-weight: 800; font-size: 19px; line-height: 1; text-transform: uppercase; }
.puce[aria-current] { background: var(--noir); color: var(--blanc); }
.sous-puce { min-height: 44px; border-width: 2px; font: 600 15px/1.15 var(--texte); text-transform: none; overflow-wrap: anywhere; }
.sous-puce[aria-current] { background: var(--bagad); border-color: var(--bagad); color: var(--sur-bagad); }
.batterie-page .sous-puce[aria-current] { background: var(--batterie); border-color: var(--noir); color: var(--sur-batterie); }
.uc-tete { margin-top: 6px; display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }
.uc-tete p { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.uc-titre { font-family: var(--titre); font-weight: 900; font-size: 32px; line-height: 1; text-transform: uppercase; }
.uc-tete p > span:last-child { font-size: 14px; line-height: 1.35; color: var(--gris); }
.tri { flex: none; min-height: 44px; padding: 0 12px; display: flex; align-items: center; gap: 6px; border: 2px solid var(--noir); text-decoration: none; font-size: 14px; font-weight: 600; }
.tri[aria-current] { background: var(--noir); color: var(--blanc); }
.uc-table { table-layout: fixed; }
.uc-table thead th { padding: 8px 10px; font-size: 18px; }
.uc-table thead th.uc-rang { width: 40px; padding: 8px 0; font-size: 18px; text-align: center; }
.uc-table thead th.uc-valeur { width: 144px; text-align: right; }
.uc-table tbody td { height: 57px; padding: 0; }
td.uc-rang { text-align: center; font-family: var(--titre); font-weight: 900; font-size: 24px; }
.uc-table td.uc-nom { padding: 7px 8px 7px 10px; }
.uc-nom a { display: block; font-size: 15px; font-weight: 700; line-height: 1.2; }
.uc-nom small { display: block; font-size: 12.5px; line-height: 1.3; color: var(--gris); }
.uc-valeur > div { min-height: 57px; display: flex; align-items: stretch; gap: 8px; padding-left: 4px; }
.uc-jauge { flex: 1; align-self: center; height: 10px; display: block; background: var(--fond); }
.uc-jauge b { display: block; height: 10px; background: var(--bagad); }
.uc-chiffre { width: 66px; margin-left: auto; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.uc-chiffre.neutre { background: var(--fond); }
.uc-chiffre b { font-size: 17px; line-height: 1.15; }
.uc-chiffre small { font-size: 12px; font-weight: 600; }

/* Classement d'une saison sur téléphone : la moyenne à droite, chaque concours dessous */
.classement-liste { margin: 0; padding: 0; list-style: none; border: 3px solid var(--noir); }
.classement-liste li { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; border-bottom: 1px solid var(--noir); }
.classement-liste li:last-child { border-bottom: 0; }
.classement-liste .rang { grid-row: 1 / 3; width: auto; display: flex; align-items: center; justify-content: center; }
.cl-nom { min-width: 0; padding: 10px 8px 0 12px; display: flex; flex-direction: column; text-decoration: none; }
.cl-nom b { font-size: 16px; line-height: 1.2; }
.cl-nom small, .cl-moyenne small { font-size: 13px; line-height: 1.3; color: var(--gris); }
.cl-moyenne { padding: 8px 12px 0 0; display: flex; flex-direction: column; align-items: flex-end; }
.cl-moyenne b { font-family: var(--titre); font-weight: 900; font-size: 32px; line-height: 1; }
.cl-concours { grid-column: 2 / 4; padding: 8px 12px 10px; display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 3px; }
.cl-concours > * { min-height: 44px; padding: 5px 8px; display: flex; justify-content: space-between; align-items: flex-end; gap: 6px; text-decoration: none; }
.cl-concours .neutre { background: var(--fond); }
.cl-concours > * > span { min-width: 0; display: flex; flex-direction: column; }
.cl-concours small { font-size: 11.5px; line-height: 1.2; }
.cl-concours > * > small { font-size: 13px; font-weight: 600; }
.cl-concours b { font-size: 15px; line-height: 1.25; }
.cl-concours .absent, .cl-concours .a-venir { background: var(--blanc); border: 1px dashed var(--filet); color: var(--gris); }

/* Cartes et tuiles */
.grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(560px, 100%), 1fr)); gap: 12px; align-items: start; }
.carte-titre { padding: 8px 14px; background: var(--noir); color: var(--blanc); display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 2px 16px; }
.carte-titre h2 { font-size: 32px; }
.carte-titre span { font-size: 14.5px; }
.chiffres { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 4px; }
.chiffres div { padding: 10px 16px; border: 3px solid var(--noir); display: flex; flex-direction: column; }
.chiffres b { font-family: var(--titre); font-weight: 900; font-size: 64px; line-height: 1; }
.chiffres .inverse { background: var(--noir); color: var(--blanc); }
.courbe { display: block; color: var(--bagad); }
.batterie-page .courbe { color: var(--noir); }
.histogramme { padding: 14px 16px; height: 220px; display: flex; align-items: flex-end; gap: 4px; }
.histogramme div { flex: 1 1 0; min-width: 0; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; text-align: center; }
.histogramme b { font-family: var(--titre); font-weight: 900; font-size: 24px; }
.histogramme i { display: block; background: var(--bagad); }
.batterie-page .histogramme i { background: var(--noir); }
.histogramme span { font-size: 13px; }
.resume { margin: 0; padding: 12px 14px; font-size: 17px; line-height: 1.45; }
.chapeau { margin: 0; max-width: 72ch; font-size: 18px; line-height: 1.45; }
.vide { padding: 28px 24px; background: var(--fond); display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.bouton { min-height: 52px; padding: 0 20px; display: inline-flex; align-items: center; background: var(--noir); color: var(--blanc); text-decoration: none; font-weight: 700; border: 0; }
.lien-liste { min-height: 56px; padding: 8px 14px; display: flex; justify-content: space-between; align-items: center; gap: 14px; border-bottom: 1px solid var(--noir); text-decoration: none; }
.lien-liste:hover { background: var(--fond); }
.lien-liste b { font-size: 17px; }
.colonnes { column-width: 300px; column-gap: 12px; }
.colonnes a { break-inside: avoid; }

/* Accueil */
.heros { background: var(--noir); color: var(--blanc); padding: 24px 24px 32px; }
.heros h1 { font-size: clamp(48px, 13vw, 132px); line-height: .9; }
.volets { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(480px, 100%), 1fr)); }
.volet { padding: 28px 24px; display: flex; flex-direction: column; gap: 20px; }
.volet.bagad { background: var(--bagad); color: var(--sur-bagad); }
.volet.batterie { background: var(--batterie); color: var(--sur-batterie); }
.volet-tete { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 24px; font-weight: 600; }
.volet h2 { font-size: 56px; line-height: 1; }
.volet .score { font-family: var(--titre); font-weight: 900; font-size: clamp(100px, 13vw, 180px); line-height: 1; display: block; }
.volet .vainqueur { font-family: var(--titre); font-weight: 800; font-size: 36px; text-transform: uppercase; }
.volet > a { text-decoration: none; }
.volet > a:last-child { min-height: 44px; display: flex; align-items: center; }
.podium { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 2px; }
.podium li { background: var(--blanc); color: var(--noir); }
.podium a { min-height: 52px; display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; align-items: center; gap: 14px; padding-right: 14px; text-decoration: none; font-size: 17px; font-weight: 600; }
.podium .rang { align-self: stretch; width: auto; display: flex; align-items: center; justify-content: center; font-size: 28px; }
.bandeau-chiffres { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); border-bottom: 4px solid var(--noir); }
.bandeau-chiffres div { padding: 20px 24px; border-right: 2px solid var(--noir); display: flex; flex-direction: column; }
.bandeau-chiffres b { font-family: var(--titre); font-weight: 900; font-size: 64px; line-height: 1; }

/* Fiches */
.fiche-tete { background: var(--noir); color: var(--blanc); padding: 24px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px 40px; }
.fiche-tete h1 { font-size: clamp(64px, 10vw, 148px); line-height: .88; }
.faits { margin: 0; display: flex; flex-wrap: wrap; gap: 8px 40px; }
.faits div { display: flex; flex-direction: column-reverse; }
.faits dd { margin: 0; font-family: var(--titre); font-weight: 900; font-size: 64px; line-height: 1; }
.faits dt { font-size: 15px; }
.parcours, .parcours ol { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; }
.parcours { gap: 18px 14px; }
.parcours ol { gap: 4px; flex-wrap: nowrap; }
.parcours-saison { margin: 0 0 6px; padding-top: 6px; border-top: 3px solid var(--noir); display: flex; flex-direction: column; font-size: 13.5px; line-height: 1.2; }
.parcours-saison b { font-family: var(--titre); font-weight: 900; font-size: 22px; line-height: 1; }
.parcours-saison span { display: flex; align-items: center; gap: 6px; min-height: 20px; }
.parcours ol li { width: 72px; display: flex; flex-direction: column; font-size: 13.5px; line-height: 1.2; }
.parcours ol span { height: 84px; margin-bottom: 6px; display: flex; align-items: center; justify-content: center; border: 2px solid var(--noir); font-family: var(--titre); font-weight: 900; font-size: 44px; }
i.mouvement { width: 18px; height: 18px; flex: none; display: inline-flex; align-items: center; justify-content: center; color: var(--blanc); }
i.mouvement.monte { background: var(--bagad); }
i.mouvement.descend { background: var(--noir); }
i.mouvement.descend svg { transform: rotate(180deg); }
.deux { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.deux > :first-child { flex: 999 1 560px; min-width: 0; }
.deux > :last-child { flex: 1 1 320px; min-width: 0; }
.encart { padding: 16px; background: var(--batterie); color: var(--sur-batterie); display: flex; flex-direction: column; gap: 6px; }
.encart h2 { margin-bottom: 0; }
.encart p { margin: 0 0 6px; font-size: 14px; }
.encart a { min-height: 52px; padding: 8px 14px; display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--blanc); color: var(--noir); text-decoration: none; }
.encart a span { display: flex; flex-direction: column; gap: 2px; }
.encart a small { font-size: 13px; color: var(--gris); }
.encart a > b { white-space: nowrap; }
.barres { display: flex; flex-direction: column; gap: 8px; padding: 14px; border: 3px solid var(--noir); }
.barres div { display: grid; grid-template-columns: 110px minmax(0, 1fr) 56px; gap: 10px; align-items: center; }
.barres i { height: 12px; background: var(--fond); display: block; }
.barres i b { display: block; height: 12px; background: var(--bagad); }
/* Épreuves d'un bagad groupées par saison, sur téléphone */
.saisons-liste { display: flex; flex-direction: column; gap: 12px; }
.saison-titre { margin: 0; padding: 6px 12px; display: flex; justify-content: space-between; align-items: baseline; gap: 12px; background: var(--noir); color: var(--blanc); font-size: 22px; }
.saison-titre small { font: 600 13px var(--texte); text-transform: none; }
.saison-epreuve { min-height: 56px; display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; border-top: 1px solid var(--noir); text-decoration: none; }
.saison-titre + .saison-epreuve { border-top: 0; }
.saison-epreuve .rang { width: auto; display: flex; align-items: center; justify-content: center; font-size: 26px; }
.saison-epreuve > span:nth-child(2) { padding: 6px 10px 6px 12px; display: flex; flex-direction: column; justify-content: center; }
.saison-epreuve > span:nth-child(2) b { font-size: 16px; line-height: 1.2; }
.saison-epreuve small { font-size: 13px; color: var(--gris); }
.saison-epreuve > b { padding: 0 12px; display: flex; align-items: center; font-family: var(--titre); font-weight: 900; font-size: 26px; }
/* La suite d'une liste longue, repliée */
details.plus > summary { list-style: none; cursor: pointer; }
details.plus > summary::-webkit-details-marker { display: none; }
details.plus[open] > summary { margin-bottom: 12px; }
.saisons-liste summary.bouton { width: 100%; justify-content: center; text-align: center; }
.encart details.plus > summary { min-height: 44px; display: flex; align-items: center; font-weight: 700; text-decoration: underline; }
.encart details.plus[open] > summary { margin-bottom: 0; }
.encart details.plus > a { margin-top: 6px; }

/* Texte courant */
.lecture { max-width: 760px; display: flex; flex-direction: column; gap: 14px; font-size: 16px; }
.lecture h2 { margin-top: 12px; font-size: 30px; }

/* Pied */
.signature { padding: 28px 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px; background: var(--noir); color: var(--blanc); }
.signature > div { flex: 1 1 320px; max-width: 760px; }
.signature .affiche { margin-bottom: 8px; font-size: clamp(28px, 4vw, 40px); }
.signature .affiche img { height: .74em; width: auto; }
.signature .bouton { background: var(--blanc); color: var(--noir); }
.signature :focus-visible { outline-color: var(--blanc); }
.pied { padding: 20px 24px; display: flex; flex-wrap: wrap; gap: 8px 24px; border-top: 4px solid var(--noir); font-size: 15px; }
.pied a:last-child { margin-left: auto; }
.lien-pied { padding: 0; border: 0; background: none; color: inherit; font: inherit; text-decoration: underline; cursor: pointer; }

@media (max-width: 640px) {
  .contenu, .heros, .volet, .fiche-tete, .signature { padding-left: 16px; padding-right: 16px; }
  .contenu { padding-top: 20px; gap: 14px; }
  .tete p { font-size: 16px; }
  .chapeau { font-size: 17px; }
  .bascule, .filtres { width: 100%; }
  .bascule a, .bascule.grande a { flex: 1 1 auto; min-width: 0; padding: 0 8px; }
  .fixe-rang { width: 36px; min-width: 36px; font-size: 22px; }
  .fixe-nom { left: 36px; min-width: 120px; max-width: 150px; white-space: normal; font-size: 13.5px; line-height: 1.15; }
  /* Épreuve batterie : sans la place par répertoire, que le cumul détaille, trois juges tiennent */
  .resultats .repertoire { display: none; }
  .cumul-detail { display: block; font: 400 11.5px/1.2 var(--texte); color: var(--gris); }
  .resultats thead th { padding: 6px 3px; font-size: 15px; }
  .resultats .juges th { padding: 5px 2px; font: 700 12px/1.1 var(--titre); text-transform: uppercase; }
  .resultats td.valeur { padding: 0 2px; }
  .resultats td.separe { padding: 0 4px; }
  .batterie-page .resultats .fixe-nom { min-width: 0; max-width: none; }
  /* Accueil */
  .volet { padding-top: 24px; padding-bottom: 24px; gap: 16px; }
  .volet h2 { font-size: 44px; }
  .volet .score { font-size: 96px; line-height: .9; }
  .volet .vainqueur { font-size: 30px; }
  .bandeau-chiffres { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bandeau-chiffres div { padding: 16px; }
  .bandeau-chiffres div:nth-child(2n) { border-right: 0; }
  .bandeau-chiffres div:nth-child(-n + 2) { border-bottom: 2px solid var(--noir); }
  .bandeau-chiffres b { font-size: 52px; }
  /* Fiches : chiffres clés sur une ligne, parcours qui défile */
  .fiche-tete { padding-top: 20px; gap: 20px; }
  .fiche-tete h1 { font-size: 64px; }
  .faits { width: 100%; display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 12px; }
  .faits dd { font-size: 44px; }
  .faits dt { font-size: 13.5px; line-height: 1.3; }
  .parcours { margin: 0 -16px; padding: 0 16px 4px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .parcours > li { flex: none; }
  .parcours ol li { width: 58px; font-size: 12.5px; }
  .parcours ol span { height: 62px; font-size: 36px; }
}

/* Administration */
.admin-nav { flex: 1 1 320px; display: flex; flex-wrap: wrap; gap: 0 2px; }
.admin-nav a { min-height: 44px; padding: 0 12px; display: flex; align-items: center; text-decoration: none; font-size: 15px; font-weight: 600; }
.admin-nav a[aria-current] { background: var(--blanc); color: var(--noir); }
.tuiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 4px; }
.tuile { padding: 12px 16px; border: 3px solid var(--noir); display: flex; flex-direction: column; text-decoration: none; }
.tuile b { font-family: var(--titre); font-weight: 900; font-size: 64px; line-height: 1; }
.tuile[aria-current] { background: var(--noir); color: var(--blanc); }
.tache { min-height: 60px; padding: 8px 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; border-bottom: 1px solid var(--noir); text-decoration: none; }
.tache:last-child { border-bottom: 0; }
.tache:hover { background: var(--fond); }
.pastille { width: 92px; padding: 2px 8px; text-align: center; font-family: var(--titre); font-weight: 800; font-size: 18px; text-transform: uppercase; }
.pastille.bagad, .titre-bagad { background: var(--bagad); color: var(--sur-bagad); }
.pastille.batterie, .titre-batterie { background: var(--batterie); color: var(--sur-batterie); }
.tache-texte { flex: 1 1 240px; display: flex; flex-direction: column; }
.tache-action { font-weight: 700; text-decoration: underline; }
.couverture { min-width: 620px; }
.couverture tbody td { height: 64px; padding: 6px 10px; }
.statut { min-height: 44px; padding: 0 8px; display: flex; align-items: center; justify-content: center; text-align: center; font-size: 14.5px; font-weight: 600; }
.statut.publie { background: var(--fond); }
.statut.manquant { background: var(--noir); color: var(--blanc); }
.statut.a_venir { border: 1px solid var(--filet); color: var(--gris); }
.statut.sans_objet { color: var(--gris); font-weight: 400; }

/* Parcours d'import */
.bandeau { padding: 14px 24px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px 32px; }
.bandeau.bagad { background: var(--bagad); color: var(--sur-bagad); }
.bandeau.batterie { background: var(--batterie); color: var(--sur-batterie); }
.bandeau > div { display: flex; flex-direction: column; }
.bandeau-discipline { font-family: var(--titre); font-weight: 800; font-size: 22px; text-transform: uppercase; }
.bandeau-titre { font-family: var(--titre); font-weight: 900; font-size: clamp(34px, 5vw, 52px); line-height: .95; text-transform: uppercase; }
.etapes { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 4px; }
.etapes li { min-height: 48px; padding: 0 14px; display: flex; align-items: center; border: 2px solid currentColor; font-family: var(--titre); font-weight: 800; font-size: 22px; text-transform: uppercase; }
.bandeau.bagad .etapes li[aria-current] { background: var(--blanc); color: var(--noir); border-color: var(--blanc); }
.bandeau.batterie .etapes li[aria-current] { background: var(--noir); color: var(--blanc); border-color: var(--noir); }
.onglets { padding: 0 24px; display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 4px solid var(--noir); }
.onglet { min-height: 48px; margin-bottom: -4px; padding: 0 16px; display: flex; align-items: center; gap: 8px; border: 2px solid var(--noir); border-bottom: 4px solid var(--noir); background: var(--blanc); color: var(--noir); font: 800 21px var(--titre); text-transform: uppercase; text-decoration: none; cursor: pointer; }
.onglet[aria-current] { background: var(--noir); color: var(--blanc); }
.onglet small { font: 400 13px var(--texte); text-transform: none; }
.onglet small.a-faire { font-weight: 700; }
.onglet.ajout { border-style: dashed; }
.aide { margin: 0; color: var(--gris); font-size: 14px; }
.onglet[aria-current] .aide, .onglet[aria-current] small { color: inherit; }
.rappel-epreuve { margin: 0; font-size: 18px; }
.nouvel-import { min-height: 44px; padding: 0 16px; display: flex; align-items: center; background: var(--blanc); color: var(--noir); text-decoration: none; font-family: var(--titre); font-weight: 800; font-size: 21px; text-transform: uppercase; }
.choix-discipline { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 4px; }
.choix-discipline a { padding: 14px 18px; border: 3px solid var(--noir); display: flex; flex-direction: column; text-decoration: none; }
.choix-discipline b { font-family: var(--titre); font-weight: 900; font-size: 36px; line-height: 1; text-transform: uppercase; }
.choix-discipline a.bagad[aria-current] { background: var(--bagad); color: var(--sur-bagad); }
.choix-discipline a.batterie[aria-current] { background: var(--batterie); color: var(--sur-batterie); }
.formulaire, .pile { display: flex; flex-direction: column; gap: 14px; }
.colonnes-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr)); gap: 14px; align-items: start; }
fieldset { margin: 0; padding: 12px 16px 16px; border: 3px solid var(--noir); display: flex; flex-direction: column; gap: 10px; min-width: 0; }
legend { padding: 0 8px; font-family: var(--titre); font-weight: 800; font-size: 24px; text-transform: uppercase; }
label { display: flex; flex-direction: column; gap: 4px; font-weight: 600; font-size: 15px; }
input[type=text], input[type=email], input[type=date], input:not([type]), select, textarea { min-height: 44px; padding: 0 10px; border: 2px solid var(--noir); border-radius: 0; background: var(--blanc); color: var(--noir); font: 400 16px var(--texte); width: 100%; }
textarea { padding: 8px 10px; }
input[type=file] { min-height: 44px; font: 400 15px var(--texte); }
.option { flex-direction: row; align-items: center; gap: 10px; min-height: 44px; font-weight: 400; }
.option input { width: 20px; height: 20px; flex: none; }
.option span { display: flex; flex-direction: column; }
.cases { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.bouton { cursor: pointer; font-family: var(--texte); font-size: 16px; }
.bouton:disabled { background: var(--fond); color: var(--gris); cursor: not-allowed; }
.bouton.secondaire { background: var(--blanc); color: var(--noir); border: 3px solid var(--noir); }
.lien-bouton { min-height: 44px; padding: 0 6px; border: 0; background: none; color: inherit; font: 400 15px var(--texte); text-decoration: underline; cursor: pointer; }
.erreur { padding: 12px 16px; background: var(--noir); color: var(--blanc); font-weight: 600; }
.verif { padding: 24px; display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; }
.verif-corps { min-width: 0; display: flex; flex-direction: column; gap: 14px; align-items: stretch; }
.verif-corps > .bouton { align-self: flex-start; }
.panneau { position: sticky; top: 12px; max-height: calc(100vh - 24px); overflow-y: auto; padding: 16px; border: 3px solid var(--noir); display: flex; flex-direction: column; gap: 10px; }
.panneau h2 { font-size: 32px; }
.panneau form { display: flex; flex-direction: column; gap: 10px; }
.panneau .bouton { justify-content: center; }
.point { padding: 10px 12px; background: var(--fond); display: flex; flex-direction: column; gap: 6px; }
.point.reussi { background: var(--batterie); color: var(--sur-batterie); }
.point.note-relecteur { background: var(--or); color: var(--noir); }
.point.note-relecteur b { display: block; }
.point-actions { display: flex; flex-wrap: wrap; gap: 4px; }
.point .bouton { min-height: 44px; padding: 0 12px; flex: 1 1 auto; font-size: 15px; }
.document { margin: 0; border: 3px solid var(--noir); max-height: 520px; overflow: auto; background: var(--fond); }
.document img { display: block; width: 100%; height: auto; }
.document object { display: block; width: 100%; height: 520px; }
.epreuve-ligne { flex-direction: row; flex-wrap: wrap; gap: 10px; }
.epreuve-ligne label { flex: 1 1 180px; }
table.saisie td { height: 50px; padding: 2px 4px; }
table.saisie th { padding: 6px 4px; font-size: 18px; }
table.saisie input, table.saisie select { min-height: 42px; padding: 0 6px; border-width: 1px; font-size: 15px; min-width: 96px; }
table.saisie input.court { width: 74px; min-width: 64px; text-align: center; }
tr.a-resoudre td { background: var(--or); }
.notes summary { min-height: 44px; display: flex; align-items: center; font-weight: 700; cursor: pointer; }
.grille-notes th { font-size: 14px; font-family: var(--texte); text-transform: none; }
.statut.recu, .statut.analyse { border: 2px dashed var(--noir); }
.statut.a_verifier { border: 3px solid var(--noir); }
.statut.a_corriger, .statut.rejete { background: var(--noir); color: var(--blanc); }
.statut.en_relecture { background: var(--or); color: var(--noir); }
@media (max-width: 960px) {
  .verif { grid-template-columns: minmax(0, 1fr); padding: 16px; }
  .panneau { position: static; max-height: none; }
  .document, .document object { max-height: 360px; height: 360px; }
}

/* Écrans de gestion et Contribuer */
.piege { position: absolute; left: -9999px; }
.choix-discipline a.contribution[aria-current] { background: var(--noir); color: var(--blanc); }
.choix-discipline a.contribution b { font-size: 30px; }
.maitre { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 14px; align-items: start; }
.tache[aria-current] { background: var(--fond); }
.detail { padding: 16px; gap: 12px; }
blockquote { margin: 0; padding-left: 12px; border-left: 4px solid var(--noir); font-size: 17px; }
.droits { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; }
.droits select { width: auto; min-width: 150px; }
.epreuve-ligne.cadre { padding: 12px 14px; align-items: flex-end; }
@media (max-width: 760px) { .maitre { grid-template-columns: minmax(0, 1fr); } }

/* Panneau de consentement */
.consentement { position: fixed; right: 16px; bottom: 16px; z-index: 10; width: min(440px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; background: var(--blanc); color: var(--noir); border: 4px solid var(--noir); }
.consentement[hidden] { display: none; }
.consentement .consentement-titre { font-size: 28px; }
.consentement p { margin: 0; font-size: 15px; }
.consentement-choix { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.consentement-choix .bouton { justify-content: center; }

/* Le bouton à bande. Tout bouton plein, et tout segment, puce ou onglet choisi, porte une
   bande de la couleur de son texte, à 4 px de son bord gauche : elle reprend les bandes du
   Gwenn-ha-du. Elle s'élargit au survol d'un bouton, et apparaît au survol d'un choix libre.
   Ni les boutons à contour, ni les boutons désactivés, ni les icônes seules, ni les liens.
   Placée en fin de fichier : un `background` plus haut l'effacerait. */
.bouton:not(.secondaire):not(:disabled), .nouvel-import,
.bascule a[aria-current], .puce[aria-current], .tri[aria-current],
.onglet[aria-current], .tuile[aria-current], .choix-discipline a[aria-current] {
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-origin: border-box;
  background-position: 4px 0;
  background-size: 4px 100%;
}
.bouton:not(.secondaire):not(:disabled), .nouvel-import { padding-left: 24px; transition: background-size .12s; }
@media (hover: hover) {
  .bouton:not(.secondaire):not(:disabled):hover, .nouvel-import:hover { background-size: 8px 100%; }
  .bascule a:not([aria-current]):hover, .puce:not([aria-current]):hover, .tri:not([aria-current]):hover,
  .onglet:not([aria-current]):hover, .tuile:not([aria-current]):hover {
    background-image: linear-gradient(currentColor, currentColor);
    background-repeat: no-repeat;
    background-origin: border-box;
    background-position: 4px 0;
    background-size: 4px 100%;
  }
}
@media (prefers-reduced-motion: reduce) { .bouton, .nouvel-import { transition: none; } }
