/* Memorisierung verstehen — Stylesheet
   Tokens und Bausteine aus dem Design-System andreasvongunten.com
   (projects/andreasvongunten-theme/assets/css/theme.css + editorial.css, Juli 2026).
   Immer über semantische Rollen arbeiten (--accent, --text, --link …). */

:root {
  /* Primitive */
  --color-paper: #F5F0E6; --color-paper-warm: #FBF7ED;
  --color-ink: #221F19; --color-ink-soft: #3A3630;
  --color-green: #365A41; --color-green-deep: #26402E; --color-green-bright: #3F6B47;
  --color-green-light: #7FA98A; --color-green-wash: #E4EDE6;
  --color-amber: #9A6B25; --color-amber-text: #7A5416; --color-amber-light: #D9A94E; --color-amber-wash: #F3E7D0;
  --color-red: #A83A2F; --color-red-wash: #F3DAD6;
  --n0: #F5F0E6; --n100: #EAE3D4; --n200: #D9D0BC; --n300: #B3A992; --n400: #857B69; --n500: #4E4840; --n600: #221F19;

  /* Semantic */
  --bg: var(--color-paper); --bg-elevated: var(--color-paper-warm);
  --surface: var(--n100); --surface-strong: var(--n200);
  --text: var(--color-ink); --text-soft: var(--n500); --text-muted: var(--n400); --text-inverse: var(--color-paper);
  --accent: var(--color-green); --accent-hover: var(--color-green-deep);
  --accent-2: var(--color-amber); --accent-2-text: var(--color-amber-text);
  --link: var(--color-green); --link-hover: var(--color-green-deep);
  --border: var(--n200); --border-strong: var(--n300);
  --ok: var(--color-green-bright); --warn: var(--color-amber); --err: var(--color-red);

  /* Type */
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Spectral", Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --fs-read: clamp(17px, 15.8px + 0.33vw, 20px);
  --fs-lede: clamp(19px, 17.6px + 0.44vw, 22px);

  /* System */
  --radius-sm: 6px; --radius-md: 12px; --radius-full: 999px;
  --shadow-sm: 0 1px 2px 0 #221F1914; --shadow-md: 0 4px 12px -2px #221F191F; --shadow-lg: 0 12px 28px -6px #221F1926;
  --shadow-focus: 0 0 0 3px #365A4133;
  --container: 720px; --container-wide: 1080px;
  --ease: cubic-bezier(.22,.61,.36,1);
}

*, *::before, *::after { box-sizing: border-box; }
::selection { background: var(--color-amber-wash); color: var(--color-ink); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font-body); font-size: var(--fs-read); line-height: 1.7;
  color: var(--text); background: var(--bg);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; font-optical-sizing: auto;
}
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 500; letter-spacing: -0.01em; line-height: 1.2; }
h1 { font-weight: 600; font-size: clamp(34px, 5vw, 48px); line-height: 1.08; letter-spacing: -.02em; margin: 0 0 20px; }
h2 { font-size: clamp(26px, 3.4vw, 34px); line-height: 1.3; margin: 56px 0 16px; }
h3 { font-size: clamp(21px, 2.6vw, 26px); margin: 36px 0 12px; }
p { margin: 0 0 22px; }
a { color: var(--link); text-decoration: underline; text-decoration-thickness: 1px; text-decoration-color: rgba(54,90,65,.4); text-underline-offset: .18em; transition: text-decoration-color .16s var(--ease), color .16s var(--ease); }
a:hover { color: var(--link-hover); text-decoration-color: var(--accent); }
strong { font-weight: 500; color: var(--text); }
em { font-style: italic; }
sup { font-size: .7em; line-height: 0; }
img { max-width: 100%; height: auto; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
#app:focus { outline: none; }

.skip-link { position: absolute; left: -9999px; top: 0; z-index: 1000; background: var(--accent); color: var(--text-inverse); padding: 10px 16px; border-radius: 0 0 var(--radius-sm) 0; }
.skip-link:focus { left: 0; }

/* ─── Header ─── */
.site-header {
  position: sticky; top: 0; z-index: 200;
  background: rgba(245,240,230,.92); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.site-header-inner { max-width: 1240px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); min-width: 0; }
.brand:hover { color: var(--text); }
.brand-icon { flex: 0 0 auto; display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; }
.brand-title { font-family: var(--font-display); font-weight: 600; font-size: 21px; letter-spacing: -.01em; white-space: nowrap; }
.brand-sub { font-size: 14px; color: var(--text-muted); white-space: nowrap; }
.brand-com { color: var(--accent-2-text); }

.progress-nav ol { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.progress-nav a {
  min-width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); border: 1px solid var(--border); color: var(--text-soft); text-decoration: none;
  font-family: var(--font-display); font-weight: 500; font-size: 15px; background: transparent; position: relative;
}
.progress-nav a:hover { background: var(--surface); color: var(--text); }
.progress-nav a.is-done { border-color: var(--color-green-light); color: var(--accent); }
.progress-nav a.is-done::after { content: ""; position: absolute; right: 3px; top: 3px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.progress-nav a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--text-inverse); font-weight: 600; }
.progress-nav a[aria-current="page"]::after { background: var(--color-amber-light); }

