/* Default Donut — Red & Black Frixion-Style Dark Theme */
:root {
  --bg-deepest: #09090b;
  --bg-secondary: #111114;
  --bg-primary: #16161a;
  --bg-tertiary: #0d0d10;
  --bg-floating: #101013;
  --bg-input: #1d1d22;

  --bg-0: var(--bg-deepest);
  --bg-1: var(--bg-secondary);
  --bg-2: var(--bg-primary);
  --surface-1: var(--bg-secondary);
  --surface-2: var(--bg-primary);
  --surface-3: #1e1e24;
  --surface: var(--surface-1);
  --surface-input: var(--bg-input);

  --accent: #dc2626;
  --accent-hover: #b91c1c;
  --accent-bright: #ef4444;
  --accent-deep: #7f1d1d;
  --accent-soft: rgba(220, 38, 38, 0.16);
  --accent-line: rgba(239, 68, 68, 0.4);
  --accent-glow: rgba(220, 38, 38, 0.25);

  /* Legacy token aliases mapped cleanly to Default Donut Red */
  --purple: var(--accent);
  --purple-vivid: var(--accent);
  --purple-bright: var(--accent-bright);
  --purple-deep: var(--accent-deep);
  --purple-soft: var(--accent-soft);
  --purple-line: var(--accent-line);
  --purple-glow: var(--accent-glow);
  --crimson: var(--accent);
  --crimson-bright: var(--accent-bright);
  --crimson-deep: var(--accent-deep);
  --crimson-soft: var(--accent-soft);
  --crimson-line: var(--accent-line);

  --divider: rgba(255, 255, 255, 0.07);
  --line: rgba(255, 255, 255, 0.07);
  --line-strong: rgba(255, 255, 255, 0.13);

  --text: #f4f4f5;
  --text-dim: #d4d4d8;
  --text-muted: #9ca3af;
  --text-faint: #6b7280;

  --win: #22c55e;
  --win-bg: rgba(34, 197, 94, 0.14);
  --lose: #ef4444;
  --lose-bg: rgba(239, 68, 68, 0.14);
  --gold: #f0b132;
  --discord: #5865f2;

  --radius-sm: 7px;
  --radius-md: 9px;
  --radius-lg: 11px;
  --radius: var(--radius-lg);
  --shadow-card: 0 2px 10px rgba(0, 0, 0, 0.35);
  --shadow-purple: 0 4px 14px rgba(0, 0, 0, 0.4);
  --shadow-crimson: var(--shadow-purple);

  --font-ui: 'Inter', system-ui, -apple-system, sans-serif;
  --font-display: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { color-scheme: dark; scroll-behavior: smooth; max-width: 100%; overflow-x: clip; }
body {
  min-height: 100vh;
  max-width: 100%;
  background: var(--bg-deepest);
  color: var(--text);
  font-family: var(--font-ui);
  line-height: 1.5;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { font-family: var(--font-display); letter-spacing: -0.02em; }
button, input, select { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
.hidden { display: none !important; }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.bg-aura, .aura-orb { display: none !important; }

/* ==================== TOPBAR & SUBBAR ==================== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(12, 12, 15, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.13);
  box-shadow: 0 6px 24px rgba(9, 9, 12, 0.42);
}
.topbar-inner {
  width: 100%;
  max-width: 1840px;
  margin: 0 auto;
  height: 60px;
  padding: 0 clamp(10px, 1.6vw, 22px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(8px, 1vw, 14px);
}
.topbar-left, .topbar-right {
  display: flex;
  align-items: center;
  gap: clamp(6px, 0.8vw, 10px);
  min-width: 0;
  white-space: nowrap;
}
.topbar-left { flex: 1 1 0; min-width: 0; overflow: hidden; }
.topbar-right { flex-shrink: 0; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding-right: 4px;
  flex-shrink: 0;
}
.brand-coin-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.brand-coin {
  width: 34px;
  height: 34px;
  border-radius: 0;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(220, 38, 38, 0.5));
  transition: transform 0.22s cubic-bezier(0.2, 0.9, 0.3, 1.2), filter 0.22s ease;
  flex-shrink: 0;
}
.brand:hover .brand-coin {
  transform: scale(1.07) rotate(-5deg);
  filter: drop-shadow(0 0 14px rgba(239, 68, 68, 0.78));
}
.brand-wordmark {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  color: #fff;
}
.brand-wordmark span {
  color: var(--purple-bright);
  text-shadow: 0 0 14px rgba(239, 68, 68, 0.42);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 1 1 auto;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.main-nav::-webkit-scrollbar { display: none; }
.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.87rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.nav-link:hover, .nav-link.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}
.nav-link.active { color: var(--crimson-bright); background: var(--crimson-soft); }
.nav-admin { color: var(--gold) !important; }

.nav-dropdown, .user-menu { position: relative; flex-shrink: 0; }
.drop-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 230px;
  padding: 7px;
  border-radius: var(--radius-md);
  background: rgba(20, 20, 23, 0.97);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 18px 44px rgba(9, 9, 12, 0.78);
  display: none;
  flex-direction: column;
  gap: 2px;
  z-index: 120;
}
.drop-menu.open { display: flex; }
.user-drop { left: auto; right: 0; min-width: 220px; }
.wallet-drop { left: auto; right: -42px; min-width: 235px; }
.wd-exact {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 11px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.035);
}
.wd-exact .muted { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; }
.wd-exact strong { font-size: 0.92rem; color: #fff; word-break: break-all; }
.drop-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 11px;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text);
  font-size: 0.87rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.14s, color 0.14s;
}
.drop-item:hover { background: var(--crimson-soft); color: #fff; }
.drop-item svg { color: var(--crimson-bright); flex-shrink: 0; }
.drop-item.danger { color: #ff6b76; }
.drop-sep { height: 1px; background: var(--line); margin: 4px 2px; }

/* Bot status pill */
.bot-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 11px;
  border-radius: 999px;
  background: rgba(24, 24, 27, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}
.bot-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.bot-dot.online { background: var(--win); box-shadow: 0 0 10px var(--win); }
.bot-dot.offline { background: var(--lose); box-shadow: 0 0 8px rgba(244, 63, 94, 0.55); }

/* Clean Unified Obsidian-Violet Balance + Wallet Pill */
.dl-wallet {
  display: inline-flex;
  align-items: stretch;
  height: 38px;
  border-radius: 10px;
  background: rgba(18, 18, 21, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 4px 14px rgba(9, 9, 12, 0.42);
  flex-shrink: 0;
}
.dl-bal-wrap {
  position: relative;
  display: flex;
  align-items: stretch;
}
.dl-bal-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 11px 0 9px;
  border: 0;
  border-radius: 9px 0 0 9px;
  background: transparent;
  color: #fff;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.14s ease;
}
.dl-bal-btn:hover { background: rgba(220, 38, 38, 0.1); }
.dl-chev { color: var(--text-muted); flex-shrink: 0; }
.dl-wallet-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  margin: -1px -1px -1px 0;
  border: 0;
  border-radius: 0 10px 10px 0;
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  color: #fff;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.24), 0 0 16px rgba(220, 38, 38, 0.25);
  transition: filter 0.14s ease, box-shadow 0.14s ease;
}
.dl-wallet-btn:hover { filter: brightness(1.12); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 0 20px rgba(220, 38, 38, 0.4); }
.dl-wallet-btn:active { filter: brightness(0.95); }

.coin-ico { width: 22px; height: 22px; border-radius: 0; object-fit: contain; flex-shrink: 0; filter: drop-shadow(0 1px 4px rgba(178, 86, 255, 0.35)); }
.coin-ico.sm { width: 18px; height: 18px; }
.coin-ico.lg { width: 36px; height: 36px; filter: drop-shadow(0 2px 12px rgba(178, 86, 255, 0.48)); }
.bal-val {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.92rem;
  letter-spacing: -0.02em;
  color: #fff;
  transition: color 0.18s ease;
}
.bal-val.bal-up { animation: balPopUp 0.36s ease; }
.bal-val.bal-down { animation: balPopDown 0.32s ease; }
@keyframes balPopUp {
  0% { color: var(--win); transform: scale(1.06); }
  100% { color: #fff; transform: scale(1); }
}
@keyframes balPopDown {
  0% { color: #ff6b78; transform: scale(0.97); }
  100% { color: #fff; transform: scale(1); }
}
.creator-tag {
  font-size: 0.62rem;
  font-weight: 800;
  padding: 2px 5px;
  border-radius: 5px;
  background: rgba(245, 184, 46, 0.18);
  color: var(--gold);
  letter-spacing: 0.4px;
}

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 9px 4px 5px;
  height: 38px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  transition: border-color 0.15s, background 0.15s;
}
.user-chip:hover { border-color: rgba(255, 255, 255, 0.22); background: var(--surface-3); }
.user-name {
  max-width: 112px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.user-avatar {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: linear-gradient(135deg, var(--crimson), var(--crimson-deep));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.78rem;
  color: #fff;
  flex-shrink: 0;
}

/* Secondary Quick-Jump Game Strip */
.subbar {
  background: rgba(11, 11, 14, 0.92);
  border-top: 1px solid rgba(255, 255, 255, 0.045);
}
.subbar-inner {
  width: 100%;
  max-width: 1840px;
  margin: 0 auto;
  padding: 0 clamp(10px, 1.6vw, 22px);
  height: 40px;
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.subbar-inner::-webkit-scrollbar { display: none; }
.strip-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 7px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
  transition: color 0.14s, background 0.14s;
}
.strip-link:hover { color: #fff; background: rgba(255, 255, 255, 0.06); }
.strip-link.active { color: #fff; background: var(--crimson-soft); }
.strip-link svg { width: 14px; height: 14px; color: var(--crimson-bright); flex-shrink: 0; }

/* ==================== BUTTONS & INPUTS ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  transition: transform 0.14s, filter 0.14s, background 0.14s, border-color 0.14s, box-shadow 0.14s;
  white-space: nowrap;
}
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:disabled { opacity: 0.48; cursor: not-allowed; filter: none; }
.btn-primary {
  background: linear-gradient(135deg, var(--crimson) 0%, #991b1b 100%);
  color: #fff;
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.32);
}
.btn-primary:hover:not(:disabled) {
  filter: brightness(1.12);
  box-shadow: 0 6px 22px rgba(239, 68, 68, 0.45);
  transform: translateY(-1px);
}
.btn-win {
  background: linear-gradient(135deg, #17b96f, #0f8a52);
  color: #fff;
  box-shadow: 0 4px 16px rgba(23, 185, 111, 0.3);
}
.btn-win:hover:not(:disabled) { filter: brightness(1.1); transform: translateY(-1px); }
.btn-ghost {
  background: rgba(255, 255, 255, 0.055);
  border-color: var(--line-strong);
  color: var(--text);
}
.btn-ghost:hover:not(:disabled) { background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.22); }
.btn-danger {
  background: rgba(255, 45, 65, 0.15);
  border-color: rgba(255, 45, 65, 0.38);
  color: #ff7a85;
}
.btn-danger:hover:not(:disabled) { background: rgba(255, 45, 65, 0.26); color: #fff; }
.btn-sm { padding: 7px 13px; font-size: 0.83rem; }
.btn-xs { padding: 5px 10px; font-size: 0.78rem; }
.btn-block { width: 100%; }
.btn-link { background: none; border: 0; color: var(--crimson-bright); font-weight: 600; font-size: 0.86rem; cursor: pointer; }
.btn-link:hover { text-decoration: underline; }
.btn-row-wrap { display: flex; gap: 8px; flex-wrap: wrap; }

.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}
.icon-btn:hover { background: var(--surface-3); color: #fff; }
.icon-btn.sm { width: 28px; height: 28px; font-size: 1.15rem; }

.field-lbl {
  display: block;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin: 10px 0 5px;
}
.text-input, .select-input {
  width: 100%;
  min-width: 0;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--surface-input);
  border: 1px solid var(--line-strong);
  color: #fff;
  font-size: 0.92rem;
  font-weight: 600;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.text-input:focus, .select-input:focus {
  border-color: var(--crimson-bright);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.18);
}
.text-input:disabled, .select-input:disabled { opacity: 0.5; cursor: not-allowed; }
.inline-form { display: flex; gap: 8px; align-items: center; }
.inline-form > input { flex: 1; min-width: 0; }

/* ==================== MAIN SHELL & CHAT DRAWER ==================== */
.app-shell {
  position: relative;
  display: flex;
  width: 100%;
  min-height: calc(100dvh - 102px);
}
.main-col {
  flex: 1;
  width: 100%;
  min-width: 0;
  max-width: 1560px;
  margin: 0 auto;
  padding: clamp(14px, 2vw, 24px) clamp(12px, 2vw, 26px) 64px;
  container-type: inline-size;
  container-name: maincol;
}

.chat-drawer {
  width: 304px;
  flex-shrink: 0;
  position: sticky;
  top: 102px;
  height: calc(100dvh - 102px);
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #111114 0%, #09090b 100%);
  border-left: 1px solid var(--line);
  transition: width 0.2s ease, opacity 0.18s ease, transform 0.2s ease;
  overflow: hidden;
}
.chat-drawer.collapsed {
  width: 0;
  border-left-width: 0;
  opacity: 0;
  pointer-events: none;
}
.chat-head {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.chat-title-wrap { display: flex; align-items: center; gap: 8px; }
.chat-title { font-weight: 700; font-size: 0.92rem; letter-spacing: -0.01em; }
.chat-online {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.74rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 8px;
  border-radius: 999px;
}
.online-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--win); }

.rain-card {
  margin: 10px 12px 6px;
  padding: 11px 12px;
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, rgba(220, 38, 38, 0.18), rgba(21, 21, 24, 0.96));
  border: 1px solid rgba(239, 68, 68, 0.22);
  flex-shrink: 0;
}
.rain-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.rain-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: 0.8rem;
  color: #fff;
}
.rain-badge svg { color: var(--crimson-bright); }
.rain-timer { font-family: var(--font-mono); font-size: 0.78rem; color: var(--gold); font-weight: 700; }
.rain-pot { display: flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 1.02rem; font-weight: 700; margin-bottom: 8px; }
.rain-unit { font-family: var(--font-ui); font-size: 0.73rem; color: var(--text-muted); font-weight: 600; }
.rain-actions { display: flex; gap: 6px; }
.rain-actions .btn { width: 100%; }

.chat-messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.14) transparent;
}
.chat-empty { color: var(--text-faint); font-size: 0.82rem; text-align: center; padding: 28px 10px; }
.chat-msg {
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.82rem;
  line-height: 1.4;
  cursor: pointer;
  transition: background 0.14s, border-color 0.14s;
  word-break: break-word;
}
.chat-msg:hover { background: var(--crimson-soft); border-color: var(--crimson-line); }
.chat-msg.system-msg { cursor: default; }
.chat-msg.system-msg:hover { background: linear-gradient(135deg, rgba(245, 184, 46, 0.13), rgba(220, 38, 38, 0.1)); border-color: rgba(245, 184, 46, 0.28); }
.chat-msg.tip-msg {
  background: linear-gradient(135deg, rgba(245, 184, 46, 0.13), rgba(220, 38, 38, 0.1));
  border-color: rgba(245, 184, 46, 0.28);
}
.chat-msg.pending { opacity: 0.72; }
.chat-user { font-weight: 700; color: #fff; margin-right: 5px; }
.role-badge {
  font-size: 0.62rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 4px;
  margin-right: 5px;
  text-transform: uppercase;
  vertical-align: middle;
}
.role-badge.admin { background: var(--crimson); color: #fff; }
.role-badge.mod { background: var(--gold); color: #000; }
.chat-tip-hint {
  padding: 6px 12px;
  font-size: 0.72rem;
  color: var(--text-faint);
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.chat-tip-hint svg { flex-shrink: 0; color: var(--text-muted); }
.chat-form {
  padding: 10px 12px;
  display: flex;
  gap: 6px;
  border-top: 1px solid var(--line);
  flex-shrink: 0;
}
.chat-form input {
  flex: 1;
  min-width: 0;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: var(--surface-input);
  border: 1px solid var(--line-strong);
  font-size: 0.84rem;
  outline: none;
}
.chat-form input:focus { border-color: var(--crimson-bright); }

.chat-fab {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 85;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: #141418;
  color: #fff;
  font-weight: 700;
  font-size: 0.84rem;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.65);
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s;
}
.chat-fab svg { color: var(--crimson-bright); }
.chat-fab:hover { transform: translateY(-2px); border-color: var(--crimson-line); }

/* ==================== HOMEPAGE ==================== */
.hero-grid {
  display: grid;
  grid-template-columns: 1.95fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}
.hero-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: clamp(22px, 2.6vw, 30px) clamp(20px, 2.8vw, 32px);
  background:
    radial-gradient(circle at 88% 50%, rgba(220, 38, 38, 0.2), transparent 54%),
    linear-gradient(145deg, #16161a 0%, #111114 56%, #0d0d10 100%);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), var(--shadow-card);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.hero-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 520px;
}
.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--purple-bright);
}
.kicker-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--crimson-bright);
  box-shadow: 0 0 8px var(--crimson-bright);
}
.hero-card h1 {
  font-size: clamp(1.65rem, 3vw, 2.32rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
  color: #fff;
}
.hero-card h1 span {
  background: linear-gradient(95deg, #ef4444 0%, #dc2626 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-desc { color: var(--text-muted); font-size: 0.91rem; line-height: 1.58; }
.hero-desc code {
  font-family: var(--font-mono);
  font-size: 0.84rem;
  padding: 1px 6px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
}
.hero-actions { display: flex; gap: 9px; flex-wrap: wrap; align-items: center; margin-top: 4px; }

.hero-emblem {
  position: relative;
  width: 146px;
  height: 146px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-emblem-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid rgba(239, 68, 68, 0.24);
  background: radial-gradient(circle, rgba(162, 74, 240, 0.18), rgba(220, 38, 38, 0.08) 48%, transparent 72%);
}
.hero-emblem-coin {
  width: 122px;
  height: 122px;
  border-radius: 0;
  object-fit: contain;
  filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.6)) drop-shadow(0 0 18px rgba(178, 86, 255, 0.34));
}

.discord-card {
  border-radius: var(--radius-lg);
  padding: 22px 22px;
  background: linear-gradient(160deg, #161029 0%, #0e091d 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), var(--shadow-card);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}
.discord-top { display: flex; align-items: flex-start; gap: 12px; }
.discord-ico {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  flex-shrink: 0;
  background: rgba(220, 38, 38, 0.14);
  border: 1px solid rgba(239, 68, 68, 0.24);
  color: var(--crimson-bright);
  display: flex;
  align-items: center;
  justify-content: center;
}
.discord-card h2 {
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}
.discord-card p { color: var(--text-muted); font-size: 0.84rem; line-height: 1.5; }
.discord-actions { display: flex; flex-direction: column; gap: 8px; }

.sec-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.sec-head h2 {
  font-size: 1.16rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.sec-head p, .sec-count { font-size: 0.78rem; color: var(--text-muted); font-weight: 600; }

/* Game Portrait Cards */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(176px, 1fr));
  gap: 14px;
  margin-bottom: 30px;
}
.game-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, #150e26 0%, #0f0a1c 100%);
  border: 1px solid rgba(255, 255, 255, 0.11);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.game-card:hover {
  transform: translateY(-3px);
  border-color: rgba(239, 68, 68, 0.42);
  box-shadow: 0 12px 26px rgba(9, 9, 12, 0.52), 0 0 18px rgba(220, 38, 38, 0.14);
}
.gc-art {
  position: relative;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 0%, rgba(220, 38, 38, 0.18), transparent 72%),
    linear-gradient(180deg, #19122e 0%, #100a1f 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.gc-svg {
  width: 100%;
  height: 100%;
  display: block;
  transition: transform 0.22s ease;
}
.game-card:hover .gc-svg, .game-card:hover .gc-coin-img { transform: scale(1.05); }
.gc-coin-wrap {
  width: 88px;
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gc-coin-img {
  width: 84px;
  height: 84px;
  border-radius: 0;
  object-fit: contain;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.52)) drop-shadow(0 0 14px rgba(178, 86, 255, 0.36));
  transition: transform 0.22s ease;
}
.gc-meta {
  padding: 12px 13px 13px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.gc-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.game-card-name { font-weight: 700; font-size: 0.94rem; color: #fff; letter-spacing: -0.01em; }
.gc-max {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 5px;
  background: rgba(220, 38, 38, 0.16);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #fecaca;
  white-space: nowrap;
}

/* Live Plays Table (Exact DonutLuck columns) */
.table-card {
  border-radius: var(--radius-lg);
  background: var(--surface-1);
  border: 1px solid var(--line-strong);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  margin-bottom: 34px;
}
.table-scroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.live-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.87rem;
}
.live-table th {
  text-align: left;
  padding: 12px 15px;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.28);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.live-table td {
  padding: 11px 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.045);
  vertical-align: middle;
  white-space: nowrap;
}
.live-table tr:last-child td { border-bottom: 0; }
.live-table tr:hover td { background: rgba(255, 255, 255, 0.025); }
.coin-cell { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-weight: 700; }
.mult-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.79rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
}
.mult-pill.win { background: var(--win-bg); color: var(--win); }
.payout-win { color: var(--win); }

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding-top: 26px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 24px;
  color: var(--text-muted);
  font-size: 0.84rem;
}
.site-footer h4 { color: #fff; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 8px; }
.footer-links { display: flex; flex-direction: column; gap: 6px; }
.footer-links a:hover { color: var(--crimson-bright); }
.footer-legal { grid-column: 1 / -1; padding-top: 14px; border-top: 1px solid var(--line); font-size: 0.76rem; color: var(--text-faint); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }

/* ==================== GAME FRAME & CONTROLS (DonutLuck x Frixion) ==================== */
.game-head {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.game-head h1 {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.1;
}
.game-head-desc { color: var(--text-muted); font-size: 0.88rem; }
.game-head-right { margin-left: auto; display: flex; align-items: center; gap: 10px; font-size: 0.82rem; color: var(--text-muted); }

.game-shell {
  display: grid;
  grid-template-columns: 312px 1fr;
  gap: 14px;
  align-items: start;
}
.game-panel {
  border-radius: var(--radius-lg);
  padding: 18px;
  background: var(--surface-1);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.game-stage {
  border-radius: var(--radius-lg);
  padding: 24px;
  min-height: 440px;
  background:
    radial-gradient(circle at 50% 30%, rgba(220, 38, 38, 0.12), transparent 64%),
    linear-gradient(180deg, #111114 0%, #0b0c10 100%);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.bet-row { display: flex; gap: 5px; }
.bet-row input { flex: 1; min-width: 0; }
.chip-btn {
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.14s, border-color 0.14s;
}
.chip-btn:hover:not(:disabled) { background: var(--crimson-soft); border-color: var(--crimson-bright); }
.chip-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.quick-row { display: flex; gap: 5px; flex-wrap: wrap; margin: 8px 0 4px; }

.seg-control {
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: var(--radius-sm);
  background: var(--surface-input);
  border: 1px solid var(--line);
}
.seg-btn {
  flex: 1;
  padding: 8px 6px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.84rem;
  cursor: pointer;
  transition: background 0.14s, color 0.14s;
}
.seg-btn.active {
  background: linear-gradient(135deg, var(--crimson), var(--crimson-deep));
  color: #fff;
}
.seg-btn.pick-red.active { background: #c81020; }
.seg-btn.pick-black.active { background: #26262d; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35); }
.seg-btn.pick-green.active { background: #149658; }

.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.stat-box {
  background: rgba(0, 0, 0, 0.38);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
}
.stat-box span { display: block; font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); }
.stat-box b { font-family: var(--font-mono); font-size: 0.94rem; color: #fff; }

.result-banner {
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  transition: all 0.2s;
}
.result-banner:not(:empty) { padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; }
.result-banner.win { background: var(--win-bg); border: 1px solid rgba(34, 229, 139, 0.35); color: var(--win); }
.result-banner.lose { background: var(--lose-bg); border: 1px solid rgba(255, 59, 74, 0.3); color: #ff8e96; }
.result-banner.push { background: rgba(255, 255, 255, 0.06); border: 1px solid var(--line-strong); color: #fff; }

.recent-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 12px;
  min-height: 26px;
}
.recent-chip {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  color: var(--text-muted);
}
.recent-chip.good { color: var(--win); border-color: rgba(34, 229, 139, 0.35); background: var(--win-bg); }
.recent-chip.rt-red { background: #c21825; color: #fff; border-color: transparent; }
.recent-chip.rt-black { background: #1e1e24; color: #fff; border-color: rgba(255, 255, 255, 0.2); }
.recent-chip.rt-green { background: #139457; color: #fff; border-color: transparent; }

/* ==================== INDIVIDUAL GAME VISUALS (Frixion + LiquidType) ==================== */

/* Mines (5x5 grid) */
.mines-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 9px;
  width: 100%;
  max-width: 440px;
}
.mine-tile {
  aspect-ratio: 1;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, #21242e, #171921);
  box-shadow: inset 0 -4px 0 rgba(0, 0, 0, 0.42);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.14s, background 0.14s, border-color 0.14s;
}
.mine-tile:hover:not(:disabled) {
  transform: translateY(-2px);
  border-color: var(--crimson-bright);
  background: linear-gradient(180deg, #2a242c, #1c171d);
}
.mine-tile:disabled { cursor: default; }
.mine-tile.gem { background: rgba(34, 229, 139, 0.16); border-color: rgba(34, 229, 139, 0.5); box-shadow: none; }
.mine-tile.mine { background: rgba(255, 59, 74, 0.16); border-color: rgba(255, 59, 74, 0.45); box-shadow: none; }
.mine-tile.boom { background: rgba(255, 38, 56, 0.42); border-color: #ff4455; box-shadow: 0 0 24px rgba(255, 38, 56, 0.55); }
.mine-tile.dim { opacity: 0.42; }
.mine-tile.opening {
  animation: tilePulse 0.42s ease-in-out infinite alternate;
  border-color: var(--crimson-bright);
}
@keyframes tilePulse {
  from { transform: scale(0.95); opacity: 0.8; }
  to { transform: scale(1.02); opacity: 1; }
}

/* Towers (9 rows) */
.towers-wrap { display: flex; flex-direction: column; gap: 7px; width: 100%; max-width: 480px; }
.tower-row { display: grid; grid-template-columns: 64px 1fr; gap: 10px; align-items: center; opacity: 0.48; transition: opacity 0.15s; }
.tower-row.now, .tower-row.done { opacity: 1; }
.tower-mult { font-family: var(--font-mono); font-size: 0.78rem; font-weight: 700; text-align: right; color: var(--text-muted); }
.tower-row.now .tower-mult { color: var(--gold); }
.tower-tiles { display: flex; gap: 7px; }
.tower-tiles .mine-tile { aspect-ratio: auto; height: 38px; flex: 1; border-radius: 8px; }
.tower-row.now .mine-tile:not(:disabled) { border-color: var(--crimson-bright); box-shadow: 0 0 12px rgba(220, 38, 38, 0.25); }

/* Blackjack (Six-Deck Shoe) */
.bj-table { width: 100%; max-width: 560px; display: flex; flex-direction: column; gap: 28px; }
.bj-banner {
  text-align: center;
  font-family: var(--font-mono);
  font-weight: 700;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.3);
}
.bj-zone { display: flex; flex-direction: column; gap: 10px; align-items: center; }
.bj-who { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); display: flex; align-items: center; gap: 8px; }
.bj-score { font-family: var(--font-mono); padding: 2px 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); color: #fff; font-size: 0.86rem; }
.bj-cards { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; min-height: 112px; }
.play-card {
  width: 78px;
  height: 112px;
  border-radius: 9px;
  background: #fafafa;
  color: #16161b;
  padding: 7px 8px;
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.55);
  animation: cardPop 0.26s cubic-bezier(0.2, 0.9, 0.3, 1.15);
}
@keyframes cardPop { from { transform: translateY(-18px) scale(0.92); opacity: 0; } to { transform: none; opacity: 1; } }
.play-card.red { color: #d61626; }
.play-card .rk { font-weight: 800; font-size: 1.2rem; line-height: 1; }
.play-card .suit-lg { position: absolute; right: 8px; bottom: 8px; opacity: 0.9; }
.play-card.back {
  background: repeating-linear-gradient(45deg, #3b0764 0 8px, #b91c1c 8px 16px);
  border: 3px solid #f6f2f2;
  display: flex;
  align-items: center;
  justify-content: center;
}
.play-card.back::after {
  content: 'DT';
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  color: #fff;
  letter-spacing: 0.05em;
}

/* Roulette (DonutLuck 0-18 Wheel + Track) */
.roul-wrap { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 20px; }
.roul-wheel-box { position: relative; width: 280px; height: 280px; }
.roul-svg { width: 100%; height: 100%; display: block; }
.roul-pointer {
  position: absolute;
  top: -6px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 18px solid var(--gold);
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.8));
  z-index: 4;
}
.roul-center-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 74px;
  height: 74px;
  border-radius: 50%;
  background: #14161e;
  border: 3px solid var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 1.7rem;
  color: #fff;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.7);
}
.roul-center-badge.red { background: #c21825; }
.roul-center-badge.black { background: #141418; }
.roul-center-badge.green { background: #139457; }
.roul-strip {
  display: grid;
  grid-template-columns: repeat(19, minmax(0, 1fr));
  gap: 3px;
  width: 100%;
  max-width: 680px;
}
.roul-cell {
  aspect-ratio: 1;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 700;
  color: #fff;
  opacity: 0.78;
  transition: transform 0.2s, opacity 0.2s, box-shadow 0.2s;
}
.roul-cell.red { background: #b81522; }
.roul-cell.black { background: #1e2029; border: 1px solid rgba(255, 255, 255, 0.14); }
.roul-cell.green { background: #139457; }
.roul-cell.hit { opacity: 1; transform: scale(1.18); box-shadow: 0 0 0 2px var(--gold), 0 0 16px rgba(245, 184, 46, 0.65); z-index: 2; }

/* Coinflip (3D RayCoin Flip) */
.coinflip-stage { display: flex; flex-direction: column; align-items: center; gap: 18px; perspective: 850px; }
.cf-coin {
  width: 170px;
  height: 170px;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 1.15s cubic-bezier(0.22, 0.82, 0.24, 1);
}
.cf-face {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 4px solid var(--crimson-bright);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.7), 0 0 28px rgba(220, 38, 38, 0.35);
  overflow: hidden;
}
.cf-face.heads {
  background: radial-gradient(circle at 35% 30%, #241236, #0d0c14 75%);
  padding: 14px;
}
.cf-face.heads img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.65));
}
.cf-face.tails {
  transform: rotateY(180deg);
  background: radial-gradient(circle at 35% 30%, #2b141a, #101118 70%);
  border-color: var(--gold);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.7), 0 0 28px rgba(245, 184, 46, 0.3);
}
.cf-tails-txt { font-family: var(--font-display); font-weight: 800; font-size: 2rem; letter-spacing: 0.06em; color: var(--gold); }
.cf-label { font-family: var(--font-mono); font-weight: 800; font-size: 1.45rem; letter-spacing: 0.1em; min-height: 32px; }

/* Dice */
.dice-stage { width: 100%; max-width: 580px; display: flex; flex-direction: column; gap: 18px; }
.dice-big { text-align: center; font-family: var(--font-mono); font-weight: 800; font-size: 4.1rem; letter-spacing: -0.02em; line-height: 1; }
.dice-big.win { color: var(--win); text-shadow: 0 0 28px rgba(34, 229, 139, 0.4); }
.dice-big.lose { color: var(--lose); text-shadow: 0 0 28px rgba(255, 59, 74, 0.4); }
.dice-track {
  position: relative;
  height: 18px;
  border-radius: 999px;
  background: rgba(255, 45, 65, 0.42);
  border: 1px solid var(--line-strong);
}
.dice-win-zone { position: absolute; top: 0; bottom: 0; border-radius: 999px; background: linear-gradient(90deg, #16b56d, #22e58b); }
.dice-marker {
  position: absolute;
  top: -10px;
  width: 8px;
  height: 36px;
  margin-left: -4px;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.8);
  transition: left 0.55s cubic-bezier(0.2, 0.85, 0.25, 1);
}
.dice-range { width: 100%; accent-color: var(--crimson-bright); cursor: pointer; }
.dice-scale { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 0.78rem; color: var(--text-faint); }

/* Keno */
.keno-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 7px; width: 100%; max-width: 560px; }
.keno-cell {
  aspect-ratio: 1;
  border-radius: 9px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, #20232d, #151720);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.96rem;
  cursor: pointer;
  transition: transform 0.12s, background 0.14s, border-color 0.14s;
}
.keno-cell:hover:not(:disabled) { border-color: var(--crimson-bright); transform: translateY(-1px); }
.keno-cell.picked { background: linear-gradient(135deg, var(--crimson), var(--crimson-deep)); border-color: var(--crimson-bright); color: #fff; }
.keno-cell.drawn { background: rgba(255, 255, 255, 0.1); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35); }
.keno-cell.hit { background: linear-gradient(135deg, #16b56d, #0f8a52); border-color: var(--win); color: #fff; transform: scale(1.06); box-shadow: 0 0 16px rgba(34, 229, 139, 0.45); }

/* Plinko (Frixion SVG Pegboard) */
.plinko-wrap { width: 100%; max-width: 600px; }
.plinko-svg { width: 100%; height: auto; display: block; }
.pl-peg { fill: #e9ecf5; opacity: 0.85; }
.pl-slot rect { rx: 5; }
.pl-slot.cold rect { fill: #252834; stroke: rgba(255, 255, 255, 0.14); }
.pl-slot.mid rect { fill: #7c0e18; }
.pl-slot.warm rect { fill: #c41222; }
.pl-slot.hot rect { fill: #f5b82e; }
.pl-slot text { font-size: 9.5px; font-weight: 800; text-anchor: middle; fill: #fff; font-family: var(--font-mono); }
.pl-slot.hot text { fill: #120405; }
.pl-slot { transform-box: fill-box; transform-origin: center; }
.pl-slot.bump { animation: plBump 0.35s ease-out; }
@keyframes plBump { 40% { transform: translateY(5px); } }
.pl-ball { fill: var(--crimson-bright); stroke: #fff; stroke-width: 1.5; }

/* Cases (CS-style horizontal reel strip) */
.case-list { display: flex; flex-direction: column; gap: 7px; }
.case-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  background: var(--surface-input);
  cursor: pointer;
  text-align: left;
  transition: border-color 0.14s, background 0.14s;
}
.case-opt.active { border-color: var(--crimson-bright); background: var(--crimson-soft); }
.case-opt b { font-size: 0.9rem; display: block; }
.case-opt small { font-size: 0.72rem; color: var(--text-muted); }
.case-reel-wrap { position: relative; width: 100%; overflow: hidden; padding: 24px 0; }
.case-reel-marker {
  position: absolute;
  left: 50%;
  top: 4px;
  bottom: 4px;
  width: 3px;
  margin-left: -1.5px;
  background: var(--gold);
  box-shadow: 0 0 14px var(--gold);
  z-index: 3;
}
.case-strip { display: flex; gap: 10px; will-change: transform; padding-left: 50%; }
.case-item {
  flex: 0 0 124px;
  height: 132px;
  border-radius: 10px;
  background: linear-gradient(180deg, #1b1d26, #0e091b);
  border: 1px solid var(--line-strong);
  border-bottom-width: 4px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 4px;
}
.case-item.r0 { border-bottom-color: #8c8c96; }
.case-item.r1 { border-bottom-color: #22e58b; }
.case-item.r2 { border-bottom-color: #3da0ff; }
.case-item.r3 { border-bottom-color: #c255ff; }
.case-item.r4 { border-bottom-color: #f5b82e; }
.case-item.r5 { border-bottom-color: #ff2638; background: linear-gradient(180deg, rgba(220, 38, 38, 0.34), #141118); }
.case-item.won { outline: 2px solid var(--gold); outline-offset: 2px; }
.case-item-rar { font-size: 0.66rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); }
.case-item-name { font-size: 0.8rem; font-weight: 700; color: #fff; line-height: 1.2; }
.case-item-val { font-family: var(--font-mono); font-size: 0.86rem; font-weight: 700; color: var(--gold); }

/* Crash (HTML5 Canvas) */
.crash-stage { position: relative; width: 100%; height: 390px; }
.crash-stage canvas { width: 100%; height: 100%; display: block; }
.crash-mult {
  position: absolute;
  top: 32%;
  left: 0;
  right: 0;
  text-align: center;
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 4.5rem;
  letter-spacing: -0.02em;
  line-height: 1;
  pointer-events: none;
  text-shadow: 0 6px 26px rgba(0, 0, 0, 0.7);
}
.crash-mult.win { color: var(--win); }
.crash-mult.lose { color: var(--lose); }
.crash-sub {
  position: absolute;
  top: calc(32% + 86px);
  left: 0;
  right: 0;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  pointer-events: none;
}

/* ==================== ACCOUNT / REWARDS / FAIRNESS / ADMIN PAGES ==================== */
.page-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.page-card {
  border-radius: var(--radius-lg);
  padding: 20px;
  background: var(--surface-1);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.page-card.span-2 { grid-column: 1 / -1; }
.page-card h2 { font-family: var(--font-display); font-size: 1.24rem; font-weight: 800; letter-spacing: -0.02em; }
.page-card h3 { font-size: 1rem; font-weight: 700; }
.muted { color: var(--text-muted); font-size: 0.86rem; }
.code-box {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--surface-input);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  word-break: break-all;
}
.steps-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.step-tile {
  padding: 18px;
  border-radius: var(--radius-md);
  background: var(--surface-1);
  border: 1px solid var(--line);
}
.step-num { font-family: var(--font-mono); font-size: 1.4rem; font-weight: 800; color: var(--crimson-bright); line-height: 1; margin-bottom: 8px; }

/* Responsive Admin Forms */
.admin-promo-row {
  display: grid;
  grid-template-columns: minmax(120px, 1.15fr) minmax(110px, 1fr) 92px;
  gap: 8px;
}
.admin-adjust-row {
  display: grid;
  grid-template-columns: minmax(160px, 1.2fr) minmax(160px, 1.1fr) minmax(140px, 0.8fr);
  gap: 10px;
  align-items: center;
}
.admin-adjust-btns {
  grid-column: 1 / -1;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* ==================== MODALS & TOASTS ==================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(5, 6, 9, 0.78);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.modal-card {
  position: relative;
  width: 100%;
  max-width: 448px;
  border-radius: var(--radius-lg);
  padding: 24px;
  background: linear-gradient(180deg, #161029 0%, #0e091c 100%);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 24px 64px rgba(9, 9, 12, 0.86), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 90dvh;
  overflow-y: auto;
}
.modal-wide { max-width: 640px; }
.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  font-size: 1.2rem;
  cursor: pointer;
}
.modal-close:hover { background: var(--crimson-soft); color: #fff; }
.modal-head { display: flex; align-items: center; gap: 10px; padding-right: 28px; }
.modal-head h2 { font-family: var(--font-display); font-size: 1.32rem; font-weight: 800; letter-spacing: -0.02em; }
.modal-sub { font-size: 0.92rem; color: var(--text); }
.modal-hint { font-size: 0.84rem; color: var(--text-muted); line-height: 1.45; }
.modal-stack { display: flex; flex-direction: column; gap: 8px; }
.modal-back { align-self: flex-start; margin-top: 4px; }
.modal-error {
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: var(--lose-bg);
  border: 1px solid rgba(255, 59, 74, 0.35);
  color: #ff8e96;
  font-size: 0.84rem;
  font-weight: 600;
}
.modal-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-faint);
  font-size: 0.78rem;
  margin: 4px 0;
}
.modal-divider::before, .modal-divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }

.bot-banner {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.83rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 9px;
}
.bot-banner.online { background: var(--win-bg); border: 1px solid rgba(34, 229, 139, 0.35); color: var(--win); }
.bot-banner.offline { background: var(--lose-bg); border: 1px solid rgba(255, 59, 74, 0.35); color: #ff8e96; }

.cmd-copy-box {
  width: 100%;
  padding: 14px;
  border-radius: var(--radius-md);
  background: rgba(11, 11, 14, 0.9);
  border: 1px dashed rgba(239, 68, 68, 0.5);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.cmd-copy-box:hover { background: rgba(220, 38, 38, 0.14); border-color: var(--purple-bright); }
.cmd-copy-box code { font-family: var(--font-mono); font-size: 1rem; font-weight: 700; color: var(--gold); word-break: break-all; }
.cmd-copy-tag { font-size: 0.74rem; color: var(--text-muted); }

.poll-status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: rgba(220, 38, 38, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.16);
  font-size: 0.84rem;
  color: var(--text-muted);
}
.poll-status.done {
  background: var(--win-bg);
  border-color: rgba(34, 229, 139, 0.42);
  color: var(--win);
  font-weight: 700;
}
.spinner {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--crimson-bright);
  animation: spin 0.75s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.info-box {
  border-radius: var(--radius-sm);
  background: rgba(10, 10, 13, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 11px 13px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.85rem;
}
.info-box > div { display: flex; justify-content: space-between; gap: 10px; }
.info-box span { color: var(--text-muted); }

.activity-list { display: flex; flex-direction: column; gap: 8px; }
.activity-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 13px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.85rem;
}
.activity-note {
  margin-top: 4px;
  font-size: 0.74rem;
  color: #fda4af;
  line-height: 1.35;
}
.status-pill {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  text-transform: uppercase;
}
.status-pill.completed { background: var(--win-bg); color: var(--win); }
.status-pill.pending, .status-pill.processing { background: rgba(245, 184, 46, 0.16); color: var(--gold); }
.status-pill.refunded, .status-pill.failed, .status-pill.expired { background: var(--lose-bg); color: #ff8e96; }

/* Mobile Games Modal & Fixed Bottom Nav Bar */
.mob-games-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.mob-game-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-size: 0.88rem;
  font-weight: 700;
  color: #fff;
  transition: background 0.14s, border-color 0.14s;
}
.mob-game-btn svg { color: var(--crimson-bright); flex-shrink: 0; }
.mob-game-btn:hover, .mob-game-btn:active { background: var(--crimson-soft); border-color: var(--crimson-line); }
.mob-extra-links { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }

.mobile-nav { display: none; }

/* Toasts & Deposit/Withdrawal Alerts */
.toast-stack {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 300;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  pointer-events: none;
  width: min(92vw, 480px);
}
.toast {
  padding: 11px 20px;
  border-radius: 12px;
  background: rgba(21, 21, 24, 0.96);
  backdrop-filter: blur(16px);
  border: 1px solid var(--purple-line);
  color: #fff;
  font-size: 0.86rem;
  font-weight: 600;
  box-shadow: 0 14px 36px rgba(9, 9, 12, 0.78);
  animation: toastIn 0.22s ease;
  text-align: center;
  pointer-events: auto;
  cursor: pointer;
}
.toast.ok { border-color: rgba(34, 229, 139, 0.52); color: var(--win); }
.toast.deposit-alert {
  background: linear-gradient(135deg, rgba(16, 46, 36, 0.97), rgba(14, 22, 34, 0.97));
  border-color: rgba(34, 229, 139, 0.72);
  box-shadow: 0 16px 40px rgba(9, 9, 12, 0.82), 0 0 24px rgba(34, 229, 139, 0.24);
  font-weight: 700;
}
.toast.err { border-color: rgba(244, 63, 94, 0.55); color: #fda4af; }
@keyframes toastIn { from { transform: translateY(10px); opacity: 0; } to { transform: none; opacity: 1; } }

/* LiquidType Jackpot Particle Celebration */
.jp-particle {
  position: fixed;
  pointer-events: none;
  z-index: 400;
  border-radius: 50%;
  animation: jpFall 1.5s ease-in forwards;
}
@keyframes jpFall {
  0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(115vh) rotate(720deg); opacity: 0; }
}

/* Slots Cabinet (Frixion 3-Reel Engine + DonutTrix Crimson/Gold Trim) */
.slots-cabinet {
  width: 100%;
  max-width: 440px;
  padding: 20px;
  border-radius: 16px;
  background: linear-gradient(175deg, #181a22 0%, #09090b 100%);
  border: 1px solid var(--line-strong);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.55);
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}
.slots-cabinet.win-glow {
  border-color: rgba(34, 229, 139, 0.55);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.55), 0 0 36px rgba(34, 229, 139, 0.2);
}
.slots-marquee {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 9px;
  background: rgba(220, 38, 38, 0.13);
  border: 1px solid rgba(239, 68, 68, 0.22);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}
.slots-marquee b { color: var(--gold); letter-spacing: 0.02em; }
.slots-reels-wrap { position: relative; }
.slots-reels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.slot-reel {
  height: 246px;
  overflow: hidden;
  border-radius: 10px;
  background: linear-gradient(180deg, #07080b 0%, #14161e 50%, #07080b 100%);
  border: 1px solid var(--line-strong);
  box-shadow: inset 0 18px 24px rgba(0, 0, 0, 0.65), inset 0 -18px 24px rgba(0, 0, 0, 0.65);
}
.slot-strip { will-change: transform; transition: filter 0.12s ease, opacity 0.12s ease; }
.slots-cabinet.spinning .slot-strip { filter: blur(2.2px); opacity: 0.84; }
.slot-cell {
  height: 82px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.slot-coin-sym { border-radius: 0; object-fit: contain; filter: drop-shadow(0 0 10px rgba(178, 86, 255, 0.52)); }
.slots-payline {
  position: absolute;
  left: -6px;
  right: -6px;
  top: 50%;
  height: 82px;
  margin-top: -41px;
  border: 2px solid rgba(245, 184, 46, 0.78);
  border-radius: 10px;
  pointer-events: none;
  box-shadow: 0 0 18px rgba(245, 184, 46, 0.18);
}
.slot-paytable {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}
.slot-pay-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.78rem;
}
.slot-pay-icons { display: inline-flex; align-items: center; gap: 4px; color: var(--text-muted); }
.slot-pay-row b { color: var(--gold); font-size: 0.8rem; }

/* Reduced Motion / Epilepsy Safety (from Frixion) */
html[data-calm="1"] *, html[data-calm="1"] *::before, html[data-calm="1"] *::after {
  animation-duration: 0.001ms !important;
  transition-duration: 0.001ms !important;
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ==================== RESPONSIVE BREAKPOINTS & CONTAINER QUERIES (320px -> 4K) ==================== */

/* Progressive Topbar Nav Hiding & Unfullscreen Monitor Scaling — guarantees zero overlap at every screen width */
@media (max-width: 1600px) {
  .nav-opt-xl { display: none; }
}
@media (max-width: 1480px) {
  .nav-opt-lg { display: none; }
  .bot-pill-txt { display: none; }
  .bot-pill { padding: 8px; }
  .nav-link { padding: 6px 8px; font-size: 0.83rem; }
}
@media (max-width: 1360px) {
  .chat-drawer { width: 268px; }
}
@media (max-width: 1320px) {
  .nav-opt-md { display: none; }
  .bot-pill { display: none; }
  .topbar-inner { gap: 8px; }
  .topbar-left, .topbar-right { gap: 6px; }
  .btn-games-cta { padding: 0 11px; height: 35px; font-size: 0.82rem; }
  .user-name { max-width: 82px; }
}
@media (max-width: 1180px) {
  .nav-bot-tab { display: none; }
  .user-lvl-badge { display: none; }
  .brand-coin { width: 29px; height: 29px; }
  .brand-wordmark { font-size: 1.06rem; }
  .nav-link { padding: 6px 7px; font-size: 0.81rem; }
}
@media (max-width: 1140px) {
  .chat-drawer {
    position: fixed;
    right: 0;
    top: 102px;
    width: min(304px, 90vw);
    height: calc(100dvh - 102px);
    z-index: 88;
    box-shadow: -12px 0 36px rgba(0, 0, 0, 0.75);
  }
}
@media (max-width: 1040px) {
  .user-name { display: none; }
  #music-toggle { display: none; }
  .btn-games-cta .games-cta-count { display: none; }
  .profile-access-btn { padding: 4px 8px 4px 5px; gap: 5px; }
  .user-chip { padding: 4px 7px 4px 5px; gap: 5px; }
}
@media (max-width: 960px) {
  .brand-wordmark { font-size: 0.98rem; }
  .nav-link { padding: 5px 6px; font-size: 0.78rem; }
  .dl-bal-btn { padding: 0 8px 0 7px; }
  .dl-bal-btn .bal-val { font-size: 0.85rem; }
}

/* Container queries on .main-col — adapts automatically whether chat drawer is open or closed! */
@container maincol (max-width: 1060px) {
  .ranks-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-grid { grid-template-columns: 1.45fr 1fr; gap: 12px; }
  .game-shell { grid-template-columns: 270px 1fr; }
}
@container maincol (max-width: 920px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-side-stack { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
  .hero-emblem { width: 108px; height: 108px; }
  .hero-emblem-coin { width: 90px; height: 90px; }
  .feature-strip { grid-template-columns: 1fr; }
  .game-shell { grid-template-columns: 1fr; gap: 12px; }
  .game-stage { order: -1; min-height: 290px; padding: 16px; }
  .admin-adjust-row { grid-template-columns: 1fr 1fr; }
  .admin-adjust-row > select { grid-column: 1 / -1; }
  .lb-podium { grid-template-columns: 1fr; }
}
@container maincol (max-width: 720px) {
  .hero-emblem { display: none; }
  .hero-copy { max-width: 100%; }
  .page-grid, .steps-3, .site-footer { grid-template-columns: 1fr; }
  .admin-promo-row, .admin-adjust-row { grid-template-columns: 1fr; }
  .games-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
@container maincol (max-width: 520px) {
  .ranks-grid { grid-template-columns: 1fr; }
  .hero-side-stack { grid-template-columns: 1fr; }
}

/* Full Mobile & Tablet Experience (<= 860px) */
@media (max-width: 860px) {
  .topbar-inner { height: 54px; padding: 0 10px; gap: 6px; }
  .subbar-inner { height: 38px; padding: 0 10px; }
  .main-nav { display: none; }
  .bot-pill { display: none; }

  .dl-wallet { height: 35px; }
  .dl-bal-btn { padding: 0 8px 0 7px; gap: 5px; }
  .dl-bal-btn .bal-val { font-size: 0.84rem; }
  .dl-bal-btn .coin-ico { width: 18px; height: 18px; }
  .dl-wallet-btn { width: 36px; }
  .wallet-drop { right: 0; left: auto; min-width: 220px; max-width: calc(100vw - 20px); }
  .user-drop { right: 0; left: auto; max-width: calc(100vw - 20px); }
  .user-chip { height: 35px; padding: 4px 7px 4px 5px; gap: 5px; }
  .user-name { display: none; }
  .user-lvl-badge { display: none; }
  .icon-btn { width: 34px; height: 34px; }

  .app-shell { min-height: calc(100dvh - 94px); }
  .main-col { padding: 12px 10px calc(84px + env(safe-area-inset-bottom)); }

  /* Prevent iOS Safari input auto-zoom */
  .text-input, .select-input, .chat-form input { font-size: 16px; }

  /* Fixed Mobile Bottom Nav Bar */
  .mobile-nav {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 95;
    height: calc(60px + env(safe-area-inset-bottom));
    padding: 4px 6px env(safe-area-inset-bottom);
    background: rgba(13, 13, 16, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--line-strong);
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.55);
  }
  .mob-nav-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border: 0;
    background: transparent;
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 700;
    cursor: pointer;
    border-radius: 9px;
    transition: color 0.14s, background 0.14s;
  }
  .mob-nav-btn.active { color: var(--crimson-bright); background: rgba(220, 38, 38, 0.13); }

  .chat-fab { display: none !important; }
  .chat-drawer {
    position: fixed;
    left: 0;
    right: 0;
    top: 94px;
    width: 100vw;
    height: calc(100dvh - 94px - 60px - env(safe-area-inset-bottom));
    border-left: 0;
    z-index: 92;
    transform: translateX(0);
    visibility: visible;
    transition: transform 0.2s ease, opacity 0.18s ease, visibility 0.2s ease;
  }
  .chat-drawer.collapsed {
    width: 100vw;
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }

  .toast-stack {
    bottom: calc(70px + env(safe-area-inset-bottom));
    width: calc(100vw - 20px);
    align-items: center;
  }

  .hero-grid { grid-template-columns: 1fr; gap: 10px; margin-bottom: 18px; }
  .hero-card { padding: 18px 16px; }
  .hero-emblem { display: none; }
  .games-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 22px; }
  .gc-art { height: 100px; }

  .game-head { gap: 8px; margin-bottom: 10px; }
  .game-head h1 { font-size: 1.28rem; }
  .game-head-desc { width: 100%; font-size: 0.81rem; }
  .game-head-right { margin-left: 0; width: 100%; justify-content: space-between; font-size: 0.78rem; }
  .game-shell { grid-template-columns: 1fr; gap: 10px; }
  .game-stage { order: -1; min-height: 230px; padding: 14px 12px; }
  .game-panel { padding: 14px 12px; gap: 8px; }
  .game-panel > .btn { min-height: 44px; font-size: 0.94rem; }

  .page-grid, .steps-3, .site-footer { grid-template-columns: 1fr; gap: 12px; }
  .admin-promo-row, .admin-adjust-row { grid-template-columns: 1fr; }
  .activity-row { flex-direction: column; align-items: flex-start; gap: 8px; }

  .roul-strip { grid-template-columns: repeat(10, minmax(0, 1fr)); }
  .crash-stage { height: 225px; }
  .crash-mult { font-size: clamp(2.2rem, 10vw, 3.4rem); }
  .crash-sub { top: calc(32% + 52px); font-size: 0.82rem; }
  .dice-big { font-size: clamp(2.3rem, 10vw, 3.4rem); }
}

@media (max-width: 560px) {
  #music-toggle { display: none; }
  .brand { padding-right: 2px; gap: 6px; }
  .brand-coin { width: 27px; height: 27px; }
  .brand-wordmark { font-size: 1rem; }

  .col-mult { display: none; }
  .live-table th, .live-table td { padding: 9px 10px; font-size: 0.79rem; }

  .mines-grid { gap: 6px; max-width: min(100%, 336px); }
  .mine-tile { border-radius: 8px; }
  .tower-row { grid-template-columns: 46px 1fr; gap: 6px; }
  .tower-tiles { gap: 5px; }
  .tower-tiles .mine-tile { height: 32px; }
  .play-card { width: 60px; height: 86px; padding: 5px 6px; }
  .play-card .rk { font-size: 0.96rem; }
  .play-card .suit-lg svg { width: 24px; height: 24px; }
  .bj-cards { min-height: 88px; gap: 7px; }
  .bj-table { gap: 18px; }
  .roul-wheel-box { width: min(210px, 60vw); height: min(210px, 60vw); }
  .roul-center-badge { width: 54px; height: 54px; font-size: 1.32rem; }
  .cf-coin { width: 124px; height: 124px; }
  .cf-tails-txt { font-size: 1.65rem; }
  .keno-grid { grid-template-columns: repeat(8, 1fr); gap: 4px; }
  .keno-cell { font-size: 0.8rem; border-radius: 6px; }
  .plinko-wrap { max-width: min(100%, 360px); }

  .inline-form { flex-direction: column; align-items: stretch; }
  .inline-form > .btn { width: 100%; }
  .mob-extra-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  /* Bottom-sheet ergonomic modals on mobile phones */
  .modal-backdrop {
    align-items: flex-end;
    padding: 0;
  }
  .modal-card {
    max-width: 100%;
    border-radius: 18px 18px 0 0;
    padding: 18px 16px calc(20px + env(safe-area-inset-bottom));
    max-height: 88dvh;
  }
}

@media (max-width: 430px) {
  .dl-bal-btn { padding: 0 6px; gap: 4px; }
  .dl-bal-btn .bal-val { font-size: 0.78rem; }
  .brand-wordmark { font-size: 0.92rem; }
}

@media (max-width: 380px) {
  .brand-wordmark { display: none; }
  .mob-games-grid { grid-template-columns: 1fr; }
  .keno-grid { grid-template-columns: repeat(5, 1fr); }
}

/* ==================== MODERN PROGRESSION, LEADERBOARDS, RANKS & GAME POLISH ==================== */

/* Smooth view entrance animation */
.main-col > * {
  animation: viewFadeIn 0.22s cubic-bezier(0.2, 0.85, 0.3, 1);
}
@keyframes viewFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Header User Level Badge & Rank Pill */
.user-lvl-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 7px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: var(--gold);
  letter-spacing: -0.02em;
}

.rank-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 0.73rem;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.16);
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.edition-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  color: var(--text-muted);
}

/* Rain Widget Level Share Hint */
.rain-lvl-hint {
  font-size: 0.74rem;
  color: var(--text-muted);
  padding: 5px 8px;
  margin-bottom: 8px;
  border-radius: 7px;
  background: rgba(0, 0, 0, 0.26);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

/* 18+ Age Confirmation Checkbox in Sign-In Modal */
.age-confirm-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line-strong);
  font-size: 0.79rem;
  line-height: 1.42;
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
  transition: border-color 0.15s, background 0.15s;
}
.age-confirm-box:hover {
  border-color: var(--crimson-line);
  background: rgba(220, 38, 38, 0.05);
}
.age-confirm-box input[type="checkbox"] {
  margin-top: 2px;
  width: 17px;
  height: 17px;
  accent-color: var(--crimson);
  flex-shrink: 0;
  cursor: pointer;
}
.age-confirm-box strong { color: #fff; }

/* Simple & Clean Deposit / Withdraw Modal Polish */
.wallet-modal-card .modal-head {
  align-items: center;
}
.wallet-modal-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}
.wallet-rate-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.12), rgba(220, 38, 38, 0.12));
  border: 1px solid rgba(220, 38, 38, 0.3);
  font-size: 0.84rem;
  color: var(--text-muted);
}
.wallet-rate-pill strong { color: #fff; }
.wallet-rate-pill .rate-arrow { color: var(--gold); font-weight: 800; }
.wallet-info-grid {
  background: rgba(255, 255, 255, 0.025);
  border-color: var(--line-strong);
}

/* Home Feature Highlight Strip */
.feature-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.feature-pill-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 15px 16px;
  border-radius: var(--radius);
  background: linear-gradient(155deg, rgba(28, 28, 31, 0.94), rgba(17, 17, 20, 0.96));
  border: 1px solid var(--line);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.feature-pill-card:hover {
  transform: translateY(-2px);
  border-color: var(--crimson-line);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}
.feature-pill-card strong {
  display: block;
  font-size: 0.96rem;
  color: #fff;
  margin-bottom: 2px;
}
.feature-pill-card p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
}
.fp-tag {
  align-self: flex-start;
  padding: 2px 9px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.69rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}
.fp-tag.gold { background: rgba(245, 184, 46, 0.16); color: var(--gold); border: 1px solid rgba(245, 184, 46, 0.35); }
.fp-tag.purple { background: rgba(220, 38, 38, 0.16); color: #f87171; border: 1px solid rgba(220, 38, 38, 0.35); }
.fp-tag.green { background: rgba(34, 229, 139, 0.15); color: var(--win); border: 1px solid rgba(34, 229, 139, 0.35); }

/* User Dashboard Hero & Animated XP Bar */
.dash-hero-card {
  background: radial-gradient(circle at 92% 15%, rgba(220, 38, 38, 0.14), transparent 45%),
              linear-gradient(160deg, #160f28 0%, #0e091b 100%);
  border-color: var(--line-strong);
}
.dash-hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.dash-identity {
  display: flex;
  align-items: center;
  gap: 14px;
}
.dash-avatar {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.25), rgba(220, 38, 38, 0.25));
  border: 2px solid var(--crimson);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.45rem;
  font-weight: 800;
  color: #fff;
  flex-shrink: 0;
}
.dash-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 3px;
}
.xp-progress-box {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.32);
  border: 1px solid var(--line);
}
.xp-progress-labels {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.8rem;
  flex-wrap: wrap;
}
.xp-bar-track {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.xp-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.35s cubic-bezier(0.2, 0.85, 0.3, 1);
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.45);
}

/* Verification & Audience Safety Checklist */
.verify-checklist {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.verify-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--line);
}
.verify-item strong {
  display: block;
  font-size: 0.84rem;
  color: #fff;
  margin-bottom: 2px;
}
.verify-item p {
  font-size: 0.77rem;
  line-height: 1.38;
}
.verify-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.67rem;
  font-weight: 800;
  padding: 3px 7px;
  border-radius: 6px;
  flex-shrink: 0;
  margin-top: 2px;
}
.verify-badge.ok {
  background: var(--win-bg);
  color: var(--win);
  border: 1px solid rgba(34, 229, 139, 0.35);
}
.verify-badge.info {
  background: rgba(220, 38, 38, 0.16);
  color: #f87171;
  border: 1px solid rgba(220, 38, 38, 0.35);
}

/* Levels & Ranks Grid + Interactive Rain Calculator */
.rain-calc-card {
  background: radial-gradient(circle at 90% 10%, rgba(34, 229, 139, 0.11), transparent 45%),
              var(--surface);
}
.rain-calc-controls {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--line);
}
.ranks-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.rank-card {
  padding: 16px;
  border-radius: var(--radius);
  background: linear-gradient(165deg, #160f28 0%, #0c0717 100%);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.rank-card:hover {
  transform: translateY(-3px);
  border-color: var(--rk-color, var(--crimson-line));
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}
.rank-card.current {
  border-color: var(--rk-color, var(--gold));
  box-shadow: 0 0 0 1px var(--rk-color, var(--gold)), 0 14px 32px rgba(0, 0, 0, 0.5);
}
.rank-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.rank-card h3 {
  font-size: 1.04rem;
  font-weight: 800;
  color: #fff;
}
.rank-card-stats {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 0.79rem;
}
.rank-card-stats > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.rank-card-stats span { color: var(--text-muted); }

/* Leaderboards Tabs & Top-3 Podium */
.lb-tabs {
  display: inline-flex;
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 3px;
  gap: 3px;
  flex-wrap: wrap;
}
.lb-tab {
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 7px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.lb-tab:hover { color: #fff; }
.lb-tab.active {
  background: var(--crimson);
  color: #fff;
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.35);
}

.lb-podium {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.lb-podium:empty { display: none; }
.lb-podium-card {
  padding: 16px;
  border-radius: var(--radius);
  background: linear-gradient(165deg, #170f2b 0%, #0c0717 100%);
  border: 1px solid var(--line-strong);
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  overflow: hidden;
}
.lb-podium-card.p1 {
  border-color: rgba(245, 184, 46, 0.55);
  background: radial-gradient(circle at 88% 12%, rgba(245, 184, 46, 0.18), transparent 50%),
              linear-gradient(165deg, #1f1535 0%, #0d0818 100%);
}
.lb-podium-card.p2 {
  border-color: rgba(148, 163, 184, 0.45);
}
.lb-podium-card.p3 {
  border-color: rgba(217, 119, 6, 0.45);
}
.lb-medal {
  align-self: flex-start;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
}
.lb-podium-card.p1 .lb-medal { background: rgba(245, 184, 46, 0.22); color: var(--gold); border: 1px solid rgba(245, 184, 46, 0.45); }
.lb-podium-card.p2 .lb-medal { background: rgba(226, 232, 240, 0.15); color: #e2e8f0; }
.lb-podium-card.p3 .lb-medal { background: rgba(217, 119, 6, 0.2); color: #fbbf24; }
.lb-podium-user {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}
.lb-podium-user strong { font-size: 1.05rem; color: #fff; }
.lb-podium-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-size: 0.78rem;
}
.lb-podium-metrics span { display: block; color: var(--text-muted); margin-bottom: 2px; }

/* Keno Stage Multiplier Ladder & Polished Game Stage Ambient Depth */
.game-stage {
  background:
    radial-gradient(circle at 50% 12%, rgba(220, 38, 38, 0.09), transparent 58%),
    radial-gradient(circle at 50% 92%, rgba(220, 38, 38, 0.07), transparent 55%),
    var(--surface);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 14px 36px rgba(0, 0, 0, 0.35);
}
.keno-stage-wrap {
  width: 100%;
  max-width: 560px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
}
.keno-ladder {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(56px, 1fr));
  gap: 6px;
}
.keno-tier {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6px 4px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-size: 0.75rem;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}
.keno-tier span { color: var(--text-muted); font-size: 0.7rem; }
.keno-tier b { color: #fff; font-size: 0.8rem; }
.keno-tier.mid b { color: var(--gold); }
.keno-tier.hot b { color: var(--win); }
.keno-tier.active {
  transform: translateY(-2px) scale(1.04);
  background: rgba(34, 229, 139, 0.16);
  border-color: var(--win);
  box-shadow: 0 0 16px rgba(34, 229, 139, 0.25);
}



/* ==================== DONUTTRIX ROYAL PURPLE MASTER UI & INTERACTIONS ==================== */

/* Premium Glowing Shine-Sweep Buttons & Micro-Interactions */
.btn {
  position: relative;
  overflow: hidden;
  transition: transform 0.16s cubic-bezier(0.2, 0.85, 0.3, 1.2), filter 0.16s ease, background 0.16s ease, border-color 0.16s ease, box-shadow 0.2s ease;
}
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 20%, rgba(255, 255, 255, 0.24) 48%, transparent 76%);
  transform: translateX(-130%);
  transition: transform 0.55s ease;
  pointer-events: none;
}
.btn:hover:not(:disabled)::after { transform: translateX(130%); }
.btn:active:not(:disabled) { transform: scale(0.97) translateY(0); }

.btn-primary {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 55%, #991b1b 100%);
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 4px 18px rgba(220, 38, 38, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.btn-primary:hover:not(:disabled) {
  filter: brightness(1.12);
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: 0 8px 28px rgba(220, 38, 38, 0.6), 0 0 18px rgba(239, 68, 68, 0.35);
  transform: translateY(-2px);
}
.btn-ghost:hover:not(:disabled) {
  background: rgba(220, 38, 38, 0.15);
  border-color: var(--purple-line);
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.22);
  transform: translateY(-1px);
}
.btn-win:hover:not(:disabled) {
  box-shadow: 0 8px 26px rgba(34, 229, 139, 0.45);
  transform: translateY(-2px);
}
.btn-discord {
  background: linear-gradient(135deg, #6370ff 0%, #5865f2 55%, #4752c4 100%);
  border: 1px solid rgba(165, 180, 252, 0.4);
  color: #fff;
  box-shadow: 0 4px 18px rgba(88, 101, 242, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.btn-discord:hover:not(:disabled) {
  filter: brightness(1.1);
  box-shadow: 0 8px 26px rgba(88, 101, 242, 0.62);
  transform: translateY(-2px);
}
.btn-lg { padding: 13px 24px; font-size: 0.96rem; }

/* Prominent Topbar Game Selection Button */
.btn-games-cta {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 13px;
  border-radius: 10px;
  border: 1px solid rgba(239, 68, 68, 0.48);
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.92), rgba(127, 29, 29, 0.96));
  color: #fff;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 4px 18px rgba(220, 38, 38, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.16s ease, box-shadow 0.2s ease, border-color 0.16s ease, filter 0.16s ease;
}
.btn-games-cta::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 20%, rgba(255, 255, 255, 0.28) 50%, transparent 80%);
  transform: translateX(-135%);
  transition: transform 0.55s ease;
}
.btn-games-cta:hover::after { transform: translateX(135%); }
.btn-games-cta:hover, .btn-games-cta.active {
  transform: translateY(-1px);
  border-color: #fecaca;
  box-shadow: 0 6px 26px rgba(220, 38, 38, 0.68), 0 0 14px rgba(239, 68, 68, 0.42);
}
.btn-games-cta:active { transform: scale(0.97); }
.games-cta-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 19px;
  padding: 0 5px;
  border-radius: 999px;
  background: rgba(12, 12, 15, 0.48);
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 800;
  color: #fecaca;
}

/* Dedicated Events Nav Pill with Letter Drop Counter */
.nav-events-btn {
  border: 1px solid rgba(239, 68, 68, 0.26);
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.16), rgba(220, 38, 38, 0.1));
  color: #fecaca;
}
.nav-events-btn:hover, .nav-events-btn.active {
  border-color: rgba(255, 255, 255, 0.55);
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.32), rgba(220, 38, 38, 0.22));
  color: #fff;
  box-shadow: 0 0 18px rgba(220, 38, 38, 0.35);
}
.events-spark-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 10px #ef4444;
  animation: pulseDot 1.8s ease-in-out infinite;
}
@keyframes pulseDot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.35); opacity: 0.65; }
}
.nav-hunt-badge {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(220, 38, 38, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fee2e2;
}
.nav-hunt-badge.done {
  background: rgba(34, 229, 139, 0.22);
  border-color: rgba(34, 229, 139, 0.5);
  color: var(--win);
}

/* Visually Appealing Profile Sidebar Access Button */
.profile-access-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 38px;
  padding: 4px 10px 4px 5px;
  border-radius: 11px;
  background: linear-gradient(145deg, rgba(28, 28, 31, 0.92), rgba(21, 21, 24, 0.96));
  border: 1px solid rgba(239, 68, 68, 0.32);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.2s ease, background 0.16s ease;
}
.profile-access-btn:hover, .profile-access-btn.active {
  border-color: var(--purple-bright);
  background: linear-gradient(145deg, rgba(28, 28, 31, 0.95), rgba(28, 28, 31, 0.98));
  box-shadow: 0 0 22px rgba(220, 38, 38, 0.42);
  transform: translateY(-1px);
}
.profile-access-btn:active { transform: scale(0.97); }
.profile-access-btn .user-avatar {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.45);
}
.profile-access-btn .user-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.profile-notify-dot {
  position: absolute;
  top: -3px;
  right: -3px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--win);
  border: 2px solid var(--bg-0);
  box-shadow: 0 0 10px var(--win);
}

/* ==================== SLIDE-OUT PROFILE SIDEBAR ==================== */
.ps-backdrop {
  position: fixed;
  inset: 0;
  z-index: 140;
  background: rgba(9, 9, 12, 0.68);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: fadeInBg 0.2s ease;
}
@keyframes fadeInBg { from { opacity: 0; } to { opacity: 1; } }

.profile-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 150;
  width: min(400px, 94vw);
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #141418 0%, #0f0f12 52%, #09090b 100%);
  border-right: 1px solid rgba(239, 68, 68, 0.28);
  box-shadow: 16px 0 48px rgba(3, 1, 10, 0.82), 0 0 36px rgba(220, 38, 38, 0.18);
  transform: translateX(-104%);
  visibility: hidden;
  transition: transform 0.26s cubic-bezier(0.2, 0.9, 0.25, 1), visibility 0.26s ease;
  overflow: hidden;
}
.profile-sidebar.open {
  transform: translateX(0);
  visibility: visible;
}
.ps-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line-strong);
  background: rgba(28, 28, 31, 0.72);
  flex-shrink: 0;
}
.ps-brand-row { display: flex; align-items: center; gap: 10px; }
.ps-brand-row strong { display: block; font-size: 0.98rem; color: #fff; line-height: 1.15; }
.ps-brand-row span { font-size: 0.75rem; }

.ps-tabs-rail {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  background: rgba(14, 14, 17, 0.7);
  flex-shrink: 0;
}
.ps-tab {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 6px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-muted);
  font-size: 0.77rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.16s ease;
}
.ps-tab:hover {
  color: #fff;
  background: rgba(220, 38, 38, 0.14);
  border-color: rgba(239, 68, 68, 0.3);
}
.ps-tab.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.42), rgba(127, 29, 29, 0.48));
  border-color: var(--purple-bright);
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.34);
}
.ps-tab-ico { display: inline-flex; color: var(--purple-bright); }
.ps-tab.active .ps-tab-ico { color: #fff; }
.ps-dot-on {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--win); box-shadow: 0 0 8px var(--win);
}
.ps-badge-pill {
  padding: 1px 5px; border-radius: 999px;
  background: var(--win); color: #052214;
  font-family: var(--font-mono); font-size: 0.66rem; font-weight: 800;
}

.ps-content {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scrollbar-width: thin;
  scrollbar-color: rgba(239, 68, 68, 0.25) transparent;
}
.ps-guest-card {
  padding: 22px 16px;
  border-radius: var(--radius-md);
  background: radial-gradient(circle at 50% 0%, rgba(220, 38, 38, 0.24), transparent 62%), var(--surface-2);
  border: 1px solid var(--purple-line);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.ps-guest-coin { width: 68px; height: 68px; filter: drop-shadow(0 0 18px rgba(220, 38, 38, 0.7)); }
.ps-guest-rune-wrap { margin-top: 4px; }

.ps-hero-card, .ps-section-card {
  padding: 14px;
  border-radius: var(--radius-md);
  background: linear-gradient(155deg, rgba(28, 28, 31, 0.94), rgba(18, 18, 21, 0.98));
  border: 1px solid var(--line-strong);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ps-hero-row { display: flex; align-items: center; gap: 11px; }
.ps-avatar {
  width: 48px; height: 48px; border-radius: 13px;
  background: linear-gradient(135deg, #dc2626, #7f1d1d);
  border: 2px solid var(--purple-bright);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.25rem; font-weight: 800; color: #fff;
  overflow: hidden; flex-shrink: 0;
  box-shadow: 0 0 18px rgba(220, 38, 38, 0.35);
}
.ps-avatar img { width: 100%; height: 100%; object-fit: cover; }
.ps-identity { flex: 1; min-width: 0; }
.ps-name-line { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.ps-name-line strong { font-size: 1rem; color: #fff; overflow: hidden; text-overflow: ellipsis; }
.ps-sub-line { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; margin-top: 4px; }
.dc-mini-tag {
  padding: 2px 7px; border-radius: 999px;
  background: rgba(88, 101, 242, 0.22); border: 1px solid rgba(129, 140, 248, 0.45);
  color: #c7d2fe; font-size: 0.66rem; font-weight: 800;
}
.ps-mini-xp { display: flex; flex-direction: column; gap: 5px; }
.ps-stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ps-action-stack { display: flex; flex-direction: column; gap: 8px; }
.ps-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ps-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.ps-card-head h4 { font-size: 0.94rem; color: #fff; }
.ps-rain-pill {
  padding: 6px 10px; border-radius: 9px;
  background: rgba(34, 229, 139, 0.12); border: 1px solid rgba(34, 229, 139, 0.32);
  text-align: right;
}
.ps-rain-pill span { display: block; font-size: 0.65rem; color: var(--text-muted); text-transform: uppercase; }
.ps-rain-pill strong { font-family: var(--font-mono); font-size: 0.85rem; color: var(--win); }

.bonus-pulse-card {
  background: radial-gradient(circle at 90% 10%, rgba(239, 68, 68, 0.2), transparent 52%),
              linear-gradient(155deg, rgba(28, 28, 31, 0.96), rgba(17, 17, 20, 0.98));
  border-color: var(--purple-line);
}
.ps-media-form { display: flex; flex-direction: column; gap: 8px; }
.ps-media-list { display: flex; flex-direction: column; gap: 7px; }
.ps-media-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 10px 11px; border-radius: 10px;
  background: rgba(255, 255, 255, 0.035); border: 1px solid var(--line);
}
.ps-media-meta { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ps-media-title { font-size: 0.84rem; font-weight: 700; color: #fecaca; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ps-media-title:hover { color: #fff; text-decoration: underline; }
.ps-empty-box {
  padding: 14px; border-radius: 10px; text-align: center;
  border: 1px dashed var(--line-strong); color: var(--text-muted); font-size: 0.79rem;
}
.ps-community-links { display: flex; flex-direction: column; gap: 6px; }
.ps-comm-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 11px; border-radius: 9px;
  background: rgba(220, 38, 38, 0.08); border: 1px solid var(--line);
  font-size: 0.81rem; font-weight: 700; transition: all 0.15s ease;
}
.ps-comm-row:hover { border-color: var(--purple-line); background: rgba(220, 38, 38, 0.18); }

.ps-reward-list, .ps-history-list { display: flex; flex-direction: column; gap: 7px; }
.ps-reward-row, .ps-hist-row {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 9px 10px; border-radius: 10px;
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--line);
}
.ps-reward-row strong, .ps-hist-row strong { display: block; font-size: 0.82rem; color: #fff; }
.ps-reward-row span, .ps-hist-row span { font-size: 0.73rem; }

.ps-discord-card {
  background: radial-gradient(circle at 90% 10%, rgba(88, 101, 242, 0.22), transparent 52%),
              linear-gradient(155deg, rgba(28, 28, 31, 0.96), rgba(17, 17, 20, 0.98));
  border-color: rgba(129, 140, 248, 0.34);
}
.dc-status-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 9px; border-radius: 999px; font-size: 0.71rem; font-weight: 800;
}
.dc-status-pill.connected { background: var(--win-bg); color: var(--win); border: 1px solid rgba(34, 229, 139, 0.4); }
.dc-status-pill.disconnected { background: rgba(255, 255, 255, 0.06); color: var(--text-muted); border: 1px solid var(--line); }
.dc-status-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ps-dc-profile {
  display: flex; align-items: center; gap: 12px;
  padding: 11px; border-radius: 12px;
  background: rgba(88, 101, 242, 0.14); border: 1px solid rgba(129, 140, 248, 0.34);
}
.ps-dc-avatar {
  width: 50px; height: 50px; border-radius: 50%;
  border: 2px solid #818cf8; object-fit: cover; flex-shrink: 0;
}
.ps-dc-note {
  padding: 10px 11px; border-radius: 9px;
  background: rgba(245, 184, 46, 0.1); border: 1px solid rgba(245, 184, 46, 0.35);
  color: #fde68a; font-size: 0.76rem; line-height: 1.45;
  word-break: break-word;
}
.ps-dc-note code {
  display: inline-block; padding: 1px 5px; border-radius: 5px;
  background: rgba(0, 0, 0, 0.42); color: #fff; font-family: var(--font-mono); font-size: 0.72rem;
}

/* ==================== PROMINENT GAME SELECTION MODAL ==================== */
.modal-games-card {
  max-width: 920px;
  width: 100%;
  background: radial-gradient(circle at 85% 0%, rgba(220, 38, 38, 0.22), transparent 46%),
              linear-gradient(165deg, #160e2a 0%, #0b0616 100%);
  border: 1px solid rgba(239, 68, 68, 0.36);
  box-shadow: 0 28px 80px rgba(3, 1, 12, 0.88), 0 0 42px rgba(220, 38, 38, 0.26);
}
.gselect-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-right: 34px;
  margin-bottom: 14px;
}
.gselect-head-right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.gselect-kicker {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  color: var(--purple-bright);
  margin-bottom: 3px;
}
.gselect-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-height: 58dvh;
  overflow-y: auto;
  padding: 2px;
}
.gselect-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, rgba(28, 28, 31, 0.92), rgba(16, 16, 19, 0.98));
  border: 1px solid rgba(239, 68, 68, 0.2);
  overflow: hidden;
  transition: transform 0.2s cubic-bezier(0.2, 0.9, 0.3, 1.2), border-color 0.18s ease, box-shadow 0.22s ease;
}
.gselect-card:hover {
  transform: translateY(-4px) scale(1.01);
  border-color: var(--purple-bright);
  box-shadow: 0 14px 32px rgba(9, 9, 12, 0.65), 0 0 26px rgba(220, 38, 38, 0.42);
}
.gselect-card.selected {
  border-color: #ef4444;
  box-shadow: 0 0 0 1px #ef4444, 0 14px 34px rgba(220, 38, 38, 0.48);
}
.gselect-art {
  position: relative;
  height: 108px;
  background: radial-gradient(circle at 50% 0%, rgba(220, 38, 38, 0.24), transparent 72%), #0d071b;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--line);
}
.gselect-cat-pill, .gselect-active-pill {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}
.gselect-cat-pill {
  background: rgba(13, 13, 16, 0.78);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
}
.gselect-active-pill {
  background: linear-gradient(135deg, #dc2626, #ef4444);
  color: #fff;
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.7);
}
.gselect-body { padding: 11px 12px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.gselect-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.gselect-name { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: 0.95rem; color: #fff; }
.gselect-name svg { color: var(--purple-bright); }
.gselect-blurb { font-size: 0.75rem; color: var(--text-muted); line-height: 1.35; }
.gselect-foot { margin-top: auto; padding-top: 6px; display: flex; align-items: center; justify-content: space-between; }
.gselect-play-txt { font-size: 0.76rem; font-weight: 800; color: var(--purple-bright); }
.gselect-card:hover .gselect-play-txt { color: #fff; }
.gselect-quick-links { display: flex; gap: 7px; flex-wrap: wrap; }

/* ==================== HOMEPAGE HERO, LEVEL PREVIEW & EVENTS SPOTLIGHT ==================== */
.hero-card {
  background: radial-gradient(circle at 86% 42%, rgba(220, 38, 38, 0.34), transparent 52%),
              radial-gradient(circle at 12% 90%, rgba(220, 38, 38, 0.22), transparent 50%),
              linear-gradient(145deg, #16161a 0%, #111114 62%, #09090b 100%);
  border: 1px solid rgba(239, 68, 68, 0.28);
  box-shadow: 0 18px 46px rgba(9, 9, 12, 0.62), inset 0 1px 0 rgba(255, 255, 255, 0.14);
}
.hero-emblem-ring {
  border-color: rgba(239, 68, 68, 0.45);
  box-shadow: 0 0 42px rgba(220, 38, 38, 0.45), inset 0 0 28px rgba(239, 68, 68, 0.25);
}
.hero-emblem-coin {
  filter: drop-shadow(0 0 28px rgba(220, 38, 38, 0.78));
  animation: heroCoinFloat 4.2s ease-in-out infinite;
}
@keyframes heroCoinFloat {
  0%, 100% { transform: translateY(0px) rotate(-2deg); }
  50% { transform: translateY(-7px) rotate(2deg); }
}

.home-level-preview {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  gap: 14px;
  margin-bottom: 22px;
}
.home-lvl-card, .home-bonus-card {
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  background: linear-gradient(155deg, rgba(28, 28, 31, 0.96), rgba(16, 16, 19, 0.98));
  border: 1px solid var(--line-strong);
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: var(--shadow-card);
}
.home-bonus-card {
  background: radial-gradient(circle at 92% 14%, rgba(239, 68, 68, 0.22), transparent 52%),
              linear-gradient(155deg, rgba(28, 28, 31, 0.96), rgba(16, 16, 19, 0.98));
  border-color: var(--purple-line);
}

/* Animated Shimmer XP Bar */
.xp-bar-fill {
  background: linear-gradient(90deg, #b91c1c 0%, #dc2626 50%, #ef4444 100%);
  position: relative;
  overflow: hidden;
}
.xp-bar-fill.shimmer::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 15%, rgba(255, 255, 255, 0.35) 50%, transparent 85%);
  animation: xpShimmer 2.4s linear infinite;
}
@keyframes xpShimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* Tier-Specific Level Badges (Distinct Visual Designs for Level Ranges) */
.lvl-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--rk-color, var(--purple-bright));
  background: rgba(220, 38, 38, 0.14);
  border: 1px solid var(--rk-color, var(--purple-line));
  white-space: nowrap;
}
.lvl-pill.tier-amethyst, .lvl-pill.tier-diamond, .lvl-pill.tier-netherite {
  box-shadow: 0 0 12px color-mix(in srgb, var(--rk-color, #dc2626) 42%, transparent);
}
.lvl-pill.tier-netherite {
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.32), rgba(220, 38, 38, 0.42));
  color: #fef2f2;
  border-color: #fca5a5;
}
.chat-lvl-tag {
  font-family: var(--font-mono);
  font-size: 0.63rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 5px;
  margin-right: 4px;
  background: rgba(220, 38, 38, 0.18);
  border: 1px solid rgba(239, 68, 68, 0.32);
  color: #fecaca;
  vertical-align: middle;
}

/* ==================== SPECIAL EVENTS: DONUTTRIX LETTER HUNT ==================== */
.event-spotlight-card, .events-hero {
  padding: 20px 22px;
  border-radius: var(--radius-lg);
  background: radial-gradient(circle at 88% 12%, rgba(220, 38, 38, 0.24), transparent 50%),
              radial-gradient(circle at 12% 92%, rgba(220, 38, 38, 0.22), transparent 52%),
              linear-gradient(150deg, #16161a 0%, #111114 60%, #09090b 100%);
  border: 1px solid rgba(255, 255, 255, 0.34);
  box-shadow: 0 18px 46px rgba(9, 9, 12, 0.58), 0 0 30px rgba(220, 38, 38, 0.18);
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 22px;
}
.event-spotlight-head, .events-hero-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.event-spotlight-head h2, .events-hero-top h1 {
  font-size: clamp(1.35rem, 2.2vw, 1.95rem);
  color: #fff;
  margin: 6px 0 4px;
}
.event-live-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(220, 38, 38, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.42);
  font-size: 0.72rem;
  font-weight: 800;
  color: #fee2e2;
  letter-spacing: 0.04em;
}
.live-pulse {
  width: 8px; height: 8px; border-radius: 50%;
  background: #ef4444; box-shadow: 0 0 12px #ef4444;
  animation: pulseDot 1.6s ease-in-out infinite;
}
.event-reward-pill, .event-grand-box {
  padding: 12px 18px;
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(220, 38, 38, 0.26), rgba(127, 29, 29, 0.32));
  border: 1px solid rgba(239, 68, 68, 0.48);
  text-align: center;
  box-shadow: 0 0 26px rgba(220, 38, 38, 0.32);
  flex-shrink: 0;
}
.event-reward-pill span, .event-grand-box span {
  display: block; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.08em; color: #fecaca;
}
.event-reward-pill strong { font-size: 1.35rem; color: var(--gold); }
.event-grand-box strong { font-size: 2rem; color: var(--gold); line-height: 1.1; }

.hunt-tiles-row {
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 8px;
}
.hunt-tile {
  position: relative;
  aspect-ratio: 1 / 1.05;
  max-height: 68px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: clamp(1rem, 2vw, 1.45rem);
  font-weight: 800;
  background: rgba(12, 12, 15, 0.68);
  border: 1px dashed rgba(239, 68, 68, 0.32);
  color: var(--text-faint);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.hunt-tile.found {
  border-style: solid;
  border-color: #ef4444;
  color: #fff;
  background: linear-gradient(145deg, rgba(220, 38, 38, 0.45), rgba(127, 29, 29, 0.58));
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.28);
  text-shadow: 0 0 12px rgba(239, 68, 68, 0.85);
}
.hunt-tile-idx {
  position: absolute;
  bottom: 4px;
  right: 6px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  opacity: 0.55;
}
.event-spotlight-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.event-prog-wrap { flex: 1; min-width: 220px; display: flex; flex-direction: column; gap: 6px; }
.event-prog-meta { display: flex; justify-content: space-between; font-size: 0.81rem; color: var(--text-muted); }

.hunt-clues-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.hunt-clue-card {
  padding: 14px;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, rgba(28, 28, 31, 0.94), rgba(15, 15, 18, 0.98));
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.18s ease, transform 0.18s ease;
}
.hunt-clue-card:hover { transform: translateY(-2px); border-color: var(--purple-line); }
.hunt-clue-card.found { border-color: rgba(34, 229, 139, 0.4); background: linear-gradient(160deg, rgba(19, 34, 34, 0.82), rgba(15, 15, 18, 0.98)); }
.hunt-clue-top { display: flex; align-items: center; gap: 10px; }
.hunt-clue-top strong { display: block; font-size: 0.86rem; color: #fff; }
.hunt-clue-badge {
  width: 38px; height: 38px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 800; font-size: 1.1rem;
  background: rgba(220, 38, 38, 0.16); border: 1px solid var(--purple-line); color: var(--purple-bright);
  flex-shrink: 0;
}
.hunt-clue-badge.found { background: var(--win-bg); border-color: var(--win); color: var(--win); }
.hunt-status-pill {
  display: inline-block; margin-top: 2px; padding: 1px 7px; border-radius: 999px;
  font-family: var(--font-mono); font-size: 0.65rem; font-weight: 800;
  background: rgba(220, 38, 38, 0.18); color: #fecaca;
}
.hunt-status-pill.found { background: var(--win-bg); color: var(--win); }
.hunt-clue-foot { margin-top: auto; }

/* ==================== UPGRADED RACE LEADERBOARD PODIUM & COUNTDOWNS ==================== */
.race-banner-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 13px 16px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.2), rgba(23, 23, 26, 0.95));
  border: 1px solid var(--purple-line);
  margin-bottom: 14px;
}
.race-prizes-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.race-prize-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px; border-radius: 999px;
  background: rgba(12, 12, 15, 0.65); border: 1px solid var(--line-strong);
  font-size: 0.77rem; font-weight: 700;
}
.race-prize-chip.p1 { border-color: rgba(245, 184, 46, 0.55); color: var(--gold); }
.race-prize-chip.p2 { border-color: rgba(203, 213, 225, 0.45); color: #e2e8f0; }
.race-prize-chip.p3 { border-color: rgba(217, 119, 6, 0.5); color: #fbbf24; }
.race-countdown-box {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 10px;
  background: rgba(12, 12, 15, 0.72); border: 1px solid rgba(239, 68, 68, 0.34);
  font-size: 0.79rem; color: var(--text-muted);
}
.race-countdown-box strong { color: var(--purple-bright); font-size: 0.9rem; }

.lb-podium-v2 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  align-items: end;
  margin-bottom: 16px;
}
.lb-podium-card.p1 {
  order: 2;
  padding-top: 22px;
  padding-bottom: 20px;
  border-color: rgba(245, 184, 46, 0.68);
  box-shadow: 0 18px 42px rgba(9, 9, 12, 0.62), 0 0 28px rgba(245, 184, 46, 0.22);
}
.lb-podium-card.p2 {
  order: 1;
  border-color: rgba(203, 213, 225, 0.48);
  box-shadow: 0 14px 32px rgba(9, 9, 12, 0.5), 0 0 18px rgba(239, 68, 68, 0.16);
}
.lb-podium-card.p3 {
  order: 3;
  border-color: rgba(217, 119, 6, 0.52);
  box-shadow: 0 14px 32px rgba(9, 9, 12, 0.5), 0 0 18px rgba(217, 119, 6, 0.14);
}
.lb-podium-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.lb-prize-pill {
  padding: 3px 9px; border-radius: 999px;
  font-family: var(--font-mono); font-size: 0.72rem; font-weight: 800;
  background: rgba(220, 38, 38, 0.22); border: 1px solid var(--purple-line); color: #fee2e2;
}
.lb-podium-card.p1 .lb-prize-pill { background: rgba(245, 184, 46, 0.2); border-color: rgba(245, 184, 46, 0.55); color: var(--gold); }
.lb-podium-avatar-row { display: flex; align-items: center; gap: 10px; }
.lb-avatar {
  width: 40px; height: 40px; border-radius: 11px;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 800; font-size: 1rem; color: #fff;
  background: linear-gradient(135deg, #dc2626, #7f1d1d);
  border: 2px solid var(--purple-bright);
  flex-shrink: 0;
}
.lb-podium-card.p1 .lb-avatar { width: 46px; height: 46px; border-color: var(--gold); box-shadow: 0 0 16px rgba(245, 184, 46, 0.45); }
.lb-avatar.sm { width: 28px; height: 28px; border-radius: 8px; font-size: 0.76rem; border-width: 1px; }
.lb-virtual-note {
  margin-top: 10px;
  font-size: 0.76rem;
  color: var(--text-faint);
  text-align: center;
}

/* ==================== ACTIVITY TASKS & CELEBRATION MODAL ==================== */
.activity-tasks-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.activity-task-card {
  padding: 13px 14px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.activity-task-card strong { display: block; font-size: 0.86rem; color: #fff; }
.activity-task-card p { font-size: 0.75rem; color: var(--text-muted); margin-top: 2px; }

.celebration-card {
  text-align: center;
  align-items: center;
  background: radial-gradient(circle at 50% 10%, rgba(220, 38, 38, 0.34), transparent 56%),
              linear-gradient(160deg, #1e113a 0%, #0b0618 100%);
  border: 1px solid rgba(239, 68, 68, 0.55);
  box-shadow: 0 24px 80px rgba(3, 1, 14, 0.9), 0 0 54px rgba(220, 38, 38, 0.45);
  overflow: hidden;
}
.cel-halo {
  width: 72px; height: 72px; border-radius: 50%;
  background: radial-gradient(circle, rgba(239, 68, 68, 0.9), rgba(220, 38, 38, 0.25) 60%, transparent 72%);
  box-shadow: 0 0 42px rgba(220, 38, 38, 0.75);
  margin-bottom: 4px;
  animation: celPulse 1.6s ease-in-out infinite;
}
.cel-letter-showcase {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 4px 0 6px;
}
.cel-letter-tile {
  width: 78px;
  height: 82px;
  border-radius: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(145deg, #ef4444 0%, #dc2626 55%, #991b1b 100%);
  border: 2px solid #fee2e2;
  box-shadow: 0 0 36px rgba(220, 38, 38, 0.85), 0 0 70px rgba(220, 38, 38, 0.55), inset 0 2px 0 rgba(255, 255, 255, 0.45);
  text-shadow: 0 0 18px rgba(255, 255, 255, 0.9);
  animation: celLetterPop 0.55s cubic-bezier(0.2, 1.35, 0.35, 1);
}
@keyframes celLetterPop {
  0% { transform: scale(0.3) rotate(-14deg); opacity: 0; }
  70% { transform: scale(1.12) rotate(4deg); opacity: 1; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}
@keyframes celPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}
.cel-badge {
  padding: 3px 12px; border-radius: 999px;
  background: rgba(220, 38, 38, 0.28); border: 1px solid rgba(239, 68, 68, 0.6);
  color: #fee2e2; font-family: var(--font-mono); font-size: 0.72rem; font-weight: 800; letter-spacing: 0.08em;
}
.cel-reward-box {
  width: 100%;
  padding: 14px;
  border-radius: 12px;
  background: rgba(12, 12, 15, 0.68);
  border: 1px solid rgba(245, 184, 46, 0.45);
  color: var(--gold);
  font-size: 1.35rem;
  font-weight: 800;
}

/* Withdraw modal /settings payments warning */
.withdraw-warn-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 13px;
  margin-bottom: 12px;
  border-radius: 12px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 184, 46, 0.42);
  color: #fde68a;
  font-size: 0.82rem;
  line-height: 1.45;
}
.withdraw-warn-banner .warn-ico {
  flex: 0 0 auto;
  font-size: 1.05rem;
  line-height: 1.2;
  color: #fbbf24;
}
.withdraw-warn-banner strong {
  display: block;
  color: #fef3c7;
  font-weight: 700;
  margin-bottom: 2px;
}
.withdraw-warn-banner span {
  display: block;
  color: rgba(253, 230, 138, 0.88);
}
.withdraw-warn-banner code {
  padding: 1px 5px;
  border-radius: 5px;
  background: rgba(19, 19, 22, 0.65);
  border: 1px solid rgba(245, 184, 46, 0.35);
  color: #fef08a;
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

/* ==================== REDESIGNED PANEL GUI, REWARD POINTS & DEDICATED ADMIN CONSOLE ==================== */
.wd-rp-row {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed rgba(255, 255, 255, 0.08);
}
.privacy-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  background: rgba(56, 189, 248, 0.14);
  border: 1px solid rgba(56, 189, 248, 0.34);
  color: #7dd3fc;
}
.rp-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  background: rgba(245, 184, 46, 0.14);
  border: 1px solid rgba(245, 184, 46, 0.38);
  color: #fde68a;
  white-space: nowrap;
}
.rp-stat {
  border-color: rgba(245, 184, 46, 0.28) !important;
  background: linear-gradient(155deg, rgba(245, 184, 46, 0.08), rgba(20, 20, 23, 0.92)) !important;
}
.ps-rp-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 13px;
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, rgba(245, 184, 46, 0.1), rgba(23, 23, 26, 0.94));
  border: 1px solid rgba(245, 184, 46, 0.28);
}
.ps-rp-banner strong {
  display: block;
  font-size: 0.8rem;
  color: #fef08a;
  margin-bottom: 2px;
}
.ps-rp-banner span.muted {
  display: block;
  font-size: 0.7rem;
  line-height: 1.35;
}
.rain-free-tag {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #fde68a;
  background: rgba(245, 184, 46, 0.12);
  border: 1px solid rgba(245, 184, 46, 0.28);
  border-radius: 6px;
  padding: 3px 7px;
  text-align: center;
}

/* Modernized Slide-Out Player Panel Polish */
.profile-sidebar {
  background: linear-gradient(180deg, rgba(19, 19, 22, 0.985), rgba(11, 11, 14, 0.995));
  border-left: 1px solid rgba(239, 68, 68, 0.24);
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.65);
}
.ps-header {
  background: linear-gradient(180deg, rgba(220, 38, 38, 0.12), transparent);
  border-bottom: 1px solid rgba(239, 68, 68, 0.16);
}
.ps-tabs-rail {
  gap: 6px;
  padding: 10px 12px;
  background: rgba(13, 13, 16, 0.7);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.ps-tab {
  border-radius: 10px;
  border: 1px solid transparent;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, transform 0.14s ease;
}
.ps-tab.active {
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.28), rgba(220, 38, 38, 0.18));
  border-color: rgba(239, 68, 68, 0.45);
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.22);
}
.ps-section-card {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(165deg, rgba(28, 28, 31, 0.88), rgba(16, 16, 19, 0.96));
}

