/* Letterbow website. Font: Lexend, SIL OFL 1.1 (LICENSES/). */
@font-face {
  font-family: 'Lexend';
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url('/fonts/lexend-latin-400-normal.0601e0a909.woff2') format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

@font-face {
  font-family: 'Lexend';
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url('/fonts/lexend-latin-ext-400-normal.b7289189cf.woff2') format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

@font-face {
  font-family: 'Lexend';
  font-style: normal;
  font-display: swap;
  font-weight: 600;
  src: url('/fonts/lexend-latin-600-normal.c3c291158a.woff2') format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

@font-face {
  font-family: 'Lexend';
  font-style: normal;
  font-display: swap;
  font-weight: 600;
  src: url('/fonts/lexend-latin-ext-600-normal.eb0ab817ca.woff2') format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}
/* Generated by site/build.mjs from client/src/styles/tokens.css (design/tokens) — do not edit. */
:root {
  color-scheme: light;
  --bg: #f7f3ea;
  --surface: #fffdf8;
  --sunken: #f0ebe0;
  --ink: #232a3b;
  --ink-soft: #555d70;
  --line: #e3ddd0;
  --line-strong: #80858f;
  --primary: #232a3b;
  --on-primary: #fffdf8;
  --primary-hover: #363f57;
  --selected: #e8ebf2;
  --focus: #232a3b;
  --overlay: rgb(19 23 32 / 0.38);
  --success: #2d6a47;
  --success-bg: #e3f0e7;
  --warning: #7a5200;
  --warning-bg: #fbefd0;
  --streak: #d4a23c;
  --streak-flame-top: #e2b558;
  --streak-flame-base: #c76f6a;
  --on-streak: #232a3b;
  --streak-bg: #fbefd0;
  --error: #a3302a;
  --error-bg: #fae5e2;
  --info: #3a5487;
  --info-bg: #e6ebf5;
  --shadow-sm: 0 1px 2px rgb(35 42 59 / 0.08);
  --shadow-md: 0 6px 24px rgb(35 42 59 / 0.10);
  --shadow-lg: 0 16px 40px rgb(35 42 59 / 0.18);
  --provider-apple-bg: #000000;
  --provider-apple-ink: #ffffff;
  --provider-google-bg: #ffffff;
  --provider-google-ink: #1f1f1f;
  --provider-google-border: #747775;
  --read-paper: #f7f1e3;
  --read-ink: #2b2722;
  --read-ink-soft: #5e5850;
  --read-word-highlight: #dcebe8;
  --read-focus: #1565c0;
  --read-jump-a: #1a56b0;
  --read-jump-b: #b3400b;
  --read-jump-silent: #8f8a80;
  --brand-night: #232a3b;
  --brand-paper: #f7f3ea;
  --brand-ochre: #d4a23c;
  --brand-rose: #c76f6a;
  --brand-dusk: #5b72a3;
  --brand-night-light: #f7f3ea;
  --brand-ochre-light: #e2b558;
  --brand-rose-light: #df8f8a;
  --brand-dusk-light: #9fb1d8;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1.125rem;
  --radius-xl: 1.5rem;
  --radius-pill: 999px;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-md: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.375rem;
  --text-2xl: 1.75rem;
  --text-3xl: 2.25rem;
  --leading-tight: 1.2;
  --leading-normal: 1.5;
  --leading-loose: 1.65;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-bold: 600;
  --weight-heavy: 700;
  --icon-sm: 1rem;
  --icon-md: 1.375rem;
  --icon-lg: 1.75rem;
  --target: 2.75rem;
  --focus-width: 3px;
  --focus-offset: 2px;
  --motion-fast: 120ms;
  --motion-base: 200ms;
  --motion-slow: 260ms;
  --motion-ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --font-ui: 'Lexend', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
  --provider-height: 2.75rem;
  --provider-apple-radius: 0.5rem;
  --provider-google-radius: 0.25rem;
  --provider-google-mark: 1.25rem;
  --provider-text: 1rem;
  --provider-weight: 500;
  --provider-apple-font: -apple-system, system-ui, sans-serif;
  --provider-google-font: Roboto, system-ui, sans-serif;
  --provider-google-blue: #4285f4;
  --provider-google-green: #34a853;
  --provider-google-yellow: #fbbc05;
  --provider-google-red: #ea4335;
  --c-sh: #1565c0;
  --c-ch: #b34700;
  --c-th: #1b7a3a;
  --c-ng: #7b2fb5;
  --c-ing: #b0197e;
  --c-team: #00757a;
  --c-la: #c62828;
  --c-le: #457000;
  --c-li: #5a4fcf;
  --c-lo: #9a5b00;
  --c-lu: #0b6fa4;
  --c-r: #8d3a6a;
  --c-vt: #a3522e;
  --c-sv: #3f5a75;
  --c-schwa: #6b6470;
  --c-c: #2b2722;
  --c-silent: #5f6570;
  --c-dbl: #00757a;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #131720;
    --surface: #1d2230;
    --sunken: #181c27;
    --ink: #eceef3;
    --ink-soft: #a8afc1;
    --line: #323849;
    --line-strong: #737b90;
    --primary: #eceef3;
    --on-primary: #131720;
    --primary-hover: #ffffff;
    --selected: #2a3245;
    --focus: #eceef3;
    --overlay: rgb(0 0 0 / 0.55);
    --success: #8fd1a8;
    --success-bg: #1d3328;
    --warning: #f0c46a;
    --warning-bg: #3a3020;
    --streak: #e2b558;
    --streak-flame-top: #f0c46a;
    --streak-flame-base: #df8f8a;
    --on-streak: #131720;
    --streak-bg: #3a3020;
    --error: #ff9a8f;
    --error-bg: #3d2224;
    --info: #a9bde6;
    --info-bg: #243052;
    --shadow-sm: 0 1px 2px rgb(0 0 0 / 0.4);
    --shadow-md: 0 6px 24px rgb(0 0 0 / 0.45);
    --shadow-lg: 0 16px 40px rgb(0 0 0 / 0.55);
    --provider-apple-bg: #ffffff;
    --provider-apple-ink: #000000;
    --provider-google-bg: #131314;
    --provider-google-ink: #e3e3e3;
    --provider-google-border: #8e918f;
    --read-paper: #1c1f26;
    --read-ink: #eceae4;
    --read-ink-soft: #a9afbb;
    --read-word-highlight: #23403d;
    --read-focus: #8ec5ff;
    --read-jump-a: #7ab8ff;
    --read-jump-b: #ffab5e;
    --read-jump-silent: #7d828d;
    --c-sh: #6db3ff;
    --c-ch: #ff9e5e;
    --c-th: #6fd48a;
    --c-ng: #c79bff;
    --c-ing: #ff8ad0;
    --c-team: #4fd1d9;
    --c-la: #ff8a80;
    --c-le: #b5d95a;
    --c-li: #a9a2ff;
    --c-lo: #f2b84b;
    --c-lu: #5cc8f5;
    --c-r: #e79ac3;
    --c-vt: #e8a27c;
    --c-sv: #a9c1dc;
    --c-schwa: #bdb4c4;
    --c-c: #eceae4;
    --c-silent: #9aa1ab;
    --c-dbl: #4fd1d9;
  }
}

/* From client/src/styles/categories.css (generated there; copied at build time). */
/* GENERATED by scripts/gen-category-css.mjs — do not edit by hand. */
/* Colour depends on the category class only (R8): no position, line or order is involved. */

.g.c-sh { --gc: var(--c-sh); }
.g.c-ch { --gc: var(--c-ch); }
.g.c-th { --gc: var(--c-th); }
.g.c-ng { --gc: var(--c-ng); }
.g.c-ing { --gc: var(--c-ing); }
.g.c-team { --gc: var(--c-team); }
.g.c-la { --gc: var(--c-la); }
.g.c-le { --gc: var(--c-le); }
.g.c-li { --gc: var(--c-li); }
.g.c-lo { --gc: var(--c-lo); }
.g.c-lu { --gc: var(--c-lu); }
.g.c-r { --gc: var(--c-r); }
.g.c-vt { --gc: var(--c-vt); }
.g.c-sv { --gc: var(--c-sv); }
.g.c-schwa { --gc: var(--c-schwa); }
.g.c-c { --gc: var(--c-c); }
.g.c-silent { --gc: var(--c-silent); }
.g.c-dbl { --gc: var(--c-dbl); }
/* Double letters (ss, ll): a consonant segment the server marked multi. */
.g.c-c.multi { --gc: var(--c-dbl); }

/* Magic e: the silent e carries vce-<name> of its vowel (set by the server). */
.opt-vce .g.c-silent.vce-sh { --gc: var(--c-sh); }
.opt-vce .g.c-silent.vce-ch { --gc: var(--c-ch); }
.opt-vce .g.c-silent.vce-th { --gc: var(--c-th); }
.opt-vce .g.c-silent.vce-ng { --gc: var(--c-ng); }
.opt-vce .g.c-silent.vce-ing { --gc: var(--c-ing); }
.opt-vce .g.c-silent.vce-team { --gc: var(--c-team); }
.opt-vce .g.c-silent.vce-la { --gc: var(--c-la); }
.opt-vce .g.c-silent.vce-le { --gc: var(--c-le); }
.opt-vce .g.c-silent.vce-li { --gc: var(--c-li); }
.opt-vce .g.c-silent.vce-lo { --gc: var(--c-lo); }
.opt-vce .g.c-silent.vce-lu { --gc: var(--c-lu); }
.opt-vce .g.c-silent.vce-r { --gc: var(--c-r); }
.opt-vce .g.c-silent.vce-vt { --gc: var(--c-vt); }
.opt-vce .g.c-silent.vce-sv { --gc: var(--c-sv); }
.opt-vce .g.c-silent.vce-schwa { --gc: var(--c-schwa); }
.opt-vce .g.c-silent.vce-c { --gc: var(--c-c); }
.opt-vce .g.c-silent.vce-silent { --gc: var(--c-silent); }
.opt-vce .g.c-silent.vce-dbl { --gc: var(--c-dbl); }

/* Jumps / Gray styles: the two alternating colours (ja/jb, ka/kb are set by ui/chapter.ts). */
.mode-teams .g.ja, .mode-all .g.ka { --jc: var(--read-jump-a); }
.mode-teams .g.jb, .mode-all .g.kb { --jc: var(--read-jump-b); }

/* Disabled categories fall back to the ink colour. */
.off-sh .g.c-sh, .off-sh.opt-vce .g.c-silent.vce-sh { --gc: var(--read-ink); }
.off-ch .g.c-ch, .off-ch.opt-vce .g.c-silent.vce-ch { --gc: var(--read-ink); }
.off-th .g.c-th, .off-th.opt-vce .g.c-silent.vce-th { --gc: var(--read-ink); }
.off-ng .g.c-ng, .off-ng.opt-vce .g.c-silent.vce-ng { --gc: var(--read-ink); }
.off-ing .g.c-ing, .off-ing.opt-vce .g.c-silent.vce-ing { --gc: var(--read-ink); }
.off-team .g.c-team, .off-team.opt-vce .g.c-silent.vce-team { --gc: var(--read-ink); }
.off-la .g.c-la, .off-la.opt-vce .g.c-silent.vce-la { --gc: var(--read-ink); }
.off-le .g.c-le, .off-le.opt-vce .g.c-silent.vce-le { --gc: var(--read-ink); }
.off-li .g.c-li, .off-li.opt-vce .g.c-silent.vce-li { --gc: var(--read-ink); }
.off-lo .g.c-lo, .off-lo.opt-vce .g.c-silent.vce-lo { --gc: var(--read-ink); }
.off-lu .g.c-lu, .off-lu.opt-vce .g.c-silent.vce-lu { --gc: var(--read-ink); }
.off-r .g.c-r, .off-r.opt-vce .g.c-silent.vce-r { --gc: var(--read-ink); }
.off-vt .g.c-vt, .off-vt.opt-vce .g.c-silent.vce-vt { --gc: var(--read-ink); }
.off-sv .g.c-sv, .off-sv.opt-vce .g.c-silent.vce-sv { --gc: var(--read-ink); }
.off-schwa .g.c-schwa, .off-schwa.opt-vce .g.c-silent.vce-schwa { --gc: var(--read-ink); }
.off-c .g.c-c, .off-c.opt-vce .g.c-silent.vce-c { --gc: var(--read-ink); }
.off-silent .g.c-silent, .off-silent.opt-vce .g.c-silent.vce-silent { --gc: var(--read-ink); }
.off-dbl .g.c-dbl, .off-dbl.opt-vce .g.c-silent.vce-dbl { --gc: var(--read-ink); }
.off-sh.mode-teams .g.c-sh, .off-sh.mode-all .g.c-sh { --jc: var(--read-ink); }
.off-ch.mode-teams .g.c-ch, .off-ch.mode-all .g.c-ch { --jc: var(--read-ink); }
.off-th.mode-teams .g.c-th, .off-th.mode-all .g.c-th { --jc: var(--read-ink); }
.off-ng.mode-teams .g.c-ng, .off-ng.mode-all .g.c-ng { --jc: var(--read-ink); }
.off-ing.mode-teams .g.c-ing, .off-ing.mode-all .g.c-ing { --jc: var(--read-ink); }
.off-team.mode-teams .g.c-team, .off-team.mode-all .g.c-team { --jc: var(--read-ink); }
.off-la.mode-teams .g.c-la, .off-la.mode-all .g.c-la { --jc: var(--read-ink); }
.off-le.mode-teams .g.c-le, .off-le.mode-all .g.c-le { --jc: var(--read-ink); }
.off-li.mode-teams .g.c-li, .off-li.mode-all .g.c-li { --jc: var(--read-ink); }
.off-lo.mode-teams .g.c-lo, .off-lo.mode-all .g.c-lo { --jc: var(--read-ink); }
.off-lu.mode-teams .g.c-lu, .off-lu.mode-all .g.c-lu { --jc: var(--read-ink); }
.off-r.mode-teams .g.c-r, .off-r.mode-all .g.c-r { --jc: var(--read-ink); }
.off-vt.mode-teams .g.c-vt, .off-vt.mode-all .g.c-vt { --jc: var(--read-ink); }
.off-sv.mode-teams .g.c-sv, .off-sv.mode-all .g.c-sv { --jc: var(--read-ink); }
.off-schwa.mode-teams .g.c-schwa, .off-schwa.mode-all .g.c-schwa { --jc: var(--read-ink); }
.off-c.mode-teams .g.c-c, .off-c.mode-all .g.c-c { --jc: var(--read-ink); }
.off-silent.mode-teams .g.c-silent, .off-silent.mode-all .g.c-silent { --jc: var(--read-ink); }
.off-dbl.mode-teams .g.c-dbl, .off-dbl.mode-all .g.c-dbl { --jc: var(--read-ink); }
.off-dbl.mode-teams .g.c-c.multi, .off-dbl.mode-all .g.c-c.multi { --jc: var(--read-ink); }
.off-c:not(.off-dbl).mode-teams .g.c-c.multi.ja, .off-c:not(.off-dbl).mode-all .g.c-c.multi.ka { --jc: var(--read-jump-a); }
.off-c:not(.off-dbl).mode-teams .g.c-c.multi.jb, .off-c:not(.off-dbl).mode-all .g.c-c.multi.kb { --jc: var(--read-jump-b); }
.off-dbl .g.c-c.multi { --gc: var(--read-ink); }
/* Switching single consonants off leaves double letters alone, and the other way round. */
.off-c:not(.off-dbl) .g.c-c.multi { --gc: var(--c-dbl); }

/* Legend / crayon swatches. */
.swatch-sh { --sw: var(--c-sh); }
.swatch-ch { --sw: var(--c-ch); }
.swatch-th { --sw: var(--c-th); }
.swatch-ng { --sw: var(--c-ng); }
.swatch-ing { --sw: var(--c-ing); }
.swatch-team { --sw: var(--c-team); }
.swatch-la { --sw: var(--c-la); }
.swatch-le { --sw: var(--c-le); }
.swatch-li { --sw: var(--c-li); }
.swatch-lo { --sw: var(--c-lo); }
.swatch-lu { --sw: var(--c-lu); }
.swatch-r { --sw: var(--c-r); }
.swatch-vt { --sw: var(--c-vt); }
.swatch-sv { --sw: var(--c-sv); }
.swatch-schwa { --sw: var(--c-schwa); }
.swatch-c { --sw: var(--c-c); }
.swatch-silent { --sw: var(--c-silent); }
.swatch-dbl { --sw: var(--c-dbl); }

/* From client/src/styles/reader.css (copied at build time). */
/*
 * Reader display rules (spec 7, docs/api-contract.md §3). Every display option is a class on
 * the reader container + static CSS — toggling options never needs a new analysis.
 * Colour is a function of the category class only (R8).
 */

.reader-page {
  font-family: var(--font-read);
  font-size: var(--reader-font-size, 28px);
  line-height: 1.7;
  color: var(--read-ink);
  word-spacing: 0.12em;
  letter-spacing: 0.01em;
  overflow-wrap: break-word;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

.reader-page p {
  margin: 0 0 0.9em;
}

.reader-page p:last-child {
  margin-bottom: 0;
}

.opt-buttons .reader-page { line-height: 2.05; }
.opt-ipa .reader-page { line-height: 2.6; word-spacing: 0.3em; }
/* Both on: the buttons sit under the word and the pronunciation under the buttons, so the
   line needs room for three rows. */
.opt-buttons.opt-ipa .reader-page { line-height: 3.15; }

.w {
  border-radius: 0.18em;
  cursor: pointer;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}

@media (hover: hover) and (pointer: fine) {
  .w:hover { background: var(--read-word-highlight); }
}
.w:focus-visible { outline: 3px solid var(--read-focus); outline-offset: 2px; }
.w.is-open { background: var(--read-word-highlight); box-shadow: 0 0 0 0.12em var(--read-word-highlight); }

/* --- colour: category only ------------------------------------------------ */
.g { color: var(--read-ink); }
.mode-all .g,
.mode-teams .g.hl { color: var(--gc, var(--read-ink)); }

/* Magic e: vowel and its silent e share the vowel's colour and a dotted underline. */
.opt-vce .g.vce {
  color: var(--gc, var(--read-ink));
  text-decoration: underline dotted;
  text-decoration-thickness: 0.07em;
  text-underline-offset: 0.2em;
}
.opt-vce.opt-buttons .g.vce { text-decoration: none; }

/* Faded silent letters (a magic e stays visible while magic e is on). */
.opt-fade-silent .g.c-silent { opacity: 0.38; }
.opt-fade-silent.opt-vce .g.c-silent.vce { opacity: 1; }

/* --- sound buttons: dot under one letter, bar under a team, nothing under silent letters --- */
.opt-buttons .g { position: relative; display: inline-block; }
.opt-buttons .g::after {
  content: '';
  position: absolute;
  bottom: -0.2em;
  background: currentColor;
  opacity: 0.9;
}
.opt-buttons .g.one::after { left: 50%; width: 0.2em; height: 0.2em; margin-left: -0.1em; border-radius: 50%; }
.opt-buttons .g.multi::after { left: 8%; right: 8%; height: 0.1em; bottom: -0.15em; border-radius: 0.1em; }
.opt-buttons .g.c-silent::after { content: none; }

/* --- IPA below each word, straight from the server's data-ipa attribute --- */
.opt-ipa .w { position: relative; display: inline-block; }
.opt-ipa .w::after {
  content: attr(data-ipa);
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  margin-top: -0.3em;
  font-size: 0.5em;
  line-height: 1;
  letter-spacing: 0;
  color: var(--read-ink-soft);
  white-space: nowrap;
  pointer-events: none;
}
.opt-buttons.opt-ipa .w::after { margin-top: 0.42em; }

/* Plain (not yet coloured) page text. */
.reader-page.is-plain { color: var(--read-ink); }

/* --- colour styles (owner decision 2026-09-23) ---------------------------------------------
 * Jumps: plain letters in ink, silent letters grey, and the coloured letter groups of a word
 * alternating two colours (--jump-a / --jump-b) so a reader sees where each sound ends.
 * Gray: the same with shades of grey plus an underline under each group, for grayscale
 * screens and e-ink readers. Colors: one colour per kind of sound (the rules above).
 */
.style-jumps .g,
.style-gray .g { color: var(--read-ink); }
.style-jumps.mode-teams .g.hl:not(.c-silent),
.style-jumps.mode-all .g:not(.c-silent),
.style-gray.mode-teams .g.hl:not(.c-silent),
.style-gray.mode-all .g:not(.c-silent) { color: var(--jc, var(--read-ink)); }
.style-jumps .g.c-silent,
.style-gray .g.c-silent,
.style-jumps.opt-vce .g.c-silent.vce,
.style-gray.opt-vce .g.c-silent.vce { color: var(--read-jump-silent); }
.style-jumps.off-silent .g.c-silent,
.style-gray.off-silent .g.c-silent { color: var(--read-ink); }
/* Silent letters are already light: no extra fading on top. */
.style-jumps.opt-fade-silent .g.c-silent,
.style-gray.opt-fade-silent .g.c-silent { opacity: 1; }

/* Gray: a line under every group that makes one sound, so its length shows on any screen. */
.style-gray.mode-teams .g.hl.ja, .style-gray.mode-teams .g.hl.jb,
.style-gray.mode-all .g.multi:not(.c-silent) {
  text-decoration: underline;
  text-decoration-thickness: 0.07em;
  text-underline-offset: 0.2em;
}

/* E-ink redraws slowly: no page-turn slide in the Gray style. */
.style-gray .chapter.is-turning { transition: none; }

/* ==========================================================================================
 * The website's own styles (tasks/website.md; redesigned to the Letterbow identity in LB2).
 * Calm, warm and plain: ink on paper, one family (Lexend), the b mark as the only decoration.
 * Every colour and size is a token generated above this file by build.mjs from
 * design/tokens/tokens.json — no hex values here. The demo is a picture of the app's page and
 * uses the reading tokens (--read-*, --c-*) and the app's own reader rules, unchanged.
 * ======================================================================================== */

:root {
  --wrap: 1140px;
  --gutter: 20px;
  --band-pad: clamp(56px, 8vw, 100px);
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img { max-width: 100%; height: auto; display: block; }

h1, h2, h3 {
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h2 { font-size: clamp(1.8rem, 1.3rem + 1.6vw, 2.5rem); }
h3 { font-size: 1.25rem; letter-spacing: -0.01em; }
p { margin: 0 0 1em; text-wrap: pretty; }

a { color: var(--ink); text-underline-offset: 0.18em; text-decoration-thickness: 0.07em; }
a, button, summary { -webkit-tap-highlight-color: transparent; }
@media (hover: hover) and (pointer: fine) { a:hover { text-decoration-thickness: 0.14em; } }

:focus-visible {
  outline: var(--focus-width) solid var(--focus);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}
main:focus { outline: none; }

.skip {
  position: absolute;
  left: 12px;
  top: -100px;
  z-index: 100;
  padding: 12px 18px;
  background: var(--surface);
  color: var(--ink);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}
.skip:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.wrap--narrow { max-width: calc(820px + 2 * var(--gutter)); }
@media (max-width: 400px) {
  :root { --gutter: 16px; }
}
.center { text-align: center; }

/* ----------------------------------------------------------------------------- the mark */
.brand-mark { display: block; flex: none; overflow: visible; }
.brand-mark__stem { fill: var(--ink); }
.brand-mark__ring--1 { stroke: var(--brand-ochre); }
.brand-mark__ring--2 { stroke: var(--brand-rose); }
.brand-mark__ring--3 { stroke: var(--brand-dusk); }
@media (prefers-color-scheme: dark) {
  .brand-mark__ring--1 { stroke: var(--brand-ochre-light); }
  .brand-mark__ring--2 { stroke: var(--brand-rose-light); }
  .brand-mark__ring--3 { stroke: var(--brand-dusk-light); }
}

/* ----------------------------------------------------------------------------- buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 10px 24px;
  border-radius: var(--radius-pill);
  border: 1.5px solid transparent;
  font: inherit;
  font-weight: var(--weight-bold);
  font-size: 1.05rem;
  line-height: 1.2;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background-color var(--motion-fast) ease, border-color var(--motion-fast) ease;
}
.btn--primary { background: var(--primary); color: var(--on-primary); border-color: var(--primary); }
.btn--ghost { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { text-decoration: none; }
  .btn--primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
  .btn--ghost:hover { border-color: var(--ink); }
}
.btn--large { min-height: 56px; padding: 14px 30px; font-size: 1.12rem; }
.btn--small { min-height: 44px; padding: 8px 20px; font-size: 1rem; }

.actions { display: flex; flex-wrap: wrap; gap: 14px; margin: 0 0 18px; }
.actions--center { justify-content: center; }

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: var(--weight-bold);
}

/* ----------------------------------------------------------------------------- header */
.topbar {
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  border-bottom: 1px solid var(--line);
  z-index: 50;
}
@supports (backdrop-filter: blur(8px)) {
  .topbar { backdrop-filter: blur(10px); }
}
@media (min-width: 760px) {
  .topbar { position: sticky; top: 0; }
}

.topbar__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 20px;
  min-height: 72px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: var(--ink);
  text-decoration: none;
  font-weight: var(--weight-bold);
  font-size: 1.4rem;
  letter-spacing: -0.02em;
}
.brand .brand-mark { height: 34px; width: auto; }

.topnav__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 4px;
}
.topnav a:not(.btn) {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  color: var(--ink);
  text-decoration: none;
  border-radius: var(--radius-pill);
  font-weight: var(--weight-medium);
  font-size: 0.98rem;
}
@media (hover: hover) and (pointer: fine) { .topnav a:not(.btn):hover { background: var(--selected); } }
.topnav a[aria-current='page'] { background: var(--selected); }
.topnav__get { margin-left: 6px; transition: opacity var(--motion-fast) ease, visibility var(--motion-fast) ease; }
.topnav__get:not(.is-shown) { opacity: 0; visibility: hidden; }
@media (prefers-reduced-motion: reduce) { .topnav__get { transition: none; } }

@media (max-width: 759px) {
  .topnav { flex-basis: 100%; }
  .topnav__list { justify-content: space-between; gap: 0; margin: 0 -12px; }
  .topnav a:not(.btn) { padding: 0 12px; font-size: 0.95rem; }
  .topnav__get { margin-left: 0; }
  .topnav__list li:last-child {
    position: absolute;
    top: 12px;
    right: var(--gutter);
  }
  .topbar__inner { position: relative; padding-top: 12px; }
}

/* ----------------------------------------------------------------------------- store badges */
/* The badges are Apple's and Google's artwork, unmodified. Apple asks for clear space of a quarter
   of the badge's height; Google's artwork carries its own. */
.get-app { margin: 0 0 18px; }
.get-app__badges { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; margin: 0; }
.store-badge { display: inline-flex; border-radius: 10px; }
.store-badge--appStore { padding: 13px 0; }
/* Google's PNG carries its own clear space, 13px a side at this height: cancel it sideways so the artwork lines up and the gap is the one above. */
.store-badge--googlePlay { margin-inline: -13px; }
.store-badge img { display: block; max-width: none; }
.get-app__soon {
  display: inline-block;
  margin: 0;
  padding: 14px 22px;
  border-radius: var(--radius-lg);
  background: var(--sunken);
  color: var(--ink-soft);
}
.get-app__soon strong { display: block; color: var(--ink); font-size: 1.12rem; }
.cta__get .get-app__badges { justify-content: center; }
.cta__get .get-app { margin: 0; }

/* ----------------------------------------------------------------------------- hero */
.hero { padding: clamp(36px, 6vw, 80px) 0 clamp(48px, 7vw, 96px); overflow-x: clip; }

.hero__grid {
  display: grid;
  gap: clamp(40px, 5vw, 64px);
  align-items: center;
}
@media (min-width: 980px) {
  .hero__grid { grid-template-columns: 1fr 1.05fr; }
}

.eyebrow {
  display: inline-block;
  margin: 0 0 20px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: var(--weight-medium);
}

.hero__title {
  font-size: clamp(2.4rem, 1.4rem + 4vw, 4.2rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  margin-bottom: 22px;
}
.hero__lead {
  font-size: clamp(1.1rem, 1rem + 0.45vw, 1.28rem);
  color: var(--ink-soft);
  max-width: 34em;
  margin-bottom: 30px;
}
.hero__lead em { font-style: normal; color: var(--ink); font-weight: var(--weight-bold); }
.hero__note { color: var(--ink-soft); font-size: 0.95rem; margin: 0; }

/* Behind the demo: the b, very large and in the paper's own tones. The page in front stays the
   only colourful thing. */
.hero__art { position: relative; padding: 16px 0 0; }
.deco { position: absolute; inset: 0; pointer-events: none; }
.deco .brand-mark { position: absolute; height: 118%; width: auto; right: -7%; top: -12%; }
.deco .brand-mark__stem { fill: var(--sunken); }
.deco .brand-mark__ring { stroke: var(--line); }
@media (max-width: 640px) {
  .deco .brand-mark { right: -14%; height: 100%; }
}

/* ----------------------------------------------------------------------------- demo */
.demo { position: relative; z-index: 1; }
.demo__card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: clamp(14px, 2.4vw, 22px);
}

.demo__tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 4px;
  margin-bottom: 14px;
  background: var(--sunken);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
}
.demo__tabs[hidden] { display: none; }

.demo__tab {
  min-height: 44px;
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  font-weight: var(--weight-bold);
  cursor: pointer;
}
.demo__tab[aria-selected='true'] { background: var(--primary); color: var(--on-primary); }

.demo__panel:focus-visible { outline-offset: 6px; }
@media (prefers-reduced-motion: no-preference) {
  .demo__panel:not([hidden]) { animation: demo-in var(--motion-base) ease-out; }
}
@keyframes demo-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: none; }
}

