/* LiD Trainer site stylesheet. No JavaScript anywhere on this site.

   Brand: deep ink-blue + warm gold, a quiet nod to the app icon's
   black/red/gold without flag kitsch. Full palette and rationale in
   /docs/BRAND.md. Correct answers stay green, errors stay red; ink and
   gold are reserved for everything else. */

@font-face {
  font-family: "LT Sans";
  src: url("/fonts/inter-variable.b2a23cf4fe.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  /* -- brand swatches (see docs/BRAND.md) -------------------------- */
  --ink-900: #0b1c33;
  --ink-700: #16314f;
  --ink-500: #2f5788;
  --gold-500: #8c6620;
  --gold-300: #e3c988;

  /* -- semantic tokens, light mode ---------------------------------- */
  --bg: #f7f8fa;
  --bg-alt: #eef1f6;
  --surface: #ffffff;
  --border: #d7dee6;
  --text: #142033;
  --text-muted: #51607a;
  --link: var(--ink-500);
  --link-visited: #6a4f97;
  --focus: var(--gold-500);
  --heading: var(--ink-900);
  --accent-text: var(--gold-500);

  --success: #185c34;
  --success-bg: #e5f4ea;
  --success-border: #2f7d43;
  --error: #8a1f18;
  --error-bg: #fbe9e8;
  --error-border: #b3261e;

  --badge-bg: var(--ink-900);
  --badge-text: #ffffff;
  --badge-icon: var(--gold-500);

  --max-width: 46rem;
  --radius: 10px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: var(--ink-900);
    --bg-alt: #0e2138;
    --surface: var(--ink-700);
    --border: #2a4162;
    --text: #eef2f6;
    --text-muted: #a9b7c6;
    --link: #9dc0ec;
    --link-visited: #c6b3ea;
    --focus: var(--gold-300);
    --heading: var(--text);
    --accent-text: var(--gold-300);

    --success: #8fd6a4;
    --success-bg: #123a26;
    --success-border: #3f9a58;
    --error: #f0a39c;
    --error-bg: #3a1613;
    --error-border: #c0392b;

    --badge-bg: var(--gold-300);
    --badge-text: var(--ink-900);
    --badge-icon: var(--ink-900);
  }
}

/* An explicit theme choice (future toggle) always wins over prefers-color-scheme. */
:root[data-theme="dark"] {
  --bg: var(--ink-900);
  --bg-alt: #0e2138;
  --surface: var(--ink-700);
  --border: #2a4162;
  --text: #eef2f6;
  --text-muted: #a9b7c6;
  --link: #9dc0ec;
  --link-visited: #c6b3ea;
  --focus: var(--gold-300);
  --heading: var(--text);
  --accent-text: var(--gold-300);
  --success: #8fd6a4;
  --success-bg: #123a26;
  --success-border: #3f9a58;
  --error: #f0a39c;
  --error-bg: #3a1613;
  --error-border: #c0392b;
  --badge-bg: var(--gold-300);
  --badge-text: var(--ink-900);
  --badge-icon: var(--ink-900);
}
:root[data-theme="light"] {
  --bg: #f7f8fa;
  --bg-alt: #eef1f6;
  --surface: #ffffff;
  --border: #d7dee6;
  --text: #142033;
  --text-muted: #51607a;
  --link: var(--ink-500);
  --link-visited: #6a4f97;
  --focus: var(--gold-500);
  --heading: var(--ink-900);
  --accent-text: var(--gold-500);
  --success: #185c34;
  --success-bg: #e5f4ea;
  --success-border: #2f7d43;
  --error: #8a1f18;
  --error-bg: #fbe9e8;
  --error-border: #b3261e;
  --badge-bg: var(--ink-900);
  --badge-text: #ffffff;
  --badge-icon: var(--gold-500);
}

* { box-sizing: border-box; }

