/* ────────────────────────────────────────────────────────── */
/*  TheHall.hdr — shared design system                         */
/*  Architecture, not interface. Restraint over expression.    */
/* ────────────────────────────────────────────────────────── */

/* ── faces — self-hosted, no CDN ──
   Fraunces (Undercase Type, SIL OFL): variable, wght + true optical
   sizes. The site uses exactly TWO pinned cuts (matching specimen №1):
   display (opsz 144) for titles and identity, text (opsz 28) for prose.
   SOFT and WONK pinned to 0. See the "Fraunces cuts" rules below.
   Inter Tight (SIL OFL): variable wght, labels and chrome only —
   it has none of these axes, so the settings are inert on it. */
@font-face {
  font-family: 'Fraunces';
  src: url('fonts/fraunces/fraunces-latin-full-normal.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Fraunces';
  src: url('fonts/fraunces/fraunces-latin-full-italic.woff2') format('woff2');
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Inter Tight';
  src: url('fonts/inter-tight/inter-tight-latin-wght-normal.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #f4f2ee;
  --bg-2: #ece9e2;
  --bg-3: #e4e0d6;
  --ink: rgba(0, 0, 0, 0.82);
  --ink-mid: rgba(0, 0, 0, 0.62);
  --ink-dim: rgba(0, 0, 0, 0.42);
  --ink-faint: rgba(0, 0, 0, 0.18);
  --rule: rgba(0, 0, 0, 0.08);
  --rule-2: rgba(0, 0, 0, 0.05);
  --hl: rgba(0, 0, 0, 0.85);
  --serif: 'Fraunces', 'Times New Roman', serif;
  --sans: 'Inter Tight', -apple-system, sans-serif;
  --gutter: 40px;
  --col: 1320px;
  --col-narrow: 880px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

/* ── Fraunces cuts — the two approved instances, nothing in between ──
   Default: the text cut, everywhere serif prose appears. font-variation-
   settings inherits, and Inter Tight simply ignores axes it lacks. */
html { font-variation-settings: 'opsz' 28, 'SOFT' 0, 'WONK' 0; }

/* the display cut — titles, identity, and the large italic accents */
.entrance-mark h1,
.entrance-mark .thesis,
.room-head h1,
.ex-divider h2,
.ex-divider .subtitle,
.door-title,
.floor .plate-title,
.ex-foot .end,
.ex-foot .next .h,
.statement p,
.index-row .t,
.text-row .h,
.prog-cell .what,
.tech-section h3,
.essay h2,
.essay h3,
.gate-h {
  font-variation-settings: 'opsz' 144, 'SOFT' 0, 'WONK' 0;
}

html, body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  line-height: 1.5;
}

::selection { background: var(--ink); color: var(--bg); }

/* a faint paper grain over everything — no mix-blend-mode: any blend mode
   other than normal forces 8-bit GPU compositing on the entire document,
   which destroys smooth gradients in HDR images. Plain opacity overlay only. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.72' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: inherit; text-decoration: none; }

/* ───────── safari gate ─────────
   opaque, above everything except the paper grain (9999) — behind it the
   page is fully covered and interaction is blocked in JS. */
.gate {
  position: fixed;
  inset: 0;
  z-index: 9998;
  background: var(--bg);
  display: grid;
  place-items: center;
  padding: 0 var(--gutter);
  text-align: center;
}
.gate-body { max-width: 640px; }
.gate-top {
  font-size: 9px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 40px;
}
.gate-h {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.gate-h em { font-style: italic; color: var(--hl); }
.gate-p {
  margin: 32px auto 0;
  font-family: var(--serif);
  font-size: 17px;
  font-style: italic;
  line-height: 1.6;
  color: var(--ink-mid);
  max-width: 520px;
}
.gate-actions {
  margin-top: 52px;
  display: inline-flex;
  gap: 44px;
  align-items: baseline;
  border-top: 1px solid var(--rule);
  padding-top: 26px;
}
.gate-btn {
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--ink);
  cursor: pointer;
  user-select: none;
  transition: color 0.4s ease, letter-spacing 0.4s ease;
}
.gate-btn:hover { letter-spacing: 0.4em; }
.gate-btn-dim { color: var(--ink-dim); }
.gate-btn-dim:hover { color: var(--ink); }
.gate-note {
  margin-top: 36px;
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
/* the gated page holds still behind the gate */
html.no-safari body { overflow: hidden; height: 100vh; }

/* ───────── chrome ───────── */

.chrome {
  position: fixed;
  top: 0; left: 0; right: 0;
  padding: 22px var(--gutter);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  z-index: 100;
}
.chrome-l, .chrome-c, .chrome-r {
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink);
}
.chrome-c { text-align: center; color: var(--ink-mid); }
.chrome-r { text-align: right; display: flex; gap: 28px; justify-content: flex-end; }
.chrome-r a { opacity: 0.6; transition: opacity 0.5s ease; }
.chrome-r a:hover, .chrome-r a.on { opacity: 1; }

.wordmark {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: 17px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
}
.wordmark .dim {
  color: var(--ink-mid);
  font-style: normal;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  margin-left: 8px;
}

/* ───────── footer rail ───────── */

.rail {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  padding: 16px var(--gutter);
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
  z-index: 90;
  border-top: 1px solid var(--rule);
  background: linear-gradient(180deg, transparent, rgba(244, 242, 238, 0.85));
  /* backdrop-filter removed — forces 8-bit compositing of entire scene in Safari */
}
.rail .c { text-align: center; }
.rail .r { text-align: right; font-variant-numeric: tabular-nums; }
.rail .cap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.rail .cap::before {
  content: "";
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--ink-mid);
  display: inline-block;
}
.rail .cap.hdr::before {
  background: var(--hl);
}

/* ───────── room (page) wrapper ───────── */

main.room {
  min-height: 100vh;
  padding-bottom: 80px;
}

/* ───────── room head — architectural section opener ───────── */

.room-head {
  max-width: var(--col);
  margin: 0 auto;
  padding: 200px var(--gutter) 100px;
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 80px;
  align-items: end;
}
.room-head .num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--ink-dim);
}
.room-head .num span {
  display: block;
  margin-top: 10px;
  font-family: var(--sans);
  font-style: normal;
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.room-head h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(40px, 5.5vw, 84px);
  line-height: 0.98;
  letter-spacing: -0.022em;
  color: var(--ink);
}
.room-head h1 em { color: var(--ink-mid); font-style: italic; }
.room-head .sub {
  margin-top: 22px;
  font-family: var(--serif);
  font-size: 17px;
  font-style: italic;
  color: var(--ink-mid);
  max-width: 580px;
}

