/* =========================================================
   The Child I Was, The Adult I Became — Kossiwa Kougblenou
   Palette: black, aged brown, worn gold, cream white
   ========================================================= */

:root {
  --black: #0b0806;
  --ink: #120d09;
  --brown-900: #1a120c;
  --brown-800: #241810;
  --brown-700: #352416;
  --brown-500: #6b4a2e;
  --gold: #c9a35c;
  --gold-light: #e3c88f;
  --gold-dim: #8f7240;
  --cream: #efe4cf;
  --cream-dim: #bfb19a;
  --white: #faf6ee;
  /* the same colours as r, g, b lists, for translucent tints */
  --gold-rgb: 201, 163, 92;
  --gold-light-rgb: 227, 200, 143;
  --black-rgb: 11, 8, 6;

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --caps: "Cinzel", "Cormorant Garamond", Georgia, serif;

  --max: 1180px;
  --narrow: 760px;
  --gutter: 40px;
  --ease: cubic-bezier(.2, .7, .2, 1);

  /* film grain to echo the aged cover texture */
  --grain: 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='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.9 0 0 0 0 0.8 0 0 0 0 0.6 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

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

html { scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
html:not(.js-anim) { scroll-behavior: smooth; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
html.menu-open { overflow: hidden; }
/* WordPress toolbar for logged-in users */
.admin-bar .nav { top: 32px; }
@media (max-width: 782px) { .admin-bar .nav { top: 46px; } }
@media (max-width: 600px) { .admin-bar .nav.is-scrolled { top: 0; } }

body {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.2rem;
  line-height: 1.75;
  color: var(--cream);
  background: var(--black);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background-image: var(--grain);
  pointer-events: none;
  z-index: 90;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold-light); text-decoration: none; }
em { font-style: italic; }
p { margin: 0 0 1.2em; }
::selection { background: var(--gold); color: var(--black); }
:focus-visible { outline: 1px solid var(--gold-light); outline-offset: 4px; }

main, .footer { position: relative; z-index: 2; }
main { overflow-x: clip; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: calc(var(--narrow) + var(--gutter) * 2); text-align: center; }
.muted { color: var(--cream-dim); }

/* ---------- WebGL background ---------- */
.bg {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
  pointer-events: none;
}
.no-webgl body, .kk-nobg body, body.kk-static {
  background:
    radial-gradient(ellipse at 70% 20%, rgba(107, 74, 46, .35), transparent 60%),
    radial-gradient(ellipse at 20% 80%, rgba(53, 36, 22, .5), transparent 55%),
    var(--black);
  background-attachment: fixed;
}

/* ---------- Loader (first visit) ---------- */
.loader { display: none; }
.js-anim:not(.kk-return):not(.kk-plain) .loader {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 24px;
  background: var(--black);
}
.loader__text {
  margin: 0;
  text-align: center;
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.6rem, 6vw, 2.4rem);
  color: var(--cream);
  animation: candle 3s ease-in-out infinite, loaderIn 1.4s var(--ease) both;
}
@keyframes loaderIn { from { opacity: 0; filter: blur(10px); } to { opacity: 1; filter: blur(0); } }
.loader__bar { width: 160px; height: 1px; background: rgba(var(--gold-rgb), .18); overflow: hidden; }
.loader__bar span { display: block; height: 100%; background: var(--gold); transform: scaleX(0); transform-origin: left; }

@keyframes candle {
  0%, 100% { opacity: 1; text-shadow: 0 0 18px rgba(var(--gold-light-rgb), .25); }
  45% { opacity: .86; text-shadow: 0 0 10px rgba(var(--gold-light-rgb), .12); }
  55% { opacity: .95; text-shadow: 0 0 22px rgba(var(--gold-light-rgb), .3); }
}

/* ---------- Page-transition curtain ---------- */
.curtain {
  position: fixed;
  inset: 0;
  z-index: 280;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--black);
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}
.js-anim.kk-return .curtain { visibility: visible; opacity: 1; }
.curtain__glow {
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  box-shadow: 0 0 30px rgba(var(--gold-rgb), .6);
}
.curtain__label {
  position: relative;
  margin: 0;
  padding: 0 24px;
  text-align: center;
  font-family: var(--caps);
  font-size: clamp(1.4rem, 4vw, 2.4rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold-light);
}

/* ---------- Cursor + progress ---------- */
.cursor { display: none; }
@media (hover: hover) and (pointer: fine) {
  .js-anim .cursor { display: block; }
  .cursor span {
    position: fixed;
    top: 0; left: 0;
    z-index: 250;
    pointer-events: none;
    border-radius: 50%;
    opacity: 0;
    transition: opacity .3s;
    will-change: transform;
  }
  .cursor.is-active span { opacity: 1; }
  .cursor__dot { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--gold-light); }
  .cursor__ring {
    width: 38px; height: 38px;
    margin: -19px 0 0 -19px;
    border: 1px solid rgba(var(--gold-light-rgb), .45);
    transition: opacity .3s, width .35s var(--ease), height .35s var(--ease), margin .35s var(--ease), background .35s, border-color .35s;
  }
  .cursor.is-hover .cursor__ring {
    width: 70px; height: 70px;
    margin: -35px 0 0 -35px;
    background: rgba(var(--gold-rgb), .08);
    border-color: rgba(var(--gold-light-rgb), .8);
  }
}
.progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  z-index: 70;
  background: linear-gradient(90deg, var(--gold-dim), var(--gold-light));
  transform: scaleX(0);
  transform-origin: left;
  pointer-events: none;
}

