/*
 * Switchboard design tokens. Single source of truth for color, type,
 * spacing, radius and motion. Templates and app.css reference these
 * variables only; never hard-code a hex value elsewhere.
 *
 * Dark is the base theme. [data-theme="light"] on <html> switches to the
 * light palette. The head bootstrap script resolves "system" to one of
 * the two before first paint.
 */

@font-face {
	font-family: "Inter";
	font-style: normal;
	font-display: swap;
	font-weight: 100 900;
	src: url("/static/fonts/inter-latin-ext-wght.woff2") format("woff2-variations");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
	font-family: "Inter";
	font-style: normal;
	font-display: swap;
	font-weight: 100 900;
	src: url("/static/fonts/inter-latin-wght.woff2") format("woff2-variations");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
	font-family: "JetBrains Mono";
	font-style: normal;
	font-display: swap;
	font-weight: 100 800;
	src: url("/static/fonts/jetbrains-mono-latin-wght.woff2") format("woff2-variations");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
	color-scheme: dark;

	--bg: #0B0D10;
	--surface: #12151A;
	--surface-2: #161A20;
	--elevated: #181C22;
	--hover: #1C2129;
	--border: #232830;
	--border-strong: #2E343D;

	--text: #E6E9EE;
	--text-strong: #F5F7FA;
	--text-muted: #8A93A0;
	--text-faint: #5C6470;

	--accent: #22D3EE;
	--accent-hover: #67E8F9;
	--accent-press: #06B6D4;
	--accent-text: #22D3EE;
	--on-accent: #04222A;
	--accent-tint: rgb(34 211 238 / 0.10);
	--accent-border: rgb(34 211 238 / 0.35);

	--success: #34D399;
	--success-tint: rgb(52 211 153 / 0.12);
	--success-border: rgb(52 211 153 / 0.30);
	--warning: #FBBF24;
	--warning-tint: rgb(251 191 36 / 0.12);
	--warning-border: rgb(251 191 36 / 0.30);
	--danger: #F87171;
	--danger-tint: rgb(248 113 113 / 0.12);
	--danger-border: rgb(248 113 113 / 0.30);

	--code-bg: #161A20;
	--code-text: #C3C9D2;

	--shadow-card: none;
	--shadow-pop: 0 8px 24px -4px rgb(0 0 0 / 0.6);
	--shadow-modal: 0 20px 40px -8px rgb(0 0 0 / 0.85);
	--backdrop: rgb(5 7 10 / 0.6);
	--focus-ring: 0 0 0 2px var(--bg), 0 0 0 4px var(--accent);

	--font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
	--font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	--text-xs: 11px;
	--text-sm: 12px;
	--text-base: 13px;
	--text-md: 14px;
	--text-lg: 15px;
	--text-xl: 18px;
	--text-2xl: 22px;
	--text-3xl: 28px;

	--space-1: 4px;
	--space-2: 8px;
	--space-3: 12px;
	--space-4: 16px;
	--space-5: 20px;
	--space-6: 24px;
	--space-8: 32px;
	--space-12: 48px;

	--radius-sm: 4px;
	--radius: 8px;
	--radius-lg: 12px;
	--radius-full: 9999px;

	--sidebar-w: 240px;
	--content-max: 1440px;
	--form-max: 720px;
	--row-h: 44px;
	--row-h-dense: 36px;
	--control-h: 36px;
	--button-h: 32px;

	--ease-out: cubic-bezier(0.16, 1, 0.3, 1);
	--ease-enter: cubic-bezier(0.2, 0, 0, 1);
	--ease-exit: cubic-bezier(0.3, 0, 0.8, 0.15);
	--dur-fast: 120ms;
	--dur: 180ms;
	--dur-slow: 260ms;
	--dur-enter: 280ms;
	--dur-exit: 160ms;
}

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

	--bg: #F7F8FA;
	--surface: #FFFFFF;
	--surface-2: #F9FAFB;
	--elevated: #FFFFFF;
	--hover: #F2F4F7;
	--border: #E4E7EC;
	--border-strong: #D0D5DD;

	--text: #1D2939;
	--text-strong: #0F172A;
	--text-muted: #5B6474;
	--text-faint: #98A2B3;

	--accent: #0891B2;
	--accent-hover: #0E7490;
	--accent-press: #155E75;
	--accent-text: #0E7490;
	--on-accent: #FFFFFF;
	--accent-tint: rgb(8 145 178 / 0.08);
	--accent-border: rgb(8 145 178 / 0.35);

	--success: #059669;
	--success-tint: #ECFDF5;
	--success-border: #A7F3D0;
	--warning: #B45309;
	--warning-tint: #FFFBEB;
	--warning-border: #FDE68A;
	--danger: #DC2626;
	--danger-tint: #FEF2F2;
	--danger-border: #FECACA;

	--code-bg: #F2F4F7;
	--code-text: #344054;

	--shadow-card: 0 1px 2px rgb(16 24 40 / 0.04);
	--shadow-pop: 0 8px 24px -6px rgb(16 24 40 / 0.12);
	--shadow-modal: 0 24px 48px -12px rgb(16 24 40 / 0.25);
	--backdrop: rgb(15 23 42 / 0.35);
}
