/* AUTO-GENERATED by design/tokens/build_tokens.py — DO NOT EDIT.
   Edit design/tokens/tokens.yaml, then re-run the generator.

   DARK-MODE ACCENT-SWAP: secondary-tier blue accents swap
   primary(#0047AB)->secondary(#4D7EC4) in dark (ghost buttons,
   panel-footer buttons, study pills, active nav/note text,
   dashboard card headings). Primary fills & key indicators stay
   #0047AB (filled primary button, active-row border, today cell,
   checked to-do). SwiftUI: Color.accent(colorScheme).

   GRADE COLOURS (canonical; mirrors GradeHelpers.swift + components.md §8;
   `bar` also feeds the proximity bar; dark mode uses bar-as-text on
   bar-at-22%-opacity background):
     A* /9    bg #BBF7D0  text #14532D  bar #10B981
     A/8     bg #D9F99D  text #365314  bar #84CC16
     7       bg #ECFCCB  text #3F6212  bar #A3E635
     B       bg #FEF08A  text #854D0E  bar #EAB308
     C/6     bg #FED7AA  text #7C2D12  bar #F97316
     D/5     bg #FDBA74  text #92400E  bar #FB923C
     E/4     bg #FCA5A5  text #991B1B  bar #EF4444
     3/2/1   bg #FECACA  text #991B1B  bar #F87171
     U/Fail  bg #E5E7EB  text #374151  bar #9CA3AF
*/

:root {
	/* Brand palette (constant — not overridden in dark mode) */
	--primary: #0047AB;
	--secondary: #4D7EC4;
	--dusty: #7AA0D4;
	--pale: #A3BFE0;
	--powder: #C2D4ED;
	--ice: #D8E5F5;
	--plum: #94285A;
	--orange: #E86E1E;

	/* Fonts */
	--font-ui: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
	--font-mono: "Consolas", "Courier New", monospace;
	--font-serif: "Times New Roman", Times, serif;

	/* Surfaces / text / borders (light) */
	--surface-page: #D8E5F5;
	--surface-nav: #F0F4FA;
	--surface-card: #FFFFFF;
	--surface-editor-left: #F3F6FC;
	--surface-hover: #C2D4ED;
	--surface-active: #EEF4FF;
	--fill-input: #F2F2F7;
	--text-body: #111111;
	--text-heading: #4D7EC4;
	--text-muted: #5A77A3;
	--border-subtle: #C2D4ED;
	--border-normal: #A3BFE0;

	/* Type scale */
	--fs-h1: 25.6px;
	--fs-h2: 19.2px;
	--fs-body: 16px;
	--fs-small: 14px;
	--fs-meta: 12px;
	--fs-label: 11.2px;
	--fs-tiny: 11px;

	/* Spacing (8px grid) */
	--space-xs: 4px;
	--space-sm: 8px;
	--space-md: 12px;
	--space-lg: 16px;
	--space-xl: 20px;
	--space-xxl: 24px;
	--space-xxxl: 32px;

	/* Radii */
	--radius-sm: 8px;
	--radius-md: 10px;
	--radius-lg: 12px;
	--radius-modal: 20px;
	--radius-pill: 100px;

	/* Shadows */
	--shadow-card: 0 1px 3px rgba(0,71,171,0.07), 0 1px 2px rgba(0,71,171,0.04);
	--shadow-elevated: 0 4px 16px rgba(0,71,171,0.10);

	/* Motion */
	--motion-fast: 0.1s;
	--motion-nav: 0.08s;
	--motion-sidebar: 0.22s;
	--motion-chevron: 0.18s;
}

html[data-theme="dark"] {
	/* Surfaces / text / borders (dark) */
	--surface-page: #1C1C1E;
	--surface-nav: #252525;
	--surface-card: #2C2C2E;
	--surface-editor-left: #252525;
	--surface-hover: rgba(255,255,255,0.07);
	--surface-active: #1E2C45;
	--fill-input: #3A3A3C;
	--text-body: #F2F2F7;
	--text-heading: #4D7EC4;
	--text-muted: #8E8E93;
	--border-subtle: #3A3A3C;
	--border-normal: #48484A;

	/* Shadows */
	--shadow-card: 0 1px 3px rgba(0,0,0,0.40);
	--shadow-elevated: 0 4px 16px rgba(0,0,0,0.55);
	--shadow-preview: 0 4px 20px rgba(0,0,0,0.28);

	color-scheme: dark;
}