/* Dedicated Admin Operations Console */
.admin-gate-card {
  max-width: 520px;
  margin: 24px auto;
  border: 1px solid rgba(239, 68, 68, 0.28);
}
.admin-gate-badge {
  display: inline-flex;
  align-self: flex-start;
  padding: 3px 9px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  background: rgba(220, 38, 38, 0.18);
  border: 1px solid rgba(239, 68, 68, 0.38);
  color: #fecaca;
}
.admin-console {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.admin-hero-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 20px 22px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(28, 28, 31, 0.94), rgba(18, 18, 21, 0.98));
  border: 1px solid rgba(239, 68, 68, 0.28);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.35);
}
.admin-kicker {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  color: #f87171;
  margin-bottom: 6px;
}
.admin-hero-bar h1 {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}
.admin-hero-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.admin-kpi-card {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, rgba(28, 28, 31, 0.92), rgba(16, 16, 19, 0.98));
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-card);
}
.admin-kpi-card span {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}
.admin-kpi-card strong {
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
}
.admin-kpi-card small {
  font-size: 0.74rem;
  color: var(--text-faint);
}
.admin-kpi-card.kpi-dep strong,
.admin-kpi-card.kpi-pos strong { color: var(--win); }
.admin-kpi-card.kpi-wd strong,
.admin-kpi-card.kpi-neg strong { color: var(--crimson-bright); }
.admin-kpi-card.kpi-dep { border-color: rgba(34, 229, 139, 0.25); }
.admin-kpi-card.kpi-wd { border-color: rgba(244, 63, 94, 0.25); }

