/* ═══════════════════════════════════════════════════════════════
   RALLY RACING MASTERS — AAA Portal Screen Styles v3.0
   "Nitro Chrome" — Motorsport luxury meets neon tachometer glow
   ═══════════════════════════════════════════════════════════════ */

/* ── DESIGN TOKENS ── */
:root {
  --scr-bg: rgba(6,6,12,.98);
  --scr-blur: blur(24px);
  --glass: rgba(255,255,255,.035);
  --glass-border: rgba(255,255,255,.07);
  --glass-hover: rgba(255,255,255,.065);
  --glass-active: rgba(255,255,255,.09);
  --glow-purple: rgba(168,85,247,.35);
  --glow-gold: rgba(255,215,0,.35);
  --glow-green: rgba(34,197,94,.35);
  --glow-red: rgba(239,68,68,.3);
  --glow-teal: rgba(20,184,166,.35);
  --carbon: repeating-linear-gradient(45deg,transparent,transparent 2px,rgba(255,255,255,.012) 2px,rgba(255,255,255,.012) 4px);
  --chrome-shine: linear-gradient(135deg,rgba(255,255,255,.06) 0%,transparent 40%,transparent 60%,rgba(255,255,255,.03) 100%);
  --t-fast: .15s ease;
  --t-med: .28s cubic-bezier(.16,1,.3,1);
  --t-slow: .45s cubic-bezier(.16,1,.3,1);
  --t-spring: .5s cubic-bezier(.34,1.56,.64,1);
  --font-display: 'Oswald', 'Barlow Condensed', system-ui, sans-serif;
  --font-body: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
}

/* ── SCREEN OVERLAY SHELL ── */
.screen-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: var(--scr-bg);
  backdrop-filter: var(--scr-blur);
  -webkit-backdrop-filter: var(--scr-blur);
  display: none; flex-direction: column;
  overflow: hidden;
}
.screen-overlay.show {
  display: flex;
  animation: scrReveal var(--t-slow) forwards;
}
@keyframes scrReveal {
  from { opacity: 0; transform: scale(.97) translateY(12px); }
  to   { opacity: 1; transform: none; }
}
@keyframes scrDismiss {
  from { opacity: 1; transform: none; }
  to   { opacity: 0; transform: scale(.97) translateY(12px); }
}

/* ── SCREEN HEADER ── */
.screen-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px; flex-shrink: 0; z-index: 2;
  background: linear-gradient(180deg, rgba(10,10,18,.95), rgba(10,10,18,.85));
  border-bottom: 1px solid var(--glass-border);
  position: relative;
}
.screen-header::after {
  content: ''; position: absolute; bottom: 0; left: 20px; right: 20px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--primary, #a855f7), transparent);
  opacity: .4;
}
.screen-header h2 {
  font-family: var(--font-display); font-size: 18px; font-weight: 800;
  color: #fff; margin: 0; letter-spacing: .6px; text-transform: uppercase;
}
.screen-header-sub {
  font-size: 11px; color: rgba(255,255,255,.4); margin-top: 3px;
  letter-spacing: .3px; font-weight: 500;
}
.screen-close {
  background: rgba(255,255,255,.05); border: 1px solid var(--glass-border);
  color: rgba(255,255,255,.5); font-size: 22px; cursor: pointer;
  width: 44px; height: 44px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--t-fast); line-height: 1;
}
.screen-close:hover {
  color: #fff; background: rgba(239,68,68,.15);
  border-color: rgba(239,68,68,.3);
}

/* ── SCREEN BODY ── */
.screen-body {
  flex: 1; overflow-y: auto; overflow-x: hidden;
  padding: 20px; -webkit-overflow-scrolling: touch;
  background: var(--carbon);
}
.screen-body::-webkit-scrollbar { width: 3px; }
.screen-body::-webkit-scrollbar-track { background: transparent; }
.screen-body::-webkit-scrollbar-thumb { background: rgba(168,85,247,.25); border-radius: 3px; }

/* ── SHARED: CARD ── */
.s-card {
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: var(--radius-md); padding: 16px;
  transition: all var(--t-med); position: relative; overflow: hidden;
}
.s-card::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: var(--chrome-shine); border-radius: inherit;
}
.s-card:hover {
  border-color: rgba(168,85,247,.2);
  box-shadow: 0 8px 32px rgba(0,0,0,.3), 0 0 0 1px rgba(168,85,247,.08);
  transform: translateY(-2px);
}

/* ── SHARED: ICON BOX ── */
.s-icon {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; position: relative;
}
.s-icon.purple { background: linear-gradient(135deg, rgba(168,85,247,.2), rgba(124,58,237,.12)); }
.s-icon.gold   { background: linear-gradient(135deg, rgba(255,215,0,.18), rgba(245,158,11,.1)); }
.s-icon.green  { background: linear-gradient(135deg, rgba(34,197,94,.18), rgba(22,163,74,.1)); }
.s-icon.red    { background: linear-gradient(135deg, rgba(239,68,68,.18), rgba(220,38,38,.1)); }
.s-icon.teal   { background: linear-gradient(135deg, rgba(20,184,166,.18), rgba(13,148,136,.1)); }
.s-icon.blue   { background: linear-gradient(135deg, rgba(59,130,246,.18), rgba(37,99,235,.1)); }

/* ── SHARED: TABS ── */
.s-tabs {
  display: flex; gap: 6px; padding: 0 0 16px;
  overflow-x: auto; -webkit-overflow-scrolling: touch; flex-shrink: 0;
  scrollbar-width: none;
}
.s-tabs::-webkit-scrollbar { display: none; }
.s-tab {
  padding: 9px 18px; border-radius: 10px; font-size: 12px;
  font-weight: 700; border: 1px solid var(--glass-border);
  background: var(--glass); color: rgba(255,255,255,.45);
  cursor: pointer; white-space: nowrap; transition: all var(--t-fast);
  letter-spacing: .3px;
}
.s-tab:hover { background: var(--glass-hover); color: rgba(255,255,255,.7); }
.s-tab.active {
  background: rgba(168,85,247,.14); border-color: rgba(168,85,247,.35);
  color: #fff; box-shadow: 0 0 12px rgba(168,85,247,.15);
}

/* ── SHARED: SUMMARY ROW ── */
.s-summary { display: flex; gap: 10px; margin-bottom: 20px; flex-wrap: wrap; }
.s-summary-item {
  flex: 1; text-align: center; padding: 14px 10px;
  border-radius: var(--radius-md); min-width: 75px;
  background: var(--glass); border: 1px solid var(--glass-border);
  position: relative; overflow: hidden;
}
.s-summary-item::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.s-summary-num {
  font-family: var(--font-display); font-size: 24px;
  font-weight: 800; color: #fff; letter-spacing: .5px;
}
.s-summary-label {
  font-size: 10px; color: rgba(255,255,255,.35); margin-top: 3px;
  text-transform: uppercase; letter-spacing: .8px; font-weight: 600;
}

/* ── SHARED: SECTION HEADING ── */
.s-heading {
  font-family: var(--font-display); font-size: 12px; font-weight: 700;
  color: rgba(255,255,255,.3); text-transform: uppercase;
  letter-spacing: 1.2px; margin: 20px 0 12px;
  padding-bottom: 8px; position: relative;
}
.s-heading::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 32px; height: 2px; border-radius: 1px;
  background: linear-gradient(90deg, #a855f7, transparent);
}

