/* ============================================================
   PlayXcrew — Liquid Glass / Gaming Design System (v3)
   iOS-style frosted glass surfaces, specular highlights and soft
   depth, tuned for a competitive gaming product. All selectors
   used by assets/js/app.js, px-api.js and inline page scripts are
   preserved 1:1 — only the visual language has changed.
   ============================================================ */

:root {
  /* Base surfaces */
  --px-bg: #05060d;
  --px-bg-2: #0A0D1C;
  --px-nav: #0A0C18;
  --px-card: #12141F;
  --px-surface: #171A2A;
  --px-muted: #1B2036;
  --px-border: rgba(255, 255, 255, 0.12);
  --px-border-strong: rgba(255, 255, 255, 0.22);

  /* Brand */
  --px-primary: #8B5CF6;
  --px-primary-2: #A78BFA;
  --px-glow: #C4B5FD;
  --px-blue: #38BDF8;
  --px-cyan: #22D3EE;
  --px-green: #34D399;
  --px-orange: #FBBF24;
  --px-red: #FB7185;
  --px-pink: #F472B6;

  /* Type */
  --px-text: #F8FAFC;
  --px-dim: #97A2BE;
  --px-dim-2: #6B7690;

  /* Layout */
  --px-notif-h: 0px;
  --px-topbar-h: 64px;
  --px-sidebar-w: 272px;
  --px-sidebar-collapsed-w: 76px;

  /* Motion */
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-spring: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  /* Glass recipe */
  --glass-tint: rgba(17, 20, 33, 0.58);
  --glass-tint-strong: rgba(12, 14, 24, 0.78);
  --glass-border: rgba(255, 255, 255, 0.14);
  --glass-blur: 28px;
  --glass-sat: 180%;

  --shadow-glow: 0 0 28px rgba(139, 92, 246, 0.35), 0 0 64px rgba(34, 211, 238, 0.12);
  --shadow-card: 0 24px 60px rgba(0, 0, 0, 0.55), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

@media (min-width: 768px) { :root { --px-topbar-h: 72px; } }

* { -webkit-tap-highlight-color: transparent; box-sizing: border-box; }
html { scroll-behavior: smooth; }

/* ---------- Ambient background ---------- */
body {
  background-color: var(--px-bg);
  color: var(--px-text);
  font-family: 'Chakra Petch', ui-sans-serif, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(58rem 58rem at 8% -8%, rgba(139, 92, 246, 0.24), transparent 58%),
    radial-gradient(50rem 50rem at 104% 0%, rgba(34, 211, 238, 0.16), transparent 55%),
    radial-gradient(46rem 46rem at 85% 105%, rgba(52, 211, 153, 0.10), transparent 60%),
    linear-gradient(180deg, var(--px-bg-2) 0%, var(--px-bg) 100%);
}
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(circle at 50% 20%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(circle at 50% 20%, #000 0%, transparent 75%);
}

::selection { background: rgba(139, 92, 246, 0.4); color: #fff; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--px-primary), var(--px-cyan));
  border-radius: 999px;
  border: 2px solid var(--px-bg);
}
* { scrollbar-width: thin; scrollbar-color: var(--px-primary) transparent; }

/* ---------- Typography ---------- */
.font-display {
  font-family: 'Russo One', ui-sans-serif, system-ui, sans-serif;
  letter-spacing: 0.01em;
}
.text-glow { text-shadow: 0 0 18px rgba(139, 92, 246, 0.55), 0 0 36px rgba(139, 92, 246, 0.25); }
.text-glow-orange { text-shadow: 0 0 18px rgba(251, 191, 36, 0.55); }
.text-glow-cyan { text-shadow: 0 0 18px rgba(34, 211, 238, 0.5); }
.text-neon { color: var(--px-cyan); text-shadow: 0 0 10px rgba(34, 211, 238, 0.65), 0 0 26px rgba(34, 211, 238, 0.3); }
.text-neon-primary { color: var(--px-primary-2); text-shadow: 0 0 12px rgba(167, 139, 250, 0.6), 0 0 30px rgba(139, 92, 246, 0.3); }
.text-neon-orange { color: var(--px-orange); text-shadow: 0 0 10px rgba(251, 191, 36, 0.55); }

.text-gradient-primary {
  background: linear-gradient(120deg, var(--px-primary-2), var(--px-blue) 55%, var(--px-cyan));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ============================================================
   LIQUID GLASS — core surface recipe
   Frosted panel + top specular sheen + soft ambient shadow.
   ============================================================ */
.glass {
  position: relative;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.01) 45%),
    var(--glass-tint);
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat));
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat));
  border: 1px solid var(--glass-border);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-card);
  isolation: isolate;
}
.glass::before {
  /* gradient hairline border */
  content: '';
  position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.5), rgba(34, 211, 238, 0.12) 45%, transparent 75%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  pointer-events: none; opacity: 0.65; transition: opacity 280ms ease;
  z-index: 1;
}
.glass::after {
  /* top specular highlight, like light hitting curved glass */
  content: '';
  position: absolute; left: 6%; right: 6%; top: 0; height: 42%;
  border-radius: 999px / 100%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), transparent 100%);
  opacity: 0.55; pointer-events: none; z-index: 1;
}
.glass-hover:hover::before { opacity: 1; }

.glass-nav {
  position: relative;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0) 60%),
    var(--glass-tint-strong);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  border-bottom: 1px solid rgba(139, 92, 246, 0.2);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5), 0 0 24px rgba(139, 92, 246, 0.08);
}