.admin-layout {
  display: grid;
  grid-template-columns: 224px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.admin-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px;
  border-radius: var(--radius-lg);
  background: linear-gradient(165deg, rgba(26, 26, 29, 0.94), rgba(15, 15, 18, 0.98));
  border: 1px solid var(--line-strong);
  position: sticky;
  top: 124px;
}
.admin-nav-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}
.admin-nav-btn:hover {
  background: rgba(220, 38, 38, 0.1);
  color: #fff;
}
.admin-nav-btn.active {
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.26), rgba(220, 38, 38, 0.16));
  border-color: rgba(239, 68, 68, 0.42);
  color: #fff;
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.2);
}
.admin-nav-badge {
  padding: 2px 7px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
}
.admin-nav-badge.alert {
  background: rgba(244, 63, 94, 0.22);
  color: #fda4af;
  border: 1px solid rgba(244, 63, 94, 0.4);
}
.admin-panel {
  min-width: 0;
}
.admin-panel-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.admin-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  background: linear-gradient(165deg, rgba(26, 26, 29, 0.94), rgba(15, 15, 18, 0.98));
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-card);
  min-width: 0;
}
.admin-card.span-2 { grid-column: 1 / -1; }
.admin-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.admin-card-head h3 {
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin-bottom: 2px;
}
.admin-card-head p {
  font-size: 0.8rem;
}
.admin-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.admin-filter-pills {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.admin-pill {
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}
.admin-pill:hover { color: #fff; border-color: rgba(239, 68, 68, 0.35); }
.admin-pill.active {
  background: rgba(220, 38, 38, 0.24);
  border-color: rgba(239, 68, 68, 0.5);
  color: #fee2e2;
}
.admin-search {
  max-width: 260px;
  height: 34px;
  font-size: 0.8rem;
}
.admin-table th {
  font-size: 0.7rem;
  letter-spacing: 0.07em;
}
.admin-table td {
  padding-top: 10px;
  padding-bottom: 10px;
}

/* ==================== RESPONSIVE POLISH FOR NEW MASTER COMPONENTS ==================== */
@container maincol (max-width: 960px) {
  .admin-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-nav {
    position: static;
    flex-direction: row;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .admin-nav-btn { width: auto; white-space: nowrap; }
}
@container maincol (max-width: 900px) {
  .home-level-preview { grid-template-columns: 1fr; }
  .hunt-clues-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lb-podium-v2 { grid-template-columns: 1fr; align-items: stretch; }
  .lb-podium-card.p1, .lb-podium-card.p2, .lb-podium-card.p3 { order: initial; }
}
@container maincol (max-width: 640px) {
  .hunt-clues-grid, .activity-tasks-grid, .admin-panel-grid { grid-template-columns: 1fr; }
  .hunt-tiles-row { gap: 5px; }
  .admin-search { max-width: none; width: 100%; }
}
@media (max-width: 960px) {
  .gselect-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-nav { position: static; flex-direction: row; overflow-x: auto; }
  .admin-nav-btn { width: auto; white-space: nowrap; }
}
@media (max-width: 860px) {
  .btn-games-cta { display: none; }
  .profile-access-btn { height: 35px; padding: 3px 6px 3px 4px; }
  .profile-access-btn .user-name, .profile-access-btn .user-lvl-badge { display: none !important; }
  .gselect-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 55dvh; }
  .lb-podium-v2 { grid-template-columns: 1fr; }
  .lb-podium-card.p1, .lb-podium-card.p2, .lb-podium-card.p3 { order: initial; }
  .home-level-preview { grid-template-columns: 1fr; }
  .hunt-clues-grid, .activity-tasks-grid, .admin-panel-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .gselect-grid { grid-template-columns: 1fr; }
  .admin-kpi-grid { grid-template-columns: 1fr; }
  .admin-hero-bar, .admin-card { padding: 14px; }
  .hunt-tiles-row { gap: 4px; }
  .hunt-tile { border-radius: 8px; }
  .event-spotlight-card, .events-hero { padding: 15px 14px; }
}

/* ==================== BOT BALANCE TAB, CRASH AUTO-CASHOUT & FORCED DISPLAY NAME ==================== */
.nav-bot-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.wd-bot-row {
  display: block;
  text-decoration: none;
  border-top: 1px dashed rgba(34, 229, 139, 0.22);
  background: rgba(34, 229, 139, 0.06);
  transition: background 0.16s ease;
}
.wd-bot-row:hover {
  background: rgba(34, 229, 139, 0.13);
}
.bot-vault-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px;
  padding: 24px 26px;
  border-radius: 18px;
  background:
    radial-gradient(circle at 90% 15%, rgba(34, 229, 139, 0.16), transparent 46%),
    linear-gradient(155deg, rgba(24, 24, 27, 0.96), rgba(14, 14, 17, 0.98));
  border: 1px solid rgba(34, 229, 139, 0.26);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.36);
}
.bot-vault-big {
  font-size: clamp(2rem, 4.4vw, 3.1rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--win);
  line-height: 1.05;
  margin: 6px 0 4px;
}
.bot-vault-exact {
  font-size: 0.88rem;
  color: var(--text-dim);
}
.bot-vault-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}
@media (max-width: 760px) {
  .bot-vault-grid { grid-template-columns: 1fr; }
}
.crash-auto-pill {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 3;
  padding: 5px 11px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--win);
  background: rgba(12, 28, 22, 0.85);
  border: 1px solid rgba(34, 229, 139, 0.45);
  box-shadow: 0 4px 16px rgba(34, 229, 139, 0.18);
}
.dn-modal-card {
  border-color: rgba(220, 38, 38, 0.45);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(220, 38, 38, 0.2);
}
.modal-locked {
  backdrop-filter: blur(10px);
}

