/* MaxHoj Creative Works
   Noir black and white with pops of red.
   Base styles = a normal page (flat mode, no-JS). [data-mode="world"] turns it into the 3D alley. */

:root {
  --ink: #0B0B0B;
  --ink-2: #141414;
  --ink-3: #1d1d1d;
  --bone: #F2EFE9;
  --bone-dim: rgba(242, 239, 233, 0.66);
  --bone-faint: rgba(242, 239, 233, 0.16);
  --red: #C1121F;
  --red-hot: #e0182a;
  --display: "Limelight", "Didot", "Bodoni 72", Georgia, serif;
  --type: "Courier Prime", "Courier New", ui-monospace, monospace;
  --gutter: clamp(16px, 5vw, 48px);
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { background: var(--ink); -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font-family: var(--type);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* film grain over everything */
body::after {
  content: "";
  position: fixed;
  inset: -50%;
  pointer-events: none;
  z-index: 90;
  opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -4%); }
  60% { transform: translate(-4%, -1%); }
  80% { transform: translate(3%, 3%); }
  100% { transform: translate(0, 0); }
}
@media (prefers-reduced-motion: reduce) { body::after { animation: none; } }

a { color: inherit; }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--bone); color: var(--ink); padding: 8px 12px; text-decoration: none;
}
.skip:focus { top: 12px; }

/* ---------- shared type ---------- */
.kicker {
  margin: 0 0 .75rem;
  font-family: var(--type);
  font-weight: 700;
  font-size: .78rem;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--bone-dim);
}
.kicker-red { color: var(--red-hot); }

.rule-red {
  display: block;
  width: 64px;
  height: 3px;
  background: var(--red);
  margin: 1.25rem 0 1.5rem;
}

.lead {
  font-size: clamp(1.05rem, 2.6vw, 1.3rem);
  line-height: 1.5;
  max-width: 38ch;
  margin: 0 0 2rem;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6em;
  min-height: 48px;
  padding: .8em 1.6em;
  border: 1px solid var(--bone);
  background: transparent;
  font-family: var(--type);
  font-weight: 700;
  font-size: .85rem;
  letter-spacing: .24em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease), transform .2s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn-red { background: var(--red); border-color: var(--red); color: var(--bone); }
.btn-red:hover { background: var(--red-hot); border-color: var(--red-hot); }
.btn-red:disabled { background: transparent; border-color: var(--bone-faint); color: var(--bone-dim); cursor: wait; }
.btn-ghost:hover { background: var(--bone); color: var(--ink); }

.link-btn {
  background: none; border: 0; padding: .5em 0; cursor: pointer;
  font-size: .85rem; letter-spacing: .08em; color: var(--bone-dim);
  text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--bone-faint);
}
.link-btn:hover { color: var(--bone); text-decoration-color: var(--red); }

/* ---------- top bar ---------- */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(14px + env(safe-area-inset-top)) var(--gutter) 14px;
  pointer-events: none;
  background: linear-gradient(var(--ink) 62%, rgba(11, 11, 11, 0));
}
.topbar > * { pointer-events: auto; }
.wordmark { text-decoration: none; display: flex; flex-direction: column; line-height: 1; }
.wm-name { font-family: var(--display); font-size: 1.45rem; letter-spacing: .06em; }
.wm-sub { font-size: .62rem; letter-spacing: .3em; text-transform: uppercase; color: var(--bone-dim); margin-top: 5px; }

.menu-btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 0 16px;
  background: rgba(11, 11, 11, .72);
  border: 1px solid var(--bone-faint);
  cursor: pointer;
  font-weight: 700; font-size: .75rem; letter-spacing: .28em; text-transform: uppercase;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.menu-btn:hover { border-color: var(--bone); }
.menu-btn-bars, .menu-btn-bars::before {
  display: block; width: 18px; height: 2px; background: var(--bone); position: relative;
  transition: transform .25s var(--ease);
}
.menu-btn-bars::before { content: ""; position: absolute; top: 6px; width: 12px; background: var(--red); }
.menu-btn[aria-expanded="true"] .menu-btn-bars { transform: translateY(3px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .menu-btn-bars::before { width: 18px; top: 0; transform: rotate(-90deg); background: var(--bone); }

/* ---------- menu overlay ---------- */
.menu {
  position: fixed; inset: 0; z-index: 55;
  background: rgba(11, 11, 11, .96);
  display: flex; align-items: center;
  padding: 96px var(--gutter) 48px;
  overflow-y: auto;
}
.menu[hidden] { display: none; }
.menu-inner { width: 100%; max-width: 900px; margin: 0 auto; }
.menu-list { list-style: none; margin: 0 0 2rem; padding: 0; }
.menu-list li { border-top: 1px solid var(--bone-faint); }
.menu-list li:last-child { border-bottom: 1px solid var(--bone-faint); }
.menu-list a {
  display: block; padding: .45em 0;
  font-family: var(--display); font-size: clamp(1.9rem, 7vw, 3.4rem); line-height: 1.15;
  text-decoration: none;
  transition: color .2s var(--ease), padding .25s var(--ease);
}
.menu-list a:hover, .menu-list a:focus-visible { padding-left: .4em; }
.menu-list a.menu-red { color: var(--red-hot); }

/* ---------- flat page: lobby ---------- */
.lobby {
  min-height: 100svh;
  display: flex; align-items: center;
  padding: 120px var(--gutter) 72px;
  background:
    repeating-linear-gradient(-28deg, rgba(242, 239, 233, .035) 0 22px, transparent 22px 54px),
    radial-gradient(120% 80% at 80% 10%, #1b1b1b, var(--ink) 60%);
}
.lobby-inner { width: 100%; max-width: 1100px; margin: 0 auto; }
.lobby-title {
  font-family: var(--display); font-weight: 400;
  font-size: clamp(3rem, 12vw, 7.5rem); line-height: .95; letter-spacing: .01em;
  margin: 0;
}
.door-list { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); margin-bottom: 1.5rem; }

.plate {
  position: relative;
  display: flex; flex-direction: column; gap: 6px;
  padding: 18px 20px 20px;
  border: 1px solid var(--bone-faint);
  text-decoration: none;
  background: linear-gradient(var(--ink-2), var(--ink));
  transition: border-color .2s var(--ease), transform .2s var(--ease);
}
.plate::before {
  content: ""; position: absolute; inset: 5px; border: 1px solid rgba(242, 239, 233, .08); pointer-events: none;
}
.plate:hover { border-color: var(--bone); transform: translateY(-2px); }
.plate-no { font-size: .7rem; letter-spacing: .3em; text-transform: uppercase; color: var(--bone-dim); }
.plate-name { font-family: var(--display); font-size: 1.6rem; line-height: 1.1; }
.plate-red { border-color: var(--red); }
.plate-red .plate-no { color: var(--red-hot); }
.plate-red:hover { border-color: var(--red-hot); box-shadow: 0 0 0 1px var(--red) inset, 0 10px 40px -12px rgba(193, 18, 31, .6); }

/* ---------- screens (sections) ---------- */
.screen {
  position: relative;
  padding: 96px var(--gutter);
  border-top: 1px solid var(--bone-faint);
  background:
    repeating-linear-gradient(-28deg, rgba(242, 239, 233, .025) 0 18px, transparent 18px 60px),
    var(--ink);
  outline: none;
}
.screen-inner { max-width: 900px; margin: 0 auto; }
.screen-title {
  font-family: var(--display); font-weight: 400;
  font-size: clamp(2.8rem, 11vw, 6.5rem); line-height: .95; margin: 0;
}

.planned {
  position: relative;
  border: 1px dashed var(--bone-faint);
  padding: 28px 24px 22px;
  margin: 0 0 2.5rem;
  max-width: 640px;
}
.planned h3 { margin: 0 0 .9rem; font-size: .8rem; letter-spacing: .28em; text-transform: uppercase; color: var(--bone-dim); }
.planned ul { margin: 0; padding: 0; list-style: none; }
.planned li { padding: .5em 0 .5em 1.6em; position: relative; border-top: 1px solid rgba(242, 239, 233, .07); }
.planned li:first-child { border-top: 0; }
.planned li::before { content: ""; position: absolute; left: 0; top: 1.05em; width: .8em; height: 1px; background: var(--bone-dim); }
.stamp {
  position: absolute; top: -13px; right: 16px; margin: 0;
  padding: 3px 10px;
  border: 2px solid var(--red); color: var(--red-hot); background: var(--ink);
  font-weight: 700; font-size: .66rem; letter-spacing: .24em; text-transform: uppercase;
  transform: rotate(-3deg);
}

/* ---------- contact form ---------- */
.contact-form {
  display: grid; gap: 18px 20px;
  grid-template-columns: 1fr;
  max-width: 720px;
  margin: 0 0 2.5rem;
}
@media (min-width: 640px) { .contact-form { grid-template-columns: 1fr 1fr; } .field-wide, .form-foot { grid-column: 1 / -1; } }
.field { display: flex; flex-direction: column; gap: 8px; }
.field label { font-weight: 700; font-size: .74rem; letter-spacing: .26em; text-transform: uppercase; }
.field .opt { font-weight: 400; letter-spacing: .1em; text-transform: none; color: var(--bone-dim); margin-left: .4em; }
.field input, .field select, .field textarea {
  width: 100%;
  font: inherit; font-size: 16px; color: var(--bone);
  background: var(--ink-2);
  border: 0; border-bottom: 1px solid rgba(242, 239, 233, .4);
  border-radius: 0;
  padding: 12px 14px;
  transition: border-color .2s var(--ease), background .2s var(--ease);
  -webkit-appearance: none; appearance: none;
}
.field textarea { resize: vertical; min-height: 140px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom-color: var(--red); background: var(--ink-3); }
.field [aria-invalid="true"] { border-bottom-color: var(--red-hot); }
.select-wrap { position: relative; }
.select-wrap::after {
  content: ""; position: absolute; right: 16px; top: 50%; width: 8px; height: 8px; margin-top: -6px;
  border-right: 2px solid var(--bone); border-bottom: 2px solid var(--bone); transform: rotate(45deg); pointer-events: none;
}
.field select option { background: var(--ink-2); color: var(--bone); }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; }
.form-status { margin: 0; font-size: .92rem; color: var(--bone-dim); max-width: 46ch; }
.form-status.is-error { color: var(--red-hot); }

.screen-red { background:
  radial-gradient(90% 60% at 50% 0%, rgba(193, 18, 31, .16), transparent 70%),
  repeating-linear-gradient(-28deg, rgba(242, 239, 233, .025) 0 18px, transparent 18px 60px),
  var(--ink); }

/* hidden-by-default bits that only matter in world mode */
#world, .hud, .intro, .curtain { display: none; }


/* =====================================================================
   WORLD MODE: the alley is the front door, sections become screens
   ===================================================================== */
[data-mode="world"] body { overflow: hidden; height: 100svh; overscroll-behavior: none; }
[data-mode="world"] .lobby { display: none; }

[data-mode="world"] #world { display: block; position: fixed; inset: 0; z-index: 0; background: var(--ink); }
[data-mode="world"] #stage, [data-mode="world"] #stage canvas {
  position: absolute; inset: 0; width: 100%; height: 100%; display: block;
  touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
  cursor: grab;
}
[data-mode="world"] #stage canvas:active { cursor: grabbing; }
[data-mode="world"] #stage.is-door canvas { cursor: pointer; }

