/*
 * Feuille de style unique des pages, écrite à la main, sans compilation.
 * Toutes les valeurs (couleurs, espacements, rayons, ombres) viennent de
 * tokens.css. Mobile d'abord : les règles @media (min-width: …) élargissent.
 */

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

/* L'attribut hidden l'emporte toujours (les boutons ont leur propre display). */
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font);
    font-size: var(--fs-md);
    line-height: 1.55;
    color: var(--c-text);
    background: var(--c-bg);
    -webkit-font-smoothing: antialiased;
    -webkit-tap-highlight-color: transparent;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main { flex: 1; padding: var(--space-6) 0 var(--space-12); }
.has-tabbar main { padding-bottom: calc(var(--tabbar) + var(--space-8) + env(safe-area-inset-bottom)); }

img, svg { max-width: 100%; }
a { color: var(--c-primary); text-underline-offset: 3px; }
/* Numéros de téléphone : jamais coupés en fin de ligne. */
a[href^="tel:"] { white-space: nowrap; }
a:hover { color: var(--c-primary-strong); }

h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; font-weight: var(--fw-heavy); letter-spacing: -.02em; color: var(--c-heading); }
h1 { font-size: var(--fs-2xl); }
h2 { font-size: var(--fs-xl); }
h3 { font-size: var(--fs-lg); font-weight: var(--fw-bold); }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.25em; }
code { overflow-wrap: anywhere; font-size: .95em; background: var(--c-bg-warm); padding: 1px 6px; border-radius: 6px; }

:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.container-narrow { max-width: var(--container-narrow); }

.skip-link { position: absolute; left: var(--space-2); top: -60px; z-index: 50; background: var(--c-primary); color: var(--c-on-dark); padding: var(--space-2) var(--space-4); border-radius: var(--radius-sm); }
.skip-link:focus { top: var(--space-2); color: var(--c-on-dark); }

.muted { color: var(--c-muted); }
.small { font-size: var(--fs-sm); }
.center { text-align: center; }
.next-step { margin-top: var(--space-4); }
.stack > * + * { margin-top: var(--space-4); }
.eyebrow { display: inline-flex; align-items: center; gap: var(--space-2); font-size: var(--fs-sm); font-weight: var(--fw-bold); color: var(--c-accent-strong); text-transform: none; margin-bottom: var(--space-2); }
.lead { font-size: var(--fs-lg); color: var(--c-muted); }
.page-head { margin-bottom: var(--space-5); }
.page-head p:last-child { margin-bottom: 0; }
.back-link { display: inline-flex; align-items: center; gap: var(--space-1); font-weight: var(--fw-bold); text-decoration: none; margin-bottom: var(--space-3); }

/* ---------- Icônes ---------- */

.icon { width: 1.25em; height: 1.25em; flex: none; vertical-align: -.25em; }
.icon-lg { width: 28px; height: 28px; }
/* Pastilles d'icône (cartes, en-têtes) : 52 pixels, icône de 26 pixels au trait renforcé.
   Couleurs : style choisi dans config/platform.php (brand.icon_style), variables --ib-… de tokens.css.
   .icon-bubble-primary : l'essentiel (variante « forte » du style) ; .icon-bubble-danger : erreur. */
.icon-bubble { display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 16px; background: var(--ib-bg); color: var(--ib-fg); box-shadow: var(--ib-ring); flex: none; }
.icon-bubble .icon { width: 26px; height: 26px; stroke-width: 2.25; }
.icon-bubble .icon .d { fill: var(--ib-fill); }
.icon-bubble-primary { background: var(--ib-strong-bg); color: var(--ib-strong-fg); box-shadow: var(--ib-strong-ring); }
.icon-bubble-primary .icon .d { fill: var(--ib-strong-fill); }
.icon-bubble-danger { background: var(--c-danger-soft); color: var(--c-danger); box-shadow: inset 0 0 0 1px var(--c-danger-line); }
.icon-bubble-danger .icon .d { fill: none; }

/* ---------- En-tête et logo ---------- */

.site-header { position: sticky; top: 0; z-index: 20; background: var(--c-header); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--c-border); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); min-height: 60px; }
.logo { display: inline-flex; align-items: center; text-decoration: none; line-height: 0; flex: none; }
.logo img { display: block; height: 34px; width: auto; }
.site-footer .logo img { height: 40px; }
.footer-tagline { margin: var(--space-3) 0 0; color: var(--c-on-dark-muted); }
.nav { display: flex; align-items: center; gap: var(--space-1); }
.nav a, .nav .btn-link { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; text-decoration: none; padding: var(--space-2) 10px; border-radius: var(--radius-pill); font-weight: var(--fw-bold); color: var(--c-text); font-size: var(--fs-sm); min-height: 40px; }
.nav a:hover, .nav .btn-link:hover { background: var(--c-primary-soft); color: var(--c-primary-strong); }
.nav a.is-active { color: var(--c-primary); background: var(--c-primary-soft); }
.nav form { margin: 0; }
.nav .nav-cta { background: var(--c-primary); color: var(--c-on-dark); }
.nav .nav-cta:hover { background: var(--c-primary-strong); color: var(--c-on-dark); }
.nav .badge { margin-left: -2px; }
.nav a[aria-current="page"] { color: var(--c-primary); background: var(--c-primary-soft); }

/* Navigation complète (ordinateur) : cachée sous 1200 pixels, remplacée par le bouton « Menu ». */
.nav-desktop { display: none; }

/* Menu compact (téléphone, tablette) : <details>, sans JavaScript. */
.menu { position: relative; }
.menu-button { display: inline-flex; align-items: center; gap: var(--space-2); min-height: 44px; padding: var(--space-2) 14px; border-radius: var(--radius-pill); border: 1px solid var(--c-border); background: var(--c-surface); color: var(--c-heading); font-weight: var(--fw-bold); font-size: var(--fs-sm); cursor: pointer; list-style: none; user-select: none; }
.menu-button::-webkit-details-marker { display: none; }
.menu-button:hover, .menu[open] .menu-button { background: var(--c-primary-soft); border-color: var(--c-primary-line); }
.menu-panel { position: absolute; right: 0; top: calc(100% + var(--space-2)); z-index: 30; display: grid; min-width: 250px; padding: var(--space-2); background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius); box-shadow: var(--shadow-lg); animation: rise var(--dur-fast) ease-out; }
.menu-panel a, .menu-panel button { display: flex; align-items: center; gap: var(--space-3); width: 100%; min-height: 48px; padding: 0 var(--space-3); border-radius: var(--radius-sm); border: 0; background: none; color: var(--c-text); font: inherit; font-weight: var(--fw-bold); text-decoration: none; cursor: pointer; text-align: left; }
.menu-panel a:hover, .menu-panel button:hover { background: var(--c-primary-soft); color: var(--c-primary-strong); }
.menu-panel a[aria-current="page"] { background: var(--c-primary-soft); color: var(--c-primary); box-shadow: inset 3px 0 0 var(--c-accent); }
.menu-panel .badge { margin-left: auto; }
.menu-panel form { margin: var(--space-1) 0 0; padding-top: var(--space-1); border-top: 1px solid var(--c-border); }

/* Barre de navigation du bas (téléphone, apprenant connecté) */
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 25; display: grid; grid-template-columns: repeat(4, 1fr); background: var(--c-surface); border-top: 1px solid var(--c-border); box-shadow: var(--shadow-up); padding-bottom: env(safe-area-inset-bottom); }
.tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: var(--tabbar); font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--c-muted); text-decoration: none; }
.tabbar a .icon { width: 44px; height: 28px; padding: 3px 10px; border-radius: var(--radius-pill); stroke-width: 2.1; transition: background var(--dur-fast); }
.tabbar a.is-active { color: var(--c-primary); }
.tabbar a.is-active .icon { background: var(--ib-bg); color: var(--ib-fg); box-shadow: var(--ib-ring); }
.tabbar a.is-active .icon .d { fill: var(--ib-fill); }

/* ---------- Pied de page ---------- */

.site-footer { background: var(--c-primary-deep); color: var(--c-on-dark-muted); font-size: var(--fs-sm); padding: var(--space-8) 0 var(--space-6); }
.has-tabbar .site-footer { padding-bottom: calc(var(--tabbar) + var(--space-6) + env(safe-area-inset-bottom)); }
.site-footer a { color: var(--c-on-dark); }
.site-footer a:hover { color: var(--c-on-dark-muted); }
.footer-grid { display: grid; gap: var(--space-6); }
.footer-list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-2); }
.footer-list li { display: flex; gap: var(--space-2); align-items: flex-start; }
.footer-list .icon { margin-top: 2px; color: var(--c-on-dark-muted); }
.footer-links { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); margin: 0; padding: 0; list-style: none; }
.footer-bottom { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--space-1) var(--space-4); border-top: 1px solid var(--c-on-dark-line); margin-top: var(--space-6); padding-top: var(--space-4); }
.footer-bottom p { margin: 0; }
.footer-signature { color: var(--c-on-dark-muted); letter-spacing: .01em; }
.footer-signature strong { color: var(--c-on-dark); font-weight: var(--fw-bold); }

/* ---------- Boutons ---------- */

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
    border: 0; border-radius: var(--radius); cursor: pointer;
    font: inherit; font-weight: var(--fw-heavy); text-align: center; text-decoration: none; line-height: 1.2;
    padding: 12px 20px; min-height: 48px; background: var(--c-primary); color: var(--c-on-dark);
    box-shadow: var(--shadow-sm);
    transition: background var(--dur-fast), transform var(--dur-fast) var(--ease), box-shadow var(--dur-fast);
    touch-action: manipulation;
}
.btn:hover, .btn:focus-visible { background: var(--c-primary-strong); color: var(--c-on-dark); }
.btn:active { transform: scale(.97); box-shadow: none; }
.btn-block { display: flex; width: 100%; }
.btn-lg { min-height: 56px; font-size: var(--fs-lg); padding: 14px 24px; border-radius: var(--radius-lg); }
/* Bouton orange vif : texte TOUJOURS bleu nuit (blanc sur orange : contraste insuffisant). */
.btn-accent { background: var(--c-accent); color: var(--c-on-accent); box-shadow: var(--shadow-accent); }
.btn-accent:hover, .btn-accent:focus-visible { background: var(--c-accent-hover); color: var(--c-on-accent); }
.btn-light { background: var(--c-primary-soft); color: var(--c-primary-strong); box-shadow: none; }
.btn-light:hover, .btn-light:focus-visible { background: var(--c-primary-line); color: var(--c-primary-strong); }
.btn-outline { background: var(--c-surface); color: var(--c-primary-strong); box-shadow: inset 0 0 0 2px var(--c-primary); }
.btn-outline:hover, .btn-outline:focus-visible { background: var(--c-primary-soft); color: var(--c-primary-strong); }
.btn-link { background: none; color: var(--c-primary); padding: 6px 8px; min-height: 0; font-weight: var(--fw-bold); text-decoration: underline; box-shadow: none; }
.btn-link:hover, .btn-link:focus-visible { background: none; color: var(--c-primary-strong); }
.btn-whatsapp { background: var(--c-whatsapp); }
.btn-whatsapp:hover, .btn-whatsapp:focus-visible { background: var(--c-whatsapp-strong); }
.btn-danger { background: var(--c-danger); }
.btn-danger:hover, .btn-danger:focus-visible { background: var(--c-danger-strong); }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }
.actions { display: grid; gap: var(--space-3); }

/* ---------- Cartes ---------- */

.card { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: var(--space-5); margin-bottom: var(--space-4); box-shadow: var(--shadow); }
.card > :last-child { margin-bottom: 0; }
.card-soft { background: var(--c-primary-soft); border-color: var(--c-primary-line); box-shadow: none; }
.card-accent { border-top: 4px solid var(--c-accent); }
.card-title { display: flex; align-items: center; gap: var(--space-3); margin-bottom: var(--space-3); }
.card-title h2, .card-title h3 { margin: 0; }
.card-link { display: block; text-decoration: none; color: inherit; transition: transform var(--dur-fast) var(--ease), box-shadow var(--dur-fast); }
.card-link:hover { color: inherit; box-shadow: var(--shadow-lg); }
.card-link:active { transform: scale(.985); }

/* ---------- Formulaires ---------- */

.form-card { padding: var(--space-6) var(--space-5); }
.field { margin-bottom: var(--space-4); }
label { display: block; font-weight: var(--fw-bold); margin-bottom: 6px; }
input[type=text], input[type=tel], input[type=email], input[type=password], input[type=search], input[type=time], input[type=date], input[type=number], input[type=file], select, textarea {
    width: 100%; font: inherit; font-size: 1rem; padding: 12px 14px; min-height: 50px;
    border: 1.5px solid var(--c-field); border-radius: var(--radius); background: var(--c-surface); color: var(--c-text);
    transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}
input[type=file] { padding: 10px; }
textarea { resize: vertical; margin-bottom: var(--space-2); min-height: 96px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--c-primary); box-shadow: 0 0 0 4px var(--c-ring); }
.checkbox { display: flex; align-items: center; gap: var(--space-3); font-weight: var(--fw-normal); cursor: pointer; }
.checkbox input { width: 22px; height: 22px; accent-color: var(--c-primary); flex: none; margin: 0; }
/* Champ mot de passe avec le bouton « œil » (afficher / masquer). */
.password-field { position: relative; }
.password-field input { padding-right: 56px; }
.password-toggle { position: absolute; top: 50%; right: 4px; transform: translateY(-50%); width: 46px; height: 46px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: var(--radius); background: none; color: var(--c-primary); cursor: pointer; touch-action: manipulation; }
.password-toggle:hover, .password-toggle:focus-visible { background: var(--c-primary-soft); }
.hint { color: var(--c-muted); font-size: var(--fs-sm); margin-top: 6px; }
.error { color: var(--c-danger); font-size: var(--fs-sm); font-weight: var(--fw-bold); margin-top: 6px; }
.is-invalid { border-color: var(--c-danger) !important; }
fieldset { border: 0; padding: 0; margin: 0 0 var(--space-4); min-width: 0; }
legend { font-weight: var(--fw-heavy); font-size: var(--fs-lg); margin-bottom: var(--space-3); padding: 0; }
.option { padding: 14px var(--space-4); border: 1.5px solid var(--c-border); border-radius: var(--radius); margin-bottom: var(--space-2); background: var(--c-surface); transition: border-color var(--dur-fast), background var(--dur-fast), transform var(--dur-fast) var(--ease); }
.option:hover { border-color: var(--c-primary-line); }
.option:active { transform: scale(.985); }
.option:has(input:checked) { border-color: var(--c-primary); background: var(--c-primary-soft); }
/* Jours : grille souple, jamais plus large que la carte (« Dimanche » et « Jeudi » débordaient à 768 et 1280). */
.days { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 8.5rem), 1fr)); gap: 0 var(--space-2); }
.days .option, .profiles .option { min-width: 0; padding-inline: var(--space-3); overflow-wrap: anywhere; }
.form-footer { margin-top: var(--space-5); text-align: center; }
.form-footer p { margin: 0 0 var(--space-2); }

/* ---------- Messages ---------- */

.alert { display: flex; gap: var(--space-3); align-items: flex-start; border-radius: var(--radius); padding: 14px var(--space-4); margin-bottom: var(--space-4); border: 1px solid transparent; }
.alert > .icon { margin-top: 2px; }
.alert > div > :last-child { margin-bottom: 0; }
.alert-success { background: var(--c-success-soft); color: var(--c-primary-strong); border-color: var(--c-primary-line); }
.alert-error { background: var(--c-danger-soft); color: var(--c-danger); border-color: var(--c-danger-line); }
.alert-info { background: var(--c-info-soft); color: var(--c-info); border-color: var(--c-info-line); }
.alert-warning { background: var(--c-warning-soft); color: var(--c-warning); border-color: var(--c-warning-line); }
.alert a { color: inherit; font-weight: var(--fw-bold); }
.alert .btn { color: var(--c-on-dark); }
.alert .btn-accent { color: var(--c-on-accent); }

/* ---------- Badges ---------- */

.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: var(--radius-pill); background: var(--c-primary-soft); color: var(--c-primary-strong); font-weight: var(--fw-bold); font-size: var(--fs-xs); line-height: 1.6; vertical-align: middle; }
.badge-accent { background: var(--c-accent-soft); color: var(--c-accent-ink); }
.badge-muted { background: var(--c-bg-warm); color: var(--c-muted); }
.badge-alert { background: var(--c-danger); color: var(--c-on-dark); }

/* ---------- Accueil ---------- */

.hero { position: relative; display: grid; gap: var(--space-6); align-items: center; padding: var(--space-2) 0 var(--space-8); }
.hero h1 { font-size: var(--fs-3xl); line-height: 1.1; }
.hero h1 .accent { color: var(--c-accent-strong); }
.hero-teacher { display: flex; align-items: center; gap: var(--space-3); margin: 0 0 var(--space-3); font-size: var(--fs-sm); color: var(--c-muted); }
.hero-teacher-face { flex: none; width: 56px; height: 56px; border-radius: 50%; overflow: hidden; background: var(--c-bg-warm); box-shadow: 0 0 0 3px var(--c-surface), 0 0 0 5px var(--c-accent); }
.hero-teacher-face img { display: block; width: 100%; height: 100%; transform: scale(2.6) translate(0, 20%); }
.hero-teacher strong { display: block; color: var(--c-heading); font-size: var(--fs-md); }
.hero-eyebrow { display: none; }
.hero .lead { margin-bottom: var(--space-3); }
.hero-also { margin: 0 0 var(--space-5); color: var(--c-muted); font-weight: var(--fw-bold); }
.hero-media { position: relative; margin: 0 auto; width: min(100%, 360px); }
.hero-media::before { content: ""; position: absolute; inset: 8% -4% -4% 8%; border-radius: 40% 40% var(--radius-lg) var(--radius-lg); background: var(--c-accent-soft); z-index: -1; }
.hero-media img { display: block; width: 100%; height: auto; aspect-ratio: 1; border-radius: 48% 48% var(--radius-lg) var(--radius-lg); box-shadow: var(--shadow-lg); background: var(--c-bg-warm); }
.hero-bubble { position: absolute; left: -6px; bottom: 18%; background: var(--c-surface); border-radius: var(--radius) var(--radius) var(--radius) 4px; padding: 8px 14px; box-shadow: var(--shadow); font-weight: var(--fw-heavy); font-size: var(--fs-sm); }
.hero-bubble.right { left: auto; right: -6px; top: 10%; bottom: auto; border-radius: var(--radius) var(--radius) 4px var(--radius); color: var(--c-primary); }
.hero-points { list-style: none; padding: 0; margin: var(--space-5) 0 0; display: grid; gap: var(--space-2); }
.hero-points li { display: flex; gap: var(--space-2); align-items: center; font-weight: var(--fw-bold); }
.hero-points .icon { color: var(--c-accent-strong); stroke-width: 2.25; }