/* ==================== BIGGER 2-LINE CHAT CARDS & MINECRAFT SKIN PFPS ==================== */
.mc-skin-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}
.user-avatar,
.lb-avatar {
  overflow: hidden;
  padding: 0;
}
.user-avatar img,
.lb-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  image-rendering: pixelated;
}
.chat-messages {
  padding: 12px 12px;
  gap: 9px;
}
.chat-msg {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 11px 12px;
  border-radius: 13px;
  background: linear-gradient(155deg, rgba(28, 28, 31, 0.92), rgba(19, 19, 22, 0.96));
  border: 1px solid rgba(239, 68, 68, 0.16);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.28);
  font-size: 0.9rem;
  line-height: 1.42;
  transition: transform 0.14s ease, background 0.14s ease, border-color 0.14s ease;
}
.chat-msg:hover {
  background: linear-gradient(155deg, rgba(28, 28, 31, 0.96), rgba(25, 25, 28, 0.98));
  border-color: rgba(239, 68, 68, 0.38);
}
.chat-msg.staff-msg {
  background: linear-gradient(155deg, rgba(28, 28, 31, 0.95), rgba(22, 22, 25, 0.98));
  border-color: rgba(239, 68, 68, 0.36);
}
.chat-msg.high-lvl-msg {
  border-color: rgba(220, 38, 38, 0.34);
}
.chat-pfp {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
  background: #141418;
  border: 1.5px solid var(--pfp-ring, rgba(239, 68, 68, 0.55));
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
}
.chat-pfp.system-pfp {
  border-color: rgba(245, 184, 46, 0.65);
  background: radial-gradient(circle, rgba(245, 184, 46, 0.25), rgba(23, 23, 26, 0.95));
  padding: 4px;
}
.chat-pfp.system-pfp img {
  image-rendering: auto;
  object-fit: contain;
}
.chat-msg-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.chat-msg-head {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  line-height: 1.2;
}
.chat-user {
  font-weight: 800;
  font-size: 0.88rem;
  color: #f4f4f5;
  margin-right: 0;
  letter-spacing: -0.01em;
}
.chat-lvl-pill {
  font-size: 0.65rem;
  padding: 1px 6px;
  border-radius: 6px;
}
.chat-msg-text {
  font-size: 0.92rem;
  font-weight: 500;
  color: #e4e4e7;
  line-height: 1.44;
  word-break: break-word;
}
.chat-msg.system-msg .chat-msg-text {
  color: #fde68a;
  font-weight: 600;
}
.admin-table th,
.admin-table td {
  padding-left: 10px;
  padding-right: 10px;
}

