/* =========================================
   NO IMPORTS HERE (2026-10-28)
   =========================================
   topbar, banner, body, buttons, mobile and filters.css are linked by the
   pages themselves, each with its own ?v= stamp: core/html/_core_css.html.
   An @import here is fetched by the browser on its own and is NOT stamped on
   the host (LiteSpeed serves .css from disk, cached immutable for a year), so
   a deploy would never reach it. Add a new core stylesheet to _core_css.html.
   ========================================= */

/* =========================================
   THEME VARIABLES (The Source of Truth)
   ========================================= */
:root {
    /* --- CONSTANT BRAND COLORS (These NEVER change) --- */
    --brand-primary: #FF6600; /* LEDVANCE ORANGE */
    --brand-hover: #E55B00;
    
    --static-black: #000000; /* Use this for the Top Bar */
    --static-white: #ffffff; /* Use this for Banner Icons */
    
    /* --- SEMANTIC PALETTE --- */
    --color-blue: #3b82f6;
    --color-blue-hover: #2563eb;
    --color-green: #10b981;
    --color-red: #ef4444;
    --color-red-dark: #b91c1c;
    --color-gray: #9ca3af;
    
    /* THE MISSING COLORS: */
    --color-yellow: #f59e0b;
    --color-purple: #8b5cf6;
    --color-white: #ffffff;
    --color-black: #1f2937;

    /* --- LIGHT THEME (Default) --- */
    --bg-main: #f3f4f6; 
    --text-main: #1f2937; 
    --text-muted: #6b7280;
    --card-bg: #ffffff;
    --modal-bg: #ffffff;
    --row-bg: #ffffff;
    --row-border: #e5e7eb;
    --row-hover: #f9fafb;
    
    /* Hard-Lock these to Black/Orange in Light Mode */
    --top-bar-bg: var(--static-black); 
    --top-bar-text: var(--static-white);
    --banner-bg: var(--brand-primary); 
    --banner-text: var(--static-white); 
    
    --input-bg: #ffffff; 
    --input-border: #d1d5db;
}

/* --- DARK THEME OVERRIDES --- */
html[data-theme="dark"] {
    --bg-main: #121212; 
    --text-main: #f9fafb; 
    --text-muted: #9ca3af;
    --card-bg: #1e1e24;
    --modal-bg: #1e1e24;
    --row-bg: #2a2a32;
    --row-border: #3f3f46;
    --row-hover: #38383f;
    
    /* Keep these exactly the same as Light Mode! */
    --top-bar-bg: var(--static-black); 
    --top-bar-text: var(--static-white);
    --banner-bg: var(--brand-primary); 
    
    --input-bg: #2a2a32; 
    --input-border: #4b5563;
}

/* =========================================
   BASE STYLES
   ========================================= */
* {
    box-sizing: border-box;
}

body { 
    font-family: 'Inter', -apple-system, sans-serif; 
    margin: 0; 
    padding: 0;
    background-color: var(--bg-main); 
    color: var(--text-main); 
    /* Smooth theme transition */
    transition: background-color 0.3s ease, color 0.3s ease; 
    min-height: 100vh;
}

/* =========================================
   UTILITY CLASSES (Theme-Proofing)
   ========================================= */

/* Forces text and icons to stay white regardless of theme */
.btn-white, .btn-static-white, .text-white {
    color: var(--static-white) !important;
}

/* Hard-lock SVG icons inside these elements */
.btn-white svg, 
.btn-static-white svg,
.btn-white svg path,
.btn-white svg circle,
.btn-white svg line,
.btn-white svg polyline {
    stroke: var(--static-white) !important;
    /* If any icon uses fill instead of stroke, this covers it: */
    fill: none; 
}

/* Special case for the "Circle Menu" icon which might need specific fills */
#circleMenu circle {
    stroke: var(--static-white) !important;
}

/* App Drawer Icons 10% Larger */
.app-icon-square {
    transform: scale(1.1);
    transform-origin: center;
}