/* ============================================================
   PlayXcrew â€” Premium Design System
   ============================================================ */

:root {
  /* Base surfaces */
  --px-bg: #060912;
  --px-bg-2: #0A0E1C;
  --px-nav: #070A16;
  --px-card: #0E1222;
  --px-surface: #131A30;
  --px-muted: #161C33;
  --px-border: rgba(255, 255, 255, 0.10);

  /* Brand */
  --px-primary: #7C3AFF;
  --px-primary-2: #A855F7;
  --px-glow: #C084FC;
  --px-blue: #2E8BFF;
  --px-cyan: #38E6F5;
  --px-green: #2BE58B;
  --px-orange: #FFB020;
  --px-red: #FF4D7D;
  --px-pink: #FF5FA2;

  /* Type */
  --px-text: #F4F7FF;
  --px-dim: #9BA6C4;
  --px-dim-2: #6B7693;

  /* Reserved height for the live notification ticker. Kept at 0 so the bar
     floats over the very top edge of content (cards have p-6 padding, so text
     stays clear). Space is still reserved up front via this var to avoid any
     first-paint layout shift. */
  --px-notif-h: 0px;

  /* Unified top bar height (mobile / desktop set below). */
  --px-topbar-h: 58px;

  /* 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);

  /* Glow shadows */
  --shadow-glow: 0 0 24px rgba(124, 58, 255, 0.35);
  --shadow-card: 0 18px 50px rgba(0, 0, 0, 0.55);
}

* { -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; }

/* ---------- Ambient background (aurora + grid) ---------- */
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(60rem 60rem at 12% -10%, rgba(124, 58, 255, 0.22), transparent 60%),
    radial-gradient(50rem 50rem at 100% 0%, rgba(46, 139, 255, 0.18), transparent 55%),
    radial-gradient(45rem 45rem at 80% 100%, rgba(43, 229, 139, 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.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at 50% 30%, #000 0%, transparent 80%);
  -webkit-mask-image: radial-gradient(circle at 50% 30%, #000 0%, transparent 80%);
}

/* Selection */
::selection { background: rgba(124, 58, 255, 0.4); color: #fff; }

/* Scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--px-primary), var(--px-blue));
  border-radius: 999px;
  border: 2px solid var(--px-bg);
}
* { scrollbar-width: thin; scrollbar-color: var(--px-primary) transparent; }

/* ---------- Typography helpers ---------- */
.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(124, 58, 255, 0.55), 0 0 36px rgba(124, 58, 255, 0.25); }
.text-glow-orange { text-shadow: 0 0 18px rgba(255, 176, 32, 0.6); }
.text-glow-cyan { text-shadow: 0 0 18px rgba(56, 230, 245, 0.55); }

.text-gradient-primary {
  background: linear-gradient(120deg, var(--px-primary-2), var(--px-blue) 60%, var(--px-cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.text-gradient-fire {
  background: linear-gradient(120deg, var(--px-orange), var(--px-pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Glass + gradient border ---------- */
.glass {
  position: relative;
  background: rgba(14, 18, 34, 0.62);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid var(--px-border);
  border-radius: 1rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 8px 32px rgba(0, 0, 0, 0.35);
}
.glass::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(124, 58, 255, 0.55), rgba(46, 139, 255, 0.12) 45%, transparent 70%);
  -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.7;
  transition: opacity 280ms ease;
}
.glass-hover:hover::before { opacity: 1; }

.glass-nav {
  position: relative;
  background: rgba(7, 10, 22, 0.7);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-bottom: 1px solid rgba(124, 58, 255, 0.22);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.45), 0 0 24px rgba(124, 58, 255, 0.08);
}

/* Premium card variant with animated gradient border */
.glass-card {
  position: relative;
  background: rgba(14, 18, 34, 0.7);
  border-radius: 1.25rem;
  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(124, 58, 255, 0.0),
    rgba(124, 58, 255, 0.55),
    rgba(46, 139, 255, 0.45),
    rgba(56, 230, 245, 0.3),
    rgba(124, 58, 255, 0.0));
  animation: spin-slow 8s linear infinite;
  opacity: 0.55;
  transition: opacity 300ms ease;
}
.glass-card > .glass-card-inner {
  position: relative;
  z-index: 1;
  height: 100%;
  background: rgba(10, 13, 26, 0.92);
  border-radius: 1.15rem;
  backdrop-filter: blur(8px);
}
.glass-card:hover::before { opacity: 0.95; }

/* Card hover lift */
.card-hover {
  transition: transform 280ms var(--ease-spring), box-shadow 280ms var(--ease-spring), border-color 280ms ease;
}
a.card-hover, .card-hover[onclick] { cursor: pointer; }
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 46px rgba(0, 0, 0, 0.5), 0 0 30px rgba(124, 58, 255, 0.22);
  border-color: rgba(124, 58, 255, 0.45);
}
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, 58px);
  display: flex; align-items: center;
}
@media (min-width: 768px) { :root { --px-topbar-h: 66px; } }
.px-topbar-inner {
  width: 100%; max-width: 80rem; margin: 0 auto;
  padding: 0 0.875rem;
  display: flex; align-items: center; justify-content: space-between;
  gap: 0.75rem;
}
@media (min-width: 768px) { .px-topbar-inner { padding: 0 1.5rem; gap: 1.25rem; } }
.px-logo-mark {
  width: 34px; height: 34px; flex: 0 0 auto;
  filter: drop-shadow(0 0 10px rgba(124, 58, 255, 0.55));
  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 14px rgba(124, 58, 255, 0.85)); }