/* ---------- Shared type ---------- */
.eyebrow {
  display: block;
  font-family: var(--caps);
  font-size: .76rem;
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.section__title {
  font-family: var(--caps);
  font-weight: 400;
  font-size: clamp(1.8rem, 4vw, 2.9rem);
  line-height: 1.2;
  letter-spacing: .03em;
  color: var(--white);
  margin: 0 0 .4rem;
  overflow-wrap: break-word;
}
.section__title em { font-family: var(--serif); text-transform: none; color: var(--gold-light); letter-spacing: 0; }
.lead {
  font-size: clamp(1.3rem, 2.4vw, 1.6rem);
  font-style: italic;
  font-weight: 300;
  color: var(--gold-light);
  line-height: 1.55;
}

/* split text */
.w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .1em; margin-bottom: -.1em; }
.wi, .ch { display: inline-block; will-change: transform; }

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 1.4rem auto 2rem;
  color: var(--gold);
  font-size: .8rem;
}
.divider span { width: 70px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold-dim), transparent); }
.divider i { font-style: normal; }
.divider--left { justify-content: flex-start; }
.divider--left span { background: linear-gradient(90deg, var(--gold-dim), transparent); }

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-block;
  font-family: var(--caps);
  font-size: .78rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  text-align: center;
  padding: 16px 30px;
  border: 1px solid var(--gold);
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: color .45s var(--ease), border-color .45s var(--ease);
}
.btn span { position: relative; z-index: 1; }
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform .5s var(--ease);
}
.btn:hover::before { transform: scaleY(1); }
.btn--gold { background: var(--gold); color: var(--black); }
.btn--gold::before { background: var(--gold-light); }
.btn--ghost { background: rgba(var(--black-rgb), .3); color: var(--gold-light); }
.btn--ghost::before { background: var(--gold); }
.btn--ghost:hover { color: var(--black); }
.btn--text {
  background: none;
  border: none;
  border-bottom: 1px solid var(--gold-dim);
  padding: 4px 0;
  color: var(--gold);
  margin-top: .6rem;
}
.btn--text::before { display: none; }
.btn--text:hover { color: var(--gold-light); border-color: var(--gold-light); }

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px var(--gutter);
  border-bottom: 1px solid transparent;
  transition: background .4s var(--ease), padding .4s var(--ease), border-color .4s, transform .5s var(--ease);
}
.nav.is-scrolled {
  background: rgba(var(--black-rgb), .85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding-top: 14px;
  padding-bottom: 14px;
  border-color: rgba(var(--gold-rgb), .15);
}
.nav.is-hidden { transform: translateY(-100%); }
.menu-open .nav { background: transparent; border-color: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; transform: none; }
.nav__brand {
  flex-shrink: 0;
  font-family: var(--caps);
  letter-spacing: .2em;
  font-size: .86rem;
  text-transform: uppercase;
  color: var(--cream);
  white-space: nowrap;
}
.nav__links { display: flex; align-items: center; gap: 28px; }
.nav__links a {
  position: relative;
  font-family: var(--caps);
  font-size: .72rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--cream-dim);
  white-space: nowrap;
  transition: color .3s;
}
.nav__links a:not(.nav__cta)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .45s var(--ease);
}
.nav__links a:hover, .nav__links a[aria-current="page"] { color: var(--gold-light); }
.nav__links a:hover::after, .nav__links a[aria-current="page"]::after { transform: scaleX(1); transform-origin: left; }
.nav__links .nav__cta {
  display: inline-block;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
  padding: 9px 18px;
  transition: background .3s, color .3s;
}
.nav__links .nav__cta:hover { background: var(--gold); color: var(--black); }

