:root {
  --lime: #d7e021;
  --blue: #303994;
  --blue-3: #232a75;
  --navy: #1a1f5e;
  --ink: #161b52;
  --paper: #f4f4ec;
  --font: "Helvetica Neue", Inter, Helvetica, Arial, sans-serif;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --display: clamp(34px, 3.9vw, 60px);
  --body: clamp(16px, 1.25vw, 19px);
  --small: 13px;
  --gutter: clamp(16px, 3.9vw, 56px);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  margin: 0; background: var(--blue); color: var(--paper);
  font: 400 var(--body)/1.45 var(--font);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
p, h1, h2, ul { margin: 0; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--lime); outline-offset: 3px; border-radius: 8px; }

.display { font-size: var(--display); font-weight: 500; line-height: 1; letter-spacing: -0.045em; }
.body { font-size: var(--body); line-height: 1.4; }
.small { font-size: var(--small); line-height: 1.4; }

/* ---------- header ---------- */
html.js:not(.built) .top, html.js:not(.built) .map { opacity: 0; }
.top {
  position: fixed; inset: 0 0 auto 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px var(--gutter) 0; pointer-events: none; color: var(--lime);
  transition: opacity .8s;
}
.top a, .top button { pointer-events: auto; }
.brand { display: flex; align-items: center; gap: 13px; text-decoration: none; padding: 9px 14px; margin: -9px -14px; border-radius: 999px; background: rgba(36, 43, 120, .0); transition: background .5s; }
.brand-z { width: 28px; height: 28px; fill: currentColor; }
.brand-wm { width: 130px; height: 10px; fill: currentColor; }
.top-r { display: flex; align-items: center; gap: 10px; }
.top-mail { font-size: 14px; color: var(--paper); text-decoration: none; padding: 9px 14px; margin-right: -14px; border-radius: 999px; transition: background .5s; }
.top-mail:hover { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- stage ---------- */
.stage { position: fixed; inset: 0; z-index: 0; background: var(--blue); }
#town { display: block; width: 100%; height: 100%; opacity: 0; transition: opacity 1s var(--ease); }
.ready #town { opacity: 1; }
.veil { position: absolute; inset: 0; background: var(--blue); opacity: 0; pointer-events: none; transition: opacity .28s ease; }
.veil.on { opacity: 1; }
.spacer { height: 100vh; }

/* ---------- overlay (hotspots + crew) ---------- */
.overlay { position: fixed; inset: 0; z-index: 10; pointer-events: none; overflow: hidden; }
.hot { position: absolute; left: 0; top: 0; width: 10px; height: 10px; pointer-events: auto; border-radius: 14px; display: block; visibility: hidden; }
.hot.on { visibility: visible; }
.hot:focus-visible { outline: 2px dashed var(--lime); outline-offset: 2px; }

.crew { position: absolute; left: 0; top: 0; width: var(--cw, 80px); height: var(--ch, 80px); visibility: hidden; opacity: 0; pointer-events: none; will-change: transform; }
.crew.on { visibility: visible; }
.crew.on .crew-hit { pointer-events: auto; }
.crew-hit { position: absolute; inset: 0; padding: 0; border: 0; background: none; cursor: pointer; border-radius: 40% 40% 12px 12px; -webkit-tap-highlight-color: transparent; }
.crew-hit:focus-visible { outline: 2px solid var(--lime); outline-offset: 2px; }
.dept {
  position: absolute; left: var(--lx, 50%); top: var(--ly, 100%); transform: translate(-50%, 4px);
  padding: 3px 8px; border-radius: 6px; background: var(--ink); color: var(--paper);
  font-size: 12px; font-weight: 500; line-height: 1.3; white-space: nowrap; pointer-events: none;
  box-shadow: 0 0 0 1px rgba(244, 244, 236, .16);
}
.file {
  position: absolute; left: 50%; top: 0; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 11px 7px 8px; border-radius: 11px; background: #fff; color: #1d1d1f;
  font-size: 13px; font-weight: 500; white-space: nowrap;
  box-shadow: 0 14px 30px -12px rgba(16, 20, 70, .6);
  opacity: 0; transform: translate(var(--fx, -50%), -80%) scale(.92); pointer-events: none;
  transition: opacity .25s, transform .45s var(--ease);
}
.ficon { width: 19px; height: 24px; flex: none; }
.role { order: 1; font-weight: 600; color: var(--ink); }
.file > span:not(.role) { display: none; }   /* the label is the file icon and the role; no file name */
.crew .dept { display: none; }
.ficon text { font: 600 6.4px/1 var(--font); fill: #fff; }
.crew.on:hover .file, .crew:focus-within .file, .crew.open .file, .crew.near .file { opacity: 1; transform: translate(var(--fx, -50%), calc(-100% - 6px)) scale(1); }

/* ---------- captions: pure type over a soft vignette ---------- */
.captions { position: fixed; inset: 0; z-index: 20; pointer-events: none; }
.cap { position: absolute; left: var(--gutter); top: 50%; width: min(31vw, 450px); opacity: 0; visibility: hidden; transform: translateY(-50%); will-change: opacity, transform; }
.cap[data-pos="TL"] { top: 17vh; transform: none; }
.cap[data-pos="TR"], .cap[data-pos="R"], .cap[data-pos="BR"] { left: auto; right: calc(var(--gutter) + 44px); text-align: right; }
.cap[data-pos="TR"] { top: 17vh; }
.cap[data-pos="BR"] { top: auto; bottom: 6vh; }
.cap[data-pos="BL"] { top: auto; bottom: calc(64px + 5vh); transform: none; }
.cap[data-pos="TR"] .eyebrow, .cap[data-pos="R"] .eyebrow, .cap[data-pos="BR"] .eyebrow { justify-content: flex-end; }
.cap[data-pos="TR"] .body, .cap[data-pos="R"] .body, .cap[data-pos="BR"] .body { margin-left: auto; }
.cap.on { visibility: visible; }
.cap a { pointer-events: auto; }
.cap .eyebrow { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; color: var(--paper); font-weight: 500; }
.cap .num { color: var(--lime); }
.cap .display { color: var(--lime); }
.cap .body { margin-top: 16px; color: var(--paper); opacity: .88; max-width: 30ch; }
.cap-hero .display { font-size: calc(var(--display) * 1.12); }
.word { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 16px; letter-spacing: -0.05em; }
.ipa { font-size: var(--body); font-weight: 400; letter-spacing: 0; color: var(--paper); opacity: .72; }
.cap .con { margin-top: 26px; color: var(--paper); font-size: calc(var(--display) * .78); opacity: 0; transform: translateY(8px); transition: opacity .6s, transform .7s var(--ease); }
.cap .con.show { opacity: 1; transform: none; }
.redact { display: inline-block; width: 84px; height: 13px; border-radius: 3px; background: var(--ink); box-shadow: inset 0 0 0 1px rgba(244, 244, 236, .16); }
.redact.short { width: 60px; }
.go {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 22px;
  color: var(--paper); font-size: var(--body); font-weight: 500; text-decoration: none;
  padding-bottom: 3px; background: linear-gradient(var(--lime), var(--lime)) 0 100% / 100% 1.5px no-repeat;
  transition: color .3s, background-size .5s var(--ease);
}
.go span { color: var(--lime); transition: transform .4s var(--ease); display: inline-block; }
.go:hover span { transform: translate(2px, -2px); }
.mailto { color: var(--lime); text-decoration: none; font-size: clamp(30px, 3.3vw, 50px); white-space: nowrap; background: linear-gradient(currentColor, currentColor) 0 100% / 0 2px no-repeat; transition: background-size .5s var(--ease); padding-bottom: 5px; }
.mailto:hover, .mailto:focus-visible { background-size: 100% 2px; }
.crew-list { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cap-end { left: 50%; top: clamp(96px, 15vh, 150px); width: auto; transform: translateX(-50%); text-align: center; white-space: nowrap; }
.cap-end .display { font-size: calc(var(--display) * 1.12); }
.legal { position: fixed; left: var(--gutter); bottom: 22px; z-index: 20; display: flex; gap: 14px; font-size: 11px; }
.legal a { color: var(--paper); opacity: .55; text-decoration: none; transition: opacity .3s; }
.legal a:hover { opacity: 1; }
.legal { transition: opacity .4s; }
.legal.off { opacity: 0; pointer-events: none; }

.hint { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 20; display: flex; align-items: center; gap: 10px; font-size: var(--small); color: var(--paper); opacity: .75; transition: opacity .5s; pointer-events: none; }
.hint span { width: 1px; height: 22px; background: currentColor; transform-origin: top; animation: hint 2.2s var(--ease) infinite; }
@keyframes hint { 0% { transform: scaleY(0); } 55% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

/* ---------- town map ---------- */
.qa .captions, .qa .map, .qa .overlay, .qa .top, .qa .hint { visibility: hidden !important; }
.qa .captions *, .qa .map * { visibility: hidden !important; }
.map { transition: width .4s var(--ease), height .4s var(--ease), padding .4s var(--ease), border-radius .4s var(--ease), opacity .35s, transform .45s var(--ease); }
.map > * { transition: opacity .25s; }
.top-r { display: flex; align-items: center; gap: 10px; }
.map-btn, .snd-btn { display: grid; place-items: center; width: 38px; height: 38px; padding: 0; border: 0; border-radius: 50%; background: var(--blue-3); color: var(--lime); box-shadow: 0 0 0 1px rgba(244, 244, 236, .2); cursor: pointer; pointer-events: auto; transition: background .3s, color .3s; }
.map-btn svg, .snd-btn svg { width: 18px; height: 18px; }
.map-btn[aria-expanded="true"], .snd-btn[aria-pressed="true"] { background: var(--lime); color: var(--blue); }
.snd-btn .on { display: none; } .snd-btn[aria-pressed="true"] .on { display: block; } .snd-btn[aria-pressed="true"] .off { display: none; }
.map {
  position: fixed; right: var(--gutter); bottom: 28px; z-index: 25; width: clamp(196px, 17vw, 268px);
  padding: 12px 12px 12px; border-radius: 16px; background: var(--blue-3);
  box-shadow: 0 0 0 1px rgba(244, 244, 236, .14);
  opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .35s, transform .45s var(--ease), visibility 0s .45s;
}
.map.open { opacity: 1; visibility: visible; transform: none; transition: opacity .35s, transform .45s var(--ease); }
.map.open.dim { opacity: .35; }
.map.dim:hover, .map.dim:focus-within { opacity: 1; }
.map-t { color: var(--paper); opacity: .7; margin: 0 0 8px 2px; font-size: 12px; }
.map-in { position: relative; aspect-ratio: 74 / 46; }
#mapsvg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pin { position: absolute; left: calc(var(--x) * 72 / 74 + 100% / 74); top: calc(var(--y) * 44 / 46 + 100% / 46); width: 22px; height: 22px; margin: -11px 0 0 -11px; padding: 0; border: 0; background: none; cursor: pointer; display: grid; place-items: center; }
.pin::before { content: attr(data-n); display: grid; place-items: center; width: 15px; height: 15px; border-radius: 50%; background: var(--ink); color: var(--paper); font: 600 9px/1 var(--font); box-shadow: 0 0 0 1.5px var(--paper); transition: transform .35s var(--ease), background .3s, box-shadow .3s; }
.pin.active::before { background: var(--lime); color: var(--blue); box-shadow: 0 0 0 1.5px var(--ink), 0 0 0 3.5px var(--lime); transform: scale(1.18); }
.pin:hover::before { transform: scale(1.25); }
.pin span { position: absolute; bottom: calc(100% + 4px); left: 50%; transform: translate(-50%, 4px); white-space: nowrap; font-size: 12px; font-weight: 500; color: var(--blue); background: var(--paper); padding: 4px 8px; border-radius: 6px; opacity: 0; pointer-events: none; transition: opacity .25s, transform .35s var(--ease); }
.pin:hover span, .pin:focus-visible span { opacity: 1; transform: translate(-50%, 0); }
.pin:focus-visible { outline-offset: 0; border-radius: 50%; }

/* ---------- mobile ---------- */
@media (max-width: 760px) {
  :root { --display: clamp(30px, 8.8vw, 40px); }
  .top { padding-top: 14px; }
  .brand-wm { display: none; }
  .brand-z { width: 26px; height: 26px; }
  .top-mail { font-size: 13px; padding: 8px 12px; margin-right: -12px; }
  .cap, .cap[data-pos] { left: var(--gutter); right: var(--gutter); top: calc(74px + env(safe-area-inset-top)); bottom: auto; width: auto; text-align: left; }
  .cap[data-pos="B"] { top: auto; bottom: calc(64px + env(safe-area-inset-bottom)); }
  .cap[data-pos="E"] { left: 50%; right: auto; width: max-content; text-align: center; top: calc(84px + env(safe-area-inset-top)); }
  .cap[data-pos] .eyebrow { justify-content: flex-start; }
  .cap .eyebrow { margin-bottom: 10px; }
  .cap .body { margin-top: 10px; font-size: 16px; }
  .go { margin-top: 14px; font-size: 16px; }
  .mailto { font-size: clamp(28px, 8.4vw, 36px); }
  .cap-end { left: 50%; right: auto; transform: translateX(-50%); top: calc(84px + env(safe-area-inset-top)); }
  .map { top: 62px; bottom: auto; right: 12px; width: min(300px, calc(100vw - 24px)); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .3s, transform .4s var(--ease), visibility 0s .4s; }
  .map.open { opacity: 1; visibility: visible; transform: none; transition: opacity .3s, transform .4s var(--ease); }
  .cap .con { font-size: calc(var(--display) * .82); margin-top: 16px; }
  .dept { font-size: 11px; padding: 2px 6px; }
  .file { font-size: 12px; }
  .hint { bottom: 18px; }
  .legal { bottom: 18px; }
}

/* ---------- reduced motion ---------- */
.rm .cap { transition: opacity .35s ease; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; }
  .hint span { display: none; }
}

/* ---------- no JS: a readable list of all stops ---------- */
html:not(.js) .stage, html:not(.js) .overlay, html:not(.js) .map, html:not(.js) .map-btn, html:not(.js) .hint, html:not(.js) .spacer { display: none; }
html:not(.js) .top { position: static; padding-bottom: 40px; }
html:not(.js) .captions { position: static; display: grid; gap: 40px; padding: 0 var(--gutter) 64px; max-width: 760px; }
html:not(.js) .cap { position: static; opacity: 1; visibility: visible; transform: none; width: auto; }
html:not(.js) .crew-list { position: static; width: auto; height: auto; clip: auto; white-space: normal; list-style: none; padding: 0; margin-top: 16px; display: grid; gap: 4px; font-size: 15px; }
html:not(.js) .cap .con { opacity: 1; transform: none; }
html:not(.js) .cap-end { text-align: left; }
html:not(.js) .legal { position: static; padding: 0 var(--gutter) 16px; }

/* ---------- the printed page, zoomed into, becomes the footer ---------- */
.sheet { position: fixed; inset: 0; z-index: 30; background: #FBFBF5; color: var(--ink); visibility: hidden; pointer-events: none; }
.sheet.on { visibility: visible; }
.sheet.open { pointer-events: auto; }
.sheet-in { position: absolute; left: 0; top: 0; width: 100vw; height: 100vh; height: 100dvh; display: flex; flex-direction: column; justify-content: space-between; padding: 28px var(--gutter) calc(28px + env(safe-area-inset-bottom)); opacity: 0; }
.sheet-z { width: 34px; height: 34px; fill: var(--blue); }
.sheet-mid .small { color: var(--ink); opacity: .6; margin: 0 0 14px; }
.sheet-mail { display: inline-block; color: var(--blue); font-size: clamp(36px, 7.4vw, 120px); font-weight: 500; line-height: 1; letter-spacing: -0.04em; text-decoration: none; }
.sheet-mail:hover { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 8px; }
.sheet-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; font-size: 13px; color: var(--ink); opacity: .7; }
.sheet-foot nav { display: flex; gap: 18px; }
.sheet-foot a { color: inherit; text-decoration: none; }
.sheet-foot a:hover { text-decoration: underline; }
.top.gone { opacity: 0; transition: opacity .4s; }
.top.gone a, .top.gone button { pointer-events: none; }
html:not(.js) .sheet { position: static; visibility: visible; pointer-events: auto; }
html:not(.js) .sheet-in { position: static; width: auto; height: auto; min-height: 60vh; opacity: 1; }
