/* «Light Design» (Wunsch Devis 11.11.2026) – seit 16.11.2026 das Design für alle (Entscheid Devis, Apple-Stil).
   Gilt mit <html data-stil="ld">, das base.html auf jeder Cockpit-Seite setzt (nicht im Kundenbereich). Wird nach style.css und den Firmenfarben geladen.
   Regeln mit :where() haben dieselbe Spezifität wie die Originale – farbige Varianten (rot, KI …) behalten Vorrang.
   Systemfarben: Blau als Akzent, dazu Grün, Orange, Rot, Violett; neutrale Grautöne; Systemschrift. */

/* ===================== Farben ===================== */
/* Seit 16.11.2026 stehen alle Farbvariablen (hell und dunkel) zuoberst in style.css (:root,:root[data-stil]) – eine Quelle. */

/* ===================== Schrift ===================== */
:where(:root[data-stil="ld"]) body,:where(:root[data-stil="ld"]) button,:where(:root[data-stil="ld"]) input,
:where(:root[data-stil="ld"]) select,:where(:root[data-stil="ld"]) textarea{
  font-family:var(--ld-font);font-feature-settings:normal;letter-spacing:-.006em}
:where(:root[data-stil="ld"]) body{font-size:13.5px;line-height:1.45;-webkit-font-smoothing:antialiased}
:where(:root[data-stil="ld"]) h1,/* Seitentitel: jedes h1 im Inhalt ist der Seitentitel (28 px); bereichseigene Kopf-Klassen (an-kopf, ap-kopf …) mit eigener Grösse gehen vor */
:where(:root[data-stil="ld"]) main h1,:where(:root[data-stil="ld"]) .head h1{font-family:var(--ld-font-d);font-weight:700;letter-spacing:-.022em}
:where(:root[data-stil="ld"]) h2,:where(:root[data-stil="ld"]) h3{font-family:var(--ld-font-d);font-weight:600;letter-spacing:-.016em}

/* ===================== Seitenleiste (wie Finder/Einstellungen) ===================== */
:where(:root[data-stil="ld"]) .side{background:var(--side-bg);backdrop-filter:blur(30px) saturate(1.8);-webkit-backdrop-filter:blur(30px) saturate(1.8);
  border-right:1px solid var(--side-line);box-shadow:none}
