/* VIVLA Club, "Un año en el club". Concept site, v2. */

@property --fg { syntax: "<color>"; inherits: true; initial-value: #2a1a14; }
@property --accent { syntax: "<color>"; inherits: true; initial-value: #c4512a; }
@property --bg { syntax: "<color>"; inherits: true; initial-value: #f6f1e9; }

:root {
  --cream: #f6f1e9;
  --ink: #2a1a14;
  --terra: #c4512a;
  --terra-hot: #e0693c;
  --sea: #2f6f8f;
  --olive: #6b7048;
  --sand: #e6d5b8;
  --night: #12101c;
  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, sans-serif;
  --gutter: clamp(16px, 5.5vw, 96px);
  --ease-open: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-close: cubic-bezier(0.32, 0, 0.67, 0);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
/* Derived tokens resolve where --fg changes, so night chapters get light muted text. */
body, .hud, .stage, .night-card, .pf-text, #c10 .layer { --muted: color-mix(in srgb, var(--fg) 64%, transparent); --hair: color-mix(in srgb, var(--fg) 22%, transparent); }
html { background: #f6f1e9; }
html.lenis, html.lenis body { height: auto; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: --fg 500ms ease-out, --accent 500ms ease-out, --bg 500ms ease-out;
  overflow-x: hidden;
}
body.is-loading { overflow: hidden; }
::selection { background: var(--terra); color: var(--cream); }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 4px; }
em, .it { font-style: italic; }
.num { font-variant-numeric: tabular-nums lining-nums; }

/* ---------- fixed layers ---------- */
#gl { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; display: block; pointer-events: none; }
.grain {
  position: fixed; inset: -50%; z-index: 15; pointer-events: none;
  opacity: 0.06; background-size: 160px 160px;
  animation: grain 0.9s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); } 20% { transform: translate(-4%, 3%); } 40% { transform: translate(3%, -2%); }
  60% { transform: translate(-2%, -4%); } 80% { transform: translate(4%, 2%); } 100% { transform: translate(0, 0); }
}

/* ---------- loader ---------- */
#loader {
  position: fixed; inset: 0; z-index: 40; background: var(--cream); color: var(--ink);
  display: grid; place-items: center; clip-path: inset(0 0 0 0);
}
.loader-in { display: grid; justify-items: center; gap: 22px; }
.loader-word { font-family: var(--serif); font-size: clamp(28px, 3vw, 40px); font-weight: 300; letter-spacing: -0.02em; }
.loader-word em { color: var(--terra); }
.loader-bar { width: min(260px, 60vw); height: 1px; background: rgba(42, 26, 20, 0.14); position: relative; overflow: hidden; }
.loader-bar i { position: absolute; inset: 0; background: var(--terra); transform-origin: 0 50%; transform: scaleX(0); }
.loader-num { font-size: 12px; letter-spacing: 0.08em; color: rgba(42, 26, 20, 0.55); }

/* ---------- HUD ---------- */
.hud {
  position: fixed; top: 0; left: 0; right: 0; z-index: 10;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 18px var(--gutter) 0; pointer-events: none;
}
.hud > * { pointer-events: auto; }
.hud-logo { font-family: var(--serif); font-size: 22px; font-weight: 400; letter-spacing: -0.01em; justify-self: start; }
.hud-logo em { color: var(--accent); font-weight: 300; }
.hud-chapter { position: relative; height: 22px; min-width: 220px; text-align: center; overflow: hidden; font-size: 13px; }
.hud-chapter span { position: absolute; inset: 0; display: flex; justify-content: center; align-items: center; gap: 10px; white-space: nowrap; }
.hud-chapter b { font-weight: 500; font-variant-numeric: tabular-nums; color: var(--accent); }
.hud-chapter i { font-family: var(--serif); font-size: 16px; font-style: italic; }
.hud-right { justify-self: end; display: flex; gap: 10px; align-items: center; }
.sample {
  font-size: 11.5px; padding: 6px 11px; border-radius: 999px; letter-spacing: 0.01em;
  border: 1px solid var(--hair); color: var(--muted); white-space: nowrap;
}
.sound { font-size: 12px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--hair); display: flex; gap: 8px; align-items: center; }
.sound .bars { display: inline-flex; gap: 2px; align-items: flex-end; height: 10px; }
.sound .bars i { width: 2px; height: 3px; background: currentColor; border-radius: 1px; transition: height 0.3s; }
.sound.on .bars i { animation: eq 0.9s ease-in-out infinite alternate; }
.sound.on .bars i:nth-child(2) { animation-delay: -0.3s; } .sound.on .bars i:nth-child(3) { animation-delay: -0.6s; }
@keyframes eq { from { height: 2px; } to { height: 10px; } }
.hud-progress { grid-column: 1 / -1; margin-top: 14px; height: 1px; background: var(--hair); position: relative; }
.hud-progress > i { position: absolute; inset: 0; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }
.hud-progress .tick { position: absolute; top: -2px; width: 1px; height: 5px; background: var(--hair); }

