/* =====================================================================
   KalanHub — style commun (repris de la démo validée)
   Bleu nuit = actions · Vert = bonnes nouvelles · Rouge = retards
   ===================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Space+Grotesk:wght@500;600;700&display=swap');

:root {
  --navy: #1E3A5F;
  --navy-dark: #152B47;
  --navy-soft: #EEF4FF;
  --green: #1F7A50;
  --green-ink: #135C3B;
  --green-soft: #ECF7F1;
  --red: #B42318;
  --red-soft: #FEF3F2;
  --amber-ink: #93370D;
  --amber-soft: #FFFAEB;

  --ink: #101828;
  --ink-2: #344054;
  --muted: #475467;
  --muted-2: #667085;
  --line: #E4E7EC;
  --line-2: #F2F4F7;
  --field: #D0D5DD;
  --bg: #F6F7F9;
  --white: #FFFFFF;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.05);
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --font-title: 'Space Grotesk', 'Inter', system-ui, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--navy); }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }

/* L'app garde une largeur de téléphone, même sur ordinateur */
.app {
  max-width: 480px;
  min-height: 100vh;
  margin: 0 auto;
  background: var(--bg);
  display: flex;
  flex-direction: column;
}
.app.white { background: var(--white); }
.page { flex: 1; padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.page.with-nav { padding-bottom: 96px; }

/* ---------- Titres et textes ---------- */
h1, .h1 { margin: 0; font-family: var(--font-title); font-size: 24px; font-weight: 600; letter-spacing: -0.5px; line-height: 1.2; }
h2, .h2 { margin: 0; font-size: 15px; font-weight: 600; }
.section-title { margin: 0; font-size: 13px; font-weight: 600; letter-spacing: 0.6px; text-transform: uppercase; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.num { font-variant-numeric: tabular-nums; }
.big-num { font-family: var(--font-title); font-size: 26px; font-weight: 600; letter-spacing: -0.5px; font-variant-numeric: tabular-nums; }

/* ---------- Barre du haut ---------- */
.topbar {
  display: flex; align-items: center; gap: 4px;
  padding: 8px 12px; background: var(--white);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 10;
}
.topbar .title { flex: 1; font-size: 15px; font-weight: 600; }
.icon-btn {
  width: 44px; height: 44px; border: 0; background: none; border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--ink-2); cursor: pointer; text-decoration: none;
}

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 18px; border-radius: 12px;
  font: inherit; font-size: 15px; font-weight: 600; text-decoration: none;
  cursor: pointer; border: 1px solid transparent;
}
.btn-primary { background: var(--navy); color: var(--white); }
.btn-primary:hover { background: var(--navy-dark); color: var(--white); }
.btn-secondary { background: var(--white); color: var(--ink-2); border-color: var(--field); box-shadow: var(--shadow); }
.btn-block { width: 100%; }
.btn[disabled] { background: var(--line); color: var(--muted); cursor: not-allowed; }
.btn-sm { min-height: 40px; font-size: 13px; padding: 0 14px; border-radius: 10px; }
.btn-link { background: none; border: 0; padding: 0; min-height: 40px; color: var(--navy); font: inherit; font-weight: 600; cursor: pointer; }

/* Barre d'action fixée en bas */
.action-bar {
  position: sticky; bottom: 0; background: var(--white);
  border-top: 1px solid var(--line); padding: 12px 20px 16px;
  display: flex; flex-direction: column; gap: 8px;
}

