:root {
  --bg: #0b0e14;
  --surface: #11151f;
  --surface-2: #171d2b;
  --surface-3: #1f2738;
  --line: #232b3d;
  --text: #e8ecf4;
  --muted: #7d8699;
  --accent: #f0b90b;
  --accent-hot: #ffd53d;
  --accent-ink: #17130a;
  --green: #3ecf8e;
  --red: #f4566e;
  --shadow: 0 12px 32px rgba(4, 8, 20, .55);
  --r-lg: 16px;
  --r-md: 12px;
  --r-sm: 8px;
  --z-nav: 50;
  --z-modal: 100;
  --z-toast: 110;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Outfit", system-ui, sans-serif;
  font-size: 15px;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}
b { font-weight: 600; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* film grain to kill digital flatness */
.noise {
  position: fixed; inset: 0; pointer-events: none; z-index: 1; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
}

/* ---------- utility bar ---------- */
.utilbar { background: #07090e; border-bottom: 1px solid var(--line); position: relative; z-index: 3; }
.utilbar-inner {
  max-width: 1280px; margin: 0 auto; padding: 0 24px; height: 38px;
  display: flex; align-items: center; gap: 2px; font-size: .8rem; overflow-x: auto;
}
.util-icon { color: var(--muted); display: grid; place-items: center; padding: 6px 8px; border-radius: 6px; transition: color .2s; }
.util-icon:hover { color: var(--text); }
.util-icon svg { width: 14px; height: 14px; fill: currentColor; }
.util-sep { width: 1px; height: 15px; background: var(--line); margin: 0 10px 0 6px; flex-shrink: 0; }
.util-link {
  color: var(--muted); text-decoration: none; font-weight: 500; padding: 6px 10px;
  border-radius: 6px; white-space: nowrap; transition: color .2s;
}
.util-link:hover, .util-link.active { color: var(--text); }
.util-free {
  margin-left: auto; display: inline-flex; align-items: center; gap: 7px;
  color: var(--text); font-weight: 600; text-decoration: none; white-space: nowrap;
  padding: 6px 10px; border-radius: 6px; transition: color .2s;
}
.util-free svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.util-free:hover { color: var(--accent-hot); }

/* ---------- topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: var(--z-nav);
  background: rgba(11, 14, 20, .82); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  max-width: 1280px; margin: 0 auto; padding: 0 24px; height: 64px;
  display: flex; align-items: center; gap: 32px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand-mark {
  width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  background: linear-gradient(145deg, var(--accent-hot), var(--accent));
  color: var(--accent-ink); font-weight: 800; font-size: 1rem;
  box-shadow: 0 4px 14px rgba(240, 185, 11, .35);
}
.brand-name { font-weight: 800; font-size: 1.05rem; letter-spacing: .12em; }
.nav { display: flex; gap: 4px; margin-right: auto; }
.nav-link {
  color: var(--muted); text-decoration: none; font-weight: 500; font-size: .92rem;
  padding: 8px 14px; border-radius: var(--r-sm); transition: color .2s, background .2s;
}
.nav-link:hover { color: var(--text); background: var(--surface-2); }
.nav-link.active { color: var(--text); background: var(--surface-2); }
.topbar-right { display: flex; align-items: center; gap: 12px; }
.online-pill {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: .82rem; color: var(--muted); background: var(--surface-2);
  border-radius: 999px; padding: 6px 13px; font-variant-numeric: tabular-nums;
}
.live-dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--green);
  box-shadow: 0 0 8px rgba(62, 207, 142, .8); animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 50% { opacity: .45; } }

/* ---------- buttons ---------- */
.btn {
  font-family: inherit; font-weight: 700; font-size: .92rem;
  border: none; border-radius: 10px; padding: 10px 20px; cursor: pointer;
  transition: transform .2s, box-shadow .2s, background .2s, color .2s;
}
.btn:active { transform: scale(.97); }
.btn-gold {
  background: linear-gradient(145deg, var(--accent-hot), var(--accent));
  color: var(--accent-ink); box-shadow: 0 4px 16px rgba(240, 185, 11, .28);
}
.btn-gold:hover { transform: translateY(-1px); box-shadow: 0 6px 22px rgba(240, 185, 11, .42); }
.btn-ghost { background: var(--surface-3); color: var(--text); }
.btn-ghost:hover { background: var(--line); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }

/* ---------- container / layout ---------- */
.container { max-width: 1280px; margin: 0 auto; padding: 24px; position: relative; z-index: 2; }
.layout { display: grid; grid-template-columns: 1fr 320px; gap: 20px; align-items: start; }
@media (max-width: 960px) { .layout { grid-template-columns: 1fr; } }

/* ---------- chat: fixed rail on the far left ---------- */
.chat {
  position: fixed; left: 20px; top: 116px; bottom: 20px; width: 284px; z-index: 4;
  display: flex; flex-direction: column; padding: 18px;
}
/* not enough side margin for the rail — push the page content right of it */
@media (min-width: 1241px) and (max-width: 1903px) {
  .container { margin-left: 328px; margin-right: 12px; }
}
/* narrow screens: chat rejoins the page flow below the game */
@media (max-width: 1240px) {
  .chat { position: static; width: auto; grid-column: 1 / -1; order: 3; height: 380px; }
}
.chat-log {
  list-style: none; flex: 1; overflow-y: auto;
  display: flex; flex-direction: column; gap: 11px;
  margin-bottom: 12px; padding-right: 4px; scrollbar-width: thin;
}
.chat-log:empty::after { content: "No messages yet — say gm."; color: var(--muted); font-size: .85rem; }
.chat-msg { font-size: .85rem; line-height: 1.45; overflow-wrap: anywhere; }
.chat-who { color: var(--accent); font-weight: 600; font-variant-numeric: tabular-nums; margin-right: 6px; }
.chat-msg.self .chat-who { color: var(--green); }
.chat-text { color: var(--text); }
.chat-form { display: flex; gap: 8px; }
.chat-form input {
  flex: 1; min-width: 0; background: var(--surface-2); border: none; border-radius: 10px;
  padding: 10px 14px; color: var(--text); font-family: inherit; font-size: .88rem;
}
.chat-form input::placeholder { color: var(--muted); }
.chat-form .btn { padding: 10px 16px; font-variant-numeric: tabular-nums; }

/* ---------- promo banner ---------- */
.promo {
  display: flex; align-items: center; justify-content: space-between; gap: 32px;
  background:
    radial-gradient(700px 320px at 85% 20%, rgba(240, 185, 11, .13), transparent 65%),
    linear-gradient(120deg, var(--surface-2), var(--surface));
  border-radius: var(--r-lg); padding: 40px 44px; margin-bottom: 24px;
  box-shadow: var(--shadow); overflow: hidden; position: relative;
}
.promo-copy { max-width: 560px; }
.promo-tag {
  display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--accent); background: rgba(240, 185, 11, .1);
  padding: 5px 10px; border-radius: 6px; margin-bottom: 14px;
}
.promo h1 {
  font-size: clamp(1.6rem, 3.4vw, 2.5rem); font-weight: 800; line-height: 1.08;
  letter-spacing: -.02em; text-wrap: balance; margin-bottom: 12px;
}
.promo p { color: var(--muted); line-height: 1.55; max-width: 46ch; text-wrap: pretty; }
.pool-chip {
  display: inline-flex; align-items: baseline; gap: 10px; margin-top: 20px;
  background: var(--surface); border-radius: var(--r-md); padding: 12px 18px;
  box-shadow: inset 0 0 0 1px var(--line);
}
.pool-label { font-size: .78rem; color: var(--muted); font-weight: 500; }
.pool-amount { font-size: 1.25rem; font-weight: 800; color: var(--accent-hot); font-variant-numeric: tabular-nums; }
.promo-coin { flex-shrink: 0; }
.promo-coin-disc {
  width: 150px; height: 150px; border-radius: 50%; display: grid; place-items: center;
  font-size: 3.6rem; font-weight: 800; color: var(--accent-ink);
  background: radial-gradient(circle at 35% 30%, #ffe9a0, var(--accent) 72%);
  box-shadow: 0 18px 50px rgba(240, 185, 11, .3), inset 0 -8px 18px rgba(120, 80, 0, .35);
  transform: rotate(-8deg);
  cursor: grab; touch-action: none; user-select: none; will-change: transform;
}
.promo-coin-disc.grabbed { cursor: grabbing; box-shadow: 0 22px 60px rgba(240, 185, 11, .45), inset 0 -8px 18px rgba(120, 80, 0, .35); }
@media (max-width: 760px) { .promo-coin { display: none; } .promo { padding: 32px 28px; } }

/* ---------- game panel ---------- */
.game { background: var(--surface); border-radius: var(--r-lg); padding: 24px; box-shadow: var(--shadow); }
.game-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px; margin-bottom: 18px; }
.game-head h2 { font-size: 1.15rem; font-weight: 700; letter-spacing: -.01em; }
.create-controls { display: flex; gap: 10px; align-items: center; }
.side-toggle { display: flex; background: var(--surface-2); border-radius: 10px; padding: 3px; }
.side-btn {
  background: none; border: none; color: var(--muted); padding: 8px 16px; border-radius: 8px;
  cursor: pointer; font-family: inherit; font-weight: 600; font-size: .88rem; transition: all .2s;
}
.side-btn.active { background: var(--surface-3); color: var(--text); }

/* streak tracker */
.streak-strip {
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
  background:
    radial-gradient(420px 160px at 12% 50%, rgba(240, 185, 11, .12), transparent 70%),
    var(--surface-2);
  border-radius: var(--r-md); padding: 22px 26px; margin-bottom: 18px;
  box-shadow: inset 0 0 0 1px rgba(240, 185, 11, .18);
}
.streak-left { display: flex; align-items: baseline; gap: 14px; }
.streak-label { font-size: .8rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .12em; }
.streak-num {
  font-size: 2.8rem; font-weight: 800; color: var(--accent-hot);
  font-variant-numeric: tabular-nums; line-height: 1;
  text-shadow: 0 0 24px rgba(240, 185, 11, .35);
}
.streak-pips { display: flex; gap: 7px; flex: 1; min-width: 220px; }
.pip { flex: 1; max-width: 44px; height: 12px; border-radius: 6px; background: var(--surface-3); transition: all .3s; }
.pip.lit { background: linear-gradient(90deg, var(--accent), var(--accent-hot)); box-shadow: 0 0 12px rgba(240, 185, 11, .55); }
.streak-hint { font-size: .82rem; color: var(--muted); }

/* flip lobby rows */
.flip-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.flip-list .empty { color: var(--muted); padding: 44px 20px; text-align: center; background: var(--surface-2); border-radius: var(--r-md); }
.flip-item {
  display: flex; justify-content: space-between; align-items: center; gap: 14px;
  background: var(--surface-2); border-radius: var(--r-md); padding: 14px 18px;
  transition: background .2s, transform .2s;
  animation: rise .3s ease both;
}
.flip-item:hover { background: var(--surface-3); transform: translateY(-1px); }
.flip-item.mine { box-shadow: inset 3px 0 0 var(--accent); }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }
.flip-meta { display: flex; align-items: center; gap: 14px; min-width: 0; }
.flip-avatar {
  width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center;
  font-weight: 700; font-size: .8rem; color: var(--accent-ink); flex-shrink: 0;
  background: linear-gradient(145deg, var(--accent-hot), var(--accent));
}
.flip-item .who { font-weight: 600; font-variant-numeric: tabular-nums; }
.flip-item .side-tag { font-size: .8rem; color: var(--muted); }
.flip-item .hash { font-size: .68rem; color: #4a5266; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }

/* ---------- sidebar cards ---------- */
.sidebar { display: flex; flex-direction: column; gap: 20px; }
.card { background: var(--surface); border-radius: var(--r-lg); padding: 22px; box-shadow: var(--shadow); }
.card h3 { font-size: .95rem; font-weight: 700; margin-bottom: 14px; }
.stat-row {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 7px 0; font-size: .9rem; font-variant-numeric: tabular-nums;
}
.stat-row span { color: var(--muted); }
.stat-row.big b { color: var(--accent-hot); font-size: 1.05rem; font-weight: 700; }
.stat-divider { height: 1px; background: var(--line); margin: 8px 0; }

.board { list-style: none; counter-reset: rank; }
.board li {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 0; font-size: .88rem; font-variant-numeric: tabular-nums;
}
.board li + li { border-top: 1px solid var(--line); }
.board li::before {
  counter-increment: rank; content: counter(rank);
  color: var(--muted); font-size: .75rem; font-weight: 700;
  width: 22px; height: 22px; border-radius: 6px; background: var(--surface-2);
  display: inline-grid; place-items: center; margin-right: 10px; flex-shrink: 0;
}
.board li > span:first-of-type { margin-right: auto; }
.board .lb-units { color: var(--accent-hot); font-weight: 700; }
.crown { margin-left: 5px; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line); margin-top: 40px; position: relative; z-index: 2; }
.footer-inner { max-width: 720px; margin: 0 auto; padding: 36px 24px 48px; color: var(--muted); font-size: .85rem; line-height: 1.65; }
.footer-inner b { color: var(--text); }
.footer-fine { margin-top: 10px; font-size: .78rem; color: #4a5266; }

/* ---------- modal + coin ---------- */
.modal {
  position: fixed; inset: 0; z-index: var(--z-modal);
  background: rgba(6, 8, 13, .78); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
}
.modal.hidden, .toast.hidden { display: none; }
.modal-card {
  background: var(--surface); border-radius: 20px; padding: 44px;
  text-align: center; max-width: 620px; width: 94%; box-shadow: var(--shadow);
  animation: rise .25s ease both;
}
.coin-stage { perspective: 1400px; height: 250px; display: flex; justify-content: center; align-items: center; margin-bottom: 22px; }
.coin { position: relative; width: 225px; height: 225px; transform-style: preserve-3d; }
.coin.spin-heads { animation: spinHeads 2.2s cubic-bezier(.2, .7, .3, 1) forwards; }
.coin.spin-tails { animation: spinTails 2.2s cubic-bezier(.2, .7, .3, 1) forwards; }
@keyframes spinHeads { from { transform: rotateY(0); } to { transform: rotateY(1800deg); } }
@keyframes spinTails { from { transform: rotateY(0); } to { transform: rotateY(1980deg); } }
.coin-face {
  position: absolute; inset: 0; border-radius: 50%; display: grid; place-items: center;
  font-size: 5.5rem; font-weight: 800; color: var(--accent-ink); backface-visibility: hidden;
  background: radial-gradient(circle at 35% 30%, #ffe9a0, var(--accent) 72%);
  box-shadow: 0 0 70px rgba(240, 185, 11, .45), inset 0 -10px 26px rgba(120, 80, 0, .4);
}
.coin-tails {
  transform: rotateY(180deg);
  background: radial-gradient(circle at 35% 30%, var(--surface-3), var(--surface-2) 72%);
  box-shadow: 0 0 50px rgba(35, 43, 61, .8), inset 0 -10px 26px rgba(0, 0, 0, .4);
}
.modal-result { font-size: 2.2rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; }
.modal-result.win { color: var(--green); }
.modal-result.lose { color: var(--red); }
.modal-result.jackpot { color: var(--accent-hot); }
.modal-detail { color: var(--muted); margin-bottom: 14px; line-height: 1.55; font-size: 1rem; }
.modal-fair { font-size: .64rem; color: #4a5266; word-break: break-all; margin-bottom: 18px; font-variant-numeric: tabular-nums; }

/* ---------- advanced (full-page) coinflip ---------- */
.container.wide { max-width: none; }
@media (min-width: 1241px) { .container.wide { margin-left: 328px; margin-right: 12px; } }
.container.wide .game { min-height: calc(100dvh - 175px); }
.container.wide .game-head { gap: 18px; }
.container.wide .streak-strip { padding: 28px 32px; }
.container.wide .streak-num { font-size: 3.4rem; }
.container.wide .streak-pips { min-width: 320px; }
.container.wide .pip { max-width: 64px; height: 14px; }
.container.wide .flip-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 10px; }
.container.wide .flip-list .empty { grid-column: 1 / -1; padding: 90px 20px; }
.pool-chip.slim { margin: 0 auto 0 0; padding: 8px 14px; }
.pool-chip.slim .pool-amount { font-size: 1rem; }
.stats-strip { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }
.ministat {
  display: flex; align-items: baseline; gap: 9px;
  background: var(--surface-2); border-radius: 10px; padding: 10px 16px;
  font-size: .88rem; font-variant-numeric: tabular-nums;
}
.ministat span { color: var(--muted); font-size: .78rem; }
.ministat b { font-weight: 700; }
.ministat.gold b { color: var(--accent-hot); }
@media (max-width: 1240px) { .container.wide .chat { margin-top: 20px; } }

/* ---------- flash airdrop giveaway ---------- */
.giveaway {
  text-align: center;
  background:
    radial-gradient(320px 180px at 50% 0%, rgba(240, 185, 11, .14), transparent 70%),
    var(--surface);
  box-shadow: var(--shadow), inset 0 0 0 1px rgba(240, 185, 11, .22);
}
.giveaway .promo-tag { margin-bottom: 12px; }
.giveaway-prize { display: flex; flex-direction: column; gap: 2px; margin-bottom: 10px; }
.giveaway-prize b {
  font-size: 2.3rem; font-weight: 800; color: var(--accent-hot); line-height: 1.1;
  font-variant-numeric: tabular-nums; text-shadow: 0 0 26px rgba(240, 185, 11, .35);
}
.giveaway-prize span { font-size: .82rem; color: var(--muted); }
.giveaway-count { font-size: .85rem; color: var(--muted); margin-bottom: 14px; font-variant-numeric: tabular-nums; }
.giveaway-btn { width: 100%; }
.giveaway-timer { font-size: .82rem; color: var(--muted); margin-top: 12px; font-variant-numeric: tabular-nums; }
.giveaway-winner { font-size: .78rem; color: #4a5266; margin-top: 6px; font-variant-numeric: tabular-nums; }
/* winner roller (case-opening style) */
.giveaway-roller {
  position: relative; overflow: hidden; height: 56px; margin-bottom: 14px;
  border-radius: 10px; background: var(--surface-2);
}
.giveaway-roller.hidden { display: none; }
.roller-marker {
  position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; z-index: 2;
  background: var(--accent-hot); box-shadow: 0 0 10px rgba(240, 185, 11, .8);
}
.roller-track { display: flex; gap: 8px; padding: 10px 0 10px 8px; will-change: transform; }
.roller-tile {
  flex: 0 0 84px; height: 36px; border-radius: 8px; background: var(--surface-3);
  display: grid; place-items: center; font-size: .7rem; font-weight: 600;
  color: var(--muted); font-variant-numeric: tabular-nums; transition: background .3s, color .3s;
}
.roller-tile.landed {
  background: linear-gradient(145deg, var(--accent-hot), var(--accent));
  color: var(--accent-ink);
  animation: landedFlash .5s ease 2;
}
@keyframes landedFlash { 50% { box-shadow: 0 0 22px rgba(240, 185, 11, .9); } }

/* wide screens: float in the free right margin, mirroring the chat rail
   (the airdrop page's hero version stays in the page flow) */
@media (min-width: 1904px) {
  .giveaway:not(.giveaway-hero) { position: fixed; right: 20px; top: 116px; width: 300px; z-index: 4; }
  .container.wide { margin-right: 340px; }
}

/* ---------- dedicated airdrop page ---------- */
.airdrop-page { max-width: 720px; display: flex; flex-direction: column; gap: 20px; }
.giveaway-hero { padding: 44px 40px; }
.giveaway-hero .giveaway-prize b { font-size: 4.4rem; }
.giveaway-hero .giveaway-prize span { font-size: 1rem; }
.giveaway-hero .giveaway-timer { font-size: 1.15rem; color: var(--text); margin: 6px 0 18px; }
.giveaway-hero .giveaway-btn { max-width: 320px; margin: 0 auto; display: block; padding: 14px 28px; font-size: 1.05rem; }
.giveaway-hero .giveaway-count { margin: 14px 0 10px; }
.giveaway-hero .giveaway-roller { height: 66px; margin: 0 0 18px; }
.giveaway-hero .roller-track { padding-top: 15px; }
.giveaway-hero .giveaway-winner { margin-top: 14px; font-size: .85rem; }
.entrants { list-style: none; display: flex; flex-wrap: wrap; gap: 7px; justify-content: center; }
.entrants:empty::after { content: "No entries yet — be the first in."; color: #4a5266; font-size: .82rem; }
.ent {
  background: var(--surface-2); border-radius: 999px; padding: 5px 12px;
  font-size: .78rem; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums;
}
.ent.mine { background: rgba(240, 185, 11, .14); color: var(--accent-hot); }
.airdrop-how h3 { margin-bottom: 12px; }
.airdrop-how ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.airdrop-how li { color: var(--muted); line-height: 1.6; padding-left: 18px; position: relative; }
.airdrop-how li::before { content: ""; position: absolute; left: 0; top: .55em; width: 7px; height: 7px; border-radius: 2px; background: var(--accent); }
.airdrop-how b { color: var(--text); }

/* ---------- chat moderation + admin panel ---------- */
.chat-msg.admin .chat-who { color: var(--red); }
.chat-mod { display: inline-flex; gap: 3px; margin-left: 6px; vertical-align: middle; }
.chat-mod-btn {
  background: var(--surface-3); border: none; color: var(--muted); cursor: pointer;
  font-size: .68rem; line-height: 1; padding: 3px 6px; border-radius: 5px; font-family: inherit;
}
.chat-mod-btn:hover { color: var(--text); background: var(--line); }

.admin-panel {
  position: fixed; right: 20px; bottom: 20px; width: 270px; z-index: 90;
  background: var(--surface); border-radius: var(--r-md);
  box-shadow: var(--shadow), inset 0 0 0 1px var(--red);
  font-size: .85rem;
}
.admin-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 14px; border-bottom: 1px solid var(--line);
}
.admin-head b { color: var(--red); letter-spacing: .04em; }
.admin-head button { background: none; border: none; color: var(--muted); cursor: pointer; font-size: 1.1rem; line-height: 1; }
.admin-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 14px; }
.admin-body.hidden { display: none; }
.admin-sec { display: flex; flex-direction: column; gap: 8px; }
.admin-label { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.admin-row { display: flex; align-items: center; gap: 8px; }
.admin-row input {
  width: 84px; background: var(--surface-2); border: none; border-radius: 8px;
  padding: 7px 10px; color: var(--text); font-family: inherit; font-size: .85rem;
}
#adminMint { flex: 1; width: auto; min-width: 0; font-size: .68rem; font-variant-numeric: tabular-nums; }
.admin-row .btn { padding: 7px 12px; font-size: .82rem; }
.admin-unit { color: var(--muted); font-size: .78rem; }
.admin-toggle { display: flex; align-items: center; gap: 8px; color: var(--muted); cursor: pointer; }
.admin-mutes { list-style: none; display: flex; flex-direction: column; gap: 5px; }
.admin-mutes li { display: flex; justify-content: space-between; align-items: center; font-variant-numeric: tabular-nums; }
.admin-mutes:empty::after { content: "none"; color: #4a5266; }

/* ---------- leaderboard page: streak race ---------- */
.lb-page { max-width: 1000px; }
.lb-head { margin: 16px 0 24px; }
.lb-head h1 { font-size: 2.1rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; }
.lb-head p { color: var(--muted); max-width: 52ch; line-height: 1.6; }
.lb-head b { color: var(--accent-hot); }
.lb-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 860px) { .lb-grid { grid-template-columns: 1fr; } }
.streak-board { list-style: none; counter-reset: srank; display: flex; flex-direction: column; gap: 9px; }
.sb-row {
  display: flex; align-items: center; gap: 14px;
  background: var(--surface-2); border-radius: var(--r-md); padding: 13px 16px;
}
.sb-row::before {
  counter-increment: srank; content: counter(srank);
  color: var(--muted); font-size: .75rem; font-weight: 700;
  width: 24px; height: 24px; border-radius: 7px; background: var(--surface-3);
  display: inline-grid; place-items: center; flex-shrink: 0;
}
.sb-row:first-child::before { background: linear-gradient(145deg, var(--accent-hot), var(--accent)); color: var(--accent-ink); }
.sb-row.mine { box-shadow: inset 0 0 0 1px rgba(240, 185, 11, .45); }
.sb-wallet { font-weight: 600; min-width: 96px; font-variant-numeric: tabular-nums; }
.sb-bar { flex: 1; height: 10px; border-radius: 5px; background: var(--surface-3); overflow: hidden; }
.sb-fill {
  height: 100%; border-radius: 5px;
  background: linear-gradient(90deg, var(--accent), var(--accent-hot));
  box-shadow: 0 0 10px rgba(240, 185, 11, .5); transition: width .4s ease;
}
.sb-count { font-weight: 800; color: var(--accent-hot); font-variant-numeric: tabular-nums; min-width: 44px; text-align: right; }
.sb-of { color: var(--muted); font-weight: 500; font-size: .78em; }
.sb-empty { color: var(--muted); padding: 36px 20px; text-align: center; background: var(--surface-2); border-radius: var(--r-md); }

/* ---------- content pages ---------- */
.page article { max-width: 720px; margin: 0 auto; padding: 24px 0 60px; }
.page h1 { font-size: 2.1rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; text-wrap: balance; }
.page .updated { font-size: .8rem; color: #4a5266; margin-bottom: 28px; }
.page h2 { font-size: 1.15rem; font-weight: 700; margin: 30px 0 10px; }
.page p, .page li { color: var(--muted); line-height: 1.7; margin-bottom: 12px; max-width: 65ch; }
.page ul, .page ol { padding-left: 22px; margin-bottom: 12px; }
.page code { background: var(--surface-2); padding: 2px 7px; border-radius: 5px; font-size: .85em; color: var(--accent-hot); }
.page article b, .page article strong { color: var(--text); }
.post { background: var(--surface); border-radius: var(--r-lg); padding: 26px 28px; margin-bottom: 18px; box-shadow: var(--shadow); }
.post h2 { margin-top: 0; }
.post .post-date { font-size: .78rem; color: #4a5266; margin-bottom: 10px; }

/* ---------- toast ---------- */
.toast {
  position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%); z-index: var(--z-toast);
  background: var(--surface-3); color: var(--text);
  padding: 12px 22px; border-radius: var(--r-md); font-size: .9rem;
  box-shadow: var(--shadow), inset 0 0 0 1px var(--line);
  animation: rise .25s ease both;
}
