/* The Vault: his black + gold and Geist; the 3D carries the look, the controls stay quiet. */
:root {
  --bg: #050505;
  --ink: #ffffff;
  --mute: #b5afa5;
  --faint: #827c73;
  --gold: #ecc354;
  --gold-grad: linear-gradient(90deg, #fae49e 0%, #f0c862 42%, #d6a12a 100%);
  --card: rgba(16, 15, 13, 0.92);
  --line: rgba(255, 255, 255, 0.1);
  --sans: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--ink); font-family: var(--sans); overflow: hidden; }
body { min-height: 100dvh; -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none; }
#c { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
[hidden] { display: none !important; }

/* a photograph's lens: a soft vignette and a little grain */
.vignette { position: fixed; inset: 0; pointer-events: none; z-index: 1; background: radial-gradient(120% 90% at 50% 45%, transparent 55%, rgba(0, 0, 0, 0.55) 100%); }
/* a soft dark scrim under the bottom controls, so text never sits on a lit plaque */
.vignette::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 190px; background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.62)); }
.grain { position: fixed; inset: -50%; pointer-events: none; z-index: 1; opacity: 0.045; mix-blend-mode: overlay; background-size: 160px 160px; }

/* everything over the canvas fades with the mode; it keeps its layout so the room can measure it */
.door-ui, .tabs, .circle-ui, .open-top, .open-bottom, .sheet, .skip {
  position: fixed; z-index: 2; opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity 0.4s var(--ease), transform 0.5s var(--ease), visibility 0s linear 0.4s;
}
body[data-mode="door"] .door-ui,
body[data-mode="entering"] .skip,
body[data-mode="circle"] .tabs, body[data-mode="circle"] .circle-ui,
body[data-mode="opening"] .open-top, body[data-mode="open"] .open-top, body[data-mode="lift"] .open-top, body[data-mode="closing"] .open-top,
body[data-mode="open"] .open-bottom,
body[data-mode="lift"] .sheet {
  opacity: 1; visibility: visible; pointer-events: auto; transition-delay: 0s;
}
body[data-mode="opening"] .open-top, body[data-mode="closing"] .open-top { pointer-events: none; }

.top { position: fixed; z-index: 3; top: 0; left: 0; right: 0; padding: calc(14px + var(--safe-t)) 16px 0; display: flex; justify-content: center; pointer-events: none; }
.logo { height: 32px; width: auto; }

