/* Master Dictée — mobile d'abord, clair/sombre */
:root {
  color-scheme: light;
  --bg: #f6f4ef;
  --surface: #fcfcfb;
  --surface-2: #efece4;
  --border: #e2ded3;
  --text: #1b1a17;
  --text-2: #52514e;
  --muted: #7d7b74;
  --accent: #2a78d6;
  --accent-ink: #ffffff;
  --accent-soft: #e3eefb;
  --good: #1f7a3a;
  --good-soft: #e3f3e7;
  --warn: #9a5b00;
  --warn-soft: #fbf0dc;
  --bad: #b3261e;
  --bad-soft: #fbe5e3;
  /* familles de fautes (palette validée daltonisme, toutes paires) */
  --fam-mot: #2a78d6;
  --fam-grammaire: #eb6834;
  --fam-homophone: #1baf7a;
  --fam-autre: #8a8880;
  --shadow: 0 1px 2px rgb(0 0 0 / .06), 0 4px 16px rgb(0 0 0 / .06);
  --radius: 18px;
  --font: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-title: "Fredoka", "Nunito", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #121211;
    --surface: #1a1a19;
    --surface-2: #242422;
    --border: #33332f;
    --text: #f4f3ee;
    --text-2: #c3c2b7;
    --muted: #8f8d85;
    --accent: #3987e5;
    --accent-soft: #1c2a3b;
    --good: #5cc27a;
    --good-soft: #17291d;
    --warn: #e0a640;
    --warn-soft: #2e2413;
    --bad: #ef7a72;
    --bad-soft: #321a18;
    --fam-mot: #3987e5;
    --fam-grammaire: #d95926;
    --fam-homophone: #199e70;
    --fam-autre: #8f8d85;
    --shadow: 0 1px 2px rgb(0 0 0 / .4);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #121211; --surface: #1a1a19; --surface-2: #242422; --border: #33332f;
  --text: #f4f3ee; --text-2: #c3c2b7; --muted: #8f8d85;
  --accent: #3987e5; --accent-soft: #1c2a3b;
  --good: #5cc27a; --good-soft: #17291d; --warn: #e0a640; --warn-soft: #2e2413; --bad: #ef7a72; --bad-soft: #321a18;
  --fam-mot: #3987e5; --fam-grammaire: #d95926; --fam-homophone: #199e70; --fam-autre: #8f8d85;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.5 var(--font);
  min-height: 100dvh;
}
#app {
  max-width: 560px;
  margin: 0 auto;
  padding: max(16px, env(safe-area-inset-top)) 16px calc(32px + env(safe-area-inset-bottom));
}
h1, h2, h3 { font-family: var(--font-title); font-weight: 600; line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: 1.7rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 .75em; }
a { color: var(--accent); }
small, .muted { color: var(--muted); }
.text-2 { color: var(--text-2); }