.nav__toggle {
  display: none;
  flex-shrink: 0;
  background: none;
  border: none;
  width: 40px; height: 40px;
  margin-right: -6px;
  position: relative;
  cursor: pointer;
}
.nav__toggle span {
  position: absolute;
  left: 8px; right: 8px;
  height: 1px;
  background: var(--gold-light);
  transition: transform .4s var(--ease), top .4s var(--ease);
}
.nav__toggle span:first-child { top: 15px; }
.nav__toggle span:last-child { top: 24px; }
.nav__toggle[aria-expanded="true"] span:first-child { top: 20px; transform: rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:last-child { top: 20px; transform: rotate(-45deg); }

/* ---------- Full-screen menu (tablet + mobile) ---------- */
.menu {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 34px;
  padding: 100px 32px 40px;
  background:
    radial-gradient(ellipse at 80% 10%, rgba(107, 74, 46, .35), transparent 60%),
    var(--black);
  clip-path: circle(0% at calc(100% - 40px) 40px);
  visibility: hidden;
  transition: clip-path .8s var(--ease), visibility 0s .8s;
  overflow-y: auto;
}
.menu.is-open { clip-path: circle(150% at calc(100% - 40px) 40px); visibility: visible; transition: clip-path .8s var(--ease); }
.menu__links { display: flex; flex-direction: column; gap: 6px; }
.menu__links a {
  display: flex;
  align-items: baseline;
  gap: 18px;
  padding: 6px 0;
  font-family: var(--caps);
  font-size: clamp(1.6rem, 6.5vw, 2.6rem);
  letter-spacing: .06em;
  color: var(--cream);
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .5s, transform .6s var(--ease), color .3s;
}
.menu.is-open .menu__links a { opacity: 1; transform: none; }
.menu.is-open .menu__links a:nth-child(1) { transition-delay: .18s; }
.menu.is-open .menu__links a:nth-child(2) { transition-delay: .24s; }
.menu.is-open .menu__links a:nth-child(3) { transition-delay: .30s; }
.menu.is-open .menu__links a:nth-child(4) { transition-delay: .36s; }
.menu.is-open .menu__links a:nth-child(5) { transition-delay: .42s; }
.menu__links a[aria-current="page"], .menu__links a:hover { color: var(--gold-light); }
.menu__num { font-family: var(--serif); font-style: italic; font-size: 1rem; color: var(--gold-dim); letter-spacing: 0; }
.menu__cta { align-self: flex-start; }
.menu__foot { margin: 0; color: var(--gold-dim); }

/* ---------- Home hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 110px 0 80px;
}
.hero__inner {
  position: relative;
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: 40px;
  align-items: center;
}
.hero__title, .page-hero__title {
  font-family: var(--caps);
  font-weight: 400;
  font-size: clamp(2.2rem, 4.4vw, 3.9rem);
  line-height: 1.12;
  letter-spacing: .02em;
  color: var(--white);
  margin: 0;
  perspective: 600px;
}
.hero__line { display: block; }
.hero__line--gold { color: var(--gold-light); text-shadow: 0 0 40px rgba(var(--gold-rgb), .25); }
.hero__sub, .page-hero__sub {
  font-size: clamp(1.3rem, 2.6vw, 1.9rem);
  color: var(--cream-dim);
  margin: 1rem 0 0;
  font-weight: 300;
  animation: candle 4s ease-in-out infinite;
}
.hero .divider { margin: 1.6rem 0; }
.hero__tag { font-size: 1.22rem; color: var(--cream-dim); font-style: italic; max-width: 460px; }
.hero__actions { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 2rem; }

.hero__cover { display: flex; flex-direction: column; align-items: center; min-width: 0; }
.book-stage {
  position: relative;
  width: min(460px, 100%);
  aspect-ratio: 4 / 5;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.book-stage__img {
  position: absolute;
  left: 50%; top: 50%;
  width: 62%;
  transform: translate(-50%, -52%) perspective(1400px) rotateY(-10deg);
  box-shadow: 0 40px 80px rgba(0, 0, 0, .7), 0 0 0 1px rgba(var(--gold-rgb), .15);
  transition: opacity .8s var(--ease);
}
.book-stage__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s var(--ease);
}
.book-stage.is-ready .book-stage__img { opacity: 0; }
.book-stage.is-ready .book-stage__canvas { opacity: 1; }
.book-stage__shadow {
  position: absolute;
  left: 22%; right: 22%;
  bottom: 8%;
  height: 8%;
  background: radial-gradient(ellipse at center, rgba(0, 0, 0, .75), transparent 70%);
  filter: blur(6px);
  z-index: -1;
}
.hero__hint {
  margin: .6rem 0 0;
  font-family: var(--caps);
  font-size: .66rem;
  letter-spacing: .28em;
  text-transform: uppercase;
  text-align: center;
  color: var(--gold-dim);
}
.hint-touch { display: none; }
@media (hover: none) { .hint-desk { display: none; } .hint-touch { display: inline; } }
.no-webgl .hero .hero__hint, .kk-nobook .hero .hero__hint { display: none; }
.kk-nocursor .cursor { display: none !important; }

.hero__scroll {
  position: absolute;
  bottom: 28px; left: 50%;
  margin-left: -12px;
  width: 24px; height: 40px;
  border: 1px solid var(--gold-dim);
  border-radius: 12px;
}
.hero__scroll span {
  position: absolute;
  top: 8px; left: 50%;
  width: 2px; height: 8px;
  margin-left: -1px;
  background: var(--gold);
  border-radius: 1px;
  animation: scroll 2.2s ease-in-out infinite;
}
@keyframes scroll {
  0% { opacity: 0; transform: translateY(0); }
  40% { opacity: 1; }
  100% { opacity: 0; transform: translateY(14px); }
}

/* ---------- Inner page hero ---------- */
.page-hero {
  position: relative;
  min-height: 78vh;
  min-height: 78svh;
  display: flex;
  align-items: center;
  padding: 140px 0 110px;
  text-align: center;
  overflow: hidden;
}
.page-hero__inner { position: relative; }
.page-hero__title { font-size: clamp(2.2rem, 6vw, 4.6rem); }
.page-hero .divider { margin-bottom: 0; }
.page-hero__ghost {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--caps);
  font-size: clamp(7rem, 26vw, 22rem);
  line-height: 1;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(var(--gold-rgb), .09);
  pointer-events: none;
  user-select: none;
}

