/*
 * BLACK TITANIUM — LIGHT EDITION (official default theme of RAMA AG): Apple × Linear × Swiss minimalism.
 *
 *   BLACK TITANIUM DOES NOT MEAN FULL DARK MODE.
 *   Light workspace + white surfaces + a Black Titanium (#111214) sidebar. Dark backgrounds are reserved for the
 *   navigation sidebar, its active item, primary action buttons, selected branded headers and the sign-in page.
 *
 * Single source of truth for colour tokens; every component below reads them (no hard-coded colours in views).
 * Matte surfaces only (no metallic gradients on buttons, cards, inputs or segmented controls). Status colours are used
 * sparingly and never alone (always with an icon or text). Motion 150–250 ms, disabled under prefers-reduced-motion.
 */
:root {
    color-scheme: light;
    /* Owner tokens */
    --bt-sidebar: #111214;
    --bt-sidebar-gradient: linear-gradient(150deg, #292b30 0%, #111214 55%, #08090a 100%);
    --bt-sidebar-active: rgba(255,255,255,0.09);
    --bt-sidebar-category: #858993;
    --bt-sidebar-hover: rgba(255,255,255,0.04);
    --bt-sidebar-radius: 7px;
    --bt-sidebar-transition: 180ms;
    --bt-app: #f0f1f3;
    --bt-card: #ffffff;
    --bt-header: #ffffff;
    --bt-surface: #ffffff;
    --bt-text: #111214;
    --bt-text-2: #686d76; /* owner #717680 → AA on #F0F1F3 */
    --bt-border: #e2e4e8;
    --bt-accent: #a8adb5;
    --bt-button: #111214;
    --bt-button-text: #ffffff;
    --bt-hover: #e9eaed;
    /* Derived */
    --bt-elevated: #f6f7f8;
    --bt-border-strong: #cfd2d7;
    --bt-muted: #686d76;
    --bt-focus: #111214;
    --bt-sidebar-text: #A9ABB2;
    --bt-sidebar-text-strong: #ffffff;
    --bt-sidebar-border: #25272b;
    --bt-ok: #0f7552;
    --bt-warn: #9a5107;
    --bt-err: #c4321c;
    --bt-info: #3f4a5a;
    --bt-radius: 10px;
    --bt-radius-sm: 7px;
    --bt-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
    --bt-fast: 150ms;
    --bt-med: 220ms;
    --bt-metal: none; /* matte: kept only so old rules resolve to nothing */
}

/* ---------- Global base ---------- */
body { background: var(--bt-app); color: var(--bt-text); }
::selection { background: rgb(168 173 181 / 0.35); }
:focus-visible { outline: 2px solid var(--bt-focus); outline-offset: 2px; }
[data-app-header] { background: var(--bt-header) !important; border-color: var(--bt-border) !important; }
.tabular, .bt-num { font-variant-numeric: tabular-nums; font-feature-settings: 'tnum'; }
input, select, textarea { color-scheme: light; }
.text-primary { color: var(--bt-text); }

/* Map: light tiles from the same OpenStreetMap provider (no inversion), white controls. */
.leaflet-container { background: #eef0f2 !important; }
.leaflet-tile-pane { filter: none; }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { background: #ffffff !important; color: var(--bt-text) !important; border: 1px solid var(--bt-border); }
.leaflet-control-zoom a, .leaflet-bar a { background: #ffffff !important; color: var(--bt-text) !important; border-color: var(--bt-border) !important; }

/* ---------- Sidebar: group labels ---------- */
.qw-nav-group { list-style: none; padding: 14px 12px 4px; }
.qw-nav-group:first-of-type { padding-top: 4px; }
.qw-nav-group-label { font-size: 10.5px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--bt-muted); }
[data-collapsed='true'] .qw-nav-group-label { visibility: hidden; }
[data-collapsed='true'] .qw-nav-group { padding: 6px 0 0; border-top: 1px solid var(--bt-border); margin: 6px 10px 0; }

/* ---------- Page scaffolding ---------- */
.bt-page { display: flex; flex-direction: column; gap: 14px; animation: bt-enter var(--bt-med) var(--bt-ease) both; }
.bt-page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.bt-eyebrow { font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--bt-muted); }
.bt-title { font-size: 22px; line-height: 1.2; font-weight: 650; letter-spacing: -0.02em; color: var(--bt-text); }
.bt-h3 { font-size: 12.5px; font-weight: 600; color: var(--bt-text-2); margin: 10px 0 6px; }
.bt-stack { display: flex; flex-direction: column; gap: 14px; }
.bt-grid-2 { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); align-items: start; }
.bt-grid-3 { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); align-items: start; }
.bt-split { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1280px) { .bt-split { grid-template-columns: minmax(0, 1fr) 340px; } }
.bt-muted { color: var(--bt-text-2); }
.bt-small { font-size: 12px; }
.bt-pad { padding: 10px 16px; }
.bt-wrap { white-space: normal; overflow-wrap: anywhere; }
.bt-neg { color: var(--bt-err) !important; }
.bt-link { color: var(--bt-text); text-decoration: underline; text-underline-offset: 3px; background: none; border: 0; cursor: pointer; font: inherit; padding: 0; }
.bt-code { font-family: var(--font-mono); font-size: 11px; color: var(--bt-text-2); background: var(--bt-elevated); border: 1px solid var(--bt-border); border-radius: 5px; padding: 0 5px; }

