/* ==========================================================================
   A. E. Hearth — "By the fire" design system
   Dark firelit sections alternate with warm parchment ones, like turning
   from the hearth to the open page of a book.
   ========================================================================== */

:root {
  /* Firelight darks */
  --night: #140d09;
  --espresso: #1d140e;
  --cocoa: #2a1d14;
  --cocoa-2: #3a281b;

  /* Paper */
  --cream: #fbf4e6;
  --parchment: #f3e7cf;
  --parchment-deep: #eadabb;

  /* Ink on paper */
  --ink: #2a1c12;
  --ink-2: #5d4837;
  --ink-3: #8a7360;
  --rule: rgba(42, 28, 18, 0.12);

  /* Text on dark */
  --on-dark: #f6ecd8;
  --on-dark-2: #cfbb9e;
  --on-dark-3: #9c8770;
  --rule-dark: rgba(246, 236, 216, 0.1);

  /* Accents */
  --amber: #eaa54a;
  --amber-hi: #ffcf7d;
  --rust: #b9592b;
  --sage: #7f9c74;
  --glow: 234, 150, 60;       /* firelight, as rgb triplet */
  --accent: 234, 165, 74;     /* per-page accent glow, overridden by themes */

  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --script: "Caveat", "Bradley Hand", cursive;

  --r-sm: 10px;
  --r: 18px;
  --r-lg: 28px;
  --max: 1180px;
  --header-h: 76px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

.theme-hearthcore { --accent: 92, 196, 186; }
.theme-apothecary { --accent: 150, 196, 112; }

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--night);
  color: var(--on-dark);
  font: 400 1.0625rem/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Film-grain warmth over everything */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

html.menu-open { overflow: hidden; }