html { color-scheme: light dark; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "LT Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}
@media (min-width: 480px) {
  body { font-size: 18px; }
}

a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 0.12em; }
a:visited { color: var(--link-visited); }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible, button:focus-visible, summary:focus-visible, [tabindex]:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 3px;
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.25rem 1rem 3rem;
}

/* ---- header ------------------------------------------------------- */
header.site-header {
  background: var(--ink-900);
  border-bottom: 3px solid var(--gold-300);
}
header.site-header .wrap {
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1.5rem;
  justify-content: space-between;
}
.site-name {
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  color: #ffffff;
  text-decoration: none;
}
.site-name:visited { color: #ffffff; }
nav.site-nav { display: flex; flex-wrap: wrap; gap: 0.3rem 0.3rem; font-size: 0.92rem; }
/* 44px high touch targets. The current page or section gets a gold
   underline (aria-current is "page" on the page itself, "true" on the
   section a page belongs to). */
nav.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: #e7ecf5;
  text-decoration: none;
  padding: 0.35rem 0.6rem;
  border-radius: 7px;
}
nav.site-nav a:visited { color: #e7ecf5; }
nav.site-nav a:hover { background: rgba(255, 255, 255, 0.12); text-decoration: none; }
nav.site-nav a:focus-visible { outline-offset: -2px; }
nav.site-nav a[aria-current] {
  text-decoration: underline;
  text-decoration-color: var(--gold-300);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.35em;
}
.nav-app-short { display: none; }
@media (max-width: 480px) {
  header.site-header .wrap { flex-direction: column; align-items: flex-start; gap: 0.15rem; padding-bottom: 0.35rem; }
  /* One row of links under the site name. The first link's text lines up
     with the site name, the link boxes sit side by side without overlap. */
  nav.site-nav { width: 100%; gap: 0.15rem; }
  nav.site-nav a { padding: 0.35rem 0.5rem; white-space: nowrap; }
  nav.site-nav a:first-child { margin-inline-start: -0.5rem; }
  .nav-app-long { display: none; }
  .nav-app-short { display: inline; }
}

/* ---- headings & type scale ----------------------------------------- */
h1 { font-size: clamp(1.5rem, 4.6vw, 1.9rem); line-height: 1.28; font-weight: 800; letter-spacing: -0.01em; margin: 0.2rem 0 1.1rem; color: var(--heading); }
h2 { font-size: 1.2rem; font-weight: 700; margin: 1.9rem 0 0.65rem; color: var(--heading); }
h3 { font-size: 1.02rem; font-weight: 700; margin: 1.3rem 0 0.5rem; }

.breadcrumbs { font-size: 0.85rem; color: var(--text-muted); margin: 0.9rem 0 0.4rem; }
.breadcrumbs a { color: var(--text-muted); }
.breadcrumbs .sep { margin: 0 0.35rem; }

/* ---- language switcher (details/summary, no JavaScript) -------------- */
/* Its own row under the breadcrumb. Opens in place and pushes the page
   down, no overlay. The arrow is a CSS border shape (no glyph), so it is
   not read out as part of the summary's name. */
.lang-switch { margin: 0.35rem 0 0.9rem; }
.lang-switch > summary {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 44px;
  padding-block: 0.3rem;
  padding-inline: 0.9rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  /* The default tap highlight is a rectangle around the pill. */
  -webkit-tap-highlight-color: transparent;
}
.lang-switch > summary::-webkit-details-marker { display: none; }
.lang-switch > summary::after {
  content: "";
  flex: none;
  width: 0.42em;
  height: 0.42em;
  /* Physical borders on purpose: the shape is a down arrow in every
     writing direction. */
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-0.12em) rotate(45deg);
}
.lang-switch[open] > summary::after { transform: translateY(0.12em) rotate(225deg); }
.lang-switch > summary:hover { border-color: var(--link); }
.lang-switch > summary:active { background: var(--bg-alt); }
.lang-switch-list {
  list-style: none;
  margin: 0.55rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
  gap: 0.4rem;
  /* The footer link jumps to #language. Keep the summary in view above it. */
  scroll-margin-top: 4rem;
}
.lang-switch-list a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding-block: 0.35rem;
  padding-inline: 0.8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  font-size: 0.92rem;
}
.lang-switch-list a:visited { color: var(--text); }
.lang-switch-list a:hover { border-color: var(--link); }
.lang-switch-list a[aria-current="page"] {
  border-color: var(--link);
  border-width: 2px;
  padding-inline: calc(0.8rem - 1px);
  font-weight: 700;
}
.lang-switch-list .lang-switch-all { grid-column: 1 / -1; }
.lang-switch-list .lang-switch-all a {
  border-style: dashed;
  background: transparent;
  color: var(--link);
}