/* ───────── shared sub-rule ───────── */

.rule {
  max-width: var(--col);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.rule hr {
  border: none;
  height: 1px;
  background: var(--rule);
}

/* ───────── colophon strip (every page) ───────── */

.colophon {
  padding: 100px var(--gutter) 80px;
  border-top: 1px solid var(--rule);
  position: relative;
  z-index: 10;
}
/* ── registry — quiet newsletter row above the colophon grid.
   the form carries the address to the beehiiv subscribe page (GET ?email=),
   so no keys live in the client. */
.registry {
  max-width: var(--col);
  margin: 0 auto 80px;
  padding-bottom: 60px;
  border-bottom: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 60px;
  flex-wrap: wrap;
}
.registry h4 {
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 14px;
  font-weight: 400;
}
.reg-lead p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 17px;
  color: var(--ink-mid);
}
.reg-form {
  display: flex;
  align-items: baseline;
  gap: 32px;
  flex: 0 1 480px;
}
.reg-input {
  flex: 1;
  min-width: 200px;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--rule);
  border-radius: 0;
  padding: 8px 2px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  color: var(--ink);
  transition: border-color 0.5s ease;
}
.reg-input::placeholder { color: var(--ink-faint); }
.reg-input:focus {
  outline: none;
  border-bottom-color: var(--ink-mid);
}
.reg-btn {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  white-space: nowrap;
  transition: color 0.4s ease, letter-spacing 0.4s ease;
}
.reg-btn:hover {
  color: var(--ink);
  letter-spacing: 0.38em;
}

.colophon-grid {
  max-width: var(--col);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 60px;
  align-items: start;
}
.colophon-grid h4 {
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 18px;
  font-weight: 400;
}
.colophon-grid p, .colophon-grid li {
  font-family: var(--serif);
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink);
  list-style: none;
}
.colophon-grid li { margin-bottom: 6px; color: var(--ink-mid); }
.colophon-grid li a:hover { color: var(--ink); }
.col-statement p {
  color: var(--ink-mid);
  max-width: 460px;
}
.colophon-foot {
  max-width: var(--col);
  margin: 80px auto 60px;
  padding-top: 28px;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

/* ────────────────────────────────────────── */
/*  ENTRANCE HALL (homepage)                  */
/* ────────────────────────────────────────── */

.entrance {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 0 var(--gutter);
  position: relative;
}
.entrance-mark {
  text-align: center;
  max-width: 1100px;
}
.entrance-mark .meta-top {
  font-size: 10px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 56px;
}
.entrance-mark h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(72px, 12vw, 200px);
  line-height: 0.9;
  letter-spacing: -0.028em;
  color: var(--ink);
}
.entrance-mark h1 em {
  font-style: italic;
  color: var(--hl);
}
.entrance-mark .thesis {
  margin-top: 44px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 19px;
  color: var(--ink-mid);
  letter-spacing: 0.005em;
}

/* descend cue — a quiet invitation at the foot of the entrance */
.entrance-cue {
  position: absolute;
  bottom: 44px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  font-size: 9px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-dim);
  transition: opacity 1.6s ease;
}
.entrance-cue::after {
  content: "";
  width: 1px;
  height: 36px;
  background: var(--rule);
}
body.is-quiet .entrance-cue { opacity: 0; }

.entrance-mark .now {
  margin-top: 64px;
  font-family: var(--serif);
  font-size: 17px;
  color: var(--ink-mid);
  letter-spacing: 0.005em;
}
.entrance-mark .now em { color: var(--ink); font-style: italic; }
.entrance-mark .now a {
  display: inline-block;
  margin-top: 18px;
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-dim);
  border-bottom: 1px solid var(--rule);
  padding-bottom: 4px;
  transition: color 0.5s, border-color 0.5s;
}
.entrance-mark .now a:hover {
  color: var(--ink);
  border-color: var(--ink-mid);
}

/* ── foyer — the halls as doorways ──
   Two unlit rooms seen from the entrance hall. Each doorway carries the
   same light-language as the plates: dimmed at rest, the lights come up
   when the visitor approaches (hover). */