/* ── SHARED: CTA BUTTON ── */
.s-btn {
  display: block; width: 100%; padding: 15px; border: none;
  border-radius: var(--radius-md); font-family: var(--font-display);
  font-size: 15px; font-weight: 800; cursor: pointer;
  transition: all var(--t-fast); text-transform: uppercase;
  letter-spacing: 1px; position: relative; overflow: hidden;
}
.s-btn::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,.12), transparent 50%);
  pointer-events: none;
}
.s-btn.primary {
  background: linear-gradient(135deg, #a855f7, #7c3aed);
  color: #fff; box-shadow: 0 4px 20px var(--glow-purple);
}
.s-btn.primary:hover { filter: brightness(1.12); transform: translateY(-1px); }
.s-btn.gold {
  background: linear-gradient(135deg, #ffd700, #f59e0b);
  color: #0a0a0f; box-shadow: 0 4px 20px var(--glow-gold);
}
.s-btn.gold:hover { filter: brightness(1.1); transform: translateY(-1px); }
.s-btn.green {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #fff; box-shadow: 0 4px 16px var(--glow-green);
}
.s-btn.green:hover { filter: brightness(1.12); transform: translateY(-1px); }
.s-btn.ghost {
  background: var(--glass); color: rgba(255,255,255,.5);
  border: 1px solid var(--glass-border);
}
.s-btn.ghost:hover { background: var(--glass-hover); color: #fff; }
.s-btn.done {
  background: rgba(34,197,94,.08); color: #22c55e;
  border: 1px solid rgba(34,197,94,.15); cursor: default;
}
.s-btn.pulse { animation: btnPulse 2.5s ease-in-out infinite; }
@keyframes btnPulse {
  0%,100% { box-shadow: 0 4px 16px var(--glow-purple); }
  50%     { box-shadow: 0 4px 32px rgba(168,85,247,.5); }
}

/* ── SHARED: LIST ROW ── */
.s-row {
  display: flex; align-items: center; gap: 12px;
  padding: 14px; border-radius: var(--radius-md); margin-bottom: 6px;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-fast); position: relative; overflow: hidden;
}
.s-row::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.s-row:hover { background: var(--glass-hover); }
.s-row-info { flex: 1; min-width: 0; }
.s-row-title { font-size: 13px; color: #fff; font-weight: 700; margin-bottom: 3px; }
.s-row-desc { font-size: 11px; color: rgba(255,255,255,.35); }

/* ── SHARED: PROGRESS BAR ── */
.s-progress {
  height: 5px; background: rgba(255,255,255,.06);
  border-radius: 3px; overflow: hidden; margin-top: 6px;
}
.s-progress-fill {
  height: 100%; border-radius: 3px;
  background: linear-gradient(90deg, #a855f7, #6366f1);
  transition: width .5s cubic-bezier(.16,1,.3,1);
  position: relative;
}
.s-progress-fill::after {
  content: ''; position: absolute; right: 0; top: -1px; bottom: -1px; width: 8px;
  border-radius: 0 3px 3px 0;
  background: rgba(255,255,255,.3);
  box-shadow: 0 0 6px rgba(168,85,247,.6);
}

/* ── SHARED: BADGE ── */
.s-badge {
  display: inline-block; padding: 3px 10px; border-radius: 6px;
  font-size: 10px; font-weight: 800; letter-spacing: .5px;
  text-transform: uppercase;
}
.s-badge.purple { background: rgba(168,85,247,.15); color: #a855f7; border: 1px solid rgba(168,85,247,.2); }
.s-badge.gold   { background: rgba(255,215,0,.12); color: #ffd700; border: 1px solid rgba(255,215,0,.15); }
.s-badge.green  { background: rgba(34,197,94,.12); color: #22c55e; border: 1px solid rgba(34,197,94,.15); }
.s-badge.red    { background: rgba(239,68,68,.12); color: #ef4444; border: 1px solid rgba(239,68,68,.15); }

/* ══════════════════════════════════════════════
   1. DAILY REWARDS
   ══════════════════════════════════════════════ */
.dr-streak-bar {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 20px; border-radius: var(--radius-lg); margin-bottom: 20px;
  background: linear-gradient(135deg, rgba(168,85,247,.1), rgba(59,130,246,.06));
  border: 1px solid rgba(168,85,247,.12);
  position: relative; overflow: hidden;
}
.dr-streak-bar::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.dr-streak-icon { font-size: 32px; filter: drop-shadow(0 0 8px rgba(255,160,0,.4)); }
.dr-streak-info h3 {
  font-family: var(--font-display); font-size: 16px;
  color: #fff; margin: 0 0 3px; font-weight: 700; letter-spacing: .3px;
}
.dr-streak-info p { font-size: 12px; color: rgba(255,255,255,.35); margin: 0; }
.dr-streak-count {
  margin-left: auto; font-family: var(--font-display);
  font-size: 28px; font-weight: 900; color: #a855f7;
  text-shadow: 0 0 16px var(--glow-purple);
  letter-spacing: 1px;
}

.dr-calendar {
  display: grid; grid-template-columns: repeat(7, 1fr);
  gap: 6px; margin-bottom: 20px;
}
.dr-day {
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: 12px; padding: 10px 4px; text-align: center;
  transition: all var(--t-med); position: relative;
  min-height: 76px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 3px;
  overflow: hidden;
}
.dr-day::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.dr-day.claimed {
  background: rgba(34,197,94,.06); border-color: rgba(34,197,94,.15);
}
.dr-day.claimed::after {
  content: ''; position: absolute; top: 5px; right: 6px;
  width: 14px; height: 14px; border-radius: 50%;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  box-shadow: 0 0 6px var(--glow-green);
}
.dr-day.today {
  background: rgba(168,85,247,.08); border-color: rgba(168,85,247,.25);
  box-shadow: 0 0 20px var(--glow-purple), inset 0 0 20px rgba(168,85,247,.05);
  animation: dayPulse 2.5s ease-in-out infinite;
}
@keyframes dayPulse {
  0%,100% { box-shadow: 0 0 12px var(--glow-purple); }
  50%     { box-shadow: 0 0 24px rgba(168,85,247,.45); }
}
.dr-day.today.claimable { cursor: pointer; }
.dr-day.today.claimable:hover { transform: scale(1.06); }
.dr-day.locked { opacity: .3; }
.dr-day-num {
  font-size: 9px; color: rgba(255,255,255,.3); font-weight: 700;
  text-transform: uppercase; letter-spacing: .5px;
}
.dr-day-icon { font-size: 20px; line-height: 1; }
.dr-day-amount {
  font-family: var(--font-display); font-size: 12px;
  font-weight: 700; color: rgba(255,255,255,.85);
}

.dr-bonus-row { display: flex; gap: 10px; margin-top: 16px; }
.dr-bonus-card {
  flex: 1; padding: 16px 12px; border-radius: var(--radius-md);
  text-align: center; position: relative; overflow: hidden;
  background: linear-gradient(135deg, rgba(255,215,0,.06), rgba(245,158,11,.03));
  border: 1px solid rgba(255,215,0,.1); transition: all var(--t-med);
}
.dr-bonus-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.dr-bonus-card.unlocked {
  border-color: rgba(34,197,94,.2); background: rgba(34,197,94,.05);
  box-shadow: 0 0 12px rgba(34,197,94,.1);
}
.dr-bonus-card h4 {
  font-family: var(--font-display); font-size: 12px;
  color: #ffd700; margin: 0 0 6px; font-weight: 700;
  letter-spacing: .5px; text-transform: uppercase;
}
.dr-bonus-card p { font-size: 22px; color: #fff; margin: 0; font-weight: 900; }
.dr-bonus-card .sub { font-size: 10px; color: rgba(255,255,255,.3); margin-top: 4px; }

/* ══════════════════════════════════════════════
   2. SHOP
   ══════════════════════════════════════════════ */
.shop-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: 10px;
}
.shop-item {
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: var(--radius-md); padding: 18px 12px; text-align: center;
  transition: all var(--t-med); cursor: pointer;
  position: relative; overflow: hidden;
}
.shop-item::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.shop-item:hover {
  border-color: rgba(168,85,247,.25); transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,0,0,.35), 0 0 0 1px rgba(168,85,247,.1);
}
.shop-item:active { transform: translateY(0); }
.shop-item.featured {
  border-color: rgba(255,215,0,.18);
  background: linear-gradient(135deg, rgba(255,215,0,.05), rgba(245,158,11,.02));
}
.shop-item.featured::after {
  content: 'BEST VALUE'; position: absolute; top: 10px; right: -26px;
  background: linear-gradient(135deg, #ffd700, #f59e0b); color: #0a0a0f;
  font-size: 7px; font-weight: 900; padding: 3px 30px;
  transform: rotate(45deg); letter-spacing: .8px;
}
.shop-item-icon { font-size: 36px; margin-bottom: 10px; }
.shop-item-name {
  font-size: 12px; font-weight: 700; color: rgba(255,255,255,.8);
  margin-bottom: 4px; letter-spacing: .2px;
}
.shop-item-amount {
  font-family: var(--font-display); font-size: 20px;
  font-weight: 900; color: #ffd700; margin-bottom: 8px;
  text-shadow: 0 0 8px var(--glow-gold);
}
.shop-item-bonus {
  font-size: 10px; color: #22c55e; font-weight: 700;
  margin-bottom: 10px; letter-spacing: .3px;
}
.shop-item-price {
  display: inline-block; padding: 7px 18px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #a855f7, #7c3aed); color: #fff;
  font-size: 13px; font-weight: 800; letter-spacing: .3px;
  box-shadow: 0 2px 8px var(--glow-purple);
}

.shop-vip-banner {
  padding: 20px; margin-bottom: 18px; display: flex;
  align-items: center; gap: 16px; border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(255,215,0,.08), rgba(168,85,247,.05));
  border: 1px solid rgba(255,215,0,.12);
  position: relative; overflow: hidden;
}
.shop-vip-banner::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.shop-vip-icon { font-size: 42px; filter: drop-shadow(0 0 12px rgba(255,215,0,.3)); }
.shop-vip-info h3 {
  font-family: var(--font-display); font-size: 17px;
  color: #ffd700; margin: 0 0 4px; font-weight: 800;
  letter-spacing: .5px; text-transform: uppercase;
}
.shop-vip-info p { font-size: 12px; color: rgba(255,255,255,.35); margin: 0; }
.shop-vip-btn {
  margin-left: auto; padding: 11px 24px; border-radius: 10px;
  background: linear-gradient(135deg, #ffd700, #f59e0b); color: #0a0a0f;
  font-family: var(--font-display); font-size: 14px; font-weight: 800;
  border: none; cursor: pointer; transition: all var(--t-fast);
  white-space: nowrap; letter-spacing: .5px; text-transform: uppercase;
  box-shadow: 0 4px 16px var(--glow-gold);
}
.shop-vip-btn:hover { filter: brightness(1.1); transform: scale(1.03); }

/* ══════════════════════════════════════════════
   3. SEASON PASS
   ══════════════════════════════════════════════ */
.sp-header-banner {
  padding: 22px; border-radius: var(--radius-lg); margin-bottom: 20px;
  background: linear-gradient(135deg, rgba(168,85,247,.1), rgba(59,130,246,.06));
  border: 1px solid rgba(168,85,247,.12);
  position: relative; overflow: hidden;
}
.sp-header-banner::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.sp-header-banner h3 {
  font-family: var(--font-display); font-size: 22px;
  font-weight: 900; color: #fff; margin: 0 0 6px;
  letter-spacing: .5px; text-transform: uppercase;
}
.sp-header-banner p { font-size: 13px; color: rgba(255,255,255,.4); margin: 0 0 14px; }
.sp-xp-bar {
  height: 8px; background: rgba(255,255,255,.06);
  border-radius: 4px; overflow: hidden; margin-bottom: 5px;
}
.sp-xp-fill {
  height: 100%; border-radius: 4px;
  background: linear-gradient(90deg, #a855f7, #6366f1);
  transition: width .6s cubic-bezier(.16,1,.3,1);
  position: relative;
}
.sp-xp-fill::after {
  content: ''; position: absolute; right: -1px; top: -2px; bottom: -2px; width: 6px;
  border-radius: 0 4px 4px 0; background: rgba(255,255,255,.5);
  box-shadow: 0 0 8px #a855f7;
}
.sp-xp-text { font-size: 11px; color: rgba(255,255,255,.3); }

.sp-track-labels {
  display: flex; justify-content: space-between;
  font-size: 10px; color: rgba(255,255,255,.3); font-weight: 700;
  margin-bottom: 8px; letter-spacing: .8px; text-transform: uppercase;
}
.sp-track {
  display: flex; gap: 10px; overflow-x: auto; padding: 8px 0 16px;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.sp-track::-webkit-scrollbar { display: none; }
.sp-tier {
  flex-shrink: 0; width: 96px; text-align: center;
  position: relative;
}
.sp-tier::before {
  content: ''; position: absolute; top: 50%; left: 100%; width: 10px; height: 2px;
  background: rgba(255,255,255,.06);
}
.sp-tier:last-child::before { display: none; }
.sp-tier-num {
  font-family: var(--font-display); font-size: 10px; font-weight: 700;
  color: rgba(255,255,255,.25); margin-bottom: 6px;
  letter-spacing: .8px; text-transform: uppercase;
}
.sp-tier-free, .sp-tier-premium {
  padding: 12px 6px; border-radius: 10px; margin-bottom: 5px;
  min-height: 58px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 3px;
  transition: all var(--t-fast); position: relative; overflow: hidden;
}
.sp-tier-free::before, .sp-tier-premium::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.sp-tier-free {
  background: var(--glass); border: 1px solid var(--glass-border);
}
.sp-tier-premium {
  background: linear-gradient(135deg, rgba(255,215,0,.04), rgba(168,85,247,.04));
  border: 1px solid rgba(255,215,0,.08);
}
.sp-tier.unlocked .sp-tier-free,
.sp-tier.unlocked .sp-tier-premium {
  border-color: rgba(34,197,94,.15); background: rgba(34,197,94,.04);
}
.sp-tier.current .sp-tier-free,
.sp-tier.current .sp-tier-premium {
  border-color: rgba(168,85,247,.3);
  box-shadow: 0 0 16px var(--glow-purple);
}
.sp-tier-icon { font-size: 20px; }
.sp-tier-label { font-size: 10px; color: rgba(255,255,255,.4); font-weight: 700; }

/* ══════════════════════════════════════════════
   4. LEADERBOARD
   ══════════════════════════════════════════════ */
.lb-podium {
  display: flex; gap: 8px; margin-bottom: 20px;
  align-items: flex-end; justify-content: center;
}
.lb-podium-item {
  text-align: center; padding: 16px 12px; border-radius: var(--radius-md);
  border: 1px solid var(--glass-border); background: var(--glass);
  flex: 0 0 100px; position: relative; overflow: hidden;
  transition: all var(--t-med);
}
.lb-podium-item::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.lb-podium-item.gold {
  border-color: rgba(255,215,0,.2);
  background: linear-gradient(180deg, rgba(255,215,0,.08), rgba(255,215,0,.02));
  order: 1; padding-bottom: 28px;
  box-shadow: 0 0 24px rgba(255,215,0,.1);
}
.lb-podium-item.silver {
  border-color: rgba(192,192,192,.15);
  background: linear-gradient(180deg, rgba(192,192,192,.06), rgba(192,192,192,.015));
  order: 0;
}
.lb-podium-item.bronze {
  border-color: rgba(205,127,50,.15);
  background: linear-gradient(180deg, rgba(205,127,50,.06), rgba(205,127,50,.015));
  order: 2;
}
.lb-podium-rank { font-size: 24px; margin-bottom: 6px; }
.lb-podium-name { font-size: 11px; color: #fff; font-weight: 700; margin-bottom: 4px; }
.lb-podium-score {
  font-family: var(--font-display); font-size: 13px;
  color: #ffd700; font-weight: 800;
}

.lb-list { display: flex; flex-direction: column; gap: 4px; }
.lb-row {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: 10px;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-fast);
}
.lb-row:hover { background: var(--glass-hover); }
.lb-row.self {
  border-color: rgba(168,85,247,.2);
  background: rgba(168,85,247,.05);
  box-shadow: 0 0 12px rgba(168,85,247,.08);
}
.lb-rank {
  font-family: var(--font-display); font-size: 14px;
  font-weight: 800; color: rgba(255,255,255,.3);
  min-width: 28px; text-align: center;
}
.lb-avatar {
  width: 32px; height: 32px; border-radius: 10px;
  background: linear-gradient(135deg, #a855f7, #6366f1);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: #fff; font-weight: 800;
}
.lb-name { flex: 1; font-size: 13px; color: rgba(255,255,255,.8); font-weight: 600; }
.lb-score {
  font-family: var(--font-display); font-size: 13px;
  color: #ffd700; font-weight: 700;
}

/* ══════════════════════════════════════════════
   5. MISSIONS
   ══════════════════════════════════════════════ */
.ms-card {
  display: flex; align-items: center; gap: 12px;
  padding: 14px; border-radius: var(--radius-md); margin-bottom: 6px;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-fast); position: relative; overflow: hidden;
}
.ms-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.ms-card:hover { background: var(--glass-hover); }
.ms-card.completed { opacity: .5; }
.ms-card-icon {
  width: 42px; height: 42px; border-radius: 11px; flex-shrink: 0;
  background: linear-gradient(135deg, rgba(168,85,247,.15), rgba(59,130,246,.08));
  display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.ms-card-info { flex: 1; min-width: 0; }
.ms-card-title { font-size: 13px; color: #fff; font-weight: 700; margin-bottom: 3px; }
.ms-card-desc { font-size: 11px; color: rgba(255,255,255,.3); margin-bottom: 6px; }
.ms-card-progress {
  height: 4px; background: rgba(255,255,255,.05);
  border-radius: 2px; overflow: hidden;
}
.ms-card-progress-fill {
  height: 100%; border-radius: 2px;
  background: linear-gradient(90deg, #a855f7, #6366f1);
  transition: width .4s ease;
}
.ms-card-reward { flex-shrink: 0; text-align: center; }
.ms-card-reward-icon { font-size: 18px; }
.ms-card-reward-amount {
  font-family: var(--font-display); font-size: 12px;
  font-weight: 800; color: #ffd700;
}

.ms-claim-btn {
  padding: 7px 16px; border-radius: var(--radius-sm);
  font-size: 11px; font-weight: 800; border: none; cursor: pointer;
  transition: all var(--t-fast); letter-spacing: .3px; text-transform: uppercase;
}
.ms-claim-btn.ready {
  background: linear-gradient(135deg, #22c55e, #16a34a); color: #fff;
  box-shadow: 0 2px 8px var(--glow-green);
}
.ms-claim-btn.ready:hover { filter: brightness(1.12); transform: scale(1.02); }
.ms-claim-btn.done {
  background: rgba(34,197,94,.08); color: #22c55e;
  border: 1px solid rgba(34,197,94,.15); cursor: default;
}

/* ══════════════════════════════════════════════
   6. ACHIEVEMENTS
   ══════════════════════════════════════════════ */
.ach-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
}
.ach-card {
  padding: 18px 12px; border-radius: var(--radius-md); text-align: center;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-med); position: relative; overflow: hidden;
}
.ach-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.ach-card:hover { background: var(--glass-hover); transform: translateY(-2px); }
.ach-card.unlocked {
  border-color: rgba(255,215,0,.12);
  box-shadow: 0 0 12px rgba(255,215,0,.06);
}
.ach-card.locked { opacity: .3; filter: grayscale(.8); }
.ach-card-icon { font-size: 30px; margin-bottom: 8px; }
.ach-card-name { font-size: 12px; font-weight: 700; color: #fff; margin-bottom: 4px; }
.ach-card-desc { font-size: 10px; color: rgba(255,255,255,.3); line-height: 1.4; }
.ach-card-xp {
  font-family: var(--font-display); font-size: 11px;
  color: #a855f7; font-weight: 700; margin-top: 8px;
  letter-spacing: .3px;
}

/* ══════════════════════════════════════════════
   7. PROFILE
   ══════════════════════════════════════════════ */
.prof-hero {
  text-align: center; margin-bottom: 24px; padding: 20px 0;
  position: relative;
}
.prof-hero::before {
  content: ''; position: absolute; top: 0; left: 50%;
  width: 200px; height: 200px; transform: translateX(-50%);
  background: radial-gradient(circle, rgba(168,85,247,.12), transparent 70%);
  pointer-events: none;
}
.prof-avatar-ring {
  width: 88px; height: 88px; border-radius: 50%; margin: 0 auto 14px;
  background: linear-gradient(135deg, #a855f7, #ffd700);
  padding: 3px; position: relative;
}
.prof-avatar-ring::after {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid rgba(168,85,247,.2);
}
.prof-avatar-inner {
  width: 100%; height: 100%; border-radius: 50%;
  background: linear-gradient(135deg, #12121c, #0a0a14);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-size: 32px;
  color: #fff; font-weight: 900;
}
.prof-name {
  font-family: var(--font-display); font-size: 20px;
  font-weight: 800; color: #fff; letter-spacing: .5px;
}
.prof-title {
  font-size: 12px; color: #a855f7; font-weight: 600;
  margin-top: 4px; letter-spacing: .3px;
}
.prof-stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 8px; margin-bottom: 24px;
}
.prof-stat {
  text-align: center; padding: 14px 8px; border-radius: var(--radius-md);
  background: var(--glass); border: 1px solid var(--glass-border);
  position: relative; overflow: hidden;
}
.prof-stat::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.prof-stat-num {
  font-family: var(--font-display); font-size: 22px;
  font-weight: 900; color: #fff;
}
.prof-stat-label {
  font-size: 9px; color: rgba(255,255,255,.3); margin-top: 3px;
  text-transform: uppercase; letter-spacing: .8px; font-weight: 600;
}

/* ══════════════════════════════════════════════
   8. EVENTS
   ══════════════════════════════════════════════ */
.ev-tabs { display: flex; gap: 6px; margin-bottom: 16px; overflow-x: auto; scrollbar-width: none; }
.ev-tabs::-webkit-scrollbar { display: none; }
.ev-card {
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg); padding: 20px; margin-bottom: 10px;
  transition: all var(--t-med); position: relative; overflow: hidden;
}
.ev-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.ev-card:hover { background: var(--glass-hover); }
.ev-card.ev-live { border-left: 3px solid #22c55e; }
.ev-card.ev-upcoming { border-left: 3px solid #a855f7; }
.ev-card.ev-completed { border-left: 3px solid rgba(255,255,255,.15); opacity: .6; }

.ev-card-header { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.ev-card-icon { font-size: 32px; flex-shrink: 0; }
.ev-card-name {
  font-family: var(--font-display); font-size: 16px;
  font-weight: 800; color: #fff; letter-spacing: .3px;
}
.ev-card-status {
  font-size: 11px; font-weight: 700; margin-top: 3px; letter-spacing: .3px;
}
.ev-card-status.ev-live { color: #22c55e; }
.ev-card-status.ev-upcoming { color: #a855f7; }
.ev-card-status.ev-completed { color: rgba(255,255,255,.3); }
.ev-card-desc { font-size: 13px; color: rgba(255,255,255,.35); margin-bottom: 12px; line-height: 1.5; }
.ev-card-footer {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12px; color: rgba(255,255,255,.35); flex-wrap: wrap;
  gap: 8px; margin-bottom: 14px;
}
.ev-card-reward { color: #ffd700; font-weight: 700; }
.ev-card-participants { color: rgba(255,255,255,.3); }
.ev-card-winner { color: #ffd700; font-weight: 700; }
.ev-label { color: rgba(255,255,255,.3); font-weight: 400; }

.ev-join-btn {
  display: block; width: 100%; padding: 12px; border: none;
  border-radius: 10px; font-family: var(--font-display);
  font-size: 13px; font-weight: 800; cursor: pointer;
  transition: all var(--t-fast); text-transform: uppercase; letter-spacing: .8px;
}
.ev-join-btn:not(.upcoming) {
  background: linear-gradient(135deg, #22c55e, #16a34a); color: #fff;
  box-shadow: 0 4px 12px var(--glow-green);
}
.ev-join-btn.upcoming {
  background: linear-gradient(135deg, #a855f7, #7c3aed); color: #fff;
  box-shadow: 0 4px 12px var(--glow-purple);
}
.ev-join-btn:hover { filter: brightness(1.1); transform: translateY(-1px); }

/* ══════════════════════════════════════════════
   9. FRIENDS
   ══════════════════════════════════════════════ */
.fr-search-row { display: flex; gap: 8px; margin-bottom: 16px; }
.fr-search-input {
  flex: 1; padding: 11px 16px; border-radius: 10px;
  border: 1px solid var(--glass-border); background: var(--glass);
  color: #fff; font-size: 13px; outline: none;
  transition: border-color var(--t-fast);
}
.fr-search-input::placeholder { color: rgba(255,255,255,.2); }
.fr-search-input:focus { border-color: rgba(168,85,247,.4); box-shadow: 0 0 12px rgba(168,85,247,.1); }
.fr-search-btn {
  padding: 11px 20px; border-radius: 10px; border: none;
  background: linear-gradient(135deg, #a855f7, #7c3aed); color: #fff;
  font-size: 13px; font-weight: 700; cursor: pointer;
  transition: all var(--t-fast);
}
.fr-search-btn:hover { filter: brightness(1.1); }

.fr-gift-all-btn {
  display: block; width: 100%; padding: 12px; margin-bottom: 16px;
  border: 1px solid rgba(255,215,0,.15); border-radius: 10px;
  background: rgba(255,215,0,.04); color: #ffd700;
  font-size: 13px; font-weight: 700; cursor: pointer;
  transition: all var(--t-fast); letter-spacing: .3px;
}
.fr-gift-all-btn:hover { background: rgba(255,215,0,.08); }

.fr-card {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 12px; margin-bottom: 6px;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-fast); position: relative; overflow: hidden;
}
.fr-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.fr-card:hover { background: var(--glass-hover); }
.fr-card.suggested { border-style: dashed; opacity: .7; }

.fr-avatar {
  width: 42px; height: 42px; border-radius: 12px; position: relative;
  background: linear-gradient(135deg, #a855f7, #6366f1);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; color: #fff; font-weight: 800; flex-shrink: 0;
}
.fr-status-dot {
  position: absolute; bottom: -1px; right: -1px; width: 12px; height: 12px;
  border-radius: 50%; border: 2px solid rgba(10,10,15,.95);
}
.fr-info { flex: 1; min-width: 0; }
.fr-name { font-size: 13px; color: #fff; font-weight: 700; }
.fr-level { font-size: 11px; color: #a855f7; font-weight: 700; }
.fr-meta { font-size: 11px; color: rgba(255,255,255,.3); margin-top: 2px; }

.fr-actions { display: flex; gap: 6px; flex-shrink: 0; }
.fr-action-btn {
  width: 38px; height: 38px; border-radius: 10px;
  border: 1px solid var(--glass-border); background: var(--glass);
  color: rgba(255,255,255,.6); font-size: 16px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--t-fast);
}
.fr-action-btn:hover {
  border-color: rgba(168,85,247,.3); background: rgba(168,85,247,.1);
  color: #fff;
}
.fr-action-btn.add {
  background: rgba(34,197,94,.08); border-color: rgba(34,197,94,.15);
  color: #22c55e; font-weight: 900;
}

/* ══════════════════════════════════════════════
   10. LUCKY WHEEL
   ══════════════════════════════════════════════ */
.whl-container { max-width: 400px; margin: 0 auto; }
.whl-stats { display: flex; gap: 12px; margin-bottom: 20px; }

.whl-wheel-wrap {
  position: relative; width: 280px; height: 280px;
  margin: 0 auto 24px;
}
.whl-wheel {
  width: 100%; height: 100%; border-radius: 50%;
  position: relative; overflow: hidden;
  border: 3px solid rgba(168,85,247,.3);
  box-shadow:
    0 0 40px rgba(168,85,247,.2),
    0 0 80px rgba(168,85,247,.08),
    inset 0 0 30px rgba(0,0,0,.5);
}
.whl-segment {
  position: absolute; width: 50%; height: 50%;
  top: 0; left: 50%; transform-origin: 0% 100%;
  clip-path: polygon(0 100%, 100% 0, 100% 100%);
  display: flex; align-items: center; justify-content: center;
}
.whl-seg-content {
  transform: rotate(20deg) translateX(30px) translateY(-20px);
  text-align: center;
}
.whl-seg-icon { font-size: 18px; display: block; }
.whl-seg-amount {
  font-family: var(--font-display); font-size: 10px;
  font-weight: 900; color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,.6);
}

.whl-pointer {
  position: absolute; top: -10px; left: 50%; transform: translateX(-50%);
  font-size: 28px; color: #ffd700; z-index: 2;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,.5));
}

.whl-spin-btn {
  display: block; width: 100%; padding: 16px; border: none;
  border-radius: var(--radius-md); font-family: var(--font-display);
  font-size: 16px; font-weight: 900; cursor: pointer;
  transition: all var(--t-fast); text-transform: uppercase; letter-spacing: 1px;
}
.whl-spin-btn.ready {
  background: linear-gradient(135deg, #a855f7, #7c3aed); color: #fff;
  box-shadow: 0 4px 24px var(--glow-purple);
  animation: btnPulse 2.5s ease-in-out infinite;
}
.whl-spin-btn.ready:hover { filter: brightness(1.12); transform: translateY(-1px); }
.whl-spin-btn.done {
  background: var(--glass); color: rgba(255,255,255,.3);
  border: 1px solid var(--glass-border); cursor: default;
}

.whl-prizes { display: flex; flex-direction: column; gap: 4px; }
.whl-prize-item {
  display: flex; align-items: center; gap: 10px; padding: 9px 14px;
  border-radius: var(--radius-sm); background: var(--glass);
  border: 1px solid var(--glass-border);
}
.whl-prize-icon { font-size: 18px; width: 28px; text-align: center; }
.whl-prize-amount { flex: 1; font-size: 13px; color: rgba(255,255,255,.7); font-weight: 600; }
.whl-prize-chance {
  font-family: var(--font-display); font-size: 11px;
  color: rgba(255,255,255,.3); font-weight: 700;
}

/* ══════════════════════════════════════════════
   11. MATCH-3 BONUS GAME
   ══════════════════════════════════════════════ */
.m3-hud {
  display: flex; gap: 12px; margin-bottom: 16px; justify-content: center;
}
.m3-hud-item {
  text-align: center; padding: 10px 22px; border-radius: 12px;
  background: var(--glass); border: 1px solid var(--glass-border);
  position: relative; overflow: hidden;
}
.m3-hud-item::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.m3-hud-label {
  display: block; font-size: 9px; color: rgba(255,255,255,.3);
  text-transform: uppercase; margin-bottom: 3px;
  letter-spacing: .8px; font-weight: 600;
}
.m3-hud-val {
  display: block; font-family: var(--font-display);
  font-size: 22px; font-weight: 900;
}

.m3-board {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px;
  max-width: 350px; margin: 0 auto 20px; padding: 12px;
  background: rgba(0,0,0,.35); border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  box-shadow: inset 0 2px 12px rgba(0,0,0,.3);
}
.m3-cell {
  aspect-ratio: 1; display: flex; align-items: center; justify-content: center;
  font-size: 24px; border-radius: var(--radius-sm); cursor: pointer;
  background: var(--glass); border: 2px solid transparent;
  transition: all .12s ease; user-select: none; -webkit-user-select: none;
}
.m3-cell:hover { background: var(--glass-hover); transform: scale(1.06); }
.m3-cell.selected {
  border-color: #a855f7; background: rgba(168,85,247,.12);
  box-shadow: 0 0 12px var(--glow-purple); transform: scale(1.1);
}

.m3-gameover {
  text-align: center; padding: 24px; border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(168,85,247,.1), rgba(59,130,246,.06));
  border: 1px solid rgba(168,85,247,.12);
  position: relative; overflow: hidden;
}
.m3-gameover::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.m3-gameover h3 {
  font-family: var(--font-display); font-size: 24px;
  color: #fff; font-weight: 900; margin: 0 0 8px;
  letter-spacing: .5px; text-transform: uppercase;
}
.m3-gameover p { font-size: 14px; color: rgba(255,255,255,.4); margin: 0 0 14px; }

/* ══════════════════════════════════════════════
   12. GARAGE
   ══════════════════════════════════════════════ */
.garage-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(175px, 1fr));
  gap: 10px;
}
.garage-card {
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: var(--radius-md); padding: 18px 14px; text-align: center;
  transition: all var(--t-med); position: relative; overflow: hidden;
}
.garage-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.garage-card:hover {
  border-color: rgba(168,85,247,.2); transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(0,0,0,.3);
}
.garage-card.locked { opacity: .65; }

.garage-card-cls {
  position: absolute; top: 8px; left: 8px; padding: 3px 10px;
  border-radius: 6px; font-family: var(--font-display);
  font-size: 10px; font-weight: 900; color: #fff;
  letter-spacing: .5px;
}
.garage-card-icon { font-size: 48px; margin: 10px 0 14px; }
.garage-card-name {
  font-family: var(--font-display); font-size: 14px;
  font-weight: 800; color: #fff; margin-bottom: 12px;
  letter-spacing: .3px;
}
.garage-card-owned {
  font-size: 12px; color: #22c55e; font-weight: 700;
  margin-top: 12px; letter-spacing: .3px;
}

.garage-card-stats { text-align: left; }
.garage-stat { display: flex; align-items: center; gap: 6px; margin-bottom: 5px; }
.garage-stat-label {
  font-family: var(--font-display); font-size: 9px; font-weight: 800;
  color: rgba(255,255,255,.3); width: 28px; letter-spacing: .5px;
}
.garage-stat-bar {
  flex: 1; height: 4px; background: rgba(255,255,255,.05);
  border-radius: 2px; overflow: hidden;
}
.garage-stat-fill { height: 100%; border-radius: 2px; transition: width .4s ease; }

.garage-buy-btn {
  margin-top: 12px; padding: 9px 16px; border-radius: var(--radius-sm);
  border: none; background: linear-gradient(135deg, #a855f7, #7c3aed); color: #fff;
  font-family: var(--font-display); font-size: 12px; font-weight: 800;
  cursor: pointer; transition: all var(--t-fast); width: 100%;
  letter-spacing: .5px; text-transform: uppercase;
  box-shadow: 0 2px 8px var(--glow-purple);
}
.garage-buy-btn:hover { filter: brightness(1.12); }

/* ══════════════════════════════════════════════
   13. RACE HISTORY
   ══════════════════════════════════════════════ */
.rh-card {
  display: flex; align-items: center; gap: 14px;
  padding: 14px; border-radius: var(--radius-md); margin-bottom: 6px;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-fast); position: relative; overflow: hidden;
}
.rh-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.rh-card:hover { background: var(--glass-hover); }
.rh-card.podium { border-color: rgba(255,215,0,.1); }
.rh-pos { text-align: center; flex-shrink: 0; width: 44px; }
.rh-pos-num {
  font-family: var(--font-display); font-size: 11px;
  font-weight: 800; color: rgba(255,255,255,.3);
}
.rh-info { flex: 1; min-width: 0; }
.rh-track { font-size: 14px; font-weight: 700; color: #fff; }
.rh-meta { font-size: 11px; color: rgba(255,255,255,.3); margin-top: 2px; }
.rh-rewards { flex-shrink: 0; text-align: right; }
.rh-reward { font-family: var(--font-display); font-size: 12px; font-weight: 700; color: #ffd700; }

/* ══════════════════════════════════════════════
   14. CHAMPIONSHIPS BRACKET
   ══════════════════════════════════════════════ */
.bracket-preview {
  display: flex; flex-direction: column; gap: 8px; padding: 16px;
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
}
.bracket-match {
  display: flex; align-items: center; gap: 8px; padding: 8px 12px;
  border-radius: var(--radius-sm); background: rgba(0,0,0,.2);
}
.bracket-player {
  flex: 1; font-size: 12px; font-weight: 600; color: rgba(255,255,255,.4);
  padding: 7px 10px; border-radius: 6px; background: var(--glass);
}
.bracket-player.winner { color: #22c55e; border: 1px solid rgba(34,197,94,.15); }
.bracket-player.you { color: #a855f7; border: 1px solid rgba(168,85,247,.2); background: rgba(168,85,247,.05); }
.bracket-vs { font-family: var(--font-display); font-size: 10px; font-weight: 900; color: rgba(255,255,255,.2); }

/* ══════════════════════════════════════════════
   15. NOTIFICATIONS
   ══════════════════════════════════════════════ */
.notif-header-bar {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px; padding-bottom: 12px;
  border-bottom: 1px solid var(--glass-border);
  font-size: 12px; color: rgba(255,255,255,.35);
}
.notif-mark-read {
  background: none; border: 1px solid var(--glass-border); border-radius: var(--radius-sm);
  padding: 6px 14px; color: #a855f7; font-size: 11px; font-weight: 700;
  cursor: pointer; transition: all var(--t-fast); letter-spacing: .3px;
}
.notif-mark-read:hover { background: rgba(168,85,247,.08); }

.notif-card {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px; border-radius: var(--radius-md); margin-bottom: 6px;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-fast); position: relative; overflow: hidden;
}
.notif-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.notif-card:hover { background: var(--glass-hover); }
.notif-card.unread { border-left: 3px solid #a855f7; background: rgba(168,85,247,.03); }
.notif-icon { font-size: 24px; flex-shrink: 0; width: 36px; text-align: center; }
.notif-content { flex: 1; min-width: 0; }
.notif-title { font-size: 13px; font-weight: 700; color: #fff; margin-bottom: 3px; }
.notif-desc { font-size: 12px; color: rgba(255,255,255,.35); line-height: 1.4; }
.notif-time { font-size: 10px; color: rgba(255,255,255,.2); flex-shrink: 0; white-space: nowrap; }

/* ══════════════════════════════════════════════
   16. SETTINGS
   ══════════════════════════════════════════════ */
.set-toggle-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 13px 14px; border-radius: 10px; margin-bottom: 4px;
  background: var(--glass); border: 1px solid var(--glass-border);
}
.set-toggle-info { flex: 1; min-width: 0; }
.set-toggle-label { font-size: 13px; font-weight: 700; color: rgba(255,255,255,.85); }
.set-toggle-desc { font-size: 11px; color: rgba(255,255,255,.3); margin-top: 2px; }

.set-toggle-switch { position: relative; width: 48px; height: 26px; flex-shrink: 0; }
.set-toggle-switch input { opacity: 0; width: 0; height: 0; }
.set-toggle-slider {
  position: absolute; inset: 0; cursor: pointer;
  background: rgba(255,255,255,.08); border-radius: 13px;
  transition: background .25s, box-shadow .25s;
}
.set-toggle-slider::before {
  content: ''; position: absolute; width: 20px; height: 20px;
  left: 3px; bottom: 3px; border-radius: 50%;
  background: rgba(255,255,255,.7); transition: transform .25s;
  box-shadow: 0 1px 3px rgba(0,0,0,.3);
}
.set-toggle-switch input:checked + .set-toggle-slider {
  background: linear-gradient(135deg, #a855f7, #7c3aed);
  box-shadow: 0 0 10px var(--glow-purple);
}
.set-toggle-switch input:checked + .set-toggle-slider::before {
  transform: translateX(22px); background: #fff;
}

.set-links { display: flex; flex-direction: column; gap: 0; }
.set-links a {
  display: block; padding: 11px 14px; font-size: 13px; color: #a855f7;
  text-decoration: none; border-radius: var(--radius-sm);
  transition: background var(--t-fast); font-weight: 600;
}
.set-links a:hover { background: rgba(168,85,247,.06); }

.set-signout-btn {
  display: block; width: 100%; padding: 13px; margin-top: 20px;
  border-radius: 10px; border: 1px solid rgba(239,68,68,.15);
  background: rgba(239,68,68,.04); color: #ef4444;
  font-size: 13px; font-weight: 700; cursor: pointer;
  transition: all var(--t-fast); letter-spacing: .3px;
}
.set-signout-btn:hover { background: rgba(239,68,68,.1); }

/* ══════════════════════════════════════════════
   TOAST NOTIFICATIONS
   ══════════════════════════════════════════════ */
.toast-container {
  position: fixed; top: 16px; right: 16px; z-index: 999;
  display: flex; flex-direction: column; gap: 8px; pointer-events: none;
}
.toast {
  padding: 13px 22px; border-radius: 12px;
  background: rgba(12,12,20,.95); backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border); box-shadow: 0 8px 32px rgba(0,0,0,.4);
  color: #fff; font-size: 13px; font-weight: 600;
  pointer-events: auto; animation: toastIn .35s cubic-bezier(.16,1,.3,1) forwards;
  max-width: 320px; letter-spacing: .2px;
}
.toast.success { border-color: rgba(34,197,94,.25); }
.toast.error { border-color: rgba(239,68,68,.25); }
.toast.info { border-color: rgba(59,130,246,.25); }
@keyframes toastIn {
  from { opacity: 0; transform: translateX(24px) scale(.95); }
  to   { opacity: 1; transform: none; }
}
@keyframes toastOut {
  from { opacity: 1; transform: none; }
  to   { opacity: 0; transform: translateX(24px) scale(.95); }
}

/* ══════════════════════════════════════════════
   REWARD ANIMATION
   ══════════════════════════════════════════════ */
.reward-overlay {
  position: fixed; inset: 0; z-index: 500;
  background: rgba(0,0,0,.85); display: flex;
  align-items: center; justify-content: center;
  animation: fadeIn .3s ease; flex-direction: column; cursor: pointer;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.reward-burst { text-align: center; animation: rewardPop .5s cubic-bezier(.34,1.56,.64,1); }
.reward-icon { font-size: 72px; margin-bottom: 14px; filter: drop-shadow(0 0 24px rgba(255,215,0,.4)); }
.reward-amount {
  font-family: var(--font-display); font-size: 40px;
  font-weight: 900; color: #ffd700;
  text-shadow: 0 0 32px var(--glow-gold); letter-spacing: 1px;
}
.reward-label {
  font-size: 14px; color: rgba(255,255,255,.4); margin-top: 10px;
  letter-spacing: .5px;
}
@keyframes rewardPop {
  from { opacity: 0; transform: scale(.4) rotate(-5deg); }
  60%  { transform: scale(1.08) rotate(1deg); }
  to   { opacity: 1; transform: scale(1) rotate(0); }
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ══════════════════════════════════════════════
   VIP SYSTEM
   ══════════════════════════════════════════════ */
.vip-header {
  padding: 24px; border-radius: var(--radius-lg); margin-bottom: 20px;
  text-align: center; position: relative; overflow: hidden;
  background: linear-gradient(135deg, rgba(255,215,0,.08), rgba(168,85,247,.06));
  border: 1px solid rgba(255,215,0,.12);
}
.vip-header::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.vip-header-tier {
  font-family: var(--font-display); font-size: 14px;
  color: #ffd700; font-weight: 700; margin-bottom: 4px;
  letter-spacing: 1px; text-transform: uppercase;
}
.vip-header-name {
  font-family: var(--font-display); font-size: 28px;
  color: #fff; font-weight: 900; margin-bottom: 6px;
  letter-spacing: .5px;
}
.vip-header-desc { font-size: 12px; color: rgba(255,255,255,.35); margin-bottom: 16px; }

.vip-progress-wrap { margin-bottom: 8px; }
.vip-progress-bar {
  height: 10px; background: rgba(255,255,255,.06);
  border-radius: 5px; overflow: hidden;
}
.vip-progress-fill {
  height: 100%; border-radius: 5px;
  background: linear-gradient(90deg, #ffd700, #f59e0b);
  transition: width .6s cubic-bezier(.16,1,.3,1);
  position: relative;
}
.vip-progress-fill::after {
  content: ''; position: absolute; right: -1px; top: -2px; bottom: -2px; width: 6px;
  border-radius: 0 5px 5px 0; background: rgba(255,255,255,.5);
  box-shadow: 0 0 8px #ffd700;
}
.vip-progress-text { font-size: 11px; color: rgba(255,255,255,.3); margin-top: 4px; }

.vip-perks-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px; margin-bottom: 20px;
}
.vip-perk {
  padding: 14px 12px; border-radius: var(--radius-md); text-align: center;
  background: var(--glass); border: 1px solid var(--glass-border);
  position: relative; overflow: hidden;
}
.vip-perk::before {
  content: ''; position: absolute; inset: 0;
  background: var(--chrome-shine); pointer-events: none;
}
.vip-perk.active { border-color: rgba(255,215,0,.15); }
.vip-perk.locked { opacity: .35; }
.vip-perk-icon { font-size: 24px; margin-bottom: 6px; }
.vip-perk-name { font-size: 11px; font-weight: 700; color: rgba(255,255,255,.7); }
.vip-perk-val {
  font-family: var(--font-display); font-size: 10px;
  color: #ffd700; font-weight: 700; margin-top: 3px;
}

.vip-tiers-list { display: flex; flex-direction: column; gap: 6px; }
.vip-tier-row {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 10px;
  background: var(--glass); border: 1px solid var(--glass-border);
  transition: all var(--t-fast);
}
.vip-tier-row.current {
  border-color: rgba(255,215,0,.2);
  background: rgba(255,215,0,.03);
  box-shadow: 0 0 12px rgba(255,215,0,.06);
}
.vip-tier-row.locked { opacity: .4; }
.vip-tier-num {
  font-family: var(--font-display); font-size: 18px;
  font-weight: 900; color: #ffd700; min-width: 36px; text-align: center;
}
.vip-tier-info { flex: 1; }
.vip-tier-name { font-size: 13px; font-weight: 700; color: #fff; }
.vip-tier-req { font-size: 11px; color: rgba(255,255,255,.3); margin-top: 2px; }

/* ══════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════ */
@media (max-width: 768px) {
  .dr-calendar { gap: 4px; }
  .dr-day { padding: 8px 3px; min-height: 64px; }
  .dr-day-icon { font-size: 16px; }
  .dr-bonus-row { flex-direction: column; }
  .shop-grid { grid-template-columns: repeat(2, 1fr); }
  .lb-podium-item { flex: 0 0 85px; }
  .prof-stats { grid-template-columns: repeat(2, 1fr); }
  .ach-grid { grid-template-columns: repeat(2, 1fr); }
  .s-summary { flex-wrap: wrap; }
  .s-summary-item { flex: 0 0 calc(50% - 5px); }
  .sp-header-banner { padding: 16px; }
  .garage-grid { grid-template-columns: repeat(2, 1fr); }
  .m3-cell { font-size: 20px; }
  .m3-board { max-width: 300px; }
  .whl-wheel-wrap { width: 240px; height: 240px; }
  .ev-card { padding: 16px; }
  .vip-perks-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .screen-body { padding: 14px; }
  .screen-header { padding: 12px 14px; }
  .screen-header h2 { font-size: 16px; }
  .shop-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .shop-vip-banner { flex-direction: column; text-align: center; }
  .shop-vip-btn { margin-left: 0; width: 100%; }
  .garage-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .m3-board { max-width: 280px; gap: 2px; }
  .m3-cell { font-size: 18px; }
  .m3-hud { gap: 6px; }
  .m3-hud-item { padding: 8px 14px; }
  .whl-wheel-wrap { width: 200px; height: 200px; }
  .fr-card { padding: 10px; }
  .s-summary-num { font-size: 20px; }
  .sp-header-banner h3 { font-size: 18px; }
  .prof-avatar-ring { width: 72px; height: 72px; }
  .prof-name { font-size: 18px; }
  .vip-header-name { font-size: 22px; }
}

/* ── STAGGER ANIMATION ── */
.screen-overlay.show .screen-body > *:nth-child(1) { animation: staggerIn .4s .05s both; }
.screen-overlay.show .screen-body > *:nth-child(2) { animation: staggerIn .4s .1s both; }
.screen-overlay.show .screen-body > *:nth-child(3) { animation: staggerIn .4s .15s both; }
.screen-overlay.show .screen-body > *:nth-child(4) { animation: staggerIn .4s .2s both; }
.screen-overlay.show .screen-body > *:nth-child(5) { animation: staggerIn .4s .25s both; }
.screen-overlay.show .screen-body > *:nth-child(6) { animation: staggerIn .4s .3s both; }
.screen-overlay.show .screen-body > *:nth-child(n+7) { animation: staggerIn .4s .35s both; }
@keyframes staggerIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

/* ═══════════════════════════════════════════════════════════════
   MOBILE-FIRST CRITICAL FIXES — Safe Area, Touch, Motion, PWA
   ═══════════════════════════════════════════════════════════════ */

/* ── Safe Area (notch / home indicator) ── */
.screen-overlay .screen-header { padding-top: max(12px, env(safe-area-inset-top)); }
.screen-overlay .screen-body { padding-bottom: max(16px, env(safe-area-inset-bottom)); }
body { padding-bottom: env(safe-area-inset-bottom); }

/* ── Touch Targets — 44px minimum per Apple HIG ── */
.screen-overlay button,
.screen-overlay [role="button"],
.screen-overlay .btn,
.screen-overlay .tab-pill,
.screen-overlay input[type="submit"] { min-height: 44px; min-width: 44px; }

/* ── Reduced Motion — accessibility ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ── Hover only on devices with hover ── */
@media (hover: none) {
  .screen-overlay button:hover,
  .glass-card:hover,
  .tab-pill:hover { background: initial; }
}

/* ── Performance ── */
.screen-overlay { will-change: opacity, transform; }
.screen-overlay.show { will-change: auto; }

/* ── Color scheme ── */
:root { color-scheme: dark; }

/* ── Gacha Module ── */
.rrm-gacha-backdrop { position:fixed; inset:0; z-index:500; background:rgba(0,0,0,.7); backdrop-filter:blur(8px); display:flex; align-items:center; justify-content:center; animation:rrmFadeIn .3s ease; }
.rrm-gacha-panel { background:rgba(18,18,26,.97); border:1px solid rgba(168,85,247,.25); border-radius:20px; max-width:420px; width:92%; max-height:85vh; overflow-y:auto; padding:0; box-shadow:0 16px 48px rgba(0,0,0,.6); animation:rrmPopIn .4s cubic-bezier(.34,1.56,.64,1); }
.rrm-crate-card { background:rgba(255,255,255,.03); border:1px solid rgba(255,255,255,.08); border-radius:14px; padding:16px; text-align:center; cursor:pointer; transition:all .2s; min-width:140px; flex-shrink:0; }
.rrm-crate-card:hover { border-color:rgba(168,85,247,.4); transform:translateY(-2px); }
.rrm-rarity-common { color:#9ca3af; border-color:#9ca3af; }
.rrm-rarity-uncommon { color:#22c55e; border-color:#22c55e; }
.rrm-rarity-rare { color:#3b82f6; border-color:#3b82f6; }
.rrm-rarity-epic { color:#a855f7; border-color:#a855f7; }
.rrm-rarity-legendary { color:#f59e0b; border-color:#f59e0b; }
.rrm-rarity-mythic { color:#ef4444; border-color:#ef4444; }

/* ── Collection Book Grid ── */
.rrm-collection-grid { display:grid; grid-template-columns:repeat(6,1fr); gap:8px; padding:12px; }
@media(min-width:768px) { .rrm-collection-grid { grid-template-columns:repeat(8,1fr); } }
.rrm-char-card { position:relative; border-radius:12px; overflow:hidden; aspect-ratio:1; background:rgba(255,255,255,.03); border:1px solid rgba(255,255,255,.08); cursor:pointer; transition:all .2s; }
.rrm-char-card:hover { border-color:rgba(168,85,247,.4); transform:scale(1.05); }
.rrm-char-card.locked { filter:brightness(.3) saturate(0); }
.rrm-char-card.locked::after { content:'?'; position:absolute; inset:0; display:flex; align-items:center; justify-content:center; font-size:24px; font-weight:900; color:rgba(255,255,255,.3); }
.rrm-char-card img { width:100%; height:100%; object-fit:cover; }

/* ── Retention Module ── */
.rrm-streak-banner { position:fixed; top:0; left:0; right:0; z-index:450; padding:10px 16px; background:linear-gradient(135deg,rgba(239,68,68,.9),rgba(168,85,247,.9)); text-align:center; font-family:var(--font-display); font-weight:800; color:#fff; font-size:14px; animation:rrmSlideDown .3s ease; }
.rrm-social-ticker { position:fixed; bottom:60px; left:16px; z-index:300; background:rgba(18,18,26,.9); border:1px solid rgba(255,255,255,.08); border-radius:12px; padding:8px 14px; font-size:12px; color:rgba(255,255,255,.7); animation:rrmSlideUp .3s ease; max-width:280px; }

/* ── Monetization Module ── */
.rrm-first-purchase { position:fixed; bottom:80px; right:16px; z-index:350; background:rgba(18,18,26,.95); border:1px solid rgba(255,215,0,.3); border-radius:16px; padding:14px 18px; max-width:260px; animation:rrmSlideUp .4s cubic-bezier(.34,1.56,.64,1); }
.rrm-value-badge { position:absolute; top:-8px; right:-8px; padding:4px 10px; border-radius:8px; font-size:10px; font-weight:800; letter-spacing:.5px; text-transform:uppercase; }
.rrm-value-badge.best { background:#f59e0b; color:#000; }
.rrm-value-badge.popular { background:#a855f7; color:#fff; }
.rrm-value-badge.bonus { background:#22c55e; color:#000; }

/* ── Splash Module ── */
.rrm-splash { position:fixed; inset:0; z-index:9999; background:#0a0a0f; display:flex; flex-direction:column; align-items:center; justify-content:center; }
.rrm-splash-logo { width:120px; height:120px; border-radius:28px; animation:splashPulse 2s ease infinite; }
@keyframes splashPulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.05)} }
.rrm-splash-bar { width:200px; height:4px; border-radius:2px; background:rgba(255,255,255,.1); overflow:hidden; margin-top:24px; }
.rrm-splash-fill { height:100%; background:linear-gradient(90deg,#a855f7,#ffd700); border-radius:2px; transition:width .3s ease; }

/* ── Mascot ── */
.rrm-mascot-wrap { position:fixed; bottom:16px; right:16px; z-index:400; pointer-events:auto; }
.rrm-mascot-bubble { position:absolute; bottom:calc(100% + 8px); right:0; background:rgba(18,18,26,.95); border:1px solid rgba(168,85,247,.25); border-radius:14px; padding:12px 16px; max-width:240px; font-size:13px; color:rgba(255,255,255,.85); line-height:1.5; box-shadow:0 8px 24px rgba(0,0,0,.4); animation:rrmPopIn .3s cubic-bezier(.34,1.56,.64,1); }
.rrm-mascot-bubble::after { content:''; position:absolute; bottom:-6px; right:20px; width:12px; height:12px; background:rgba(18,18,26,.95); border-right:1px solid rgba(168,85,247,.25); border-bottom:1px solid rgba(168,85,247,.25); transform:rotate(45deg); }

/* ── Social Module ── */
.rrm-social-panel { background:rgba(18,18,26,.97); border:1px solid rgba(168,85,247,.25); border-radius:20px; max-width:400px; width:92%; max-height:80vh; overflow:hidden; display:flex; flex-direction:column; }
.rrm-social-tabs { display:flex; border-bottom:1px solid rgba(255,255,255,.08); overflow-x:auto; }
.rrm-social-tab { flex:1; padding:12px 8px; text-align:center; font-family:var(--font-display); font-weight:700; font-size:13px; color:rgba(255,255,255,.4); cursor:pointer; border-bottom:2px solid transparent; transition:all .2s; min-height:44px; min-width:44px; white-space:nowrap; }
.rrm-social-tab.active { color:#ffd700; border-bottom-color:#ffd700; }
.rrm-friend-row { display:flex; align-items:center; gap:12px; padding:10px 14px; border-bottom:1px solid rgba(255,255,255,.04); }
.rrm-friend-avatar { width:40px; height:40px; border-radius:50%; background:linear-gradient(135deg,#a855f7,#6b2fc7); display:flex; align-items:center; justify-content:center; font-weight:800; color:#fff; font-size:16px; flex-shrink:0; }
.rrm-online-dot { width:10px; height:10px; border-radius:50%; border:2px solid #0a0a0f; position:absolute; bottom:0; right:0; }
.rrm-online-dot.online { background:#22c55e; }
.rrm-online-dot.offline { background:#6b7280; }

/* ── Shared Keyframes (used by multiple modules) ── */
@keyframes rrmFadeIn { from{opacity:0} to{opacity:1} }
@keyframes rrmPopIn { from{transform:scale(.85);opacity:0} to{transform:scale(1);opacity:1} }
@keyframes rrmSlideUp { from{transform:translateY(100px);opacity:0} to{transform:translateY(0);opacity:1} }
@keyframes rrmSlideDown { from{transform:translateY(-60px);opacity:0} to{transform:translateY(0);opacity:1} }
@keyframes rrmShimmer { 0%{background-position:-200px 0} 100%{background-position:200px 0} }
.rrm-skeleton { background:linear-gradient(90deg,rgba(255,255,255,.03) 25%,rgba(255,255,255,.06) 50%,rgba(255,255,255,.03) 75%); background-size:400px 100%; animation:rrmShimmer 1.5s infinite; border-radius:8px; }