.demo__page {
  --reader-font-size: clamp(19px, 1rem + 0.6vw, 24px);
  background: var(--read-paper);
  border-radius: var(--radius-lg);
  padding: clamp(18px, 3vw, 28px);
  margin-bottom: 14px;
  line-height: 1.75;
}
/* The demo is a picture of a page, not the reader: words are not buttons here. */
.demo__page .w { cursor: auto; }
.demo__page .w:hover { background: none; }

.demo__help { font-size: 0.95rem; color: var(--ink-soft); margin: 0 4px 10px; }
.demo__help em { font-style: normal; font-weight: var(--weight-bold); color: var(--ink); }

.legend {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin: 0 4px 4px;
  padding: 0;
  font-size: 0.9rem;
}
.legend li { display: inline-flex; align-items: center; gap: 7px; }
.swatch {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--sw, var(--read-ink));
  flex: none;
}
.swatch-ja { --sw: var(--read-jump-a); }
.swatch-jb { --sw: var(--read-jump-b); }
.swatch-js { --sw: var(--read-jump-silent); }

.demo__source { position: relative; z-index: 1; font-size: 0.88rem; color: var(--ink-soft); margin: 16px 8px 0; text-align: center; }

/* ----------------------------------------------------------------------------- bands */
.band { padding: var(--band-pad) 0; position: relative; }
.band--flush { padding-top: 0; }
.band--sky,
.band--sun,
.band--mint,
.band--pink {
  background: var(--sunken);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-head { max-width: 740px; margin: 0 auto clamp(32px, 5vw, 56px); text-align: center; }
.section-head p { color: var(--ink-soft); font-size: 1.12rem; margin: 0; }
.section-title { text-align: center; margin-bottom: clamp(28px, 4vw, 44px); }
.section-lead { color: var(--ink-soft); font-size: 1.12rem; }

.section-head .sticker {
  display: inline-block;
  margin: 0 0 16px;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  font-weight: var(--weight-medium);
  font-size: 0.95rem;
}

/* Icons in a plain ring: ink line on the card, no colour. */
.bubble {
  display: inline-grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--bg);
  border: 1.5px solid var(--line-strong);
  color: var(--ink);
}

