:root {
    color-scheme: light;

    --bg: #F6F7F9;  --surface: #FFFFFF;  --sunken: #EEF0F4;
    --text: #1F2A44;  --muted: #5B677D;
    --border: #D7DCE5;  --border-input: #7A8599;
    --accent: #1F5FD6;  --accent-hover: #1A4FB3;  --on-accent: #FFFFFF;
    --danger: #B42318;
    --shadow: 0 1px 3px rgba(16,24,40,.16);
    --shadow-drawer: -8px 0 24px rgba(16,24,40,.2);
    --backdrop: rgba(10,15,25,.45);

    /* category colours: background and text */
    --cat-blue-bg: #E3EDFD;    --cat-blue-fg: #174CAD;
    --cat-purple-bg: #EEE9FB;  --cat-purple-fg: #4B3A9A;
    --cat-green-bg: #DFF5E8;   --cat-green-fg: #1B6B3E;
    --cat-orange-bg: #FDEBD3;  --cat-orange-fg: #8A4B08;
    --cat-red-bg: #FDE7E4;     --cat-red-fg: #9B2C1F;
    --cat-teal-bg: #DDF3F2;    --cat-teal-fg: #0F6B66;
    --cat-pink-bg: #FBE6F1;    --cat-pink-fg: #9D2465;
    --cat-grey-bg: #E8EBF0;    --cat-grey-fg: #475569;

    /* spacing scale */
    --space-1: 4px;  --space-2: 8px;  --space-3: 12px;  --space-4: 16px;
    --space-5: 24px;  --space-6: 32px;  --space-7: 48px;
    /* extra spacing used by the mock-up */
    --space-6px: 6px;  --space-10px: 10px;  --space-14px: 14px;
    --space-20px: 20px;  --space-64px: 64px;

    --radius-label: 3px;  --radius-control: 6px;  --radius-card: 8px;

    --font: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --text-label: 11px;  --text-small: 13px;  --text-body: 14px;
    --text-card-title: 16px;  --text-panel-title: 20px;  --text-page-title: 24px;
    --line-body: 1.5;  --line-title: 1.4;  --line-page-title: 1.3;

    --tap-target: 44px;
    --icon: 18px;  --icon-small: 16px;  --logo: 28px;
    --content-max: 1120px;  --card-min: 320px;
    --search-width: 260px;  --drawer-width: 440px;  --login-width: 360px;

    --slide: .25s ease;
    --theme-fade: .3s;
}

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

    --bg: #14181F;  --surface: #1C222B;  --sunken: #262E3A;
    --text: #E6EAF0;  --muted: #9AA5B8;
    --border: #333C4A;  --border-input: #6C7789;
    --accent: #6FA2F5;  --accent-hover: #8DB6F7;  --on-accent: #0B1A33;
    --danger: #F28B82;
    --shadow: 0 1px 3px rgba(0,0,0,.55);

    --cat-blue-bg: #1B3358;    --cat-blue-fg: #A9C8FA;
    --cat-purple-bg: #2E2753;  --cat-purple-fg: #C7BBF5;
    --cat-green-bg: #17382A;   --cat-green-fg: #8FD6AC;
    --cat-orange-bg: #44300F;  --cat-orange-fg: #F2C27E;
    --cat-red-bg: #4A1F1B;     --cat-red-fg: #F5A59B;
    --cat-teal-bg: #123B3A;    --cat-teal-fg: #8ADBD6;
    --cat-pink-bg: #4A1D35;    --cat-pink-fg: #F4AACB;
    --cat-grey-bg: #2D3542;    --cat-grey-fg: #B8C0CE;
}