/* ---------- cursor ---------- */
.cursor { position: fixed; top: 0; left: 0; z-index: 30; pointer-events: none; opacity: 0; transition: opacity .3s; }
.cursor.on { opacity: 1; }
.c-dot, .c-ring { position: fixed; top: 0; left: 0; border-radius: 50%; pointer-events: none; }
.c-dot { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--accent); }
.c-ring {
  width: 38px; height: 38px; margin: -19px 0 0 -19px; border: 1px solid color-mix(in srgb, var(--fg) 45%, transparent);
  display: grid; place-items: center; transition: width 0.45s var(--ease-open), height 0.45s var(--ease-open), margin 0.45s var(--ease-open), background-color 0.3s, border-color 0.3s;
}
.c-ring span { font-size: 11px; font-weight: 500; color: var(--cream); opacity: 0; transition: opacity 0.2s; white-space: nowrap; }
.cursor.is-hover .c-ring { width: 84px; height: 84px; margin: -42px 0 0 -42px; background: var(--accent); border-color: transparent; }
.cursor.is-hover .c-ring span { opacity: 1; }
.cursor.is-hover .c-dot { opacity: 0; }
@media (hover: none) { .cursor { display: none; } }
@media (hover: hover) { body.has-cursor, body.has-cursor a, body.has-cursor button { cursor: none; } }