.section { padding: var(--space-8) 0; }
.section-warm { background: var(--c-bg-warm); }
.section-head { max-width: 640px; margin-bottom: var(--space-6); }
.section-head p:last-child { margin-bottom: 0; }
.features { display: grid; gap: var(--space-4); }
.feature { display: flex; gap: var(--space-4); align-items: flex-start; margin: 0; }
.feature h3 { margin-bottom: var(--space-1); }
.feature p { margin: 0; color: var(--c-muted); }

.steps { list-style: none; padding: 0; margin: 0; counter-reset: step; display: grid; gap: var(--space-4); }
.steps li { counter-increment: step; position: relative; padding-left: 56px; min-height: 40px; }
.steps li::before {
    content: counter(step); position: absolute; left: 0; top: 0; width: 40px; height: 40px; border-radius: 50%;
    background: var(--c-primary); color: var(--c-on-dark); font-weight: var(--fw-heavy); display: flex; align-items: center; justify-content: center;
}
.steps li:not(:last-child)::after { content: ""; position: absolute; left: 19px; top: 44px; bottom: calc(-1 * var(--space-4) + 4px); width: 2px; background: var(--c-primary-line); }
.steps strong { font-weight: var(--fw-heavy); }

/* Niveaux A1 → C2 : échelle reliée par un trait, noms dessous ; deux lignes de trois sur téléphone, une ligne de six ensuite. */
.levels { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-5) 0; list-style: none; padding: 0; margin: 0; }
.levels li { position: relative; display: flex; flex-direction: column; align-items: center; gap: var(--space-2); padding: 0 var(--space-1); text-align: center; }
.levels li::before { content: ""; position: absolute; top: 24px; left: 0; right: 0; height: 3px; margin-top: -1px; background: var(--c-primary-line); }
.levels li:nth-child(3n + 1)::before { left: 50%; }
.levels li:nth-child(3n)::before { right: 50%; }
.levels .level-dot { position: relative; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--c-surface); color: var(--c-primary); font-size: var(--fs-lg); font-weight: var(--fw-heavy); box-shadow: 0 0 0 3px var(--c-accent); }
.levels span { font-size: var(--fs-xs); color: var(--c-muted); hyphens: auto; overflow-wrap: break-word; }

.plans { display: grid; gap: var(--space-4); }
.plans-offer { margin-bottom: var(--space-4); animation: rise var(--dur) var(--ease) both; }
.plans-offer h2 { font-size: var(--fs-lg); }
/* Écran de conversation étroit : formules l'une sous l'autre. */
.live .plans { grid-template-columns: 1fr; }
.plan { display: flex; flex-direction: column; text-align: left; position: relative; overflow: hidden; }
.plan::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: var(--c-primary); }
.plan h2, .plan h3 { margin-bottom: var(--space-1); }
.plan .price { font-size: var(--fs-2xl); font-weight: var(--fw-heavy); color: var(--c-primary); margin: var(--space-2) 0 0; line-height: 1.1; }
.plan .period { color: var(--c-muted); font-weight: var(--fw-bold); }
.plan ul { list-style: none; padding: 0; margin: var(--space-4) 0; display: grid; gap: var(--space-2); }
.plan li { display: flex; gap: var(--space-2); align-items: flex-start; }
.plan li .icon { color: var(--c-accent-strong); margin-top: 1px; stroke-width: 2.25; }
.plan .btn { margin-top: auto; }
.plan.is-current { border-color: var(--c-primary); }
/* Bouton d'achat des formules : orange plein, texte bleu nuit gras, relief, enfoncement au toucher. */
.btn-plan { min-height: 56px; font-size: var(--fs-md); font-weight: var(--fw-heavy); box-shadow: var(--shine), var(--shadow-accent); }
.btn-plan .icon { transition: transform var(--dur-fast) var(--ease); }
.btn-plan:hover .icon, .btn-plan:focus-visible .icon { transform: translateX(3px); }
.btn-plan:active { transform: translateY(2px) scale(.98); box-shadow: var(--shine), var(--shadow-accent-press); }
/* Formule recommandée : contour orange et badge. */
.plan.is-recommended { border: 2px solid var(--c-accent); box-shadow: var(--shadow), var(--shadow-accent-press); }
.plan.is-recommended::before { background: var(--c-accent); }
.plan-badge { position: absolute; top: var(--space-4); right: var(--space-4); display: inline-flex; align-items: center; gap: 4px; max-width: 55%; padding: 4px 10px; border-radius: var(--radius-pill); background: var(--c-primary-soft); color: var(--c-primary); box-shadow: inset 0 0 0 1px var(--c-primary-line); font-size: var(--fs-xs); font-weight: var(--fw-bold); line-height: 1.3; text-align: center; }
.plan-badge-strong { background: var(--c-accent); color: var(--c-on-accent); box-shadow: var(--shadow-accent-press); font-weight: var(--fw-heavy); }
.plan-badge .icon { width: 14px; height: 14px; stroke-width: 2.5; }
.plan.has-badge h2, .plan.has-badge h3 { padding-right: 45%; }

.cta-band { background: var(--c-primary); color: var(--c-on-dark); border-radius: var(--radius-lg); padding: var(--space-8) var(--space-5); text-align: center; box-shadow: var(--shadow-lg); position: relative; overflow: hidden; }
.cta-band::after { content: ""; position: absolute; width: 180px; height: 180px; right: -60px; top: -60px; border-radius: 50%; background: var(--c-on-dark-glow); }
.cta-band h2 { color: var(--c-on-dark); }
.cta-band p { color: var(--c-on-dark-muted); }
/* Photos (config/photos.php, <x-photo>) : cadre arrondi, ratio 4:3 réservé (pas de saut à l'affichage). */
.photo-frame { margin: 0; border-radius: var(--radius-lg); overflow: hidden; background: var(--c-bg-warm); box-shadow: var(--shadow); aspect-ratio: 4 / 3; }
.photo-frame picture { display: contents; }
.photo { display: block; width: 100%; height: 100%; object-fit: cover; }
.credit-photo { display: grid; gap: var(--space-4); }
.credit-photo .photo-frame { max-width: 220px; }
.section-split { display: grid; gap: var(--space-5); align-items: center; margin-bottom: var(--space-6); }
.section-split .section-head { margin-bottom: 0; }

/* Fonds animés : formes douces aux couleurs de la marque, en CSS seulement. Seuls transform et
   opacity bougent (aucun recalcul de mise en page) ; coupés si l'appareil demande moins d'animations. */
.hero::before, .hero::after, .students::before, .cta-band::before { content: ""; position: absolute; z-index: -1; border-radius: 50%; pointer-events: none; will-change: transform; }
.hero::before { width: 420px; height: 420px; top: -140px; right: -160px; background: radial-gradient(circle at 35% 35%, var(--c-accent-soft), transparent 68%); }
.hero::after { width: 360px; height: 360px; bottom: -120px; left: -180px; background: radial-gradient(circle at 60% 40%, var(--c-primary-soft), transparent 70%); }
/* Troisième forme floue de l'accueil (téléphone : immobile ; ordinateur : lente, voir plus bas). */
.hero-blob { position: absolute; z-index: -1; width: 240px; height: 240px; top: 34%; left: 25%; border-radius: 50%; pointer-events: none; background: radial-gradient(circle, var(--c-accent-soft), transparent 70%); opacity: .7; }
.students { isolation: isolate; }
.students::before { width: 320px; height: 320px; right: -120px; bottom: -140px; background: radial-gradient(circle, var(--c-accent-soft), transparent 70%); animation: drift 24s ease-in-out infinite alternate; }
.cta-band::before { z-index: 0; width: 260px; height: 260px; left: -90px; bottom: -110px; background: radial-gradient(circle, var(--c-on-dark-glow), transparent 70%); animation: drift 20s ease-in-out infinite alternate; }
.cta-band::after { animation: drift 28s ease-in-out -6s infinite alternate-reverse; }
.cta-band > * { position: relative; z-index: 1; }
@keyframes drift {
    0% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(-24px, 18px, 0) scale(1.06); }
    100% { transform: translate3d(16px, -14px, 0) scale(.96); }
}
.hero { isolation: isolate; }
main { overflow-x: clip; }

/* Accueil : étapes numérotées, élèves, foire aux questions, appel final. */
.how { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.how li { position: relative; margin: 0; }
.how-head { display: flex; align-items: center; gap: var(--space-3); margin-bottom: var(--space-3); }
.how-num { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--ib-strong-bg); color: var(--ib-strong-fg); box-shadow: var(--ib-strong-ring); font-size: var(--fs-2xl); font-weight: var(--fw-heavy); line-height: 1; flex: none; }
.how h3 { margin-bottom: var(--space-1); }
.how p { margin: 0; color: var(--c-muted); }
.features + .levels { margin-top: var(--space-6); }
.students { position: relative; overflow: hidden; display: grid; gap: var(--space-6); align-items: center; padding: var(--space-8) var(--space-5); border-radius: var(--radius-lg); background: var(--c-surface); border: 1px solid var(--c-border); box-shadow: var(--shadow); }
.students h2 { margin-top: 0; }
.check-list { list-style: none; padding: 0; margin: 0 0 var(--space-5); display: grid; gap: var(--space-2); }
/* Icône posée à gauche, texte d'un seul tenant (liens et mots en gras restent dans la phrase, sur toute la largeur). */
.check-list li { position: relative; padding-left: 28px; font-weight: var(--fw-bold); }
.check-list .icon { position: absolute; left: 0; top: 3px; color: var(--c-accent-strong); }
.faq { display: grid; gap: var(--space-2); max-width: 760px; }
.faq details { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius); }
/* Lignes repliées compactes (douze questions sur l'accueil) : 48 pixels au moins, toujours faciles à toucher. */
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); min-height: 48px; padding: var(--space-2) var(--space-3); font-weight: var(--fw-bold); color: var(--c-heading); cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--c-accent); color: var(--c-on-accent); font-size: var(--fs-lg); font-weight: var(--fw-heavy); transition: transform var(--dur-fast); }
.faq summary > span { flex: 1; }
@media (max-width: 639px) { .faq summary > span { font-size: var(--fs-sm); } }
.faq summary .icon { flex: none; width: 36px; height: 36px; padding: 8px; border-radius: 11px; background: var(--ib-bg); color: var(--ib-fg); box-shadow: var(--ib-ring); stroke-width: 2.25; }
.faq summary .icon .d { fill: var(--ib-fill); }
.faq details[open] summary::after { content: "−"; }
.faq summary:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; border-radius: var(--radius); }
.faq details p { margin: 0; padding: 0 var(--space-4) var(--space-4); color: var(--c-text); }
.faq-list { margin: calc(-1 * var(--space-2)) 0 0; padding: 0 var(--space-4) var(--space-4) calc(var(--space-4) + 18px); display: grid; gap: var(--space-1); }
.cta-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-3); position: relative; z-index: 1; }
.pay-logos { display: flex; flex-wrap: wrap; gap: var(--space-2); list-style: none; padding: 0; margin: var(--space-3) 0 0; }
.pay-logos li { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-pill); padding: 4px 12px; font-weight: var(--fw-bold); font-size: var(--fs-sm); }

/* ---------- Authentification ---------- */

.auth-head { text-align: center; margin-bottom: var(--space-5); }
.auth-head .icon-bubble { margin: 0 auto var(--space-3); width: 64px; height: 64px; border-radius: 20px; }
.auth-head .icon-bubble .icon { width: 32px; height: 32px; }
.auth-head p { color: var(--c-muted); margin: 0; }

/* ---------- Tableau de bord ---------- */

.welcome { display: flex; align-items: center; gap: var(--space-4); margin-bottom: var(--space-5); }
.welcome img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; object-position: 50% 20%; box-shadow: var(--shadow); background: var(--c-bg-warm); flex: none; }
.welcome h1 { margin: 0; }
.welcome p { margin: 0; color: var(--c-muted); }
.stats { display: grid; gap: var(--space-3); grid-template-columns: 1fr; }
.stat { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: var(--space-4); box-shadow: var(--shadow-sm); }
.stat .label { display: flex; align-items: center; gap: 6px; color: var(--c-muted); font-size: var(--fs-sm); font-weight: var(--fw-bold); }
.stat .label { gap: var(--space-2); }
.stat .label .icon { width: 40px; height: 40px; padding: 9px; border-radius: 12px; background: var(--ib-bg); color: var(--ib-fg); box-shadow: var(--ib-ring); stroke-width: 2.25; }
.stat .label .icon .d { fill: var(--ib-fill); }
.stat .value { font-size: var(--fs-2xl); font-weight: var(--fw-heavy); line-height: 1.2; margin-top: 2px; }
.stat .detail { color: var(--c-muted); font-size: var(--fs-sm); }
.small-value { font-size: var(--fs-lg) !important; }
.next-card { background: linear-gradient(135deg, var(--c-primary) 0%, var(--c-primary-strong) 100%); color: var(--c-on-dark); border: 0; box-shadow: var(--shadow-lg); }
.next-card h2, .next-card h3 { color: var(--c-on-dark); }
.next-card p, .next-card .muted { color: var(--c-on-dark-muted); }
.next-card a:not(.btn) { color: var(--c-on-dark); }
.next-card .btn { background: var(--c-accent); color: var(--c-on-accent); box-shadow: var(--shadow-accent); }
.next-card .btn:hover, .next-card .btn:focus-visible { background: var(--c-accent-hover); color: var(--c-on-accent); }
.next-card-eyebrow { display: inline-block; margin-bottom: var(--space-2); padding: 4px 12px; border-radius: var(--radius-pill); background: var(--c-accent); color: var(--c-on-accent); font-size: var(--fs-sm); font-weight: var(--fw-heavy); }
.next-card-note { display: flex; gap: var(--space-2); align-items: flex-start; margin: var(--space-4) 0 0 !important; padding: var(--space-3); border-radius: var(--radius); background: var(--c-on-dark-glow); border: 1px solid var(--c-on-dark-line); }
.next-card-note .icon { flex: none; margin-top: 2px; color: var(--c-accent); }
/* La suite d'une étape (<x-next-step>) : phrase, UN bouton orange d'au moins 56 pixels, actions secondaires discrètes. */
.next-card.next-step-card { display: block; margin: 0 0 var(--space-5); scroll-margin-top: 84px; }
.next-step-card h2 { margin: 0 0 var(--space-2); font-size: var(--fs-lg); }
.next-step-card h2:focus { outline: none; }
.next-step-text { margin: 0 0 var(--space-4); }
.btn-next { min-height: 56px; }
.next-step-more { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-2) var(--space-4); margin-top: var(--space-3); font-size: var(--fs-sm); }
.next-step-more .btn { background: transparent; color: var(--c-on-dark); box-shadow: inset 0 0 0 2px var(--c-on-dark-line); min-height: 48px; }
.next-step-more .btn:hover, .next-step-more .btn:focus-visible { background: var(--c-on-dark-glow); color: var(--c-on-dark); }
.next-step-more a:not(.btn) { display: inline-flex; align-items: center; min-height: 48px; font-weight: var(--fw-bold); }
.stats.stats-main { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: var(--space-4); }
.stats-main .stat { padding: var(--space-3); }
/* Téléphone : deux colonnes étroites, l'icône au-dessus du libellé (le libellé ne se coupe plus mot par mot). */
@media (max-width: 899px) { .stats-main .stat .label { flex-direction: column; align-items: flex-start; gap: var(--space-2); } }
.stats-main .value { font-size: var(--fs-xl); overflow-wrap: anywhere; }
@media (min-width: 900px) { .stats.stats-main { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* Barres de progression (programme, niveau) */
.progress { height: 10px; background: var(--c-bg-warm); border-radius: var(--radius-pill); overflow: hidden; margin: var(--space-2) 0; }
.progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--c-primary), var(--c-primary-bright)); border-radius: var(--radius-pill); animation: grow var(--dur-slow) var(--ease) both .15s; }
@keyframes grow { from { width: 0; } }

/* Graphique des compétences : barres horizontales, une seule série, valeur au bout. */
.skills-chart { list-style: none; padding: 0; margin: 0; }
.skills-chart li { display: grid; grid-template-columns: 112px 1fr 32px; align-items: center; gap: var(--space-2); padding: 6px 0; }
.skill-name { font-size: var(--fs-sm); }
.skill-track { height: 14px; background: var(--c-bg-warm); border-radius: var(--radius-pill); overflow: hidden; }
.skill-bar { display: block; height: 14px; background: var(--c-primary); border-radius: var(--radius-pill); animation: grow var(--dur-slow) var(--ease) both .2s; }
.skill-value { font-variant-numeric: tabular-nums; font-weight: var(--fw-bold); text-align: right; }

.error-item { margin: 0 0 var(--space-3); padding: var(--space-3); background: var(--c-bg); border-radius: var(--radius); }
.error-item .wrong { text-decoration: line-through; color: var(--c-muted); }
.error-item:last-child { margin-bottom: 0; }

/* ---------- Étapes (paiement, questionnaire) ---------- */