@media (max-width: 760px) {
  .site-header-inner { flex-direction: column; align-items: stretch; gap: 8px; padding: 10px 16px; }
  .brand-icon { width: 36px; height: 36px; }
  .brand-title { font-size: 18px; }
  .brand-sub { display: none; }
  .progress-nav ol { justify-content: space-between; gap: 4px; flex-wrap: nowrap; }
  .progress-nav li { flex: 1; }
  .progress-nav a { width: 100%; min-width: 0; height: 32px; font-size: 14px; }
}

/* ─── Seitenrahmen ─── */
.shell { max-width: var(--container); margin: 0 auto; padding: 48px 24px 72px; }
.shell-wide { max-width: var(--container-wide); }
@media (max-width: 600px) { .shell { padding: 32px 18px 56px; } }

.kicker { font-family: var(--font-display); color: var(--accent-2); font-size: 14px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; margin: 0 0 14px; }
.lede { font-size: var(--fs-lede); line-height: 1.55; color: var(--text-soft); font-style: italic; margin: 0 0 32px; }
.muted { color: var(--text-muted); }
.small { font-size: 15px; line-height: 1.55; }

.hero-img, .lesson-img { display: block; width: 100%; aspect-ratio: 21/9; object-fit: cover; border-radius: var(--radius-md); margin: 8px 0 36px; }
figure.illu { margin: 40px 0; }
figure.illu img { display: block; width: 100%; border-radius: var(--radius-md); background: var(--surface); }
figure.illu figcaption { font-style: italic; font-size: 14px; color: var(--text-muted); margin-top: 8px; }

/* Listen wie in der Artikel-Prosa */
.prose ul, .prose ol { padding-left: 22px; margin: 0 0 24px; }
.prose ul li { list-style: none; position: relative; margin-bottom: 8px; }
.prose ul li::before { content: "•"; color: var(--accent); position: absolute; left: -18px; top: 0; font-size: 20px; line-height: 1.35; }
.prose ol { list-style: none; counter-reset: step; padding-left: 36px; }
.prose ol li { counter-increment: step; position: relative; margin-bottom: 8px; }
.prose ol li::before { content: counter(step) "."; font-family: var(--font-display); font-weight: 500; color: var(--accent); position: absolute; left: -32px; top: 0; width: 24px; text-align: right; }

/* ─── Kapitelkopf (Editorial 4.1) ─── */
.kapitelkopf { margin: 64px 0 0; }
.kapitel-zeile { display: flex; align-items: center; gap: 12px; }
.kapitel-ziffer { font-family: var(--font-display); font-weight: 600; font-size: 16px; line-height: 1; color: var(--accent); }
.kapitel-label { font-weight: 500; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-soft); }
.kapitel-linie { flex: 1; height: 1px; background: var(--border); }
.kapitelkopf h2 { margin: 12px 0 16px; }

