/* The Safe. One world: the vaporwave marble ruins. Layout system: container 1200 px, spacing 8/16/24/32/48/64/96,
   one card style (.glass), one section head (.head). Colours: cobalt ground, white ink, hot pink accent. */
:root {
  --cobalt: #1E3FD8;
  --deep: #0B1A6B;
  --night: #070A2E;
  --ink: #FFFFFF;
  --ink-2: #DCDDFF;
  --pink: #FF4FB8;
  --pink-2: #FF7FD0;
  --lilac: #B9A6FF;
  --brass: #E2BE63;
  --mint: #7CFFC4;
  --glass: rgba(9, 14, 52, 0.62);
  --glass-line: rgba(185, 166, 255, 0.38);
  --gutter: 48px;
  --container: 1344px;
  --display: "DM Serif Display", Georgia, serif;
  --sans: "Plus Jakarta Sans", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; color: var(--ink); background: var(--night);
  font: 400 18px/1.55 var(--sans); font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { display: block; }
a { color: inherit; }
b { font-weight: 800; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--mint); outline-offset: 3px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 50; padding: 12px 20px; background: var(--night); border-radius: 12px; }
.container { width: min(var(--container), 100% - 2 * var(--gutter)); margin: 0 auto; }

/* ---- nav: four words over the sky ---------------------------------------------------------------------------- */
.nav {
  position: absolute; z-index: 20; top: 0; left: 0; right: 0;
  width: min(var(--container), 100% - 2 * var(--gutter)); margin: 0 auto; padding-top: 24px;
  display: flex; align-items: center;
}
.nav-row {
  display: flex; gap: 4px; padding: 6px; border-radius: 999px;
  background: rgba(9, 14, 52, 0.42); box-shadow: inset 0 0 0 1px rgba(220, 221, 255, 0.35); backdrop-filter: blur(10px);
}
.nav-row a, .drawer a {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 600; font-size: 17px; text-decoration: none; padding: 10px 18px; border-radius: 999px;
  transition: background-color 160ms ease-out;
}
.nav-row a:hover { background: rgba(255, 255, 255, 0.16); }
.nav-row a:focus-visible, .drawer a:focus-visible { outline: 3px solid var(--mint); outline-offset: 2px; background: rgba(255, 255, 255, 0.16); }
.nav-row a:not([aria-current="page"]):hover::before { /* hover: the lamp glows faintly before it lights */
  content: ""; width: 10px; height: 10px; border-radius: 50%; flex: none; background: rgba(255, 127, 216, 0.45);
}
/* the current page wears a lit lamp, like the door */
.nav-row a[aria-current="page"]::before, .drawer a[aria-current="page"]::before {
  content: ""; width: 10px; height: 10px; border-radius: 50%; flex: none;
  background: radial-gradient(circle at 45% 40%, #FFE6F6, #FF4FB8 60%); box-shadow: 0 0 10px rgba(255, 79, 184, 0.9);
}
.menu { display: none; }
.drawer { display: none; }

/* ---- the door: the picture box and what sits on it ----------------------------------------------------------- */
.door { position: relative; height: 100svh; min-height: 680px; max-height: 1100px; overflow: hidden; background: var(--cobalt); }
.stage {
  /* placed so the first column (from 39% of the picture) starts 24 px right of the copy column, but never so far that
     the safe (to 88% of the picture) leaves the window; the stage always covers the window's right edge */
  --cr: calc(max(var(--gutter), (100% - var(--container)) / 2) + min(36vw, 520px));
  --sw: max(103%, calc(max(680px, min(100svh, 1100px)) * 1672 / 941), calc((var(--cr) + 24px) / 0.39));
  position: absolute; top: 50%; transform: translateY(-50%);
  left: clamp(calc(100% - var(--sw)), min(calc(var(--cr) + 24px - 0.39 * var(--sw)), calc(100% - 0.88 * var(--sw))), 0px);
  width: var(--sw); aspect-ratio: 1672 / 941;
  container-type: size;
  /* measured on art/site/hero-wide.png by tools/measure.mjs, percent of the picture */
  --wy: 31.8%; --wh: 8.1%; --ww: 2.63%; --ly: 26.6%; --ld: 2.1%;
}
.door-art { width: 100%; height: 100%; object-fit: cover; max-width: none; }
.wheels, .lamps, .spill { position: absolute; inset: 0; pointer-events: none; }
.spill { width: 100%; height: 100%; }
.wheel {
  position: absolute; top: var(--wy); height: var(--wh); width: var(--ww); transform: translateX(-50%);
  overflow: hidden; border-radius: 6% / 4%;
}
.wheel::after { /* the curve of the drum: darker top and bottom over the generated cream face */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(70, 40, 10, 0.55) 0%, rgba(70, 40, 10, 0) 26%, rgba(70, 40, 10, 0) 74%, rgba(70, 40, 10, 0.55) 100%);
}
.reel { position: absolute; left: 0; right: 0; top: 0; will-change: transform; }
.reel span {
  display: flex; align-items: center; justify-content: center; height: calc(100cqh * 0.081);
  font: 800 calc(100cqh * 0.058) / 1 var(--sans); color: #3B2208; letter-spacing: 0;
}
.lamp {
  position: absolute; top: var(--ly); width: var(--ld); aspect-ratio: 1; translate: -50% -50%; /* the translate property, so the scale below does not stretch it */
  border-radius: 50%; opacity: 0; transition: opacity 260ms ease-out;
  /* lit glass: a solid pink disc the size of the lamp (radius 40% of the box at scale 1.9) and its bloom around it */
  background: radial-gradient(circle at 50% 46%, #FFF2FA 0%, #FFB3E3 9%, #FF5CC0 22%, #E8209C 40%, rgba(255, 60, 170, 0.6) 46%, rgba(255, 79, 184, 0.22) 58%, rgba(255, 79, 184, 0) 72%);
  scale: 1.9;
}
.lamp.on { opacity: 1; }
.lamp.dim { opacity: 0.8; }
.lamp.flash { animation: flash 420ms ease-out 3; }
@keyframes flash { 0% { opacity: 1; } 50% { opacity: 0.25; } 100% { opacity: 1; } }

/* ---- the copy column ----------------------------------------------------------------------------------------- */
.copy {
  position: absolute; z-index: 10; top: 0; bottom: 0; left: max(var(--gutter), (100% - var(--container)) / 2);
  /* the nav pill ends at 82 px: 32 px below it, and "safe center" never pushes the name up under it */
  width: min(36vw, 520px); display: flex; flex-direction: column; justify-content: safe center; padding: 114px 0 24px;
}
.name {
  position: relative; margin: 0 0 16px; font: 400 clamp(60px, min(10.2vw, 12.5svh), 140px) / 0.9 var(--display);
  letter-spacing: -0.01em; color: transparent;
}
.name::before { /* the chrome: an iridescent fill on a copy of the same letters, so the real text stays selectable */
  content: attr(data-text); white-space: pre; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(172deg, #FFFFFF 8%, #E9E4FF 30%, #FFC2EC 46%, #FFFFFF 54%, #B8F4FF 70%, #F3EEFF 88%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 2px 0 rgba(120, 60, 200, 0.55)) drop-shadow(0 0 24px rgba(255, 127, 216, 0.45));
}
.headline { margin: 0 0 16px; font: 800 clamp(24px, 1.95vw, 30px) / 1.2 var(--sans); text-shadow: 0 2px 18px rgba(5, 6, 15, 0.45); }
.headline em { font-style: normal; color: var(--pink-2); }
.lede { margin: 0 0 24px; max-width: 34em; color: var(--ink-2); text-shadow: 0 1px 12px rgba(5, 6, 15, 0.55); }
.actions { display: flex; gap: 16px; margin-bottom: 16px; }
.actions .btn { flex: 1 1 0; padding: 0 1em; }
.btn {
  text-decoration: none;
  min-height: 56px; padding: 0 1.4em; border-radius: 999px; border: 0; cursor: pointer;
  font-weight: 800; font-size: 19px; line-height: 1; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center;
  transition: transform 140ms ease-out, background-color 160ms ease-out, box-shadow 160ms ease-out;
}
.btn:active { transform: translateY(1px) scale(0.98); }
.btn:disabled { cursor: not-allowed; color: rgba(255, 255, 255, 0.45); box-shadow: none; }
.btn-pink { background: linear-gradient(180deg, #FF6CC8, #F23AA8); box-shadow: 0 10px 30px rgba(255, 79, 184, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.45); color: #fff; }
.btn-pink:hover { box-shadow: 0 12px 38px rgba(255, 79, 184, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.45); }
.btn-pink:disabled { background: rgba(255, 79, 184, 0.28); }
.btn-glass { background: rgba(14, 22, 80, 0.45); box-shadow: inset 0 0 0 1.5px rgba(220, 221, 255, 0.7); backdrop-filter: blur(8px); color: #fff; }
.btn-glass:hover { background: rgba(14, 22, 80, 0.62); }
.btn-wide { width: 100%; }

/* the contract: the address on its own line across the whole column, then three equal keys under it */
.bar {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 16px; border-radius: 20px;
  background: rgba(9, 14, 52, 0.78); box-shadow: inset 0 0 0 1px rgba(220, 221, 255, 0.45); backdrop-filter: blur(10px);
}
.ca { grid-column: 1 / -1; min-width: 0; display: flex; flex-direction: column; padding: 0 4px 4px; }
.ca-label { font-size: 16px; font-weight: 600; color: var(--lilac); line-height: 1.3; }
.ca-value { font: 500 16px/1.4 var(--mono); color: var(--ink); overflow-wrap: anywhere; user-select: all; }
.ca-value.empty { font-family: var(--sans); font-weight: 600; user-select: none; white-space: nowrap; }
.chip {
  min-height: 48px; padding: 0 16px; border-radius: 14px; border: 0; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; flex: none;
  font-weight: 700; font-size: 16px; background: #F3F0FF; color: #0B1A6B;
  transition: background-color 160ms ease-out, transform 140ms ease-out;
}
.chip:hover { background: #FFFFFF; box-shadow: 0 0 0 2px var(--pink-2); }
.chip:active { transform: translateY(1px); }
.chip:focus-visible { outline: 3px solid var(--mint); outline-offset: 2px; }
/* before launch: plainly "not yet", still readable (white 78% on the deep glass = 9:1) */
.chip[aria-disabled="true"], .chip:disabled { color: rgba(255, 255, 255, 0.78); cursor: not-allowed; background: rgba(255, 255, 255, 0.08); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.35); }
.chip[aria-disabled="true"] img, .chip:disabled img { opacity: 0.7; }
.bar .chip img { width: 20px; height: 20px; }
.chip.ok { background: var(--mint); color: #062B1C; }
.status:empty, .status:has(> :only-child:empty) { visibility: hidden; }
.status {
  margin: 12px 0 0; padding: 8px 16px; border-radius: 12px; font-size: 16px; font-weight: 600; color: var(--ink-2);
  background: rgba(7, 10, 46, 0.72); backdrop-filter: blur(6px); align-self: flex-start;
}
.status .tag { color: var(--mint); }

/* ---- sections ----------------------------------------------------------------------------------------------- */
.clues {
  position: relative; padding: 96px 0;
  /* the plaza's columns stand at the far edges; under the content they fade into the night */
  background:
    linear-gradient(90deg, rgba(7, 10, 46, 0.92) 0%, rgba(7, 10, 46, 0.55) 18%, rgba(7, 10, 46, 0.2) 34%, rgba(7, 10, 46, 0.2) 66%, rgba(7, 10, 46, 0.55) 82%, rgba(7, 10, 46, 0.92) 100%),
    linear-gradient(180deg, rgba(7, 10, 46, 0.35), rgba(7, 10, 46, 0.6)),
    url("/img/clues-bg.webp") center / cover no-repeat, var(--night);
}
.head { margin-bottom: 48px; max-width: 760px; }
.head h2 { margin: 0 0 8px; font: 400 clamp(44px, 5vw, 64px) / 1 var(--display); }
.head p { margin: 0; color: var(--ink-2); }
.glass {
  background: var(--glass); border-radius: 24px; box-shadow: inset 0 0 0 1px var(--glass-line), 0 20px 60px rgba(3, 4, 20, 0.45);
  backdrop-filter: blur(14px); padding: 32px;
}
.clue-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 24px; align-items: start; }
.label { margin: 0 0 8px; font-size: 16px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--lilac); }
.big { margin: 0; font: 400 clamp(64px, 7vw, 104px) / 1 var(--display); color: #fff; }
.big.known { color: var(--pink-2); }
.fit-note { margin: 16px 0 32px; color: var(--ink-2); }
.suggest { display: flex; flex-direction: column; gap: 24px; }
.tiles { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.tile {
  position: relative; isolation: isolate; height: 72px; display: flex; align-items: center; justify-content: center;
  font: 800 36px/1 var(--sans); color: #3B2208;
}
.tile::before { /* the brass wheel face (a drum, like the six on the door) */
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: 12px;
  background: linear-gradient(180deg, #B8862F 0%, #FFF3D6 18%, #FFF8E8 50%, #F5E1B5 82%, #A6782A 100%);
  box-shadow: inset 0 0 0 2px #8C6420, 0 4px 14px rgba(0, 0, 0, 0.35);
}
.tile.blank { color: rgba(59, 34, 8, 0.3); }
.suggest-actions { display: flex; gap: 16px; flex-wrap: wrap; }
.suggest-actions .btn { flex: 1 1 200px; }
.ledger { display: flex; flex-direction: column; max-height: 640px; }
.ledger-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.pot { margin: 0; font-weight: 700; color: var(--ink-2); }
.pot b { color: var(--brass); }
.rows { list-style: none; margin: 16px 0 0; padding: 0; overflow-y: auto; flex: 1; scrollbar-width: thin; scrollbar-color: rgba(185, 166, 255, 0.5) transparent; }
.row {
  position: relative; display: grid; grid-template-columns: 56px auto 1fr auto; align-items: center; gap: 16px; padding: 12px 0;
}
.row + .row::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; background: rgba(185, 166, 255, 0.18); }
.row.new { animation: slide 420ms ease-out; }
@keyframes slide { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: none; } }
.row .k { font-weight: 700; color: var(--lilac); }
.row .code { font: 500 22px/1 var(--mono); letter-spacing: 0.12em; }
.row .dots { display: flex; gap: 6px; }
.row .dot { width: 14px; height: 14px; border-radius: 50%; background: rgba(255, 255, 255, 0.14); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25); }
.row .dot.on { background: radial-gradient(circle at 45% 40%, #FFE3F4, var(--pink) 60%); box-shadow: 0 0 10px rgba(255, 79, 184, 0.8); }
.row .who { font-size: 16px; color: var(--ink-2); text-align: right; }
.row .who a { text-decoration: none; }
.row .who a:hover { text-decoration: underline; }
.row.relock .code, .row.relock .dots { opacity: 0.4; }
.row.open .code { color: var(--pink-2); }
.empty-rows { color: var(--ink-2); padding: 16px 0; }

.how { padding: 96px 0; background: linear-gradient(180deg, #0B1A6B 0%, #070A2E 100%); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: 24px; align-items: stretch; }
.step { height: 100%; background: var(--glass); border-radius: 24px; box-shadow: inset 0 0 0 1px var(--glass-line); overflow: hidden; display: flex; flex-direction: column; }
.step img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.step h3 { margin: 24px 32px 8px; font: 400 32px/1.1 var(--display); }
.step p { margin: 0 32px 32px; color: var(--ink-2); }
.step a, .head a { color: var(--pink-2); }

/* ---- the opened banner ---------------------------------------------------------------------------------------- */
.opened-banner {
  position: fixed; z-index: 40; left: 50%; bottom: 24px; transform: translateX(-50%);
  width: min(720px, 100% - 32px); display: grid; grid-template-columns: 220px 1fr; align-items: center; gap: 24px;
  padding: 16px 32px 16px 16px; border-radius: 24px; background: rgba(9, 14, 52, 0.86);
  box-shadow: inset 0 0 0 1.5px rgba(255, 213, 120, 0.7), 0 24px 80px rgba(0, 0, 0, 0.55); backdrop-filter: blur(12px);
  animation: rise 420ms ease-out;
}
.opened-banner[hidden] { display: none; }
@keyframes rise { from { opacity: 0; transform: translate(-50%, 24px); } to { opacity: 1; transform: translate(-50%, 0); } }
.opened-banner img { width: 220px; height: auto; border-radius: 14px; }
.opened-text p { margin: 0; color: var(--ink-2); }
.opened-text .opened-title { font: 400 34px/1.1 var(--display); color: #FFE7A8; margin-bottom: 8px; }

/* ---- the dial dialog ------------------------------------------------------------------------------------------ */
.dial {
  border: 0; padding: 0; margin: auto auto auto max(var(--gutter), (100% - var(--container)) / 2);
  width: min(560px, 100% - 32px); max-height: calc(100svh - 48px); color: var(--ink); border-radius: 28px;
  background: rgba(9, 14, 52, 0.9); box-shadow: inset 0 0 0 1.5px var(--glass-line), 0 30px 100px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(16px);
}
.dial::backdrop { background: rgba(5, 6, 15, 0.25); }
.dial[open] { animation: rise-in 260ms ease-out; }
@keyframes rise-in { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.dial-in { padding: 32px; display: flex; flex-direction: column; gap: 16px; }
.dial-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.dial-head h2 { margin: 0; font: 400 40px/1 var(--display); }
.close { min-height: 48px; padding: 0 20px; border-radius: 999px; border: 0; background: rgba(255, 255, 255, 0.12); font-weight: 700; font-size: 16px; cursor: pointer; }
.dial-sub { margin: 0; color: var(--ink-2); }
.digits { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.digits input {
  width: 100%; height: 84px; border: 0; border-radius: 14px; text-align: center; padding: 0;
  font: 800 44px/1 var(--sans); color: #3B2208; caret-color: var(--pink);
  background: linear-gradient(180deg, #B8862F 0%, #FFF3D6 18%, #FFF8E8 50%, #F5E1B5 82%, #A6782A 100%);
  box-shadow: inset 0 0 0 2px #8C6420;
}
.digits input:focus-visible { outline: 3px solid var(--pink); outline-offset: 2px; }
.dial-lamps { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; justify-items: center; }
.dial-lamps span { width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #4A4A7A, #11122C 70%); box-shadow: inset 0 0 0 2px #B48A36; transition: background 220ms ease-out, box-shadow 220ms ease-out; }
.dial-lamps span.on { background: radial-gradient(circle at 45% 40%, #FFE6F6, var(--pink) 60%); box-shadow: inset 0 0 0 2px #B48A36, 0 0 16px rgba(255, 79, 184, 0.9); }
.dial-answer { margin: 0; min-height: 1.6em; font-weight: 700; text-align: center; }
.dial-row { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.dial-row .btn { flex: 1 1 200px; }
.amount { display: flex; align-items: center; gap: 8px; font-weight: 700; padding: 0 0 0 20px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); min-height: 56px; }
.amount input { width: 100px; min-height: 56px; border: 0; background: transparent; color: #fff; font: 700 19px var(--sans); padding: 0 20px 0 0; }
.amount[hidden] { display: none; }
.wallets { display: flex; flex-wrap: wrap; gap: 8px; }
.wallets:empty { display: none; }
.wallets .chip[aria-pressed="true"] { background: rgba(255, 79, 184, 0.35); }
.wallets .chip img { width: 22px; height: 22px; border-radius: 6px; }
.dial-memo { margin: 0; font-size: 16px; color: var(--ink-2); }
.dial-memo code { font: 500 16px var(--mono); color: #fff; }
.dial-memo .chip { min-height: 40px; padding: 0 14px; margin: 0 4px; }

/* ---- other pages ---------------------------------------------------------------------------------------------- */
.page-hero { position: relative; min-height: 340px; display: flex; align-items: flex-start; padding: 120px 0 32px; background: var(--deep) center / cover no-repeat; }
.page-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(7, 10, 46, 0.82) 0%, rgba(7, 10, 46, 0.45) 45%, rgba(7, 10, 46, 0) 70%), linear-gradient(0deg, rgba(7, 10, 46, 0.9) 0%, rgba(7, 10, 46, 0) 40%); }
.page-hero .container { position: relative; }
.page-hero h1 { margin: 0 0 16px; font: 400 clamp(52px, 6vw, 88px) / 0.95 var(--display); text-shadow: 0 2px 24px rgba(5, 6, 15, 0.6); }
.page-hero p { display: inline-block; margin: 0; max-width: 40em; padding: 12px 20px; border-radius: 14px; color: var(--ink); background: rgba(7, 10, 46, 0.8); backdrop-filter: blur(8px); }
.page-body { padding: 64px 0 96px; background: linear-gradient(180deg, #070A2E 0%, #0B1A6B 100%); }
.vaults { display: flex; flex-direction: column; gap: 24px; }
.vault { display: grid; grid-template-columns: 200px minmax(0, 1fr) auto; gap: 32px; align-items: center; }
.vault .n { font: 400 64px/1 var(--display); color: #FFE7A8; }
.vault .n small { display: block; font: 700 16px/1.4 var(--sans); color: var(--lilac); letter-spacing: 0.06em; text-transform: uppercase; }
.vault dl { margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 24px; }
.vault dt { font-size: 16px; font-weight: 700; color: var(--lilac); }
.vault dd { margin: 0; font-weight: 700; overflow-wrap: anywhere; }
.vault dd code { font: 500 16px var(--mono); }
.vault dd .codebig { font: 500 26px var(--mono); letter-spacing: 0.12em; color: var(--pink-2); }
.vault .check { display: flex; flex-direction: column; gap: 8px; align-items: stretch; min-width: 220px; }
.vault .verdict { margin: 0; font-size: 16px; font-weight: 700; min-height: 1.5em; }
.vault .verdict.good { color: var(--mint); }
.vault .verdict.bad { color: var(--pink-2); }
.vault .links { font-size: 16px; color: var(--ink-2); }
.vault .links a { color: var(--ink-2); }
.note-line { margin: 0 0 32px; color: var(--ink-2); }
.rules-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.rules-grid h2 { margin: 0 0 16px; font: 400 36px/1.1 var(--display); }
.rules-grid ul, .rules-grid ol { margin: 0; padding-left: 1.2em; }
.rules-grid li { margin-bottom: 8px; color: var(--ink-2); }
.rules-grid li b { color: #fff; }
.rules-grid code, .formula { font: 500 16px/1.6 var(--mono); color: #fff; overflow-wrap: anywhere; }
.formula { display: block; margin: 16px 0; padding: 16px 20px; border-radius: 14px; background: rgba(255, 255, 255, 0.07); }
.split { margin-top: 8px; }
.split p { position: relative; margin: 0; padding: 12px 0; display: flex; justify-content: space-between; gap: 16px; color: var(--ink-2); }
.split p + p::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; background: rgba(185, 166, 255, 0.2); }
.split b { color: #fff; white-space: nowrap; }
.nf { position: relative; min-height: 100svh; display: flex; align-items: center; background: var(--deep) url("/img/empty-safe.webp") 65% center / cover no-repeat; }
.nf .container { position: relative; }
.nf h1 { margin: 0 0 16px; max-width: 5.6em; font: 400 clamp(56px, 8vw, 120px) / 0.95 var(--display); }
.nf p { margin: 0 0 32px; max-width: 26em; color: var(--ink-2); text-shadow: 0 1px 12px rgba(5, 6, 15, 0.6); }

/* ---- narrow ------------------------------------------------------------------------------------------------- */
@media (max-width: 1100px) {
  .clue-grid { grid-template-columns: minmax(0, 1fr); }
  .ledger { max-height: 560px; }
  .vault { grid-template-columns: 140px minmax(0, 1fr); }
  .vault .check { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; }
}
@media (max-width: 960px) {
  .copy { width: min(52vw, 560px); }
  .steps { grid-template-columns: minmax(0, 1fr); max-width: 560px; }
  .rules-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 900px) {
  :root { --gutter: 16px; }
  .nav { padding-top: 12px; justify-content: flex-end; }
  .nav-row { display: none; }
  .menu { display: inline-flex; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 0; font-weight: 700; font-size: 17px; background: rgba(9, 14, 52, 0.55); box-shadow: inset 0 0 0 1px rgba(220, 221, 255, 0.5); backdrop-filter: blur(8px); cursor: pointer; align-items: center; }
  .drawer:not([hidden]) { display: flex; flex-direction: column; position: fixed; z-index: 30; top: 72px; right: 16px; left: 16px; padding: 16px; border-radius: 24px; background: rgba(9, 14, 52, 0.95); box-shadow: inset 0 0 0 1px var(--glass-line), 0 20px 60px rgba(0, 0, 0, 0.5); }
  .drawer a { padding: 14px 16px; font-size: 20px; }
  .door { height: auto; min-height: 0; max-height: none; overflow: visible; background: var(--night); }
  .stage {
    position: relative; top: auto; right: auto; transform: none; width: 100%; aspect-ratio: 941 / 1672;
    /* measured on art/site/hero-tall.png */
    --wy: 51.2%; --wh: 5.26%; --ww: 5.7%; --ly: 47.85%; --ld: 4.25%;
  }
  .reel span { height: calc(100cqh * 0.0526); font-size: calc(100cqh * 0.037); }
  .copy { position: static; width: auto; padding: 0; display: block; }
  .copy-top { position: absolute; z-index: 10; top: 72px; left: 16px; right: 16px; }
  .name { font-size: 56px; margin-bottom: 8px; }
  .headline { font-size: 22px; margin: 0; }
  .stage::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 14%; background: linear-gradient(180deg, rgba(7, 10, 46, 0), var(--night)); pointer-events: none; }
  .copy-act { position: relative; z-index: 10; margin: 0 16px; padding: 8px 0 48px; }
  .lede { font-size: 17px; max-width: none; }
  .actions { gap: 12px; }
  .actions .btn { flex: 1 1 0; padding: 0 1em; font-size: 17px; }
  .bar { flex-wrap: wrap; padding: 16px; }
  .ca { flex-basis: 100%; }
  .bar .chip { flex: 1 1 auto; }
  .clues, .how { padding: 64px 0; }
  .glass { padding: 24px; }
  .tile { height: 56px; font-size: 28px; }
  .row { grid-template-columns: 36px auto 1fr; gap: 8px 12px; }
  .row .dots { gap: 4px; justify-content: flex-end; }
  .row .dot { width: 11px; height: 11px; }
  .row .who { grid-column: 2 / -1; text-align: left; }
  .row .code { font-size: 17px; letter-spacing: 0.08em; }
  .dial { margin: auto 0 0; width: 100%; max-width: none; border-radius: 28px 28px 0 0; max-height: 92svh; }
  .dial-in { padding: 24px 16px 32px; }
  .digits input { height: 68px; font-size: 34px; }
  .opened-banner { grid-template-columns: 1fr; padding: 16px; bottom: 16px; }
  .opened-banner img { width: 100%; }
  .vault { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .vault dl { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .page-hero { min-height: 300px; padding: 96px 0 24px; }
  .page-hero::before { background: linear-gradient(0deg, rgba(7, 10, 46, 0.95) 0%, rgba(7, 10, 46, 0.55) 100%); }
  .nf { align-items: flex-start; padding-top: 120px; }
  .nf { background-position: 72% center; }
}
/* nearly square windows: the column cannot leave the copy's side without cutting the safe, so it fades into the night */
@media (min-width: 901px) and (max-aspect-ratio: 3/2) {
  .door::after {
    content: ""; position: absolute; inset: 0; z-index: 5; pointer-events: none;
    background: linear-gradient(90deg, rgba(8, 14, 62, 0.86) 0%, rgba(8, 14, 62, 0.78) 38%, rgba(8, 14, 62, 0) 52%);
  }
}
@media (min-width: 901px) and (max-height: 800px) {
  .headline { margin-bottom: 12px; }
  .lede { margin-bottom: 16px; }
  .actions .btn { min-height: 52px; }
  .bar { padding: 12px; gap: 8px; }
  .status { margin-top: 8px; }
}
@media (max-width: 360px) {
  .copy-top { top: 64px; }
  .name { font-size: 48px; }
  .headline { font-size: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---- the turnable wheels in Clues, the hint, the relocking badge ------------------------------------------------ */
button.tile { border: 0; padding: 0; background: none; cursor: pointer; width: 100%; font: 800 36px/1 var(--sans); color: #3B2208; }
button.tile:hover::before { box-shadow: inset 0 0 0 2px #8C6420, 0 0 0 2px var(--pink-2), 0 4px 14px rgba(0, 0, 0, 0.35); }
button.tile:focus-visible { outline: 3px solid var(--mint); outline-offset: 2px; border-radius: 12px; }
.hint { margin: 0; font-size: 16px; color: var(--ink-2); }
.relock-badge {
  display: inline-block; padding: 12px 18px; border-radius: 999px; font-size: 16px; font-weight: 700; line-height: 1; white-space: nowrap;
  color: #FFE7A8; background: rgba(255, 213, 120, 0.14); box-shadow: inset 0 0 0 1px rgba(255, 213, 120, 0.5);
}
.row.relock { background: rgba(5, 6, 15, 0.35); border-radius: 12px; padding: 14px 24px; margin: 4px 0; }
.row.relock .code, .row.relock .dots { opacity: 0.35; }
.row:has(.relock-badge) { grid-template-columns: auto auto 1fr auto; }
@media (max-width: 900px) { .row:has(.relock-badge) { grid-template-columns: 36px auto 1fr; } .row:has(.relock-badge) .k { grid-column: 1 / -1; } }
@media (max-width: 900px) { button.tile { font-size: 28px; } }

/* the contract keys on a phone: pump.fun gets the widest cell; under 361 px it takes its own row */
@media (max-width: 900px) { .bar { grid-template-columns: 1fr 1.5fr 0.9fr; } }
@media (max-width: 360px) { .bar { grid-template-columns: 1fr 1fr; } #link-pump { grid-column: 1 / -1; grid-row: 3; } }
