:root {
  --background: 266 45% 96%;
  --foreground: 258 42% 10%;
  --primary: 174 100% 43%;
  --primary-foreground: 258 45% 8%;
  --secondary: 319 100% 57%;
  --secondary-foreground: 0 0% 100%;
  --muted: 257 22% 88%;
  --muted-foreground: 258 18% 38%;
  --destructive: 8 95% 58%;
  --destructive-foreground: 0 0% 100%;
  --border: 258 28% 78%;
  --card: 0 0% 100%;
  --shadow-sm: 0 8px 20px rgba(10, 6, 30, 0.14);
  --shadow-md: 0 18px 45px rgba(10, 6, 30, 0.22);
  --shadow-lg: 0 28px 80px rgba(10, 6, 30, 0.35);
  --transition-fast: 160ms ease;
  --transition-smooth: 280ms cubic-bezier(.2,.8,.2,1);
  --radius-sm: 12px;
  --radius-md: 20px;
  --radius-lg: 30px;
}

.dark {
  --background: 258 48% 5%;
  --foreground: 186 100% 92%;
  --primary: 176 100% 48%;
  --primary-foreground: 254 48% 7%;
  --secondary: 321 100% 61%;
  --secondary-foreground: 0 0% 100%;
  --muted: 258 28% 16%;
  --muted-foreground: 190 34% 72%;
  --destructive: 13 100% 61%;
  --destructive-foreground: 0 0% 100%;
  --border: 263 28% 25%;
  --card: 260 42% 9%;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow-x: hidden;
}
button, a, input, select { -webkit-tap-highlight-color: transparent; }
input, select, textarea { font-size: max(16px, 1rem); }

.arcade-bg {
  background:
    radial-gradient(circle at 18% 8%, hsl(var(--secondary) / 0.34), transparent 28%),
    radial-gradient(circle at 86% 20%, hsl(var(--primary) / 0.28), transparent 30%),
    linear-gradient(180deg, hsl(258 56% 7%), hsl(268 42% 4%) 58%, hsl(18 70% 10%));
}

.scanlines::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(255,255,255,0.045), rgba(255,255,255,0.045) 1px, transparent 1px, transparent 5px);
  mix-blend-mode: overlay;
  opacity: .42;
}

.neon-card {
  background: linear-gradient(145deg, hsl(var(--card) / 0.9), hsl(var(--muted) / 0.38));
  border: 1px solid hsl(var(--border));
  box-shadow: var(--shadow-md), inset 0 0 35px hsl(var(--primary) / 0.05);
  backdrop-filter: blur(18px);
}

.neon-text {
  text-shadow: 0 0 18px hsl(var(--primary) / 0.75), 0 0 34px hsl(var(--secondary) / 0.35);
}

.game-lane {
  transform: perspective(700px) rotateX(58deg);
  transform-origin: bottom center;
}

.runner-bob { animation: runnerBob 720ms ease-in-out infinite alternate; }
.coin-spin { animation: coinSpin 980ms linear infinite; }
.floaty { animation: floaty 3s ease-in-out infinite; }
.pulse-glow { animation: pulseGlow 1.8s ease-in-out infinite; }

@keyframes runnerBob { from { transform: translateY(0) scale(1); } to { transform: translateY(-8px) scale(1.03); } }
@keyframes coinSpin { from { transform: rotateY(0deg); } to { transform: rotateY(360deg); } }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes pulseGlow { 0%, 100% { box-shadow: 0 0 18px hsl(var(--primary) / .35); } 50% { box-shadow: 0 0 38px hsl(var(--secondary) / .55); } }

.safe-bottom { padding-bottom: calc(84px + env(safe-area-inset-bottom)); }
.bottom-nav { padding-bottom: env(safe-area-inset-bottom); }