img { display: block; max-width: 100%; height: auto; }
svg { flex-shrink: 0; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  font-family: var(--display);
  font-optical-sizing: auto;
  font-variation-settings: "SOFT" 100;
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
h1 { font-size: clamp(2.9rem, 6.4vw, 5.4rem); }
h2 { font-size: clamp(2.2rem, 4.4vw, 3.6rem); }
h3 { font-size: clamp(1.5rem, 2.4vw, 2rem); }

h1 em, h2 em, h3 em {
  font-style: italic;
  font-weight: 400;
  color: var(--amber-hi);
}

p { margin: 0 0 1.1em; }

.wrap {
  width: min(var(--max), 100% - 3rem);
  margin-inline: auto;
}
.wrap--narrow { width: min(760px, 100% - 3rem); margin-inline: auto; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  border-radius: 6px;
}

::selection { background: rgba(234, 165, 74, 0.35); color: inherit; }

/* ---------- Small type ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 1.25rem;
  font: 600 0.74rem/1 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--amber);
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}
.eyebrow--center { justify-content: center; }
.eyebrow--center::after {
  content: "";
  width: 28px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}
.paper .eyebrow { color: var(--rust); }

.lede { font-size: clamp(1.1rem, 1.6vw, 1.25rem); line-height: 1.65; }

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 52px;
  padding: 0.9rem 1.6rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font: 600 0.98rem/1 var(--sans);
  letter-spacing: 0.005em;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s, color 0.25s, border-color 0.25s;
}
.btn svg { width: 18px; height: 18px; transition: transform 0.25s var(--ease); }
.btn:hover svg { transform: translateX(3px); }

.btn--fire {
  color: #2a1708;
  background: linear-gradient(180deg, #ffd387 0%, #f0aa4e 55%, #e2913a 100%);
  box-shadow:
    0 14px 34px -12px rgba(var(--glow), 0.75),
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    inset 0 -2px 0 rgba(150, 70, 10, 0.25);
}
.btn--fire:hover {
  transform: translateY(-2px);
  box-shadow:
    0 20px 44px -12px rgba(var(--glow), 0.95),
    inset 0 1px 0 rgba(255, 255, 255, 0.6),
    inset 0 -2px 0 rgba(150, 70, 10, 0.25);
}
.btn--fire:active { transform: translateY(0); }

.btn--line {
  color: var(--on-dark);
  border-color: rgba(246, 236, 216, 0.22);
  background: rgba(246, 236, 216, 0.03);
}
.btn--line:hover { border-color: var(--amber); color: var(--amber-hi); }

.paper .btn--line { color: var(--ink); border-color: rgba(42, 28, 18, 0.22); background: transparent; }
.paper .btn--line:hover { border-color: var(--rust); color: var(--rust); }

.btn--ink {
  color: var(--cream);
  background: var(--ink);
  box-shadow: 0 12px 26px -14px rgba(42, 28, 18, 0.8);
}
.btn--ink:hover { transform: translateY(-2px); background: #3a281b; }

.btn--sm { min-height: 42px; padding: 0.7rem 1.15rem; font-size: 0.9rem; }

.btn:disabled { opacity: 0.65; cursor: wait; transform: none; }

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 600;
  color: var(--amber-hi);
  border-bottom: 1px solid rgba(255, 207, 125, 0.35);
  padding-bottom: 2px;
  transition: gap 0.25s var(--ease), border-color 0.25s;
}
.text-link:hover { gap: 0.7rem; border-color: var(--amber-hi); }
.text-link svg { width: 16px; height: 16px; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 60;
  height: var(--header-h);
}
.site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(20, 13, 9, 0.8);
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  box-shadow: 0 1px 0 var(--rule-dark), 0 20px 40px -30px rgba(0, 0, 0, 0.8);
  opacity: 0;
  transition: opacity 0.4s var(--ease);
}
.site-header.is-scrolled::before { opacity: 1; }

.site-header__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 1.5rem;
}

.brand {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font: 500 1.4rem/1 var(--display);
  font-variation-settings: "SOFT" 100;
  letter-spacing: -0.01em;
  color: var(--on-dark);
}
.brand__flame {
  width: 26px;
  height: 26px;
  filter: drop-shadow(0 0 10px rgba(var(--glow), 0.7));
}

.nav {
  display: flex;
  align-items: center;
  gap: 2.2rem;
}
.nav a:not(.btn) {
  position: relative;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--on-dark-2);
  transition: color 0.2s;
}
.nav a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 1px;
  background: var(--amber);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}
.nav a:not(.btn):hover,
.nav a[aria-current="page"] { color: var(--on-dark); }
.nav a:not(.btn):hover::after,
.nav a[aria-current="page"]::after { transform: scaleX(1); }

.nav__toggle {
  position: relative;
  z-index: 2;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid rgba(246, 236, 216, 0.18);
  border-radius: 14px;
  background: rgba(20, 13, 9, 0.4);
  color: var(--on-dark);
  cursor: pointer;
}
.nav__toggle span {
  display: block;
  width: 18px;
  height: 1.5px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.35s var(--ease), opacity 0.2s;
}
.menu-open .nav__toggle span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.menu-open .nav__toggle span:nth-child(2) { opacity: 0; }
.menu-open .nav__toggle span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ---------- Sections ---------- */
.section { position: relative; padding: clamp(5rem, 10vw, 8.5rem) 0; }
.section--tight { padding: clamp(3.5rem, 7vw, 5.5rem) 0; }

.paper {
  color: var(--ink);
  background:
    radial-gradient(900px 500px at 10% 0%, rgba(255, 255, 255, 0.45), transparent 60%),
    radial-gradient(800px 600px at 100% 100%, rgba(214, 180, 128, 0.25), transparent 60%),
    var(--parchment);
}
.paper--deep { background-color: var(--parchment-deep); }
.paper p { color: var(--ink-2); }
.paper h1, .paper h2, .paper h3 { color: var(--ink); }
.paper h2 em, .paper h3 em { color: var(--rust); }

.section__head { max-width: 720px; margin-bottom: clamp(2.75rem, 5vw, 4rem); }
.section__head--center { margin-inline: auto; text-align: center; }
.section__head p { font-size: 1.12rem; }

/* Soft wavy seams between dark and paper sections */
.seam {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  z-index: 1;
  display: block;
  width: 100%;
  height: clamp(30px, 5vw, 70px);
  pointer-events: none;
}
.seam--top { top: -1px; bottom: auto; transform: scale(-1, -1); }
.seam--to-paper { color: var(--parchment); }
.seam--to-deep { color: var(--parchment-deep); }
.seam--to-night { color: var(--night); }
.seam path { fill: currentColor; }

/* Ornament divider */
.ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  color: var(--rust);
  opacity: 0.7;
}
.ornament::before,
.ornament::after {
  content: "";
  width: 70px;
  height: 1px;
  background: currentColor;
  opacity: 0.5;
}
.ornament svg { width: 22px; height: 22px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: min(100svh, 980px);
  padding: calc(var(--header-h) + 3rem) 0 clamp(4rem, 8vw, 6rem);
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(1100px 620px at 72% 115%, rgba(226, 110, 36, 0.38), transparent 62%),
    radial-gradient(680px 520px at 74% 46%, rgba(var(--glow), 0.2), transparent 70%),
    radial-gradient(900px 600px at -5% -10%, rgba(130, 74, 40, 0.28), transparent 60%),
    var(--night);
}
.embers {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.hero__grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  align-items: center;
  gap: clamp(3rem, 6vw, 5.5rem);
}
.hero h1 { margin-bottom: 1.4rem; }
.hero .lede { max-width: 33rem; margin-bottom: 2.25rem; color: var(--on-dark-2); }
.hero .lede strong { color: var(--on-dark); font-weight: 600; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.6rem;
  padding: 0.5rem 0.95rem 0.5rem 0.75rem;
  border: 1px solid rgba(234, 165, 74, 0.32);
  border-radius: 999px;
  background: rgba(234, 165, 74, 0.08);
  font: 600 0.78rem/1 var(--sans);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--amber-hi);
}
.pill__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--amber-hi);
  box-shadow: 0 0 0 4px rgba(255, 207, 125, 0.18), 0 0 14px rgba(255, 190, 90, 0.9);
  animation: flicker 2.4s ease-in-out infinite;
}