@media (min-width: 768px) { .px-logo-mark { width: 38px; height: 38px; } }
.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.25rem; } }

/* Desktop primary nav links */
.px-topnav { display: none; }
@media (min-width: 900px) {
  .px-topnav { display: flex; align-items: center; gap: 0.25rem; }
}
.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.05); }
.px-navlink.active { color: #fff; background: rgba(124, 58, 255, 0.14); }
.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-blue));
  box-shadow: 0 0 10px rgba(124, 58, 255, 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, #ff4d6d);
  border: 2px solid rgba(7, 10, 22, 0.9);
  display: none;
}
.px-bell-btn .px-bell-dot.active { display: block; }

/* Keep the top bar from overflowing / clipping the avatar on narrow screens */
.px-topbar-inner {
  padding-right: max(0.875rem, env(safe-area-inset-right));
  padding-left: max(0.875rem, env(safe-area-inset-left));
  overflow: visible;
}
.px-topbar-inner > div:first-child { min-width: 0; flex: 0 1 auto; }
.px-topbar-inner > div:last-child { flex: 0 0 auto; }
.px-topbar .px-wordmark { overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 359px) { .px-topbar .px-wordmark { display: none; } }

/* ---------- Mobile drawer (real CSS, no Tailwind JIT flash) ---------- */
.px-drawer {
  position: fixed; top: 0; left: 0; height: 100%;
  width: 18rem; max-width: 84vw;
  background: var(--px-nav);
  border-right: 1px solid var(--px-border);
  z-index: 50;
  transform: translateX(-100%);
  transition: transform 320ms var(--ease-spring);
  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 var(--px-border);
}
.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, var(--px-border), transparent);
  margin: 0.75rem 0;
}
.px-drawer-footer {
  padding: 1rem 0.75rem;
  border-top: 1px solid var(--px-border);
}
.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-blue));
  color: #fff;
  font-weight: 600;
  font-size: 0.875rem;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(124, 58, 255, 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(124, 58, 255, 0.5);
}
.px-drawer-overlay {
  position: fixed; inset: 0;
  background: rgba(2, 4, 10, 0.72);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  z-index: 45;
  opacity: 0; visibility: hidden;
  transition: opacity 300ms ease, visibility 300ms ease;
}
.px-drawer-overlay.open { opacity: 1; visibility: visible; }
.px-noscroll { overflow: hidden; }

.px-icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: 9999px;
  color: #fff;
  background: transparent;
  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.06); border-color: var(--px-border); transform: scale(1.05); }
.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;
  background: linear-gradient(135deg, rgba(43, 229, 139, 0.12), rgba(14, 18, 34, 0.6));
  border: 1px solid rgba(43, 229, 139, 0.35);
  font-weight: 600; 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(43, 229, 139, 0.7); transform: translateY(-1px); box-shadow: 0 0 18px rgba(43, 229, 139, 0.25); }
.px-wallet-pill:focus-visible { outline: 2px solid var(--px-green); outline-offset: 2px; }

.px-avatar {
  position: relative;
  width: 36px; height: 36px;
  border-radius: 9999px;
  padding: 2px;
  background: linear-gradient(135deg, var(--px-primary), var(--px-blue));
}
.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); }

