/* RUNX Seattle — splash v2 "Aperture" (from deck Splash 01) */
:root {
  --ink: #000000;
  --paper: #F5F7DF;
  --energy: #DDFF00;

  --display: "degular-variable", "Degular Variable", "Degular Display", "Degular", "Inter", "Helvetica Neue", Arial, sans-serif;
  --text: "Inter", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: "Italian Plate No1 Mono", "DM Mono", ui-monospace, Menlo, monospace;

  --pad: clamp(20px, 5vw, 72px);
  --lockup-w: clamp(260px, 36vw, 560px);

  /* motion: same extreme, elegant curve pair as v1 */
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-in-out: cubic-bezier(.87, 0, .13, 1);

  /* X mask state, written by main.js (px) */
  --mx: 0px; --my: 0px; --ms: 0px;

  --x-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 458.23 457.4'%3E%3Cpolygon points='343.61 457.4 229.17 343.01 114.68 457.39 0 342.86 114.42 228.67 .02 114.42 114.66 .02 229.14 114.33 343.58 0 458.23 114.44 343.75 228.68 458.12 342.75 343.61 457.4'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
html { background: var(--ink); -webkit-text-size-adjust: 100%; }
body { margin: 0; overflow: hidden; overscroll-behavior: none; background: var(--ink); color: var(--paper); font: 500 16px/1.4 var(--text); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
svg { display: block; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
[hidden] { display: none !important; } /* component display rules must never override the hidden attribute */

/* ---------- pills ---------- */
.pill {
  display: inline-flex; align-items: center; justify-content: center; white-space: nowrap;
  border: 0; border-radius: 999px; background: var(--energy); color: var(--ink); text-decoration: none; cursor: pointer;
  font-family: var(--display); font-weight: 500; font-variation-settings: "opsz" 72; text-transform: uppercase; letter-spacing: -.01em;
  transition: background .8s var(--ease-out);
}
.pill--sm { height: 40px; padding: 0 18px; font-size: 13px; }
.pill--lg { height: clamp(50px, 4.2vw, 60px); padding: 0 clamp(24px, 2.8vw, 42px); font-size: clamp(17px, 1.5vw, 22px); }
.pill--static { cursor: default; }
a.pill:hover, a.pill:focus-visible { background: var(--paper); }
a.pill:focus-visible, button:focus-visible { outline: 2px solid var(--energy); outline-offset: 3px; }

/* ---------- loader ---------- */
.loader { position: fixed; inset: 0; z-index: 40; pointer-events: none; transition: opacity .6s var(--ease-out); }
.loader__x { position: absolute; left: 50%; top: 50%; width: 40px; translate: -50% -50%; fill: var(--energy); animation: pulse 1.4s var(--ease-in-out) infinite; }
@keyframes pulse { 0%, 100% { scale: .78; } 50% { scale: 1; } }
.loader__count { position: absolute; left: var(--pad); bottom: 28px; font: 500 clamp(24px, 2.4vw, 34px)/1 var(--mono); font-variant-numeric: tabular-nums; }
body:not(.is-loading) .loader { opacity: 0; }
.is-loading .nav, .is-loading .page--hero, .is-loading .bleed { opacity: 0; }

/* ---------- photo layer seen through the X ---------- */
.bleed {
  position: fixed; inset: 0; z-index: 1; overflow: hidden;
  -webkit-mask: var(--x-mask) no-repeat; mask: var(--x-mask) no-repeat;
  -webkit-mask-size: var(--ms) var(--ms); mask-size: var(--ms) var(--ms);
  -webkit-mask-position: var(--mx) var(--my); mask-position: var(--mx) var(--my);
}
.bleed.is-full { -webkit-mask: none; mask: none; }
/* subtle depth only: a few px of pointer drift + a gentle scale, composition never repositioned */
.bleed__move { position: absolute; inset: 0; will-change: transform; transform: translate3d(var(--px, 0px), var(--py, 0px), 0) scale(var(--zoom, 1.03)); }
.photo { position: absolute; inset: 0; opacity: 0; }
.photo.is-on { opacity: 1; }
.photo__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; display: block; }
.bleed__shade { position: absolute; inset: 0; background: var(--ink); opacity: var(--shade, 0); }

/* ---------- nav ---------- */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; padding: clamp(22px, 3vw, 40px) var(--pad); }
.brand { display: flex; align-items: flex-end; gap: .42em; height: clamp(15px, 1.4vw, 21px); text-decoration: none; }
.brand svg { height: 100%; width: auto; fill: currentColor; overflow: visible; }
.brand__mark, .lockup__mark { aspect-ratio: 1020.96 / 268.69; }
.brand__city, .lockup__city { aspect-ratio: 1403.06 / 261.93; }
.brand__city { height: 96%; }
.links { display: flex; align-items: center; gap: clamp(20px, 2.4vw, 36px); font: 500 13px/1 var(--text); letter-spacing: .04em; text-transform: uppercase; }
.links a:not(.pill) { text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; padding-bottom: 3px; transition: background-size .9s var(--ease-out); }
.links a:not(.pill):hover { background-size: 100% 1px; }
.menu { display: none; }

/* ---------- pages ---------- */
.scene { position: fixed; inset: 0; z-index: 2; }
.page { position: absolute; inset: 0; }

.page--hero {
  display: grid; grid-template-columns: minmax(0, 1fr); align-content: center;
  padding: clamp(96px, 11vw, 150px) var(--pad) clamp(64px, 8vw, 110px);
}
.hero__copy { position: relative; z-index: 2; width: var(--lockup-w); }
/* layered pointer parallax: each layer reads its own offset */
.lockup { margin: 0; width: var(--lockup-w); display: grid; gap: clamp(10px, 1.1vw, 18px); translate: var(--l1x, 0px) var(--l1y, 0px); }
.lockup__line { display: block; clip-path: inset(-60% -12% 0 -12%); }
.lockup__line svg { width: 100%; height: auto; fill: var(--paper); overflow: visible; will-change: transform; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: clamp(40px, 6.6vw, 96px); translate: var(--l2x, 0px) var(--l2y, 0px); }
.meta { margin: 30px 0 0; font: 500 13px/1 var(--text); letter-spacing: .06em; text-transform: uppercase; translate: var(--l3x, 0px) var(--l3y, 0px); }

/* the X's zone: everything right of the lockup, below the nav and above the hint.
   main.js fits the largest square in it, centred. */
.x-slot {
  position: absolute; pointer-events: none;
  top: clamp(88px, 11vh, 132px); bottom: clamp(64px, 9vh, 100px);
  left: calc(var(--pad) * 2 + var(--lockup-w)); right: var(--pad);
}

.hint {
  position: absolute; left: 50%; bottom: 22px; translate: -50% 0; z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  border: 0; padding: 0; background: none; color: var(--paper); cursor: pointer;
  font: 500 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .08em;
}
.hint i { width: 1px; height: 30px; background: var(--paper); transform-origin: top; animation: hint 2.2s var(--ease-in-out) infinite; }
@keyframes hint { 0% { scale: 1 0; } 50% { scale: 1 1; } 100% { scale: 1 0; transform-origin: bottom; } }
.replay {
  position: absolute; right: var(--pad); bottom: 26px; z-index: 3;
  border: 0; padding: 6px 0; background: none; color: var(--paper); cursor: pointer;
  font: 500 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .04em; opacity: .55;
  transition: opacity .8s var(--ease-out);
}
.replay:hover, .replay:focus-visible { opacity: 1; }

.page--city {
  z-index: 3; visibility: hidden; overflow-y: auto; overscroll-behavior: contain;
  background: var(--ink); clip-path: inset(100% 0 0 0);
}
.page--city.is-active { visibility: visible; }
.city__inner {
  min-height: 100%; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .82fr); gap: clamp(32px, 5vw, 96px);
  padding: clamp(110px, 12vw, 170px) var(--pad) 28px;
}
.city__main { min-width: 0; display: flex; flex-direction: column; }
.eyebrow { margin: 0 0 26px; font: 500 12px/1 var(--mono); text-transform: uppercase; color: var(--energy); }
.city__title { margin: 0; font-family: var(--display); font-weight: 500; font-variation-settings: "opsz" 72; font-size: clamp(44px, 6.4vw, 116px); line-height: .88; letter-spacing: -.035em; text-transform: uppercase; }
.city__line { display: block; clip-path: inset(-40% -4% 0 -4%); }
.city__line > span { display: block; }
.city__lede { margin: clamp(28px, 3vw, 44px) 0 0; max-width: 36ch; font: 500 clamp(18px, 1.6vw, 24px)/1.35 var(--text); opacity: .85; }
.city__list { list-style: none; margin: auto 0 0; padding: clamp(48px, 6vw, 90px) 0 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--pad); }
.city__list li { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; border-top: 2px solid var(--energy); padding-top: 16px; }
.city__name { font-family: var(--display); font-weight: 500; font-size: clamp(36px, 4.2vw, 68px); line-height: 1; text-transform: uppercase; }
.city__meta { font: 500 12px/1 var(--mono); text-transform: uppercase; color: var(--energy); }
.city__cta { margin-top: clamp(36px, 4vw, 56px); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; font: 500 12px/1.4 var(--mono); text-transform: uppercase; }
.city__foot { margin-top: clamp(36px, 4vw, 56px); display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; font: 500 12px/1.4 var(--mono); text-transform: uppercase; }
.city__foot > * { opacity: .6; transition: opacity .8s var(--ease-out); }
.city__foot > *:hover { opacity: 1; }
.back { border: 0; padding: 0; background: none; color: inherit; font: inherit; text-transform: inherit; cursor: pointer; }

