/* =========================================================
   TaxSMP — style.css
   Yellow / gold on warm black, diamond-blue accents.
   ========================================================= */
:root {
  --bg: #0d0b06;
  --bg2: #141108;
  --panel: #1a160c;
  --panel2: #221c0e;
  --line: rgba(255, 210, 63, .14);
  --line2: rgba(255, 210, 63, .28);
  --y: #ffd23f;
  --y2: #ffb300;
  --y3: #b87a00;
  --ink: #fff7de;
  --muted: #b9ad8c;
  --dim: #7d735a;
  --blue: #4fd1ff;
  --green: #6dff8e;
  --red: #ff5c5c;
  --purple: #b980ff;
  --pixel: "Press Start 2P", monospace;
  --sans: "Outfit", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --radius: 14px;
  --nav-h: 68px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 12px); }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body.locked { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
code { font-family: var(--mono); font-size: .9em; color: var(--y); background: rgba(255,210,63,.1); padding: .1em .4em; border-radius: 4px; }
::selection { background: var(--y); color: #1a1200; }

.wrap { width: min(1200px, 100% - 32px); margin-inline: auto; }
.hl { color: var(--y); text-shadow: 0 0 24px rgba(255, 210, 63, .35); }

/* subtle pixel grid texture over the whole page */
body::before {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background-image:
    linear-gradient(rgba(255,210,63,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,210,63,.025) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(to bottom, transparent 0, #000 90vh);
}
main, .footer { position: relative; z-index: 1; }

/* ================= PIXEL BUTTONS ================= */
.px-btn {
  --face: #3a3322; --hi: #5c5236; --lo: #1b170d; --txt: var(--ink);
  position: relative;
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; padding: 14px 26px 16px;
  background: var(--face); color: var(--txt);
  font-family: var(--pixel); font-size: 13px; line-height: 1.2; letter-spacing: .02em;
  border: 3px solid #000;
  box-shadow: inset 3px 3px 0 var(--hi), inset -3px -4px 0 var(--lo), 0 6px 0 #000, 0 10px 24px rgba(0,0,0,.4);
  transition: transform .12s, box-shadow .12s, filter .2s;
  image-rendering: pixelated;
}
.px-btn:hover { transform: translateY(-2px); filter: brightness(1.12); box-shadow: inset 3px 3px 0 var(--hi), inset -3px -4px 0 var(--lo), 0 8px 0 #000, 0 16px 30px rgba(0,0,0,.45); }
.px-btn:active { transform: translateY(5px); box-shadow: inset 3px 3px 0 var(--lo), inset -3px -3px 0 var(--hi), 0 1px 0 #000; }
.px-btn .px-sub { font-family: var(--sans); font-size: 12px; font-weight: 600; opacity: .72; letter-spacing: 0; }
.px-yellow { --face: var(--y); --hi: #fff09a; --lo: var(--y3); --txt: #2a1d00; }
.px-yellow:hover { box-shadow: inset 3px 3px 0 var(--hi), inset -3px -4px 0 var(--lo), 0 8px 0 #000, 0 0 40px rgba(255,210,63,.45); }
.px-dark { --face: #2a2518; --hi: #4a4230; --lo: #120f07; }
.px-lg { font-size: 16px; padding: 18px 40px 20px; }
.px-sm { font-size: 11px; padding: 11px 20px 13px; }

.link-btn { color: var(--muted); font-size: 14px; text-decoration: underline; text-underline-offset: 4px; }
.link-btn:hover { color: var(--ink); }

/* ================= SPLASH ================= */
.splash {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center;
  background:
    radial-gradient(ellipse at 50% 40%, rgba(255,190,40,.18), transparent 60%),
    repeating-conic-gradient(#171309 0% 25%, #120f07 0% 50%) 0 0 / 48px 48px;
  transition: opacity .6s ease, visibility .6s;
}
.splash.gone { opacity: 0; visibility: hidden; }
.splash-inner { display: flex; flex-direction: column; align-items: center; gap: 18px; padding: 16px; text-align: center; }
.splash-logo { width: min(280px, 70vw); height: auto; animation: bob 3.2s ease-in-out infinite; filter: drop-shadow(0 20px 40px rgba(0,0,0,.6)); }
.splash-tip { font-family: var(--pixel); font-size: 11px; color: var(--muted); min-height: 1.2em; }
.splash-bar { width: min(320px, 80vw); height: 10px; background: #000; border: 2px solid #3a3322; }
.splash-bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--y2), var(--y)); transition: width .25s steps(8); }
#enterBtn { opacity: 0; transform: translateY(8px); pointer-events: none; transition: opacity .4s, transform .4s; }
#enterBtn.ready { opacity: 1; transform: none; pointer-events: auto; animation: pulse 1.8s ease-in-out infinite; }

@keyframes bob { 0%,100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-14px) rotate(1deg); } }
@keyframes pulse { 0%,100% { filter: brightness(1); } 50% { filter: brightness(1.18); } }

/* ================= NAV ================= */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: center; gap: 24px;
  padding: 0 max(16px, calc((100% - 1200px) / 2));
  transition: background .3s, border-color .3s, backdrop-filter .3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled { background: rgba(13, 11, 6, .82); backdrop-filter: blur(14px); border-color: var(--line); }
.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand img { border-radius: 8px; image-rendering: auto; }
.wordmark { font-family: var(--pixel); font-size: 15px; letter-spacing: .04em; }
.wordmark b { color: var(--y); font-weight: 400; text-shadow: 2px 2px 0 #7a5200; }
.wordmark i { color: var(--blue); font-style: normal; text-shadow: 2px 2px 0 #10507a; }
.nav-links { display: flex; gap: 4px; margin-left: 12px; }
.nav-links a { padding: 8px 14px; border-radius: 8px; font-weight: 600; font-size: 15px; color: var(--muted); transition: color .2s, background .2s; }
.nav-links a:hover { color: var(--ink); background: rgba(255,210,63,.08); }
.nav-links .nav-store { color: var(--y); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.icon-link { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; color: var(--muted); border: 1px solid var(--line); transition: all .2s; }
.icon-link svg { width: 20px; height: 20px; }
.icon-link.discord-link:hover { color: #fff; background: #5865f2; border-color: #5865f2; }
.icon-link.twitch-link:hover { color: #fff; background: #9146ff; border-color: #9146ff; }
.ip-chip {
  display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 6px 0 14px;
  border: 1px solid var(--line2); border-radius: 10px; background: rgba(255,210,63,.06);
  font-family: var(--mono); font-weight: 700; font-size: 14px; transition: all .2s;
}
.ip-chip:hover { background: rgba(255,210,63,.14); border-color: var(--y); }
.ip-copy { font-family: var(--pixel); font-size: 9px; background: var(--y); color: #2a1d00; padding: 7px 8px; border-radius: 6px; }
.burger { display: none; width: 40px; height: 40px; flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.burger span { width: 22px; height: 3px; background: var(--ink); transition: transform .25s, opacity .25s; }
.nav.open .burger span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav.open .burger span:nth-child(2) { opacity: 0; }
.nav.open .burger span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 0 rgba(109,255,142,.6); animation: ping 2s infinite; flex-shrink: 0; display: inline-block; }
.live-dot.off { background: var(--red); animation: none; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(109,255,142,.55); } 70% { box-shadow: 0 0 0 9px rgba(109,255,142,0); } 100% { box-shadow: 0 0 0 0 rgba(109,255,142,0); } }

/* ================= HERO ================= */
.hero { position: relative; min-height: 100svh; display: grid; place-items: center; overflow: hidden; isolation: isolate; }
#world { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; cursor: crosshair; image-rendering: pixelated; }
.hero-vignette {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse 60% 55% at 50% 45%, rgba(13,11,6,.55), transparent 70%),
    linear-gradient(to bottom, rgba(13,11,6,.55) 0%, transparent 22%, transparent 70%, var(--bg) 100%);
}
.hero-content { display: flex; flex-direction: column; align-items: center; text-align: center; padding: calc(var(--nav-h) + 8px) 16px 64px; pointer-events: none; }
.hero-content > * { pointer-events: auto; }
.hero-logo-wrap { position: relative; width: min(420px, 78vw, 40svh); aspect-ratio: 1; margin-bottom: -28px; pointer-events: none; }
.hero-logo { width: 100%; height: 100%; animation: bob 4.5s ease-in-out infinite; filter: drop-shadow(0 30px 40px rgba(0,0,0,.55)); -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 58%, transparent 71%); mask-image: radial-gradient(circle at 50% 50%, #000 58%, transparent 71%); }
.logo-glow { position: absolute; inset: 18%; border-radius: 50%; background: radial-gradient(circle, rgba(255,200,40,.45), rgba(79,209,255,.15) 55%, transparent 72%); filter: blur(30px); animation: glow 4.5s ease-in-out infinite; }
@keyframes glow { 0%,100% { opacity: .7; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }
.hero-tag { font-family: var(--pixel); font-size: clamp(13px, 2.2vw, 20px); line-height: 1.7; text-shadow: 3px 3px 0 #000; margin-bottom: 18px; }
.online-pill {
  display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px; margin-bottom: 26px;
  background: rgba(0,0,0,.55); border: 1px solid rgba(109,255,142,.35); border-radius: 999px;
  font-weight: 600; font-size: 15px; backdrop-filter: blur(6px);
}
.online-pill b { color: var(--green); font-family: var(--mono); }
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
.hero-cta .server-ip { font-size: 16px; }
.hero-hint { margin-top: 22px; font-size: 14px; color: var(--muted); text-shadow: 0 2px 6px #000; }
.kbd { font-family: var(--pixel); font-size: 9px; padding: 4px 6px; border: 2px solid var(--muted); border-bottom-width: 4px; border-radius: 4px; margin-right: 6px; color: var(--ink); }

.cash-hud {
  position: absolute; right: 20px; bottom: 90px; display: flex; align-items: center; gap: 10px;
  background: rgba(0,0,0,.65); border: 2px solid var(--y3); padding: 8px 14px 8px 10px;
  font-family: var(--pixel); font-size: 12px; opacity: 0; transform: translateY(10px); transition: all .35s;
}
.cash-hud.show { opacity: 1; transform: none; }
.cash-hud b { color: var(--y); font-weight: 400; }
.cash-hud small { font-family: var(--sans); color: var(--muted); font-size: 12px; }
.cash-hud.bump b { animation: bump .35s; }
@keyframes bump { 40% { transform: scale(1.35); color: #fff; } }
.coin { width: 18px; height: 18px; background: radial-gradient(circle at 35% 35%, #fff3a8, var(--y) 45%, var(--y3)); border-radius: 50%; box-shadow: inset -2px -2px 0 rgba(0,0,0,.25); animation: spin 1.6s linear infinite; }
@keyframes spin { 0%,100% { transform: scaleX(1); } 50% { transform: scaleX(.15); } }

/* ================= TICKER ================= */
.ticker { position: relative; z-index: 2; overflow: hidden; background: var(--y); color: #241900; border-block: 3px solid #000; transform: rotate(-1.2deg) scale(1.03); margin-top: -40px; box-shadow: 0 10px 40px rgba(255,190,40,.18); }
.ticker-track { display: flex; width: max-content; animation: marquee 70s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.tick { display: inline-flex; align-items: center; gap: 10px; padding: 12px 22px; font-weight: 700; font-size: 15px; white-space: nowrap; border-right: 2px dashed rgba(0,0,0,.2); }
.tick .slot { width: 22px; height: 22px; }
.tick b { font-family: var(--mono); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ================= SECTIONS ================= */
.section { padding: 120px 0 40px; }
.section-head { max-width: 720px; margin-bottom: 44px; }
.kicker { font-family: var(--pixel); font-size: 11px; color: var(--y); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.kicker::before { content: ""; width: 10px; height: 10px; background: var(--y); box-shadow: 3px 3px 0 var(--y3); }
h2 { font-size: clamp(32px, 5vw, 54px); line-height: 1.08; font-weight: 800; letter-spacing: -.02em; margin-bottom: 16px; }
.lede { color: var(--muted); font-size: 18px; }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }

/* ================= BENTO ================= */
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, var(--panel2), var(--panel));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; transform-style: preserve-3d;
  transition: border-color .3s, box-shadow .3s, transform .2s;
}
.card:hover { border-color: var(--line2); box-shadow: 0 20px 50px rgba(0,0,0,.4), 0 0 0 1px rgba(255,210,63,.1); }
.card::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 0%), rgba(255,210,63,.1), transparent 40%); opacity: 0; transition: opacity .3s; }
.card:hover::after { opacity: 1; }
.card.big { grid-row: span 2; display: flex; flex-direction: column; }
.card h3 { font-size: 22px; font-weight: 700; margin: 10px 0 6px; }
.card p { color: var(--muted); font-size: 15.5px; }
.card p b { color: var(--ink); }
.card .count { color: var(--y); font-family: var(--mono); }
.card-icon { width: 52px; height: 52px; display: grid; place-items: center; font-size: 26px; color: var(--c); background: color-mix(in srgb, var(--c) 14%, transparent); border: 2px solid color-mix(in srgb, var(--c) 40%, transparent); border-radius: 10px; margin-bottom: 14px; box-shadow: 4px 4px 0 color-mix(in srgb, var(--c) 22%, transparent); }
.tag { align-self: flex-start; display: inline-block; font-family: var(--pixel); font-size: 9px; padding: 5px 8px; border-radius: 4px; background: rgba(255,210,63,.12); color: var(--y); }
.tag.red { background: rgba(255,92,92,.14); color: var(--red); }
.tag.purple { background: rgba(185,128,255,.14); color: var(--purple); }
.tag.blue { background: rgba(79,209,255,.14); color: var(--blue); }
.tag.green { background: rgba(109,255,142,.12); color: var(--green); }
.tag.orange { background: rgba(255,169,77,.14); color: #ffa94d; }
.card-link { margin-top: auto; padding-top: 18px; color: var(--y); font-weight: 700; }
.card-link:hover { text-decoration: underline; text-underline-offset: 4px; }

.art-economy { position: relative; height: 170px; margin: -6px -6px 18px; border-radius: 10px; background: radial-gradient(circle at 50% 110%, rgba(23,221,98,.22), transparent 60%), #0f0c06; overflow: hidden; border: 1px solid var(--line); }
.art-economy img { position: absolute; bottom: -34px; width: 34px; height: 34px; image-rendering: pixelated; filter: drop-shadow(0 0 12px rgba(23,221,98,.55)); animation: emeraldUp 3.4s ease-in infinite; }
.art-economy .c1 { left: 18%; animation-delay: 0s; }
.art-economy .c2 { left: 46%; animation-delay: 1.15s; }
.art-economy .c3 { left: 72%; animation-delay: 2.2s; }
@keyframes emeraldUp {
  0% { transform: translateY(0) rotate(-8deg); opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  100% { transform: translateY(-200px) rotate(12deg); opacity: 0; }
}

/* item icons inside cards, rank badges and the cash counter */
.card-icon img { width: 34px; height: 34px; image-rendering: pixelated; filter: drop-shadow(1px 2px 0 rgba(0,0,0,.45)); }
.rank-badge { display: inline-flex; align-items: center; gap: 10px; }
.rank-badge img { width: 26px; height: 26px; image-rendering: pixelated; filter: drop-shadow(1px 2px 0 rgba(0,0,0,.45)); }

/* ================= COMMANDS ================= */
.cmd-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: start; }
.cmd-col { background: linear-gradient(180deg, var(--panel2), var(--panel)); border: 1px solid var(--line); border-radius: 16px; padding: 10px; }
.cmd-col h3 { display: flex; align-items: center; gap: 10px; font-family: var(--pixel); font-size: 11px; color: var(--y); padding: 12px 12px 14px; }
.cmd-col h3 img { width: 22px; height: 22px; image-rendering: pixelated; }
.cmd { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 10px; transition: background .18s; }
.cmd + .cmd { border-top: 1px solid rgba(255,210,63,.07); }
.cmd:hover { background: rgba(255,210,63,.06); }
.cmd img { width: 24px; height: 24px; image-rendering: pixelated; flex-shrink: 0; filter: drop-shadow(1px 2px 0 rgba(0,0,0,.45)); }
.cmd code { display: block; background: none; padding: 0; font-size: 15px; font-weight: 700; color: var(--y); }
.cmd span { display: block; font-size: 13.5px; color: var(--muted); line-height: 1.4; }

/* ================= LEADERBOARDS ================= */
.lb-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.lb-tab { display: flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 10px; font-weight: 600; font-size: 14.5px; color: var(--muted); border: 1px solid var(--line); transition: all .2s; }
.lb-tab img { width: 20px; height: 20px; image-rendering: pixelated; }
.lb-tab:hover { color: var(--ink); border-color: var(--line2); }
.lb-tab.active { background: rgba(255,210,63,.14); color: var(--y); border-color: var(--y); }
.lb-board { display: grid; gap: 6px; max-width: 720px; }
.lb-row { display: flex; align-items: center; gap: 14px; padding: 11px 16px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; animation: itemIn .35s backwards; }
.lb-row.top1 { border-color: var(--y); background: linear-gradient(90deg, rgba(255,210,63,.16), transparent 60%); }
.lb-row.top2 { border-color: rgba(220,220,230,.4); }
.lb-row.top3 { border-color: rgba(200,130,60,.45); }
.lb-rank { font-family: var(--pixel); font-size: 11px; color: var(--dim); width: 38px; }
.lb-row.top1 .lb-rank { color: var(--y); }
.lb-head { width: 32px; height: 32px; image-rendering: pixelated; border-radius: 4px; }
.lb-name { flex: 1; font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-value { font-family: var(--mono); font-weight: 700; color: var(--y); }
.lb-loading { color: var(--muted); padding: 18px 4px; }

/* ================= FAQ ================= */
.faq-list { display: grid; gap: 10px; max-width: 860px; }
.faq { background: linear-gradient(180deg, var(--panel2), var(--panel)); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.faq summary { list-style: none; cursor: pointer; padding: 18px 20px; font-weight: 700; font-size: 17px; display: flex; align-items: center; gap: 14px; transition: color .2s; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "+"; font-family: var(--pixel); font-size: 13px; color: var(--y); transition: transform .25s; }
.faq[open] summary::before { content: "–"; }
.faq summary:hover { color: var(--y); }
.faq p { padding: 0 20px 20px 48px; color: var(--muted); }

/* ================= STATUS ================= */
.status-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 20px; align-items: start; }
.mc-list {
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' shape-rendering='crispEdges'%3E%3Crect width='32' height='32' fill='%232b2116'/%3E%3Crect x='0' y='0' width='8' height='8' fill='%23332719'/%3E%3Crect x='16' y='8' width='8' height='8' fill='%23241b12'/%3E%3Crect x='8' y='20' width='8' height='8' fill='%23362a1b'/%3E%3Crect x='24' y='24' width='8' height='8' fill='%23221a11'/%3E%3C/svg%3E");
  border: 3px solid #000; box-shadow: 0 20px 50px rgba(0,0,0,.5);
  padding: 20px; image-rendering: pixelated;
}
.mc-list-title { text-align: center; font-family: var(--pixel); font-size: 13px; margin-bottom: 18px; text-shadow: 2px 2px 0 #3f3f3f; }
.mc-entry { display: flex; gap: 14px; padding: 10px; background: rgba(0,0,0,.72); border: 2px solid #a0a0a0; }
.mc-icon { width: 64px; height: 64px; image-rendering: pixelated; flex-shrink: 0; }
.mc-body { min-width: 0; flex: 1; }
.mc-row1 { display: flex; align-items: center; gap: 10px; font-family: var(--pixel); font-size: 12px; }
.mc-name { color: #fff; }
.mc-count { margin-left: auto; color: #aaa; }
.mc-ping { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.mc-ping i { width: 3px; background: #2a2a2a; }
.mc-ping i:nth-child(1) { height: 3px; } .mc-ping i:nth-child(2) { height: 5px; } .mc-ping i:nth-child(3) { height: 8px; } .mc-ping i:nth-child(4) { height: 11px; } .mc-ping i:nth-child(5) { height: 14px; }
.mc-ping.on i { background: #3cfc3c; box-shadow: 1px 1px 0 #0a4a0a; }
.mc-motd { margin-top: 8px; font-family: var(--pixel); font-size: 10.5px; line-height: 1.8; color: #aaa; white-space: pre; overflow: hidden; text-overflow: ellipsis; }
.mc-motd .line { display: block; overflow: hidden; text-overflow: ellipsis; }
.mc-gray { color: #aaa; }
.mc-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.mc-btn {
  font-family: var(--pixel); font-size: 11px; padding: 12px; color: #fff; text-shadow: 2px 2px 0 #3f3f3f;
  background: #6f6f6f; border: 2px solid #000;
  box-shadow: inset 2px 2px 0 #aaa, inset -2px -3px 0 #4a4a4a;
}
.mc-btn:hover { background: #7b87c6; box-shadow: inset 2px 2px 0 #b8c1f2, inset -2px -3px 0 #4a5390; color: #ffffa0; }
.mc-btn:active { transform: translateY(2px); }

.status-side { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.stat-box { background: linear-gradient(180deg, var(--panel2), var(--panel)); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.stat-label { font-family: var(--pixel); font-size: 9px; color: var(--dim); text-transform: uppercase; letter-spacing: .06em; }
.stat-big { font-family: var(--mono); font-size: 46px; line-height: 1; color: var(--green); text-shadow: 0 0 30px rgba(109,255,142,.35); }
.stat-mid { display: flex; align-items: center; gap: 10px; font-size: 22px; font-weight: 700; }
.stat-note { font-size: 13px; color: var(--muted); }
.cap-bar { height: 10px; background: #000; border: 1px solid #2d2715; border-radius: 3px; overflow: hidden; }
.cap-bar span { display: block; height: 100%; width: 0; background: repeating-linear-gradient(90deg, var(--green) 0 8px, #4bd66a 8px 10px); transition: width 1.2s cubic-bezier(.2,.8,.2,1); }
.ip-line { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-family: var(--mono); font-weight: 700; font-size: 17px; color: var(--y); text-align: left; min-width: 0; }
.ip-line .server-ip { overflow: hidden; text-overflow: ellipsis; }
.ip-line em { font-style: normal; font-family: var(--pixel); font-size: 8px; color: var(--dim); padding: 5px 6px; border: 1px solid var(--line2); border-radius: 4px; transition: all .2s; }
.ip-line:hover em { background: var(--y); color: #2a1d00; border-color: var(--y); }

.player-heads { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.head { display: flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; font-size: 14px; font-weight: 600; animation: popIn .4s backwards; }
.head img { width: 24px; height: 24px; image-rendering: pixelated; border-radius: 3px; }
@keyframes popIn { from { opacity: 0; transform: scale(.7); } }

/* ================= PRICES ================= */
.price-top { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-bottom: 30px; }
.top-item { position: relative; padding: 16px; border-radius: 12px; background: linear-gradient(160deg, rgba(255,210,63,.14), rgba(255,210,63,.02)); border: 1px solid var(--line2); cursor: pointer; transition: transform .2s, border-color .2s; overflow: hidden; }
.top-item:hover { transform: translateY(-4px); border-color: var(--y); }
.top-item .rank-n { position: absolute; top: 10px; right: 12px; font-family: var(--pixel); font-size: 10px; color: var(--y3); }
.top-item .slot { width: 40px; height: 40px; margin-bottom: 12px; }
.top-item .ti-name { font-weight: 600; font-size: 14px; color: var(--muted); line-height: 1.25; }
.top-item .ti-price { font-family: var(--mono); font-weight: 700; font-size: 20px; color: var(--y); }

.price-tools { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.tabs { display: flex; padding: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; }
.tab { padding: 10px 18px; border-radius: 9px; font-family: var(--pixel); font-size: 11px; color: var(--muted); transition: all .2s; }
.tab small { font-family: var(--sans); font-size: 12px; opacity: .7; }
.tab.active { background: var(--y); color: #2a1d00; box-shadow: 0 3px 0 var(--y3); }
.search { flex: 1; min-width: 220px; display: flex; align-items: center; gap: 10px; padding: 0 14px; height: 48px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; transition: border-color .2s; }
.search:focus-within { border-color: var(--y); }
.search svg { width: 18px; height: 18px; color: var(--dim); flex-shrink: 0; }
.search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: var(--ink); font: inherit; font-size: 16px; }
.search input::placeholder { color: var(--dim); }
select { height: 48px; padding: 0 14px; background: var(--panel); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; font: inherit; font-size: 15px; cursor: pointer; }
select:focus { outline: 0; border-color: var(--y); }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.chip { padding: 7px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--muted); border: 1px solid var(--line); background: transparent; transition: all .2s; }
.chip:hover { color: var(--ink); border-color: var(--line2); }
.chip.active { background: rgba(255,210,63,.14); color: var(--y); border-color: var(--y); }
.chip small { opacity: .6; margin-left: 4px; }

.price-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.item {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
  text-align: left; transition: transform .15s, border-color .15s, background .15s;
  animation: itemIn .35s backwards;
}
.item:hover { transform: translateY(-2px); border-color: var(--line2); background: var(--panel2); }
.item.sel { border-color: var(--y); background: rgba(255,210,63,.08); }
@keyframes itemIn { from { opacity: 0; transform: translateY(8px); } }
.item-body { min-width: 0; flex: 1; }
.item-name { display: block; font-weight: 600; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-stack { display: block; font-size: 12px; color: var(--dim); }
.item-price { font-family: var(--mono); font-weight: 700; color: var(--y); font-size: 15px; white-space: nowrap; }
.empty { grid-column: 1 / -1; text-align: center; padding: 50px; color: var(--muted); font-family: var(--pixel); font-size: 12px; line-height: 2; }

/* item "slot" swatch (fake inventory icon) */
.slot { display: block; position: relative; width: 34px; height: 34px; flex-shrink: 0; background: #8b8b8b; box-shadow: inset 2px 2px 0 #373737, inset -2px -2px 0 #fff; padding: 4px; }
.slot i { display: block; width: 100%; height: 100%; background: var(--c1); box-shadow: inset -3px -3px 0 rgba(0,0,0,.28), inset 3px 3px 0 rgba(255,255,255,.22); image-rendering: pixelated; }
.slot i.ore { background: radial-gradient(circle at 30% 30%, var(--c2) 18%, transparent 20%), radial-gradient(circle at 70% 60%, var(--c2) 16%, transparent 18%), radial-gradient(circle at 40% 78%, var(--c2) 12%, transparent 14%), #7a7a7a; }
.slot i.gem { background: linear-gradient(135deg, transparent 22%, var(--c1) 22% 78%, transparent 78%), linear-gradient(45deg, transparent 22%, var(--c2) 22% 78%, transparent 78%); box-shadow: none; }
.slot i.item-ic { border-radius: 30%; }
.slot i.sprite { background: url("/assets/items.png") no-repeat; box-shadow: none; image-rendering: pixelated; filter: drop-shadow(1px 1px 0 rgba(0,0,0,.35)); }
.slot:has(.sprite) { padding: 2px; }

/* calculator */
.calc {
  position: fixed; left: 50%; bottom: 96px; z-index: 60; width: min(560px, calc(100% - 32px));
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center;
  background: #16120a; border: 2px solid var(--y); border-radius: 14px; padding: 16px 18px;
  box-shadow: 0 20px 60px rgba(0,0,0,.6), 0 0 40px rgba(255,210,63,.15);
  transition: all .3s cubic-bezier(.2,.8,.2,1);
}
.calc.show { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
.calc .slot { width: 52px; height: 52px; padding: 6px; }
.calc-name { font-weight: 700; font-size: 17px; }
.calc-unit { font-size: 13px; color: var(--muted); }
.calc-quick { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.calc-quick button { padding: 5px 10px; border-radius: 6px; font-size: 13px; font-weight: 600; border: 1px solid var(--line2); color: var(--muted); }
.calc-quick button:hover, .calc-quick button.active { background: var(--y); color: #2a1d00; border-color: var(--y); }
.calc-quick input { width: 74px; padding: 4px 8px; border-radius: 6px; border: 1px solid var(--line2); background: #0d0b06; color: var(--ink); font: inherit; font-size: 13px; }
.calc-total { text-align: right; }
.calc-total span { display: block; font-size: 12px; color: var(--muted); }
.calc-total b { font-family: var(--mono); font-size: 24px; color: var(--y); white-space: nowrap; }
.calc-close { position: absolute; top: -12px; right: -12px; width: 28px; height: 28px; border-radius: 50%; background: var(--y); color: #2a1d00; font-weight: 800; font-size: 13px; }

.price-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 22px; color: var(--muted); font-size: 14px; }

/* ================= RANKS ================= */
.ranks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.rank { position: relative; padding: 26px 22px; border-radius: var(--radius); background: linear-gradient(180deg, color-mix(in srgb, var(--r) 10%, var(--panel2)), var(--panel)); border: 1px solid color-mix(in srgb, var(--r) 30%, transparent); transition: transform .2s, box-shadow .3s; }
.rank:hover { box-shadow: 0 20px 50px color-mix(in srgb, var(--r) 18%, transparent); }
.rank.featured { border-width: 2px; border-color: var(--r); }
.rank.featured::before { content: "BEST"; position: absolute; top: -11px; right: 16px; font-family: var(--pixel); font-size: 9px; background: var(--r); color: #00202c; padding: 5px 8px; border-radius: 4px; }
.rank-badge { display: inline-block; font-family: var(--pixel); font-size: 15px; color: var(--r); text-shadow: 2px 2px 0 color-mix(in srgb, var(--r) 35%, #000); margin-bottom: 12px; }
.rank-price { color: var(--muted); margin-bottom: 14px; font-size: 15px; }
.rank-price b { font-family: var(--mono); font-size: 26px; color: var(--ink); }
.rank ul { list-style: none; display: grid; gap: 6px; }
.rank li { font-size: 14.5px; color: var(--muted); padding-left: 20px; position: relative; }
.rank li::before { content: ""; position: absolute; left: 0; top: .55em; width: 8px; height: 8px; background: var(--r); box-shadow: 2px 2px 0 color-mix(in srgb, var(--r) 40%, #000); }

/* ================= LINK CARDS ================= */
.links { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.link-card {
  --lc: var(--y);
  position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 4px;
  padding: 28px; min-height: 240px; border-radius: 18px;
  background: linear-gradient(150deg, color-mix(in srgb, var(--lc) 26%, #0d0b06), #0f0d08 70%);
  border: 1px solid color-mix(in srgb, var(--lc) 40%, transparent);
  transition: transform .25s, box-shadow .3s;
}
.link-card:hover { transform: translateY(-6px) rotate(-.5deg); box-shadow: 0 24px 60px color-mix(in srgb, var(--lc) 25%, transparent); }
.link-card::after { content: ""; position: absolute; width: 220px; height: 220px; right: -60px; bottom: -80px; border-radius: 50%; background: var(--lc); opacity: .12; filter: blur(10px); transition: transform .4s; }
.link-card:hover::after { transform: scale(1.35); }
.link-card.discord { --lc: #5865f2; }
.link-card.twitch { --lc: #9146ff; }
.lc-icon { width: 58px; height: 58px; display: grid; place-items: center; font-size: 28px; border-radius: 14px; background: var(--lc); color: #fff; margin-bottom: 18px; box-shadow: 4px 4px 0 rgba(0,0,0,.4); }
.link-card.store .lc-icon { color: #2a1d00; }
.lc-icon svg { width: 30px; height: 30px; }
.lc-title { font-size: 28px; font-weight: 800; }
.lc-sub { color: var(--muted); }
.lc-url { margin-top: auto; padding-top: 18px; font-family: var(--mono); font-weight: 700; color: var(--lc); filter: brightness(1.3); }

/* ================= JOIN ================= */
.join {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 30px; align-items: center;
  padding: 44px; border-radius: 22px;
  background: radial-gradient(circle at 90% 10%, rgba(255,210,63,.22), transparent 50%), linear-gradient(160deg, #221b0b, #120f07);
  border: 2px solid var(--line2);
}
.join ol { list-style: none; display: grid; gap: 12px; margin-top: 18px; }
.join li { display: flex; align-items: center; gap: 14px; font-size: 17px; }
.join li b { width: 32px; height: 32px; display: grid; place-items: center; font-family: var(--pixel); font-size: 11px; background: var(--y); color: #2a1d00; box-shadow: 3px 3px 0 var(--y3); flex-shrink: 0; }
.join li .server-ip { font-family: var(--mono); color: var(--y); margin: 0 6px; }
.big-ip {
  display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 34px 20px;
  background: #0b0904; border: 3px dashed var(--y); border-radius: 16px; transition: all .2s;
}
.big-ip .server-ip { font-family: var(--pixel); font-size: clamp(16px, 2.6vw, 26px); color: var(--y); text-shadow: 3px 3px 0 var(--y3); }
.big-ip small { color: var(--muted); font-size: 14px; }
.big-ip:hover { background: #17120a; transform: scale(1.02); border-style: solid; }

/* ================= FOOTER ================= */
.footer { margin-top: 100px; padding: 40px 0 120px; border-top: 1px solid var(--line); background: #0a0804; }
.footer-in { display: grid; grid-template-columns: auto 1fr; gap: 16px 30px; align-items: center; }
.footer-links { display: flex; gap: 20px; justify-content: flex-end; font-weight: 600; color: var(--muted); }
.footer-links a:hover { color: var(--y); }
.fine { grid-column: 1 / -1; color: var(--dim); font-size: 13px; }

/* ================= MUSIC PLAYER ================= */
.player {
  position: fixed; left: 16px; bottom: 16px; z-index: 55;
  display: flex; align-items: center; gap: 12px;
  padding: 8px 12px 8px 8px; border-radius: 14px;
  background: rgba(20, 16, 8, .88); border: 1px solid var(--line2); backdrop-filter: blur(12px);
  box-shadow: 0 12px 40px rgba(0,0,0,.5);
  transform: translateY(140%); transition: transform .5s cubic-bezier(.2,.8,.2,1);
}
.player.show { transform: none; }
.p-play { width: 44px; height: 44px; display: grid; place-items: center; background: var(--y); color: #2a1d00; border: 2px solid #000; box-shadow: inset 2px 2px 0 #fff09a, inset -2px -3px 0 var(--y3); }
.p-play:active { transform: translateY(2px); }
.p-play svg { width: 20px; height: 20px; }
.p-play .i-pause, .player.playing .p-play .i-play { display: none; }
.player.playing .p-play .i-pause { display: block; }
.player-info { display: flex; flex-direction: column; min-width: 0; width: 150px; }
.player-label { display: flex; align-items: center; gap: 6px; font-family: var(--pixel); font-size: 8px; color: var(--y); text-transform: uppercase; }
.disc { width: 10px; height: 10px; border-radius: 50%; background: conic-gradient(var(--y), #000, var(--y), #000, var(--y)); }
.player.playing .disc { animation: rot 1.4s linear infinite; }
@keyframes rot { to { transform: rotate(360deg); } }
.player-track { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#viz { width: 96px; height: 32px; }
.p-btn { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 8px; color: var(--muted); border: 1px solid var(--line); }
.p-btn:hover { color: var(--ink); border-color: var(--line2); }
.p-btn svg { width: 16px; height: 16px; }
.p-sfx { font-family: var(--pixel); font-size: 7px; width: 40px; }
.p-sfx.on { color: var(--y); border-color: var(--y3); }
.p-sfx:not(.on) { text-decoration: line-through; }
#volume { width: 80px; accent-color: var(--y); cursor: pointer; }

/* ================= TOAST ================= */
.toast {
  position: fixed; top: 84px; left: 50%; z-index: 90;
  transform: translate(-50%, -20px); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 12px;
  background: #1c1810; border: 2px solid #000; outline: 2px solid #5a4d2a; padding: 12px 18px;
  font-family: var(--pixel); font-size: 11px; color: var(--y); line-height: 1.6;
  box-shadow: 0 10px 30px rgba(0,0,0,.6);
  transition: all .3s cubic-bezier(.2,.8,.2,1);
}
.toast small { display: block; font-family: var(--sans); font-size: 13px; color: var(--ink); }
.toast.show { transform: translate(-50%, 0); opacity: 1; }
.toast .t-icon { width: 30px; height: 30px; background: var(--y); display: grid; place-items: center; color: #2a1d00; font-size: 16px; box-shadow: inset -3px -3px 0 var(--y3); }

/* floating +$ text and xp orbs for copy clicks */
.float-txt { position: fixed; z-index: 95; pointer-events: none; font-family: var(--pixel); font-size: 13px; color: var(--y); text-shadow: 2px 2px 0 #000; animation: floatUp 1s ease-out forwards; }
@keyframes floatUp { to { transform: translateY(-60px); opacity: 0; } }
.orb { position: fixed; z-index: 95; width: 10px; height: 10px; pointer-events: none; border-radius: 2px; background: #c8ff3c; box-shadow: 0 0 10px #b6ff3c, inset -2px -2px 0 #5aa600; }

/* ================= RESPONSIVE ================= */
@media (max-width: 1020px) {
  .cmd-cols { grid-template-columns: 1fr 1fr; }
  .nav-links { position: fixed; top: var(--nav-h); left: 0; right: 0; flex-direction: column; margin: 0; padding: 12px 16px 20px; background: rgba(13,11,6,.97); border-bottom: 1px solid var(--line); transform: translateY(-120%); transition: transform .3s; z-index: -1; }
  .nav.open .nav-links { transform: none; }
  .nav.open { background: rgba(13,11,6,.97); }
  .nav-links a { padding: 12px 14px; font-size: 17px; }
  .burger { display: flex; }
  .bento { grid-template-columns: 1fr 1fr; }
  .card.big { grid-column: 1 / -1; grid-row: auto; }
  .status-grid { grid-template-columns: 1fr; }
  .price-top { grid-template-columns: repeat(3, 1fr); }
  .price-top .top-item:nth-child(n+4) { display: none; }
  .ranks { grid-template-columns: 1fr 1fr; }
  .links { grid-template-columns: 1fr; }
  .link-card { min-height: 0; }
  .join { grid-template-columns: 1fr; padding: 30px; }
}
@media (max-width: 640px) {
  .cmd-cols { grid-template-columns: 1fr; }
  body { font-size: 16px; }
  .icon-link { display: none; }
  .ip-chip .ip-copy { display: none; }
  .ip-chip { padding: 0 12px; font-size: 13px; }
  .wordmark { font-size: 12px; }
  .section { padding-top: 84px; }
  .bento, .status-side, .ranks { grid-template-columns: 1fr; }
  .price-top { grid-template-columns: 1fr 1fr; }
  .price-top .top-item:nth-child(n+3) { display: none; }
  .price-grid { grid-template-columns: 1fr; }
  .tabs { width: 100%; }
  .tab { flex: 1; }
  select { width: 100%; }
  .mc-motd { font-size: 8px; }
  .mc-row1 { font-size: 10px; }
  .hero-cta { flex-direction: column; width: 100%; max-width: 320px; }
  .cash-hud { right: 12px; bottom: 70px; }
  .player { left: 8px; right: 8px; bottom: 8px; gap: 8px; }
  .player-info { flex: 1; width: auto; }
  #viz, #volume { display: none; }
  .calc { grid-template-columns: auto 1fr; bottom: 84px; }
  .calc-total { grid-column: 1 / -1; text-align: left; display: flex; align-items: baseline; justify-content: space-between; }
  .footer-in { grid-template-columns: 1fr; }
  .footer-links { justify-content: flex-start; }
  .join { padding: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; animation-iteration-count: 1 !important; transition-duration: .001s !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}

/* ================= MULTI-PAGE ================= */
.nav-links a.active { color: var(--y); background: rgba(255,210,63,.1); }
main.page-out { opacity: 0; transform: translateY(10px); transition: opacity .18s, transform .18s; }
main.page-in { animation: pageIn .45s cubic-bezier(.2,.8,.2,1); }
@keyframes pageIn { from { opacity: 0; transform: translateY(14px); } }

.page-hero {
  position: relative; overflow: hidden;
  padding: calc(var(--nav-h) + 70px) 0 40px;
  background:
    radial-gradient(ellipse 70% 90% at 85% 0%, rgba(255,190,40,.16), transparent 60%),
    linear-gradient(to bottom, #15110a, var(--bg));
  border-bottom: 1px solid var(--line);
}
.page-hero::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 18px;
  background: repeating-linear-gradient(90deg, #5fa83a 0 18px, #6bbf45 18px 36px, #56982f 36px 54px);
  box-shadow: 0 -6px 0 rgba(0,0,0,.25) inset; opacity: .9;
}
.page-hero h1 { font-size: clamp(36px, 6vw, 64px); line-height: 1.05; font-weight: 800; letter-spacing: -.02em; margin-bottom: 16px; }
.page-hero .lede { max-width: 700px; margin-bottom: 20px; }
.inline-link { color: var(--y); text-decoration: underline; text-underline-offset: 3px; }
.section.tight { padding-top: 40px; }
.teaser-cta { margin-top: 26px; display: flex; justify-content: center; }

/* rules */
.rules-layout { display: grid; grid-template-columns: 240px 1fr; gap: 40px; padding: 50px 0 20px; align-items: start; }
.rules-toc { position: sticky; top: calc(var(--nav-h) + 20px); }
.rules-toc nav { display: flex; flex-direction: column; gap: 4px; padding: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.rules-toc a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px; font-weight: 600; color: var(--muted); font-size: 15px; transition: all .2s; }
.rules-toc a:hover { color: var(--ink); background: rgba(255,210,63,.06); }
.rules-toc a.active { color: #2a1d00; background: var(--y); }
.toc-ic { width: 22px; text-align: center; }
.rules-body { display: grid; gap: 22px; }
.rule-sec { background: linear-gradient(180deg, var(--panel2), var(--panel)); border: 1px solid var(--line); border-radius: 18px; padding: 28px; scroll-margin-top: calc(var(--nav-h) + 20px); }
.rule-sec h2 { display: flex; align-items: center; gap: 14px; font-size: clamp(22px, 3vw, 30px); margin-bottom: 18px; }
.rule-ic { width: 44px; height: 44px; display: grid; place-items: center; font-size: 20px; background: var(--y); color: #2a1d00; box-shadow: 4px 4px 0 var(--y3); flex-shrink: 0; }
.rule-list { list-style: none; display: grid; gap: 4px; }
.rule { display: grid; grid-template-columns: 48px 1fr; gap: 12px; padding: 14px 12px; border-radius: 10px; transition: background .2s; }
.rule:hover { background: rgba(255,210,63,.05); }
.rule-n { font-family: var(--pixel); font-size: 11px; color: var(--y); padding-top: 5px; }
.rule b { font-size: 17px; }
.rule p { color: var(--muted); font-size: 15.5px; }
.rules-foot { color: var(--dim); font-size: 14px; padding: 0 6px; }

/* 404: you died */
.died {
  min-height: 100svh; display: grid; place-items: center; text-align: center; padding: 100px 16px;
  background: radial-gradient(ellipse at center, rgba(160,0,0,.55), rgba(60,0,0,.85) 70%), #1a0000;
}
.died-inner { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.died-title { font-family: var(--pixel); font-weight: 400; font-size: clamp(28px, 6vw, 56px); color: #fff; text-shadow: 4px 4px 0 #3f3f3f; animation: dieIn .9s cubic-bezier(.2,.8,.2,1); }
@keyframes dieIn { from { transform: scale(2.2); opacity: 0; } }
.died-sub { color: #ddd; }
.died-score { font-family: var(--pixel); font-size: 13px; color: #fff; }
.died-score b { color: #ff5; font-weight: 400; }
.died-btns { display: grid; gap: 10px; width: min(360px, 100%); margin-top: 10px; }
.died .mc-btn { display: block; padding: 14px; }

@media (max-width: 1020px) {
  .rules-layout { grid-template-columns: 1fr; gap: 20px; }
  .rules-toc { position: static; }
  .rules-toc nav { flex-direction: row; flex-wrap: wrap; }
  .rules-toc a { padding: 8px 10px; font-size: 14px; }
}
@media (max-width: 640px) {
  .rule-sec { padding: 20px 16px; }
  .rule { grid-template-columns: 38px 1fr; padding: 12px 4px; }
}

/* rank cards: buy button pinned to the bottom */
.rank { display: flex; flex-direction: column; }
.rank ul { margin-bottom: 20px; }
.rank-buy {
  margin-top: auto; text-align: center; padding: 11px; font-family: var(--pixel); font-size: 10px;
  background: var(--r); color: #1a1200; border: 2px solid #000;
  box-shadow: inset 2px 2px 0 rgba(255,255,255,.45), inset -2px -3px 0 rgba(0,0,0,.3);
  transition: transform .12s, filter .2s;
}
.rank-buy:hover { filter: brightness(1.12); transform: translateY(-2px); }
.rank-buy:active { transform: translateY(2px); }
.ranks { align-items: stretch; }

/* top payout cards */
.top-item { display: flex; flex-direction: column; align-items: flex-start; text-align: left; }
.top-item .ti-name, .top-item .ti-price { display: block; }

/* rules: every section has its own colour (--rc) + a Minecraft item icon */
.rule-ic, .toc-ic { display: grid; place-items: center; flex-shrink: 0; }
.rule-ic { width: 48px; height: 48px; background: color-mix(in srgb, var(--rc) 22%, #120f07); border: 2px solid var(--rc); box-shadow: 4px 4px 0 color-mix(in srgb, var(--rc) 45%, #000); }
.rule-ic img { width: 30px; height: 30px; image-rendering: pixelated; filter: drop-shadow(1px 1px 0 rgba(0,0,0,.5)); }
.toc-ic { width: 26px; height: 26px; border-radius: 6px; background: color-mix(in srgb, var(--rc) 20%, transparent); }
.toc-ic img { width: 18px; height: 18px; image-rendering: pixelated; }
.rules-toc a.active { background: color-mix(in srgb, var(--rc) 18%, transparent); color: var(--rc); box-shadow: inset 3px 0 0 var(--rc); }
.rule-sec { border-top: 3px solid var(--rc); }
.rule-sec h2 { color: var(--ink); }
.rule-n { color: var(--rc); }
.rule:hover { background: color-mix(in srgb, var(--rc) 7%, transparent); }

/* ================= LEADERBOARD PAGE ================= */
.lb-podium { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; align-items: end; margin: 10px 0 26px; }
.pod {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 20px 12px 0; border-radius: 16px 16px 0 0; text-align: center;
  background: linear-gradient(180deg, rgba(255,210,63,.10), transparent 70%);
  animation: podRise .75s cubic-bezier(.2,.9,.25,1) backwards; animation-delay: var(--d, 0s);
}
@keyframes podRise { from { opacity: 0; transform: translateY(40px) scale(.94); } }
.pod-head { position: relative; padding: 5px; border-radius: 12px; background: var(--panel2); border: 2px solid var(--line2); }
.pod-head img { width: 64px; height: 64px; image-rendering: pixelated; border-radius: 6px; display: block; }
.pod-name { font-weight: 700; font-size: 17px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pod-value { font-family: var(--mono); font-size: 20px; color: var(--y); }
.pod-block {
  width: 100%; margin-top: 6px; display: grid; place-items: center;
  font-family: var(--pixel); font-size: 13px; color: #2a1d00;
  background: linear-gradient(180deg, #6f6f6f, #4a4a4a); border: 3px solid #000; border-bottom: 0;
  box-shadow: inset 3px 3px 0 rgba(255,255,255,.25), inset -3px 0 0 rgba(0,0,0,.35);
  animation: podGrow .8s cubic-bezier(.2,.9,.25,1) backwards; animation-delay: var(--d, 0s);
  transform-origin: bottom;
}
@keyframes podGrow { from { transform: scaleY(0); } }
.pod1 .pod-block { height: 92px; background: linear-gradient(180deg, #ffe066, var(--y2)); box-shadow: inset 3px 3px 0 #fff3a8, inset -3px 0 0 var(--y3), 0 0 40px rgba(255,210,63,.35); }
.pod2 .pod-block { height: 64px; background: linear-gradient(180deg, #e9e9ef, #b9b9c4); }
.pod3 .pod-block { height: 46px; background: linear-gradient(180deg, #e0a06a, #b2703c); }
.pod1 .pod-head { border-color: var(--y); box-shadow: 0 0 30px rgba(255,210,63,.35); }
.pod1 .pod-value { font-size: 24px; text-shadow: 0 0 22px rgba(255,210,63,.5); }
.pod-crown { position: absolute; top: -14px; font-size: 26px; color: var(--y); filter: drop-shadow(0 0 10px rgba(255,210,63,.6)); animation: crownFloat 2.6s ease-in-out infinite; }
@keyframes crownFloat { 0%,100% { transform: translateY(0) rotate(-4deg); } 50% { transform: translateY(-6px) rotate(4deg); } }

/* rows 4+ with a bar showing how far behind #1 they are */
#leaderboards .lb-row { animation: lbIn .5s cubic-bezier(.2,.8,.2,1) backwards; animation-delay: var(--d, 0s); }
@keyframes lbIn { from { opacity: 0; transform: translateX(-18px); } }
.lb-bar { flex: 1; height: 8px; min-width: 40px; background: #0d0b06; border: 1px solid var(--line); border-radius: 4px; overflow: hidden; margin: 0 6px; }
.lb-bar i { display: block; height: 100%; width: var(--w, 0%); background: linear-gradient(90deg, var(--y3), var(--y)); animation: barFill 1s cubic-bezier(.2,.8,.2,1) backwards; animation-delay: calc(var(--d, 0s) + .1s); }
@keyframes barFill { from { width: 0; } }
.lb-row:hover .lb-bar i { filter: brightness(1.25); }
.lb-row .lb-head { transition: transform .2s; }
.lb-row:hover .lb-head { transform: scale(1.15) rotate(-4deg); }

/* first place shimmer on the compact home board */
.lb-row.top1 { position: relative; overflow: hidden; }
.lb-row.top1::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 40%, rgba(255,240,154,.28) 50%, transparent 60%);
  transform: translateX(-100%); animation: shine 4.5s ease-in-out infinite 1.5s;
}
@keyframes shine { 0% { transform: translateX(-100%); } 35%, 100% { transform: translateX(100%); } }
.lb-foot { display: flex; align-items: center; gap: 10px; margin-top: 20px; color: var(--muted); font-size: 14px; }

@media (max-width: 640px) {
  .lb-podium { gap: 6px; }
  .pod { padding: 16px 4px 0; }
  .pod-head img { width: 44px; height: 44px; }
  .pod-name { font-size: 13px; }
  .pod-value { font-size: 15px; }
  .pod1 .pod-value { font-size: 17px; }
  .lb-bar { display: none; }
}

/* ================= MINECRAFT GUI (/shop and /sell) ================= */
.gui-wrap { display: flex; justify-content: center; }
.gui-links { display: flex; gap: 10px; flex-wrap: wrap; }
.mc-window {
  background: #c6c6c6; border: 4px solid #000;
  box-shadow: inset 4px 4px 0 #fff, inset -4px -4px 0 #555, 0 24px 60px rgba(0,0,0,.55);
  padding: 14px; image-rendering: pixelated;
  width: min(640px, 100%);
}
.mc-title { font-family: var(--pixel); font-size: 12px; color: #3f3f3f; margin-bottom: 12px; }
.mc-grid { display: grid; grid-template-columns: repeat(9, 1fr); gap: 4px; }
.mc-slot {
  position: relative; aspect-ratio: 1; min-width: 30px; display: grid; place-items: center; padding: 4px;
  background: #8b8b8b; box-shadow: inset 2px 2px 0 #373737, inset -2px -2px 0 #fff;
  border: 0; cursor: default;
}
.mc-slot.filled { cursor: pointer; }
.mc-slot.filled:hover { background: #b6b6b6; }
.mc-slot.filled:hover::after { content: ""; position: absolute; inset: 2px; background: rgba(255,255,255,.45); pointer-events: none; }
.mc-slot.filled:active { transform: scale(.94); }
.mc-slot i { width: 100%; height: 100%; display: block; background-repeat: no-repeat; }
.mc-slot i.sprite { background-image: url("/assets/items.png"); image-rendering: pixelated; filter: drop-shadow(2px 2px 0 rgba(0,0,0,.35)); }
.slot-count, .slot-price {
  position: absolute; right: 1px; bottom: 0; font-family: var(--pixel); font-size: 8px;
  color: #fff; text-shadow: 2px 2px 0 #3f3f3f; pointer-events: none;
}
.slot-price { color: #fff09a; }
.mc-slot.pulse { animation: slotPulse .4s ease; }
@keyframes slotPulse { 50% { box-shadow: inset 2px 2px 0 #373737, inset -2px -2px 0 #fff, 0 0 0 4px rgba(255,210,63,.65); } }
.mc-navrow { grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 8px; }
.mc-slot.nav { aspect-ratio: auto; width: auto; min-width: 46px; height: 34px; font-family: var(--pixel); font-size: 11px; color: #2a2a2a; }
.mc-slot.nav:disabled { opacity: .45; cursor: default; }
.mc-page { font-family: var(--pixel); font-size: 10px; color: #3f3f3f; }

/* item tooltip */
.mc-tip {
  position: fixed; z-index: 120; pointer-events: none; opacity: 0; transition: opacity .12s;
  min-width: 150px; max-width: 280px; padding: 8px 10px;
  background: rgba(16, 0, 24, .94); border: 2px solid #2b0e4a; outline: 2px solid #120021;
  display: flex; flex-direction: column; gap: 3px;
}
.mc-tip.show { opacity: 1; }
.mc-tip .t-name { font-family: var(--pixel); font-size: 10px; color: #fff; line-height: 1.5; }
.mc-tip .t-line { font-size: 13px; color: #aaa; }
.mc-tip .t-line.gold { color: var(--y); font-weight: 700; }
.mc-tip .t-hint { font-size: 12px; color: #9a7ad1; font-style: italic; }

.gui-msg { margin-top: 18px; text-align: center; color: var(--muted); opacity: 0; transform: translateY(6px); transition: all .3s; }
.gui-msg.show { opacity: 1; transform: none; }
.gui-msg b { color: var(--ink); }
.gui-msg .gold { color: var(--y); }
.gui-msg em { color: var(--dim); font-size: 14px; }

/* /sell layout */
.sell-layout { display: grid; grid-template-columns: 300px 1fr; gap: 22px; align-items: start; }
.sell-side { background: linear-gradient(180deg, var(--panel2), var(--panel)); border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.sell-hint { font-size: 13px; color: var(--dim); margin: 10px 2px; }
.mc-palette { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; max-height: 420px; overflow-y: auto; padding-right: 4px; }
.mc-palette::-webkit-scrollbar { width: 8px; }
.mc-palette::-webkit-scrollbar-thumb { background: var(--y3); border-radius: 4px; }
.mc-grid.drop { outline: 3px dashed transparent; outline-offset: 6px; transition: outline-color .2s; }
.mc-grid.drop-hot { outline-color: var(--y); }
.sell-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; flex-wrap: wrap; }
.sell-stack { display: flex; align-items: center; gap: 6px; font-family: var(--pixel); font-size: 9px; color: #3f3f3f; }
.sell-stack button { padding: 6px 9px; font-family: var(--pixel); font-size: 9px; color: #2a2a2a; background: #8b8b8b; box-shadow: inset 2px 2px 0 #fff, inset -2px -2px 0 #555; }
.sell-stack button.active { background: var(--y); box-shadow: inset 2px 2px 0 #fff09a, inset -2px -2px 0 var(--y3); }
.sell-slots { font-family: var(--pixel); font-size: 9px; color: #3f3f3f; }
.sell-total {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  margin-top: 18px; padding: 18px 22px; border-radius: 14px;
  background: linear-gradient(120deg, rgba(23,221,98,.12), rgba(255,210,63,.1)); border: 1px solid var(--line2);
}
.sell-total-label { display: block; font-family: var(--pixel); font-size: 9px; color: var(--dim); margin-bottom: 6px; }
.sell-total b { font-family: var(--mono); font-size: clamp(26px, 4vw, 38px); color: var(--y); }
.sell-actions { display: flex; gap: 10px; }
#sellAll:disabled { opacity: .5; }

.drag-ghost { position: fixed; z-index: 130; width: 46px; height: 46px; pointer-events: none; transform: translate(-50%, -50%); opacity: .9; }
.drag-ghost .mc-slot { width: 46px; height: 46px; }
.cash-fly { position: fixed; z-index: 125; width: 26px; height: 26px; pointer-events: none; image-rendering: pixelated; }

@media (max-width: 900px) {
  .sell-layout { grid-template-columns: 1fr; }
  .mc-palette { grid-template-columns: repeat(8, 1fr); max-height: 220px; }
}
@media (max-width: 640px) {
  .mc-window { padding: 8px; border-width: 3px; }
  .mc-grid { gap: 3px; }
  .mc-palette { grid-template-columns: repeat(6, 1fr); }
  .mc-tip { max-width: 220px; }
}

/* in-game colours for the GUI tooltips and the back button */
.mc-tip .t-name.gold { color: #ffde21; }
.mc-tip .t-name.aqua { color: #55ffb8; }
.mc-tip .t-name.red { color: #ff5555; }
.mc-tip b.mint { color: #55ffb8; }
.mc-tip b.red { color: #ff5555; }
.mc-tip b.aqua { color: #55ffb8; }
.mc-slot i.pane-red { width: 100%; height: 100%; background: #a62c2c; box-shadow: inset 0 0 0 3px #c33b3b, inset 0 0 0 5px rgba(0,0,0,.25); }
.mc-slot i.ui-icon { width: 100%; height: 100%; background-size: contain; background-repeat: no-repeat; background-position: center; image-rendering: pixelated; filter: drop-shadow(2px 2px 0 rgba(0,0,0,.35)); }
a.mc-slot { text-decoration: none; }

/* buy menu */
.mc-tip .t-name.green { color: #55ff55; }
.mc-slot.preview { cursor: default; }
.mc-total { margin-top: 12px; text-align: center; font-family: var(--pixel); font-size: 10px; color: #3f3f3f; }
.mc-total b { color: #1d7a52; }
