/* ============================================================
   Parcours RGPD — feuille de style
   ============================================================ */

:root {
  --bg: #f5f7fb;
  --bg-soft: #eef1f8;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --border: #e3e8f0;
  --text: #101828;
  --text-soft: #5a6a85;
  --text-mute: #8a97ab;

  --brand: #4f46e5;
  --brand-2: #7c3aed;
  --brand-soft: #eef2ff;
  --teal: #0d9488;
  --ok: #12b76a;
  --ok-soft: #e7f8ef;
  --warn: #f79009;
  --warn-soft: #fff5e6;
  --danger: #e11d48;
  --danger-soft: #ffeaef;
  --info: #0ea5e9;
  --info-soft: #e8f6fe;

  --accent: var(--brand);

  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 26px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .05), 0 1px 3px rgba(16, 24, 40, .06);
  --shadow: 0 4px 12px rgba(16, 24, 40, .07), 0 12px 28px rgba(16, 24, 40, .06);
  --shadow-lg: 0 18px 50px rgba(16, 24, 40, .14);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

html[data-theme='dark'] {
  --bg: #0c1020;
  --bg-soft: #121729;
  --surface: #161c31;
  --surface-2: #1c2338;
  --border: #2a3350;
  --text: #eef2fb;
  --text-soft: #a8b4cd;
  --text-mute: #7d8aa6;
  --brand: #8b8cff;
  --brand-2: #b78bff;
  --brand-soft: #232a49;
  --ok-soft: #12301f;
  --warn-soft: #33260f;
  --danger-soft: #3a1220;
  --info-soft: #0f2a3d;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow: 0 6px 22px rgba(0, 0, 0, .45);
  --shadow-lg: 0 22px 60px rgba(0, 0, 0, .6);
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
  /* Pas de surlignement bleu au double-clic ou au glissé : l'interface est
     faite de zones cliquables, la sélection de texte n'y a pas d'usage. */
  -webkit-user-select: none;
  -moz-user-select: none;
  user-select: none;
  /* Supprime aussi le flash bleu au toucher sur mobile. */
  -webkit-tap-highlight-color: transparent;
}

/* Les champs de saisie doivent évidemment rester sélectionnables. */
input, textarea, select, [contenteditable] {
  -webkit-user-select: text;
  -moz-user-select: text;
  user-select: text;
}

h1, h2, h3, h4 { line-height: 1.22; margin: 0 0 .5em; font-weight: 700; letter-spacing: -.02em; }
p { margin: 0 0 1em; }
a { color: var(--brand); }
button { font-family: inherit; }

::selection { background: color-mix(in srgb, var(--brand) 25%, transparent); }

/* ─────────────── Boutons ─────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  padding: .72em 1.35em; border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; font-size: .95rem; cursor: pointer;
  background: var(--brand); color: #fff;
  transition: transform .15s, box-shadow .2s, background .2s, opacity .2s;
  box-shadow: 0 2px 8px color-mix(in srgb, var(--brand) 35%, transparent);
}
.btn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 8px 20px color-mix(in srgb, var(--brand) 35%, transparent); }
.btn:active:not(:disabled) { transform: translateY(0); }
.btn:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
.btn.ghost { background: transparent; color: var(--text-soft); border-color: var(--border); box-shadow: none; }
.btn.ghost:hover:not(:disabled) { background: var(--surface-2); color: var(--text); }
.btn.soft { background: var(--brand-soft); color: var(--brand); box-shadow: none; }
.btn.soft:hover:not(:disabled) { background: color-mix(in srgb, var(--brand) 16%, var(--surface)); }
.btn.lg { padding: .95em 2em; font-size: 1.05rem; }
.btn.sm { padding: .45em .95em; font-size: .84rem; }
.btn.danger { background: var(--danger); box-shadow: 0 2px 8px color-mix(in srgb, var(--danger) 35%, transparent); }

/* ─────────────── Écran d'authentification ─────────────── */
.auth {
  min-height: 100vh; display: grid; grid-template-columns: 1.05fr .95fr;
}
.auth__brand {
  position: relative; overflow: hidden; color: #fff;
  background: linear-gradient(140deg, #4f46e5 0%, #7c3aed 45%, #0d9488 120%);
  display: flex; flex-direction: column; justify-content: center; padding: 4rem 4.5rem;
}
.auth__brand::before, .auth__brand::after {
  content: ''; position: absolute; border-radius: 50%; filter: blur(2px); opacity: .18;
  background: radial-gradient(circle at 30% 30%, #fff, transparent 65%);
}
.auth__brand::before { width: 520px; height: 520px; top: -160px; right: -140px; animation: float 16s ease-in-out infinite; }
.auth__brand::after { width: 380px; height: 380px; bottom: -120px; left: -100px; animation: float 20s ease-in-out infinite reverse; }
@keyframes float { 50% { transform: translate(26px, -30px) scale(1.06); } }

.auth__logo { display: flex; align-items: center; gap: .75rem; font-weight: 800; font-size: 1.15rem; letter-spacing: -.01em; margin-bottom: 3rem; position: relative; }
/* Le logo est posé sur une pastille blanche : ses roses et ses bleus se
   perdraient sur le dégradé violet du panneau de gauche. */
.auth__logo .mark {
  width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; padding: 5px;
  background: #fff; box-shadow: 0 4px 14px rgba(0, 0, 0, .18);
}
.auth__brand h1 { font-size: clamp(2rem, 3.4vw, 3rem); position: relative; margin-bottom: .35em; }
.auth__brand p { font-size: 1.08rem; opacity: .92; max-width: 30ch; position: relative; }
.auth__features { list-style: none; padding: 0; margin: 2.5rem 0 0; display: grid; gap: 1rem; position: relative; }
.auth__features li { display: flex; align-items: flex-start; gap: .85rem; font-size: .98rem; opacity: .95; }
.auth__features .ico {
  flex: none; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .2);
}

.auth__panel { display: grid; place-items: center; padding: 2.5rem; background: var(--bg); }
.auth__card { width: min(430px, 100%); }
.auth__tabs { display: flex; gap: .3rem; background: var(--bg-soft); padding: .3rem; border-radius: 999px; margin-bottom: 1.8rem; }
.auth__tabs button {
  flex: 1; padding: .65em 1em; border: 0; background: transparent; border-radius: 999px;
  font-weight: 600; color: var(--text-soft); cursor: pointer; transition: .2s;
}
.auth__tabs button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }

.field { margin-bottom: 1.05rem; }
.field label { display: block; font-size: .85rem; font-weight: 600; color: var(--text-soft); margin-bottom: .4rem; }
.field input, .field select, .field textarea {
  width: 100%; padding: .8em 1em; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font-size: .98rem; font-family: inherit; transition: .18s;
}
.field input:focus, .field select:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 14%, transparent);
}
.field .hint { font-size: .78rem; color: var(--text-mute); margin-top: .35rem; }

.alert { padding: .8em 1em; border-radius: var(--radius-sm); font-size: .9rem; margin-bottom: 1rem; display: flex; gap: .6em; align-items: flex-start; }
.alert.err { background: var(--danger-soft); color: var(--danger); }
.alert.ok { background: var(--ok-soft); color: var(--ok); }

/* ─────────────── Shell applicatif ─────────────── */
.topbar {
  position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--surface) 86%, transparent);
  backdrop-filter: blur(14px); border-bottom: 1px solid var(--border);
}
.topbar__in { max-width: 1180px; margin: 0 auto; padding: .7rem 1.4rem; display: flex; align-items: center; gap: 1.2rem; }
.topbar__logo { display: flex; align-items: center; gap: .6rem; font-weight: 800; cursor: pointer; letter-spacing: -.02em; }
.topbar__logo .mark {
  width: 36px; height: 36px; display: grid; place-items: center; flex: none;
}

/* Le logo garde ses couleurs propres : pas de fond ni de teinte appliquée. */
.logo-img { display: block; width: 100%; height: 100%; object-fit: contain; }
.topbar__nav { display: flex; gap: .2rem; margin-left: .6rem; }
.topbar__nav button {
  border: 0; background: transparent; padding: .5em .9em; border-radius: 999px; cursor: pointer;
  color: var(--text-soft); font-weight: 600; font-size: .9rem; transition: .18s;
}
.topbar__nav button:hover { background: var(--surface-2); color: var(--text); }
.topbar__nav button.on { background: var(--brand-soft); color: var(--brand); }
.topbar__spacer { flex: 1; }

.xpchip {
  display: flex; align-items: center; gap: .6rem; padding: .35rem .8rem .35rem .45rem;
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px;
}
.xpchip .lvl {
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: .8rem; font-weight: 700;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
}
.xpchip .bar { width: 96px; height: 6px; border-radius: 99px; background: var(--border); overflow: hidden; }
.xpchip .bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--brand), var(--teal)); transition: width .6s cubic-bezier(.2,.8,.2,1); }
.xpchip .val { font-size: .78rem; font-weight: 700; color: var(--text-soft); white-space: nowrap; }

.iconbtn {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--border); background: var(--surface);
  cursor: pointer; display: grid; place-items: center; font-size: 1rem; color: var(--text-soft); transition: .18s;
}
.iconbtn:hover { background: var(--surface-2); color: var(--text); transform: translateY(-1px); }

.avatar {
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; cursor: pointer;
  font-weight: 700; font-size: .85rem; color: #fff; background: linear-gradient(135deg, var(--teal), var(--brand));
  border: 2px solid var(--surface); box-shadow: var(--shadow-sm);
}
.menu {
  position: absolute; right: 1.4rem; top: 62px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow-lg); min-width: 230px; padding: .45rem; z-index: 60;
  animation: pop .16s ease-out;
}
.menu .who { padding: .7rem .8rem; border-bottom: 1px solid var(--border); margin-bottom: .3rem; }
.menu .who b { display: block; font-size: .93rem; }
.menu .who span { font-size: .8rem; color: var(--text-mute); word-break: break-all; }
.menu button {
  width: 100%; text-align: left; border: 0; background: transparent; padding: .6em .8em; border-radius: 8px;
  cursor: pointer; color: var(--text); font-size: .9rem; display: flex; gap: .6em; align-items: center;
}
.menu button:hover { background: var(--surface-2); }
@keyframes pop { from { opacity: 0; transform: translateY(-6px) scale(.98); } }

main { max-width: 1180px; margin: 0 auto; padding: 2.2rem 1.4rem 5rem; }