/* ---------- structure */
.topbar { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; min-height: 44px; }
.topbar h1 { margin: 0; flex: 1; font-size: 1.35rem; }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 14px;
  box-shadow: var(--shadow);
}
.card.hero { background: linear-gradient(160deg, var(--accent-soft), var(--surface) 70%); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.spread { justify-content: space-between; }
.stack > * + * { margin-top: 10px; }
.center { text-align: center; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
hr { border: 0; border-top: 1px solid var(--border); margin: 16px 0; }

/* ---------- boutons */
button, .btn {
  font: inherit;
  font-weight: 700;
  border: 0;
  border-radius: 14px;
  padding: 12px 18px;
  min-height: 48px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  background: var(--surface-2);
  color: var(--text);
  transition: transform .08s ease, background .2s;
  -webkit-tap-highlight-color: transparent;
}
button:active, .btn:active { transform: scale(.97); }
button:disabled { opacity: .45; cursor: default; transform: none; }
button:focus-visible, .btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--accent); outline-offset: 2px;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-big { width: 100%; font-size: 1.2rem; min-height: 60px; border-radius: 18px; }
.btn-ghost { background: transparent; color: var(--text-2); }
.btn-icon { width: 44px; min-height: 44px; padding: 0; border-radius: 50%; background: transparent; font-size: 1.3rem; }
.btn-small { min-height: 36px; padding: 6px 12px; font-size: .9rem; border-radius: 10px; }
.btn-danger { background: var(--bad-soft); color: var(--bad); }

/* ---------- formulaires */
label { display: block; font-weight: 700; margin-bottom: 6px; }
input[type=text], input[type=password], input[type=number], textarea, select {
  width: 100%;
  font: inherit;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
}
textarea { min-height: 160px; resize: vertical; }
input[type=range] { width: 100%; accent-color: var(--accent); }
.field { margin-bottom: 14px; }
.field .hint { font-size: .85rem; color: var(--muted); margin-top: 4px; font-weight: 400; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; font-weight: 600; }
.switch input { width: 22px; height: 22px; accent-color: var(--accent); flex: none; }
.error-msg { color: var(--bad); font-weight: 700; }

/* ---------- puces / pastilles */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 12px; border-radius: 999px;
  background: var(--surface-2); color: var(--text-2);
  font-size: .9rem; font-weight: 700;
}
.chip.good { background: var(--good-soft); color: var(--good); }
.chip.warn { background: var(--warn-soft); color: var(--warn); }
.chip.bad { background: var(--bad-soft); color: var(--bad); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }

.stat { background: var(--surface-2); border-radius: 14px; padding: 12px; text-align: center; }
.stat b { display: block; font-family: var(--font-title); font-size: 1.6rem; line-height: 1.1; }
.stat span { font-size: .8rem; color: var(--text-2); font-weight: 600; }

.notice { background: var(--warn-soft); color: var(--warn); border-radius: 12px; padding: 10px 14px; font-size: .92rem; font-weight: 600; margin-bottom: 14px; }
.notice.info { background: var(--accent-soft); color: var(--text-2); }

.list-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); text-decoration: none; color: inherit; }
.list-item:last-child { border-bottom: 0; }