/* ---------- Sections ---------- */
.section { padding: 130px 0; position: relative; }
.section--tight { padding-top: 40px; }

/* Home teasers */
.teasers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; perspective: 1000px; }
.teaser {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 48px 42px;
  min-height: 300px;
  border: 1px solid rgba(var(--gold-rgb), .2);
  background: linear-gradient(160deg, rgba(53, 36, 22, .6), rgba(18, 13, 9, .8));
  overflow: hidden;
  transition: border-color .4s;
}
.teaser::before, .theme::before, .buy__card::before, .word::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(280px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--gold-rgb), .16), transparent 70%);
  opacity: 0;
  transition: opacity .4s;
  pointer-events: none;
}
.teaser:hover, .theme:hover, .buy__card:hover, .word:hover { border-color: rgba(var(--gold-rgb), .5); }
.teaser:hover::before, .theme:hover::before, .buy__card:hover::before, .word:hover::before { opacity: 1; }
.teaser .eyebrow { margin: 0; }
.teaser__title { font-family: var(--caps); font-size: clamp(1.5rem, 2.6vw, 2rem); color: var(--white); line-height: 1.2; }
.teaser__text { font-style: italic; color: var(--cream-dim); flex: 1; }
.teaser__more { font-family: var(--caps); font-size: .74rem; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); }
.teaser__more i { display: inline-block; font-style: normal; transition: transform .4s var(--ease); }
.teaser:hover .teaser__more i { transform: translateX(8px); }

/* Themes */
.themes {
  margin-top: 30px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  perspective: 1000px;
}
.theme {
  position: relative;
  padding: 50px 34px;
  text-align: center;
  background: linear-gradient(160deg, rgba(53, 36, 22, .55), rgba(18, 13, 9, .75));
  border: 1px solid rgba(var(--gold-rgb), .18);
  transform-style: preserve-3d;
  transition: border-color .4s;
}
.theme__num { font-family: var(--caps); color: var(--gold-dim); font-size: .9rem; letter-spacing: .2em; }
.theme h3 {
  font-family: var(--caps);
  font-weight: 400;
  font-size: 1.35rem;
  letter-spacing: .12em;
  color: var(--gold-light);
  margin: .6rem 0 .8rem;
}
.theme p { color: var(--cream-dim); font-size: 1.08rem; margin: 0; }

/* ---------- Chapters by candlelight (home) ---------- */
.candle {
  --p: 0;          /* scroll progress through the section, 0 to 1 */
  --gy: 50%;       /* glow position */
  --gx: 50%;
  position: relative;
  padding: 150px 0 160px;
  overflow: hidden;
  isolation: isolate;
}
/* the darkness lifts as you read. Both layers fade in and out over a tall
   band at the top and bottom, so the section has no visible edge. */
.candle__veil, .candle__glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 260px, #000 calc(100% - 260px), transparent);
  mask-image: linear-gradient(180deg, transparent, #000 260px, #000 calc(100% - 260px), transparent);
}
.candle__veil {
  z-index: -2;
  background: rgba(6, 4, 3, calc(.82 - var(--p) * .5));
}
.candle__glow {
  z-index: -1;
  background: radial-gradient(560px circle at var(--gx) var(--gy), rgba(227, 170, 90, calc(.10 + var(--p) * .1)), rgba(201, 140, 70, .045) 40%, rgba(201, 140, 70, .015) 60%, transparent 78%);
}
.candle__head { margin-bottom: 70px; }
.candle__hint { color: var(--gold-dim); margin: 1rem 0 0; }

.candle__body {
  position: relative;
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 var(--gutter) 0 calc(var(--gutter) + 90px);
}
@media (hover: hover) and (pointer: fine) {
  .candle__body { padding-left: calc(var(--gutter) + 20px); }
}
.candle__list { list-style: none; margin: 0; padding: 0; counter-reset: none; }