/* ─────────────── Accueil / carte du parcours ─────────────── */
.hero-home {
  position: relative; overflow: hidden; border-radius: var(--radius-lg); padding: 2.4rem 2.6rem;
  background: linear-gradient(135deg, #4f46e5, #7c3aed 55%, #0d9488); color: #fff; margin-bottom: 2.2rem;
  box-shadow: var(--shadow);
}
.hero-home::after {
  content: ''; position: absolute; width: 420px; height: 420px; border-radius: 50%; right: -120px; top: -180px;
  background: radial-gradient(circle, rgba(255,255,255,.22), transparent 68%);
}
.hero-home h1 { font-size: clamp(1.6rem, 3vw, 2.3rem); margin-bottom: .3em; position: relative; }
.hero-home p { opacity: .93; max-width: 56ch; position: relative; margin-bottom: 1.4rem; }
.hero-home .row { display: flex; flex-wrap: wrap; gap: 2rem; position: relative; align-items: center; }
.hero-home .btn { background: #fff; color: var(--brand); box-shadow: 0 6px 20px rgba(0,0,0,.18); }
.hero-home .btn:hover { background: #fff; }

.ring { --p: 0; width: 104px; height: 104px; flex: none; position: relative; display: grid; place-items: center; }
.ring::before {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(#fff calc(var(--p) * 1%), rgba(255,255,255,.22) 0);
  mask: radial-gradient(farthest-side, transparent calc(100% - 9px), #000 calc(100% - 8px));
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 9px), #000 calc(100% - 8px));
  transition: background .8s cubic-bezier(.2,.8,.2,1);
}
.ring b { font-size: 1.5rem; font-weight: 800; }
.ring small { display: block; font-size: .68rem; opacity: .85; text-align: center; margin-top: -4px; }

.section-title { display: flex; align-items: baseline; gap: .8rem; margin: 2.4rem 0 1.1rem; }
.section-title h2 { font-size: 1.28rem; margin: 0; }
.section-title span { font-size: .87rem; color: var(--text-mute); }

.path { display: grid; gap: 1rem; }
.node {
  display: flex; gap: 1.2rem; align-items: center; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.1rem 1.3rem; cursor: pointer; position: relative;
  transition: transform .18s, box-shadow .22s, border-color .2s;
}
.node:hover:not(.locked) { transform: translateY(-3px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }
.node.locked { opacity: .55; cursor: not-allowed; }
.node__badge {
  flex: none; width: 58px; height: 58px; border-radius: 18px; display: grid; place-items: center; font-size: 1.6rem;
  background: color-mix(in srgb, var(--accent) 14%, var(--surface)); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent);
  position: relative;
}
.node__num {
  position: absolute; top: -7px; left: -7px; width: 24px; height: 24px; border-radius: 50%; font-size: .72rem;
  display: grid; place-items: center; color: #fff; font-weight: 700; background: var(--accent); border: 2px solid var(--surface);
}
.node__body { flex: 1; min-width: 0; }
.node__body h3 { font-size: 1.05rem; margin: 0 0 .15em; }
.node__body p { margin: 0; font-size: .88rem; color: var(--text-soft); }
.node__meta { display: flex; gap: .8rem; margin-top: .45rem; font-size: .78rem; color: var(--text-mute); flex-wrap: wrap; }
.node__state { flex: none; font-size: 1.5rem; }
.node.done { border-color: color-mix(in srgb, var(--ok) 40%, var(--border)); }
.node.done .node__badge { background: var(--ok-soft); border-color: color-mix(in srgb, var(--ok) 30%, transparent); }
.node.current { box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }

.pill { display: inline-flex; align-items: center; gap: .35em; padding: .2em .65em; border-radius: 999px; font-size: .74rem; font-weight: 700; }
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.info { background: var(--info-soft); color: var(--info); }
.pill.brand { background: var(--brand-soft); color: var(--brand); }

/* Carte finale : questionnaire */
.finale {
  margin-top: 1rem; border-radius: var(--radius); padding: 1.6rem 1.8rem; border: 1px dashed var(--border);
  background: linear-gradient(135deg, var(--surface), var(--surface-2)); display: flex; gap: 1.4rem; align-items: center; flex-wrap: wrap;
}
.finale.ready { border: 1px solid transparent; background: linear-gradient(135deg, #101828, #2b1c5a); color: #fff; box-shadow: var(--shadow); }
.finale.ready p { color: rgba(255,255,255,.85); }
.finale .em { font-size: 2.6rem; }
.finale h3 { margin: 0 0 .2em; }
.finale p { margin: 0; font-size: .9rem; color: var(--text-soft); }
.finale .grow { flex: 1; min-width: 220px; }

/* Badges */
.badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(148px, 1fr)); gap: .9rem; }
.badge {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.1rem .9rem;
  text-align: center; transition: .2s;
}
.badge .em { font-size: 2rem; display: block; filter: grayscale(1); opacity: .35; transition: .3s; }
.badge b { display: block; font-size: .85rem; margin-top: .35rem; }
.badge small { font-size: .74rem; color: var(--text-mute); display: block; margin-top: .2rem; line-height: 1.35; }
.badge.on { border-color: color-mix(in srgb, var(--warn) 45%, var(--border)); background: linear-gradient(180deg, var(--warn-soft), var(--surface)); }
.badge.on .em { filter: none; opacity: 1; animation: badgePop .5s cubic-bezier(.2,1.4,.4,1); }
@keyframes badgePop { 0% { transform: scale(.4) rotate(-16deg); } 60% { transform: scale(1.18) rotate(6deg); } }

/* ─────────────── Chapitre ─────────────── */
.chapter-head { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.4rem; }
.chapter-head .back { flex: none; }
.chapter-head .info { flex: 1; min-width: 0; }
.chapter-head .info b { font-size: .78rem; text-transform: uppercase; letter-spacing: .09em; color: var(--accent); }
.chapter-head .info h2 { margin: .1rem 0 0; font-size: 1.2rem; }

.steps-bar { display: flex; gap: 6px; margin-bottom: 1.8rem; }
.steps-bar i {
  height: 5px; flex: 1; border-radius: 99px; background: var(--border); transition: background .35s, transform .35s;
}
.steps-bar i.done { background: color-mix(in srgb, var(--accent) 55%, var(--border)); }
.steps-bar i.on { background: var(--accent); transform: scaleY(1.7); }

.step { animation: stepIn .42s cubic-bezier(.2,.8,.2,1); }
@keyframes stepIn { from { opacity: 0; transform: translateY(16px); } }

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 2.2rem 2.4rem; box-shadow: var(--shadow-sm);
}
.card h2 { font-size: 1.55rem; }
.card h3 { font-size: 1.15rem; }
.card .intro { color: var(--text-soft); font-size: 1rem; }

.step-hero { text-align: center; padding: 3.2rem 2.4rem; }
.step-hero .kicker { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.step-hero .em { font-size: 3.6rem; display: block; margin-bottom: .6rem; animation: bob 3s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-9px); } }
.step-hero h2 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); margin: .3em 0 .45em; }
.step-hero p { font-size: 1.06rem; color: var(--text-soft); max-width: 60ch; margin: 0 auto; }