.glass-card {
  position: relative;
  background: var(--glass-tint);
  border-radius: 1.5rem;
  padding: 1px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
.glass-card::before {
  content: ''; position: absolute; inset: 0;
  background: conic-gradient(from 180deg at 50% 50%,
    rgba(139, 92, 246, 0), rgba(139, 92, 246, 0.55), rgba(34, 211, 238, 0.4),
    rgba(139, 92, 246, 0));
  animation: spin-slow 9s linear infinite;
  opacity: 0.5; transition: opacity 300ms ease;
}
.glass-card > .glass-card-inner {
  position: relative; z-index: 1; height: 100%;
  background: rgba(10, 12, 22, 0.92);
  border-radius: 1.4rem;
  backdrop-filter: blur(8px);
}
.glass-card:hover::before { opacity: 0.9; }

/* Card hover lift */
.card-hover { transition: transform 200ms var(--ease-spring), box-shadow 200ms ease, border-color 200ms ease; will-change: transform; }
a.card-hover, .card-hover[onclick] { cursor: pointer; }
.card-hover:hover {
  transform: translateY(-5px);
  box-shadow: 0 30px 64px rgba(0, 0, 0, 0.55), 0 0 32px rgba(139, 92, 246, 0.22);
  border-color: rgba(139, 92, 246, 0.4);
}
a.card-hover:hover, .card-hover[onclick]:hover { text-decoration: none; }

/* ---------- Top bar ---------- */
.px-topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30;
  height: var(--px-topbar-h, 64px);
  display: flex; align-items: center;
  transition: background-color 200ms ease, border-color 200ms ease;
}
.px-topbar-inner {
  width: 100%; margin: 0 auto;
  padding: 0 max(0.75rem, env(safe-area-inset-left)) 0 max(0.75rem, env(safe-area-inset-right));
  display: flex; align-items: center; justify-content: space-between;
  gap: 0.5rem;
  min-height: var(--px-topbar-h, 64px);
  overflow: visible;
}
@media (min-width: 768px) { .px-topbar-inner { padding-left: 1.5rem; padding-right: 1.5rem; gap: 1.25rem; } }
.px-topbar-inner > div:first-child { min-width: 0; flex: 0 1 auto; display: flex; align-items: center; gap: 0.5rem; }
.px-topbar-inner > div:last-child { flex: 0 0 auto; display: flex; align-items: center; gap: 0.25rem; }
.px-topbar .px-wordmark { overflow: hidden; text-overflow: ellipsis; }

/* Hide non-essential topbar items on small screens to prevent squishing */
@media (max-width: 479px) {
  .px-topbar .px-wallet-pill { min-width: 0; padding: 0.375rem 0.5rem; font-size: 0.75rem; }
  .px-topbar .px-wallet-pill .px-wallet-label { display: none; }
  .px-topbar [aria-label="Search"] { display: none; }
  .px-topbar .px-wordmark { font-size: 0.875rem; }
  .px-topbar .px-logo-mark { width: 28px; height: 28px; }
  .px-topbar .px-icon-btn { width: 36px; height: 36px; }
  .px-topbar .px-icon-btn svg { width: 18px; height: 18px; }
  .px-topbar .px-avatar { width: 32px; height: 32px; }
}
@media (max-width: 359px) { .px-topbar .px-wordmark { display: none; } .px-topbar .px-wallet-pill .px-wallet-label { display: none; } }

/* On desktop the topbar spans full width (no sidebar) */
@media (min-width: 1024px) {
  .px-topbar-inner { padding-left: 1.5rem; }
}

.px-logo-mark {
  width: 32px; height: 32px; flex: 0 0 auto;
  filter: drop-shadow(0 0 10px rgba(139, 92, 246, 0.6));
  transition: transform 260ms var(--ease-spring), filter 260ms ease;
}
a:hover > .px-logo-mark { transform: rotate(-6deg) scale(1.08); filter: drop-shadow(0 0 16px rgba(139, 92, 246, 0.9)); }
@media (min-width: 768px) { .px-logo-mark { width: 36px; height: 36px; } }
.px-wordmark { font-family: 'Russo One', sans-serif; font-size: 1.0625rem; line-height: 1; white-space: nowrap; }
@media (min-width: 768px) { .px-wordmark { font-size: 1.2rem; } }

/* Desktop inline nav (legacy fallback — unused once sidebar is present, kept for back-compat) */
.px-topnav { display: none; }
.px-navlink {
  position: relative; display: inline-flex; align-items: center; gap: 0.45rem;
  padding: 0.5rem 0.85rem; border-radius: 9999px;
  font-size: 0.875rem; font-weight: 600; color: var(--px-dim);
  transition: color 200ms ease, background 200ms ease;
}
.px-navlink svg { width: 17px; height: 17px; opacity: 0.9; }
.px-navlink:hover { color: #fff; background: rgba(255, 255, 255, 0.06); }
.px-navlink.active { color: #fff; background: rgba(139, 92, 246, 0.16); }
.px-navlink.active::after {
  content: ''; position: absolute; left: 50%; bottom: -2px;
  width: 18px; height: 3px; border-radius: 3px; transform: translateX(-50%);
  background: linear-gradient(90deg, var(--px-primary), var(--px-cyan));
  box-shadow: 0 0 10px rgba(139, 92, 246, 0.8);
}

/* Notification bell + dot */
.px-bell-btn { position: relative; }
.px-bell-btn .px-bell-dot {
  position: absolute; top: 8px; right: 8px;
  width: 8px; height: 8px; border-radius: 9999px;
  background: var(--px-red);
  border: 2px solid rgba(10, 12, 24, 0.9);
  display: none;
}
.px-bell-btn .px-bell-dot.active { display: block; box-shadow: 0 0 8px rgba(251, 113, 133, 0.8); }

/* ---------- Icon buttons ---------- */
.px-icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 9999px; color: #fff;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid transparent;
  transition: background-color 200ms ease, transform 200ms var(--ease-spring), border-color 200ms ease;
}
.px-icon-btn:hover { background: rgba(255, 255, 255, 0.08); border-color: var(--px-border); transform: scale(1.06); }
.px-icon-btn:focus-visible { outline: 2px solid var(--px-primary); outline-offset: 2px; }

.px-wallet-pill {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.375rem 0.5rem 0.375rem 0.75rem;
  border-radius: 9999px; min-width: 92px; justify-content: center;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(52, 211, 153, 0.08));
  border: 1px solid rgba(52, 211, 153, 0.35);
  font-weight: 700; font-size: 0.875rem;
  transition: border-color 200ms ease, transform 200ms var(--ease-spring), box-shadow 200ms ease;
}
.px-wallet-pill:hover { border-color: rgba(52, 211, 153, 0.7); transform: translateY(-1px); box-shadow: 0 0 18px rgba(52, 211, 153, 0.25); }
.px-wallet-pill:focus-visible { outline: 2px solid var(--px-green); outline-offset: 2px; }
.px-wallet-pill #wallet-balance, .px-wallet-pill .wallet-balance { min-width: 1.2em; display: inline-block; text-align: right; }