.stepper { margin: 0 0 var(--space-5); }
.stepper-bar { height: 6px; background: var(--c-border); border-radius: var(--radius-pill); overflow: hidden; }
.stepper-bar span { display: block; height: 100%; width: var(--to); background: var(--c-primary); border-radius: var(--radius-pill); animation: step-fill var(--dur-slow) var(--ease) both; }
@keyframes step-fill { from { width: var(--from); } }
.pay-steps { display: flex; gap: var(--space-1); list-style: none; padding: 0; margin: var(--space-2) 0 0; font-size: var(--fs-xs); color: var(--c-muted); }
.pay-steps li { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; font-weight: var(--fw-bold); }
.pay-steps li .step-num { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; background: var(--c-surface); border: 2px solid var(--c-border); color: var(--c-muted); font-weight: var(--fw-heavy); font-size: var(--fs-xs); }
.pay-steps .done .step-num { background: var(--c-primary-soft); border-color: var(--c-primary-line); color: var(--c-primary-strong); }
.pay-steps .current { color: var(--c-text); }
.pay-steps .current .step-num { background: var(--c-primary); border-color: var(--c-primary); color: var(--c-on-dark); box-shadow: 0 0 0 4px var(--c-ring); }

/* Panneau d'une étape : arrive en glissant */
.step-panel { animation: slide-in var(--dur) var(--ease) both; }
@keyframes slide-in { from { opacity: 0; transform: translateX(24px); } }

.choices { display: grid; gap: var(--space-2); }
.operators { list-style: none; padding: 0; margin: 0 0 var(--space-3); display: grid; gap: var(--space-3); }
.operators li { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); padding: var(--space-4); border: 1px solid var(--c-border); border-radius: var(--radius); background: var(--c-bg); flex-wrap: wrap; }
.pay-number { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); flex-wrap: wrap; margin-top: var(--space-2); padding: var(--space-4); border: 1px solid var(--c-border); border-radius: var(--radius); background: var(--c-bg); }
.pay-number .number, .operators .number { font-size: var(--fs-xl); font-weight: var(--fw-heavy); font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.pay-number .number { white-space: nowrap; font-size: min(var(--fs-xl), 4.9vw); }
.amount { display: inline-block; background: var(--c-accent-soft); color: var(--c-accent-ink); border-radius: var(--radius-sm); padding: 0 8px; }
.summary { display: grid; grid-template-columns: max-content 1fr; gap: var(--space-2) var(--space-4); margin: 0 0 var(--space-3); }
.summary dt { color: var(--c-muted); }
.summary dd { margin: 0; overflow-wrap: anywhere; font-weight: var(--fw-bold); }
.status-head { text-align: center; padding: var(--space-4) 0 var(--space-2); }
.status-head .icon-bubble { width: 72px; height: 72px; border-radius: 50%; margin: 0 auto var(--space-4); animation: pop var(--dur-slow) var(--ease) both; }
.status-head .icon-bubble .icon { width: 38px; height: 38px; }
@keyframes pop { from { transform: scale(.6); opacity: 0; } }
.secret { font-size: var(--fs-lg); letter-spacing: .05em; background: var(--c-surface); padding: 2px 8px; border-radius: 6px; }

/* ---------- Programme ---------- */

.calendar { list-style: none; padding: var(--space-2) var(--space-4); }
.calendar li { display: flex; gap: var(--space-3); padding: var(--space-3) 0; border-bottom: 1px solid var(--c-border); align-items: flex-start; }
.calendar li:last-child { border-bottom: 0; }
.calendar .date { flex: none; min-width: 84px; line-height: 1.25; text-align: center; background: var(--c-bg); border-radius: var(--radius-sm); padding: 4px 6px; font-weight: var(--fw-heavy); font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.calendar .today .date { background: var(--c-primary); color: var(--c-on-dark); }
.units { list-style: none; padding: 0; display: grid; gap: var(--space-2); }
.units li { margin: 0; padding: 0; }
.units .card { padding: 0; margin: 0; }
.unit-link { display: flex; align-items: center; gap: var(--space-3); padding: 14px var(--space-4); text-decoration: none; color: var(--c-text); }
.unit-link:hover { color: var(--c-text); }
.unit-number { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; background: var(--c-bg-warm); font-weight: var(--fw-heavy); }
.unit-body { flex: 1; min-width: 0; }
.unit-body strong { display: block; }
.unit-done .unit-number { background: var(--c-primary); color: var(--c-on-dark); }
.unit-current { border-color: var(--c-primary) !important; box-shadow: 0 0 0 2px var(--c-primary-line); }
.unit-current .unit-number { background: var(--c-accent); color: var(--c-on-accent); }
/* Deux colonnes égales : une longue expression anglaise ne réduit plus la traduction à quelques lettres par ligne. */
.summary.vocabulary { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.vocabulary dt, .vocabulary dd { overflow-wrap: break-word; hyphens: auto; }
.vocabulary dt { font-weight: var(--fw-bold); color: var(--c-text); }
.vocabulary dd { font-weight: var(--fw-normal); }
.unit-section h2 { display: flex; align-items: center; gap: var(--space-2); font-size: var(--fs-lg); }
.unit-section h2 .icon { color: var(--c-accent-strong); }

/* ---------- Historique des séances ---------- */

.lesson-card h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--space-2); }
.scores { display: flex; flex-wrap: wrap; gap: var(--space-2); list-style: none; padding: 0; margin: 0; }
.scores li { background: var(--c-bg); border-radius: var(--radius-pill); padding: 2px 10px; font-size: var(--fs-sm); }

/* ---------- Pages d'information et d'erreur ---------- */

.empty-state { text-align: center; padding: var(--space-8) 0; max-width: 480px; margin: 0 auto; }
.empty-state .code { font-size: 4rem; font-weight: var(--fw-heavy); color: var(--c-primary); line-height: 1; margin-bottom: var(--space-3); }
.empty-state .icon-bubble { width: 80px; height: 80px; border-radius: 50%; margin: 0 auto var(--space-4); }
.empty-state .icon-bubble .icon { width: 40px; height: 40px; }
.contact-list .icon-bubble .icon { width: 22px; height: 22px; }
.empty-state .actions { max-width: 320px; margin: var(--space-5) auto 0; }
.credit h2 { font-size: var(--fs-lg); }
.contact-list { list-style: none; padding: 0; margin: 0 0 var(--space-4); display: grid; gap: var(--space-3); }
.contact-list li { display: flex; gap: var(--space-3); align-items: flex-start; }
.contact-list .icon-bubble { width: 40px; height: 40px; border-radius: var(--radius-sm); }
.contact-list strong { display: block; }
.contact-list li > div { min-width: 0; overflow-wrap: anywhere; }

/* ---------- Installation de l'application ---------- */

/* « Installer l'application » : petite barre fixe juste au-dessus de la barre du bas (en bas de l'écran sans elle). */
.install { position: fixed; z-index: 24; left: var(--space-3); right: var(--space-3); bottom: calc(var(--space-3) + env(safe-area-inset-bottom)); max-width: 560px; margin: 0 auto; display: flex; align-items: center; gap: var(--space-2); background: var(--c-surface); border: 1px solid var(--c-primary-line); border-radius: var(--radius); padding: 6px 6px 6px var(--space-3); box-shadow: var(--shadow-lg); animation: rise var(--dur) var(--ease) both; }
.has-tabbar .install { bottom: calc(var(--tabbar) + var(--space-2) + env(safe-area-inset-bottom)); }
.install .icon-bubble { display: none; }
.install p { margin: 0; flex: 1; min-width: 0; font-size: var(--fs-xs); line-height: 1.3; }
.install p strong { display: block; font-size: var(--fs-sm); }
.install-more { display: none; }
@media (min-width: 640px) { .install-more { display: inline; } .install .icon-bubble { display: grid; width: 40px; height: 40px; } }
/* Place gardée sous le contenu : la barre ne cache jamais la fin de la page ni le pied de page. */
.has-install-bar .site-footer { padding-bottom: calc(var(--space-6) + 64px + env(safe-area-inset-bottom)); }
.has-install-bar.has-tabbar .site-footer { padding-bottom: calc(var(--tabbar) + var(--space-6) + 64px + env(safe-area-inset-bottom)); }
.install .btn { min-height: 40px; padding: 8px 14px; }
.install .install-close { background: none; border: 0; padding: 6px; color: var(--c-muted); cursor: pointer; border-radius: 50%; min-height: 44px; min-width: 44px; display: grid; place-items: center; }
.install p a { font-weight: var(--fw-bold); }
/* Invitation à installer, sous le bouton principal : une ligne discrète, jamais à sa place. */
.install-hint { display: flex; align-items: flex-start; gap: var(--space-2); flex-basis: 100%; margin: var(--space-2) 0 0; font-size: var(--fs-sm); text-align: left; }
.install-hint .icon { flex: none; margin-top: 3px; color: var(--c-accent-strong); }
.install-hint a { display: inline-block; font-weight: var(--fw-bold); padding: 6px 0; }
.next-card .install-hint .icon { color: var(--c-accent); }
/* Page « Installer l'application ». */
.install-done { display: none; }
.is-standalone .install-done { display: flex; }
.install-success { display: none; }
.is-installed:not(.is-standalone) .install-success { display: flex; }
/* Attente de la proposition du navigateur : seulement avec JavaScript, ni sur iPhone (aucune proposition), ni une fois prête. */
.install-wait { display: none; margin: 0 0 var(--space-3); }
.js .install-wait:not([hidden]) { display: block; }
.can-install .install-wait, .is-installed .install-wait { display: none !important; }
.install-wait-late, .install-wait.is-late .install-wait-soon { display: none; }
.install-wait.is-late .install-wait-late { display: inline; }
.install-sub { font-size: var(--fs-md); margin: var(--space-5) 0 var(--space-1); }
.install-steps h2 { font-size: var(--fs-lg); }
.install-list { margin: var(--space-3) 0 0; padding-left: 1.4em; display: grid; gap: var(--space-2); }
.install-list .icon { vertical-align: -3px; color: var(--c-accent-strong); }
/* Application installée (ouverte depuis l'écran d'accueil) : plus aucun lien ni invitation à l'installer. */
.is-standalone [data-install-link], .is-standalone [data-install-link-item], .is-standalone [data-install-hint], .is-installed [data-install-hint] { display: none !important; }

/* ---------- Pagination (vues par défaut de Laravel) ---------- */

.pagination { display: flex; gap: 6px; list-style: none; padding: 0; margin: var(--space-4) 0; flex-wrap: wrap; }
.pagination .page-item > * { display: block; padding: 8px 12px; border: 1px solid var(--c-border); border-radius: var(--radius-sm); background: var(--c-surface); text-decoration: none; }
.pagination .active > * { background: var(--c-primary); color: var(--c-on-dark); border-color: var(--c-primary); }
.pagination .disabled > * { color: var(--c-muted); }

/* Paiement en un seul enchaînement : blocs visés par le défilement automatique (sous l'en-tête fixe). */
.pay-section, .pay-block, [data-pay-methods-for] { scroll-margin-top: 84px; }
.pay-section h2[tabindex]:focus, .pay-block h2[tabindex]:focus, [data-pay-methods-for] h2[tabindex]:focus { outline: none; }
.pay-section h2[tabindex]:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 4px; border-radius: 4px; }
.pay-hint { margin: 0 0 var(--space-3); }
.pay-choice { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 var(--space-3); padding: 8px 12px; border-radius: var(--radius-pill); background: var(--c-primary-soft); color: var(--c-primary); font-size: var(--fs-sm); width: fit-content; max-width: 100%; }
.pay-choice .icon { color: var(--c-accent-strong); }
.pay-choice a { font-weight: var(--fw-heavy); }
.pay-block h2.pay-choice { margin: 0 0 var(--space-3); padding: 4px 12px; font-size: var(--fs-sm); line-height: 1.3; }
/* Sur téléphone, la carte du paiement est moins épaisse : les trois étapes tiennent ensemble dans l'écran. */
@media (max-width: 639px) { .pay-form.form-card { padding: var(--space-4); } }
/* « Modifier » : zone de toucher de 48 pixels de haut, sans agrandir la pastille. */
.pay-block h2.pay-choice a { position: relative; display: inline-flex; align-items: center; min-height: 32px; }
.pay-block h2.pay-choice a::after { content: ""; position: absolute; inset: -8px -10px; }
.pay-label { display: block; font-size: var(--fs-sm); font-weight: var(--fw-bold); color: var(--c-muted); }

/* Les trois grandes étapes du paiement : ① le numéro, ② le montant, ③ la capture. Compactes : à 360 × 640, le bouton
   de l'étape ③ tient dans l'écran une fois le moyen de paiement choisi (mesures dans le compte rendu du chantier). */