/* Cartes en grille */
.grid-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1rem; margin-top: 1.4rem; }
.mini {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.3rem;
  transition: transform .2s, box-shadow .2s;
}
.mini:hover { transform: translateY(-3px); box-shadow: var(--shadow-sm); }
.grid-cards.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cards.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.mini .em { font-size: 1.7rem; display: block; margin-bottom: .5rem; }
.mini b { display: block; margin-bottom: .3rem; font-size: 1rem; }
.mini p { margin: 0 0 .6rem; font-size: .9rem; color: var(--text-soft); }
.mini p:last-child { margin-bottom: 0; }
.mini .src {
  margin-top: .8rem; padding-top: .7rem; border-top: 1px solid var(--border);
  font-size: .78rem; color: var(--text-mute);
}

/* Définition */
.defbox {
  border-left: 4px solid var(--accent); background: color-mix(in srgb, var(--accent) 6%, var(--surface-2));
  border-radius: 0 var(--radius) var(--radius) 0; padding: 1.5rem 1.7rem; margin-top: 1.2rem;
}
.defbox .term { font-size: 1.25rem; font-weight: 700; }
.defbox .src { font-size: .78rem; color: var(--text-mute); margin-bottom: .8rem; }
.defbox .txt { font-size: 1.02rem; }
.chips { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: 1rem; }
.chips span {
  background: var(--surface); border: 1px solid var(--border); padding: .32em .8em; border-radius: 999px; font-size: .84rem; color: var(--text-soft);
}

/* Callout */
.callout { border-radius: var(--radius); padding: 1.4rem 1.6rem; display: flex; gap: 1rem; margin-top: 1.2rem; }
.callout .em { font-size: 1.5rem; flex: none; }
.callout b { display: block; margin-bottom: .3rem; }
.callout p { margin: 0; font-size: .96rem; }
.callout.info { background: var(--info-soft); color: color-mix(in srgb, var(--info) 75%, var(--text)); }
.callout.warn { background: var(--warn-soft); color: color-mix(in srgb, var(--warn) 78%, var(--text)); }
.callout.danger { background: var(--danger-soft); color: color-mix(in srgb, var(--danger) 78%, var(--text)); }

/* Timeline */
.timeline { position: relative; margin-top: 1.6rem; padding-left: 2.2rem; }
.timeline::before { content: ''; position: absolute; left: 9px; top: 8px; bottom: 8px; width: 2px; background: var(--border); }
.tl-item { position: relative; padding-bottom: 1.7rem; }
.tl-item::before {
  content: ''; position: absolute; left: -2.2rem; top: 5px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--surface); border: 3px solid var(--border);
}
.tl-item.hl::before { border-color: var(--accent); box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 15%, transparent); }
.tl-item .date { font-size: .78rem; font-weight: 800; color: var(--accent); letter-spacing: .04em; }
.tl-item b { display: block; margin: .1rem 0 .25rem; }
.tl-item p { margin: 0; font-size: .93rem; color: var(--text-soft); }

/* Pyramide */
.pyramid { display: grid; gap: .8rem; margin-top: 1.4rem; }
.pyr-level {
  border-radius: var(--radius); padding: 1.2rem 1.4rem; border: 1px solid var(--border); background: var(--surface-2);
  display: flex; gap: 1rem; align-items: flex-start; transition: transform .2s;
  border-left: 5px solid var(--lvl);
}
.pyr-level:hover { transform: translateX(5px); }
.pyr-level .em { font-size: 1.6rem; flex: none; }
.pyr-level b { display: block; color: var(--lvl); margin-bottom: .25rem; }
.pyr-level p { margin: 0; font-size: .92rem; color: var(--text-soft); }

/* Split 2 colonnes */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.4rem; }
.split .col { border-radius: var(--radius); padding: 1.4rem 1.5rem; border: 1px solid var(--border); background: var(--surface-2); }
.split .col .em { font-size: 1.7rem; display: block; margin-bottom: .5rem; }
.split .col b { display: block; font-size: 1.05rem; margin-bottom: .5rem; }
.split .col p { font-size: .93rem; color: var(--text-soft); margin: 0; white-space: pre-line; }
.split .col ul { margin: .3rem 0 0; padding-left: 1.1rem; font-size: .92rem; color: var(--text-soft); }
.split .col ul li { margin-bottom: .45rem; }
.split .col.danger { background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 22%, transparent); }
.split .col.ok { background: var(--ok-soft); border-color: color-mix(in srgb, var(--ok) 22%, transparent); }
.split .col.warn { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 22%, transparent); }

/* Listes à puces enrichies */
.blist { display: grid; gap: .8rem; margin-top: 1.4rem; }
.blist .row { display: flex; gap: 1rem; padding: 1rem 1.2rem; border-radius: var(--radius); background: var(--surface-2); border: 1px solid var(--border); }
.blist .row .n {
  flex: none; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-size: .95rem;
  background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); font-weight: 700;
}
.blist .row b { display: block; margin-bottom: .15rem; }
.blist .row p { margin: 0; font-size: .92rem; color: var(--text-soft); }

