:root {
  --bg: #fbfaf7;
  --bg-alt: #f2efe8;
  --ink: #1c1d21;
  --muted: #5d6068;
  --rule: #ddd8cc;
  --accent: #1f3a5f;
  --accent-ink: #ffffff;
  --brass: #a9803a;
  --serif: "Fraunces", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --max: 1080px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14161a;
    --bg-alt: #1b1e23;
    --ink: #ecebe6;
    --muted: #a3a6ad;
    --rule: #2e3239;
    --accent: #9cb8e0;
    --accent-ink: #10131a;
    --brass: #c9a25e;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--accent); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.15; margin: 0 0 .6em; }
h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.25rem; margin-top: 2rem; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 32px; } }

.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; background: var(--bg); padding: 8px; z-index: 10; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 5;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { font-family: var(--serif); font-weight: 600; font-size: 1.2rem; color: var(--ink); text-decoration: none; }
.nav nav { display: flex; gap: 20px; }
.nav nav a { color: var(--muted); text-decoration: none; font-size: .95rem; font-weight: 500; }
.nav nav a:hover { color: var(--ink); }
@media (max-width: 520px) { .nav nav { gap: 12px; } .nav nav a { font-size: .85rem; } }

/* Hero */
.hero { padding: 72px 0 64px; }
.hero-grid { display: grid; gap: 40px; align-items: center; }
@media (min-width: 820px) { .hero-grid { grid-template-columns: 1.15fr 1fr; gap: 56px; } }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; font-weight: 600; color: var(--muted); margin: 0 0 12px; }
.lede { font-size: 1.2rem; color: var(--muted); max-width: 34em; }
.portrait {
  width: 100%; height: auto; max-width: 480px; aspect-ratio: 1000 / 1079; object-fit: cover; align-self: center;
  border-radius: 4px; justify-self: center;
  box-shadow: 0 20px 40px -20px rgba(0,0,0,.35);
}

.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.btn {
  display: inline-block; padding: 12px 22px; border-radius: 3px;
  background: var(--accent); color: var(--accent-ink); border: 1px solid var(--accent);
  font: 600 .95rem var(--sans); text-decoration: none; cursor: pointer;
}
.btn-ghost { background: transparent; color: var(--accent); }

/* Sections */
.section { padding: 80px 0; border-top: 1px solid var(--rule); }
.section.alt { background: var(--bg-alt); }
.two-col { display: grid; gap: 24px; }
@media (min-width: 820px) { .two-col { grid-template-columns: 1fr 2.2fr; gap: 64px; } }
.prose { max-width: 40em; }

.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { display: grid; grid-template-columns: 110px 1fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--rule); }
.timeline .when { color: var(--muted); font-size: .9rem; padding-top: 2px; }

/* Media */
.outlets { font-family: var(--serif); font-size: 1.15rem; color: var(--muted); margin-bottom: 1.5rem; }
.media-list { list-style: none; padding: 0; margin: 0; }
.media-list li {
  display: grid; gap: 2px 20px; padding: 14px 0; border-bottom: 1px solid var(--rule);
}
@media (min-width: 720px) {
  .media-list li { grid-template-columns: 120px 220px 1fr; align-items: baseline; }
}
.media-list .date { color: var(--muted); font-size: .88rem; }
.media-list .outlet { font-weight: 600; font-size: .92rem; }
.media-list a { text-decoration: none; }
.media-list a:hover { text-decoration: underline; }
.media-list:empty::after { content: "Coming soon."; color: var(--muted); display: block; padding: 12px 0; }

/* Book */
.book-hero { display: grid; gap: 40px; align-items: center; margin-bottom: 72px; }
@media (min-width: 820px) { .book-hero { grid-template-columns: 340px 1fr; gap: 72px; } }
.cover { width: 100%; max-width: 340px; justify-self: center; border-radius: 3px;
  box-shadow: 0 30px 50px -24px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.04); }