:root[data-stil="ld"] .side nav button.grp{font-size:11.5px;font-weight:600;letter-spacing:0;text-transform:none;color:var(--ink3);padding:14px 10px 4px}
:root[data-stil="ld"] .side nav button.grp::before{display:none}
:root[data-stil="ld"] .side nav button.grp:hover{background:none;color:var(--ink2)}
:root[data-stil="ld"] .side nav .nav-g > button.grp .nav-griff{color:var(--ink3)}
:root[data-stil="ld"] .side nav a{gap:9px;padding:4px 8px;min-height:30px;border-radius:7px;color:var(--ink);font-weight:500;font-size:13px;box-shadow:none}
:root[data-stil="ld"] .side nav a:hover{background:var(--side-hover);color:var(--ink)}
:root[data-stil="ld"] .side nav a.on,:root[data-stil="ld"] .side nav .nav-g-in > a.on{background:var(--ld-sel);color:var(--ink);font-weight:600;box-shadow:none}
/* Symbole als farbige Kacheln mit weissem Zeichen, Farbe je Gruppe */
:root[data-stil="ld"] .side nav .nav-g{--gf:#8E8E93}
:root[data-stil="ld"] .side nav .nav-g[data-g=uebersicht]{--gf:#007AFF}
:root[data-stil="ld"] .side nav .nav-g[data-g=kommunikation]{--gf:#34C759}
:root[data-stil="ld"] .side nav .nav-g[data-g=vertrieb]{--gf:#AF52DE}
:root[data-stil="ld"] .side nav .nav-g[data-g=support]{--gf:#FF9500}
:root[data-stil="ld"] .side nav .nav-g[data-g=zeit]{--gf:#FF2D55}
:root[data-stil="ld"] .side nav .nav-g[data-g=lager]{--gf:#A2845E}
:root[data-stil="ld"] .side nav .nav-g[data-g=projekte]{--gf:#5856D6}
:root[data-stil="ld"] .side nav .nav-g[data-g=finanzen]{--gf:#30B0C7}
:root[data-stil="ld"] .side nav .nav-g[data-g=abo]{--gf:#5AC8FA}
:root[data-stil="ld"] .side nav .nav-g-in > a > .ic{flex:none;width:22px;height:22px;padding:4px;border-radius:6px;color:#fff;stroke-width:2.1;
  background:linear-gradient(180deg,color-mix(in srgb,var(--gf) 82%,#fff),var(--gf));box-shadow:inset 0 0 0 .5px rgba(0,0,0,.08)}
:root[data-stil="ld"] .side nav a .badge{background:var(--sys-rot);min-width:18px;height:18px;font-size:11px;font-weight:600}
:root[data-stil="ld"] .nav-sub{border-left:0;margin-left:26px!important}
:root[data-stil="ld"] .nav-sub a{color:var(--ink2)}
:root[data-stil="ld"] .nav-sub a.on{background:var(--ld-sel)!important;color:var(--ink)!important}
:where(:root[data-stil="ld"]) .me{border-top-color:var(--side-line)}

/* ===================== Kopfzeile ===================== */
:root[data-stil="ld"] .topbar{background:color-mix(in srgb,var(--surface) 78%,transparent);backdrop-filter:blur(24px) saturate(1.8);
  -webkit-backdrop-filter:blur(24px) saturate(1.8);border-bottom:1px solid var(--line);box-shadow:none}
:where(:root[data-stil="ld"]) .crumb b{font-size:14px;font-weight:600}
:where(:root[data-stil="ld"]) .crumb small{font-size:11.5px}

/* =====================================================================================================================
   APPLE-BASIS: massgebende Bausteine (Basis-Agent 16.11.2026). Je Baustein gilt GENAU diese Definition.
   Massstab und Anleitung: docs/gestaltung/apple-stil.md (Abschnitt 3 und «Für die Bereichs-Agenten»).
   - Alte Klassen (.btn, .card, table.list, .pill, Felder …) sind mit :where(:root[data-stil="ld"]) gefasst: gleiche
     Spezifität wie das Original, aber nach style.css und den Firmenfarben geladen – bereichseigene Varianten behalten Vorrang.
   - Neue Klassen (.a-*, .ios-sw) gelten überall, auch im Kundenbereich.
   - Nur Variablen aus style.css (Kopf), keine Hex-Werte, kein neues !important.
   ===================================================================================================================== */

/* ---------- Seitenkopf: grosser Titel links, Knöpfe rechts (Makro seitenkopf() in _seite.html) ---------- */
:where(:root[data-stil="ld"]) .head{display:flex;justify-content:space-between;align-items:center;gap:10px 16px;flex-wrap:wrap;margin:0 0 18px}
/* Seitentitel: jedes h1 im Inhalt ist der Seitentitel (28 px); bereichseigene Kopf-Klassen (an-kopf, ap-kopf …) mit eigener Grösse gehen vor */
:where(:root[data-stil="ld"]) main h1,:where(:root[data-stil="ld"]) .head h1{font-family:var(--ld-font-d);font-size:28px;line-height:1.15;font-weight:700;letter-spacing:-.022em;margin:0;
  color:var(--ink);background:none;-webkit-text-fill-color:currentColor}
:where(:root[data-stil="ld"]) .head > div:first-child p.info-box{margin:8px 0 0}
.a-kopf-text{min-width:0;flex:1 1 360px}
.a-kopf-unter{margin:4px 0 0;color:var(--ink2);font-size:13.5px}
.a-kopf-knoepfe{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin-left:auto;padding-top:2px}
.cardhead .a-kopf-knoepfe{padding-top:0}

/* ---------- Knöpfe: primär (.btn), sekundär (.btn.ghost), Text (.btn.text), Gefahr (.btn.rot), KI (.btn.ki), klein (.sm) ---------- */
:where(:root[data-stil="ld"]) .btn{border:0;border-radius:var(--r-knopf);background:var(--akzent);color:#fff;font-weight:500;box-shadow:none;text-decoration:none}
:where(:root[data-stil="ld"]) .btn:hover{background:var(--akzent-h);color:#fff}
:where(:root[data-stil="ld"]) .btn:active:not(:disabled){filter:brightness(.92)}
:where(:root[data-stil="ld"]) .btn:disabled,:where(:root[data-stil="ld"]) .btn[aria-disabled=true]{opacity:.45;cursor:default}
:where(:root[data-stil="ld"]) .btn.sm{border-radius:7px}
:where(:root[data-stil="ld"]) .btn.ghost{background:var(--ld-fill);color:var(--ink);border:0;box-shadow:none}
:where(:root[data-stil="ld"]) .btn.ghost:hover{background:var(--ld-fill2);color:var(--ink);border:0}
:where(:root[data-stil="ld"]) .btn.text,:where(:root[data-stil="ld"]) .btn.ghost.text{background:none;color:var(--teal-d);padding:0 8px;box-shadow:none;border:0}
:where(:root[data-stil="ld"]) .btn.text:hover{background:color-mix(in srgb,var(--akzent) 8%,transparent);color:var(--teal-d)}
:where(:root[data-stil="ld"]) .btn.rot,:where(:root[data-stil="ld"]) .btn.rec{background:var(--ld-fill);border:0;color:var(--crit)!important}
:where(:root[data-stil="ld"]) .btn.rot:hover,:where(:root[data-stil="ld"]) .btn.rec:hover{background:var(--crit);color:#fff!important}
:where(:root[data-stil="ld"]) .iconbtn{border-radius:7px}
:where(:root[data-stil="ld"]) .iconbtn:hover{background:var(--ld-fill);color:var(--ink)}
:where(:root[data-stil="ld"]) :is(.btn,.iconbtn,a,button,summary):focus-visible{outline:none;box-shadow:0 0 0 3px var(--ld-ring)}

/* ---------- Segment (.a-seg) – statt Reitern, Pillen-Reihen, Tab-Leisten ---------- */
.a-seg{display:inline-flex;align-items:stretch;flex-wrap:wrap;gap:0;row-gap:2px;padding:2px;border-radius:9px;background:var(--ld-fill);max-width:100%;margin:0}
.a-seg>label,.a-seg>a,.a-seg>button{position:relative;display:inline-flex;align-items:center;justify-content:center;gap:6px;margin:0;cursor:pointer}
.a-seg input{position:absolute;opacity:0;pointer-events:none}
.a-seg>label>span,.a-seg>a,.a-seg>button{padding:5px 14px;border-radius:7px;font:inherit;font-size:13px;font-weight:500;line-height:20px;color:var(--ink);background:none;
  border:0;text-decoration:none;white-space:nowrap;transition:background .15s,box-shadow .15s}
.a-seg>label>span{display:inline-flex;align-items:center;gap:6px;width:100%;justify-content:center}
.a-seg>a:hover,.a-seg>button:hover,.a-seg>label:hover>span{background:color-mix(in srgb,var(--ink) 5%,transparent)}
.a-seg>label input:checked+span,.a-seg>a.on,.a-seg>button.on,.a-seg>a[aria-selected=true],.a-seg>a[aria-current=page]{background:var(--surface);color:var(--ink);font-weight:600;
  box-shadow:0 1px 3px rgba(0,0,0,.12),0 0 0 .5px rgba(0,0,0,.04)}
:root[data-theme="dark"] :is(.a-seg>label input:checked+span,.a-seg>a.on,.a-seg>button.on,.a-seg>a[aria-selected=true],.a-seg>a[aria-current=page]){background:#636366;color:#fff}
.a-seg>label input:focus-visible+span{outline:2px solid var(--akzent);outline-offset:1px}
.a-seg :is(a,button,span)>b{display:inline-grid;place-items:center;min-width:18px;height:18px;padding:0 6px;border-radius:99px;background:var(--grau-s);color:var(--ink2);
  font-size:11px;font-weight:600;line-height:18px}
.a-seg .ic{width:15px;height:15px}
.a-seg-voll{display:flex}.a-seg-voll>label,.a-seg-voll>a,.a-seg-voll>button{flex:1}
@media(max-width:760px){.a-seg{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none}}

/* ---------- Schalter (.ios-sw) – Ein/Aus; an = Grün ---------- */
.ios-sw{position:relative;display:inline-block;width:42px;height:26px;flex:none;vertical-align:middle}
.ios-sw input{position:absolute;inset:0;width:100%;height:100%;opacity:0;margin:0;cursor:pointer;z-index:1}
.ios-sw i{position:absolute;inset:0;border-radius:99px;background:var(--ld-fill2);transition:background .2s}
.ios-sw i::after{content:"";position:absolute;top:2px;left:2px;width:22px;height:22px;border-radius:50%;background:#fff;box-shadow:0 2px 5px rgba(0,0,0,.2);transition:transform .2s}
.ios-sw input:checked+i{background:var(--green)}.ios-sw input:checked+i::after{transform:translateX(16px)}
.ios-sw input:disabled+i{opacity:.5}
.ios-sw input:focus-visible+i{outline:2px solid var(--akzent);outline-offset:2px}

/* ---------- Gruppierte Liste (.a-gruppe / .a-zeile) – Einstellungen, Listen mit Wert und Chevron ---------- */
.a-gruppe-titel{font-size:13px;font-weight:600;color:var(--ink2);margin:22px 4px 7px;text-transform:none;letter-spacing:0}
.a-gruppe-titel:first-child{margin-top:0}
.a-gruppe{background:var(--surface);border-radius:var(--r);box-shadow:var(--karte-schatten);overflow:hidden;margin:0}
.a-gruppe>*+*{border-top:.5px solid var(--haar)}
/* .a-gruppe.eingerueckt: Haarlinie erst ab dem Text (Zeilen mit Symbolkachel), wie iOS-Einstellungen */
.a-gruppe.eingerueckt>*+*{border-top:0;background:linear-gradient(var(--haar),var(--haar)) 56px 0/calc(100% - 56px) .5px no-repeat}
/* .a-gruppe>.a-zeile (Spezifität 0,2,0) schlägt Formular-Regeln wie «.formgrid label{flex-direction:column}» ohne !important */
.a-zeile,.a-gruppe>.a-zeile{display:flex;flex-direction:row;align-items:center;justify-content:space-between;gap:12px;min-height:44px;padding:10px 14px;box-sizing:border-box;
  font-size:13.5px;color:var(--ink);text-decoration:none}
/* Hintergrund nur mit Spezifität 0,1,0, damit die eingerückte Haarlinie (.a-gruppe.eingerueckt>*+*) bleibt (17.11.2026) */
.a-zeile{background:none}
.a-gruppe.eingerueckt>a.a-zeile:hover,.a-gruppe.eingerueckt>button.a-zeile:hover{background:var(--hover)}
a.a-zeile,button.a-zeile,label.a-zeile{cursor:pointer}
a.a-zeile:hover,button.a-zeile:hover{background:var(--hover);color:var(--ink)}
button.a-zeile{width:100%;border:0;font:inherit;text-align:left}
.a-zeile>span:first-child{display:flex;align-items:center;gap:12px;min-width:0;flex:0 1 auto}
.a-zeile b{font-size:14px;font-weight:500;color:var(--ink)}
.a-zeile small{display:block;font-size:12.5px;color:var(--ink3);margin-top:1px}
.a-zeile .a-wert{margin-left:auto;color:var(--ink2);text-align:right;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.a-zeile .a-chev{flex:none;width:14px;height:14px;color:var(--grau3)}
.a-zeile .ik{flex:none}
.ik.ik-zeile{width:30px;height:30px;border-radius:7px}.ik.ik-zeile .ic{width:18px;height:18px}
.a-zeile input:not([type=checkbox]):not([type=radio]),.a-zeile select{border:0;background:none;font:inherit;color:var(--teal-d);text-align:right;padding:0;min-width:0;box-shadow:none}
.a-gruppe textarea{display:block;width:100%;box-sizing:border-box;border:0;background:none;padding:12px 14px;font:inherit;font-size:13.5px;line-height:1.5;resize:vertical;color:var(--ink);outline:none;box-shadow:none}
.a-fuss{margin:7px 14px 0;font-size:12.5px;line-height:1.45;color:var(--ink3)}
:root[data-theme="dark"] .a-gruppe{background:var(--surface)}

/* ---------- Karte (.card + .cardhead) – ohne Rahmen, Hauch Schatten ---------- */
:where(:root[data-stil="ld"]) .card{background:var(--surface);border:0;border-radius:var(--r);box-shadow:var(--karte-schatten)}
:where(:root[data-stil="ld"]) .cardhead h2,:where(:root[data-stil="ld"]) .card>h2{font-family:var(--ld-font-d);font-size:17px;font-weight:600;letter-spacing:-.01em;margin:0}
:where(:root[data-stil="ld"]) .cardhead>:last-child:not(:first-child){margin-left:auto}
:where(:root[data-stil="ld"]) .kpi{border:0;border-radius:var(--r);box-shadow:var(--karte-schatten);background:var(--surface)}
:where(:root[data-stil="ld"]) .kpi .lbl{font-size:12px;font-weight:500;letter-spacing:0;text-transform:none;color:var(--ink3)}
:where(:root[data-stil="ld"]) .kpi .v{font-size:24px;font-weight:600;letter-spacing:-.01em;font-variant-numeric:tabular-nums}
:where(:root[data-stil="ld"]) .auf-kachel{border:0;border-radius:12px;box-shadow:var(--karte-schatten)}
:where(:root[data-stil="ld"]) .auf-kachel .ak-ico{border-radius:9px}
:where(:root[data-stil="ld"]) .auf-kachel.aktiv .ak-ico{background:var(--ak);color:#fff}

/* ---------- Tabelle (table.list) – ohne Rahmen, Kopf ohne Fläche, Haarlinien ---------- */
:where(:root[data-stil="ld"]) table.list{border:0;border-radius:var(--r);box-shadow:var(--karte-schatten);background:var(--surface)}
:where(:root[data-stil="ld"]) .card table.list{border-radius:0;box-shadow:none;background:none}
:where(:root[data-stil="ld"]) table.list thead th,:where(:root[data-stil="ld"]) .list th{background:none;color:var(--ink3);font-size:12px;font-weight:500;
  text-transform:none;letter-spacing:0;border:0;border-bottom:.5px solid var(--haar)}
:where(:root[data-stil="ld"]) table.list td{border:0;border-bottom:.5px solid color-mix(in srgb,var(--ink) 10%,transparent)}
:where(:root[data-stil="ld"]) table.list tbody tr:last-child td{border-bottom:0}
:where(:root[data-stil="ld"]) table.list tbody tr:hover td{background:color-mix(in srgb,var(--ink) 3%,transparent)}
:where(:root[data-stil="ld"]) table.list td.r,:where(:root[data-stil="ld"]) table.list th.r{font-variant-numeric:tabular-nums}
th .sort-ic{width:11px;height:11px;margin-left:3px;vertical-align:-1px;color:var(--ink3)}

/* ---------- Formularfelder – grau gefüllt, ohne Rahmen; Fokus weiss mit Ring ---------- */
:where(:root[data-stil="ld"]) input:where(:not([type=checkbox],[type=radio],[type=range],[type=color],[type=file])),
:where(:root[data-stil="ld"]) select,:where(:root[data-stil="ld"]) textarea{
  background-color:var(--feld);border:1px solid transparent;border-radius:var(--r-feld);box-shadow:none;color:var(--ink)}
:where(:root[data-stil="ld"]) input:where(:not([type=checkbox],[type=radio])):hover,:where(:root[data-stil="ld"]) select:hover,
:where(:root[data-stil="ld"]) textarea:hover{background-color:color-mix(in srgb,var(--ink) 8%,var(--surface))}
:where(:root[data-stil="ld"]) input:where(:not([type=checkbox],[type=radio])):focus,:where(:root[data-stil="ld"]) select:focus,
:where(:root[data-stil="ld"]) textarea:focus{background-color:var(--surface);border-color:color-mix(in srgb,var(--akzent) 55%,transparent);box-shadow:0 0 0 3px var(--ld-ring);outline:none}
:where(:root[data-stil="ld"]) input[type=checkbox],:where(:root[data-stil="ld"]) input[type=radio]{accent-color:var(--akzent)}
:where(:root[data-stil="ld"]) ::placeholder{color:var(--ink3)}
.a-feld{display:flex;flex-direction:column;gap:5px;font-size:12.5px;color:var(--ink2)}
.a-feld>span{font-weight:500}
.a-datei input[type=file]{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}

/* ---------- Dialog / Blatt (.kal-dialog bzw. .a-blatt) – Kopf mit Titel links und Schliessen rechts, Fuss mit Knöpfen rechts ---------- */
:where(:root[data-stil="ld"]) dialog{border-radius:14px}
:where(:root[data-stil="ld"]) dialog::backdrop{background:rgba(0,0,0,.22);backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px)}
:where(:root[data-stil="ld"]) dialog.kal-dialog,dialog.a-blatt{border:0;border-radius:var(--r-dialog);box-shadow:0 0 0 .5px rgba(0,0,0,.12),0 24px 60px -12px rgba(0,0,0,.35)}
dialog.a-blatt{width:min(600px,94vw);padding:0;background:var(--surface2);color:var(--ink)}
.a-blatt-kopf,:where(:root[data-stil="ld"]) .kal-dialog .kd-kopf{display:flex;align-items:center;gap:10px}
.a-blatt-kopf{padding:16px 20px 10px}
.a-blatt-kopf h2,:where(:root[data-stil="ld"]) .kal-dialog .kd-kopf h2{font-size:17px;font-weight:600;letter-spacing:-.01em;margin:0;flex:1;min-width:0}
.a-blatt-kopf .iconbtn:last-child{margin-left:auto}
.a-blatt-titel{flex:1;min-width:0}.a-blatt-unter{margin:2px 0 0;font-size:12.5px;color:var(--ink3)}
.a-blatt-inhalt{padding:4px 20px 12px;display:flex;flex-direction:column;gap:10px}
/* Felder im Blatt heben sich vom grauen Blattgrund ab: hell weiss, dunkel eine Stufe heller (17.11.2026) */
.a-blatt-inhalt :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]),select,textarea):not(.a-gruppe *){background:var(--surface)}
:root[data-theme="dark"] .a-blatt-inhalt :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]),select,textarea):not(.a-gruppe *){background:var(--surface2)}
.a-blatt-fuss,:where(:root[data-stil="ld"]) .kal-dialog .kd-fuss{display:flex;justify-content:flex-end;align-items:center;gap:8px;flex-wrap:wrap}
.a-blatt-fuss{padding:10px 20px 18px}
:root[data-theme="dark"] dialog.a-blatt{background:var(--surface)}

/* ---------- Meldungen (.a-meldung ok|info|warn|fehler) – getönt, mit Symbol, ohne Rahmen ---------- */
.a-meldung,.rd-msg,.fm-dlg-warn{display:flex;align-items:flex-start;gap:9px;margin:0 0 14px;padding:10px 14px;border:0;border-radius:var(--r);
  font-size:13.5px;line-height:1.45;font-weight:400;background:var(--grau-s);color:var(--ink)}
.a-meldung>.ic{flex:none;width:17px;height:17px;margin-top:1px}
.a-meldung.ok,.rd-msg.ok,div.kal-meldung.ok,.mkf-ok{background:var(--green-s);color:var(--ink);border:0}
.a-meldung.info{background:var(--blue-s);color:var(--ink)}
.a-meldung.warn,.rd-msg.warn,div.kal-meldung.warn,.fm-dlg-warn{background:var(--amber-s);color:var(--ink);border:0}
.a-meldung.fehler,.rd-msg.fehl,div.kal-meldung.err{background:var(--crit-s);color:var(--ink);border:0}
.a-meldung.ok>.ic{color:var(--green)}.a-meldung.info>.ic{color:var(--akzent)}.a-meldung.warn>.ic{color:var(--amber)}.a-meldung.fehler>.ic{color:var(--crit)}
.a-meldung a,.rd-msg a,div.kal-meldung a{font-weight:600}
div.kal-meldung,.mkf-ok{display:block;margin:0 0 14px;padding:10px 14px;border:0;border-radius:var(--r);font-size:13.5px;line-height:1.45;font-weight:400;background:var(--grau-s);color:var(--ink)}
div.kal-meldung:is(.ok,.warn,.err),.mkf-ok{position:relative;padding-left:38px}
div.kal-meldung:is(.ok,.warn,.err)::before,.mkf-ok::before{position:absolute;left:13px;top:11px}
/* Übergang: alte Meldungen schreiben «✓ <span>…</span>» – das Zeichen wird ausgeblendet und durch das Symbol ersetzt */
.rd-msg{font-size:0}.rd-msg>*{font-size:13.5px}
.rd-msg::before,div.kal-meldung:is(.ok,.warn,.err)::before,.mkf-ok::before{content:"";flex:none;width:17px;height:17px;margin-top:1px;background:var(--akzent);
  -webkit-mask:var(--ic-info) center/contain no-repeat;mask:var(--ic-info) center/contain no-repeat}
:is(.rd-msg.ok,div.kal-meldung.ok,.mkf-ok)::before{background:var(--green);-webkit-mask-image:var(--ic-check-circle);mask-image:var(--ic-check-circle)}
:is(.rd-msg.warn,div.kal-meldung.warn)::before{background:var(--amber);-webkit-mask-image:var(--ic-alert);mask-image:var(--ic-alert)}
:is(.rd-msg.fehl,div.kal-meldung.err)::before{background:var(--crit);-webkit-mask-image:var(--ic-alert);mask-image:var(--ic-alert)}
.fm-dlg-warn>.ic{flex:none;width:17px;height:17px;color:var(--amber);margin-top:1px}
/* Info-Feld (p.info-box) mit blauem i – Masken-Grafik zentral */
p.info-box::before{-webkit-mask-image:var(--ic-info);mask-image:var(--ic-info)}

/* ---------- Status-Pillen (.pill ok|warn|rot|blau|grau|ki) – getönte Kapsel ohne Punkt und Rahmen ---------- */
:where(:root[data-stil="ld"]) .pill{display:inline-flex;align-items:center;gap:4px;padding:2px 9px;border:0;border-radius:999px;font-size:12px;font-weight:500;line-height:1.5;
  background:var(--grau-s);color:var(--grau-t);white-space:nowrap}
:where(:root[data-stil="ld"]) :is(.pill.ok,.pill.gruen,.pill.active){background:var(--green-s);color:var(--green-t)}
:where(:root[data-stil="ld"]) :is(.pill.warn,.pill.orange,.pill.pending,.pill.suspended){background:var(--amber-s);color:var(--amber-t)}
:where(:root[data-stil="ld"]) :is(.pill.rot,.pill.fehler,.pill.terminated,.pill.cancelled,.pill.closed,.pill.fraud,.pill.inactive){background:var(--crit-s);color:var(--crit-t)}
:where(:root[data-stil="ld"]) :is(.pill.blau,.pill.info){background:var(--blue-s);color:var(--blue-t)}
:where(:root[data-stil="ld"]) .pill.grau{background:var(--grau-s);color:var(--grau-t)}
:where(:root[data-stil="ld"]) .pill.ki{background:var(--ki-s);color:var(--ki-t)}
:where(:root[data-stil="ld"]) .chip{border-radius:99px}
:where(:root[data-stil="ld"]) .badge{background:var(--sys-rot)}
.badge-kunde,.badge-lead{display:inline-flex;align-items:center;padding:1px 8px;border-radius:999px;font-size:11.5px;font-weight:500;line-height:1.5;white-space:nowrap}
.badge-kunde{background:var(--green-s);color:var(--green-t)}.badge-lead{background:var(--blue-s);color:var(--blue-t)}
.badge-kunde .art-punkt,.badge-lead .art-punkt{display:none}
/* Buchstaben-Avatar: grau wie Apple-Kontakte (Personenfoto liegt darüber) */
:where(:root[data-stil="ld"]) .avatar{background:linear-gradient(180deg,var(--grau2),var(--grau));color:#fff}

/* ---------- Leerer Zustand (.a-leer) ---------- */
.a-leer{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;padding:28px 16px;text-align:center;color:var(--ink3);font-size:13.5px}
.a-leer-ic{display:grid;place-items:center;width:44px;height:44px;border-radius:50%;background:var(--grau-s);color:var(--ink3)}
.a-leer-ic .ic{width:22px;height:22px}
.a-leer b{color:var(--ink);font-weight:600;font-size:14px}
.a-leer p{margin:0;max-width:420px}

/* ---------- KI-Bereich (.ki-bereich) – weiss mit Verlaufsrahmen; Rahmen/Felder über die Sammelregel in style.css ---------- */
.ki-bereich{padding:14px 16px;margin-bottom:16px}
.ki-kopf{display:flex;align-items:center;gap:10px;margin-bottom:8px}
.ki-kopf b{background:var(--ki-verlauf);-webkit-background-clip:text;background-clip:text;color:transparent;font-weight:700;font-size:14.5px}
.ki-ic{flex:none;width:26px;height:26px;border-radius:8px;display:grid;place-items:center;background:var(--ki-verlauf);color:#fff}
.ki-ic .ic{width:15px;height:15px}
.ki-hilfe{margin-left:auto;font-size:12px;color:var(--ink3)}

/* ---------- Symbol-Grössen für Zeichen-Ersatz in der Kopfleiste und in Grundteilen ---------- */
.ic-text{width:1em;height:1em;vertical-align:-.12em}
.nav-chev .ic,.nav-sub-tgl .ic{width:12px;height:12px;stroke-width:2.2}
.nav-griff .ic{width:12px;height:14px}
.fm-pfeil .ic{width:14px;height:14px}
.fm-ok .ic{width:16px;height:16px;color:var(--akzent);stroke-width:2.4}
.ki-suche-ic{display:inline-grid;place-items:center}.ki-suche-ic .ic{width:15px;height:15px;color:var(--ki)}
.ks-ic{background:var(--ki-verlauf);color:#fff}.ks-ic .ic{width:20px;height:20px}
.tc-tasse-ic .ic{width:1em;height:1em}
.kk-such .ic{width:16px;height:16px;color:var(--ink3)}
.kk-kopf .iconbtn .ic{width:16px;height:16px}
.dv-monat .iconbtn .ic{width:16px;height:16px}
.ltl-nur{display:flex;align-items:center;justify-content:center;gap:6px}.ltl-nur .ic{width:14px;height:14px}
.cpf-btn{display:inline-grid;place-items:center}.cpf-btn .ic{width:15px;height:15px}
.cpf-link .ic{width:12px;height:12px;vertical-align:-2px}
.abl-menu button{display:flex;align-items:center;gap:8px}.abl-menu button .ic,.abl-o>span .ic{width:16px;height:16px;color:var(--ink2)}
.abl-auf{display:inline-grid;place-items:center}.abl-auf .ic{width:13px;height:13px}
.nl-chip button{display:inline-grid;place-items:center}.nl-chip button .ic{width:12px;height:12px}
.da-anh button .ic,.rt-bildleiste button .ic{width:14px;height:14px;vertical-align:-2px}
.ds-abgelaufen .ic{width:16px;height:16px;vertical-align:-3px}
.sz-pdf-k .btn .ic{width:13px;height:13px}
.ks-ki-kopf .ic{width:15px;height:15px;color:var(--ki);vertical-align:-2px}
/* Format-Leiste: Symbolknöpfe in einer grauen Spur */
:where(:root[data-stil="ld"]) .fmt-leiste{display:inline-flex;align-items:center;gap:2px;padding:2px;border-radius:9px;background:var(--ld-fill)}
:where(:root[data-stil="ld"]) .fmt-leiste button{display:inline-flex;align-items:center;justify-content:center;gap:4px;min-width:30px;height:28px;padding:0 7px;border:0;border-radius:7px;background:none;color:var(--ink)}
:where(:root[data-stil="ld"]) .fmt-leiste button:hover{background:var(--surface);color:var(--ink)}
:where(:root[data-stil="ld"]) .fmt-leiste button .ic{width:16px;height:16px}
:where(:root[data-stil="ld"]) .fmt-leiste .fmt-ki>button{color:var(--ki-t)}

/* ===================== Mail ===================== */
:root[data-stil="ld"] .mail-app .ml-z.gekennzeichnet:not(.on):not(.markiert){background:color-mix(in srgb,var(--amber) 16%,transparent)}
:root[data-stil="ld"] .mail-app .ml-z.gekennzeichnet:not(.on):not(.markiert):hover{background:color-mix(in srgb,var(--amber) 24%,transparent)}

/* ===================== Bildlaufleisten ===================== */
:where(:root[data-stil="ld"]) *{scrollbar-width:thin;scrollbar-color:color-mix(in srgb,var(--ink) 22%,transparent) transparent}

/* ===================== Beschriftungen ohne Grossbuchstaben (automatisch aus style.css erzeugt) ===================== */
:where(:root[data-stil="ld"]) #k-mahnwesen .kn2-h,
:where(:root[data-stil="ld"]) .ab-grp,
:where(:root[data-stil="ld"]) .ab-kat-gn,
:where(:root[data-stil="ld"]) .ab-s-liste.als-liste .ab-s-kopfzeile,
:where(:root[data-stil="ld"]) .abk-th,
:where(:root[data-stil="ld"]) .abp-kpi small,
:where(:root[data-stil="ld"]) .abp-thead,
:where(:root[data-stil="ld"]) .af-karte h3,
:where(:root[data-stil="ld"]) .ag-3l,
:where(:root[data-stil="ld"]) .ag-k-zahlen label,
:where(:root[data-stil="ld"]) .ag-th,
:where(:root[data-stil="ld"]) .ak-grid h3,
:where(:root[data-stil="ld"]) .akk-zahlen small,
:where(:root[data-stil="ld"]) .an-ki-prio,
:where(:root[data-stil="ld"]) .anh-art,
:where(:root[data-stil="ld"]) .auf-dl dt,
:where(:root[data-stil="ld"]) .auf-kachel .ak-l,
:where(:root[data-stil="ld"]) .brand .app,
:where(:root[data-stil="ld"]) .cp-trenner,
:where(:root[data-stil="ld"]) .dk-tag,
:where(:root[data-stil="ld"]) .dm-grp,
:where(:root[data-stil="ld"]) .dt-neu-b,
:where(:root[data-stil="ld"]) .dv-kal-tage span,
:where(:root[data-stil="ld"]) .dv-s-datum small,
:where(:root[data-stil="ld"]) .dv-sp-kopf,
:where(:root[data-stil="ld"]) .ev-datum small,
:where(:root[data-stil="ld"]) .ew-art,
:where(:root[data-stil="ld"]) .ew-trenn,
:where(:root[data-stil="ld"]) .fm-txt small,
:where(:root[data-stil="ld"]) .grp,
:where(:root[data-stil="ld"]) .ka-tag,
:where(:root[data-stil="ld"]) .kb-ab h3,
:where(:root[data-stil="ld"]) .kk-titel,
:where(:root[data-stil="ld"]) .kn2-gruppe,
:where(:root[data-stil="ld"]) .kn2-h,
:where(:root[data-stil="ld"]) .kn2-ztitel,
:where(:root[data-stil="ld"]) .kp-h,
:where(:root[data-stil="ld"]) .kp-kachel small,
:where(:root[data-stil="ld"]) .kp-optgruppe,
:where(:root[data-stil="ld"]) .kpi .lbl,
:where(:root[data-stil="ld"]) .kpi>small,
:where(:root[data-stil="ld"]) .ks-kopf small,
:where(:root[data-stil="ld"]) .ks-titel,
:where(:root[data-stil="ld"]) .kst legend,
:where(:root[data-stil="ld"]) .la-teil h4,
:where(:root[data-stil="ld"]) .lb-kopf,
:where(:root[data-stil="ld"]) .lb-z .lb-art,
:where(:root[data-stil="ld"]) .lg-ueb-l,
:where(:root[data-stil="ld"]) .lga-gruppe>h3,
:where(:root[data-stil="ld"]) .lga-kacheln small,
:where(:root[data-stil="ld"]) .lga-rechts h3,
:where(:root[data-stil="ld"]) .list th,
:where(:root[data-stil="ld"]) .ltl-claim,
:where(:root[data-stil="ld"]) .mg-hinweis em,
:where(:root[data-stil="ld"]) .mkf-titel,
:where(:root[data-stil="ld"]) .mo-grp,
:where(:root[data-stil="ld"]) .msf-gruppe legend,
:where(:root[data-stil="ld"]) .nl-chips-gr,
:where(:root[data-stil="ld"]) .nl-w-titel,
:where(:root[data-stil="ld"]) .nlx-kicker,
:where(:root[data-stil="ld"]) .ns-trenn,
:where(:root[data-stil="ld"]) .oder,
:where(:root[data-stil="ld"]) .of-stand-lab,
:where(:root[data-stil="ld"]) .ok-zahlen small,
:where(:root[data-stil="ld"]) .pk-spalten small,
:where(:root[data-stil="ld"]) .pk-vorschlag small,
:where(:root[data-stil="ld"]) .pm-wl-titel,
:where(:root[data-stil="ld"]) .pmg-lkopf,
:where(:root[data-stil="ld"]) .pmk-ph,
:where(:root[data-stil="ld"]) .pmt-kopfz,
:where(:root[data-stil="ld"]) .pmt-kz small,
:where(:root[data-stil="ld"]) .pmu-gruppe,
:where(:root[data-stil="ld"]) .pmu-kopfz,
:where(:root[data-stil="ld"]) .pmu-sp h4,
:where(:root[data-stil="ld"]) .pmv-karte .pmv-tasks h4,
:where(:root[data-stil="ld"]) .pmv-tasks h4,
:where(:root[data-stil="ld"]) .pv-upg-t,
:where(:root[data-stil="ld"]) .pw-form h3,
:where(:root[data-stil="ld"]) .pz-t,
:where(:root[data-stil="ld"]) .re-k .re-l,
:where(:root[data-stil="ld"]) .rh-art,
:where(:root[data-stil="ld"]) .rh-betrag small,
:where(:root[data-stil="ld"]) .rh-fakten small,
:where(:root[data-stil="ld"]) .rh-st,
:where(:root[data-stil="ld"]) .rp-k small,
:where(:root[data-stil="ld"]) .rr-tab tr.rr-bereich th,
:where(:root[data-stil="ld"]) .rz-k small,
:where(:root[data-stil="ld"]) .side nav button.grp,
:where(:root[data-stil="ld"]) .sr-g,
:where(:root[data-stil="ld"]) .szk-wt,
:where(:root[data-stil="ld"]) .szt-k small,
:where(:root[data-stil="ld"]) .tel-pk-k,
:where(:root[data-stil="ld"]) .tel-tag,
:where(:root[data-stil="ld"]) .tg-kopf,
:where(:root[data-stil="ld"]) .th-pik-morgen small,
:where(:root[data-stil="ld"]) .th-pik-t small,
:where(:root[data-stil="ld"]) .tkn-block h2,
:where(:root[data-stil="ld"]) .tl2 thead th,
:where(:root[data-stil="ld"]) .tl2-prio,
:where(:root[data-stil="ld"]) .tp-heute small,
:where(:root[data-stil="ld"]) .tv-kopf,
:where(:root[data-stil="ld"]) .tw-feld>span,
:where(:root[data-stil="ld"]) .tw-h3,
:where(:root[data-stil="ld"]) .tw-opt label>span:first-child,
:where(:root[data-stil="ld"]) .tw-rolle,
:where(:root[data-stil="ld"]) .tz2-titel,
:where(:root[data-stil="ld"]) .vm-g,
:where(:root[data-stil="ld"]) .zi-fakten dt,
:where(:root[data-stil="ld"]) .zs-zahlen small,
:where(:root[data-stil="ld"]) .zt-km-total small,
:where(:root[data-stil="ld"]) .zt-sek h3,
:where(:root[data-stil="ld"]) .ztk-zahl small,
:where(:root[data-stil="ld"]) .zw-kz small{text-transform:none;letter-spacing:0}
/* Platz für den Aufklapp-Pfeil (Tickets, Rechnungen) auch im hellen Stil – sonst lag der Pfeil im Zähler (16.11.2026) */
:root[data-stil="ld"] .side nav .nav-g-in>a{padding-right:30px}
:root[data-stil="ld"] .side nav .nav-g-in>a .nav-sub-tgl{right:6px}
