/* Appli élèves et parents : la charte « arène » (25/09/2026, quatrième piste, conception.html §4), repartie de la
   charte sobre v2 (archivée dans tools/appli-familles/chartes/2026-09-25-sobre-v2/). Le jeu est dans la forme et
   la typo, visible sur chaque écran, le texte reste du texte : panneaux à coins coupés (chanfrein de 10 px en haut
   à gauche et en bas à droite), bordure fine claire à 12 %, liseré d'accent de 3 px sur l'élément actif, titres en
   Barlow Condensed majuscules espacées, chiffres en Rajdhani, texte Inter. Deux accents : cyan pour l'action et
   l'actif, orange pour l'attention (à revérifier, ✗, échéance proche) ; l'or reste aux pièces et au palier le
   plus haut. Paliers de rareté (gris, bronze, argent, or, prisme) lus par composants-suivi.css. Fond anthracite
   bleuté, jamais du noir pur ; thème clair gris ardoise, jamais du blanc pur. **Quatre niveaux de surface à pas
   visibles** (25/09/2026, sixième passe, sur retour de Robin « les cartes ne ressortent pas ») : page (--af-fond),
   carte (--af-carte), panneau (--af-panneau, les éléments dans une carte et les missions posées sur la page), creux
   (--af-creux, les cartes de sujets dans une zone, les blocs de maths et de réponse). Ce qui est posé directement sur la
   page et doit sauter aux yeux (missions à revoir, habitudes, cadre du radar) prend --af-saillant : la surface la plus
   claire du sombre (le panneau) et la plus claire du clair (la carte, blanche). En sombre chaque niveau est
   7 à 9 L* plus clair que le précédent (5,8 → 15 → 22 → 29), en clair 84,7 → 98 pour la carte, 92 et 85 pour les
   deux niveaux imbriqués ; vérifié par tests/contraste.test.mjs (surfaces voisines à 6 L* au moins). Sombre par défaut pour l'élève,
   clair pour le parent, bascule dans les deux. Colonne de 600 px, boutons de 44 px, 390 px sans débordement,
   aucune animation sous prefers-reduced-motion. Les noms de jetons --af-* de la v2 sont conservés. */
@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@500;600&family=Rajdhani:wght@600;700&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@500;700&display=swap');