.doors {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px var(--gutter);
  border-top: 1px solid var(--rule);
  position: relative;
  z-index: 10;
}
.doors-body {
  max-width: var(--col);
  width: 100%;
}
.doors-head {
  text-align: center;
  font-size: 9px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 72px;
}
.doors-inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 56px;
  align-items: start;
}
.door { display: block; }
.door-label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 16px;
}
.door-label .r::before {
  content: "";
  display: inline-block;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--ink-mid);
  margin-right: 8px;
  margin-bottom: 1px;
}
.door-frame {
  aspect-ratio: 4 / 5;
  max-height: 52vh;
  width: 100%;
  background-size: cover;
  background-position: 50% 52%;
  /* an unlit room. hover = the lights come up — the same slow, museum-paced
     ramp the plates use, so the doorway keeps the halls' light-language.
     the image itself holds perfectly still: only the light changes. */
  filter: brightness(0.5);
  transition: filter 1400ms cubic-bezier(0.35, 0, 0.75, 1);
  box-shadow:
    0 2px 40px rgba(0, 0, 0, 0.08),
    0 1px 8px  rgba(0, 0, 0, 0.06);
}
.door:hover .door-frame {
  filter: brightness(0.96);
}
.door-title {
  margin-top: 26px;
  font-family: var(--serif);
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.door-title em { font-style: italic; color: var(--ink-mid); }
.door:hover .door-title em { color: var(--hl); }
.door-desc {
  margin-top: 12px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-mid);
  max-width: 440px;
}
.door-meta {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.door-meta .enter {
  color: var(--ink-mid);
  transition: color 0.5s ease, letter-spacing 0.5s ease;
}
.door:hover .door-meta .enter {
  color: var(--ink);
  letter-spacing: 0.36em;
}

/* institution paragraph — single quiet statement (a full chamber) */
.statement {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 100px var(--gutter);
  text-align: center;
  border-top: 1px solid var(--rule);
  position: relative;
  z-index: 10;
}
.statement p { max-width: 880px; margin: 0 auto; }
.statement p {
  font-family: var(--serif);
  font-size: clamp(22px, 2.2vw, 30px);
  line-height: 1.4;
  color: var(--ink-mid);
  letter-spacing: -0.005em;
}
.statement p em { color: var(--ink); font-style: italic; }
.statement .below {
  margin-top: 64px;
  font-size: 9px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

/* ────────────────────────────────────────── */
/*  EXHIBITIONS INDEX                          */
/* ────────────────────────────────────────── */

.index {
  max-width: var(--col);
  margin: 0 auto;
  padding: 0 var(--gutter) 60px;
}
.index-row {
  display: grid;
  grid-template-columns: 80px 1fr 1.4fr 180px 140px;
  gap: 40px;
  padding: 44px 0;
  border-top: 1px solid var(--rule);
  align-items: center;
  position: relative;
  transition: background 0.6s ease;
}
.index-row:last-of-type { border-bottom: 1px solid var(--rule); }
.index-row:hover { background: linear-gradient(90deg, transparent, rgba(255,255,255,0.012), transparent); }
.index-row .n {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  color: var(--ink-mid);
}
.index-row .t {
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.1;
  color: var(--ink);
  letter-spacing: -0.005em;
}
.index-row .t a:hover { color: var(--hl); }
.index-row .t em { color: var(--ink-mid); font-style: italic; }
.index-row .d {
  font-family: var(--serif);
  font-size: 14px;
  color: var(--ink-mid);
  line-height: 1.55;
}
.index-row .meta {
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
  line-height: 1.9;
}
.index-row .status {
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-mid);
  text-align: right;
}
.index-row .status.now { color: var(--hl); }
.index-row .status.now::before {
  content: "";
  display: inline-block;
  width: 4px; height: 4px;
  background: var(--hl);
  border-radius: 50%;
  margin-right: 8px;
  margin-bottom: 2px;
  box-shadow: 0 0 6px rgba(236, 232, 222, 0.5);
}

.index-foot {
  max-width: var(--col);
  margin: 0 auto;
  padding: 60px var(--gutter) 60px;
}
.index-foot p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  color: var(--ink-dim);
  max-width: 560px;
  line-height: 1.55;
}

/* ────────────────────────────────────────── */
/*  EXHIBITION (Hall page)                    */
/* ────────────────────────────────────────── */

.ex-divider {
  height: 92vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 0 var(--gutter);
  border-top: 1px solid var(--rule);
  position: relative;
  z-index: 10;
}
.ex-divider .top {
  font-size: 9px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 36px;
}
.ex-divider h2 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(54px, 8vw, 130px);
  line-height: 0.95;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.ex-divider h2 em { color: var(--hl); font-style: italic; }
.ex-divider .subtitle {
  margin-top: 32px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: var(--ink-mid);
}
.ex-divider .meta {
  margin-top: 64px;
  display: inline-flex;
  gap: 48px;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
  padding-top: 28px;
  border-top: 1px solid var(--rule);
}

.ex-intro {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--gutter);
  border-top: 1px solid var(--rule);
  position: relative;
  z-index: 10;
}
.ex-intro > div,
.ex-intro-body {
  max-width: var(--col-narrow);
  width: 100%;
  margin: 0 auto;
}
.ex-intro p {
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.55;
  color: var(--ink);
  margin-bottom: 22px;
}
.ex-intro p.dim { color: var(--ink-mid); }

/* ────────────────────────────────────────── */
/*  GROUND + VIGNETTE — atmospheric layers    */
/* ────────────────────────────────────────── */