/* Grille 6 bases légales */
.grid6 { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: .9rem; margin-top: 1.4rem; }
.grid6 .cell {
  border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem; background: var(--surface-2);
  transition: .2s; position: relative; overflow: hidden;
}
.grid6 .cell::before {
  content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 12%, transparent), transparent 60%);
  opacity: 0; transition: .25s;
}
.grid6 .cell:hover { transform: translateY(-3px); box-shadow: var(--shadow-sm); }
.grid6 .cell:hover::before { opacity: 1; }
.grid6 .em { font-size: 1.5rem; display: block; margin-bottom: .4rem; position: relative; }
.grid6 b { display: block; margin-bottom: .25rem; position: relative; }
.grid6 p { margin: 0; font-size: .88rem; color: var(--text-soft); position: relative; }

/* Checklist */
.checklist { display: grid; gap: .6rem; margin-top: 1.4rem; }
.checklist .item {
  display: flex; gap: .9rem; align-items: flex-start; padding: .95rem 1.2rem; border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px solid var(--border); cursor: pointer; transition: .18s;
}
.checklist .item:hover { border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); }
.checklist .item .box {
  flex: none; width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--border); display: grid; place-items: center;
  font-size: .8rem; color: transparent; transition: .18s; margin-top: 1px;
}
.checklist .item.on { background: var(--ok-soft); border-color: color-mix(in srgb, var(--ok) 30%, transparent); }
.checklist .item.on .box { background: var(--ok); border-color: var(--ok); color: #fff; }
.checklist .item span { font-size: .95rem; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 1rem; margin-top: 1.4rem; }
.stat { text-align: center; padding: 1.4rem 1rem; border-radius: var(--radius); background: var(--surface-2); border: 1px solid var(--border); }
.stat b { display: block; font-size: 2.2rem; font-weight: 800; letter-spacing: -.03em; color: var(--accent); }
.stat span { font-size: .84rem; color: var(--text-soft); }

/* Outro */
.outro { text-align: center; padding: 3rem 2.4rem; }
.outro .em { font-size: 4rem; display: block; animation: bob 3s ease-in-out infinite; }
.outro .mail {
  display: inline-block; margin-top: 1rem; padding: .6em 1.3em; border-radius: 999px;
  background: var(--brand-soft); color: var(--brand); font-weight: 600; text-decoration: none;
}

/* Navigation de chapitre */
.step-nav { display: flex; gap: .8rem; align-items: center; margin-top: 1.6rem; }
.step-nav .grow { flex: 1; }
.step-count { font-size: .84rem; color: var(--text-mute); font-weight: 600; }

/* ─────────────── Loupe / mots-clés ─────────────── */
.kw {
  display: inline; cursor: pointer; font-weight: 600; color: var(--accent);
  border-bottom: 1.5px dashed color-mix(in srgb, var(--accent) 55%, transparent);
  padding: 0 .1em; border-radius: 3px; transition: background .18s;
  position: relative;
}
.kw::after { content: '\00a0🔍'; font-size: .78em; opacity: .75; }
.kw:hover { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.kw.seen { color: var(--text-soft); border-bottom-color: var(--border); }
.kw.seen::after { opacity: .4; }

.overlay {
  position: fixed; inset: 0; background: rgba(10, 14, 30, .55); backdrop-filter: blur(4px);
  display: grid; place-items: center; z-index: 100; padding: 1.4rem; animation: fade .18s;
}
@keyframes fade { from { opacity: 0; } }
.modal {
  background: var(--surface); border-radius: var(--radius-lg); width: min(560px, 100%); max-height: 86vh; overflow: auto;
  box-shadow: var(--shadow-lg); animation: modalIn .28s cubic-bezier(.2,.9,.3,1.1); position: relative;
}
@keyframes modalIn { from { opacity: 0; transform: translateY(24px) scale(.96); } }
.modal__head {
  padding: 1.6rem 1.8rem 1.2rem; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 14%, var(--surface)), var(--surface));
  border-bottom: 1px solid var(--border); position: sticky; top: 0; backdrop-filter: blur(8px);
}
.modal__head .lens { font-size: 1.7rem; }
.modal__head h3 { margin: .3rem 0 .1rem; font-size: 1.35rem; }
.modal__head .sub { font-size: .82rem; color: var(--text-mute); }
.modal__body { padding: 1.4rem 1.8rem 1.8rem; }
.modal__body p { font-size: .98rem; }
.modal__body ul { padding-left: 1.1rem; margin: .8rem 0 0; }
.modal__body li { font-size: .93rem; color: var(--text-soft); margin-bottom: .55rem; }
.modal__close {
  position: absolute; top: 1rem; right: 1rem; width: 32px; height: 32px; border-radius: 50%; border: 0;
  background: var(--surface-2); cursor: pointer; font-size: 1rem; color: var(--text-soft); z-index: 2;
}
.modal__close:hover { background: var(--border); }
.modal .srcline { margin-top: 1.1rem; padding-top: .9rem; border-top: 1px solid var(--border); font-size: .8rem; color: var(--text-mute); }

/* ─────────────── Mini-jeux ─────────────── */
.game { border: 2px solid color-mix(in srgb, var(--accent) 25%, var(--border)); border-radius: var(--radius-lg); padding: 2rem 2.2rem; background: var(--surface); }
.game__head { display: flex; align-items: center; gap: .8rem; margin-bottom: .4rem; }
.game__head .em { font-size: 1.5rem; }
.game__head h3 { margin: 0; font-size: 1.25rem; }
.game__head .score { margin-left: auto; font-weight: 800; color: var(--accent); font-size: .95rem; }
.game .intro { color: var(--text-soft); font-size: .94rem; margin-bottom: 1.4rem; }