.pay-step { display: grid; gap: var(--space-2); }
.pay-step + .pay-step, .pay-block + .pay-step { margin-top: var(--space-3); }
.pay-step-title { display: flex; align-items: flex-start; gap: var(--space-2); margin: 0; font-size: var(--fs-md); line-height: 1.3; color: var(--c-heading); }
.pay-step-title:focus { outline: none; }
.pay-step-title:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 4px; border-radius: 4px; }
.pay-step-num { flex: none; display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--c-primary); color: var(--c-on-dark); font-size: var(--fs-sm); font-weight: var(--fw-heavy); }
.pay-step-title > span:last-child { padding-top: 3px; min-width: 0; }
.pay-big { font-size: min(var(--fs-3xl), 8.6vw); font-weight: var(--fw-heavy); color: var(--c-primary); line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pay-with { display: block; }
.pay-step-text { margin: 0; font-size: var(--fs-xs); line-height: 1.4; color: var(--c-muted); }
.pay-number { display: grid; gap: 2px; padding: var(--space-2) var(--space-3) var(--space-3); border: 1px solid var(--c-border); border-radius: var(--radius); background: var(--c-bg); }
.pay-block .pay-number .number { font-size: clamp(1.2rem, 6.4vw, 1.75rem); font-weight: var(--fw-heavy); letter-spacing: .01em; line-height: 1.2; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pay-block .pay-number .btn { width: 100%; min-height: 44px; margin-top: 6px; }
.pay-holder { font-size: var(--fs-xs); line-height: 1.35; }
.pay-proof { margin-top: var(--space-3); scroll-margin-top: 84px; }
.pay-proof .file-pick { display: grid; gap: var(--space-2); margin: 0; }
.pay-proof-hint { margin: var(--space-2) 0 0; }
.pay-when-file { display: none; }
.pay-form[data-has-file] .pay-when-file { display: inline; }
.pay-form[data-has-file] .pay-when-empty, .pay-form[data-has-file] .pay-arrow { display: none; }

/* Flèche vers le bouton de l'étape ③ : elle bouge doucement, sauf si le téléphone demande moins d'animations. */
.pay-arrow { display: inline-grid; place-items: center; vertical-align: middle; color: var(--c-accent-strong); line-height: 0; }
.pay-arrow .icon { width: 24px; height: 24px; transform: rotate(90deg); stroke-width: 2.75; }
@media (prefers-reduced-motion: no-preference) {
    .pay-arrow .icon { animation: pay-arrow 1.4s var(--ease) infinite; }
}
@keyframes pay-arrow { 0%, 100% { translate: 0 -3px; } 50% { translate: 0 4px; } }

/* Retour depuis l'application Mobile Money : le bouton est mis en évidence quelques secondes (payment-flow.js). */
.pick-first.is-highlighted { box-shadow: 0 0 0 4px var(--c-surface), 0 0 0 8px var(--c-accent); }
@media (prefers-reduced-motion: no-preference) {
    .pick-first.is-highlighted { animation: pay-highlight 1.2s var(--ease) 3; }
}
@keyframes pay-highlight { 0%, 100% { scale: 1; } 50% { scale: 1.03; } }

.pick-again { display: none; }
.js .pay-form:not([data-has-file]) .pay-submit { display: none; }
.pay-form[data-has-file] .pick-first { display: none; }
.pay-form[data-has-file] .pick-again { display: flex; }
.pay-form .proof-preview { max-height: min(320px, 28vh); margin: 0 auto; }

/* Texte lu seulement par les lecteurs d'écran (par exemple « Étape 1 sur 3 : »). */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Champ de capture : bouton français, le vrai champ reste accessible au clavier. */
.file-pick-input { position: absolute; left: 0; top: 0; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.file-pick { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); margin: var(--space-2) 0; cursor: pointer; font-weight: var(--fw-regular); }
.file-pick .btn { pointer-events: none; }
.file-pick-name { flex: 1 1 160px; min-width: 0; overflow-wrap: anywhere; color: var(--c-muted); font-size: var(--fs-sm); }
.file-pick-input:focus-visible + .file-pick .btn { outline: 3px solid var(--c-accent); outline-offset: 2px; }
.file-pick-input[aria-invalid="true"] + .file-pick .btn { box-shadow: inset 0 0 0 2px var(--c-danger); }
.pay-help h2 { font-size: var(--fs-lg); }
.pay-help .check-list { margin-bottom: var(--space-4); }
.pay-help .check-list li { font-weight: var(--fw-regular); }

/* ---------- Résultat de l'évaluation ---------- */
.section-tight { padding: var(--space-6) 0 0; }
.result-hero { position: relative; isolation: isolate; overflow: hidden; display: grid; gap: var(--space-4); justify-items: center; text-align: center; padding: var(--space-5) var(--space-4); border-radius: var(--radius-lg); background: var(--c-surface); border: 1px solid var(--c-border); box-shadow: var(--shadow-sm); border-top: 5px solid var(--c-accent); }
.result-hero::before { content: ""; position: absolute; z-index: -1; width: 320px; height: 320px; right: -120px; top: -140px; border-radius: 50%; background: radial-gradient(circle, var(--c-accent-soft) 0%, transparent 70%); animation: drift 14s ease-in-out infinite alternate; }
.result-teacher { width: 132px; height: 132px; border-radius: 50%; overflow: hidden; background: var(--c-bg-warm); box-shadow: 0 0 0 4px var(--c-surface), 0 0 0 7px var(--c-accent); }
.result-teacher img { display: block; width: 100%; height: 100%; transform: scale(2.5) translate(0, 19%); }
/* Message vocal pas encore prêt (« Un instant… ») : léger hochement de Teacher Joe. */
.result-teacher[data-waiting] { animation: nod 1.2s ease-in-out infinite; }
.result-main h1 { margin: 0; font-size: var(--fs-2xl); }
.result-level { color: var(--c-accent-strong); }
.result-label { margin: var(--space-1) 0 var(--space-3); font-size: var(--fs-lg); font-weight: var(--fw-heavy); color: var(--c-heading); }
.result-feedback { max-width: 60ch; margin: 0 auto var(--space-4); }
/* La suite, dans le haut du résultat : phrase et bouton orange avant l'avis, le tableau et les formules. */
.result-next { display: grid; justify-items: center; gap: var(--space-3); max-width: 60ch; margin: 0 auto var(--space-5); padding: var(--space-4); border-radius: var(--radius); background: var(--c-accent-soft); }
.result-next-text { margin: 0; font-weight: var(--fw-bold); color: var(--c-heading); }
.result-next .btn-next { width: 100%; max-width: 420px; }
.result-voice { display: grid; justify-items: center; gap: var(--space-2); }
.result-voice [hidden] { display: none; }
.result-transcript { margin-top: var(--space-3); max-width: 60ch; margin-inline: auto; text-align: left; }
.result-transcript summary { cursor: pointer; text-align: center; font-weight: var(--fw-bold); color: var(--c-primary); min-height: 44px; display: flex; align-items: center; justify-content: center; }
.result-transcript p { margin: var(--space-2) 0 0; padding: var(--space-3); background: var(--c-bg); border-radius: var(--radius); }
.next-card { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); margin-top: var(--space-5); }
.next-card > div { flex: 1 1 220px; }
.next-card h2 { margin: 0 0 var(--space-1); font-size: var(--fs-lg); }
.next-card p { margin: 0; }
.level-picker summary { cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); min-height: 44px; }
.level-picker summary::-webkit-details-marker { display: none; }
.level-picker summary::after { content: "+"; font-size: var(--fs-xl); font-weight: var(--fw-heavy); color: var(--c-primary); }
.level-picker[open] summary::after { content: "−"; }
.level-picker summary h2 { margin: 0; font-size: var(--fs-lg); }
.level-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); margin: var(--space-3) 0; }
.level-option { position: relative; display: block; margin: 0; cursor: pointer; }
.level-option input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.level-option-body { display: grid; gap: 2px; min-height: 72px; padding: var(--space-3); border: 2px solid var(--c-border); border-radius: var(--radius); background: var(--c-surface); transition: border-color var(--dur-fast), background var(--dur-fast); }
.level-option-body strong { font-size: var(--fs-lg); color: var(--c-heading); }
.level-option-body span { font-size: var(--fs-sm); color: var(--c-muted); }
.level-option-body .badge { justify-self: start; margin-top: 4px; color: var(--c-accent-ink); }
.level-option input:checked + .level-option-body { border-color: var(--c-primary); background: var(--c-primary-soft); }
.level-option input:focus-visible + .level-option-body { outline: 3px solid var(--c-accent); outline-offset: 2px; }
.level-warning { display: none; }
.level-choice:has(input[data-higher]:checked) .level-warning { display: flex; }
@media (min-width: 640px) {
    .result-hero { grid-template-columns: auto 1fr; justify-items: start; text-align: left; padding: var(--space-6); gap: var(--space-6); align-items: center; }
    .result-teacher { width: 168px; height: 168px; }
    .result-feedback, .result-transcript { margin-inline: 0; }
    .result-voice { justify-items: start; }
    .result-transcript summary { justify-content: flex-start; }
    .level-options { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 900px) {
    .level-options { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}

/* ---------- Conversation vocale avec le professeur ---------- */

.live { max-width: 560px; margin: 0 auto; }
.live-head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); margin-bottom: var(--space-3); }
.live-head h1 { font-size: var(--fs-xl); margin: 0; }
.teacher { position: relative; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; margin: 0 0 var(--space-3); padding: var(--space-4); border-radius: var(--radius-lg); background: radial-gradient(circle at 50% 35%, var(--c-surface) 0%, var(--c-bg-warm) 75%); border: 1px solid var(--c-border); }
.face { width: 180px; height: 225px; }
.face-vest { fill: var(--c-primary); }
.face-shirt { fill: var(--c-surface); }
.face-tie { fill: var(--c-accent); }
.face-skin { fill: #8d5a3b; }
.face-hair { fill: #2b1a12; }
.face-eyes { fill: #1d1410; animation: blink 5s infinite; transform-origin: 100px 92px; }
.face-brows { fill: none; stroke: #2b1a12; stroke-width: 4; stroke-linecap: round; }
.face-mouth { fill: #4a1f1a; }
/* Attente de la réponse (« Un instant… ») : petit hochement du visage simple. */
[data-waiting] .face { animation: nod 1.2s ease-in-out 2; transform-origin: 50% 80%; }
@keyframes nod { 0%, 100% { transform: none; } 40% { transform: translateY(3px) rotate(1deg); } }
@keyframes blink { 0%, 96%, 100% { transform: scaleY(1); } 98% { transform: scaleY(.1); } }
/* Professeur 3D (remplace le visage SVG quand il est chargé) */
.teacher-3d { padding: 0; overflow: hidden; background: var(--c-bg-warm); }
.teacher3d-stage { display: none; }
.teacher-3d .face { display: none; }
.teacher-3d .teacher3d-stage { display: block; width: 100%; height: clamp(210px, 36vh, 340px); }
.teacher3d-canvas { display: block; width: 100%; height: 100%; }
.teacher3d-loading { width: 100%; text-align: center; font-size: var(--fs-xs); color: var(--c-muted); margin-top: var(--space-2); }
.teacher3d-loading progress { display: block; width: 60%; height: 6px; margin: 6px auto 0; accent-color: var(--c-primary); }
/* Attente de l'arrivée du professeur (data-teacher="loading") : nom, phrase rassurante, trois points orange qui
   pulsent et une barre fine, sans texte technique. */
.teacher-wait { display: flex; flex-direction: column; align-items: center; gap: var(--space-2); margin: 0; }
.teacher-wait[hidden] { display: none; }
.teacher-wait-title { margin: 0; font-size: var(--fs-lg); font-weight: var(--fw-bold); color: var(--c-primary); }
.teacher-wait-text { margin: 0; font-size: var(--fs-sm); color: var(--c-muted); }
.teacher-wait-dots { display: inline-flex; gap: 8px; }
.teacher-wait-dots span { width: 12px; height: 12px; border-radius: 50%; background: var(--c-accent); opacity: .35; animation: teacher-wait 1.2s ease-in-out infinite; }
.teacher-wait-dots span:nth-child(2) { animation-delay: .2s; }
.teacher-wait-dots span:nth-child(3) { animation-delay: .4s; }
.teacher-wait progress { appearance: none; -webkit-appearance: none; width: min(180px, 60%); height: 3px; margin: var(--space-1) auto 0; border: 0; border-radius: 3px; overflow: hidden; background: var(--c-primary-soft); color: var(--c-accent); }
.teacher-wait progress::-webkit-progress-bar { background: var(--c-primary-soft); }
.teacher-wait progress::-webkit-progress-value { background: var(--c-accent); transition: width var(--dur) ease-out; }
.teacher-wait progress::-moz-progress-bar { background: var(--c-accent); }
@keyframes teacher-wait { 0%, 100% { opacity: .35; transform: scale(.85); } 50% { opacity: 1; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .teacher-wait-dots span { animation: none; opacity: .8; } }
/* 3D en chargement (data-teacher="loading") : un emplacement de la taille du professeur 3D avec la barre, jamais le
   visage simple (il n'apparaît qu'en repli). Sans JavaScript, le visage simple reste. */
.js [data-teacher="loading"] .face { display: none; }
.js [data-teacher="loading"] .teacher { min-height: clamp(210px, 36vh, 340px); }
.teacher3d-toggle { display: block; margin: -4px auto var(--space-2); font-size: var(--fs-xs); }
/* Séance du jour : annonce du temps en cours (pratique, conversation, bilan), sous le professeur, sans bouton. */
.phase-note { display: flex; align-items: center; gap: var(--space-2); margin: 0 0 var(--space-3); padding: var(--space-2) var(--space-3); border-radius: var(--radius); background: var(--c-primary); color: var(--c-on-dark); font-weight: var(--fw-bold); font-size: var(--fs-sm); animation: rise var(--dur) ease-out both; }
.phase-note .icon { flex: none; color: var(--c-accent); }
.live[data-teacher="3d"] .subtitles { height: 26vh; }
.live-bar { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); margin-bottom: var(--space-3); background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: var(--space-3) var(--space-4); box-shadow: var(--shadow-sm); }
.live-bar .label { display: flex; align-items: center; gap: 6px; color: var(--c-muted); font-size: var(--fs-sm); font-weight: var(--fw-bold); }
.timer { font-size: var(--fs-3xl); font-weight: var(--fw-heavy); font-variant-numeric: tabular-nums; line-height: 1.1; }
.timer-low { color: var(--c-danger); animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .55; } }
.live-status { display: inline-flex; align-items: center; gap: 6px; background: var(--c-primary-soft); color: var(--c-primary-strong); border-radius: var(--radius-pill); padding: 6px 12px; font-size: var(--fs-sm); font-weight: var(--fw-bold); text-align: right; }
.live-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--c-primary); flex: none; }
.intro-text { margin-bottom: var(--space-3); }
.intro-tips { list-style: none; padding: 0; margin: var(--space-4) 0 0; display: grid; gap: var(--space-2); font-size: var(--fs-sm); color: var(--c-muted); }
.intro-tips li { display: flex; gap: var(--space-2); align-items: flex-start; }
.intro-tips .icon { color: var(--c-primary); margin-top: 1px; }
.subtitles { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: var(--space-3); height: 38vh; min-height: 160px; overflow-y: auto; margin-bottom: var(--space-3); box-shadow: var(--shadow-sm); }
.subtitles .line { margin: 0 0 var(--space-2); padding: var(--space-2) var(--space-3); border-radius: var(--radius); background: var(--c-bg); animation: rise var(--dur) var(--ease) both; }
.subtitles .line::before { content: attr(data-speaker) " : "; font-weight: var(--fw-heavy); }
.line-teacher { background: var(--c-primary-soft) !important; margin-right: var(--space-6) !important; }
.line-teacher::before { color: var(--c-primary-strong); }
.line-learner { color: var(--c-text); margin-left: var(--space-6) !important; }
.line-learner::before { color: var(--c-accent-strong); }
.live-actions { display: grid; gap: var(--space-3); }
/* Tour de parole et boutons de la conversation (grands, faciles à toucher). */
.live-turn { display: flex; align-items: center; justify-content: center; gap: var(--space-3); margin-bottom: var(--space-3); padding: var(--space-3) var(--space-4); border-radius: var(--radius-lg); font-size: var(--fs-lg); font-weight: var(--fw-heavy); background: var(--c-primary-soft); color: var(--c-primary-strong); border: 2px solid var(--c-primary-line); }
.live-turn-dot { width: 14px; height: 14px; border-radius: 50%; background: var(--c-primary); flex: none; }
.live-turn[data-turn="listening"] { background: var(--c-accent-soft); color: var(--c-accent-ink); border-color: var(--c-accent); }
.live-turn[data-turn="listening"] .live-turn-dot { background: var(--c-accent); animation: pulse 1.2s ease-in-out infinite; }
.live-turn[data-turn="speaking"] .live-turn-dot { animation: pulse .7s ease-in-out infinite; }
.live-turn[data-turn="thinking"] .live-turn-dot { background: var(--c-primary-bright); animation: pulse 1.6s ease-in-out infinite; }
.live-turn[data-turn="paused"], .live-turn[data-turn="muted"] { background: var(--c-bg-warm); color: var(--c-muted); border-color: var(--c-border); }
.live-turn[data-turn="paused"] .live-turn-dot, .live-turn[data-turn="muted"] .live-turn-dot { background: var(--c-muted); }
.mic-panel { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); margin-bottom: var(--space-3); }
.mic-meter { display: flex; align-items: center; gap: var(--space-2); flex: 1 1 140px; color: var(--c-primary); }
.mic-meter-track { flex: 1; height: 10px; border-radius: var(--radius-pill); background: var(--c-bg-warm); overflow: hidden; }
.mic-meter-bar { display: block; height: 100%; background: var(--c-accent); transform-origin: left center; transform: scaleX(0); transition: transform 80ms linear; }
.mic-choice { display: flex; align-items: center; gap: var(--space-2); margin: 0; font-size: var(--fs-sm); flex: 1 1 220px; }
.mic-choice select { min-height: 44px; padding: 8px 10px; }
.live-controls { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); margin-bottom: var(--space-3); }
.live-control { min-height: 64px; padding: 12px; font-size: var(--fs-md); }
.live-control > span { display: inline-flex; align-items: center; gap: var(--space-2); }
.live-control-wide { grid-column: 1 / -1; }
.live-control[aria-pressed="true"] { background: var(--c-accent); color: var(--c-on-accent); box-shadow: none; }
/* « Enregistrer ma séance » : discret, sous les commandes ; point rouge pendant l'enregistrement. */
.recorder { margin-bottom: var(--space-3); }
/* Avant « Commencer » : juste sous le bouton (live-session.js → placeRecorder). */
#intro .recorder { margin: var(--space-3) 0 0; }
.recorder #record-start[aria-pressed="true"] { border-color: var(--c-accent); }
.recorder-armed, .recorder-note { margin: var(--space-2) 0 0; font-size: var(--fs-sm); color: var(--c-muted); }
.recorder-live { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); padding: var(--space-3); border: 1px solid var(--c-danger-line); border-radius: var(--radius-lg); background: var(--c-danger-soft); color: var(--c-danger-strong); font-weight: var(--fw-bold); }
.recorder-live[hidden], .recorder [hidden] { display: none; }
.recorder-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--c-danger); animation: recorder-blink 1.2s ease-in-out infinite; }
.recorder-stop { margin-left: auto; }
#record-download { flex-wrap: wrap; justify-content: center; }
.recorder-ready, .recorder-saved { display: flex; gap: var(--space-2); align-items: flex-start; margin: var(--space-3) 0 var(--space-2); font-weight: var(--fw-bold); }
.recorder-ready { padding: var(--space-3); border: 1px solid var(--c-warning-line); border-radius: var(--radius); background: var(--c-warning-soft); color: var(--c-warning); }
.recorder-saved { font-size: var(--fs-sm); font-weight: 400; color: var(--c-muted); }
.recorder-ready .icon, .recorder-saved .icon { flex: none; margin-top: 3px; }
.recorder.is-ready { margin-top: var(--space-4); }
.recorder-size { flex-basis: 100%; font-size: var(--fs-sm); font-weight: 400; }
#record-time { font-variant-numeric: tabular-nums; }
@keyframes recorder-blink { 50% { opacity: 0.35; } }
@media (prefers-reduced-motion: reduce) { .recorder-dot { animation: none; } }
/* Paysage (téléphone couché) et ordinateur : le professeur à gauche, toujours entier à l'écran,
   les commandes à droite ; « Commencer » visible sans faire défiler. */
@media (min-width: 900px), (orientation: landscape) and (max-height: 560px) {
    .live { max-width: 1080px; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); grid-template-rows: auto 1fr; column-gap: var(--space-5); align-items: start; }
    .live-head { grid-column: 2; grid-row: 1; }
    .live-stage { grid-column: 1; grid-row: 1 / span 2; position: sticky; top: var(--space-3); }
    .live-panel { grid-column: 2; grid-row: 2; min-width: 0; }
    .live-stage .teacher { height: var(--stage-height); margin-bottom: var(--space-2); }
    .live-stage .face { height: min(440px, calc(var(--stage-height) - 2 * var(--space-4))); width: auto; }
    .teacher-3d .teacher3d-stage { height: 100%; }
    .live { --stage-height: clamp(220px, calc(100vh - 180px), 560px); }
}
@media (orientation: landscape) and (max-height: 560px) {
    .live { --stage-height: max(190px, calc(100vh - 132px)); column-gap: var(--space-4); }
    .live-head h1 { font-size: var(--fs-lg); }
    .live-stage { top: var(--space-2); }
    .intro-text { font-size: var(--fs-sm); }
    .live[data-teacher="3d"] .subtitles, .subtitles { height: 40vh; min-height: 120px; }
}
/* Hauteur réellement visible (barres du navigateur déduites) quand le navigateur la connaît. */
@supports (height: 1dvh) {
    @media (min-width: 900px) { .live { --stage-height: clamp(220px, calc(100dvh - 180px), 560px); } }
    @media (orientation: landscape) and (max-height: 560px) { .live { --stage-height: max(190px, calc(100dvh - 132px)); } }
}

#outcome { border-top: 4px solid var(--c-accent); animation: rise var(--dur) var(--ease) both; }
#outcome h2 { color: var(--c-primary); }

/* ---------- Administration : sobre ---------- */
.voice-list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.voice-item { display: grid; gap: var(--space-2); padding: var(--space-3); border: 1px solid var(--c-border); border-radius: var(--radius); }
.voice-item.is-current { border-color: var(--c-primary); background: var(--c-primary-soft); }
.voice-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }

.admin main { padding-top: var(--space-4); }
.admin .card { box-shadow: none; border-radius: var(--radius); }
/* Onglets de l'administration : sur plusieurs lignes, tous visibles (rien de caché à faire défiler). */
.tabs { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-bottom: var(--space-5); }
.tabs a { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border: 1px solid var(--c-border); border-radius: var(--radius-pill); background: var(--c-surface); text-decoration: none; white-space: nowrap; font-weight: var(--fw-bold); font-size: var(--fs-sm); color: var(--c-text); }
.tabs a:hover { border-color: var(--c-primary-line); background: var(--c-primary-soft); }
.tabs a.active { background: var(--c-primary); border-color: var(--c-primary); color: var(--c-on-dark); }
.tabs a .icon { color: var(--c-accent-strong); stroke-width: 2.25; }
.tabs a.active .icon { color: var(--c-accent); }
/* « Aperçu des icônes » (administration) : un bloc par style. */
.icon-preview { margin-top: var(--space-6); padding: var(--space-5) var(--space-4); border-radius: var(--radius-lg); background: var(--c-bg-warm); }
.icon-preview-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-2); margin-bottom: var(--space-4); }
.icon-preview-head h2 { margin: 0; font-size: var(--fs-lg); }
.icon-preview-grid .feature h3 { font-size: var(--fs-md); }
.icon-preview-extras { display: grid; gap: var(--space-3); margin-top: var(--space-4); }
.icon-preview-extras h3 { margin: 0; }
@media (min-width: 900px) { .icon-preview-extras { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; } }
.inline-form { display: inline; margin: 0; }
.search { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-bottom: var(--space-4); }
.search select { flex: 1 1 10rem; width: auto; }
.search input { flex: 1 1 12rem; min-width: 0; }
.table { width: 100%; border-collapse: collapse; background: var(--c-surface); }
.table th, .table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--c-border); vertical-align: top; }
.table th { font-size: var(--fs-sm); color: var(--c-muted); }
@media (max-width: 639px) {
    .table thead { display: none; }
    .table, .table tbody, .table tr, .table td { display: block; width: 100%; }
    .table tr { border: 1px solid var(--c-border); border-radius: var(--radius); margin-bottom: 10px; padding: 8px 0; }
    .table td { border: 0; padding: 4px 14px; }
    .table td::before { content: attr(data-label) " : "; color: var(--c-muted); font-size: var(--fs-sm); }
}
.payment-grid { display: grid; gap: var(--space-4); }
.proof img { display: block; width: 100%; max-height: 420px; object-fit: contain; background: var(--c-bg-warm); border-radius: var(--radius); }
.payment-actions { display: grid; gap: var(--space-3); margin-top: var(--space-3); }
.payment-actions form { margin: 0; }
.filters { display: grid; gap: 0 var(--space-3); }
.filters .btn { align-self: end; margin-bottom: var(--space-4); }