/* ==================== ROLES: OWNER (RED + BLACK), CO-OWNER (ONLY RED), ADMIN (GOLD), MOD (BLUE) ==================== */
.role-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 5px;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.25;
  white-space: nowrap;
  vertical-align: middle;
}
.role-badge.owner {
  background: linear-gradient(135deg, #060608 0%, #140407 48%, #dc2626 100%);
  color: #ffffff;
  border: 1px solid #ef4444;
  box-shadow: none;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.85);
}
.role-badge.co_owner,
.role-badge.co-owner {
  background: #dc2626;
  color: #ffffff;
  border: 1px solid #f87171;
  box-shadow: none;
  text-shadow: none;
}
.role-badge.admin {
  background: rgba(240, 177, 50, 0.16);
  color: #f0b132;
  border: 1px solid rgba(240, 177, 50, 0.44);
  box-shadow: none;
}
.role-badge.mod {
  background: rgba(56, 189, 248, 0.16);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.44);
}
.role-badge.bot {
  background: rgba(148, 163, 184, 0.14);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.34);
}
.chat-msg.owner-msg {
  background: linear-gradient(135deg, #070709 0%, #160508 58%, #2c080d 100%);
  border-color: #dc2626;
  border-left: 3px solid #ef4444;
  box-shadow: none;
}
.chat-msg.co-owner-msg {
  background: rgba(220, 38, 38, 0.22);
  border-color: #ef4444;
  border-left: 3px solid #f87171;
  box-shadow: none;
}
.chat-msg.owner-msg .chat-user {
  color: #ffffff;
}
.chat-msg.co-owner-msg .chat-user {
  color: #fecaca;
}

/* ==================== HOMEPAGE SIDE STACK: TOP WAGER OF THE DAY & COMPACT DISCORD ==================== */
.hero-side-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
  justify-content: space-between;
}
.top-wager-hero-card {
  padding: 15px 16px;
  border-radius: 16px;
  background:
    radial-gradient(circle at 92% 12%, rgba(245, 184, 46, 0.24), transparent 52%),
    linear-gradient(155deg, rgba(28, 28, 31, 0.97), rgba(17, 17, 20, 0.99));
  border: 1px solid rgba(245, 184, 46, 0.42);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.38), 0 0 22px rgba(245, 184, 46, 0.14);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.twd-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}