.ground {
  position: fixed; inset: 0; z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 42%, rgba(0,0,0,0.012) 0%, transparent 100%),
    radial-gradient(ellipse 50% 50% at 18% 80%, rgba(120,100,60,0.04) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 84% 14%, rgba(120,100,60,0.03) 0%, transparent 70%),
    var(--bg);
  pointer-events: none;
}
.vignette {
  position: fixed; inset: 0; z-index: 5;
  pointer-events: none;
  background: radial-gradient(ellipse 90% 85% at 50% 46%,
    transparent 40%,
    rgba(210, 205, 195, 0.22) 68%,
    rgba(200, 194, 182, 0.58) 100%);
}

/* ────────────────────────────────────────── */
/*  INSCRIPTION — fixed top, gallery title    */
/* ────────────────────────────────────────── */

.inscription {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 90;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  pointer-events: none;
  transition: opacity 1.6s ease;
}
.inscription-back {
  position: absolute;
  left: var(--gutter);
  font-family: var(--sans);
  font-size: 0.52rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-dim);
  font-weight: 200;
  pointer-events: auto;
  text-decoration: none;
  transition: color 0.4s ease, letter-spacing 0.4s ease;
}
.inscription-back:hover {
  color: var(--ink);
  letter-spacing: 0.34em;
}

.inscription-rule {
  width: 32px;
  height: 1px;
  background: var(--rule);
}
.inscription-text {
  font-family: var(--sans);
  font-size: 0.56rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-dim);
  font-weight: 200;
}
.inscription-text em {
  font-style: normal;
  color: var(--ink-mid);
}

/* ────────────────────────────────────────── */
/*  PLATE — chamber + work, soft on paper     */
/* ────────────────────────────────────────── */

.plate {
  height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  position: relative;
  padding: 64px 5.5vw 100px;
  overflow: hidden;
  z-index: 10;
}

.work {
  position: relative;
  max-width: min(88vw, 1700px);
  max-height: calc(100vh - 44px - 80px - 8vh);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #111;
  box-shadow:
    0 2px 40px rgba(0, 0, 0, 0.08),
    0 1px 8px  rgba(0, 0, 0, 0.06);
}
.work::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0, 0, 0, 0.45);
  opacity: 1;
  /* the slow ramp is the room lights coming up — deliberate, museum-paced.
     gated in JS so .is-adapted only flips once the image is decode-ready,
     so the lights never come up over an unpainted slot. */
  transition: opacity 3600ms cubic-bezier(0.35, 0, 0.75, 1);
  pointer-events: none;
}
.plate.is-adapted .work::before { opacity: 0; }

/* glide pages: the scrim ramp is driven per-frame by JS via --scrim.
   The CSS opacity transition ran nested inside the stage's transform
   transition, and when the stage transition completed Safari rebuilt the
   layer tree and RESTARTED the in-flight opacity animation — lights came
   up, snapped back to dark, came up again. No transition → no restart.
   (Hall I keeps the transition path above until it's ported.) */
body.glide .work::before,
body.glide .plate.is-adapted .work::before {
  transition: none;
  opacity: var(--scrim, 1);
  /* own compositor layer — while the stage's transform animation runs,
     WebKit's overlap testing fails to keep an un-composited overlay stacked
     above the composited img (translateZ(0)): the scrim silently drops
     BELOW the image and vanishes mid-glide, then pops back when the layer
     tree is rebuilt at glide end. An explicit layer keeps it above the
     image at all times, and opacity updates become compositor-only. */
  transform: translateZ(0);
}

/* same layer treatment for the inner vignette — same overlap situation,
   subtler symptom (gradient popping in at glide end). */
body.glide .work::after {
  transform: translateZ(0);
}

/* the image itself doesn't fade in — it snaps to visible the moment it's
   decoded, hidden under the scrim. the scrim is the only visible reveal,
   and it's only lifted (via .is-adapted, gated in JS on decode-ready) once
   the image underneath is actually paint-ready. */
.work img {
  opacity: 0;
}
.work img.loaded { opacity: 1; }

.work img {
  display: block;
  width: auto;
  height: auto;
  max-width: min(88vw, 1700px);
  max-height: calc(100vh - 44px - 80px - 8vh);
  /* force own GPU compositing layer so Safari renders at display-native
     bit depth (10-bit / EDR) rather than the parent layer's 8-bit path */
  transform: translateZ(0);
}
/* a soft inner vignette that integrates the image with the room */
.work::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom,
      rgba(0,0,0,0.08) 0%, transparent 18%,
      transparent 72%, rgba(0,0,0,0.12) 100%),
    linear-gradient(to right,
      rgba(0,0,0,0.05) 0%, transparent 14%,
      transparent 86%, rgba(0,0,0,0.05) 100%);
  pointer-events: none;
}

