/* Fantasy / Adventure preset
   For: D&D, Pathfinder, classic fantasy */

:root {
  --bg: #1a1a2e;
  --bg-card: #222240;
  --bg-header: #0f0f1f;
  --bg-hero: #0f0f1f;
  --text: #c8d6e5;
  --text-muted: #808fa2;
  /* The header and hero stay dark in both schemes, so their text keeps the
     dark palette's ink even when light mode darkens --text (#259). */
  --text-on-header: #c8d6e5;
  --text-muted-on-header: #808fa2;
  --accent: #fbbf24;
  --accent-on-header: #fbbf24;
  --accent-dim: rgba(251, 191, 36, 0.1);
  --border: #2a2a4a;
  --danger: #ef4444;
  --warning: #f59e0b;
  --success: #22c55e;
  --font-heading: "Palatino", "Palatino Linotype", "Book Antiqua", serif;
  --font-reading: var(--font-heading);
  --font-body: system-ui, -apple-system, sans-serif;
}

@media screen and (prefers-color-scheme: light) {
  :root:not(:where([data-theme="dark"])) {
    --bg: #f5f0e6;
    --bg-card: #fffdf5;
    --bg-header: #1a1a2e;
    --bg-hero: #1a1a2e;
    --text: #1a1a2e;
    --text-muted: #5a5a7e;
    --accent: #8a6508;
    /* the header and hero stay dark in the light palette: the bright accent reads there */
    --accent-on-header: #fbbf24;
    --accent-dim: rgba(184, 134, 11, 0.08);
    --border: #c8c0a8;
    /* the Story page's Memorable Moments: deeper kind colours for the light card */
    --moment-dramatic: #b42318; --moment-intriguing: #0b5cad; --moment-funny: #7a4f00; --moment-epic: #6b3fb5; --moment-tragic: #475569;
  }
}
@media screen {
  :root:where([data-theme="light"]) {
    --bg: #f5f0e6;
    --bg-card: #fffdf5;
    --bg-header: #1a1a2e;
    --bg-hero: #1a1a2e;
    --text: #1a1a2e;
    --text-muted: #5a5a7e;
    --accent: #8a6508;
    /* the header and hero stay dark in the light palette: the bright accent reads there */
    --accent-on-header: #fbbf24;
    --accent-dim: rgba(184, 134, 11, 0.08);
    --border: #c8c0a8;
    /* the Story page's Memorable Moments: deeper kind colours for the light card */
    --moment-dramatic: #b42318; --moment-intriguing: #0b5cad; --moment-funny: #7a4f00; --moment-epic: #6b3fb5; --moment-tragic: #475569;
  }
}
@media print {
  :root {
    --bg: #f5f0e6;
    --bg-card: #fffdf5;
    --bg-header: #1a1a2e;
    --bg-hero: #1a1a2e;
    --text: #1a1a2e;
    --text-muted: #5a5a7e;
    --accent: #8a6508;
    /* the header and hero stay dark in the light palette: the bright accent reads there */
    --accent-on-header: #fbbf24;
    --accent-dim: rgba(184, 134, 11, 0.08);
    --border: #c8c0a8;
    /* the Story page's Memorable Moments: deeper kind colours for the light card */
    --moment-dramatic: #b42318; --moment-intriguing: #0b5cad; --moment-funny: #7a4f00; --moment-epic: #6b3fb5; --moment-tragic: #475569;
  }
}

/* chapter pages: start */
/* An illuminated book: a coloured initial on each chapter's Teaser or overview, star ornaments between chapters. */
.story-contents-chapter + .story-contents-chapter::before {
  content: "✦ ✧ ✦";
  display: block;
  color: var(--accent);
  letter-spacing: 0.4em;
  margin-bottom: var(--space-1500);
}
p.story-chapter-label { font-family: var(--font-heading); font-variant: small-caps; letter-spacing: 0.14em; font-size: var(--font-size-1000); color: var(--accent); }
.story-contents-chapter h3, .story-chapter > .page-title { font-family: var(--font-heading); }
.story-contents .story-chapter-teaser > p:first-child::first-letter, .story-contents p.story-chapter-overview::first-letter,
.story-chapter-teaser > p:first-child::first-letter, .story-chapter > p.story-chapter-overview::first-letter {
  font-family: var(--font-heading);
  font-size: 2.2em;
  line-height: 1;
  color: var(--accent);
}
.story-contents-sessions { font-family: var(--font-heading); }
p.story-chapter-now { text-transform: none; font-variant: small-caps; font-family: var(--font-heading); }
.story-contents-end { font-family: var(--font-heading); }
.story-contents-end[data-ending="continues"]::before { content: "Here the tale pauses…"; }
.story-contents-end[data-ending="ended"]::before { content: "Here ends the tale"; }
/* chapter pages: end */