/* ----------------------------------------------------------------------------- family promise */
.band--promise { padding-top: clamp(24px, 4vw, 48px); }
.promise {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.promise__item,
.feature,
.audience,
.privacy-card,
.faq__item,
.faq--open .faq__entry {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.promise__item { padding: 26px 24px 22px; text-align: center; }
.promise__title { font-size: 1.25rem; margin-bottom: 6px; }
.promise__item p { color: var(--ink-soft); margin: 0; font-size: 1rem; }

/* ----------------------------------------------------------------------------- screenshots */
/* A plain rounded frame — no recognisable device outline (tasks/website.md, "Imagery"). */
.shot {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 8px;
  border-radius: 30px;
  box-shadow: var(--shadow-md);
}
.shot__img { border-radius: 22px; width: 100%; }
.shot--wide { border-radius: var(--radius-xl); padding: 10px; }
.shot--wide .shot__img { border-radius: var(--radius-lg); }

/* ----------------------------------------------------------------------------- how it works */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 52px;
}
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(3, 1fr); gap: 36px; }
}
.step { display: grid; gap: 24px; justify-items: center; align-content: start; text-align: center; }
.step .shot { width: min(270px, 62vw); }
.step__text { max-width: 340px; }
.step__n {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-bottom: 12px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--on-primary);
  font-weight: var(--weight-bold);
  font-size: 1.1rem;
}
.step__title { font-size: 1.35rem; }
.step p { color: var(--ink-soft); margin: 0; }