/* placeholder variant for forthcoming plates (Hall II) */
.plate-frame-placeholder {
  position: relative;
  width: min(86vw, 1560px);
  aspect-ratio: 16 / 9;
  max-height: 76vh;
  background-size: cover;
  background-position: center;
  box-shadow:
    0 2px 40px rgba(0, 0, 0, 0.08),
    0 1px 8px  rgba(0, 0, 0, 0.06);
  filter: brightness(0.55) contrast(1.01);
  transition: filter 2400ms cubic-bezier(0.35, 0, 0.75, 1);
}
.plate.is-adapted .plate-frame-placeholder { filter: brightness(0.97) contrast(1.01); }
.ph-note-below {
  position: absolute;
  bottom: 3.4vh;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  pointer-events: none;
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

/* ────────────────────────────────────────── */
/*  FLOOR — fixed bottom, identity + notation */
/* ────────────────────────────────────────── */

.floor {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 90;
  height: 80px;
  display: flex;
  align-items: center;
  padding: 0 5.5vw;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1.6s ease;
}
body.on-plate .floor {
  opacity: 1;
  pointer-events: auto;
}
body.is-quiet .inscription { opacity: 0; }
body.is-quiet.on-plate .floor { pointer-events: none; }
body.is-quiet.on-plate .floor .notation,
body.is-quiet.on-plate .floor .instruments { opacity: 0; }
body.is-quiet.on-plate .floor .identity { opacity: 0.28; }

/* while inspect is open, keep the floor's plate identity visible.
   the room's other instruments (Mastering / Licensing / audio) fade out. */
body.inspect-active.is-quiet.on-plate .floor { pointer-events: auto; }
body.inspect-active.is-quiet.on-plate .floor .identity { opacity: 1; }
body.inspect-active.is-quiet.on-plate .floor .notation { opacity: 0; }

.floor .identity {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 260px;
  transition: opacity 1.6s ease;
}
.floor .plate-serial {
  font-family: var(--sans);
  font-size: 0.52rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
  font-weight: 200;
}
.floor .plate-title {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: 1.12rem;
  letter-spacing: 0.02em;
  color: var(--ink);
  line-height: 1;
}

.floor .notation {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  transition: opacity 1.6s ease;
}
.floor .note {
  font-family: var(--sans);
  font-size: 0.56rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-dim);
  font-weight: 200;
  padding: 0 18px;
  white-space: nowrap;
  position: relative;
}
.floor .note + .note::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 10px;
  background: var(--rule);
}

.floor .instruments {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 28px;
  min-width: 220px;
  justify-content: flex-end;
  transition: opacity 1.6s ease;
}
.floor .inst {
  font-family: var(--sans);
  font-size: 0.56rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  font-weight: 200;
  cursor: default;
  user-select: none;
  white-space: nowrap;
  transition: color 400ms ease, letter-spacing 400ms ease;
}
.floor .inst:hover {
  color: var(--ink);
  letter-spacing: 0.28em;
}

/* the explicit Inspect toggle is retired — clicking the plate enters zoom */
#inspectBtn { display: none; }

/* mastering button — clickable, active state */
#masteringBtn { cursor: pointer; }
.floor .inst.is-active {
  color: var(--ink);
  letter-spacing: 0.28em;
}

/* mastering panel — floats above the floor, right-aligned */
.mastering-panel {
  position: fixed;
  bottom: 92px;
  right: 5.5vw;
  z-index: 91;
  min-width: 220px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 340ms ease, transform 340ms ease;
}
.mastering-panel.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.mp-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 28px;
  padding: 7px 0;
  border-bottom: 1px solid var(--rule);
}
.mp-row:last-child { border-bottom: none; }
.mp-key {
  font-family: var(--sans);
  font-size: 0.5rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-dim);
  font-weight: 200;
  white-space: nowrap;
}
.mp-val {
  font-family: var(--sans);
  font-size: 0.5rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-mid);
  font-weight: 300;
  text-align: right;
  white-space: nowrap;
}
/* live display reading — slightly brighter to distinguish from mastered data */
.mp-val--live {
  color: var(--ink);
  font-weight: 400;
}
/* thin rule between authored metadata and display detection */
.mp-divider {
  height: 1px;
  background: var(--rule);
  margin: 3px 0;
}

/* ── click-to-zoom affordance on the adapted plate ── */
.plate.is-adapted .work img { cursor: zoom-in; }
body.inspect-active .plate.is-adapted .work img { cursor: default; }

/* while inspecting, pin the seed image to its own compositor layer so
   seed-phase zoom/pan never triggers main-thread repaints. scoped to
   inspect-active only — a permanent will-change on all 8 plates would
   waste layer memory. */
body.inspect-active .plate.is-adapted .work img { will-change: transform; }

/* ── floor instrument modes ──
   room mode: Mastering · Licensing · audio
   inspect mode: Leave · − · + · Reset
   crossfade by opacity; pointer-events follow visibility */
.floor .inst-room,
.floor .audio-btn {
  transition: opacity 400ms ease, color 400ms ease, letter-spacing 400ms ease;
}
body.inspect-active .floor .inst-room,
body.inspect-active .floor .audio-btn {
  opacity: 0;
  pointer-events: none;
}

/* ── inspect ── */

/* dim — sits between ground(0) and plates(10), darkens the room */
.inspect-dim {
  position: fixed;
  inset: 0;
  z-index: 8;
  /* animate opacity, never background-color — a colour transition repaints
     the full viewport on the main thread every frame; opacity runs entirely
     on the compositor. */
  background: rgba(4, 3, 2, 0.84);
  opacity: 0;
  pointer-events: none;
  transition: opacity 700ms ease;
}
body.inspect-active .inspect-dim { opacity: 1; }

/* full-res layer — lives inside .work, clipped by its overflow:hidden */
.inspect-layer {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent; /* no dark frame behind the full-res image */
  cursor: grab;
}
.inspect-layer.dragging { cursor: grabbing; }
.inspect-layer img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
  transform-origin: center;
  will-change: transform;
  opacity: 0;
  transition: opacity 500ms ease;
}
.inspect-layer img.loaded { opacity: 1; }