.eyebrow {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: 0.35rem;
  font-variant-numeric: tabular-nums;
}

/* ---- generic surfaces ------------------------------------------------ */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
  margin: 1rem 0;
}
.card > .eyebrow:first-child { margin-top: 0; }

/* ---- answers: letter-in-a-circle rows -------------------------------- */
.answers { list-style: none; margin: 0.85rem 0; padding: 0; display: grid; gap: 0.55rem; }
.answers li {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.7rem 0.85rem;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  background: var(--surface);
}
.answers .label {
  flex: none;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  border: 2px solid var(--link);
  color: var(--link);
  font-weight: 800;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.05rem;
}
/* The text column is at least as tall as the letter circle and centres
   its content in that height, so a one-line answer (and its "correct
   answer" mark) sits on the circle's axis while a multi-line answer still
   starts at the top next to the circle. */
.answers li > span:last-child {
  min-height: 1.9rem;
  /* Long German answers ("Ministerpräsidentin/Ministerpräsident") may
     break inside the word instead of widening the page on a phone. */
  min-width: 0;
  overflow-wrap: anywhere;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 0.45rem;
  row-gap: 0.1rem;
}
.answers li.is-correct {
  background: var(--success-bg);
  border-color: var(--success-border);
  border-width: 2px;
  padding: calc(0.7rem - 1px) calc(0.85rem - 1px);
}
.answers li.is-correct .label {
  background: var(--surface);
  border-color: var(--success-border);
  color: var(--success);
}
.correct-mark {
  color: var(--success);
  font-weight: 700;
  white-space: nowrap;
}

.correct-answer-banner {
  border: 1px solid var(--success-border);
  background: var(--success-bg);
  color: var(--success);
  border-radius: var(--radius);
  padding: 0.7rem 0.9rem;
  font-weight: 700;
  margin: 1rem 0;
}

/* ---- translation card: visually secondary to the German original ----- */
.translation-block {
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: var(--bg-alt);
  margin-top: 1.3rem;
  padding: 0.95rem 1.1rem;
}
.translation-block .eyebrow { color: var(--text-muted); }
.translation-block > .eyebrow:first-child { margin-top: 0; }
/* :not(.eyebrow) keeps the Translation label the same size as the German
   original label. */
.translation-block p:not(.eyebrow), .translation-block .answers { font-size: 0.95em; }
.translation-block .answers li { background: transparent; }
.translation-block .answers li.is-correct { background: var(--success-bg); }

/* ---- explanation / tips: readable blocks with a left accent ---------- */
.accent-block {
  border-left: 3px solid var(--accent-text);
  padding: 0.15rem 0 0.15rem 1rem;
  margin: 0.75rem 0 1.25rem;
}
.accent-block p { margin: 0.6rem 0; }
[dir="rtl"] .accent-block { border-left: none; border-right: 3px solid var(--accent-text); padding: 0.15rem 1rem 0.15rem 0; }