.px-avatar {
  position: relative; width: 36px; height: 36px; border-radius: 9999px; padding: 2px;
  background: linear-gradient(135deg, var(--px-primary), var(--px-cyan));
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.4);
}
.px-avatar-inner { width: 100%; height: 100%; border-radius: 9999px; background: var(--px-card); display: flex; align-items: center; justify-content: center; }
.px-avatar-dot { position: absolute; bottom: 0; right: 0; width: 10px; height: 10px; border-radius: 9999px; background: var(--px-green); border: 2px solid var(--px-nav); }

/* ============================================================
   DESKTOP SIDEBAR (persistent nav, lg+ only)
   ============================================================ */
.px-sidebar {
  position: fixed; left: 0; top: 0; bottom: 0; z-index: 25;
  width: var(--px-sidebar-w);
  padding-top: var(--px-topbar-h, 72px);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0) 30%),
    var(--glass-tint-strong);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  border-right: 1px solid rgba(139, 92, 246, 0.18);
  box-shadow: 8px 0 40px rgba(0, 0, 0, 0.35);
  display: none; flex-direction: column;
}
.px-sidebar-scroll { flex: 1; overflow-y: auto; padding: 1.25rem 1rem 1.5rem; }
.px-sidebar-section-label {
  font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--px-dim-2); padding: 1rem 0.75rem 0.5rem;
}
.px-sidebar-section-label:first-child { padding-top: 0.25rem; }
.px-sidebar-link {
  position: relative; display: flex; align-items: center; gap: 0.75rem;
  padding: 0.65rem 0.85rem; border-radius: 1rem; margin-bottom: 0.2rem;
  color: var(--px-dim); font-size: 0.875rem; font-weight: 600;
  transition: color 200ms ease, background 200ms ease, transform 160ms var(--ease-spring);
}
.px-sidebar-link svg { width: 19px; height: 19px; flex: 0 0 auto; opacity: 0.85; }
.px-sidebar-link:hover { color: #fff; background: rgba(255, 255, 255, 0.05); transform: translateX(2px); }
.px-sidebar-link.active {
  color: #fff;
  background: linear-gradient(120deg, rgba(139, 92, 246, 0.28), rgba(34, 211, 238, 0.10));
  box-shadow: inset 0 0 0 1px rgba(139, 92, 246, 0.35), 0 0 20px rgba(139, 92, 246, 0.18);
}
.px-sidebar-link.active svg { opacity: 1; filter: drop-shadow(0 0 6px rgba(139, 92, 246, 0.7)); }
.px-sidebar-link .px-sidebar-badge {
  margin-left: auto; font-size: 0.65rem; font-weight: 800; padding: 0.1rem 0.45rem;
  border-radius: 999px; background: rgba(251, 113, 133, 0.18); color: var(--px-red);
  border: 1px solid rgba(251, 113, 133, 0.4);
}
.px-sidebar-footer {
  padding: 1rem; border-top: 1px solid var(--px-border);
}
.px-sidebar-cta {
  display: flex; align-items: center; gap: 0.65rem; padding: 0.75rem;
  border-radius: 1rem; background: linear-gradient(135deg, rgba(139,92,246,0.18), rgba(34,211,238,0.08));
  border: 1px solid rgba(139, 92, 246, 0.3);
}

/* Reserve space for sidebar on desktop — DISABLED (sidebar hidden on PC) */
@media (min-width: 1024px) {
  .px-sidebar { display: none !important; }
  .px-main-shifted { padding-left: 0; }
  body > main { padding-left: 0; }
  body.px-sidebar-collapsed > main { padding-left: 0; }
  body.px-sidebar-collapsed .px-topbar-inner { padding-left: 1.5rem; }
  .px-topbar-inner { padding-left: 1.5rem !important; }
  /* Bottom nav hidden on desktop — use top bar inline nav instead */
  .px-bottomnav { display: none !important; }
  /* Show inline desktop nav in topbar */
  .px-topnav { display: flex !important; }
  .pb-safe { padding-bottom: 2.5rem !important; }
}

/* ---------- Collapsed sidebar (icon-only rail) ---------- */
.px-sidebar {
  transition: width 280ms var(--ease-out);
}
.px-sidebar-collapsed {
  width: var(--px-sidebar-collapsed-w) !important;
}
.px-sidebar-collapsed .px-sidebar-section-label {
  text-align: center; padding-left: 0; padding-right: 0; font-size: 0;
  overflow: hidden;
}
.px-sidebar-collapsed .px-sidebar-section-label::before {
  content: ''; display: block; width: 24px; height: 1px; margin: 0.5rem auto;
  background: var(--px-border); font-size: 1rem;
}
.px-sidebar-collapsed .px-sidebar-link {
  justify-content: center; padding: 0.65rem 0;
}
.px-sidebar-collapsed .px-sidebar-link span { display: none; }
.px-sidebar-collapsed .px-sidebar-link svg { width: 22px; height: 22px; }
.px-sidebar-collapsed .px-sidebar-footer { padding: 0.75rem 0.5rem; }
.px-sidebar-collapsed .px-sidebar-cta {
  justify-content: center; padding: 0.6rem;
}
.px-sidebar-collapsed .px-sidebar-cta span { display: none; }
.px-sidebar-collapsed .px-sidebar-cta svg { width: 22px; height: 22px; }

/* Collapse toggle button — sits at the top-right edge of the sidebar */
.px-sidebar-toggle {
  position: absolute; top: calc(var(--px-topbar-h, 72px) + 0.75rem); right: -14px;
  width: 28px; height: 28px; border-radius: 9999px;
  background: linear-gradient(135deg, var(--px-primary), var(--px-cyan));
  color: #fff; display: flex; align-items: center; justify-content: center;
  cursor: pointer; z-index: 26; border: 2px solid var(--px-bg);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), 0 0 12px rgba(139, 92, 246, 0.4);
  transition: transform 280ms var(--ease-spring), box-shadow 200ms ease;
}
.px-sidebar-toggle:hover { transform: scale(1.1); box-shadow: 0 4px 18px rgba(0, 0, 0, 0.5), 0 0 20px rgba(139, 92, 246, 0.6); }
.px-sidebar-toggle svg { width: 16px; height: 16px; transition: transform 280ms var(--ease-spring); }
.px-sidebar-collapsed .px-sidebar-toggle svg { transform: rotate(180deg); }
@media (max-width: 1023px) { .px-sidebar-toggle { display: none; } }