.cl {
  --lit: 1;  /* set per line by js: 0 = in the dark, 1 = in the light */
  position: relative;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 24px;
  padding: 30px 0;
}
/* soft separator that fades out at both ends instead of a hard rule */
.cl::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(var(--gold-rgb), calc(.04 + var(--lit) * .2)) 20%, rgba(var(--gold-rgb), calc(.02 + var(--lit) * .08)) 80%, transparent);
}
.cl__num {
  font-family: var(--caps);
  font-size: .95rem;
  letter-spacing: .1em;
  color: var(--gold);
  opacity: calc(.12 + var(--lit) * .88);
}
.cl__title {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.6rem, 4.2vw, 3.3rem);
  line-height: 1.15;
  color: color-mix(in srgb, #3a2a1c, var(--white) calc(var(--lit) * 100%));
  text-shadow: 0 0 calc(var(--lit) * 34px) rgba(var(--gold-light-rgb), calc(var(--lit) * .5));
  filter: blur(calc((1 - var(--lit)) * 2.5px));
  transform: translateX(calc((1 - var(--lit)) * -12px));
  will-change: transform, filter;
}
.cl__phase {
  font-family: var(--caps);
  font-size: .64rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--gold-light);
  opacity: calc(var(--lit) * .9);
}

/* The candle */
.flame { z-index: 5; }
.flame {
  --fy: 0px;
  position: absolute;
  left: calc(var(--gutter) + 20px);
  top: 0;
  width: 40px;
  height: 120px;
  transform: translateY(calc(var(--fy) - 60px));
  pointer-events: none;
}
.flame__halo {
  position: absolute;
  left: 50%; top: 24px;
  width: 160px; height: 160px;
  margin: -80px 0 0 -80px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 196, 110, .35), rgba(255, 160, 70, .08) 45%, transparent 70%);
  animation: halo 2.6s ease-in-out infinite;
}
.flame__outer, .flame__inner {
  position: absolute;
  left: 50%;
  border-radius: 50% 50% 50% 50% / 62% 62% 38% 38%;
  transform-origin: 50% 100%;
}
.flame__outer {
  top: 4px;
  width: 22px; height: 42px;
  margin-left: -11px;
  background: radial-gradient(ellipse at 50% 80%, #fff3c4 0%, #ffcc66 30%, #e88a2c 65%, rgba(200, 80, 20, 0) 100%);
  filter: blur(.6px);
  box-shadow: 0 0 22px 6px rgba(255, 170, 80, .45);
  animation: flicker 1.8s ease-in-out infinite;
}
.flame__inner {
  top: 22px;
  width: 9px; height: 20px;
  margin-left: -4.5px;
  background: radial-gradient(ellipse at 50% 70%, #fff, #fff4d6 50%, rgba(255, 230, 170, 0) 100%);
  animation: flicker 1.3s ease-in-out infinite reverse;
}
.flame__wick { position: absolute; left: 50%; top: 42px; width: 2px; height: 8px; margin-left: -1px; background: #2a1a10; }
.flame__stick {
  position: absolute;
  left: 50%; top: 50px;
  width: 16px; height: 70px;
  margin-left: -8px;
  background: linear-gradient(90deg, #cdb98f, #f1e4c4 45%, #b49c6c);
  border-radius: 3px 3px 1px 1px;
  box-shadow: inset 0 6px 8px rgba(255, 200, 120, .35);
}
/* Mouse: the cursor becomes the candle inside this section */
.candle.is-cursor, .candle.is-cursor * { cursor: none; }
.candle.is-cursor .flame {
  position: fixed;
  left: 0; top: 0;
  transform: translate(calc(var(--cx, -100px) - 20px), calc(var(--cy, -100px) - 26px)) scale(.85);
  transform-origin: 20px 26px;
  opacity: 0;
  transition: opacity .35s;
}
.candle.is-cursor.has-pointer .flame { opacity: 1; }
.candle.is-cursor .flame__stick { height: 46px; }
.cursor.is-hidden span { opacity: 0 !important; }

@keyframes flicker {
  0%, 100% { transform: scale(1, 1) rotate(-1deg); }
  25% { transform: scale(.94, 1.06) rotate(1.5deg); }
  50% { transform: scale(1.04, .96) rotate(-2deg); }
  75% { transform: scale(.97, 1.04) rotate(1deg); }
}
@keyframes halo { 0%, 100% { opacity: .85; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }

.candle__end {
  margin: 80px 0 0;
  text-align: center;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--gold-light);
  opacity: calc(.2 + var(--p) * .8);
  animation: candle 3.5s ease-in-out infinite;
}

/* ---------- Quote band ---------- */
.quote-band { position: relative; padding: 150px 24px; text-align: center; }
.quote-band::before {
  content: "";
  position: absolute;
  left: 50%; top: 50%;
  width: min(900px, 100%);
  height: 70%;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at center, rgba(107, 74, 46, .35), transparent 70%);
  pointer-events: none;
}
.quote-band blockquote { position: relative; max-width: 900px; margin: 0 auto; }
.quote-band p {
  font-size: clamp(1.7rem, 4vw, 3rem);
  font-weight: 300;
  font-style: italic;
  line-height: 1.35;
  color: var(--white);
}
.qw { display: inline-block; }
.quote-band cite {
  font-family: var(--caps);
  font-style: normal;
  font-size: .74rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--gold);
}

/* ---------- Book page ---------- */
.book-detail {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: 80px;
  align-items: center;
}
.book-detail__cover { display: flex; flex-direction: column; align-items: center; }
.flip {
  display: block;
  width: min(380px, 100%);
  aspect-ratio: 2 / 3;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  perspective: 1600px;
}
.flip__inner {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 1.2s var(--ease);
}
.flip.is-flipped .flip__inner { transform: rotateY(180deg); }
.flip__face {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-shadow: 0 40px 80px rgba(0, 0, 0, .7), 0 0 0 1px rgba(var(--gold-rgb), .18);
}
.flip__face--back { transform: rotateY(180deg); }
.book-detail .hero__hint { margin-top: 1.2rem; }
.details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin: 2.2rem 0 0;
  background: rgba(var(--gold-rgb), .18);
  border: 1px solid rgba(var(--gold-rgb), .18);
}
.details div { padding: 18px 20px; background: rgba(18, 13, 9, .85); }
.details dt { font-family: var(--caps); font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: var(--gold); }
.details dd { margin: 4px 0 0; color: var(--cream); overflow-wrap: anywhere; }

/* ---------- Excerpt page ---------- */
.preface p {
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-style: italic;
  font-weight: 300;
  line-height: 1.45;
  color: var(--white);
  margin: 0 0 .5em;
}
.letter {
  position: relative;
  text-align: left;
  padding: 60px 64px 50px;
  background:
    var(--grain),
    linear-gradient(180deg, rgba(53, 36, 22, .82), rgba(26, 18, 12, .9));
  border: 1px solid rgba(var(--gold-rgb), .22);
  box-shadow: 0 40px 90px rgba(0, 0, 0, .55), inset 0 0 80px rgba(0, 0, 0, .35);
  transform-origin: center top;
}
.letter::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(var(--gold-rgb), .08);
  pointer-events: none;
}
.letter p { font-size: 1.25rem; color: var(--cream); }
.letter > p:first-of-type + p::first-letter {
  float: left;
  font-family: var(--caps);
  font-size: 3.6rem;
  line-height: .9;
  padding: 6px 10px 0 0;
  color: var(--gold);
}
.letter__salute { font-style: italic; color: var(--gold-light) !important; }
.letter__more { overflow: hidden; }
.letter__after { margin: 2.4rem 0 0; color: var(--gold-light); font-size: 1.35rem; }

