:root {
  --ink: #17130F;
  --paper: #FAF9F3;
  --muted: #6B655C;
  --accent: #7A3419;
  --carry-muted: #C9BFAE;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); font-family: 'Space Grotesk', system-ui, sans-serif; color: var(--ink); }
a { color: var(--ink); }
.wrap { max-width: 640px; margin: 0 auto; position: relative; min-height: 100vh; }

.lockup { padding: 88px 32px 8px; display: flex; flex-direction: column; align-items: center; gap: 18px; text-align: center; }
.lockup img { width: 60px; height: auto; display: block; opacity: 0.9; }
.lockup .word { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: clamp(24px, 7vw, 34px); letter-spacing: -0.015em; line-height: 1; overflow-wrap: break-word; max-width: 100%; }

/* Library index gets a bigger, tagline-bearing lockup than the Reader header. */
.wrap.library .lockup { padding: 88px 32px 56px; gap: 20px; }
.wrap.library .lockup img { width: 64px; }
.wrap.library .lockup .word { font-size: clamp(30px, 8.5vw, 46px); letter-spacing: -0.02em; line-height: 0.98; }
.lockup .tagline { font-family: 'Frank Ruhl Libre', serif; font-size: 18px; line-height: 1.55; color: #3A352E; max-width: 320px; margin: 8px 0 0; }

.progress-ring { position: fixed; top: 18px; right: 18px; z-index: 50; background: var(--paper); border-radius: 50%; }
.progress-arc { transition: stroke-dashoffset 120ms linear; }

.statement { width: 100%; display: flex; align-items: center; justify-content: center; text-align: center; }
.statement .text { font-weight: 700; line-height: 1.1; letter-spacing: -0.01em; max-width: 520px; margin: 0; }
.statement.lead { padding: 140px 32px; }
.statement.lead .text { font-size: 42px; }
.statement.standard { padding: 96px 32px; }
.statement.standard .text { font-size: 27px; }

.subline { padding: 0 32px 96px; text-align: center; font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }

.scripture { padding: 56px 32px 56px 64px; display: flex; flex-direction: column; gap: 22px; position: relative; }
.scripture::before { content: ''; position: absolute; left: 24px; top: 0; bottom: 0; width: 2px; background: var(--ink); opacity: 0.55; }
.scripture .lines { font-family: 'Frank Ruhl Libre', serif; font-size: 24px; line-height: 1.68; }
.scripture .lines div { margin: 0; }
.scripture .emph { font-style: normal; font-weight: 700; }
.scripture .ref-block { position: relative; display: inline-block; margin-top: 2px; }
.scripture .rule { position: absolute; left: -46px; top: 7px; width: 26px; height: 2px; background: var(--accent); transform: rotate(-35deg); transform-origin: right center; }
.scripture .ref { font-size: 11px; font-weight: 600; letter-spacing: 0.14em; color: var(--muted); }

.prose { padding: 36px 32px; display: flex; flex-direction: column; gap: 20px; }
.prose p { margin: 0; font-weight: 400; font-size: 17px; line-height: 1.6; color: #3A352E; max-width: 34ch; }

.interjection { padding: 72px 20px; display: flex; align-items: center; justify-content: center; }
.interjection .text { font-weight: 700; line-height: 0.95; letter-spacing: -0.02em; text-align: center; text-transform: uppercase; font-size: 92px; margin: 0; }

.contrast { padding: 48px 32px; display: flex; flex-direction: column; gap: 28px; }
.contrast .row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 56px; }
.contrast .first { font-size: 22px; font-weight: 400; }
.contrast .second { font-size: 22px; font-weight: 700; text-align: right; display: inline; }
.contrast .reveal-btn { font-family: 'Space Grotesk', sans-serif; font-size: 12px; font-weight: 700; letter-spacing: 0.12em; color: var(--paper); background: var(--accent); border: none; clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%); height: 52px; padding: 0 24px 0 22px; cursor: pointer; display: none; flex-shrink: 0; }
.contrast .reveal-all { font-family: 'Space Grotesk', sans-serif; align-self: flex-start; font-size: 13px; font-weight: 600; letter-spacing: 0.08em; color: var(--muted); background: none; border: none; border-bottom: 1px solid var(--muted); padding: 4px 0; cursor: pointer; display: none; }
.contrast .resolution { font-weight: 700; font-size: 24px; line-height: 1.25; padding-top: 8px; margin: 0; display: block; }

.js .contrast .row.pending .second { display: none; }
.js .contrast .row.pending .reveal-btn { display: inline-flex; align-items: center; justify-content: center; }
.js .contrast .resolution { display: none; }
.js .contrast.all-revealed .resolution { display: block; }
.js .contrast .reveal-all { display: inline-block; }
.js .contrast.all-revealed .reveal-all { display: none; }

.tension { padding: 96px 24px; display: flex; flex-direction: column; align-items: center; gap: 28px; }
.tension .pair { display: flex; align-items: center; justify-content: center; gap: 20px; width: 100%; transition: gap 380ms ease; }
.tension .word { font-weight: 700; font-size: 30px; letter-spacing: 0.01em; }
.tension .rule { height: 2px; background: var(--ink); width: 0px; opacity: 0; transition: all 380ms ease; flex-shrink: 0; }
.tension .resolution { font-size: 15px; color: var(--muted); text-align: center; max-width: 280px; margin: 0; }
.tension.ts-diverged .pair { gap: 18vw; }
.tension.ts-diverged .rule { width: 32px; opacity: 1; }
.tension.ts-diverged .resolution { display: none; }

.carry-wrap { padding: 48px 32px 64px; display: flex; flex-direction: column; align-items: center; gap: 32px; }
.carry-card { width: 100%; max-width: 400px; background: var(--ink); padding: 44px 32px; display: flex; flex-direction: column; gap: 18px; align-items: flex-start; }
.carry-card .carry-statement { color: var(--paper); font-weight: 700; font-size: 26px; line-height: 1.2; margin: 0; text-align: left; }
.carry-card .carry-ref { font-size: 11px; font-weight: 600; letter-spacing: 0.14em; color: var(--carry-muted); }
.carry-actions { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.btn { font-family: 'Space Grotesk', sans-serif; font-size: 13px; font-weight: 700; letter-spacing: 0.08em; border-radius: 28px; height: 52px; padding: 0 26px; cursor: pointer; border: none; }
.btn-primary { color: var(--paper); background: var(--ink); }
.btn-secondary { color: var(--ink); background: transparent; border: 1.5px solid var(--ink); }
.carry-note { font-size: 12px; color: var(--muted); min-height: 16px; }

.site-footer { padding: 40px 32px 80px; text-align: center; display: flex; flex-direction: column; gap: 12px; }
.site-footer a { font-weight: 700; font-size: 12px; letter-spacing: 0.08em; text-decoration: none; }
.site-footer .credit { font-size: 11px; font-weight: 600; letter-spacing: 0.1em; color: var(--muted); margin: 0; }

/* Library index list */
.list { padding: 0 32px 96px; display: flex; flex-direction: column; gap: 20px; }
.card { display: flex; flex-direction: column; gap: 14px; background: var(--ink); padding: 36px 30px; text-decoration: none; }
.card:hover { opacity: 0.94; }
.card .title { font-weight: 700; font-size: 23px; line-height: 1.25; color: var(--paper); margin: 0; }
.card .meta { display: flex; align-items: center; gap: 14px; }
.card .meta span.label { font-size: 11px; font-weight: 600; letter-spacing: 0.12em; color: var(--carry-muted); }
.card .meta span.dot { width: 3px; height: 3px; border-radius: 50%; background: var(--muted); }
.empty-state { padding: 0 32px 96px; text-align: center; font-family: 'Frank Ruhl Libre', serif; font-size: 17px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .tension .pair, .tension .rule, .progress-arc { transition: none; }
}