/* ---------- Mobile drawer (extra pages) ---------- */
.px-drawer {
  position: fixed; top: 0; left: 0; height: 100%;
  width: 18.5rem; max-width: 86vw;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0) 30%),
    var(--glass-tint-strong);
  backdrop-filter: blur(26px) saturate(180%);
  -webkit-backdrop-filter: blur(26px) saturate(180%);
  border-right: 1px solid rgba(139, 92, 246, 0.25);
  z-index: 50;
  transform: translateX(-101%);
  transition: transform 280ms var(--ease-out), box-shadow 280ms ease;
  will-change: transform;
  overflow-y: auto;
}
.px-drawer.open { transform: translateX(0); box-shadow: 0 0 60px rgba(0, 0, 0, 0.6); }

/* Mobile drawer interior styling */
.px-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.px-drawer-nav {
  display: flex;
  flex-direction: column;
  padding: 1rem 0.75rem;
  gap: 0.25rem;
}
.px-drawer-link {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  color: var(--px-dim);
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  transition: background-color 200ms ease, color 200ms ease;
}
.px-drawer-link svg {
  width: 20px;
  height: 20px;
  color: var(--px-dim);
  opacity: 0.85;
  transition: color 200ms ease;
  flex-shrink: 0;
}
.px-drawer-link:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}
.px-drawer-link:hover svg {
  color: var(--px-primary);
}
.px-drawer-link.active {
  background: rgba(124, 58, 255, 0.12);
  color: #fff;
}
.px-drawer-link.active svg {
  color: var(--px-glow);
}
.px-drawer-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  margin: 0.75rem 0;
}
.px-drawer-footer {
  padding: 1rem 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.px-drawer-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  width: 100%;
  border-radius: 9999px;
  background: linear-gradient(135deg, var(--px-primary), var(--px-cyan));
  color: #fff;
  font-weight: 600;
  font-size: 0.875rem;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(139, 92, 246, 0.35);
  transition: transform 200ms var(--ease-spring), box-shadow 200ms ease;
}
.px-drawer-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(139, 92, 246, 0.5);
}

.px-drawer-overlay {
  position: fixed; inset: 0;
  background: rgba(2, 3, 8, 0.72);
  -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px);
  z-index: 45; opacity: 0; visibility: hidden;
  transition: opacity 260ms ease, visibility 260ms ease;
}
.px-drawer-overlay.open { opacity: 1; visibility: visible; }
.px-noscroll { overflow: hidden; }
@media (prefers-reduced-motion: reduce) { .px-drawer { transition: none; } }

/* ---------- Bottom nav (mobile + tablet) ---------- */
.px-bottomnav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 40;
  height: 64px;
  background: transparent;
  pointer-events: none;
  overflow: visible;
}
.px-bottomnav::before {
  content: '';
  position: absolute; inset: 0;
  background: rgba(9, 11, 20, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(139, 92, 246, 0.35);
  z-index: -1;
  pointer-events: auto;
}
.px-bottomnav-inner {
  display: flex; align-items: center; justify-content: space-around;
  height: 100%;
  width: 100%;
  pointer-events: auto;
  overflow: visible;
}
.px-nav-item {
  flex: 1 1 0; min-width: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px;
  height: 100%;
  color: var(--px-dim);
  font-size: 10px; font-weight: 700;
  text-decoration: none;
  position: relative;
  transition: color 180ms ease;
}
.px-nav-item svg {
  width: 22px; height: 22px;
  transition: transform 180ms ease, filter 180ms ease;
}
.px-nav-item span {
  font-size: 9px; line-height: 1;
}
.px-nav-item::after {
  content: ''; position: absolute; bottom: 6px; left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 24px; height: 3px; border-radius: 999px;
  background: linear-gradient(90deg, var(--px-primary), var(--px-cyan));
  box-shadow: 0 0 10px rgba(139, 92, 246, 0.8);
  transition: transform 180ms var(--ease-spring);
}
.px-nav-item:hover { color: #fff; }
.px-nav-item.active { color: #fff; }
.px-nav-item.active svg {
  transform: translateY(-3px) scale(1.1);
  filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.7));
}
.px-nav-item.active::after { transform: translateX(-50%) scaleX(1); }

.px-nav-fab {
  position: relative;
  width: 56px; height: 56px;
  margin-top: -22px;
  flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  border: 0; border-radius: 9999px;
  background: linear-gradient(135deg, var(--px-primary), var(--px-cyan));
  color: #fff;
  box-shadow: 0 6px 26px rgba(139, 92, 246, 0.55), 0 0 0 4px rgba(9, 11, 20, 0.95);
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease;
  animation: px-fab-pulse 2.5s ease-in-out infinite;
}
.px-nav-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 30px rgba(139, 92, 246, 0.7), 0 0 0 4px rgba(9, 11, 20, 0.95);
}
.px-nav-fab:active { transform: scale(0.95); }
.px-nav-fab svg {
  width: 26px; height: 26px;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.6));
}

