/* MailArchivBox · Gestaltungssystem
   Navy #0B1F3A · Siegelrot #A4243B · Siegelgold #e0a83b (sparsam)

   Dieselbe Identität wie die Produktseite und mann-it.de: Navy und helles
   Grau als Grundton, Poppins als Schrift, Siegelrot als Akzent. Wer sich
   von der Produktseite aus anmeldet, soll nicht in einem anderen Programm
   zu landen glauben. */

/* ------------------------------------------------------------------ Farben */
:root {
  --marke: #0B1F3A;
  --marke-2: #162D4F;
  --gold: #e0a83b;
  --akzent-basis: #A4243B;
  --akzent: var(--akzent-basis);
  --akzent-stark: color-mix(in oklab, var(--akzent) 84%, black);
  --akzent-weich: color-mix(in oklab, var(--akzent) 9%, transparent);
  --akzent-weich-2: color-mix(in oklab, var(--akzent) 15%, transparent);
  --akzent-linie: color-mix(in oklab, var(--akzent) 35%, transparent);
  --auf-akzent: #ffffff;

  --bg: #F0F4F9;
  --flaeche: #ffffff;
  --flaeche-2: #f8f9fb;
  --flaeche-3: #E8EFF8;
  --flaeche-hover: #f1f4f8;
  --seite: #F0F4F9;
  --linie: #D5E0EE;
  --linie-2: #B7C7DC;
  --linie-weich: #edf0f4;
  --text: #1E293B;
  --text-2: #475569;
  --text-3: #7A8699;

  --ok: #177a50;       --ok-weich: #e3f3ea;
  --warn: #9a6200;     --warn-weich: #fcf1d8;   --warn-punkt: #e0a022;
  --fehler: #b3372a;   --fehler-weich: #fbe8e5;
  --info: #2e5c8a;     --info-weich: #e7eff8;
  --gold-text: #8a5c0a; --gold-weich: #fbf1dc; --gold-linie: #ecd3a0;

  --schatten-1: 0 1px 2px rgba(16, 32, 52, .06);
  --schatten-2: 0 2px 6px rgba(16, 32, 52, .06), 0 8px 24px rgba(16, 32, 52, .07);
  --schatten-3: 0 24px 64px rgba(12, 26, 44, .22), 0 4px 16px rgba(12, 26, 44, .08);
  --abdunkeln: rgba(15, 26, 40, .38);

  --r-1: 6px; --r-2: 8px; --r-3: 12px; --r-4: 16px;
  --schrift: "Poppins", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  --schrift-anzeige: "Poppins", "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  --mono: "IBM Plex Mono", "Cascadia Mono", Consolas, "SF Mono", Menlo, monospace;
  --t: 150ms cubic-bezier(.2, .7, .3, 1);
  --fokus-ring: 0 0 0 2px var(--flaeche), 0 0 0 4px color-mix(in oklab, var(--akzent) 75%, transparent);

  --kopf-h: 60px;
  --zeile-py: 11px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --akzent: var(--akzent-basis);
    --akzent-stark: color-mix(in oklab, var(--akzent) 85%, white);
    --akzent-weich: color-mix(in oklab, var(--akzent) 12%, transparent);
    --akzent-weich-2: color-mix(in oklab, var(--akzent) 20%, transparent);
    --akzent-basis: #E5879A;
    --auf-akzent: #1A0E12;
    --bg: #0A1626; --flaeche: #0F2036; --flaeche-2: #132741; --flaeche-3: #16304F; --flaeche-hover: #142B49;
    --seite: #0B1B2E;
    --linie: #22395A; --linie-2: #33507A; --linie-weich: #1B2E4A;
    --text: #E6EDF6; --text-2: #A3B4C9; --text-3: #7E8FA6;
    --ok: #5cc995; --ok-weich: rgba(92, 201, 149, .12);
    --warn: #eab452; --warn-weich: rgba(234, 180, 82, .12); --warn-punkt: #eab452;
    --fehler: #f0826f; --fehler-weich: rgba(240, 130, 111, .12);
    --info: #8db6e2; --info-weich: rgba(141, 182, 226, .12);
    --gold-text: #ecbd61; --gold-weich: rgba(224, 168, 59, .12); --gold-linie: rgba(224, 168, 59, .35);
    --schatten-1: 0 1px 2px rgba(0, 0, 0, .3);
    --schatten-2: 0 2px 8px rgba(0, 0, 0, .35), 0 8px 24px rgba(0, 0, 0, .25);
    --schatten-3: 0 24px 64px rgba(0, 0, 0, .55), 0 4px 16px rgba(0, 0, 0, .3);
    --abdunkeln: rgba(3, 8, 14, .6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --akzent: var(--akzent-basis);
  --akzent-stark: color-mix(in oklab, var(--akzent) 85%, white);
  --akzent-weich: color-mix(in oklab, var(--akzent) 12%, transparent);
  --akzent-weich-2: color-mix(in oklab, var(--akzent) 20%, transparent);
  --akzent-basis: #E5879A;
  --auf-akzent: #1A0E12;
  --bg: #0A1626; --flaeche: #0F2036; --flaeche-2: #132741; --flaeche-3: #16304F; --flaeche-hover: #142B49;
  --seite: #0B1B2E;
  --linie: #22395A; --linie-2: #33507A; --linie-weich: #1B2E4A;
  --text: #E6EDF6; --text-2: #A3B4C9; --text-3: #7E8FA6;
  --ok: #5cc995; --ok-weich: rgba(92, 201, 149, .12);
  --warn: #eab452; --warn-weich: rgba(234, 180, 82, .12); --warn-punkt: #eab452;
  --fehler: #f0826f; --fehler-weich: rgba(240, 130, 111, .12);
  --info: #8db6e2; --info-weich: rgba(141, 182, 226, .12);
  --gold-text: #ecbd61; --gold-weich: rgba(224, 168, 59, .12); --gold-linie: rgba(224, 168, 59, .35);
  --schatten-1: 0 1px 2px rgba(0, 0, 0, .3);
  --schatten-2: 0 2px 8px rgba(0, 0, 0, .35), 0 8px 24px rgba(0, 0, 0, .25);
  --schatten-3: 0 24px 64px rgba(0, 0, 0, .55), 0 4px 16px rgba(0, 0, 0, .3);
  --abdunkeln: rgba(3, 8, 14, .6);
  color-scheme: dark;
}

:root[data-dichte="kompakt"] { --zeile-py: 6px; }

/* ------------------------------------------------------------------ Grundlagen */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.5 var(--schrift);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow: hidden;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--akzent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
h1, h2, h3, h4 { margin: 0; font-family: var(--schrift-anzeige); letter-spacing: -.01em; }
p { margin: 0; }
code, kbd, .mono { font-family: var(--mono); font-size: .92em; }
kbd {
  display: inline-block; min-width: 1.6em; padding: 0 .4em; text-align: center;
  border: 1px solid var(--linie-2); border-bottom-width: 2px; border-radius: 5px;
  background: var(--flaeche); color: var(--text-2); font-size: 11.5px; line-height: 1.6;
}
[hidden] { display: none !important; }
:focus-visible { outline: none; box-shadow: var(--fokus-ring); border-radius: var(--r-1); }
::selection { background: color-mix(in oklab, var(--akzent) 25%, transparent); }

.i {
  width: 18px; height: 18px; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.75;
  stroke-linecap: round; stroke-linejoin: round;
  vertical-align: middle;
}
.i--klein { width: 15px; height: 15px; }
.i--gross { width: 22px; height: 22px; }
.nur-sr {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.sprunglink {
  position: fixed; left: 12px; top: -60px; z-index: 1000; padding: 8px 14px;
  background: var(--akzent); color: var(--auf-akzent); border-radius: var(--r-2);
  transition: top var(--t);
}
.sprunglink:focus { top: 12px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 1ms !important; animation-duration: 1ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}

/* Scrollbalken ruhig */
* { scrollbar-width: thin; scrollbar-color: var(--linie-2) transparent; }

/* ------------------------------------------------------------------ Knöpfe */
.knopf {
  --k-bg: var(--flaeche); --k-fg: var(--text); --k-rand: var(--linie-2);
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 36px; padding: 0 14px; border-radius: var(--r-2);
  border: 1px solid var(--k-rand); background: var(--k-bg); color: var(--k-fg);
  font-weight: 550; font-size: 13.5px; white-space: nowrap; cursor: pointer; user-select: none;
  transition: background var(--t), border-color var(--t), color var(--t), box-shadow var(--t), transform var(--t);
  box-shadow: var(--schatten-1);
}
.knopf:hover { background: var(--flaeche-hover); border-color: color-mix(in oklab, var(--linie-2) 60%, var(--text-3)); text-decoration: none; }
.knopf:active { transform: translateY(.5px); }
.knopf:disabled, .knopf[aria-disabled="true"] { opacity: .5; cursor: not-allowed; pointer-events: none; }
.knopf .i { width: 17px; height: 17px; }
.knopf--primaer { --k-bg: var(--akzent); --k-fg: var(--auf-akzent); --k-rand: transparent; box-shadow: 0 1px 2px rgba(16,32,52,.12), inset 0 1px 0 rgba(255,255,255,.08); }
.knopf--primaer:hover { background: var(--akzent-stark); border-color: transparent; }
.knopf--gefahr { --k-bg: var(--fehler); --k-fg: #fff; --k-rand: transparent; }
.knopf--gefahr:hover { background: color-mix(in oklab, var(--fehler) 86%, black); border-color: transparent; }
:root[data-theme="dark"] .knopf--gefahr { --k-fg: #1a0b08; }
.knopf--gefahr-leise { --k-fg: var(--fehler); }
.knopf--gefahr-leise:hover { background: var(--fehler-weich); border-color: color-mix(in oklab, var(--fehler) 40%, transparent); }
.knopf--leise { --k-bg: transparent; --k-rand: transparent; box-shadow: none; color: var(--text-2); }
.knopf--leise:hover { background: var(--flaeche-3); border-color: transparent; color: var(--text); }
.knopf--gold { --k-bg: var(--gold-weich); --k-fg: var(--gold-text); --k-rand: var(--gold-linie); box-shadow: none; }
.knopf--icon { width: 36px; padding: 0; }
.knopf--klein { height: 30px; padding: 0 10px; font-size: 13px; border-radius: 7px; }
.knopf--klein.knopf--icon { width: 30px; padding: 0; }
.knopf--gross { height: 44px; padding: 0 20px; font-size: 15px; border-radius: var(--r-3); }
.knopf--voll { width: 100%; }
.knopf .zaehler { margin-left: 2px; }
.knopf.laedt { color: transparent !important; position: relative; pointer-events: none; }
.knopf.laedt::after {
  content: ""; position: absolute; width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid var(--k-fg); border-right-color: transparent; animation: drehen .7s linear infinite;
}
@keyframes drehen { to { transform: rotate(360deg); } }
.knopfgruppe { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ------------------------------------------------------------------ Formulare */
.feld { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.feld-name { font-size: 13px; font-weight: 600; color: var(--text); }
.feld-name small { font-weight: 400; color: var(--text-3); margin-left: 4px; }
.feld-hilfe { font-size: 12.5px; color: var(--text-3); line-height: 1.45; }
.feld-fehler { font-size: 12.5px; color: var(--fehler); }
.eingabe {
  width: 100%; height: 38px; padding: 0 12px;
  border: 1px solid var(--linie-2); border-radius: var(--r-2); background: var(--flaeche);
  color: var(--text); outline: none; transition: border-color var(--t), box-shadow var(--t);
}
.eingabe::placeholder { color: var(--text-3); opacity: .85; }
.eingabe:hover { border-color: color-mix(in oklab, var(--linie-2) 55%, var(--text-3)); }
.eingabe:focus { border-color: var(--akzent); box-shadow: 0 0 0 3px var(--akzent-weich-2); }
.eingabe[aria-invalid="true"] { border-color: var(--fehler); box-shadow: 0 0 0 3px var(--fehler-weich); }
.eingabe:disabled, .eingabe[readonly] { background: var(--flaeche-2); color: var(--text-2); }
textarea.eingabe { height: auto; min-height: 84px; padding: 9px 12px; resize: vertical; line-height: 1.5; }
select.eingabe {
  appearance: none; padding-right: 34px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%);
  background-position: calc(100% - 17px) 16px, calc(100% - 12px) 16px; background-size: 5px 5px; background-repeat: no-repeat;
}
.eingabe.mono { font-family: var(--mono); font-size: 13px; }
.eingabe-gruppe { display: flex; align-items: stretch; }
.eingabe-gruppe > .eingabe { border-radius: var(--r-2) 0 0 var(--r-2); }
.eingabe-gruppe > .knopf { border-radius: 0 var(--r-2) var(--r-2) 0; margin-left: -1px; height: 38px; box-shadow: none; }
.eingabe-mit-icon { position: relative; }
.eingabe-mit-icon > .i { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.eingabe-mit-icon > .eingabe { padding-left: 36px; }
.formular { display: grid; gap: 18px; }
.formular-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.formular-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 18px; }
.spanne-2 { grid-column: span 2; }
.formular-abschnitt { display: grid; gap: 14px; padding-bottom: 22px; border-bottom: 1px solid var(--linie-weich); }
.formular-abschnitt:last-child { border-bottom: 0; padding-bottom: 0; }
.formular-abschnitt > h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); font-weight: 650; }

.ankreuz { display: inline-flex; align-items: flex-start; gap: 10px; cursor: pointer; line-height: 1.4; }
.ankreuz input { appearance: none; margin: 1px 0 0; width: 18px; height: 18px; flex: none; border: 1.5px solid var(--linie-2); border-radius: 5px; background: var(--flaeche); display: grid; place-items: center; transition: background var(--t), border-color var(--t); cursor: pointer; }
.ankreuz input:checked { background: var(--akzent); border-color: var(--akzent); }
.ankreuz input:checked::after { content: ""; width: 9px; height: 5px; border: 2px solid var(--auf-akzent); border-top: 0; border-right: 0; transform: translateY(-1px) rotate(-45deg); }
.ankreuz input:focus-visible { box-shadow: var(--fokus-ring); }
.ankreuz input[type="radio"] { border-radius: 50%; }
.ankreuz input[type="radio"]:checked::after { width: 8px; height: 8px; border: 0; border-radius: 50%; background: var(--auf-akzent); transform: none; }
.ankreuz small { display: block; color: var(--text-3); font-size: 12.5px; margin-top: 2px; }

.schalter { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; }
.schalter input { appearance: none; margin: 0; width: 36px; height: 20px; flex: none; border-radius: 99px; background: var(--linie-2); position: relative; cursor: pointer; transition: background var(--t); }
.schalter input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.25); transition: transform var(--t); }
.schalter input:checked { background: var(--akzent); }
.schalter input:checked::after { transform: translateX(16px); }
.schalter input:focus-visible { box-shadow: var(--fokus-ring); }
.schalter input:disabled { opacity: .5; cursor: not-allowed; }

.segment { display: inline-flex; padding: 3px; gap: 2px; background: var(--flaeche-3); border-radius: 10px; flex-wrap: wrap; }
.segment button, .segment label { position: relative; height: 30px; padding: 0 12px; border: 0; border-radius: 7px; background: transparent; color: var(--text-2); font-weight: 550; font-size: 13px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: background var(--t), color var(--t); }
.segment input { position: absolute; opacity: 0; inset: 0; cursor: pointer; margin: 0; }
.segment button:hover, .segment label:hover { color: var(--text); }
.segment [aria-pressed="true"], .segment label:has(input:checked) { background: var(--flaeche); color: var(--text); box-shadow: var(--schatten-1); }
.segment label:has(input:focus-visible) { box-shadow: var(--fokus-ring); }

/* ------------------------------------------------------------------ Abzeichen, Chips, Ampeln */
.abz {
  display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px;
  border-radius: 99px; font-size: 12px; font-weight: 600; white-space: nowrap; line-height: 1;
  background: var(--flaeche-3); color: var(--text-2);
}
.abz .i { width: 13px; height: 13px; stroke-width: 2; }
.abz--ok { background: var(--ok-weich); color: var(--ok); }
.abz--warn { background: var(--warn-weich); color: var(--warn); }
.abz--fehler { background: var(--fehler-weich); color: var(--fehler); }
.abz--info { background: var(--info-weich); color: var(--info); }
.abz--gold { background: var(--gold-weich); color: var(--gold-text); box-shadow: inset 0 0 0 1px var(--gold-linie); }
.abz--akzent { background: var(--akzent-weich-2); color: var(--akzent); }
.abz--rand { background: transparent; box-shadow: inset 0 0 0 1px var(--linie-2); }
.zaehler { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--akzent); color: var(--auf-akzent); font-size: 11.5px; font-weight: 700; line-height: 1; }
.zaehler--gold { background: var(--gold); color: #2a1d05; }

.chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 6px 0 10px; border-radius: 99px; background: var(--akzent-weich); color: var(--text); font-size: 12.5px; border: 1px solid var(--akzent-linie); }
.chip b { font-weight: 600; color: var(--text-2); }
.chip button { width: 20px; height: 20px; display: grid; place-items: center; border: 0; background: transparent; border-radius: 50%; color: var(--text-2); cursor: pointer; padding: 0; }
.chip button:hover { background: var(--akzent-weich-2); color: var(--text); }
.chip button .i { width: 13px; height: 13px; stroke-width: 2.2; }