/* ---------- Apparition des blocs (seulement si JavaScript est actif) ---------- */

@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
.js .reveal { opacity: 0; transform: translateY(10px); transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease); transition-delay: calc(var(--i, 0) * 50ms); }
.js .reveal.is-visible { opacity: 1; transform: none; }
.rise { animation: rise var(--dur-slow) var(--ease) both; animation-delay: calc(var(--i, 0) * 80ms); }

/* Transitions entre les pages (navigateurs récents) */
@view-transition { navigation: auto; }

/* ---------- Écrans plus larges ---------- */

@media (min-width: 640px) {
    :root { --gutter: 24px; }
    h1 { font-size: var(--fs-3xl); }
    .hero h1 { font-size: 2.6rem; }
    .actions-row { grid-template-columns: max-content max-content; }
    .actions-row .btn-block { width: auto; }
    .plans { grid-template-columns: repeat(3, 1fr); }
    .stats { grid-template-columns: repeat(3, 1fr); }
    .features { grid-template-columns: repeat(2, 1fr); gap: var(--space-5); }
    .levels { grid-template-columns: repeat(6, minmax(0, 1fr)); }
    .levels li:nth-child(n)::before { left: 0; right: 0; }
    .levels li:first-child::before { left: 50%; }
    .levels li:last-child::before { right: 50%; }
    .choices { grid-template-columns: repeat(3, 1fr); }
    .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; }
    .payment-grid { grid-template-columns: 240px 1fr; }
    .payment-actions { grid-template-columns: 1fr 2fr; align-items: start; }
    .filters { grid-template-columns: repeat(4, 1fr) auto; }
    .card { padding: var(--space-6); }
    .cta-band { padding: var(--space-10) var(--space-8); }
    .how { grid-template-columns: repeat(2, 1fr); gap: var(--space-4); }
    .students { padding: var(--space-10) var(--space-8); grid-template-columns: 1fr 1.2fr; gap: var(--space-8); }
    .students-reverse .photo-frame { order: 2; }
    .section-split { grid-template-columns: 1.2fr 1fr; gap: var(--space-8); }
    .credit-photo { grid-template-columns: 180px 1fr; align-items: center; }
}

@media (min-width: 900px) {
    main { padding-top: var(--space-8); }
    .hero { grid-template-columns: 1.1fr .9fr; gap: var(--space-10); padding-bottom: var(--space-10); }
    .hero h1 { font-size: 3.1rem; }
    .hero-teacher { display: none; }
    .hero-eyebrow { display: inline-flex; }
    .hero-media { width: 100%; max-width: 420px; }
    .features { grid-template-columns: repeat(2, 1fr); }
    .how { grid-template-columns: repeat(4, 1fr); }
}

/* Ordinateur : navigation complète avec libellés, plus de menu ni de barre du bas. */
@media (min-width: 1200px) {
    .nav-desktop { display: flex; gap: 2px; }
    .nav-desktop a, .nav-desktop .btn-link { padding: var(--space-2) 9px; }
    .menu { display: none; }
    .tabbar { display: none; }
    .has-tabbar main { padding-bottom: var(--space-12); }
    .has-tabbar .site-footer { padding-bottom: var(--space-6); }
    .has-tabbar .install { bottom: calc(var(--space-3) + env(safe-area-inset-bottom)); }
    .has-install-bar.has-tabbar .site-footer { padding-bottom: calc(var(--space-6) + 64px); }
}

/* Administrateur : un lien et une pastille de plus, la navigation complète ne tient qu'à partir de 1440 pixels. */
@media (min-width: 1200px) and (max-width: 1439px) {
    .is-admin-user .nav-desktop { display: none; }
    .is-admin-user .menu { display: block; }
}

/* ---------- Réduire les animations (réglage du téléphone) ---------- */

@media (prefers-reduced-motion: reduce) {
    .hero::before, .hero::after, .hero-blob, .hero-bubble, .students::before, .cta-band::before, .cta-band::after, .result-hero::before { animation: none !important; }
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
    .js .reveal { opacity: 1; transform: none; }
    .face-eyes { animation: none; }
    @view-transition { navigation: none; }
}

/* Capture d'écran d'un paiement : aperçu (apprenant) et vignette agrandissable (administration). */
.proof-preview { display: block; max-width: 100%; max-height: 320px; margin-top: var(--space-3); border: 1px solid var(--c-border); border-radius: var(--radius-sm); }
.proof-thumb { display: inline-block; }
.proof-thumb img { display: block; width: 120px; max-height: 220px; object-fit: cover; object-position: top; border: 1px solid var(--c-border); border-radius: var(--radius-sm); }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-2); }
.checks li { display: flex; gap: var(--space-2); align-items: flex-start; }
.checks .icon { flex: none; margin-top: 2px; }
.checks .ok { color: var(--c-primary); }
.checks .ko { color: var(--c-danger); }

/* Message de confirmation (session « status ») : en haut de la page, aux couleurs de la marque,
   disparaît tout seul après --toast-delay (animation CSS : fonctionne sans JavaScript). */
.toast { position: fixed; z-index: 60; top: calc(env(safe-area-inset-top, 0px) + var(--space-3)); left: 50%; width: min(560px, calc(100% - 2 * var(--space-4))); display: flex; gap: var(--space-3); align-items: flex-start; padding: 14px var(--space-4); border-radius: var(--radius); background: var(--c-primary); color: var(--c-on-dark); border-left: 4px solid var(--c-accent); box-shadow: var(--shadow-lg); transform: translateX(-50%); animation: toast-in var(--dur) ease-out, toast-out var(--dur-slow) ease-in var(--toast-delay, 5s) forwards; }
.toast > .icon { flex: none; margin-top: 2px; color: var(--c-accent); }
.toast > div { flex: 1; }
.toast-close { flex: none; margin: -6px -8px -6px 0; padding: 6px; background: none; border: 0; color: var(--c-on-dark); cursor: pointer; border-radius: var(--radius-sm); }
.toast-close:focus-visible { outline: 2px solid var(--c-focus); }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, -12px); } }
@keyframes toast-out { to { opacity: 0; visibility: hidden; transform: translate(-50%, -12px); } }

/* Confirmation des actions graves : fenêtre intégrée (<dialog>, public/js/app.js) et page de repli. */
.confirm-dialog { width: min(460px, calc(100% - 2 * var(--space-4))); max-width: none; padding: 0; border: 0; border-radius: var(--radius-lg); background: var(--c-surface); color: var(--c-text); box-shadow: var(--shadow-lg); }
.confirm-dialog::backdrop { background: color-mix(in srgb, var(--c-primary-deep) 60%, transparent); }
.confirm-dialog-box { margin: 0; padding: var(--space-5); border-top: 4px solid var(--c-accent); border-radius: var(--radius-lg); }
.confirm-dialog h2 { margin: 0 0 var(--space-2); font-size: var(--fs-xl); color: var(--c-heading); }
.confirm-dialog p { margin: 0; }
.confirm-actions { display: grid; gap: var(--space-2); margin-top: var(--space-4); }
@media (min-width: 640px) {
    .confirm-actions { grid-template-columns: 1fr 1fr; }
    .confirm-actions .btn-light { order: -1; }
}