@keyframes px-fab-pulse {
  0%, 100% { box-shadow: 0 6px 26px rgba(139, 92, 246, 0.55), 0 0 0 4px rgba(9, 11, 20, 0.95); }
  50%      { box-shadow: 0 6px 32px rgba(56, 230, 245, 0.65), 0 0 0 4px rgba(9, 11, 20, 0.95); }
}

@media (max-width: 480px) {
  .px-bottomnav {
    left: 12px;
    right: 12px;
    bottom: 12px;
    height: 60px;
    padding-bottom: 0 !important;
  }
  .px-bottomnav::before {
    border: 1px solid rgba(139, 92, 246, 0.35);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55), 0 0 24px rgba(124, 58, 255, 0.18);
  }
  .px-bottomnav-inner {
    padding: 0 0.5rem;
  }
  .px-nav-item {
    font-size: 9px;
  }
  .px-nav-item svg {
    width: 24px;
    height: 24px;
    padding: 0;
  }
  .px-nav-fab {
    width: 50px;
    height: 50px;
    margin-top: -18px;
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.5), 0 0 0 3px rgba(9, 11, 20, 0.95);
  }
  .px-nav-fab svg {
    width: 22px;
    height: 22px;
  }
}

@media (min-width: 1024px) {
  .px-bottomnav { display: none !important; }
}
@media (max-width: 380px) {
  .px-nav-item svg { width: 20px; height: 20px; }
  .px-nav-item span { font-size: 8px; }
  .px-nav-fab { width: 50px; height: 50px; margin-top: -20px; }
}

/* Safe area for floating bottom nav */
.pb-safe { padding-bottom: calc(96px + env(safe-area-inset-bottom)) !important; }
@media (min-width: 1024px) { .pb-safe { padding-bottom: 2.5rem !important; } }
.pt-safe { padding-top: calc(var(--px-topbar-h, 64px) + var(--px-notif-h, 0px) + env(safe-area-inset-top)) !important; }
.pt-safe-notif { padding-top: calc(var(--px-topbar-h, 64px) + var(--px-notif-h, 0px) + env(safe-area-inset-top)) !important; }

/* ---------- Buttons ---------- */
.px-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.75rem 1.5rem; border-radius: 9999px; font-weight: 700; font-size: 0.9375rem;
  line-height: 1; cursor: pointer; border: 0; min-height: 46px; position: relative; overflow: hidden;
  transition: transform 200ms var(--ease-spring), box-shadow 200ms ease, opacity 200ms ease;
}
.px-btn:focus-visible { outline: 2px solid var(--px-glow); outline-offset: 2px; }
.px-btn-primary {
  background: linear-gradient(135deg, var(--px-primary), var(--px-blue));
  color: #fff; box-shadow: 0 0 24px rgba(139, 92, 246, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.px-btn-primary::after {
  content: ''; position: absolute; top: 0; left: -120%; width: 60%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg); transition: left 420ms var(--ease-out);
}
.px-btn-primary:hover { transform: translateY(-1px) scale(1.02); box-shadow: 0 0 34px rgba(139, 92, 246, 0.6); }
.px-btn-primary:hover::after { left: 140%; }
.px-btn-primary:active { transform: scale(0.96); }
.px-btn-secondary {
  background: rgba(255, 255, 255, 0.05); color: #fff; border: 1px solid rgba(255, 255, 255, 0.18);
}
.px-btn-secondary:hover { background: rgba(255, 255, 255, 0.1); transform: translateY(-1px); }
.px-btn-ghost { background: transparent; color: #fff; }
.px-btn-ghost:hover { background: rgba(255, 255, 255, 0.06); }
.px-btn-sm { padding: 0.5rem 1rem; font-size: 0.8125rem; min-height: 36px; }

/* ---------- Form inputs ---------- */
.px-field { display: flex; flex-direction: column; gap: 0.375rem; margin-bottom: 1rem; }
.px-label { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--px-dim); }
.px-input, .px-select, .px-textarea {
  width: 100%; height: 46px; padding: 0 0.875rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--px-border); border-radius: 1rem;
  color: #fff; font-size: 0.9375rem; font-family: inherit;
  transition: border-color 200ms ease, box-shadow 200ms ease, background 200ms ease;
}
.px-textarea { height: auto; padding: 0.625rem 0.875rem; min-height: 88px; resize: vertical; }
.px-input::placeholder { color: rgba(151, 162, 190, 0.55); }
.px-select option { background: var(--px-card); color: #fff; }
.px-input:hover, .px-select:hover, .px-textarea:hover { border-color: rgba(255, 255, 255, 0.2); }
.px-input:focus, .px-select:focus, .px-textarea:focus {
  outline: none; border-color: var(--px-primary);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2); background: rgba(255, 255, 255, 0.06);
}
.px-input[aria-invalid="true"] { border-color: var(--px-red); box-shadow: 0 0 0 3px rgba(251, 113, 133, 0.18); }
.px-error { color: var(--px-red); font-size: 0.75rem; min-height: 1em; }