figure.q-image { margin: 1rem 0; }
figure.q-image img { max-width: 100%; height: auto; border-radius: var(--radius); border: 1px solid var(--border); display: block; }
figure.q-image figcaption { font-size: 0.85rem; color: var(--text-muted); margin-top: 0.35rem; }
.image-grid { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.image-grid figure { width: calc(50% - 0.4rem); margin: 0; }
@media (max-width: 480px) { .image-grid figure { width: 100%; } }

.tips-list { padding-left: 1.2rem; }
[dir="rtl"] .tips-list { padding-left: 0; padding-right: 1.2rem; }
.meta-row { display: flex; flex-wrap: wrap; gap: 0.9rem; font-size: 0.92rem; color: var(--text-muted); margin: 0.5rem 0 1.1rem; }

/* ---- previous/next as buttons ----------------------------------------- */
/* Logical placement: previous at the inline start, next at the inline
   end, so Arabic pages put previous on the right. The arrows are swapped
   in the template. */
.pager { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.75rem; margin: 2rem 0; }
.pager a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  gap: 0.4rem;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 999px;
  padding: 0.55rem 1.05rem;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  color: var(--text);
}
.pager a:visited { color: var(--text); }
.pager a:hover { border-color: var(--link); }
.pager .next { text-align: end; margin-inline-start: auto; }

/* ---- app promo (templates/_promo.html) ----------------------------------- */
/* A plain box on the page surface with a thin border: title, one factual
   sentence or two, the official badge. Sits after the content, never
   between a question and its answer. */
.app-promo {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.2rem 0.6rem;
  margin: 1.75rem 0;
  background: var(--surface);
}
.app-promo-title { margin: 0 0 0.3rem; font-weight: 700; color: var(--heading); }
.app-promo-body { margin: 0 0 0.4rem; }
/* Official Google Play badge, used unmodified per Google's badge
   guidelines: at least 40px high, with clear space around it. The PNG
   itself carries that clear space. */
.app-promo .badge-link { display: inline-block; line-height: 0; }
.app-promo .badge-link img { width: 186px; height: auto; max-width: 100%; }
.app-promo .badge-link:hover { opacity: 0.9; }
/* Compact variant: one text line near the top of a long page. */
.app-promo-compact {
  margin: 1rem 0 1.5rem;
  padding: 0 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.app-promo-compact a { display: flex; align-items: center; min-height: 44px; padding: 0.35rem 0; }

/* ---- language home: hero ---------------------------------------------------- */
/* H1, lead, two buttons, the feature line and the language switcher, all in
   the first screen on a phone. */
.hero .lead { margin: 0 0 1.1rem; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 0 0 0.65rem; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 48px;
  padding: 0.5rem 1.2rem;
  border: 2px solid transparent;
  border-radius: var(--radius);
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
}
.btn:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.18em; }
/* --badge-bg and --badge-text flip in dark mode (gold button, ink text). */
.btn-primary, .btn-primary:visited { background: var(--badge-bg); border-color: var(--badge-bg); color: var(--badge-text); }
.btn-secondary, .btn-secondary:visited { background: var(--surface); border-color: var(--link); color: var(--link); }
@media (max-width: 480px) {
  .hero-ctas .btn { flex: 1 1 100%; }
}
.hero-features { margin: 0 0 0.35rem; color: var(--text-muted); font-size: 0.92rem; }
.hero-feature { white-space: nowrap; }
.hero .lang-switch { margin-bottom: 0; }
/* Note under the stat tiles: normal weight, so it reads as an explanation
   of the third tile and not as a fourth one. */
.about-box + .pass-note { margin-top: -0.6rem; }
.pass-note { margin-bottom: 1.6rem; color: var(--text-muted); font-size: 0.95rem; }

/* ---- related links: "Read next" after a guide, "Related guide" on topics -- */
.related h2 { margin-top: 1.75rem; }
.related-guide-title { margin-top: 1.75rem; }

/* Root chooser: the one text link to the app */
.root-app { margin: 0.5rem 0 1.5rem; }