/* ---------- Bottom nav ---------- */
.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(7, 10, 22, 0.86);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--px-border);
  z-index: -1;
  pointer-events: auto;
}
.px-bottomnav-inner {
  max-width: 80rem; margin: 0 auto;
  height: 100%;
  padding: 0 1.5rem;
  display: flex; align-items: center; justify-content: space-between;
  pointer-events: auto;
  overflow: visible;
}
.px-nav-item {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  color: var(--px-dim);
  font-size: 10px; font-weight: 600; letter-spacing: 0.01em;
  transition: color 220ms ease;
  -webkit-tap-highlight-color: transparent;
}
.px-nav-item svg {
  width: 24px; height: 24px;
  padding: 7px;
  box-sizing: content-box;
  border-radius: 14px;
  stroke-width: 2;
  transition: color 220ms ease, background 220ms ease,
              transform 260ms var(--ease-spring), box-shadow 220ms ease;
}
.px-nav-item:hover { color: #fff; }
.px-nav-item:hover svg { background: rgba(255, 255, 255, 0.06); transform: translateY(-2px); }
.px-nav-item.active { color: var(--px-primary); }
.px-nav-item.active svg {
  color: #fff;
  background: linear-gradient(135deg, var(--px-primary), var(--px-blue));
  box-shadow: 0 6px 18px rgba(124, 58, 255, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  transform: translateY(-2px);
}
.px-nav-fab {
  position: relative; top: -22px;
  width: 58px; height: 58px;
  border-radius: 9999px;
  background: linear-gradient(135deg, var(--px-primary), var(--px-blue));
  box-shadow: 0 8px 26px rgba(124, 58, 255, 0.6), 0 0 0 4px rgba(7, 10, 22, 0.86), 0 0 0 5px rgba(124, 58, 255, 0.25);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  transition: transform 220ms var(--ease-spring), box-shadow 220ms ease;
}
.px-nav-fab svg { width: 26px; height: 26px; }
.px-nav-fab:hover { transform: scale(1.08) translateY(-2px); box-shadow: 0 10px 30px rgba(124, 58, 255, 0.7), 0 0 0 4px rgba(7, 10, 22, 0.86), 0 0 0 5px rgba(124, 58, 255, 0.35); }
.px-nav-fab:active { transform: scale(0.96); }
.px-nav-fab::before {
  content: ''; position: absolute; inset: -8px; border-radius: 9999px;
  background: radial-gradient(circle, rgba(124, 58, 255, 0.4), transparent 70%);
  z-index: -1;
  animation: px-fab-pulse 2.8s ease-in-out infinite;
}
@keyframes px-fab-pulse {
  0%, 100% { opacity: 0.6; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.12); }
}

@media (max-width: 480px) {
  .px-bottomnav {
    left: 12px;
    right: 12px;
    bottom: 12px;
    height: 60px;
    padding-bottom: 0 !important;
  }
  .px-bottomnav::before {
    border: 1px solid var(--px-border);
    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: 20px;
    height: 20px;
    padding: 5px;
    border-radius: 10px;
  }
  .px-nav-fab {
    width: 50px;
    height: 50px;
    top: -18px;
    box-shadow: 0 6px 20px rgba(124, 58, 255, 0.5), 0 0 0 3px rgba(7, 10, 22, 0.86), 0 0 0 4px rgba(124, 58, 255, 0.2);
  }
  .px-nav-fab svg {
    width: 22px;
    height: 22px;
  }
}

/* ---------- 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: 600;
  font-size: 0.9375rem;
  line-height: 1;
  cursor: pointer;
  transition: transform 200ms var(--ease-spring), box-shadow 200ms ease, opacity 200ms ease;
  border: 0;
  min-height: 44px;
  position: relative;
  overflow: hidden;
}
.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 22px rgba(124, 58, 255, 0.4);
}
.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 600ms var(--ease-out);
}
.px-btn-primary:hover { transform: translateY(-1px) scale(1.02); box-shadow: 0 0 30px rgba(124, 58, 255, 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: 600; 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: 0.85rem;
  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(155, 166, 196, 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.18); }
.px-input:focus, .px-select:focus, .px-textarea:focus {
  outline: none;
  border-color: var(--px-primary);
  box-shadow: 0 0 0 3px rgba(124, 58, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
}
.px-input[aria-invalid="true"] { border-color: var(--px-red); box-shadow: 0 0 0 3px rgba(255, 77, 125, 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: 600;
  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(124, 58, 255, 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: 600; 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-blue));
  border-radius: 2px;
  box-shadow: 0 0 12px rgba(124, 58, 255, 0.6);
}

/* ---------- Modal ---------- */
.px-modal-backdrop {
  position: fixed; inset: 0; background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(6px);
  z-index: 60;
}
.px-modal-panel {
  background: var(--px-card);
  border: 1px solid var(--px-border);
  border-radius: 1.5rem;
  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: rgba(19, 22, 38, 0.95);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  font-weight: 600; font-size: 0.875rem;
  z-index: 80;
  opacity: 0;
  transition: opacity 240ms ease, transform 320ms var(--ease-bounce);
  pointer-events: none;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

/* ---------- Hero gradient ---------- */
.px-hero-bg {
  background:
    radial-gradient(circle at 70% 30%, rgba(124, 58, 255, 0.22), transparent 55%),
    linear-gradient(180deg, #0B0E1C 0%, var(--px-bg) 100%);
}

/* ---------- Theme color helpers ---------- */
.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: 4rem; padding-bottom: 1rem; }
@media (min-width: 768px) { .px-section { padding-top: 5rem; } }
.px-container { max-width: 80rem; margin: 0 auto; padding-left: 1rem; padding-right: 1rem; }

/* Decorative section heading */
.px-eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.35rem 0.85rem; border-radius: 999px;
  background: rgba(124, 58, 255, 0.12);
  border: 1px solid rgba(124, 58, 255, 0.3);
  color: var(--px-glow);
  font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em;
}

/* ---------- Logo invert ---------- */
.logo-invert { filter: brightness(0) invert(1); }

/* ---------- Hide scrollbars on horizontal lists ---------- */
.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: 600;
  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%); } }