:root {
  --af-fond: #CDD4DE; --af-fond-2: #C3CBD7; --af-fond-ext: #CDD4DE; --af-fond-ext-2: #D5DBE4; --af-carte: #F9FAFC; --af-panneau: #E4E8EF; --af-creux: #CFD6E1; --af-saillant: #F9FAFC;
  --af-encre: #131A2E; --af-texte-2: #3F4A5A; --af-texte-3: #4C5870; --af-filet: #5F6C85; --af-filet-opaque: #5F6C85;
  --af-contour-accent: #0B6279; --af-contour-alerte: #7A4F00; --af-contour-or: #7A5A06;
  --af-accent: #22D3EE; --af-accent-sur: #0B1C22; --af-accent-texte: #0B6279; --af-accent-doux: #C3F0F8;
  --af-alerte: #F59E0B; --af-alerte-sur: #1A1300; --af-alerte-texte: #7A4F00; --af-alerte-doux: #F7E3C0;
  --af-teal: #22D3EE; --af-teal-sur: #0B1C22; --af-teal-texte: #0B6279; --af-teal-doux: #C3F0F8;
  --af-or: #D4A017; --af-or-texte: #7A5A06; --af-or-encre: #1A1300; --af-or-doux: #EFE4C3; --af-or-clair: #F2C14E; --af-or-profond: #B8860B; --af-or-sur: #131A2E;
  --af-soleil: #F59E0B; --af-soleil-encre: #1A1300; --af-soleil-texte: #7A4F00; --af-soleil-doux: #F7E3C0;
  --af-orange: #C2410C;
  --af-corail: #DC2626; --af-corail-sur: #FFFFFF; --af-corail-texte: #A81919; --af-corail-doux: #F5D4D4;
  --af-violet: #6B7280; --af-violet-encre: #FFFFFF; --af-violet-texte: #444E5E; --af-violet-doux: #C4CCD8;
  --af-palier-gris: #8A93A3; --af-palier-gris-texte: #56607A;
  --af-palier-bronze: #B87333; --af-palier-bronze-texte: #8A5220;
  --af-palier-argent: #C0C7D1; --af-palier-argent-texte: #56607A;
  --af-palier-or: #F2C14E; --af-palier-or-texte: #7A5A06;
  --af-palier-prisme: conic-gradient(from 200deg, #22D3EE, #8B5CF6, #F2C14E, #22D3EE); --af-palier-prisme-texte: #4A3BB8;
  --af-halo: rgba(34, 211, 238, .30); --af-halo-or: rgba(212, 160, 23, .28);
  --af-gris-doux: #C4CCD8;
  --af-ombre: none; --af-ombre-haute: 0 16px 40px rgba(19, 26, 46, .18); --af-ombre-cadre: none;
  --af-rayon: 0; --af-rayon-petit: 0; --af-chanfrein: 10px; --af-chanfrein-petit: 6px;
  --af-onglets-h: 60px;
  --af-police-titre: "Barlow Condensed", "Inter", "Segoe UI", system-ui, sans-serif;
  --af-police-texte: "Inter", "Segoe UI", system-ui, sans-serif;
  --af-police-chiffres: "Rajdhani", "JetBrains Mono", ui-monospace, Consolas, monospace;
  --af-police-mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
  --af-encre-2: var(--af-texte-2); --af-encre-3: var(--af-texte-3); --af-ligne: var(--af-filet);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --af-fond: #0F131B; --af-fond-2: #1A2030; --af-fond-ext: #0F131B; --af-fond-ext-2: #141924; --af-carte: #1F2637; --af-panneau: #2C3549; --af-creux: #3A4459; --af-saillant: #2C3549;
    --af-encre: #E6E8EC; --af-texte-2: #B8C0CC; --af-texte-3: #98A2B0; --af-filet: #8593A7; --af-filet-opaque: #8593A7;
    --af-contour-accent: #22D3EE; --af-contour-alerte: #F59E0B; --af-contour-or: #F2C14E;
    --af-accent: #22D3EE; --af-accent-sur: #0B1C22; --af-accent-texte: #22D3EE; --af-accent-doux: #1E5568;
    --af-alerte: #F59E0B; --af-alerte-sur: #1A1300; --af-alerte-texte: #F5B043; --af-alerte-doux: #5A4526;
    --af-teal: #22D3EE; --af-teal-sur: #0B1C22; --af-teal-texte: #22D3EE; --af-teal-doux: #1E5568;
    --af-or: #F2C14E; --af-or-texte: #F2C14E; --af-or-encre: #1A1300; --af-or-doux: #5A5430; --af-or-clair: #F7D57A; --af-or-profond: #B8860B; --af-or-sur: #131A2E;
    --af-soleil: #F59E0B; --af-soleil-encre: #1A1300; --af-soleil-texte: #F5B043; --af-soleil-doux: #5A4526;
    --af-orange: #F0A35C;
    --af-corail: #F26D6D; --af-corail-sur: #1F0A0A; --af-corail-texte: #FF8A8A; --af-corail-doux: #4A2F36;
    --af-violet: #8B93A7; --af-violet-encre: #12161F; --af-violet-texte: #BCC3D2; --af-violet-doux: #414B62;
    --af-palier-gris: #8A93A3; --af-palier-gris-texte: #AEB6C4;
    --af-palier-bronze: #B87333; --af-palier-bronze-texte: #D89A5E;
    --af-palier-argent: #C0C7D1; --af-palier-argent-texte: #C0C7D1;
    --af-palier-or: #F2C14E; --af-palier-or-texte: #F2C14E;
    --af-palier-prisme: conic-gradient(from 200deg, #22D3EE, #8B5CF6, #F2C14E, #22D3EE); --af-palier-prisme-texte: #22D3EE;
    --af-halo: rgba(34, 211, 238, .38); --af-halo-or: rgba(242, 193, 78, .30);
    --af-gris-doux: #414B62;
    --af-ombre: none; --af-ombre-haute: 0 16px 40px rgba(0, 0, 0, .6); --af-ombre-cadre: none;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --af-fond: #0F131B; --af-fond-2: #1A2030; --af-fond-ext: #0F131B; --af-fond-ext-2: #141924; --af-carte: #1F2637; --af-panneau: #2C3549; --af-creux: #3A4459; --af-saillant: #2C3549;
  --af-encre: #E6E8EC; --af-texte-2: #B8C0CC; --af-texte-3: #98A2B0; --af-filet: #8593A7; --af-filet-opaque: #8593A7;
    --af-contour-accent: #22D3EE; --af-contour-alerte: #F59E0B; --af-contour-or: #F2C14E;
  --af-accent: #22D3EE; --af-accent-sur: #0B1C22; --af-accent-texte: #22D3EE; --af-accent-doux: #1E5568;
  --af-alerte: #F59E0B; --af-alerte-sur: #1A1300; --af-alerte-texte: #F5B043; --af-alerte-doux: #5A4526;
  --af-teal: #22D3EE; --af-teal-sur: #0B1C22; --af-teal-texte: #22D3EE; --af-teal-doux: #1E5568;
  --af-or: #F2C14E; --af-or-texte: #F2C14E; --af-or-encre: #1A1300; --af-or-doux: #5A5430; --af-or-clair: #F7D57A; --af-or-profond: #B8860B; --af-or-sur: #131A2E;
  --af-soleil: #F59E0B; --af-soleil-encre: #1A1300; --af-soleil-texte: #F5B043; --af-soleil-doux: #5A4526;
  --af-orange: #F0A35C;
  --af-corail: #F26D6D; --af-corail-sur: #1F0A0A; --af-corail-texte: #FF8A8A; --af-corail-doux: #4A2F36;
  --af-violet: #8B93A7; --af-violet-encre: #12161F; --af-violet-texte: #BCC3D2; --af-violet-doux: #414B62;
  --af-palier-gris: #8A93A3; --af-palier-gris-texte: #AEB6C4;
  --af-palier-bronze: #B87333; --af-palier-bronze-texte: #D89A5E;
  --af-palier-argent: #C0C7D1; --af-palier-argent-texte: #C0C7D1;
  --af-palier-or: #F2C14E; --af-palier-or-texte: #F2C14E;
  --af-palier-prisme: conic-gradient(from 200deg, #22D3EE, #8B5CF6, #F2C14E, #22D3EE); --af-palier-prisme-texte: #22D3EE;
  --af-halo: rgba(34, 211, 238, .38); --af-halo-or: rgba(242, 193, 78, .30);
  --af-gris-doux: #414B62;
  --af-ombre: none; --af-ombre-haute: 0 16px 40px rgba(0, 0, 0, .6); --af-ombre-cadre: none;
  color-scheme: dark;
}

/* ---------- base ---------- */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; color: var(--af-encre); font-family: var(--af-police-texte); font-size: 15px; line-height: 1.55; -webkit-font-smoothing: antialiased; overflow-x: hidden; background: linear-gradient(180deg, var(--af-fond-ext) 0%, var(--af-fond-ext-2) 100%) fixed var(--af-fond-ext); }
h1, h2, h3, h4 { font-family: var(--af-police-titre); margin: 0; line-height: 1.15; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; }
h1 { font-size: 22px; letter-spacing: .06em; } h2 { font-size: 15px; } h3 { font-size: 14px; }
p { margin: 0 0 10px; }
a { color: var(--af-accent-texte); }
button { font: inherit; cursor: pointer; color: inherit; }
button:disabled { opacity: .45; cursor: not-allowed; }
input, textarea, select { font: inherit; color: var(--af-encre); background: var(--af-fond); border: 1px solid var(--af-filet-opaque); border-radius: 0; padding: 10px 12px; width: 100%; min-height: 44px; }
input:focus, textarea:focus, button:focus-visible { outline: 2px solid var(--af-accent); outline-offset: 2px; }
::selection { background: var(--af-accent); color: var(--af-accent-sur); }
.af-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.af-muet { color: var(--af-texte-2); }
.af-petit { font-size: 13.5px; }
.af-centre { text-align: center; }
.af-pile { display: grid; gap: 8px; }
.af-ligne { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.af-ligne .af-espace { flex: 1; }
.af-mono { font-family: var(--af-police-chiffres); font-weight: 600; font-variant-numeric: tabular-nums; }

/* ---------- le panneau à coins coupés ----------
   Le chanfrein coupe l'angle haut-gauche et bas-droit. clip-path couperait la bordure : elle est donc simulée par
   deux calques sous le contenu, ::before (la bordure) et ::after (le fond, en retrait d'un pixel). Le liseré
   d'accent de l'élément actif est un dégradé sur le calque de fond. */
.af-carte, .af-quete, .af-tete-jeu, .af-onglets, .af-solde-hud, .af-modale, .af-jour, .af-compteurs div, .af-choix button, .af-choix label.af-opt, .af-bascule, .af-check, .af-picker, .af-emplacement, .af-cle .af-sym {
  position: relative; isolation: isolate; border: 0; background: transparent;
}
.af-carte::before, .af-quete::before, .af-tete-jeu::before, .af-onglets::before, .af-solde-hud::before, .af-modale::before, .af-jour::before, .af-compteurs div::before, .af-choix button::before, .af-choix label.af-opt::before, .af-bascule::before, .af-check::before, .af-picker::before, .af-emplacement::before, .af-cle .af-sym::before {
  content: ""; position: absolute; inset: 0; z-index: -2; background: var(--af-filet);
  clip-path: polygon(var(--af-chanfrein) 0, 100% 0, 100% calc(100% - var(--af-chanfrein)), calc(100% - var(--af-chanfrein)) 100%, 0 100%, 0 var(--af-chanfrein));
}
.af-carte::after, .af-quete::after, .af-tete-jeu::after, .af-onglets::after, .af-solde-hud::after, .af-modale::after, .af-jour::after, .af-compteurs div::after, .af-choix button::after, .af-choix label.af-opt::after, .af-bascule::after, .af-check::after, .af-picker::after, .af-emplacement::after, .af-cle .af-sym::after {
  content: ""; position: absolute; inset: 1px; z-index: -1; background: var(--af-carte);
  clip-path: polygon(calc(var(--af-chanfrein) - 1px) 0, 100% 0, 100% calc(100% - var(--af-chanfrein) + 1px), calc(100% - var(--af-chanfrein) + 1px) 100%, 0 100%, 0 calc(var(--af-chanfrein) - 1px));
}
.af-quete::after, .af-solde-hud::after, .af-jour::after, .af-compteurs div::after, .af-choix button::after, .af-choix label.af-opt::after, .af-bascule::after, .af-check::after, .af-picker::after, .af-emplacement::after, .af-cle .af-sym::after { background: var(--af-panneau); }
.af-solde-hud, .af-jour, .af-compteurs div, .af-choix button, .af-choix label.af-opt, .af-bascule, .af-check, .af-picker, .af-emplacement, .af-cle .af-sym { --af-chanfrein: var(--af-chanfrein-petit); }
/* le liseré d'accent, sur le bord gauche */
.af-en-cours::after { background: linear-gradient(90deg, var(--af-accent) 0 3px, var(--af-carte) 3px) !important; }
.af-carte.af-appel::after { background: linear-gradient(90deg, var(--af-accent) 0 3px, var(--af-carte) 3px); }
.af-carte.af-appel::before { background: var(--af-accent); }
.af-carte.af-or::before, .af-quete.af-accompli::before { background: var(--af-or); }
.af-quete.af-accompli::after { background: linear-gradient(90deg, var(--af-or) 0 3px, transparent 3px), linear-gradient(110deg, rgba(255, 255, 255, 0) 0 40%, rgba(255, 255, 255, .16) 50%, rgba(255, 255, 255, 0) 60%), linear-gradient(135deg, color-mix(in srgb, var(--af-or) 25%, var(--af-carte)) 0%, color-mix(in srgb, var(--af-or) 10%, var(--af-carte)) 100%); background-size: 100% 100%, 250% 100%, 100% 100%; background-repeat: no-repeat; animation: af-scintille 6s linear infinite; }
@keyframes af-scintille { 0% { background-position: 0 0, 120% 0, 0 0; } 100% { background-position: 0 0, -20% 0, 0 0; } }

/* ---------- la colonne ---------- */
.af-page { max-width: 600px; margin: 0 auto; padding: 0 16px calc(var(--af-onglets-h) + 28px); min-height: 100vh; position: relative; display: flex; flex-direction: column; }
.af-contenu { flex: 1; }
.af-contenu > section:first-child { margin-top: 2px; }
.af-titre-onglet { margin: 12px 0 14px; font-size: 22px; }
.af-pied { margin-top: 36px; padding-top: 14px; border-top: 1px solid var(--af-filet); font-size: 12.5px; color: var(--af-texte-3); }
@media (min-width: 700px) {
  .af-page { border-left: 1px solid var(--af-filet); border-right: 1px solid var(--af-filet); padding-bottom: 0; }
}

/* HUD : la barre chanfreinée, avatar hexagonal, prénom, classe, jeton et solde */
.af-tete-jeu { display: flex; align-items: center; gap: 12px; padding: 10px 12px; margin: 14px 0 10px; }
.af-avatar { width: 42px; height: 42px; flex: none; color: var(--af-texte-2); }
.af-avatar svg { width: 100%; height: 100%; display: block; }
.af-avatar text { font-family: var(--af-police-titre); font-weight: 600; font-size: 18px; fill: var(--af-encre); }
.af-tete-jeu .af-qui { flex: 1; min-width: 0; }
.af-tete-jeu .af-qui h1 { font-size: 20px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.af-tete-jeu .af-qui .af-sous { color: var(--af-texte-2); font-size: 12.5px; line-height: 1.25; margin-top: 1px; white-space: normal; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.af-tete-jeu .af-outils { display: flex; align-items: center; gap: 6px; flex: none; }
.af-solde-hud { display: inline-flex; align-items: center; gap: 7px; flex: none; white-space: nowrap; min-height: 40px; padding: 4px 12px 4px 10px; font-family: var(--af-police-chiffres); font-weight: 700; font-size: 20px; line-height: 1; transition: box-shadow .5s ease; }
.af-solde-hud .af-piece { width: 20px; height: 20px; flex: none; }
.af-solde-hud .af-plus { position: absolute; right: 6px; top: -12px; font-family: var(--af-police-chiffres); font-weight: 700; font-size: 18px; color: var(--af-or-texte); opacity: 0; pointer-events: none; }
.af-solde-hud::before { background: var(--af-or); }
.af-solde-hud::after { background: color-mix(in srgb, var(--af-or) 20%, var(--af-panneau)); }
.af-solde-hud { color: var(--af-encre); }
.af-solde-hud.af-gain { box-shadow: 0 0 0 1px var(--af-accent), 0 0 18px var(--af-halo); }
.af-solde-hud.af-gain::before { background: var(--af-accent); }
.af-solde-hud.af-gain .af-plus { animation: af-monte 1.2s ease-out forwards; }
@keyframes af-monte { 0% { opacity: 0; transform: translateY(6px); } 15% { opacity: 1; } 100% { opacity: 0; transform: translateY(-22px); } }
.af-icone-btn { width: 40px; height: 40px; border: 1px solid var(--af-filet-opaque); background: transparent; color: var(--af-encre); display: inline-flex; align-items: center; justify-content: center; flex: none; padding: 0; clip-path: polygon(var(--af-chanfrein-petit) 0, 100% 0, 100% calc(100% - var(--af-chanfrein-petit)), calc(100% - var(--af-chanfrein-petit)) 100%, 0 100%, 0 var(--af-chanfrein-petit)); }
.af-icone-btn svg { width: 18px; height: 18px; }
.af-icone-btn:hover { border-color: var(--af-accent); }
.af-date-hud { font-size: 13px; color: var(--af-texte-3); margin: 0 0 12px; font-family: var(--af-police-mono); }

/* onglets : la barre chanfreinée en bas, l'actif avec fond cyan à 15 % et liseré */
.af-onglets { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; height: var(--af-onglets-h); display: grid; grid-template-columns: repeat(var(--af-nt, 6), minmax(0, 1fr)); gap: 2px; padding: 4px 4px calc(4px + env(safe-area-inset-bottom)); }
.af-onglets::before { clip-path: none; }
.af-onglets::after { inset: 1px 0 0; clip-path: none; background: var(--af-carte); }
.af-onglets button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 44px; border: 0; background: transparent; color: var(--af-texte-2); font-family: var(--af-police-titre); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; line-height: 1.1; padding: 4px 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; clip-path: polygon(var(--af-chanfrein-petit) 0, 100% 0, 100% calc(100% - var(--af-chanfrein-petit)), calc(100% - var(--af-chanfrein-petit)) 100%, 0 100%, 0 var(--af-chanfrein-petit)); }
.af-onglets button svg { width: 20px; height: 20px; flex: none; }
.af-onglets button span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.af-onglets button[aria-selected="true"] { color: var(--af-accent-texte); background: linear-gradient(90deg, var(--af-accent) 0 3px, color-mix(in srgb, var(--af-accent) 15%, transparent) 3px); }
@media (min-width: 700px) {
  .af-onglets { position: sticky; bottom: 0; margin: 16px -16px 0; padding: 6px 8px; height: auto; }
  .af-onglets button { font-size: 12.5px; min-height: 48px; }
}

/* ---------- panneaux ---------- */
.af-carte { padding: 16px; margin: 0 0 16px; }
.af-carte > h2 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.af-nb { font-size: 13px; font-weight: 600; color: var(--af-encre); background: var(--af-panneau); border: 1px solid var(--af-filet-opaque); padding: 1px 7px; font-family: var(--af-police-chiffres); letter-spacing: .02em; }
.af-grand { font-family: var(--af-police-chiffres); font-size: 52px; font-weight: 700; line-height: .95; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.af-grand small { font-family: var(--af-police-chiffres); font-size: 20px; color: var(--af-texte-2); font-weight: 600; margin-left: 4px; letter-spacing: 0; }
.af-constat { border-left: 3px solid var(--af-accent); background: var(--af-panneau); padding: 10px 12px; margin: 12px 0 0; font-size: 14px; color: var(--af-texte-2); }
.af-info { border-left: 3px solid var(--af-accent); background: var(--af-panneau); padding: 10px 12px; margin: 0 0 12px; font-size: 14px; }
.af-alerte { border-left: 3px solid var(--af-corail); background: var(--af-corail-doux); padding: 10px 12px; margin: 0 0 12px; font-size: 14px; }
.af-citation { border-left: 3px solid var(--af-or); background: var(--af-panneau); padding: 10px 12px; font-weight: 500; margin: 12px 0; }
.af-rien { text-align: center; padding: 20px 8px; color: var(--af-texte-2); }
.af-demo-bandeau { background: var(--af-panneau); color: var(--af-texte-2); border: 1px solid var(--af-filet); border-top: 0; font-family: var(--af-police-titre); font-weight: 600; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; text-align: center; padding: 6px 12px; }

/* ---------- boutons ---------- */
.af-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 8px 18px; border: 1px solid transparent; font-family: var(--af-police-titre); font-weight: 600; font-size: 16px; text-transform: uppercase; letter-spacing: .06em; background: var(--af-accent); color: var(--af-accent-sur); text-decoration: none; text-align: center; transition: filter .15s, border-color .15s; clip-path: polygon(var(--af-chanfrein-petit) 0, 100% 0, 100% calc(100% - var(--af-chanfrein-petit)), calc(100% - var(--af-chanfrein-petit)) 100%, 0 100%, 0 var(--af-chanfrein-petit)); }
.af-btn:hover { filter: brightness(1.06); }
.af-btn.af-plein { width: 100%; }
.af-btn.af-gros { min-height: 52px; font-size: 18px; }
.af-btn.af-blanc { background: var(--af-panneau); border-color: var(--af-filet-opaque); color: var(--af-encre); }
.af-btn.af-blanc:hover { border-color: var(--af-accent); filter: none; }
.af-btn.af-corail { background: var(--af-corail); color: var(--af-corail-sur); }
.af-btn.af-teal { background: var(--af-accent); color: var(--af-accent-sur); }
.af-btn.af-soleil { background: var(--af-or); color: var(--af-or-encre); }
.af-btn.af-sm { min-height: 44px; padding: 6px 12px; font-size: 14px; }
.af-btn.af-lien { background: transparent; color: var(--af-texte-2); min-height: 44px; padding: 6px 8px; font-family: var(--af-police-texte); font-weight: 500; font-size: 13.5px; text-transform: none; letter-spacing: 0; clip-path: none; }
.af-btn.af-lien:hover { color: var(--af-accent-texte); filter: none; }
.af-form { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.af-form label { display: grid; gap: 6px; font-weight: 500; font-size: 13px; color: var(--af-texte-2); }
.af-form .af-remarque { font-size: 13px; color: var(--af-texte-3); }
.af-bascule { display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 4px; }
.af-bascule button { min-height: 40px; border: 1px solid transparent; background: transparent; color: var(--af-texte-2); font-family: var(--af-police-titre); font-weight: 600; font-size: 15px; text-transform: uppercase; letter-spacing: .06em; }
.af-bascule button[aria-pressed="true"] { background: linear-gradient(90deg, var(--af-accent) 0 3px, color-mix(in srgb, var(--af-accent) 15%, transparent) 3px); color: var(--af-encre); }

/* ---------- semaine : sept segments et balises ---------- */
.af-semaine { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; margin: 8px 0; }
.af-jour { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 60px; min-width: 0; padding: 4px 0; font-weight: 500; }
.af-jour .af-n { font-family: var(--af-police-titre); font-size: 13px; color: var(--af-texte-3); text-transform: uppercase; letter-spacing: .06em; }
.af-jour .af-d { font-family: var(--af-police-chiffres); font-size: 15px; color: var(--af-texte-2); font-weight: 600; line-height: 1; }
.af-jour .af-s { font-size: 18px; line-height: 1; min-height: 20px; }
.af-jour.V { color: var(--af-accent-sur); }
.af-jour.V::before { background: var(--af-accent); }
.af-jour.V::after { background: var(--af-accent); }
.af-jour.V .af-d, .af-jour.V .af-n { color: var(--af-accent-sur); }
.af-jour.X { color: var(--af-texte-2); }
.af-jour.af-auj::before { background: var(--af-accent); }
.af-jour.af-auj::after { background: linear-gradient(90deg, var(--af-accent) 0 3px, var(--af-panneau) 3px); }
.af-jour.V.af-auj::after { background: var(--af-accent); }
.af-jour.af-futur { opacity: .5; }
.af-jour.af-hors { visibility: hidden; }
.af-jour.q { color: var(--af-alerte-texte); } .af-jour.q::before { background: var(--af-alerte); }
.af-jour.af-neuf::before { background: var(--af-accent); }
.af-jour.af-conflit::before { background: var(--af-alerte); }
.af-jour.af-ignore { opacity: .4; }
.af-segments7 { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin: 22px 0 6px; position: relative; }
.af-segments7 i { display: block; height: 12px; background: var(--af-fond-2); border: 1px solid var(--af-filet-opaque); clip-path: polygon(4px 0, 100% 0, 100% calc(100% - 4px), calc(100% - 4px) 100%, 0 100%, 0 4px); transform-origin: left center; }
.af-segments7 i.af-allume { background: var(--af-accent); border-color: var(--af-accent); animation: af-remplir .4s ease-out; }
.af-segments7.af-atteint i.af-allume { background: var(--af-or); border-color: var(--af-or); }
.af-segments7 .af-repere { position: absolute; top: -6px; bottom: -6px; width: 2px; background: var(--af-texte-3); transform: translateX(-50%); }
.af-segments7 .af-repere::after { content: attr(data-l); position: absolute; top: -18px; left: 50%; transform: translateX(-50%); font-family: var(--af-police-titre); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--af-texte-3); white-space: nowrap; }
.af-segments7.af-atteint .af-repere { background: var(--af-or); }
.af-segments7.af-atteint .af-repere::after { color: var(--af-or-texte); }
.af-barre-semaine-legende { display: flex; justify-content: space-between; font-size: 13px; color: var(--af-texte-3); font-family: var(--af-police-chiffres); font-weight: 600; }
@keyframes af-remplir { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.af-wk { border-top: 1px solid var(--af-filet); padding: 12px 0; }
.af-wk:first-of-type { border-top: 0; padding-top: 0; }
.af-wk-tete { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.af-wk-tete .af-tot { font-family: var(--af-police-chiffres); font-weight: 700; font-size: 20px; }
.af-courbe svg { display: block; width: 100%; height: auto; }

/* ---------- fichier de suivi ---------- */
.af-etiq { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 500; padding: 2px 7px; max-width: 100%; text-align: left; line-height: 1.4; border: 1px solid transparent; }
.af-etiq.af-solide { color: var(--af-or-texte); background: var(--af-or-doux); border-color: var(--af-contour-or); }
.af-etiq.af-progres { color: var(--af-accent-texte); background: var(--af-accent-doux); border-color: var(--af-contour-accent); }
.af-etiq.af-cours { color: var(--af-texte-2); background: var(--af-panneau); border-color: var(--af-filet-opaque); }
.af-etiq.af-fragile { color: var(--af-alerte-texte); background: var(--af-alerte-doux); border-color: var(--af-contour-alerte); }
.af-marque { display: inline-flex; align-items: center; justify-content: center; min-width: 32px; height: 28px; padding: 0 6px; font-weight: 700; font-size: 14px; font-family: var(--af-police-mono); border: 1px solid transparent; }
.af-marque.VV { background: var(--af-accent-doux); color: var(--af-accent-texte); border-color: var(--af-accent); }
.af-marque.V { background: var(--af-panneau); color: var(--af-encre); border-color: var(--af-filet-opaque); }
.af-marque.T { background: var(--af-panneau); color: var(--af-alerte-texte); border-color: var(--af-filet-opaque); }
.af-marque.X { background: var(--af-alerte-doux); color: var(--af-alerte-texte); border-color: var(--af-alerte); }
.af-marque.Q { background: var(--af-alerte-doux); color: var(--af-alerte-texte); border-color: var(--af-alerte); }
.af-marque.af-restant { border: 1px dashed var(--af-filet-opaque); background: transparent; color: var(--af-texte-3); font-weight: 500; }
.af-marque.af-neuve { box-shadow: 0 0 0 2px var(--af-accent); }
.af-marque.af-plus { background: transparent; border: 1px dashed var(--af-texte-3); color: var(--af-texte-2); min-height: 28px; }
.af-marque.af-sel { outline: 2px solid var(--af-accent); outline-offset: 1px; }
.af-cercle { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 34px; padding: 0 8px; border: 1.5px solid var(--af-accent); font-family: var(--af-police-chiffres); font-weight: 700; font-size: 16px; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; flex: none; clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px); }
.af-exo-mission { border-top: 1px solid var(--af-filet); padding: 12px 0; }
.af-exo-mission:first-of-type { border-top: 0; }
.af-exo-mission .af-exo-mission-tete { display: flex; align-items: center; gap: 10px; }
.af-exo-mission .af-f { font-size: 13px; color: var(--af-texte-3); font-family: var(--af-police-chiffres); font-weight: 600; }
.af-exo-mission.af-solide { padding-left: 10px; border-left: 3px solid transparent; border-image: var(--af-palier-prisme) 1; }
.af-exo-mission.af-solide .af-cercle { border-color: var(--af-or); color: var(--af-or-texte); }
.af-emplacements { display: flex; align-items: center; gap: 6px; margin: 10px 0 6px; }
.af-emplacement { width: 42px; height: 28px; display: inline-flex; align-items: center; justify-content: center; font-family: var(--af-police-mono); font-weight: 700; font-size: 13px; color: var(--af-texte-3); }
.af-emplacement::before { background: var(--af-filet-opaque); }
.af-emplacement.af-plein { color: var(--af-accent-texte); }
.af-emplacement.af-plein::before { background: var(--af-accent); } .af-emplacement.af-plein::after { background: var(--af-accent-doux); }
.af-emplacement.af-casse { color: var(--af-alerte-texte); }
.af-emplacement.af-casse::before { background: var(--af-alerte); } .af-emplacement.af-casse::after { background: var(--af-alerte-doux); }
.af-exo-mission.af-solide .af-emplacement.af-plein { color: var(--af-or-texte); }
.af-exo-mission.af-solide .af-emplacement.af-plein::before { background: var(--af-or); } .af-exo-mission.af-solide .af-emplacement.af-plein::after { background: var(--af-or-doux); }
.af-trophee { width: 22px; height: 22px; flex: none; margin-left: auto; color: var(--af-or-texte); }
.af-marques { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 8px; }
.af-marques > span { display: inline-flex; flex-direction: column; align-items: center; gap: 2px; }
.af-marques .af-d { font-size: 12px; color: var(--af-texte-3); white-space: nowrap; font-family: var(--af-police-mono); }
.af-marques.af-historique .af-marque { min-width: 28px; height: 24px; font-size: 12px; }
.af-cle .af-it { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-top: 1px solid var(--af-filet); }
.af-cle .af-it:first-child { border-top: 0; }
.af-cle .af-sym { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; font-weight: 700; font-size: 16px; flex: none; font-family: var(--af-police-mono); }
.af-cle .af-sym.V { color: var(--af-accent-sur); } .af-cle .af-sym.V::before, .af-cle .af-sym.V::after { background: var(--af-accent); }
.af-cle .af-sym.X { color: var(--af-texte-2); }
.af-regles { padding-left: 20px; margin: 0; }
.af-regles li { margin-bottom: 8px; }
.af-rangee { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--af-filet); flex-wrap: wrap; }
.af-rangee:first-of-type { border-top: 0; }
.af-rangee .af-corps { flex: 1; min-width: 140px; }
.af-rangee .af-sur { font-family: var(--af-police-titre); font-size: 13px; color: var(--af-texte-3); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; }
.af-rangee .af-st { font-size: 13.5px; }
.af-compteurs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 8px 0 4px; }
.af-compteurs div { text-align: center; padding: 10px 4px; font-family: var(--af-police-chiffres); font-weight: 700; font-size: 30px; line-height: 1; }
.af-compteurs div small { display: block; font-family: var(--af-police-texte); color: var(--af-texte-2); font-weight: 400; font-size: 12px; line-height: 1.2; margin-top: 4px; }

/* ce soir : le cadre autour de la liste à revoir, et la coche qui s'anime */
.af-missions-tete { display: flex; align-items: center; gap: 8px; margin: 22px 0 10px; }
.af-missions-tete h2 { font-size: 15px; }
.af-missions input[type="checkbox"] { accent-color: var(--af-accent); outline: 1px solid var(--af-filet-opaque); outline-offset: -1px; }
.af-missions input[type="checkbox"]:checked { animation: af-coche .3s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes af-coche { 0% { transform: scale(.7); } 60% { transform: scale(1.2); } 100% { transform: scale(1); } }

/* ---------- photo ---------- */
.af-choix { display: grid; gap: 8px; }
.af-choix button, .af-choix label.af-opt { display: flex; align-items: center; gap: 12px; text-align: left; min-height: 48px; padding: 8px 12px; font-weight: 500; font-size: 14px; cursor: pointer; }
.af-choix .af-on::before { background: var(--af-accent); }
.af-choix .af-on::after { background: linear-gradient(90deg, var(--af-accent) 0 3px, var(--af-panneau) 3px); }
.af-choix button .af-marque { flex: none; }
.af-choix input[type=radio] { width: 20px; height: 20px; min-height: 0; margin: 0; flex: none; accent-color: var(--af-accent); }
label.af-btn { cursor: pointer; }
input.af-fichier { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.af-apercu { display: block; max-width: 100%; max-height: 220px; margin: 0 auto 12px; border: 1px solid var(--af-filet-opaque); }
.af-attente { width: 32px; height: 32px; border-radius: 50%; border: 3px solid var(--af-filet-opaque); border-top-color: var(--af-accent); animation: af-tourne .9s linear infinite; margin: 18px auto; }
@keyframes af-tourne { to { transform: rotate(360deg); } }
.af-lu { border-top: 1px solid var(--af-filet); padding: 10px 0; }
.af-lu:first-of-type { border-top: 0; }
.af-lu .af-etat { font-size: 12.5px; font-weight: 500; margin-top: 4px; }
.af-lu .af-etat.af-conflit, .af-lu .af-etat.af-illisible { color: var(--af-alerte-texte); }
.af-lu .af-etat.af-ajout, .af-lu .af-etat.af-nouveau { color: var(--af-accent-texte); }
.af-lu .af-etat.af-neutre { color: var(--af-texte-3); }
.af-picker { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; padding: 8px; }
.af-picker button { min-height: 44px; }
.af-rit { display: grid; grid-template-columns: 88px repeat(7, minmax(0, 1fr)); gap: 4px; align-items: center; margin: 4px 0; }
.af-rit .af-lab { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.af-rit .af-hd { font-family: var(--af-police-titre); font-size: 12px; color: var(--af-texte-3); text-align: center; text-transform: uppercase; letter-spacing: .06em; }
.af-cell { min-height: 44px; border: 1px solid var(--af-filet-opaque); background: var(--af-panneau); font-weight: 700; font-size: 16px; display: flex; align-items: center; justify-content: center; min-width: 0; padding: 0; }
.af-cell.V { background: var(--af-accent); border-color: var(--af-accent); color: var(--af-accent-sur); }
.af-cell.q { border-color: var(--af-alerte); color: var(--af-alerte-texte); }
.af-cell.af-neuf { box-shadow: 0 0 0 2px var(--af-accent); }

/* ---------- pièces et objectifs ---------- */
.af-solde { display: flex; align-items: center; gap: 14px; }
.af-carte.af-solde-or, .af-carte.af-solde-or .af-muet, .af-carte.af-solde-or .af-grand small { color: var(--af-or-sur); }
.af-carte.af-solde-or::before { background: var(--af-or-profond); }
.af-carte.af-solde-or::after { background: linear-gradient(115deg, rgba(255, 255, 255, 0) 0 38%, rgba(255, 255, 255, .22) 46%, rgba(255, 255, 255, 0) 54%), linear-gradient(135deg, var(--af-or-profond) 0%, var(--af-or-clair) 100%); }
.af-carte.af-solde-or .af-piece { filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .25)); }
.af-solde .af-piece { width: 48px; height: 48px; flex: none; }
.af-quete { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; margin: 0 0 8px; }
.af-quete .af-corps { flex: 1; min-width: 0; }
.af-quete .af-titre { font-family: var(--af-police-texte); font-weight: 600; font-size: 15px; }
.af-quete .af-delai { font-size: 14px; color: var(--af-texte-2); margin-top: 2px; font-family: var(--af-police-chiffres); font-weight: 600; }
.af-quete .af-delai.af-urgent { color: var(--af-alerte-texte); }
.af-quete .af-recompense { flex: none; display: inline-flex; align-items: center; gap: 5px; min-width: 56px; height: 30px; padding: 0 10px; background: var(--af-or); color: var(--af-or-encre); font-family: var(--af-police-chiffres); font-weight: 700; font-size: 16px; clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px); }
.af-quete .af-recompense .af-piece { width: 16px; height: 16px; }
.af-quete.af-accompli .af-delai { color: var(--af-or-texte); }
.af-progression { position: relative; height: 8px; background: var(--af-fond-2); border: 1px solid var(--af-filet-opaque); margin-top: 8px; overflow: hidden; }
.af-progression i, .af-barre-semaine .af-remplie { display: block; height: 100%; background: repeating-linear-gradient(135deg, rgba(255, 255, 255, .2) 0 4px, transparent 4px 8px), var(--af-accent); transform-origin: left center; animation: af-remplir .4s ease-out; }
.af-progression-l { font-family: var(--af-police-chiffres); font-size: 14px; font-weight: 600; color: var(--af-texte-2); margin-top: 4px; }
.af-gain { display: flex; align-items: flex-start; gap: 10px; padding: 9px 0; border-top: 1px solid var(--af-filet); }
.af-gain:first-of-type { border-top: 0; }
.af-gain .af-date { font-family: var(--af-police-mono); font-size: 13px; color: var(--af-texte-3); white-space: nowrap; min-width: 46px; padding-top: 2px; }
.af-gain .af-cause { flex: 1; font-size: 14px; }
.af-gain .af-val { font-family: var(--af-police-chiffres); font-weight: 700; font-size: 17px; color: var(--af-or-texte); white-space: nowrap; }

/* ---------- récompenses et rappels ---------- */
.af-recomp .af-delai.af-or-t { color: var(--af-or-texte); }
.af-interrupteur { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 8px 12px; border: 1px solid var(--af-filet-opaque); background: var(--af-panneau); cursor: pointer; font-weight: 600; margin-top: 12px; }
.af-interrupteur input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.af-interrupteur i { position: relative; width: 44px; height: 24px; flex: none; background: var(--af-fond-2); border: 1px solid var(--af-filet-opaque); transition: background .2s; }
.af-interrupteur i::after { content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; background: var(--af-texte-2); transition: transform .2s, background .2s; }
.af-interrupteur.af-on i { background: var(--af-accent); border-color: var(--af-accent); }
.af-interrupteur.af-on i::after { transform: translateX(20px); background: var(--af-accent-sur); }
.af-interrupteur input:disabled ~ i { opacity: .45; }
.af-interrupteur input:focus-visible ~ i { outline: 2px solid var(--af-accent); outline-offset: 2px; }

/* ---------- modale, toast ---------- */
.af-modale-fond { position: fixed; inset: 0; background: rgba(6, 8, 14, .66); display: none; align-items: flex-end; justify-content: center; z-index: 50; padding: 0; }
.af-modale-fond.af-ouverte { display: flex; }
.af-modale { color: var(--af-encre); width: 100%; max-width: 600px; max-height: 92vh; overflow: auto; padding: 18px 16px 28px; }
.af-modale::before { clip-path: polygon(var(--af-chanfrein) 0, 100% 0, 100% 100%, 0 100%, 0 var(--af-chanfrein)); }
.af-modale::after { clip-path: polygon(calc(var(--af-chanfrein) - 1px) 0, 100% 0, 100% 100%, 0 100%, 0 calc(var(--af-chanfrein) - 1px)); }
@media (min-width: 700px) { .af-modale-fond { align-items: center; padding: 16px; } }
.af-modale h3 { margin-bottom: 10px; font-size: 16px; }
.af-check { display: flex; gap: 12px; align-items: flex-start; padding: 12px; cursor: pointer; margin-bottom: 12px; }
.af-check.af-ok::before { background: var(--af-accent); } .af-check.af-ok::after { background: var(--af-accent-doux); }
.af-check input { width: 22px; height: 22px; min-height: 0; margin: 2px 0 0; flex: none; accent-color: var(--af-accent); }
.af-fermer { position: sticky; top: 0; float: right; background: var(--af-panneau); border: 1px solid var(--af-filet-opaque); width: 40px; height: 40px; font-size: 18px; font-weight: 500; z-index: 1; }
.af-toast { position: fixed; left: 50%; bottom: calc(var(--af-onglets-h) + 14px); transform: translateX(-50%); background: var(--af-encre); color: var(--af-fond); padding: 10px 14px; font-weight: 500; font-size: 13.5px; max-width: calc(100% - 32px); z-index: 60; display: none; box-shadow: var(--af-ombre-haute); clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px); }
.af-toast.af-visible { display: block; }
@media (min-width: 700px) { .af-toast { bottom: 20px; } }

/* ---------- connexion ---------- */
.af-connexion { max-width: 440px; margin: 0 auto; padding: 28px 16px 40px; min-height: 100vh; display: flex; flex-direction: column; }
@media (min-width: 700px) { .af-connexion { border-left: 1px solid var(--af-filet); border-right: 1px solid var(--af-filet); padding: 32px 28px 36px; } }
.af-connexion .af-logo { display: flex; align-items: center; gap: 10px; font-family: var(--af-police-titre); font-weight: 600; font-size: 20px; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 24px; }
.af-connexion .af-logo svg { width: 30px; height: 30px; }
.af-connexion .af-logo .af-espace { flex: 1; }
.af-connexion h1 { font-size: 24px; margin-bottom: 6px; }
.af-connexion .af-lede { color: var(--af-texte-2); margin-bottom: 18px; font-size: 14px; }
.af-connexion .af-pied { margin-top: auto; }

/* ---------- mouvement ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .af-attente { border-top-color: var(--af-filet-opaque); }
  .af-quete.af-accompli::after { animation: none; background-position: 0 0, 200% 0, 0 0; }
}

/* ---- le modèle d'apprenant (27/09/2026) : confiance avant une question, fiche de joueur, mode d'emploi ---- */
.af-conf { margin-top: 8px; }
.af-conf-q { margin: 6px 0; font-weight: 600; }
.af-conf-dit, .af-conf-bilan { margin: 6px 0; font-size: 14px; color: var(--af-texte-2); }
.af-conf-bilan { color: var(--af-encre); border-left: 3px solid var(--af-accent); padding: 6px 10px; background: var(--af-panneau); }
.af-conf-btns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.af-conf-res { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.af-conf-btn { min-height: 52px; padding: 8px 4px; font-size: 14px; letter-spacing: .02em; line-height: 1.15; overflow-wrap: normal; word-break: keep-all; hyphens: manual; }
.af-joueur-nom { font-family: var(--af-police-titre); font-weight: 700; font-size: 30px; letter-spacing: .04em; text-transform: uppercase; margin: 4px 0 2px; color: var(--af-accent-texte); }
.af-joueur-props { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 6px; }
.af-joueur-form { display: flex; gap: 8px; margin-top: 10px; }
.af-joueur-form input { flex: 1; min-width: 0; min-height: 44px; padding: 6px 10px; border: 1px solid var(--af-filet-opaque); background: var(--af-panneau); color: var(--af-encre); font: inherit; }
.af-dim { padding: 10px 0; border-top: 1px solid var(--af-filet); }
.af-dim:first-of-type { border-top: 0; }
.af-dim-tete { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.af-dim-titre { font-weight: 600; }
.af-dim-compte { font-family: var(--af-police-chiffres); font-size: 18px; font-weight: 600; }
.af-dim-off .af-dim-titre { color: var(--af-texte-2); }
.af-dim-barre { height: 8px; background: var(--af-creux); margin: 6px 0; overflow: hidden; }
.af-dim-barre span { display: block; height: 100%; background: var(--af-accent); }
.af-dim-geste { margin: 4px 0 0; font-size: 14px; color: var(--af-texte-2); }
.af-dim-tend, .af-tend { font-weight: 700; }
.af-t-monte { color: var(--af-accent-texte); } .af-t-descend { color: var(--af-alerte-texte); } .af-t-stable { color: var(--af-texte-2); }
.af-cal li { margin-bottom: 6px; }

/* ---- « En savoir plus » et « Un exemple » (27/09/2026, décision (77)) ---- */
.af-plus { margin-top: 6px; border-left: 2px solid var(--af-filet); padding-left: 10px; }
.af-plus > summary { cursor: pointer; min-height: 36px; display: flex; align-items: center; font-size: 14px; font-weight: 600; color: var(--af-accent-texte); list-style: none; }
.af-plus > summary::-webkit-details-marker { display: none; }
.af-plus > summary::before { content: "+"; display: inline-block; width: 18px; font-family: var(--af-police-chiffres); font-weight: 700; }
.af-plus[open] > summary::before { content: "−"; }
.af-plus-geste { border-left-color: var(--af-accent); }
.af-moments-tete { margin: 8px 0 4px; font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--af-texte-2); }
.af-moments { list-style: none; padding: 0; margin: 0 0 4px; }
.af-moment { display: flex; gap: 6px; align-items: baseline; font-size: 14px; line-height: 1.45; margin: 0 0 6px; }
.af-moment-sig { flex: none; width: 16px; font-family: var(--af-police-chiffres); font-weight: 700; }
.af-moment-plus .af-moment-sig { color: var(--af-accent-texte); }
.af-moment-moins .af-moment-sig { color: var(--af-alerte-texte); }
.af-moment-date { flex: none; font-family: var(--af-police-chiffres); color: var(--af-texte-2); }

/* ---- les paliers des barres (27/09/2026, décision (78)) ---- */
.af-dim-jauge { position: relative; margin: 6px 0; }
.af-dim-jauge .af-dim-barre { margin: 0; }
.af-repere { position: absolute; top: -3px; width: 3px; height: 14px; margin-left: -1px; background: var(--af-encre); opacity: .55; }
.af-repere-ok { background: var(--af-or); opacity: 1; }
.af-palier-ligne { margin: 4px 0 0; font-size: 13px; color: var(--af-texte-2); }

/* ---- La fiche « À revoir » à imprimer (27/09/2026, décision (80)) ---- */
.afi-liste { max-height: 50vh; overflow-y: auto; margin: 10px 0 0; border: 1px solid var(--af-filet); padding: 4px 8px; }
.afi-choix { display: flex; gap: 10px; align-items: flex-start; min-height: 44px; padding: 6px 0; border-bottom: 1px solid var(--af-filet); font-size: 14px; }
.afi-choix:last-child { border-bottom: 0; }
.afi-choix input { width: 22px; height: 22px; flex: none; margin-top: 1px; accent-color: var(--af-accent); }
.afi-tout { gap: 8px; margin-top: 8px; }
.afi-bouton-jour { margin: 4px 0 16px; }
#af-impression { display: none; }
@media print {
  @page { size: A4; margin: 12mm 12mm 14mm; }
  html, body { background: #fff !important; color: #000 !important; }
  body > *:not(#af-impression) { display: none !important; }
  #af-impression { display: block !important; }
}
.afi { font-family: "Inter", "Segoe UI", Arial, sans-serif; color: #000; background: #fff; font-size: 10.5pt; line-height: 1.4; }
.afi-tete { display: flex; justify-content: space-between; align-items: baseline; border-bottom: 1.5pt solid #000; padding-bottom: 4pt; margin-bottom: 6pt; }
.afi-titre { font-size: 16pt; font-weight: 700; letter-spacing: .02em; }
.afi-qui { font-size: 10pt; }
.afi-mode { border: 1pt solid #000; padding: 6pt 8pt; margin-bottom: 10pt; font-size: 9.5pt; }
.afi-mode p { margin: 0 0 4pt; }
.afi-mode p:last-child { margin: 0; }
.afi-legende { display: flex; flex-wrap: wrap; gap: 4pt 14pt; }
.afi-exo { border-bottom: .75pt solid #888; padding: 7pt 0; break-inside: avoid; page-break-inside: avoid; }
.afi-ligne-marques { display: flex; align-items: center; gap: 5pt; }
.afi-num { display: inline-flex; align-items: center; justify-content: center; min-width: 30pt; height: 22pt; padding: 0 5pt; border: 1.5pt solid #000; border-radius: 50%; font-weight: 700; font-size: 11pt; margin-right: 6pt; }
.afi-case { display: inline-flex; align-items: center; justify-content: center; width: 22pt; height: 18pt; border: .75pt solid #000; font-size: 10pt; }
.afi-deja { background: #e6e6e6; color: #333; }
.afi-sujet { font-weight: 600; margin: 5pt 0 2pt; }
.afi-enonce { font-size: 10pt; }
.afi-libre { color: #555; font-style: italic; }
.afi-pied { margin-top: 10pt; font-size: 8.5pt; color: #333; }
.afi-reponses { break-before: page; page-break-before: always; }
.afi-petit { font-size: 9pt; margin: 2pt 0 6pt; }
.afi-rep { list-style: none; padding-left: 0; font-size: 10pt; }
.afi-rep li { margin: 0 0 4pt; }
.afi-num-petit { display: inline-block; min-width: 24pt; font-weight: 700; }

/* ---------- ordinateur et grande tablette (28/09/2026) ----------
   L'élève qui a rangé son téléphone fait ses devoirs sur l'ordinateur ou la tablette de la maison : à partir de
   1024 px, les onglets passent en colonne à gauche (collée en haut au défilement), l'en-tête et le contenu à
   droite, la colonne de lecture s'élargit sans devenir une ligne de 1 000 px. Sous 1024 px, rien ne change. */
@media screen and (min-width: 1024px) {
  .af-page {
    max-width: 1120px; padding: 0 32px 48px; border-left: 0; border-right: 0;
    display: grid; grid-template-columns: 236px minmax(0, 1fr); column-gap: 36px; align-items: start;
    grid-template-areas: "nav hud" "nav bandeau" "nav contenu";
  }
  .af-tete-jeu-zone { grid-area: hud; }
  .af-bandeau { grid-area: bandeau; }
  .af-contenu { grid-area: contenu; max-width: 820px; width: 100%; }
  .af-onglets {
    grid-area: nav; position: sticky; top: 20px; bottom: auto; margin: 20px 0 0; padding: 10px; height: auto;
    display: flex; flex-direction: column; gap: 4px;
  }
  .af-onglets::after { inset: 1px; }
  .af-onglets button {
    flex-direction: row; justify-content: flex-start; gap: 12px; min-height: 48px; padding: 8px 14px;
    font-size: 15px; letter-spacing: .08em; text-align: left;
  }
  .af-onglets button svg { width: 22px; height: 22px; }
  .af-onglets button:hover:not([aria-selected="true"]) { color: var(--af-encre); background: color-mix(in srgb, var(--af-accent) 8%, transparent); }
  .af-tete-jeu { margin-top: 20px; padding: 12px 16px; }
  .af-tete-jeu .af-qui h1 { font-size: 24px; }
  .af-titre-onglet { font-size: 26px; margin-top: 16px; }
  .af-carte { padding: 20px 22px; }
  .af-modale { max-width: 680px; }
}