@keyframes flicker {
  0%, 100% { opacity: 1; transform: scale(1); }
  40% { opacity: 0.75; transform: scale(0.9); }
  60% { opacity: 0.95; transform: scale(1.05); }
}

/* ---------- Signup ---------- */
.signup-card {
  max-width: 560px;
  padding: 1.15rem;
  border: 1px solid rgba(246, 236, 216, 0.12);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(58, 40, 27, 0.6), rgba(42, 29, 20, 0.5));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.signup-card__label {
  display: block;
  margin: 0.15rem 0.35rem 0.8rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--on-dark-2);
}

.signup {
  position: relative;
  display: flex;
  gap: 0.5rem;
}
.signup input[type="email"] {
  flex: 1;
  min-width: 0;
  min-height: 54px;
  padding: 0 1.15rem;
  border: 1px solid rgba(246, 236, 216, 0.14);
  border-radius: 999px;
  background: rgba(20, 13, 9, 0.55);
  color: var(--on-dark);
  font: 500 1rem var(--sans);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.signup input[type="email"]::placeholder { color: var(--on-dark-3); }
.signup input[type="email"]:focus {
  outline: none;
  border-color: var(--amber);
  background: rgba(20, 13, 9, 0.75);
  box-shadow: 0 0 0 4px rgba(234, 165, 74, 0.16);
}
.signup .btn { flex-shrink: 0; min-height: 54px; }

.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.signup__msg {
  margin: 0;
  font-size: 0.92rem;
  color: var(--on-dark-2);
}
.signup__msg:not(:empty) { margin-top: 0.85rem; padding-inline: 0.35rem; }
.signup__msg.is-error { color: #ff9b82; }
.signup__msg.is-success { color: #b9dba5; }
.signup__msg a { color: var(--amber-hi); text-decoration: underline; }

.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.4rem;
  margin: 1.1rem 0 0;
  padding: 0 0.35rem;
  list-style: none;
  font-size: 0.86rem;
  color: var(--on-dark-3);
}
.trust li { display: inline-flex; align-items: center; gap: 0.45rem; }
.trust svg { width: 15px; height: 15px; color: var(--amber); }

/* ---------- 3D book ---------- */
.book3d-stage {
  position: relative;
  display: grid;
  place-items: center;
  perspective: 1800px;
}
.book3d-stage::after {
  content: "";
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: -4%;
  height: 50px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(0, 0, 0, 0.6), transparent);
  filter: blur(8px);
  z-index: -1;
}
.book3d-stage::before {
  content: "";
  position: absolute;
  inset: 5% 0;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(var(--glow), 0.35), transparent);
  filter: blur(40px);
  z-index: -1;
}