/* ---------- Tabs ---------- */
.px-tabs {
  display: inline-flex; align-items: center; gap: 0.25rem; padding: 0.25rem; border-radius: 9999px;
  background: rgba(255, 255, 255, 0.04); border: 1px solid var(--px-border);
  position: relative; overflow-x: auto;
}
.px-tab {
  padding: 0.5rem 1rem; font-size: 0.875rem; font-weight: 700; color: var(--px-dim);
  border-radius: 9999px; white-space: nowrap; cursor: pointer;
  transition: color 200ms ease, background 200ms ease; background: transparent; border: 0;
}
.px-tab:hover { color: #fff; background: rgba(255, 255, 255, 0.05); }
.px-tab.active { color: #fff; background: linear-gradient(135deg, var(--px-primary), var(--px-blue)); box-shadow: 0 0 16px rgba(139, 92, 246, 0.4); }

.px-tabs-underline { display: flex; gap: 0.5rem; border-bottom: 1px solid var(--px-border); position: relative; }
.px-tab-u {
  padding: 0.75rem 1rem; font-weight: 700; color: var(--px-dim); background: transparent; border: 0;
  cursor: pointer; position: relative; transition: color 200ms ease; white-space: nowrap;
}
.px-tab-u:hover { color: #fff; }
.px-tab-u.active { color: var(--px-glow); }
.px-tab-u.active::after {
  content: ''; position: absolute; left: 0.5rem; right: 0.5rem; bottom: -1px; height: 2px;
  background: linear-gradient(90deg, var(--px-primary), var(--px-cyan)); border-radius: 2px;
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.6);
}

/* ---------- Modal ---------- */
.px-modal-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.68); backdrop-filter: blur(8px); z-index: 60; }
.px-modal-panel {
  background: var(--glass-tint-strong);
  backdrop-filter: blur(30px) saturate(180%);
  border: 1px solid var(--glass-border); border-radius: 1.75rem; padding: 1.5rem;
  position: relative; max-width: 28rem; width: 100%; box-shadow: var(--shadow-card);
}

/* ---------- Toast ---------- */
#toast {
  position: fixed; top: 84px; left: 50%; transform: translateX(-50%) translateY(-12px);
  padding: 0.75rem 1.5rem; border-radius: 9999px;
  background: var(--glass-tint-strong);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff; font-weight: 700; font-size: 0.875rem; z-index: 80; opacity: 0;
  transition: opacity 240ms ease, transform 320ms var(--ease-bounce);
  pointer-events: none; box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45), 0 0 20px rgba(139, 92, 246, 0.2);
}

/* ---------- Hero gradient ---------- */
.px-hero-bg {
  background:
    radial-gradient(circle at 75% 25%, rgba(139, 92, 246, 0.24), transparent 55%),
    radial-gradient(circle at 15% 85%, rgba(34, 211, 238, 0.14), transparent 55%),
    linear-gradient(180deg, #0B0D1D 0%, var(--px-bg) 100%);
}
.px-hero-bg h1, .px-hero-bg p { text-shadow: 0 2px 24px rgba(0, 0, 0, 0.55); }

/* ---------- Theme color helpers (Tailwind CDN also generates these from
   the inline config; kept as a safety net in case the CDN JIT hasn't run) --- */
.bg-px-bg { background-color: var(--px-bg); }
.bg-px-nav { background-color: var(--px-nav); }
.bg-px-card { background-color: var(--px-card); }
.bg-px-muted { background-color: var(--px-muted); }
.text-px-primary { color: var(--px-primary); }
.text-px-glow { color: var(--px-glow); }
.text-px-blue { color: var(--px-blue); }
.text-px-cyan { color: var(--px-cyan); }
.text-px-green { color: var(--px-green); }
.text-px-orange { color: var(--px-orange); }
.text-px-red { color: var(--px-red); }
.text-px-dim { color: var(--px-dim); }
.border-px-border { border-color: var(--px-border); }

/* ---------- Section + container ---------- */
.px-section { padding-top: 4.5rem; padding-bottom: 1.5rem; }
@media (min-width: 768px) { .px-section { padding-top: 6rem; } }
.px-container { max-width: 80rem; margin: 0 auto; padding-left: 1rem; padding-right: 1rem; }

.px-eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.35rem 0.85rem; border-radius: 999px;
  background: rgba(139, 92, 246, 0.14); border: 1px solid rgba(139, 92, 246, 0.32);
  color: var(--px-glow); font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em;
}

.logo-invert { filter: brightness(0) invert(1); }

.px-hide-scroll::-webkit-scrollbar { display: none; }
.px-hide-scroll { -ms-overflow-style: none; scrollbar-width: none; }
.px-snap-x { scroll-snap-type: x mandatory; }
.px-snap-start { scroll-snap-align: start; }