/* ---------- Countdown ---------- */
.px-countdown { font-family: 'Russo One', monospace; font-variant-numeric: tabular-nums; }

/* ---------- Safe padding ---------- */
/* !important: Tailwind's py-* utilities are injected at runtime AFTER this
   stylesheet and would otherwise override padding-top, hiding content under
   the fixed top bar + notification ticker. Base is the exact top-bar height
   (64px); the live notification bar height is added via --px-notif-h. */
.pb-safe { padding-bottom: calc(64px + env(safe-area-inset-bottom)) !important; }
  .pt-safe { padding-top: calc(var(--px-topbar-h, 58px) + var(--px-notif-h, 0px) + env(safe-area-inset-top)) !important; }
.pt-safe-notif { padding-top: calc(var(--px-topbar-h, 58px) + var(--px-notif-h, 0px) + env(safe-area-inset-top)) !important; }

/* ---------- Badges / chips ---------- */
.px-chip {
  display: inline-flex; align-items: center; gap: 0.35rem;
  padding: 0.25rem 0.6rem; border-radius: 999px;
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.04em;
  text-transform: uppercase;
}
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(122, 46, 255, 0.18);
  color: #fff;
  border-color: rgba(122, 46, 255, 0.5);
}
.px-chip-live { background: rgba(255, 77, 125, 0.14); color: var(--px-red); border: 1px solid rgba(255, 77, 125, 0.35); }
.px-chip-green { background: rgba(43, 229, 139, 0.14); color: var(--px-green); border: 1px solid rgba(43, 229, 139, 0.35); }
.px-chip-blue { background: rgba(46, 139, 255, 0.14); color: var(--px-blue); border: 1px solid rgba(46, 139, 255, 0.35); }
.px-chip-orange { background: rgba(255, 176, 32, 0.14); color: var(--px-orange); border: 1px solid rgba(255, 176, 32, 0.35); }

/* ---------- Divider ---------- */
.px-divider { height: 1px; background: linear-gradient(90deg, transparent, var(--px-border), transparent); border: 0; }

/* ---------- 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); }

/* ---------- Tournament card (Batch 1) ---------- */
.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(255, 77, 125, 0.18); color: var(--px-red); border: 1px solid rgba(255, 77, 125, 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(46, 139, 255, 0.16); color: var(--px-blue); border: 1px solid rgba(46, 139, 255, 0.35); }
.px-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--px-red); box-shadow: 0 0 0 0 rgba(255, 77, 125, 0.7); animation: px-pulse 1.4s infinite; }
@keyframes px-pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 77, 125, 0.6); }
  70% { box-shadow: 0 0 0 6px rgba(255, 77, 125, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 77, 125, 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); }
.px-live-now { color: var(--px-red) !important; font-weight: 700; }

/* PlayXcrew Animations - bouncy, fluid motion */

:root {
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-spring: cubic-bezier(0.22, 1, 0.36, 1);
  --dur-micro: 220ms;
  --dur-soft: 400ms;
  --dur-page: 700ms;
}