/* ---------- Author page ---------- */
.author__grid {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 80px;
  align-items: center;
  max-width: 1120px;
}
.author__photo { position: relative; z-index: 0; }
.frame {
  position: relative;
  aspect-ratio: 4 / 5;
  background:
    var(--grain),
    radial-gradient(ellipse at 50% 40%, var(--brown-700), var(--black));
  border: 1px solid rgba(var(--gold-rgb), .3);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.author__photo::after {
  content: "";
  position: absolute;
  inset: -16px 16px 16px -16px;
  border: 1px solid var(--gold-dim);
  z-index: -1;
}
.frame img {
  position: absolute;
  inset: -8% 0;
  width: 100%;
  height: 116%;
  object-fit: cover;
  filter: sepia(.25) contrast(1.02) brightness(.95);
  z-index: 1;
}
.frame__mono { font-family: var(--caps); font-size: 4.5rem; letter-spacing: .1em; color: var(--gold-dim); }
.author__sign {
  font-style: italic;
  font-size: 1.4rem;
  color: var(--gold-light);
  border-left: 1px solid var(--gold);
  padding-left: 20px;
  margin-top: 2rem;
}
.words { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; perspective: 1000px; }
.word {
  position: relative;
  margin: 0;
  padding: 44px 34px;
  border: 1px solid rgba(var(--gold-rgb), .18);
  background: linear-gradient(160deg, rgba(53, 36, 22, .55), rgba(18, 13, 9, .75));
  transition: border-color .4s;
}
.word p { margin: 0; font-size: 1.35rem; font-style: italic; line-height: 1.5; color: var(--cream); }

/* ---------- Buy ---------- */
.buy__links {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 2.6rem 0 2rem;
  perspective: 900px;
}
.buy__card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 30px 18px;
  border: 1px solid rgba(var(--gold-rgb), .3);
  background: rgba(26, 18, 12, .75);
  transition: border-color .35s;
  overflow: hidden;
}
.buy__store { position: relative; font-family: var(--caps); letter-spacing: .14em; color: var(--white); font-size: 1rem; }
.buy__fmt { position: relative; font-style: italic; color: var(--gold); font-size: 1.05rem; }
.isbn { font-family: var(--caps); font-size: .76rem; letter-spacing: .25em; color: var(--gold); }