/* ---------- Mes cours (complément facultatif) ---------- */
.course-counter { display: flex; align-items: center; gap: var(--space-2); margin: var(--space-3) 0; font-weight: var(--fw-bold); }
.course-counter .icon { flex: none; color: var(--c-accent-strong); }
.course-card { display: grid; gap: var(--space-3); }
.course-card h3 { margin: 0 0 var(--space-1); font-size: var(--fs-lg); overflow-wrap: anywhere; }
.course-card h3 a { text-decoration: none; }
.course-card p { margin: 0; }
.course-card-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.course-card-actions form { margin: 0; }
.course-choices { position: relative; display: grid; gap: var(--space-3); margin-bottom: var(--space-3); }
.course-choice { margin: 0; }
.course-step { font-size: var(--fs-lg); margin: 0 0 var(--space-3); }
.course-step-2 { margin-top: var(--space-6); }
.course-previews { list-style: none; margin: var(--space-4) 0; padding: 0; display: grid; gap: var(--space-3); grid-template-columns: repeat(2, minmax(0, 1fr)); }
.course-preview { display: grid; gap: var(--space-2); align-content: start; padding: var(--space-2); border: 1px solid var(--c-border); border-radius: var(--radius); background: var(--c-surface); }
.course-preview img { display: block; width: 100%; height: 150px; object-fit: cover; object-position: top; border-radius: var(--radius-sm); }
.course-preview-pdf { display: grid; place-items: center; height: 150px; border-radius: var(--radius-sm); background: var(--c-primary-soft); color: var(--c-primary-strong); font-weight: var(--fw-heavy); font-size: var(--fs-xl); }
.course-preview-name { font-size: var(--fs-xs); color: var(--c-muted); overflow-wrap: anywhere; }
.course-preview-remove { min-height: 44px; padding: 8px 10px; font-size: var(--fs-sm); }
.js .course-form:not([data-has-files]) .course-submit { display: none; }
.course-tips { margin: var(--space-4) 0; padding: var(--space-3) var(--space-4); border-radius: var(--radius); background: var(--c-bg); }
.course-tips h3 { font-size: var(--fs-md); margin: 0 0 var(--space-2); }
.course-tips .check-list { margin-bottom: 0; }
.course-error .check-list { margin: var(--space-2) 0 0; }
.course-waiting { margin-top: var(--space-3); }
.course-pages { list-style: none; margin: 0 0 var(--space-3); padding: 0; display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: flex-start; }
.course-pages li { display: grid; gap: var(--space-1); justify-items: start; }
.course-details { margin-top: var(--space-3); border-top: 1px solid var(--c-border); padding-top: var(--space-2); }
.course-details summary { display: flex; align-items: center; min-height: 44px; cursor: pointer; font-weight: var(--fw-bold); }
.course-point { margin: var(--space-3) 0; }
.course-point p { margin: var(--space-1) 0 0; }
.course-words { margin: var(--space-2) 0 0; padding-left: var(--space-5); }
.course-words li { margin-bottom: var(--space-1); overflow-wrap: anywhere; }
@media (min-width: 640px) {
    .course-choices { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .course-previews { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
/* Titre et boutons côte à côte seulement s'il reste au moins 14 rem au titre (page étroite) ; sinon les boutons passent dessous. */
.course-card { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.course-card-body { flex: 1 1 14rem; min-width: 0; }
.course-extract { max-height: 260px; overflow: auto; padding: var(--space-3); border-radius: var(--radius-sm); background: var(--c-bg); white-space: pre-wrap; overflow-wrap: anywhere; font-family: inherit; font-size: var(--fs-sm); }

/* Accueil : aide aux cours d'anglais des élèves (étapes avec icônes) */
.help-steps { list-style: none; padding: 0; margin: var(--space-4) 0; display: grid; gap: var(--space-3); }
.help-steps li { display: flex; gap: var(--space-3); align-items: center; font-weight: var(--fw-bold); }
.help-steps .icon-bubble { flex: none; width: 44px; height: 44px; }
.help-only { display: flex; gap: var(--space-2); align-items: center; margin: 0 0 var(--space-3); font-weight: var(--fw-heavy); color: var(--c-accent-strong); }
.help-only .icon { flex: none; }

/* Accès offert (administration) */
.badge-grant { background: var(--c-accent-soft); color: var(--c-accent-ink); }
.grant-current { display: flex; gap: var(--space-2); align-items: flex-start; margin: 0 0 var(--space-3); }
.grant-current .icon { flex: none; margin-top: 3px; color: var(--c-accent-strong); }
.grant-durations { border: 0; padding: 0; margin: 0 0 var(--space-4); display: flex; flex-wrap: wrap; gap: var(--space-2); }
.grant-durations legend { font-weight: var(--fw-bold); margin-bottom: var(--space-2); padding: 0; }
.grant-durations label { display: inline-flex; align-items: center; gap: var(--space-2); min-height: 44px; padding: 0 var(--space-4); border: 1px solid var(--c-border); border-radius: var(--radius-pill); background: var(--c-surface); font-weight: var(--fw-bold); cursor: pointer; margin: 0; }
.grant-durations label:has(input:checked) { border-color: var(--c-primary); box-shadow: 0 0 0 3px var(--c-ring); }
.grant-history { margin: 0 0 var(--space-3); }

/* Bienvenue de Teacher Joe : professeur en grand sur un fond aux couleurs de la marque */
.welcome-page { max-width: 560px; margin: 0 auto; padding: var(--space-5) var(--space-4) var(--space-6); border-radius: var(--radius-lg); color: var(--c-on-dark);
    background: radial-gradient(120% 70% at 50% 0%, var(--c-primary-raised) 0%, var(--c-primary) 55%, var(--c-primary-strong) 100%); box-shadow: var(--shadow-lg); position: relative; overflow: hidden; isolation: isolate; }
.welcome-page::before { content: ""; position: absolute; z-index: -1; width: 320px; height: 320px; border-radius: 50%; left: -120px; bottom: 18%; background: radial-gradient(circle, rgba(255, 122, 26, .22), transparent 70%); pointer-events: none; }
.welcome-head { text-align: center; margin-bottom: var(--space-3); }
.welcome-page h1 { color: var(--c-on-dark); margin: 0 0 var(--space-1); }
.welcome-lead { color: var(--c-on-dark-muted); margin: 0; font-size: var(--fs-lg); }
.welcome-page .teacher { background: transparent; border: 0; margin: 0; padding: 0; }
.welcome-page .teacher-3d .teacher3d-stage { height: clamp(300px, 52dvh, 480px); }
.js .welcome-page[data-teacher="loading"] .teacher { min-height: clamp(300px, 52dvh, 480px); }
.welcome-page .face { width: min(260px, 70%); height: auto; }
.welcome-page .teacher3d-loading { color: var(--c-on-dark-muted); }
.welcome-page .teacher3d-loading progress { accent-color: var(--c-accent); }
.welcome-page .teacher-wait-title { color: var(--c-on-dark); }
.welcome-page .teacher-wait-text { color: var(--c-on-dark-muted); }
.welcome-page .teacher-wait progress { background: var(--c-on-dark-line); }
.welcome-page .teacher-wait progress::-webkit-progress-bar { background: var(--c-on-dark-line); }
.welcome-page .btn-link, .welcome-page .btn-link:hover { color: var(--c-on-dark); }
.welcome-page .btn-light, .welcome-page .btn-light:hover, .welcome-page .btn-light:focus-visible { background: var(--c-on-dark-glow); color: var(--c-on-dark); border: 1px solid var(--c-on-dark-line); box-shadow: none; }
.welcome-panel { display: grid; gap: var(--space-3); }
.welcome-start { text-align: center; }
.welcome-hint { color: var(--c-on-dark-muted); font-size: var(--fs-sm); margin: var(--space-2) 0 0; }
.welcome-controls { display: flex; align-items: center; justify-content: center; gap: var(--space-3); }
.welcome-status { text-align: center; color: var(--c-on-dark-muted); margin: 0; }
.welcome-subtitles { max-height: 11.5em; overflow-y: auto; padding: var(--space-3) var(--space-4); border-radius: var(--radius); background: var(--c-on-dark-glow); border: 1px solid var(--c-on-dark-line); line-height: 1.55; }
.welcome-subtitles p { margin: 0 0 var(--space-2); color: var(--c-on-dark-muted); }
.welcome-subtitles p:last-child { margin-bottom: 0; }
.welcome-subtitles .sentence { border-radius: 4px; transition: color var(--dur-fast), background var(--dur-fast); }
.welcome-subtitles .sentence.is-now { color: var(--c-on-dark); background: rgba(255, 122, 26, .28); box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.js .welcome-next { display: none; }
.js .welcome-next.is-shown { display: flex; animation: rise var(--dur) var(--ease) both; }
.welcome-replay { margin-top: var(--space-1); font-size: var(--fs-sm); }
@media (min-width: 900px) {
    .welcome-page { max-width: 980px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: var(--space-6); align-items: center; padding: var(--space-8); }
    .welcome-head { grid-column: 1 / -1; }
    .welcome-page .teacher-3d .teacher3d-stage { height: clamp(360px, 60dvh, 560px); }
}
@media (prefers-reduced-motion: reduce) { .js .welcome-next.is-shown { animation: none; } }

/* ---------- Navigation automatique ---------- */

/* Une partie visée par un lien (#…) s'arrête sous l'en-tête collant, jamais dessous. */
main [id], main h1, main h2 { scroll-margin-top: 84px; }
/* Titre qui reçoit le focus après un lien vers sa partie : pas de cadre au clic, un cadre au clavier. */
[tabindex="-1"]:focus { outline: none; }
[tabindex="-1"]:focus-visible { outline: 2px solid var(--c-focus); outline-offset: 4px; border-radius: var(--radius-sm); }

/* Message d'erreur d'un formulaire, en haut de l'écran comme le message de réussite. */
.toast-error { border-left-color: var(--c-danger); }
.toast-error > .icon { color: var(--c-on-dark); }

/* Bouton d'envoi pendant l'envoi : « Envoi en cours… », un second toucher est ignoré (public/js/app.js). */
.is-busy { cursor: progress; opacity: .8; pointer-events: none; }
.busy-spinner { display: inline-block; width: 1em; height: 1em; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; vertical-align: -.15em; animation: busy-spin .8s linear infinite; }
@keyframes busy-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .busy-spinner { animation: none; border-right-color: currentColor; opacity: .6; } }

/* Lecture d'une conversation (administration) : bulles distinctes, pensées pour le téléphone. */
.conversation-facts { list-style: none; margin: var(--space-3) 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); }
.conversation-facts li { display: inline-flex; align-items: center; gap: var(--space-2); font-weight: var(--fw-heavy); color: var(--c-heading); }
.chat { list-style: none; margin: var(--space-4) 0; padding: 0; display: grid; gap: var(--space-3); }
.chat-bubble { max-width: 88%; padding: var(--space-2) var(--space-3); border-radius: var(--radius-lg); border: 1px solid var(--c-border); background: var(--c-surface); }
.chat-bubble p { margin: 0; }
.chat-teacher { justify-self: start; background: var(--c-primary-soft); border-color: var(--c-primary-line); border-bottom-left-radius: var(--space-1); }
.chat-learner { justify-self: end; background: var(--c-accent-soft); border-color: var(--c-accent-line); border-bottom-right-radius: var(--space-1); }
.chat-meta { display: flex; justify-content: space-between; gap: var(--space-3); font-size: var(--fs-sm); color: var(--c-muted); margin-bottom: var(--space-1) !important; }
.chat-teacher .chat-meta strong { color: var(--c-primary-strong); }
.chat-learner .chat-meta strong { color: var(--c-accent-ink); }
.chat-text { white-space: pre-line; overflow-wrap: anywhere; color: var(--c-text); }
/* Délai de réponse de Teacher Joe (orange au-delà de platform.transcripts.slow_reply_seconds) et événements gris. */
.chat-delay { margin-top: var(--space-1) !important; font-size: var(--fs-xs); color: var(--c-muted); }
.chat-delay-slow { color: var(--c-accent-strong); font-weight: var(--fw-bold); }
.chat-event { justify-self: center; font-size: var(--fs-xs); color: var(--c-muted); text-align: center; }
.chat-event time { margin-right: var(--space-1); font-variant-numeric: tabular-nums; }
.conversation-delays { margin: var(--space-3) 0 var(--space-2); }
/* Écran de séance : aucune réponse du professeur (« réfléchit, un instant… », « Relancer »). */
.live-wait p { margin: 0; }
.live-wait .btn { margin-top: var(--space-2); }

/* Page « Confidentialité » et lien du gabarit simple. */
.privacy h2 { margin-top: 0; }
.privacy ul:not(.contact-list) { padding-left: var(--space-5); display: grid; gap: var(--space-2); }
.register-privacy { margin: var(--space-3) 0 0; text-align: center; }
.site-footer-simple { padding: var(--space-4) 0 var(--space-6); text-align: center; font-size: var(--fs-sm); }

/* Pages publiques du référencement : liens vers les pages par pays, « À propos ». */
.country-links { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.country-link { display: flex; align-items: center; gap: var(--space-3); margin: 0; text-decoration: none; color: var(--c-text); }
.country-link > span:nth-child(2) { display: grid; gap: 2px; flex: 1; }
.country-link strong { color: var(--c-primary); }
.country-link > .icon { flex: none; color: var(--c-accent-strong); }
.country-link:hover strong { text-decoration: underline; }
.about-card { display: flex; gap: var(--space-4); align-items: flex-start; }
.about-card h2 { margin-top: 0; }
.footer-countries { margin-top: var(--space-2); }
.students h1 { margin-top: 0; }
@media (min-width: 640px) { .footer-countries { grid-column: 1 / -1; margin-top: 0; } }
/* Pied de page : à partir de 640 pixels, les liens forment une colonne bien rangée (pays : une ligne). */
.footer-links li:has(> [hidden]:only-child) { display: none; }
@media (min-width: 640px) {
    .footer-links:not(.footer-countries) { flex-direction: column; flex-wrap: nowrap; gap: var(--space-2); align-content: start; }
}
@media (min-width: 640px) { .country-links { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Accueil : quatre cartes compactes (.students.audience) : étudiants, élèves, parents, professionnels.
   Même carte que .students, en plus court : photo 16:9 en haut, titre, une phrase, trois points, bouton.
   Téléphone : l'une sous l'autre ; à partir de 720 pixels : grille 2 × 2. */
.audiences { display: grid; gap: var(--space-5); }
.students.audience { align-items: start; align-content: start; gap: var(--space-4); padding: var(--space-4) var(--space-4) var(--space-5); }
.audience .photo-frame { aspect-ratio: 2 / 1; box-shadow: none; border-radius: var(--radius); }
.audience h2 { margin: 0 0 var(--space-2); font-size: 1.3rem; }
.audience-body > p { margin: 0 0 var(--space-3); }
.audience-points { list-style: none; padding: 0; margin: 0 0 var(--space-4); display: grid; gap: var(--space-2); }
.audience-points li { display: flex; gap: var(--space-2); align-items: flex-start; line-height: 1.4; }
.audience-points .icon { flex: none; margin-top: 2px; color: var(--c-accent-strong); }
.audience .help-only { font-size: .92rem; align-items: flex-start; }
@media (min-width: 720px) {
    .audiences { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .students.audience { grid-template-columns: 1fr; padding: var(--space-5); }
    .audience-body { display: flex; flex-direction: column; height: 100%; }
    .audience-body .btn { margin-top: auto; align-self: flex-start; }
}

/* « Mon espace » : bouton « Modifier mes objectifs », sous les chiffres. */
.edit-goals { margin: var(--space-4) 0 0; }
@media (min-width: 640px) { .edit-goals .btn-block { width: auto; } }

/* Questionnaire, « Vous êtes… » : libellés longs (« En recherche d'emploi ») : une colonne sur petit téléphone,
   deux colonnes qui ne dépassent jamais la carte ensuite. */
.profiles { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 var(--space-2); }
@media (min-width: 400px) { .profiles { grid-template-columns: repeat(auto-fill, minmax(min(100%, 10.5rem), 1fr)); } }

/* ---------- Accueil : finition ----------
   Sections alternées sur toute la largeur (.band : blanc ; .band-soft : bleu très clair ; .band-dark : bleu nuit,
   une seule section). Fond peint par une ombre portée et coupé en hauteur : aucun changement de structure.
   Une .band passe au-dessus des formes floues du haut de page (elles ne voilent plus « Quatre étapes simples »). */
.band { --band: var(--c-surface); position: relative; background: var(--band); box-shadow: 0 0 0 100vmax var(--band); clip-path: inset(0 -100vmax); }
.band-soft { --band: var(--c-primary-soft); }
.band-dark { --band: var(--c-primary); color: var(--c-on-dark); }
.band-dark .section-head h2 { color: var(--c-on-dark); }
.band-dark .section-head .eyebrow { color: var(--c-accent); }
.band-dark .section-head .muted, .band-dark > .muted { color: var(--c-on-dark-muted); }
.band-dark .card { color: var(--c-text); }
.band-dark .levels li::before { background: var(--c-on-dark-line); background: rgba(255, 255, 255, .35); }
.band-dark .levels span { color: var(--c-on-dark-muted); }
.band-dark .photo-frame { box-shadow: none; }

/* Étapes : sur ordinateur, une ligne relie les quatre numéros posés sur le haut des cartes. */
@media (min-width: 900px) {
    .how { position: relative; padding-top: 26px; }
    .how::before { content: ""; position: absolute; z-index: 1; top: 25px; height: 3px; left: calc((100% - 3 * var(--space-4)) / 8); right: calc((100% - 3 * var(--space-4)) / 8); border-radius: 2px; background: var(--c-accent); }
    .how li { padding-top: calc(26px + var(--space-4)); }
    .how .how-num { position: absolute; z-index: 2; top: -26px; left: 50%; transform: translateX(-50%); box-shadow: var(--ib-strong-ring), 0 0 0 5px var(--band, var(--c-surface)); }
}

/* « Ce qui rend … différent » : la photo prend la hauteur du texte (moins haute qu'avant). */
.section-split .photo-frame { aspect-ratio: 16 / 9; }
.section-split .photo-frame picture, .section-split .photo-frame img { display: block; width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 640px) {
    .section-split { align-items: stretch; }
    .section-split .section-head { align-self: center; }
    .section-split .photo-frame { aspect-ratio: auto; contain: size; min-height: 180px; }
}

/* Moyens de paiement sous les formules, groupés par pays. */
.pay-methods { margin-top: var(--space-6); }
.pay-methods > p { margin: 0 0 var(--space-3); }
.pay-countries { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.pay-countries li { display: grid; grid-template-columns: 8.5em minmax(0, 1fr); align-items: baseline; gap: var(--space-2); }
.pay-country { font-weight: var(--fw-bold); color: var(--c-heading); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { display: inline-block; padding: 2px 10px; border-radius: var(--radius-pill); background: var(--c-primary-soft); border: 1px solid var(--c-primary-line); color: var(--c-primary); font-size: var(--fs-xs); font-weight: var(--fw-bold); white-space: nowrap; }
@media (min-width: 900px) { .pay-countries { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Cartes Étudiants, Élèves, Parents, « Vous travaillez ? » : boutons alignés en bas, note discrète. */
.audience .help-only { font-size: var(--fs-xs); font-weight: var(--fw-normal); color: var(--c-muted); align-items: flex-start; }
.audience .help-only .icon { width: 16px; height: 16px; margin-top: 2px; color: var(--c-muted); }
@media (min-width: 720px) {
    .students.audience { grid-template-rows: auto 1fr; align-items: stretch; align-content: stretch; }
    .audience-body { height: auto; }
}

/* Questions fréquentes : centrées, environ 760 pixels de large. */
.faq-section .section-head { margin-inline: auto; text-align: center; }
.faq-section .faq { margin-inline: auto; max-width: 760px; }

/* Haut de l'accueil : bulles près de Teacher Joe (deux, immobiles, sur téléphone), troisième bulle et
   animations lentes sur ordinateur seulement ; tout est coupé par « réduire les animations ». */
.hero-bubble.third { display: none; }
@media (min-width: 900px) {
    .hero-media { max-width: 460px; }
    .hero::before { animation: drift 22s ease-in-out infinite alternate; }
    .hero::after { animation: drift 26s ease-in-out -8s infinite alternate-reverse; }
    .hero-blob { width: 300px; height: 300px; left: 38%; animation: drift 30s ease-in-out -4s infinite alternate; }
    .hero-bubble { animation: bob 6s ease-in-out infinite; }
    .hero-bubble.right { animation-delay: -2s; }
    .hero-bubble.third { display: block; left: auto; right: -18px; bottom: 34%; border-radius: var(--radius) var(--radius) 4px var(--radius); color: var(--c-accent-strong); animation-delay: -4s; }
}
@media (min-width: 1200px) {
    .hero { grid-template-columns: 1fr 1fr; }
    .hero-media { max-width: 520px; }
}
@keyframes bob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* Pages étroites (connexion, inscription, questionnaire) : sur grand écran, carte formulaire et petit panneau d'aide
   à côté (<x-form-aside>) ; téléphone et tablette : panneau caché, rien ne change. */
.with-aside-panel { display: none; }
.aside-teacher { margin: 0 0 var(--space-4); text-align: center; }
.aside-face { display: block; width: 140px; height: 140px; margin: 0 auto var(--space-3); border-radius: 50%; overflow: hidden; background: var(--c-bg-warm); box-shadow: 0 0 0 4px var(--c-surface), 0 0 0 7px var(--c-accent); }
.aside-face img { display: block; width: 100%; height: 100%; transform: scale(2.5) translate(0, 19%); }
.aside-teacher figcaption { color: var(--c-muted); font-size: var(--fs-sm); }
.aside-teacher strong { display: block; color: var(--c-heading); font-size: var(--fs-md); }
.with-aside-panel .hero-points { margin: 0; }
.aside-title { display: flex; align-items: center; gap: var(--space-2); font-size: var(--fs-lg); }
.aside-title .icon { color: var(--c-accent-strong); flex: none; }
.aside-list { margin: 0 0 var(--space-3); padding-left: 1.1em; display: grid; gap: var(--space-2); font-size: var(--fs-sm); }
@media (min-width: 900px) {
    .container-narrow:has(.with-aside) { max-width: calc(var(--container-narrow) + 300px + var(--space-8)); }
    .with-aside { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: var(--space-8); align-items: start; }
    .with-aside-panel { display: block; position: sticky; top: 96px; padding: var(--space-5); }
}

/* « Mon espace » : petit visage de Teacher Joe en tête (même cadrage que l'accueil). */
.welcome .welcome-face img { width: 100%; height: 100%; border-radius: 0; box-shadow: none; object-fit: fill; }
/* « Mon suivi » : deux chiffres = deux colonnes égales (« Séances faites » en troisième quand il y en a). */
.stats.stats-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* Page de résultat : l'avis de Teacher Joe sous un titre ; formules repliées pour un apprenant qui a déjà un accès. */
.result-opinion { margin: var(--space-3) 0 var(--space-4); }
.result-opinion-title { font-size: var(--fs-md); margin: 0 0 var(--space-1); }
.result-opinion .result-feedback { margin: 0; }
.plans-fold { margin-top: var(--space-6); }
.plans-fold > summary { list-style: none; }
.plans-fold > summary::-webkit-details-marker { display: none; }
@media (min-width: 640px) { .plans-fold > summary.btn-block { width: auto; } }

/* Séance et évaluation : pendant la connexion, « Teacher Joe arrive… » (indicateur discret), conseils visibles. */
.live-arriving { display: none; align-items: center; gap: var(--space-3); margin: 0; padding: var(--space-3) var(--space-4); border-radius: var(--radius); background: var(--c-primary-soft); color: var(--c-primary-strong); font-weight: var(--fw-bold); }
.live[data-phase="connecting"] .live-arriving { display: flex; }
.live[data-phase="connecting"] .intro-text, .live[data-phase="connecting"] #start { display: none; }
.live-arriving-dots { display: inline-flex; gap: 4px; flex: none; }
.live-arriving-dots span { width: 7px; height: 7px; border-radius: 50%; background: var(--c-primary); opacity: .35; animation: arriving 1.2s ease-in-out infinite; }
.live-arriving-dots span:nth-child(2) { animation-delay: .2s; }
.live-arriving-dots span:nth-child(3) { animation-delay: .4s; }
@keyframes arriving { 0%, 100% { opacity: .35; transform: none; } 50% { opacity: 1; transform: translateY(-2px); } }
@media (prefers-reduced-motion: reduce) { .live-arriving-dots span { animation: none; opacity: .7; } }

/* Ordinateur : sous Teacher Joe, les conseils avant le début puis la transcription ; cadre limité en hauteur
   pour que le professeur et le texte tiennent dans l'écran. Téléphone et paysage : rien ne change. */
.live-stage-notes { display: none; }
@media (min-width: 900px) and (min-height: 561px) {
    .live { --stage-height: clamp(220px, calc(100vh - 420px), 440px); }
    .live-stage-notes { display: block; }
    .live-panel .intro-tips { display: none; }
    .live:not([data-phase="intro"]):not([data-phase="connecting"]) .stage-tips { display: none; }
    .stage-tips { margin: 0; padding: var(--space-3) var(--space-4); background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); }
    .live-stage-notes .subtitles, .live[data-teacher="3d"] .live-stage-notes .subtitles { height: auto; min-height: 120px; max-height: max(120px, calc(100vh - var(--stage-height) - 150px)); margin: 0; }
}
@supports (height: 1dvh) {
    @media (min-width: 900px) and (min-height: 561px) {
        .live { --stage-height: clamp(220px, calc(100dvh - 420px), 440px); }
        .live-stage-notes .subtitles, .live[data-teacher="3d"] .live-stage-notes .subtitles { max-height: max(120px, calc(100dvh - var(--stage-height) - 150px)); }
    }
}

/* Accueil, juste après le haut de page : « Vous vous reconnaissez ? » et « Vous avez déjà essayé ? »
   (situations vécues, jamais des témoignages). L'une sous l'autre, côte à côte à partir de 900 pixels. */
.persuade { display: grid; gap: var(--space-4); }
.persuade-card { margin: 0; display: flex; flex-direction: column; }
.persuade-card h2 { margin-bottom: var(--space-4); }
.persuade-card h2:has(+ .persuade-lead) { margin-bottom: var(--space-2); }
.persuade-lead { margin: 0 0 var(--space-3); font-size: var(--fs-sm); color: var(--c-muted); }
.situations, .tried { list-style: none; padding: 0; margin: 0 0 var(--space-4); display: grid; gap: var(--space-3); }
/* Phrases plus serrées que la liste voisine : le titre a maintenant une ligne d'explication, l'accueil ne s'allonge pas. */
.situations { gap: var(--space-2); }
.situations li { display: flex; align-items: center; gap: var(--space-3); font-size: var(--fs-sm); line-height: 1.4; font-weight: var(--fw-bold); color: var(--c-heading); }
.situations .icon-bubble { flex: none; width: 40px; height: 40px; border-radius: 12px; }
.situations .icon-bubble .icon { width: 20px; height: 20px; }
.persuade-answer { margin: 0 0 var(--space-4); padding: var(--space-2) var(--space-3); border-left: 4px solid var(--c-accent); border-radius: var(--radius-sm); background: var(--c-accent-soft); color: var(--c-text); }
.persuade-answer strong { color: var(--c-heading); }
.persuade-card > .btn { margin-top: auto; }
.tried li { display: flex; align-items: flex-start; gap: var(--space-3); color: var(--c-muted); }
.tried .icon { flex: none; margin-top: 2px; color: var(--c-muted); }
.tried-yes { display: flex; align-items: flex-start; gap: var(--space-3); margin: auto 0 0; padding: var(--space-3) var(--space-4); border-radius: var(--radius); background: var(--c-primary-soft); color: var(--c-heading); font-weight: var(--fw-bold); }
.tried-yes .icon { flex: none; margin-top: 2px; color: var(--c-accent-strong); }
@media (min-width: 640px) { .persuade-card > .btn-block { width: auto; align-self: flex-start; } }
@media (min-width: 900px) { .persuade { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); align-items: stretch; } }

/* « Qui est derrière … ? » (accueil, avant les questions fréquentes) et « À propos » : photo ronde du fondateur. */
.founder-section { padding-top: 0; }
.founder-card { display: grid; gap: var(--space-4); justify-items: center; text-align: center; max-width: 760px; margin: 0 auto; }
.founder-card h2 { font-size: var(--fs-lg); margin-bottom: var(--space-2); }
.founder-photo { display: block; flex: none; width: 96px; height: 96px; border-radius: 50%; object-fit: cover; background: var(--c-bg-warm); box-shadow: 0 0 0 4px var(--c-surface), 0 0 0 6px var(--c-primary-line); }
.founder-name { margin: 0 0 var(--space-2); color: var(--c-muted); }
.founder-name strong { color: var(--c-heading); }
.founder-bio { margin: 0 0 var(--space-3); color: var(--c-text); }
.founder-more { display: inline-flex; align-items: center; gap: var(--space-1); font-weight: var(--fw-bold); }
.about-card .founder-photo { width: 112px; height: 112px; }
@media (min-width: 640px) {
    .founder-card { grid-template-columns: auto 1fr; justify-items: start; align-items: center; text-align: left; gap: var(--space-5); }
    .founder-photo { width: 112px; height: 112px; }
}
@media (max-width: 639px) { .about-card:has(.founder-photo) { flex-direction: column; } }

/* Séance du jour : TABLEAU de la leçon (components/live-board.blade.php, public/js/lesson-board.js). Bleu nuit comme un
   tableau, élément expliqué en orange (texte bleu nuit), éléments déjà vus cochés. Téléphone : sous Teacher Joe,
   replié, la ligne du haut donne l'étape et l'élément en cours ; grand écran : à droite, ouvert. */
.board { margin: 0 0 var(--space-3); border-radius: var(--radius-lg); background: var(--c-primary); color: var(--c-on-dark); box-shadow: var(--shadow-sm); overflow: hidden; }
.board-head { display: flex; align-items: center; gap: var(--space-2); min-height: 48px; padding: var(--space-2) var(--space-3); cursor: pointer; list-style: none; }
.board-head::-webkit-details-marker { display: none; }
.board-head::after { content: "+"; flex: none; margin-left: auto; font-weight: var(--fw-heavy); color: var(--c-accent); }
.board[open] .board-head::after { content: "−"; }
.board-label { display: inline-flex; align-items: center; gap: 6px; font-weight: var(--fw-heavy); flex: none; }
.board-label .icon { color: var(--c-accent); }
.board-phase { flex: none; padding: 2px 10px; border-radius: var(--radius-pill); background: var(--c-accent); color: var(--c-on-accent); font-size: var(--fs-xs); font-weight: var(--fw-heavy); }
.board-now { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--fs-sm); color: var(--c-on-dark-muted); }
.board[open] .board-now { display: none; }
.board-body { padding: 0 var(--space-3) var(--space-3); max-height: 42vh; overflow-y: auto; }
.board-title { color: var(--c-on-dark); font-size: var(--fs-lg); margin: 0 0 var(--space-2); }
.board-heading { margin: var(--space-3) 0 var(--space-1); font-size: var(--fs-xs); font-weight: var(--fw-bold); text-transform: uppercase; letter-spacing: .06em; color: var(--c-accent); }
.board-list, .board-words { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.board-words { grid-template-columns: repeat(auto-fill, minmax(min(100%, 9rem), 1fr)); }
.board-item { position: relative; display: grid; gap: 2px; margin: 0; padding: 6px 10px 6px 12px; border-radius: var(--radius-sm); border-left: 3px solid transparent; background: var(--c-on-dark-glow); transition: background var(--dur-fast), color var(--dur-fast); }
.board-en { font-weight: var(--fw-bold); overflow-wrap: anywhere; }
.board-fr { font-size: var(--fs-sm); color: var(--c-on-dark-muted); overflow-wrap: anywhere; }
.board-item.is-seen { border-left-color: var(--c-on-dark-line); border-left-color: rgba(255, 255, 255, .45); }
.board-item.is-lit { background: var(--c-accent); color: var(--c-on-accent); border-left-color: var(--c-surface); animation: board-lit var(--dur-slow) var(--ease); }
.board-item.is-lit .board-fr { color: var(--c-on-accent); }
@keyframes board-lit { from { transform: scale(.98); } to { transform: none; } }
.board[data-translations="discreet"] .board-fr { font-size: var(--fs-xs); opacity: .8; }
.board[data-translations="hidden"] .board-fr { display: none; }
.board.show-translations .board-fr { display: block; font-size: var(--fs-sm); opacity: 1; }
.board-heading .icon { width: 14px; height: 14px; vertical-align: -2px; }
.board-pitfall { margin: 0; padding: 6px 10px 6px 12px; border-radius: var(--radius-sm); border-left: 3px solid var(--c-accent); background: var(--c-on-dark-glow); font-size: var(--fs-sm); overflow-wrap: anywhere; }
.board-toggle { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-xs); color: var(--c-on-dark-muted); cursor: pointer; }
.board-toggle input { accent-color: var(--c-accent); width: 16px; height: 16px; }
@media (min-width: 900px), (orientation: landscape) and (max-height: 560px) {
    #board-wide .board-body { max-height: min(36vh, 320px); }
}
@media (prefers-reduced-motion: reduce) { .board-item.is-lit { animation: none; } }

/* Accueil : « Comment se passe votre cours avec Teacher Joe ? » (section bleu nuit). Quatre temps en cartes compactes
   (numéro + texte), aperçu du Tableau (mêmes classes que la séance, sans script), deux points forts en une ligne. */
.lead .hero-also { display: block; margin: var(--space-2) 0 0; }
/* Phrases utiles pendant une séance (components/useful-phrases) : à lire, à dire à voix haute. */
.useful-phrases { margin: 0 0 var(--space-3); border: 1px solid var(--c-border); border-left: 4px solid var(--c-accent); border-radius: var(--radius-lg); background: var(--c-surface); box-shadow: var(--shadow-sm); }
.useful-head { display: flex; align-items: center; gap: var(--space-2); min-height: 44px; padding: var(--space-2) var(--space-3); cursor: pointer; list-style: none; }
.useful-head::-webkit-details-marker { display: none; }
.useful-head::after { content: "+"; flex: none; margin-left: auto; font-weight: var(--fw-heavy); color: var(--c-accent-strong); }
.useful-phrases[open] .useful-head::after { content: "−"; }
.useful-label { display: inline-flex; align-items: center; gap: 6px; font-weight: var(--fw-heavy); color: var(--c-heading); flex: none; }
.useful-label .icon { color: var(--c-accent-strong); }
.useful-hint { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--fs-xs); color: var(--c-muted); }
.useful-body { padding: 0 var(--space-3) var(--space-3); }
.useful-intro { margin: 0 0 var(--space-2); font-size: var(--fs-sm); color: var(--c-muted); }
.useful-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr)); }
.useful-list li { display: grid; gap: 1px; padding: 6px 10px; border-radius: var(--radius-sm); background: var(--c-primary-soft); }
.useful-en { font-weight: var(--fw-bold); color: var(--c-heading); overflow-wrap: anywhere; }
.useful-fr { font-size: var(--fs-sm); color: var(--c-muted); overflow-wrap: anywhere; }
/* « Enregistrer ma séance » : rappel d'une ligne (components/recording-hint) et « Comment partager ma vidéo »
   (components/recording-share, même style que les phrases utiles). */
.recording-hint { display: flex; align-items: flex-start; gap: var(--space-2); margin: var(--space-3) 0 0; font-size: var(--fs-sm); }
.recording-hint .icon { flex: none; margin-top: 3px; color: var(--c-accent-strong); }
.next-card .recording-hint .icon { color: var(--c-accent); }
.recording-hint a { display: inline-block; font-weight: var(--fw-bold); padding: 4px 0; }
.recording-share { margin: var(--space-3) 0 0; }
.recording-steps { margin: 0 0 var(--space-2); padding-left: 1.3em; display: grid; gap: 6px; font-size: var(--fs-sm); }
.board-preview { margin: 0; max-width: 420px; width: 100%; justify-self: center; box-shadow: 0 0 0 1px var(--c-on-dark-line), var(--shadow); box-shadow: 0 0 0 1px rgba(255, 255, 255, .25), var(--shadow); }
.board-preview .board-head { cursor: default; }
.board-preview .board-head::after { content: none; }
.board-preview .board-body { max-height: none; overflow: visible; }
.course-grid { display: grid; gap: var(--space-5); }
.course-grid .section-head { margin-bottom: 0; }
.course-steps { list-style: none; margin: 0; padding: var(--space-4); display: grid; gap: var(--space-3); }
.course-steps li { display: flex; gap: var(--space-3); align-items: flex-start; }
.course-steps .how-num { width: 32px; height: 32px; font-size: var(--fs-md); }
.course-steps p { margin: 0; color: var(--c-muted); line-height: 1.45; }
.course-steps strong { color: var(--c-primary); }
.course-plus { list-style: none; padding: 0; margin: var(--space-5) 0; display: grid; gap: var(--space-2); color: var(--c-on-dark-muted); }
.course-plus li { display: flex; gap: var(--space-2); align-items: flex-start; }
.course-plus .icon { flex: none; margin-top: 3px; color: var(--c-accent); }
.course-plus strong { color: var(--c-on-dark); }
@media (min-width: 720px) {
    .course-plus { grid-template-columns: repeat(2, 1fr); gap: var(--space-4); }
}
@media (min-width: 900px) {
    .course-grid { grid-template-columns: 1.25fr 1fr; column-gap: var(--space-8); align-items: center; }
    .course-grid .section-head { grid-column: 1; grid-row: 1; }
    .course-grid .course-steps { grid-column: 1; grid-row: 2; }
    .course-grid .board-preview { grid-column: 2; grid-row: 1 / 3; }
}

/* Page de résultat : « Voici votre première leçon » (tableau de l'unité 1, leçon 1, au-dessus des formules). */
.first-lesson .board-preview { max-width: 560px; margin-top: var(--space-4); justify-self: start; }

/* « Mes cours » : partie d'un PDF à travailler (pages côte à côte, sommaire, parties déjà travaillées). */
.course-part-pages { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }
.course-part-form { margin-top: var(--space-4); }
.course-outline { list-style: none; padding: 0; margin: var(--space-2) 0 0; display: grid; gap: var(--space-1); max-height: 320px; overflow-y: auto; }
.course-outline strong { margin-right: var(--space-2); color: var(--c-primary); }
.course-parts { list-style: none; padding: 0; margin: var(--space-2) 0 0; display: grid; gap: var(--space-2); }
.course-parts li { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); }
.course-parts form { margin: 0; flex: none; }

/* Documents de révision « Mes cours » (components/course-review) : une ligne par séance. */
.review-list { list-style: none; padding: 0; margin: var(--space-3) 0 0; display: grid; gap: var(--space-3); }
.review-list > li { display: grid; gap: var(--space-2); padding-top: var(--space-3); border-top: 1px solid var(--c-border); }
.review-list > li:first-child { padding-top: 0; border-top: 0; }
.review-date { font-weight: var(--fw-bold); color: var(--c-heading); overflow-wrap: anywhere; }
.review-doc, .review-doc-line { margin: 0; }
.review-doc-line form { margin: var(--space-2) 0 0; }
.review-doc .btn { max-width: 100%; white-space: normal; }
p.review-doc-line[data-review-when="pending"] { display: flex; align-items: center; gap: var(--space-2); color: var(--c-muted); font-size: var(--fs-sm); }
p.review-doc-line[hidden], div.review-doc-line[hidden] { display: none; }
.review-spinner { flex: none; width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--c-border); border-top-color: var(--c-accent); animation: review-spin 1s linear infinite; }
@keyframes review-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .review-spinner { animation: none; } }
.review-mailed { display: inline-flex; align-items: center; gap: 6px; margin: 0; }
/* Invitation à ajouter son e-mail : du texte qui passe à la ligne normalement (lien compris), l'icône dans la ligne. */
.review-invite { margin: var(--space-2) 0 0; }
.review-invite .icon { width: 16px; height: 16px; vertical-align: -3px; margin-right: 4px; }
.review-doc-line[data-review-when="ready"] { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }

/* Page « Vidéos » de l'administration */
.video-prepare { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); margin-top: var(--space-4); }
.video-prepare label { font-weight: var(--fw-bold); }
.video-prepare select { min-height: 48px; }
.video-preview { display: block; width: 100%; max-width: 360px; aspect-ratio: 9 / 16; background: var(--c-primary); border-radius: var(--radius); margin-bottom: var(--space-3); }
.video-caption { display: block; width: 100%; font: inherit; font-size: var(--fs-sm); padding: var(--space-3); border: 1px solid var(--c-border); border-radius: var(--radius); margin-bottom: var(--space-2); resize: vertical; }
.video-published { display: flex; align-items: center; gap: var(--space-3); margin-top: var(--space-4); }
.video-published label { display: inline-flex; align-items: center; gap: var(--space-2); font-weight: var(--fw-bold); min-height: 48px; }
.video-published input[type="checkbox"] { width: 24px; height: 24px; accent-color: var(--c-accent); }
.video-site { margin-top: var(--space-4); }
.video-measures { font-weight: var(--fw-bold); color: var(--c-primary-strong); }
.video-redo { margin-top: var(--space-4); }
.voice-trials { list-style: none; padding: 0; margin: var(--space-4) 0 0; display: grid; gap: var(--space-3); }
.voice-trial { border: 1px solid var(--c-border); border-radius: var(--radius); padding: var(--space-3); display: grid; gap: var(--space-2); }
.voice-trial audio { width: 100%; }