/* ----------------------------------------------------------------------------- kids' library */
.ages {
  list-style: none;
  margin: 0 0 36px;
  padding: 0;
  display: grid;
  gap: 22px;
}
@media (min-width: 900px) {
  .ages { grid-template-columns: repeat(3, 1fr); }
}
.age {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 28px 24px 22px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
}
.age__badge {
  display: inline-grid;
  place-items: center;
  width: 72px;
  height: 72px;
  margin: 0 0 16px;
  border-radius: 50%;
  background: var(--sunken);
  border: 1.5px solid var(--line-strong);
  color: var(--ink);
  font-weight: var(--weight-bold);
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}
.age__name { font-size: 1.5rem; margin-bottom: 6px; }
.age__range { font-size: 1rem; color: var(--ink-soft); font-weight: var(--weight-regular); white-space: nowrap; }
.age__body { color: var(--ink-soft); }
.age__books {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
  display: grid;
  gap: 8px;
  flex: 1;
  align-content: start;
}
.age__books li {
  background: var(--sunken);
  border-radius: var(--radius-md);
  border-left: 4px solid var(--line-strong);
  padding: 8px 12px;
  font-size: 0.95rem;
  font-weight: var(--weight-medium);
  line-height: 1.3;
}
.age__count { margin: 0; font-weight: var(--weight-bold); font-size: 1.05rem; }
.age__count a { color: var(--ink); display: inline-flex; min-height: 44px; align-items: center; }