/* ---------- Contact page ---------- */
.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 60px;
  align-items: start;
}
.contact__info { display: grid; gap: 18px; }
.info {
  padding: 30px 30px 26px;
  border: 1px solid rgba(var(--gold-rgb), .18);
  background: linear-gradient(160deg, rgba(53, 36, 22, .5), rgba(18, 13, 9, .75));
}
.info__num { font-family: var(--caps); font-size: .8rem; letter-spacing: .2em; color: var(--gold-dim); }
.info h3 { margin: .3rem 0 .4rem; font-family: var(--caps); font-weight: 400; font-size: 1.2rem; letter-spacing: .1em; color: var(--gold-light); }
.info p { margin: 0; color: var(--cream-dim); font-size: 1.08rem; }

.form {
  display: grid;
  gap: 22px;
  padding: 44px 40px;
  border: 1px solid rgba(var(--gold-rgb), .2);
  background: linear-gradient(160deg, rgba(36, 24, 16, .75), rgba(var(--black-rgb), .85));
}
.form .eyebrow { margin: 0; }
.form__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.form label { display: grid; gap: 8px; min-width: 0; }
.form label span {
  font-family: var(--caps);
  font-size: .68rem;
  letter-spacing: .25em;
  text-transform: uppercase;
  color: var(--gold);
}
.form input, .form select, .form textarea {
  width: 100%;
  min-width: 0;
  font: inherit;
  font-size: 1.1rem;
  color: var(--cream);
  background: rgba(var(--black-rgb), .7);
  border: 1px solid rgba(var(--gold-rgb), .22);
  border-radius: 0;
  padding: 13px 16px;
  transition: border-color .3s, background .3s, box-shadow .3s;
  -webkit-appearance: none;
  appearance: none;
}
.form select {
  padding-right: 44px;
  background-image: linear-gradient(45deg, transparent 50%, var(--gold) 50%), linear-gradient(135deg, var(--gold) 50%, transparent 50%);
  background-position: calc(100% - 22px) 52%, calc(100% - 16px) 52%;
  background-size: 6px 6px;
  background-repeat: no-repeat;
}
.form select option { background: var(--brown-900); }
.form input:focus, .form select:focus, .form textarea:focus {
  outline: none;
  border-color: var(--gold);
  background-color: rgba(36, 24, 16, .9);
  box-shadow: 0 0 0 4px rgba(var(--gold-rgb), .08), 0 0 30px rgba(var(--gold-rgb), .1);
}
.form textarea { resize: vertical; }
.form .btn { justify-self: start; }
.form__note { margin: 0; font-style: italic; color: var(--gold-light); min-height: 1.5em; }

/* ---------- Plain content pages (WordPress) ---------- */
.entry { text-align: left; }
.entry > * + * { margin-top: 1.2em; }
.entry h2, .entry h3 { font-family: var(--caps); font-weight: 400; color: var(--white); letter-spacing: .03em; }
.entry a { border-bottom: 1px solid var(--gold-dim); }
.entry img { margin: 2em auto; }
.entry blockquote { margin: 2em 0; padding-left: 24px; border-left: 1px solid var(--gold); font-style: italic; color: var(--gold-light); }

/* ---------- Closing CTA ---------- */
.cta { position: relative; padding: 110px 0 120px; background: linear-gradient(90deg, transparent, rgba(var(--gold-rgb), .16) 50%, transparent) top / 100% 1px no-repeat; }
.cta::before {
  content: "";
  position: absolute;
  left: 50%; top: 0;
  width: min(800px, 100%);
  height: 100%;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at 50% 30%, rgba(var(--gold-rgb), .1), transparent 65%);
  pointer-events: none;
}
.cta__title {
  position: relative;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 1.3;
  color: var(--white);
  margin: 0 0 2.2rem;
}
.cta__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }

/* ---------- Footer ---------- */
.footer {
  padding: 70px 0 40px;
  background:
    linear-gradient(90deg, transparent, rgba(var(--gold-rgb), .18) 50%, transparent) top / 100% 1px no-repeat,
    linear-gradient(180deg, rgba(var(--black-rgb), 0), rgba(var(--black-rgb), .9) 45%);
}
.footer__inner {
  max-width: var(--max);
  margin: 0 auto 40px;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: 1.2fr 1fr auto;
  gap: 40px;
  align-items: start;
}
.footer__title { font-family: var(--caps); letter-spacing: .08em; color: var(--cream); margin: 0; font-size: 1.05rem; line-height: 1.5; }
.footer__sub { color: var(--gold); margin: .3rem 0 0; }
.footer__links { display: grid; grid-template-columns: repeat(2, auto); justify-content: start; gap: 10px 40px; }
.footer__links a {
  font-family: var(--caps);
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--cream-dim);
  transition: color .3s;
}
.footer__links a:hover, .footer__links a[aria-current="page"] { color: var(--gold-light); }
.footer__isbn { margin: 0; font-family: var(--caps); font-size: .7rem; letter-spacing: .2em; color: var(--gold-dim); }
.footer__copy {
  max-width: var(--max);
  margin: 0 auto;
  padding: 24px var(--gutter) 0;
  background: linear-gradient(90deg, transparent, rgba(var(--gold-rgb), .1) 50%, transparent) top / 100% 1px no-repeat;
  font-size: .95rem;
  color: var(--gold-dim);
}

