/* ===== Design Tokens — Domofen Brand ===== */
:root {
    /* Brand colors */
    --brand-violet-900: #3F2948;
    --brand-violet-700: #4d3356;
    --brand-violet-600: #6B4080;
    --brand-violet-500: #7E518F;
    --brand-violet-300: #F9EAFF;
    --brand-beige-900: #E2DACF;
    --brand-beige-500: #F0ECE6;
    --brand-bois: #262018;
    --brand-blanc: #FFFFFF;

    /* Sidebar */
    --sidebar-bg: #3F2948;
    --sidebar-text: #d4c6db;
    --sidebar-active: #7E518F;
    --sidebar-hover: #4d3356;
    --sidebar-width: 250px;

    /* Semantic status — warmer tones harmonised with Domofen palette */
    --status-success: #2d7a3a;
    --status-warning: #c67a0e;
    --status-error: #b93131;
    --status-info: #7E518F;
    --status-muted: #78909c;

    /* Semantic backgrounds */
    --bg-success: #e8f5e9;
    --bg-warning: #fff4dc;
    --bg-error: #fde8e8;
    --bg-info: #F9EAFF;

    /* Typography */
    --text-primary: #262018;
    --text-secondary: #5a5249;
    --text-muted: #635b53;
    --border-color: #E2DACF;
    --bg-page: #F0ECE6;
    --bg-card: #FFFFFF;
    --bg-card-contrast: #f7f4f0;
    --font-family: 'Proxima Nova', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
    --font-mono: 'SF Mono', 'Cascadia Code', 'Fira Code', monospace;

    /* Spacing scale */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 0.75rem;
    --space-lg: 1rem;
    --space-xl: 1.5rem;
    --space-2xl: 2rem;

    /* Typography scale — standardised 6-step */
    --text-xs: 0.75rem;
    --text-sm: 0.8125rem;
    --text-base: 0.875rem;
    --text-lg: 1rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;

    /* Legacy aliases — deprecated, use --text-* instead */
    --font-xs: 0.75rem;
    --font-sm: 0.8125rem;
    --font-md: 0.875rem;
    --font-lg: 1rem;

    /* Elevation / shadows */
    --shadow-xs: 0 1px 2px rgba(38, 32, 24, 0.04);
    --shadow-sm: 0 1px 3px rgba(38, 32, 24, 0.06), 0 1px 2px rgba(38, 32, 24, 0.04);
    --shadow-md: 0 4px 12px rgba(38, 32, 24, 0.08), 0 2px 4px rgba(38, 32, 24, 0.04);
    --shadow-lg: 0 8px 24px rgba(38, 32, 24, 0.12), 0 4px 8px rgba(38, 32, 24, 0.06);
    --shadow-xl: 0 16px 48px rgba(38, 32, 24, 0.16), 0 8px 16px rgba(38, 32, 24, 0.08);

    /* Border radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 10px;
    --radius-xl: 16px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.25s ease;
    --transition-slow: 0.35s ease;

    /* Z-index layers */
    --z-table-header: 10;
    --z-sidebar: 100;
    --z-mobile-toggle: 200;
    --z-mobile-action: 200;
    --z-drawer-overlay: 300;
    --z-drawer: 310;
    --z-modal: 400;
    --z-toast: 500;
    --z-dropdown: 500;

    /* Line heights */
    --leading-tight: 1.25;
    --leading-normal: 1.5;
    --leading-relaxed: 1.65;

    /* Chip / source-tag colors (changelog, sync-run-detail, permit-detail) */
    --chip-blue-bg: #e8f0fe;
    --chip-blue-text: #1a56db;
    --chip-purple-bg: #f3e5f5;
    --chip-purple-text: #7b1fa2;
    --chip-orange-bg: #fff3e0;
    --chip-orange-text: #e65100;
    --chip-neutral-bg: #fafafa;
    --chip-neutral-text: #9e9e9e;

    /* Map marker colors (Leaflet permit map) */
    --map-marker-orange: #f57f17;
    --map-marker-gray: #9e9e9e;
    --map-marker-blue: #1565c0;

    /* Misc semantic */
    --status-warning-dark: #8a5500;
    --toggle-off: #ccc5bd;
    --code-bg: #ede8e2;
    --warning-border: #f0d68a;

    /* Primary aliases (referenced by FAB, search scope, notification center) */
    --primary: var(--brand-violet-500);
    --primary-hover: var(--brand-violet-900);
}