/* Sub navigation (SMGV Center) */
.bt-subnav { display: flex; gap: 2px; overflow-x: auto; border-bottom: 1px solid var(--bt-border); padding-bottom: 0; }
.bt-subnav-link { white-space: nowrap; padding: 8px 12px; font-size: 13px; color: var(--bt-text-2); border-bottom: 2px solid transparent; margin-bottom: -1px; transition: color var(--bt-fast), border-color var(--bt-fast); }
.bt-subnav-link:hover { color: var(--bt-text); }
.bt-subnav-link[aria-current='page'] { color: var(--bt-text); border-bottom-color: var(--bt-text); }

/* ---------- Cards ---------- */
.bt-card { position: relative; background: var(--bt-card); border: 1px solid var(--bt-border); border-radius: var(--bt-radius); padding: 16px; box-shadow: 0 1px 2px rgb(17 18 20 / 0.04); }
.bt-card-flush { padding: 0; overflow: hidden; }
.bt-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.bt-card-flush > .bt-card-head { margin: 0; padding: 12px 16px; border-bottom: 1px solid var(--bt-border); }
.bt-card-head h2 { font-size: 14px; font-weight: 600; letter-spacing: -0.01em; color: var(--bt-text); }
.bt-card-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--bt-border); }
.bt-card-flush > .bt-card-foot { margin: 0; padding: 12px 16px; }
.bt-card-accent { border-color: var(--bt-border-strong); }
.bt-subcard { background: var(--bt-surface); border: 1px solid var(--bt-border); border-radius: var(--bt-radius-sm); padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.bt-subcard h3 { font-size: 13px; font-weight: 600; }

/* ---------- KPI ---------- */
.bt-kpi-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.bt-kpi { background: var(--bt-card); border: 1px solid var(--bt-border); border-radius: var(--bt-radius); padding: 12px 14px; transition: border-color var(--bt-fast), transform var(--bt-fast) var(--bt-ease); }
.bt-kpi:hover { border-color: var(--bt-border-strong); transform: translateY(-1px); }
.bt-kpi-label { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--bt-text-2); }
.bt-kpi-value { margin-top: 6px; font-size: 21px; font-weight: 650; letter-spacing: -0.02em; color: var(--bt-text); font-variant-numeric: tabular-nums; }
.bt-kpi-unit { margin-left: 4px; font-size: 11px; font-weight: 500; color: var(--bt-muted); }
.bt-reveal { animation: bt-count var(--bt-med) var(--bt-ease) both; }