.ampel { display: inline-block; width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--text-3); box-shadow: 0 0 0 3px color-mix(in oklab, currentColor 0%, transparent); }
.ampel--ok { background: #23a26b; box-shadow: 0 0 0 3px rgba(35,162,107,.16); }
.ampel--warnung, .ampel--warn { background: var(--warn-punkt); box-shadow: 0 0 0 3px rgba(224,160,34,.18); }
.ampel--fehler { background: #d64a37; box-shadow: 0 0 0 3px rgba(214,74,55,.16); }
.ampel--laeuft { background: var(--akzent); box-shadow: 0 0 0 3px var(--akzent-weich-2); animation: pulsieren 1.6s ease-in-out infinite; }
.ampel--abgebrochen, .ampel--aus { background: var(--text-3); }
@keyframes pulsieren { 50% { box-shadow: 0 0 0 6px transparent; } }

/* ------------------------------------------------------------------ Karten, Tabellen */
.karte { background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--r-3); box-shadow: var(--schatten-1); min-width: 0; }
.karte-kopf { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px 0; }
.karte-kopf h2, .karte-kopf h3 { font-size: 15px; font-weight: 650; display: flex; align-items: center; gap: 8px; }
.karte-kopf .unter { color: var(--text-3); font-size: 12.5px; font-weight: 400; }
.karte-inhalt { padding: 16px 20px 20px; }
.karte-fuss { padding: 12px 20px; border-top: 1px solid var(--linie-weich); display: flex; justify-content: flex-end; gap: 8px; }
.karte--leise { box-shadow: none; background: var(--flaeche-2); }

.tabelle-huelle { overflow-x: auto; border-radius: inherit; }
.tabelle { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; }
.tabelle th { position: sticky; top: 0; z-index: 1; text-align: left; font-weight: 600; font-size: 12px; color: var(--text-3); letter-spacing: .02em; padding: 10px 14px; background: var(--flaeche-2); border-bottom: 1px solid var(--linie); white-space: nowrap; }
.tabelle th:first-child { border-top-left-radius: var(--r-3); }
.tabelle th:last-child { border-top-right-radius: var(--r-3); }
.tabelle td { padding: 11px 14px; border-bottom: 1px solid var(--linie-weich); vertical-align: middle; }
.tabelle tr:last-child td { border-bottom: 0; }
.tabelle tbody tr { transition: background var(--t); }
.tabelle tbody tr[data-act], .tabelle tbody tr.klickbar { cursor: pointer; }
.tabelle tbody tr[data-act]:hover, .tabelle tbody tr.klickbar:hover { background: var(--flaeche-hover); }
.tabelle tbody tr:focus-visible { box-shadow: inset 0 0 0 2px var(--akzent); border-radius: 0; }
.tabelle .rechts { text-align: right; font-variant-numeric: tabular-nums; }
.tabelle .schmal { width: 1%; white-space: nowrap; }
.tabelle .gedaempft, .gedaempft { color: var(--text-3); }
.tabelle .stark { font-weight: 600; }
.zelle-person { display: flex; align-items: center; gap: 10px; min-width: 0; }
.zelle-person > div { min-width: 0; }
.zelle-person .unter { font-size: 12.5px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.avatar { --av: #2e5c8a; width: 32px; height: 32px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 650; letter-spacing: .02em; color: #fff; background: var(--av); }
.avatar--gross { width: 42px; height: 42px; font-size: 15px; }
.avatar--klein { width: 26px; height: 26px; font-size: 10.5px; }
.farbe-0 { --av: #2e5c8a; } .farbe-1 { --av: #6a4fa3; } .farbe-2 { --av: #1f7a6d; } .farbe-3 { --av: #b0563a; }
.farbe-4 { --av: #3d6fb5; } .farbe-5 { --av: #8a5a24; } .farbe-6 { --av: #a13f6b; } .farbe-7 { --av: #4f7a2c; }

/* ------------------------------------------------------------------ Hülle */
.huelle { height: 100vh; height: 100dvh; display: grid; grid-template-rows: var(--kopf-h) minmax(0, 1fr); grid-template-columns: minmax(0, 1fr); }
.kopf {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 20px;
  padding: 0 16px 0 18px; background: var(--flaeche); border-bottom: 1px solid var(--linie);
  position: relative; z-index: 30;
}
.kopf-marke { display: flex; align-items: center; gap: 11px; color: var(--text); min-width: 0; }
.kopf-marke:hover { text-decoration: none; }
.kopf-marke img { width: 34px; height: 34px; display: block; }
.kopf-marke-text { display: flex; flex-direction: column; line-height: 1.15; }
.kopf-marke-name { font-family: var(--schrift-anzeige); font-weight: 700; font-size: 15.5px; letter-spacing: -.015em; }
.kopf-marke-name span { color: var(--akzent); }
.kopf-marke-mandant { font-size: 12px; color: var(--text-3); }
.kopf-mitte { display: flex; justify-content: center; min-width: 0; }
.kopf-rechts { display: flex; align-items: center; gap: 4px; }
.kopf-titel { font-weight: 600; color: var(--text-2); font-size: 14px; display: flex; align-items: center; gap: 8px; }
.kopf-knopf { position: relative; }
.kopf-knopf .zaehler { position: absolute; top: 1px; right: 0; min-width: 17px; height: 17px; font-size: 10.5px; padding: 0 4px; box-shadow: 0 0 0 2px var(--flaeche); }
.kopf-link { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: var(--r-2); color: var(--text-2); font-weight: 550; font-size: 13.5px; }
.kopf-link:hover { background: var(--flaeche-3); color: var(--text); text-decoration: none; }
.kopf-link[aria-current="page"] { color: var(--akzent); background: var(--akzent-weich); }
.kopf-link .zaehler { margin-left: 2px; }
.benutzerknopf { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 6px 0 4px; margin-left: 6px; border: 0; border-radius: 99px; background: transparent; cursor: pointer; }
.benutzerknopf:hover { background: var(--flaeche-3); }
.haupt { min-height: 0; overflow: hidden; position: relative; display: grid; grid-template-rows: minmax(0, 1fr); grid-template-columns: minmax(0, 1fr); }
.haupt > * { min-height: 0; min-width: 0; }
.haupt--scroll { overflow-y: auto; }

/* Suche im Kopf */
.suche { position: relative; width: 100%; max-width: 680px; }
.suche-feld {
  display: flex; align-items: center; gap: 4px; height: 42px; padding: 0 5px 0 13px;
  border-radius: 12px; background: var(--flaeche-3); border: 1px solid transparent;
  transition: background var(--t), border-color var(--t), box-shadow var(--t);
}
.suche-feld:hover { background: color-mix(in oklab, var(--flaeche-3) 70%, var(--linie-2)); }
.suche-feld:focus-within { background: var(--flaeche); border-color: var(--akzent); box-shadow: 0 0 0 4px var(--akzent-weich-2), var(--schatten-1); }
.suche-feld > .i { color: var(--text-3); }
.suche-feld input { flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; outline: none; font-size: 14.5px; padding: 0 6px; }
.suche-feld input::placeholder { color: var(--text-3); }
.suche-feld input::-webkit-search-cancel-button { display: none; }
.suche-feld .knopf--icon { width: 32px; height: 32px; border-radius: 8px; }
.suche-feld kbd { margin-right: 6px; }
.suche-trenner { width: 1px; height: 20px; background: var(--linie-2); margin: 0 3px; }
.suche-feld .knopf[aria-expanded="true"] { background: var(--akzent-weich-2); color: var(--akzent); }

/* ------------------------------------------------------------------ Schwebende Ebenen */
.menue {
  position: fixed; z-index: 200; min-width: 220px; max-width: 340px; padding: 6px;
  background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--r-3); box-shadow: var(--schatten-3);
  animation: einblenden 140ms cubic-bezier(.2,.7,.3,1);
}
.menue-eintrag { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 36px; padding: 6px 10px; border: 0; border-radius: 7px; background: transparent; color: var(--text); text-align: left; cursor: pointer; font-size: 13.5px; }
.menue-eintrag:hover, .menue-eintrag:focus-visible { background: var(--flaeche-3); box-shadow: none; }
.menue-eintrag .i { color: var(--text-3); }
.menue-eintrag[aria-checked="true"] { color: var(--akzent); font-weight: 600; }
.menue-eintrag[aria-checked="true"] .i { color: var(--akzent); }
.menue-eintrag--gefahr { color: var(--fehler); }
.menue-eintrag--gefahr .i { color: var(--fehler); }
.menue-eintrag:disabled { opacity: .45; cursor: not-allowed; }
.menue-eintrag .hinweis { margin-left: auto; color: var(--text-3); font-size: 12px; }
.menue-trenner { height: 1px; background: var(--linie); margin: 6px 4px; }
.menue-kopf { padding: 8px 10px 6px; font-size: 11.5px; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); }
.menue-person { display: flex; gap: 12px; align-items: center; padding: 10px 10px 12px; }
.menue-person .name { font-weight: 650; }
.menue-person .unter { font-size: 12.5px; color: var(--text-3); }
@keyframes einblenden { from { opacity: 0; transform: translateY(-4px) scale(.985); } }

.popover { position: fixed; z-index: 190; background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--r-3); box-shadow: var(--schatten-3); animation: einblenden 140ms cubic-bezier(.2,.7,.3,1); }

dialog.dlg {
  padding: 0; border: 0; border-radius: var(--r-4); background: var(--flaeche); color: var(--text);
  box-shadow: var(--schatten-3); width: min(520px, calc(100vw - 32px)); max-height: calc(100dvh - 48px);
}
dialog.dlg--breit { width: min(760px, calc(100vw - 32px)); }
dialog.dlg--schmal { width: min(420px, calc(100vw - 32px)); }
dialog.dlg[open] { animation: dialog-ein 180ms cubic-bezier(.2,.7,.3,1); }
dialog.dlg::backdrop { background: var(--abdunkeln); backdrop-filter: blur(2px); animation: blende 180ms ease; }
@keyframes dialog-ein { from { opacity: 0; transform: translateY(8px) scale(.985); } }
@keyframes blende { from { opacity: 0; } }
.dlg-form { display: flex; flex-direction: column; max-height: inherit; margin: 0; }
.dlg-kopf { display: flex; gap: 14px; align-items: flex-start; justify-content: space-between; padding: 20px 20px 0 24px; }
.dlg-kopf-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--akzent-weich-2); color: var(--akzent); flex: none; }
.dlg-kopf-icon--gefahr { background: var(--fehler-weich); color: var(--fehler); }
.dlg-kopf-icon--gold { background: var(--gold-weich); color: var(--gold-text); }
.dlg-kopf-icon .i { width: 21px; height: 21px; }
.dlg-kopf-text { flex: 1; min-width: 0; padding-top: 2px; }
.dlg-titel { font-size: 18px; font-weight: 650; line-height: 1.3; }
.dlg-unter { color: var(--text-2); margin-top: 4px; font-size: 13.5px; }
.dlg-inhalt { padding: 18px 24px 8px; overflow-y: auto; display: grid; gap: 16px; }
.dlg-fehler { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: var(--r-2); background: var(--fehler-weich); color: var(--fehler); font-size: 13px; }
.dlg-fuss { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 24px 20px; flex-wrap: wrap; }
.dlg-fuss .links { margin-right: auto; }

