/* Shared business workspace: slate surfaces, brand-specific accents, action-first hierarchy. */
:root { --breite: 1440px; }
:root:not([data-theme="dunkel"]) { --paper: #eef2f6; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="hell"]) { --paper: #141b22; } }
:root[data-theme="dunkel"] { --paper: #141b22; }
.workspace-switch { display:flex; gap:4px; margin:0 0 20px; padding:5px; background:rgba(255,255,255,.06); border:1px solid rgba(255,255,255,.15); border-radius:10px; }
.workspace-switch a,.workspace-switch span { flex:1; padding:9px 5px; border-radius:6px; text-align:center; text-decoration:none; color:#c6d1db; font-size:13px; font-weight:650; }
.workspace-switch [aria-current] { background:#35424d; color:#fff; box-shadow:inset 0 -2px var(--accent); }
.workspace-switch a:hover { background:#35424d; color:#fff; }
.workspace-switch .unavailable { opacity:.55; }
.nav .nav-gruppe { text-transform:none; letter-spacing:0; font-size:11px; }
.nav a { min-height:40px; }
.main,.stage-inner { margin-inline:auto; }
.card,.fleet-card { box-shadow:none; }
.cockpit-date { color:var(--ink-soft); font-size:13px; margin:0 0 8px; }
.cockpit-head { display:flex; align-items:center; justify-content:space-between; gap:20px; margin-bottom:24px; }
.cockpit-head h1 { font-size:clamp(25px,3vw,36px); line-height:1.2; letter-spacing:-1px; margin:0 0 8px; }
.cockpit-head p { color:var(--ink-soft); margin:0; max-width:65ch; }
.cockpit-actions { display:flex; gap:8px; flex-wrap:wrap; }
.business-strip { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); background:var(--surface); border:1px solid var(--line); border-radius:14px; margin-bottom:24px; overflow:hidden; }
.business-metric { padding:22px 24px; color:var(--ink); text-decoration:none; min-width:0; border-right:1px solid var(--line); display:flex; flex-direction:column; gap:7px; }
.business-metric:last-child { border-right:0; }
a.business-metric:hover { background:var(--surface-3); }
.business-metric>span { font-size:13px; color:var(--ink-soft); }
.business-metric strong { font-size:clamp(24px,2.5vw,32px); font-weight:650; letter-spacing:-.8px; line-height:1.25; font-variant-numeric:tabular-nums; }
.business-metric small { font-size:12px; color:var(--ink-soft); line-height:1.5; }
.business-metric .negative { color:var(--rust); }
.cockpit-grid { display:grid; grid-template-columns:minmax(0,1.35fr) minmax(300px,1fr); gap:20px; margin-bottom:24px; align-items:start; }
.focus-panel { border:1px solid var(--line); border-radius:14px; background:var(--surface); overflow:hidden; min-width:0; }
.focus-heading { display:flex; justify-content:space-between; align-items:center; gap:12px; padding:19px 22px; border-bottom:1px solid var(--line-soft); }
.focus-heading h2 { margin:0; font-size:17px; letter-spacing:-.3px; }
.focus-heading a { font-size:12px; color:var(--accent-ink); }
.focus-count { border-radius:20px; background:var(--amber-soft); color:var(--amber); padding:3px 9px; font-size:12px; font-weight:650; }
.focus-row { display:flex; gap:13px; align-items:center; padding:16px 22px; border-bottom:1px solid var(--line-soft); text-decoration:none; color:var(--ink); min-width:0; }
.focus-row:last-child { border-bottom:0; }
a.focus-row:hover { background:var(--surface-3); color:var(--ink); }
.focus-row>div { flex:1; min-width:0; }
.focus-row strong { font-size:13px; font-weight:650; display:block; overflow-wrap:anywhere; }
.focus-row small { display:block; font-size:12px; color:var(--ink-soft); margin-top:3px; overflow-wrap:anywhere; }
.focus-row .row-action { font-size:12px; color:var(--accent-ink); flex-shrink:0; }
.focus-dot { width:8px; height:8px; flex:none; border-radius:50%; background:var(--amber); }
.focus-dot.danger { background:var(--rust); }
.focus-dot.ok { background:var(--moss); }
.focus-dot.neutral { background:var(--ink-faint); }
.focus-empty { padding:23px; color:var(--ink-soft); font-size:13px; line-height:1.6; }
.focus-empty strong { color:var(--ink); display:block; margin-bottom:4px; }
.connection-note { padding:12px 20px; font-size:12px; line-height:1.6; background:var(--surface-3); color:var(--ink-soft); border-top:1px solid var(--line-soft); }
.connection-note.warn { background:var(--amber-soft); color:var(--amber); }
.system-strip { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin-bottom:24px; }
.system-tile { padding:16px 18px; background:var(--surface); border:1px solid var(--line); border-radius:10px; color:var(--ink); text-decoration:none; }
.system-tile span,.system-tile small { display:block; font-size:12px; color:var(--ink-soft); }
.system-tile strong { display:block; font-size:17px; margin:6px 0; font-variant-numeric:tabular-nums; }
.system-tile[href]:hover { border-color:var(--accent); }
.cockpit-section-title { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:24px 0 14px; }
.cockpit-section-title h2 { font-size:19px; margin:0; }
.cockpit-section-title a { font-size:13px; color:var(--accent-ink); }
.cockpit-details { border:1px solid var(--line); border-radius:12px; background:var(--surface); margin:20px 0; }
.cockpit-details>summary { cursor:pointer; padding:18px 22px; font-weight:650; font-size:14px; }
.cockpit-details>.card { border:0; margin:0; }
.cockpit-filter { display:flex; align-items:end; gap:14px; padding:16px 20px; background:var(--surface); border:1px solid var(--line); border-radius:12px; margin-bottom:20px; flex-wrap:wrap; }
.cockpit-filter label { display:grid; gap:6px; font-size:12px; color:var(--ink-soft); flex:1; min-width:180px; }
.cockpit-filter input,.cockpit-filter select { min-height:42px; width:100%; }
.cockpit-filter output { font-size:13px; padding-bottom:12px; color:var(--ink-soft); }
.command-trigger { border:1px solid var(--line-hard); background:var(--surface); color:var(--ink-soft); border-radius:8px; padding:8px 12px; cursor:pointer; font:inherit; font-size:12px; }
.command-trigger kbd { margin-left:35px; font-family:inherit; }
.command-dialog { padding:0; width:min(620px,calc(100% - 32px)); max-height:75vh; border:1px solid var(--line-hard); background:var(--surface); color:var(--ink); border-radius:16px; box-shadow:var(--shadow-lg); }
.command-dialog::backdrop { background:rgba(12,24,36,.55); }
.command-head { padding:18px; border-bottom:1px solid var(--line); display:flex; gap:12px; align-items:center; }
.command-head input { flex:1; min-width:0; }
.command-head button { border:0; background:var(--surface-3); color:var(--ink); border-radius:6px; padding:9px; cursor:pointer; }
.command-results { max-height:50vh; overflow:auto; }
.command-results a:focus { outline:2px solid var(--accent); outline-offset:-3px; }
.skip-link { position:fixed; top:8px; left:8px; transform:translateY(-160%); z-index:1000; background:var(--surface); color:var(--ink); padding:12px; border:2px solid var(--accent); }
.skip-link:focus { transform:none; }
:where(a,button,input,select,summary):focus-visible { outline:2px solid var(--accent-ink); outline-offset:3px; }
@media(max-width:1100px) { .cockpit-grid { grid-template-columns:1fr; } .business-metric { padding:18px; } }
@media(max-width:600px) { .cockpit-head { align-items:start; flex-direction:column; } .business-strip { grid-template-columns:repeat(2,minmax(0,1fr)); } .business-metric:nth-child(2) { border-right:0; } .business-metric:nth-child(-n+2) { border-bottom:1px solid var(--line); } .system-strip { grid-template-columns:1fr; gap:8px; } .system-tile { padding:14px 18px; } .focus-heading,.focus-row { padding:16px; } .focus-row .row-action { display:none; } .command-trigger kbd { display:none; } .cockpit-filter label { min-width:100%; } }
@media(prefers-reduced-motion:reduce) { *,*::before,*::after { scroll-behavior:auto!important; animation:none!important; transition:none!important; } }
@media print { .workspace-switch,.cockpit-actions,.command-trigger,.skip-link { display:none!important; } .business-strip,.cockpit-grid,.focus-panel { break-inside:avoid; } }

/* Keep the working surface steady during navigation and refresh. */
.stage,.reveal { animation:none; }
.stage-inner:has(.cockpit-head) { gap:0; }
:root[data-seitenleiste="schmal"] .workspace-switch { flex-direction:column; padding:2px; }
:root[data-seitenleiste="schmal"] .workspace-switch a,:root[data-seitenleiste="schmal"] .workspace-switch span { font-size:10px; padding:8px 0; }
/* A workbench rather than a wall of cards: shared controls, readable rows, consistent hierarchy. */
.workspace-switch { margin-bottom:8px; }
.cockpit-head h1 { font-size:clamp(26px,2.4vw,34px); letter-spacing:-.8px; }
.business-metric:last-child { background:var(--accent-weich); }
.business-metric:last-child strong { color:var(--accent-ink); }
.business-metric:last-child strong.negative { color:var(--rust); }
.workspace-context { display:flex; align-items:center; gap:16px; flex-wrap:wrap; margin:-2px 0 22px; font-size:12px; color:var(--ink-soft); }
.workspace-context>a { margin-left:auto; color:var(--ink-soft); }
.scope-switch { display:flex; padding:4px; border:1px solid var(--line); border-radius:9px; background:var(--surface); gap:3px; }
.scope-switch a { padding:7px 12px; border-radius:6px; color:var(--ink-soft); text-decoration:none; font-weight:600; }
.scope-switch a[aria-current] { background:var(--brand); color:var(--on-brand); }
.focus-panel { display:flex; flex-direction:column; }
.focus-filters { display:flex; flex-wrap:wrap; gap:5px; padding:12px 16px; border-bottom:1px solid var(--line-soft); background:var(--surface-2); }
.focus-filters button { appearance:none; font:inherit; font-size:12px; border:1px solid transparent; border-radius:7px; padding:7px 9px; background:transparent; color:var(--ink-soft); cursor:pointer; min-height:34px; }
.focus-filters button[aria-pressed="true"] { background:var(--surface); border-color:var(--line-hard); color:var(--ink); font-weight:650; }
.focus-filters button:hover { color:var(--ink); border-color:var(--line-hard); }
.focus-filters button span { margin-left:4px; font-variant-numeric:tabular-nums; opacity:.75; }
.focus-row strong { font-size:14px; line-height:1.4; }
.focus-row small { line-height:1.6; }
.focus-more,.agenda-more { display:block; width:100%; text-align:left; font:inherit; font-size:12px; color:var(--accent-ink); padding:13px 22px; background:var(--surface-2); border:0; border-top:1px solid var(--line-soft); cursor:pointer; text-decoration:none; }
.focus-more:hover,.agenda-more:hover { background:var(--surface-3); }
.focus-row[hidden],.focus-more[hidden],.focus-empty[hidden],[data-agenda-view][hidden],.update-notice[hidden] { display:none!important; }
.agenda-day { font-size:12px; font-weight:650; color:var(--ink-soft); background:var(--surface-3); border:1px solid var(--line); border-radius:8px; padding:8px; flex:none; font-variant-numeric:tabular-nums; }
.agenda-day.late { color:var(--rust); background:var(--rust-soft); border-color:transparent; }
.operations-link { display:flex; gap:15px; justify-content:space-between; align-items:center; padding:20px 22px; border:1px solid var(--line); border-radius:12px; background:var(--surface); color:var(--ink-soft); text-decoration:none; margin-top:20px; font-size:13px; }
.operations-link span:first-child { display:flex; gap:12px; align-items:center; color:var(--ink); }
.operations-link svg { width:20px; height:20px; color:var(--accent-ink); }
.operations-link:hover { border-color:var(--accent); }
.fleet-context { font-size:12px; color:var(--ink-soft); margin:6px 0; }
.fleet-stats .label { text-transform:none; letter-spacing:0; }
.update-notice { display:flex; justify-content:space-between; gap:14px; align-items:center; background:var(--amber-soft); color:var(--amber); padding:12px 24px; font-size:13px; border-bottom:1px solid var(--line); }
.error-recovery { margin:40px auto; max-width:600px; text-align:center; }
.error-recovery h1 { font-size:24px; }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
@media(max-width:600px) { .workspace-context { gap:10px; } .workspace-context>a { margin-left:0; } .scope-switch a { min-height:40px; display:flex; align-items:center; } .focus-filters { padding:10px; } .focus-filters button { min-height:40px; } .focus-row { padding:14px; } .operations-link { flex-direction:column; align-items:start; } .update-notice { align-items:start; padding:12px 16px; flex-wrap:wrap; } }

.business-metric:has(.negative) { background:var(--rust-soft); }
