/*
 * Databad design tokens.
 *
 * This file contains values only. Components must consume these semantic
 * tokens instead of declaring light-theme colors themselves. Theme variants
 * may override the same tokens on html[data-theme="..."] without duplicating
 * component selectors.
 */

:root {
    color-scheme: light;

    /* Base surfaces */
    --theme-page-bg: #f8fafc;
    --theme-surface-bg: #ffffff;
    --theme-surface-muted-bg: #f1f5f9;
    --theme-surface-subtle-bg: #f5f7fb;
    --theme-surface-raised-bg: #ffffff;

    /* Text and foregrounds */
    --theme-text: #1e293b;
    --theme-text-muted: #64748b;
    --theme-text-subtle: #94a3b8;
    --theme-on-accent: #ffffff;
    --document-surface: #ffffff;
    --document-text: #17243a;
    --document-primary: #2458b8;
    --document-primary-dark: #173f86;
    --document-muted: #536783;
    --document-rule: #cbd5e3;
    --document-border: #aebcd0;
    --document-accent-border: #9db5df;
    --document-heading-bg: #eaf0fb;
    --document-canvas-bg: #dbe2ec;
    --theme-on-accent-muted-bg: rgba(255, 255, 255, 0.18);
    --theme-on-accent-muted-text: rgba(255, 255, 255, 0.78);

    /* Borders */
    --theme-border: #e2e8f0;
    --theme-border-soft: #edf2f7;
    --theme-border-primary: #bfdbfe;
    --theme-border-primary-strong: #93c5fd;
    --theme-data-control-border: var(--theme-border);

    /* Brand and action colors */
    --theme-primary: #2563eb;
    --theme-primary-hover: #1d4ed8;
    --theme-primary-dark: #1e40af;
    --theme-primary-soft: #eff6ff;
    --theme-primary-muted: var(--theme-primary-soft);
    --theme-primary-row-soft: rgba(29, 78, 216, 0.035);
    --theme-primary-row-hover: rgba(29, 78, 216, 0.075);
    --theme-secondary: #475569;
    --theme-secondary-dark: #334155;

    /* Headers and section labels */
    --theme-header-bg: #ecf1fd;
    --theme-header-text: #3730a3;
    --theme-header-border: var(--theme-border-primary);
    --theme-header-border-strong: #c6dcf5;
    --theme-header-focus: rgba(55, 48, 163, 0.2);

    /* Status colors */
    --theme-success: #065f46;
    --theme-success-dark: #044e39;
    --theme-success-soft: #ecfdf5;
    --theme-success-disabled: #6b9f8c;
    --theme-success-focus: rgba(6, 95, 70, 0.2);
    --theme-success-border: #6ee7b7;
--theme-warning: #f59e0b;
--theme-warning-dark: #d97706;
--theme-warning-contrast: #2b1d00;
--theme-warning-soft: #fffbeb;
    --theme-warning-text: #b45309;
    --theme-warning-border: #fcd34d;
    --theme-danger: #dc2626;
    --theme-danger-dark: #b91c1c;
    --theme-danger-bright: #ef4444;
    --theme-danger-soft: #fef2f2;
    --theme-danger-panel: #fee2e2;
    --theme-danger-border: #fecaca;
    --theme-danger-border-strong: #fca5a5;
    --theme-danger-rose-soft: var(--theme-danger-soft);
    --theme-danger-rose-border: var(--theme-danger-border);
    --theme-danger-rose-text: #9f1239;
    --theme-error: #f00;

    /* Domain statuses. These retain their meaning in every visual theme. */
    --theme-status-normal: #000000;
    --theme-status-alarm: #cc3300;
    --theme-status-tolerance: #9933bb;
    --theme-status-alarm-tolerance: #2266dd;

    /* Dashboard charts */
    --theme-chart-series-1: var(--theme-primary);
    --theme-chart-series-2: #059669;
    --theme-chart-series-3: var(--theme-warning);
    --theme-chart-series-4: #7c3aed;
    --theme-chart-series-5: var(--theme-danger);
    --theme-chart-series-6: #0891b2;
    --theme-chart-series-7: #4f46e5;
    --theme-chart-series-8: #9333ea;
    --theme-chart-series-9: var(--theme-text-muted);
    --theme-chart-series-10: #16a34a;
    --theme-chart-axis: #cbd5e1;
    --theme-chart-grid: var(--theme-border);
    --theme-chart-plotband-bg: rgba(0, 255, 0, 0.2);
    --theme-chart-plotband-text: var(--theme-status-normal);

    /* Component accents */
    --theme-toggle-active: #6ab6f9;
    --theme-toggle-checked: limeGreen;
    --theme-toggle-off: var(--theme-chart-axis);
    --theme-info: #04c1c4;
    --theme-info-border: #00acd6;
    --theme-google: #dd4b39;
    --theme-google-border: #d73925;
    --theme-form-border: #dbe3ef;
    --theme-nav-button-border: #dbeafe;
    --theme-dashboard-blue-dark: #1e3a8a;
    --theme-input-muted-bg: var(--theme-border-soft);
    --theme-panel-alt-bg: #f5f8ff;
    --theme-purple: #ba99f7;
    --theme-purple-dark: #312e81;
    --theme-purple-soft: #f5f3ff;
    --theme-purple-text: #4c1d95;
    --theme-purple-border: #c4b5fd;
    --theme-autofill-bg: var(--theme-primary-muted);

    /* Public/front page and assistant surfaces */
    --theme-front-outline: rgba(28, 45, 74, 0.14);
    --theme-front-muted-alt: #6b7280;
    --theme-front-pill-bg: var(--theme-primary-muted);
    --theme-front-pill-text: #283a7a;
    --theme-assistant-handle-bg: #6c757d;
    --theme-assistant-handle-hover-bg: #5a6268;
    --theme-assistant-panel-bg: var(--theme-surface-muted-bg);
    --theme-assistant-accent: #538ed5;
    --theme-assistant-pulse: rgba(83, 142, 213, 0.7);
    --theme-assistant-pulse-clear: rgba(83, 142, 213, 0);
    --theme-assistant-critical: #dc3545;
    --theme-assistant-warning: #ffc107;
    --theme-assistant-text: #333333;

    /* Legacy values awaiting component migration */
    --theme-legacy-blue: #0077d3;
    --theme-legacy-grey: #868e96;
    --theme-legacy-dark: #343a40;
    --theme-legacy-muted: #ccc;
    --theme-legacy-subtle: #999;
    --theme-legacy-muted-strong: #aaa;
    --theme-legacy-neutral-bg: #eee;
    --theme-legacy-row-bg: var(--theme-legacy-neutral-bg);

    /* Shadows and focus rings */
    --theme-shadow-xs: rgba(0, 0, 0, 0.05);
    --theme-shadow-xs-soft: rgba(0, 0, 0, 0.04);
    --theme-shadow-xs-strong: rgba(0, 0, 0, 0.06);
    --theme-shadow-black-sm: rgba(0, 0, 0, 0.1);
    --theme-shadow-black-md: rgba(0, 0, 0, 0.15);
    --theme-shadow-black-lg: rgba(0, 0, 0, 0.2);
    --theme-shadow-sm: rgba(15, 23, 42, 0.04);
    --theme-shadow-md: rgba(15, 23, 42, 0.06);
    --theme-shadow-lg: rgba(15, 23, 42, 0.08);
    --theme-shadow-lg-strong: rgba(15, 23, 42, 0.10);
    --theme-shadow-xl: rgba(15, 23, 42, 0.20);
    --theme-shadow-xl-soft: rgba(15, 23, 42, 0.12);
    --theme-shadow-xl-muted: rgba(15, 23, 42, 0.18);
    --theme-shadow-xxl: rgba(15, 23, 42, 0.22);
    --theme-focus-primary: rgba(29, 78, 216, 0.1);
    --theme-focus-primary-soft: rgba(29, 78, 216, 0.08);
    --theme-focus-primary-strong: rgba(29, 78, 216, 0.18);
    --theme-focus-primary-stronger: rgba(29, 78, 216, 0.24);

    /* Audit and diagnostic states */
    --theme-audit-created-bg: #e0f2fe;
    --theme-audit-created-text: #075985;
    --theme-audit-updated-bg: #fef3c7;
    --theme-audit-updated-text: #92400e;
    --theme-audit-deleted-bg: #fee2e2;
    --theme-audit-deleted-text: #991b1b;
    --theme-audit-restored-bg: #dcfce7;
    --theme-audit-restored-text: #166534;
    --theme-audit-old-bg: #fff1f2;
    --theme-audit-new-bg: #ecfdf3;
    --theme-audit-changed-bg: #fff7d6;
    --theme-audit-changed-border: #d99a00;
    --theme-audit-changed-text: #6f4d00;
    --theme-diagnostic-error-bg: #fde2e2;
    --theme-diagnostic-error-text: #9d1c1c;
    --theme-diagnostic-warning-bg: #fff2cc;
    --theme-diagnostic-warning-text: #795700;
    --theme-diagnostic-success-bg: #dcf3e7;
    --theme-diagnostic-success-text: #17633e;

    /* Public navigation and footer */
    --theme-public-ink: #10223f;
    --theme-public-link: #46566d;
    --theme-public-link-active: #245edb;
    --theme-public-action: #007256;
    --theme-public-action-hover: #005b45;
    --theme-public-footer-bg: #10223f;
    --theme-public-footer-text: #d8e3f2;
    --theme-public-footer-muted: #aebed3;
    --theme-public-footer-link: #b9c9dc;
    --theme-public-footer-subtle: #8498b2;
    --theme-public-header-bg: rgba(255, 255, 255, 0.96);
    --theme-public-control-border: #ccd6e3;
    --theme-public-footer-border: rgba(255, 255, 255, 0.1);
    --theme-cookie-heading-bg: #eef3fa;
    --theme-cookie-heading-text: #29435f;
    --theme-cookie-text: #465b72;
    --theme-cookie-code: #173f70;
    --theme-cookie-border: #d6e0ec;
    --theme-cookie-summary-bg: #f3f6fa;
    --theme-cookie-summary-hover-bg: #eaf0f7;

    /* Public report browser */
    --theme-reports-ink: #14233c;
    --theme-reports-primary: #285ac7;
    --theme-reports-primary-soft: #edf3ff;
    --theme-reports-action: #00684f;
    --theme-reports-action-hover: #005240;
    --theme-reports-border: #dfe6ef;
    --theme-reports-muted: #64748b;
    --theme-reports-surface: #ffffff;
    --theme-reports-page-bg: #f4f7fb;
    --theme-reports-row-bg: #f8fafc;
    --theme-reports-row-hover: #fbfcfe;
    --theme-reports-control-bg: #f3f6fa;
    --theme-reports-disabled-bg: #f7f9fc;
    --theme-reports-disabled-text: #a0aec0;
    --theme-reports-day-text: #1d4ed8;
    --theme-reports-day-bg: #eaf1ff;
    --theme-reports-week-text: #6d28d9;
    --theme-reports-week-bg: #f2ebff;
    --theme-reports-month-text: #9a4d05;
    --theme-reports-month-bg: #fff3df;

    /* Pricing presentation */
    --theme-pricing-ink: #10223f;
    --theme-pricing-muted: #5e6e85;
    --theme-pricing-primary: #245edb;
    --theme-pricing-action: #007256;
    --theme-pricing-action-hover: #005b45;
    --theme-pricing-border: #dbe4ef;
    --theme-pricing-on-dark-muted: #d7e5fa;
    --theme-pricing-on-dark-subtle: #adc3e1;
    --theme-pricing-on-dark-accent: #78e0c0;
    --theme-pricing-dark-start: #10223f;
    --theme-pricing-dark-end: #153a70;
    --theme-pricing-feature-bg: rgba(255, 255, 255, 0.92);
    --theme-pricing-difference-bg: #e8f2ff;
    --theme-pricing-difference-border: #ccdef7;
    --theme-pricing-outcome-start: #e4f8f0;
    --theme-pricing-outcome-end: #f3fbf8;
    --theme-pricing-outcome-border: #c5ebdc;

    /* Deliberate emphasis and search marking */
    --theme-highlight-bg: #ffe36e;
    --theme-highlight-border: #d4a600;
    --theme-highlight-text: #111827;
    --theme-highlight-shadow: rgba(212, 166, 0, 0.25);

    /* Compatibility aliases. Do not use these in new components. */
    --primary: var(--theme-primary);
    --primary-dark: var(--theme-primary-dark);
    --primary-light: var(--theme-primary-soft);
    --secondary: var(--theme-text-muted);
    --secondary-light: var(--theme-surface-muted-bg);
    --success: var(--theme-success);
    --danger: var(--theme-danger-bright);
    --warning: var(--theme-warning);
    --bg-main: var(--theme-page-bg);
    --card-bg: var(--theme-surface-bg);
    --text-main: var(--theme-text);
    --text-muted: var(--theme-text-muted);
    --border-color: var(--theme-border);
    --admin-heading: var(--theme-text);
}