/* plate identity stays in the floor while inspecting — light against the dim */
body.inspect-active .floor .plate-serial { color: rgba(248, 244, 235, 0.55); }
body.inspect-active .floor .plate-title  { color: rgba(248, 244, 235, 0.9);  }

/* ── inspect controls bar ──
   the only inspect-mode UI: Leave · − · + · Reset.
   centered at the bottom, light text so it reads on top of the dim. */
.inspect-controls {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 95;
  display: flex;
  align-items: baseline;
  gap: 36px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 600ms ease;
}
body.inspect-active .inspect-controls {
  opacity: 1;
  pointer-events: auto;
}
body.inspect-active.is-quiet .inspect-controls { opacity: 0; }

.inspect-ctl {
  display: inline-block;               /* span → inline-block so padding works */
  padding: 10px 8px;                   /* generous click target */
  font-family: var(--sans);
  font-size: 0.56rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 200;
  color: rgba(248, 244, 235, 0.85);   /* light, reads on top of the dim */
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: color 400ms ease, letter-spacing 400ms ease;
}
.inspect-ctl:hover {
  color: rgba(248, 244, 235, 1);
  letter-spacing: 0.28em;
}

.inspect-ctl-zoom {
  min-width: 32px;
  padding: 4px 10px;
  text-align: center;
  font-size: 1.1rem;
  letter-spacing: 0;
  font-weight: 200;
  line-height: 1;
}
.inspect-ctl-zoom:hover { letter-spacing: 0; }

/* ── inspect resolution status ──
   tiny top-centre readout: a soft pulsing ring while the full-res loads,
   a steady lit dot once it's actually on screen. fades with the rest of the
   inspect chrome (and away when idle). */
.inspect-status {
  position: fixed;
  top: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 95;
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--sans);
  font-size: 0.52rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 200;
  color: rgba(248, 244, 235, 0.7);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 600ms ease, color 400ms ease;
}
body.inspect-active .inspect-status { opacity: 1; }
body.inspect-active.is-quiet .inspect-status { opacity: 0; }
.inspect-status.is-full { color: rgba(248, 244, 235, 0.92); }

.ist-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  border: 1px solid rgba(248, 244, 235, 0.55);
  background: transparent;
  transition: background 450ms ease, border-color 450ms ease, box-shadow 450ms ease;
  animation: ist-pulse 1.4s ease-in-out infinite;
}
.inspect-status.is-full .ist-dot {
  background: rgba(248, 244, 235, 0.95);
  border-color: rgba(248, 244, 235, 0.95);
  box-shadow: 0 0 7px rgba(248, 244, 235, 0.5);
  animation: none;
}
@keyframes ist-pulse {
  0%, 100% { opacity: 0.35; }
  50%      { opacity: 1; }
}

/* ── audio instrument ── */
.audio-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: default;
  user-select: none;
  color: var(--ink-dim);
  padding-left: 4px;
  border-left: 1px solid var(--rule);
  margin-left: 4px;
  transition: color 400ms ease;
}
.audio-btn:hover { color: var(--ink); }
.audio-btn svg { width: 13px; height: 13px; display: block; }
.audio-btn .wave { opacity: 0; transition: opacity 360ms ease; }
.audio-btn:hover .wave { opacity: 1; }
.audio-btn.playing { color: var(--ink-mid); }
.audio-btn.playing .wave { opacity: 1; }

/* ────────────────────────────────────────── */
/*  Quiet — the room dims around the work.    */
/*  After a short stillness, chrome recedes.  */
/* ────────────────────────────────────────── */

.chrome,
.rail {
  transition: opacity 1.6s ease;
}
body.is-quiet .chrome,
body.is-quiet .rail {
  opacity: 0;
  pointer-events: none;
}
body.is-quiet .ph-note-below { opacity: 0.4; }

/* ────────────────────────────────────────── */
/*  Chamber sections — JS handles stepping    */
/* ────────────────────────────────────────── */

/* scroll-behavior: smooth REMOVED — hall pages no longer scroll at all.
   Chamber stepping translates .stage with a compositor-driven transform
   transition (sub-pixel, unthrottled, immune to main-thread jank). */

/* the transform-scrolled stage */
.stage {
  position: relative;      /* offsetTop of sections resolves against the stage */
  z-index: 10;             /* the z every stepped section already carried —
                              keeps the inspect dim (z8) under the content,
                              identical to the old document-level stacking */
  will-change: transform;
}
/* .glide, not .hall — Hall I still document-scrolls (old code); only the
   transform-scrolled pages (Hall II, entrance) may lock the document. */
body.glide {
  height: 100vh;
  overflow: hidden;        /* the document must never scroll underneath */
}
.ex-divider,
.ex-intro,
.ex-foot {
  min-height: 100vh;
}

/* hide scrollbars on hall pages — chamber stepping is the navigation */
body.hall {
  scrollbar-width: none;
  -ms-overflow-style: none;
}
body.hall::-webkit-scrollbar { display: none; width: 0; height: 0; }
body.hall { overflow-x: hidden; }

/* prevent browser overscroll bounce from breaking out of chambers */
body.hall { overscroll-behavior-y: contain; }