/* ---- plain / card-style link lists -------------------------------------- */
ul.plain-list, ol.plain-list { padding-left: 1.2rem; }
[dir="rtl"] ul.plain-list, [dir="rtl"] ol.plain-list { padding-left: 0; padding-right: 1.2rem; }
ul.link-list { list-style: none; padding: 0; margin: 0.6rem 0 1.5rem; display: grid; gap: 0.55rem; }
ul.link-list.grid-2 { grid-template-columns: 1fr 1fr; }
@media (max-width: 480px) { ul.link-list.grid-2 { grid-template-columns: 1fr; } }
ul.link-list a {
  display: block;
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
}
ul.link-list a:visited { color: var(--text); }
ul.link-list a:hover { border-color: var(--link); }
ul.link-list strong { font-variant-numeric: tabular-nums; color: var(--link); }

/* ---- hub "about the test" stat tiles ------------------------------------ */
.about-box { display: flex; flex-wrap: wrap; gap: 0.85rem; margin: 1.1rem 0 1.6rem; }
.about-box .stat {
  flex: 1 1 8rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  text-align: center;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1rem 0.75rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.about-box .stat svg { width: 1.6rem; height: 1.6rem; stroke: var(--accent-text); fill: none; stroke-width: 1.8; }

footer.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-alt);
  margin-top: 2.5rem;
  color: var(--text-muted);
  font-size: 0.88rem;
}
footer.site-footer .wrap { padding-top: 1.5rem; padding-bottom: 1.75rem; }
footer.site-footer .footer-name { font-weight: 800; color: var(--text); margin: 0 0 0.2rem; }
footer.site-footer .footer-tagline { margin: 0 0 0.9rem; }
footer.site-footer p { margin: 0.4rem 0; }
footer.site-footer a { color: var(--text-muted); }
footer.site-footer nav { margin-top: 0.6rem; display: flex; gap: 1rem; flex-wrap: wrap; }

.lang-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.6rem; margin: 1.25rem 0; }
@media (max-width: 480px) { .lang-grid { grid-template-columns: repeat(2, 1fr); } }
.lang-grid a {
  display: block; text-align: center; padding: 1rem 0.5rem;
  border: 1px solid var(--border); background: var(--surface);
  border-radius: var(--radius); text-decoration: none; font-weight: 700; color: var(--text);
}
.lang-grid a:hover { border-color: var(--link); }

/* ---- hand-authored content pages (site/content/) ------------------------ */
.content-slot { max-width: 40rem; }
.content-slot dl { margin: 0.5rem 0 1.5rem; }
.content-slot dt {
  font-weight: 700;
  margin-top: 1.2rem;
  padding-left: 0.75rem;
  border-left: 3px solid var(--accent-text);
  color: var(--heading);
}
[dir="rtl"] .content-slot dt { border-left: none; border-right: 3px solid var(--accent-text); padding-left: 0; padding-right: 0.75rem; }
.content-slot dt:first-child { margin-top: 0; }
.content-slot dd { margin: 0.3rem 0 0 0.75rem; }
[dir="rtl"] .content-slot dd { margin: 0.3rem 0.75rem 0 0; }
.content-slot ul, .content-slot ol { padding-left: 1.2rem; }
[dir="rtl"] .content-slot ul, [dir="rtl"] .content-slot ol { padding-left: 0; padding-right: 1.2rem; }
.content-slot li { margin: 0.25rem 0; }
.content-slot figure { margin: 1.6rem 0; }
.content-slot figcaption { font-size: 0.85rem; color: var(--text-muted); text-align: center; margin-top: 0.5rem; }
.content-slot .diagram { display: block; max-width: 600px; width: 100%; height: auto; margin: 0 auto; color: var(--text); }
.content-slot .diagram text { fill: currentColor; }
.content-slot .diagram .muted { color: var(--text-muted); }
.content-slot .step-list { list-style: none; padding: 0; counter-reset: step; }
.content-slot .step-list li { counter-increment: step; padding-left: 2.1rem; position: relative; margin: 0.6rem 0; }
.content-slot .step-list li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 1.5rem; height: 1.5rem; border-radius: 50%;
  background: var(--gold-300); color: var(--ink-900); border: none;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 800;
}