/* ---------- Toggle switch ---------- */
.px-switch { position: relative; display: inline-block; width: 44px; height: 24px; }
.px-switch input { opacity: 0; width: 0; height: 0; }
.px-switch .slider { position: absolute; inset: 0; cursor: pointer; background: rgba(255, 255, 255, 0.12); border-radius: 9999px; transition: background 200ms ease; }
.px-switch .slider::before { content: ''; position: absolute; height: 18px; width: 18px; left: 3px; bottom: 3px; background: #fff; border-radius: 9999px; transition: transform 240ms var(--ease-bounce); }
.px-switch input:checked + .slider { background: var(--px-primary); }
.px-switch input:checked + .slider::before { transform: translateX(20px); }

/* ---------- Accordion ---------- */
.px-accordion-item { border-bottom: 1px solid var(--px-border); }
.px-accordion-trigger { width: 100%; display: flex; justify-content: space-between; align-items: center; padding: 1rem 0; font-weight: 700; background: transparent; border: 0; color: #fff; cursor: pointer; text-align: left; }
.px-accordion-trigger .chev { transition: transform 220ms var(--ease-bounce); }
.px-accordion-item.open .chev { transform: rotate(180deg); }
.px-accordion-content { max-height: 0; overflow: hidden; transition: max-height 320ms var(--ease-spring), padding 220ms ease; color: var(--px-dim); font-size: 0.875rem; line-height: 1.6; }
.px-accordion-item.open .px-accordion-content { max-height: 400px; padding-bottom: 1rem; }

/* ---------- Skeleton shimmer ---------- */
.px-shimmer { position: relative; overflow: hidden; background: rgba(255, 255, 255, 0.04); border-radius: 0.75rem; }
.px-shimmer::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.06), transparent); transform: translateX(-100%); animation: shimmer 1.6s infinite; }
@keyframes shimmer { to { transform: translateX(100%); } }
#wallet-balance[data-count-up] { animation: none !important; }
#wallet-balance.px-shimmer::after, #wallet-balance .px-shimmer::after { display: none; }

/* ---------- Countdown ---------- */
.px-countdown { font-family: 'Russo One', monospace; font-variant-numeric: tabular-nums; color: var(--px-cyan); text-shadow: 0 0 8px rgba(34, 211, 238, 0.4); }
.px-live-now { color: var(--px-red) !important; font-weight: 700; }

/* ---------- Badges / chips ---------- */
.px-chip { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.3rem 0.7rem; border-radius: 999px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.03em; }
button.px-chip { cursor: pointer; background: rgba(255, 255, 255, 0.05); color: #b9c2d0; border: 1px solid var(--px-border); transition: background .2s ease, color .2s ease, border-color .2s ease; }
button.px-chip:hover { background: rgba(255, 255, 255, 0.09); color: #fff; }
button.px-chip.active { background: rgba(139, 92, 246, 0.2); color: #fff; border-color: rgba(139, 92, 246, 0.5); }
.px-chip-live { background: rgba(251, 113, 133, 0.14); color: var(--px-red); border: 1px solid rgba(251, 113, 133, 0.35); }
.px-chip-green { background: rgba(52, 211, 153, 0.14); color: var(--px-green); border: 1px solid rgba(52, 211, 153, 0.35); }
.px-chip-blue { background: rgba(56, 189, 248, 0.14); color: var(--px-blue); border: 1px solid rgba(56, 189, 248, 0.35); }
.px-chip-orange { background: rgba(251, 191, 36, 0.14); color: var(--px-orange); border: 1px solid rgba(251, 191, 36, 0.35); }

.px-badge-live, .px-badge-done, .px-badge-soon {
  display: inline-flex; align-items: center; gap: 5px; padding: 2px 8px; border-radius: 999px;
  font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; backdrop-filter: blur(6px);
}
.px-badge-live { background: rgba(251, 113, 133, 0.18); color: var(--px-red); border: 1px solid rgba(251, 113, 133, 0.4); }
.px-badge-done { background: rgba(255, 255, 255, 0.08); color: #b9c2d0; border: 1px solid rgba(255, 255, 255, 0.14); }
.px-badge-soon { background: rgba(56, 189, 248, 0.16); color: var(--px-blue); border: 1px solid rgba(56, 189, 248, 0.35); }
.px-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--px-red); box-shadow: 0 0 0 0 rgba(251, 113, 133, 0.7); animation: px-pulse 1.4s infinite; }
@keyframes px-pulse { 0% { box-shadow: 0 0 0 0 rgba(251, 113, 133, 0.6); } 70% { box-shadow: 0 0 0 6px rgba(251, 113, 133, 0); } 100% { box-shadow: 0 0 0 0 rgba(251, 113, 133, 0); } }
.px-seatbar { height: 5px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.px-seatbar > span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--px-green), var(--px-cyan)); transition: width .5s var(--ease-spring); }

/* ---------- Divider ---------- */
.px-divider { height: 1px; background: linear-gradient(90deg, transparent, var(--px-border), transparent); border: 0; }

/* ---------- Neon box glow (used on profile / stat cards) ---------- */
.neon-box { box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.32), 0 0 24px rgba(139, 92, 246, 0.2), inset 0 0 18px rgba(139, 92, 246, 0.06); }
.neon-box-cyan { box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.32), 0 0 24px rgba(34, 211, 238, 0.16), inset 0 0 18px rgba(34, 211, 238, 0.05); }

/* ---------- Utility: glow ring on hover for icons ---------- */
.px-icon-glow { transition: filter 240ms ease, transform 240ms var(--ease-spring); }
.px-icon-glow:hover { filter: drop-shadow(0 0 10px currentColor); transform: scale(1.08); }

/* Section heading underline accent (opt-in only via .px-accent-heading) */
.px-accent-heading { position: relative; display: inline-block; margin-bottom: 12px; }
.px-accent-heading::after {
  content: ''; position: absolute; left: 0; bottom: -6px; width: 36px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, var(--px-cyan), var(--px-primary)); box-shadow: 0 0 10px var(--px-cyan);
}

/* Focus-visible rings (accessibility) */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--px-cyan); outline-offset: 2px;
}

/* ============================================================
   SEARCH COMMAND PALETTE — full-screen overlay
   ============================================================ */