dialog.blatt {
  margin: 0 0 0 auto; height: 100dvh; max-height: 100dvh; width: min(620px, 100vw); border-radius: var(--r-4) 0 0 var(--r-4);
}
dialog.blatt[open] { animation: blatt-ein 220ms cubic-bezier(.2,.7,.3,1); }
dialog.blatt .dlg-form { height: 100%; }
dialog.blatt .dlg-inhalt { flex: 1; padding-top: 12px; }
dialog.blatt .dlg-kopf { padding-bottom: 14px; border-bottom: 1px solid var(--linie-weich); }
dialog.blatt .dlg-fuss { border-top: 1px solid var(--linie-weich); padding-top: 14px; }
@keyframes blatt-ein { from { transform: translateX(40px); opacity: 0; } }

.toast-stapel { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 400; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: min(480px, calc(100vw - 32px)); }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 8px 10px 14px; border-radius: var(--r-3); background: #172433; color: #eef3f8; box-shadow: var(--schatten-3); font-size: 13.5px; animation: toast-ein 220ms cubic-bezier(.2,.7,.3,1); }
:root[data-theme="dark"] .toast { background: #26364a; }
.toast .i { flex: none; }
.toast--ok > .i { color: #6fd6a4; }
.toast--fehler > .i { color: #ff9c8a; }
.toast--warn > .i { color: #f3c46b; }
.toast--info > .i { color: #9cc3ec; }
.toast-text { flex: 1; min-width: 0; }
.toast .knopf--leise { color: #c7d6e6; }
.toast .knopf--leise:hover { background: rgba(255,255,255,.08); color: #fff; }
.toast.weg { opacity: 0; transform: translateY(6px); transition: opacity 200ms, transform 200ms; }
@keyframes toast-ein { from { opacity: 0; transform: translateY(10px); } }

/* ------------------------------------------------------------------ Zustände */
.leer { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 48px 24px; color: var(--text-2); max-width: 420px; margin: auto; }
.leer-bild { position: relative; width: 88px; height: 88px; margin-bottom: 8px; display: grid; place-items: center; }
.leer-bild::before { content: ""; position: absolute; inset: 0; border-radius: 28px; background: linear-gradient(145deg, var(--akzent-weich-2), var(--akzent-weich)); transform: rotate(-6deg); }
.leer-bild::after { content: ""; position: absolute; inset: 8px; border-radius: 22px; background: var(--flaeche); box-shadow: var(--schatten-2); }
.leer-bild .i { position: relative; z-index: 1; width: 34px; height: 34px; color: var(--akzent); stroke-width: 1.5; }
.leer-bild .leer-punkt { position: absolute; z-index: 2; right: -2px; top: 4px; width: 14px; height: 14px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 3px var(--bg); }
.leer h3 { font-size: 16px; color: var(--text); font-weight: 650; }
.leer p { font-size: 13.5px; line-height: 1.55; }
.leer .knopfgruppe { margin-top: 8px; justify-content: center; }

.skelett { position: relative; overflow: hidden; background: var(--flaeche-3); border-radius: 6px; }
.skelett::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, color-mix(in oklab, var(--flaeche) 55%, transparent), transparent); animation: schimmer 1.3s ease-in-out infinite; }
@keyframes schimmer { to { transform: translateX(100%); } }
.sk-zeile { height: 12px; margin: 6px 0; }
.sk-kreis { width: 32px; height: 32px; border-radius: 50%; }

.hinweis { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r-2); background: var(--info-weich); color: var(--text); font-size: 13.5px; line-height: 1.5; border: 1px solid color-mix(in oklab, var(--info) 18%, transparent); }
.hinweis > .i { color: var(--info); margin-top: 1px; }
.hinweis--warn { background: var(--warn-weich); border-color: color-mix(in oklab, var(--warn) 22%, transparent); }
.hinweis--warn > .i { color: var(--warn); }
.hinweis--fehler { background: var(--fehler-weich); border-color: color-mix(in oklab, var(--fehler) 22%, transparent); }
.hinweis--fehler > .i { color: var(--fehler); }
.hinweis--ok { background: var(--ok-weich); border-color: color-mix(in oklab, var(--ok) 22%, transparent); }
.hinweis--ok > .i { color: var(--ok); }
.hinweis--gold { background: var(--gold-weich); border-color: var(--gold-linie); }
.hinweis--gold > .i { color: var(--gold-text); }
.hinweis strong { font-weight: 650; }
.hinweis-text { flex: 1; min-width: 0; display: grid; gap: 4px; }

.fehlerseite { display: grid; place-items: center; height: 100%; padding: 24px; }

/* ------------------------------------------------------------------ Seiten (Einstellungen, Verwaltung, Anträge) */
.seite-scroll { height: 100%; overflow-y: auto; }
.seite { max-width: 1180px; margin: 0 auto; padding: 28px 32px 64px; display: grid; gap: 20px; align-content: start; }
.seite--schmal { max-width: 820px; }
.seitenkopf { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 4px; }
.seitenkopf h1 { font-size: 24px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; }
.seitenkopf p { color: var(--text-2); margin-top: 6px; max-width: 680px; }
.seitenkopf .knopfgruppe { margin-left: auto; }
.brotkrumen { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-3); margin-bottom: 8px; }
.brotkrumen a { color: var(--text-3); }
.brotkrumen .i { width: 14px; height: 14px; }
.raster { display: grid; gap: 16px; }
.raster-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.raster-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.raster-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.raster-auto { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.werkzeugleiste { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.werkzeugleiste .eingabe-mit-icon { flex: 1; max-width: 340px; min-width: 200px; }
.abstand { flex: 1; }

.dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; font-size: 13.5px; margin: 0; }
.dl dt { color: var(--text-3); }
.dl dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* Verwaltung */
.verwaltung { display: grid; grid-template-columns: 248px minmax(0, 1fr); height: 100%; }
.vnav { background: var(--seite); border-right: 1px solid var(--linie); overflow-y: auto; padding: 18px 12px 24px; }
.vnav-gruppe { margin-bottom: 14px; }
.vnav-gruppe h4 { font-size: 11.5px; font-weight: 650; text-transform: uppercase; letter-spacing: .07em; color: var(--text-3); padding: 0 10px 6px; }
.vnav a { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 10px; border-radius: 8px; color: var(--text-2); font-weight: 520; font-size: 13.5px; position: relative; }
.vnav a:hover { background: var(--flaeche-3); color: var(--text); text-decoration: none; }
.vnav a[aria-current="page"] { background: var(--flaeche); color: var(--text); font-weight: 620; box-shadow: var(--schatten-1), inset 0 0 0 1px var(--linie); }
.vnav a[aria-current="page"] .i { color: var(--akzent); }
.vnav a .i { color: var(--text-3); }
.vnav a .zaehler { margin-left: auto; }
.vnav a .ampel { margin-left: auto; }
.vinhalt { overflow-y: auto; min-width: 0; }

/* Kennzahlen */
.kachel { padding: 18px 20px; display: grid; gap: 6px; position: relative; overflow: hidden; }
.kachel-kopf { display: flex; align-items: center; gap: 8px; color: var(--text-2); font-size: 13px; font-weight: 550; }
.kachel-kopf .i { color: var(--text-3); width: 17px; height: 17px; }
.kachel-wert { font-family: var(--schrift-anzeige); font-size: 30px; font-weight: 650; letter-spacing: -.025em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.kachel-wert small { font-size: 15px; font-weight: 550; color: var(--text-3); margin-left: 3px; letter-spacing: 0; }
.kachel-unter { font-size: 12.5px; color: var(--text-3); display: flex; align-items: center; gap: 6px; }
.kachel-unter .plus { color: var(--ok); font-weight: 600; }
.sparkline { position: absolute; right: 16px; top: 44px; width: 104px; height: 34px; }
.sparkline path.linie { fill: none; stroke: var(--akzent); stroke-width: 1.75; stroke-linejoin: round; stroke-linecap: round; }
.sparkline path.flaeche { fill: var(--akzent-weich-2); stroke: none; }
.sparkline circle { fill: var(--akzent); stroke: var(--flaeche); stroke-width: 2; }

.warnliste { display: grid; gap: 8px; }
.warnung { display: flex; align-items: center; gap: 12px; padding: 11px 12px 11px 14px; border-radius: var(--r-2); border: 1px solid var(--linie); background: var(--flaeche); position: relative; overflow: hidden; }
.warnung::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--warn-punkt); }
.warnung--rot::before { background: #d64a37; }
.warnung > .i { color: var(--warn); }
.warnung--rot > .i { color: var(--fehler); }
.warnung-text { flex: 1; min-width: 0; font-size: 13.5px; }
.warnung a { font-weight: 600; font-size: 13px; white-space: nowrap; }

.laufliste { display: grid; }
.lauf-zeile { display: grid; grid-template-columns: 12px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 2px; border-bottom: 1px solid var(--linie-weich); }
.lauf-zeile:last-child { border-bottom: 0; }
.lauf-zeile .name { font-weight: 550; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lauf-zeile .unter { font-size: 12.5px; color: var(--text-3); }
.lauf-zeile .zahl { font-variant-numeric: tabular-nums; text-align: right; font-size: 13px; color: var(--text-2); }

.balken { height: 8px; background: var(--flaeche-3); border-radius: 99px; overflow: hidden; }
.balken > span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--akzent), color-mix(in oklab, var(--akzent) 70%, #8fb3d9)); width: 0; transition: width 400ms cubic-bezier(.2,.7,.3,1); }
.balken--gold > span { background: linear-gradient(90deg, #d4972a, var(--gold)); }

.monatsbalken { display: flex; align-items: flex-end; gap: 6px; height: 150px; padding-top: 10px; }
.monatsbalken .spalte { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; min-width: 0; }
.monatsbalken .saeule { width: 100%; max-width: 34px; border-radius: 6px 6px 3px 3px; background: color-mix(in oklab, var(--akzent) 30%, var(--flaeche-3)); position: relative; min-height: 3px; transition: background var(--t); }
.monatsbalken .saeule--aktuell { background: var(--akzent); }
.monatsbalken .saeule--zu { background: color-mix(in oklab, var(--gold) 55%, var(--flaeche-3)); }
.monatsbalken .spalte:hover .saeule { filter: brightness(1.08); }
.monatsbalken .monat { font-size: 11px; color: var(--text-3); white-space: nowrap; }

.kettenbild { display: flex; align-items: stretch; gap: 0; overflow-x: auto; padding: 6px 2px 10px; }
.glied { flex: none; width: 170px; padding: 12px; border: 1px solid var(--linie); border-radius: var(--r-2); background: var(--flaeche); display: grid; gap: 4px; font-size: 12px; position: relative; }
.glied .seq { font-weight: 650; font-size: 13px; }
.glied .vorgang { color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.glied .h { font-family: var(--mono); font-size: 11px; color: var(--text-3); }
.glied .h b { color: var(--akzent); font-weight: 600; }
.glied--siegel { border-color: var(--gold-linie); background: var(--gold-weich); }
.glied--siegel .seq { color: var(--gold-text); display: flex; align-items: center; gap: 6px; }
.kettenverbinder { flex: none; width: 34px; display: grid; place-items: center; color: var(--text-3); }
.kettenverbinder .i { width: 20px; height: 20px; }

/* Zeitstrahl */
.zeitstrahl { position: relative; padding: 44px 8px 50px; }
.zeitstrahl-linie { position: relative; height: 6px; border-radius: 99px; background: var(--flaeche-3); }
.zeitstrahl-sperre { position: absolute; top: 0; bottom: 0; left: 0; border-radius: 99px; background: linear-gradient(90deg, color-mix(in oklab, var(--akzent) 45%, var(--flaeche-3)), var(--akzent)); }
.zeitstrahl-frei { position: absolute; top: 0; bottom: 0; border-radius: 0 99px 99px 0; background: repeating-linear-gradient(135deg, var(--ok-weich) 0 6px, color-mix(in oklab, var(--ok) 25%, transparent) 6px 9px); }
.zeitstrahl-offen { position: absolute; top: 0; bottom: 0; right: -8px; width: 40px; background: linear-gradient(90deg, transparent, var(--flaeche)); }
.zeitpunkt { position: absolute; top: 50%; transform: translate(-50%, -50%); width: 14px; height: 14px; border-radius: 50%; background: var(--flaeche); border: 3px solid var(--akzent); }
.zeitpunkt--frei { border-color: var(--ok); }
.zeitpunkt--ende { border-color: var(--fehler); }
.zeitpunkt-text { position: absolute; transform: translateX(-50%); white-space: nowrap; font-size: 12px; text-align: center; line-height: 1.35; }
.zeitpunkt-text b { display: block; font-weight: 650; font-size: 12.5px; color: var(--text); }
.zeitpunkt-text span { color: var(--text-3); }
.zeitpunkt-text--unten { top: calc(50% + 14px); }
.zeitpunkt-text--oben { bottom: calc(50% + 14px); }
.zeitpunkt-text--links { transform: none; text-align: left; }
.zeitpunkt-text--rechts { transform: translateX(-100%); text-align: right; }
.heute { position: absolute; top: -8px; bottom: -8px; width: 2px; transform: translateX(-1px); background: var(--gold); border-radius: 2px; }
.heute::before { content: "heute"; position: absolute; top: -20px; left: 50%; transform: translateX(-50%); font-size: 11px; font-weight: 700; color: var(--gold-text); background: var(--gold-weich); padding: 1px 6px; border-radius: 99px; box-shadow: inset 0 0 0 1px var(--gold-linie); }

/* Schrittleiste */
.schritte { display: flex; gap: 0; list-style: none; margin: 0; padding: 0; counter-reset: schritt; overflow-x: auto; }
.schritte li { flex: 1; min-width: 104px; position: relative; }
.schritte button { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 8px; border: 0; background: transparent; padding: 0 4px; cursor: pointer; color: var(--text-3); font-size: 12.5px; font-weight: 550; }
.schritte button:disabled { cursor: default; }
.schritte .nummer { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--flaeche); border: 1.5px solid var(--linie-2); font-weight: 650; font-size: 13px; color: var(--text-3); position: relative; z-index: 1; transition: all var(--t); }
.schritte li::before { content: ""; position: absolute; top: 15px; left: calc(-50% + 18px); right: calc(50% + 18px); height: 2px; background: var(--linie); border-radius: 2px; }
.schritte li:first-child::before { display: none; }
.schritte li.erledigt::before, .schritte li.aktiv::before { background: var(--akzent); }
.schritte li.erledigt .nummer { background: var(--akzent); border-color: var(--akzent); color: var(--auf-akzent); }
.schritte li.aktiv .nummer { border-color: var(--akzent); color: var(--akzent); box-shadow: 0 0 0 4px var(--akzent-weich-2); }
.schritte li.aktiv button, .schritte li.erledigt button { color: var(--text); }

/* Quellkacheln */
.quellkachel { display: grid; gap: 10px; align-content: start; padding: 18px; text-align: left; border: 1px solid var(--linie); border-radius: var(--r-3); background: var(--flaeche); cursor: pointer; transition: border-color var(--t), box-shadow var(--t), transform var(--t); box-shadow: var(--schatten-1); color: var(--text); }
.quellkachel:hover { border-color: var(--akzent-linie); box-shadow: var(--schatten-2); transform: translateY(-1px); }
.quellkachel[aria-pressed="true"] { border-color: var(--akzent); box-shadow: 0 0 0 3px var(--akzent-weich-2); }
.quellkachel .symbol { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--akzent-weich-2); color: var(--akzent); }
.quellkachel .symbol .i { width: 22px; height: 22px; }
.quellkachel h3 { font-size: 14.5px; font-weight: 650; }
.quellkachel p { font-size: 12.5px; color: var(--text-3); line-height: 1.45; }

/* Ordner-Testbaum */
.testbaum { border: 1px solid var(--linie); border-radius: var(--r-2); overflow: hidden; background: var(--flaeche); }
.testbaum-zeile { display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border-bottom: 1px solid var(--linie-weich); font-size: 13.5px; }
.testbaum-zeile:last-child { border-bottom: 0; }
.testbaum-zeile .einzug { flex: none; }
.testbaum-zeile .name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.testbaum-zeile .anzahl { color: var(--text-3); font-variant-numeric: tabular-nums; font-size: 12.5px; }
.testbaum-zeile.gilt-nicht .name { color: var(--text-3); text-decoration: line-through; text-decoration-color: color-mix(in oklab, var(--text-3) 50%, transparent); }
.gilt { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.gilt .i { width: 14px; height: 14px; stroke-width: 2.4; }
.gilt--ja { background: var(--ok-weich); color: var(--ok); }
.gilt--nein { background: var(--flaeche-3); color: var(--text-3); }

.regel-liste { display: grid; gap: 6px; }
.regel { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 12px; border: 1px solid var(--linie); border-radius: var(--r-2); background: var(--flaeche); font-size: 13px; }
.regel code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Rangliste (ziehbar) */
.rangliste { display: grid; gap: 8px; }
.rang { display: grid; grid-template-columns: 28px 30px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px 12px 8px; border: 1px solid var(--linie); border-radius: var(--r-3); background: var(--flaeche); box-shadow: var(--schatten-1); transition: box-shadow var(--t), border-color var(--t), transform var(--t), opacity var(--t); }
.rang:hover { border-color: var(--linie-2); }
.rang.zieht { opacity: .55; }
.rang.ziel-oben { box-shadow: 0 -3px 0 0 var(--akzent); }
.rang.ziel-unten { box-shadow: 0 3px 0 0 var(--akzent); }
.rang.inaktiv .rang-titel { color: var(--text-3); }
.rang-griff { display: grid; place-items: center; height: 32px; color: var(--text-3); cursor: grab; border: 0; background: transparent; border-radius: 6px; padding: 0; }
.rang-griff:hover { background: var(--flaeche-3); color: var(--text); }
.rang-nr { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--flaeche-3); font-weight: 700; font-size: 12.5px; color: var(--text-2); }
.rang-titel { font-weight: 620; }
.rang-unter { font-size: 12.5px; color: var(--text-3); display: flex; gap: 6px 12px; flex-wrap: wrap; margin-top: 3px; }
.rang-unter span { display: inline-flex; align-items: center; gap: 4px; }
.rang-unter .i { width: 13px; height: 13px; }

/* Compliance-Kacheln */
.ckachel { display: grid; grid-template-rows: auto 1fr auto; gap: 12px; padding: 20px; }
.ckachel-kopf { display: flex; align-items: flex-start; gap: 12px; }
.ckachel-symbol { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; background: var(--flaeche-3); color: var(--text-2); }
.ckachel-symbol.an { background: var(--ok-weich); color: var(--ok); }
.ckachel-symbol.gold { background: var(--gold-weich); color: var(--gold-text); }
.ckachel h3 { font-size: 15px; font-weight: 650; }
.ckachel p { font-size: 13px; color: var(--text-2); line-height: 1.5; }
.ckachel-fuss { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px solid var(--linie-weich); }

/* JSON */
.json { font-family: var(--mono); font-size: 12.5px; line-height: 1.6; background: var(--flaeche-2); border: 1px solid var(--linie); border-radius: var(--r-2); padding: 12px 14px; overflow: auto; white-space: pre; margin: 0; max-height: 360px; }
.json .k { color: var(--akzent); }
.json .s { color: #2f7d4f; }
.json .n { color: #a15c10; }
.json .b { color: #8a3fa0; }
:root[data-theme="dark"] .json .s { color: #7fd1a0; }
:root[data-theme="dark"] .json .n { color: #f0b36b; }
:root[data-theme="dark"] .json .b { color: #d39bf0; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .json .s { color: #7fd1a0; } :root:not([data-theme="light"]) .json .n { color: #f0b36b; } :root:not([data-theme="light"]) .json .b { color: #d39bf0; } }

.hash { font-family: var(--mono); font-size: 12.5px; word-break: break-all; letter-spacing: .02em; }
.hash-block { display: flex; align-items: center; gap: 8px; padding: 8px 8px 8px 12px; border-radius: var(--r-2); background: var(--flaeche-2); border: 1px solid var(--linie); }
.hash-block .hash { flex: 1; min-width: 0; }

/* Geheimnis-Anzeige */
.einmalig { display: grid; gap: 10px; padding: 16px; border-radius: var(--r-3); background: var(--gold-weich); border: 1px dashed var(--gold-linie); }
.einmalig .wert { font-family: var(--mono); font-size: 18px; font-weight: 600; letter-spacing: .06em; word-break: break-all; color: var(--text); }

/* ------------------------------------------------------------------ Anmeldung */
.anmeldung { min-height: 100dvh; height: 100dvh; overflow-y: auto; display: grid; grid-template-columns: minmax(380px, 46%) 1fr; background: var(--flaeche); }
.anm-marke {
  position: relative; overflow: hidden; color: #eaf1f8; padding: 48px 56px; display: flex; flex-direction: column; justify-content: space-between;
  background: radial-gradient(1200px 600px at -10% -20%, #16304F 0%, transparent 60%), radial-gradient(800px 500px at 120% 120%, #A4243B 0%, transparent 58%), linear-gradient(160deg, #0B1F3A 0%, #071324 100%);
}
.anm-marke::after { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px); background-size: 32px 32px; mask-image: radial-gradient(ellipse at 30% 40%, black 20%, transparent 75%); pointer-events: none; }
.anm-marke > * { position: relative; z-index: 1; }
.anm-logo { display: flex; align-items: center; gap: 14px; }
.anm-logo img { width: 52px; height: 52px; padding: 6px; border-radius: 15px; background: rgba(255,255,255,.96); box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.anm-logo .name { font-family: var(--schrift-anzeige); font-size: 21px; font-weight: 700; letter-spacing: -.02em; }
.anm-logo .name span { color: #9cc3ec; }
.anm-claim h1 { font-size: clamp(30px, 3.3vw, 44px); line-height: 1.12; font-weight: 700; letter-spacing: -.03em; max-width: 520px; }
.anm-claim h1 em { font-style: normal; color: var(--gold); }
.anm-claim p { margin-top: 16px; font-size: 16px; line-height: 1.6; color: #b9cadb; max-width: 470px; }
.anm-punkte { display: grid; gap: 14px; margin-top: 34px; }
.anm-punkt { display: flex; gap: 14px; align-items: flex-start; }
.anm-punkt .i { width: 20px; height: 20px; color: #9cc3ec; margin-top: 2px; }
.anm-punkt b { display: block; font-weight: 620; color: #fff; }
.anm-punkt span { color: #a9bccf; font-size: 13.5px; }
.anm-fuss { font-size: 12.5px; color: #8aa2ba; display: flex; gap: 18px; flex-wrap: wrap; }
.anm-siegel { position: absolute; right: -60px; bottom: -60px; width: 320px; height: 320px; border-radius: 50%; border: 1px solid rgba(224,168,59,.25); z-index: 0 !important; }
.anm-siegel::before { content: ""; position: absolute; inset: 26px; border-radius: 50%; border: 1px dashed rgba(224,168,59,.22); }
.anm-siegel::after { content: ""; position: absolute; inset: 70px; border-radius: 50%; background: radial-gradient(circle, rgba(224,168,59,.16), transparent 70%); }
.anm-form-seite { display: grid; place-items: center; padding: 40px 24px; background: var(--flaeche); }
.anm-karte { width: min(400px, 100%); display: grid; gap: 22px; }
.anm-mandant { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-3); background: var(--flaeche-2); border: 1px solid var(--linie); }
.anm-mandant .symbol { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--akzent); color: var(--auf-akzent); font-weight: 700; font-size: 14px; }
.anm-mandant img { width: 36px; height: 36px; border-radius: 10px; object-fit: contain; }
.anm-mandant .name { font-weight: 650; }
.anm-mandant .unter { font-size: 12px; color: var(--text-3); }
.anm-mandant .knopf { margin-left: auto; }
.anm-titel h2 { font-size: 26px; font-weight: 700; letter-spacing: -.02em; }
.anm-titel p { color: var(--text-2); margin-top: 6px; }
.anm-schrittpunkte { display: flex; gap: 6px; }
.anm-schrittpunkte span { width: 22px; height: 4px; border-radius: 99px; background: var(--linie); }
.anm-schrittpunkte span.an { background: var(--akzent); }
.kennwort-feld { position: relative; }
.kennwort-feld .eingabe { padding-right: 44px; }
.kennwort-feld .knopf { position: absolute; right: 3px; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; }
.anm-karte .knopf--gross { width: 100%; }
.anm-hinweis { font-size: 12.5px; color: var(--text-3); text-align: center; line-height: 1.5; }
.codefelder { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.codefelder input { width: 100%; height: 56px; text-align: center; font-size: 24px; font-weight: 650; font-family: var(--schrift-anzeige); border: 1.5px solid var(--linie-2); border-radius: var(--r-3); background: var(--flaeche); outline: none; transition: border-color var(--t), box-shadow var(--t); font-variant-numeric: tabular-nums; }
.codefelder input:nth-child(3) { margin-right: 8px; }
.codefelder input:focus { border-color: var(--akzent); box-shadow: 0 0 0 4px var(--akzent-weich-2); }
.codefelder.falsch input { border-color: var(--fehler); animation: wackeln 360ms; }
@keyframes wackeln { 20%, 60% { transform: translateX(-4px); } 40%, 80% { transform: translateX(4px); } }
.qr-rahmen { display: grid; grid-template-columns: 164px 1fr; gap: 18px; align-items: center; }
.qr-bild { width: 164px; height: 164px; padding: 10px; background: #fff; border-radius: var(--r-3); border: 1px solid var(--linie); }
.qr-bild svg { width: 100%; height: 100%; display: block; }
.regeln { display: grid; gap: 7px; font-size: 13px; }
.regel-punkt { display: flex; align-items: center; gap: 8px; color: var(--text-3); transition: color var(--t); }
.regel-punkt .kreis { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--linie-2); display: grid; place-items: center; flex: none; transition: all var(--t); }
.regel-punkt .kreis .i { width: 11px; height: 11px; stroke-width: 3; opacity: 0; }
.regel-punkt.ok { color: var(--text); }
.regel-punkt.ok .kreis { background: var(--ok); border-color: var(--ok); color: #fff; }
.regel-punkt.ok .kreis .i { opacity: 1; }
.klassen { display: flex; gap: 4px; margin-left: 26px; }
.klassen span { font-size: 11px; padding: 1px 6px; border-radius: 99px; background: var(--flaeche-3); color: var(--text-3); }
.klassen span.an { background: var(--ok-weich); color: var(--ok); font-weight: 600; }
.staerke { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.staerke span { height: 4px; border-radius: 99px; background: var(--linie); transition: background var(--t); }
.mock-hinweis { font-size: 12px; color: var(--text-3); padding: 8px 12px; border-radius: var(--r-2); background: var(--flaeche-2); border: 1px dashed var(--linie-2); }

/* ------------------------------------------------------------------ Archiv */
.archiv {
  --b-seite: 272px; --b-liste: 440px;
  display: grid; grid-template-columns: var(--b-seite) 0 var(--b-liste) 0 minmax(0, 1fr);
  height: 100%; min-height: 0; position: relative;
}
.trenner { position: relative; z-index: 6; cursor: col-resize; touch-action: none; }
.trenner::before { content: ""; position: absolute; top: 0; bottom: 0; left: -5px; width: 10px; }
.trenner::after { content: ""; position: absolute; top: 0; bottom: 0; left: -.5px; width: 1px; background: var(--linie); transition: background var(--t), width var(--t), left var(--t); }
.trenner:hover::after, .trenner.zieht::after, .trenner:focus-visible::after { background: var(--akzent); width: 3px; left: -1.5px; }
.trenner:focus-visible { box-shadow: none; }

/* Seitenleiste */
.a-seite { background: var(--seite); overflow-y: auto; padding: 14px 10px 24px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.a-abschnitt { margin-top: 12px; }
.a-abschnitt:first-child { margin-top: 0; }
.a-abschnitt-kopf { display: flex; align-items: center; justify-content: space-between; padding: 4px 10px 6px; font-size: 11.5px; font-weight: 650; text-transform: uppercase; letter-spacing: .07em; color: var(--text-3); }
.a-abschnitt-kopf .knopf { height: 24px; width: 24px; }
.a-abschnitt-kopf .knopf .i { width: 15px; height: 15px; }

.baum { list-style: none; margin: 0; padding: 0; }
.baum ul { list-style: none; margin: 0; padding: 0; }
.knoten { display: flex; align-items: center; gap: 4px; height: 32px; padding-right: 8px; border-radius: 8px; cursor: pointer; color: var(--text-2); font-size: 13.5px; position: relative; user-select: none; }
.knoten:hover { background: var(--flaeche-3); color: var(--text); }
.knoten:focus-visible { box-shadow: inset 0 0 0 2px var(--akzent); border-radius: 8px; }
.knoten[aria-selected="true"] { background: var(--flaeche); color: var(--text); font-weight: 600; box-shadow: var(--schatten-1), inset 0 0 0 1px var(--linie); }
.knoten[aria-selected="true"] .knoten-symbol { color: var(--akzent); }
.knoten-auf { width: 22px; height: 22px; display: grid; place-items: center; flex: none; border: 0; background: transparent; color: var(--text-3); border-radius: 5px; cursor: pointer; padding: 0; }
.knoten-auf:hover { background: var(--flaeche-3); color: var(--text); }
.knoten-auf .i { width: 14px; height: 14px; stroke-width: 2; transition: transform var(--t); }
.knoten[aria-expanded="false"] > .knoten-auf .i, .archivkopf[aria-expanded="false"] > .knoten-auf .i { transform: rotate(-90deg); }
.knoten-auf.leer { visibility: hidden; }
.knoten-symbol { color: var(--text-3); width: 17px; height: 17px; }
.knoten-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-left: 4px; }
.knoten-zahl { font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; font-weight: 450; }
.knoten .abz { height: 19px; font-size: 10.5px; padding: 0 6px; }

.archivkopf { display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 6px; border-radius: 10px; cursor: pointer; }
.archivkopf:hover { background: var(--flaeche-3); }
.archivkopf[aria-selected="true"] { background: var(--flaeche); box-shadow: var(--schatten-1), inset 0 0 0 1px var(--linie); }
.archivkopf .avatar { width: 30px; height: 30px; font-size: 11.5px; border-radius: 9px; }
.archivkopf-text { flex: 1; min-width: 0; line-height: 1.25; }
.archivkopf-name { font-weight: 620; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.archivkopf-unter { font-size: 11.5px; color: var(--text-3); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.archivkopf .abz { height: 19px; font-size: 10.5px; padding: 0 7px; }

.speicheranzeige { margin: auto 6px 0; padding: 14px 12px 4px; border-top: 1px solid var(--linie); display: grid; gap: 8px; font-size: 12px; color: var(--text-3); }
.speicheranzeige .reihe { display: flex; justify-content: space-between; }

/* Liste */
.a-liste { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--flaeche); }
.liste-kopf { padding: 14px 14px 10px 16px; display: grid; gap: 10px; border-bottom: 1px solid var(--linie); }
.liste-kopf-zeile { display: flex; align-items: center; gap: 8px; min-width: 0; }
.liste-titel { flex: 1; min-width: 0; }
.liste-titel h2 { font-size: 17px; font-weight: 680; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; letter-spacing: -.015em; }
.liste-titel .unter { font-size: 12.5px; color: var(--text-3); display: flex; gap: 6px; align-items: center; }
.liste-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.liste-auswahl-alle { width: 30px; height: 30px; display: grid; place-items: center; }
.liste-inhalt { flex: 1; overflow-y: auto; outline: none; min-height: 0; position: relative; overscroll-behavior: contain; }
.liste-inhalt:focus-visible { box-shadow: inset 0 0 0 2px var(--akzent-linie); border-radius: 0; }
.gruppe-kopf { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; padding: 7px 16px 6px; font-size: 11.5px; font-weight: 650; letter-spacing: .05em; text-transform: uppercase; color: var(--text-3); background: color-mix(in oklab, var(--flaeche) 92%, transparent); backdrop-filter: blur(6px); border-bottom: 1px solid var(--linie-weich); }

.z { display: flex; align-items: flex-start; gap: 12px; padding: var(--zeile-py) 14px var(--zeile-py) 14px; border-bottom: 1px solid var(--linie-weich); position: relative; cursor: default; transition: background 80ms; }
.z:hover { background: var(--flaeche-hover); }
.z[aria-selected="true"] { background: var(--akzent-weich); }
.z.offen { background: var(--akzent-weich-2); }
.z.offen::before { content: ""; position: absolute; left: 0; top: 7px; bottom: 7px; width: 3px; border-radius: 0 3px 3px 0; background: var(--akzent); }
.z.fokus { box-shadow: inset 0 0 0 2px var(--akzent-linie); }
.z-avatar { position: relative; width: 34px; height: 34px; margin-top: 1px; flex: none; border-radius: 50%; border: 0; padding: 0; display: grid; place-items: center; background: var(--av); color: #fff; font-size: 12px; font-weight: 650; cursor: pointer; transition: background var(--t), box-shadow var(--t); }
.z-avatar .i { position: absolute; width: 16px; height: 16px; stroke-width: 2.6; opacity: 0; transition: opacity var(--t); }
.z-avatar .z-ini { transition: opacity var(--t); }
.z:hover .z-avatar, .liste-inhalt.mehrfach .z-avatar { background: var(--flaeche); box-shadow: inset 0 0 0 1.5px var(--linie-2); color: var(--text-3); }
.z:hover .z-avatar .z-ini, .liste-inhalt.mehrfach .z-avatar .z-ini { opacity: 0; }
.z[aria-selected="true"] .z-avatar { background: var(--akzent) !important; box-shadow: none !important; color: var(--auf-akzent) !important; }
.z[aria-selected="true"] .z-avatar .z-ini { opacity: 0; }
.z[aria-selected="true"] .z-avatar .i { opacity: 1; }
.z-avatar:focus-visible { box-shadow: var(--fokus-ring); border-radius: 50%; }
.z-haupt { flex: 1; min-width: 0; display: grid; gap: 2px; }
.z-z1, .z-z2 { display: flex; align-items: center; gap: 8px; min-width: 0; }
.z-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 620; font-size: 13.5px; }
.z-name .an { color: var(--text-3); font-weight: 450; }
.z-datum { font-size: 12px; color: var(--text-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.z-betreff { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); font-size: 13.5px; }
.z-sym { display: inline-flex; gap: 4px; align-items: center; color: var(--text-3); }
.z-sym .i { width: 14px; height: 14px; }
.z-sym .wichtig { color: var(--fehler); stroke-width: 2.4; }
.z-sym .gesperrt { color: var(--gold-text); }
.z-groesse { font-size: 11.5px; color: var(--text-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.z-ordner { font-size: 11px; padding: 0 6px; height: 18px; border-radius: 5px; background: var(--flaeche-3); color: var(--text-3); display: inline-flex; align-items: center; white-space: nowrap; max-width: 120px; overflow: hidden; text-overflow: ellipsis; }

:root[data-dichte="kompakt"] .z { align-items: center; }
:root[data-dichte="kompakt"] .z-avatar { width: 24px; height: 24px; font-size: 9.5px; margin-top: 0; }
:root[data-dichte="kompakt"] .z-avatar .i { width: 13px; height: 13px; }
:root[data-dichte="kompakt"] .z-haupt { display: flex; gap: 10px; align-items: center; }
:root[data-dichte="kompakt"] .z-z1 { flex: 0 0 38%; }
:root[data-dichte="kompakt"] .z-z1 .z-datum { display: none; }
:root[data-dichte="kompakt"] .z-z2 { flex: 1; }
:root[data-dichte="kompakt"] .z-z2 .z-groesse { display: none; }
:root[data-dichte="kompakt"] .z-kompakt-datum { display: inline; }
.z-kompakt-datum { display: none; font-size: 12px; color: var(--text-3); white-space: nowrap; font-variant-numeric: tabular-nums; }

.nachladen { padding: 18px; display: grid; place-items: center; color: var(--text-3); font-size: 12.5px; }
.listenende { padding: 22px 16px 28px; text-align: center; color: var(--text-3); font-size: 12.5px; }
.sk-z { display: flex; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--linie-weich); }
.sk-z .skelett.sk-kreis { width: 34px; height: 34px; }
.sk-z > div:last-child { flex: 1; }

/* Aktionsleiste */
.aktionsleiste { display: flex; align-items: center; gap: 4px; padding: 8px 10px 8px 12px; background: var(--akzent); color: var(--auf-akzent); border-radius: 12px; margin: 10px 10px 0; box-shadow: var(--schatten-2); animation: einblenden 160ms cubic-bezier(.2,.7,.3,1); flex-wrap: wrap; }
.aktionsleiste .anzahl { font-weight: 650; font-size: 13.5px; margin: 0 8px 0 2px; white-space: nowrap; }
.aktionsleiste .knopf { --k-bg: transparent; --k-fg: var(--auf-akzent); --k-rand: transparent; box-shadow: none; height: 32px; padding: 0 9px; }
.aktionsleiste .knopf:hover { background: rgba(255,255,255,.14); }
:root[data-theme="dark"] .aktionsleiste .knopf:hover { background: rgba(0,0,0,.12); }
.aktionsleiste .knopf--icon { width: 32px; padding: 0; margin-left: auto; }

/* Erweiterte Suche */
.erweitert { position: absolute; z-index: 25; top: 10px; left: 50%; transform: translateX(-50%); width: min(820px, calc(100% - 32px)); max-height: calc(100% - 20px); overflow-y: auto; background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--r-4); box-shadow: var(--schatten-3); animation: einblenden 160ms cubic-bezier(.2,.7,.3,1); }
.erweitert-kopf { display: flex; align-items: center; gap: 12px; padding: 18px 20px 4px 24px; }
.erweitert-kopf h2 { font-size: 17px; font-weight: 680; flex: 1; }
.erweitert-inhalt { padding: 14px 24px 8px; display: grid; gap: 18px; }
.erweitert-raster { display: grid; grid-template-columns: 150px 1fr; gap: 14px 18px; align-items: center; }
.erweitert-raster > .feld-name { color: var(--text-2); font-weight: 550; }
.erweitert-fuss { display: flex; gap: 8px; align-items: center; padding: 14px 24px 20px; border-top: 1px solid var(--linie-weich); margin-top: 10px; flex-wrap: wrap; }
.von-bis { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.von-bis .eingabe { width: 170px; }
.von-bis span { color: var(--text-3); }

.syntaxhilfe { width: min(440px, calc(100vw - 24px)); padding: 16px; display: grid; gap: 12px; }
.syntaxhilfe h3 { font-size: 14px; font-weight: 650; }
.syntax-tabelle { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 13px; align-items: baseline; }
.syntax-tabelle button { justify-self: start; border: 1px solid var(--linie); background: var(--flaeche-2); border-radius: 6px; padding: 2px 8px; font-family: var(--mono); font-size: 12.5px; cursor: pointer; color: var(--akzent); white-space: nowrap; }
.syntax-tabelle button:hover { border-color: var(--akzent-linie); background: var(--akzent-weich); }
.syntax-tabelle span { color: var(--text-2); }

/* Lesebereich */
.a-lesen { background: var(--bg); min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.lese-leiste { display: flex; align-items: center; gap: 2px; padding: 10px 14px; min-height: 56px; }
.lese-leiste .trennstrich { width: 1px; height: 20px; background: var(--linie-2); margin: 0 6px; }
.lese-leiste .zurueck { display: none; }
.mailblatt { flex: 1; min-height: 0; margin: 0 16px 16px; background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--r-3); box-shadow: var(--schatten-1); display: flex; flex-direction: column; overflow: hidden; }
.mail-kopf { padding: 20px 24px 0; display: grid; gap: 14px; }
.mail-betreff-zeile { display: flex; align-items: flex-start; gap: 12px; }
.mail-betreff { font-size: 20px; font-weight: 680; line-height: 1.3; letter-spacing: -.018em; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.siegel-abz { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px 0 6px; border-radius: 99px; background: var(--gold-weich); color: var(--gold-text); font-size: 12px; font-weight: 650; white-space: nowrap; box-shadow: inset 0 0 0 1px var(--gold-linie); border: 0; cursor: pointer; flex: none; margin-top: 1px; }
.siegel-abz .siegelpunkt { width: 18px; height: 18px; border-radius: 50%; background: linear-gradient(135deg, #f0c46a, #d4972a); display: grid; place-items: center; color: #0B1F3A; }
.siegel-abz .siegelpunkt .i { width: 12px; height: 12px; stroke-width: 3; }
.siegel-abz:hover { background: color-mix(in oklab, var(--gold-weich) 70%, var(--gold)); }
.mail-absender { display: flex; gap: 12px; align-items: flex-start; }
.mail-absender .avatar { width: 40px; height: 40px; font-size: 14px; }
.mail-personen { flex: 1; min-width: 0; display: grid; gap: 2px; font-size: 13px; }
.mail-von { font-size: 14px; }
.mail-von b { font-weight: 650; }
.mail-von .adr { color: var(--text-3); }
.mail-empf { color: var(--text-2); overflow: hidden; }
.mail-empf .rolle { color: var(--text-3); display: inline-block; min-width: 28px; }
.mail-datum { text-align: right; font-size: 12.5px; color: var(--text-3); white-space: nowrap; display: grid; gap: 4px; justify-items: end; }
.mail-datum b { color: var(--text-2); font-weight: 550; font-size: 13px; }
.mail-marken { display: flex; gap: 6px; flex-wrap: wrap; }
.anhaenge { display: flex; gap: 8px; flex-wrap: wrap; }
.anhang { display: flex; align-items: center; gap: 10px; min-width: 0; max-width: 260px; height: 50px; padding: 0 8px 0 8px; border: 1px solid var(--linie); border-radius: 10px; background: var(--flaeche); cursor: pointer; transition: border-color var(--t), box-shadow var(--t); text-align: left; }
.anhang:hover { border-color: var(--akzent-linie); box-shadow: var(--schatten-1); }
.anhang-typ { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; flex: none; font-size: 9.5px; font-weight: 800; letter-spacing: .02em; color: #fff; position: relative; }
.anhang-typ .i { width: 18px; height: 18px; }
.typ-pdf { background: #c8483a; } .typ-doc { background: #2f65b5; } .typ-xls { background: #217a4b; } .typ-ppt { background: #c4622d; }
.typ-bild { background: #7a58b0; } .typ-zip { background: #7b6a45; } .typ-sonst { background: #5d6b7b; } .typ-mail { background: #2e5c8a; } .typ-kal { background: #b03c6b; }
.anhang-text { min-width: 0; line-height: 1.25; flex: 1; }
.anhang-name { font-size: 13px; font-weight: 580; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.anhang-groesse { font-size: 11.5px; color: var(--text-3); }
.anhang .ladeicon { color: var(--text-3); opacity: 0; transition: opacity var(--t); }
.anhang:hover .ladeicon { opacity: 1; }

.reiter { display: flex; gap: 2px; border-bottom: 1px solid var(--linie); padding: 0 20px; margin-top: 4px; overflow-x: auto; }
.reiter button { position: relative; height: 42px; padding: 0 12px; border: 0; background: transparent; color: var(--text-2); font-weight: 560; font-size: 13.5px; cursor: pointer; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.reiter button:hover { color: var(--text); }
.reiter button[aria-selected="true"] { color: var(--text); }
.reiter button[aria-selected="true"]::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2.5px; border-radius: 3px 3px 0 0; background: var(--akzent); }
.reiter button .i { width: 16px; height: 16px; color: var(--text-3); }
.reiter button[aria-selected="true"] .i { color: var(--akzent); }
.reiter button.gold[aria-selected="true"]::after { background: var(--gold); }
.reiter button.gold .i { color: var(--gold-text); }
.reiter-panel { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.reiter-panel--scroll { overflow-y: auto; }

.banner { display: flex; align-items: center; gap: 10px; margin: 12px 20px 0; padding: 8px 8px 8px 12px; border-radius: 10px; background: var(--flaeche-2); border: 1px solid var(--linie); font-size: 13px; color: var(--text-2); }
.banner .i { color: var(--text-3); }
.banner .knopf { margin-left: auto; }
.mailrahmen { flex: 1; min-height: 240px; width: 100%; border: 0; background: #fff; display: block; }
.mailtext { flex: 1; overflow: auto; margin: 0; padding: 20px 24px; white-space: pre-wrap; font: 14px/1.6 var(--schrift); color: var(--text); overflow-wrap: anywhere; }
.kopfzeilen { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.kopfzeilen td { padding: 6px 20px; vertical-align: top; border-bottom: 1px solid var(--linie-weich); }
.kopfzeilen td:first-child { font-weight: 620; color: var(--text-2); white-space: nowrap; width: 1%; font-family: var(--mono); font-size: 12px; }
.kopfzeilen td:last-child { font-family: var(--mono); font-size: 12px; word-break: break-all; color: var(--text); }
.quelltext { margin: 0; padding: 16px 20px; font: 12px/1.55 var(--mono); white-space: pre-wrap; word-break: break-all; color: var(--text-2); }
.panel-werkzeug { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 20px; border-bottom: 1px solid var(--linie-weich); font-size: 12.5px; color: var(--text-3); position: sticky; top: 0; background: var(--flaeche); z-index: 1; }

/* Nachweis */
.nachweis { padding: 20px; display: grid; gap: 14px; }
.nw-karte { border: 1px solid var(--linie); border-radius: var(--r-3); background: var(--flaeche); overflow: hidden; }
.nw-kopf { display: flex; align-items: center; gap: 12px; padding: 14px 16px; }
.nw-kopf h3 { font-size: 14px; font-weight: 650; flex: 1; }
.nw-kopf .unter { font-size: 12.5px; color: var(--text-3); font-weight: 400; display: block; margin-top: 1px; }
.nw-symbol { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--akzent-weich-2); color: var(--akzent); }
.nw-symbol .i { width: 18px; height: 18px; }
.nw-symbol--gold { background: linear-gradient(135deg, #f0c46a, #d4972a); color: #0B1F3A; box-shadow: 0 2px 8px rgba(212,151,42,.35); }
.nw-symbol--ok { background: var(--ok-weich); color: var(--ok); }
.nw-symbol--fehler { background: var(--fehler-weich); color: var(--fehler); }
.nw-symbol--leise { background: var(--flaeche-3); color: var(--text-3); }
.nw-inhalt { padding: 0 16px 16px; display: grid; gap: 12px; }
.nw-karte--siegel { border-color: var(--gold-linie); background: linear-gradient(180deg, var(--gold-weich), var(--flaeche) 70%); }
.nw-reihen { display: grid; grid-template-columns: max-content 1fr; gap: 7px 18px; font-size: 13px; }
.nw-reihen dt { color: var(--text-3); }
.nw-reihen dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.nw-raster { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* Leerer Lesebereich */
.lese-leer { flex: 1; display: grid; place-items: center; }

/* ------------------------------------------------------------------ Anträge */
.antraege { display: grid; grid-template-columns: 400px minmax(0, 1fr); height: 100%; }
.antr-liste { border-right: 1px solid var(--linie); background: var(--flaeche); display: flex; flex-direction: column; min-height: 0; }
.antr-liste-kopf { padding: 20px 16px 12px 20px; display: grid; gap: 12px; border-bottom: 1px solid var(--linie); }
.antr-liste-kopf h1 { font-size: 20px; font-weight: 700; }
.antr-eintraege { overflow-y: auto; flex: 1; }
.antr-eintrag { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 12px; padding: 14px 16px 14px 18px; border-bottom: 1px solid var(--linie-weich); cursor: pointer; position: relative; }
.antr-eintrag:hover { background: var(--flaeche-hover); }
.antr-eintrag[aria-selected="true"] { background: var(--akzent-weich-2); }
.antr-eintrag[aria-selected="true"]::before { content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--akzent); }
.antr-symbol { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--flaeche-3); color: var(--text-2); }
.antr-symbol--loeschen { background: var(--fehler-weich); color: var(--fehler); }
.antr-symbol--zugriff { background: var(--info-weich); color: var(--info); }
.antr-symbol--dsgvo { background: var(--gold-weich); color: var(--gold-text); }
.antr-titel { font-weight: 620; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.antr-unter { font-size: 12.5px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.antr-detail { overflow-y: auto; background: var(--bg); }
.antr-detail .seite { max-width: 860px; }
.verlauf { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.verlauf li { display: grid; grid-template-columns: 28px 1fr; gap: 12px; position: relative; padding-bottom: 18px; }
.verlauf li::before { content: ""; position: absolute; left: 13px; top: 26px; bottom: 0; width: 2px; background: var(--linie); }
.verlauf li:last-child::before { display: none; }
.verlauf .punkt { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--flaeche-3); color: var(--text-2); }
.verlauf .punkt .i { width: 15px; height: 15px; }
.verlauf .punkt--ok { background: var(--ok-weich); color: var(--ok); }
.verlauf .punkt--fehler { background: var(--fehler-weich); color: var(--fehler); }
.verlauf .punkt--offen { background: var(--warn-weich); color: var(--warn); }
.verlauf .wer { font-weight: 600; }
.verlauf .wann { font-size: 12.5px; color: var(--text-3); }
.zitat { margin-top: 6px; padding: 10px 14px; border-radius: var(--r-2); background: var(--flaeche); border: 1px solid var(--linie); font-size: 13.5px; color: var(--text); white-space: pre-wrap; }
.artwahl { display: grid; gap: 10px; }
.artwahl label { display: grid; grid-template-columns: 40px 1fr; gap: 14px; align-items: start; padding: 14px; border: 1px solid var(--linie); border-radius: var(--r-3); cursor: pointer; transition: border-color var(--t), box-shadow var(--t), background var(--t); position: relative; }
.artwahl label:hover { border-color: var(--linie-2); background: var(--flaeche-2); }
.artwahl label:has(input:checked) { border-color: var(--akzent); box-shadow: 0 0 0 3px var(--akzent-weich-2); background: var(--flaeche); }
.artwahl label:has(input:focus-visible) { box-shadow: var(--fokus-ring); }
.artwahl input { position: absolute; opacity: 0; }
.artwahl b { display: block; font-weight: 650; }
.artwahl span { color: var(--text-2); font-size: 13px; }

/* ------------------------------------------------------------------ Einstellungen */
.einst-zeile { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--linie-weich); }
.einst-zeile:last-child { border-bottom: 0; padding-bottom: 0; }
.einst-zeile:first-child { padding-top: 0; }
.einst-zeile .text b { font-weight: 600; display: block; }
.einst-zeile .text span { font-size: 13px; color: var(--text-3); }
.themawahl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.themawahl label { display: grid; gap: 8px; cursor: pointer; font-size: 13px; font-weight: 550; text-align: center; }
.themawahl input { position: absolute; opacity: 0; }
.themawahl .vorschau { height: 74px; border-radius: 10px; border: 2px solid var(--linie); overflow: hidden; display: grid; grid-template-columns: 30% 1fr; transition: border-color var(--t), box-shadow var(--t); }
.themawahl label:has(input:checked) .vorschau { border-color: var(--akzent); box-shadow: 0 0 0 3px var(--akzent-weich-2); }
.themawahl label:has(input:focus-visible) .vorschau { box-shadow: var(--fokus-ring); }
.vorschau--hell { background: #fff; } .vorschau--hell i { background: #eef1f5; }
.vorschau--dunkel { background: #121a24; } .vorschau--dunkel i { background: #0c121a; }
.vorschau--system { background: linear-gradient(135deg, #fff 50%, #121a24 50%); } .vorschau--system i { background: linear-gradient(135deg, #eef1f5 50%, #0c121a 50%); }
.vorschau i { display: block; }

/* Markenvorschau */
.markenvorschau { border: 1px solid var(--linie); border-radius: var(--r-3); overflow: hidden; display: grid; grid-template-columns: 42% 1fr; height: 300px; box-shadow: var(--schatten-2); background: #fff; }
.markenvorschau .mv-marke { background: linear-gradient(160deg, #0B1F3A, #071324); padding: 20px; color: #fff; display: flex; flex-direction: column; justify-content: space-between; }
.markenvorschau .mv-form { padding: 28px 24px; display: grid; gap: 10px; align-content: center; color: #132030; }
.mv-feld { height: 26px; border-radius: 6px; border: 1px solid #d3dae3; }
.mv-knopf { height: 30px; border-radius: 7px; background: var(--mv-farbe, #A4243B); }
.mv-logo { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: var(--mv-farbe, #A4243B); color: #fff; font-weight: 700; overflow: hidden; }
.mv-logo img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.farbwahl { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.farbwahl button { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--flaeche); box-shadow: 0 0 0 1px var(--linie-2); cursor: pointer; padding: 0; }
.farbwahl button[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--text); }
.farbwahl input[type="color"] { width: 44px; height: 32px; border: 1px solid var(--linie-2); border-radius: 8px; padding: 2px; background: var(--flaeche); cursor: pointer; }

/* Fortschritt */
.fortschritt { display: grid; gap: 8px; }
.fortschritt-zahlen { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; }
.fzahl { padding: 12px 14px; border-radius: var(--r-2); background: var(--flaeche-2); border: 1px solid var(--linie-weich); }
.fzahl b { display: block; font-size: 20px; font-weight: 650; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.fzahl span { font-size: 12px; color: var(--text-3); }
.protokoll { font: 12px/1.6 var(--mono); background: #0f1822; color: #c9d5e2; border-radius: var(--r-2); padding: 12px 14px; max-height: 340px; overflow: auto; }
.protokoll div { display: grid; grid-template-columns: 76px 66px 1fr; gap: 10px; }
.protokoll .zeit { color: #6f8398; }
.protokoll .stufe-info { color: #8db6e2; }
.protokoll .stufe-warnung { color: #eab452; }
.protokoll .stufe-fehler { color: #f0826f; }

/* ------------------------------------------------------------------ Betreiber */
.betreiber-kopf { background: linear-gradient(160deg, #0B1F3A, #071324); color: #eaf1f8; border-bottom: 0; }
.betreiber-kopf .kopf-marke { color: #fff; }
.betreiber-kopf .kopf-marke img { background: rgba(255,255,255,.96); border-radius: 10px; padding: 3px; }
.betreiber-kopf .kopf-marke-mandant { color: #9fb6cc; }
.betreiber-kopf .knopf--leise { color: #c9d8e7; }
.betreiber-kopf .knopf--leise:hover { background: rgba(255,255,255,.1); color: #fff; }
.dienst-reihe { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--linie-weich); }
.dienst-reihe:last-child { border-bottom: 0; }
.dienst-reihe .name { font-weight: 600; flex: 1; }
.dienst-reihe .unter { font-size: 12.5px; color: var(--text-3); }

/* ------------------------------------------------------------------ Mobil */
.nur-mobil { display: none !important; }
.schublade-hintergrund { display: none; }

@media (max-width: 1280px) {
  .archiv { --b-liste: 380px; }
  .raster-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 1100px) {
  .archiv { --b-seite: 236px; }
  .nw-raster { grid-template-columns: 1fr; }
}

@media (max-width: 899px) {
  :root { --kopf-h: 56px; }
  .nur-mobil { display: inline-flex !important; }
  .nur-desktop { display: none !important; }
  .kopf { grid-template-columns: auto minmax(0, 1fr) auto; gap: 8px; padding: 0 8px 0 12px; }
  .kopf-marke-text { display: none; }
  .kopf-marke img { width: 30px; height: 30px; }
  .kopf-link span.txt { display: none; }
  .kopf-link { padding: 0 9px; }
  .suche-feld { height: 40px; }
  .suche-feld kbd { display: none; }
  .benutzerknopf { margin-left: 0; }
  .benutzerknopf .chev { display: none; }

  .archiv { display: block; position: relative; }
  .archiv .trenner { display: none; }
  .a-seite { position: fixed; z-index: 60; top: 0; bottom: 0; left: 0; width: min(320px, 86vw); transform: translateX(-102%); visibility: hidden; transition: transform 220ms cubic-bezier(.2,.7,.3,1), visibility 0s 220ms; box-shadow: var(--schatten-3); padding-top: 16px; }
  .archiv.schublade-offen .a-seite { visibility: visible; transition: transform 220ms cubic-bezier(.2,.7,.3,1); }
  .archiv.schublade-offen .a-seite { transform: none; }
  .archiv.schublade-offen .schublade-hintergrund { display: block; position: fixed; inset: 0; z-index: 55; background: var(--abdunkeln); animation: blende 180ms; }
  .a-liste, .a-lesen { position: absolute; inset: 0; }
  .archiv[data-ansicht="liste"] .a-lesen { display: none; }
  .archiv[data-ansicht="lesen"] .a-liste { display: none; }
  .liste-kopf { padding: 12px 12px 10px 16px; }
  .z { padding-left: 16px; padding-right: 16px; }
  .lese-leiste { padding: 8px 8px; min-height: 52px; }
  .lese-leiste .zurueck { display: inline-flex; }
  .lese-leiste .nur-breit { display: none; }
  .mailblatt { margin: 0; border-radius: 0; border-left: 0; border-right: 0; border-bottom: 0; box-shadow: none; }
  .a-lesen { background: var(--flaeche); }
  .mail-kopf { padding: 16px 16px 0; }
  .mail-betreff { font-size: 18px; }
  .siegel-abz .txt { display: none; }
  .siegel-abz { padding: 0 4px; }
  .reiter { padding: 0 8px; }
  .banner { margin: 10px 16px 0; }
  .nachweis { padding: 16px; }
  .anhang { max-width: 100%; flex: 1 1 100%; }
  .mailtext { padding: 16px; }
  .mailblatt { overflow-y: auto; }
  .reiter-panel { flex: none; }
  .mailrahmen { flex: none; height: 78vh; }
  .reiter button { padding: 0 9px; }
  .reiter button .i { display: none; }
  .mail-absender { flex-wrap: wrap; }
  .mail-personen { flex: 1 1 calc(100% - 52px); }
  .mail-von .adr { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .mail-datum { order: 3; width: 100%; display: flex; gap: 8px; justify-content: flex-start; padding-left: 52px; text-align: left; }
  .anm-logo img { width: 40px; height: 40px; }
  .erweitert { top: 0; left: 0; transform: none; width: 100%; max-height: 100%; height: 100%; border-radius: 0; border: 0; }
  .erweitert-raster { grid-template-columns: 1fr; gap: 6px; }
  .erweitert-raster > .feld-name { margin-top: 10px; }
  .erweitert-inhalt, .erweitert-fuss { padding-left: 16px; padding-right: 16px; }
  .von-bis .eingabe { width: calc(50% - 16px); }

  .anmeldung { grid-template-columns: 1fr; height: auto; min-height: 100dvh; }
  .anm-marke { padding: 22px 20px; }
  .anm-claim, .anm-punkte, .anm-fuss, .anm-siegel { display: none; }
  .anm-form-seite { place-items: start center; padding: 28px 16px 40px; }
  .codefelder { gap: 5px; }
  .codefelder input { height: 50px; font-size: 21px; }
  .codefelder input:nth-child(3) { margin-right: 4px; }
  .qr-rahmen { grid-template-columns: 1fr; justify-items: center; }

  .seite { padding: 20px 16px 48px; }
  .seitenkopf h1 { font-size: 21px; }
  .raster-2, .raster-3, .raster-4 { grid-template-columns: minmax(0, 1fr); }
  .formular-2, .formular-3 { grid-template-columns: 1fr; }
  .spanne-2 { grid-column: auto; }
  .verwaltung { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); }
  .vnav { display: flex; gap: 4px; overflow-x: auto; padding: 8px 12px; border-right: 0; border-bottom: 1px solid var(--linie); }
  .vnav-gruppe { display: contents; }
  .vnav-gruppe h4 { display: none; }
  .vnav a { flex: none; }
  .antraege { grid-template-columns: 1fr; }
  .antraege[data-ansicht="detail"] .antr-liste { display: none; }
  .antraege[data-ansicht="liste"] .antr-detail { display: none; }
  .markenvorschau { grid-template-columns: 1fr; height: auto; }
  .markenvorschau .mv-marke { min-height: 90px; }
  dialog.blatt { width: 100vw; border-radius: 0; }
  .toast-stapel { bottom: 12px; }
  .dl { grid-template-columns: 1fr; gap: 2px; }
  .dl dd { margin-bottom: 8px; }
  .kachel-wert { font-size: 26px; }
  .sparkline { width: 96px; }
}

/* ------------------------------------------------------------------ Druck */
@media print {
  body { overflow: visible; background: #fff; }
  .kopf, .a-seite, .a-liste, .trenner, .lese-leiste, .reiter, .banner, .toast-stapel { display: none !important; }
  .huelle, .archiv, .a-lesen, .mailblatt { display: block !important; height: auto !important; border: 0; box-shadow: none; margin: 0; }
  .mailrahmen { height: 90vh; }
}

.kopf-mitte.unsichtbar > * { visibility: hidden; }
:root[data-theme="dark"] .mailrahmen { margin: 12px; width: calc(100% - 24px); border-radius: 10px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .mailrahmen { margin: 12px; width: calc(100% - 24px); border-radius: 10px; } }
.heute.links::before { left: -2px; transform: none; }