.book-title { font-size: clamp(2.4rem, 5vw, 3.4rem); margin-bottom: .1em; }
.book-sub { font-family: var(--serif); font-style: italic; font-size: 1.3rem; color: var(--muted); margin: 0 0 1.2em; }
.book-hook { font-family: var(--serif); font-size: 1.35rem; line-height: 1.4; border-left: 3px solid var(--brass); padding-left: 16px; }
.center { text-align: center; margin: 0 0 28px; }
.pillars { display: grid; gap: 16px; margin-bottom: 64px; }
@media (min-width: 720px) { .pillars { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.pillar { background: var(--bg-alt); border: 1px solid var(--rule); border-radius: 4px; padding: 28px 24px; }
.pillar svg { width: 48px; height: 48px; fill: var(--accent); margin-bottom: 12px; }
.pillar svg .lift { fill: var(--brass); }
.pillar svg .link { stroke: var(--brass); stroke-width: 2; fill: none; }
.pillar h4 { font-family: var(--serif); font-size: 1.2rem; margin: 0 0 6px; }
.pillar p { margin: 0; color: var(--muted); font-size: .96rem; }
.law { margin: 0 auto 72px; max-width: 760px; text-align: center; }
.law p { font-family: var(--serif); font-size: clamp(1.6rem, 3.4vw, 2.3rem); line-height: 1.25; margin: 0 0 12px; }
.law cite { font-style: normal; text-transform: uppercase; letter-spacing: .14em; font-size: .78rem; font-weight: 600; color: var(--muted); }
.arc { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; counter-reset: arc; }
.arc li { counter-increment: arc; }
.arc span { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border: 1px solid var(--rule);
  border-radius: 999px; font-size: .92rem; background: var(--bg); }
.arc span::before { content: counter(arc); font-weight: 600; font-size: .75rem; color: var(--brass); }

/* Contact */
.contact-form { display: grid; gap: 14px; margin: 20px 0 28px; }
.contact-form label { display: grid; gap: 6px; font-size: .9rem; font-weight: 500; }
.contact-form input, .contact-form textarea {
  font: inherit; padding: 10px 12px; border: 1px solid var(--rule); border-radius: 3px;
  background: var(--bg); color: var(--ink);
}
.contact-form button { justify-self: start; }
.social { list-style: none; padding: 0; display: flex; gap: 20px; }

/* Footer */
.site-footer { padding: 40px 0; border-top: 1px solid var(--rule); color: var(--muted); font-size: .85rem; }
.disclaimer { max-width: 60em; }
.more { margin-top: 24px; font-weight: 500; }
.media-list .date:empty::before { content: "—"; }

/* Reader (chapter excerpt) */
.progress { position: sticky; top: 60px; height: 3px; z-index: 4; }
.progress span { display: block; height: 100%; width: 0; background: var(--brass); }
.chapter { max-width: 680px; margin: 0 auto; padding: 72px 16px 40px; }
.chapter-head { text-align: center; margin-bottom: 48px; }
.chapter-head .eyebrow a { color: inherit; text-decoration: none; }
.chapter-head h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); margin-bottom: .2em; }
.byline { text-transform: uppercase; letter-spacing: .18em; font-size: .8rem; font-weight: 600; color: var(--muted); }
.chapter-body { font-family: var(--serif); font-size: 1.16rem; line-height: 1.75; }
.chapter-body p { margin: 0 0 1.2em; }
.chapter-body > p:first-of-type::first-letter { float: left; font-size: 3.6em; line-height: .85; padding: 6px 8px 0 0; font-weight: 600; color: var(--accent); }
.chapter-body h2 { font-size: 1.5rem; margin: 2.2em 0 .8em; }
.chapter-body sup { font-family: var(--sans); font-size: .62em; line-height: 0; }
.chapter-body sup a { text-decoration: none; padding: 0 1px; }
.props { font-weight: 600; padding-left: 1.4em; margin: 0 0 1.2em; }
.chapter-end { text-align: center; margin: 56px 0; padding: 40px 24px; background: var(--bg-alt); border: 1px solid var(--rule); border-radius: 4px; }
.chapter-end .book-hook { border: 0; padding: 0; margin: 0 0 24px; }
.chapter-end .btn { margin: 4px; }
.notes { border-top: 1px solid var(--rule); padding-top: 24px; font-size: .88rem; color: var(--muted); }
.notes h2 { font-size: 1.2rem; color: var(--ink); }
.notes ol { padding-left: 1.6em; }
.notes li { margin-bottom: .6em; overflow-wrap: anywhere; }
.notes li:target, .chapter-body sup a:target { background: color-mix(in srgb, var(--brass) 25%, transparent); }
.notes .back { text-decoration: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-status { margin: 0; font-size: .92rem; color: var(--muted); min-height: 1.4em; }
.book-hero.home { margin-bottom: 0; }
.book-page { border-top: 0; padding-top: 64px; }

/* Sign-in gate */
.gate { position: relative; margin-top: -140px; padding-top: 140px; }
.gate-fade { position: absolute; inset: 0 0 auto 0; height: 140px; background: linear-gradient(to bottom, transparent, var(--bg)); pointer-events: none; }
.gate-card { font-family: var(--sans); text-align: center; background: var(--bg-alt); border: 1px solid var(--rule); border-radius: 6px; padding: 36px 24px; }
.gate-card h3 { font-size: 1.5rem; margin: 0 0 10px; }
.gate-card p { font-size: 1rem; color: var(--muted); max-width: 30em; margin: 0 auto 20px; }
.btn-google { display: inline-flex; align-items: center; gap: 10px; background: #fff; color: #1f1f1f; border: 1px solid #c8c8c8; }
.btn-google:hover { background: #f5f5f5; }
.btn-google:disabled { opacity: .55; cursor: not-allowed; }
.gate-card .gate-fine { font-size: .82rem; margin: 16px auto 0; }
.gate-card .gate-status { font-size: .9rem; margin: 8px auto 0; min-height: 1.2em; }
[hidden] { display: none !important; }
.reader-bar { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 14px; font-family: var(--sans); font-size: .9rem; color: var(--muted); background: var(--bg-alt); border: 1px solid var(--rule); border-radius: 999px; padding: 8px 18px; margin: 8px auto 32px; width: fit-content; max-width: 100%; }
.linkish { background: none; border: 0; padding: 0; font: inherit; color: var(--accent); text-decoration: underline; cursor: pointer; }
.media-list .title { color: var(--ink); }
