:root {
  --ink: #09090b;
  --ink-2: #111116;
  --ink-3: #18181e;
  --paper: #f3ede2;
  --paper-dim: #cfc5b6;
  --gold: #b78c43;
  --gold-bright: #d3ad67;
  --gold-soft: rgba(211, 173, 103, .16);
  --line: rgba(211, 173, 103, .28);
  --line-soft: rgba(243, 237, 226, .10);
  --shadow: rgba(0,0,0,.48);
  --max: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--paper);
  background:
    radial-gradient(circle at 12% 0%, rgba(183,140,67,.11), transparent 34rem),
    linear-gradient(180deg, #101014 0%, var(--ink) 48rem, #08080a 100%);
  font-family: Georgia, 'Times New Roman', serif;
  line-height: 1.68;
}
a { color: inherit; }
img, svg { max-width: 100%; display: block; }
button { font: inherit; }

.skip-link { position: absolute; left: -999px; top: 0; padding: .7rem 1rem; background: var(--paper); color: var(--ink); z-index: 999; }
.skip-link:focus { left: .75rem; top: .75rem; }

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(9,9,11,.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  width: min(calc(100% - 2rem), var(--max)); margin: 0 auto;
  min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand { display: inline-flex; align-items: center; gap: .75rem; text-decoration: none; text-transform: uppercase; letter-spacing: .13em; font-size: .9rem; }
.brand img { width: 36px; height: 36px; }
.site-nav { display: flex; gap: 1.15rem; align-items: center; }
.site-nav a { text-decoration: none; color: var(--paper-dim); font-size: .94rem; }
.site-nav a:hover, .site-nav a[aria-current='page'] { color: var(--gold-bright); }
.menu-toggle { display: none; border: 1px solid var(--line); background: transparent; color: var(--paper); border-radius: 999px; padding: .5rem .85rem; }

main { min-height: 65vh; }
.container { width: min(calc(100% - 2rem), var(--max)); margin: 0 auto; }
.narrow { width: min(calc(100% - 2rem), 860px); margin: 0 auto; }

.eyebrow { color: var(--gold-bright); text-transform: uppercase; letter-spacing: .18em; font-size: .74rem; margin-bottom: 1.1rem; }
h1,h2,h3,h4 { font-weight: 500; line-height: 1.06; margin-top: 0; }
h1 { font-size: clamp(3.3rem, 8vw, 7rem); margin-bottom: 1.2rem; }
h2 { font-size: clamp(2.15rem, 5vw, 4rem); margin-bottom: 1rem; }
h3 { font-size: clamp(1.4rem, 2.4vw, 2rem); margin-bottom: .7rem; }
h4 { font-size: 1.15rem; }
p { margin-top: 0; }
.lede { font-size: clamp(1.16rem, 2.1vw, 1.45rem); color: var(--paper-dim); max-width: 48rem; }
.muted { color: var(--paper-dim); }
.small { font-size: .9rem; }

.hero { min-height: 74vh; border-bottom: 1px solid var(--line); display: grid; align-items: center; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, .9fr); gap: 4rem; align-items: center; padding: 5.5rem 0; }
.hero-copy h1 { max-width: 850px; }
.hero-covers { display: grid; grid-template-columns: repeat(3, 1fr); align-items: end; gap: .8rem; perspective: 1200px; }
.hero-covers a { transition: transform .2s ease; box-shadow: 0 1.8rem 4rem var(--shadow); }
.hero-covers a:nth-child(1) { transform: translateY(1.25rem) rotateY(4deg); }
.hero-covers a:nth-child(2) { transform: translateY(-.6rem); }
.hero-covers a:nth-child(3) { transform: translateY(1.25rem) rotateY(-4deg); }
.hero-covers a:hover { transform: translateY(-.85rem); }
.hero-covers img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border: 1px solid var(--line); }

.actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; text-decoration: none; border: 1px solid var(--gold); color: var(--ink); background: var(--gold-bright); padding: .78rem 1.08rem; border-radius: 999px; font-size: .9rem; letter-spacing: .03em; }
.button.secondary { color: var(--paper); background: transparent; border-color: var(--line); }
.button:hover { transform: translateY(-1px); }
.text-link { color: var(--gold-bright); text-decoration: none; }
.text-link:hover { text-decoration: underline; }

.section { padding: 5.3rem 0; border-bottom: 1px solid var(--line); }
.section.tight { padding: 3.6rem 0; }
.section-intro { color: var(--paper-dim); max-width: 48rem; margin-bottom: 2.4rem; }
.page-hero { padding: 6.4rem 0 4.3rem; border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: clamp(3rem, 7vw, 6rem); }

.grid-2 { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1.25rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1.1rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1rem; }
.card { border: 1px solid var(--line); background: linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,.008)); padding: 1.35rem; min-height: 100%; }
.card p { color: var(--paper-dim); }
.card .meta { color: var(--gold-bright); text-transform: uppercase; letter-spacing: .14em; font-size: .7rem; }

.cover-strip { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 1.2rem; align-items: start; }
.cover-card { text-decoration: none; display: block; }
.cover-card img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border: 1px solid var(--line); box-shadow: 0 1.5rem 3rem var(--shadow); }
.cover-card .caption { padding-top: 1rem; }
.cover-card .caption span { display:block; color:var(--gold-bright); text-transform:uppercase; letter-spacing:.14em; font-size:.68rem; margin-bottom:.35rem; }
.cover-card .caption strong { font-weight:500; font-size:1.25rem; }

.book-list { display: grid; gap: 5rem; }
.book-feature { display: grid; grid-template-columns: minmax(250px,.58fr) minmax(0,1.42fr); gap: 3.3rem; align-items: start; padding-bottom: 5rem; border-bottom: 1px solid var(--line); }
.book-feature:last-child { border-bottom: 0; padding-bottom: 0; }
.book-feature .cover-wrap { position: sticky; top: 100px; }
.book-feature .cover-wrap img { width: min(100%, 400px); aspect-ratio: 2/3; object-fit: cover; border: 1px solid var(--line); box-shadow: 0 1.8rem 4rem var(--shadow); }
.book-meta { display: flex; flex-wrap: wrap; gap: .45rem .9rem; padding: 1rem 0 1.2rem; color: var(--paper-dim); font-size: .9rem; }
.book-meta span::after { content: '•'; margin-left: .9rem; color: var(--gold); }
.book-meta span:last-child::after { content: ''; margin: 0; }
.book-blurb { color: var(--paper-dim); }
.book-blurb p { margin-bottom: 1rem; }
.book-hook { color: var(--paper); font-weight: 700; font-size: 1.12rem; }

.reading-order { list-style: none; padding: 0; margin: 0; }
.reading-order li { display: grid; grid-template-columns: 56px 1fr; gap: 1rem; align-items: center; border-top: 1px solid var(--line); padding: 1rem 0; }
.reading-order .num { color: var(--gold-bright); letter-spacing: .12em; }
.reading-order a { text-decoration: none; display: flex; justify-content: space-between; gap: 1rem; }
.reading-order small { color: var(--paper-dim); }

.world-map, .feature-art { border: 1px solid var(--line); box-shadow: 0 1.5rem 4rem var(--shadow); background:#0d0d10; }
.image-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1rem; }
.lightbox-link { cursor: zoom-in; }

.kingdom-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1rem; }
.kingdom-card h3 { color: var(--gold-bright); font-size: 1.45rem; }

.lore-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1rem; }
.lore-card { padding: 1.6rem; }
.lore-card h3 { color: var(--gold-bright); }