/* ----------------------------------------------------------------------------- features */
.features {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}
.feature { padding: 26px 22px 22px; }
.feature__title { font-size: 1.2rem; margin-bottom: 6px; }
.feature p { color: var(--ink-soft); font-size: 0.98rem; margin: 0; }
.feature em { font-style: normal; font-weight: var(--weight-bold); color: var(--ink); }

.showcase { margin: clamp(48px, 7vw, 80px) auto 0; max-width: 940px; }
.showcase figcaption { text-align: center; color: var(--ink-soft); font-size: 0.98rem; margin-top: 18px; }
.showcase em { font-style: normal; font-weight: var(--weight-bold); color: var(--ink); }

/* ----------------------------------------------------------------------------- audiences */
.audiences {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 18px;
}
@media (min-width: 760px) {
  .audiences { grid-template-columns: repeat(2, 1fr); }
}
.audience { padding: 26px 28px 24px; }
.audience__title { font-size: 1.3rem; margin-bottom: 6px; }
.audience p { color: var(--ink-soft); margin: 0; }

/* ----------------------------------------------------------------------------- lists with ticks */
.checks { list-style: none; margin: 0 0 24px; padding: 0; }
.checks li {
  position: relative;
  padding-left: 36px;
  margin-bottom: 12px;
}
.checks li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.12em;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--selected);
}
.checks li::after {
  content: '';
  position: absolute;
  left: 8.5px;
  top: 0.32em;
  width: 6px;
  height: 11px;
  border: solid var(--ink);
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(40deg);
}
.checks--large li { font-size: 1.08rem; }
.band--mint .checks li::before { background: var(--surface); }