/* ---------- chapters ---------- */
.ch { position: relative; height: calc(var(--h) * 1vh); }
.stage { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.thread { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; z-index: 1; }
.thread path { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.thread .t-glow { stroke: var(--terra); stroke-width: 7; opacity: 0.16; }
.thread .t-line { stroke: var(--terra); stroke-width: 1.6; }
.thread .t-tip { fill: var(--terra-hot); }
.thread .t-halo { fill: var(--terra-hot); opacity: 0.25; }
.layer { position: absolute; inset: 0; z-index: 2; }

.h-display { font-family: var(--serif); font-weight: 300; letter-spacing: -0.03em; line-height: 0.98; font-optical-sizing: auto; }
.h-display em { color: var(--accent); font-weight: 300; }
.lede { font-size: clamp(15px, 1.15vw, 18px); line-height: 1.55; color: var(--muted); max-width: 38ch; }
.by { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--muted); }
.by .av {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: var(--accent); color: var(--cream); font-family: var(--serif); font-size: 16px; font-style: italic;
}
.by b { color: var(--fg); font-weight: 500; }
.quote { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(20px, 1.8vw, 28px); line-height: 1.3; max-width: 26ch; letter-spacing: -0.01em; }
.count { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.count b { color: var(--fg); font-weight: 500; }

/* typed link CTA */
.cta-link {
  display: inline-flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 500;
  padding: 12px 0; border-bottom: 1px solid var(--accent); color: var(--fg); min-height: 44px;
}
.cta-link .type::after { content: ""; display: inline-block; width: 1px; height: 1em; margin-left: 2px; vertical-align: -2px; background: var(--accent); opacity: 0; }
.cta-link .type.typing::after { opacity: 1; }
.cta-link:hover { color: var(--accent); }

/* magnetic buttons */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: 12px; min-height: 52px;
  padding: 0 26px; border-radius: 999px; background: var(--terra); color: var(--cream);
  font-size: 15px; font-weight: 500; letter-spacing: 0.005em; will-change: transform;
  box-shadow: 0 10px 30px -12px rgba(196, 81, 42, 0.7);
  transition: background-color 0.3s;
}
.btn:hover { background: #b2451f; }
.btn .btn-in { display: inline-flex; gap: 12px; align-items: center; pointer-events: none; }
.btn.ghost { background: transparent; color: var(--fg); border: 1px solid var(--hair); box-shadow: none; }
.btn.ghost:hover { border-color: var(--fg); }
.btn svg { width: 16px; height: 16px; }

/* ---------- c0 intro ---------- */
#c0 .layer { display: grid; place-items: center; text-align: center; }
.intro { position: relative; display: grid; justify-items: center; gap: 28px; margin-top: -4vh; }
.intro-title { font-family: var(--serif); font-weight: 300; line-height: 0.8; letter-spacing: -0.045em; font-size: clamp(88px, 18vw, 300px); position: relative; }
.intro-title .w1 { display: block; }
.intro-title .w2 {
  display: block; font-style: italic; color: var(--terra); font-size: 0.5em; letter-spacing: -0.03em;
  margin: -0.12em -1.6em 0 auto; width: max-content; position: relative;
}
.intro-sub { font-size: clamp(15px, 1.2vw, 18px); color: var(--muted); max-width: 36ch; line-height: 1.55; }
.scroll-cue { position: absolute; left: 50%; bottom: 34px; transform: translateX(-50%); display: grid; justify-items: center; gap: 10px; font-size: 12px; color: var(--muted); z-index: 3; }
.scroll-cue i { width: 1px; height: 46px; background: var(--hair); position: relative; overflow: hidden; }
.scroll-cue i::after { content: ""; position: absolute; left: 0; top: -40%; width: 1px; height: 40%; background: var(--terra); animation: cue 1.8s var(--ease-open) infinite; }
@keyframes cue { to { top: 110%; } }

/* ---------- c1 manifesto ---------- */
#c1 .layer { display: grid; align-content: center; padding: 0 var(--gutter); }
.manifesto { font-size: clamp(44px, 7.4vw, 124px); max-width: 13.5ch; }
.manifesto .w { display: inline-block; will-change: transform, opacity; }
.manifesto em { color: var(--terra); }
.manifesto-sub { margin-top: 44px; margin-left: clamp(0px, 34vw, 560px); max-width: 34ch; font-size: clamp(16px, 1.25vw, 19px); line-height: 1.55; }

/* ---------- c2 dive ---------- */
.dive-title { position: absolute; left: 0; right: 0; top: 17vh; text-align: center; font-size: clamp(40px, 6vw, 96px); padding: 0 var(--gutter); }
.dive-title span { display: block; }
.dive-side { position: absolute; left: var(--gutter); bottom: 9vh; max-width: 34ch; font-size: clamp(15px, 1.2vw, 18px); line-height: 1.55; }
.dive-end { position: absolute; left: 0; right: 0; bottom: 14vh; text-align: center; font-size: clamp(30px, 3.6vw, 56px); }
.dest {
  position: absolute; left: 0; top: 0; display: flex; align-items: center; gap: 8px; white-space: nowrap;
  transform: translate3d(-999px, -999px, 0); will-change: transform, opacity; opacity: 0;
}
.dest i { width: 8px; height: 8px; border-radius: 50%; background: var(--terra); box-shadow: 0 0 0 4px rgba(196, 81, 42, 0.22); flex: none; }
.dest span { font-family: var(--serif); font-style: italic; font-size: 19px; color: #fffaf2; text-shadow: 0 1px 12px rgba(15, 30, 45, 0.45); }
.dest small { font-size: 11.5px; color: rgba(255, 250, 242, 0.8); text-shadow: 0 1px 8px rgba(15, 30, 45, 0.5); }

/* ---------- shared item stacks ---------- */
.items { position: relative; }
.item { position: absolute; left: 0; top: 0; width: 100%; pointer-events: none; }
.item.is-on { pointer-events: auto; }
.item .ln { opacity: 0; }

/* ---------- c3 books ---------- */
.ribbon { position: absolute; top: 96px; left: 0; right: 0; white-space: nowrap; overflow: hidden; z-index: 3; padding: 4px 0 10px; -webkit-mask-image: linear-gradient(90deg, transparent, #000 18%, #000 82%, transparent); mask-image: linear-gradient(90deg, transparent, #000 18%, #000 82%, transparent); }
.ribbon-track { display: inline-flex; gap: 56px; will-change: transform; padding-left: 50vw; }
.ribbon-track span { position: relative; font-family: var(--serif); font-size: clamp(24px, 2.6vw, 40px); font-weight: 300; letter-spacing: -0.02em; display: inline-grid; }
.ribbon-track span > * { grid-area: 1 / 1; transition: opacity 0.5s ease-out; }
.ribbon-track .ro { opacity: 0; }
.ribbon-track .ri { font-style: italic; opacity: 0.32; }
.ribbon-track span.on .ro { opacity: 1; }
.ribbon-track span.on .ri { opacity: 0; }
.books-text { position: absolute; left: var(--gutter); top: 50%; width: min(40vw, 560px); transform: translateY(-38%); }
.books-text .count { margin-bottom: 18px; }
.book-title { font-size: clamp(48px, 5.6vw, 92px); margin-bottom: 12px; }
.book-author { font-size: 15px; color: var(--muted); margin-bottom: 30px; }
.books-text .quote { margin-bottom: 22px; }
.books-text .by { margin-bottom: 26px; }

/* ---------- c4 vinyl ---------- */
.vinyl-text { position: absolute; right: var(--gutter); top: 50%; transform: translateY(-50%); width: min(36vw, 500px); }
.vinyl-text h2 { font-size: clamp(46px, 5vw, 84px); margin: 14px 0 18px; }
.vinyl-text .quote { margin-bottom: 26px; font-size: clamp(19px, 1.5vw, 24px); }
.tracks { list-style: none; border-top: 1px solid var(--hair); margin-bottom: 24px; }
.tracks li { display: grid; grid-template-columns: 28px 1fr auto; gap: 12px; align-items: baseline; padding: 11px 0; border-bottom: 1px solid var(--hair); font-size: 14.5px; }
.tracks li span:first-child { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 12px; }
.tracks li small { color: var(--muted); font-size: 13px; }
.tracks li em { font-style: normal; color: var(--muted); }
.tracks li.now span:first-child { color: var(--accent); }
.tracks li.now { color: var(--fg); }
.wave { position: absolute; left: var(--gutter); right: var(--gutter); bottom: 5vh; height: 56px; display: flex; align-items: center; gap: 4px; z-index: 2; }
.wave i { flex: 1; height: 100%; background: var(--accent); opacity: 0.55; border-radius: 2px; transform-origin: 50% 50%; transform: scaleY(0.08); will-change: transform; }

/* ---------- c5 places ---------- */
.places-text { position: absolute; left: var(--gutter); bottom: 8vh; width: min(44vw, 620px); }
.place-name { font-size: clamp(50px, 6vw, 100px); margin: 12px 0 10px; }
.place-loc { font-size: 15px; color: var(--muted); margin-bottom: 22px; }
.places-text .quote { margin-bottom: 18px; font-size: clamp(19px, 1.5vw, 24px); }
.places-text .by { margin-bottom: 14px; }
.map { position: absolute; right: var(--gutter); top: 110px; width: min(300px, 26vw); z-index: 3; }
.map svg { width: 100%; height: auto; display: block; overflow: visible; }
.map .isle { fill: color-mix(in srgb, var(--fg) 10%, transparent); stroke: color-mix(in srgb, var(--fg) 45%, transparent); stroke-width: 0.8; }
.map .pin { opacity: 0; }
.map .pin circle.dot { fill: var(--terra); }
.map .pin circle.ring { fill: none; stroke: var(--terra); stroke-width: 1; opacity: 0; }
.map .pin.on circle.ring { animation: ping 1.6s var(--ease-open) infinite; }
.map .pin text { font-family: var(--sans); font-size: 9px; fill: var(--fg); }
@keyframes ping { from { r: 4; opacity: 0.9; } to { r: 16; opacity: 0; } }
.map-cap { font-size: 12px; color: var(--muted); margin-top: 8px; text-align: right; }

/* ---------- c6 Baqueira ---------- */
.day-head { position: absolute; left: var(--gutter); top: 104px; z-index: 3; }
.day-head h2 { font-size: clamp(40px, 4.6vw, 76px); margin-bottom: 14px; }
.sunarc { position: absolute; right: var(--gutter); top: 100px; width: min(260px, 30vw); z-index: 3; }
.sunarc svg { width: 100%; display: block; overflow: visible; }
.sunarc .arc { fill: none; stroke: var(--hair); stroke-width: 1; stroke-dasharray: 2 4; }
.sunarc .sun { fill: var(--accent); }
.sunarc text { font-size: 10px; fill: var(--muted); font-family: var(--sans); }
.sunarc .clock { font-family: var(--serif); font-size: 24px; fill: var(--fg); font-variant-numeric: tabular-nums; }
.track { position: absolute; left: 0; top: 0; height: 100%; display: flex; align-items: flex-end; gap: 4vw; padding: 0 var(--gutter) 9vh calc(var(--gutter) + 30vw); will-change: transform; }
.track-line { position: absolute; left: 0; top: calc(100% - 9vh - max(50vh, 360px) - 26px); height: 1px; width: 100%; overflow: visible; }
.hour {
  position: relative; flex: none; width: clamp(280px, 28vw, 440px); height: 50vh; min-height: 360px;
  display: flex; flex-direction: column; justify-content: flex-end; padding: 30px;
  border-radius: 16px; background: color-mix(in srgb, #ffffff 38%, transparent);
  backdrop-filter: blur(14px) saturate(1.1); -webkit-backdrop-filter: blur(14px) saturate(1.1);
  box-shadow: 0 30px 60px -40px rgba(30, 40, 60, 0.45);
}
.hour::before { content: ""; position: absolute; left: 30px; top: -31px; width: 11px; height: 11px; border-radius: 50%; background: var(--terra); box-shadow: 0 0 0 5px rgba(196, 81, 42, 0.18); }
.hour .t { font-family: var(--serif); font-weight: 300; font-size: clamp(64px, 7vw, 112px); line-height: 0.9; letter-spacing: -0.04em; font-variant-numeric: tabular-nums lining-nums; margin-bottom: auto; will-change: transform; }
.hour h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(22px, 1.8vw, 28px); line-height: 1.15; letter-spacing: -0.01em; margin-bottom: 10px; }
.hour p { font-size: 14.5px; color: var(--muted); line-height: 1.5; max-width: 34ch; }
.hour .tag { margin-top: 16px; font-size: 12px; color: var(--accent); font-weight: 500; }
.hour.photo { color: #fffaf2; overflow: hidden; background: #2b2a33; }
.hour.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.12); will-change: transform; }
.hour.photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 16, 24, 0.05) 30%, rgba(20, 16, 24, 0.75)); }
.hour.photo > * { position: relative; z-index: 1; }
.hour.photo p, .hour.photo .tag { color: rgba(255, 250, 242, 0.86); }
.hour.photo::before { z-index: 2; }

/* ---------- c7 events ---------- */
.ev-text { position: absolute; left: var(--gutter); top: 50%; transform: translateY(-50%); width: min(38vw, 540px); }
.ev-text > h2 { font-size: clamp(40px, 4.4vw, 72px); margin-bottom: 14px; }
.ev-text > .lede { margin-bottom: 40px; }
.ev-text .items { min-height: 260px; }
.ev-kind { font-size: 13px; color: var(--accent); font-weight: 500; margin-bottom: 10px; }
.ev-title { font-family: var(--serif); font-weight: 300; font-size: clamp(30px, 2.8vw, 46px); line-height: 1.04; letter-spacing: -0.02em; margin-bottom: 14px; }
.ev-meta { font-size: 15px; color: var(--muted); margin-bottom: 18px; }
.seats { display: flex; align-items: baseline; gap: 10px; margin-bottom: 22px; font-size: 14px; }
.seats b { font-family: var(--serif); font-weight: 300; font-size: 44px; line-height: 1; color: var(--fg); font-variant-numeric: tabular-nums; letter-spacing: -0.03em; }
.chips { position: absolute; right: var(--gutter); bottom: 7vh; display: flex; gap: 10px; z-index: 3; }
.chips.stacked { display: block; width: 92px; height: 104px; }
.chip {
  width: 92px; height: 104px; border-radius: 14px; background: #fffaf2; color: var(--ink);
  display: grid; place-content: center; text-align: center; box-shadow: 0 18px 40px -22px rgba(60, 20, 10, 0.55);
}
.chips.stacked .chip { position: absolute; left: 0; top: 0; }
.chips.stacked .chip:nth-child(2) { transform: rotate(-6deg); }
.chips.stacked .chip:nth-child(3) { transform: rotate(5deg); }
.chip b { font-family: var(--serif); font-weight: 300; font-size: 38px; line-height: 1; }
.chip small { font-size: 11px; font-weight: 600; letter-spacing: 0.08em; color: var(--terra); }
.chips-cap { position: absolute; right: var(--gutter); bottom: calc(7vh + 116px); font-size: 12px; color: var(--muted); z-index: 3; }

/* ---------- c8 night ---------- */
.night-head { position: absolute; left: var(--gutter); top: 104px; z-index: 3; color: #f6f1e9; }
.night-head h2 { font-size: clamp(48px, 6vw, 104px); margin-bottom: 16px; }
.night-head .lede { color: rgba(246, 241, 233, 0.72); }
.facade { position: absolute; left: 50%; bottom: 0; width: min(980px, 82vw, 118vh); transform: translateX(-50%); z-index: 2; }
.facade svg { width: 100%; height: auto; display: block; }
.facade .wall { fill: #1b1626; }
.facade .trim { fill: #241e31; }
.facade .win { fill: #2a2438; }
.facade .glow { fill: #ffc77a; opacity: 0; }
.facade .halo { fill: url(#winHalo); opacity: 0; }
.facade .rail { stroke: #3a3248; stroke-width: 2; fill: none; }
.facade .sign { font-family: var(--serif); font-style: italic; fill: #ffd9a6; font-size: 26px; opacity: 0; }
.night-photo { position: absolute; inset: 0; z-index: 4; clip-path: inset(50% 50% 50% 50%); will-change: clip-path; }
.night-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.25); }
.night-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(18, 12, 10, 0.86) 0%, rgba(18, 12, 10, 0.4) 55%, rgba(18, 12, 10, 0.1) 100%); }
.night-card { position: absolute; left: var(--gutter); top: 50%; transform: translateY(-46%); z-index: 5; color: #f6f1e9; width: min(560px, 86vw); --fg: #f6f1e9; }
.night-card .ev-kind { color: #ffb48a; }
.night-card h3 { font-family: var(--serif); font-weight: 300; font-size: clamp(46px, 5.4vw, 92px); line-height: 0.98; letter-spacing: -0.03em; margin-bottom: 18px; }
.night-card h3 em { color: #ffb48a; }
.night-card p { color: rgba(246, 241, 233, 0.8); max-width: 40ch; margin-bottom: 18px; font-size: 16px; }
.night-card .row { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; margin-top: 26px; }
.night-card .seats b { color: #f6f1e9; }
.btn.done { background: #3f6b4e; }

/* ---------- c9 profile ---------- */
.pf-text { position: absolute; left: var(--gutter); top: 50%; transform: translateY(-48%); width: min(40vw, 540px); color: #f6f1e9; --fg: #f6f1e9; }
.pf-text .items { min-height: 470px; }
.pf-text h2 { font-size: clamp(42px, 4.6vw, 76px); margin-bottom: 12px; }
.pf-name { font-size: 15px; color: var(--muted); margin-bottom: 20px; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; }
.badge { font-size: 12.5px; padding: 7px 12px; border-radius: 999px; border: 1px solid rgba(246, 241, 233, 0.24); display: inline-flex; gap: 7px; align-items: center; }
.badge i { width: 6px; height: 6px; border-radius: 50%; background: #ffb48a; }
.ledger { list-style: none; border-top: 1px solid rgba(246, 241, 233, 0.16); margin-bottom: 22px; }
.ledger li { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 0; border-bottom: 1px solid rgba(246, 241, 233, 0.16); font-size: 14.5px; color: rgba(246, 241, 233, 0.74); }
.ledger li b { font-family: var(--serif); font-weight: 300; font-size: 30px; color: #f6f1e9; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.code { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; font-size: 14px; color: rgba(246, 241, 233, 0.74); }
.code button { font-family: var(--serif); font-size: 20px; letter-spacing: 0.04em; color: #f6f1e9; border: 1px dashed rgba(255, 180, 138, 0.7); padding: 8px 16px; border-radius: 10px; min-height: 44px; }
.pass-rows { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 24px; margin: 6px 0 28px; }
.pass-rows small { display: block; font-size: 12px; color: rgba(246, 241, 233, 0.6); margin-bottom: 2px; }
.pass-rows b { font-family: var(--serif); font-weight: 300; font-size: 24px; }
.btn.wallet { background: #f6f1e9; color: var(--ink); box-shadow: none; }

/* ---------- c10 close ---------- */
#c10 .layer { display: grid; place-items: center; text-align: center; color: #f6f1e9; --fg: #f6f1e9; }
.close-in { display: grid; justify-items: center; gap: 30px; padding: 0 var(--gutter); }
.close-mark { font-family: var(--serif); font-weight: 300; font-size: clamp(34px, 3.4vw, 52px); letter-spacing: -0.02em; }
.close-mark em { color: #ffb48a; }
.close-title { font-size: clamp(54px, 9vw, 156px); max-width: 11ch; }
.close-title em { color: #ffb48a; }
.close-sub { color: rgba(246, 241, 233, 0.72); max-width: 36ch; font-size: clamp(15px, 1.2vw, 18px); }
.foot { position: absolute; left: var(--gutter); right: var(--gutter); bottom: 28px; display: flex; justify-content: space-between; font-size: 12px; color: rgba(246, 241, 233, 0.55); z-index: 3; gap: 16px; flex-wrap: wrap; }

/* fallback slots (no WebGL) */
.fb-slot { display: none; }
.no-gl .fb-slot { display: block; position: absolute; z-index: 1; }
.no-gl .fb-slot canvas, .no-gl .fb-slot img { width: 100%; height: auto; display: block; border-radius: 6px; box-shadow: 0 30px 60px -30px rgba(40, 20, 10, 0.55); }
.no-gl #c3 .fb-slot { right: 10vw; top: 22vh; width: min(24vw, 300px); }
.no-gl #c4 .fb-slot { left: 10vw; top: 24vh; width: min(30vw, 400px); }
.no-gl #c5 .fb-slot { right: 8vw; top: 20vh; width: min(34vw, 460px); }
.no-gl #c7 .fb-slot { right: 8vw; top: 26vh; width: min(34vw, 460px); }
.no-gl #c9 .fb-slot { right: 9vw; top: 30vh; width: min(32vw, 440px); }
.no-gl body, body.no-gl { background: var(--skybg, var(--cream)); transition: background 0.6s; }

/* ---------- reduced motion ---------- */
.rm .grain { animation: none; }
.rm .scroll-cue i::after { animation: none; }

/* ---------- mobile ---------- */
@media (max-width: 760px) {
  .hud { grid-template-columns: 1fr auto; padding-top: 14px; }
  .hud-chapter { display: none; }
  .sample { font-size: 10.5px; padding: 5px 9px; }
  .sound { padding: 5px 9px; }
  .sound .lbl { display: none; }
  .hud-logo { font-size: 19px; }
  .hud-progress { margin-top: 12px; }
  .intro-title .w2 { margin-right: -0.6em; }
  .manifesto { font-size: clamp(40px, 11.5vw, 60px); }
  .manifesto-sub { margin-left: 0; margin-top: 30px; }
  .dive-title { top: 13vh; }
  .dive-side { right: var(--gutter); bottom: 7vh; }
  .ribbon { top: 70px; }
  .books-text, .vinyl-text, .ev-text, .pf-text { left: var(--gutter); right: var(--gutter); width: auto; top: auto; bottom: 5vh; transform: none; }
  .book-title { font-size: 44px; }
  .books-text .quote, .vinyl-text .quote { font-size: 19px; margin-bottom: 14px; }
  .book-author { margin-bottom: 14px; }
  .books-text .by { margin-bottom: 8px; }
  .vinyl-text h2 { font-size: 42px; margin: 6px 0 10px; }
  .tracks li:nth-child(n + 4) { display: none; }
  .tracks li { padding: 7px 0; font-size: 13.5px; }
  .tracks { margin-bottom: 8px; }
  .wave { display: none; }
  .places-text { width: auto; right: var(--gutter); bottom: 5vh; }
  .place-name { font-size: 44px; }
  .map { width: 132px; top: 76px; }
  .map .pin text { display: none; }
  .map-cap { display: none; }
  .day-head { top: 80px; }
  .day-head h2 { font-size: 34px; }
  .sunarc { display: none; }
  .track { padding-left: var(--gutter); gap: 18px; }
  .track-line { top: calc(100% - 9vh - 52vh - 26px); }
  .hour { width: 76vw; height: 52vh; min-height: 0; padding: 22px; }
  .hour::before { left: 22px; }
  .ev-text > h2 { font-size: 34px; margin-bottom: 8px; }
  .ev-text > .lede { display: none; }
  .ev-text .items { min-height: 230px; }
  .ev-title { font-size: 28px; }
  .seats b { font-size: 34px; }
  .chips, .chips.stacked, .chips-cap { display: none; }
  .ribbon { display: none; }
  .ev-text .items { margin-top: 18px; }
  .night-head { top: 84px; }
  .night-card { top: auto; bottom: 7vh; transform: none; }
  .night-card h3 { font-size: 44px; }
  .pf-text h2 { font-size: 34px; }
  .pf-text .items { min-height: 380px; }
  .ledger li { padding: 7px 0; }
  .ledger li b { font-size: 22px; }
  .badges { margin-bottom: 14px; }
  .pf-name { margin-bottom: 12px; }
  .pass-rows b { font-size: 19px; }
  .foot { justify-content: center; text-align: center; }
}