.twd-crown-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #140c02;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.38);
}
.twd-reset-pill {
  font-size: 0.68rem;
  color: #fde68a;
  background: rgba(245, 184, 46, 0.12);
  border: 1px solid rgba(245, 184, 46, 0.28);
  padding: 2px 8px;
  border-radius: 999px;
}
.twd-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.twd-player {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.twd-avatar {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  overflow: hidden;
  flex-shrink: 0;
  border: 2px solid #fbbf24;
  box-shadow: 0 0 14px rgba(251, 191, 36, 0.42);
  background: #141418;
}
.twd-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.twd-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.twd-name {
  font-size: 0.96rem;
  color: #fff;
}
.twd-stats {
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.twd-lbl {
  font-size: 0.68rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.twd-val {
  font-size: 1.05rem;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
}
.twd-prize {
  font-size: 0.7rem;
  color: var(--win);
  font-weight: 700;
}
.twd-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(245, 184, 46, 0.18);
  font-size: 0.75rem;
}
.twd-link {
  color: #fde68a;
  font-weight: 700;
  text-decoration: none;
}
.twd-link:hover {
  text-decoration: underline;
}
.top-wager-podium {
  border-color: rgba(251, 191, 36, 0.65) !important;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45), 0 0 28px rgba(251, 191, 36, 0.24) !important;
}
.twd-podium-crown {
  margin-bottom: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #140c02;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  display: inline-block;
}
.twd-table-row {
  background: linear-gradient(90deg, rgba(245, 184, 46, 0.14), rgba(245, 184, 46, 0.03)) !important;
}
.twd-table-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.63rem;
  font-weight: 800;
  color: #140c02;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}

/* Compact Stylish Homepage Discord Banner */
.discord-compact-card {
  padding: 14px 16px;
  border-radius: 16px;
  background:
    radial-gradient(circle at 88% 20%, rgba(88, 101, 242, 0.28), transparent 55%),
    linear-gradient(155deg, rgba(28, 28, 31, 0.96), rgba(18, 18, 21, 0.99));
  border: 1px solid rgba(129, 140, 248, 0.34);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.32);
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.dc-compact-left {
  display: flex;
  align-items: center;
  gap: 11px;
}
.dc-compact-icon {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  background: linear-gradient(135deg, #5865f2, #4752c4);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 6px 16px rgba(88, 101, 242, 0.4);
}
.dc-compact-copy {
  min-width: 0;
  flex: 1;
}
.dc-compact-title-row {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}
.dc-compact-title-row strong {
  font-size: 0.92rem;
  color: #fff;
}
.dc-live-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 1px 7px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 800;
  color: #c7d2fe;
  background: rgba(88, 101, 242, 0.24);
  border: 1px solid rgba(129, 140, 248, 0.4);
}
.dc-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22e58b;
  box-shadow: 0 0 8px #22e58b;
}
.dc-compact-copy p {
  font-size: 0.77rem;
  color: var(--text-dim);
  margin: 3px 0 0;
  line-height: 1.35;
}
.dc-compact-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.btn-discord-join {
  background: linear-gradient(135deg, #5865f2, #4f46e5);
  color: #fff;
  border: 1px solid rgba(165, 180, 252, 0.45);
  box-shadow: 0 6px 18px rgba(88, 101, 242, 0.35);
  font-weight: 800;
  flex: 1;
  justify-content: center;
}
.btn-discord-join:hover {
  background: linear-gradient(135deg, #6370f7, #5b52f0);
  transform: translateY(-1px);
}

/* ==================== CASE BATTLES SYSTEM ==================== */
.cb-builder-card {
  padding: 20px 22px;
  border-radius: 18px;
  background:
    radial-gradient(circle at 90% 10%, rgba(220, 38, 38, 0.2), transparent 48%),
    linear-gradient(155deg, rgba(27, 27, 30, 0.97), rgba(14, 14, 17, 0.99));
  border: 1px solid rgba(239, 68, 68, 0.3);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.cb-builder-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.cb-summary-metrics {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.cb-metric {
  padding: 8px 14px;
  border-radius: 12px;
  background: rgba(15, 15, 18, 0.8);
  border: 1px solid rgba(239, 68, 68, 0.25);
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.cb-metric span {
  font-size: 0.68rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.cb-metric strong {
  font-size: 1.1rem;
  color: var(--win);
}
.cb-case-picker {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 11px;
}
.cb-case-tile {
  padding: 13px;
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(28, 28, 31, 0.9), rgba(17, 17, 20, 0.96));
  border: 1px solid rgba(239, 68, 68, 0.22);
  display: flex;
  flex-direction: column;
  gap: 7px;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.cb-case-tile.selected {
  border-color: var(--case-color, #dc2626);
  box-shadow: 0 0 22px color-mix(in srgb, var(--case-color, #dc2626) 32%, transparent);
}
.cb-case-tile-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.cb-case-price {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--gold);
  background: rgba(245, 184, 46, 0.14);
  border: 1px solid rgba(245, 184, 46, 0.34);
  padding: 2px 8px;
  border-radius: 999px;
}
.cb-case-qty {
  font-size: 0.76rem;
  font-weight: 800;
  color: #fff;
  background: var(--case-color, #dc2626);
  padding: 2px 8px;
  border-radius: 999px;
}
.cb-case-icon-box {
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cb-case-coin {
  width: 38px;
  height: 38px;
  filter: drop-shadow(0 0 10px var(--case-color, #dc2626));
}
.cb-case-title {
  font-size: 0.92rem;
  color: #fff;
  text-align: center;
}
.cb-case-top-drop {
  font-size: 0.7rem;
  color: var(--win);
  text-align: center;
}
.cb-case-items-list {
  font-size: 0.68rem;
  color: var(--text-dim);
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-align: center;
}
.cb-case-btns {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
}
.cb-case-btns .btn {
  flex: 1;
}
.cb-builder-controls {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding-top: 12px;
  border-top: 1px solid rgba(239, 68, 68, 0.18);
}
.cb-selected-queue {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.cb-queue-pills {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.cb-queue-pill,
.cb-round-case-pill {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  color: #fee2e2;
  background: rgba(220, 38, 38, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.38);
  cursor: pointer;
}
.cb-round-case-pill {
  cursor: default;
}
.cb-config-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.cb-config-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.cb-toggle-group {
  display: inline-flex;
  background: rgba(13, 13, 16, 0.85);
  border: 1px solid rgba(239, 68, 68, 0.24);
  border-radius: 10px;
  padding: 3px;
  gap: 4px;
}
.cb-toggle-btn {
  padding: 6px 12px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-dim);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.14s ease, color 0.14s ease;
}
.cb-toggle-btn.active {
  background: linear-gradient(135deg, #b91c1c, #dc2626);
  color: #fff;
}
.cb-launch-btns {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* Active Case Battle Arena */
.cb-arena-card {
  padding: 20px;
  border-radius: 18px;
  background: linear-gradient(155deg, rgba(25, 25, 28, 0.97), rgba(12, 12, 15, 0.99));
  border: 1px solid rgba(239, 68, 68, 0.3);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.42);
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.cb-arena-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.cb-arena-tags {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}
.cb-arena-pot-box {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(13, 13, 16, 0.82);
  border: 1px solid rgba(239, 68, 68, 0.22);
}
.cb-arena-pot-box > div span {
  display: block;
  font-size: 0.66rem;
  color: var(--text-dim);
  text-transform: uppercase;
}
.cb-arena-pot-box > div strong {
  font-size: 1rem;
}
.cb-cases-strip {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  padding: 9px 12px;
  border-radius: 11px;
  background: rgba(15, 15, 18, 0.68);
  border: 1px solid rgba(239, 68, 68, 0.16);
}
.cb-participants-grid {
  display: grid;
  gap: 12px;
}
.cb-participants-grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cb-participants-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cb-participants-grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cb-participant-col {
  padding: 14px;
  border-radius: 14px;
  background: rgba(17, 17, 20, 0.92);
  border: 1px solid rgba(239, 68, 68, 0.22);
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.cb-participant-col.is-winner {
  border-color: #fbbf24;
  background:
    radial-gradient(circle at 50% 0%, rgba(251, 191, 36, 0.18), transparent 55%),
    rgba(21, 21, 24, 0.96);
  box-shadow: 0 0 26px rgba(251, 191, 36, 0.22);
}
.cb-winner-crown {
  padding: 5px 10px;
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 800;
  text-align: center;
  color: #140c02;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}
.cb-pt-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
.cb-pt-avatar {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
  border: 1.5px solid rgba(239, 68, 68, 0.5);
  background: #141418;
}
.cb-pt-meta {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.cb-pt-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.cb-pt-total-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 11px;
  border-radius: 10px;
  background: rgba(11, 11, 14, 0.75);
  border: 1px solid rgba(239, 68, 68, 0.16);
  font-size: 0.78rem;
}
.cb-pulls-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.cb-pull-item {
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(24, 24, 27, 0.9);
  border-left: 3px solid #94a3b8;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.cb-pull-item.rarity-1 { border-left-color: #22c55e; }
.cb-pull-item.rarity-2 { border-left-color: #38bdf8; }
.cb-pull-item.rarity-3 { border-left-color: #a855f7; }
.cb-pull-item.rarity-4 { border-left-color: #f59e0b; background: rgba(45, 29, 14, 0.55); }
.cb-pull-item.rarity-5 { border-left-color: #ef4444; background: rgba(52, 14, 24, 0.65); }
.cb-pull-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.66rem;
  color: var(--text-dim);
}
.cb-rarity-tag {
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 0.62rem;
}
.cb-rarity-tag.rarity-1 { color: #4ade80; }
.cb-rarity-tag.rarity-2 { color: #7dd3fc; }
.cb-rarity-tag.rarity-3 { color: #d8b4fe; }
.cb-rarity-tag.rarity-4 { color: #fcd34d; }
.cb-rarity-tag.rarity-5 { color: #fca5a5; }
.cb-pull-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.cb-pull-name {
  font-size: 0.82rem;
  color: #fff;
}
.cb-pull-val {
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--win);
}
.cb-empty-seat-inner {
  margin: auto;
  text-align: center;
  padding: 20px 10px;
}
.cb-empty-seat-ico {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin: 0 auto 8px;
  border: 1px dashed rgba(239, 68, 68, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: var(--purple-bright);
}
.cb-arena-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(239, 68, 68, 0.16);
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* Case Battles Lobby List */
.cb-lobby-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cb-lobby-row {
  padding: 13px 16px;
  border-radius: 14px;
  background: linear-gradient(155deg, rgba(28, 28, 31, 0.92), rgba(16, 16, 19, 0.96));
  border: 1px solid rgba(239, 68, 68, 0.2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.cb-lobby-row.active-row {
  border-color: var(--purple-bright);
  box-shadow: 0 0 18px rgba(220, 38, 38, 0.24);
}
.cb-lobby-avatars {
  display: flex;
  align-items: center;
  gap: 6px;
}
.cb-seat-dot {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #141418;
  border: 1.5px solid rgba(239, 68, 68, 0.45);
}
.cb-seat-dot.empty {
  border-style: dashed;
  color: var(--text-dim);
  font-weight: 800;
}
.cb-vs-sep {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 800;
  color: var(--text-faint);
}
.cb-lobby-pot {
  display: flex;
  align-items: center;
  gap: 16px;
}
.cb-lobby-pot > div {
  display: flex;
  flex-direction: column;
}
.cb-lobby-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
@media (max-width: 1024px) {
  .cb-case-picker { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cb-participants-grid.cols-3,
  .cb-participants-grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
  .cb-case-picker { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cb-participants-grid.cols-2,
  .cb-participants-grid.cols-3,
  .cb-participants-grid.cols-4 { grid-template-columns: 1fr; }
}

/* ==================== AUTHORITATIVE UNFULLSCREEN & SMALL MONITOR SCALING ==================== */
html, body {
  overflow-x: clip;
}
.topbar-left {
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
}
.main-nav {
  flex: 1 1 auto;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.main-nav::-webkit-scrollbar { display: none; }
.top-wager-hero-card,
.discord-compact-card,
.hero-card,
.home-lvl-card {
  min-width: 0;
}

@media (max-width: 1600px) {
  .nav-opt-xl { display: none; }
}
@media (max-width: 1480px) {
  .nav-opt-lg { display: none; }
  .bot-pill-txt { display: none; }
  .bot-pill { padding: 8px; }
  .nav-link { padding: 6px 8px; font-size: 0.83rem; }
}
@media (max-width: 1340px) {
  .nav-opt-md { display: none; }
  .bot-pill { display: none; }
  .topbar-inner { gap: 8px; padding: 0 12px; }
  .topbar-left, .topbar-right { gap: 6px; }
  .btn-games-cta { padding: 0 11px; height: 35px; font-size: 0.82rem; gap: 6px; }
  .profile-access-btn { height: 36px; padding: 3px 9px 3px 4px; gap: 6px; }
  .user-name { max-width: 82px; }
}
@media (max-width: 1200px) {
  .nav-bot-tab { display: none; }
  .user-lvl-badge { display: none; }
  .brand-coin { width: 29px; height: 29px; }
  .brand-wordmark { font-size: 1.05rem; }
  .nav-link { padding: 6px 7px; font-size: 0.81rem; }
}
@media (max-width: 1060px) {
  .profile-access-btn .user-name { display: none; }
  #music-toggle { display: none; }
  .btn-games-cta .games-cta-count { display: none; }
  .profile-access-btn { padding: 3px 7px 3px 4px; gap: 5px; }
}
@media (max-width: 960px) {
  .brand-wordmark { font-size: 0.96rem; }
  .btn-games-cta { padding: 0 9px; font-size: 0.78rem; }
  .nav-link { padding: 5px 6px; font-size: 0.78rem; }
  .dl-bal-btn { padding: 0 8px 0 7px; }
  .dl-bal-btn .bal-val { font-size: 0.84rem; }
  .dl-wallet-btn { width: 35px; }
}
@media (max-width: 860px) {
  .main-nav { display: none; }
  .btn-games-cta { display: none; }
  .profile-access-btn .user-name,
  .profile-access-btn .user-lvl-badge { display: none !important; }
}

/* ==================== SITE LOCKDOWN (MAINTENANCE MODE) ==================== */
body.site-locked {
  overflow: hidden;
}
.lockdown-screen {
  position: fixed;
  inset: 0;
  z-index: 180;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(circle at 25% 20%, rgba(220, 38, 38, 0.24), transparent 52%),
    radial-gradient(circle at 75% 80%, rgba(239, 68, 68, 0.16), transparent 50%),
    rgba(9, 9, 12, 0.97);
  backdrop-filter: blur(18px);
}
.lockdown-screen.hidden {
  display: none !important;
}
.lockdown-card {
  width: 100%;
  max-width: 480px;
  padding: 36px 30px;
  border-radius: 22px;
  background: linear-gradient(160deg, rgba(28, 28, 31, 0.96), rgba(14, 14, 17, 0.99));
  border: 1px solid rgba(239, 68, 68, 0.32);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.72), 0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
}
.lockdown-emblem {
  width: 76px;
  height: 76px;
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, rgba(220, 38, 38, 0.28), rgba(28, 28, 31, 0.85));
  border: 1px solid rgba(239, 68, 68, 0.42);
  box-shadow: 0 10px 30px rgba(220, 38, 38, 0.32);
}
.lockdown-coin {
  width: 52px;
  height: 52px;
  object-fit: contain;
}
.lockdown-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 12px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  color: #fecaca;
  background: rgba(239, 68, 68, 0.16);
  border: 1px solid rgba(239, 68, 68, 0.42);
}
.lockdown-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #f87171;
  box-shadow: 0 0 10px rgba(248, 113, 113, 0.9);
  display: inline-block;
  flex-shrink: 0;
}
.lockdown-card h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
}
.lockdown-msg {
  margin: 0;
  font-size: 0.94rem;
  line-height: 1.55;
  color: var(--text-dim);
  max-width: 390px;
  word-break: break-word;
}
.lockdown-user-note {
  font-size: 0.78rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 6px 12px;
  border-radius: 10px;
}
.lockdown-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 6px;
  width: 100%;
}
.staff-lockdown-banner {
  position: relative;
  z-index: 95;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 7px 14px;
  font-size: 0.8rem;
  color: #fee2e2;
  background: linear-gradient(90deg, rgba(153, 27, 27, 0.92), rgba(127, 29, 29, 0.92));
  border-bottom: 1px solid rgba(248, 113, 113, 0.45);
}
.staff-lockdown-banner.hidden {
  display: none !important;
}
.admin-lockdown-card {
  border-color: rgba(248, 113, 113, 0.34);
}
.admin-lockdown-card.is-on {
  background: linear-gradient(145deg, rgba(127, 29, 29, 0.32), rgba(21, 21, 24, 0.96));
  border-color: rgba(248, 113, 113, 0.62);
}
.admin-lockdown-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.admin-lockdown-controls .text-input {
  flex: 1 1 260px;
}


/* ==================== DEFAULT DONUT — FRIXION RED & BLACK MASTER LAYER ==================== */

/* 1. Frixion 3-Column App Shell & Left Sidebar */
.app-shell {
  display: flex;
  align-items: stretch;
  width: 100%;
  min-height: 100dvh;
  position: relative;
}

.left-sidebar {
  width: 236px;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border-right: 1px solid var(--divider);
  z-index: 95;
}

.side-header {
  height: 52px;
  padding: 0 12px 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 1px solid var(--divider);
  flex-shrink: 0;
}

.side-header .brand {
  gap: 9px;
  padding-right: 0;
}

.brand-coin {
  width: 26px;
  height: 26px;
  filter: none;
  transition: transform 0.15s ease;
}

.brand:hover .brand-coin {
  transform: scale(1.04);
  filter: none;
}

.brand-wordmark {
  font-size: 0.96rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #ffffff;
}

.brand-wordmark span {
  color: var(--accent-bright);
  text-shadow: none;
}

.side-close-btn,
.side-menu-btn {
  display: none;
}

.side-nav-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 8px 8px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.12) transparent;
}

.side-section-label {
  font-size: 0.67rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-faint);
  padding: 12px 10px 4px;
  user-select: none;
}

.side-section-label:first-child {
  padding-top: 4px;
}

.side-item {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 7px 10px;
  border-radius: 7px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s ease, color 0.12s ease;
}

.side-item svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  opacity: 0.82;
}

.side-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}

.side-item.active {
  background: var(--accent-soft);
  color: #ffffff;
  font-weight: 600;
  box-shadow: inset 2px 0 0 var(--accent-bright);
}

.side-item.active svg {
  color: var(--accent-bright);
  opacity: 1;
}

.side-item.side-admin {
  color: var(--gold);
}

.side-item.side-admin.active {
  background: rgba(240, 177, 50, 0.14);
  box-shadow: inset 2px 0 0 var(--gold);
}

.side-pill {
  margin-left: auto;
  font-size: 0.67rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-dim);
}

.side-pill.done {
  background: var(--win-bg);
  color: var(--win);
}

.side-games-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.side-game-item {
  padding: 6px 10px;
  font-size: 0.82rem;
}

/* Docked Bottom User Panel (Frixion #user-panel) */
.side-user-panel {
  height: 56px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  border-top: 1px solid var(--divider);
  background: var(--bg-tertiary);
  flex-shrink: 0;
}

.side-user-who {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 5px 6px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: inherit;
  cursor: pointer;
  text-align: left;
  transition: background 0.12s ease;
}

.side-user-who:hover {
  background: rgba(255, 255, 255, 0.05);
}

.user-avatar.side-av {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 1px solid var(--line-strong);
  background: var(--bg-input);
}

.side-user-meta {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.side-user-top {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.side-user-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.side-user-sub {
  font-size: 0.7rem;
  color: var(--text-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Center Workspace Column + Compact Topbar */
.center-col {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  background: var(--bg-primary);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 80;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--divider);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.topbar-inner {
  max-width: none;
  height: 52px;
  padding: 0 16px;
}

.topbar-route-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.main-col {
  max-width: 1360px;
  width: 100%;
  margin: 0 auto;
  padding: 18px 20px 64px;
}

.chat-drawer {
  top: 0;
  height: 100dvh;
  width: 296px;
  background: var(--bg-secondary);
  border-left: 1px solid var(--divider);
}

/* 2. Flat Tactile Frixion Component Overrides (No AI Glow / No Shine Sweep / No Gradient Headlines) */
.btn::after {
  display: none !important;
}

.btn {
  border-radius: 7px;
  font-weight: 600;
  box-shadow: none !important;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}

.btn:hover:not(:disabled) {
  transform: none;
  filter: none;
}

.btn:active:not(:disabled) {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--accent);
  border: 1px solid var(--accent);
  color: #ffffff;
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.btn-win {
  background: #16a34a;
  border: 1px solid #16a34a;
  color: #ffffff;
}

.btn-win:hover:not(:disabled) {
  background: #15803d;
  border-color: #15803d;
}

.btn-ghost {
  background: var(--bg-input);
  border: 1px solid var(--divider);
  color: var(--text);
}

.btn-ghost:hover:not(:disabled) {
  background: #27272f;
  border-color: rgba(255, 255, 255, 0.16);
  color: #ffffff;
}

.btn-discord {
  background: #5865f2;
  border: 1px solid #5865f2;
  color: #ffffff;
}

.btn-discord:hover:not(:disabled) {
  background: #4752c4;
  border-color: #4752c4;
}

.icon-btn {
  border-radius: 7px;
  background: var(--bg-input);
  border: 1px solid var(--divider);
  color: var(--text-muted);
}

.icon-btn:hover {
  background: #27272f;
  color: #ffffff;
}

.profile-access-btn {
  height: 34px;
  padding: 3px 9px 3px 4px;
  border-radius: 8px;
  background: var(--bg-input);
  border: 1px solid var(--divider);
  box-shadow: none;
}

.profile-access-btn:hover,
.profile-access-btn.active {
  background: #27272f;
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: none;
  transform: none;
}

.profile-access-btn .user-avatar {
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.dl-wallet {
  background: var(--bg-input);
  border: 1px solid var(--divider);
  border-radius: 8px;
  box-shadow: none;
}

.dl-wallet-btn {
  background: var(--accent);
  color: #ffffff;
}

.dl-wallet-btn:hover {
  background: var(--accent-hover);
}

.hero-card {
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: 10px;
  box-shadow: none;
  padding: 22px 24px;
}

.hero-card h1 {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  font-weight: 800;
  color: #ffffff;
}

.hero-card h1 span {
  background: none !important;
  -webkit-background-clip: initial !important;
  background-clip: initial !important;
  -webkit-text-fill-color: var(--accent-bright) !important;
  color: var(--accent-bright) !important;
}

.page-card,
.home-lvl-card,
.home-bonus-card,
.event-spotlight-card,
.events-hero,
.table-card,
.top-wager-hero-card,
.discord-compact-card,
.cb-builder-card,
.cb-arena-card,
.race-banner-bar,
.lb-podium-card,
.rank-card,
.hunt-clue-card {
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: 10px;
  box-shadow: none;
}

.top-wager-hero-card {
  border-color: rgba(240, 177, 50, 0.28);
}

.game-card {
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: 10px;
  box-shadow: none;
}

.game-card:hover {
  border-color: var(--accent-line);
  box-shadow: none;
  transform: translateY(-2px);
}

.gc-max {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.rain-card {
  background: var(--bg-primary);
  border: 1px solid var(--divider);
  border-radius: 9px;
}

.chat-msg {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--divider);
  border-radius: 8px;
  box-shadow: none;
  padding: 9px 10px;
}

.chat-msg:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.12);
}

.chat-msg.owner-msg {
  background: linear-gradient(135deg, #070709 0%, #160508 58%, #2c080d 100%);
  border-color: #dc2626;
  border-left: 3px solid #ef4444;
  box-shadow: none;
}

.chat-msg.co-owner-msg {
  background: rgba(220, 38, 38, 0.22);
  border-color: #ef4444;
  border-left: 3px solid #f87171;
  box-shadow: none;
}

.chat-fab {
  background: var(--bg-floating);
  border: 1px solid var(--line-strong);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55);
}

.modal-card {
  background: var(--bg-floating);
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  box-shadow: 0 20px 54px rgba(0, 0, 0, 0.78);
}

.drop-menu {
  background: var(--bg-floating);
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  backdrop-filter: none;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.7);
}

.profile-sidebar {
  background: var(--bg-floating);
  border-right: 1px solid var(--divider);
  box-shadow: 12px 0 36px rgba(0, 0, 0, 0.75);
}

.ps-header,
.ps-tabs-rail {
  background: var(--bg-secondary);
}

.lockdown-screen {
  background: rgba(9, 9, 11, 0.97);
  backdrop-filter: none;
}

.lockdown-card {
  background: var(--bg-secondary);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.75);
}

.lockdown-emblem {
  background: var(--bg-input);
  border: 1px solid var(--accent-line);
  border-radius: 12px;
  box-shadow: none;
}

.xp-bar-fill {
  background: var(--accent);
}

.xp-bar-fill.shimmer::after {
  display: none;
}

.lvl-pill.tier-amethyst,
.lvl-pill.tier-diamond,
.lvl-pill.tier-netherite {
  box-shadow: none;
}

.lvl-pill.tier-netherite {
  background: rgba(220, 38, 38, 0.22);
  color: #fecaca;
  border-color: #ef4444;
}

/* 12-Letter DEFAULTDONUT Letter Drop Grid */
.hunt-tiles-row {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 6px;
}

.hunt-tile {
  border-radius: 8px;
  background: var(--bg-input);
  border: 1px dashed var(--line-strong);
}

.hunt-tile.found {
  background: var(--accent-soft);
  border: 1px solid var(--accent-bright);
  box-shadow: none;
  text-shadow: none;
}

.event-reward-pill,
.event-grand-box {
  background: var(--bg-input);
  border: 1px solid var(--accent-line);
  border-radius: 9px;
  box-shadow: none;
}

/* 3. Avatar Decorations Overlay Positioning (Unclipped Frixion Style) */
.user-avatar,
.chat-pfp,
.ps-avatar,
.lb-avatar,
.twd-avatar,
.cb-pt-avatar,
.sic-deco-av,
.shop-active-av {
  position: relative;
  overflow: visible !important;
}

.user-avatar > img,
.chat-pfp > img,
.ps-avatar > img,
.lb-avatar > img,
.twd-avatar > img,
.cb-pt-avatar > img,
.sic-deco-av > img,
.shop-active-av > img {
  border-radius: inherit;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar-decoration {
  position: absolute;
  pointer-events: none;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-decoration svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* 4. Homepage Shop Row + Themes Shop & Avatar Deco Shop */
.home-shop-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0 20px;
}

.home-shop-tile {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 15px 18px;
  border-radius: 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  transition: border-color 0.14s ease, background 0.14s ease;
}

.home-shop-tile:hover {
  border-color: var(--accent-line);
}

.home-shop-kicker {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--accent-bright);
  margin-bottom: 3px;
}

.home-shop-tile h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 2px;
}

.home-shop-tile p {
  font-size: 0.8rem;
}

.shop-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.shop-head-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.shop-head-left h2 {
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
}

.shop-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  border-radius: 8px;
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
}

.shop-tab {
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: background 0.12s ease, color 0.12s ease;
}

.shop-tab:hover {
  color: #ffffff;
}

.shop-tab.active {
  background: var(--accent);
  color: #ffffff;
}

.shop-head-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.shop-search {
  width: 220px;
  padding: 7px 10px;
  font-size: 0.83rem;
}

.shop-bal-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 35px;
  padding: 0 11px;
  border-radius: 7px;
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  font-size: 0.82rem;
  font-weight: 700;
  color: #ffffff;
}

.shop-active-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 11px 14px;
  margin-bottom: 14px;
  border-radius: 9px;
  background: var(--bg-secondary);
  border: 1px solid var(--accent-line);
}

.shop-active-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.shop-active-av {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 1px solid var(--line-strong);
  background: var(--bg-input);
}

.shop-pv-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 2px solid rgba(255, 255, 255, 0.35);
}

.shop-section-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-faint);
  margin: 18px 0 8px;
}

.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(225px, 1fr));
  gap: 12px;
}

.deco-shop-grid {
  grid-template-columns: repeat(auto-fill, minmax(205px, 1fr));
}

.shop-item-card {
  display: flex;
  flex-direction: column;
  border-radius: 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  overflow: hidden;
  transition: border-color 0.14s ease;
}

.shop-item-card:hover {
  border-color: rgba(255, 255, 255, 0.16);
}

.shop-item-card.equipped,
.shop-item-card.previewing {
  border-color: var(--accent-bright);
}

.sic-theme-preview {
  position: relative;
  height: 88px;
  width: 100%;
  overflow: hidden;
  border-bottom: 1px solid var(--divider);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 10px;
}

.sic-theme-accent-dot {
  position: relative;
  z-index: 1;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.45);
}

.sic-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(9, 9, 11, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: var(--text-dim);
}

.sic-badge.equipped {
  background: var(--accent);
  border-color: var(--accent-bright);
  color: #ffffff;
}

.sic-badge.owned {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(34, 197, 94, 0.45);
  color: #86efac;
}

.sic-badge.anim {
  background: rgba(240, 177, 50, 0.18);
  border-color: rgba(240, 177, 50, 0.42);
  color: #fde68a;
}

.sic-deco-stage {
  position: relative;
  height: 108px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--divider);
}

.sic-deco-av {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--bg-input);
}

.sic-body {
  padding: 11px 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.sic-top-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.sic-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: #ffffff;
}

.sic-price {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--accent-bright);
  white-space: nowrap;
}

.shop-item-card.owned .sic-price {
  color: var(--win);
}

.sic-desc {
  font-size: 0.77rem;
  color: var(--text-muted);
  line-height: 1.4;
  flex: 1;
}

.sic-actions {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

.sic-actions .btn {
  flex: 1;
}

/* 5. Frixion Shop Themes Layer (Translucent Panels + Animated Celestial & Gradient Themes) */
body.shop-theme-active {
  background: transparent;
}

body.shop-theme-active::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--shop-theme-bg);
}

body.shop-theme-active .modal-card,
body.shop-theme-active .drop-menu,
body.shop-theme-active .profile-sidebar,
body.shop-theme-active .mobile-nav,
body.shop-theme-active .chat-fab {
  background: var(--bg-floating);
}

body.shop-anim-hue::before,
body.shop-anim-holo::before,
body.shop-anim-aurora::before {
  animation: shopThemeHueRot 6s linear infinite;
}

body.shop-anim-holo::before {
  animation-duration: 5s;
  filter: saturate(1.4);
}

body.shop-anim-aurora::before {
  animation-duration: 9s;
}

@keyframes shopThemeHueRot {
  from { filter: hue-rotate(0deg); }
  to { filter: hue-rotate(360deg); }
}

@keyframes shopSpaceTurn {
  to { transform: rotate(360deg); }
}

body.shop-anim-blackhole::after,
.sic-theme-preview.sic-theme-blackhole::before {
  content: '';
  position: fixed;
  z-index: -1;
  pointer-events: none;
  border-radius: 50%;
  right: -16vmin;
  bottom: -16vmin;
  width: 70vmin;
  height: 70vmin;
  background:
    radial-gradient(circle, #000 0 19%, rgba(255, 236, 206, 0.95) 20.5%, rgba(255, 160, 70, 0.7) 23%, rgba(255, 120, 40, 0.25) 30%, rgba(120, 50, 170, 0.12) 40%, transparent 52%),
    conic-gradient(rgba(255, 150, 60, 0), rgba(255, 170, 80, 0.55) 60deg, rgba(255, 236, 206, 0.7) 110deg, rgba(255, 120, 40, 0.4) 170deg, rgba(160, 70, 220, 0.25) 240deg, rgba(255, 150, 60, 0.35) 300deg, rgba(255, 150, 60, 0));
  -webkit-mask: radial-gradient(circle, #000 0 48%, transparent 70%);
  mask: radial-gradient(circle, #000 0 48%, transparent 70%);
  animation: shopSpaceTurn 60s linear infinite;
}

.sic-theme-preview.sic-theme-blackhole::before {
  position: absolute;
  z-index: 0;
  right: -34px;
  bottom: -52px;
  width: 170px;
  height: 170px;
  animation-duration: 24s;
}

body.shop-anim-supernova::after,
.sic-theme-preview.sic-theme-supernova::before {
  content: '';
  position: fixed;
  z-index: -1;
  pointer-events: none;
  border-radius: 50%;
  right: -14vmin;
  bottom: -14vmin;
  width: 74vmin;
  height: 74vmin;
  background:
    radial-gradient(circle, #fff8ec 0 6%, #ffd166 11%, rgba(255, 77, 148, 0.85) 18%, rgba(255, 77, 148, 0.12) 26%, rgba(255, 209, 102, 0.52) 31%, rgba(168, 30, 110, 0.15) 37%, transparent 50%),
    conic-gradient(rgba(255, 77, 148, 0), rgba(255, 209, 102, 0.55) 28deg, rgba(255, 77, 148, 0.65) 75deg, rgba(168, 30, 110, 0.15) 125deg, rgba(255, 236, 190, 0.6) 185deg, rgba(255, 77, 148, 0.55) 250deg, rgba(130, 40, 210, 0.35) 310deg, rgba(255, 77, 148, 0));
  -webkit-mask: radial-gradient(circle, #000 0 46%, transparent 72%);
  mask: radial-gradient(circle, #000 0 46%, transparent 72%);
  animation: shopSpaceTurn 48s linear infinite;
}

.sic-theme-preview.sic-theme-supernova::before {
  position: absolute;
  z-index: 0;
  right: -36px;
  bottom: -54px;
  width: 180px;
  height: 180px;
  animation-duration: 20s;
}

body.shop-anim-eclipse::after,
.sic-theme-preview.sic-theme-eclipse::before {
  content: '';
  position: fixed;
  z-index: -1;
  pointer-events: none;
  border-radius: 50%;
  right: -15vmin;
  bottom: -15vmin;
  width: 70vmin;
  height: 70vmin;
  background:
    radial-gradient(circle at 39% 39%, #fffdf5 0 3.2%, rgba(255, 232, 160, 0.85) 6.5%, transparent 15%),
    radial-gradient(circle, #010104 0 21%, #fff7df 22.3%, rgba(255, 224, 130, 0.85) 24.5%, rgba(255, 190, 85, 0.35) 31%, rgba(120, 95, 40, 0.12) 42%, transparent 55%),
    conic-gradient(from 25deg, rgba(255, 224, 130, 0.12), rgba(255, 247, 214, 0.65) 40deg, rgba(255, 200, 90, 0.2) 110deg, rgba(255, 240, 190, 0.55) 210deg, rgba(255, 180, 70, 0.18) 295deg, rgba(255, 224, 130, 0.12));
  -webkit-mask: radial-gradient(circle, #000 0 48%, transparent 72%);
  mask: radial-gradient(circle, #000 0 48%, transparent 72%);
  animation: shopSpaceTurn 70s linear infinite;
}

.sic-theme-preview.sic-theme-eclipse::before {
  position: absolute;
  z-index: 0;
  right: -34px;
  bottom: -52px;
  width: 175px;
  height: 175px;
  animation-duration: 28s;
}

body.shop-anim-nebula::after,
.sic-theme-preview.sic-theme-nebula::before {
  content: '';
  position: fixed;
  z-index: -1;
  pointer-events: none;
  border-radius: 50%;
  right: -18vmin;
  bottom: -18vmin;
  width: 82vmin;
  height: 82vmin;
  background:
    radial-gradient(1.6px 1.6px at 32% 38%, #fff, transparent),
    radial-gradient(1.4px 1.4px at 56% 29%, #c7f9ff, transparent),
    radial-gradient(1.8px 1.8px at 44% 58%, #f0d6ff, transparent),
    radial-gradient(1.3px 1.3px at 66% 52%, #fff, transparent),
    radial-gradient(circle at 42% 45%, rgba(44, 230, 255, 0.55) 0%, rgba(44, 230, 255, 0.15) 24%, transparent 45%),
    radial-gradient(circle at 60% 56%, rgba(192, 132, 252, 0.58) 0%, rgba(124, 58, 237, 0.22) 26%, transparent 50%),
    conic-gradient(rgba(44, 230, 255, 0.08), rgba(44, 230, 255, 0.45) 85deg, rgba(192, 132, 252, 0.55) 175deg, rgba(236, 72, 153, 0.35) 255deg, rgba(56, 189, 248, 0.4) 320deg, rgba(44, 230, 255, 0.08));
  -webkit-mask: radial-gradient(circle, #000 0 46%, transparent 72%);
  mask: radial-gradient(circle, #000 0 46%, transparent 72%);
  animation: shopSpaceTurn 64s linear infinite reverse;
}

.sic-theme-preview.sic-theme-nebula::before {
  position: absolute;
  z-index: 0;
  right: -40px;
  bottom: -56px;
  width: 190px;
  height: 190px;
  animation-duration: 26s;
}

body.shop-anim-crimsonrift::after,
.sic-theme-preview.sic-theme-crimsonrift::before {
  content: '';
  position: fixed;
  z-index: -1;
  pointer-events: none;
  border-radius: 50%;
  right: -16vmin;
  bottom: -16vmin;
  width: 72vmin;
  height: 72vmin;
  background:
    radial-gradient(circle, #050002 0 18%, rgba(255, 210, 220, 0.92) 19.4%, rgba(255, 41, 87, 0.85) 22.5%, rgba(180, 12, 50, 0.35) 31%, rgba(90, 6, 34, 0.15) 42%, transparent 54%),
    conic-gradient(rgba(255, 41, 87, 0.05), rgba(255, 60, 100, 0.72) 55deg, rgba(255, 190, 205, 0.75) 105deg, rgba(220, 20, 60, 0.45) 175deg, rgba(140, 10, 60, 0.3) 245deg, rgba(255, 41, 87, 0.5) 315deg, rgba(255, 41, 87, 0.05));
  -webkit-mask: radial-gradient(circle, #000 0 48%, transparent 71%);
  mask: radial-gradient(circle, #000 0 48%, transparent 71%);
  animation: shopSpaceTurn 52s linear infinite;
}

.sic-theme-preview.sic-theme-crimsonrift::before {
  position: absolute;
  z-index: 0;
  right: -34px;
  bottom: -52px;
  width: 175px;
  height: 175px;
  animation-duration: 22s;
}

@media (prefers-reduced-motion: reduce) {
  body.shop-anim-hue::before,
  body.shop-anim-holo::before,
  body.shop-anim-aurora::before,
  body.shop-anim-blackhole::after,
  .sic-theme-preview.sic-theme-blackhole::before,
  body.shop-anim-supernova::after,
  .sic-theme-preview.sic-theme-supernova::before,
  body.shop-anim-eclipse::after,
  .sic-theme-preview.sic-theme-eclipse::before,
  body.shop-anim-nebula::after,
  .sic-theme-preview.sic-theme-nebula::before,
  body.shop-anim-crimsonrift::after,
  .sic-theme-preview.sic-theme-crimsonrift::before {
    animation: none !important;
  }
}

html[data-calm="1"] body.shop-anim-hue::before,
html[data-calm="1"] body.shop-anim-holo::before,
html[data-calm="1"] body.shop-anim-aurora::before,
html[data-calm="1"] body.shop-anim-blackhole::after,
html[data-calm="1"] .sic-theme-preview.sic-theme-blackhole::before,
html[data-calm="1"] body.shop-anim-supernova::after,
html[data-calm="1"] .sic-theme-preview.sic-theme-supernova::before,
html[data-calm="1"] body.shop-anim-eclipse::after,
html[data-calm="1"] .sic-theme-preview.sic-theme-eclipse::before,
html[data-calm="1"] body.shop-anim-nebula::after,
html[data-calm="1"] .sic-theme-preview.sic-theme-nebula::before,
html[data-calm="1"] body.shop-anim-crimsonrift::after,
html[data-calm="1"] .sic-theme-preview.sic-theme-crimsonrift::before {
  animation: none !important;
}

/* 6. Responsive Drawer Sidebar & Breakpoints */
@media (max-width: 1020px) {
  .left-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(260px, 84vw);
    z-index: 155;
    transform: translateX(-105%);
    transition: transform 0.2s ease;
    box-shadow: 16px 0 42px rgba(0, 0, 0, 0.72);
  }

  .left-sidebar.open {
    transform: translateX(0);
  }

  .side-menu-btn,
  .side-close-btn {
    display: inline-flex;
  }
}

@media (max-width: 760px) {
  .home-shop-row {
    grid-template-columns: 1fr;
  }

  .hunt-tiles-row {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .shop-head {
    flex-direction: column;
    align-items: stretch;
  }

  .shop-head-right {
    justify-content: space-between;
  }

  .shop-search {
    flex: 1;
    width: auto;
  }

  .main-col {
    padding: 14px 12px 84px;
  }
}
