/* ============================================================================
   AUBOTA Learning — style « signalisation routière » (direction C, couleurs vives).
   Bandeau bleu d'indication à liseré jaune, écusson de route, menu en panneaux de
   direction, jauges en marquage au sol, panonceaux. Boutons en relief qui s'enfoncent.
   Tout passe par les variables : on change la palette ICI, rien d'autre.
   Contrastes AA vérifiés (texte blanc sur bleu/vert/rouge, encre sur jaune).
   ========================================================================== */
@font-face {
  font-family: "Noto Sans Learning";
  src: url("fonts/noto-sans-latin.woff2") format("woff2");
  font-weight: 400 700; font-style: normal; font-display: swap;
}
:root {
  --bleu: #0B5ED7; --bleu-fonce: #073F94; --bleu-pale: #E4EEFF; --bleu-trait: #9EC1F5;
  --jaune: #FFCC00; --jaune-fonce: #A88600; --jaune-pale: #FFF4C2; --jaune-trait: #E9C84A;
  --vert: #00843D; --vert-fonce: #005A29; --vert-pale: #E1F5E8; --vert-trait: #94D3AE;
  --rouge: #D4111E; --rouge-fonce: #8E0A13; --rouge-pale: #FDE6E8; --rouge-trait: #F2A5AB;
  --rouge-panneau: #E2001A; --orange: #FF8A00;
  --encre: #0B1F3A; --muted: #46566B; --fond: #EEF3FA; --carte: #FFFFFF; --trait: #C9D3E1;
  --asphalte: #2B3036;
  --rel: 5px;                 /* hauteur du relief des boutons */
  --r: 14px;
  --f: "Noto Sans Learning", "Noto Sans", Roboto, system-ui, "Segoe UI", Arial, sans-serif;
  /* couleur d'un thème (posée en ligne par l'appli) */
  --c: var(--bleu); --cd: var(--bleu-fonce); --c-soft: #0B5ED71f; --c-ring: #0B5ED780;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html, body { margin: 0; background: var(--fond); color: var(--encre); }
body { font-family: var(--f); font-size: 16px; line-height: 1.4; min-height: 100vh; overflow-x: hidden; -webkit-tap-highlight-color: transparent; }
h1, h2, h3, p { margin: 0; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: default; }
[hidden], .hidden { display: none !important; }
svg.ic { width: 1.3em; height: 1.3em; flex: none; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 3px solid var(--encre); outline-offset: 3px; }
.bandeau :focus-visible, .player__top :focus-visible, .dir:focus-visible, .btn--primary:focus-visible, .btn--bleu:focus-visible { outline-color: var(--jaune); }

.app { max-width: 560px; margin: 0 auto; min-height: 100vh; background: var(--fond); position: relative; }
.ecran { min-height: 100vh; display: flex; flex-direction: column; }
.page { padding: 14px 16px 28px; display: flex; flex-direction: column; gap: 14px; }
.chargement { padding: 40px 16px; text-align: center; color: var(--muted); font-weight: 700; }
.intro { color: var(--muted); font-weight: 600; font-size: .96rem; }
.etiquette { display: block; font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

/* ---- Bandeau : panneau d'indication bleu, liseré jaune ---- */
.bandeau {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 10px;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 14px 12px;
  background: var(--bleu); color: #fff; border-bottom: 5px solid var(--jaune);
}
.bandeau__txt { flex: 1; min-width: 0; }
.bandeau__titre { font-size: 1.22rem; font-weight: 700; line-height: 1.15; overflow-wrap: anywhere; }
.bandeau__titre:focus { outline: none; }
.bandeau__sous { font-size: .84rem; font-weight: 600; opacity: .95; line-height: 1.25; margin-top: 2px; }
.bandeau__retour {
  width: 42px; height: 42px; flex: none; border-radius: 50%; border: 2px solid #fff; background: transparent;
  color: #fff; display: grid; place-items: center; padding: 0;
}
.bandeau__retour svg.ic { width: 22px; height: 22px; }
.bandeau__ecu { background: none; border: 0; padding: 0; flex: none; border-radius: 10px; }
.bandeau__ecu .ecusson { box-shadow: 0 3px 0 var(--bleu-fonce); }

/* ---- Écusson de formation = numéro de route ---- */
.ecusson {
  display: inline-grid; place-items: center; flex: none; min-width: 48px; height: 36px; padding: 0 8px;
  background: var(--jaune); color: var(--encre); border: 3px solid var(--encre); border-radius: 8px;
  font-weight: 700; font-size: 1.15rem; letter-spacing: .02em; line-height: 1; white-space: nowrap;
}
.ecusson--long { font-size: .98rem; min-width: 60px; }
.ecusson--s { min-width: 36px; height: 26px; font-size: .82rem; border-width: 2px; border-radius: 6px; padding: 0 5px; }

/* ---- Panonceau : cartouche blanc cerclé de noir ---- */
.panonceau {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  background: #fff; color: var(--encre); border: 2px solid var(--encre); border-radius: 7px;
  padding: 2px 9px; font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; white-space: nowrap;
}
.panonceau--jaune { background: var(--jaune); }

/* ---- Blocs (cartes) ---- */
.bloc { background: var(--carte); border: 2px solid var(--trait); border-radius: 16px; padding: 12px 14px; box-shadow: 0 3px 0 var(--trait); min-width: 0; }
.bloc__n { font-size: 1rem; font-weight: 600; margin-top: 2px; }
.bloc__n b { font-size: 1.7rem; font-weight: 700; line-height: 1.05; }
.deux { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* progression = jauge « prêt à X % » */
.prog__top { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.prog__pct { line-height: 1; margin-top: 2px; }
.prog__pct b { font-size: 2.6rem; font-weight: 700; letter-spacing: -.02em; }
.prog__pct small { font-size: 1.3rem; font-weight: 700; }
.prog__droite { display: flex; align-items: center; gap: 6px; text-align: right; }
.prog__l { font-size: .9rem; font-weight: 600; color: var(--muted); max-width: 150px; line-height: 1.2; }
.rev-ready__info { width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--bleu-trait); background: var(--bleu-pale); color: var(--bleu); display: grid; place-items: center; padding: 0; flex: none; }
.rev-ready__tip { margin-top: 10px; font-size: .88rem; color: var(--muted); background: var(--bleu-pale); border-radius: 10px; padding: 8px 10px; }

/* ---- Jauge = marquage au sol ---- */
.route { position: relative; height: 22px; background: var(--asphalte); border: 2px solid var(--encre); border-radius: 11px; overflow: hidden; }
.route::after { content: ""; position: absolute; left: 8px; right: 8px; top: 50%; height: 3px; margin-top: -1.5px; background: repeating-linear-gradient(90deg, #fff 0 10px, transparent 10px 20px); opacity: .9; }
.route__fill { position: absolute; inset: 0 auto 0 0; background: var(--jaune); box-shadow: inset 0 -5px 0 rgba(0, 0, 0, .14); border-radius: 9px 0 0 9px; transition: width .4s ease; }
.route--s { height: 14px; border-radius: 7px; border-width: 2px; }
.route--s::after { height: 2px; margin-top: -1px; }

/* bornes (objectif du jour) */
.bornes { display: flex; gap: 3px; margin-top: 8px; }
.bornes b { flex: 1; height: 10px; border-radius: 5px; background: var(--trait); }
.bornes b.f { background: var(--bleu); }

/* série : la semaine en pastilles rondes façon panneaux */
.semaine { display: flex; justify-content: space-between; margin-top: 8px; gap: 2px; }
.jour { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: .7rem; font-weight: 700; color: var(--muted); }
.jour i { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; border: 3px solid var(--trait); background: #fff; }
.jour.ok i { border-color: var(--rouge-panneau); }
.jour.ok i::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--vert); }
.jour.auj { color: var(--bleu); }
.jour.auj i { border-color: var(--bleu); box-shadow: 0 0 0 2px var(--bleu-pale); }
.jour.auj.ok i { border-color: var(--rouge-panneau); }

/* ---- Menu : panneaux de direction en relief ---- */
.menu { display: flex; flex-direction: column; gap: 12px; }
.dir {
  display: flex; align-items: center; gap: 12px; width: 100%; min-height: 62px; padding: 8px 14px; text-align: left;
  background: var(--bleu); color: #fff; border: 3px solid #fff; border-radius: 12px;
  box-shadow: 0 0 0 2px var(--bleu), 0 calc(var(--rel) + 2px) 0 2px var(--bleu-fonce);
  margin-bottom: var(--rel); transition: transform .08s, box-shadow .08s;
}
.dir:active:not(:disabled) { transform: translateY(var(--rel)); box-shadow: 0 0 0 2px var(--bleu), 0 2px 0 2px var(--bleu-fonce); }
.dir:disabled { opacity: .7; }
.dir__ico { width: 42px; height: 42px; border-radius: 50%; background: #fff; color: var(--bleu); display: grid; place-items: center; flex: none; }
.dir__ico svg.ic { width: 25px; height: 25px; }
.dir__txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dir__t { font-size: 1.08rem; font-weight: 700; line-height: 1.15; }
.dir__s { font-size: .84rem; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dir__fleche { color: var(--jaune); display: flex; flex: none; }
.dir__fleche svg.ic { width: 24px; height: 24px; stroke-width: 3; }
.dir--jaune { background: var(--jaune); color: var(--encre); border-color: var(--encre); box-shadow: 0 0 0 2px var(--jaune), 0 calc(var(--rel) + 2px) 0 2px var(--jaune-fonce); min-height: 68px; }
.dir--jaune:active:not(:disabled) { box-shadow: 0 0 0 2px var(--jaune), 0 2px 0 2px var(--jaune-fonce); }
.dir--jaune .dir__ico { background: var(--encre); color: var(--jaune); }
.dir--jaune .dir__t { font-size: 1.22rem; }
.dir--jaune .dir__fleche { color: var(--encre); }
.dir--vert { background: var(--vert); box-shadow: 0 0 0 2px var(--vert), 0 calc(var(--rel) + 2px) 0 2px var(--vert-fonce); }
.dir--vert:active:not(:disabled) { box-shadow: 0 0 0 2px var(--vert), 0 2px 0 2px var(--vert-fonce); }
.dir--vert .dir__ico { color: var(--vert); }
.dir--col { flex-direction: column; align-items: flex-start; gap: 6px; min-height: 104px; }
.dir--col .dir__fleche { display: none; }
.menu .deux { gap: 12px; }

/* ---- Bandeau « nouveau », rail des formations ---- */
.nouveau { background: var(--jaune-pale); border: 2px solid var(--encre); border-left-width: 10px; border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.nouveau__t { font-weight: 600; }
.nouveau__b { display: flex; gap: 10px; flex-wrap: wrap; width: 100%; }
.nouveau__b .btn { flex: 1 1 150px; min-height: 46px; font-size: .95rem; }
.rail { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 6px; margin: 0 -2px; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.rail__b { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px 5px 6px; border-radius: 999px; border: 2px solid var(--trait); background: #fff; font-weight: 700; font-size: .86rem; max-width: 220px; }
.rail__t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail__b.is-on { border-color: var(--bleu); background: var(--bleu-pale); color: var(--bleu-fonce); box-shadow: 0 0 0 2px var(--bleu); }

.avert { font-size: .84rem; color: var(--muted); background: #fff; border: 2px dashed var(--trait); border-radius: 10px; padding: 8px 10px; }
.mention { font-size: .78rem; color: var(--muted); line-height: 1.35; }

/* ---- Choix des formations ---- */
.ecran-choix { min-height: 100vh; display: flex; flex-direction: column; }
.ecran-choix .page { flex: 1; }
.famille { display: flex; flex-direction: column; gap: 10px; }
.famille__t { font-size: 1.05rem; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.famille__t::before { content: ""; width: 14px; height: 14px; border-radius: 50%; background: var(--jaune); border: 3px solid var(--encre); }
.famille__l { display: flex; flex-direction: column; gap: 10px; }
.famille__note { font-size: .78rem; color: var(--muted); }
.form-it {
  position: relative; display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 12px;
  background: #fff; border: 3px solid var(--trait); border-radius: 14px; box-shadow: 0 4px 0 var(--trait); cursor: pointer;
  margin-bottom: 4px;
}
.form-it__in { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.form-it__tx { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.form-it__t { font-weight: 700; font-size: 1.04rem; }
.form-it__s { font-size: .84rem; color: var(--muted); font-weight: 600; }
.form-it__case { width: 32px; height: 32px; border-radius: 8px; border: 3px solid var(--trait); display: grid; place-items: center; color: transparent; flex: none; background: #fff; }
.form-it__case svg.ic { stroke-width: 3.4; width: 20px; height: 20px; }
.form-it.is-on { border-color: var(--bleu); background: var(--bleu-pale); box-shadow: 0 4px 0 var(--bleu); }
.form-it.is-on .form-it__case { background: var(--bleu); border-color: var(--bleu); color: #fff; }
.form-it:focus-within { outline: 3px solid var(--encre); outline-offset: 3px; }
.form-it.is-bientot { cursor: default; background: #F5F7FA; box-shadow: none; border-style: dashed; }
.form-it.is-bientot .ecusson { background: #E6EAF0; }
.form-it.is-bientot .form-it__t { color: var(--muted); }
.bas { position: sticky; bottom: 0; z-index: 15; padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px)); background: #fff; border-top: 3px solid var(--bleu); }
.bas__msg { font-size: .88rem; color: var(--muted); text-align: center; }
.bas__msg:empty { display: none; }

/* Mes formations */
.form-carte { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px; background: #fff; border: 3px solid var(--trait); border-radius: 14px; box-shadow: 0 4px 0 var(--trait); }
.form-carte.is-active { border-color: var(--bleu); box-shadow: 0 4px 0 var(--bleu); }
.form-carte__tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.form-carte__t { font-weight: 700; font-size: 1.05rem; }
.form-carte__s { font-size: .86rem; color: var(--muted); font-weight: 600; }

/* Réglages */
.reglage { display: flex; align-items: center; gap: 10px; background: #fff; border: 2px solid var(--trait); border-radius: 12px; padding: 10px 12px; }
.reglage__tx { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.reglage__t { font-weight: 700; }
.reglage__s { font-size: .84rem; color: var(--muted); }
.reglage__b { width: auto; min-height: 44px; flex: none; }

/* ---- Boutons en relief ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 8px 16px;
  border-radius: 14px; border: 3px solid var(--encre); background: #fff; color: var(--encre);
  font-weight: 700; font-size: 1.02rem; line-height: 1.15; text-align: center;
  box-shadow: 0 var(--rel) 0 var(--encre); margin-bottom: var(--rel); transition: transform .08s, box-shadow .08s;
}
.btn:active:not(:disabled) { transform: translateY(var(--rel)); box-shadow: 0 0 0 var(--encre) !important; }
.btn:disabled { opacity: .55; }
.btn--block { width: 100%; }
.btn--primary, .btn--bleu { background: var(--bleu); border-color: var(--bleu-fonce); color: #fff; box-shadow: 0 var(--rel) 0 var(--bleu-fonce); }
.btn--ghost { background: #fff; border-color: var(--encre); color: var(--encre); box-shadow: 0 var(--rel) 0 var(--trait); }
.btn--jaune { background: var(--jaune); border-color: var(--encre); color: var(--encre); box-shadow: 0 var(--rel) 0 var(--jaune-fonce); }
.btn--savais { background: var(--vert); border-color: var(--vert-fonce); color: #fff; box-shadow: 0 var(--rel) 0 var(--vert-fonce); }
.btn--flou { background: var(--jaune); border-color: var(--encre); color: var(--encre); box-shadow: 0 var(--rel) 0 var(--jaune-fonce); }
.btn--revoir { background: var(--rouge); border-color: var(--rouge-fonce); color: #fff; box-shadow: 0 var(--rel) 0 var(--rouge-fonce); }
.btn--theme { background: var(--c); border-color: var(--cd); color: #fff; box-shadow: 0 var(--rel) 0 var(--cd); }
.btn--theme-ghost { background: #fff; border-color: var(--c); color: var(--cd); box-shadow: 0 var(--rel) 0 var(--c-ring); }
.btn--note { flex-direction: column; gap: 1px; padding: 6px 4px; min-height: 60px; }
.btn--note .btn__t { font-size: 1rem; }
.btn--note small { font-size: .74rem; font-weight: 600; opacity: .95; }
.btn.is-parle { background: var(--bleu-pale); border-color: var(--bleu); color: var(--bleu-fonce); }
.btn--voix { min-height: 46px; font-size: .95rem; }

/* ---- Thèmes ---- */
.theme { background: #fff; border: 2px solid var(--trait); border-left: 8px solid var(--c); border-radius: 14px; padding: 12px 14px; box-shadow: 0 3px 0 var(--trait); display: flex; flex-direction: column; gap: 8px; }
.theme__head { display: flex; align-items: center; gap: 10px; }
.theme__pastille { width: 34px; height: 34px; border-radius: 9px; background: var(--c); color: #fff; display: grid; place-items: center; font-weight: 700; flex: none; box-shadow: 0 3px 0 var(--cd); }
.theme__titre { font-size: 1.05rem; font-weight: 700; line-height: 1.2; }
.theme__tete { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.theme__sur { font-size: .72rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--c, #0B5ED7); }
.theme__meta { font-size: .85rem; color: var(--muted); font-weight: 600; }
.theme__pct { font-size: .82rem; font-weight: 700; color: var(--vert-fonce); }
.theme__actions { display: flex; gap: 10px; }
.theme__actions .btn { flex: 1 1 0; min-width: 0; min-height: 46px; padding-left: 8px; padding-right: 8px; }
.theme__actions .btn:nth-child(3) { flex-basis: 100%; }
.theme__actions:has(.btn:nth-child(3)) { flex-wrap: wrap; }

/* ---- Lecteur (quiz, fiches, révision, examen, oral) ---- */
.player { min-height: 100vh; display: flex; flex-direction: column; }
.player__top {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 10px;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 14px 12px; background: var(--bleu); color: #fff; border-bottom: 5px solid var(--jaune);
}
.player__quit { width: 42px; height: 42px; flex: none; border-radius: 50%; border: 2px solid #fff; background: transparent; color: #fff; display: grid; place-items: center; padding: 0; }
.player__quit svg.ic { width: 22px; height: 22px; }
.player__bar { flex: 1; position: relative; height: 18px; background: var(--asphalte); border: 2px solid #fff; border-radius: 9px; overflow: hidden; }
.player__bar::after { content: ""; position: absolute; left: 6px; right: 6px; top: 50%; height: 2px; margin-top: -1px; background: repeating-linear-gradient(90deg, #fff 0 8px, transparent 8px 16px); opacity: .85; }
.player__fill { position: absolute; inset: 0 auto 0 0; background: var(--jaune); transition: width .3s ease; }
.player__count { flex: none; font-weight: 700; font-size: .9rem; background: var(--jaune); color: var(--encre); border: 2px solid var(--encre); border-radius: 8px; padding: 2px 8px; white-space: nowrap; }
.player__hud { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px 0; }
.vies { display: flex; gap: 4px; }
.vies__c { width: 26px; height: 26px; color: var(--rouge); }
.vies__c svg { width: 100%; height: 100%; display: block; }
.vies__c.is-off { color: var(--trait); }
.combo { background: var(--orange); color: var(--encre); border: 2px solid var(--encre); border-radius: 8px; padding: 1px 10px; font-weight: 700; }
.player__zone { flex: 1; padding: 14px 16px 18px; display: flex; flex-direction: column; gap: 14px; }
.player__pied { position: sticky; bottom: 0; z-index: 15; background: #fff; border-top: 3px solid var(--bleu); padding: 12px 16px calc(10px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 10px; }
.player__pied.is-ok { background: var(--vert-pale); border-top-color: var(--vert); border-radius: 22px 22px 0 0; }
.player__pied.is-faux { background: var(--rouge-pale); border-top-color: var(--rouge); border-radius: 22px 22px 0 0; }
.player__action { display: flex; flex-direction: column; gap: 6px; }
.player > .player__action { padding: 12px 16px calc(10px + env(safe-area-inset-bottom, 0px)); background: #fff; border-top: 3px solid var(--bleu); position: sticky; bottom: 0; }
.examen-nav { flex-direction: row !important; gap: 10px; }
.examen-nav .btn { flex: 1; }
.chrono { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-weight: 700; font-size: 1.1rem; background: var(--jaune); color: var(--encre); border: 3px solid var(--encre); border-radius: 10px; padding: 3px 10px; }
.chrono.is-court { background: var(--rouge); color: #fff; border-color: #fff; }

.q { font-size: 1.18rem; font-weight: 700; line-height: 1.35; }
.rev-src { align-self: flex-start; display: inline-flex; background: var(--bleu); color: #fff; border: 2px solid #fff; box-shadow: 0 0 0 2px var(--bleu); border-radius: 7px; padding: 2px 10px; font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* choix (QCM) */
.choix { display: flex; flex-direction: column; gap: 12px; }
.choix__b { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 8px 14px; text-align: left; background: #fff; border: 3px solid var(--bleu); border-radius: 14px; box-shadow: 0 4px 0 var(--bleu); font-weight: 600; font-size: 1.02rem; color: var(--encre); margin-bottom: 4px; transition: transform .08s, box-shadow .08s; }
.choix__b:active:not(:disabled) { transform: translateY(4px); box-shadow: 0 0 0 var(--bleu); }
.choix__l { width: 32px; height: 32px; border-radius: 8px; background: var(--bleu); color: #fff; display: grid; place-items: center; font-weight: 700; flex: none; }
.choix__t { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.choix__b.is-sel { background: var(--bleu-pale); box-shadow: 0 4px 0 var(--bleu-fonce), 0 0 0 3px var(--jaune); }
.choix__b.is-bon { border-color: var(--vert); background: var(--vert-pale); box-shadow: 0 4px 0 var(--vert-fonce); }
.choix__b.is-bon .choix__l { background: var(--vert); }
.choix__b.is-faux { border-color: var(--rouge); background: var(--rouge-pale); box-shadow: 0 4px 0 var(--rouge-fonce); }
.choix__b.is-faux .choix__l { background: var(--rouge); }
.choix__b:disabled:not(.is-bon):not(.is-faux) { border-color: var(--trait); box-shadow: 0 4px 0 var(--trait); color: var(--muted); }
.choix__b:disabled:not(.is-bon):not(.is-faux) .choix__l { background: var(--trait); color: var(--encre); }

/* feuille de retour */
.feed { display: flex; flex-direction: column; gap: 10px; }
.feed__head { display: flex; align-items: center; gap: 12px; }
.feed__rond { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; color: #fff; flex: none; border: 3px solid #fff; }
.feed__rond svg.ic { width: 26px; height: 26px; stroke-width: 3.4; }
.feed.is-ok .feed__rond { background: var(--vert); box-shadow: 0 0 0 3px var(--vert); }
.feed.is-faux .feed__rond { background: var(--rouge); box-shadow: 0 0 0 3px var(--rouge); }
.feed__tx { display: flex; flex-direction: column; min-width: 0; }
.feed__t { font-size: 1.45rem; font-weight: 700; line-height: 1.1; }
.feed__s { font-size: .92rem; font-weight: 700; overflow-wrap: anywhere; }
.feed.is-ok .feed__t, .feed.is-ok .feed__s { color: var(--vert-fonce); }
.feed.is-faux .feed__t, .feed.is-faux .feed__s { color: var(--rouge-fonce); }
.feed.is-ok .feed__head { animation: pop .4s cubic-bezier(.3, 1.6, .5, 1); }
.feed.is-faux .feed__rond { animation: shake .35s; }
.explic { background: var(--jaune-pale); border: 2px solid var(--encre); border-left-width: 10px; border-radius: 10px; padding: 8px 12px; font-size: .95rem; font-weight: 500; max-height: 30vh; overflow-y: auto; }
.explic strong { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 2px; }
.rev-note-hint { font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.rev-grade { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rev-grade .btn { width: 100%; }
.btn.is-suggest { outline: 3px solid var(--encre); outline-offset: 2px; }
.btn.is-propose { position: relative; }
.rev-grade__tag { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: var(--encre); color: #fff; font-size: .62rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: 1px 6px; border-radius: 5px; white-space: nowrap; }
.btn.is-choisi { outline: 3px solid var(--encre); outline-offset: 2px; opacity: 1; }

/* saisie au pavé + formule */
.saisie { display: flex; flex-direction: column; gap: 14px; }
.saisie__calc { font-size: 1.1rem; font-weight: 700; background: #fff; border: 2px solid var(--trait); border-radius: 12px; padding: 12px; overflow-wrap: anywhere; }
.saisie__slot { display: inline-block; min-width: 64px; padding: 2px 10px; margin: 0 2px; border-radius: 8px; border: 3px solid var(--bleu); background: var(--bleu-pale); text-align: center; }
.saisie__slot.is-vide { color: var(--muted); }
.saisie__slot.is-bon { border-color: var(--vert); background: var(--vert-pale); }
.saisie__slot.is-faux { border-color: var(--rouge); background: var(--rouge-pale); }
.pave { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.pave__k { min-height: 54px; border-radius: 12px; border: 3px solid var(--encre); background: #fff; font-size: 1.3rem; font-weight: 700; box-shadow: 0 4px 0 var(--trait); margin-bottom: 4px; display: grid; place-items: center; }
.pave__k:active:not(:disabled) { transform: translateY(4px); box-shadow: none; }
.pave__k--eff { background: var(--jaune-pale); }
.formule { display: flex; flex-direction: column; gap: 16px; }
.formule__cases, .formule__pool { display: flex; flex-wrap: wrap; gap: 8px; }
.formule__cases { padding: 10px; background: #fff; border: 2px dashed var(--trait); border-radius: 12px; min-height: 64px; }
.case { min-width: 50px; height: 44px; border-radius: 10px; border: 3px dashed var(--bleu-trait); }
.jeton { min-height: 44px; min-width: 46px; padding: 4px 12px; border-radius: 10px; border: 3px solid var(--bleu); background: #fff; font-weight: 700; font-size: 1.05rem; box-shadow: 0 4px 0 var(--bleu); margin-bottom: 4px; }
.jeton--placed { background: var(--bleu-pale); }
.jeton.is-bon { border-color: var(--vert); background: var(--vert-pale); box-shadow: 0 4px 0 var(--vert-fonce); }
.jeton.is-faux { border-color: var(--rouge); background: var(--rouge-pale); box-shadow: 0 4px 0 var(--rouge-fonce); }

/* fiche recto/verso */
.carte { background: #fff; border: 3px solid var(--c); border-radius: 18px; box-shadow: 0 6px 0 var(--cd); padding: 22px 18px; min-height: 230px; display: flex; flex-direction: column; justify-content: center; gap: 12px; cursor: pointer; text-align: center; }
.carte__face { align-self: center; background: var(--c); color: #fff; border-radius: 7px; padding: 2px 10px; font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }
.carte__face--verso { background: var(--vert); }
.carte__txt { font-size: 1.15rem; font-weight: 600; }
.carte__hint { font-size: .85rem; color: var(--muted); }
.carte__note { background: var(--jaune-pale); border: 2px solid var(--encre); border-radius: 10px; padding: 6px 10px; font-size: .92rem; text-align: left; }
.carte.is-flip { animation: flip .32s ease; }
.fiche-voix-row { display: flex; justify-content: center; }
.fiches-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* ---- Panneaux routiers (vignette + panonceaux) ---- */
.panneau { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: 0 auto; padding: 14px 14px 10px; width: 100%; background: linear-gradient(#fff, var(--bleu-pale)); border: 2px solid var(--bleu-trait); border-radius: 16px; box-shadow: 0 3px 0 var(--bleu-trait); }
.panneau::before { content: "Observe ce signal"; display: inline-flex; background: var(--bleu); color: #fff; border: 2px solid #fff; box-shadow: 0 0 0 2px var(--bleu); border-radius: 7px; padding: 1px 10px; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; margin-bottom: 4px; }
.panneau__v { width: 136px; height: 136px; filter: drop-shadow(0 4px 0 rgba(11, 31, 58, .16)); }
.panneau__v svg { width: 100%; height: 100%; display: block; }
.panneau__v img { width: 100%; height: 100%; display: block; object-fit: contain; }
.panneau__v--over { position: relative; }
/* A16 : pourcentage de pente écrit en blanc sur la pente noire, incliné comme elle */
.panneau__over { position: absolute; left: 40%; top: 76%; transform: translate(-50%, -50%) rotate(21deg); font-family: Arial, Helvetica, sans-serif; font-weight: 800; font-size: .82rem; line-height: 1; color: #fff; white-space: nowrap; pointer-events: none; }
.panneau__sous { background: #fff; color: #1a1a1a; font-weight: 700; font-size: .85rem; padding: 2px 12px; border-radius: 5px; border: 3px solid #1a1a1a; }
/* panonceau de texte sous un « autres dangers » (A14) — jamais dans le triangle */
.panneau__panonceau { background: #fff; color: #1a1a1a; font-weight: 700; font-size: .88rem; text-align: center; padding: 3px 12px; border-radius: 5px; border: 3px solid #1a1a1a; max-width: 240px; }
.panneau__lib { font-weight: 700; font-size: .88rem; text-align: center; }
.panneau--mini { flex-direction: row; flex-wrap: wrap; gap: 8px; margin: 6px 0 2px; justify-content: flex-start; padding: 0; background: none; border: 0; box-shadow: none; width: auto; }
.panneau--mini::before { display: none; }
.panneau--mini .panneau__v { width: 54px; height: 54px; filter: none; }
.panneau--mini .panneau__sous { font-size: .72rem; padding: 1px 7px; border-width: 2px; }
.panneau__panpicto { width: 96px; height: 48px; display: block; margin-top: -2px; }
.panneau--mini .panneau__panpicto { width: 40px; height: 20px; }
.panneau--mini .panneau__panonceau { font-size: .7rem; padding: 1px 7px; max-width: 150px; border-width: 2px; }
.panneau--mini .panneau__over { font-size: .34rem; }
.panneau--mini .panneau__lib { font-size: .78rem; }

/* ---- Examen écrit ---- */
.examen-bloc { display: flex; flex-direction: column; }
.examen-ou { font-weight: 700; color: var(--muted); font-size: .9rem; }
.fiches-grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.fiches-grille .btn { padding: 8px 6px; min-height: 48px; font-size: .95rem; }
.examen-q { display: flex; flex-direction: column; gap: 14px; }
.examen-q__num { align-self: flex-start; background: var(--jaune); color: var(--encre); border: 2px solid var(--encre); border-radius: 7px; padding: 1px 10px; font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; }
.examen-champ { width: 100%; min-height: 54px; padding: 10px 14px; font-size: 1.1rem; font-weight: 600; border: 3px solid var(--bleu); border-radius: 12px; background: #fff; }
.examen-champ:focus { outline: 3px solid var(--jaune); outline-offset: 1px; }
.examen-champ.is-bon { border-color: var(--vert); background: var(--vert-pale); }
.examen-champ.is-faux { border-color: var(--rouge); background: var(--rouge-pale); }
.symboles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.symb { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 8px; border-radius: 14px; border: 3px solid var(--bleu); background: #fff; color: var(--encre); box-shadow: 0 4px 0 var(--bleu); margin-bottom: 4px; }
.symb:active:not(:disabled) { transform: translateY(4px); box-shadow: none; }
.symb__ic { width: 46px; height: 46px; color: var(--encre); }
.symb__ic svg { width: 100%; height: 100%; display: block; }
.symb__l { font-weight: 700; font-size: .92rem; }
.symb.is-sel { background: var(--bleu-pale); box-shadow: 0 4px 0 var(--bleu-fonce), 0 0 0 3px var(--jaune); }
.symb.is-bon { border-color: var(--vert); background: var(--vert-pale); box-shadow: 0 4px 0 var(--vert-fonce); }
.symb.is-faux { border-color: var(--rouge); background: var(--rouge-pale); box-shadow: 0 4px 0 var(--rouge-fonce); }
.symb-mini { display: inline-block; width: 20px; height: 20px; vertical-align: -5px; margin: 0 4px; color: var(--vert-fonce); }
.symb-mini svg { width: 100%; height: 100%; display: block; }
.examen-corr { display: flex; flex-direction: column; gap: 10px; }
.examen-corr__row { background: #fff; border: 2px solid var(--trait); border-left: 8px solid var(--trait); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 4px; }
.examen-corr__row.is-ok { border-left-color: var(--vert); }
.examen-corr__row.is-faux { border-left-color: var(--rouge); }
.examen-corr__row.is-check { border-left-color: var(--jaune); }
.examen-corr__q { display: flex; gap: 8px; font-weight: 700; }
.examen-corr__n { flex: none; width: 24px; height: 24px; border-radius: 6px; background: var(--bleu); color: #fff; display: grid; place-items: center; font-size: .8rem; }
.examen-corr__tien { font-size: .92rem; color: var(--muted); }
.examen-corr__bonne { font-size: .92rem; font-weight: 700; color: var(--vert-fonce); }
.examen-corr__badge { align-self: flex-start; font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: 1px 8px; border-radius: 6px; border: 2px solid; }
.examen-corr__badge.is-ok { color: var(--vert-fonce); background: var(--vert-pale); }
.examen-corr__badge.is-faux { color: var(--rouge-fonce); background: var(--rouge-pale); }
.examen-corr__badge.is-check { color: #5C4600; background: var(--jaune-pale); }
.examen-corr__juge { display: flex; gap: 8px; margin-top: 4px; }
.examen-corr__juge .btn { flex: 1; min-height: 44px; font-size: .92rem; }

/* ---- Bilans ---- */
.bilan { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 6px 0; }
.bilan__picto { width: 92px; height: 92px; color: var(--vert); filter: drop-shadow(0 5px 0 var(--vert-fonce)); animation: pop .5s cubic-bezier(.3, 1.6, .5, 1); }
.bilan__picto.is-moyen { color: var(--bleu); filter: drop-shadow(0 5px 0 var(--bleu-fonce)); }
.bilan__picto svg { width: 100%; height: 100%; display: block; }
.bilan__h { font-size: 1.4rem; font-weight: 700; }
.bilan__xp { font-size: 2.2rem; font-weight: 700; color: var(--encre); background: var(--jaune); border: 3px solid var(--encre); border-radius: 12px; padding: 0 16px; box-shadow: 0 4px 0 var(--jaune-fonce); }
.bilan__sc { color: var(--muted); font-weight: 600; }
.bilan__combo { font-weight: 700; color: #8A3A00; }
.bilan__note { font-weight: 700; }
.bilan__revoir { width: 100%; text-align: left; background: #fff; border: 2px solid var(--trait); border-left: 8px solid var(--rouge); border-radius: 10px; padding: 10px 12px; }
.bilan__revoir ul { margin: 6px 0 0; padding-left: 18px; font-size: .92rem; }
.bilan__actions { display: flex; flex-direction: column; gap: 6px; width: 100%; margin-top: 6px; }
.bilan__actions .btn { width: 100%; }
.tri { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; width: 100%; }
.tri__c { border: 3px solid; border-radius: 14px; padding: 6px 4px; background: #fff; box-shadow: 0 3px 0; display: flex; flex-direction: column; }
.tri__c b { font-size: 1.8rem; font-weight: 700; line-height: 1.1; }
.tri__c span { font-size: .8rem; font-weight: 700; }
.tri__c--v { border-color: var(--vert); color: var(--vert-fonce); background: var(--vert-pale); }
.tri__c--j { border-color: #7A5C00; color: #5C4600; background: var(--jaune-pale); }
.tri__c--r { border-color: var(--rouge); color: var(--rouge-fonce); background: var(--rouge-pale); }
.rev-goal { width: 100%; display: flex; flex-direction: column; gap: 4px; }
.rev-goal__bar { height: 12px; border-radius: 6px; background: var(--trait); overflow: hidden; }
.rev-goal__fill { display: block; height: 100%; background: var(--bleu); }
.rev-goal__l { font-size: .85rem; font-weight: 700; color: var(--muted); }

/* ---- Vérifications (Socle 1) ---- */
.schema { background: #fff; border: 2px solid var(--trait); border-radius: 16px; padding: 10px; box-shadow: 0 3px 0 var(--trait); }
.schema svg { width: 100%; height: auto; display: block; }
.past text { pointer-events: none; }
.past:focus { outline: none; }
.past:focus-visible circle { stroke: var(--encre); stroke-width: 4; }
.zone-pan { background: #fff; border: 2px solid var(--trait); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.zone-pan__hint { color: var(--muted); font-weight: 600; font-size: .92rem; }
.zone-pan__t { font-size: 1.05rem; font-weight: 700; }
.zone-pan__it { display: flex; gap: 10px; }
.zone-pan__n, .socle-it__n { flex: none; min-width: 34px; height: 34px; padding: 0 4px; border-radius: 9px; background: var(--jaune); border: 3px solid var(--encre); color: var(--encre); display: grid; place-items: center; font-weight: 700; box-shadow: 0 3px 0 var(--jaune-fonce); }
.zone-pan__tx p { font-size: .95rem; margin-top: 2px; }
.socle-liste__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.socle-liste__h { font-size: 1.05rem; font-weight: 700; }
.socle-rev { min-height: 44px; font-size: .9rem; padding: 4px 12px; }
.socle-rev[aria-pressed="true"] { background: var(--jaune); }
.socle-liste { display: flex; flex-direction: column; gap: 10px; }
.socle-it { background: #fff; border: 2px solid var(--trait); border-radius: 12px; overflow: hidden; box-shadow: 0 3px 0 var(--trait); }
.socle-it__tete { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; background: #fff; border: 0; text-align: left; font-weight: 700; min-height: 52px; }
.socle-it__tete[aria-expanded="true"] { background: var(--bleu); color: #fff; }
.socle-it__t { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.socle-it__chev { display: flex; flex: none; }
.socle-it__chev svg.ic { width: 22px; height: 22px; stroke-width: 2.8; }
.socle-it__corps { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 10px; }
.socle-it__corps > p { font-size: .96rem; }
.socle-it__note { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.socle-it__voix { display: flex; }
.socle-it.is-su { border-color: var(--vert); box-shadow: 0 3px 0 var(--vert); }
.socle-it.is-rev { border-color: var(--rouge); box-shadow: 0 3px 0 var(--rouge); }
.socle-it--info .socle-it__n { background: var(--bleu-pale); }

/* ---- Fiches orales ---- */
.oral-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.oral-actions .btn { flex: 1 1 140px; }
.oral-meta { font-weight: 600; color: var(--muted); font-size: .92rem; }
.oral-liste { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.oral-it { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; background: #fff; border: 2px solid var(--trait); border-radius: 12px; box-shadow: 0 3px 0 var(--trait); text-align: left; }
.oral-it__n { flex: none; min-width: 40px; height: 40px; border-radius: 10px; background: var(--jaune); border: 3px solid var(--encre); display: grid; place-items: center; font-weight: 700; font-size: 1.1rem; box-shadow: 0 3px 0 var(--jaune-fonce); }
.oral-it__tx { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.oral-it__t { font-weight: 700; line-height: 1.25; }
.oral-it__m { font-size: .84rem; color: var(--muted); font-weight: 600; }
.oral-it__chev { font-size: 1.6rem; color: var(--bleu); font-weight: 700; }
.oral-tirage { background: var(--jaune-pale); border: 2px solid var(--encre); border-left-width: 10px; border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.oral-badge { display: inline-block; margin-left: 6px; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; background: var(--jaune); color: var(--encre); border: 2px solid var(--encre); border-radius: 6px; padding: 0 6px; vertical-align: 2px; }
.oral-pts { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 4px; }
.oral-pt { font-size: .96rem; }
.oral-pt::marker { color: var(--bleu); }
.oral-pt--n1 { margin-left: 16px; list-style-type: circle; }
.oral-pt--n2 { margin-left: 32px; list-style-type: square; }
.oral-question { font-weight: 700; color: var(--bleu-fonce); }
.oral-rep { display: flex; flex-direction: column; gap: 10px; }
.oral-rep:focus { outline: none; }
.oral-outils { display: flex; flex-direction: column; gap: 4px; }
.oral-recite { background: var(--bleu-pale); border-radius: 10px; padding: 8px 10px; font-weight: 600; }
.oral-corr { display: flex; flex-direction: column; gap: 8px; }
.oral-corr__h { font-weight: 700; }
.oral-chks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.oral-chk--n1 { margin-left: 18px; }
.oral-chk--n2 { margin-left: 36px; }
.oral-chk__l { position: relative; display: flex; gap: 10px; align-items: flex-start; padding: 8px 10px; border: 2px solid var(--trait); border-radius: 10px; background: #fff; cursor: pointer; }
.oral-chk__in { position: absolute; opacity: 0; width: 1px; height: 1px; }
.oral-chk__box { flex: none; width: 26px; height: 26px; border-radius: 7px; border: 3px solid var(--trait); display: grid; place-items: center; color: transparent; background: #fff; }
.oral-chk__box svg.ic { width: 18px; height: 18px; stroke-width: 3.4; }
.oral-chk__t { font-size: .95rem; }
.oral-chk.is-dit .oral-chk__l { border-color: var(--vert); background: var(--vert-pale); }
.oral-chk.is-dit .oral-chk__box { background: var(--vert); border-color: var(--vert); color: #fff; }
.oral-chk.is-voix .oral-chk__l { box-shadow: inset 4px 0 0 var(--bleu); }
.oral-chk__in:focus-visible + .oral-chk__box { outline: 3px solid var(--encre); outline-offset: 2px; }
.oral-score { font-weight: 600; }
.oral-score__n { font-size: 1.1rem; }
.oral-score__g.is-su { color: var(--vert-fonce); }
.oral-score__g.is-flou { color: #5C4600; }
.oral-score__g.is-rate { color: var(--rouge-fonce); }
.oral-note-ok { font-weight: 700; color: var(--vert-fonce); }
.oral-retenir { background: var(--jaune-pale); border: 2px solid var(--encre); border-left-width: 10px; border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.oral-retenir:focus { outline: none; }
.oral-retenir__h { display: flex; align-items: center; gap: 6px; font-weight: 700; }
.oral-fiche-corr { display: flex; flex-direction: column; gap: 10px; }
.oral-corps { gap: 12px; }

/* M'enregistrer */
.rec { display: flex; flex-direction: column; gap: 4px; }
.rec__ligne { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rec__chrono { font-weight: 700; color: var(--rouge); font-variant-numeric: tabular-nums; }
.btn--rec.is-rec { background: var(--rouge); color: #fff; border-color: var(--rouge-fonce); box-shadow: 0 var(--rel) 0 var(--rouge-fonce); }
.btn--rec .ic { color: var(--rouge); }
.btn--rec.is-rec .ic { color: #fff; animation: rec-pulse 1s infinite; }
.rec__etat { font-size: .9rem; color: var(--muted); font-weight: 600; }
.rec__etat:empty { display: none; }
.rec.is-err .rec__etat { color: var(--rouge-fonce); }
.rec__lect { display: flex; flex-direction: column; gap: 6px; }
.rec__audio { width: 100%; height: 40px; }

/* Réciter et corriger (correction à la voix) */
.recite { display: flex; flex-direction: column; gap: 4px; }
.btn--recite.is-rec { background: var(--rouge); color: #fff; border-color: var(--rouge-fonce); box-shadow: 0 var(--rel) 0 var(--rouge-fonce); }
.recite__etat { font-size: .9rem; font-weight: 600; color: var(--muted); }
.recite__etat:empty { display: none; }
.recite.is-err .recite__etat { color: var(--rouge-fonce); background: var(--rouge-pale); border-radius: 8px; padding: 6px 8px; }
.recite__live { font-style: italic; background: #fff; border: 2px dashed var(--bleu-trait); border-radius: 10px; padding: 8px 10px; min-height: 2.2em; color: var(--encre); }
.voix-res { background: var(--bleu-pale); border: 2px solid var(--bleu); border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.voix-res__h { display: flex; align-items: center; gap: 6px; font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--bleu-fonce); }
.voix-res__t { font-weight: 600; }
.voix-res__t b { font-size: 1.15rem; }
.voix-res__manque { margin: 0; padding-left: 20px; font-size: .92rem; }
.voix-res__brut { background: #fff; border-radius: 8px; padding: 6px 10px; }
.voix-res__brut p { font-style: italic; font-size: .92rem; }
.voix-res__aide { font-size: .84rem; color: var(--muted); }
.voix-res.is-vide { border-color: var(--trait); background: #fff; }

/* ---- Animations (coupées si l'utilisateur préfère moins de mouvement) ---- */
.pulse { animation: pop .35s ease; }
.is-tap { animation: pop .18s ease; }
@keyframes pop { 0% { transform: scale(.85); } 100% { transform: scale(1); } }
@keyframes shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
@keyframes flip { from { transform: rotateX(18deg); opacity: .4; } to { transform: none; opacity: 1; } }
@keyframes rec-pulse { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---- Petits écrans ---- */
@media (max-width: 370px) {
  .page, .player__zone { padding-left: 12px; padding-right: 12px; }
  .bandeau, .player__top { padding-left: 10px; padding-right: 10px; gap: 8px; }
  .bandeau__titre { font-size: 1.08rem; }
  .dir { padding: 8px 10px; gap: 10px; }
  .dir__ico { width: 36px; height: 36px; }
  .prog__pct b { font-size: 2.2rem; }
  .btn--note small { font-size: .68rem; }
  .ecusson--long { min-width: 54px; font-size: .9rem; }
}

/* ---- Rappel « N fiches orales à revoir » (Réviser) et verdict du test blanc au format officiel ---- */
.rev-oral { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; padding: 8px 14px; background: #fff; color: var(--bleu-fonce); border: 2px dashed var(--bleu); border-radius: 12px; font-weight: 700; font-size: .98rem; text-align: left; }
.rev-oral span { flex: 1; min-width: 0; }
.rev-oral .ic { width: 22px; height: 22px; flex: none; }
.rev-oral:active { background: var(--bleu-pale); }
.bilan .rev-oral { margin-top: 4px; }
.bilan__verdict { font-weight: 800; font-size: 1.05rem; border: 2px solid; border-radius: 10px; padding: 4px 12px; }
.bilan__verdict.is-ok { color: var(--vert-fonce); background: var(--vert-pale); }
.bilan__verdict.is-ko { color: var(--rouge-fonce); background: var(--rouge-pale); }

/* ---- Essai gratuit, cadenas, feuille « Débloquer », carte « Ton compte AUBOTA » (19/11, droits.js) ---- */
.essai { background: var(--jaune-pale); border: 2px solid var(--jaune-trait); border-radius: 16px; padding: 12px 14px; margin: 0 0 14px; }
.essai__t { margin: 8px 0 10px; font-weight: 600; color: var(--encre); }
.essai__go { margin-bottom: var(--rel); }
/* 24/11 : bandeau d'accès (droits.js) : gratuit temporaire, pause sans réseau, fin de l'accès gratuit */
.acces { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.acces__t { margin: 2px 0 0; font-weight: 800; font-size: 1.05rem; color: var(--encre); }
.acces__p { margin: 0; color: var(--encre); }
.acces__s { margin: 0; color: var(--muted); font-size: .9rem; }
.acces__msg { margin: 0; min-height: 1.2em; font-weight: 600; color: var(--encre); }
.acces__msg:empty { display: none; }
.acces__go { margin-top: 4px; min-height: 46px; }
.acces__b { display: flex; gap: 10px; flex-wrap: wrap; width: 100%; margin-top: 4px; }
.acces__b .btn { flex: 1 1 150px; min-height: 46px; }
.acces--pause { border-color: var(--encre); border-left-width: 10px; }
.verrous { display: grid; gap: 10px; margin: 6px 0 14px; }
.verrou { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 10px 14px; text-align: left;
  background: #F4F6FA; border: 2px dashed var(--trait); border-radius: 14px; color: var(--muted); font: inherit; }
.verrou__ico { flex: none; display: inline-flex; width: 34px; height: 34px; align-items: center; justify-content: center;
  border-radius: 50%; background: var(--jaune); color: var(--encre); }
.verrou__ico .ic { width: 20px; height: 20px; }
.verrou__tx { display: flex; flex-direction: column; min-width: 0; }
.verrou__t { font-weight: 700; color: var(--encre); overflow-wrap: anywhere; }
.verrou__s { font-size: .85rem; }
.oral-liste .verrou { margin: 0; }
.btn--verrou { background: #F4F6FA; border-style: dashed; border-color: var(--trait); color: var(--muted); box-shadow: 0 var(--rel) 0 var(--trait); }
.btn--verrou .ic { color: var(--jaune-fonce); }
.dir.is-verrou { opacity: .8; border-style: dashed; }
.feuille { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center;
  background: #0B1F3A99; padding: 0; }
.feuille__boite { position: relative; width: 100%; max-width: 520px; max-height: 92vh; overflow: auto; background: var(--carte);
  border-radius: 20px 20px 0 0; border-top: 6px solid var(--jaune); padding: 18px 16px calc(18px + env(safe-area-inset-bottom)); }
.feuille__fermer { position: absolute; top: 8px; right: 10px; width: 44px; height: 44px; border: 0; background: none;
  font-size: 1.8rem; line-height: 1; color: var(--muted); }
.feuille__sur { display: inline-block; font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.feuille__t { margin: 4px 44px 10px 0; font-size: 1.35rem; color: var(--encre); }
.feuille__liste { margin: 0 0 14px; padding: 0; list-style: none; display: grid; gap: 6px; }
.feuille__liste li { padding-left: 26px; position: relative; font-weight: 600; }
.feuille__liste li::before { content: ""; position: absolute; left: 4px; top: .3em; width: 12px; height: 7px;
  border-left: 3px solid var(--vert); border-bottom: 3px solid var(--vert); transform: rotate(-45deg); }
.feuille__p { margin: 0 0 10px; color: var(--muted); }
.feuille__zone .btn { margin-top: 4px; }
.feuille__msg { min-height: 1.3em; margin: 8px 0 0; font-weight: 700; color: var(--encre); }
@media (min-width: 560px) { .feuille { align-items: center; } .feuille__boite { border-radius: 20px; } }
.compte-carte { background: var(--carte); border: 2px solid var(--trait); border-radius: 16px; padding: 12px 14px; margin: 0 0 14px;
  box-shadow: 0 3px 0 var(--trait); }
.compte-carte__tete { display: flex; align-items: center; gap: 10px; }
.compte-carte__logo { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 9px;
  background: var(--encre); color: #fff; font-weight: 800; font-size: .9rem; }
.compte-carte__t { font-size: 1.05rem; }
.compte-carte__qui { margin: 8px 0 2px; font-weight: 700; overflow-wrap: anywhere; }
.compte-carte__etat { margin: 0 0 10px; color: var(--muted); font-size: .92rem; }
.compte-carte__b { display: flex; flex-wrap: wrap; gap: 10px; }
.compte-carte__b .btn { flex: 1 1 150px; min-height: 46px; font-size: .95rem; }
.compte-carte__lien { display: inline-block; margin-top: 4px; color: var(--bleu); font-weight: 700; text-decoration: none; padding: 6px 0; }

/* ---- Pistes de manœuvre (19/11) : 4 vignettes debout, puis une piste en grand ---- */
.pistes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.piste-carte { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px 10px; background: #fff;
  border: 2px solid var(--trait); border-radius: 14px; box-shadow: 0 3px 0 var(--trait); min-width: 0; }
.piste-carte:active { transform: translateY(3px); box-shadow: none; }
.piste-carte__n { width: 30px; height: 30px; border-radius: 50%; background: var(--bleu); color: #fff; font-weight: 700; display: grid; place-items: center; }
.piste-carte__svg { width: 100%; display: block; }
.piste-carte__t { font-size: .78rem; font-weight: 700; line-height: 1.15; text-align: center; overflow-wrap: anywhere; }
.piste-carte__s { font-size: .74rem; color: var(--muted); font-weight: 600; }
.piste-svg { width: 100%; height: auto; display: block; }
.piste-schema { padding: 8px; }
.piste-schema svg { max-width: 340px; margin: 0 auto; }
.piste-vue { font-size: .84rem; font-weight: 700; color: var(--muted); text-align: center; margin-bottom: 6px; }
.piste-etapes { margin: 6px 0 0; padding-left: 1.4em; display: flex; flex-direction: column; gap: 4px; font-weight: 600; }
.piste-trajet-txt p { margin-top: 4px; font-weight: 600; }
.piste-leg { display: flex; flex-direction: column; gap: 6px; font-size: .9rem; font-weight: 600; }
.piste-leg__l { display: flex; align-items: center; gap: 10px; }
.piste-leg__s { flex: none; width: 22px; height: 14px; display: inline-block; }
.piste-leg__rouge { width: 14px; margin: 0 4px; background: var(--rouge-panneau); border: 2px solid var(--encre); border-radius: 2px; }
.piste-leg__vide { width: 10px; height: 10px; margin: 0 6px; border: 1.5px solid #B7C2D0; }
.piste-leg__trajet { height: 6px; background: var(--bleu); border-radius: 3px; }
.piste-leg__ab { width: 22px; height: 22px; border-radius: 50%; background: var(--jaune); border: 3px solid var(--encre); }
.piste-nav { display: flex; gap: 10px; }
.piste-nav .btn { flex: 1; }

/* Tour du véhicule (21/11) : choix du véhicule, du mode, des côtés */
.tour-choix { display: flex; gap: 8px; flex-wrap: wrap; }
.tour-choix--defile { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
.tour-puce { flex: 0 1 auto; max-width: 100%; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 8px 12px; border-radius: 12px; border: 2px solid var(--trait); background: #fff; color: var(--encre); font: inherit; font-weight: 700; cursor: pointer; box-shadow: 0 3px 0 var(--trait); }
.tour-puce.is-on { background: var(--jaune); border-color: var(--encre); box-shadow: 0 3px 0 var(--jaune-fonce); }
.tour-puce__s { font-size: .78rem; font-weight: 600; opacity: .8; }
.tour-nav { display: flex; align-items: center; gap: 8px; }
.tour-nav__b { flex: none; width: 48px; height: 48px; padding: 0; justify-content: center; }
.tour-nav__mil { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 0; }
.boussole { width: 150px; max-width: 100%; }
.boussole svg { width: 100%; height: auto; display: block; }
.boussole__z:focus { outline: none; }
.boussole__z:focus-visible rect { stroke: var(--encre); stroke-width: 2.5; }
.tour-nav__t { font-weight: 700; font-size: .95rem; text-align: center; }
.tour-schema { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.tour-schema svg { width: 100%; height: auto; display: block; }
.tour-schema.is-large svg { max-width: none; }

/* Confirmation « Quitter l'appli ? » (bouton retour à l'accueil) */
.feuille__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.feuille__actions .btn { flex: 1 1 140px; }
.retour-msg { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 60; max-width: 90vw; background: var(--encre); color: #fff; font-weight: 700; padding: 10px 16px; border-radius: 12px; box-shadow: 0 4px 0 rgba(0,0,0,.25); text-align: center; }

/* Thèmes de l'examen (21/11) */
.thc { display: flex; flex-direction: column; gap: 12px; }
.thc-tire { background: var(--jaune); border: 2px solid var(--encre); border-radius: 12px; padding: 10px 12px; font-weight: 700; }
.thc__prog { color: var(--muted); font-weight: 700; font-size: .9rem; }
.thc__schema { overflow: hidden; }
.thc__vue { margin-top: 6px; font-weight: 700; font-size: .9rem; text-align: center; }
.thc__carte { background: #fff; border: 2px solid var(--trait); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 3px 0 var(--trait); }
.thc__q { font-size: 1.15rem; font-weight: 800; }
.thc__consigne { color: var(--muted); font-weight: 600; }
.thc__rep { font-size: 1rem; line-height: 1.45; }
.thc__note { display: flex; gap: 10px; flex-wrap: wrap; }
.thc__note .btn { flex: 1 1 130px; }
.thc__score { font-size: 3rem; font-weight: 800; text-align: center; color: var(--encre); }

/* Carte d'entraînement (thèmes, vérifications en révision) */
.entr { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.entr__rep { display: flex; flex-direction: column; gap: 8px; }
.entr__dire { line-height: 1.45; }
.entr-it { align-items: flex-start; }
.entr-it .zone-pan__tx { flex: 1; min-width: 0; }
.tour-choix--defile .tour-puce { flex: none; max-width: none; }

/* 23/11 : tickets de chronotachygraphe (.tk-*), attelage / dételage (.att-*), examen complet (.exc-*).
   Mêmes jetons que le reste du fichier, pas de color-mix (vieilles WebView). */
.tk-bloc { margin: 0 0 12px; border: 2px solid var(--trait, #C9D3E1); border-radius: 12px; background: var(--carte, #fff); }
.tk-bloc > summary { cursor: pointer; padding: 10px 14px; font-weight: 700; color: var(--bleu, #0B5ED7); min-height: 44px; display: flex; align-items: center; }
.tk-papier { padding: 6px 8px 10px; max-height: 70vh; overflow: auto; -webkit-overflow-scrolling: touch; display: flex; justify-content: center; }
.tk-bloc { max-width: 100%; min-width: 0; overflow: hidden; }
.tk-bloc > summary { overflow-wrap: anywhere; }
.tk-papier svg { display: block; width: 100%; max-width: min(300px, 100%); height: auto; box-shadow: 0 2px 6px rgba(0,0,0,.15); background: #fff; }
.tk-picto { display: flex; justify-content: center; margin: 4px 0 12px; color: var(--encre, #0B1F3A); }
.att-proc { background: var(--carte, #fff); border-radius: var(--r, 14px); padding: 14px; margin: 0 0 14px; box-shadow: 0 2px 0 var(--trait, #C9D3E1); }
.att-proc__t { margin: 0 0 2px; font-size: 1.15rem; color: var(--encre, #0B1F3A); }
.att-proc__s { margin: 0 0 10px; color: var(--muted, #46566B); font-size: .92rem; }
.att-proc .btn { margin-top: 8px; }
.att-liste { padding-left: 1.4em; margin: 0 0 14px; }
.att-etape { margin: 0 0 10px; color: var(--encre, #0B1F3A); }
.att-etape.is-trou { font-weight: 800; color: var(--rouge, #D4111E); letter-spacing: .1em; }
.att-etape__t { margin: 0; font-weight: 700; }
.att-etape__d { margin: 2px 0; }
.att-etape__s { margin: 2px 0; font-size: .92rem; color: var(--vert-fonce, #005A29); }
.att-etape__src { margin: 2px 0; font-size: .8rem; color: var(--muted, #46566B); font-style: italic; }
.att-cases { list-style: none; padding: 0; margin: 0 0 12px; }
.att-case { display: flex; flex-direction: column; gap: 2px; min-height: 48px; margin: 0 0 6px; padding: 6px 10px; border: 2px dashed var(--trait, #C9D3E1); border-radius: 12px; background: var(--carte, #fff); }
.att-case.is-plein { border-style: solid; border-color: var(--bleu-trait, #9EC1F5); }
.att-case.is-ok { border: 2px solid var(--vert, #00843D); background: var(--vert-pale, #E1F5E8); }
.att-case.is-ko { border: 2px solid var(--rouge, #D4111E); background: var(--rouge-pale, #FDE6E8); }
.att-case__vide { color: var(--muted, #46566B); font-weight: 700; }
.att-case__ko { font-size: .85rem; color: var(--rouge-fonce, #8E0A13); }
.att-reserve { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.att-jeton { min-height: 44px; padding: 8px 12px; border: 3px solid var(--bleu, #0B5ED7); border-radius: 12px; background: #fff; color: var(--encre, #0B1F3A); font: inherit; font-weight: 600; text-align: left; box-shadow: 0 3px 0 var(--bleu, #0B5ED7); }
.att-case .att-jeton { width: 100%; box-shadow: none; border-width: 0; padding: 4px 0; background: transparent; }
.att-feed { font-weight: 700; padding: 8px 12px; border-radius: 10px; }
.att-feed.is-ok { background: var(--vert-pale, #E1F5E8); color: var(--vert-fonce, #005A29); }
.att-feed.is-ko { background: var(--rouge-pale, #FDE6E8); color: var(--rouge-fonce, #8E0A13); }
.att-avalider { font-size: .8rem; color: var(--muted, #46566B); font-style: italic; margin: 0 0 8px; }
.exc-plan { padding-left: 1.4em; margin: 0 0 14px; }
.exc-plan__e { margin: 0 0 8px; }
.exc-plan__t { display: block; font-weight: 700; color: var(--encre, #0B1F3A); }
.exc-plan__s { display: block; font-size: .9rem; color: var(--muted, #46566B); }
.exc-sautee { color: var(--rouge-fonce, #8E0A13); font-size: .9rem; }
.exc-titre { margin: 8px 0 4px; color: var(--encre, #0B1F3A); }
.exc-chrono { margin-left: auto; font-variant-numeric: tabular-nums; font-weight: 800; padding: 4px 8px; border-radius: 8px; background: var(--jaune, #FFCC00); color: var(--encre, #0B1F3A); }
.exc-quitter { margin-left: 8px; min-height: 40px; padding: 4px 10px; border-radius: 8px; border: 2px solid #fff; background: transparent; color: #fff; font: inherit; font-weight: 700; }
.exc-bilan { list-style: none; padding: 0; margin: 0 0 14px; }
.exc-bilan__l { display: flex; flex-wrap: wrap; gap: 4px 10px; padding: 10px 12px; margin: 0 0 6px; background: var(--carte, #fff); border-radius: 12px; }
.exc-bilan__t { font-weight: 700; flex: 1 1 100%; color: var(--encre, #0B1F3A); }
.exc-bilan__n { color: var(--encre, #0B1F3A); }
.exc-bilan__src { font-size: .8rem; color: var(--muted, #46566B); font-style: italic; }
.exc-elim { font-weight: 700; color: var(--rouge-fonce, #8E0A13); background: var(--rouge-pale, #FDE6E8); padding: 8px 12px; border-radius: 10px; }

/* ==== 23/11 (étape 3) : séries courtes et formats mélangés (.se-*, assets/series.js). Jetons d'app.css.
   Tout ce qui se touche fait au moins 44 px de haut. */
.se .player__zone { gap: 12px; padding-bottom: 12px; }
.se-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.se-format { display: inline-flex; align-items: center; min-height: 24px; padding: 1px 9px; border-radius: 7px; background: var(--jaune); color: var(--encre); border: 2px solid var(--encre); font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.se-retour { font-size: .74rem; font-weight: 700; color: var(--rouge-fonce); background: var(--rouge-pale); border-radius: 7px; padding: 2px 8px; }
.se-ctx { font-size: 1rem; font-weight: 700; color: var(--muted); line-height: 1.3; }
.se-consigne { font-size: .86rem; font-weight: 600; color: var(--muted); }
.se .tk-papier { max-height: 42vh; }
.se .q { font-size: 1.12rem; }

/* vrai / faux : la réponse proposée sur une carte, deux gros boutons côte à côte */
.se-affirm { background: #fff; border: 3px solid var(--bleu); border-radius: 14px; padding: 10px 14px; }
.se-affirm__l { display: block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--bleu-fonce); margin-bottom: 4px; }
.se-affirm__t { font-size: 1.06rem; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.se-vf { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.se-vf__b { min-height: 64px; border-radius: 14px; border: 3px solid var(--encre); font-size: 1.2rem; font-weight: 700; background: #fff; color: var(--encre); box-shadow: 0 5px 0 var(--trait); margin-bottom: 5px; }
.se-vf__b--oui { border-color: var(--vert); box-shadow: 0 5px 0 var(--vert-fonce); color: var(--vert-fonce); }
.se-vf__b--non { border-color: var(--rouge); box-shadow: 0 5px 0 var(--rouge-fonce); color: var(--rouge-fonce); }
.se-vf__b:active:not(:disabled) { transform: translateY(5px); box-shadow: none; }
.se-vf__b.is-bon { background: var(--vert); color: #fff; border-color: var(--vert-fonce); }
.se-vf__b.is-faux { background: var(--rouge); color: #fff; border-color: var(--rouge-fonce); }
.se-vf__b:disabled:not(.is-bon):not(.is-faux) { opacity: .5; }

/* texte à trous */
.se-trou { font-size: 1.08rem; font-weight: 600; line-height: 1.6; background: #fff; border: 2px solid var(--trait); border-radius: 12px; padding: 10px 14px; overflow-wrap: anywhere; }
.se-trou__case { display: inline-block; min-width: 70px; padding: 0 10px; border-radius: 8px; border: 3px dashed var(--bleu); background: var(--bleu-pale); text-align: center; font-weight: 700; }
.se-trou__case.is-bon { border: 3px solid var(--vert); background: var(--vert-pale); }
.se-trou__case.is-faux { border: 3px solid var(--rouge); background: var(--rouge-pale); }
.choix--court .choix__b { min-height: 52px; }

/* qu'est-ce qui manque : la liste, le trou en jaune */
.se-liste { margin: 0; padding: 8px 12px 8px 32px; background: #fff; border: 2px solid var(--trait); border-radius: 12px; display: flex; flex-direction: column; gap: 4px; font-weight: 600; font-size: .96rem; }
.se-liste li.is-trou { background: var(--jaune-pale); border: 2px dashed var(--jaune-fonce); border-radius: 8px; padding: 2px 8px; font-weight: 700; list-style-position: inside; margin-left: -20px; }
.se-liste li.is-trou.is-bon { background: var(--vert-pale); border: 2px solid var(--vert); }
.se-liste li.is-trou.is-faux { background: var(--rouge-pale); border: 2px solid var(--rouge); }

/* remettre dans l'ordre / associer : cases en haut, cartes à toucher en bas */
.se-cases { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; counter-reset: se; }
.se-cases--ligne { flex-direction: row; flex-wrap: wrap; padding: 10px; background: #fff; border: 2px dashed var(--trait); border-radius: 12px; }
.se-case { display: flex; flex-direction: column; gap: 4px; padding: 6px; border-radius: 12px; border: 2px dashed var(--trait); background: #fff; }
.se-cases:not(.se-cases--ligne):not(.se-cases--paires) > .se-case { flex-direction: row; align-items: center; counter-increment: se; }
.se-cases:not(.se-cases--ligne):not(.se-cases--paires) > .se-case::before { content: counter(se); width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--bleu); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .9rem; }
.se-cases--ligne > .se-case { border: none; padding: 0; background: none; }
.se-case.is-plein { border-style: solid; border-color: var(--bleu-trait); }
.se-case.is-choisie { border: 3px solid var(--jaune-fonce); background: var(--jaune-pale); }
.se-case.is-ok { border: 2px solid var(--vert); background: var(--vert-pale); }
.se-case.is-ko { border: 2px solid var(--rouge); background: var(--rouge-pale); }
.se-case__g { font-weight: 700; font-size: .98rem; line-height: 1.3; overflow-wrap: anywhere; }
.se-case__g--picto { width: 52px; height: 52px; color: var(--encre); }
.se-case__g--picto svg { width: 100%; height: 100%; display: block; }
.se-case__g--panneau { width: 72px; }
.se-case__g--panneau svg, .se-case__g--panneau img { width: 72px; height: 72px; display: block; }
.se-case__d { flex: 1; min-height: 44px; width: 100%; text-align: left; padding: 6px 10px; border-radius: 10px; border: 2px solid transparent; background: var(--fond); color: var(--muted); font-weight: 600; font-size: .95rem; overflow-wrap: anywhere; }
.se-case.is-plein .se-case__d { background: var(--bleu-pale); color: var(--encre); border-color: var(--bleu); }
.se-cases--ligne .se-case__d { min-width: 48px; width: auto; text-align: center; font-size: 1.05rem; font-weight: 700; }
.se-case__bon { font-size: .86rem; font-weight: 700; color: var(--vert-fonce); }
.se-reserve { display: flex; flex-wrap: wrap; gap: 8px; }
.se-jeton { min-height: 48px; text-align: left; line-height: 1.25; font-size: .98rem; max-width: 100%; overflow-wrap: anywhere; }

/* pied : bouton principal + « J'ai deviné » */
.se-actions { display: flex; gap: 8px; }
.se-actions .btn--primary { flex: 1; }
.se-doute { flex: none; min-height: 52px; font-size: .9rem; padding: 6px 12px; }
.se-avalider { font-size: .84rem; font-weight: 600; color: var(--muted); }
.se-revient { font-size: .86rem; font-weight: 700; color: var(--rouge-fonce); }
.player__pied .explic { max-height: 24vh; }

/* bilan */
.se-erreurs { text-align: left; width: 100%; }
.se-erreurs ul { margin: 6px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; }
.se-erreurs__q { display: block; font-weight: 600; }
.se-erreurs__r { display: block; font-weight: 700; color: var(--vert-fonce); }
.se-bilan .bilan__actions { display: flex; flex-direction: column; gap: 10px; width: 100%; }
.se-bilan .bilan__actions .btn { width: 100%; }

/* écran « S'entraîner » : taille, tout mélanger, chapitres à cocher */
.se-choix .page { padding-bottom: 96px; }
.se-taille { display: flex; flex-direction: column; gap: 6px; }
.se-seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.se-seg__b { min-height: 48px; border-radius: 12px; border: 3px solid var(--bleu); background: #fff; color: var(--bleu-fonce); font-size: 1.15rem; font-weight: 700; }
.se-seg__b.is-on { background: var(--bleu); color: #fff; box-shadow: 0 0 0 3px var(--jaune); }
.se-tout .dir__txt, .se-dues .dir__txt, .se-reprendre .dir__txt { padding: 4px 0; }
.se-chapitres { display: flex; flex-direction: column; gap: 8px; }
.se-ch { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 8px 12px; text-align: left; border-radius: 12px; border: 2px solid var(--trait); background: #fff; color: var(--encre); }
.se-ch__case { width: 26px; height: 26px; flex: none; border-radius: 7px; border: 3px solid var(--bleu); background: #fff; }
.se-ch.is-on { border-color: var(--bleu); background: var(--bleu-pale); }
.se-ch.is-on .se-ch__case { background: var(--bleu); box-shadow: inset 0 0 0 3px #fff; }
.se-ch__txt { display: flex; flex-direction: column; min-width: 0; }
.se-ch__t { font-weight: 700; line-height: 1.2; }
.se-ch__s { font-size: .84rem; font-weight: 600; color: var(--muted); }
.se-lancer { position: fixed; left: 0; right: 0; bottom: 0; max-width: 560px; margin: 0 auto; }
/* 44 px au moins aussi pour la croix « Quitter » et le retour du bandeau (42 px avant, partout) */
.player__quit, .bandeau__retour { width: 44px; height: 44px; }

/* Fiches et quiz : la taille et « Tout mélanger » en haut, une ligne par chapitre avec « Série de 10 » */
.chap-tete { display: flex; flex-direction: column; gap: 10px; }
.theme--ligne { gap: 6px; padding: 10px 12px; }
.theme--ligne .theme__head { align-items: flex-start; }
.theme--ligne .theme__actions { flex-wrap: nowrap; gap: 6px; }
.theme--ligne .theme__actions:has(.btn:nth-child(4)) { flex-wrap: wrap; }
.theme--ligne .theme__actions .btn { flex: 1 1 0; min-width: 0; min-height: 44px; font-size: .88rem; padding-left: 5px; padding-right: 5px; white-space: nowrap; }
.theme--ligne .theme__actions .btn:nth-child(3) { flex-basis: 0; }
.theme--ligne .theme__actions .theme__serie { flex: 1.45 1 0; }
.theme--ligne .theme__actions:has(.btn:nth-child(4)) .theme__serie { flex-basis: 100%; }
.theme--ligne .theme__actions .btn svg.ic { flex: none; }
.rev-ready__info { width: 44px; height: 44px; }
/* accueil : compte à rebours de l'examen (touche = Réglages) */
.examen-date { display: flex; flex-direction: column; gap: 2px; width: 100%; text-align: left; color: var(--encre); font: inherit; cursor: pointer; }
.examen-date__n { font-size: 1rem; font-weight: 600; }
.examen-date__n b { font-size: 1.5rem; margin-right: 2px; }
.examen-date__s { font-size: .84rem; font-weight: 600; color: var(--muted); }
.examen-date.is-sprint { border-color: var(--jaune-fonce); background: var(--jaune-pale); }
/* Réglages : date d'examen et taille des séries */
.reglage--date { flex-direction: column; align-items: stretch; }
.reglage__ligne { display: flex; gap: 8px; align-items: center; }
.reglage__date { flex: 1; min-width: 0; min-height: 48px; padding: 6px 10px; border: 2px solid var(--bleu); border-radius: 10px; font: inherit; font-weight: 700; color: var(--encre); background: #fff; }
.reglage .se-seg { flex: none; width: 168px; }
.bandeau__ecu { min-height: 44px; min-width: 44px; display: grid; place-items: center; }

/* ============================================================================
   Simulateur d'attelage (23/11, branché le 23/11 au soir) : styles .sim-* (assets/attelage-simu.js).
   Mêmes jetons que l'appli (variables d'app.css, avec une valeur de secours), pas de color-mix.
   Toutes les cibles tactiles font au moins 44 × 44 px.
   ========================================================================== */
.sim .bandeau__retour { width: 44px; height: 44px; }
.sim-page { gap: 10px; padding-bottom: 32px; }
.sim-aide { margin: 0; padding-left: 1.2em; color: var(--encre, #0B1F3A); }
.sim-aide li { margin: 0 0 6px; }
.sim-mode { min-height: 56px; }
.sim-mode__s { margin: -4px 0 8px; color: var(--muted, #46566B); font-size: .92rem; font-weight: 600; }

/* statut : étape guidée ou chrono */
.sim-statut { background: var(--carte, #fff); border-radius: 12px; padding: 8px 12px; border-left: 6px solid var(--bleu, #0B5ED7); min-height: 44px; }
.sim--examen .sim-statut { border-left-color: var(--jaune, #FFCC00); }
.sim-statut__n { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted, #46566B); }
.sim-statut__t { font-weight: 700; font-size: 1.02rem; }
.sim-statut__l { margin: 4px 0 0; padding-left: 1.1em; font-size: .9rem; color: var(--encre, #0B1F3A); }

/* la scène et les dessins */
.sim-scene { background: #DCE7F5; border-radius: 12px; overflow: hidden; touch-action: none; border: 2px solid var(--trait, #C9D3E1); }
.sim-svg { display: block; width: 100%; height: auto; }
.sim-detail { background: var(--carte, #fff); border-radius: 12px; overflow: hidden; border: 2px solid var(--trait, #C9D3E1); touch-action: none; }
.sim-org, .sim-flex, .sim-tracteur { cursor: pointer; }
.sim-org:focus, .sim-flex:focus { outline: none; }
.sim-org:focus-visible .sim-hit, .sim-flex:focus-visible .sim-hit { fill-opacity: .12; stroke: var(--encre, #0B1F3A); stroke-width: 3; }
.sim-flex.is-choisi .sim-hit { fill-opacity: .15; stroke: var(--jaune, #FFCC00); stroke-width: 4; }
.sim-anneau { animation: sim-clignote 1.2s ease-in-out infinite; }
@keyframes sim-clignote { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { .sim-anneau { animation: none; } }

/* messages */
.sim-msg:empty { display: none; }
.sim-msg { border-radius: 12px; padding: 10px 12px; font-weight: 600; }
.sim-msg__t { font-weight: 800; }
.sim-msg__x { margin-top: 2px; }
.sim-msg__s { margin-top: 4px; font-size: .82rem; font-weight: 600; opacity: .9; font-style: italic; }
.sim-msg.is-info { background: var(--vert-pale, #E1F5E8); color: var(--vert-fonce, #005A29); }
.sim-msg.is-geste { background: var(--bleu-pale, #E4EEFF); color: var(--bleu-fonce, #073F94); }
.sim-msg.is-ordre { background: var(--jaune-pale, #FFF4C2); color: var(--encre, #0B1F3A); border: 2px solid var(--jaune-trait, #E9C84A); }
.sim-msg.is-danger { background: var(--rouge-pale, #FDE6E8); color: var(--rouge-fonce, #8E0A13); border: 3px solid var(--rouge, #D4111E); }

/* onglets : où l'on est */
.sim-onglets { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.sim-onglet { min-height: 48px; min-width: 44px; padding: 4px 2px; overflow-wrap: anywhere; border: 2px solid var(--bleu, #0B5ED7); border-radius: 10px; background: #fff; color: var(--bleu-fonce, #073F94); font-weight: 700; font-size: .86rem; }
.sim-onglet.is-ici { background: var(--bleu, #0B5ED7); color: #fff; }
.sim-onglet.is-suggere { box-shadow: 0 0 0 3px var(--jaune, #FFCC00); }

/* boutons des gestes */
.sim-panneau { display: flex; flex-direction: column; gap: 10px; }
.sim-groupe { background: var(--carte, #fff); border-radius: 12px; padding: 8px 10px 10px; }
.sim-groupe.is-montre { box-shadow: 0 0 0 3px var(--jaune, #FFCC00); }
.sim-groupe__t { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted, #46566B); margin-bottom: 6px; }
.sim-boutons { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sim-b { min-height: 48px; padding: 6px 8px; font-size: .9rem; line-height: 1.2; white-space: normal; text-align: center; justify-content: center; }
.sim-b.is-actif { background: var(--bleu-pale, #E4EEFF); border-color: var(--bleu, #0B5ED7); }
.sim-b.is-suggere { box-shadow: 0 0 0 3px var(--jaune, #FFCC00), 0 var(--rel, 5px) 0 var(--trait, #C9D3E1); }
.sim-b--maintien { min-height: 56px; background: var(--jaune-pale, #FFF4C2); -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; touch-action: none; }
.sim-fin { margin-top: 6px; min-height: 52px; }

/* la feuille d'annonce */
.sim-annonce { position: fixed; inset: 0; z-index: 50; background: rgba(11, 31, 58, .55); display: flex; align-items: flex-end; justify-content: center; }
.sim-annonce[hidden] { display: none; }
.sim-annonce__boite { width: 100%; max-width: 560px; max-height: 92vh; overflow: auto; background: var(--fond, #EEF3FA); border-radius: 18px 18px 0 0; padding: 16px 16px calc(18px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 10px; }
.sim-annonce__t { font-size: 1.15rem; }
.sim-annonce__s { color: var(--muted, #46566B); font-weight: 600; }
.sim-annonce .choix__b { min-height: 52px; }
.sim-voix__etat { font-size: .9rem; color: var(--muted, #46566B); margin-top: 6px; }

/* bilan */
.sim-bilan__gros { font-size: 1.5rem; font-weight: 800; color: var(--encre, #0B1F3A); }
.sim-bilan__s { color: var(--muted, #46566B); font-weight: 600; }
.sim-bilan__h { font-size: 1.05rem; margin: 6px 0 4px; }
.sim-bilan__bloc { background: var(--carte, #fff); border-radius: 12px; padding: 8px 12px; }
.sim-bilan__bloc ul { margin: 0; padding-left: 1.1em; }
.sim-bilan__bloc li { margin: 0 0 6px; }
.sim-bilan__bloc.is-danger { border-left: 6px solid var(--rouge, #D4111E); }
.sim-bilan__bloc.is-oubli { border-left: 6px solid var(--orange, #FF8A00); }
.sim-bilan__bloc.is-ordre { border-left: 6px solid var(--jaune, #FFCC00); }
.sim-bilan__etapes { list-style: none; padding: 0; margin: 0; counter-reset: sim; }
.sim-be { counter-increment: sim; position: relative; padding: 8px 10px 8px 40px; margin: 0 0 6px; border-radius: 10px; background: var(--carte, #fff); border: 2px solid var(--trait, #C9D3E1); }
.sim-be::before { content: counter(sim); position: absolute; left: 8px; top: 8px; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .8rem; background: var(--trait, #C9D3E1); }
.sim-be.is-ok { border-color: var(--vert, #00843D); }
.sim-be.is-ok::before { background: var(--vert, #00843D); color: #fff; }
.sim-be.is-desordre { border-color: var(--jaune-trait, #E9C84A); }
.sim-be.is-desordre::before { background: var(--jaune, #FFCC00); }
.sim-be.is-incomplet, .sim-be.is-oubli { border-color: var(--rouge, #D4111E); background: var(--rouge-pale, #FDE6E8); }
.sim-be.is-incomplet::before, .sim-be.is-oubli::before { background: var(--rouge, #D4111E); color: #fff; }
.sim-be.is-ok.is-annonce-ko { border-color: var(--orange, #FF8A00); }
.sim-be__t { font-weight: 700; }
.sim-be__s { font-size: .86rem; color: var(--muted, #46566B); }
.sim-be__m { font-size: .86rem; color: var(--rouge-fonce, #8E0A13); }
.sim-annonce .sim-voix { margin-bottom: 4px; }
.sim-annonce .choix__b:disabled { opacity: .75; }
/* 25/11 : simulateur « évident sur téléphone » — une carte consigne + UN bouton d'action ; le reste replié. Préfixe « simu- ». */
.simu-regles { margin: 0; padding-left: 1.3em; display: flex; flex-direction: column; gap: 6px; }
.simu-consigne { background: var(--carte); border-radius: 12px; padding: 10px 12px 12px; border-left: 6px solid var(--bleu); display: flex; flex-direction: column; gap: 6px; box-shadow: 0 2px 0 var(--trait); }
.sim--examen .simu-consigne { border-left-color: var(--jaune); }
.simu-consigne__n { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.simu-consigne__t { font-weight: 800; font-size: 1.08rem; line-height: 1.25; }
.simu-faire { font-weight: 700; color: var(--bleu-fonce); }
.simu-barre { display: flex; gap: 3px; height: 8px; background: var(--asphalte); border-radius: 4px; padding: 2px; }
.simu-barre__s { flex: 1; border-radius: 2px; background: #59626E; }
.simu-barre__s.is-fait { background: var(--vert-trait); animation: simu-pop .4s ease-out; }
.simu-barre__s.is-ici { background: var(--jaune); }
.simu-action { display: flex; flex-direction: column; gap: 4px; }
.simu-go { min-height: 60px; font-size: 1.08rem; font-weight: 800; line-height: 1.2; white-space: normal; animation: simu-appel 1.6s ease-in-out infinite; }
.simu-go.sim-b--maintien { background: var(--jaune); }
.simu-action__s { font-size: .86rem; font-weight: 600; color: var(--muted); text-align: center; }
.simu-outils { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sim--examen .simu-outils { grid-template-columns: 1fr; }
.simu-outil { min-height: 48px; font-size: .95rem; padding: 6px 8px; }
.simu-outil.is-actif { background: var(--bleu-pale); border-color: var(--bleu); }
.simu-outil.is-off { opacity: .8; text-decoration: line-through; }
.simu-ici { font-size: .86rem; font-weight: 700; color: var(--muted); margin: -6px 0 -8px; }
.simu-indice { background: var(--bleu-pale); border-radius: 10px; padding: 8px 10px; font-size: .92rem; display: flex; flex-direction: column; gap: 4px; }
.simu-indice__t { font-weight: 800; color: var(--bleu-fonce); }
.simu-indice__secu { font-weight: 700; color: var(--rouge-fonce); }
.simu-indice__l { margin: 0; padding-left: 1.1em; }
.simu-consigne .sim-msg { padding: 8px 10px; font-size: .95rem; }
.sim-msg.is-bien { background: var(--vert-pale); color: var(--vert-fonce); border: 2px solid var(--vert-trait); }
.sim-msg.is-etape { background: var(--vert); color: #fff; animation: simu-pop .4s ease-out; }
.sim-msg.is-etape .sim-msg__t::before, .sim-msg.is-bien .sim-msg__x::before { content: "✓ "; font-weight: 900; }
.simu-plus { background: var(--carte); border-radius: 12px; border: 2px solid var(--trait); }
.simu-plus > summary { min-height: 48px; display: flex; align-items: center; padding: 0 14px; font-weight: 700; color: var(--muted); cursor: pointer; list-style: none; }
.simu-plus > summary::-webkit-details-marker { display: none; }
.simu-plus > summary::after { content: "+"; margin-left: auto; font-size: 1.3rem; }
.simu-plus[open] > summary::after { content: "–"; }
.simu-plus[open] { padding: 0 10px 12px; display: flex; flex-direction: column; gap: 10px; }
.simu-pilote { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.simu-pilote[hidden] { display: none; }
.simu-roule { min-height: 56px; font-size: 1.02rem; font-weight: 800; }
.simu-pilote__s { grid-column: 1 / -1; font-size: .84rem; font-weight: 600; color: var(--muted); text-align: center; }
details.sim-groupe > summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; margin: 0; }
details.sim-groupe[open] > summary { margin-bottom: 6px; }
.simu-recap { background: var(--carte); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 8px; text-align: center; border-top: 6px solid var(--bleu); }
.simu-recap.is-parfait { border-top-color: var(--vert); }
.simu-etoiles { font-size: 2.4rem; line-height: 1; letter-spacing: 4px; }
.simu-etoile { color: var(--trait); }
.simu-etoile.is-on { color: var(--jaune); -webkit-text-stroke: 1.5px var(--encre); }
.simu-recap__t { font-size: 1.25rem; font-weight: 800; }
.simu-recap__e { background: var(--rouge); color: #fff; border-radius: 10px; padding: 8px 10px; font-weight: 800; }
.simu-tuiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.simu-tuile { background: var(--fond); border-radius: 10px; padding: 6px 2px; display: flex; flex-direction: column; }
.simu-tuile b { font-size: 1.15rem; }
.simu-tuile span { font-size: .72rem; font-weight: 700; color: var(--muted); }
.sim-be.is-montree { border-color: var(--bleu-trait); }
.sim-be.is-montree::before { background: var(--bleu-pale); }
.simu-joue .sim-detail, .simu-joue .sim-scene { box-shadow: 0 0 0 3px var(--bleu); }
@keyframes simu-pop { 0% { transform: scale(.96); } 60% { transform: scale(1.03); } 100% { transform: none; } }
@keyframes simu-appel { 50% { box-shadow: 0 0 0 4px var(--encre), 0 var(--rel) 0 var(--jaune-fonce); } }
@media (prefers-reduced-motion: reduce) { .simu-go, .simu-barre__s.is-fait, .sim-msg.is-etape { animation: none; } }

/* 24/11 (six thèmes) : accueil rangé par épreuve ; sujets de révision sans numéro ; rappel et tirage des thèmes */
.menu__section { display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
.menu__section-t { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 0; }
.menu__section-s { margin: -8px 0 0; font-size: .88rem; color: var(--muted); font-weight: 600; }
.theme__pastille--ico svg { width: 18px; height: 18px; }
.theme__liens { margin: 2px 0 0; font-size: .84rem; font-weight: 700; color: var(--muted); }
.thc-rappel { border-left: 4px solid var(--jaune); padding: 6px 10px; font-weight: 600; }
.thc__tirage { background: var(--jaune); border-radius: 10px; padding: 8px 10px; font-weight: 700; }
@media (min-width: 900px) {   /* version ordinateur (ordinateur.css : menu en deux colonnes) : une section = toute la largeur */
  .ecran--accueil .menu > .menu__section { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 4px; }
  .ecran--accueil .menu__section > .menu__section-t, .ecran--accueil .menu__section > .menu__section-s { grid-column: 1 / -1; }
}

/* ---- 25/11 : couche de jeu (assets/fun.js) — bulle d'encouragement, défi éclair, Mes badges. Préfixe « fun- ». ----
   Animations courtes (≤ 0,5 s), posées seulement si les effets sont activés (classe fun-anim / fun-bravo / fun-hop
   ajoutée par fun.js) et coupées par prefers-reduced-motion. */
.fun-picto { width: 1.3em; height: 1.3em; flex: none; fill: none; stroke: currentColor; stroke-width: 2.1; stroke-linecap: round; stroke-linejoin: round; }
.fun-bulle {
  position: fixed; z-index: 9000; left: 50%; top: calc(70px + env(safe-area-inset-top, 0px)); transform: translateX(-50%);
  display: flex; align-items: center; gap: 8px; max-width: calc(100vw - 32px); width: max-content;
  padding: 8px 14px; border-radius: 12px; border: 3px solid var(--encre); background: var(--orange); color: var(--encre);
  font-weight: 800; font-size: .98rem; line-height: 1.2; box-shadow: 0 4px 0 var(--encre); pointer-events: none;
}
.fun-bulle--badge { background: var(--jaune); }
.fun-bulle .fun-picto { width: 22px; height: 22px; }
.fun-bulle.fun-anim { animation: fun-arrive .45s cubic-bezier(.3, 1.5, .5, 1); }
@keyframes fun-arrive { from { opacity: 0; transform: translate(-50%, -14px) scale(.9); } to { opacity: 1; transform: translate(-50%, 0) scale(1); } }
.fun-bravo { animation: fun-bravo .45s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes fun-bravo { 0% { transform: scale(.8); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }
.fun-hop { animation: fun-hop .4s ease-out; }
@keyframes fun-hop { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-6px) rotate(-4deg); } }

/* Accueil : section « Pause défi » */
.fun-section .dir__ico { background: var(--orange); color: var(--encre); }

/* Défi éclair */
.fun-intro { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 18px 14px; }
.fun-intro__rond { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; background: var(--jaune); color: var(--encre); border: 4px solid var(--encre); box-shadow: 0 4px 0 var(--jaune-fonce); }
.fun-intro__rond .fun-picto { width: 40px; height: 40px; stroke-width: 2.2; }
.fun-intro__rond.fun-anim { animation: fun-bravo .5s cubic-bezier(.3, 1.6, .5, 1); }
.fun-intro__t { font-size: 1.2rem; font-weight: 800; }
.fun-intro__s { color: var(--muted); font-weight: 600; font-size: .94rem; }
.fun-intro__rec { font-weight: 700; background: var(--bleu-pale); border-radius: 10px; padding: 6px 12px; }
.fun-go { min-height: 56px; font-size: 1.15rem; }
.fun-defi__bar .player__fill { transition: width .2s linear; }
.fun-defi__chrono { min-width: 52px; text-align: center; }
.fun-defi.is-presse .fun-defi__fill { background: var(--orange); }
.fun-defi.is-presse .fun-defi__chrono { background: var(--orange); }
.fun-defi__hud { font-weight: 700; color: var(--muted); font-size: .92rem; }
.fun-defi__score { background: var(--vert-pale); color: var(--vert-fonce); border: 2px solid var(--vert); border-radius: 8px; padding: 1px 10px; }
.fun-bilan .fun-intro__rond { margin-bottom: 2px; }
.fun-record { font-weight: 800; background: var(--jaune); border: 2px solid var(--encre); border-radius: 10px; padding: 4px 12px; }
.fun-record--non { background: var(--bleu-pale); border-color: var(--bleu-trait); font-weight: 700; }
.fun-bonne { display: block; font-weight: 700; color: var(--vert-fonce); font-size: .9rem; }

/* Mes badges */
.fun-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; text-align: center; }
.fun-stat { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.fun-stat b { font-size: 1.5rem; line-height: 1.1; }
.fun-stat span { font-size: .76rem; color: var(--muted); font-weight: 600; overflow-wrap: anywhere; }
.fun-badges { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 10px; }
.fun-badge { display: flex; align-items: center; gap: 12px; background: #fff; border: 2px solid var(--trait); border-radius: 14px; padding: 10px 12px; min-width: 0; }
.fun-badge__m { width: 52px; height: 52px; flex: none; border-radius: 50%; display: grid; place-items: center; border: 3px solid var(--encre); }
.fun-badge__m .fun-picto { width: 28px; height: 28px; }
.fun-badge.is-on { border-color: var(--jaune-trait); box-shadow: 0 3px 0 var(--jaune-trait); }
.fun-badge.is-on .fun-badge__m { background: var(--jaune); color: var(--encre); box-shadow: 0 3px 0 var(--jaune-fonce); }
.fun-badge.is-off .fun-badge__m { background: var(--fond); color: var(--muted); border-color: var(--trait); border-style: dashed; }
.fun-badge.is-off .fun-badge__t { color: var(--muted); }
.fun-badge__tx { display: flex; flex-direction: column; min-width: 0; }
.fun-badge__t { font-weight: 800; }
.fun-badge__d { font-size: .86rem; color: var(--muted); }
.fun-badge__q { font-size: .76rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin-top: 2px; }
.fun-badge.is-on .fun-badge__q { color: var(--vert-fonce); }
@media (min-width: 520px) { .fun-badges { grid-template-columns: 1fr 1fr; } }
@media (prefers-reduced-motion: reduce) {
  .fun-bulle.fun-anim, .fun-bravo, .fun-hop, .fun-intro__rond.fun-anim { animation: none; }
  .fun-defi__bar .player__fill { transition: none; }
}