/* Vrai / faux */
.tf-card {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.8rem;
  text-align: center; font-size: 1.12rem; font-weight: 600; margin-bottom: 1.2rem; min-height: 110px;
  display: grid; place-items: center; animation: stepIn .3s;
}
.tf-actions { display: flex; gap: 1rem; justify-content: center; }
.tf-actions .btn { min-width: 140px; }
.tf-actions .btn.vrai { background: var(--ok); box-shadow: 0 2px 8px color-mix(in srgb, var(--ok) 35%, transparent); }
.tf-actions .btn.faux { background: var(--danger); box-shadow: 0 2px 8px color-mix(in srgb, var(--danger) 35%, transparent); }

.feedback { border-radius: var(--radius); padding: 1.1rem 1.3rem; margin-top: 1.2rem; animation: stepIn .3s; font-size: .94rem; }
.feedback.good { background: var(--ok-soft); color: color-mix(in srgb, var(--ok) 80%, var(--text)); }
.feedback.bad { background: var(--danger-soft); color: color-mix(in srgb, var(--danger) 80%, var(--text)); }
.feedback b { display: block; margin-bottom: .25rem; }

/* QCM */
.opt {
  display: flex; gap: .85rem; align-items: flex-start; width: 100%; text-align: left; padding: 1rem 1.2rem; margin-bottom: .6rem;
  border-radius: var(--radius-sm); border: 1.5px solid var(--border); background: var(--surface-2); cursor: pointer;
  font-size: .96rem; color: var(--text); transition: .16s; font-family: inherit;
}
.opt:hover:not(:disabled) { border-color: var(--accent); transform: translateX(3px); }
.opt .let {
  flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; font-weight: 700; font-size: .82rem;
  background: var(--surface); border: 1px solid var(--border);
}
.opt.good { background: var(--ok-soft); border-color: var(--ok); }
.opt.good .let { background: var(--ok); color: #fff; border-color: var(--ok); }
.opt.bad { background: var(--danger-soft); border-color: var(--danger); }
.opt.bad .let { background: var(--danger); color: #fff; border-color: var(--danger); }
.opt.sel { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 9%, var(--surface-2)); }
.opt.sel .let { background: var(--accent); color: #fff; border-color: var(--accent); }
.opt:disabled { cursor: default; }

/* Tri (sort) */
.sort-item {
  background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--radius-sm); padding: 1rem 1.3rem;
  font-weight: 600; text-align: center; margin-bottom: 1.2rem; box-shadow: var(--shadow-sm); animation: stepIn .28s;
}
.sort-cats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: .8rem; }
/* Bordure pleine, et non en pointillés : ce sont des boutons à cliquer,
   pas des zones de dépôt — le pointillé suggérait un glisser-déposer. */
.sort-cat {
  border: 2px solid color-mix(in srgb, var(--c) 45%, var(--border)); border-radius: var(--radius); padding: 1.2rem .9rem;
  text-align: center; cursor: pointer; background: color-mix(in srgb, var(--c) 7%, var(--surface-2)); transition: .18s;
  font-family: inherit; color: var(--text); width: 100%; box-shadow: var(--shadow-sm);
}
.sort-cat:hover:not(:disabled) {
  transform: translateY(-3px); box-shadow: var(--shadow);
  background: color-mix(in srgb, var(--c) 15%, var(--surface-2));
}
.sort-cat:active:not(:disabled) { transform: translateY(0); }
.sort-cat .em { font-size: 1.5rem; display: block; margin-bottom: .3rem; }
.sort-cat b { font-size: .88rem; color: var(--c); }
.sort-cat:disabled { opacity: .5; cursor: default; }

/* Association (match) */
.match-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.match-col { display: grid; gap: .55rem; align-content: start; }
.match-col h4 { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-mute); margin: 0 0 .2rem; }
.match-item {
  padding: .85rem 1rem; border-radius: var(--radius-sm); border: 1.5px solid var(--border); background: var(--surface-2);
  cursor: pointer; font-size: .9rem; text-align: left; transition: .16s; font-family: inherit; color: var(--text);
}
.match-item:hover:not(:disabled) { border-color: var(--accent); }
.match-item.sel { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, var(--surface-2)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 15%, transparent); }
.match-item.paired { opacity: .45; cursor: default; border-style: dashed; }
.match-item.flash-good { border-color: var(--ok); background: var(--ok-soft); }
.match-item.flash-bad { border-color: var(--danger); background: var(--danger-soft); animation: shake .35s; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* Remise en ordre */
.order-list { display: grid; gap: .6rem; }
.order-item {
  display: flex; align-items: center; gap: .9rem; padding: .95rem 1.1rem; border-radius: var(--radius-sm);
  border: 1.5px solid var(--border); background: var(--surface-2); cursor: grab; font-size: .94rem;
}
.order-item.dragging { opacity: .4; }
.order-item .handle { color: var(--text-mute); font-size: 1.1rem; cursor: grab; }
.order-item .arrows { margin-left: auto; display: flex; gap: .25rem; }
.order-item .arrows button {
  width: 28px; height: 28px; border-radius: 8px; border: 1px solid var(--border); background: var(--surface);
  cursor: pointer; color: var(--text-soft); font-size: .8rem;
}
.order-item .arrows button:hover { background: var(--brand-soft); color: var(--brand); }
.order-item.good { border-color: var(--ok); background: var(--ok-soft); }
.order-item.bad { border-color: var(--danger); background: var(--danger-soft); }

/* Phishing */
.mailbox { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface-2); }
.mailbox__head { padding: 1rem 1.3rem; border-bottom: 1px solid var(--border); background: var(--surface); font-size: .88rem; }
.mailbox__head .line { display: flex; gap: .5rem; margin-bottom: .3rem; }
.mailbox__head .line .lbl { color: var(--text-mute); min-width: 62px; }
.mailbox__head .subject { font-weight: 700; font-size: 1rem; margin-top: .5rem; }
.mailbox__body { padding: 1.4rem 1.3rem; font-size: .95rem; white-space: pre-wrap; line-height: 1.7; }
.clue {
  cursor: pointer; border-radius: 4px; padding: .05em .25em; background: color-mix(in srgb, var(--warn) 12%, transparent);
  border-bottom: 2px dotted color-mix(in srgb, var(--text-mute) 60%, transparent); transition: .16s;
}
.clue:hover { background: color-mix(in srgb, var(--warn) 25%, transparent); }
.clue.found { background: var(--ok-soft); border-bottom-color: var(--ok); color: color-mix(in srgb, var(--ok) 75%, var(--text)); font-weight: 600; }
.clue.miss { background: var(--danger-soft); }
.clue-list { margin-top: 1.2rem; display: grid; gap: .5rem; }
.clue-list .found-item {
  padding: .8rem 1rem; border-radius: var(--radius-sm); background: var(--ok-soft); font-size: .89rem;
  color: color-mix(in srgb, var(--ok) 80%, var(--text)); animation: stepIn .3s;
}
.clue-counter { text-align: center; font-weight: 700; color: var(--accent); margin: 1rem 0 0; }