/* screens as full-screen overlays */
[data-mode="world"] .screen {
  position: fixed; inset: 0; z-index: 40;
  border-top: 0;
  overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
  padding-top: 110px; padding-bottom: 80px;
  opacity: 0; visibility: hidden;
  transition: opacity .45s var(--ease), visibility 0s linear .45s;
}
[data-mode="world"] .screen.is-open { opacity: 1; visibility: visible; transition: opacity .45s var(--ease), visibility 0s; }
[data-mode="world"] .screen .screen-inner { transform: translateY(18px); transition: transform .6s var(--ease); }
[data-mode="world"] .screen.is-open .screen-inner { transform: none; }

/* HUD */
[data-mode="world"] .hud { display: block; position: fixed; inset: 0; z-index: 20; pointer-events: none; }
.hud > * { pointer-events: auto; }
.intro-on .hud { visibility: hidden; }
/* the alley draws its own film grain, so the page grain steps aside while you walk */
body.alley-live::after { display: none; }

.hint {
  position: absolute; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  margin: 0; padding: 8px 14px; width: max-content; max-width: calc(100% - 32px);
  font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; text-align: center;
  color: var(--bone-dim); background: rgba(11, 11, 11, .6);
  pointer-events: none;
  transition: opacity .8s var(--ease);
}
.hud.has-moved .hint { opacity: 0; }
.hint-touch { display: none; }

.prompt {
  position: absolute; left: 50%; bottom: calc(76px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  display: flex; align-items: center; gap: 14px;
  padding: 10px 10px 10px 18px;
  background: rgba(11, 11, 11, .86);
  border: 1px solid var(--bone-faint);
  white-space: nowrap;
  animation: rise .35s var(--ease);
}
.prompt[hidden] { display: none; }
.prompt.is-red { border-color: var(--red); }
.prompt-kicker { font-size: .64rem; letter-spacing: .3em; text-transform: uppercase; color: var(--bone-dim); }
.prompt-label { font-family: var(--display); font-size: 1.5rem; line-height: 1; color: var(--bone); }
.prompt-btn {
  min-height: 40px; padding: 0 16px; cursor: pointer;
  background: var(--bone); color: var(--ink); border: 0;
  font-weight: 700; font-size: .72rem; letter-spacing: .24em; text-transform: uppercase;
}
.prompt.is-red .prompt-btn { background: var(--red); color: var(--bone); }
.prompt-btn kbd { font: inherit; opacity: .6; margin-left: .4em; }
@keyframes rise { from { opacity: 0; transform: translate(-50%, 8px); } to { opacity: 1; transform: translate(-50%, 0); } }

.dpad { display: none; }

/* touch devices: on-screen arrows */
@media (hover: none) and (pointer: coarse) {
  .hint-desk { display: none; }
  .hint-touch { display: block; }
  [data-mode="world"] .dpad {
    display: grid;
    position: absolute; left: calc(16px + env(safe-area-inset-left)); bottom: calc(16px + env(safe-area-inset-bottom));
    grid-template-columns: repeat(3, 52px); grid-template-rows: repeat(3, 52px); gap: 4px;
  }
  .hint { bottom: auto; top: calc(124px + env(safe-area-inset-top)); }
  .prompt { left: auto; right: calc(16px + env(safe-area-inset-right)); bottom: calc(36px + env(safe-area-inset-bottom)); transform: none; flex-direction: column; align-items: flex-end; gap: 6px; padding: 10px; }
  @keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
  .prompt-btn { min-height: 48px; padding: 0 22px; }
}
.dp {
  display: grid; place-items: center;
  background: rgba(11, 11, 11, .55); border: 1px solid rgba(242, 239, 233, .28);
  touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
  cursor: pointer; padding: 0;
}
.dp svg { width: 20px; height: 20px; fill: var(--bone); }
.dp.is-down { background: rgba(242, 239, 233, .2); border-color: var(--bone); }
.dp-up { grid-area: 1 / 2; } .dp-left { grid-area: 2 / 1; } .dp-right { grid-area: 2 / 3; } .dp-down { grid-area: 3 / 2; }

/* intro title card */
[data-mode="world"] .intro {
  display: flex; align-items: center; justify-content: center;
  position: fixed; inset: 0; z-index: 30;
  padding: 90px var(--gutter) 40px;
  background: radial-gradient(65% 55% at 50% 50%, rgba(11, 11, 11, .62), rgba(11, 11, 11, .2) 100%);
  transition: opacity .7s var(--ease), visibility 0s linear .7s;
}
[data-mode="world"] .intro.is-gone { opacity: 0; visibility: hidden; pointer-events: none; }
.intro-card { text-align: center; max-width: 560px; display: flex; flex-direction: column; align-items: center; }
.intro-kicker { margin: 0 0 1rem; font-size: .72rem; letter-spacing: .36em; text-transform: uppercase; color: var(--bone-dim); }
.intro-title { font-family: var(--display); font-weight: 400; font-size: clamp(3.6rem, 16vw, 8rem); line-height: .9; margin: 0; letter-spacing: .02em; }
.intro .rule-red { margin: 1.4rem auto 1.4rem; }
.intro-line { margin: 0 0 1rem; font-size: clamp(1rem, 2.8vw, 1.2rem); }
.intro-small { margin: 0 0 2rem; font-size: .9rem; color: var(--bone-dim); max-width: 40ch; }
.intro-go { min-width: 240px; }
.intro-go .go-loading { display: none; }
.intro-go:disabled .go-ready { display: none; }
.intro-go:disabled .go-loading { display: inline; }
.intro-skip { margin-top: 1rem; }

/* black cut between alley and a door */
[data-mode="world"] .curtain {
  display: block; position: fixed; inset: 0; z-index: 35; background: #000;
  opacity: 0; pointer-events: none; transition: opacity .35s ease;
}
[data-mode="world"] .curtain.is-down { opacity: 1; }

[data-mode="world"] .menu { z-index: 58; }

@media (prefers-reduced-motion: reduce) {
  [data-mode="world"] .screen, [data-mode="world"] .screen .screen-inner, .intro, .curtain, .prompt { transition: none !important; animation: none !important; }
}


/* =====================================================================
   ROOMS: the contact form as a panel, the host's dialogue
   ===================================================================== */

/* Netlify honeypot: present for bots, invisible to people */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.panel-close { display: none; }

/* in world mode the contact form floats over the red anteroom */
[data-mode="world"] #contact {
  background: radial-gradient(80% 70% at 50% 40%, rgba(11, 11, 11, .35), rgba(11, 11, 11, .78));
  padding-top: calc(96px + env(safe-area-inset-top, 0px));
}
[data-mode="world"] #contact .screen-inner {
  position: relative;
  max-width: 760px;
  background: rgba(11, 11, 11, .94);
  border: 1px solid rgba(193, 18, 31, .55);
  padding: clamp(24px, 4vw, 40px) clamp(18px, 4vw, 40px);
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .9);
}
[data-mode="world"] #contact .screen-title { font-size: clamp(2.4rem, 8vw, 4.4rem); }
[data-mode="world"] #contact .lead { margin-bottom: 1.5rem; }
[data-mode="world"] #contact .panel-close {
  display: inline-flex; align-items: center;
  min-height: 40px; margin: 0 0 1rem; padding: 0 14px;
  background: transparent; color: var(--bone-dim);
  border: 1px solid var(--bone-faint); cursor: pointer;
  font-weight: 700; font-size: .68rem; letter-spacing: .2em; text-transform: uppercase;
}
[data-mode="world"] #contact .panel-close:hover { color: var(--bone); border-color: var(--bone); }