/* ---------- lecteur de dictée */
.player-orb {
  width: 180px; height: 180px; margin: 10px auto 18px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent-soft);
  position: relative;
  font-size: 3.6rem;
}
.player-orb::before, .player-orb::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 3px solid var(--accent); opacity: 0;
}
.player-orb.speaking::before { animation: ripple 1.6s ease-out infinite; }
.player-orb.speaking::after { animation: ripple 1.6s ease-out .8s infinite; }
@keyframes ripple { from { transform: scale(.85); opacity: .7; } to { transform: scale(1.25); opacity: 0; } }
.player-status { text-align: center; font-family: var(--font-title); font-size: 1.3rem; min-height: 1.6em; }
.progress { height: 10px; background: var(--surface-2); border-radius: 99px; overflow: hidden; margin: 14px 0 6px; }
.progress > div { height: 100%; background: var(--accent); border-radius: 99px; transition: width .3s; }
.player-controls { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.player-controls .btn-big { grid-column: 1 / -1; min-height: 76px; font-size: 1.35rem; }
.countdown { height: 6px; background: var(--surface-2); border-radius: 99px; overflow: hidden; margin-top: 10px; }
.countdown > div { height: 100%; background: var(--good); width: 0; }

/* ---------- photos */
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; margin: 12px 0; }
.photo { position: relative; border-radius: 12px; overflow: hidden; aspect-ratio: 3/4; background: var(--surface-2); }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo button { position: absolute; top: 6px; right: 6px; min-height: 32px; width: 32px; padding: 0; border-radius: 50%; background: rgb(0 0 0 / .6); color: #fff; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- correction */
.score-hero { text-align: center; padding: 8px 0 4px; }
.score-hero .score { font-family: var(--font-title); font-size: 4rem; line-height: 1; font-weight: 600; }
.score-hero .score small { font-size: 1.6rem; color: var(--muted); }
.dictee-text { font-size: 1.12rem; line-height: 2.1; }
.err {
  --c: var(--fam-autre);
  border-radius: 6px;
  padding: 1px 3px;
  background: color-mix(in srgb, var(--c) 18%, transparent);
  border-bottom: 3px solid var(--c);
  cursor: pointer;
  font-weight: 700;
}
.err.selected { background: color-mix(in srgb, var(--c) 38%, transparent); }
.err.missing { border-bottom-style: dashed; }
.fam-mot { --c: var(--fam-mot); }
.fam-grammaire { --c: var(--fam-grammaire); }
.fam-homophone { --c: var(--fam-homophone); }
.fam-autre, .fam-oubli, .fam-ponct { --c: var(--fam-autre); }
.err.fam-ponct { border-bottom-style: dotted; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 14px; font-size: .88rem; color: var(--text-2); font-weight: 600; margin: 4px 0 12px; }
.legend i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; background: var(--c); vertical-align: -2px; margin-right: 5px; }
.err-cat { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--text-2); }
.detail-box { background: var(--surface-2); border-left: 5px solid var(--c, var(--fam-autre)); border-radius: 12px; padding: 10px 12px 12px 14px; margin: -6px 0 14px; }
.detail-head { display: flex; align-items: center; gap: 4px; margin-bottom: 4px; }
.detail-head .err-cat { flex: 1; min-width: 0; }
.detail-words { display: grid; grid-template-columns: auto 1fr; gap: 2px 8px; margin: 0 0 6px; font-size: 1.05rem; align-items: baseline; }
.detail-words dt { color: var(--text-2); font-size: .92rem; font-weight: 600; }
.detail-words dt:only-of-type, .detail-words dt + dt { grid-column: 1 / -1; }
.detail-words dd { margin: 0; }
.detail-words .wrong { color: var(--text-2); text-decoration: line-through; text-decoration-thickness: 2px; }
.detail-words .right { font-weight: 800; }
.touch-hint { margin: -4px 0 10px; font-size: .9rem; }
.dismissed-list { margin-top: 6px; font-size: .95rem; }
.dismissed-list ul { list-style: none; margin: 4px 0 0; padding: 0; }
.dismissed-list li { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--border); }
.dismissed-list li:last-child { border-bottom: 0; }
details summary { cursor: pointer; font-weight: 700; padding: 6px 0; }
.transcription { white-space: pre-wrap; font-size: .95rem; color: var(--text-2); }

/* ---------- quiz verbes */
.verb-q { display: grid; grid-template-columns: 1fr; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.verb-q:last-child { border-bottom: 0; }
.verb-q .prompt { font-weight: 600; }
.verb-q .prompt em { color: var(--muted); font-style: normal; font-weight: 600; font-size: .9rem; }
.verb-line { display: flex; align-items: center; gap: 8px; }
.verb-line .pronom { font-weight: 800; min-width: 3ch; }
.ready-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: var(--surface); border-top: 1.5px solid var(--border); box-shadow: 0 -6px 20px rgba(0, 0, 0, .12);
}
.ready-bar span { font-weight: 800; }
.ready-bar small { display: block; font-weight: 400; color: var(--text-2); font-size: .85rem; }
.ready-bar .btn { flex-shrink: 0; }
.ready-spacer { height: 96px; }
.btn-count { color: inherit; opacity: .85; font-weight: 600; }
.verdict { font-weight: 800; }
.verdict.ok { color: var(--good); }
.verdict.faux { color: var(--bad); }
.verdict.accent { color: var(--warn); }