/* ─── Boxen ─── */
.notiz { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 22px 24px; margin: 32px 0; font-size: 16px; line-height: 1.6; }
.notiz p { margin: 0 0 12px; } .notiz p:last-child { margin-bottom: 0; }
.notiz-tag { font-weight: 500; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-2-text); margin: 0 0 10px; display: block; }
.notiz ul { margin: 0 0 12px; padding-left: 20px; } .notiz li { margin-bottom: 6px; }
.notiz-warn { background: var(--color-amber-wash); border-color: #E6D2AC; }
.notiz-limit { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--border-strong); color: var(--text-soft); }

.ausblick { background: var(--accent); color: rgba(245,240,230,.94); border-radius: var(--radius-md); padding: 28px 32px; margin: 40px 0; font-size: 18px; line-height: 1.6; }
.ausblick .notiz-tag { color: var(--color-amber-light); }
.ausblick p { margin: 0 0 12px; } .ausblick p:last-child { margin-bottom: 0; }
.ausblick strong { color: #fff; }
.ausblick a { color: #CFE3D5; text-decoration-color: rgba(207,227,213,.5); }

blockquote.zitat { border-left: 3px solid var(--accent); margin: 32px 0; padding: 4px 0 4px 24px; font-style: italic; font-size: clamp(19px, 2.2vw, 23px); line-height: 1.45; color: var(--text); }
blockquote.zitat cite { display: block; margin-top: 10px; font-style: normal; font-size: 15px; color: var(--text-muted); }

details.neugier { border: 1px solid var(--border); border-radius: var(--radius-md); margin: 28px 0; background: var(--bg-elevated); }
details.neugier summary { cursor: pointer; padding: 14px 20px; font-family: var(--font-display); font-weight: 500; font-size: 18px; color: var(--accent); list-style: none; }
details.neugier summary::-webkit-details-marker { display: none; }
details.neugier summary::before { content: "+"; display: inline-block; width: 22px; font-weight: 600; }
details.neugier[open] summary::before { content: "−"; }
details.neugier .neugier-body { padding: 0 20px 18px; font-size: 16px; line-height: 1.6; }
details.neugier .neugier-body p:last-child { margin-bottom: 0; }

/* Quellenhinweis im Fliesstext */
.ref { font-size: .72em; vertical-align: super; line-height: 0; margin-left: 1px; text-decoration: none; font-family: var(--font-display); font-weight: 600; }
.quelle { font-size: 14.5px; color: var(--text-muted); line-height: 1.5; margin: -8px 0 24px; }

/* Belegstatus-Pill */
.pill { display: inline-block; font-weight: 500; font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; border: 1px solid currentColor; border-radius: var(--radius-full); padding: 2px 10px; line-height: 1.5; white-space: nowrap; }
.pill-green { color: var(--accent); } .pill-amber { color: var(--accent-2-text); } .pill-red { color: var(--err); } .pill-muted { color: var(--text-muted); }

/* Tabellen */
.table-wrap { overflow-x: auto; margin: 24px 0 32px; border: 1px solid var(--border); border-radius: var(--radius-md); background: var(--bg-elevated); }
table { border-collapse: collapse; width: 100%; font-size: 16px; line-height: 1.5; }
th, td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
th { font-family: var(--font-display); font-weight: 600; font-size: 14px; letter-spacing: .04em; color: var(--text-soft); background: var(--surface); }
tr:last-child td { border-bottom: 0; }

/* ─── Buttons ─── */
.btn { font-family: var(--font-display); font-weight: 600; font-size: 16px; line-height: 1.2; padding: 11px 22px; min-height: 44px; border-radius: var(--radius-sm); border: 2px solid var(--accent); background: var(--accent); color: var(--text-inverse); cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 8px; transition: background .16s var(--ease), border-color .16s var(--ease), color .16s var(--ease); }
.btn:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--text-inverse); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-outline { background: transparent; color: var(--text); border-color: var(--text); }
.btn-outline:hover { background: transparent; border-color: var(--accent); color: var(--accent); }
.btn-ghost { background: transparent; color: var(--text-soft); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-small { font-size: 14.5px; padding: 7px 14px; min-height: 36px; }

/* Segment-Umschalter (Fassungs-Umschalter des DS) */
.toggle { display: inline-flex; gap: 4px; background: var(--surface); border-radius: var(--radius-full); padding: 4px; flex-wrap: wrap; }
.toggle button { font-family: var(--font-display); font-weight: 600; font-size: 15px; line-height: 1.2; padding: 8px 18px; min-height: 36px; border: 0; border-radius: var(--radius-full); background: transparent; color: var(--text-soft); cursor: pointer; transition: background .2s var(--ease), color .2s var(--ease); }
.toggle button[aria-pressed="true"] { background: var(--accent); color: var(--text-inverse); }

/* ─── Startseite ─── */
.start-hero { padding-top: 8px; }
.start-hero h1 { font-size: clamp(38px, 6vw, 60px); line-height: 1.02; letter-spacing: -.025em; }
.mythen { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 32px 0; }
.mythos { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 22px 22px 18px; box-shadow: var(--shadow-sm); }
.mythos .notiz-tag { margin-bottom: 8px; }
.mythos p { font-family: var(--font-display); font-style: italic; font-size: 20px; line-height: 1.35; margin: 0 0 10px; }
.mythos small { font-size: 15px; color: var(--text-soft); display: block; line-height: 1.5; }
@media (max-width: 640px) { .mythen { grid-template-columns: 1fr; } }

.lesson-list { list-style: none; padding: 0; margin: 24px 0 40px; display: grid; gap: 14px; }
.lesson-card { display: flex; gap: 18px; align-items: flex-start; padding: 18px 20px; text-decoration: none; color: var(--text); background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-md); transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.lesson-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); color: var(--text); }
.lc-num { flex: 0 0 auto; width: 40px; height: 40px; border-radius: var(--radius-full); background: var(--surface); border: 1px solid var(--border); display: inline-flex; align-items: center; justify-content: center; font-family: var(--font-display); font-weight: 600; color: var(--accent); }
.lesson-card.is-done .lc-num { background: var(--accent); color: var(--text-inverse); border-color: var(--accent); }
.lc-title { font-family: var(--font-display); font-weight: 600; font-size: 20px; line-height: 1.25; display: block; margin: 2px 0 4px; }
.lc-desc { font-size: 15.5px; color: var(--text-soft); line-height: 1.5; display: block; }
.lc-meta { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-2-text); display: block; margin-top: 6px; }

