/* weshlia.com : les couleurs et les polices des vidéos (src/Episode.tsx), un seul thème sombre, voulu. */
@font-face { font-family: Anton; src: url(/f/anton.woff2) format('woff2'); font-display: swap; }
@font-face { font-family: Montserrat; src: url(/f/montserrat.woff2) format('woff2'); font-weight: 100 900; font-display: swap; }

:root {
  color-scheme: dark;
  --fond: #12052e; --violet: #8b3dff; --nuit: #1a0540; --carte: #200b4d; --trait: #3a1d82;
  --texte: #f4f0ff; --doux: #b9aedb; --jaune: #ffd60a; --cyan: #5ce1ff; --vert: #2dbe4c; --rouge: #ff5a5a; --encre: #111;
  --titre: Anton, 'Arial Narrow', Impact, sans-serif; --corps: Montserrat, 'Segoe UI', Roboto, Arial, sans-serif;
  --ombre: 0 7px 0 rgba(0, 0, 0, .38);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--fond) radial-gradient(120% 60% at 50% -10%, #3b148f 0%, transparent 70%) no-repeat;
  color: var(--texte); font: 500 17px/1.6 var(--corps);
  padding: env(safe-area-inset-top, 0) max(16px, env(safe-area-inset-right, 0px)) env(safe-area-inset-bottom, 0) max(16px, env(safe-area-inset-left, 0px));
}
a { color: var(--cyan); }
img, video { max-width: 100%; display: block; }
h1, h2, h3 { font-family: var(--titre); font-weight: 400; text-transform: uppercase; letter-spacing: .01em; line-height: 1.05; text-wrap: balance; margin: 0; }
h1 { font-size: clamp(2.2rem, 9vw, 3.4rem); }
h2 { font-size: 1.55rem; color: var(--jaune); }
h3 { font-size: 1.15rem; }
b, strong { font-weight: 800; }