.divine-lineup { margin-bottom: 2rem; }
.divine-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1.25rem; }
.divine-card { border: 1px solid var(--line); background: #0e0e11; overflow: hidden; }
.divine-card a { display: block; text-decoration: none; }
.divine-card img { width: 100%; height: auto; display: block; object-fit: contain; background: #0e0e11; }
.divine-card.portrait img { width: 100%; height: auto; display: block; object-fit: contain; background: #0e0e11; }
.divine-card .divine-meta { padding: 1rem 1.1rem 1.2rem; display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; }
.divine-card .divine-meta strong { font-size: 1.25rem; font-weight: 500; }
.divine-card .divine-meta span { color: var(--gold-bright); font-size: .82rem; }

.coffin-notes { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:1rem; margin-top:2rem; }
.coffin-notes .card h3 { font-size:1.25rem; color:var(--gold-bright); }

.about-grid { display: grid; grid-template-columns: minmax(320px,.85fr) minmax(0,1.15fr); gap: 4rem; align-items: center; }
.about-portrait { border: 1px solid var(--line); box-shadow: 0 1.8rem 4rem var(--shadow); }
.about-portrait img { width: 100%; height: auto; }
.about-copy p { color: var(--paper-dim); font-size: 1.08rem; }
.about-copy .closing { color: var(--paper); font-style: italic; }

.notice { border-left: 2px solid var(--gold); padding: .15rem 0 .15rem 1rem; color: var(--paper-dim); }
.quote-line { font-size: clamp(1.65rem, 3.2vw, 2.6rem); line-height: 1.25; max-width: 900px; }

.site-footer { padding: 2.3rem 0; }
.footer-grid { display: flex; justify-content: space-between; gap: 2rem; color: var(--paper-dim); font-size: .9rem; }
.footer-links { display: flex; gap: 1rem; flex-wrap: wrap; }
.footer-links a { text-decoration: none; }
.footer-links a:hover { color: var(--gold-bright); }

.lightbox { position: fixed; inset: 0; z-index: 200; display:none; background:rgba(0,0,0,.93); padding:2rem; align-items:center; justify-content:center; }
.lightbox.open { display:flex; }
.lightbox img { max-width:min(96vw, 1500px); max-height:90vh; object-fit:contain; border:1px solid var(--line); }
.lightbox button { position:absolute; top:1rem; right:1rem; border:1px solid var(--line); background:#111116; color:var(--paper); border-radius:999px; width:42px; height:42px; cursor:pointer; }

.error-page { min-height: calc(100vh - 75px); display:grid; place-items:center; }
.error-wrap { max-width:760px; padding:4rem 1rem; }
.error-code { color:var(--gold-bright); letter-spacing:.25em; font-size:.8rem; }
.error-page h1 { font-size:clamp(4rem, 10vw, 8rem); margin:.75rem 0 1.5rem; }

@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: 3rem; }
  .hero-covers { max-width: 700px; }
  .grid-4 { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .kingdom-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .about-grid { grid-template-columns: 1fr; }
  .about-portrait { max-width: 700px; }
}

@media (max-width: 760px) {
  .menu-toggle { display:inline-block; }
  .site-nav { display:none; position:absolute; left:1rem; right:1rem; top:66px; flex-direction:column; align-items:stretch; gap:0; border:1px solid var(--line); background:#101014; padding:.5rem; }
  .site-nav.open { display:flex; }
  .site-nav a { padding:.8rem; }
  .hero { min-height:auto; }
  .hero-grid { padding:4rem 0; }
  .hero-covers { gap:.45rem; }
  .grid-2,.grid-3,.lore-grid,.divine-grid,.kingdom-grid,.coffin-notes { grid-template-columns:1fr; }
  .cover-strip { gap:.6rem; }
  .cover-card .caption strong { font-size:1rem; }
  .book-feature { grid-template-columns:1fr; gap:2rem; }
  .book-feature .cover-wrap { position:static; }
  .book-feature .cover-wrap img { max-width:360px; }
  .footer-grid { flex-direction:column; }
  .divine-card img { aspect-ratio:auto; }
}

@media (max-width: 520px) {
  .cover-strip { grid-template-columns:1fr; gap:2rem; }
  .cover-card img { max-width:340px; }
  .hero-covers { grid-template-columns: repeat(3, minmax(0,1fr)); }
  .hero-covers a:nth-child(1),.hero-covers a:nth-child(2),.hero-covers a:nth-child(3) { transform:none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior:auto; }
  *,*::before,*::after { animation:none!important; transition:none!important; }
}