@media (prefers-reduced-motion: reduce) {
  .hero__scroll span, .hero__sub, .page-hero__sub, .loader__text, .candle__end, .flame span { animation: none; }
  .menu, .menu__links a { transition: none; }
}

/* =========================================================
   Responsive
   ========================================================= */

/* Large laptops */
@media (max-width: 1280px) {
  :root { --gutter: 32px; }
  .nav__links { gap: 22px; }
}

/* Tablets landscape and below: hamburger menu */
@media (max-width: 1100px) {
  .nav__links { display: none; }
  .nav__toggle { display: block; }
  .book-detail, .author__grid { gap: 56px; }
  .contact__grid { gap: 40px; }
  .words { grid-template-columns: 1fr; max-width: 720px; margin: 0 auto; }
}

/* Short desktop screens: keep the hero compact */
@media (min-width: 961px) and (max-height: 760px) {
  .hero { padding: 96px 0 60px; }
  .book-stage { width: min(400px, 100%); }
  .hero__scroll { display: none; }
}

/* Tablets portrait */
@media (max-width: 960px) {
  .hero { min-height: auto; padding: 100px 0 80px; }
  .hero__inner { grid-template-columns: 1fr; text-align: center; gap: 14px; }
  .hero .divider { justify-content: center; }
  .hero .divider--left span { background: linear-gradient(90deg, transparent, var(--gold-dim), transparent); }
  .hero__tag { margin-left: auto; margin-right: auto; }
  .hero__actions { justify-content: center; }
  .hero__cover { order: -1; }
  .book-stage { width: min(380px, 78vw); }
  .hero__scroll { display: none; }

  .page-hero { min-height: 60vh; min-height: 60svh; padding: 130px 0 80px; }
  .page-hero .hero__scroll { display: none; }

  .book-detail, .author__grid, .contact__grid { grid-template-columns: 1fr; }
  .book-detail__text, .author__text { text-align: center; }
  .book-detail .divider--left, .author .divider--left { justify-content: center; }
  .book-detail .divider--left span, .author .divider--left span { background: linear-gradient(90deg, transparent, var(--gold-dim), transparent); }
  .flip { width: min(320px, 70vw); }
  .author__photo { max-width: 300px; margin: 0 auto; width: 100%; }
  .author__sign { border-left: none; padding-left: 0; }
  .details { text-align: left; }

  .footer__inner { grid-template-columns: 1fr 1fr; }
  .footer__isbn { grid-column: 1 / -1; }
}

/* Phones */
@media (max-width: 760px) {
  :root { --gutter: 20px; }
  body { font-size: 1.12rem; }
  .nav, .nav.is-scrolled { padding-top: 14px; padding-bottom: 14px; }
  .nav { background: rgba(var(--black-rgb), .7); }
  .nav__brand { font-size: .74rem; letter-spacing: .14em; }

  .hero { padding: 84px 0 64px; }
  .hero__title { font-size: clamp(1.75rem, 8.4vw, 2.6rem); }
  .page-hero__title { font-size: clamp(2rem, 10vw, 3rem); }
  .book-stage { width: min(320px, 84vw); }
  .hero__actions .btn, .cta__actions .btn { flex: 1 1 220px; }
  .btn { padding: 15px 22px; }

  .section { padding: 90px 0; }
  .section--tight { padding-top: 20px; }
  .teasers, .themes { grid-template-columns: 1fr; }
  .teaser { padding: 36px 26px; min-height: 0; }
  .theme { padding: 36px 24px; }
  .quote-band { padding: 100px 20px; }

  .letter { padding: 40px 22px 34px; }
  .letter p { font-size: 1.15rem; }
  .letter > p:first-of-type + p::first-letter { font-size: 3rem; }

  .details { grid-template-columns: 1fr; }
  .buy__links { grid-template-columns: 1fr; }
  .form { padding: 30px 22px; }
  .form__row { grid-template-columns: 1fr; }
  .form .btn { justify-self: stretch; }
  .word { padding: 34px 26px; }

  .candle { padding: 100px 0 110px; }
  .candle__head { margin-bottom: 40px; }
  .candle__body { padding-left: calc(var(--gutter) + 44px); }
  .flame { left: calc(var(--gutter) - 6px); transform: translateY(calc(var(--fy) - 60px)) scale(.8); }
  .cl { grid-template-columns: minmax(0, 1fr); gap: 4px; padding: 22px 0; }
  .cl__phase { order: -1; }
  .cl__num { display: none; }
  .cta { padding: 90px 0 100px; }
  .footer__inner { grid-template-columns: 1fr; gap: 28px; margin-bottom: 28px; }
}

/* Small phones */
@media (max-width: 380px) {
  .nav__brand { font-size: .68rem; letter-spacing: .1em; }
  .eyebrow { letter-spacing: .24em; }
  .footer__links { gap: 10px 24px; }
}