/* German original block on RTL pages stays left-to-right and left-aligned.
   Its label and "correct answer" mark are in the page language and carry
   their own dir, so they read right to left. */
[dir="rtl"] [dir="ltr"] { text-align: left; }
[dir="rtl"] [dir="ltr"] .answers li { flex-direction: row; text-align: left; }
[dir="rtl"] [dir="ltr"] > .eyebrow[dir="rtl"] { text-align: start; }

.site-footer .footer-legal { font-size: 0.85em; color: var(--text-muted); }

/* Diagrams: SVG text-anchor is computed from the inherited direction, so an
   RTL page would place every label on the other side of its x coordinate
   and over the shapes. Keep the coordinate system LTR, Arabic glyph runs
   inside a label still shape right-to-left on their own. */
[dir="rtl"] svg { direction: ltr; }

/* ---- study lists: question link plus its correct answer ---------------- */
ul.study-list { list-style: none; padding: 0; margin: 0.6rem 0 1.5rem; display: grid; gap: 0.55rem; }
ul.study-list li {
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
}
ul.study-list a { color: var(--text); text-decoration: none; }
ul.study-list a:visited { color: var(--text); }
ul.study-list a:hover { text-decoration: underline; }
ul.study-list strong { font-variant-numeric: tabular-nums; color: var(--link); }
.answer-line { margin: 0.3rem 0 0; color: var(--success); font-size: 0.93em; font-weight: 600; }

/* Bundesland page: one card per question with answer and explanation */
.study-card h2 { font-size: 1.05rem; line-height: 1.4; margin: 0 0 0.4rem; }
.study-card h2 a { color: var(--heading); text-decoration: none; }
.study-card h2 a:hover { text-decoration: underline; }
.study-card .q-num { color: var(--link); font-variant-numeric: tabular-nums; }
.study-card .answer-line { margin-bottom: 0.6rem; }
.study-card p { margin: 0.5rem 0; }
.study-card .more-link { margin-bottom: 0; font-size: 0.92em; }

/* Question list: topic contents at the top */
nav.toc { border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); padding: 0.8rem 1rem; margin: 1rem 0 1.5rem; }
nav.toc .eyebrow { margin-top: 0; }
nav.toc ul { margin: 0.3rem 0 0; padding-left: 1.2rem; }
[dir="rtl"] nav.toc ul { padding-left: 0; padding-right: 1.2rem; }
nav.toc li { margin: 0.2rem 0; }
nav.toc .count { color: var(--text-muted); font-variant-numeric: tabular-nums; }
h2 > a { color: inherit; }

/* Footer link columns */
footer.site-footer .footer-cols { display: flex; flex-wrap: wrap; gap: 0.5rem 2.5rem; margin: 0.6rem 0 1rem; }
footer.site-footer nav.footer-links { display: block; margin: 0; flex: 1 1 14rem; }
footer.site-footer .footer-heading { font-weight: 700; color: var(--text); margin: 0 0 0.3rem; }
footer.site-footer nav.footer-links ul { list-style: none; padding: 0; margin: 0; }
footer.site-footer nav.footer-links li { margin: 0.25rem 0; }

/* Root chooser: German and English study links */
.root-study { display: flex; flex-wrap: wrap; gap: 0 2.5rem; }
.root-study section { flex: 1 1 16rem; }

/* Touch screens: more room between stacked links */
@media (pointer: coarse) {
  nav.toc li, footer.site-footer nav.footer-links li, .root-study li { margin: 0.55rem 0; }
  .study-card .more-link a, .root-app a { display: inline-block; padding: 0.3rem 0; }
}

/* Long German compounds (Staatsangehörigkeitsmodernisierungsgesetz) break
   instead of pushing the page wider than a 360px phone. */
main.wrap { overflow-wrap: break-word; }