/* the host's dialogue: bottom of the screen, never covers the controls */
.dialogue { display: none; }
[data-mode="world"] .dialogue:not([hidden]) {
  display: block;
  position: fixed; z-index: 25;
  left: 50%; transform: translateX(-50%);
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  width: min(640px, calc(100% - 32px));
  animation: dlg-in .35s var(--ease);
}
@keyframes dlg-in { from { opacity: 0; transform: translate(-50%, 10px); } to { opacity: 1; transform: translate(-50%, 0); } }
.dlg-card {
  background: rgba(11, 11, 11, .92);
  border: 1px solid var(--bone-faint);
  border-top: 3px solid var(--red);
  padding: 16px 18px 14px;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.dlg-top { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.dlg-face { width: 52px; height: 52px; object-fit: cover; border: 1px solid var(--bone-faint); align-self: center; flex: none; }
.dlg-face + .dlg-speaker { margin-right: auto; }
.about-wrap { display: grid; gap: 24px; align-items: center; margin-bottom: 2rem; }
.about-wrap .lead { margin: 0; }
.about-photo { margin: 0; max-width: 340px; border: 1px solid var(--bone-faint); border-top: 3px solid var(--red); }
.about-photo img { display: block; width: 100%; height: auto; }
@media (min-width: 760px) { .about-wrap { grid-template-columns: minmax(220px, 320px) 1fr; gap: 40px; } }
.dlg-speaker { margin: 0; font-family: var(--display); font-size: 1.5rem; line-height: 1; }
.dlg-speaker span { font-family: var(--type); font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: var(--bone-dim); margin-left: .6em; }
.dlg-close {
  width: 40px; height: 40px; flex: none;
  background: transparent; border: 1px solid var(--bone-faint); cursor: pointer;
  font-size: 1.4rem; line-height: 1; color: var(--bone);
}
.dlg-close:hover { border-color: var(--bone); }
.dlg-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 10px; }
.dlg-tab {
  min-height: 34px; padding: 0 12px;
  background: transparent; border: 1px solid var(--bone-faint); cursor: pointer;
  font-weight: 700; font-size: .66rem; letter-spacing: .2em; text-transform: uppercase; color: var(--bone-dim);
}
.dlg-tab[aria-selected="true"] { color: var(--bone); border-color: var(--bone); }
.dlg-page p { margin: 0; font-size: 1rem; line-height: 1.55; max-width: 60ch; }
.dlg-page .dlg-stamp {
  display: inline-block; margin: 0 0 8px; padding: 2px 8px;
  border: 2px solid var(--red); color: var(--red-hot);
  font-weight: 700; font-size: .62rem; letter-spacing: .22em; text-transform: uppercase;
  transform: rotate(-2deg);
}
.dlg-foot { display: flex; justify-content: flex-end; margin-top: 12px; }
.dlg-foot .btn { min-height: 40px; padding: .5em 1.2em; font-size: .72rem; }

/* on wide screens the dialogue sits to the side so the host stays in view */
@media (min-width: 900px) {
  [data-mode="world"] .dialogue:not([hidden]) {
    left: auto; transform: none;
    right: max(var(--gutter), env(safe-area-inset-right, 0px));
    bottom: calc(96px + env(safe-area-inset-bottom, 0px));
    width: min(440px, 40vw);
    animation-name: dlg-in-side;
  }
}
@keyframes dlg-in-side { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* while the dialogue is up, the on-screen arrows and prompt move out of its way on phones */
@media (hover: none) and (pointer: coarse) {
  [data-mode="world"] .dialogue:not([hidden]) { bottom: auto; top: calc(124px + env(safe-area-inset-top, 0px)); }
}
@media (prefers-reduced-motion: reduce) { .dialogue { animation: none !important; } }

/* sound: one button, and a small panel to mute music, rain or street on their own */
.snd {
  position: absolute;
  top: calc(72px + env(safe-area-inset-top, 0px));
  right: max(var(--gutter), env(safe-area-inset-right, 0px));
  display: flex; flex-direction: column; align-items: flex-end; gap: 6px;
}
.snd-btn {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 40px; padding: 0 12px 0 10px;
  background: rgba(11, 11, 11, .62);
  border: 1px solid var(--bone-faint);
  cursor: pointer;
  font-weight: 700; font-size: .66rem; letter-spacing: .22em; text-transform: uppercase;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  transition: border-color .2s var(--ease);
}
.snd-btn:hover { border-color: var(--bone); }
.snd-btn svg { width: 18px; height: 18px; fill: var(--bone); stroke: var(--bone); }
.snd-btn svg path:first-child { stroke: none; }
/* the state reads at a glance: ON has the red edge and sound waves, OFF a crossed-out speaker,
   and a browser that blocked sound gets a bright button asking for one tap */
.snd-btn .snd-x { display: none; }
.snd-btn:not(.is-on) .snd-wave { display: none; }
.snd-btn:not(.is-on) .snd-x { display: inline; }
.snd-btn.is-on { border-color: var(--red); }
.snd-btn.is-on svg path:first-child { fill: var(--red-hot); }
.snd-btn:not(.is-on):not(.is-blocked) .snd-label { color: var(--bone-dim); }
.snd-btn.is-blocked {
  background: var(--bone); color: var(--ink, #0b0b0b);
  border-color: var(--bone); box-shadow: inset 4px 0 0 var(--red);
  min-height: 44px; padding-left: 14px;
  animation: snd-ask 1.6s var(--ease) infinite;
}
.snd-btn.is-blocked svg { fill: #0b0b0b; stroke: #0b0b0b; }
.snd-btn.is-blocked .snd-label { color: #0b0b0b; }
@keyframes snd-ask { 0%, 100% { outline: 2px solid rgba(193, 18, 31, 0); outline-offset: 2px; } 50% { outline: 2px solid rgba(193, 18, 31, .85); outline-offset: 4px; } }
@media (prefers-reduced-motion: reduce) { .snd-btn.is-blocked { animation: none; outline: 2px solid var(--red); outline-offset: 2px; } }
.snd-panel {
  display: flex; flex-direction: column; gap: 4px;
  padding: 6px;
  background: rgba(11, 11, 11, .9);
  border: 1px solid var(--bone-faint);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.snd-panel[hidden] { display: none; }
.snd-opt {
  display: flex; align-items: center; gap: 10px;
  min-height: 36px; min-width: 132px; padding: 0 12px 0 8px;
  background: transparent; border: 1px solid transparent; cursor: pointer;
  font-weight: 700; font-size: .66rem; letter-spacing: .22em; text-transform: uppercase; color: var(--bone-dim);
  text-align: left;
}
.snd-opt:hover { border-color: var(--bone-faint); color: var(--bone); }
.snd-tick { width: 14px; height: 14px; border: 1px solid var(--bone-dim); flex: none; position: relative; }
.snd-opt[aria-pressed="true"] { color: var(--bone); }
.snd-opt[aria-pressed="true"] .snd-tick { background: var(--red); border-color: var(--red); }
.snd-opt[aria-pressed="true"] .snd-tick::after {
  content: ""; position: absolute; left: 4px; top: 1px; width: 4px; height: 8px;
  border: solid var(--bone); border-width: 0 2px 2px 0; transform: rotate(45deg);
}
@media (hover: none) and (pointer: coarse) {
  .hint { top: calc(172px + env(safe-area-inset-top)); }
  [data-mode="world"] .dialogue:not([hidden]) { top: calc(172px + env(safe-area-inset-top, 0px)); }
}

/* =====================================================================
   real copy: bio, projects
   ===================================================================== */
.lead.bio { max-width: 52ch; }
.cases { list-style: none; margin: 0 0 2.5rem; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); max-width: 820px; }
.case {
  position: relative; padding: 20px 20px 18px;
  border: 1px solid var(--bone-faint);
  background: linear-gradient(var(--ink-2), var(--ink));
}
.case::before { content: ""; position: absolute; left: 20px; top: 0; width: 40px; height: 3px; background: var(--red); }
.case-title { margin: .2rem 0 .5rem; font-family: var(--display); font-weight: 400; font-size: 1.7rem; line-height: 1.05; }
.case-desc { margin: 0; color: var(--bone-dim); font-size: .95rem; line-height: 1.5; }

/* info panel in the rooms: same card as the host's dialogue */
.info .info-body { max-height: min(46vh, 380px); overflow-y: auto; }
.info .info-body p { margin: 0 0 .6rem; font-size: 1rem; line-height: 1.55; max-width: 60ch; }
.info .case-kicker { font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: var(--bone-dim); }

/* =====================================================================
   project videos
   ===================================================================== */
.case-watch {
  display: inline-block; margin-top: .8rem;
  font-weight: 700; font-size: .68rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--bone); text-decoration: none; border-bottom: 2px solid var(--red); padding-bottom: 2px;
}
.case-watch:hover { color: var(--red-hot); }

.video { display: none; }
[data-mode="world"] .video:not([hidden]) {
  display: flex; align-items: center; justify-content: center;
  position: fixed; inset: 0; z-index: 26;
  padding: calc(76px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) calc(20px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
  background: rgba(0, 0, 0, .55);
  pointer-events: none;
  animation: dlg-in-side .3s var(--ease);
}
.video-card {
  pointer-events: auto;
  display: flex; gap: 18px; align-items: stretch;
  max-width: 100%;
  background: rgba(11, 11, 11, .95);
  border: 1px solid var(--bone-faint);
  border-top: 3px solid var(--red);
  padding: 14px;
}
.video-frame {
  position: relative;
  height: min(72vh, 680px);
  aspect-ratio: 9 / 16;
  max-width: 100%;
  background: #000;
  flex: none;
}
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.video-side { display: flex; flex-direction: column; gap: 10px; width: 260px; min-width: 0; }
.video-desc { margin: 0; font-size: .98rem; line-height: 1.55; color: var(--bone-dim); }
.video-desc:empty { display: none; }
.video-link {
  margin-top: auto; align-self: flex-start;
  font-weight: 700; font-size: .68rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--bone); text-decoration: none; border-bottom: 2px solid var(--red); padding-bottom: 2px;
}
.video-link:hover { color: var(--red-hot); }
/* when the player can't load here: a poster that links out */
.video-fallback {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  background: #050505 center / cover no-repeat; color: var(--bone); text-decoration: none; text-align: center; padding: 20px;
}
.video-fallback::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .55); }
.video-fallback > * { position: relative; }
.video-play { width: 74px; height: 74px; border-radius: 50%; background: var(--red); display: grid; place-items: center; }
.video-play::after { content: ""; margin-left: 6px; border-style: solid; border-width: 14px 0 14px 22px; border-color: transparent transparent transparent var(--bone); }
.video-fallback span { font-weight: 700; font-size: .7rem; letter-spacing: .22em; text-transform: uppercase; }

@media (max-width: 720px) {
  .video-card { flex-direction: column; gap: 10px; padding: 10px; }
  .video-frame { height: min(62vh, 560px); align-self: center; }
  .video-side { width: auto; }
}

/* =====================================================================
   QUICK LINKS: the work and the form, one click from anywhere
   ===================================================================== */
.topbar { gap: 10px; }
.top-cta { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.top-cta a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px;
  font-weight: 700; font-size: .7rem; letter-spacing: .24em; text-transform: uppercase; text-decoration: none;
  border: 1px solid var(--bone-faint); background: rgba(11, 11, 11, .72);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  transition: border-color .2s var(--ease), background .2s var(--ease);
}
.top-cta a:hover { border-color: var(--bone); }
.top-cta .top-start { background: var(--red); border-color: var(--red); }
.top-cta .top-start:hover { background: var(--red-hot); border-color: var(--red-hot); }
.top-cta .sm { display: none; }
@media (max-width: 640px) {
  .wm-sub { display: none; }
  .top-cta { gap: 6px; }
  .top-cta a { padding: 0 11px; letter-spacing: .16em; }
  .top-cta .lg { display: none; }
  .top-cta .sm { display: inline; }
}
@media (max-width: 480px) {
  .menu-btn { padding: 0 13px; }
  .menu-btn-label { display: none; }
  .wm-name { font-size: 1.25rem; }
}

/* the entrance: three ways in */
.btn-bone { background: var(--bone); border-color: var(--bone); color: var(--ink); }
.btn-bone:hover { background: #fff; border-color: #fff; }
.btn-bone:disabled { background: transparent; border-color: var(--bone-faint); color: var(--bone-dim); cursor: wait; }
.intro-choices { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; width: 100%; }
.intro-choices .btn { min-width: 0; flex: 1 1 180px; max-width: 240px; padding-left: 1em; padding-right: 1em; }
@media (max-width: 560px) { .intro-choices { flex-direction: column; align-items: stretch; max-width: 300px; } .intro-choices .btn { max-width: none; flex: none; } }
.lobby-choices { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 2rem; }

/* =====================================================================
   THE CASE FILES: the archive
   ===================================================================== */
.screen-files .files-inner { max-width: 1180px; }
.files { margin: 0 0 3rem; }
.files-nojs { margin: 0; padding-left: 1.2em; }
.files-preview {
  margin: 0 0 2rem; padding: 10px 14px; max-width: 720px;
  border: 1px dashed var(--bone-faint); color: var(--bone-dim); font-size: .85rem;
}
.files-preview strong { color: var(--red-hot); letter-spacing: .14em; text-transform: uppercase; font-size: .72rem; margin-right: .4em; }
.files-row { display: grid; gap: 34px 22px; }
.files-featured { grid-template-columns: 1fr; margin-bottom: 3.2rem; }
.files-supporting { grid-template-columns: 1fr; }
@media (min-width: 860px) {
  .files-featured { grid-template-columns: 1fr 1fr; }
  .files-supporting { grid-template-columns: 1fr 1fr; }
}
.files-sub {
  margin: 0 0 1.6rem; font-size: .78rem; letter-spacing: .32em; text-transform: uppercase; color: var(--bone-dim);
  display: flex; align-items: center; gap: 14px;
}
.files-sub::after { content: ""; flex: 1; height: 1px; background: var(--bone-faint); }

.file-card {
  position: relative; display: flex; flex-direction: column;
  margin-top: 16px;
  text-decoration: none; color: var(--bone);
  background: linear-gradient(var(--ink-2), #0e0e0e);
  border: 1px solid var(--bone-faint);
  transition: border-color .25s var(--ease), transform .25s var(--ease), box-shadow .25s var(--ease);
}
/* the folder tab */
.file-card .card-no {
  position: absolute; left: 18px; top: -17px;
  padding: 0 16px; height: 17px; line-height: 19px;
  background: var(--bone); color: var(--ink);
  font-weight: 700; font-size: .62rem; letter-spacing: .24em; text-transform: uppercase;
  clip-path: polygon(8px 0, calc(100% - 8px) 0, 100% 100%, 0 100%);
}
.file-card::after {
  content: ""; position: absolute; left: -1px; bottom: -1px; height: 3px; width: 0;
  background: var(--red); transition: width .35s var(--ease);
}
.file-card:hover, .file-card:focus-visible { border-color: rgba(242, 239, 233, .5); transform: translateY(-3px); box-shadow: 0 24px 50px -28px rgba(0, 0, 0, .9); }
.file-card:hover::after, .file-card:focus-visible::after { width: calc(100% + 2px); }
.file-card:focus-visible { outline-offset: 4px; }

.cover { position: relative; overflow: hidden; background: #141414; aspect-ratio: 3 / 2; }
.cover img { width: 100%; height: 100%; object-fit: cover; transition: filter .5s var(--ease), transform .8s var(--ease); }
.cover img.is-yt { transform: scale(1.36); }      /* a vertical Short's thumbnail comes with black bars; crop into it */
.cover::after {          /* halftone over the print until you look closer */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(rgba(11, 11, 11, .55) 1px, transparent 1.6px) 0 0 / 5px 5px;
  opacity: .35; transition: opacity .5s var(--ease);
}
@media (hover: hover) {
  .card-cover img { filter: grayscale(1) contrast(1.12); }
  .file-card:hover .card-cover img, .file-card:focus-visible .card-cover img { filter: none; }
  .file-card:hover .cover::after, .file-card:focus-visible .cover::after { opacity: 0; }
}
.cover.is-empty { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 10px; padding: 18px; text-align: center; }
.cover.is-empty::after { opacity: .5; }
.cover-no { font-family: var(--display); font-size: clamp(4rem, 12vw, 8rem); line-height: .9; color: transparent; -webkit-text-stroke: 1px rgba(242, 239, 233, .32); }
.cover-note { position: relative; z-index: 1; font-size: .78rem; line-height: 1.45; color: var(--bone-dim); max-width: 40ch; }

.card-body { display: flex; flex-direction: column; gap: 6px; padding: 18px 20px 20px; flex: 1; }
.card-meta { margin: 0; display: flex; gap: 12px; font-size: .64rem; letter-spacing: .26em; text-transform: uppercase; color: var(--bone-dim); }
.card-title { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(1.7rem, 3vw, 2.3rem); line-height: 1.02; }
.is-featured .card-title { font-size: clamp(2rem, 4.2vw, 3.1rem); }
.card-discipline { margin: 0; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--bone-dim); }
.card-line { margin: .35rem 0 0; font-size: 1rem; line-height: 1.5; max-width: 52ch; }
.card-open {
  margin-top: auto; padding-top: 14px; align-self: flex-start;
  font-weight: 700; font-size: .7rem; letter-spacing: .24em; text-transform: uppercase;
  border-bottom: 2px solid var(--red); padding-bottom: 3px;
}
.card-open .arr { display: inline-block; transition: transform .25s var(--ease); }
.file-card:hover .card-open .arr { transform: translateX(5px); }

.file-stamp {
  position: absolute; right: 14px; top: 14px; z-index: 2;
  padding: 4px 10px; transform: rotate(-4deg);
  font-weight: 700; font-size: .6rem; letter-spacing: .24em; text-transform: uppercase;
  border: 2px solid rgba(242, 239, 233, .6); color: var(--bone); background: rgba(11, 11, 11, .55);
}
.file-stamp.is-featured { border-color: var(--red); color: #fff; background: rgba(193, 18, 31, .85); }
.card-draft {
  position: absolute; left: 14px; top: 14px; z-index: 2; padding: 3px 8px;
  border: 1px dashed var(--bone); background: rgba(11, 11, 11, .75);
  font-size: .6rem; font-weight: 700; letter-spacing: .24em; text-transform: uppercase;
}
/* supporting files: smaller, picture beside the text on wide screens */
@media (min-width: 620px) {
  .file-card.is-supporting { flex-direction: row; }
  .file-card.is-supporting .card-cover { flex: 0 0 42%; aspect-ratio: auto; min-height: 220px; }
  .file-card.is-supporting .cover-no { font-size: 4.5rem; }
}

.files-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin: 0 0 2.5rem; padding-top: 1.8rem; border-top: 1px solid var(--bone-faint); }
.files-foot p { margin: 0; font-family: var(--display); font-size: clamp(1.5rem, 3.4vw, 2.1rem); }

/* in the 3D world the archive floats over the scene */
[data-mode="world"] #projects { background: repeating-linear-gradient(-28deg, rgba(242, 239, 233, .025) 0 18px, transparent 18px 60px), var(--ink); z-index: 42; }
[data-mode="world"] #projects .files-close {
  display: inline-flex; align-items: center; min-height: 40px; margin: 0 0 1.4rem; padding: 0 14px;
  background: transparent; color: var(--bone-dim); border: 1px solid var(--bone-faint); cursor: pointer;
  font-weight: 700; font-size: .68rem; letter-spacing: .2em; text-transform: uppercase;
}
[data-mode="world"] #projects .files-close:hover { color: var(--bone); border-color: var(--bone); }

/* the flat-rate packs: three cards, a price on each */
.packs-inner { max-width: 1180px; }
.packs { display: grid; gap: 18px; grid-template-columns: 1fr; margin: 0 0 2rem; }
/* five packs: the three design packs, then the two websites a little wider */
@media (min-width: 640px) { .packs { grid-template-columns: repeat(2, 1fr); } .pack:last-child { grid-column: 1 / -1; } }
@media (min-width: 1100px) { .packs { grid-template-columns: repeat(6, 1fr); } .pack { grid-column: span 2; } .pack:nth-child(n+4) { grid-column: span 3; } }
.pack {
  display: flex; flex-direction: column; gap: .7rem;
  padding: 24px 22px 22px; border: 1px solid var(--bone-faint); border-top: 3px solid var(--red);
  background: rgba(20, 20, 20, .6);
}
.pack-no { margin: 0; font-weight: 700; font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: var(--bone-dim); }
.pack-name { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(1.6rem, 3.4vw, 2.1rem); line-height: 1.05; }
.pack-price { margin: 0; font-family: var(--display); font-size: clamp(2.2rem, 5vw, 2.8rem); line-height: 1; color: var(--red-hot); }
.pack-from { display: block; margin-bottom: .2rem; font-family: var(--type); font-weight: 700; font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: var(--bone-dim); }
.pack-desc { margin: 0; flex: 1; line-height: 1.55; color: var(--bone-dim); }
.pack-go { align-self: flex-start; margin-top: .4rem; }
.pack-desc:has(+ .pack-incl) { flex: 0 0 auto; }   /* with a list under it, the list takes the slack instead */
.pack-incl { flex: 1; align-content: start; margin: 0; padding: 0; list-style: none; display: grid; gap: .35rem; font-size: .84rem; line-height: 1.45; color: var(--bone); }
.pack-incl li { position: relative; padding-left: 1.1em; }
.pack-incl li::before { content: ""; position: absolute; left: 0; top: .6em; width: .5em; height: 2px; background: var(--red); }
.pm-incl { margin: 0 0 10px; font-size: .8rem; }
.menu-social { display: flex; flex-wrap: wrap; gap: .6rem 1.6rem; margin: 0 0 1.6rem; }
.menu-social a { color: var(--bone-dim); font-weight: 700; font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; text-decoration: underline; text-decoration-color: var(--bone-faint); text-underline-offset: 4px; }
.menu-social a:hover, .menu-social a:focus-visible { color: var(--bone); text-decoration-color: var(--red); }
.pack.is-spot { border-color: var(--red); animation: pack-spot 2.4s var(--ease) both; }
@keyframes pack-spot { 0%, 30% { box-shadow: 0 0 0 2px var(--red), 0 0 36px rgba(193, 18, 31, .55); } 100% { box-shadow: 0 0 0 1px var(--red); } }
@media (prefers-reduced-motion: reduce) { .pack.is-spot { animation: none; box-shadow: 0 0 0 2px var(--red); } }
/* in the 3D world the packs float over the scene, like the archive */
[data-mode="world"] #packs { background: repeating-linear-gradient(-28deg, rgba(242, 239, 233, .025) 0 18px, transparent 18px 60px), var(--ink); z-index: 42; }
[data-mode="world"] #packs .packs-close {
  display: inline-flex; align-items: center; min-height: 40px; margin: 0 0 1.4rem; padding: 0 14px;
  background: transparent; color: var(--bone-dim); border: 1px solid var(--bone-faint); cursor: pointer;
  font-weight: 700; font-size: .68rem; letter-spacing: .2em; text-transform: uppercase;
}
[data-mode="world"] #packs .packs-close:hover { color: var(--bone); border-color: var(--bone); }

/* the menu at the bar: the same packs, in the lounge */
.packmenu { display: none; }
.packmenu .dlg-card { max-height: calc(100vh - 150px); max-height: calc(100svh - 150px); overflow-y: auto; overscroll-behavior: contain; }
@media (min-width: 900px) { .packmenu .dlg-card { max-height: calc(100vh - 200px); max-height: calc(100svh - 200px); } }   /* clear of the top bar */
.packmenu-list { display: grid; gap: 0; margin-top: 10px; }
.pm-item { padding: 12px 0; border-top: 1px solid var(--bone-faint); }
.pm-item:first-child { border-top: 0; }
.pm-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.pm-name { margin: 0; font-family: var(--display); font-weight: 400; font-size: 1.3rem; line-height: 1.1; }
.pm-price { margin: 0; font-family: var(--display); font-size: 1.3rem; color: var(--red-hot); white-space: nowrap; text-align: right; }
.pm-price .pack-from { display: block; margin: 0; font-size: .58rem; }
.pm-desc { margin: 6px 0 10px; font-size: .86rem; line-height: 1.5; color: var(--bone-dim); }
.pm-go { min-height: 38px; padding: .4em 1em; font-size: .68rem; }

/* placeholders: never mistaken for facts */
.tbd { display: inline; color: var(--bone-dim); background: rgba(242, 239, 233, .04); outline: 1px dashed rgba(242, 239, 233, .25); outline-offset: 2px; }
.tbd-tag {
  display: inline-block; vertical-align: .12em; margin-right: .2em; padding: 1px 6px 0;
  border: 1px solid var(--red-hot); color: var(--red-hot);
  font-family: var(--type); font-weight: 700; font-size: .58rem; letter-spacing: .2em; text-transform: uppercase; line-height: 1.5;
}
.tbd.is-suggest { color: var(--bone); }
.tbd-note { color: var(--bone-dim); font-size: .85em; }
.card-title .tbd, .dossier-title .tbd { outline: 0; background: none; }
.card-title .tbd-tag, .dossier-title .tbd-tag { font-size: .6rem; vertical-align: middle; }

/* =====================================================================
   AN OPEN FILE: the dossier
   ===================================================================== */
.file { display: none; }
.file:not([hidden]) {
  display: block; position: fixed; inset: 0; z-index: 70;
  overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
  background:
    radial-gradient(90% 50% at 50% 0%, #1c1c1c, transparent 70%),
    repeating-linear-gradient(-28deg, rgba(242, 239, 233, .022) 0 18px, transparent 18px 60px),
    var(--ink);
  opacity: 0; transition: opacity .35s var(--ease);
}
.file.is-open { opacity: 1; }
.file .dossier { transform: translateY(16px); transition: transform .5s var(--ease); }
.file.is-open .dossier { transform: none; }
body.file-open { overflow: hidden; }
.file-bar {
  position: sticky; top: 0; z-index: 3;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: calc(12px + env(safe-area-inset-top)) var(--gutter) 12px;
  background: rgba(11, 11, 11, .9); border-bottom: 1px solid var(--bone-faint);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.file-bar-label { margin: 0; font-weight: 700; font-size: .7rem; letter-spacing: .32em; text-transform: uppercase; color: var(--bone-dim); }
.file-close {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px;
  background: transparent; border: 1px solid var(--bone-faint); cursor: pointer;
  font-weight: 700; font-size: .72rem; letter-spacing: .24em; text-transform: uppercase;
}
.file-close span[aria-hidden] { font-size: 1.3rem; line-height: 1; letter-spacing: 0; }
.file-close:hover { border-color: var(--bone); }

.dossier { max-width: 1120px; margin: 0 auto; padding: clamp(28px, 5vw, 56px) var(--gutter) 80px; }
.dossier-head { max-width: 900px; margin-bottom: 2rem; }
.dossier-kicker { margin: 0 0 1rem; font-weight: 700; font-size: .72rem; letter-spacing: .28em; text-transform: uppercase; color: var(--bone-dim); }
.dossier-title { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(2.6rem, 8.5vw, 5.8rem); line-height: .95; }
.dossier-discipline { margin: 1rem 0 0; font-size: .78rem; letter-spacing: .24em; text-transform: uppercase; color: var(--bone-dim); }
.dossier-line { margin: 1.2rem 0 0; font-size: clamp(1.1rem, 2.4vw, 1.4rem); line-height: 1.45; max-width: 44ch; }
.dossier-cover { aspect-ratio: 16 / 9; border: 1px solid var(--bone-faint); margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.dossier-cover::after { opacity: .12; }
.dossier-cover img.is-yt { transform: scale(1.8); }

.dossier-grid { display: grid; gap: 2.5rem 3.5rem; margin-bottom: 3rem; }
@media (min-width: 900px) { .dossier-grid { grid-template-columns: minmax(0, 1.7fr) minmax(280px, 1fr); align-items: start; } }
.file-sec { margin: 0 0 2.4rem; }
.sec-label {
  display: flex; align-items: center; gap: 12px; margin: 0 0 .9rem;
  font-weight: 700; font-size: .72rem; letter-spacing: .3em; text-transform: uppercase; color: var(--bone-dim);
}
.sec-label::before { content: ""; width: 26px; height: 3px; background: var(--red); flex: none; }
.sec-text { margin: 0; font-size: 1.06rem; line-height: 1.65; max-width: 62ch; }
.pillars { margin: 0; }
.pillar { display: grid; gap: 4px; padding: 14px 0; border-top: 1px solid var(--bone-faint); }
.pillar:last-child { border-bottom: 1px solid var(--bone-faint); }
.pillar dt { font-family: var(--display); font-size: 1.35rem; line-height: 1.1; }
.pillar dd { margin: 0; line-height: 1.6; }
@media (min-width: 700px) { .pillar { grid-template-columns: 220px 1fr; gap: 20px; } }

/* the file sheet: a typed index card */
.sheet {
  position: relative; color: #1a1a1a;
  background:
    repeating-linear-gradient(transparent 0 31px, rgba(36, 72, 140, .16) 31px 32px),
    #ebe5d6;
  padding: 26px 24px 18px; box-shadow: 0 22px 50px -26px rgba(0, 0, 0, .9);
  border-top: 4px solid var(--red);
  transform: rotate(.6deg);
}
.sheet-head { margin: 0 0 12px; font-weight: 700; font-size: .7rem; letter-spacing: .3em; text-transform: uppercase; color: #6a6052; }
.sheet dl { margin: 0; }
.sheet-row { padding: 6px 0 8px; border-top: 1px solid rgba(26, 26, 26, .12); }
.sheet-row dt { font-weight: 700; font-size: .64rem; letter-spacing: .24em; text-transform: uppercase; color: #6a6052; margin-bottom: 2px; }
.sheet-row dd { margin: 0; font-size: .98rem; line-height: 1.5; }
.sheet-row ul { margin: 0; padding: 0; list-style: none; }
.sheet-row li { padding-left: 1em; position: relative; }
.sheet-row li::before { content: ""; position: absolute; left: 0; top: .72em; width: .5em; height: 2px; background: var(--red); }
.sheet .tbd { color: #5a5a5a; background: rgba(0, 0, 0, .04); outline-color: rgba(0, 0, 0, .3); }
.sheet .tbd.is-suggest { color: #1a1a1a; }
.sheet .tbd-note { color: #6a6052; }

/* the evidence: 3 to 5 strong pieces, any mix of stills and video */
.ev-grid { display: grid; gap: 22px; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-flow: dense; }
.ev { margin: 0; grid-column: span 12; }
@media (min-width: 720px) {
  .ev { grid-column: span 6; }
  .ev:first-child:not(.is-vertical) { grid-column: span 12; }
  .ev.is-vertical { grid-column: span 3; }
  .ev.ev-ph { grid-column: span 6; }
}
@media (max-width: 719px) { .ev.is-vertical { grid-column: span 6; } }
.ev-frame { position: relative; overflow: hidden; background: #111; border: 1px solid var(--bone-faint); aspect-ratio: 3 / 2; }
.ev:first-child:not(.is-vertical) .ev-frame { aspect-ratio: 16 / 9; }
.ev-frame img { width: 100%; height: 100%; object-fit: cover; }
.ev-video.is-vertical { aspect-ratio: 9 / 16; }
.ev-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ev-play {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  width: 100%; padding: 0; border: 0; background: #0a0a0a; cursor: pointer; color: var(--bone); text-decoration: none;
}
.ev-play img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.0); }
.ev-video.is-vertical .ev-play img { transform: scale(1); object-fit: cover; }
.ev-play::before { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 40%, rgba(0, 0, 0, .7)); z-index: 1; }
.ev-play > span { position: relative; z-index: 2; }
.ev-play .video-play { transition: transform .25s var(--ease), background .25s var(--ease); }
.ev-play:hover .video-play, .ev-play:focus-visible .video-play { transform: scale(1.08); background: var(--red-hot); }
.ev-play-label { font-weight: 700; font-size: .62rem; letter-spacing: .2em; text-transform: uppercase; padding: 0 10px; text-align: center; }
.ev figcaption { margin-top: 10px; font-size: .86rem; line-height: 1.5; color: var(--bone-dim); }
.ev-out { color: var(--bone-dim); text-decoration: none; border-bottom: 1px solid var(--bone-faint); white-space: nowrap; }
.ev-out:hover { color: var(--bone); border-color: var(--red); }
.ev-ph .ev-frame { aspect-ratio: 16 / 9; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 18px; text-align: center; border-style: dashed; }
.ev-ph .cover-no { font-size: clamp(3rem, 8vw, 5rem); }
/* watch everything: the channel's uploads playlist, one wide player */
.watch-all .ev-all { aspect-ratio: 16 / 9; }
.watch-all .ev-play { background: radial-gradient(80% 90% at 50% 40%, rgba(193, 18, 31, .2), transparent 70%), #0a0a0a; }

/* every file ends at the form */
.dossier-cta {
  margin-top: 1rem; padding: clamp(24px, 4vw, 40px);
  border: 1px solid rgba(193, 18, 31, .55);
  background: radial-gradient(90% 120% at 0% 0%, rgba(193, 18, 31, .14), transparent 60%), #0e0e0e;
}
.cta-line { margin: 0 0 1.4rem; font-family: var(--display); font-size: clamp(1.6rem, 4vw, 2.6rem); line-height: 1.08; max-width: 26ch; }
.cta-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.cta-next { max-width: 100%; text-align: left; }

/* the walk-up tag in the gallery */
.file-summary p { margin: 0 0 .6rem; }
.file-summary .summary-open { min-height: 42px; margin-top: .3rem; font-size: .72rem; }

@media (prefers-reduced-motion: reduce) {
  .file, .file .dossier, .file-card, .file-card::after, .cover img, .cover::after, .card-open .arr { transition: none !important; }
}
.ev-frame.is-missing { display: flex; align-items: center; justify-content: center; }
p.tbd { display: block; width: fit-content; max-width: 100%; }
.info .info-body .case-kicker { font-size: .64rem; letter-spacing: .24em; text-transform: uppercase; color: var(--bone-dim); margin-bottom: .5rem; }
.file-summary .summary-open { display: flex; }
/* a closing overlay stops catching clicks the moment it starts to fade */
[data-mode="world"] .screen:not(.is-open) { pointer-events: none; }

/* =====================================================================
   PHOTO SETS: a large photo, arrows or swipe, the same dialog as a file
   ===================================================================== */
.file.is-viewer { background: #050505; overflow: hidden; display: flex; flex-direction: column; }
.file.is-viewer[hidden] { display: none; }
.file.is-viewer .file-body { flex: 1; min-height: 0; display: flex; }
.pv { flex: 1; min-height: 0; display: flex; flex-direction: column; align-items: center; padding: 14px var(--gutter) calc(14px + env(safe-area-inset-bottom)); }
.pv-head { text-align: center; margin-bottom: 12px; }
.pv-title { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(1.6rem, 4vw, 2.6rem); line-height: 1; }
.pv-sub { margin: .45rem 0 0; font-size: .72rem; letter-spacing: .26em; text-transform: uppercase; color: var(--bone-dim); }
.pv-main { flex: 1; min-height: 0; width: 100%; display: flex; align-items: center; justify-content: center; gap: 14px; }
.pv-stage { position: relative; height: 100%; max-width: 100%; aspect-ratio: 4 / 5; display: flex; align-items: center; justify-content: center; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.pv-img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; border: 1px solid var(--bone-faint); background: #111; opacity: 0; transition: opacity .25s var(--ease); -webkit-user-drag: none; }
.pv-img.is-in { opacity: 1; }
.pv-arrow {
  flex: none; width: 52px; height: 52px; display: grid; place-items: center; cursor: pointer;
  background: rgba(11, 11, 11, .7); border: 1px solid var(--bone-faint); color: var(--bone); font-size: 1.4rem;
  transition: border-color .2s var(--ease), background .2s var(--ease);
}
.pv-arrow:hover { border-color: var(--bone); }
.pv-arrow:focus-visible { border-color: var(--red); }
.pv-arrow[hidden] { display: none; }
.pv-count { margin: 10px 0 0; font-weight: 700; font-size: .72rem; letter-spacing: .3em; color: var(--bone-dim); }
.pv-quote { margin: 12px auto 0; max-width: 62ch; padding-left: 14px; border-left: 3px solid var(--red); text-align: left; }
.pv-quote blockquote { margin: 0; }
.pv-quote p { margin: 0; font-size: .86rem; line-height: 1.5; color: var(--bone); }
.pv-quote figcaption { margin-top: 6px; font-weight: 700; font-size: .66rem; letter-spacing: .22em; text-transform: uppercase; color: var(--bone-dim); }
@media (max-height: 640px) { .pv-quote p { font-size: .78rem; } }
@media (max-width: 640px) {
  .pv-main { position: relative; gap: 0; }
  .pv-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 46px; height: 46px; }
  .pv-prev { left: 4px; } .pv-next { right: 4px; }
}
@media (prefers-reduced-motion: reduce) { .pv-img { transition: none; } }

/* =====================================================================
   THE THEATER: the box office, the ticket stub, the player on the screen
   ===================================================================== */
.booth { display: none; }
.booth-lead { margin: 10px 0 12px; color: var(--bone-dim); font-size: .95rem; }
.booth-list { display: grid; gap: 8px; }
.booth-pick {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 46px; padding: 0 16px; cursor: pointer; text-align: left;
  background: transparent; border: 1px solid var(--bone-faint); color: var(--bone);
  font-family: var(--display); font-size: 1.25rem;
  transition: border-color .2s var(--ease), background .2s var(--ease);
}
.booth-pick::after { content: "\2192"; font-family: var(--type); color: var(--red-hot); }
.booth-pick:hover, .booth-pick:focus-visible { border-color: var(--bone); background: rgba(242, 239, 233, .05); }
.booth-pick:disabled { opacity: .35; cursor: default; }
.booth.has-stub .booth-list { display: none; }
.booth-stub:empty { display: none; }
.booth-stub { margin-top: 12px; display: flex; justify-content: center; }
.booth-stub .ticket { animation: stub-in .6s var(--ease); }
@keyframes stub-in { from { transform: translateY(-14px) rotate(-4deg); opacity: 0; } to { transform: rotate(-2deg); opacity: 1; } }

.ticket {
  position: relative; display: inline-flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 12px 34px 12px; transform: rotate(-2deg);
  background: #e9dfc6; color: #1a1a1a;
  border: 2px dashed rgba(26, 26, 26, .35); border-left: 0; border-right: 0;
  -webkit-mask: radial-gradient(circle 9px at 0 50%, transparent 98%, #000) left / 51% 100% no-repeat, radial-gradient(circle 9px at 100% 50%, transparent 98%, #000) right / 51% 100% no-repeat;
          mask: radial-gradient(circle 9px at 0 50%, transparent 98%, #000) left / 51% 100% no-repeat, radial-gradient(circle 9px at 100% 50%, transparent 98%, #000) right / 51% 100% no-repeat;
}
.ticket-admit { font-weight: 700; font-size: .62rem; letter-spacing: .34em; text-transform: uppercase; color: var(--red); }
.ticket-house { font-weight: 700; font-size: .6rem; letter-spacing: .22em; text-transform: uppercase; color: #5a5040; }
.ticket-title { font-family: var(--display); font-size: 1.45rem; line-height: 1.05; }

.feature { display: none; }
[data-mode="world"] .feature:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 27; pointer-events: none; }
.feature-frame { position: fixed; left: 0; top: 0; width: 0; height: 0; background: #000; pointer-events: auto; box-shadow: 0 0 60px 10px rgba(0, 0, 0, .6); }
.feature-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.feature-bar {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  display: flex; align-items: center; gap: 14px; pointer-events: auto;
}
.feature-bar .ticket { padding: 6px 22px; }
.feature-bar .ticket-title { font-size: 1rem; }
.feature-close { background: rgba(11, 11, 11, .8); min-height: 42px; font-size: .7rem; }
@media (max-width: 560px) { .feature-bar .feature-stub { display: none; } }
@media (prefers-reduced-motion: reduce) { .booth-stub .ticket { animation: none; } }
/* while a feature plays or the box office is open, the walking controls step aside */
body.is-screening .dpad, body.is-screening .hint { display: none !important; }
/* the feature starts muted; one tap on the screen turns the sound on */
.feature-sound {
  position: absolute; left: 50%; bottom: 12%; transform: translateX(-50%);
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 48px; padding: 0 18px 0 14px; cursor: pointer; white-space: nowrap;
  background: var(--red); color: var(--bone); border: 0;
  font-weight: 700; font-size: .72rem; letter-spacing: .22em; text-transform: uppercase;
  box-shadow: 0 10px 30px -8px rgba(0, 0, 0, .8);
  animation: snd-ask 1.6s var(--ease) infinite;
}
.feature-sound:hover { background: var(--red-hot); }
.feature-sound svg { width: 20px; height: 20px; fill: var(--bone); stroke: var(--bone); flex: none; }
.feature-sound svg path:first-child { stroke: none; }
@media (prefers-reduced-motion: reduce) { .feature-sound { animation: none; } }

/* ---------------- the case: a four-line checklist in the HUD ----------------
   The visitor is a new client gathering the evidence before the meeting at the
   bar. Folded to a tab on phones; tap it to read the list. */
.brief {
  position: absolute;
  top: calc(72px + env(safe-area-inset-top, 0px));
  left: max(var(--gutter), env(safe-area-inset-left, 0px));
  width: 252px;
  background: rgba(11, 11, 11, .74);
  border: 1px solid var(--bone-faint);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.brief::before { content: ""; position: absolute; left: 12px; top: -1px; width: 34px; height: 3px; background: var(--red); }
.brief-head {
  display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 40px; padding: 0 12px;
  background: none; border: 0; color: var(--bone); cursor: pointer;
  font: 700 .66rem/1 var(--type); letter-spacing: .24em; text-transform: uppercase;
}
.brief-count { color: var(--red-hot); letter-spacing: .12em; }
.brief-body { padding: 0 12px 12px; }
.brief.is-folded { width: auto; }
.brief.is-folded .brief-body { display: none; }
.brief-intro { margin: 0 0 9px; font-size: .74rem; line-height: 1.45; color: var(--bone-dim); }
.brief-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.brief-list li { display: flex; gap: 9px; align-items: flex-start; font-size: .78rem; line-height: 1.35; color: var(--bone); }
.brief-list li[data-obj="message"] { margin-top: 2px; padding-top: 8px; border-top: 1px dashed var(--bone-faint); }
.brief-box { flex: none; position: relative; width: 13px; height: 13px; margin-top: 2px; border: 1.5px solid var(--bone); }
.brief-list li.is-next { color: var(--red-hot); font-weight: 700; }
.brief-list li.is-done { color: var(--bone-dim); text-decoration: line-through; text-decoration-color: var(--red-hot); text-decoration-thickness: 2px; }
.brief-list li.is-done .brief-box { background: var(--red); border-color: var(--red); }
.brief-list li.is-done .brief-box::after {
  content: ""; position: absolute; left: 3px; top: 0; width: 4px; height: 8px;
  border: solid var(--bone); border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.brief.is-closed { border-color: var(--red); }
.brief-toast {
  position: absolute; left: 50%; top: calc(72px + env(safe-area-inset-top, 0px)); transform: translateX(-50%);
  margin: 0; padding: 11px 16px 11px 14px; width: max-content; max-width: min(440px, calc(100% - 32px));
  background: var(--ink); border: 1px solid var(--bone-faint); border-left: 4px solid var(--red);
  font-size: .82rem; line-height: 1.4; letter-spacing: .04em; color: var(--bone);
  pointer-events: none;
  animation: brief-in .35s var(--ease);
  transition: opacity .4s var(--ease);
}
@keyframes brief-in { from { opacity: 0; transform: translate(-50%, 8px); } to { opacity: 1; transform: translate(-50%, 0); } }
.brief-toast.is-out { opacity: 0; }
.brief-toast[hidden] { display: none; }
body.is-screening .brief, body.is-screening .brief-toast { display: none; }
@media (hover: none) and (pointer: coarse) {
  .brief { width: min(252px, calc(100% - 150px)); }
  .brief.is-folded { width: auto; }
  .brief-toast { top: calc(176px + env(safe-area-inset-top, 0px)); }
}

/* ---------------- darts in the About room: the score at the bottom while you play ---------------- */
.darts { display: none; }
[data-mode="world"] .darts:not([hidden]) {
  display: block; position: fixed; z-index: 25;
  left: 50%; transform: translateX(-50%);
  bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  width: min(440px, calc(100% - 32px));
  padding: 10px 14px 12px;
  background: rgba(11, 11, 11, .82);
  border: 1px solid var(--bone-faint);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  color: var(--bone);
}
.darts::before { content: ""; position: absolute; left: 12px; top: -1px; width: 34px; height: 3px; background: var(--red); }
.darts-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.darts-kicker { margin: 0; font: 700 .66rem/1 var(--type); letter-spacing: .24em; text-transform: uppercase; }
.darts-kicker span { color: var(--bone-dim); margin-left: .6em; }
.darts-close {
  min-height: 36px; padding: 0 14px; cursor: pointer;
  background: transparent; border: 1px solid var(--bone-faint); color: var(--bone);
  font: 700 .64rem/1 var(--type); letter-spacing: .22em; text-transform: uppercase;
}
.darts-close:hover, .darts-close:focus-visible { border-color: var(--bone); }
.darts-row { display: flex; align-items: center; gap: 16px; margin-top: 8px; }
.darts-round { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; flex: 1; }
.darts-pip {
  flex: 1; min-width: 0; height: 40px; display: grid; place-items: center;
  border: 1px solid var(--bone-faint);
  font-family: var(--display); font-size: 1.25rem; color: var(--bone-dim);
}
.darts-pip.is-hit { color: var(--bone); border-color: var(--bone); }
.darts-num { margin: 0; font: 700 .6rem/1.2 var(--type); letter-spacing: .2em; text-transform: uppercase; color: var(--bone-dim); text-align: center; }
.darts-num b { display: block; margin-top: 3px; font: 400 1.6rem/1 var(--display); letter-spacing: 0; color: var(--bone); }
.darts-best { color: var(--red-hot) !important; }
.darts-call { margin: 9px 0 0; min-height: 1.3em; font-size: .78rem; line-height: 1.35; letter-spacing: .04em; color: var(--bone-dim); }
.darts-call.is-big { color: var(--bone); font-family: var(--display); font-size: 1.15rem; letter-spacing: .02em; }
/* at the line the walking controls step aside (is-screening), and so does the case list */
body.is-darts #stage, body.is-darts #stage canvas { cursor: crosshair !important; touch-action: none; }

/* ---------------- the arcade machine in the About room: movie trivia ---------------- */
.trivia { display: none; }
[data-mode="world"] .trivia:not([hidden]) .dlg-card { position: relative; }
.trivia-score { margin: 8px 0 0; font: 700 .6rem/1.2 var(--type); letter-spacing: .2em; text-transform: uppercase; color: var(--bone-dim); }
.trivia-score b { margin-left: .5em; font: 400 1.3rem/1 var(--display); letter-spacing: 0; color: var(--red-hot); }
.trivia-q { margin: 12px 0 14px; font-family: var(--display); font-size: 1.3rem; line-height: 1.25; }
.trivia-answers { display: grid; gap: 8px; }
.trivia-answers:empty { display: none; }
.trivia-pick {
  display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 12px;
  min-height: 46px; padding: 8px 14px; cursor: pointer; text-align: left;
  background: transparent; border: 1px solid var(--bone-faint); color: var(--bone);
  font: inherit; font-size: .95rem;
  transition: border-color .2s var(--ease), background .2s var(--ease);
}
.trivia-pick kbd { font: 700 .62rem/1 var(--type); letter-spacing: .1em; color: var(--bone-dim); border: 1px solid var(--bone-faint); padding: 4px 6px; }
.trivia-pick:hover:not(:disabled), .trivia-pick:focus-visible { border-color: var(--bone); background: rgba(242, 239, 233, .05); }
.trivia-pick:disabled { cursor: default; opacity: .45; }
.trivia-pick.is-right { opacity: 1; border-color: var(--bone); background: rgba(242, 239, 233, .1); }
.trivia-pick.is-right kbd { color: var(--ink); background: var(--bone); border-color: var(--bone); }
.trivia-pick.is-wrong { opacity: 1; border-color: var(--red); background: rgba(193, 18, 31, .16); }
.trivia-pick.is-wrong kbd { color: var(--bone); background: var(--red); border-color: var(--red); }
.trivia-call { margin: 12px 0 0; min-height: 1.3em; font-size: .85rem; color: var(--bone-dim); }
.trivia-call.is-big { color: var(--bone); font-family: var(--display); font-size: 1.2rem; }
.trivia-call:empty { display: none; }
.trivia-next { margin-top: 12px; }
.trivia-next[hidden] { display: none; }

/* ---------------- the next step after a message: a consultation call or the project brief ---------------- */
.next-step { max-width: 720px; margin: 0 0 2.5rem; }
.next-step[hidden] { display: none; }
.next-title { margin: .4rem 0 .5rem; font-family: var(--display); font-weight: 400; font-size: clamp(1.6rem, 4.6vw, 2.4rem); line-height: 1.1; outline: none; }
.next-lead { margin: 0 0 1.2rem; color: var(--bone-dim); }
.paths { display: grid; gap: 12px; grid-template-columns: 1fr; margin-bottom: 1.4rem; }
@media (min-width: 640px) { .paths { grid-template-columns: 1fr 1fr; } }
.path {
  display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; align-items: baseline;
  padding: 16px 18px; text-align: left; cursor: pointer;
  background: var(--ink-2); color: var(--bone);
  border: 1px solid var(--bone-faint); border-left: 4px solid var(--bone-faint);
  font: inherit;
  transition: border-color .2s var(--ease), background .2s var(--ease);
}
.path:hover, .path:focus-visible { border-color: var(--bone); outline: none; }
.path.is-on { border-color: var(--red); border-left-color: var(--red); background: var(--ink-3); }
.path-no { grid-row: 1 / span 2; font: 400 1.6rem/1 var(--display); color: var(--red-hot); }
.path-name { font-weight: 700; font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; line-height: 1.35; }
.path-desc { font-size: .88rem; color: var(--bone-dim); line-height: 1.45; }
.step-form { margin-bottom: 1.6rem; }
.step-form[hidden] { display: none; }
.step-note { margin: 0; padding: 12px 14px; border-left: 3px solid var(--red); background: rgba(193, 18, 31, .08); font-size: .95rem; }
.checks { border: 0; margin: 0; padding: 0; min-width: 0; }
.checks legend { padding: 0; margin-bottom: 8px; font-weight: 700; font-size: .74rem; letter-spacing: .26em; text-transform: uppercase; }
.check-row { display: flex; flex-wrap: wrap; gap: 8px; }
.check { position: relative; display: inline-flex; cursor: pointer; }
.check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.check span {
  display: inline-flex; align-items: center; min-height: 42px; padding: 0 14px;
  background: var(--ink-2); border: 1px solid var(--bone-faint); color: var(--bone-dim);
  font-size: .86rem; transition: border-color .2s var(--ease), color .2s var(--ease), background .2s var(--ease);
}
.check input:checked + span { color: var(--bone); border-color: var(--red); background: rgba(193, 18, 31, .18); }
.check input:focus-visible + span { outline: 2px solid var(--bone); outline-offset: 2px; }
.checks.is-invalid .check span { border-color: var(--red-hot); }
.files .file-pick {
  padding: 12px 14px; background: var(--ink-2); border: 1px dashed rgba(242, 239, 233, .4); color: var(--bone-dim); cursor: pointer;
}
.files .file-pick::file-selector-button {
  margin-right: 14px; padding: 8px 14px; cursor: pointer;
  background: transparent; color: var(--bone); border: 1px solid var(--bone);
  font: 700 .68rem/1 var(--type); letter-spacing: .2em; text-transform: uppercase;
}
.file-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.file-list:empty { display: none; }
.file-list li { display: flex; align-items: center; gap: 12px; padding: 8px 10px; background: var(--ink-2); font-size: .86rem; }
.file-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-size { color: var(--bone-dim); font-size: .78rem; }
.file-x { min-height: 32px; padding: 0 10px; background: transparent; color: var(--bone-dim); border: 1px solid var(--bone-faint); cursor: pointer; font: 700 .6rem/1 var(--type); letter-spacing: .18em; text-transform: uppercase; }
.file-x:hover { color: var(--bone); border-color: var(--bone); }
.next-again {
  min-height: 40px; padding: 0 14px; background: transparent; color: var(--bone-dim);
  border: 1px solid var(--bone-faint); cursor: pointer;
  font-weight: 700; font-size: .68rem; letter-spacing: .2em; text-transform: uppercase;
}
.next-again:hover { color: var(--bone); border-color: var(--bone); }
.contact-form[hidden] { display: none; }

/* ---------------- the Content Engine, on the plain page ---------------- */
.ce-grid { display: grid; gap: 18px; grid-template-columns: 1fr; max-width: 760px; margin: 0 0 2rem; }
@media (min-width: 720px) { .ce-grid { grid-template-columns: 1fr 1.4fr; } }
.ce-block { border: 1px solid var(--bone-faint); border-top: 3px solid var(--red); padding: 22px 22px 16px; background: rgba(20, 20, 20, .6); }
.ce-block h3 { margin: 0 0 .8rem; font-size: .8rem; letter-spacing: .28em; text-transform: uppercase; color: var(--bone-dim); }
.ce-block ul { margin: 0; padding: 0; list-style: none; }
.ce-block li { padding: .55em 0 .55em 1.6em; position: relative; border-top: 1px solid rgba(242, 239, 233, .07); line-height: 1.5; }
.ce-block li:first-child { border-top: 0; }
.ce-block li::before { content: ""; position: absolute; left: 0; top: 1.15em; width: .8em; height: 2px; background: var(--red); }
.ce-block strong { font-weight: 700; }

/* =====================================================================
   THE FLAT PAGE, WITH THE ALLEY'S MAGIC
   Flat mode only (never the 3D world's panels). Textures are pure CSS; flat.js
   adds the motion (rain, the alley drawn behind the lobby, the reveals) and the
   .flat-fx class. With reduced motion it adds .flat-calm: gentle fades, no typing,
   no flicker. The funnel and the forms are left exactly as they are.
   ===================================================================== */
:root:not([data-mode="world"]) .lobby { position: relative; overflow: hidden; }
:root:not([data-mode="world"]) .lobby-inner,
:root:not([data-mode="world"]) .screen-inner { position: relative; z-index: 2; }

/* halftone and a lamp over every section: the alley's print, flat */
:root:not([data-mode="world"]) .screen::before,
:root:not([data-mode="world"]) .lobby::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(55% 38% at 50% 0%, rgba(242, 239, 233, .075), transparent 72%),
    radial-gradient(rgba(242, 239, 233, .11) 1px, transparent 1.6px) 0 0 / 7px 7px;
  -webkit-mask-image: linear-gradient(to bottom, #000, rgba(0, 0, 0, .35) 45%, transparent 80%);
          mask-image: linear-gradient(to bottom, #000, rgba(0, 0, 0, .35) 45%, transparent 80%);
}
:root:not([data-mode="world"]) #contact::before {
  background:
    radial-gradient(60% 42% at 50% 0%, rgba(193, 18, 31, .2), transparent 72%),
    radial-gradient(rgba(224, 24, 42, .2) 1px, transparent 1.6px) 0 0 / 7px 7px;
}
:root:not([data-mode="world"]) #contact { border-top: 1px solid var(--red); box-shadow: 0 -1px 18px rgba(193, 18, 31, .45); }

/* ink: headings printed with a hard shadow, kickers in comic caption boxes */
:root:not([data-mode="world"]) .lobby-title,
:root:not([data-mode="world"]) .screen-title { text-shadow: .035em .045em 0 #000, .07em .09em 0 rgba(0, 0, 0, .55); }
:root:not([data-mode="world"]) .lobby-inner > .kicker,
:root:not([data-mode="world"]) .screen-inner > .kicker {
  display: inline-block; padding: 6px 11px 5px;
  background: var(--bone); color: var(--ink);
  border: 2px solid #000; box-shadow: 4px 4px 0 #000;
  transform: rotate(-1.2deg); transform-origin: left center;
}
:root:not([data-mode="world"]) .screen-inner > .kicker .kicker-red { color: var(--red); }
:root:not([data-mode="world"]) .screen-inner > .kicker.kicker-red { background: var(--red); color: var(--bone); }

/* the doors: ink plates with a hard shadow, the number turning red under your hand */
:root:not([data-mode="world"]) .plate {
  border: 2px solid rgba(242, 239, 233, .3);
  background: radial-gradient(rgba(242, 239, 233, .06) 1px, transparent 1.6px) 0 0 / 6px 6px, linear-gradient(var(--ink-2), var(--ink));
  box-shadow: 5px 5px 0 #000;
}
:root:not([data-mode="world"]) .plate:hover { transform: translate(-2px, -2px); box-shadow: 7px 7px 0 #000; }
:root:not([data-mode="world"]) .plate:hover .plate-no { color: var(--red-hot); }
:root:not([data-mode="world"]) .plate-red { border-color: var(--red); box-shadow: 5px 5px 0 #000, 0 0 26px -6px rgba(193, 18, 31, .7); }

/* the alley drawn behind the lobby (flat.js), the rain over the page */
.fx-scene {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(62vw, 820px); z-index: 0; pointer-events: none;
  -webkit-mask-image: linear-gradient(to left, #000 50%, transparent);
          mask-image: linear-gradient(to left, #000 50%, transparent);
}
.fx-scene svg { display: block; width: 100%; height: 100%; }
@media (max-width: 760px) {
  .fx-scene { width: 100%; bottom: auto; height: 100svh; opacity: .42;   /* the alley fills the first screen, the red door behind the title */
    -webkit-mask-image: linear-gradient(to bottom, transparent, #000 18%, #000 62%, transparent);
            mask-image: linear-gradient(to bottom, transparent, #000 18%, #000 62%, transparent); }
}
.fx-rain { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; }
:root[data-mode="world"] .fx-rain, :root[data-mode="world"] .fx-scene { display: none; }

/* the lamp breathes, the lit windows go dark and come back, the red door glows */
.flat-fx .fx-cone { animation: fx-breathe 6s ease-in-out infinite; }
.flat-fx .fx-bulb { animation: fx-breathe 6s ease-in-out infinite; }
.flat-fx .fx-door-glow { animation: fx-glow 4.5s ease-in-out infinite; }
.flat-fx .fx-reflect { animation: fx-glow 4.5s ease-in-out infinite; }
.flat-fx .fx-window-1 { animation: fx-window 11s ease-in-out infinite; }
.flat-fx .fx-window-2 { animation: fx-window 15s ease-in-out -6s infinite; }
.flat-fx .plate-red { animation: fx-door 4.5s ease-in-out infinite; }
@keyframes fx-breathe { 0%, 100% { opacity: 1; } 50% { opacity: .78; } }
@keyframes fx-glow { 0%, 100% { opacity: .75; } 50% { opacity: 1; } }
@keyframes fx-window { 0%, 40%, 100% { opacity: 1; } 48%, 70% { opacity: .15; } }
@keyframes fx-door {
  0%, 100% { box-shadow: 5px 5px 0 #000, 0 0 22px -8px rgba(193, 18, 31, .55); }
  50% { box-shadow: 5px 5px 0 #000, 0 0 34px -4px rgba(224, 24, 42, .85); }
}

/* the reveals: headings stamp in with a red misprint that settles, red rules draw in,
   kickers and leads type out behind a red caret, the rest rises in */
.flat-fx .fx-wait { opacity: 0; }
.flat-fx .fx-rule.fx-wait { opacity: 1; transform: scaleX(0); transform-origin: left center; }
.flat-fx .fx-stamp.fx-in { animation: fx-stamp .75s var(--ease) backwards; }
.flat-fx .fx-rule.fx-in { transform-origin: left center; animation: fx-rule .7s .12s var(--ease) backwards, fx-rule-glow 1.6s .12s ease-out backwards; }
.flat-fx .fx-rise.fx-in { animation: fx-rise .6s calc(var(--fx-i, 0) * 70ms) var(--ease) backwards; }
.flat-fx .lobby-choices .btn-red.fx-in { animation: fx-rise .6s calc(var(--fx-i, 0) * 70ms) var(--ease) backwards, fx-red-arrive 1.8s .45s ease-out; }
.flat-fx .fx-rise.fx-in .btn-red { animation: fx-red-arrive 1.8s .45s ease-out; }
@keyframes fx-stamp {
  0% { opacity: 0; transform: scale(1.06) translateY(6px); text-shadow: .14em .1em 0 rgba(193, 18, 31, .9); }
  45% { opacity: 1; text-shadow: .08em .07em 0 rgba(193, 18, 31, .7); }
  100% { transform: none; }
}
@keyframes fx-rule { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes fx-rule-glow { 0% { box-shadow: 0 0 0 rgba(224, 24, 42, 0); } 35% { box-shadow: 0 0 16px rgba(224, 24, 42, .85); } 100% { box-shadow: 0 0 0 rgba(224, 24, 42, 0); } }
@keyframes fx-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes fx-red-arrive { 0% { box-shadow: 0 0 0 0 rgba(224, 24, 42, 0); } 30% { box-shadow: 0 0 0 4px rgba(224, 24, 42, .35), 0 0 30px 4px rgba(224, 24, 42, .55); } 100% { box-shadow: 0 0 0 0 rgba(224, 24, 42, 0); } }

/* the typewriter (flat.js): every letter waits, then appears; the words stay readable for screen readers */
.fx-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.fx-typing .fx-ch { opacity: 0; }
.fx-typing .fx-ch.on { opacity: 1; }
.fx-caret {
  display: inline-block; width: .55em; height: 1.05em; margin-left: 2px; margin-right: -.6em; vertical-align: -.17em;   /* takes no room: the line never jumps */
  background: var(--red-hot); box-shadow: 0 0 10px rgba(224, 24, 42, .6);
  animation: fx-caret .8s steps(1) infinite;
}
@keyframes fx-caret { 50% { opacity: 0; } }

/* reduced motion: the same page, calmer. Soft fades instead of typing and stamping, no flicker */
.flat-calm .fx-stamp.fx-in, .flat-calm .fx-type.fx-in, .flat-calm .fx-rise.fx-in { animation: fx-fade .9s ease backwards; }
.flat-calm .fx-rule.fx-in { animation: fx-rule 1.2s ease backwards; }
.flat-calm .fx-cone, .flat-calm .fx-bulb, .flat-calm .fx-window-1, .flat-calm .fx-window-2, .flat-calm .fx-reflect { animation: none; }
.flat-calm .fx-door-glow { animation: fx-glow 9s ease-in-out infinite; }
.flat-calm .plate-red { animation: none; }
.flat-calm .fx-rise.fx-in .btn-red, .flat-calm .lobby-choices .btn-red.fx-in { animation: fx-fade .9s ease backwards; }
@keyframes fx-fade { from { opacity: 0; } to { opacity: 1; } }