.eyebrow { margin: 0; font-size: 12px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: #e9c46a; }

/* the door */
.door-ui { left: 0; right: 0; bottom: 0; padding: 0 16px calc(26px + var(--safe-b)); display: grid; gap: 10px; justify-items: center; text-align: center; }
.door-ui h1 { margin: 0 0 8px; font-size: 40px; line-height: 1; font-weight: 800; letter-spacing: -0.01em; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.skip { left: 0; right: 0; bottom: calc(24px + var(--safe-b)); margin: 0 auto; width: max-content; font-size: 13px; color: var(--faint); padding: 8px 14px; }

/* the circle */
.tabs { top: calc(58px + var(--safe-t)); left: 0; right: 0; display: flex; gap: 6px; justify-content: safe center; overflow-x: auto; padding: 0 16px 6px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; font-size: 14px; font-weight: 700; color: var(--mute); padding: 8px 13px; border-radius: 999px; border: 1px solid var(--line); background: rgba(8, 8, 7, 0.62); transition: background 0.25s, color 0.25s, transform 0.15s var(--ease); }
.tabs button:hover { transform: translateY(-1px); }
.tabs button[aria-current="true"] { background: var(--gold-grad); color: #111; border-color: transparent; }
.tabs button:active { transform: scale(0.98); }

.circle-ui { left: 0; right: 0; bottom: 0; padding: 0 16px calc(18px + var(--safe-b)); display: grid; gap: 14px; justify-items: center; }
.ring-nav, .page-nav { display: flex; align-items: center; gap: 10px; }
.ring-nav { width: min(100%, 440px); justify-content: space-between; }
.arrow { width: 48px; height: 48px; flex: none; border-radius: 50%; border: 1.5px solid rgba(236, 195, 84, 0.7); color: var(--gold); display: grid; place-items: center; background: rgba(8, 8, 7, 0.55); transition: transform 0.15s var(--ease), background 0.2s; }
.arrow svg { width: 18px; height: 18px; }
.arrow:hover { transform: translateY(-1px); }
.arrow:active { transform: scale(0.95); }
.side { flex: 1; font-size: 13px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side.right { text-align: right; }
.count { font-size: 15px; font-weight: 700; color: var(--mute); font-variant-numeric: tabular-nums; min-width: 52px; text-align: center; }

.pill { display: inline-flex; align-items: center; justify-content: center; height: 44px; padding: 0 20px; border-radius: 999px; font-size: 15px; font-weight: 800; text-decoration: none; transition: transform 0.15s var(--ease); white-space: nowrap; }
.pill:hover { transform: translateY(-1px); }
.pill:active { transform: scale(0.98); }
.pill.gold { background: var(--gold-grad); color: #111; }
.pill.ghost { border: 1px solid rgba(255, 255, 255, 0.24); color: var(--ink); }
.pill.big { height: 54px; width: min(100%, 340px); font-size: 16px; letter-spacing: 0.06em; text-transform: uppercase; }

/* a stand opened */
.open-top { top: calc(56px + var(--safe-t)); left: 16px; right: 16px; }
.link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--mute); padding: 6px 0; transition: color 0.2s; }
.link:hover { color: var(--ink); }
.open-top h2 { margin: 2px 0 0; font-size: 22px; font-weight: 800; color: #f0c862; text-transform: uppercase; letter-spacing: 0.02em; }
.open-top small { font-size: 14px; font-weight: 600; color: var(--faint); text-transform: none; margin-left: 6px; letter-spacing: 0; }
.open-bottom { left: 0; right: 0; bottom: 0; padding: 0 16px calc(18px + var(--safe-b)); display: grid; justify-items: center; gap: 10px; }
.hint { margin: 0; font-size: 13px; color: var(--mute); text-align: center; }

/* the lifted item: a bottom sheet on phones, a side panel on wide screens */
.sheet { left: 0; right: 0; bottom: 0; padding: 18px 16px calc(16px + var(--safe-b)); background: var(--card); border-top: 1px solid var(--line); border-radius: 18px 18px 0 0; transform: translateY(24px); }
body[data-mode="lift"] .sheet { transform: none; }
.sheet h3 { margin: 4px 0 2px; font-size: 19px; line-height: 1.2; font-weight: 800; }
.price { margin: 0; font-size: 20px; font-weight: 800; color: #f0c862; }
.note { margin: 6px 0 0; font-size: 13px; color: var(--faint); line-height: 1.4; }
.note:empty { display: none; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.actions .pill { height: 40px; font-size: 14px; padding: 0 16px; }
.drag { margin: 10px 0 0; font-size: 12px; color: var(--faint); }
@media (min-width: 900px) {
  .sheet { left: auto; top: 50%; bottom: auto; right: 24px; width: 380px; border-radius: 18px; border: 1px solid var(--line); transform: translate(16px, -50%); padding: 22px; }
  body[data-mode="lift"] .sheet { transform: translate(0, -50%); }
  .sheet h3 { font-size: 22px; }
  .door-ui h1 { font-size: 52px; }
}

.loading { position: fixed; z-index: 2; left: 16px; bottom: calc(6px + var(--safe-b)); margin: 0; font-size: 11px; color: var(--faint); pointer-events: none; }
.credit { position: fixed; z-index: 2; right: 16px; bottom: calc(6px + var(--safe-b)); margin: 0; font-size: 11px; color: #5f5a52; pointer-events: none; transition: opacity 0.4s var(--ease); }
body:not([data-mode="door"]) .credit { opacity: 0; }
@media (min-width: 900px) { body[data-mode="circle"] .credit { opacity: 1; } }