.barre { max-width: 1040px; margin: 0 auto; padding-block: 18px 6px; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.logo { font: 400 1.9rem/1 var(--titre); color: var(--texte); text-decoration: none; letter-spacing: .02em; }
.logo span { color: var(--jaune); }
.devise { color: var(--doux); font-size: .85rem; font-weight: 700; }

main { max-width: 640px; margin: 0 auto; padding-block: 18px 40px; display: flex; flex-direction: column; gap: 26px; }
main.accueil { max-width: 1040px; }

/* Accueil */
.une { display: flex; flex-direction: column; gap: 12px; padding-block: 18px 4px; }
.une h1 em { font-style: normal; color: var(--jaune); display: block; }
.une p { margin: 0; color: var(--doux); max-width: 34em; }
.progression { background: var(--carte); border: 3px solid var(--trait); border-radius: 20px; padding: 14px 18px; box-shadow: var(--ombre); }
.progression p { margin: 8px 0 0; font-size: .95rem; }
progress { appearance: none; width: 100%; height: 14px; border: 0; border-radius: 9px; background: var(--nuit); overflow: hidden; }
progress::-webkit-progress-bar { background: var(--nuit); }
progress::-webkit-progress-value { background: var(--jaune); border-radius: 9px; }
progress::-moz-progress-bar { background: var(--jaune); border-radius: 9px; }
.saison { color: var(--texte); font-size: 1.9rem; }
.saison span { color: var(--jaune); }
.cartes { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.carte { position: relative; display: flex; flex-direction: column; gap: 4px; color: var(--texte); text-decoration: none; min-width: 0; }
.carte img { width: 100%; height: auto; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 18px; border: 3px solid var(--trait); box-shadow: var(--ombre); background: var(--nuit); }
.carte:hover img, .carte:focus-visible img { border-color: var(--jaune); }
.carte .num { margin-top: 6px; font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--doux); }
.carte .titre { font-weight: 800; line-height: 1.25; }
.etat { align-self: flex-start; margin-top: 4px; font-size: .72rem; font-weight: 900; text-transform: uppercase; letter-spacing: .04em;
  background: var(--nuit); color: var(--texte); border: 2px solid var(--trait); border-radius: 20px; padding: 3px 9px; }
.etat.ok { background: var(--vert); border-color: #0d5e22; color: #fff; }
.bientot { color: var(--doux); font-weight: 700; text-align: center; margin: 0; }

/* Épisode */
.fil { margin: 0; font-size: .85rem; font-weight: 700; color: var(--doux); }
.fil a { color: var(--doux); }
.video { display: flex; justify-content: center; }
.video video { width: auto; max-height: 78vh; aspect-ratio: 9 / 16; border-radius: 22px; border: 3px solid #000; box-shadow: var(--ombre); background: #000; }
.recap { margin: 0; font-size: 1.12rem; font-weight: 700; }
section { display: flex; flex-direction: column; gap: 10px; }
section p { margin: 0; }
.regle { background: var(--jaune); color: var(--encre); border-radius: 22px; padding: 18px 20px; box-shadow: var(--ombre); }
.regle h2 { color: var(--encre); font-size: 1.1rem; }
.regle p { font: 400 1.7rem/1.1 var(--titre); text-transform: uppercase; }
.mots { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.mot { background: var(--carte); border: 3px solid var(--trait); border-radius: 18px; padding: 12px 16px; }
.mot dt { font-weight: 900; text-transform: uppercase; color: var(--cyan); letter-spacing: .02em; }
.mot dd { margin: 2px 0 0; }
.cours { gap: 14px; }
.exemple { background: var(--carte); border-left: 6px solid var(--cyan); border-radius: 0 18px 18px 0; padding: 12px 16px; display: flex; flex-direction: column; gap: 4px; }
.exemple h3 { color: var(--cyan); }
.piege p { font-weight: 800; font-size: 1.1rem; }
.piege s { color: var(--rouge); text-decoration-thickness: 3px; }
.piege b { color: var(--vert); }
.quiz { background: #fff; color: var(--encre); border-radius: 24px; padding: 18px; box-shadow: var(--ombre); }
.quiz h2 { color: #5b21d6; }
.question { font-weight: 800; font-size: 1.1rem; }
.quiz form { display: flex; flex-direction: column; gap: 10px; }
.choix { font: 800 1rem/1.3 var(--corps); text-align: left; display: flex; align-items: center; gap: 12px; width: 100%;
  background: #f1ecff; color: var(--encre); border: 3px solid #2a1065; border-radius: 16px; padding: 12px 14px; cursor: pointer; }
.choix b { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: #5b21d6; color: #fff; font: 400 1rem var(--titre); }
.choix:hover:not(:disabled), .choix:focus-visible { background: #fff6c2; }
.choix:disabled { cursor: default; opacity: .75; }
.choix.bonne { background: #dcf7e3; border-color: var(--vert); opacity: 1; }
.choix.bonne b { background: var(--vert); }
.choix.fausse { background: #ffe1e1; border-color: var(--rouge); text-decoration: line-through; }
.choix.fausse b { background: var(--rouge); }
.verdict { font-weight: 800; border-radius: 14px; padding: 10px 14px; margin: 0; }
.verdict.ok { background: var(--vert); color: #fff; }
.verdict.ko { background: var(--rouge); color: #fff; }
.retenir ul { margin: 0; padding-left: 1.2em; display: flex; flex-direction: column; gap: 6px; font-weight: 700; }
.retenir li::marker { color: var(--jaune); }
.astuce { color: var(--doux); font-size: .92rem; }
.suite { display: flex; justify-content: space-between; align-items: stretch; gap: 12px; flex-wrap: wrap; }
.prec { align-self: center; font-weight: 800; }
.suiv { flex: 1 1 260px; display: flex; flex-direction: column; background: var(--jaune); color: var(--encre); text-decoration: none; font-weight: 900;
  border-radius: 18px; padding: 12px 18px; box-shadow: var(--ombre); }
.suiv small { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; }

/* Pages de texte */
.texte ul { margin: 0; padding-left: 1.2em; }
.texte form .choix { width: auto; background: var(--rouge); color: #fff; border-color: #7a1a1a; }

.pied { max-width: 1040px; margin: 0 auto; padding-block: 20px 34px; text-align: center; font-size: .85rem; color: var(--doux); border-top: 1px solid var(--trait); }
.pied a { color: var(--doux); }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; }

/* Code perso : retrouver sa progression ailleurs */
.progression .code { margin: 10px 0 0; font-size: .92rem; color: var(--doux); }
.progression .code b { color: var(--jaune); font: 400 1.25rem/1.4 var(--titre); letter-spacing: .06em; }
.progression .verdict { margin-top: 10px; }
.progression details { margin-top: 10px; font-size: .92rem; }
.progression summary { cursor: pointer; color: var(--cyan); font-weight: 700; }
.reprendre { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.reprendre input { flex: 1 1 180px; min-width: 0; font: 700 1rem var(--corps); letter-spacing: .08em; text-transform: uppercase;
  background: var(--nuit); color: var(--texte); border: 2px solid var(--trait); border-radius: 12px; padding: 10px 12px; }
.reprendre .choix { width: auto; background: var(--jaune); border-color: #111; }