/* ─── Lektionen ─── */
.lesson-eyebrow { font-family: var(--font-display); color: var(--accent-2); font-size: 14px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; margin: 0 0 14px; }
.lesson-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 56px 0 0; padding-top: 28px; border-top: 1px solid var(--border); }
.lesson-nav a { display: flex; flex-direction: column; gap: 2px; padding: 14px 18px; text-decoration: none; border: 1px solid var(--border); border-radius: var(--radius-md); color: var(--text); background: var(--bg-elevated); }
.lesson-nav a:hover { box-shadow: var(--shadow-md); color: var(--text); }
.lesson-nav .ln-next { text-align: right; grid-column: 2; }
.ln-dir { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); font-weight: 500; }
.ln-title { font-family: var(--font-display); font-weight: 500; font-size: 17px; line-height: 1.3; }
@media (max-width: 600px) { .lesson-nav { grid-template-columns: 1fr; } .lesson-nav .ln-next { grid-column: 1; } }

/* ─── Widgets ─── */
.widget { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-md); padding: 24px 24px 22px; margin: 40px 0; font-size: 16px; line-height: 1.55; }
.widget-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 4px; }
.widget-kicker { font-weight: 500; font-size: 12.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-2-text); }
.widget-title { font-family: var(--font-display); font-weight: 600; font-size: 22px; margin: 2px 0 6px; line-height: 1.25; }
.widget-task { color: var(--text-soft); margin: 0 0 18px; font-size: 15.5px; }
.widget p { margin: 0 0 12px; }
.widget-note { font-size: 14px; color: var(--text-muted); margin: 14px 0 0; line-height: 1.5; }
@media (max-width: 600px) { .widget { padding: 18px 16px; margin: 32px -6px; } }