.book3d {
  --w: clamp(240px, 27vw, 380px);
  --t: 30px;
  position: relative;
  width: var(--w);
  aspect-ratio: 2 / 3;
  transform-style: preserve-3d;
  transform: rotateY(var(--ry, -24deg)) rotateX(var(--rx, 5deg));
  transition: transform 0.9s var(--ease);
}
.book3d__front,
.book3d__back {
  position: absolute;
  inset: 0;
  border-radius: 3px 8px 8px 3px;
}
.book3d__front {
  overflow: hidden;
  transform: translateZ(calc(var(--t) / 2));
}
.book3d__front img { width: 100%; height: 100%; object-fit: cover; }
.book3d__front::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.32) 0, rgba(255, 255, 255, 0.22) 1.4%, rgba(0, 0, 0, 0.15) 3.2%, transparent 7%),
    linear-gradient(115deg, rgba(255, 255, 255, 0.16), transparent 40%);
  pointer-events: none;
}
.book3d__back {
  background: #3a2414;
  transform: translateZ(calc(var(--t) / -2));
  box-shadow: -30px 40px 70px -20px rgba(0, 0, 0, 0.75);
}
.book3d__pages {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: calc(100% - var(--t) / 2 - 4px);
  width: var(--t);
  background: repeating-linear-gradient(90deg, #f4e8cf 0 2px, #d8c39d 2px 3px);
  transform: rotateY(90deg);
}
.book3d__spine {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--t) / -2);
  width: var(--t);
  background: linear-gradient(90deg, #2c1a0e, #5a3a1f 50%, #2c1a0e);
  transform: rotateY(-90deg);
}

.seal {
  position: absolute;
  top: -4%;
  right: 4%;
  z-index: 3;
  display: grid;
  place-items: center;
  width: clamp(84px, 8vw, 104px);
  aspect-ratio: 1;
  border-radius: 50%;
  color: #fff3dc;
  text-align: center;
  background: radial-gradient(circle at 35% 30%, #d9733d, #a8461c 60%, #7e3010);
  box-shadow: 0 12px 26px -8px rgba(0, 0, 0, 0.6), inset 0 0 0 3px rgba(255, 220, 180, 0.25), inset 0 0 0 7px rgba(126, 48, 16, 0.6);
  transform: rotate(12deg);
}
.seal strong {
  display: block;
  font: 600 clamp(1.4rem, 2vw, 1.75rem)/0.9 var(--display);
  font-variation-settings: "SOFT" 100;
}
.seal span {
  display: block;
  margin-top: 0.2rem;
  font: 700 0.58rem/1 var(--sans);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* ---------- Flat book cover (reusable) ---------- */
.cover {
  position: relative;
  border-radius: 3px 7px 7px 3px;
  box-shadow:
    0 1px 1px rgba(0, 0, 0, 0.15),
    0 22px 40px -16px rgba(30, 15, 5, 0.65),
    0 50px 80px -40px rgba(30, 15, 5, 0.5);
  overflow: hidden;
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.cover img { width: 100%; aspect-ratio: 5 / 8; object-fit: cover; }
.cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.3) 0, rgba(255, 255, 255, 0.2) 1.5%, rgba(0, 0, 0, 0.12) 3.5%, transparent 7%),
    linear-gradient(120deg, rgba(255, 255, 255, 0.12), transparent 45%);
  pointer-events: none;
}

/* ---------- Promises ---------- */
.promises {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.25rem, 2.5vw, 2rem);
}
.promise {
  position: relative;
  padding: 2.25rem 2rem 2rem;
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, rgba(255, 252, 244, 0.75), rgba(255, 250, 240, 0.4));
  box-shadow: 0 30px 50px -40px rgba(80, 50, 20, 0.5);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.promise:hover { transform: translateY(-4px); box-shadow: 0 34px 60px -36px rgba(80, 50, 20, 0.55); }
