/*
 * CAILO design tokens: the ONE :root block (design 402 D19). Moved here from app.css so the owner
 * app (App.razor links this before app.css) and the public journey page (from S6, under
 * /j/assets/css/) read the same values, with no copied hex anywhere.
 *
 * Brand: Earth Green --cailo-primary is the primary colour; Montserrat headings, Open Sans body.
 * Journeys use --cailo-tertiary-light as the one accent for selection (D19).
 */

/* CAILO Brand Variables - Updated from Brand Guidelines */
:root {
    /* Primary Brand Colors - Earth Green */
    --cailo-primary: #1B9986;           /* Earth Green - Primary brand color */
    --cailo-primary-hover: #157a6b;     /* Darker Earth Green for hover states */
    --cailo-primary-light: #3EC8B2;     /* Accent Green - Optimism and highlights */
    --cailo-primary-dark: #0f5c52;      /* Darkest Earth Green */
    /* Accent Brand Colors - Smart Green */
    --cailo-secondary: #52B788;         /* Smart Green - Growth and sustainability */
    --cailo-secondary-light: #6fd1a0;   /* Lighter Smart Green */
    --cailo-secondary-dark: #3a8562;    /* Darkest Smart Green */
    /* Secondary Colors - Blue Palette */
    --cailo-tertiary: #3E6AE1;          /* Tech Blue - Trust and intelligence */
    --cailo-tertiary-light: #00B4D8;    /* Vivid Azure - Innovation and energy */
    --cailo-tertiary-dark: #2c4fb3;     /* Darker Tech Blue */
    /* Accent Colors */
    --cailo-accent: #3EC8B2;            /* Accent Green - Optimism and highlights */
    --cailo-accent-hover: #2fb59f;      /* Darker Accent Green for hover */
    --cailo-accent-light: #5fd4bf;      /* Lighter Accent Green */
    --cailo-accent-dark: #1fa18d;       /* Darker Accent Green */
    /* Earth Green - Primary brand color */
    --cailo-earth-green: #1B9986;       /* Earth Green - Sustainability, earthy and vibrant */
    /* Neutral Colors - From Brand Guidelines */
    --cailo-slate-grey: #495057;     /* Slate Grey - Professionalism and stability */
    --cailo-soft-white: #F8F9FA;     /* Soft White - Clean, minimal, open */
    /* Semantic Colors - Enhanced for web application */
    --cailo-success: #52B788;        /* Smart Green for success states */
    --cailo-success-dark: #3a8562;   /* Darker Smart Green */
    --cailo-success-light: #3EC8B2;  /* Accent Green for light success */
    --cailo-warning: #ffc107;        /* Warning yellow */
    --cailo-warning-dark: #c79100;   /* Darker warning */
    --cailo-warning-light: #ffecb3;  /* Light warning */
    --cailo-danger: #d9534f;         /* Error red */
    --cailo-danger-dark: #b02a24;    /* Darker error */
    --cailo-danger-light: #f28b82;   /* Light error */
    --cailo-info: #00B4D8;          /* Vivid Azure for info states */
    --cailo-info-dark: #008CAD;     /* Darker Vivid Azure */
    --cailo-info-light: #33C2E0;    /* Lighter Vivid Azure */
    /* Application Colors - Using brand colors */
    --cailo-dark: #495057;           /* Slate Grey for dark elements */
    --cailo-text-primary: #495057;   /* Slate Grey for primary text (professionalism) */
    --cailo-text-secondary: #6c757d; /* Secondary text */
    --cailo-text-disabled: #adb5bd;  /* Disabled text */
    --cailo-background: #F8F9FA;     /* Soft White background */
    --cailo-surface: #ffffff;        /* Pure white surface */
    --cailo-light-bg: #F8F9FA;      /* Soft White for light backgrounds */
    --cailo-white: #ffffff;          /* Pure white */
    --cailo-border-color: #dee2e6;   /* Light border */
    --cailo-border-light: #F8F9FA;   /* Very light border */
    /* Shadows - Updated for new brand colors */
    --cailo-shadow-color: rgba(27, 153, 134, 0.1);    /* Earth Green shadow */
    --cailo-shadow-hover: rgba(27, 153, 134, 0.15);   /* Earth Green hover shadow */
    --cailo-shadow-primary: rgba(27, 153, 134, 0.2);  /* Earth Green primary shadow */
    --cailo-shadow-secondary: rgba(82, 183, 136, 0.2); /* Smart Green shadow */
    --cailo-shadow-tertiary: rgba(62, 106, 225, 0.2);  /* Tech Blue shadow */
    --cailo-shadow-accent: rgba(62, 200, 178, 0.2);  /* Accent Green shadow */
    /* Additional transparent whites for consistency */
    --cailo-white-90: rgba(255, 255, 255, 0.9);
    --cailo-white-80: rgba(255, 255, 255, 0.8);
    --cailo-white-55: rgba(255, 255, 255, 0.55);
    --cailo-white-20: rgba(255, 255, 255, 0.2);
    --cailo-white-15: rgba(255, 255, 255, 0.15);
    --cailo-white-10: rgba(255, 255, 255, 0.1);
    /* Additional color shades for consistency - Updated for new brand */
    --cailo-primary-05: rgba(27, 153, 134, 0.05);     /* Earth Green 5% */
    --cailo-primary-10: rgba(27, 153, 134, 0.1);      /* Earth Green 10% */
    --cailo-primary-25: rgba(27, 153, 134, 0.25);     /* Earth Green 25% */
    --cailo-secondary-05: rgba(82, 183, 136, 0.05);   /* Smart Green 5% */
    --cailo-secondary-10: rgba(82, 183, 136, 0.1);    /* Smart Green 10% */
    --cailo-secondary-25: rgba(82, 183, 136, 0.25);   /* Smart Green 25% */
    --cailo-tertiary-05: rgba(62, 106, 225, 0.05);    /* Tech Blue 5% */
    --cailo-tertiary-10: rgba(62, 106, 225, 0.1);     /* Tech Blue 10% */
    --cailo-tertiary-25: rgba(62, 106, 225, 0.25);    /* Tech Blue 25% */
    --cailo-accent-05: rgba(62, 200, 178, 0.05);      /* Accent Green 5% */
    --cailo-accent-10: rgba(62, 200, 178, 0.1);       /* Accent Green 10% */
    --cailo-accent-25: rgba(62, 200, 178, 0.25);      /* Accent Green 25% */
    --cailo-black-20: rgba(0, 0, 0, 0.2);
    --cailo-black-30: rgba(0, 0, 0, 0.3);
    --cailo-black-40: rgba(0, 0, 0, 0.4);
    /* Semantic color for highlights */
    --cailo-highlight: #fffacd;
    /* Typography - Updated for CAILO Brand Guidelines */
    --cailo-font-family-headings: 'Montserrat', 'Open Sans', 'Roboto', system-ui, -apple-system, 'BlinkMacSystemFont', 'Segoe UI', sans-serif;
    --cailo-font-family-body: 'Open Sans', 'Roboto', 'Inter', system-ui, -apple-system, 'BlinkMacSystemFont', 'Segoe UI', sans-serif;
    --cailo-font-family: var(--cailo-font-family-body); /* Default to body font */
    --cailo-font-family-mono: 'Roboto Mono', 'Fira Code', 'Monaco', 'Consolas', monospace;
    /* Layout */
    --cailo-border-radius: 8px;
    --cailo-border-radius-sm: 4px;
    --cailo-border-radius-lg: 12px;
    --cailo-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --cailo-transition-fast: all 0.15s ease;
    --cailo-spacing: 1rem;
    --cailo-spacing-xs: 0.25rem;
    --cailo-spacing-sm: 0.5rem;
    --cailo-spacing-md: 1rem;
    --cailo-spacing-lg: 1.5rem;
    --cailo-spacing-xl: 2rem;
    --cailo-spacing-xxl: 3rem;
    /* Legacy variables for backward compatibility */
    --primary-color: var(--cailo-primary);
    --accent-color: var(--cailo-accent);
    --secondary-color: var(--cailo-success);
    --danger-color: var(--cailo-danger);
    --text-color: var(--cailo-text-primary);
    --light-bg: var(--cailo-light-bg);
    --white: var(--cailo-white);
    --border-color: var(--cailo-border-color);
    --shadow-color: var(--cailo-shadow-color);
    --font-family: var(--cailo-font-family);
    --border-radius: var(--cailo-border-radius);
    --transition: var(--cailo-transition);
    /* Cailo white variations for nav menu styling */
    --Cailo-white: var(--cailo-white);
    --Cailo-white-90: var(--cailo-white-90);
    --Cailo-white-80: var(--cailo-white-80);
    --Cailo-white-55: var(--cailo-white-55);
    --Cailo-white-20: var(--cailo-white-20);
    --Cailo-white-15: var(--cailo-white-15);
    --Cailo-white-10: var(--cailo-white-10);
    /* Cailo highlight for error UI */
    --Cailo-highlight: var(--cailo-highlight);
    /* Drive assist (FSD (Supervised)), issue #378, 04a §4.1 (OD-R7). Violet differs in hue AND
       luminance from the route teal, the replay blue and the brake red, and is always paired with
       a non-colour cue. Light theme only (owner ruling D-V2-4). Leaflet and Lightweight Charts
       read --cailo-assist once through getComputedStyle (drive-assist-overlay.js). */
    --cailo-assist: #5B21B6;                      /* map overlay core, chip icon, timeline, bars */
    --cailo-assist-text: #4C1D95;                 /* text on the soft tint */
    --cailo-assist-soft: #EDE9FE;                 /* chip and pill background */
    --cailo-assist-tint: rgba(91, 33, 182, 0.13); /* hover, legend swatch */
    --cailo-assist-band: rgba(91, 33, 182, 0.09); /* speed-chart band */
    --cailo-assist-on-dark: #C4B5FD;              /* the FSD stat on the #1A2332 trip header */
    /* Issue #378 plan S11 (04a §5.2 to §5.9): chip and card borders, the day-part strip ramp. */
    --cailo-assist-border: rgba(91, 33, 182, 0.22);  /* chip border, hover rings */
    --cailo-assist-ramp-1: #EDE9FE;               /* day-part strip: lowest share */
    --cailo-assist-ramp-2: #DDD6FE;
    --cailo-assist-ramp-3: #8B5CF6;
    --cailo-assist-ramp-4: #5B21B6;               /* day-part strip: highest share */
    /* Issue #402: the map legend's card (.cda-legend, drive-assist.css), the values the overlay
       used to inject inline, so trip details looks the same and the public page's CSP allows it. */
    --cailo-assist-legend-bg: rgba(255, 255, 255, 0.95);
    --cailo-assist-legend-text: #1a2e2a;
    --cailo-assist-legend-shadow: rgba(0, 0, 0, 0.12);
}