/* ---------- Cartes et listes ---------- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.list { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); display: flex; flex-direction: column; overflow: hidden; }
.list-row {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px;
  border-bottom: 1px solid var(--line-2); color: var(--ink); text-decoration: none; min-height: 44px;
}
.list-row:last-child { border-bottom: 0; }
.list-row .grow { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.row-title { font-size: 15px; font-weight: 600; }

/* ---------- Champs ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.label { font-size: 14px; font-weight: 500; color: var(--ink-2); }
.input, .select, .textarea {
  width: 100%; min-height: 48px; border: 1px solid var(--field); border-radius: var(--radius-sm);
  padding: 0 14px; font: inherit; font-size: 15px; color: var(--ink); background: var(--white); box-shadow: var(--shadow);
}
.textarea { padding: 12px 14px; min-height: 96px; resize: vertical; line-height: 1.5; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 4px rgba(30, 58, 95, 0.12); }
.hint { font-size: 13px; color: var(--muted); }
.error { font-size: 13px; color: var(--red); }

/* ---------- Pastilles, badges, avatars ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; flex-wrap: nowrap; }
.chip {
  flex: none; min-height: 36px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--field); background: var(--white); color: var(--ink-2);
  font: inherit; font-size: 13px; font-weight: 500; cursor: pointer;
}
.chip[aria-pressed="true"], .chip.on { background: var(--navy); border-color: var(--navy); color: var(--white); }

.badge { flex: none; display: inline-flex; align-items: center; font-size: 12px; font-weight: 500; padding: 2px 8px; border-radius: 999px; border: 1px solid; }
.badge-new { background: var(--navy-soft); color: var(--navy); border-color: #C7D7FE; }
.badge-contacted { background: var(--amber-soft); color: var(--amber-ink); border-color: #FEDF89; }
.badge-rdv { background: #F4F3FF; color: #3D3466; border-color: #D9D6FE; }
.badge-ok, .badge-enrolled { background: var(--green-soft); color: var(--green-ink); border-color: #ABEFC6; }
.badge-late, .badge-refused { background: var(--red-soft); color: #912018; border-color: #FECDCA; }

.avatar {
  width: 40px; height: 40px; flex: none; border-radius: 999px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 600; background: var(--navy-soft); color: var(--navy);
}
.logo-tile {
  width: 48px; height: 48px; flex: none; border-radius: 12px; background: var(--navy); color: var(--white);
  display: inline-flex; align-items: center; justify-content: center; overflow: hidden;
  font-family: var(--font-title); font-weight: 700; font-size: 16px;
}
.logo-tile img { width: 100%; height: 100%; object-fit: cover; }

/* Barre de progression */
.bar { height: 8px; border-radius: 999px; background: var(--line-2); overflow: hidden; }
.bar > span { display: block; height: 100%; border-radius: 999px; background: var(--navy); }
.bar.green > span { background: var(--green); }

/* Interrupteur et onglets */
.segmented { display: flex; background: var(--line-2); border-radius: 8px; padding: 3px; gap: 2px; }
.segmented button, .segmented a {
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; background: transparent; color: var(--muted); border-radius: 6px;
  padding: 0 12px; min-height: 32px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
}
.segmented button[aria-pressed="true"], .segmented a[aria-pressed="true"] { background: var(--white); color: var(--ink); box-shadow: 0 1px 2px rgba(16, 24, 40, 0.08); }

.tabs { display: flex; gap: 20px; overflow-x: auto; }
.tabs button {
  flex: none; border: 0; background: none; font: inherit; font-size: 14px; font-weight: 500;
  color: var(--muted); padding: 10px 0 12px; min-height: 44px; border-bottom: 2px solid transparent; cursor: pointer;
}
.tabs button[aria-selected="true"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--navy); }