/* Testeur de mot de passe */
.pw-box { margin-top: 1.4rem; }
.pw-box input {
  width: 100%; padding: 1em 1.2em; border-radius: var(--radius-sm); border: 1.5px solid var(--border);
  background: var(--surface); color: var(--text); font-size: 1.05rem; font-family: ui-monospace, monospace;
}
.pw-box input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent); }
.pw-meter { height: 9px; border-radius: 99px; background: var(--border); margin: .9rem 0 .6rem; overflow: hidden; }
.pw-meter i { display: block; height: 100%; width: 0; border-radius: 99px; transition: width .35s, background .35s; }
.pw-verdict { font-weight: 700; font-size: .95rem; margin-bottom: .8rem; }
/* Champ mot de passe avec bouton afficher/masquer */
.pw-input { position: relative; }
.pw-input input { padding-right: 3rem; }
.pw-eye {
  position: absolute; right: .5rem; top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px; border: 0; background: transparent; cursor: pointer;
  border-radius: 8px; font-size: 1rem; line-height: 1;
}
.pw-eye:hover { background: var(--surface-2); }

.pw-rules { display: grid; gap: .4rem; }
.pw-rules div { font-size: .88rem; color: var(--text-mute); display: flex; gap: .5rem; align-items: center; }
.pw-rules div.on { color: var(--ok); }

/* Résultat de mini-jeu */
.game-done {
  text-align: center; padding: 1.8rem; border-radius: var(--radius); margin-top: 1.4rem;
  background: linear-gradient(135deg, var(--brand-soft), var(--surface-2)); animation: stepIn .4s;
}
.game-done .em { font-size: 2.6rem; display: block; }
.game-done b { display: block; font-size: 1.15rem; margin: .4rem 0 .2rem; }
.game-done p { margin: 0; font-size: .9rem; color: var(--text-soft); }

/* ─────────────── Questionnaire final ─────────────── */
.quiz-shell { max-width: 800px; margin: 0 auto; }
.quiz-top { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.4rem; }
.quiz-top .prog { flex: 1; height: 8px; border-radius: 99px; background: var(--border); overflow: hidden; }
.quiz-top .prog i { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--teal)); transition: width .4s; }
.quiz-top .cnt { font-size: .85rem; font-weight: 700; color: var(--text-soft); white-space: nowrap; }
.quiz-q { font-size: 1.22rem; font-weight: 600; margin: .3rem 0 1.4rem; }
.quiz-theme { font-size: .74rem; text-transform: uppercase; letter-spacing: .09em; font-weight: 800; color: var(--accent); }
.quiz-multi-hint { font-size: .82rem; color: var(--text-mute); margin-bottom: .8rem; }

.score-hero { text-align: center; padding: 3rem 2rem 2.4rem; }
.big-ring { --p: 0; --col: var(--brand); width: 180px; height: 180px; margin: 0 auto 1.4rem; position: relative; display: grid; place-items: center; }
.big-ring::before {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(var(--col) calc(var(--p) * 1%), var(--border) 0);
  mask: radial-gradient(farthest-side, transparent calc(100% - 15px), #000 calc(100% - 14px));
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 15px), #000 calc(100% - 14px));
  transition: background 1.2s cubic-bezier(.2,.8,.2,1);
}
.big-ring > div { text-align: center; }
.big-ring b { display: block; font-size: 2.8rem; font-weight: 800; letter-spacing: -.04em; line-height: 1.1; }
.big-ring small { display: block; font-size: .8rem; color: var(--text-mute); }

.theme-bars { display: grid; gap: .8rem; margin-top: 1.4rem; }
.theme-bar { display: flex; align-items: center; gap: 1rem; }
.theme-bar .nm { width: 150px; font-size: .88rem; font-weight: 600; flex: none; }
.theme-bar .tr { flex: 1; height: 10px; border-radius: 99px; background: var(--border); overflow: hidden; }
.theme-bar .tr i { display: block; height: 100%; border-radius: 99px; transition: width .8s; }
.theme-bar .vl { font-size: .82rem; color: var(--text-mute); width: 46px; text-align: right; flex: none; }

