/* Silkscreen with the Czech letters it lacks (Č Ď Ě Ň Ř Ť Ů) drawn in its own style: scripts/build-pixel-font.py. */
@font-face {
  font-family: 'Silkscreen';
  font-weight: 400;
  font-display: swap;
  src: url(/fonts/silkscreen-400-cz.woff2) format('woff2');
}
@font-face {
  font-family: 'Silkscreen';
  font-weight: 700;
  font-display: swap;
  src: url(/fonts/silkscreen-700-cz.woff2) format('woff2');
}
@font-face {
  font-family: 'DM Sans';
  font-weight: 100 1000;
  font-display: swap;
  src: url(/fonts/dm-sans-latin-v17.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face {
  font-family: 'DM Sans';
  font-weight: 100 1000;
  font-display: swap;
  src: url(/fonts/dm-sans-latin-ext-v17.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}


/* GrindPrison: deepslate and iron, a rust accent for everything you can press, and the ore colours for the ranks. */
:root {
  --bg: #0D0F12;
  --bar: #121519;
  --well: #0F1216;
  --panel: #1A1E24;
  --line: #2A3038;
  --black: #07080A;
  --ink: #EEF1F4;
  --body: #C3CAD3;
  --muted: #9AA3AE;
  --rust: #D2582A;
  --rust-hi: #F07A3A;
  --rust-lo: #6E2810;
  /* Darker rust for filled buttons: white text on it passes WCAG AA (5:1); --rust alone is 4:1. */
  --rust-btn: #BF4A1E;
  --lava: #FF8A2A;
  --iron: #AAB3BE;
  --diamond: #4FE3E0;
  --gold: #FFD24A;
  --emerald: #3DDC84;
  --redstone: #FF4A3A;
  --amethyst: #B07CFF;
  --display: 'Silkscreen', ui-monospace, monospace;
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --bevel: inset 4px 4px 0 rgba(255, 255, 255, 0.3), inset -4px -4px 0 rgba(0, 0, 0, 0.3);
  --sunk: inset 4px 4px 0 #050607, inset -4px -4px 0 var(--line);
  /* Rust-and-black warning stripes, like the edge of a pit. */
  --hazard: repeating-linear-gradient(-45deg, var(--rust) 0 14px, var(--black) 14px 28px);
}

* { box-sizing: border-box; }
html { color-scheme: dark; overscroll-behavior: none; scroll-padding-top: 84px; }
/* A faint 32 px block grid under everything: the world is made of blocks. */
body { margin: 0; color: var(--body); font-family: 'DM Sans', system-ui, sans-serif; font-size: 17px; line-height: 1.6; overflow-x: hidden;
  background: linear-gradient(rgba(255, 255, 255, 0.018) 2px, transparent 2px) 0 0 / 32px 32px, linear-gradient(90deg, rgba(255, 255, 255, 0.018) 2px, transparent 2px) 0 0 / 32px 32px, var(--bg); }
a { color: var(--rust-hi); transition: color 0.18s ease; }
a:hover { color: #FFA36E; }
code { font-size: 0.95em; color: var(--ink); }
b, strong { color: var(--ink); font-weight: 600; }
h1, h2, h3 { margin: 0; color: var(--ink); }
:focus-visible { outline: 3px solid var(--diamond); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { max-width: 1200px; margin: 0 auto; padding-inline: 28px; }
.display { font-family: var(--display); font-weight: 700; text-transform: uppercase; line-height: 1.15; }
.h1 { font-size: clamp(24px, calc((100vw - 56px) / 9), 52px); text-shadow: 0 4px 0 var(--black); }
.h2 { font-size: clamp(20px, calc((100vw - 56px) / 13), 36px); text-shadow: 0 3px 0 var(--black); }
.stack-sm { display: flex; flex-direction: column; gap: 16px; }
.section { padding-block: 96px; }
.lead { margin: 0; font-size: 19px; line-height: 1.65; color: var(--body); max-width: 34em; }
.center { text-align: center; margin-inline: auto; }
.hint { color: var(--muted); font-size: 15px; }
.muted-lg { margin: 0; color: var(--body); font-size: 18px; line-height: 1.65; max-width: 40em; }

/* Header */
.topbar { position: sticky; top: 0; z-index: 20; background: rgba(18, 21, 25, 0.92); backdrop-filter: blur(8px); border-bottom: 4px solid var(--black); box-shadow: 0 2px 0 var(--line); }
.nav { height: 68px; display: flex; align-items: center; gap: 20px; }
.brand { display: flex; align-items: center; gap: 12px; min-height: 44px; margin-right: auto; text-decoration: none; }
.brand img { display: block; image-rendering: pixelated; }
.brand-icon { width: 36px; height: 36px; transition: transform 0.3s var(--spring); }
.brand-word { width: auto; height: 22px; }
.brand:hover .brand-icon { transform: rotate(-8deg) translateY(-2px); }
.brand:active .brand-icon { transform: rotate(4deg); transition-duration: 0.05s; }
.nav-links { display: none; gap: 2px; }
.nav-link, .btn-sm { white-space: nowrap; }
.nav-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px; color: var(--body); text-decoration: none; font-weight: 500; transition: color 0.18s ease; }
.nav-link:hover, .nav-link[aria-current] { color: var(--rust-hi); }
@media (min-width: 980px) { .nav-links { display: flex; } .menu { display: none; } }
/* Phones and tablets: the links behind a menu button. */
.menu { position: relative; order: 2; }
.menu-button { list-style: none; display: grid; place-items: center; width: 48px; height: 48px; cursor: pointer; background: var(--panel); border: 4px solid var(--black); box-shadow: inset 3px 3px 0 rgba(255, 255, 255, 0.06), inset -3px -3px 0 rgba(0, 0, 0, 0.35); }
.menu-button::-webkit-details-marker { display: none; }
.menu-icon, .menu-icon::before, .menu-icon::after { display: block; width: 20px; height: 4px; background: var(--ink); }
.menu-icon { position: relative; }
.menu-icon::before, .menu-icon::after { content: ''; position: absolute; left: 0; }
.menu-icon::before { top: -7px; } .menu-icon::after { top: 7px; }
.menu[open] .menu-icon { background: transparent; }
.menu[open] .menu-icon::before { top: 0; rotate: 45deg; } .menu[open] .menu-icon::after { top: 0; rotate: -45deg; }
.menu-panel { position: absolute; right: 0; top: calc(100% + 12px); z-index: 30; display: flex; flex-direction: column; min-width: 240px; padding: 8px; background: var(--bar); border: 4px solid var(--black); box-shadow: 0 8px 0 var(--black); }
.menu-panel .nav-link { min-height: 48px; padding: 0 14px; font-size: 17px; }
.menu-panel .nav-link:hover { background: var(--panel); }
.nav > .btn { order: 1; }
/* Keyboard users can jump past the menu. */
.skip-link { position: absolute; left: 12px; top: -80px; z-index: 50; padding: 12px 16px; background: var(--ink); color: var(--black); font-weight: 700; }
.skip-link:focus { top: 12px; }
#content:focus { outline: none; }
@media (max-width: 420px) { .brand-word { height: 16px; } .brand-icon { width: 30px; height: 30px; } }

/* Buttons: a pixel bevel that sinks when pressed. */
.btn { --lift: 4px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; padding: 0 28px; border: 4px solid var(--black); font: 700 16px var(--display); text-transform: uppercase; text-decoration: none; cursor: pointer;
  color: #fff; background: var(--rust-btn); text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.35);
  box-shadow: var(--bevel), 0 var(--lift) 0 var(--black); transition: transform 0.22s var(--spring), box-shadow 0.22s var(--spring), filter 0.15s; }
.btn:hover { transform: translateY(-2px); --lift: 6px; color: #fff; filter: brightness(1.08); }
.btn:active { transform: translateY(var(--lift)); --lift: 0px; transition-duration: 0s; }
.btn-iron { background: #5D656F; }
.btn-sm { min-height: 48px; padding: 0 18px; font-size: 14px; }
.btn[aria-current] { filter: brightness(0.9); }


/* The mine behind the surface: three layers that drift apart as you scroll. */
.mine { position: absolute; inset: 0; z-index: -1; --scroll: 0px; }
.mine-layer { position: absolute; left: 0; top: -8%; width: 100%; height: 116%; object-fit: cover; object-position: 50% 45%; image-rendering: pixelated; will-change: transform; }
.mine-back { transform: translate3d(0, calc(var(--scroll) * 0.45), 0); }
.mine-mid { transform: translate3d(0, calc(var(--scroll) * 0.28), 0); }
.mine-front { transform: translate3d(0, calc(var(--scroll) * 0.08), 0); }
/* The lava breathes. */
.mine-glow { position: absolute; inset: 0; background: radial-gradient(60% 45% at 50% 105%, rgba(255, 122, 42, 0.38), transparent 70%); mix-blend-mode: screen; animation: lava 4.5s ease-in-out infinite alternate; transform: translate3d(0, calc(var(--scroll) * 0.45), 0); }
@keyframes lava { from { opacity: 0.55; } to { opacity: 1; } }
.mine-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(7, 8, 10, 0.92) 0%, rgba(7, 8, 10, 0.72) 34%, rgba(7, 8, 10, 0.12) 64%, transparent 80%), linear-gradient(180deg, transparent 70%, var(--bg) 100%); }
@media (max-width: 860px) {
  .mine-layer { object-position: 58% 50%; }
  .mine-shade { background: linear-gradient(180deg, rgba(7, 8, 10, 0.55), rgba(7, 8, 10, 0.82) 60%, var(--bg)); }
}
.actions-row { display: flex; flex-wrap: wrap; gap: 14px; }
@keyframes pop { 0% { transform: scale(0.85); } 100% { transform: scale(1); } }

.counts { display: flex; flex-wrap: wrap; gap: 10px 18px; margin: 2px 0 0; font-size: 16px; color: var(--body); }
.count { display: inline-flex; align-items: center; gap: 8px; }
.count-online { color: var(--emerald); font-weight: 600; }
.pulse { width: 10px; height: 10px; background: var(--emerald); box-shadow: 0 0 0 0 rgba(61, 220, 132, 0.6); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(61, 220, 132, 0); } 100% { box-shadow: 0 0 0 0 rgba(61, 220, 132, 0); } }

/* Numbered steps (thanks page). */
.steps { margin: 0; padding: 0; list-style: none; display: grid; gap: 20px; counter-reset: s; }
.steps li { display: flex; gap: 18px; align-items: flex-start; padding: 22px; background: var(--panel); border: 4px solid var(--black); box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.05), inset -4px -4px 0 rgba(0, 0, 0, 0.3); }
.steps p { margin: 6px 0 0; color: var(--body); }
.step-n { display: grid; place-items: center; flex: none; width: 44px; height: 44px; background: var(--rust); color: #fff; border: 4px solid var(--black); font: 700 20px var(--display); box-shadow: inset 3px 3px 0 rgba(255, 255, 255, 0.3), inset -3px -3px 0 rgba(0, 0, 0, 0.25); }
@media (min-width: 860px) { .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* Feature cards, each with its own ore colour (vote page). */
.entries { margin: 0; padding: 0; list-style: none; display: grid; gap: 22px; }
@media (min-width: 700px) { .entries { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.entry { --c: var(--rust); position: relative; display: flex; flex-direction: column; gap: 14px; padding: 26px 24px 28px; background: linear-gradient(180deg, color-mix(in srgb, var(--c) 10%, transparent), transparent 60%), var(--panel);
  border: 4px solid var(--black); box-shadow: inset 0 6px 0 var(--c), inset 4px 4px 0 rgba(255, 255, 255, 0.05), inset -4px -4px 0 rgba(0, 0, 0, 0.3); transition: transform 0.28s var(--spring); }
.entry:hover { transform: translateY(-4px); }
.entry .n { font: 700 28px var(--display); color: var(--c); text-shadow: 3px 3px 0 var(--black); }
.entry h3 { font: 700 19px var(--display); text-transform: uppercase; }
.entry p { margin: 8px 0 0; }
.r-rust { --c: var(--rust-hi); } .r-diamond { --c: var(--diamond); } .r-gold { --c: var(--gold); }
.r-emerald { --c: var(--emerald); } .r-redstone { --c: var(--redstone); } .r-amethyst { --c: var(--amethyst); }

.head { display: inline-grid; place-items: center; flex: none; width: 32px; height: 32px; background: #3A4049; color: var(--ink); border: 3px solid var(--black); font: 700 14px var(--display); box-shadow: inset 3px 3px 0 rgba(255, 255, 255, 0.15), inset -3px -3px 0 rgba(0, 0, 0, 0.3); }
.head-lg { width: 56px; height: 56px; font-size: 24px; }

/* Vote */
.vote-top { display: grid; gap: 28px; align-items: start; }
@media (min-width: 900px) { .vote-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .vote-month { grid-column: 1 / -1; } }
.vote-head { display: flex; flex-direction: column; gap: 20px; align-items: flex-start; }
.vote-kicker { margin: 0 0 12px; font: 700 15px var(--display); text-transform: uppercase; color: var(--muted); }
.vote-site-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.vote-site { display: flex; align-items: center; gap: 16px; padding: 16px 20px; text-decoration: none; background: var(--panel); border: 4px solid var(--black); box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.05), inset -4px -4px 0 rgba(0, 0, 0, 0.3), 0 4px 0 var(--black); transition: transform 0.22s var(--spring); }
.vote-site:hover { transform: translateY(-2px); }
.vote-site-text { display: flex; flex-direction: column; margin-right: auto; }
.vote-site-name { font: 700 18px var(--display); color: var(--ink); text-transform: uppercase; }
.vote-site-note { font-size: 14px; color: var(--muted); }
.vote-site-go { font: 700 24px var(--display); color: var(--rust-hi); }
.month-votes { display: flex; align-items: baseline; gap: 14px; margin: 0; padding: 18px 22px; background: var(--well); border: 4px solid var(--black); box-shadow: var(--sunk); }
.month-votes-n { font: 700 36px var(--display); color: var(--gold); }
.vote-page { padding-block: 56px 96px; display: flex; flex-direction: column; gap: 72px; }
.vote-rewards { display: flex; flex-direction: column; gap: 32px; }
.panel { background: var(--well); border: 4px solid var(--black); box-shadow: var(--sunk); padding: 24px; }
.nick { display: flex; flex-direction: column; gap: 10px; }
.label { font-weight: 700; color: var(--ink); }
.nick input, .store-step input[type=text] { width: 100%; background: var(--bg); border: 4px solid var(--black); box-shadow: inset 3px 3px 0 #000; color: var(--ink); font: 700 20px var(--display); padding: 14px 16px; transition: border-color 0.18s ease; }
.nick input:focus, .store-step input[type=text]:focus { border-color: var(--rust); outline: none; }
.error { margin: 4px 0 0; color: #FF8A7A; font-weight: 500; }
.error[hidden] { display: none; }
input.invalid { border-color: #FF8A7A !important; }


/* ───────── Home: a descent through the mine. Each section is one level deeper. ───────── */
.descent { position: relative; }

/* 0 m: the surface, seen from the cell. The layers drift apart as you scroll (motion.js sets --scroll). */
.surface { position: relative; isolation: isolate; overflow: hidden; display: grid; place-items: center; min-height: min(100svh, 980px); padding-block: 64px 72px; text-align: center; background: #08090B; }
.surface .mine-shade { background: radial-gradient(70% 60% at 50% 46%, rgba(7, 8, 10, 0.86), rgba(7, 8, 10, 0.5) 70%, rgba(7, 8, 10, 0.2)), linear-gradient(180deg, transparent 72%, var(--bg)); }
.surface-inner { display: flex; flex-direction: column; align-items: center; gap: 26px; width: 100%; }
.title { font-size: clamp(40px, 10.5vw, 120px); line-height: 0.98; letter-spacing: -0.01em; }
.title span { display: block; color: var(--ink); text-shadow: 0 6px 0 var(--black), 0 0 30px rgba(0, 0, 0, 0.6); }
.title .hl { color: var(--rust-hi); text-shadow: 0 6px 0 var(--rust-lo), 0 11px 0 var(--black); }
.surface .lead { max-width: 32em; color: #E1E6EC; font-size: clamp(17px, 2.2vw, 20px); text-shadow: 0 2px 10px #000; }
.surface .actions-row { justify-content: center; }
.surface .counts { justify-content: center; }
.bedrock-line { margin: -8px 0 0; font-size: 16px; color: var(--body); }
.bedrock-line code { color: var(--gold); }
.scrollcue { display: inline-flex; flex-direction: column; align-items: center; gap: 10px; min-height: 44px; padding: 8px 12px; font: 700 14px var(--display); text-transform: uppercase; color: var(--body); text-decoration: none; }
.scrollcue::after { content: ''; width: 4px; height: 40px; background: repeating-linear-gradient(var(--iron) 0 6px, transparent 6px 12px); animation: drop 1.4s linear infinite; }
@keyframes drop { to { background-position: 0 12px; } }

/* The address is a block of gold ore: hit it and it copies. */
.ore-address { all: unset; box-sizing: border-box; display: inline-flex; align-items: center; gap: 22px; max-width: 100%; padding: 14px 22px 14px 14px; cursor: pointer; text-align: left;
  background: rgba(7, 8, 10, 0.78); border: 4px solid var(--black); box-shadow: inset 3px 3px 0 rgba(255, 255, 255, 0.06), 0 6px 0 var(--black); transition: transform 0.22s var(--spring); }
.ore-address:hover { transform: translateY(-2px); }
.ore-address:focus-visible { outline: 3px solid var(--diamond); outline-offset: 4px; }
.ore-slot { position: relative; flex: none; width: 88px; height: 88px; }
.ore-block { position: absolute; inset: 0; background: url(/img/mine/block-gold.png?v=2) 0 0 / 100% 100%; image-rendering: pixelated; border: 4px solid var(--black); box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.08); transition: transform 0.18s; }
/* Breaking cracks: ten stages in one strip (scripts/build-mine-textures.py), stepped through like digging in game. */
.ore-block::after { content: ''; position: absolute; inset: 0; background: url(/img/mine/break.png?v=2) 0 0 / 1000% 100%; image-rendering: pixelated; opacity: 0; }
.ore-address:hover .ore-block { transform: rotate(-3deg) scale(1.04); }
.ore-address.copied .ore-block { animation: dig 1.5s linear forwards; }
/* The cracks go the moment the block breaks, so it grows back as a fresh block. */
.ore-address.copied .ore-block::after { opacity: 1; animation: crack 0.7s steps(9, end) forwards, mined 0s 0.7s forwards; }
@keyframes mined { to { opacity: 0; } }
/* Each crack stage is one pickaxe hit: a small knock, then the block goes and comes back. */
@keyframes dig {
  0%, 9%, 18%, 27%, 36%, 45% { transform: none; }
  4%, 13%, 22%, 31%, 40% { transform: translate(-2px, 2px) scale(0.97); }
  47% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0); opacity: 0; }
  70% { transform: scale(0); opacity: 0; }
  90% { transform: scale(1.06); opacity: 1; }
  100% { transform: none; opacity: 1; }
}
@keyframes crack { to { background-position: 100% 0; } }
/* Debris: eight small gold and stone chips thrown out when the block breaks. */
.ore-bits { position: absolute; inset: 0; pointer-events: none; }
.ore-bits i { --a: calc(var(--i) * 45deg + 20deg); position: absolute; left: 50%; top: 50%; width: 12px; height: 12px; margin: -6px; background: var(--gold); box-shadow: inset -3px -3px 0 #8C5A0E; opacity: 0; }
.ore-bits i:nth-child(3n) { background: #4A4F5A; box-shadow: inset -3px -3px 0 #282B33; width: 10px; height: 10px; }
.ore-address.copied .ore-bits i { animation: bits 0.75s cubic-bezier(0.2, 0.6, 0.4, 1) 0.7s forwards; }
@keyframes bits {
  0% { opacity: 1; transform: rotate(var(--a)) translateX(10px); }
  100% { opacity: 0; transform: rotate(var(--a)) translateX(64px) translateY(30px) rotate(90deg); }
}
.ore-sign { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ore-hint { font: 700 14px var(--display); text-transform: uppercase; color: var(--gold); }
.ore-address.copied .ore-hint { color: var(--emerald); }
.ore-addr { font: 700 clamp(17px, 3.6vw, 32px) / 1.1 var(--display); text-transform: uppercase; color: var(--ink); text-shadow: 0 4px 0 var(--black); overflow-wrap: anywhere; }
.ore-note { font-size: 15px; color: var(--body); }

/* A level: textured rock behind a dark wash, a jagged top edge cut into the level above. */
.level { --tile: url(/img/mine/stone.png?v=2); --wash: rgba(10, 11, 14, 0.8); position: relative; padding-block: 112px 104px; background: linear-gradient(var(--wash), var(--wash)), var(--tile) 0 0 / 64px 64px; image-rendering: pixelated; }
.level > * { image-rendering: auto; }
.level::before { content: ''; position: absolute; left: 0; right: 0; top: -22px; height: 24px; z-index: 1; background: inherit; background-position: 0 -22px;
  clip-path: polygon(0 100%, 0 40%, 4% 40%, 4% 0, 9% 0, 9% 60%, 15% 60%, 15% 20%, 22% 20%, 22% 70%, 27% 70%, 27% 30%, 35% 30%, 35% 0, 41% 0, 41% 50%, 48% 50%, 48% 10%, 56% 10%, 56% 60%, 62% 60%, 62% 20%, 70% 20%, 70% 0, 77% 0, 77% 55%, 84% 55%, 84% 25%, 91% 25%, 91% 65%, 96% 65%, 96% 30%, 100% 30%, 100% 100%); }
.level-dirt { --tile: url(/img/mine/dirt.png?v=2); --wash: rgba(16, 11, 8, 0.78); }
.level-stone { --tile: url(/img/mine/stone-ore.png?v=2); }
.level-deep { --tile: url(/img/mine/deep.png?v=2); --wash: rgba(9, 9, 13, 0.78); }
.level-deep-ore { --tile: url(/img/mine/deep-ore-wide.png?v=2); --wash: rgba(8, 9, 13, 0.76); background-size: auto, 192px 192px; }
.level-wall { --tile: url(/img/mine/deep.png?v=2); --wash: rgba(7, 7, 10, 0.86); }
.level-lava { --tile: url(/img/mine/basalt.png?v=2); --wash: rgba(20, 10, 7, 0.74); text-align: center; padding-bottom: 96px;
  background: radial-gradient(80% 60% at 50% 120%, rgba(255, 110, 30, 0.35), transparent 70%), linear-gradient(var(--wash), var(--wash)), var(--tile) 0 0 / 64px 64px; }
.depth-tag { display: inline-flex; align-items: center; gap: 10px; padding: 6px 12px; font: 700 14px var(--display); text-transform: uppercase; letter-spacing: 0.04em; color: var(--c, var(--iron)); background: rgba(7, 8, 10, 0.75); border: 3px solid var(--black); }
.depth-tag::before { content: ''; width: 12px; height: 12px; background: var(--c, var(--iron)); box-shadow: 2px 2px 0 var(--black); }
.level-head { display: flex; flex-direction: column; align-items: center; gap: 14px; margin-bottom: 56px; text-align: center; }
.level-head p { margin: 0; max-width: 36em; font-size: 18px; color: var(--body); }

/* −40 m: the join steps hang off a wooden ladder (img/mine/ladder.png at 4x), each card nailed to it with a plank. */
.ladder { position: relative; max-width: 880px; margin: 0 auto; padding: 0; list-style: none; display: grid; gap: 32px; }
.ladder::before { content: ''; position: absolute; left: 50%; top: -40px; bottom: -40px; width: 64px; translate: -50% 0;
  background: url(/img/mine/ladder.png?v=2) 0 0 / 64px 64px repeat-y; image-rendering: pixelated; filter: drop-shadow(8px 8px 0 rgba(0, 0, 0, 0.45)); }
.rung { position: relative; width: calc(50% - 56px); padding: 22px 24px 24px; background: var(--panel); border: 4px solid var(--black); box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.05), inset -4px -4px 0 rgba(0, 0, 0, 0.35), 0 6px 0 var(--black); }
.rung:nth-child(even) { margin-left: auto; }
/* The plank: covers the card's border and runs onto the near rail, an iron nail at each end. */
.rung::after { content: ''; position: absolute; top: 28px; width: 48px; height: 24px; border: 4px solid var(--black);
  background: linear-gradient(#B4B9C0 0 0) left 6px center / 4px 4px no-repeat, linear-gradient(#B4B9C0 0 0) right 6px center / 4px 4px no-repeat, #82592F;
  box-shadow: inset 0 4px 0 #B5864B, inset 0 -4px 0 #5C3B1F, 0 4px 0 rgba(0, 0, 0, 0.45); }
.rung:nth-child(odd)::after { right: -48px; }
.rung:nth-child(even)::after { left: -48px; }
.rung-n { font: 700 14px var(--display); text-transform: uppercase; color: var(--rust-hi); }
.rung h3 { margin: 6px 0 8px; font: 700 20px var(--display); text-transform: uppercase; }
.rung p { margin: 0; }
.rung code { color: var(--gold); font-weight: 700; overflow-wrap: anywhere; }

/* −120 m: features at stops along a rail, alternating sides. */
.rail { position: relative; max-width: 1000px; margin: 0 auto; padding: 0; list-style: none; display: grid; gap: 28px; }
.rail::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 34px; translate: -50% 0; background:
  linear-gradient(90deg, transparent 4px, var(--iron) 4px 9px, transparent 9px 25px, var(--iron) 25px 30px, transparent 30px),
  repeating-linear-gradient(transparent 0 14px, #5A3C22 14px 22px); }
.stop { position: relative; display: grid; grid-template-columns: 1fr 34px 1fr; align-items: center; gap: 28px; }
.plaque { grid-column: 1; grid-row: 1; padding: 24px; background: linear-gradient(180deg, color-mix(in srgb, var(--c) 14%, transparent), transparent 70%), #171A20; border: 4px solid var(--black); border-top: 6px solid var(--c); box-shadow: 0 6px 0 var(--black); }
.stop:nth-child(even) .plaque { grid-column: 3; }
.node { grid-column: 2; grid-row: 1; justify-self: center; z-index: 1; width: 34px; height: 34px; background: var(--c); border: 4px solid var(--black); box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.35), inset -4px -4px 0 rgba(0, 0, 0, 0.3); }
.plaque h3 { font: 700 21px var(--display); text-transform: uppercase; color: var(--c); text-shadow: 3px 3px 0 var(--black); }
.plaque p { margin: 10px 0 0; }

/* −200 m: the top three ride in minecarts. */
.track { position: relative; margin: 0; padding: 0 0 34px; list-style: none; display: flex; justify-content: center; align-items: flex-end; gap: clamp(10px, 4vw, 56px); }
.track::after { content: ''; position: absolute; left: -24px; right: -24px; bottom: 0; height: 22px; background:
  linear-gradient(transparent 4px, var(--iron) 4px 8px, transparent 8px),
  repeating-linear-gradient(90deg, #5A3C22 0 12px, transparent 12px 30px) 0 10px / 100% 12px no-repeat; }
.cart { --c: var(--iron); display: flex; flex-direction: column; align-items: center; gap: 6px; width: clamp(96px, 24vw, 200px); min-width: 0; text-align: center; }
.cart-1 { --c: var(--gold); order: 2; width: clamp(112px, 30vw, 250px); }
.cart-2 { order: 1; }
.cart-3 { --c: #E0894A; order: 3; }
.cart-place { font-size: 24px; color: var(--c); text-shadow: 3px 3px 0 var(--black); }
.cart-load { z-index: 1; display: grid; place-items: center; width: 60px; height: 60px; margin-bottom: -12px; background: #3A4049; color: var(--ink); border: 4px solid var(--black); font-size: 24px; box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.15), inset -4px -4px 0 rgba(0, 0, 0, 0.3); }
.cart-1 .cart-load { width: 76px; height: 76px; background: #8A5A06; color: var(--gold); }
.cart-body { width: 100%; aspect-ratio: 24 / 16; background: url(/img/mine/cart.png?v=2) center / contain no-repeat; image-rendering: pixelated; }
.cart-name { max-width: 100%; font-weight: 700; font-size: 17px; color: var(--ink); overflow-wrap: anywhere; }
.cart-value { font-size: 15px; color: var(--body); }
.level .center { margin-top: 36px; }

/* −260 m: vote sites as signposts. */
.signs { max-width: 920px; margin: 0 auto; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 18px; }
.signpost { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 64px; padding: 16px 20px; background: #6B4A2B; color: #FFF1DE; border: 4px solid var(--black); text-decoration: none; font: 700 16px var(--display); text-transform: uppercase; overflow-wrap: anywhere;
  box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.15), inset -4px -4px 0 rgba(0, 0, 0, 0.3), 0 6px 0 var(--black); transition: transform 0.22s var(--spring); }
.signpost:hover { transform: translateY(-3px) rotate(-1deg); color: #fff; }
.signpost-discord { background: #4752C4; }
.rewards { margin: 32px 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 28px; color: var(--ink); font-weight: 600; }
.rewards li::before { content: '◆ '; color: var(--diamond); }
.level .month-votes { display: inline-flex; margin-top: 32px; }

/* −300 m: questions scratched into the wall. */
.wall { max-width: 780px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.wall details { background: rgba(14, 15, 20, 0.9); border: 4px solid var(--black); border-left: 8px solid var(--amethyst); }
.wall summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 14px; min-height: 56px; padding: 14px 20px; cursor: pointer; font-weight: 700; font-size: 18px; color: var(--ink); }
.wall summary::-webkit-details-marker { display: none; }
.wall summary::after { content: ''; flex: none; width: 12px; height: 12px; border-right: 4px solid var(--amethyst); border-bottom: 4px solid var(--amethyst); rotate: 45deg; translate: 0 -3px; transition: rotate 0.2s, translate 0.2s; }
.wall details[open] summary::after { rotate: 225deg; translate: 0 3px; }
.wall summary:hover { background: rgba(176, 124, 255, 0.08); }
.wall details p { margin: 0; padding: 0 20px 18px; }

/* −320 m: the VIP offer above the lava (the pool itself is the top of the footer). */
.offer { display: flex; flex-direction: column; align-items: center; gap: 20px; }
.offer .h2 { font-size: clamp(28px, 6vw, 56px); text-shadow: 0 5px 0 var(--black), 0 0 40px rgba(255, 120, 40, 0.5); }
.offer p { margin: 0; max-width: 34em; font-size: 18px; color: #EADBD2; }
.offer-badges { display: flex; align-items: flex-end; gap: clamp(12px, 3vw, 28px); }
.offer-badges .pixel-badge { height: clamp(64px, 12vw, 104px); width: auto; filter: drop-shadow(0 8px 0 rgba(0, 0, 0, 0.45)); animation: bob 2.6s ease-in-out infinite; }
.offer-badges .pixel-badge:nth-child(2) { height: clamp(80px, 15vw, 128px); animation-delay: 0.3s; }
.offer-badges .pixel-badge:nth-child(3) { animation-delay: 0.6s; }
@keyframes bob { 50% { translate: 0 -8px; } }

/* Depth gauge: a shaft on the right with a tick per level; one readout rides down it with the depth and the level's
   name, so labels never stack on each other. motion.js adds the ticks and moves the readout. */
.gauge { position: fixed; right: 28px; top: 50%; translate: 0 -50%; z-index: 15; width: 14px; height: min(56vh, 480px); pointer-events: none; opacity: 0; transition: opacity 0.3s; }
.gauge.on { opacity: 1; }
.gauge-bar { position: absolute; inset: 0; background: #0B0D10; border: 3px solid var(--black); box-shadow: 0 0 0 2px #2A3038, inset 2px 2px 0 #000; }
.gauge-fill { position: absolute; left: 0; right: 0; top: 0; height: var(--p, 0%); background: linear-gradient(#B98A5A, var(--iron) 25%, var(--diamond) 55%, var(--amethyst) 80%, var(--lava)) 0 0 / 100% var(--h, 480px); }
.gauge-mark { position: absolute; left: calc(100% + 5px); top: var(--at); width: 8px; height: 3px; margin-top: -1px; background: #4A525C; }
.gauge-mark.past { background: var(--iron); }
.gauge-mark.here { background: var(--ink); width: 12px; }
.gauge-now { position: absolute; right: calc(100% + 12px); top: var(--p, 0%); translate: 0 -50%; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; padding: 6px 9px; background: rgba(7, 8, 10, 0.92); border: 3px solid var(--black); box-shadow: 0 0 0 2px #2A3038, 0 4px 0 var(--black); white-space: nowrap; text-align: right; }
.gauge-now::after { content: ''; position: absolute; right: -11px; top: 50%; width: 8px; height: 3px; margin-top: -1px; background: #2A3038; }
.gauge-now b { font: 700 15px var(--display); color: var(--ink); }
.gauge-now span { font: 700 11px var(--display); text-transform: uppercase; color: var(--rust-hi); }
@media (max-width: 1379px) { .gauge { display: none; } }

/* ───────── Store: categories on top, products in the middle, one checkout on the side. ───────── */
.shop-page { padding-block: 56px 96px; background: linear-gradient(rgba(10, 11, 14, 0.88), rgba(10, 11, 14, 0.94)), url(/img/mine/deep.png?v=2) 0 0 / 64px 64px; image-rendering: pixelated; }
.shop-page > * { image-rendering: auto; }
.shop-head { display: flex; flex-direction: column; align-items: center; gap: 14px; margin-bottom: 40px; text-align: center; }
.shop-head .lead { max-width: 36em; }
.shop { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; }
.shop-main { min-width: 0; display: flex; flex-direction: column; gap: 24px; }

/* Category tabs: radios, so the page works without JavaScript. */
.cats { margin: 0; padding: 0; border: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.cat { position: relative; flex: 1 1 200px; }
.cat input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.cat > span { display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 64px; padding: 8px 20px; background: var(--panel); border: 4px solid var(--black); font: 700 17px var(--display); text-transform: uppercase; color: var(--body);
  box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.06), inset -4px -4px 0 rgba(0, 0, 0, 0.35), 0 5px 0 var(--black); transition: transform 0.2s var(--spring), background-color 0.15s; }
.cat .pixel-badge { height: 36px; width: auto; }
.cat:hover input:not(:checked) + span { background: var(--line); color: var(--ink); }
.cat input:checked + span { background: #2A2F37; color: var(--ink); box-shadow: inset 0 -6px 0 var(--rust-hi), inset 4px 4px 0 rgba(255, 255, 255, 0.08), 0 5px 0 var(--black); }
.cat input:focus-visible + span { outline: 3px solid var(--diamond); outline-offset: 3px; }
.cat input:active + span { transform: translateY(3px); transition-duration: 0s; }
.shop:has(#cat-ranks:checked) .view-gems, .shop:has(#cat-gems:checked) .view-ranks { display: none; }
.cat-view { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.view-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; }
.view-head .hint { margin: 0; }
.h3 { font-size: clamp(20px, 3vw, 26px); text-shadow: 0 3px 0 var(--black); }
.plan > span { min-height: 48px; padding: 0 16px; font-size: 15px; }
.plan input:checked + span { background: var(--rust-btn); }

/* A product row is a radio: the whole row is the target. */
.items { margin: 0; padding: 0; border: 0; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.item { --c: var(--rust-hi); position: relative; display: grid; grid-template-columns: 88px minmax(0, 1fr) auto; align-items: center; gap: 20px; padding: 18px 22px 18px 24px; cursor: pointer;
  background: linear-gradient(90deg, color-mix(in srgb, var(--c) 16%, transparent), transparent 55%), #171A20; border: 4px solid var(--black); box-shadow: inset 6px 0 0 var(--c), 0 5px 0 var(--black); transition: transform 0.22s var(--spring), box-shadow 0.15s; }
.item:hover { transform: translateX(4px); }
.item > input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.item:has(> input:checked) { box-shadow: inset 6px 0 0 var(--c), 0 0 0 4px var(--c), 0 5px 0 4px var(--black); background: linear-gradient(90deg, color-mix(in srgb, var(--c) 24%, transparent), transparent 70%), #1B1F26; }
.item:has(> input:focus-visible) { outline: 3px solid var(--diamond); outline-offset: 8px; }
/* The tick in the corner says which one is chosen, not only the colour. */
.item::after { content: ''; position: absolute; top: 12px; right: 12px; width: 26px; height: 26px; background: var(--well) center / 16px 12px no-repeat; border: 3px solid var(--black); box-shadow: inset 2px 2px 0 #000; }
.item:has(> input:checked)::after { background-color: var(--c); box-shadow: inset 2px 2px 0 rgba(255, 255, 255, 0.35);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8' shape-rendering='crispEdges'%3E%3Cpath fill='%2307080A' d='M8 0h2v1h-2zM7 1h2v1h-2zM6 2h2v1h-2zM0 3h2v1h-2zM5 3h2v1h-2zM1 4h2v1h-2zM4 4h2v1h-2zM2 5h3v1h-3zM3 6h1v1h-1z'/%3E%3C/svg%3E"); }
.item-pic { display: grid; place-items: center; height: 80px; }
.item-pic .pixel-badge { max-height: 80px; width: auto; filter: drop-shadow(0 5px 0 rgba(0, 0, 0, 0.4)); transition: transform 0.3s var(--spring); }
.item-pic svg { width: 52px; height: 52px; filter: drop-shadow(0 5px 0 rgba(0, 0, 0, 0.4)); }
.item:hover .item-pic > * { transform: translateY(-3px) rotate(-4deg); }
.item-body { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.item-title { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.item-name { font-size: 24px; color: var(--c); text-shadow: 3px 3px 0 var(--black); overflow-wrap: anywhere; }
.tag { font: 700 13px var(--display); text-transform: uppercase; color: #fff; background: var(--rust-btn); padding: 4px 8px; border: 2px solid var(--black); }
.item-line { color: var(--ink); font-weight: 500; }
.item-perks { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 15.5px; color: var(--body); }
.item-perks li { display: flex; gap: 8px; align-items: baseline; }
.item-perks li::before { content: ''; flex: none; width: 8px; height: 8px; background: var(--c); box-shadow: 2px 2px 0 var(--black); translate: 0 -2px; }
.item-perks svg { display: none; }
.item .badge-off { justify-self: start; }
.item-price { display: flex; flex-direction: column; align-items: flex-end; text-align: right; padding-right: 30px; }
.price { display: none; flex-direction: column; align-items: flex-end; gap: 2px; }
.price-gems { display: flex; }
.amount { font-size: 26px; color: var(--ink); white-space: nowrap; }
.per { font-size: 14px; color: var(--body); white-space: nowrap; }
s.per { color: var(--muted); }

/* All ranks side by side; the chosen rank's column lights up (rules in StorePage). */
.compare { margin-top: 18px; padding: 24px; background: rgba(15, 18, 22, 0.92); border: 4px solid var(--black); box-shadow: var(--sunk); }
.compare-title { margin-bottom: 16px; font-size: 20px; }
.compare-scroll { overflow-x: auto; margin-inline: -8px; padding-inline: 8px; }
.compare table { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 16px; }
.compare th, .compare td { padding: 12px 14px; text-align: center; border-bottom: 2px solid #232830; }
.compare tbody th { text-align: left; font-weight: 500; color: var(--body); }
.compare thead th { vertical-align: bottom; padding-bottom: 14px; }
.compare thead th > * { display: block; margin-inline: auto; }
.compare thead .pixel-badge { height: 44px; width: auto; margin-bottom: 8px; }
.compare thead .display { font-size: 16px; color: var(--c); text-shadow: 2px 2px 0 var(--black); }
.compare td { color: var(--ink); font-weight: 600; }
.compare tbody tr:last-child th, .compare tbody tr:last-child td { border-bottom: 0; }
.compare .yes { color: var(--emerald); font-weight: 700; }
.compare .yes svg { width: 24px; height: 21px; vertical-align: -4px; }
.compare .no { color: var(--muted); }
.compare [class^='col-'] { transition: background-color 0.2s; }
.compare tbody tr:nth-last-child(-n+2) td { font-family: var(--display); font-size: 15px; }

/* Checkout */
.checkout { position: sticky; top: 92px; display: flex; flex-direction: column; gap: 18px; padding: 24px; background: var(--panel); border: 4px solid var(--black); box-shadow: inset 0 8px 0 var(--rust-hi), inset 4px 4px 0 rgba(255, 255, 255, 0.04), 0 6px 0 var(--black); }
.checkout .h3 { padding-top: 6px; }
.picked { padding: 14px 16px; background: var(--well); border: 4px solid var(--black); box-shadow: inset 3px 3px 0 #000; }
.picked-line { display: none; justify-content: space-between; align-items: baseline; gap: 12px; margin: 0; }
.picked-line > span:first-child { display: flex; flex-direction: column; min-width: 0; }
.picked-line b { font-size: 18px; }
.picked-what { font-size: 14px; color: var(--body); }
.picked-sum { font-size: 22px; color: var(--rust-hi); white-space: nowrap; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field input { width: 100%; min-height: 56px; padding: 12px 14px; background: var(--bg); border: 4px solid var(--black); box-shadow: inset 3px 3px 0 #000; color: var(--ink); font: 700 18px var(--display); transition: border-color 0.18s; }
.field input::placeholder { color: #69727D; }
.field input:focus { outline: none; border-color: var(--rust-hi); }
.checkout .check { font-size: 15px; }
.pay-note { font-size: 14px; }
.shop-page .fineprint { margin-top: 32px; }

@media (max-width: 1100px) {
  .shop { grid-template-columns: 1fr; }
  .checkout { position: static; }
}
@media (max-width: 640px) {
  .shop-page { padding-top: 36px; }
  .cat { flex-basis: 140px; }
  .cat > span { min-height: 56px; padding: 6px 12px; font-size: 15px; gap: 8px; }
  .cat .pixel-badge { height: 28px; }
  .item { grid-template-columns: 56px minmax(0, 1fr); gap: 8px 14px; padding: 16px 16px 16px 20px; }
  .item-pic { height: 56px; align-self: start; }
  .item-pic .pixel-badge { max-height: 56px; }
  .item-pic svg { width: 40px; height: 40px; }
  .item-name { font-size: 20px; padding-right: 30px; }
  .item-price { grid-column: 1 / -1; align-items: flex-start; text-align: left; padding: 6px 0 0; border-top: 2px dashed #2A3038; }
  .price { flex-direction: row; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; }
  .amount { font-size: 22px; }
  .compare { padding: 16px; }
  .compare table { font-size: 15px; }
  .compare th, .compare td { padding: 10px 8px; }
  .checkout { padding: 20px 16px; }
}

/* Home on small screens: one column, the ladder and the rail on the left. */
@media (max-width: 760px) {
  .level { padding-block: 88px 80px; }
  .level-head { margin-bottom: 40px; }
  .ore-address { flex-direction: column; text-align: center; gap: 14px; padding: 16px; }
  .ore-sign { align-items: center; }
  .ore-slot { width: 72px; height: 72px; }
  .ladder::before { left: 0; width: 48px; translate: 0; background-size: 48px 48px; filter: drop-shadow(6px 6px 0 rgba(0, 0, 0, 0.45)); }
  .rung { width: auto; margin-left: 64px !important; padding: 18px; }
  .rung::after { left: -35px !important; right: auto !important; width: 35px; }
  .rail::before { left: 15px; translate: 0; }
  .stop { grid-template-columns: 34px minmax(0, 1fr); gap: 14px; }
  .plaque, .stop:nth-child(even) .plaque { grid-column: 2; padding: 20px; }
  .node { grid-column: 1; align-self: start; margin-top: 22px; }
  .cart-load { width: 44px; height: 44px; font-size: 18px; }
  .cart-1 .cart-load { width: 56px; height: 56px; }
  .cart-name { font-size: 15px; }
  .cart-value { font-size: 14px; }
  .cart-place { font-size: 18px; }
}
@media (max-width: 420px) {
  .wrap { padding-inline: 18px; }
  .surface .actions-row .btn { flex: 1 1 100%; }
}

/* Shared store pieces: plan switch, consent box, pay button. */
.store-head { display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; }
.plans { display: flex; flex-wrap: wrap; gap: 12px; }
.plan { position: relative; }
.plan input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.plan > span { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 20px; background: var(--panel); border: 4px solid var(--black); font-weight: 700; color: var(--ink);
  box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.06), inset -4px -4px 0 rgba(0, 0, 0, 0.35), 0 4px 0 var(--black); transition: transform 0.22s var(--spring), background-color 0.18s ease; }
.plan:hover input:not(:checked) + span { background: var(--line); }
.plan input:checked + span { background: var(--rust); color: #fff; box-shadow: var(--bevel), 0 4px 0 var(--black); }
.plan input:active + span { transform: translateY(3px); transition-duration: 0s; }
.plan input:focus-visible + span { outline: 3px solid var(--diamond); outline-offset: 3px; }
.badge-off { align-self: center; background: var(--emerald); color: #06210F; font: 700 13px var(--display); text-transform: uppercase; padding: 5px 7px; border: 2px solid var(--black); }
.plan input:checked + span .badge-off { background: #fff; }
.pixel-badge { image-rendering: pixelated; }
.consent { display: flex; flex-direction: column; gap: 8px; }
.check { position: relative; display: flex; gap: 16px; align-items: flex-start; padding: 14px 18px 14px 14px; cursor: pointer; font-size: 15.5px; line-height: 1.6;
  background: var(--well); border: 4px solid var(--black); box-shadow: inset 3px 3px 0 rgba(0, 0, 0, 0.35), inset -3px -3px 0 rgba(255, 255, 255, 0.04); transition: border-color 0.18s ease; }
.check input { position: absolute; left: 14px; top: 14px; width: 34px; height: 34px; margin: 0; opacity: 0; cursor: pointer; }
.check-slot { flex: none; display: grid; place-items: center; width: 34px; height: 34px; margin-top: -3px; background: var(--panel); border: 3px solid var(--black); box-shadow: inset 3px 3px 0 rgba(0, 0, 0, 0.5), inset -3px -3px 0 rgba(255, 255, 255, 0.1); transition: background-color 0.18s ease; }
.check-slot svg { width: 24px; height: 18px; opacity: 0; }
.check:hover { border-color: var(--line); }
.check:hover .check-slot { border-color: var(--rust); }
.check input:checked + .check-slot { background: var(--rust); box-shadow: inset 3px 3px 0 rgba(255, 255, 255, 0.3), inset -3px -3px 0 rgba(0, 0, 0, 0.3); }
.check input:checked + .check-slot svg { opacity: 1; }
.check input:focus-visible + .check-slot { outline: 3px solid var(--diamond); outline-offset: 3px; }
.check:has(input[aria-invalid='true']) { border-color: #B8483A; }
.btn-pay { width: 100%; min-height: 60px; font-size: 18px; }
.pay-note { margin: 0; }

/* Leaderboard */
.leaderboard { padding-block: 56px 96px; display: flex; flex-direction: column; gap: 40px; }
.empty { text-align: center; }
.boards { display: flex; flex-direction: column; gap: 24px; }
.board-tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.board-tab { position: relative; }
.board-tab input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.board-tab span { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; background: var(--panel); border: 4px solid var(--black); font: 700 14px var(--display); text-transform: uppercase; color: var(--body); box-shadow: inset 3px 3px 0 rgba(255, 255, 255, 0.05), inset -3px -3px 0 rgba(0, 0, 0, 0.3), 0 4px 0 var(--black); transition: transform 0.2s var(--spring); }
.board-tab:hover span { color: var(--ink); }
.board-tab input:checked + span { background: var(--rust-btn); color: #fff; box-shadow: var(--bevel), 0 4px 0 var(--black); }
.board-tab input:focus-visible + span { outline: 3px solid var(--diamond); outline-offset: 3px; }
.board { display: none; max-width: 760px; width: 100%; margin: 0 auto; background: var(--panel); border: 4px solid var(--black); box-shadow: inset 4px 4px 0 rgba(255, 255, 255, 0.04), inset -4px -4px 0 rgba(0, 0, 0, 0.3); }
.board table { width: 100%; border-collapse: collapse; }
.board th, .board td { padding: 12px 18px; text-align: left; border-bottom: 2px solid var(--black); }
.board th { font: 700 14px var(--display); text-transform: uppercase; color: var(--muted); }
.board tr:last-child td { border-bottom: 0; }
.board .num { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink); font-weight: 600; }
.board .pos { width: 60px; font-size: 18px; color: var(--muted); }
.board .who { display: flex; align-items: center; gap: 12px; color: var(--ink); font-weight: 600; }
.place-1 .pos { color: var(--gold); } .place-2 .pos { color: var(--iron); } .place-3 .pos { color: #C87533; }
.place-1 { background: linear-gradient(90deg, rgba(255, 210, 74, 0.12), transparent 60%); }

/* Thank you */
.thanks { padding-block: 72px 96px; }
.thanks-card { --mid: var(--rust); max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 18px; text-align: center; padding: 48px 40px 36px; background: var(--panel); border: 4px solid var(--black); box-shadow: inset 0 10px 0 var(--mid), var(--sunk); }
.thanks-card .pixel-badge { height: 96px; width: auto; }
.thanks-rank { margin: 0; font: 700 18px var(--display); text-transform: uppercase; color: var(--light, var(--amethyst)); }
.thanks-lead { margin: 0; }
.thanks-steps { width: 100%; text-align: left; grid-template-columns: 1fr !important; }
.thanks-actions { justify-content: center; }
@media (max-width: 520px) { .thanks-card { padding: 36px 20px 28px; } .thanks-actions .btn { flex: 1 1 100%; } }

/* Legal pages */
.legal { max-width: 860px; padding-block: 56px 80px; }
.legal h1 { margin-bottom: 16px; font-size: clamp(26px, 5vw, 40px); line-height: 1.4; }
.legal h2 { margin-top: 48px; font-size: 24px; line-height: 1.4; }
.legal ol { padding-left: 1.4em; display: flex; flex-direction: column; gap: 14px; }
.legal ol ol { margin-top: 12px; }
.legal li { line-height: 1.7; }
.withdrawal p { margin: 10px 0; }

/* Footer */
.footer { position: relative; margin-top: 0; padding-bottom: 32px; background: linear-gradient(#1A0E09, var(--bar) 260px); }
.footer > .wrap { padding-top: 48px; }
/* The lava every page ends in; it creeps sideways. */
.pool { height: 72px; background: url(/img/mine/lava.png?v=2) 0 0 / 64px 64px; image-rendering: pixelated; border-top: 4px solid var(--black); border-bottom: 4px solid var(--black); box-shadow: 0 -24px 60px rgba(255, 110, 30, 0.35); animation: flow 8s linear infinite; }
@keyframes flow { to { background-position: 64px 0; } }
.footer-main { display: grid; gap: 36px; }
@media (min-width: 900px) { .footer-main { grid-template-columns: minmax(0, 1.2fr) minmax(0, 2fr) auto; } }
.footer-about p { margin: 14px 0 0; color: var(--muted); max-width: 26em; }
.footer-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 24px; }
.footer-col { display: flex; flex-direction: column; gap: 8px; }
.footer-col h2 { font: 700 14px var(--display); text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.footer-col a { color: var(--body); text-decoration: none; }
.footer-col a:hover { color: var(--rust-hi); }
.lang-switch { display: flex; flex-direction: column; gap: 8px; }
.lang-opt { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 12px; color: var(--body); text-decoration: none; border: 3px solid transparent; }
.lang-opt[aria-current] { border-color: var(--black); background: var(--panel); color: var(--ink); }
.flag { width: 24px; height: 16px; }
.footer-base { margin-top: 40px; padding-top: 20px; border-top: 2px solid var(--line); display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--muted); }
.footer-base p { margin: 0; }

/* Motion */
.reveal { transition: opacity 0.6s var(--ease-out) var(--d, 0s), translate 0.6s var(--ease-out) var(--d, 0s); }
.motion .reveal:not(.in) { opacity: 0; translate: 0 22px; }
.stagger > :nth-child(2) { --d: 0.08s; }
.stagger > :nth-child(3) { --d: 0.16s; }
.stagger > :nth-child(4) { --d: 0.24s; }
.entries > :nth-child(2) { --d: 0.06s; } .entries > :nth-child(3) { --d: 0.12s; } .entries > :nth-child(4) { --d: 0.18s; }
.entries > :nth-child(5) { --d: 0.24s; } .entries > :nth-child(6) { --d: 0.3s; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .mine-layer, .mine-glow { transform: none !important; }
  .pool { animation: none; }
}

/* Admin */
.admin { display: flex; flex-direction: column; gap: 24px; padding-block: 32px; }
.admin-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.admin-head form { display: flex; align-items: center; gap: 12px; }
.admin-form { display: flex; flex-direction: column; gap: 10px; max-width: 420px; }
.admin-form.inline { flex-direction: row; flex-wrap: wrap; align-items: center; max-width: none; margin-top: 16px; }
.admin-form input[type=text], .admin-form input[type=password], .admin-form input[type=number], .admin-form select { background: var(--bg); border: 2px solid var(--line); border-radius: 4px; color: var(--ink); font: inherit; padding: 10px 12px; min-height: 44px; }
.admin-form input:focus, .admin-form select:focus { border-color: var(--rust); outline: none; }
.table-wrap { overflow-x: auto; margin-block: 12px; }
.admin table { border-collapse: collapse; width: 100%; font-size: 15px; }
.admin th, .admin td { text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.admin th { color: var(--muted); font-weight: 500; }
.status { font-weight: 700; }
.status-ok { color: var(--emerald); }
.status-wait { color: var(--muted); }
.status-bad { color: #FF8A7A; }
.status-off { color: var(--muted); text-decoration: line-through; }
.token-new { border-color: var(--rust); }
.token-value { display: block; padding: 12px; background: var(--bg); border-radius: 4px; word-break: break-all; user-select: all; }
.btn-small { min-height: 36px; padding: 0 12px; font-size: 12px; }

/* 404: the hero's mine, darker, with a huge carved 404. */
.lost { position: relative; isolation: isolate; overflow: hidden; display: grid; align-items: center; min-height: min(78vh, 720px); padding-block: 72px; border-bottom: 4px solid var(--black); background: #08090B; }
.lost .mine-shade { background: radial-gradient(70% 80% at 30% 50%, rgba(7, 8, 10, 0.55), rgba(7, 8, 10, 0.92)), linear-gradient(180deg, transparent 70%, var(--bg)); }
.lost-inner { width: 100%; display: flex; flex-direction: column; align-items: flex-start; gap: 22px; }
.lost-code { margin: 0; font-size: clamp(96px, 26vw, 220px); line-height: 0.9; color: #2A3038; text-shadow: 0 6px 0 var(--black), 0 -2px 0 #3A424C; letter-spacing: -0.02em; }
.lost .lead { color: #D9DEE5; }

/* Store fixes for narrow screens. */
fieldset.plans { margin: 0; padding: 0; border: 0; min-width: 0; }
.badge-off { white-space: nowrap; }
.compare tbody th { position: sticky; left: 0; z-index: 1; background: #12151A; }
@media (max-width: 640px) {
  .view-head { flex-direction: column; align-items: stretch; }
  .plans { flex-direction: column; }
  .plan > span { justify-content: space-between; }
  .compare table { min-width: 460px; }
  .compare tbody th { min-width: 130px; font-size: 14px; }
}

/* Gem bonus sits under the name, aligned with it, not centred in the row. */
.item-body .badge-off { align-self: flex-start; font-size: 12px; padding: 4px 8px; }
/* The checkout total wraps under the name when the two don't fit side by side, and never pushes out of the box. */
.picked-line { flex-wrap: wrap; row-gap: 4px; }
.picked-line > span:first-child { flex: 1 1 120px; }
.picked-sum { margin-left: auto; font-size: clamp(18px, 1.6vw, 22px); white-space: normal; text-align: right; overflow-wrap: anywhere; }
