/**
 * Aquila brand tokens (mirror of brand/tokens.css) - night sky, dark default.
 * Kept in-tree so the manager image builds standalone (build context is manager/).
 * Dark is the default; the light variant is an opt-in via the topbar toggle.
 * `--*-line` tokens extend the brand mirror for app chrome borders.
 */
:root {
  color-scheme: dark;

  --bg: #050a18;
  --surface: #0b1226;
  --surface-2: #111a33;
  --surface-3: #16203d;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.14);
  --overlay: rgba(5, 10, 24, 0.84);

  --text: #f2f5ff;
  --text-muted: #b9c3dd;
  --text-faint: #8b96b6;

  --accent: #f5b942;
  --accent-strong: #ffd166;
  --accent-soft: rgba(245, 185, 66, 0.12);
  --accent-line: rgba(245, 185, 66, 0.38);
  --accent-2: #7c9cff;
  --accent-2-soft: rgba(124, 156, 255, 0.14);
  --accent-2-line: rgba(124, 156, 255, 0.3);
  --btn-ink: #0b1226;
  --star: #ffffff;

  --success: #4ade80;
  --success-soft: rgba(74, 222, 128, 0.12);
  --success-line: rgba(74, 222, 128, 0.35);
  --warning: #fbbf24;
  --warning-line: rgba(251, 191, 36, 0.35);
  --danger: #f87171;
  --danger-soft: rgba(248, 113, 113, 0.12);
  --danger-line: rgba(248, 113, 113, 0.4);

  --focus-ring: 0 0 0 3px rgba(245, 185, 66, 0.34);
  --shadow-card: 0 22px 54px rgba(2, 5, 14, 0.5);
  --shadow-pop: 0 26px 70px rgba(2, 5, 14, 0.62);

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 0.18s;
  --dur: 0.3s;
  --dur-slow: 0.7s;

  --font-display: "Montserrat", system-ui, sans-serif;
  --font-body: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, monospace;

  --space-1: 4px;  --space-2: 8px;  --space-3: 12px; --space-4: 16px;
  --space-5: 24px; --space-6: 32px; --space-7: 48px; --space-8: 64px;
  --radius-sm: 8px; --radius-md: 12px; --radius-lg: 20px; --radius-full: 999px;

  --sky: radial-gradient(1200px 600px at 70% -10%, rgba(72, 96, 190, 0.25), transparent 60%),
         radial-gradient(900px 500px at 8% 110%, rgba(245, 185, 66, 0.08), transparent 60%);
  --gold-line: linear-gradient(90deg, transparent, var(--accent), transparent);
}

html[data-theme="light"] {
  color-scheme: light;

  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-2: #eef1f9;
  --surface-3: #e4e9f5;
  --line: rgba(11, 18, 38, 0.10);
  --line-strong: rgba(11, 18, 38, 0.18);
  --overlay: rgba(246, 247, 251, 0.86);

  --text: #0b1226;
  --text-muted: #3d4763;
  --text-faint: #5b6580;

  --accent: #8a6008;
  --accent-strong: #6d4c06;
  --accent-soft: rgba(138, 96, 8, 0.12);
  --accent-line: rgba(138, 96, 8, 0.35);
  --accent-2: #3b5bdb;
  --accent-2-soft: rgba(59, 91, 219, 0.12);
  --accent-2-line: rgba(59, 91, 219, 0.3);
  --btn-ink: #ffffff;
  --star: #0b1226;

  --success: #15803d;
  --success-soft: rgba(21, 128, 61, 0.10);
  --success-line: rgba(21, 128, 61, 0.4);
  --warning: #a16207;
  --warning-line: rgba(161, 98, 7, 0.4);
  --danger: #b91c1c;
  --danger-soft: rgba(185, 28, 28, 0.10);
  --danger-line: rgba(185, 28, 28, 0.4);

  --focus-ring: 0 0 0 3px rgba(138, 96, 8, 0.30);
  --shadow-card: 0 22px 54px rgba(20, 28, 55, 0.14);
  --shadow-pop: 0 26px 70px rgba(20, 28, 55, 0.18);

  --sky: radial-gradient(1200px 600px at 70% -10%, rgba(72, 96, 190, 0.12), transparent 60%),
         radial-gradient(900px 500px at 8% 110%, rgba(245, 185, 66, 0.10), transparent 60%);
}

@media (prefers-color-scheme: light) {
  html:not([data-theme="dark"]):not([data-theme="light"]) {
    color-scheme: light;

    --bg: #f6f7fb;
    --surface: #ffffff;
    --surface-2: #eef1f9;
    --surface-3: #e4e9f5;
    --line: rgba(11, 18, 38, 0.10);
    --line-strong: rgba(11, 18, 38, 0.18);
    --overlay: rgba(246, 247, 251, 0.86);

    --text: #0b1226;
    --text-muted: #3d4763;
    --text-faint: #5b6580;

    --accent: #8a6008;
    --accent-strong: #6d4c06;
    --accent-soft: rgba(138, 96, 8, 0.12);
    --accent-line: rgba(138, 96, 8, 0.35);
    --accent-2: #3b5bdb;
    --accent-2-soft: rgba(59, 91, 219, 0.12);
    --accent-2-line: rgba(59, 91, 219, 0.3);
    --btn-ink: #ffffff;
    --star: #0b1226;

    --success: #15803d;
    --success-soft: rgba(21, 128, 61, 0.10);
    --success-line: rgba(21, 128, 61, 0.4);
    --warning: #a16207;
    --warning-line: rgba(161, 98, 7, 0.4);
    --danger: #b91c1c;
    --danger-soft: rgba(185, 28, 28, 0.10);
    --danger-line: rgba(185, 28, 28, 0.4);

    --focus-ring: 0 0 0 3px rgba(138, 96, 8, 0.30);
    --shadow-card: 0 22px 54px rgba(20, 28, 55, 0.14);
    --shadow-pop: 0 26px 70px rgba(20, 28, 55, 0.18);

    --sky: radial-gradient(1200px 600px at 70% -10%, rgba(72, 96, 190, 0.12), transparent 60%),
           radial-gradient(900px 500px at 8% 110%, rgba(245, 185, 66, 0.10), transparent 60%);
  }
}