/* ----------------------------------------------------------------------------- privacy teaser */
.privacy-teaser { display: grid; gap: 32px; align-items: center; }
@media (min-width: 860px) {
  .privacy-teaser { grid-template-columns: 300px 1fr; gap: 64px; }
}
.privacy-teaser__art { justify-self: center; width: min(260px, 48vw); }
.art { width: 100%; height: auto; }
.art__frame { fill: var(--ink); }
/* The screen is a picture of the page, so it uses the page's own colours. */
.art__screen { fill: var(--read-paper); }
.art__ink { fill: var(--read-ink); opacity: 0.22; }
.art__a { fill: var(--read-jump-a); }
.art__b { fill: var(--read-jump-b); }
.art__shield-bg { fill: var(--bg); }
.art__shield { fill: var(--ink); }
.art__tick { fill: none; stroke: var(--on-primary); stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.links-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; margin: 0; }

/* ----------------------------------------------------------------------------- plans */
.plans {
  display: grid;
  gap: 24px;
  max-width: 920px;
  margin: 0 auto 24px;
  align-items: start;
}
@media (min-width: 760px) {
  .plans { grid-template-columns: 1fr 1fr; }
}
.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 32px 28px 28px;
  box-shadow: var(--shadow-sm);
}
.plan--paid { border: 2px solid var(--ink); box-shadow: var(--shadow-md); }
.plan__ribbon {
  position: absolute;
  top: -15px;
  right: 22px;
  margin: 0;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  background: var(--primary);
  color: var(--on-primary);
  font-weight: var(--weight-bold);
  font-size: 0.92rem;
}
.plan__name { font-size: 1.45rem; margin-bottom: 4px; }
.plan__price { font-size: 2.6rem; font-weight: var(--weight-bold); letter-spacing: -0.03em; line-height: 1.05; margin-bottom: 6px; }
.plan__price--word { font-size: 2rem; }
.plan__per { font-size: 1.1rem; color: var(--ink-soft); letter-spacing: 0; }
.plan__note { color: var(--ink-soft); font-size: 0.98rem; margin-bottom: 22px; }
.plan .checks li { font-size: 1rem; }
.plan__action { margin: 0; }
.plan__action .btn { width: 100%; }
.plan__soon {
  margin: 0;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: var(--sunken);
  text-align: center;
  font-weight: var(--weight-bold);
}