.promise__icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  margin-bottom: 1.4rem;
  border-radius: 18px;
  color: var(--rust);
  background: linear-gradient(160deg, #fbe2bd, #f2c995);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 10px 20px -12px rgba(185, 89, 43, 0.6);
}
.promise__icon svg { width: 28px; height: 28px; }
.promise h3 { font-size: 1.55rem; margin-bottom: 0.45rem; }
.promise p { margin: 0; font-size: 1rem; }

/* ---------- Series features (home) ---------- */
.series-list { display: grid; gap: clamp(1.5rem, 3vw, 2.25rem); }

.series-feature {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  overflow: hidden;
  border-radius: 32px;
  color: var(--on-dark);
  background:
    radial-gradient(600px 420px at 25% 60%, rgba(var(--accent), 0.28), transparent 65%),
    linear-gradient(140deg, var(--cocoa) 0%, var(--espresso) 70%);
  box-shadow: 0 50px 90px -50px rgba(40, 20, 8, 0.85);
  isolation: isolate;
}
.series-feature--flip { grid-template-columns: 1fr 1fr; }
.series-feature--flip .series-feature__art { order: 2; }
.series-feature--flip { background:
    radial-gradient(600px 420px at 75% 60%, rgba(var(--accent), 0.26), transparent 65%),
    linear-gradient(220deg, var(--cocoa) 0%, var(--espresso) 70%); }

.series-feature__art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 460px;
  padding: 3rem 2rem;
}
.series-feature__body { padding: clamp(2.25rem, 5vw, 4rem); }
.series-feature__body p { color: var(--on-dark-2); max-width: 30rem; }
.series-feature h3 { font-size: clamp(2rem, 3.4vw, 2.9rem); margin-bottom: 0.9rem; }

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1.5rem 0 2rem;
  padding: 0;
  list-style: none;
}
.chips li {
  padding: 0.4rem 0.85rem;
  border: 1px solid rgba(246, 236, 216, 0.16);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--on-dark-2);
  background: rgba(246, 236, 216, 0.04);
}
.paper .chips li { border-color: var(--rule); color: var(--ink-2); background: rgba(255, 255, 255, 0.35); }

/* Fanned covers */
.fan { position: relative; width: min(100%, 380px); height: 380px; }
.fan .cover { position: absolute; top: 50%; left: 50%; width: 200px; }
.fan .cover:nth-child(1) { transform: translate(-82%, -50%) rotate(-7deg); z-index: 1; }
.fan .cover:nth-child(2) { transform: translate(-18%, -46%) rotate(6deg); z-index: 2; }
.fan--single .cover { width: 230px; transform: translate(-50%, -50%) rotate(-3deg); }
.series-feature:hover .fan .cover:nth-child(1) { transform: translate(-90%, -52%) rotate(-10deg); }
.series-feature:hover .fan .cover:nth-child(2) { transform: translate(-12%, -48%) rotate(8deg); }
.series-feature:hover .fan--single .cover { transform: translate(-50%, -53%) rotate(-1deg); }

/* ---------- Letter ---------- */
.letter-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  align-items: center;
  gap: clamp(2.5rem, 6vw, 5.5rem);
}
.letter {
  position: relative;
  padding: clamp(2.25rem, 5vw, 3.5rem);
  border-radius: 6px;
  background:
    repeating-linear-gradient(180deg, transparent 0 35px, rgba(140, 100, 60, 0.08) 35px 36px),
    var(--cream);
  box-shadow: 0 2px 0 rgba(255, 255, 255, 0.6) inset, 0 40px 70px -40px rgba(70, 40, 15, 0.55), 0 6px 14px -8px rgba(70, 40, 15, 0.25);
  transform: rotate(-0.8deg);
}
.letter::before,
.letter::after {
  content: "";
  position: absolute;
  top: -14px;
  width: 110px;
  height: 30px;
  background: rgba(234, 205, 150, 0.7);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}