.control { display: grid; gap: 4px; margin: 0 0 16px; }
.control label { font-weight: 500; font-size: 15px; color: var(--text); display: flex; justify-content: space-between; gap: 12px; }
.control output, .control .val { font-family: var(--font-display); font-weight: 600; color: var(--accent); font-variant-numeric: tabular-nums; }
.control .hint { font-size: 13.5px; color: var(--text-muted); }
input[type="range"] { width: 100%; accent-color: var(--accent); height: 28px; margin: 0; }
select { min-height: 40px; padding: 6px 10px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--color-paper); color: var(--text); font-family: var(--font-body); font-size: 15px; max-width: 100%; }

.presets { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 18px; }
.chip { font-family: var(--font-display); font-size: 14.5px; padding: 6px 14px; border-radius: var(--radius-full); border: 1px solid var(--border); background: var(--surface); color: var(--text-soft); cursor: pointer; transition: background .16s, color .16s; }
.chip:hover, .chip[aria-pressed="true"] { background: var(--accent); color: var(--text-inverse); border-color: var(--accent); }

.big-result { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin: 4px 0 10px; }
.big-num { font-family: var(--font-display); font-weight: 600; font-size: clamp(36px, 6vw, 52px); line-height: 1; color: var(--accent); font-variant-numeric: tabular-nums; }
.big-label { color: var(--text-soft); font-size: 15.5px; max-width: 34ch; }
.meter { height: 14px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-full); overflow: hidden; margin: 8px 0 6px; }
.meter > span { display: block; height: 100%; background: var(--accent); border-radius: var(--radius-full); transition: width .25s var(--ease); }
.verdict { font-style: italic; color: var(--text-soft); min-height: 1.6em; }

/* Kaskade */
.kaskade-text { font-family: var(--font-display); font-size: 20px; line-height: 1.7; background: var(--color-paper); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px 18px; min-height: 120px; }
.kaskade-text span { transition: color .2s; }
.kaskade-text .w-ok { color: var(--text); }
.kaskade-text .w-dev { color: var(--color-red); text-decoration: underline wavy; text-decoration-color: rgba(168,58,47,.5); text-underline-offset: 4px; }
.kaskade-text .w-drift { color: var(--accent-2-text); font-style: italic; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 14px; color: var(--text-muted); margin: 10px 0 0; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }

/* SVG-Charts */
.chart { width: 100%; height: auto; display: block; background: var(--color-paper); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.chart text { font-family: var(--font-body); font-size: 12px; fill: var(--text-muted); }
.chart .lbl-strong { fill: var(--text); font-weight: 500; }

/* Leiter / Balken */
.bars { display: grid; gap: 12px; margin: 8px 0; }
.bar-row { display: grid; grid-template-columns: minmax(120px, 190px) 1fr; gap: 12px; align-items: center; }
.bar-name { font-family: var(--font-display); font-weight: 500; font-size: 15.5px; line-height: 1.25; }
.bar-name small { display: block; font-family: var(--font-body); font-weight: 400; font-size: 13px; color: var(--text-muted); }
.bar-track { position: relative; height: 30px; background: var(--surface); border-radius: var(--radius-sm); overflow: hidden; }
.bar-fill { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); border-radius: var(--radius-sm); transition: width .5s var(--ease); }
.bar-fill.amber { background: var(--accent-2); }
.bar-fill.muted { background: var(--n400); }
.bar-val { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); font-family: var(--font-display); font-weight: 600; font-size: 14.5px; color: var(--text-inverse); white-space: nowrap; }
.bar-val.out { color: var(--text); }
@media (max-width: 560px) { .bar-row { grid-template-columns: 1fr; gap: 4px; } }

