:root {
  --font-sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --background: 220 24% 7%;
  --foreground: 210 40% 96%;
  --card: 220 22% 10%;
  --card-foreground: 210 40% 96%;
  --popover: 220 24% 9%;
  --popover-foreground: 210 40% 96%;
  --primary: 190 95% 58%;
  --primary-foreground: 220 24% 7%;
  --secondary: 262 70% 62%;
  --secondary-foreground: 210 40% 98%;
  --muted: 220 18% 16%;
  --muted-foreground: 217 16% 74%;
  --accent: 160 84% 45%;
  --accent-foreground: 220 24% 7%;
  --destructive: 0 72% 58%;
  --destructive-foreground: 210 40% 98%;
  --success: 152 68% 45%;
  --success-foreground: 220 24% 7%;
  --warning: 38 92% 56%;
  --warning-foreground: 220 24% 7%;
  --info: 205 90% 58%;
  --info-foreground: 220 24% 7%;
  --border: 218 18% 22%;
  --input: 218 18% 22%;
  --ring: 190 95% 58%;
  --radius: 0.625rem;
  --shadow-sm: 0 1px 2px hsl(var(--foreground)/0.05);
  --shadow-md: 0 4px 12px hsl(var(--foreground)/0.08);
  --shadow-lg: 0 12px 32px hsl(var(--foreground)/0.12);
  --shadow-elegant: 0 24px 80px hsl(var(--primary)/0.18), 0 0 0 1px hsl(var(--primary)/0.18);
  --transition-fast: 150ms cubic-bezier(0.4,0,0.2,1);
  --transition: 200ms cubic-bezier(0.4,0,0.2,1);
  --transition-smooth: 300ms cubic-bezier(0.4,0,0.2,1);
}

html:not(.dark) {
  --background: 210 40% 98%;
  --foreground: 222 47% 11%;
  --card: 0 0% 100%;
  --card-foreground: 222 47% 11%;
  --popover: 0 0% 100%;
  --popover-foreground: 222 47% 11%;
  --primary: 194 88% 38%;
  --primary-foreground: 210 40% 98%;
  --secondary: 262 62% 48%;
  --secondary-foreground: 210 40% 98%;
  --muted: 214 32% 91%;
  --muted-foreground: 215 16% 35%;
  --accent: 158 64% 38%;
  --accent-foreground: 210 40% 98%;
  --destructive: 0 72% 45%;
  --destructive-foreground: 210 40% 98%;
  --success: 152 66% 32%;
  --success-foreground: 210 40% 98%;
  --warning: 38 86% 42%;
  --warning-foreground: 222 47% 11%;
  --info: 205 84% 42%;
  --info-foreground: 210 40% 98%;
  --border: 214 32% 84%;
  --input: 214 32% 84%;
  --ring: 194 88% 38%;
}

* { box-sizing: border-box; }
html { min-height: 100%; font-family: var(--font-sans); background: hsl(var(--background)); color: hsl(var(--foreground)); }
body { min-height: 100vh; margin: 0; background: radial-gradient(circle at top left, hsl(var(--primary)/0.16), transparent 34rem), radial-gradient(circle at top right, hsl(var(--secondary)/0.14), transparent 30rem), hsl(var(--background)); color: hsl(var(--foreground)); }
button, input, textarea, select { font: inherit; }
input, textarea, select { font-size: max(16px, 1rem); }
::selection { background: hsl(var(--primary)/0.24); }

.metal-panel { background: linear-gradient(145deg, hsl(var(--card)/0.96), hsl(var(--muted)/0.7)); border: 1px solid hsl(var(--border)); box-shadow: var(--shadow-sm); }
.scanline { position: relative; overflow: hidden; }
.scanline::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to bottom, transparent, hsl(var(--primary)/0.08), transparent); transform: translateY(-100%); animation: scan 5s ease-in-out infinite; }
@keyframes scan { 0%, 72% { transform: translateY(-100%); } 100% { transform: translateY(100%); } }
.safe-bottom { padding-bottom: calc(5rem + env(safe-area-inset-bottom)); }
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { scrollbar-width: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
}