.review-item { border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem 1.4rem; margin-bottom: .8rem; }
.review-item.ko { border-color: color-mix(in srgb, var(--danger) 35%, var(--border)); background: color-mix(in srgb, var(--danger) 3%, var(--surface)); }
.review-item .qh { display: flex; gap: .7rem; align-items: flex-start; margin-bottom: .7rem; }
.review-item .qh .st { font-size: 1.1rem; }
.review-item .qh b { font-size: .98rem; font-weight: 600; }
.review-item .ans { font-size: .88rem; display: grid; gap: .3rem; margin-bottom: .6rem; }
.review-item .ans .lbl { color: var(--text-mute); }
.review-item .ans .good { color: var(--ok); font-weight: 600; }
.review-item .ans .bad { color: var(--danger); font-weight: 600; }
.review-item .why { font-size: .88rem; color: var(--text-soft); background: var(--surface-2); border-radius: var(--radius-sm); padding: .7rem .9rem; }

/* Attestation */
.cert {
  background: #fff; color: #101828; border-radius: var(--radius-lg); padding: 3rem; text-align: center;
  border: 3px double #4f46e5; box-shadow: var(--shadow); max-width: 720px; margin: 0 auto;
}
.cert .seal { font-size: 3rem; }
.cert h2 { font-size: 1.7rem; margin: .5rem 0; letter-spacing: -.02em; }
.cert .sub { color: #5a6a85; font-size: .95rem; }
.cert .who { font-size: 1.6rem; font-weight: 800; margin: 1.6rem 0 .3rem; color: #4f46e5; }
.cert .meta { display: flex; justify-content: center; gap: 2.4rem; margin-top: 2rem; flex-wrap: wrap; }
.cert .meta div b { display: block; font-size: 1.3rem; }
.cert .meta div span { font-size: .78rem; color: #5a6a85; }
.cert .ref { margin-top: 2rem; font-size: .74rem; color: #8a97ab; letter-spacing: .05em; }

/* ─────────────── Glossaire ─────────────── */
.gl-search { position: relative; margin-bottom: 1.4rem; }
.gl-search input { width: 100%; padding: .9em 1em .9em 2.8em; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font-size: .98rem; }
.gl-search input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 14%, transparent); }
.gl-search .ico { position: absolute; left: 1.1em; top: 50%; transform: translateY(-50%); color: var(--text-mute); }
.gl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.gl-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.3rem 1.4rem; cursor: pointer; transition: .2s; }
.gl-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--brand) 35%, var(--border)); }
.gl-card b { display: block; font-size: 1.02rem; margin-bottom: .2rem; }
.gl-card .sub { font-size: .76rem; color: var(--text-mute); margin-bottom: .5rem; }
.gl-card p { margin: 0; font-size: .88rem; color: var(--text-soft); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ─────────────── Admin ─────────────── */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
table.data { width: 100%; border-collapse: collapse; font-size: .89rem; min-width: 860px; }
table.data th {
  text-align: left; padding: .9rem 1rem; font-size: .74rem; text-transform: uppercase; letter-spacing: .07em;
  color: var(--text-mute); border-bottom: 1px solid var(--border); background: var(--surface-2); white-space: nowrap;
}
table.data td { padding: .85rem 1rem; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tr:hover td { background: var(--surface-2); }
.mini-bar { width: 84px; height: 7px; border-radius: 99px; background: var(--border); overflow: hidden; display: inline-block; vertical-align: middle; margin-right: .5rem; }
.mini-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--teal)); }

.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-bottom: 1.6rem; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.3rem 1.4rem; }
.kpi b { display: block; font-size: 2rem; font-weight: 800; letter-spacing: -.03em; }
.kpi span { font-size: .82rem; color: var(--text-mute); }

/* ─────────────── Divers ─────────────── */
.toast-wrap { position: fixed; bottom: 1.6rem; left: 50%; transform: translateX(-50%); z-index: 200; display: grid; gap: .6rem; }
.toast {
  background: var(--text); color: var(--bg); padding: .85em 1.4em; border-radius: 999px; font-size: .92rem; font-weight: 600;
  box-shadow: var(--shadow-lg); animation: toastIn .3s cubic-bezier(.2,1.2,.3,1); display: flex; gap: .6em; align-items: center;
}
@keyframes toastIn { from { opacity: 0; transform: translateY(20px) scale(.9); } }
.toast.badge-toast { background: linear-gradient(135deg, #f79009, #e11d48); color: #fff; }

.empty { text-align: center; padding: 3rem 1rem; color: var(--text-mute); }
.empty .em { font-size: 3rem; display: block; margin-bottom: .6rem; opacity: .6; }

.spinner {
  width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--border); border-top-color: var(--brand);
  animation: spin .8s linear infinite; margin: 3rem auto;
}
@keyframes spin { to { transform: rotate(360deg); } }

.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 150; overflow: hidden; }
.confetti i {
  position: absolute; width: 9px; height: 15px; opacity: .9; top: -20px;
  animation: fall linear forwards;
}
@keyframes fall { to { transform: translateY(105vh) rotate(720deg); opacity: .2; } }

.footer { text-align: center; padding: 2rem 1rem 1rem; font-size: .8rem; color: var(--text-mute); }

/* ─────────────── Responsive ─────────────── */
@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; }
  .auth__brand { padding: 2.6rem 2rem; }
  .auth__features { display: none; }
  .split, .match-grid { grid-template-columns: 1fr; }
  .grid-cards.cols-2, .grid-cards.cols-3 { grid-template-columns: 1fr; }
  .card { padding: 1.6rem 1.3rem; }
  .game { padding: 1.4rem 1.2rem; }
  .hero-home { padding: 1.8rem 1.5rem; }
  .topbar__nav { display: none; }
  .xpchip .bar { display: none; }
  .cert { padding: 1.8rem 1.2rem; }
  .theme-bar .nm { width: 108px; font-size: .82rem; }
}

@media print {
  .topbar, .footer, .btn, .no-print { display: none !important; }
  body { background: #fff; }
  main { padding: 0; }
  .cert { box-shadow: none; border-color: #4f46e5; }
}