.notes {
  max-width: 760px;
  margin: 40px auto 0;
  padding: 0 0 0 20px;
  color: var(--ink-soft);
  font-size: 0.98rem;
}
.notes li { margin-bottom: 8px; }

/* ----------------------------------------------------------------------------- FAQ */
.faq { margin-bottom: 24px; }
.faq__item { margin-bottom: 12px; }
.faq__item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
  padding: 12px 20px 12px 24px;
  font-weight: var(--weight-bold);
  font-size: 1.1rem;
  cursor: pointer;
  list-style: none;
  border-radius: var(--radius-lg);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: '+';
  flex: none;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid var(--line-strong);
  color: var(--ink);
  font-size: 1.3rem;
  font-weight: var(--weight-regular);
  line-height: 1;
}
.faq__item[open] summary::after { content: '−'; }
.faq__item p { padding: 0 24px 20px; margin: 0; color: var(--ink-soft); }

.faq--open .faq__entry { padding: 24px 26px 8px; margin-bottom: 14px; }
.faq__q { font-size: 1.3rem; }
.faq__entry p { color: var(--ink-soft); }

/* ----------------------------------------------------------------------------- CTA */
.band--cta { padding-top: clamp(40px, 6vw, 72px); }
.cta { text-align: center; max-width: 760px; }
.cta__title { font-size: clamp(2rem, 1.4rem + 2.2vw, 3rem); }
.cta__body { color: var(--ink-soft); font-size: 1.12rem; margin-bottom: 28px; }