/* ---------- Controls ---------- */
.bt-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.bt-btn-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.bt-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; padding: 0 13px; border-radius: var(--bt-radius-sm); border: 1px solid var(--bt-border); background: #ffffff; color: var(--bt-text); font-size: 13px; font-weight: 550; white-space: nowrap; cursor: pointer; transition: background var(--bt-fast), border-color var(--bt-fast), transform var(--bt-fast); }
.bt-btn:hover { background: var(--bt-hover); border-color: var(--bt-border-strong); }
.bt-btn:active { transform: translateY(1px); }
.bt-btn:disabled { opacity: 0.55; cursor: not-allowed; }
.bt-btn-primary { background: var(--bt-button); color: var(--bt-button-text); border-color: var(--bt-button); }
.bt-btn-primary:hover { background: var(--bt-sidebar-active); border-color: var(--bt-sidebar-active); }
.bt-btn-ghost { background: transparent; border-color: var(--bt-border); color: var(--bt-text-2); }
.bt-btn-ghost:hover { color: var(--bt-text); background: var(--bt-hover); }
.bt-btn-danger { background: #fff5f4; border-color: #f2c4bd; color: var(--bt-err); }
.bt-btn-sm { height: 28px; padding: 0 9px; font-size: 12px; }
.bt-btn-icon { width: 34px; padding: 0; }
.bt-actions { text-align: right; white-space: nowrap; }
.bt-actions .bt-btn + .bt-btn { margin-left: 4px; }
.bt-input, .bt-select { height: 34px; min-width: 0; border-radius: var(--bt-radius-sm); border: 1px solid var(--bt-border); background: var(--bt-surface); color: var(--bt-text); padding: 0 10px; font-size: 13px; transition: border-color var(--bt-fast), box-shadow var(--bt-fast); }
.bt-select { padding-right: 28px; }
.bt-select-wide { min-width: 220px; }
.bt-input::placeholder { color: var(--bt-muted); }
.bt-input:focus, .bt-select:focus { outline: none; border-color: var(--bt-text); box-shadow: 0 0 0 3px rgb(168 173 181 / 0.28); }
.bt-textarea { height: auto; padding: 8px 10px; width: 100%; resize: vertical; }
.bt-form-grid { display: grid; gap: 10px 12px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); }
.bt-field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.bt-span-2 { grid-column: 1 / -1; }
.bt-label { font-size: 11.5px; font-weight: 550; color: var(--bt-text-2); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.bt-hint { font-size: 11.5px; color: var(--bt-muted); line-height: 1.45; }
.bt-error { font-size: 12px; color: var(--bt-err); }
.bt-readonly { min-height: 34px; display: flex; align-items: center; gap: 6px; padding: 0 10px; border: 1px dashed var(--bt-border); border-radius: var(--bt-radius-sm); color: var(--bt-text-2); font-size: 13px; overflow-wrap: anywhere; }
.bt-check { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--bt-text); cursor: pointer; min-height: 28px; }
.bt-check input, .bt-choice input, .bt-chip input { accent-color: var(--bt-text); width: 15px; height: 15px; }
.bt-fieldset { border: 0; padding: 0; margin: 0 0 12px; display: flex; flex-direction: column; gap: 8px; }
.bt-choice-grid { display: grid; gap: 6px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.bt-choice { display: flex; align-items: center; gap: 8px; padding: 9px 10px; border: 1px solid var(--bt-border); border-radius: var(--bt-radius-sm); font-size: 13px; cursor: pointer; transition: border-color var(--bt-fast), background var(--bt-fast); }
.bt-choice.is-on { border-color: var(--bt-text); background: var(--bt-elevated); }
.bt-chip-row { display: flex; flex-wrap: wrap; gap: 6px; }
.bt-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border: 1px solid var(--bt-border); border-radius: 999px; font-size: 12px; cursor: pointer; }
.bt-pensum-row { display: grid; gap: 8px; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.bt-dropzone { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 26px 12px; border: 1px dashed var(--bt-border-strong); border-radius: var(--bt-radius); color: var(--bt-text-2); cursor: pointer; text-align: center; transition: border-color var(--bt-fast), background var(--bt-fast); }
.bt-dropzone:hover { border-color: var(--bt-text); background: var(--bt-elevated); }

/* ---------- Status / alerts (icon + text, never colour alone) ---------- */
.bt-badge { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 7px; border-radius: 999px; font-size: 11px; font-weight: 600; border: 1px solid; white-space: nowrap; vertical-align: middle; }
.bt-badge--ok { color: var(--bt-ok); border-color: #b9e3cf; background: #ecf8f2; }
.bt-badge--warn { color: var(--bt-warn); border-color: #f1d3a6; background: #fdf4e6; }
.bt-badge--err { color: var(--bt-err); border-color: #f2c4bd; background: #fff2f0; }
.bt-badge--info { color: var(--bt-info); border-color: var(--bt-border-strong); background: var(--bt-elevated); }
.bt-badge--muted { color: var(--bt-text-2); border-color: var(--bt-border); background: var(--bt-elevated); }
.bt-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border: 1px solid var(--bt-border); border-radius: 999px; font-size: 12px; }
.bt-alert { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; border-radius: var(--bt-radius-sm); border: 1px solid; font-size: 13px; line-height: 1.45; animation: bt-enter var(--bt-med) var(--bt-ease) both; }
.bt-alert ul { margin: 4px 0 0 16px; list-style: disc; }
.bt-alert--ok { color: #0b5a3f; border-color: #b9e3cf; background: #ecf8f2; }
.bt-alert--warn { color: #7a4106; border-color: #f1d3a6; background: #fdf4e6; }
.bt-alert--err { color: #9f2615; border-color: #f2c4bd; background: #fff2f0; }
.bt-alert--info { color: #30363f; border-color: var(--bt-border); background: #f6f7f8; }
.bt-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 34px 16px; text-align: center; color: var(--bt-text-2); font-size: 13px; }
.bt-avatar { display: inline-grid; place-items: center; width: 24px; height: 24px; margin-right: 8px; border-radius: 999px; background: var(--bt-elevated); border: 1px solid var(--bt-border); color: var(--bt-text); font-size: 10px; font-weight: 600; vertical-align: middle; }
.bt-progress { height: 2px; overflow: hidden; background: var(--bt-border); border-radius: 2px; margin-top: 8px; }
.bt-progress span { display: block; height: 100%; width: 35%; background: var(--bt-text); animation: bt-progress 1.1s var(--bt-ease) infinite; }
.bt-spin { animation: bt-spin 0.9s linear infinite; }
.bt-skeleton { background: linear-gradient(90deg, var(--bt-elevated), var(--bt-hover), var(--bt-elevated)); background-size: 200% 100%; animation: bt-shimmer 1.4s ease infinite; border-radius: 6px; }

/* ---------- Tables ---------- */
.bt-table-wrap { overflow: auto; max-width: 100%; }
.bt-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; }
.bt-table th, .bt-table td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--bt-border); white-space: nowrap; }
.bt-table thead th { position: sticky; top: 0; z-index: 1; background: #f8f9fa; font-size: 11.5px; font-weight: 600; color: var(--bt-text-2); text-transform: none; }
.bt-table tbody th { font-weight: 550; color: var(--bt-text); }
.bt-table tbody tr { transition: background var(--bt-fast); }
.bt-table tbody tr:hover { background: #f7f8f9; }
.bt-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.bt-table-compact th, .bt-table-compact td { padding: 6px 10px; font-size: 12.5px; }
.bt-row-total th, .bt-row-total td { font-weight: 650; border-top: 1px solid var(--bt-border-strong); }
.bt-dl { display: flex; flex-direction: column; }
.bt-dl > div { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--bt-border); font-size: 13px; }
.bt-dl dt { color: var(--bt-text-2); }
.bt-dl dd { font-weight: 600; font-variant-numeric: tabular-nums; }
.bt-dl-strong dt, .bt-dl-strong dd { color: var(--bt-text); font-weight: 650; }
.bt-list { display: flex; flex-direction: column; gap: 6px; }
.bt-timeline { display: flex; flex-direction: column; gap: 8px; }
.bt-timeline li { display: flex; flex-direction: column; gap: 2px; padding-left: 12px; border-left: 2px solid var(--bt-border-strong); font-size: 12.5px; }

/* ---------- Spreadsheet (SMGV monthly / annual) ---------- */
.bt-sheet-head { align-items: flex-start; }
.bt-sheet-title { font-size: 15px; font-weight: 650; letter-spacing: -0.01em; }
.bt-sheet-kpis { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.bt-sheet-legend { display: flex; flex-wrap: wrap; gap: 14px; padding: 8px 16px; border-bottom: 1px solid var(--bt-border); font-size: 11.5px; color: var(--bt-text-2); }
.bt-sheet-legend span { display: inline-flex; align-items: center; gap: 6px; }
.bt-swatch { display: inline-block; width: 14px; height: 10px; border-radius: 3px; border: 1px solid var(--bt-border-strong); }
.bt-swatch-edit { background: #fbfbfc; border-color: var(--bt-accent); }
.bt-swatch-calc { background: var(--bt-card); }
.bt-swatch-weekend { background: #f2f3f5; }
.bt-swatch-holiday { background: rgb(96 165 250 / 0.15); }
.bt-sheet-wrap { overflow: auto; max-height: calc(100vh - 290px); min-height: 280px; }
.bt-sheet { border-collapse: separate; border-spacing: 0; font-size: 11.5px; font-variant-numeric: tabular-nums; }
.bt-sheet th, .bt-sheet td { height: 26px; min-width: 42px; padding: 0 6px; text-align: right; border-right: 1px solid var(--bt-border); border-bottom: 1px solid var(--bt-border); white-space: nowrap; color: var(--bt-text); }
.bt-sheet thead th { position: sticky; top: 0; z-index: 3; background: #f8f9fa; font-weight: 600; color: var(--bt-text-2); text-align: center; }
.bt-sheet thead tr:nth-child(2) th { top: 26px; }
.bt-sheet .bt-sheet-label { position: sticky; left: 0; z-index: 2; min-width: 250px; max-width: 280px; text-align: left; background: var(--bt-card); font-weight: 500; color: var(--bt-text-2); white-space: normal; line-height: 1.2; }
.bt-sheet thead .bt-sheet-label { z-index: 4; background: #f8f9fa; }
.bt-sheet .bt-sheet-total { position: sticky; right: 0; z-index: 2; min-width: 64px; background: var(--bt-elevated); font-weight: 650; }
.bt-sheet thead .bt-sheet-total { z-index: 4; }
.bt-sheet .is-weekend { background: #f2f3f5; color: var(--bt-muted); }
.bt-sheet .is-holiday { background: #eceef1; }
.bt-sheet .is-corrected { color: var(--bt-warn); }
.bt-sheet-group th { position: sticky; left: 0; text-align: left !important; background: #f4f5f7 !important; color: var(--bt-text) !important; font-size: 11px; font-weight: 650; letter-spacing: 0.04em; text-transform: uppercase; height: 24px; }
.bt-sheet-strong th, .bt-sheet-strong td { font-weight: 650; color: var(--bt-text); }
.bt-sheet-weektotal { font-weight: 650; color: var(--bt-text) !important; }
.bt-sheet-dd { display: block; font-size: 12px; color: var(--bt-text); }
.bt-sheet-wd { display: block; font-size: 10px; font-weight: 500; color: var(--bt-muted); }
.bt-sheet-week { font-size: 10px; }
.bt-sheet-edit { padding: 0 !important; background: #fbfbfc; }
.bt-cell { width: 100%; min-width: 46px; height: 25px; border: 0; background: transparent; color: var(--bt-text); text-align: right; padding: 0 6px; font: inherit; font-variant-numeric: tabular-nums; }
.bt-cell:hover { background: var(--bt-hover); }
.bt-cell:focus { outline: none; box-shadow: inset 0 0 0 1px var(--bt-text); background: #ffffff; }
.bt-cell-link { display: block; color: inherit; }
.bt-cell-link:hover { color: var(--bt-text); text-decoration: underline; }
.bt-sheet-annual th, .bt-sheet-annual td { min-width: 64px; }
.bt-holiday-grid { border-collapse: separate; border-spacing: 2px; font-size: 11px; }
.bt-holiday-grid th { color: var(--bt-muted); font-weight: 600; padding: 2px 4px; }
.bt-holiday-grid td { padding: 0; }
.bt-hg-cell { width: 24px; height: 22px; border-radius: 5px; border: 1px solid var(--bt-border); background: var(--bt-surface); color: var(--bt-text); font-weight: 700; cursor: pointer; transition: background var(--bt-fast), border-color var(--bt-fast); }
.bt-hg-weekend .bt-hg-cell { background: #f2f3f5; }
.bt-hg-cell:hover { border-color: var(--bt-accent); }
.bt-hg-cell.is-on { background: var(--bt-button); color: var(--bt-button-text); border-color: var(--bt-button); }
.bt-hg-void { background: transparent; }
.bt-closing-grid td { padding: 4px 6px; }
.bt-state-dot { display: inline-grid; place-items: center; width: 28px; height: 24px; border-radius: 6px; border: 1px solid var(--bt-border); background: var(--bt-surface); color: var(--bt-text-2); font-size: 12px; cursor: pointer; transition: border-color var(--bt-fast), transform var(--bt-fast); }
.bt-state-dot:hover { border-color: var(--bt-accent); transform: translateY(-1px); }
.bt-state-dot.is-review { color: var(--bt-info); border-color: var(--bt-border-strong); }
.bt-state-dot.is-ready { color: var(--bt-warn); border-color: #f1d3a6; }
.bt-state-dot.is-closed { color: var(--bt-ok); border-color: #b9e3cf; background: #ecf8f2; }
.bt-state-dot.is-reopened { color: var(--bt-warn); }
.bt-state-dot.is-selected { box-shadow: 0 0 0 2px var(--bt-text); }

/* ---------- Charts ---------- */
.bt-chart { width: 100%; height: auto; margin: 6px 0 4px; }
.bt-chart-axis { stroke: var(--bt-accent); stroke-dasharray: 3 4; }
.bt-chart-line { fill: none; stroke: #111214; stroke-width: 1.8; stroke-linejoin: round; stroke-dasharray: 900; stroke-dashoffset: 900; animation: bt-draw 900ms var(--bt-ease) forwards; }
.bt-chart-dot { fill: #ffffff; stroke: #35383d; stroke-width: 1; }
.bt-chart-dot-active { fill: var(--bt-text); stroke: var(--bt-text); }
.bt-chart-label { fill: var(--bt-muted); font-size: 8.5px; }

/* The sign-in page has its own scoped styles (login-titanium.css). */

/* ---------- Motion ---------- */
@keyframes bt-enter { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes bt-count { from { opacity: 0; transform: translateY(3px); filter: blur(2px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes bt-draw { to { stroke-dashoffset: 0; } }
@keyframes bt-progress { 0% { transform: translateX(-100%); } 100% { transform: translateX(300%); } }
@keyframes bt-spin { to { transform: rotate(360deg); } }
@keyframes bt-shimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
    .bt-chart-line { stroke-dashoffset: 0; }
}

/* ---------- Mobile ---------- */
@media (max-width: 640px) {
    .bt-title { font-size: 19px; }
    .bt-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .bt-pensum-row { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .bt-select-wide { min-width: 0; width: 100%; }
    .bt-toolbar > * { flex: 1 1 auto; }
    .bt-sheet .bt-sheet-label { min-width: 150px; }
    .bt-btn { min-height: 40px; }
}

/* ---------- Sidebar: the dark surface of the workspace (Black Titanium) ---------- */
.qw-global-sidebar { background: var(--bt-sidebar-gradient) !important; border-right: 1px solid var(--bt-sidebar) !important; box-shadow: none !important; color: var(--bt-sidebar-text) !important; }
.qw-sidebar-ambient { display: none !important; }
.qw-sidebar-brand { border-bottom-color: var(--bt-sidebar-border) !important; }
.qw-nav-link { color: var(--bt-sidebar-text) !important; }
.qw-nav-link:hover { color: var(--bt-sidebar-text-strong) !important; background: var(--bt-sidebar-hover); }
.qw-nav-link[aria-current='page'] { color: var(--bt-sidebar-text-strong) !important; }
.qw-nav-icon { color: var(--bt-sidebar-text) !important; }
.qw-nav-link[aria-current='page'] .qw-nav-icon, .qw-nav-link:hover .qw-nav-icon { color: var(--bt-sidebar-text-strong) !important; }
.qw-active-indicator { background: var(--bt-sidebar-active) !important; border: 0 !important; box-shadow: none !important; }
.qw-active-indicator::before { background: var(--bt-sidebar-text-strong) !important; box-shadow: none !important; }
.qw-global-sidebar .qw-nav-group-label { color: var(--bt-sidebar-category); }
[data-collapsed='true'] .qw-nav-group { border-top-color: var(--bt-sidebar-border); }
.qw-sidebar-toggle, .qw-sidebar-close { border-color: rgb(255 255 255 / 0.08) !important; background: rgb(255 255 255 / 0.03) !important; color: var(--bt-sidebar-text) !important; }
.qw-global-sidebar .qw-nav-separated { border-top-color: var(--bt-sidebar-border) !important; }

/* ---------- Workspace: one light background everywhere (owner token #F0F1F3) ---------- */
body.dashboard-shell, body.worksites-shell, body.admin-reference-shell { background: var(--bt-app) !important; }