/* ---------- graphiques */
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid line { stroke: var(--border); stroke-width: 1; }
.chart .axis text { fill: var(--muted); font-size: 12px; font-family: var(--font); }
.chart .line { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .dot { fill: var(--accent); stroke: var(--surface); stroke-width: 2; }
.chart .bar { fill: var(--accent); }
.chart .bar-label { fill: var(--text-2); font-size: 13px; font-family: var(--font); font-weight: 700; }
.chart .value-label { fill: var(--text); font-size: 13px; font-family: var(--font); font-weight: 800; }
.chart .crosshair { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 3 3; }
.chart-wrap { position: relative; }
.tooltip {
  position: absolute; pointer-events: none;
  background: var(--text); color: var(--surface);
  padding: 6px 10px; border-radius: 8px; font-size: .82rem; font-weight: 700;
  transform: translate(-50%, calc(-100% - 10px)); white-space: nowrap; z-index: 2;
}

/* ---------- divers */
.spinner { width: 42px; height: 42px; border: 4px solid var(--surface-2); border-top-color: var(--accent); border-radius: 50%; animation: spin 1s linear infinite; margin: 10px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: var(--text); color: var(--surface); padding: 10px 18px; border-radius: 12px; font-weight: 700; z-index: 10; max-width: calc(100% - 32px); }
.nav { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.nav a { flex-direction: column; gap: 2px; font-size: .9rem; min-height: 70px; background: var(--surface); border: 1px solid var(--border); }
.nav a span { font-size: 1.5rem; }
.empty { text-align: center; color: var(--muted); padding: 10px 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- code PIN */
.pin-dots { display: flex; justify-content: center; gap: 18px; margin: 18px 0 6px; }
.pin-dots span { width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid var(--accent); transition: background .15s; }
.pin-dots span.on { background: var(--accent); }
.pin-msg { min-height: 1.5em; color: var(--bad); font-weight: 700; margin: 4px 0 10px; }
.pin-pad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; max-width: 270px; margin: 0 auto; }
.pin-pad button {
  aspect-ratio: 1; min-height: 64px; border-radius: 50%; font-size: 1.7rem; font-family: var(--font-title);
  background: var(--surface); border: 1.5px solid var(--border); box-shadow: var(--shadow); padding: 0;
}
.pin-pad button:active { background: var(--accent-soft); }
.pin-pad button[data-k="del"] { background: transparent; box-shadow: none; border-color: transparent; font-size: 1.5rem; }
.remember { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; margin-top: 10px; color: var(--text-2); font-size: .95rem; }
.remember input { width: 22px; height: 22px; accent-color: var(--accent); }
.shake { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }

/* ---------- génération manuelle */
.stepper { display: flex; gap: 8px; align-items: center; }
.stepper .btn { min-width: 48px; min-height: 48px; padding: 0; font-size: 1.4rem; font-weight: 800; }
.stepper input { width: 5em; text-align: center; font-weight: 700; }
.gen-box { background: var(--surface-2); border-radius: 14px; padding: 12px 14px; margin-bottom: 12px; }
.gen-box .hint { font-size: .85rem; color: var(--muted); margin-top: 6px; }
.chip-btn { min-height: 40px; padding: 6px 14px; border-radius: 999px; background: var(--surface); border: 1.5px solid var(--border); font-size: .95rem; }
.chip-btn.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

/* ---------- dictée du jour (espace parent) */
.list-item.is-active { background: var(--good-soft); margin: 0 -10px; padding: 10px; border-radius: 12px; }
.list-item.is-active .chip { margin-bottom: 4px; }

/* ---------- conjugaison libre / boutons audio */
.verbs-card { text-decoration: none; color: inherit; }
.verbs-card small { color: var(--text-2); }
.is-playing { background: var(--accent-soft); }

/* ---------- astuces pour retenir */
.err-why { margin-top: 2px; }
.err-tip { margin-top: 6px; padding: 8px 10px; border-radius: 10px; background: var(--accent-soft); font-size: .95rem; }
.remember-card { background: var(--accent-soft); border-color: transparent; }
.remember-card ul { margin: 0; padding-left: 1.2em; font-weight: 700; }
.remember-card li + li { margin-top: 4px; }

/* ---------- galerie / anciennes dictées */
.photo-choices { display: grid; gap: 10px; }
.evolution { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-family: var(--font-title); font-size: 1.25rem; }
.evo-score { text-decoration: none; color: var(--text); background: var(--surface-2); border-radius: 10px; padding: 2px 10px; }
.evo-score.ok { background: var(--good-soft); color: var(--good); }
.evo-arrow { color: var(--muted); }
.hist-list { margin-top: 8px; }
.hist-row { display: block; padding: 4px 0; color: inherit; text-decoration: none; font-size: .95rem; }
details.hist summary { font-size: .88rem; padding: 4px 0; }

/* ---------- accueil : dictées refaisables */
.done-row { gap: 8px; }
.done-link { flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.done-scores { flex: none; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.verbs-chip { padding: 2px 9px; font-size: .78rem; white-space: nowrap; }
@media (max-width: 359px) {
  .done-row { flex-wrap: wrap; }
  .done-link { flex-basis: 100%; }
  .done-scores { flex-direction: row; }
  .redo-btn { margin-left: auto; }
}
.redo-btn { flex: none; background: var(--accent-soft); color: var(--accent); }

/* ---------- texte écrit + corrections (sans clic) */
.dictee-text.written .err { font-weight: 600; }
.dictee-text.written .err.extra { font-style: italic; }
.dictee-text.written .err.missing { padding: 0 6px; }
.fix-list { list-style: none; margin: 8px 0 14px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 8px; }
.fix {
  display: inline-flex; align-items: baseline; gap: 4px;
  padding: 4px 10px; border-radius: 10px; cursor: pointer;
  background: color-mix(in srgb, var(--c) 12%, var(--surface));
  border-left: 4px solid var(--c);
  font-size: .98rem; line-height: 1.35;
}
.fix.selected { background: color-mix(in srgb, var(--c) 28%, var(--surface)); }
.fix-wrong { color: var(--text-2); text-decoration: line-through; text-decoration-thickness: 1px; text-decoration-color: color-mix(in srgb, var(--text-2) 60%, transparent); }
.fix-right { color: var(--text); }
.fix-note { color: var(--muted); font-size: .85rem; }

/* ---------- fiches d'exercices (espace parent) */
.card-link { display: block; text-decoration: none; color: inherit; border: 1.5px solid var(--accent-soft); }
.card-link h3 { margin-top: 0; }
.notion-row small { line-height: 1.5; }
.notion-row .chip, .sheet-item .chip { white-space: nowrap; flex: none; }
.notion-words { margin: 12px 0 0; }
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px 12px; margin-top: 12px; }
.theme { display: flex; align-items: center; gap: 8px; min-height: 40px; }
.theme input { width: 20px; height: 20px; flex: none; }
.sheet-item { padding: 12px 0; border-bottom: 1px solid var(--border); }
.sheet-item:last-child { border-bottom: 0; }
.sheet-item > .muted { font-size: .92rem; margin-top: 2px; }
.sheet-actions { flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.sheet-done { margin-top: 8px; }
.spinner-inline { display: inline-block; width: .9em; height: .9em; border-width: 2px; vertical-align: -1px; margin: 0; }
.answer-list { margin: 0; padding-left: 1.6em; }
.answer-list li { padding: 10px 0; border-bottom: 1px solid var(--border); }
.answer-list li:last-child { border-bottom: 0; }
.ans-q { color: var(--text-2); }
.ans-r { margin-top: 4px; font-size: 1.05rem; }
.ans-full, .ans-rule { font-size: .9rem; margin-top: 2px; }
.ans-why { margin-top: 4px; }

/* ---------- révisions vidéo (Maître Lucas) */
.video-card h3 { margin-bottom: .2em; }
.video-intro { font-size: .92rem; margin-bottom: 10px; }
.video-list { list-style: none; margin: 0; padding: 0; counter-reset: video; }
ol.video-list .video-item { counter-increment: video; }
ol.video-list .video-title b::before { content: counter(video) ". "; color: var(--accent); }
.video-item { padding: 12px 0; border-bottom: 1px solid var(--border); }
.video-item:last-child { border-bottom: 0; padding-bottom: 0; }
.video-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.video-title { min-width: 0; }
.video-title small { display: block; line-height: 1.4; }
.video-head .chip { flex: none; white-space: nowrap; }
.video-reason { margin: 6px 0 8px; font-size: .95rem; color: var(--text-2); }
.video-progress { margin: 0 0 10px; height: 6px; }
.video-player { margin-top: 10px; }
.yt-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 12px; overflow: hidden; }
.yt-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 4px; }
.video-fallback { margin-top: 8px; background: var(--surface-2); border-radius: 12px; padding: 10px 12px; }
.video-fallback p { margin-bottom: 8px; font-size: .95rem; }
.revision-card { display: flex; align-items: center; justify-content: space-between; gap: 10px; text-decoration: none; color: inherit; background: var(--accent-soft); border-color: transparent; }
.revision-card small { color: var(--text-2); }
.revision-card .btn { flex: none; }
.revision-card.is-done { background: var(--good-soft); padding: 12px 18px; }
.reco-item { padding: 12px 0; border-bottom: 1px solid var(--border); }
.reco-item:last-child { border-bottom: 0; }
.reco-item.is-removed { opacity: .55; }
.reco-item .video-reason { margin-bottom: 4px; }
.cat-group { margin: 14px 0 4px; font-size: .95rem; }
.cat-item { padding: 4px 0; }
.cat-item small { display: block; }

/* ---------- suivi pédagogique (espace parent) */
.progress-card h3 { margin-bottom: 8px; }
.recent-item { display: flex; gap: 10px; padding: 6px 0; line-height: 1.35; }
.recent-icon { flex: none; width: 1.6em; text-align: center; }
.recent-item small { color: var(--text-2); }
.prio-title { margin: 12px 0 4px; font-size: 1rem; }
.prio-list { margin: 0; padding-left: 1.4em; }
.prio-list li { padding: 3px 0; }
.prio-list .btn { min-height: 32px; padding: 2px 8px; }
.state-travailler { background: var(--bad-soft); color: var(--bad); }
.state-progres { background: var(--warn-soft); color: var(--warn); }
.state-maitrise { background: var(--good-soft); color: var(--good); }
.skill-item { padding: 10px 0; border-bottom: 1px solid var(--border); }
.skill-item:last-child { border-bottom: 0; }
.skill-item.is-old { opacity: .6; }
.skill-item .chip { flex: none; white-space: nowrap; font-size: .82rem; }
.timeline { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0 2px; }
.tl { font-size: .8rem; font-weight: 700; padding: 1px 7px; border-radius: 8px; text-decoration: none; }
.tl.bad { background: var(--bad-soft); color: var(--bad); }
.tl.good { background: var(--good-soft); color: var(--good); }
.word-chip { display: inline-block; padding: 1px 8px; margin: 2px 0; border-radius: 8px; background: var(--warn-soft); color: var(--warn); font-weight: 700; font-size: .9rem; }
.word-chip.good { background: var(--good-soft); color: var(--good); }
.retake { padding: 8px 0; border-bottom: 1px solid var(--border); }
.retake:last-child { border-bottom: 0; }
.good-text { color: var(--good); }
.fb-list { margin: 6px 0 0; padding-left: 1.2em; }
.fb-row { gap: 6px; margin-top: 6px; }
.fb { background: transparent; border: 1.5px solid var(--border); }
.fb.on { background: var(--accent-soft); border-color: var(--accent); }
.journal-day h3 { text-transform: capitalize; margin-bottom: 6px; }
.journal-item { display: flex; gap: 8px; padding: 4px 0; font-size: .95rem; line-height: 1.4; }
.journal-item > span:first-child { flex: none; width: 1.5em; text-align: center; }
.journal-item a { color: inherit; }
.journal-item.type-etat { font-weight: 700; }
.cheer { margin: 4px 0 0; font-weight: 800; color: var(--good); }
