
:root {
  --bg: #191816;
  --bg-alt: #211E1B;
  --card: #26231F;
  --footer-bg: #100F0E;
  --ink: #F5EEE1;
  --ink-2: #C9C0AF;
  --gold: #EEC86C;
  --gold-deep: #C69E4F;
  --line: rgba(245, 238, 225, 0.16);
  --line-strong: rgba(245, 238, 225, 0.38);
  --btn-bg: #EEC86C;
  --btn-ink: #191816;
  --dur: 0.95s;
  --ease: cubic-bezier(0.22, 0.8, 0.24, 1);
  --sans: 'Acumin Pro', 'Source Sans 3', Arial, sans-serif;
  --serif: 'Mackinac', 'Libre Baskerville', Georgia, serif;
  color-scheme: dark;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
html { scroll-padding-top: env(safe-area-inset-top, 0px); }
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { font-family: var(--sans); font-size: 17px; line-height: 1.5; -webkit-font-smoothing: antialiased; }

.site-header { position: relative; z-index: 30; background: var(--bg); border-bottom: 1px solid var(--line); }
.bar { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 24px; padding: 14px clamp(18px, 2.8vw, 34px); }
.nav-group { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: clamp(24px, 3.4vw, 40px); }
.nav-left { grid-column: 1; justify-content: flex-start; }
.nav-end { grid-column: 3; display: flex; align-items: center; justify-content: flex-end; gap: clamp(24px, 3.4vw, 40px); }
.nav-group a { color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 400; letter-spacing: 0.04em; text-transform: uppercase; }
.nav-group a:hover { color: var(--gold); }
.brand { grid-column: 2; display: block; }
.brand img { display: block; height: 28px; width: auto; }
.plus { position: relative; flex: none; width: 40px; height: 40px; border: 0; border-radius: 4px; background: transparent; color: var(--ink); cursor: pointer; }
.plus::before, .plus::after { content: ""; position: absolute; left: 50%; top: 50%; width: 24px; height: 1.6px; background: currentColor; transform: translate(-50%, -50%); transition: transform 0.24s cubic-bezier(0.16, 0.84, 0.32, 1); }
.plus::after { transform: translate(-50%, -50%) rotate(90deg); }
.plus[aria-expanded="true"]::before { transform: translate(-50%, -50%) rotate(45deg); }
.plus[aria-expanded="true"]::after { transform: translate(-50%, -50%) rotate(135deg); }
.plus:hover { color: var(--gold); }
.plus:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
html.menu-open { overflow: hidden; }
.menu-open .site-header { position: fixed; top: 0; left: 0; right: 0; border-bottom-color: transparent; background: transparent; }
.menu-panel { position: fixed; inset: 0; z-index: 1; overflow-y: auto; background: #1C1B19; display: flex; flex-direction: column; justify-content: center; padding: 96px clamp(24px, 14.5vw, 240px) 64px; }
.menu-panel[hidden] { display: none; }
.menu-panel ul { list-style: none; margin: 0; padding: 0; }
.menu-primary a { display: inline-block; font-size: clamp(44px, 6.4vw, 82px); font-weight: 400; line-height: 1.06; letter-spacing: -0.005em; text-transform: uppercase; color: var(--ink); text-decoration: none; }
.menu-secondary { display: flex; flex-wrap: wrap; gap: 10px clamp(24px, 3vw, 36px); margin-top: clamp(32px, 5vw, 56px) !important; }
.menu-secondary a { font-family: var(--serif); font-size: clamp(24px, 2.8vw, 34px); line-height: 1.2; color: var(--ink); text-decoration: none; }
.menu-primary a:hover, .menu-secondary a:hover { color: var(--gold); }
.menu-panel a:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.menu-panel .mobile-only { display: none; }
@media (max-width: 860px) {
  .nav-group { display: none; }
  .menu-panel { padding: 96px 28px 56px; justify-content: flex-start; }
  .menu-panel .mobile-only { display: block; }
}
.btn { display: inline-flex; align-items: center; justify-content: center; font-family: var(--sans); font-size: 14px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; line-height: 1.2; padding: 12px 22px; border: 0; border-radius: 4px; cursor: pointer; text-decoration: none; transition: background 0.14s cubic-bezier(0.16, 0.84, 0.32, 1), box-shadow 0.14s cubic-bezier(0.16, 0.84, 0.32, 1); }
.btn:active { opacity: 0.96; }
.btn-primary { background: var(--gold); color: #191816; }
.btn-primary:hover { background: var(--gold-deep); }
.btn-secondary { background: var(--btn-bg); color: var(--btn-ink); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-strong); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1px var(--ink); }
.btn-sm { padding: 8px 14px; font-size: 12px; }
.btn-lg { padding: 14px 28px; }
.btn[hidden] { display: none; }
.btn-link { background: none; border: 0; padding: 4px 0; font: inherit; font-size: 15px; font-weight: 600; color: var(--ink); text-decoration: underline; text-decoration-color: var(--gold-deep); text-decoration-thickness: 1.5px; text-underline-offset: 4px; cursor: pointer; }
.btn:focus-visible, .btn-link:focus-visible, .nav-group a:focus-visible, .tour:focus-visible, .site-footer a:focus-visible, .brand:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

.hero { display: flex; flex-direction: column; height: calc(100svh - 76px - env(safe-area-inset-top, 0px)); min-height: 600px; max-height: 1100px; }
/* Let the guide grow when phone controls wrap instead of overlapping the
   following section. The minimum still fills the original viewport stage. */
main .hero {
  height: auto;
  min-height: min(1100px, max(600px, calc(100svh - var(--header-height, 76px) - env(safe-area-inset-top, 0px))));
  max-height: none;
}
.intro { flex: none; text-align: center; max-width: 900px; margin: 0 auto; padding: 20px 22px 0; }
.share-row { display: flex; justify-content: center; gap: 22px; flex-wrap: wrap; }
.intro h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(26px, 3.6vw, 44px); line-height: 1.12; letter-spacing: -0.01em; margin: 0 0 8px; }
.intro p { margin: 0; color: var(--ink-2); }

.stage { position: relative; flex: 1 1 auto; min-height: 340px; width: 100%; margin-top: 16px; overflow: hidden; background: radial-gradient(ellipse 90% 45% at 50% 112%, rgba(238, 200, 108, 0.16) 0%, rgba(238, 200, 108, 0) 70%), linear-gradient(180deg, #0A0D18 0%, #111324 52%, #1C1A1A 100%); }
.sky { position: absolute; left: 0; top: 0; display: block; pointer-events: none; }
.slot { position: absolute; left: 50%; top: 50%; cursor: pointer; outline: none; transition: transform var(--dur) var(--ease), width var(--dur) var(--ease), height var(--dur) var(--ease), opacity 0.5s ease; }
.slot:focus-visible .shadow { box-shadow: 0 0 0 3px var(--gold), 0 30px 60px rgba(0, 0, 0, 0.55), 0 0 90px rgba(238, 200, 108, 0.16); }
.slot.hidden { opacity: 0; pointer-events: none; }
.slot.fast { --dur: 0.5s; }
.stage.instant .slot, .stage.instant .sheet, .stage.instant .hinge { transition: none !important; }
.stage { touch-action: pan-y; }
.stage.zoomed { touch-action: none; cursor: grab; }
.stage.zoomed.dragging { cursor: grabbing; }
.view { position: absolute; inset: 0; transform-origin: 50% 50%; }
.view.ease { transition: transform 0.45s cubic-bezier(0.16, 0.84, 0.32, 1); }
.tilt { position: absolute; inset: 0; transform-style: preserve-3d; transform-origin: 50% 50%; }
@keyframes beckon { 0%, 100% { box-shadow: 0 0 0 0 rgba(238, 200, 108, 0); } 50% { box-shadow: 0 0 0 9px rgba(238, 200, 108, 0.32); } }
#flip { animation: beckon 2.4s ease-in-out infinite; }
.zoom-ctrl { position: absolute; right: 14px; bottom: 14px; z-index: 3; display: flex; gap: 6px; }
.zoom-ctrl[hidden] { display: none; }
.zbtn { min-width: 40px; height: 40px; padding: 0 12px; border: 0; border-radius: 4px; background: rgba(25, 24, 22, 0.62); color: #F5EEE1; box-shadow: inset 0 0 0 1px rgba(245, 238, 225, 0.3); font: 600 20px/1 var(--sans); cursor: pointer; }
.zbtn:hover { box-shadow: inset 0 0 0 1px #F5EEE1; }
.zbtn:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.zbtn.zreset { font-size: 12px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.zbtn[hidden] { display: none; }
.shadow { position: absolute; left: 3%; right: 3%; top: 5%; bottom: 0; pointer-events: none; box-shadow: 0 30px 60px rgba(0, 0, 0, 0.55), 0 6px 14px rgba(0, 0, 0, 0.35), 0 0 90px rgba(238, 200, 108, 0.16); transition: box-shadow 0.3s ease; }
.sheet { position: absolute; width: 480px; height: 480px; transform-style: preserve-3d; transform-origin: 50% 50%; transition: transform var(--dur) var(--ease), left var(--dur) var(--ease), top var(--dur) var(--ease); }
.col, .panel, .hinge { position: absolute; width: 480px; height: 480px; transform-style: preserve-3d; }
.col, .panel { left: 0; top: 0; }
.hinge { transition: transform var(--dur) var(--ease); }
.hT { left: 0; top: -480px; transform-origin: 50% 100% -1px; transform: rotateX(180deg); }
.hB { left: 0; top: 480px; transform-origin: 50% 0 -0.5px; transform: rotateX(-180deg); }
.cR { left: 480px; top: 0; transform-origin: 0 50% -2.5px; transform: rotateY(180deg); }
.cL { left: -480px; top: 0; transform-origin: 100% 50% -4px; transform: rotateY(-180deg); }
.sheet[data-k="1"] .cL, .sheet[data-k="2"] .cL, .sheet[data-k="3"] .cL, .sheet[data-k="4"] .cL, .sheet[data-k="5"] .cL { transform: rotateY(0deg); }
.sheet[data-k="2"] .cR, .sheet[data-k="3"] .cR, .sheet[data-k="4"] .cR, .sheet[data-k="5"] .cR { transform: rotateY(0deg); }
.sheet[data-k="3"] .hT, .sheet[data-k="4"] .hT, .sheet[data-k="5"] .hT { transform: rotateX(0deg); }
.sheet[data-k="4"] .hB, .sheet[data-k="5"] .hB { transform: rotateX(0deg); }
.face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; background-size: 1440px 1440px; background-repeat: no-repeat; box-shadow: inset 0 0 0 0.75px rgba(25, 24, 22, 0.16); }
.fb { transform: rotateY(180deg); }
.cap { position: absolute; left: 50%; top: calc(100% + 16px); width: calc(100% + 24px); transform: translateX(-50%); text-align: center; pointer-events: none; transition: opacity 0.35s ease; line-height: 1.3; }
.cap b { display: block; font-family: var(--serif); font-style: italic; font-weight: 400; font-size: 19px; color: #F5EEE1; }
.cap span { display: block; font-size: 14px; color: #C9C0AF; margin-top: 2px; }
.slot:not(.active):not(.hidden) .cap { pointer-events: auto; }
.cap .choose-cue { display: inline-flex; align-items: center; justify-content: center; gap: 6px; margin-top: 10px; color: var(--gold); font-size: 13px; font-weight: 600; }
.choose-cue svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; animation: invite-click 2.4s ease-in-out 3; }
@keyframes invite-click { 0%, 35%, 75%, 100% { transform: translateY(0); } 55% { transform: translateY(-3px); } }
.motion-off .choose-cue svg { animation-play-state: paused; }
.slot.active .cap, .slot.hidden .cap { opacity: 0; }

/* The closed paper needs only its cover. Exclude folded backs from compositing
   until a flap opens; otherwise their pale edges shimmer during scaling. */
.sheet.cover-only .hinge { visibility: hidden; }
/* Mask only the texture's outermost pixels, which interpolate with adjacent
   cream panels in the full-sheet image. No artwork or text is changed. */
.cover-face.img-pagan-a::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  box-shadow: inset 0 0 0 1.5px #191816;
}

/* Resting artwork is painted at its final size, outside the scaled 3D layers.
   The original layers remain responsible for every fold and turn. */
.paper-art { position: absolute; cursor: pointer; background-repeat: no-repeat; }
.zoomed .paper-art { cursor: grab; }
.zoomed.dragging .paper-art { cursor: grabbing; }
.paper-art[hidden] { display: none; }
.paper-settled .tilt { visibility: hidden; }

/* Desktop controls stay at the stage edge. On phones they occupy a dedicated
   row below the paper, outside the clipped and zoomable reading surface. */
.stage-tools { position: relative; height: 0; flex: none; z-index: 3; }
@media (max-width: 767px) {
  .stage-tools {
    height: auto; min-height: 68px; padding: 12px 14px;
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 10px; background: var(--bg);
    border-bottom: 1px solid var(--line);
  }
  .stage-tools .motion-btn, .stage-tools .zoom-ctrl { position: static; }
  .stage-tools .motion-btn { width: 44px; height: 44px; padding: 0; }
  .stage-tools .zoom-ctrl { margin-left: auto; gap: 6px; }
  .stage-tools .zbtn { min-width: 44px; height: 44px; padding: 0 10px; }
  .stage-tools .zreset { font-size: 11px; padding: 0 8px; }
}

.controls { flex: none; display: flex; flex-direction: column; align-items: center; gap: 12px; min-height: 124px; padding: 18px 20px 20px; }
.intro .hint { margin: 14px auto 0; color: var(--gold); font-size: clamp(17px, 2vw, 20px); font-weight: 600; line-height: 1.35; max-width: 40ch; }
.progress { width: min(320px, 70vw); height: 4px; margin: 14px auto 0; border-radius: 2px; background: var(--line-strong); overflow: hidden; }
.progress[hidden] { display: none; }
.progress span { display: block; width: 0; height: 100%; background: var(--gold-deep); transition: width 0.5s ease; }
.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }

.section { padding: clamp(56px, 8vw, 96px) clamp(22px, 5vw, 48px); }
.section-alt { background: var(--bg-alt); }
.section-first { padding-top: clamp(40px, 5vw, 64px); }
.wrap { max-width: 1120px; margin: 0 auto; }
.narrow { max-width: 720px; margin: 0 auto; text-align: center; }
.section h2 { font-family: var(--sans); font-weight: 700; font-size: clamp(28px, 3.4vw, 40px); line-height: 1.12; letter-spacing: -0.01em; margin: 0 0 14px; }
.section .lede { margin: 0 0 32px; max-width: 60ch; color: var(--ink-2); }
.tour-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.tour { display: flex; flex-direction: column; gap: 6px; padding: 26px 26px 24px; background: var(--card); border-radius: 12px; box-shadow: inset 0 0 0 1px var(--line), 0 6px 16px -8px rgba(25, 24, 22, 0.18); color: var(--ink); text-decoration: none; transition: box-shadow 0.14s cubic-bezier(0.16, 0.84, 0.32, 1); }
.tour:hover { box-shadow: inset 0 0 0 1px var(--ink), 0 6px 16px -8px rgba(25, 24, 22, 0.18); }
.tour-name { font-size: 22px; font-weight: 700; line-height: 1.2; }
.tour-place { font-size: 15px; color: var(--ink-2); }
.tour-go { margin-top: 18px; font-size: 13px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; text-decoration: underline; text-decoration-color: var(--gold-deep); text-decoration-thickness: 1.5px; text-underline-offset: 5px; }
@media (max-width: 760px) { .tour-grid { grid-template-columns: minmax(0, 1fr); } }
.narrow p { margin: 0 auto; max-width: 58ch; color: var(--ink-2); }
.cta-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 30px; }
.narrow .note { margin-top: 28px; font-size: 15px; }

.newsletter-band { background: var(--bg-alt); }
.newsletter { max-width: 1120px; margin: 0 auto; padding: clamp(48px, 7vw, 80px) clamp(22px, 5vw, 48px); display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 40px; align-items: end; }
.newsletter h2 { margin: 0 0 6px; font-size: clamp(28px, 3.4vw, 40px); font-weight: 700; line-height: 1.12; letter-spacing: -0.01em; }
.nl-sub { margin: 0 0 14px; font-family: var(--serif); font-style: italic; font-size: 20px; color: var(--gold); }
.nl-body { margin: 0; max-width: 58ch; color: var(--ink-2); }
.nl-form label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 600; }
.nl-row { display: flex; gap: 10px; }
.nl-row input { flex: 1; min-width: 0; font: inherit; font-size: 16px; color: var(--ink); background: var(--card); border: 0; border-radius: 4px; box-shadow: inset 0 0 0 1px var(--line-strong); padding: 12px 14px; }
.nl-row input::placeholder { color: #A89F90; }
.nl-row input:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.nl-note { margin: 8px 0 0; min-height: 1.4em; font-size: 13px; color: var(--ink-2); }
.site-footer { overflow: hidden; background: var(--footer-bg); color: var(--ink); padding: clamp(48px, 5vw, 72px) clamp(22px, 3vw, 36px) 0; }
.footer-cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.site-footer h3 { margin: 0 0 clamp(28px, 3.6vw, 44px); font-size: 15px; font-weight: 600; color: #9E968A; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li a { font-size: clamp(20px, 2.2vw, 27px); line-height: 1.24; color: var(--ink); text-decoration: none; }
.site-footer li a:hover { color: var(--gold); }
.footer-legal { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 14px; align-content: start; font-size: 15px; font-weight: 600; line-height: 1.5; color: #9E968A; }
.footer-legal svg { grid-row: 1 / span 2; width: 30px; height: 30px; margin-top: -2px; }
.footer-legal p { margin: 0; }
.footer-legal a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.footer-legal a:hover { color: var(--gold); }
.footer-legal .copy { margin-top: clamp(28px, 3.6vw, 44px); }
.footer-mark { margin-top: clamp(72px, 13vw, 200px); overflow: hidden; aspect-ratio: 1621 / 373; }
.footer-mark img { display: block; width: 100%; height: auto; }
.to-top { position: fixed; right: 20px; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); z-index: 15; width: 56px; height: 56px; border: 0; border-radius: 50%; background: var(--gold); display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 10px 24px -10px rgba(0, 0, 0, 0.6); opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity 0.24s ease, transform 0.24s ease, background 0.14s ease; }
.to-top.show { opacity: 1; pointer-events: auto; transform: none; }
.to-top:hover { background: var(--gold-deep); }
.to-top:focus-visible { outline: 3px solid #F5EEE1; outline-offset: 3px; }
.to-top img { width: 26px; height: auto; display: block; }
@media (max-width: 760px) { .newsletter { grid-template-columns: minmax(0, 1fr); } .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 40px; } .footer-legal { grid-column: 1 / -1; } }

/* Each topic is its own disclosure; both handouts share one open answer. */
.tv-handout { border-top: 1px solid var(--line); }
.tv-handout:last-child { border-bottom: 1px solid var(--line); }
.tv-handout > summary { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 84px; padding: 22px 4px; cursor: pointer; list-style: none; }
.tv-handout > summary::-webkit-details-marker { display: none; }
.tv-handout > summary h3 { margin: 0; font-family: var(--serif); font-size: clamp(24px, 3vw, 32px); font-weight: 400; line-height: 1.2; }
.tv-handout > summary::after { content: "+"; flex: none; width: 24px; text-align: center; font-size: 28px; line-height: 1; color: var(--gold); }
.tv-handout[open] > summary::after { content: "−"; }
.tv-handout > summary:hover { color: var(--gold); }
.tv-handout > summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.tv-topics { padding: 0 clamp(12px, 2vw, 28px) 28px; }
.tv-topics > .tv-side:first-child { margin-top: 8px; }
.tv-side { margin: 32px 0 12px; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.tv-topic { border-top: 1px solid var(--line); scroll-margin-top: 90px; }
.tv-topic:last-child { border-bottom: 1px solid var(--line); }
.tv-topic summary { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 64px; padding: 18px 4px; font-size: clamp(18px, 2vw, 21px); font-weight: 600; line-height: 1.35; cursor: pointer; list-style: none; }
.tv-topic summary::-webkit-details-marker { display: none; }
.tv-topic summary::after { content: "+"; flex: none; width: 24px; text-align: center; font-size: 26px; font-weight: 400; line-height: 1; color: var(--gold); }
.tv-topic[open] summary::after { content: "−"; }
.tv-topic[open] summary { color: var(--gold); }
.tv-topic summary:hover { color: var(--gold); }
.tv-topic summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.tv-answer { max-width: 68ch; padding: 0 4px 24px; color: var(--ink-2); }
.tv-answer h4 { margin: 0 0 12px; font-size: 20px; line-height: 1.35; color: var(--ink); }
.tv-answer p, .tv-answer li { margin: 0 0 10px; }
.tv-answer ol { margin: 4px 0 12px; padding-left: 22px; }
.tv-answer p:last-child { margin-bottom: 0; }
.tv-answer b { color: var(--ink); }
.tv-label { font-size: 12px; font-weight: 700; letter-spacing: .07em; color: var(--ink); }
.tv-cite { font-size: 14px; color: var(--ink-2); }

.motion-btn { position: absolute; left: 14px; bottom: 14px; z-index: 3; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 4px; background: rgba(25, 24, 22, 0.62); color: #F5EEE1; box-shadow: inset 0 0 0 1px rgba(245, 238, 225, 0.3); cursor: pointer; }
.motion-btn svg { display: block; width: 20px; height: 20px; fill: currentColor; }
.motion-btn:hover { box-shadow: inset 0 0 0 1px #F5EEE1; }
.motion-btn:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.motion-off #flip { animation-play-state: paused; }

.reader { position: fixed; inset: 0; z-index: 20; display: flex; flex-direction: column; background: rgba(25, 24, 22, 0.94); padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); }
.reader[hidden] { display: none; }
html.reader-open { overflow: hidden; }
body.reader-open { position: fixed; width: 100%; overflow: hidden; }
.reader { height: 100dvh; overscroll-behavior: contain; }
.reader-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 18px; color: #F5EEE1; font-weight: 600; }
.reader-bar .btn-ghost { flex: none; min-width: 44px; min-height: 44px; color: #F5EEE1; box-shadow: inset 0 0 0 1px rgba(245, 238, 225, 0.4); }
.reader-scroll { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 0 12px 24px; }
.reader-img { width: max(100%, 1100px); max-width: 1440px; aspect-ratio: 1; margin: 0 auto; background-size: 100% 100%; background-repeat: no-repeat; }

html.share-open { overflow: hidden; }
.share-dialog { width: min(460px, calc(100% - 32px)); max-height: calc(100dvh - 32px); margin: auto; padding: clamp(22px, 5vw, 32px); border: 1px solid var(--line-strong); border-radius: 4px; background: var(--bg); color: var(--ink); box-shadow: 0 24px 90px rgba(0, 0, 0, 0.45); overflow-y: auto; overscroll-behavior: contain; }
.share-dialog::backdrop { background: rgba(8, 10, 17, 0.76); }
.share-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.share-heading h2 { margin: 0; font: 400 clamp(24px, 5vw, 28px)/1.2 var(--serif); }
.share-close { display: grid; place-items: center; flex: none; width: 44px; height: 44px; margin: -8px -8px -8px 0; border: 0; border-radius: 4px; background: transparent; color: var(--ink-2); cursor: pointer; }
.share-dialog svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
#share-description { margin: 12px 0 24px; color: var(--ink-2); font-size: 16px; }
.share-options { border-top: 1px solid var(--line); }
.share-option { display: flex; align-items: center; gap: 16px; width: 100%; min-height: 80px; padding: 16px 4px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; color: var(--ink); font: inherit; text-align: left; text-decoration: none; cursor: pointer; }
.share-option > svg { flex: none; color: var(--gold); }
.share-option strong { display: block; font-size: 18px; font-weight: 600; line-height: 1.3; }
.share-option small { display: block; margin-top: 3px; color: var(--ink-2); font-size: 14px; }
.share-arrow { margin-left: auto; color: var(--gold); font-size: 23px; }
.share-option:hover, .share-close:hover { color: var(--gold); background: var(--bg-alt); }
.share-option:focus-visible, .share-close:focus-visible, #share-url:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.share-native { width: 100%; min-height: 48px; margin-top: 22px; }
.share-dialog button:disabled { opacity: 0.6; cursor: wait; }
.share-manual { margin-top: 20px; }
.share-manual label { display: block; margin-bottom: 6px; font-size: 14px; color: var(--ink-2); }
#share-url { display: block; width: 100%; min-height: 44px; border: 1px solid var(--line-strong); border-radius: 4px; padding: 10px; background: var(--bg-alt); color: var(--ink); font: 16px/1.4 var(--sans); }
.share-status { margin: 16px 0 0; font-size: 14px; color: var(--gold); }
.share-status:empty { margin: 0; }

@media (prefers-reduced-motion: reduce) {
  .slot, .sheet, .hinge, .view.ease { transition-duration: 1ms !important; }
  #flip, .choose-cue svg { animation: none; }
}

.img-pagan-a { background-image: url("../assets/pagan-outside.png?v=esv-1"); }
.img-pagan-b { background-image: url("../assets/pagan-inside.png?v=esv-1"); }
.img-nativity-a { background-image: url("../assets/nativity-outside.svg?v=esv-1"); }
.img-nativity-b { background-image: url("../assets/nativity-inside.png?v=esv-1"); }