/* waitlist pop-up */
.waitlist {
  --heat: #FF5900;
  width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0;
  border: 0; background: transparent; color: var(--paper);
}
.waitlist[open] { display: grid; place-items: center; }
.waitlist::backdrop { background: rgba(0, 0, 0, .74); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.waitlist__panel {
  position: relative; width: min(560px, calc(100% - 2 * var(--pad))); max-height: calc(100svh - 32px); overflow: auto;
  padding: clamp(28px, 4vw, 48px); background: #0b0b0b; border: 1px solid rgba(245, 247, 223, .14);
}
.waitlist__close {
  position: absolute; top: 16px; right: 16px; width: 40px; height: 40px; display: grid; place-items: center;
  border: 1px solid rgba(245, 247, 223, .25); border-radius: 50%; background: none; cursor: pointer;
  transition: border-color .8s var(--ease-out), rotate .8s var(--ease-out);
}
.waitlist__close svg { width: 12px; fill: var(--paper); }
.waitlist__close:hover, .waitlist__close:focus-visible { border-color: var(--energy); rotate: 90deg; }
.waitlist__eyebrow { margin: 0 0 18px; font: 500 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--energy); }
.waitlist__title { margin: 0; padding-right: 40px; font-family: var(--display); font-weight: 500; font-variation-settings: "opsz" 72; font-size: clamp(40px, 5vw, 64px); line-height: .9; letter-spacing: -.03em; text-transform: uppercase; }
.waitlist__title:focus { outline: none; }
.waitlist__lede { margin: 16px 0 0; max-width: 40ch; font: 500 16px/1.45 var(--text); opacity: .8; }
.waitlist__form { position: relative; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 30px; }
.field { display: grid; gap: 8px; min-width: 0; }
.field--full, .waitlist__error, .waitlist__submit, .waitlist__fine { grid-column: 1 / -1; }
.field label { font: 500 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .06em; opacity: .7; }
.field input {
  width: 100%; height: 52px; padding: 0 18px; border: 1px solid rgba(245, 247, 223, .3); border-radius: 999px;
  background: transparent; color: var(--paper); font: 500 16px/1 var(--text);
  transition: border-color .8s var(--ease-out);
}
.field input:focus { outline: none; border-color: var(--energy); }
.field input[aria-invalid="true"] { border-color: var(--heat); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.waitlist__error { margin: 0; font: 500 13px/1.4 var(--text); color: var(--heat); }
.waitlist__submit { width: 100%; margin-top: 6px; }
.waitlist__submit[disabled] { opacity: .6; cursor: progress; }
.waitlist__fine { margin: 0; font: 500 12px/1.4 var(--text); opacity: .5; }
.waitlist__done { display: grid; justify-items: start; }
.waitlist__mark { width: 44px; margin-bottom: 26px; fill: var(--energy); }
.waitlist__done .pill { margin-top: 30px; }

/* large-format slideshow (page 2, right) */
.city__show { position: relative; margin: 0; min-height: 420px; overflow: hidden; background: #0b0b0b; }
.city__show::after { content: ""; position: absolute; inset: auto 0 0 0; height: 28%; z-index: 3; pointer-events: none; background: linear-gradient(to top, rgba(0, 0, 0, .5), transparent); }
.show__slide { position: absolute; inset: 0; overflow: hidden; opacity: 0; }
.show__slide.is-on { opacity: 1; }
.show__slide img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; will-change: transform; }
.show__hit { position: absolute; inset: 0; z-index: 5; border: 0; padding: 0; background: none; cursor: pointer; }
.show__hit:focus-visible { outline: 2px solid var(--energy); outline-offset: -4px; }
.show__meta {
  position: absolute; left: clamp(16px, 1.6vw, 24px); right: clamp(16px, 1.6vw, 24px); bottom: clamp(14px, 1.4vw, 22px); z-index: 4;
  display: flex; align-items: center; gap: 10px; pointer-events: none;
  font: 500 12px/1 var(--mono); text-transform: uppercase; color: var(--paper); font-variant-numeric: tabular-nums;
}
.show__total { opacity: .6; }
.show__bar { position: relative; flex: 1; height: 1px; margin-left: 8px; overflow: hidden; background: rgba(245, 247, 223, .28); }
.show__bar i { position: absolute; inset: 0; background: var(--energy); transform-origin: left center; transform: scaleX(0); }

/* ---------- mobile ---------- */
@media (max-width: 760px) {
  :root { --lockup-w: min(64vw, 300px); }
  .links { gap: 0; }
  /* Mobile framing: the photo is a still full-screen backdrop that the X cuts a window into —
     it never scales with the X. --mpos/--mscale/--mshift (set per image) simply park the
     subject where the X window sits, and stay fixed through the whole sequence. */
  .photo__img { object-position: var(--mpos, 50% 50%); }
  .photo { transform: translateY(var(--mshift, 0px)) scale(var(--mscale, 1)); }
  .waitlist__form { grid-template-columns: minmax(0, 1fr); }
  .page--hero {
    --slot-h: min(calc(100vw - 2 * var(--pad)), 46svh);
    align-content: start; justify-items: center; text-align: center;
    padding-top: calc(78px + var(--slot-h) + 28px); padding-bottom: 90px;
  }
  .x-slot { top: 78px; bottom: auto; left: var(--pad); right: var(--pad); height: var(--slot-h); }
  .hero__copy { width: auto; }
  .lockup { margin-inline: auto; }
  .actions { justify-content: center; margin-top: 26px; }
  .meta { margin-top: 20px; }
  .replay { display: none; }
  /* page 2 stacks: headline, slideshow, then details */
  .city__inner { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .city__main { display: contents; }
  .page--city .eyebrow { order: 1; }
  .city__title { order: 2; }
  .city__show { order: 3; min-height: 0; aspect-ratio: 4 / 5; margin-top: 28px; }
  .city__lede { order: 4; }
  .city__list { order: 5; }
  .city__cta { order: 6; }
  .city__foot { order: 7; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .loader { display: none; }
  .replay { display: none; }
  .loader__x, .hint i { animation: none; }
}