.letter::before { left: 12%; transform: rotate(-4deg); }
.letter::after { right: 12%; transform: rotate(3deg); }
.letter p {
  font: 400 clamp(1.1rem, 1.5vw, 1.25rem)/1.75 var(--display);
  font-variation-settings: "SOFT" 100;
  color: var(--ink-2);
}
.letter p:first-of-type::first-letter {
  float: left;
  margin: 0.08em 0.12em 0 0;
  font: 500 3.6em/0.8 var(--display);
  color: var(--rust);
}
.signature {
  margin-top: 1.5rem;
  font: 700 clamp(2rem, 3.5vw, 2.6rem)/1 var(--script);
  color: var(--rust);
  transform: rotate(-3deg);
  transform-origin: left;
}

/* ---------- Shop band ---------- */
.shop-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem 2.5rem;
  padding: clamp(1.75rem, 3.5vw, 2.5rem) clamp(1.75rem, 4vw, 3rem);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  background: rgba(255, 252, 244, 0.5);
}
.shop-band__text { display: flex; align-items: center; gap: 1.25rem; }
.shop-band__icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  color: var(--rust);
  background: #f8dcb4;
}
.shop-band__icon svg { width: 26px; height: 26px; }
.shop-band h3 { margin: 0 0 0.2rem; font-size: 1.5rem; }
.shop-band p { margin: 0; font-size: 0.98rem; }

/* ---------- Final CTA ---------- */
.final-cta {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
  background:
    radial-gradient(900px 500px at 50% 120%, rgba(226, 110, 36, 0.42), transparent 62%),
    radial-gradient(500px 300px at 50% 60%, rgba(var(--glow), 0.12), transparent 70%),
    var(--night);
}
.final-cta .embers { opacity: 0.8; }
.final-cta h2 { max-width: 15ch; margin-inline: auto; }
.final-cta .lede { max-width: 34rem; margin: 0 auto 2.25rem; color: var(--on-dark-2); }
.final-cta .signup-card { margin-inline: auto; text-align: left; }
.final-cta .trust { justify-content: center; }
.final-cta__cover {
  width: 132px;
  margin: 0 auto 2.25rem;
  transform: rotate(-4deg);
}

/* ---------- Page hero (series + shop) ---------- */
.page-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding: calc(var(--header-h) + clamp(3.5rem, 8vw, 6rem)) 0 clamp(4.5rem, 9vw, 7rem);
  background:
    radial-gradient(800px 560px at 78% 55%, rgba(var(--accent), 0.26), transparent 65%),
    radial-gradient(900px 500px at 70% 120%, rgba(226, 110, 36, 0.3), transparent 62%),
    radial-gradient(800px 500px at -5% -10%, rgba(130, 74, 40, 0.28), transparent 60%),
    var(--night);
}
.page-hero__grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: clamp(2.5rem, 6vw, 5rem);
}
.page-hero h1 { margin-bottom: 1.25rem; }
.page-hero .lede { max-width: 36rem; color: var(--on-dark-2); }
.page-hero__actions { display: flex; flex-wrap: wrap; gap: 0.85rem; margin-top: 2.25rem; }
.page-hero .chips { margin: 0 0 1.75rem; }
.page-hero--center { text-align: center; }
.page-hero--center .lede { margin-inline: auto; }
.page-hero--center .signup-card { margin: 2.5rem auto 0; text-align: left; }
.page-hero--center .trust { justify-content: center; }

.crumbs {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1.75rem;
  font-size: 0.88rem;
  color: var(--on-dark-3);
}
.crumbs a { color: var(--on-dark-2); transition: color 0.2s; }
.crumbs a:hover { color: var(--amber-hi); }