/* Karten-Raster (Gerichte, Begriffe) */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.card-btn { text-align: left; font: inherit; color: var(--text); background: var(--color-paper); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 14px 16px; cursor: pointer; transition: box-shadow .16s, border-color .16s, transform .16s; display: flex; flex-direction: column; gap: 6px; }
.card-btn:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.card-btn[aria-expanded="true"], .card-btn[aria-pressed="true"] { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent) inset; }
.card-title { font-family: var(--font-display); font-weight: 600; font-size: 17px; line-height: 1.25; }
.card-sub { font-size: 14px; color: var(--text-muted); line-height: 1.4; }
.detail { margin-top: 16px; background: var(--color-paper); border: 1px solid var(--border); border-left: 3px solid var(--accent); border-radius: var(--radius-sm); padding: 16px 18px; }
.detail h4 { font-family: var(--font-display); font-weight: 600; font-size: 19px; margin: 0 0 8px; }
.detail dl { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 14px; margin: 0; }
.detail dd { overflow-wrap: anywhere; }
.detail .pill { white-space: normal; }
.detail dt { font-weight: 500; color: var(--text-soft); font-size: 14.5px; }
.detail dd { margin: 0; font-size: 15.5px; }
@media (max-width: 520px) { .detail dl { grid-template-columns: 1fr; } .detail dt { margin-top: 6px; } }

/* Fähigkeit vs. Neigung */
.fn-panel { display: grid; grid-template-columns: 120px 1fr; gap: 18px; align-items: center; margin-top: 18px; }
.fn-panel svg { width: 120px; height: 120px; }
@media (max-width: 520px) { .fn-panel { grid-template-columns: 1fr; } }