/* ----------------------------------------------------------------------------- inner pages */
.page-head { padding: clamp(48px, 8vw, 96px) 0 clamp(36px, 5vw, 56px); text-align: center; }
.page-head h1 { font-size: clamp(2.3rem, 1.5rem + 3.2vw, 3.6rem); letter-spacing: -0.03em; }
.page-head__lead { color: var(--ink-soft); font-size: 1.15rem; max-width: 40em; margin: 0 auto; }
.page-head--center { padding-bottom: var(--band-pad); }
.page-head--center .page-head__lead { margin-bottom: 28px; }

.privacy-grid { display: grid; gap: 18px; margin-bottom: 36px; }
@media (min-width: 760px) {
  .privacy-grid { grid-template-columns: 1fr 1fr; }
}
.privacy-card { padding: 28px 26px 10px; }
.privacy-card h2 { font-size: 1.4rem; }
.privacy-card .checks li { font-size: 1rem; }

.booklist {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: clamp(22px, 4vw, 36px);
  margin-bottom: 28px;
}
.booklist__title { font-size: 1.8rem; margin-bottom: 20px; }
.booklist__count {
  display: inline-block;
  vertical-align: middle;
  margin-left: 8px;
  padding: 3px 12px;
  border-radius: var(--radius-pill);
  background: var(--primary);
  color: var(--on-primary);
  font-size: 0.9rem;
  letter-spacing: 0;
}
.booklist__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
}
.book {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--sunken);
  border-left: 4px solid var(--line-strong);
  border-radius: var(--radius-md);
  padding: 14px 18px;
}
.book__title { font-weight: var(--weight-bold); line-height: 1.3; }
.book__author { color: var(--ink-soft); font-size: 0.92rem; }

.notfound__code {
  font-size: clamp(4.5rem, 3rem + 7vw, 8rem);
  font-weight: var(--weight-bold);
  letter-spacing: -0.04em;
  line-height: 1;
  color: var(--ink);
  margin-bottom: 16px;
}

/* ----------------------------------------------------------------------------- the whole shelf */
.shelf { margin-top: clamp(32px, 5vw, 48px); }
.shelf__toggle {
  display: flex;
  justify-content: center;
  width: fit-content;
  margin: 0 auto;
  min-height: 50px;
  align-items: center;
  padding: 10px 24px;
  border-radius: var(--radius-pill);
  border: 1.5px solid var(--line-strong);
  background: var(--surface);
  font-weight: var(--weight-bold);
  cursor: pointer;
  list-style: none;
}
.shelf__toggle::-webkit-details-marker { display: none; }
@media (hover: hover) and (pointer: fine) { .shelf__toggle:hover { border-color: var(--ink); } }
.shelf[open] .shelf__toggle { margin-bottom: clamp(32px, 5vw, 48px); }

/* ----------------------------------------------------------------------------- footer */
.footer {
  background: var(--sunken);
  border-top: 1px solid var(--line);
  padding: 36px 0 28px;
  font-size: 0.95rem;
}
.footer__grid { display: grid; gap: 28px 20px; grid-template-columns: 1fr 1fr; }
.footer__about { grid-column: 1 / -1; }
@media (min-width: 760px) {
  .footer__grid { grid-template-columns: 1.6fr 1fr 1fr; }
  .footer__about { grid-column: auto; }
}
.footer__about p { color: var(--ink-soft); max-width: 26em; margin-top: 10px; }
.brand--footer { font-size: 1.2rem; }
.brand--footer .brand-mark { height: 28px; }
.footer__title {
  font-size: 0.9rem;
  font-weight: var(--weight-bold);
  color: var(--ink-soft);
  margin-bottom: 8px;
  letter-spacing: 0;
}
.footer__col ul { list-style: none; margin: 0; padding: 0; }
.footer__col a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--ink);
  text-decoration: none;
  font-weight: var(--weight-medium);
}
@media (hover: hover) and (pointer: fine) { .footer__col a:hover { text-decoration: underline; } }
.footer__base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 24px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.88rem;
}
.footer__base p { margin: 0; }

/* The hero text sits above the demo's background shape. */
.hero__text { position: relative; z-index: 3; }

/* Phones: the four promises two by two, a little more compact. */
@media (max-width: 560px) {
  .promise { grid-template-columns: 1fr 1fr; gap: 12px; }
  .promise__item { padding: 20px 12px 16px; }
  .promise__title { font-size: 1.05rem; }
  .promise__item p { font-size: 0.9rem; }
  .promise .bubble { width: 46px; height: 46px; }
}
.footer__marks { flex-basis: 100%; font-size: 0.85rem; }

/* ----------------------------------------------------------------------------- contact form */
.contact {
  display: grid;
  gap: 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: clamp(20px, 4vw, 36px);
}
.contact__field { display: grid; gap: 8px; }
.contact__label { font-weight: var(--weight-bold); }
.contact__hint { color: var(--ink-soft); font-weight: var(--weight-regular); }
.contact input,
.contact textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-md);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
}
.contact textarea { resize: vertical; min-height: 10em; }
.contact input:focus-visible,
.contact textarea:focus-visible { border-color: var(--ink); }
.contact__note { margin: 0; color: var(--ink-soft); font-size: 0.95rem; }
.contact .actions { margin: 0; }
.contact__error {
  margin: 0;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: var(--error-bg);
  color: var(--error);
  font-weight: var(--weight-medium);
}
/* The honeypot: out of sight and out of the tab order, still in the form for bots. */
.contact__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ----------------------------------------------------------------------------- consent bar */
.consent {
  position: fixed;
  inset: auto 0 0;
  z-index: 50;
  background: var(--surface);
  border-top: 1px solid var(--line-strong);
  box-shadow: var(--shadow-lg);
  padding: 14px 0 calc(14px + env(safe-area-inset-bottom));
}
.consent[hidden] { display: none; }
.consent__inner { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }
.consent__text { flex: 1 1 32em; margin: 0; font-size: 0.95rem; }
.consent__actions { display: flex; gap: 10px; margin: 0; }
.footer__link {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  cursor: pointer;
  min-height: 24px;
}