@keyframes bounce-in {
  0%   { opacity: 0; transform: scale(0.6); }
  60%  { opacity: 1; transform: scale(1.08); }
  80%  { transform: scale(0.96); }
  100% { transform: scale(1); }
}
.bounce-in { animation: bounce-in 600ms var(--ease-bounce) both; }

@keyframes spring-pop {
  0%   { opacity: 0; transform: scale(0.85) translateY(10px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
.spring-pop { animation: spring-pop 420ms var(--ease-spring) both; }

@keyframes fade-up {
  0%   { opacity: 0; transform: translateY(18px); }
  100% { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fade-up 500ms var(--ease-spring) both; }
.stagger > * { animation: fade-up 500ms var(--ease-spring) both; }
.stagger > *:nth-child(1) { animation-delay: 0ms; }
.stagger > *:nth-child(2) { animation-delay: 40ms; }
.stagger > *:nth-child(3) { animation-delay: 80ms; }
.stagger > *:nth-child(4) { animation-delay: 120ms; }
.stagger > *:nth-child(5) { animation-delay: 160ms; }
.stagger > *:nth-child(6) { animation-delay: 200ms; }
.stagger > *:nth-child(7) { animation-delay: 240ms; }
.stagger > *:nth-child(8) { animation-delay: 280ms; }

@keyframes glow-pulse {
  0%,100% { box-shadow: 0 0 14px rgba(122,46,255,0.35), 0 0 28px rgba(122,46,255,0.18); }
  50%     { box-shadow: 0 0 24px rgba(122,46,255,0.6),  0 0 50px rgba(122,46,255,0.28); }
}
.glow-pulse { animation: glow-pulse 3s ease-in-out infinite; }

@keyframes float {
  0%,100% { transform: translateY(0); }
  50%     { transform: translateY(-8px); }
}
.float { animation: float 4s ease-in-out infinite; }

@keyframes live-dot {
  0%,100% { opacity: 1; }
  50%     { opacity: 0.55; }
}
.live-dot { animation: live-dot 2.4s ease-in-out infinite; }

@keyframes tilt-shimmer {
  0%,100% { transform: perspective(600px) rotateY(0deg); }
  50%     { transform: perspective(600px) rotateY(8deg); }
}
.tilt-hover { transition: transform 300ms var(--ease-spring); }
.tilt-hover:hover { transform: perspective(600px) rotateY(8deg) rotateX(4deg) scale(1.03); }

@keyframes neon-sweep {
  0%   { transform: translateX(-120%); opacity: 0; }
  20%  { opacity: 0.7; }
  100% { transform: translateX(120%); opacity: 0; }
}
.neon-sweep { position: relative; overflow: hidden; }
.neon-sweep::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(122,46,255,0.35), transparent);
  transform: translateX(-120%);
  animation: neon-sweep 2.2s ease-in-out infinite;
  pointer-events: none;
}

@keyframes shake {
  0%,100% { transform: translateX(0); }
  20%     { transform: translateX(-6px); }
  40%     { transform: translateX(6px); }
  60%     { transform: translateX(-4px); }
  80%     { transform: translateX(4px); }
}
.shake { animation: shake 420ms var(--ease-spring); }

@keyframes success-check {
  0%   { opacity: 0; transform: scale(0.4) rotate(-20deg); }
  60%  { opacity: 1; transform: scale(1.15) rotate(0); }
  100% { transform: scale(1) rotate(0); }
}
.success-check { animation: success-check 600ms var(--ease-bounce) both; }

@keyframes press-pop {
  0%   { transform: scale(1); }
  50%  { transform: scale(0.94); }
  100% { transform: scale(1); }
}
.press-pop:active { animation: press-pop 180ms var(--ease-spring); }

@keyframes spin-slow {
  to { transform: rotate(360deg); }
}
.spin-slow { animation: spin-slow 18s linear infinite; }

@keyframes wiggle {
  0%,100% { transform: rotate(0deg); }
  25%     { transform: rotate(6deg); }
  75%     { transform: rotate(-6deg); }
}
.wiggle:hover { animation: wiggle 380ms ease-in-out; }

@keyframes px-notif-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
#px-notif-track { animation-duration: 60s !important; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .float, .glow-pulse, .live-dot, .neon-sweep::after { animation: none !important; }
}

/* Helper: animate when in view */
.in-view { animation-play-state: running !important; }

/* ---- added for pages that referenced premium.css ---- */
.gradient-text {
  background: linear-gradient(135deg, #7C3AFF, #2E8BFF);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