#px-search-overlay { position: fixed; inset: 0; z-index: 70; animation: px-search-fade 180ms ease both; }
@keyframes px-search-fade { from { opacity: 0; } to { opacity: 1; } }
#px-search-overlay > div:nth-child(2) { animation: px-search-slide 260ms cubic-bezier(0.22, 1, 0.36, 1) both; }
@keyframes px-search-slide { from { transform: translateY(-20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
#px-search-input { letter-spacing: -0.01em; }
#px-search-input::placeholder { color: rgba(151, 162, 190, 0.55); }
#px-search-input::-webkit-search-cancel-button { display: none; }
.px-search-section { padding: 10px 12px 4px; font-family: 'Russo One', sans-serif; font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--px-dim); }
.px-search-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px;
  color: #fff; font-size: 14px; line-height: 1.3; cursor: pointer;
  transition: background-color 140ms ease, transform 140ms var(--ease-spring);
  background: transparent; border: 0; width: 100%; text-decoration: none;
  min-height: 44px; pointer-events: auto; touch-action: manipulation;
}
.px-search-item:hover, .px-search-item:focus, .px-search-item.px-search-active { background: rgba(139, 92, 246, 0.15); outline: none; }
.px-search-item.px-search-active { background: linear-gradient(135deg, rgba(34, 211, 238, 0.18), rgba(56, 189, 248, 0.1)); box-shadow: inset 0 0 12px rgba(34, 211, 238, 0.14); }
.px-search-item img { background: rgba(255, 255, 255, 0.04); border-radius: 6px; padding: 2px; }
#px-search-results { scrollbar-width: thin; }
#px-search-results::-webkit-scrollbar { width: 6px; }
#px-search-results::-webkit-scrollbar-thumb { background: rgba(139,92,246,0.4); border-radius: 999px; }
@media (max-width: 640px) {
  #px-search-overlay > div:nth-child(2) { margin-top: 6vh; }
  #px-search-input { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) { #px-search-overlay, #px-search-overlay > div:nth-child(2) { animation: none; } }

/* Live notification ticker (created dynamically by app.js) */
#px-notif-bar { }
#px-notif-track { animation-duration: 60s !important; }

/* ---------- Mobile performance: reduce blur load on low-power GPUs ---------- */
@media (max-width: 768px) {
  .px-topbar, .px-card, .glass-card, .glass, .px-modal-backdrop, .px-sidebar, .px-drawer,
  .px-badge-live, .px-badge-done, .px-badge-soon {
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }
  .px-topbar { background: rgba(9, 11, 20, 0.96); }
  /* Keep bottom nav blurred for the glass look, just with lighter blur */
  .px-bottomnav {
    -webkit-backdrop-filter: blur(16px) saturate(150%) !important;
    backdrop-filter: blur(16px) saturate(150%) !important;
    background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(10,12,24,0.88) 40%);
  }
  .px-card, .glass-card, .glass { background: rgba(15, 17, 28, 0.95); }
  .px-logo-mark, a:hover > .px-logo-mark { filter: none; }
}

/* ---------- FOUC guard: fade in auth/wallet state after first sync ---------- */
body:not(.px-ui-ready) [data-auth],
body:not(.px-ui-ready) #wallet-balance,
body:not(.px-ui-ready) .wallet-balance,
body:not(.px-ui-ready) .px-bell-dot {
  opacity: 0;
}
body.px-ui-ready [data-auth],
body.px-ui-ready #wallet-balance,
body.px-ui-ready .wallet-balance,
body.px-ui-ready .px-bell-dot {
  opacity: 1;
  transition: opacity 220ms ease;
}

/* ============================================================
   Podium Top-3 Leaderboard (index.html mini widget)
   ============================================================ */
.px-podium-wrap {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.5rem 0 1rem;
}
.px-podium-card {
  position: relative;
  flex: 1;
  max-width: 160px;
  min-width: 90px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 1.25rem 0.75rem 1.5rem;
  border-radius: 1.25rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(12px);
  text-decoration: none;
  overflow: hidden;
  transition: transform 200ms ease, box-shadow 200ms ease;
}
.px-podium-card:nth-child(2) {       /* center #1 card */
  max-width: 200px;
  padding: 1.5rem 0.75rem 1.75rem;
  border-color: rgba(255,176,32,0.3);
  background: rgba(255,176,32,0.06);
}
.px-podium-card:hover { transform: translateY(-4px); }
.px-podium-medal { font-size: 1.75rem; line-height: 1; }
.px-podium-avatar {
  width: 52px; height: 52px;
  border-radius: 50%;
  border: 2px solid;
  background: rgba(255,255,255,0.06);
  display: flex; align-items: center; justify-content: center;
  margin: 0.25rem 0;
}
.px-podium-card:nth-child(2) .px-podium-avatar { width: 64px; height: 64px; }
.px-podium-rank {
  font-size: 0.75rem; font-weight: 800;
  letter-spacing: 0.05em; text-transform: uppercase;
}
.px-podium-name {
  font-weight: 700; font-size: 0.82rem;
  color: #fff; max-width: 100%; text-align: center;
}
.px-podium-card:nth-child(2) .px-podium-name { font-size: 0.95rem; }
.px-podium-earnings {
  font-size: 0.75rem; font-weight: 700;
  color: #4ADE80; margin-top: 0.1rem;
}
.px-podium-base {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 4px; border-radius: 0 0 1.25rem 1.25rem;
}
@media (max-width: 400px) {
  .px-podium-wrap { gap: 0.5rem; }
  .px-podium-card { min-width: 80px; padding: 1rem 0.5rem 1.25rem; }
  .px-podium-card:nth-child(2) { max-width: 160px; }
  .px-podium-medal { font-size: 1.4rem; }
  .px-podium-avatar { width: 44px; height: 44px; }
  .px-podium-card:nth-child(2) .px-podium-avatar { width: 56px; height: 56px; }
}