/* Phase 2B.8F: one publishing layout, one spacing and typography system. */
:root {
  color-scheme: dark;
  --ink: #101112;
  --surface: #191b1d;
  --paper: #f4f3ed;
  --muted: #b7b9bb;
  --gold: #dfb965;
  --rule: #36393b;
  --body: "Segoe UI", Arial, Helvetica, sans-serif;
  --display: var(--body);
  --content: 1400px;
  --gutter: clamp(20px, 4vw, 56px);
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 48px;
  --space-6: 64px;
  --section: clamp(64px, 7vw, 104px);
}
* { box-sizing: border-box; }
html { scroll-padding-top: 28px; }
body { margin: 0; background: var(--ink); color: var(--paper); font: 400 17px/1.65 var(--body); -webkit-font-smoothing: antialiased; }
[hidden] { display: none !important; }
img { max-width: 100%; }
a { color: inherit; text-underline-offset: 5px; }
button, select, input { font: inherit; }
a, button, select, summary { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 5px; }
p { margin: 0 0 20px; }
h1, h2, h3 { margin: 0 0 24px; font-weight: 700; line-height: 1.08; letter-spacing: -.035em; text-wrap: balance; }
h1 { font-size: clamp(48px, 6vw, 88px); }
h2 { font-size: clamp(34px, 3.6vw, 52px); }
h3 { font-size: clamp(26px, 2.7vw, 36px); }
.eyebrow { margin-bottom: 16px; color: var(--gold); font-size: 14px; line-height: 1.5; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; }
.muted, .fine-print, .status-note { color: var(--muted); }
.fine-print { font-size: 15px; line-height: 1.6; }
.skip { position: fixed; top: -100px; left: 20px; z-index: 100; padding: 12px 20px; background: var(--paper); color: var(--ink); }
.skip:focus { top: 12px; }
.masthead, .library-mode main, .site-footer { width: min(var(--content), calc(100% - var(--gutter) * 2)); margin-inline: auto; }
.masthead { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 104px; padding-block: 24px; border-bottom: 1px solid var(--rule); }
.publication { flex-shrink: 0; font-size: 26px; line-height: 1; font-weight: 800; letter-spacing: -.04em; text-decoration: none; }
.publication span { display: block; margin-top: 8px; font-size: 13px; font-weight: 500; letter-spacing: .22em; color: var(--gold); }
.masthead-caption { display: none; }
.masthead nav { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 28px; }
.masthead nav a { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; font-weight: 600; text-decoration: none; }
.masthead nav a:hover { color: var(--gold); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
button, .button { display: inline-flex; justify-content: center; align-items: center; gap: 8px; min-height: 48px; border: 1px solid var(--rule); border-radius: 4px; padding: 12px 20px; background: var(--surface); color: var(--paper); font-size: 15px; line-height: 1.4; font-weight: 650; text-decoration: none; cursor: pointer; }
.button.primary, #connect { background: var(--gold); color: #171717; border-color: var(--gold); }
button:hover, .button:hover { border-color: var(--paper); background: #26292c; }
.button.primary:hover, #connect:hover { background: #efd39a; border-color: #efd39a; }
button:disabled { background: transparent; color: var(--muted); cursor: not-allowed; border-color: var(--rule); }
.text-link { display: inline-flex; align-items: center; min-height: 48px; color: var(--paper); font-size: 15px; font-weight: 650; }
.text-link:hover { color: var(--gold); }
/* Hero: a single story and a single dominant cover. */
.edition-feature { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 48px; align-items: center; padding-block: var(--section); }
.edition-intro { grid-column: 1 / 7; }
.edition-intro h1 { max-width: 10ch; }
.hero-deck { max-width: 47ch; color: var(--muted); font-size: 19px; line-height: 1.65; margin-bottom: 32px; }
.edition-intro .actions { align-items: flex-start; flex-direction: column; gap: 10px; }
.edition-intro .button { min-height: 54px; padding-inline: 28px; }
.feature-note, .reading-resume { margin: 22px 0 0; font-size: 15px; color: var(--muted); }
.reading-resume:empty { display: none; }
.hero-art { grid-column: 8 / 13; margin: 0; width: 100%; max-width: 400px; justify-self: center; }
.cover-art { width: 100%; height: auto; display: block; object-fit: contain; }
.hero-art > a { display: block; }
.hero-art figcaption { padding-top: 16px; color: var(--muted); font-size: 14px; text-align: center; }
/* Edition shelf: two intentional full-size products, no thumbnail rows. */
.library-section { padding-block: var(--section); border-top: 1px solid var(--rule); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 32px; margin-bottom: 40px; }
.section-heading h2 { margin-bottom: 0; }
.section-heading > p { color: var(--muted); max-width: 35ch; margin: 0; }
.edition-covers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; }
.edition-book { min-width: 0; margin: 0; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .95fr); align-items: center; gap: 28px; }
.edition-book > a { display: block; }
.edition-book figcaption { min-width: 0; }
.edition-book h3 { font-size: 29px; margin-bottom: 16px; }
.edition-book p { color: var(--muted); font-size: 16px; }
.edition-book .eyebrow { color: var(--gold); font-size: 13px; }
.issue-row { display: block; text-decoration: none; }
.issue-row:hover .row-action { color: var(--gold); }
.issue-name { display: block; margin-bottom: 16px; font-size: 29px; line-height: 1.15; letter-spacing: -.03em; font-weight: 700; }
.issue-row small { display: block; color: var(--muted); font-size: 15px; }
.issue-synopsis { margin-top: 16px; }
.row-action { display: inline-flex; align-items: center; min-height: 48px; color: var(--paper); text-decoration: underline; text-underline-offset: 5px; font-size: 16px; font-weight: 650; }
.prelaunch-label { display: inline-block; color: var(--gold); font-size: 14px; margin: 0 0 16px; }
.edition-facts { margin: 40px 0 0; padding-top: 24px; border-top: 1px solid var(--rule); display: flex; gap: 20px 40px; flex-wrap: wrap; }
.edition-facts div { display: flex; gap: 12px; }
.edition-facts dt { color: var(--muted); }
.edition-facts dd { margin: 0; font-weight: 600; }
/* Collector feature and access are full-width sections, not nested boxes. */
.collector-archive { border-top: 1px solid var(--rule); }
.collector-archive > summary { cursor: pointer; padding-block: 24px; font-size: 16px; font-weight: 600; }
.collector-archive > summary span { color: var(--muted); margin-left: 20px; font-weight: 400; }
.vault { padding-block: var(--section); }
.archive-label { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 40px; color: var(--gold); font-size: 14px; font-weight: 600; }
.stamp { font-size: 13px; letter-spacing: .03em; color: var(--gold); }
.genesis-layout { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 5vw, 80px); align-items: start; }
.founders-display { width: 100%; max-width: 440px; margin: 0 auto; }
.collectible-cover img { display: block; width: 100%; height: auto; object-fit: contain; }
.founders-display figcaption { padding-top: 16px; color: var(--muted); font-size: 14px; }
.founders-editorial { min-width: 0; }
.founders-editorial h3 { font-size: clamp(36px, 4vw, 56px); }
.founders-editorial > p { color: var(--muted); }
.founders-editorial .edition-note { color: var(--paper); font-size: 20px; }
.policy-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 32px; margin: 32px 0; padding-block: 24px; border-block: 1px solid var(--rule); }
.holder-facts dt { font-size: 14px; color: var(--muted); margin-bottom: 5px; }
.holder-facts dd { margin: 0; font-size: 21px; font-weight: 650; overflow-wrap: anywhere; }
.genesis button[disabled] { margin-block: 16px; }
.collection-reference, .upgrade-disclosure, .edition-technical { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--rule); }
summary { min-height: 44px; align-content: center; }
.collection-reference summary, .upgrade-disclosure summary, .edition-technical summary { cursor: pointer; font-size: 16px; }
.collection-reference code { display: block; margin-block: 16px; overflow-wrap: anywhere; font-size: 14px; }
.upgrade-disclosure p, .edition-technical p { color: var(--muted); font-size: 16px; }
.wallet-reading-note { font-size: 16px; }
#holders { border-top: 1px solid var(--rule); }
.holder-marque { display: flex; gap: 24px; align-items: center; margin-bottom: 40px; }
.holder-marque img { width: 72px; height: 72px; object-fit: contain; flex-shrink: 0; }
.holder-marque h2 { margin: 0; }
.holder-marque .eyebrow { margin-bottom: 8px; }
.vault-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 80px); }
.holder-editorial p { max-width: 54ch; color: var(--muted); }
.holder-editorial h3 { font-size: 28px; }
.benefit-list { list-style: none; margin: 32px 0 0; padding: 0; }
.benefit-list li { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px 16px; padding-block: 12px; border-top: 1px solid var(--rule); font-size: 16px; }
.archive-lock { display: inline-flex; gap: 8px; align-items: center; font-size: 14px; color: var(--muted); }
.archive-lock svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.access-desk { min-width: 0; background: var(--surface); padding: 32px; border-radius: 8px; }
.access-heading .eyebrow { color: var(--paper); font-size: 20px; letter-spacing: 0; text-transform: none; margin-bottom: 8px; }
#collector-state-label { color: var(--muted); margin-bottom: 24px; }
.access-desk > p { color: var(--muted); font-size: 16px; }
.access-desk label { display: block; margin: 28px 0 8px; font-size: 15px; }
select { background: var(--ink); border: 1px solid #6e7275; border-radius: 4px; padding: 10px 12px; color: var(--paper); min-height: 48px; max-width: 100%; }
.access-desk select { width: 100%; }
.access-desk .actions { margin-block: 20px; gap: 12px; }
.access-desk button { flex: 1 1 190px; }
.status-note { font-size: 16px; overflow-wrap: anywhere; }
.eligibility-details { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--rule); }
.eligibility-details .holder-facts { display: grid; gap: 20px; }
.eligibility-details dd { font-size: 16px; font-weight: 500; }
.exclusive-content { margin-top: 40px; padding-top: 28px; border-top: 1px solid var(--rule); }
.exclusive-content h3 { font-size: 24px; }
.private-content:empty { display: none; }
#holders[data-display-state=verified] #holder-state { color: #9ed4a4; }
#holders[data-display-state=denied] #holder-state, #holders[data-display-state=unavailable] #holder-state { color: #efb6ab; }
.site-footer { display: grid; grid-template-columns: 1fr 2fr auto; gap: 32px; padding-block: 40px; border-top: 1px solid var(--rule); color: var(--muted); font-size: 14px; }
.site-footer p { margin-bottom: 12px; }
.footer-brand { color: var(--paper); font-size: 17px; font-weight: 700; text-decoration: none; }
.noscript-note { padding: 24px var(--gutter); }
/* Reader: retain the measured artwork canvas, simplify its surrounding chrome. */
.reading-mode .masthead { min-height: 80px; padding-block: 16px; }
.reading-mode main { width: 100%; padding: 0; }
.reader-heading { width: min(var(--content), calc(100% - var(--gutter)*2)); margin-inline: auto; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 24px; padding-block: 20px; }
.reader-heading h1 { font-size: 18px; line-height: 1.4; margin: 0; letter-spacing: 0; }
.reader-heading .eyebrow { font-size: 13px; margin: 0; }
.reader-back { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; }
.reader { position: relative; min-width: 0; background: #08090a; }
.reader .page-stage, .reader:fullscreen .page-stage { box-sizing: border-box; min-height: 0; height: calc(100svh - 250px); overflow: auto; padding: 16px; text-align: center; scrollbar-gutter: stable; overscroll-behavior-x: contain; touch-action: pan-y pinch-zoom; }
.reader .comic-image, .reader:fullscreen .comic-image, .reader .continuous-page { display: block; max-width: none; height: auto; object-fit: contain; margin: 0 auto; flex-shrink: 0; }
.reader .continuous-stage { padding-block: 16px; }
.reader .continuous-page { margin-bottom: 16px; }
.reader .continuous-page:last-child { margin-bottom: 0; }
.reader-dock { position: sticky; bottom: 0; z-index: 20; background: #181a1c; padding: 12px max(16px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 12px 24px; border-top: 1px solid var(--rule); }
.dock-group { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; min-width: 0; }
.reader-dock button { min-height: 44px; padding: 8px 12px; font-size: 14px; font-weight: 500; }
.reader-dock select { min-height: 44px; font-size: 14px; width: auto; max-width: 150px; }
.reader-dock label, .reader-dock output { font-size: 14px; }
.reader #zoom-label { min-width: 8ch; text-align: center; }
.reader #page-select { width: 65px; }
.page-position { margin: 0; white-space: nowrap; font-size: 14px; }
progress { display: block; appearance: none; width: 100%; height: 4px; border: 0; color: var(--gold); background: var(--rule); accent-color: var(--gold); }
progress::-webkit-progress-bar { background: var(--rule); }
progress::-webkit-progress-value { background: var(--gold); }
progress::-moz-progress-bar { background: var(--gold); }
.page-browser { width: min(var(--content), calc(100% - var(--gutter)*2)); margin-inline: auto; padding-top: 16px; }
.page-browser summary { cursor: pointer; font-size: 15px; }
.page-thumbnails { display: grid; grid-template-columns: repeat(auto-fit, minmax(80px, 1fr)); gap: 12px; padding-block: 16px 24px; }
.page-thumbnail { display: block; min-width: 0; padding: 4px; background: transparent; }
.page-thumbnail img { display: block; width: 100%; height: auto; }
.page-thumbnail span { display: block; font-size: 14px; padding-top: 8px; }
.page-thumbnail[aria-pressed=true] { border-color: var(--gold); }
.reader-hint { text-align: center; color: var(--muted); font-size: 14px; padding: 16px; margin: 0; }
.page-placeholder { min-height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 24px; }
.page-placeholder h2 { font-size: 28px; }
.reader:fullscreen { overflow: auto; background: #08090a; }
.end-card { padding: var(--section) var(--gutter); background: var(--surface); }
.end-card h2 { max-width: 16ch; }
.end-subtitle { color: var(--muted); }
.reading-mode .collector-archive { width: min(var(--content), calc(100% - var(--gutter)*2)); margin-inline: auto; }
@media (max-width: 1199px) {
  .edition-feature { gap: 32px; }
  .edition-intro { grid-column: 1 / 8; }
  .hero-art { grid-column: 8 / 13; }
  .edition-covers { gap: 32px; }
  .edition-book { grid-template-columns: 1fr; align-content: start; gap: 24px; }
  .edition-book > a { width: 100%; max-width: 340px; margin-inline: auto; }
  .edition-book figcaption { width: 100%; max-width: 400px; margin-inline: auto; }
  .section-heading { align-items: start; }
  .genesis-layout { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 32px; }
}
@media (max-width: 899px) {
  .edition-feature { gap: 40px; }
  .edition-intro { grid-column: 1 / 8; }
  .hero-art { grid-column: 8 / 13; }
  .edition-intro h1 { font-size: 56px; }
  .hero-deck { font-size: 17px; }
  .genesis-layout { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .founders-display { max-width: 400px; }
  .founders-editorial { max-width: 680px; margin-inline: auto; width: 100%; }
  .vault-layout { grid-template-columns: 1fr; gap: 40px; }
  .access-desk { width: 100%; }
  .site-footer { grid-template-columns: 1fr 2fr; }
  .site-footer > a:last-child { grid-column: 2; }
}
@media (max-width: 639px) {
  body { font-size: 16px; }
  .masthead { flex-wrap: wrap; gap: 16px; padding-block: 20px; }
  .publication { font-size: 24px; }
  .masthead nav { width: 100%; justify-content: space-between; gap: 4px 16px; }
  .masthead nav a { font-size: 14px; }
  .edition-feature { grid-template-columns: minmax(0, 1fr); gap: 36px; padding-top: 48px; }
  .edition-intro, .hero-art { grid-column: 1; }
  .edition-intro h1 { font-size: clamp(48px, 11vw, 64px); }
  .hero-deck { font-size: 18px; }
  .edition-intro .actions { align-items: stretch; }
  .edition-intro .button { width: 100%; }
  .edition-intro .text-link { justify-content: center; }
  .hero-art { width: min(100%, 340px); }
  .section-heading { display: block; }
  .section-heading > p { margin-top: 20px; }
  .edition-covers { grid-template-columns: 1fr; gap: 48px; }
  .edition-book { gap: 24px; }
  .edition-book + .edition-book { border-top: 1px solid var(--rule); padding-top: 48px; }
  .edition-facts { display: grid; gap: 12px; }
  .collector-archive > summary span { display: block; margin: 8px 0 0; }
  .archive-label { margin-bottom: 28px; }
  .holder-marque { align-items: start; gap: 16px; }
  .holder-marque img { width: 52px; height: 52px; }
  .holder-marque h2 { font-size: 30px; }
  .access-desk { padding: 24px 20px; }
  .policy-facts { gap: 24px 16px; }
  .holder-facts dd { font-size: 20px; }
  .site-footer { grid-template-columns: 1fr; gap: 20px; }
  .site-footer > a:last-child { grid-column: 1; }
  .reader-heading h1 { order: 3; flex-basis: 100%; font-size: 16px; }
  .reader .page-stage { padding: 8px; }
  .reader-dock { position: relative; padding: 12px 8px max(12px, env(safe-area-inset-bottom)); }
  .dock-navigation { width: 100%; gap: 6px; }
  .dock-navigation label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .reader-dock label { font-size: 14px; }
  .dock-tools { width: 100%; gap: 8px; }
  .page-thumbnails { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
}
@media (prefers-reduced-motion: no-preference) {
  a, button { transition: color 150ms ease, background-color 150ms ease, border-color 150ms ease; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