/* Premier écran de l'accueil : bouton orange et réassurance visibles sans faire défiler ; le reste de l'accroche dessous. */
.hero-cta { margin-top: var(--space-4); }
.hero-reassure { display: flex; gap: var(--space-2); align-items: flex-start; margin: var(--space-3) 0 0; font-size: var(--fs-sm); font-weight: var(--fw-bold); color: var(--c-text); }
.hero-reassure .icon { flex: none; margin-top: 2px; color: var(--c-accent-strong); }
.hero-login { margin-top: var(--space-3); }
.hero-more { margin-top: var(--space-5); color: var(--c-muted); }
.hero-more > p { margin: 0 0 var(--space-3); }
.hero-caption { display: none; }

/* Téléphone et tablette : Teacher Joe en bandeau tout en haut (même image), accroche courte, bouton dans le premier écran. */
@media (max-width: 899.98px) {
    .hero { gap: var(--space-4); padding-top: 0; }
    .hero h1 { font-size: clamp(1.75rem, 7.6vw, 2.4rem); line-height: 1.12; }
    .hero .lead { margin-bottom: 0; }
    .hero-media { order: -1; width: 100%; max-width: 640px; }
    .hero-media::before { display: none; }
    .hero-media img { aspect-ratio: auto; height: clamp(140px, 25svh, 240px); object-fit: cover; object-position: 50% 24%; border-radius: var(--radius-lg); box-shadow: var(--shadow); }
    .hero-caption { display: block; position: absolute; left: 10px; bottom: 10px; max-width: calc(100% - 20px); padding: 6px 12px; border-radius: var(--radius); background: var(--c-primary); color: var(--c-on-dark-muted); font-size: var(--fs-xs); line-height: 1.35; }
    .hero-caption strong { display: block; color: var(--c-on-dark); font-size: var(--fs-sm); }
    .hero-bubble { left: auto; right: 10px; bottom: 12px; }
    .hero-bubble.right { right: 10px; top: 10px; bottom: auto; }
}
@media (max-width: 380px) {
    .hero-bubble:not(.right) { display: none; }
}
@media (min-width: 640px) {
    .hero-cta, .hero-login { display: inline-flex; width: auto; }
}

/* Pied de page : liens faciles à toucher au pouce (44 pixels de haut), un numéro de téléphone par ligne. */
.footer-phones { display: grid; }
.site-footer .footer-list a, .site-footer .footer-links a { display: inline-flex; align-items: center; min-height: 44px; }
.footer-list li { align-items: flex-start; }
.footer-list li:has(a) .icon { margin-top: 12px; }
.footer-links { row-gap: 0; }

/* Accueil plus court : formules compactes (détail replié), pays une seule fois, cartes des publics compactes. */
.plan-summary { display: flex; gap: var(--space-2); align-items: center; margin: var(--space-3) 0; font-weight: var(--fw-bold); color: var(--c-heading); }
.plan-summary .icon { flex: none; color: var(--c-accent-strong); }
.plan-more, .audience-more { margin: 0 0 var(--space-3); }
.plan-more summary, .audience-more summary { display: inline-flex; align-items: center; gap: var(--space-2); min-height: 44px; font-weight: var(--fw-bold); color: var(--c-primary); cursor: pointer; list-style: none; }
.plan-more summary::-webkit-details-marker, .audience-more summary::-webkit-details-marker { display: none; }
.plan-more summary::after, .audience-more summary::after { content: "+"; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--c-primary-soft); color: var(--c-primary); font-weight: var(--fw-heavy); }
.plan-more[open] summary::after, .audience-more[open] summary::after { content: "−"; }
.plan-more summary:focus-visible, .audience-more summary:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; border-radius: var(--radius); }
.plan.plan-compact ul { margin: var(--space-2) 0 0; }
.plan-price-line { margin: var(--space-2) 0 0; }
.plan-price-line .price { font-size: var(--fs-xl); font-weight: var(--fw-heavy); color: var(--c-primary); }
.plan.plan-compact .plan-summary { margin: var(--space-2) 0 0; }
.plan.plan-compact .plan-more { margin-bottom: var(--space-2); }
@media (max-width: 639.98px) { .plan.plan-compact { padding: var(--space-4); } }
.pay-methods h3 { margin: 0 0 var(--space-3); font-size: var(--fs-lg); }
.pay-methods > p.muted { margin: var(--space-3) 0 0; }
.pay-countries a.pay-country { display: inline-flex; align-items: center; gap: 2px; min-height: 44px; color: var(--c-heading); text-decoration: underline; text-decoration-color: var(--c-primary-line); text-underline-offset: 3px; }
.pay-countries a.pay-country .icon { width: 16px; height: 16px; color: var(--c-accent-strong); }
@media (max-width: 639.98px) {
    .pay-countries { gap: var(--space-1); }
    .pay-countries li { display: flex; flex-wrap: wrap; align-items: center; column-gap: var(--space-3); row-gap: 4px; }
}
.audience-cta { align-self: flex-start; }

