/* ==========================================================================
   DESIGN TOKENS
   Dark theme: premium cyberpunk reactor command center (default).
   Light theme: bright solar-energy research laboratory — a deliberate
   redesign, not an inversion of the dark palette.
   ========================================================================== */

:root {
  /* Typography */
  --font-display: 'Orbitron', system-ui, sans-serif;
  --font-body: 'Rajdhani', system-ui, sans-serif;

  /* Shape + spacing */
  --radius-lg: 1.25rem;
  --radius-md: 0.9rem;
  --radius-sm: 0.6rem;
  --gap: 1rem;

  /* Z-layers */
  --z-nav: 60;
  --z-toast: 80;
  --z-overlay: 100;

  /* ----- Dark: reactor command center ----- */
  --bg: #050812;
  --bg-2: #0b1020;
  --surface: rgba(15, 22, 38, 0.78);
  --surface-hi: rgba(27, 38, 62, 0.94);
  --surface-soft: rgba(255, 255, 255, 0.05);
  --border: rgba(0, 240, 255, 0.14);
  --border-strong: rgba(0, 240, 255, 0.5);
  --text: #eaf6ff;
  --text-dim: #a3b4c9;
  --text-faded: #74879f;

  --accent: #00f0ff;
  --accent-contrast: #032029;
  --accent-2: #ff2d95;
  --accent-3: #ffd60a;
  --horizon: #b06bff;
  --good: #6dffb8;
  --danger: #ff4565;
  --glow-violet: 0 0 18px rgba(176, 107, 255, 0.45), 0 0 44px rgba(176, 107, 255, 0.2);

  --shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  --shadow-soft: 0 8px 26px rgba(0, 0, 0, 0.3);
  --glow: 0 0 16px rgba(0, 240, 255, 0.5), 0 0 44px rgba(0, 240, 255, 0.24);
  --glow-pink: 0 0 18px rgba(255, 45, 149, 0.45), 0 0 44px rgba(255, 45, 149, 0.2);
  --glow-gold: 0 0 16px rgba(255, 214, 10, 0.5), 0 0 36px rgba(255, 214, 10, 0.22);

  /* Reactor core lighting */
  --core-hot: #ffffff;
  --core-color: var(--accent);
  --core-dim: rgba(0, 240, 255, 0.12);
  --core-shell: rgba(0, 0, 0, 0.45);
  --core-glow-inner: rgba(255, 255, 255, 0.32);

  /* Background scene */
  --scene-bg:
    radial-gradient(circle at 14% 18%, rgba(0, 240, 255, 0.1), transparent 30rem),
    radial-gradient(circle at 86% 70%, rgba(255, 45, 149, 0.09), transparent 28rem),
    linear-gradient(150deg, var(--bg), var(--bg-2));
  --scene-grid-line: rgba(0, 240, 255, 0.12);
  --scene-grid-size: 56px;
  --scene-grid-opacity: 0.55;
  --scene-texture: repeating-linear-gradient(0deg, transparent 0 7px, rgba(255, 255, 255, 0.018) 8px 9px);
  --scene-texture-opacity: 0.75;
  --scene-glow:
    radial-gradient(circle at 12% 22%, rgba(0, 240, 255, 0.13), transparent 24rem),
    radial-gradient(circle at 85% 72%, rgba(255, 45, 149, 0.12), transparent 26rem),
    radial-gradient(circle at 50% 8%, rgba(255, 214, 10, 0.05), transparent 20rem);

  color-scheme: dark;
}

/* ----- Light: solar research laboratory ----- */
[data-theme="light"] {
  --bg: #f7f3e9;
  --bg-2: #ece5d3;
  --surface: rgba(255, 255, 255, 0.82);
  --surface-hi: rgba(255, 255, 255, 0.97);
  --surface-soft: rgba(34, 56, 74, 0.05);
  --border: rgba(34, 64, 84, 0.22);
  --border-strong: rgba(2, 119, 163, 0.55);
  --text: #1a2733;
  --text-dim: #445666;
  --text-faded: #647482;

  --accent: #026e96;
  --accent-contrast: #ffffff;
  --accent-2: #a82367;
  --accent-3: #7d6000;
  --horizon: #6a35c8;
  --good: #0a7a4d;
  --danger: #b82a47;
  --glow-violet: 0 0 14px rgba(106, 53, 200, 0.22);

  --shadow: 0 18px 44px rgba(96, 84, 60, 0.16);
  --shadow-soft: 0 6px 20px rgba(96, 84, 60, 0.12);
  --glow: 0 0 14px rgba(2, 119, 163, 0.2);
  --glow-pink: 0 0 14px rgba(179, 38, 111, 0.18);
  --glow-gold: 0 0 14px rgba(178, 141, 16, 0.28);

  /* The light-theme core reads as a captured sun: hot white center, deep
     cyan plasma rim, restrained bloom so it never washes out. */
  --core-hot: #fffdf4;
  --core-color: #00a8cc;
  --core-dim: rgba(0, 168, 204, 0.14);
  --core-shell: rgba(8, 56, 76, 0.34);
  --core-glow-inner: rgba(255, 255, 255, 0.6);

  /* Warm sunlit lab: soft gold wash from above, faint cyan from below,
     fine blueprint grid on warm paper. */
  --scene-bg:
    radial-gradient(ellipse at 50% -10%, rgba(255, 200, 87, 0.22), transparent 34rem),
    radial-gradient(circle at 88% 86%, rgba(2, 119, 163, 0.08), transparent 26rem),
    linear-gradient(165deg, var(--bg), var(--bg-2));
  --scene-grid-line: rgba(34, 64, 84, 0.1);
  --scene-grid-size: 44px;
  --scene-grid-opacity: 0.5;
  --scene-texture: repeating-linear-gradient(90deg, transparent 0 86px, rgba(34, 64, 84, 0.035) 87px 88px);
  --scene-texture-opacity: 0.6;
  --scene-glow:
    radial-gradient(circle at 18% 14%, rgba(255, 214, 10, 0.1), transparent 22rem),
    radial-gradient(circle at 82% 78%, rgba(2, 119, 163, 0.07), transparent 24rem);

  color-scheme: light;
}
