/*
 * Theme color tokens. The only place colors are defined; every custom stylesheet uses these.
 * Roles: bg (page), surface* (cards, panels, menus), border*, text*, brand/state colors with
 * -hover / -soft (tinted background) variants, and -rgb channels for alpha: rgb(var(--c-x-rgb) / .2).
 * Values are literal (no var(--x-*)) because public pages don't load main.css.
 */
:root {
    --c-bg: #f5f9fc;
    --c-surface: #ffffff;
    --c-surface-raised: #ffffff;
    --c-surface-subtle: #eef5f9;
    --c-surface-sunken: #f5f9fc;
    --c-surface-inverse: #1d2b36;
    --c-surface-inverse-raised: #4e717f;
    --c-border: #e7eaf0;
    --c-border-strong: #cfd6df;

    --c-text: #16192c;
    --c-text-rgb: 22 25 44;
    --c-text-body: #525f7f;
    --c-text-muted: #6b7b93;
    --c-text-quiet: #64748b;
    --c-text-inverse: #ffffff;
    --c-text-inverse-rgb: 255 255 255;

    --c-primary: #5c60f5;
    --c-primary-rgb: 92 96 245;
    --c-primary-hover: #4f46e5;
    --c-primary-soft: #e0e7ff;

    --c-info: #3b82f6;
    --c-info-rgb: 59 130 246;
    --c-info-hover: #2563eb;
    --c-info-soft: #dbeafe;

    --c-accent: #21a191;
    --c-accent-rgb: 33 161 145;
    --c-accent-hover: #17786d;
    --c-accent-strong: #12635a;
    --c-accent-soft: #e4f2f0;

    --c-success: #16a34a;
    --c-success-soft: #d1fae5;

    --c-warning: #d97706;
    --c-warning-soft: #fef3c7;

    --c-danger: #dc2626;
    --c-danger-soft: #fee2e2;

    --c-ai: #8b5cf6;
    --c-ai-rgb: 139 92 246;
    --c-ai-soft: #ede4ff;

    --c-brand: #e5484d;

    --c-shadow-rgb: 0 0 0;
}

[data-theme=dark] {
    --c-bg: #2d3748;
    --c-surface: #1f2333;
    --c-surface-raised: #272b3f;
    --c-surface-subtle: #232a3b;
    --c-surface-sunken: #16192c;
    --c-surface-inverse: #1d2b36;
    --c-surface-inverse-raised: #4e717f;
    --c-border: rgb(255 255 255 / .09);
    --c-border-strong: #4b5563;

    --c-text: #fafafa;
    --c-text-rgb: 250 250 250;
    --c-text-body: #f5f9fc;
    --c-text-muted: #cfd6df;
    --c-text-quiet: #aab4c3;
    --c-text-inverse: #ffffff;
    --c-text-inverse-rgb: 255 255 255;

    --c-primary: #6366f1;
    --c-primary-rgb: 99 102 241;
    --c-primary-hover: #4f46e5;
    --c-primary-soft: #211f4a;

    --c-info: #3b82f6;
    --c-info-rgb: 59 130 246;
    --c-info-hover: #2563eb;
    --c-info-soft: #1e2a44;

    --c-accent: #4cc3b3;
    --c-accent-rgb: 76 195 179;
    --c-accent-hover: #5eead4;
    --c-accent-strong: #99f6e4;
    --c-accent-soft: #22403f;

    --c-success: #34d399;
    --c-success-soft: #1a2e22;

    --c-warning: #fbbf24;
    --c-warning-soft: #3a2f12;

    --c-danger: #f87171;
    --c-danger-soft: #3b1d1d;

    --c-ai: #a78bfa;
    --c-ai-rgb: 167 139 250;
    --c-ai-soft: #2e2350;

    --c-brand: #ff6369;

    --c-shadow-rgb: 0 0 0;
}