/* Mail-Kette */
.kette { display: grid; gap: 10px; }
.glied { display: grid; grid-template-columns: 34px 1fr; gap: 12px; align-items: start; padding: 12px 14px; background: var(--color-paper); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.glied-nr { width: 30px; height: 30px; border-radius: 50%; background: var(--surface); border: 1px solid var(--border); display: inline-flex; align-items: center; justify-content: center; font-family: var(--font-display); font-weight: 600; color: var(--accent); font-size: 14px; }
.glied .control { margin: 4px 0 0; }
.glied-title { font-weight: 500; line-height: 1.35; }
.kette-sum { margin-top: 18px; padding: 18px 20px; border-radius: var(--radius-md); background: var(--surface); border: 1px solid var(--border); }
.kette-vergleich { font-size: 15px; color: var(--text-soft); margin: 6px 0 0; }
.stamp { display: inline-block; transform: rotate(-2deg); border: 2px solid var(--accent-2); color: var(--accent-2-text); font-family: var(--font-display); font-weight: 600; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; padding: 3px 10px; border-radius: 4px; margin-bottom: 12px; }

/* Sortierübung */
.sort-item { padding: 14px 16px; background: var(--color-paper); border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 10px; }
.sort-item p { margin: 0 0 10px; font-family: var(--font-display); font-style: italic; font-size: 18px; line-height: 1.4; }
.sort-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.sort-fb { margin-top: 10px; font-size: 15px; line-height: 1.5; }
.sort-item.is-right { border-color: var(--color-green-light); background: var(--color-green-wash); }
.sort-item.is-wrong { border-color: #E2B7B0; background: var(--color-red-wash); }

/* ─── Quiz ─── */
.quiz { margin: 56px 0 0; padding-top: 8px; }
.quiz-header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; border-top: 1px solid var(--border); padding-top: 28px; margin-bottom: 8px; }
.quiz-header h2 { margin: 0; }
.quiz-count { font-size: 14px; color: var(--text-muted); font-weight: 400; }
.quiz fieldset { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 18px 20px 16px; margin: 18px 0; background: var(--bg-elevated); }
.quiz legend { font-family: var(--font-display); font-weight: 500; font-size: 19px; line-height: 1.35; padding: 0 6px; margin-left: -6px; float: left; width: 100%; margin-bottom: 12px; }
.quiz legend + * { clear: both; }
.q-options { display: grid; gap: 8px; margin-bottom: 12px; }
.q-option { display: flex; gap: 12px; align-items: flex-start; padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--color-paper); cursor: pointer; font-size: 16px; line-height: 1.5; }
.q-option:hover { border-color: var(--border-strong); }
.q-option input { margin-top: 5px; accent-color: var(--accent); flex: 0 0 auto; }
.q-option.is-correct { border-color: var(--color-green-light); background: var(--color-green-wash); }
.q-option.is-wrong { border-color: #E2B7B0; background: var(--color-red-wash); }
.q-option.is-missed { border-style: dashed; border-color: var(--color-green-light); }
.q-feedback { font-weight: 500; margin: 4px 0 8px; }
.q-feedback.is-ok { color: var(--ok); } .q-feedback.is-nope { color: var(--err); }
.q-why { font-size: 15px; line-height: 1.55; color: var(--text-soft); display: grid; gap: 8px; }
.q-why .why-correct strong { color: var(--accent); }
.quiz-summary { margin-top: 18px; padding: 16px 20px; border-radius: var(--radius-md); background: var(--color-green-wash); border: 1px solid var(--color-green-light); font-weight: 500; }

/* ─── Quellen ─── */
.quellen-list { list-style: none; padding: 0; margin: 0 0 32px; counter-reset: q; }
.quellen-list li { counter-increment: q; position: relative; padding: 12px 0 12px 44px; border-bottom: 1px solid var(--border); font-size: 16px; line-height: 1.55; scroll-margin-top: 140px; }
.quellen-list li::before { content: "[" counter(q) "]"; position: absolute; left: 0; top: 12px; font-family: var(--font-display); font-weight: 600; color: var(--accent); font-size: 15px; }
.quellen-list li:target { background: var(--color-amber-wash); }
.quellen-list .q-used { display: block; font-size: 14px; color: var(--text-muted); margin-top: 2px; }

.glossar dt { font-family: var(--font-display); font-weight: 600; font-size: 19px; margin-top: 22px; }
.glossar dd { margin: 4px 0 0; font-size: 16.5px; line-height: 1.6; }

/* ─── Kolophon (About) ─── */
.kolophon { background: var(--surface); border-top: 1px solid var(--border-strong); border-radius: 0 0 var(--radius-md) var(--radius-md); padding: 28px 30px; margin-top: 48px; font-size: 16px; line-height: 1.6; }
.kolophon p { margin: 0 0 12px; }

/* ─── Footer (Claude-Design-Footer-Pattern) ─── */
.foot { background: var(--n500); color: var(--color-paper); margin-top: 24px; }
.foot-inner { max-width: 1240px; margin: 0 auto; padding: 56px 40px 34px; }
.foot-cols { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px; }
.foot-brandline { display: flex; align-items: center; gap: 11px; margin-bottom: 16px; }
.foot-wordmark { font-family: var(--font-display); font-weight: 600; font-size: 20px; color: var(--color-paper); text-decoration: none; }
.foot-wordmark:hover { color: var(--color-paper); }
.foot-wordmark .dot { color: var(--color-amber-light); }
.foot-credo { font-style: italic; font-size: 18px; color: var(--color-paper); margin: 0 0 20px; }
.foot-person { display: flex; align-items: center; gap: 16px; max-width: 40ch; }
.foot-avatar { width: 66px; height: 66px; flex: 0 0 auto; border-radius: 999px; overflow: hidden; background: var(--n100); box-shadow: 0 4px 12px -2px rgba(0,0,0,.28); }
.foot-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.foot-bio { font-size: 14.5px; line-height: 1.5; color: var(--n300); margin: 0; }
.foot-h { font-family: var(--font-display); font-weight: 600; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; color: var(--n300); margin-bottom: 16px; }
.foot-list { display: flex; flex-direction: column; gap: 12px; font-size: 16px; }
.foot-list a { color: var(--color-paper); text-decoration: none; }
.foot-list a:hover { color: var(--color-green-light); }
.foot-base { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; border-top: 1px solid #6b6459; margin-top: 40px; padding-top: 24px; }
.foot-copy { font-size: 14px; color: var(--n300); }
.foot a:focus-visible { outline: 2px solid var(--color-green-light); outline-offset: 3px; }
@media (max-width: 768px) {
  .foot-inner { padding: 40px 24px 28px; }
  .foot-cols { grid-template-columns: 1fr; gap: 32px; }
  .foot-person { max-width: none; }
}

@media print {
  .site-header, .foot, .lesson-nav, .widget, .quiz { display: none; }
}