@media (max-width: 719.98px) {
    /* Petite photo à côté du titre ; le reste en dessous, sur toute la largeur. */
    .students.audience { grid-template-columns: 88px minmax(0, 1fr); gap: var(--space-2) var(--space-3); align-items: center; padding: var(--space-4); }
    .audience-body { display: contents; }
    .audience .photo-frame { aspect-ratio: 1; grid-row: 1; grid-column: 1; }
    .audience .photo-frame img { width: 100%; height: 100%; object-fit: cover; }
    .audience h2 { grid-row: 1; grid-column: 2; margin: 0; font-size: var(--fs-lg); }
    .audience-body > :not(h2) { grid-column: 1 / -1; }
    .audience-body > p { margin: 0; }
    .audience-more { margin: 0; }
    .audiences { gap: var(--space-3); }
    .audience-cta { width: 100%; }
}

@media (max-width: 639.98px) {
    /* Étapes : numéro à gauche, titre et phrase à droite, sans pastille d'icône. */
    .how .card { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: var(--space-3); padding: var(--space-3) var(--space-4); }
    .how .how-head { grid-row: 1 / span 2; margin: 0; align-self: start; }
    .how .how-head .icon-bubble { display: none; }
    .how .how-num { width: 40px; height: 40px; font-size: var(--fs-lg); }
    .how p { font-size: var(--fs-sm); }
    /* Persuasion : listes plus serrées. */
    .tried { gap: var(--space-2); }
    .tried li { font-size: var(--fs-sm); }
}
@media (max-width: 639.98px) {
    /* Bandes de l'accueil moins hautes sur téléphone. */
    .section.band { padding: var(--space-6) 0; }
    .band .section-head { margin-bottom: var(--space-4); }
}

/* Questions fréquentes : les six premières visibles, les autres derrière « Voir les autres questions ». */
.faq > .faq-more { background: none; border: 0; }
.faq-more > .faq { margin-top: var(--space-2); }
.faq .faq-more-toggle { justify-content: center; gap: var(--space-2); color: var(--c-primary); }
.faq .faq-more-toggle::after { background: var(--c-primary-soft); color: var(--c-primary); }
.faq-more[open] > .faq-more-toggle { display: none; }

/* Cartes des publics sur téléphone : côte à côte, on les fait glisser (aucune animation, défilement natif). */
@media (max-width: 719.98px) {
    .audiences { grid-auto-flow: column; grid-auto-columns: 86%; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; padding-bottom: var(--space-3); scrollbar-width: thin; }
    .audiences > .audience { scroll-snap-align: start; }
}
.swipe-hint { display: none; }
@media (max-width: 719.98px) {
    .swipe-hint { display: flex; align-items: center; gap: var(--space-2); margin: 0 0 var(--space-3); }
    .swipe-hint .icon { flex: none; color: var(--c-accent-strong); }
}
.founder-more { display: inline-flex; align-items: center; min-height: 44px; }
.result-whatsapp { margin-top: var(--space-3); }

/* « Inviter un ami sur WhatsApp » : discret (bouton secondaire, pas le vert du bouton WhatsApp principal). */
.invite-friend h2 { margin: 0 0 var(--space-1); font-size: var(--fs-lg); }
.invite-friend p { margin: 0 0 var(--space-3); }
.invite-friend-btn .icon { color: var(--c-primary); }
@media (max-width: 639.98px) { .invite-friend-btn { width: 100%; } }

/* Avant « Commencer » (évaluation, séance du jour, « Mes cours », bilan) : le bouton orange tout de suite, UNE ligne
   courte, « Enregistrer ma séance », puis « Avant de commencer » replié. */
.start-block .intro-text { margin: var(--space-2) 0 0; text-align: center; font-weight: var(--fw-bold); color: var(--c-heading); }
.intro-mic-line { display: flex; justify-content: center; align-items: flex-start; gap: 6px; margin: var(--space-1) 0 0; font-size: var(--fs-xs); color: var(--c-muted); text-align: center; }
.intro-mic-line .icon { flex: none; width: 14px; height: 14px; margin-top: 2px; color: var(--c-primary); }
.live:not([data-phase="intro"]) .intro-mic-line { display: none; }
.before-start { margin-top: var(--space-3); border-top: 1px solid var(--c-border); }
.before-start > summary { display: flex; align-items: center; gap: var(--space-2); min-height: 48px; font-weight: var(--fw-bold); color: var(--c-primary); cursor: pointer; list-style: none; }
.before-start > summary::-webkit-details-marker { display: none; }
.before-start > summary > span { flex: 1; }
.before-start > summary::after { content: "+"; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--c-primary-soft); color: var(--c-primary); font-weight: var(--fw-heavy); }
.before-start[open] > summary::after { content: "−"; }
.before-start > summary:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; border-radius: var(--radius); }
.before-start-body > p { margin: 0 0 var(--space-2); font-size: var(--fs-sm); color: var(--c-muted); }
.before-start .intro-tips { margin-top: var(--space-2); }

/* Téléphone en portrait, avant « Commencer » seulement : titre, Teacher Joe un peu moins haut, puis tout de suite la
   carte de « Commencer » ; le tableau et le reste passent dessous. L'écran de la conversation ne change pas. */
@media (max-width: 899.98px) and (orientation: portrait) {
    .live[data-phase="intro"] { display: flex; flex-direction: column; }
    .live[data-phase="intro"] .live-stage, .live[data-phase="intro"] .live-panel { display: contents; }
    .live[data-phase="intro"] .live-stage > *, .live[data-phase="intro"] .live-panel > * { order: 5; }
    .live[data-phase="intro"] .live-head { order: 0; margin-bottom: var(--space-2); }
    .live[data-phase="intro"] .live-head h1 { font-size: var(--fs-lg); }
    .live[data-phase="intro"] .live-stage > .teacher { order: 1; margin-bottom: var(--space-2); }
    .live[data-phase="intro"] .live-stage > .teacher3d-toggle { order: 2; }
    .live[data-phase="intro"] .live-panel > #error, .live[data-phase="intro"] .live-panel > #whatsapp-help { order: 3; margin-bottom: var(--space-3); }
    .live[data-phase="intro"] .live-panel > #intro { order: 4; padding: var(--space-3) var(--space-4); }
    .live[data-phase="intro"] .live-stage > #board-home { order: 6; margin-top: var(--space-3); }
    .live[data-phase="intro"] .teacher-3d .teacher3d-stage { height: clamp(160px, 32vh, 300px); height: clamp(160px, 32svh, 300px); }
    .js .live[data-phase="intro"][data-teacher="loading"] .teacher { min-height: clamp(160px, 32vh, 300px); min-height: clamp(160px, 32svh, 300px); }
    .live[data-phase="intro"] .face { height: clamp(130px, 26vh, 225px); height: clamp(130px, 26svh, 225px); width: auto; }
}

/* Téléphone : l'action principale dans le premier écran (fil d'étapes compact, en-têtes plus courts, bouton de la
   prochaine étape juste sous son titre). */
@media (max-width: 639.98px) {
    .stepper { margin-bottom: var(--space-3); }
    .pay-steps li { flex-direction: row; justify-content: center; }
    .pay-steps li.current { flex: 3; justify-content: flex-start; text-align: left; }
    .pay-steps li:not(.current) .step-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
    .auth-head { margin-bottom: var(--space-3); }
    .auth-head .icon-bubble { display: none; }
    .welcome { gap: var(--space-3); margin-bottom: var(--space-3); }
    .welcome img { width: 48px; height: 48px; }
    .welcome h1 { font-size: var(--fs-xl); }
    .next-card:not(.next-step-card) { display: flex; flex-direction: column; }
    .next-card:not(.next-step-card) > * { order: 3; }
    .next-card:not(.next-step-card) > .next-card-eyebrow { order: 0; align-self: flex-start; }
    .next-card:not(.next-step-card) > h2 { order: 1; margin-bottom: var(--space-3); text-align: left; align-self: stretch; }
    .next-card:not(.next-step-card) > .btn, .next-card:not(.next-step-card) > .recording-hint { order: 2; }
    .next-card:not(.next-step-card) > .btn { margin-bottom: var(--space-3); }
    .next-card:not(.next-step-card) > .next-card-note { order: 4; }
}

/* Téléphone : paiement, état d'un paiement et résultat de l'évaluation plus courts au-dessus du bouton. */
@media (max-width: 639.98px) {
    .status-head { padding-top: 0; }
    .status-head .icon-bubble { width: 48px; height: 48px; margin-bottom: var(--space-2); }
    .status-head .icon-bubble .icon { width: 26px; height: 26px; }
    .result-teacher { width: 88px; height: 88px; }
    .result-main h1 { font-size: var(--fs-xl); }
}
.result-help { margin: var(--space-3) 0 var(--space-1); }
.contact-whatsapp { margin-bottom: var(--space-4); }
.forgot-steps-title { margin: var(--space-5) 0 var(--space-2); font-size: var(--fs-md); }
.edit-goals-link { margin: 0 0 var(--space-4); }
/* « Mon programme », sur téléphone : le bouton de la leçon juste sous son titre, la description dessous. */
@media (max-width: 639.98px) {
    .next-step-card.next-step-compact { display: flex; flex-direction: column; }
    .next-step-card.next-step-compact > .next-card-eyebrow { align-self: flex-start; }
    .next-step-card.next-step-compact > h2 { text-align: left; align-self: stretch; }
    .next-step-card.next-step-compact > .next-step-text { order: 3; margin: var(--space-3) 0 0; }
}
.courses-add { margin-bottom: var(--space-4); }
/* Pages pays, sur téléphone : photo moins haute, le bouton de l'évaluation dans le premier écran. */
@media (max-width: 639.98px) {
    .page-hero .photo-frame { aspect-ratio: 2 / 1; order: 2; }
    .page-hero .photo-frame img { width: 100%; height: 100%; object-fit: cover; }
}

/* Cohérence (octobre 2026) : petit titre orange sur une bande bleu pâle, orange plus foncé (accent-strong n'y
   donne que 4,2:1, accent-ink donne plus de 6:1). */
.band-soft .section-head .eyebrow, .band-soft .eyebrow { color: var(--c-accent-ink); }
/* État vide dans une carte : la marge intérieure de la carte reste (le texte ne touche plus les bords). */
.card.empty-state { padding: var(--space-5) var(--space-4); }
.card.empty-state .icon-bubble { width: 64px; height: 64px; margin-bottom: var(--space-3); }
/* « Affichage plus léger » (avant « Commencer ») : zone de toucher de 44 pixels de haut au moins, même texte, même
   comportement. */
.teacher3d-toggle { min-height: 44px; display: flex; align-items: center; justify-content: center; margin-left: auto; margin-right: auto; }
/* Accueil, cartes des publics qu'on fait glisser (téléphone) : chaque carte à la hauteur de son contenu, sans grand
   vide en bas quand une voisine est plus longue. */
@media (max-width: 719.98px) {
    .audiences > .audience { align-self: start; }
}
/* Pages pays et « À propos », téléphone : l'icône à côté du titre, le texte sur toute la largeur de la carte (deux
   fois moins de lignes, même texte). */
@media (max-width: 639.98px) {
    .card.feature { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: var(--space-2) var(--space-3); align-items: center; }
    .card.feature > div { display: contents; }
    .card.feature .icon-bubble { width: 44px; height: 44px; }
    .card.feature .icon-bubble .icon { width: 22px; height: 22px; }
    .card.feature h3 { margin: 0; }
    .card.feature p { grid-column: 1 / -1; }
}
/* Contact : le fondateur, petite photo ronde et son nom, sous le bouton WhatsApp. */
.contact-founder { display: flex; align-items: center; gap: var(--space-3); margin: var(--space-4) 0; }
.contact-founder img { flex: none; width: 56px; height: 56px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 3px var(--c-surface), 0 0 0 5px var(--c-accent); }
.contact-founder p { margin: 0; display: grid; line-height: 1.35; }
.contact-founder strong { color: var(--c-primary-strong); }
.contact-founder span { font-size: var(--fs-sm); color: var(--c-muted); }
/* Vérification d'une attestation : le code reste d'un seul tenant. */
.attestation-code { white-space: nowrap; }
.attestation-fresh { border-top: 4px solid var(--c-accent); }
/* Visage de Teacher Joe (<x-teacher-face>) en tête des pages d'erreur, hors connexion et états vides. */
.teacher-face { display: block; width: var(--face, 96px); height: var(--face, 96px); margin: 0 auto var(--space-4); }
.empty-state .code { font-size: 3rem; }

/* Fluidité sur téléphone (moins de 900 pixels) : les formes rondes restent à leur place sans tourner en boucle
   (la règle du projet réserve ces animations à l'ordinateur), et l'en-tête fixe est plein, de la même couleur, sans
   flou (le flou sous un en-tête fixe est recalculé à chaque image du défilement). */
@media (max-width: 899.98px) {
    .students::before, .cta-band::before, .cta-band::after, .result-hero::before { animation: none; }
    .site-header { background: var(--c-bg); backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* Dynamisme de l'accueil (octobre 2026). Apparition des cartes des étapes et des publics : glissement latéral léger,
   alterné (gauche, droite), avec fondu ; seulement transform et opacity ; coupé avec « réduire les animations ». */
.js .reveal.reveal-side { transform: translateX(-22px); }
.js .reveal.reveal-side:nth-child(even) { transform: translateX(22px); }
.js .reveal.reveal-side.is-visible { transform: none; }
/* Photos des publics : léger cadre orange décalé, le texte ne bouge pas. */
.audience .photo-frame { box-shadow: 5px 5px 0 var(--c-accent); margin: 0 5px 5px 0; }
/* « En bref » avant l'appel final : quatre faits vérifiés, en pastilles. */
.in-short { margin: 0 0 var(--space-5); text-align: center; }
.in-short-title { font-size: var(--fs-lg); margin: 0 0 var(--space-3); }
.in-short-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); }
.in-short-list li { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-3); border-radius: var(--radius); background: var(--c-surface); border: 1px solid var(--c-border); font-size: var(--fs-sm); font-weight: var(--fw-bold); color: var(--c-primary-strong); text-align: left; line-height: 1.3; }
.in-short-list .icon { flex: none; color: var(--c-accent-strong); }
@media (min-width: 900px) {
    .in-short-list { grid-template-columns: repeat(4, minmax(0, 1fr)); max-width: 960px; margin: 0 auto; }
}
@media (prefers-reduced-motion: reduce) {
    .js .reveal.reveal-side, .js .reveal.reveal-side:nth-child(even) { opacity: 1; transform: none; }
}
/* Teacher Joe pensif (image de notre modèle 3D, tools/brand/teacher-expressions.mjs) : pastille au coin de
   « Ce n'est pas un manque d'intelligence… », sur téléphone seulement, sans couvrir le texte ni allonger le bloc. */
.persuade-answer { position: relative; }
.persuade-face { position: absolute; top: -20px; right: 10px; width: 40px; height: 40px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--c-surface), 0 0 0 4px var(--c-accent); }
/* Tablette et ordinateur : l'encadré tient sur deux lignes jusqu'au bord, la pastille le rallongerait. */
@media (min-width: 640px) { .persuade-face { display: none; } }

/* Liens TikTok et chaîne WhatsApp (<x-social-links>) : texte seul, zone de toucher de 44 pixels. */
.social-links { margin: 0; padding: 0; list-style: none; }
.social-links a { display: inline-flex; align-items: center; min-height: 44px; }
.contact-social, .about-social { display: flex; flex-wrap: wrap; gap: 0 var(--space-4); margin: var(--space-3) 0; font-weight: var(--fw-bold); }
/* « À propos » : l'histoire de la plateforme, texte lisible sur toute la largeur de la carte. */
.result-share { margin-top: var(--space-3); }
.result-share .btn { width: 100%; }
.result-share p { margin: var(--space-1) 0 0; }
.country-pay { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: var(--space-2); margin: var(--space-3) 0 0; }
.about-story p { margin: 0 0 var(--space-3); max-width: 68ch; }
.about-story .about-social { margin-bottom: 0; }

/* « Comment ça marche » : aperçu léger, bouton « Regarder », lecteur seulement après le toucher. */
.how-data { display: flex; gap: var(--space-2); align-items: flex-start; justify-content: center; text-align: left; }
.how-data .icon { flex: none; margin-top: 2px; }
.how-video { text-align: center; }
.watch, .watch-player { position: relative; display: block; width: auto; max-width: 100%; height: min(50svh, 640px); aspect-ratio: 480 / 854; margin: var(--space-3) auto; border-radius: var(--radius-lg); overflow: hidden; background: var(--c-primary); box-shadow: var(--shadow-sm); }
.watch img { display: block; width: 100%; height: 100%; object-fit: cover; }
.watch-button { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: inline-flex; gap: var(--space-2); align-items: center; min-height: 56px; padding: 0 var(--space-5); border-radius: var(--radius-pill); background: var(--c-accent); color: var(--c-on-accent); font-weight: var(--fw-bold); box-shadow: var(--shadow-sm); }
.watch:focus-visible .watch-button, .watch:hover .watch-button { outline: 3px solid var(--c-surface); }
.how-steps { margin: var(--space-3) 0 var(--space-5); padding-left: var(--space-5); display: grid; gap: var(--space-2); }
.hero-how { margin: var(--space-3) 0 0; text-align: center; font-size: var(--fs-sm); }
.hero-how a { display: inline-flex; align-items: center; min-height: 44px; font-weight: var(--fw-bold); }
.plans-questions { margin: var(--space-3) 0 0; font-size: var(--fs-sm); text-align: center; }
/* Toute la phrase est le lien : zone de toucher de 44 pixels, jamais un point seul sur sa ligne. */
.plans-questions a { display: inline-flex; gap: var(--space-2); align-items: center; min-height: 44px; font-weight: var(--fw-bold); text-align: left; }
.plans-questions .icon { flex: none; color: var(--c-accent-strong); }