/* end-of-exhibition / ex-foot */
.ex-foot {
  text-align: center;
  padding: 200px var(--gutter);
  border-top: 1px solid var(--rule);
  position: relative;
  z-index: 10;
}
.ex-foot .end {
  font-family: var(--serif);
  font-style: italic;
  font-size: 28px;
  color: var(--ink-mid);
  letter-spacing: -0.005em;
}
.ex-foot-nav {
  margin-top: 52px;
  display: inline-flex;
  gap: 40px;
  align-items: center;
  border-top: 1px solid var(--rule);
  padding-top: 24px;
}
.foot-nav-item {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  text-decoration: none;
  transition: color 0.4s ease, letter-spacing 0.4s ease;
}
.foot-nav-item:hover {
  color: var(--ink);
  letter-spacing: 0.38em;
}
.ex-foot .next {
  margin-top: 80px;
  display: inline-block;
  border-top: 1px solid var(--rule);
  padding-top: 28px;
}
.ex-foot .next .l {
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 12px;
}
.ex-foot .next .h {
  font-family: var(--serif);
  font-size: 30px;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.ex-foot .next .h em { color: var(--ink-mid); font-style: italic; }
.ex-foot .next a:hover .h { color: var(--hl); }

/* ────────────────────────────────────────── */
/*  TEXTS                                     */
/* ────────────────────────────────────────── */

.texts {
  max-width: var(--col);
  margin: 0 auto;
  padding: 0 var(--gutter) 60px;
}
.text-row {
  display: grid;
  grid-template-columns: 80px 1fr 2fr 180px;
  gap: 40px;
  padding: 52px 0;
  border-top: 1px solid var(--rule);
  align-items: start;
}
.text-row:last-of-type { border-bottom: 1px solid var(--rule); }
.text-row .n {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  color: var(--ink-mid);
}
.text-row .h {
  font-family: var(--serif);
  font-size: 28px;
  line-height: 1.18;
  color: var(--ink);
  letter-spacing: -0.005em;
}
.text-row .h .by {
  display: block;
  margin-top: 12px;
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.text-row .ab {
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-mid);
}
.text-row .meta {
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-align: right;
  line-height: 1.9;
}
.text-row .meta a:hover { color: var(--ink); }

/* ────────────────────────────────────────── */
/*  PROGRAMME                                 */
/* ────────────────────────────────────────── */

.programme {
  max-width: var(--col);
  margin: 0 auto;
  padding: 0 var(--gutter) 120px;
}
.prog-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border-top: 1px solid var(--rule);
}
.prog-cell {
  padding: 60px 56px 60px 0;
  border-bottom: 1px solid var(--rule);
}
.prog-cell:nth-child(odd) {
  border-right: 1px solid var(--rule);
  padding-right: 56px;
  padding-left: 0;
}
.prog-cell:nth-child(even) {
  padding-left: 56px;
  padding-right: 0;
}
.prog-cell .when {
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 16px;
}
.prog-cell .what {
  font-family: var(--serif);
  font-size: 28px;
  line-height: 1.18;
  color: var(--ink);
  letter-spacing: -0.005em;
  margin-bottom: 14px;
}
.prog-cell .what em { color: var(--ink-mid); font-style: italic; }
.prog-cell .who {
  font-family: var(--serif);
  font-size: 15px;
  color: var(--ink-mid);
  font-style: italic;
  margin-bottom: 22px;
  max-width: 460px;
  line-height: 1.5;
}
.prog-cell .where {
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.prog-coda {
  padding: 80px 0 0;
}
.prog-coda p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  color: var(--ink-dim);
  max-width: 560px;
  line-height: 1.55;
}

/* ────────────────────────────────────────── */
/*  TECHNICAL                                 */
/* ────────────────────────────────────────── */

.tech-page {
  max-width: var(--col-narrow);
  margin: 0 auto;
  padding: 0 var(--gutter) 80px;
}
.tech-section {
  padding: 80px 0;
  border-top: 1px solid var(--rule);
}
.tech-section:last-of-type { border-bottom: 1px solid var(--rule); }
.tech-section h3 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 32px;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 12px;
}
.tech-section h3 em { color: var(--ink-mid); font-style: italic; }
.tech-section .lab {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 22px;
}
.tech-section p {
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-mid);
  margin-bottom: 18px;
  max-width: 720px;
}
.tech-section p em { color: var(--ink); font-style: italic; }

.tech-spec {
  margin-top: 32px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 0;
  border-top: 1px solid var(--rule);
}
.tech-spec dt, .tech-spec dd {
  padding: 18px 0;
  border-bottom: 1px solid var(--rule);
  font-variant-numeric: tabular-nums;
}
.tech-spec dt {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.tech-spec dd {
  font-family: var(--serif);
  font-size: 16px;
  color: var(--ink);
  line-height: 1.5;
}
.tech-spec dd em { color: var(--ink-mid); font-style: italic; }

/* ────────────────────────────────────────── */
/*  ESSAY (long-form text page)               */
/* ────────────────────────────────────────── */

.essay {
  max-width: 740px;
  margin: 0 auto;
  padding: 0 var(--gutter) 120px;
}
.essay h2 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.018em;
  margin-bottom: 24px;
  color: var(--ink);
}
.essay .byline {
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 60px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--rule);
}
.essay p {
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.7;
  color: var(--ink);
  margin-bottom: 22px;
}
.essay p.dim { color: var(--ink-mid); }
.essay h3 {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: 22px;
  color: var(--ink-mid);
  margin: 56px 0 18px;
}

/* ────────────────────────────────────────── */
/*  RESPONSIVE                                */
/* ────────────────────────────────────────── */

/* ── dynamic viewport units — on iPhone/iPad the toolbar changes the
   visual viewport; dvh tracks it (the resize handler re-seats the stage) */