/* Alertes */
.alert { border-radius: 12px; padding: 12px 14px; font-size: 13px; line-height: 1.45; border: 1px solid; }
.alert-warn { background: var(--amber-soft); border-color: #FEDF89; color: #7A2E0E; }
.alert-ok { background: var(--green-soft); border-color: #ABEFC6; color: #0B4A2E; }
.alert-err { background: var(--red-soft); border-color: #FECDCA; color: #7A271A; }

/* Barre de navigation du bas */
.bottom-nav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; z-index: 20;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  background: var(--white); border-top: 1px solid var(--line); padding: 6px 6px 12px;
}
.bottom-nav a, .bottom-nav > button {
  position: relative; text-decoration: none; color: var(--muted-2);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  font-size: 11px; font-weight: 500; min-height: 50px;
}
.bottom-nav a[aria-current="page"], .bottom-nav > button[aria-current="page"] { color: var(--navy); font-weight: 600; }
.bottom-nav .dot {
  position: absolute; top: 4px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px; background: #D92D20; color: var(--white); font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; border: 2px solid var(--white);
}

/* Chargement */
.loading { padding: 40px 0; text-align: center; color: var(--muted); font-size: 14px; }
.empty { padding: 40px 0; text-align: center; color: var(--muted); font-size: 14px; }

/* Message bref en bas de l'écran */
.toast {
  position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%);
  background: var(--ink); color: var(--white); padding: 10px 16px; border-radius: 10px;
  font-size: 14px; z-index: 50; max-width: 90%;
}

/* Finition KalanHub : contraste, états tactiles et lisibilité cohérente. */
:where(a, button, input, select, textarea, [role="button"]) { -webkit-tap-highlight-color: transparent; }
:where(a, button, input, select, textarea, [role="button"]):focus-visible {
  outline: 3px solid rgba(30, 58, 95, .3);
  outline-offset: 3px;
}
button, input, select, textarea { font-family: var(--font); }
.btn, .icon-btn, .bottom-nav a, .bottom-nav > button { transition: background-color .18s ease, border-color .18s ease, color .18s ease, box-shadow .18s ease, transform .18s ease; }
.btn-primary { box-shadow: 0 3px 8px rgba(30, 58, 95, .14); }
.btn-primary:hover { box-shadow: 0 5px 14px rgba(30, 58, 95, .2); transform: translateY(-1px); }
.card, .list, .list-row, .action-bar { box-shadow: 0 2px 10px rgba(16, 24, 40, .035); }
.list-row { transition: background-color .18s ease; }
.list-row:hover { background: #F9FAFB; }
.tiny, .badge, .eyebrow, .side-help p { font-size: 13px; }
.bottom-nav a, .bottom-nav > button { font-size: 13px; }
.bottom-nav { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
.action-bar { padding-bottom: max(16px, env(safe-area-inset-bottom)); }

@media (max-width: 420px) {
  .page { padding-left: 16px; padding-right: 16px; }
  .card { padding: 15px; }
  .bottom-nav { padding-left: 3px; padding-right: 3px; }
  .bottom-nav a, .bottom-nav > button { gap: 3px; font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* Feuille qui monte du bas (menu « Plus ») */
dialog.sheet {
  border: 0; padding: 0; margin: auto auto 0; width: 100%; max-width: 480px;
  border-radius: 18px 18px 0 0; background: var(--bg);
}
dialog.sheet::backdrop, dialog::backdrop { background: rgba(16, 24, 40, 0.45); }

/* =====================================================================
   Grand écran (tablette et ordinateur) — style de la maquette v0
   Téléphone : rien ne change.
   ===================================================================== */
.eyebrow { font-size: 11px; font-weight: 700; letter-spacing: 1.1px; text-transform: uppercase; color: var(--muted-2); }
.side-only { display: none !important; }

/* Tablette : un peu plus large */
@media (min-width: 640px) {
  .app { max-width: 640px; }
  .bottom-nav, dialog.sheet { max-width: 640px; }
}

/* Pages sans menu (vitrine publique, connexion, leçon…) : colonne confortable */
@media (min-width: 1024px) {
  .app { max-width: 760px; }
  .toast { bottom: 28px; }
  dialog.sheet { margin: auto; border-radius: 18px; max-width: 480px; }

  /* Leçon : contenu à gauche, actions à droite */
  .app.lesson { max-width: 1120px; display: grid; grid-template-columns: minmax(0, 1fr) 320px; grid-template-rows: auto 1fr; align-items: start; }
  .app.lesson > .topbar { grid-column: 1 / -1; }
  .app.lesson > .page { padding: 28px 36px; }
  .app.lesson > .action-bar { position: sticky; top: 20px; margin: 28px 24px 0 0; border: 1px solid var(--line); border-radius: var(--radius); }
  .app.lesson .side-only { display: flex !important; }
  .app.lesson > .action-bar { flex-direction: column; }
}

/* Pages avec menu : barre latérale à gauche (comme la maquette) */
@media (min-width: 1024px) {
  body.has-side .app { max-width: none; margin: 0 0 0 256px; }
  body.has-side .app > header { padding-left: 40px !important; padding-right: 40px !important; }
  body.has-side .page { width: 100%; max-width: 1120px; margin: 0 auto; padding: 32px 40px 48px; }
  body.has-side .page.with-nav { padding-bottom: 48px; }
  body.has-side .mob-only { display: none !important; }
  body.has-side .side-only { display: flex !important; }

  body.has-side .bottom-nav {
    left: 0; top: 0; bottom: 0; transform: none; width: 256px; max-width: none;
    display: flex; flex-direction: column; gap: 4px; padding: 20px 14px 16px;
    border-top: 0; border-right: 1px solid var(--line); overflow-y: auto;
  }
  body.has-side .bottom-nav a, body.has-side .bottom-nav > button {
    flex-direction: row; justify-content: flex-start; gap: 12px; min-height: 44px;
    padding: 0 12px; border-radius: 10px; font-size: 14px; color: var(--muted);
  }
  body.has-side .bottom-nav a:hover, body.has-side .bottom-nav > button:hover { background: var(--line-2); }
  body.has-side .bottom-nav a[aria-current="page"], body.has-side .bottom-nav > button[aria-current="page"] { background: var(--navy-soft); color: var(--navy); }
  body.has-side .bottom-nav .dot { position: static; margin-left: auto; border: 0; }
  body.has-side #nav-more { display: none !important; }

  body.has-side .bottom-nav a.side-brand { align-items: center; gap: 10px; padding: 4px 8px 18px; min-height: 0; text-decoration: none; color: var(--navy-dark); font-family: var(--font-title); font-size: 21px; font-weight: 700; letter-spacing: -0.6px; background: none; }
  .side-brand span { color: #7288A5; }
  .side-switch { gap: 2px; padding: 4px; margin: 0 2px 16px; border-radius: 11px; background: var(--line-2); }
  .side-switch a { flex: 1; min-height: 32px !important; justify-content: center !important; padding: 0 !important; font-size: 13px !important; font-weight: 600; color: var(--muted-2) !important; }
  .side-switch a[aria-current="true"] { background: var(--white) !important; color: var(--navy) !important; box-shadow: 0 1px 3px rgba(22, 43, 70, 0.08); }
  .side-label { padding: 6px 12px 6px; }
  .side-sep { height: 1px; background: var(--line); margin: 12px 8px; }
  .side-foot { margin-top: auto; flex-direction: column; gap: 10px; padding: 12px 6px 0; }
  .side-help { flex-direction: column; gap: 6px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg); }
  .side-help strong { font-size: 14px; color: var(--ink); }
  .side-help p { margin: 0; font-size: 12px; color: var(--muted); line-height: 1.45; }

  /* Accueil élève : bandeau bleu nuit */
  body.has-side .home-head { margin: 32px 40px 0; padding: 36px 40px !important; border: 0 !important; border-radius: 18px; background: linear-gradient(135deg, var(--navy) 0%, #24496f 100%) !important; color: var(--white); }
  body.has-side .home-head h1 { font-size: 40px; letter-spacing: -1px; max-width: 640px; }
  body.has-side .home-head .eyebrow { color: #C0D0E1; }
  body.has-side .home-head .input, body.has-side .home-head .select { max-width: 640px; }
  body.has-side .home-head label.small { color: #C0D0E1; }
  body.has-side .home-head .muted { color: #C0D0E1 !important; }
  body.has-side #cats-wrap { padding: 24px 40px 0 !important; max-width: 1200px; }

  /* Listes en grille de cartes */
  body.has-side .grid-cards { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; background: none; border: 0; box-shadow: none; overflow: visible; align-content: start; }
  body.has-side .grid-cards > .list-row { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
  body.has-side .grid-cards > .list-row:hover { border-color: #CFD8E3; }
  body.has-side .grid-cards > .alert, body.has-side .grid-cards > .empty, body.has-side .grid-cards > .loading, body.has-side .grid-cards > .wide { grid-column: 1 / -1; }
}


/* Application en anglais : page masquée le temps de la traduction (2,5 s max) */
html.kh-i18n body { visibility: hidden; }
.kh-lang { flex: none; margin-left: 8px; min-width: 38px; height: 32px; padding: 0 8px; border: 1px solid #D0D5DD; border-radius: 9px; background: #fff; color: #1E3A5F; font: 700 12px/1 system-ui, sans-serif; letter-spacing: .5px; cursor: pointer; }
.kh-lang:hover { background: #F2F4F7; }
/* En anglais, les libellés du bas sont plus longs (« Students », « Schedule ») */
@media (max-width: 420px) { html[lang="en"] .bottom-nav a, html[lang="en"] .bottom-nav > button { font-size: 12px !important; letter-spacing: -.2px; } }

/* Téléphone : la barre du haut doit tenir avec le bouton FR / EN */
@media (max-width: 420px) {
  body.kh .kh-top { gap: 6px !important; padding-left: 10px !important; padding-right: 10px !important; }
  body.kh .kh-switch a[href="/a-propos.html"]:not([aria-current]) { display: none; }   /* « À propos » est dans Profil */
  body.kh .kh-switch:has(a[href="/a-propos.html"][aria-current]) a { padding-left: 6px !important; padding-right: 6px !important; }
  .kh-lang { margin-left: 2px; min-width: 32px; height: 30px; padding: 0 5px; font-size: 11px; }
}
/* Page de connexion : le « ? » d'aide descend (pas de barre en bas) */
body.auth-body #kh-help-btn { bottom: calc(16px + env(safe-area-inset-bottom)); }


/* ===== Pages de connexion et de demande (carte centrée) ===== */
body.auth-body { background: linear-gradient(180deg, #EEF2F7 0%, #F7F8FA 60%); min-height: 100vh; margin: 0; }
.auth { max-width: 460px; margin: 0 auto; padding: 18px 16px 32px; display: flex; flex-direction: column; gap: 14px; }
.auth-back { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); text-decoration: none; font-size: 14px; align-self: flex-start; }
.auth-back svg { width: 18px; height: 18px; }
.auth-card { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 22px 18px; display: flex; flex-direction: column; gap: 16px; box-shadow: 0 8px 28px rgba(16, 24, 40, .07); }
.auth-brand { display: flex; align-items: center; justify-content: center; gap: 10px; text-decoration: none; color: var(--navy); font: 700 22px/1 var(--font-title, inherit); }
.auth-brand b { color: #2E7D4F; font-weight: 700; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; background: var(--line-2); border-radius: 12px; padding: 4px; gap: 4px; }
.auth-tabs button { border: 0; background: transparent; border-radius: 9px; min-height: 44px; font: inherit; font-size: 15px; font-weight: 600; color: var(--ink-2); cursor: pointer; }
.auth-tabs button[aria-selected="true"] { background: #fff; color: var(--navy); box-shadow: 0 1px 3px rgba(16, 24, 40, .1); }
.auth-head h1 { margin: 0 0 4px; font-size: 24px; }
.auth-head p { margin: 0; color: var(--ink-2); font-size: 15px; }
.auth-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.auth-mini { display: flex; gap: 2px; background: var(--line-2); border-radius: 8px; padding: 2px; }
.auth-mini button { border: 0; background: transparent; border-radius: 6px; padding: 5px 10px; font: inherit; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.auth-mini button[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(16, 24, 40, .08); }
.auth-phone { display: flex; border: 1px solid var(--field); border-radius: 10px; overflow: hidden; min-height: 48px; background: #fff; }
.auth-phone:focus-within, .auth-pass .input:focus { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(30, 58, 95, .12); }
.auth-phone select { border: 0; border-right: 1px solid var(--line); background: #F7F8FA; padding: 0 6px 0 10px; font: inherit; font-size: 15px; color: var(--ink); width: 142px; flex: none; }
.auth-phone input { border: 0; outline: none; padding: 0 14px; font: inherit; font-size: 16px; flex: 1; min-width: 0; }
.auth-pass { position: relative; }
.auth-pass .input { padding-right: 48px; width: 100%; box-sizing: border-box; }
.auth-pass button { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 40px; height: 40px; border: 0; background: transparent; color: var(--ink-2); cursor: pointer; display: grid; place-items: center; }
.auth-pass button svg { width: 20px; height: 20px; }
.auth-hint { font-size: 13px; color: var(--ink-2); }
.auth-forgot { align-self: flex-end; border: 0; background: none; padding: 2px 0; color: var(--navy); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.auth-submit { min-height: 50px; font-size: 16px; }
.auth-switch { margin: 0; text-align: center; font-size: 14px; color: var(--ink-2); }
.auth-switch button { border: 0; background: none; padding: 0; color: var(--navy); font: inherit; font-weight: 700; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.auth-note { margin: 0; text-align: center; font-size: 13px; color: var(--ink-2); line-height: 1.5; padding: 0 8px; }
@media (min-width: 641px) { .auth { padding-top: 40px; } .auth-card { padding: 28px 28px; } }

/* Partagé par la demande d'inscription */
.auth-center { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: #F9FAFB; }
.auth-center .logo-tile { flex: none; }
.auth-center b { display: block; font-size: 16px; color: var(--ink); }
.auth-center span { font-size: 13px; color: var(--ink-2); }
.auth-me { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 12px; background: #ECFDF3; color: #05603A; font-size: 14px; }
.auth-me strong { color: #054F31; }
.auth-sub { font-size: 13px; color: var(--ink-2); margin: 0; text-align: center; }
.auth-sub a { color: var(--navy); font-weight: 600; }
.auth .textarea { min-height: 96px; }
.auth .two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 380px) { .auth .two { grid-template-columns: 1fr; } }

/* Tailles fixées (la couche Lisibilité ferait passer ces libellés sur 2 lignes) */
.auth-tabs button { font-size: 16px !important; }
.auth-mini button { font-size: 13px !important; }

/* >>> LISIBILITÉ (généré par tools/lisibilite.py — ne pas modifier à la main) >>> */
@media (max-width: 640px) { html, body { font-size: 19px; } }
@media (min-width: 641px) { html, body { font-size: 16px; } }
@media (max-width: 640px) { h1, .h1 { font-size: 26px; } }
@media (max-width: 640px) { h2, .h2 { font-size: 19px; } }
@media (min-width: 641px) { h2, .h2 { font-size: 16px; } }
@media (max-width: 640px) { .section-title { font-size: 17px; } }
@media (min-width: 641px) { .section-title { font-size: 15px; } }
@media (max-width: 640px) { .small { font-size: 17px; } }
@media (min-width: 641px) { .small { font-size: 15px; } }
@media (max-width: 640px) { .tiny { font-size: 16px; } }
@media (min-width: 641px) { .tiny { font-size: 14px; } }
@media (max-width: 640px) { .big-num { font-size: 28px; } }
@media (max-width: 640px) { .topbar .title { font-size: 19px; } }
@media (min-width: 641px) { .topbar .title { font-size: 16px; } }
@media (max-width: 640px) { .btn { font-size: 19px; } }
@media (min-width: 641px) { .btn { font-size: 16px; } }
@media (max-width: 640px) { .btn-sm { font-size: 17px; } }
@media (min-width: 641px) { .btn-sm { font-size: 15px; } }
@media (max-width: 640px) { .row-title { font-size: 19px; } }
@media (min-width: 641px) { .row-title { font-size: 16px; } }
@media (max-width: 640px) { .label { font-size: 18px; } }
@media (min-width: 641px) { .label { font-size: 15px; } }
@media (max-width: 640px) { .input, .select, .textarea { font-size: 19px; } }
@media (min-width: 641px) { .input, .select, .textarea { font-size: 16px; } }
@media (max-width: 640px) { .hint { font-size: 17px; } }
@media (min-width: 641px) { .hint { font-size: 15px; } }
@media (max-width: 640px) { .error { font-size: 17px; } }
@media (min-width: 641px) { .error { font-size: 15px; } }
@media (max-width: 640px) { .chip { font-size: 17px; } }
@media (min-width: 641px) { .chip { font-size: 15px; } }
@media (max-width: 640px) { .badge { font-size: 16px; } }
@media (min-width: 641px) { .badge { font-size: 14px; } }
@media (max-width: 640px) { .avatar { font-size: 18px; } }
@media (min-width: 641px) { .avatar { font-size: 15px; } }
@media (max-width: 640px) { .logo-tile { font-size: 20px; } }
@media (min-width: 641px) { .logo-tile { font-size: 17px; } }
@media (max-width: 640px) { .segmented button, .segmented a { font-size: 17px; } }
@media (min-width: 641px) { .segmented button, .segmented a { font-size: 15px; } }
@media (max-width: 640px) { .tabs button { font-size: 18px; } }
@media (min-width: 641px) { .tabs button { font-size: 15px; } }
@media (max-width: 640px) { .alert { font-size: 17px; } }
@media (min-width: 641px) { .alert { font-size: 15px; } }
@media (max-width: 640px) { .bottom-nav a, .bottom-nav > button { font-size: 15px; } }
@media (min-width: 641px) { .bottom-nav a, .bottom-nav > button { font-size: 13px; } }
@media (max-width: 640px) { .bottom-nav .dot { font-size: 15px; } }
@media (min-width: 641px) { .bottom-nav .dot { font-size: 13px; } }
@media (max-width: 640px) { .loading { font-size: 18px; } }
@media (min-width: 641px) { .loading { font-size: 15px; } }
@media (max-width: 640px) { .empty { font-size: 18px; } }
@media (min-width: 641px) { .empty { font-size: 15px; } }
@media (max-width: 640px) { .toast { font-size: 18px; } }
@media (min-width: 641px) { .toast { font-size: 15px; } }
@media (max-width: 640px) { .tiny, .badge, .eyebrow, .side-help p { font-size: 17px; } }
@media (min-width: 641px) { .tiny, .badge, .eyebrow, .side-help p { font-size: 15px; } }
@media (max-width: 640px) { .bottom-nav a, .bottom-nav > button { font-size: 17px; } }
@media (min-width: 641px) { .bottom-nav a, .bottom-nav > button { font-size: 15px; } }
@media (max-width: 420px) and (max-width: 640px) { .bottom-nav a, .bottom-nav > button { font-size: 17px; } }
@media (max-width: 640px) { .eyebrow { font-size: 15px; } }
@media (min-width: 641px) { .eyebrow { font-size: 13px; } }
@media (min-width: 1024px) and (min-width: 641px) { body.has-side .bottom-nav a, body.has-side .bottom-nav > button { font-size: 15px; } }
@media (min-width: 1024px) and (min-width: 641px) { .side-switch a { font-size: 15px !important; } }
@media (min-width: 1024px) and (min-width: 641px) { .side-help strong { font-size: 15px; } }
@media (min-width: 1024px) and (min-width: 641px) { .side-help p { font-size: 14px; } }
@media (max-width: 640px) { .kh-lang { font-size: 16px; } }
@media (min-width: 641px) { .kh-lang { font-size: 14px; } }
@media (max-width: 420px) and (max-width: 640px) { html[lang="en"] .bottom-nav a, html[lang="en"] .bottom-nav > button { font-size: 16px !important; } }
@media (max-width: 420px) and (max-width: 640px) { .kh-lang { font-size: 15px; } }
@media (max-width: 640px) { .auth-back { font-size: 18px; } }
@media (min-width: 641px) { .auth-back { font-size: 15px; } }
@media (max-width: 640px) { .auth-brand { font-size: 24px; } }
@media (max-width: 640px) { .auth-head h1 { font-size: 26px; } }
@media (max-width: 640px) { .auth-head p { font-size: 19px; } }
@media (min-width: 641px) { .auth-head p { font-size: 16px; } }
@media (max-width: 640px) { .auth-phone select { font-size: 19px; } }
@media (min-width: 641px) { .auth-phone select { font-size: 16px; } }
@media (max-width: 640px) { .auth-phone input { font-size: 20px; } }
@media (min-width: 641px) { .auth-phone input { font-size: 17px; } }
@media (max-width: 640px) { .auth-hint { font-size: 17px; } }
@media (min-width: 641px) { .auth-hint { font-size: 15px; } }
@media (max-width: 640px) { .auth-forgot { font-size: 18px; } }
@media (min-width: 641px) { .auth-forgot { font-size: 15px; } }
@media (max-width: 640px) { .auth-submit { font-size: 20px; } }
@media (min-width: 641px) { .auth-submit { font-size: 17px; } }
@media (max-width: 640px) { .auth-switch { font-size: 18px; } }
@media (min-width: 641px) { .auth-switch { font-size: 15px; } }
@media (max-width: 640px) { .auth-note { font-size: 17px; } }
@media (min-width: 641px) { .auth-note { font-size: 15px; } }
@media (max-width: 640px) { .auth-center b { font-size: 20px; } }
@media (min-width: 641px) { .auth-center b { font-size: 17px; } }
@media (max-width: 640px) { .auth-center span { font-size: 17px; } }
@media (min-width: 641px) { .auth-center span { font-size: 15px; } }
@media (max-width: 640px) { .auth-me { font-size: 18px; } }
@media (min-width: 641px) { .auth-me { font-size: 15px; } }
@media (max-width: 640px) { .auth-sub { font-size: 17px; } }
@media (min-width: 641px) { .auth-sub { font-size: 15px; } }
/* <<< LISIBILITÉ <<< */