/* ---------- Reading order (series pages) ---------- */
.reading { border-top: 1px solid var(--rule); }
.book-row {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
  padding: clamp(3rem, 6vw, 4.5rem) 0;
  border-bottom: 1px solid var(--rule);
}
.book-row__media { position: relative; width: 250px; }
.book-row__media .cover:hover { transform: translateY(-6px) rotate(-1deg); }
.ribbon {
  position: absolute;
  top: 18px;
  left: -10px;
  z-index: 2;
  padding: 0.5rem 0.85rem;
  border-radius: 4px;
  font: 700 0.68rem/1 var(--sans);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #fff3dc;
  background: var(--rust);
  box-shadow: 0 8px 16px -8px rgba(120, 50, 15, 0.8);
}
.book-row__num {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.9rem;
  font: 600 0.74rem/1 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--rust);
}
.book-row__num b {
  font: 400 3.4rem/0.8 var(--display);
  font-variation-settings: "SOFT" 100;
  letter-spacing: -0.02em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(185, 89, 43, 0.6);
}
.book-row h2 { font-size: clamp(2.2rem, 4vw, 3.1rem); margin-bottom: 0.35rem; }
.book-row__tagline {
  font: italic 400 1.25rem/1.4 var(--display);
  font-variation-settings: "SOFT" 100;
  color: var(--ink-3) !important;
  margin-bottom: 1.25rem;
}
.book-row__blurb { max-width: 38rem; font-size: 1.06rem; }
.book-row .chips { margin: 1.4rem 0 1.9rem; }
.book-row__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ---------- Inline CTA band (series pages) ---------- */
.cta-band {
  display: grid;
  grid-template-columns: auto 1fr minmax(320px, 1.1fr);
  align-items: center;
  gap: clamp(1.75rem, 4vw, 3rem);
  padding: clamp(2rem, 4vw, 3rem);
  border: 1px solid var(--rule-dark);
  border-radius: 32px;
  background:
    radial-gradient(500px 300px at 0% 50%, rgba(var(--glow), 0.22), transparent 70%),
    linear-gradient(140deg, var(--cocoa), var(--espresso));
  box-shadow: 0 50px 90px -50px rgba(40, 20, 8, 0.85);
}
.cta-band__cover { width: 112px; transform: rotate(-4deg); }
.cta-band h3 { margin-bottom: 0.4rem; font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.cta-band p { margin: 0; color: var(--on-dark-2); }
.cta-band .signup-card { padding: 0.85rem; max-width: none; }

/* ---------- Shop (merch) ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.6rem;
  padding: 0.5rem 1rem;
  border: 1px solid rgba(234, 165, 74, 0.35);
  border-radius: 999px;
  background: rgba(234, 165, 74, 0.08);
  font: 600 0.76rem/1 var(--sans);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber-hi);
}

.wares {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.25rem, 2.5vw, 2rem);
}
.ware {
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  background: rgba(255, 252, 244, 0.6);
  box-shadow: 0 30px 50px -40px rgba(80, 50, 20, 0.5);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.ware:hover { transform: translateY(-5px); box-shadow: 0 40px 60px -36px rgba(80, 50, 20, 0.55); }
.ware__art {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  color: var(--ink);
  background:
    radial-gradient(260px 180px at 50% 60%, rgba(234, 165, 74, 0.28), transparent 70%),
    linear-gradient(180deg, #f6e4c3, #ecd4ab);
}
.ware__art svg { width: 46%; height: auto; }
.ware__tag {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font: 700 0.64rem/1 var(--sans);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--rust);
  background: rgba(255, 250, 240, 0.85);
}
.ware__body { padding: 1.6rem 1.75rem 1.9rem; }
.ware h3 { font-size: 1.55rem; margin-bottom: 0.4rem; }
.ware p { margin: 0; font-size: 0.98rem; }

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  padding: clamp(3.5rem, 7vw, 5rem) 0 2rem;
  color: var(--on-dark-3);
  background: var(--night);
  border-top: 1px solid var(--rule-dark);
}
.site-footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--rule-dark);
}
.site-footer .brand { margin-bottom: 1rem; }
.site-footer__tag { max-width: 22rem; margin: 0; font-size: 0.98rem; color: var(--on-dark-3); }
.site-footer h4 {
  margin: 0 0 1rem;
  font: 600 0.74rem/1 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--on-dark-2);
}
.site-footer ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 0.65rem; }
.site-footer ul a { color: var(--on-dark-3); transition: color 0.2s; }
.site-footer ul a:hover { color: var(--amber-hi); }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  padding-top: 1.75rem;
  font-size: 0.86rem;
}

/* ---------- Scroll reveal ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
  transition-delay: var(--d, 0s);
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1080px) {
  .cta-band { grid-template-columns: auto 1fr; }
  .cta-band .signup-card { grid-column: 1 / -1; }
}

@media (max-width: 960px) {
  .promises,
  .wares { grid-template-columns: 1fr; max-width: 560px; margin-inline: auto; }
  .letter-grid { grid-template-columns: 1fr; }
  .site-footer__top { grid-template-columns: 1fr 1fr; }
  .site-footer__top > :first-child { grid-column: 1 / -1; }
}

@media (max-width: 880px) {
  :root { --header-h: 68px; }

  .nav__toggle { display: inline-flex; }

  .nav {
    position: fixed;
    inset: 0;
    z-index: 1;
    flex-direction: column;
    justify-content: center;
    gap: 0.4rem;
    padding: 6rem 2rem 3rem;
    background:
      radial-gradient(600px 400px at 50% 110%, rgba(226, 110, 36, 0.35), transparent 65%),
      var(--night);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s var(--ease), visibility 0.35s;
  }
  .menu-open .nav { opacity: 1; visibility: visible; }
  .nav a:not(.btn) {
    padding: 0.55rem 0;
    font: 500 2.1rem/1.2 var(--display);
    font-variation-settings: "SOFT" 100;
    color: var(--on-dark);
  }
  .nav a:not(.btn)::after { display: none; }
  .nav a[aria-current="page"] { color: var(--amber-hi); }
  .nav .btn { margin-top: 1.75rem; }

  .hero { min-height: 0; }
  .hero__grid,
  .page-hero__grid { grid-template-columns: 1fr; }
  .hero__copy { text-align: center; }
  .hero .lede { margin-inline: auto; }
  .hero .signup-card { margin-inline: auto; text-align: left; }
  .hero .trust { justify-content: center; }
  .book3d { --w: min(62vw, 280px); --t: 22px; }

  .series-feature,
  .series-feature--flip { grid-template-columns: 1fr; }
  .series-feature--flip .series-feature__art { order: 0; }
  .series-feature__art { min-height: 340px; padding: 2.5rem 1rem 0; }
  .series-feature__body { padding-top: 1.5rem; text-align: center; }
  .series-feature__body p { margin-inline: auto; }
  .series-feature .chips { justify-content: center; }
  .fan { height: 320px; }
  .fan .cover { width: 168px; }
  .fan--single .cover { width: 190px; }

  .page-hero__art { order: -1; }
  .page-hero__grid { text-align: center; }
  .page-hero .lede { margin-inline: auto; }
  .page-hero .chips,
  .page-hero__actions,
  .crumbs { justify-content: center; }

  .book-row { grid-template-columns: 1fr; text-align: center; }
  .book-row__media { width: 210px; margin-inline: auto; }
  .book-row__num,
  .book-row .chips,
  .book-row__actions { justify-content: center; }
  .book-row__blurb { margin-inline: auto; }

  .cta-band { grid-template-columns: 1fr; text-align: center; }
  .cta-band__cover { margin-inline: auto; }
  .cta-band .trust { justify-content: center; }
}

@media (max-width: 560px) {
  body { font-size: 1rem; }
  .wrap, .wrap--narrow { width: calc(100% - 2.25rem); }

  .signup { flex-direction: column; }
  .signup .btn { width: 100%; }
  .signup-card { padding: 0.9rem; border-radius: 22px; }

  .trust { gap: 0.4rem 1rem; font-size: 0.82rem; }

  .seal { width: 76px; right: -2%; }

  .fan { height: 270px; }
  .fan .cover { width: 140px; }
  .fan--single .cover { width: 165px; }
  .series-feature__art { min-height: 290px; }

  .shop-band { flex-direction: column; align-items: flex-start; }
  .site-footer__top { grid-template-columns: 1fr; }
  .site-footer__bottom { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
}

/* Dark cards sitting inside paper sections keep their firelit type */
.paper .series-feature h3,
.paper .cta-band h3 { color: var(--on-dark); }
.paper .series-feature h3 em,
.paper .cta-band h3 em { color: var(--amber-hi); }
.paper .series-feature p,
.paper .cta-band p { color: var(--on-dark-2); }
.paper .series-feature .eyebrow { color: var(--amber); }
.paper .series-feature .chips li { border-color: rgba(246, 236, 216, 0.16); color: var(--on-dark-2); background: rgba(246, 236, 216, 0.04); }
.hero h1 { font-size: clamp(2.8rem, 5.4vw, 4.7rem); }