@supports (height: 100dvh) {
  body.glide { height: 100dvh; }
  .plate { height: 100dvh; }
  .entrance, .doors, .statement,
  .ex-divider, .ex-intro, .ex-foot { min-height: 100dvh; }
  .work,
  .work img { max-height: calc(100dvh - 44px - 80px - 8vh); }
  @media (max-width: 900px) {
    .door { min-height: 100dvh; }
  }
}

/* ── touch devices: no hover exists — the doorways stand lit, and the
   enter cue reads at rest */
@media (hover: none) {
  .door-frame { filter: brightness(0.85); }
  .door-meta .enter { color: var(--ink-mid); }
}

/* ── coarse pointers: honest tap targets for the inspect instruments */
@media (pointer: coarse) {
  .inspect-ctl { font-size: 0.68rem; padding: 14px 12px; }
  .inspect-ctl-zoom { font-size: 1.3rem; min-width: 44px; }
  .floor .inst { padding: 8px 0; }
}

/* ── notch / home-indicator clearance */
.floor { padding-bottom: env(safe-area-inset-bottom, 0px); }
.inspect-controls { bottom: calc(32px + env(safe-area-inset-bottom, 0px)); }

/* ── short wide viewports (iPad landscape): compact the foyer so all
   three doorways + their text fit inside a single chamber page */
@media (min-width: 901px) and (max-height: 940px) {
  .doors { padding: 48px var(--gutter); }
  .doors-head { margin-bottom: 36px; }
  .doors-inner { gap: 44px; }
  .door-frame { max-height: 38vh; }
  .door-title { margin-top: 18px; font-size: 24px; }
  .door-desc { margin-top: 8px; font-size: 13.5px; }
  .door-meta { margin-top: 14px; padding-top: 12px; }
}

@media (max-width: 900px) {
  :root { --gutter: 22px; }
  .chrome { grid-template-columns: 1fr auto; }
  .chrome-c { display: none; }
  .chrome-r { gap: 16px; }
  .chrome-r a:nth-child(n+4) { display: none; }
  .room-head { grid-template-columns: 1fr; gap: 28px; padding-top: 130px; padding-bottom: 60px; }
  .index-row { grid-template-columns: 50px 1fr; gap: 16px; padding: 28px 0; }
  .index-row .d, .index-row .meta, .index-row .status { grid-column: 2; text-align: left; }
  .text-row { grid-template-columns: 50px 1fr; gap: 16px; padding: 32px 0; }
  .text-row .ab, .text-row .meta { grid-column: 2; }
  .text-row .meta { text-align: left; }
  .prog-grid { grid-template-columns: 1fr; }
  .prog-cell, .prog-cell:nth-child(odd), .prog-cell:nth-child(even) {
    padding: 40px 0;
    border-right: none;
  }
  .colophon-grid { grid-template-columns: 1fr; gap: 36px; }
  .colophon-foot { flex-direction: column; gap: 12px; }
  .registry { flex-direction: column; gap: 28px; margin-bottom: 56px; padding-bottom: 44px; }
  .reg-form { width: 100%; flex: 1 1 auto; }

  /* ── the floor on phones: identity + instruments only; the dense
     notation row belongs to wider rooms */
  .floor {
    height: auto;
    min-height: 64px;
    padding: 10px var(--gutter) calc(12px + env(safe-area-inset-bottom, 0px));
    gap: 14px;
  }
  .floor .notation { display: none; }
  .floor .identity { min-width: 0; flex: 1 1 auto; }
  .floor .plate-title { font-size: 1rem; }
  .floor .instruments { min-width: 0; gap: 18px; }

  /* plates breathe closer to the phone's edges */
  .plate { padding: 52px 4vw 90px; }
  .work,
  .work img { max-width: 92vw; }

  /* floor panels span the width instead of hugging a corner */
  .mastering-panel {
    right: var(--gutter);
    left: var(--gutter);
    bottom: calc(78px + env(safe-area-inset-bottom, 0px));
    min-width: 0;
    background: rgba(244, 242, 238, 0.96);
    padding: 10px 14px;
  }
  .plate-cap { grid-template-columns: 1fr; gap: 20px; bottom: 90px; }
  .plate-cap .pt { border-left: none; padding-left: 0; }
  .plate-cap details { text-align: left; }
  .plate-cap details .tech { text-align: left; }
  /* ── portrait foyer: one hall per screen. Each doorway is a full-height
     page (a [data-page] anchor the stepper lands on exactly); the head
     line floats over the first page. */
  .doors { padding: 0 var(--gutter); }
  .doors-head {
    position: absolute;
    top: 64px; left: 0; right: 0;
    margin-bottom: 0;
    z-index: 2;
  }
  .doors-inner { grid-template-columns: 1fr; gap: 0; }
  .door {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 96px 0 120px;   /* clears the chrome above, the rail below */
  }
  .door-frame { aspect-ratio: 16 / 10; max-height: 36vh; }
  .door-title { font-size: 26px; }
  /* colophon: bottom padding clears the fixed rail/floor on its last page */
  .colophon { padding-bottom: 150px; }
  .colophon-foot { margin-bottom: 0; }
  .rail { grid-template-columns: 1fr; padding: 12px var(--gutter) 14px; gap: 4px; }
  .rail .c, .rail .r { text-align: left; }
  .tech-spec { grid-template-columns: 1fr; }
  .tech-spec dt { padding-bottom: 4px; border-bottom: none; }
  .tech-spec dd { padding-top: 6px; }
}
