/* zitro.works App-Inhalte: verbindlicher Hauptframe für alle nativen Apps (docs/UI-HAUPTFRAME.md).
   Farben nur über die Tokens unten – nie hart im App-CSS. Hell/Dunkel schaltet data-theme am <html>. */

:root {
  color-scheme: light;
  /* Flächen */
  --c-canvas: #f2f4f6;          /* Hintergrund des Hauptframes */
  --c-surface: #ffffff;         /* Gruppen, Karten, Tabellen, Dialoge */
  --c-raised: #f8fafb;          /* Tabellenkopf, Dialogfuß, ruhige Zonen */
  --c-subtle: #eaeef2;          /* Segmente, Leerzustand-Icons, Hover auf Flächen */
  --c-hover: #f0f5f8;           /* Zeilen-Hover */
  --c-input: #ffffff;
  --c-side: #e8edf1;            /* Baumnavigation */
  /* Text */
  --c-ink: #14212c;
  --c-ink-2: #3c4f5f;           /* Beschriftungen, Navigation */
  --c-muted: #56667a;
  /* Linien */
  --c-line: #dfe5ea;
  --c-line-soft: #ebeff3;       /* Trenner zwischen Zeilen */
  --c-line-strong: #c4ced7;     /* Eingabefelder */
  /* Akzent (zitro-Petrol) und Zustände */
  --c-accent: #1a6f8f;
  --c-accent-hover: #155d78;
  --c-accent-soft: #e2eff5;
  --c-on-accent: #ffffff;
  --c-focus: #2c7da0;
  --c-good: #1f7a55;
  --c-good-soft: #e3f2ea;
  --c-warn: #8f5d1c;
  --c-warn-soft: #f7eedd;
  --c-bad: #b23b46;
  --c-bad-hover: #9a2f39;
  --c-bad-soft: #f8e6e8;
  --c-notice-ink: #164e63;
  --c-warn-ink: #6b4614;
  --c-bad-ink: #6d2a31;
  --c-good-ink: #165a3f;
  /* Fenster */
  --c-window: #f2f4f6;
  --c-header: #fbfcfd;
  --c-header-idle: #eef1f4;
  --c-header-line: #dfe5eb;
  --c-header-ink: #14212c;
  --c-header-muted: #7a8996;
  --c-backdrop: rgba(15, 28, 42, .38);
  --c-shadow: 0 1px 2px rgba(15, 33, 52, .07);
  --c-shadow-pop: 0 24px 70px rgba(0, 10, 25, .3);
  --c-track: #c4ced7;
  --c-knob: #ffffff;
  --c-code: #0f1d2b;
  --c-code-ink: #d6e3ee;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --c-canvas: #10161b;
  --c-surface: #171f26;
  --c-raised: #1b242c;
  --c-subtle: #222c35;
  --c-hover: #1e2932;
  --c-input: #11181e;
  --c-side: #131a20;
  --c-ink: #e3eaf0;
  --c-ink-2: #b9c6d1;
  --c-muted: #8a9aa8;
  --c-line: #27323c;
  --c-line-soft: #212b34;
  --c-line-strong: #36434f;
  --c-accent: #58b0d1;
  --c-accent-hover: #72c0dc;
  --c-accent-soft: rgba(88, 176, 209, .15);
  --c-on-accent: #062230;
  --c-focus: #64bbdc;
  --c-good: #5cc394;
  --c-good-soft: rgba(92, 195, 148, .14);
  --c-warn: #e3b366;
  --c-warn-soft: rgba(227, 179, 102, .14);
  --c-bad: #f0868e;
  --c-bad-hover: #f59ca3;
  --c-bad-soft: rgba(240, 134, 142, .14);
  --c-notice-ink: #b5dcea;
  --c-warn-ink: #f0d3a2;
  --c-bad-ink: #f6c3c7;
  --c-good-ink: #b6e6cf;
  --c-window: #10161b;
  --c-header: #171f26;
  --c-header-idle: #131a20;
  --c-header-line: #26313b;
  --c-header-ink: #e3eaf0;
  --c-header-muted: #8a9aa8;
  --c-backdrop: rgba(0, 0, 0, .55);
  --c-shadow: 0 1px 2px rgba(0, 0, 0, .4);
  --c-shadow-pop: 0 24px 70px rgba(0, 0, 0, .6);
  --c-track: #3a4753;
  --c-knob: #e9eef2;
  --c-code: #0b1116;
  --c-code-ink: #cfdce6;
}

.zw-win-body, .zw-detached, .zw-overlay, .zw-login-card { color: var(--c-ink); font-size: 13px; }

.zw-muted { color: var(--c-muted); }
.zw-kicker { font-size: 11px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--c-muted); }
.zw-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.zw-grow { flex: 1; }
.zw-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; }
h2, h3, h4 { margin: 0; letter-spacing: -.01em; }
h2 { font-size: 19px; font-weight: 680; }
h3 { font-size: 14px; font-weight: 660; }

/* ------------------------------------------------------------------ Buttons */
.zw-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 32px; padding: 0 12px; border: 1px solid var(--c-line-strong); border-radius: 8px; background: var(--c-surface); color: var(--c-ink); font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; transition: background .12s, border-color .12s, color .12s; }
.zw-btn:hover:not(:disabled) { background: var(--c-subtle); }
.zw-btn:disabled { opacity: .45; cursor: not-allowed; }
.zw-btn.primary { background: var(--c-accent); border-color: var(--c-accent); color: var(--c-on-accent); }
.zw-btn.primary:hover:not(:disabled) { background: var(--c-accent-hover); border-color: var(--c-accent-hover); }
.zw-btn.danger { background: var(--c-bad); border-color: var(--c-bad); color: var(--c-on-accent); }
.zw-btn.danger:hover:not(:disabled) { background: var(--c-bad-hover); }
.zw-btn.quiet, .zw-btn.ghost { border-color: transparent; background: transparent; color: var(--c-muted); }
.zw-btn.quiet:hover:not(:disabled), .zw-btn.ghost:hover:not(:disabled) { background: var(--c-subtle); color: var(--c-ink); }
.zw-btn.small { height: 28px; padding: 0 9px; font-size: 12px; }
.zw-btn.wide { width: 100%; height: 42px; font-size: 14px; }
.zw-icon-btn { display: grid; place-items: center; width: 32px; height: 32px; border: 0; border-radius: 7px; background: transparent; color: var(--c-muted); cursor: pointer; }
.zw-icon-btn:hover { background: var(--c-subtle); color: var(--c-ink); }
@media (pointer: coarse) {
  .zw-btn { min-height: 40px; height: auto; padding-block: 7px; }
  .zw-btn.small { min-height: 36px; height: auto; }
  .zw-icon-btn { width: 40px; height: 40px; }
  .zw-side-btn, .zw-filter-chip { min-height: 40px; }
  .zw-input { min-height: 42px; height: auto; }
}
@media (pointer: coarse) and (max-width: 760px) {
  .zw-input, textarea.zw-input, select.zw-input { font-size: 16px; }
}
.zw-link { border: 0; padding: 0; background: none; color: var(--c-accent); font-weight: 600; cursor: pointer; font-size: 12.5px; }
.zw-link:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--c-focus); outline-offset: 2px; }

/* ------------------------------------------------------------------ Badges & Meter */
.zw-badge { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 999px; background: var(--c-subtle); color: var(--c-muted); font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.zw-badge.good { background: var(--c-good-soft); color: var(--c-good); }
.zw-badge.warn { background: var(--c-warn-soft); color: var(--c-warn); }
.zw-badge.bad { background: var(--c-bad-soft); color: var(--c-bad); }
.zw-badge.info { background: var(--c-accent-soft); color: var(--c-accent); }
.zw-meter { height: 7px; border-radius: 99px; background: color-mix(in srgb, var(--c-muted) 22%, transparent); overflow: hidden; }
.zw-meter span { display: block; height: 100%; border-radius: inherit; background: var(--c-good); transition: width .4s; }
.zw-meter.tone-warn span { background: var(--c-warn); }
.zw-meter.tone-bad span { background: var(--c-bad); }
.zw-meter.tone-info span { background: var(--c-accent); }

/* ------------------------------------------------------------------ Hauptframe: Baum + Inhalt */
.zw-layout { position:relative;flex: 1; min-height: 0; display: grid; grid-template-columns: 58px minmax(0,1fr); background: var(--c-canvas); transition:grid-template-columns .16s ease; }
.zw-layout.nav-expanded { grid-template-columns:220px minmax(0,1fr); }
.zw-side { display:flex;flex-direction:column;gap:1px;padding:12px 8px;background:var(--c-side);border-right:1px solid var(--c-line);overflow-y:auto; }
.zw-layout > .zw-side { z-index:12;min-width:0;gap:0;padding:0;overflow:hidden; }
.zw-side-head { flex:none;display:flex;align-items:center;min-height:54px;padding:8px;border-bottom:1px solid var(--c-line-soft); }
.zw-side-toggle { display:grid;place-items:center;width:40px;height:38px;padding:0;border:0;border-radius:11px;background:var(--c-subtle);color:var(--c-ink-2);cursor:pointer; }
.zw-side-toggle:hover,.zw-side-toggle[aria-expanded="true"] { background:var(--c-hover);color:var(--c-accent); }
.zw-side-body { flex:1;min-height:0;display:flex;flex-direction:column;gap:2px;padding:8px;overflow-y:auto;overflow-x:hidden;scrollbar-width:none; }
.zw-side-body::-webkit-scrollbar { display:none; }
.zw-side-title { padding: 12px 10px 6px; font-size: 11px; font-weight: 650; letter-spacing: .05em; text-transform: uppercase; color: var(--c-muted); }
.zw-side-title:first-child { padding-top: 2px; }
.zw-side-btn { display:flex;align-items:center;gap:10px;width:100%;min-width:40px;min-height:36px;padding:6px 10px;border:0;border-radius:10px;background:transparent;color:var(--c-ink-2);text-align:left;cursor:pointer;font-size:13px; }
.zw-side-btn:hover { background: color-mix(in srgb, var(--c-surface) 60%, transparent); }
.zw-side-btn.active { background: var(--c-surface); color: var(--c-accent); font-weight: 620; box-shadow: var(--c-shadow); }
.zw-side-search { margin-bottom: 5px; color: var(--c-accent); background: color-mix(in srgb,var(--c-accent) 7%,transparent); }
.zw-side-search:hover { background: color-mix(in srgb,var(--c-accent) 12%,var(--c-surface)); }
.zw-side-btn span:first-of-type { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zw-side-btn > svg { flex: none; }
.zw-side-badge { min-width: 20px; padding: 1px 6px; border-radius: 99px; background: var(--c-accent); color: var(--c-on-accent); font-size: 11px; text-align: center; }
.zw-side-update-dot { flex:none;width:8px;height:8px;border-radius:50%;background:var(--c-warn);box-shadow:0 0 0 3px var(--c-warn-soft); }
.zw-layout:not(.nav-expanded) .zw-side-title { height:1px;padding:4px 0;overflow:hidden;color:transparent; }
.zw-layout:not(.nav-expanded) .zw-side-btn { justify-content:center;padding-inline:0; }
.zw-layout:not(.nav-expanded) .zw-side-btn > span,.zw-layout:not(.nav-expanded) .zw-side-badge { position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap; }
.zw-main { position: relative; min-width: 0; min-height: 0; overflow-y: auto; padding: 0 28px 32px; background: var(--c-canvas); }

/* Kopf: Abschnitts-Icon, Titel, Untertitel, Aktionen. Bleibt beim Scrollen stehen. */
.zw-page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.zw-main > .zw-page-head, .zw-main > :first-child > .zw-page-head:first-child { position: sticky; top: 0; z-index: 6; margin: 0 -28px 18px; padding: 20px 28px 14px; background: color-mix(in srgb, var(--c-canvas) 92%, transparent); backdrop-filter: blur(10px); }
.zw-page-head.scrolled { box-shadow: 0 1px 0 var(--c-line); }
.zw-page-head > .zw-page-title { flex: 1; min-width: 0; }
.zw-page-head h2 { font-size: 20px; font-weight: 700; letter-spacing: -.018em; line-height: 1.25; }
.zw-page-head p { margin: 3px 0 0; font-size: 13px; line-height: 1.45; max-width: 72ch; }
.zw-page-head > .zw-row { flex: none; justify-content: flex-end; }
.zw-page-icon { display: grid; place-items: center; flex: none; width: 42px; height: 42px; border-radius: 12px; color: #fff;
  background: linear-gradient(160deg, color-mix(in srgb, var(--zw-section, #2f7fb5) 62%, #fff), var(--zw-section, #2f7fb5) 52%, color-mix(in srgb, var(--zw-section, #2f7fb5) 72%, #000));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .28), 0 3px 10px color-mix(in srgb, var(--zw-section, #2f7fb5) 28%, transparent); }
.zw-page-icon svg { stroke-width: 2; }
.zw-page-head + .zw-tabs-wrap > .zw-tabs, .zw-page-head + .zw-tabs { margin-top: -4px; }
.zw-section { margin-top: 26px; }
.zw-section > h3 { margin-bottom: 10px; }
.zw-toolbar { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: var(--c-surface); border-bottom: 1px solid var(--c-line); flex-wrap: wrap; }

/* Segmente statt Unterstrich-Tabs */
.zw-tabs { display: inline-flex; min-height: 34px; align-items: center; align-self: flex-start; justify-self: start; gap: 2px; max-width: 100%; margin-bottom: 20px; padding: 3px; border-radius: 10px; background: var(--c-subtle); overflow-x: auto; scrollbar-width: none; }
.zw-tabs button { flex: none; height: 28px; padding: 0 13px; border: 0; border-radius: 7px; background: transparent; color: var(--c-ink-2); font-weight: 600; font-size: 12.5px; white-space: nowrap; cursor: pointer; transition: background .12s, color .12s; }
.zw-tabs button:hover { color: var(--c-ink); }
.zw-tabs button.active { background: var(--c-surface); color: var(--c-ink); box-shadow: 0 1px 2px rgba(15, 33, 52, .12), 0 0 0 1px color-mix(in srgb, var(--c-ink) 4%, transparent); }
.zw-tabs-wrap { min-width: 0; }

/* Segmentschalter fuer Ansichten und Filter (war nur im Kalender-Stil) */
.zw-segmented { display: inline-flex; min-height: 34px; align-items: center; gap: 2px; padding: 3px; border-radius: 9px; background: var(--c-subtle); }
.zw-segmented button { height: 28px; padding: 0 12px; border: 0; border-radius: 7px; background: transparent; color: var(--c-ink-2); font: inherit; font-size: 12.5px; font-weight: 600; white-space: nowrap; cursor: pointer; }
.zw-segmented button:hover { color: var(--c-ink); }
.zw-segmented button:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 1px; }
.zw-segmented button.active { background: var(--c-surface); color: var(--c-ink); box-shadow: 0 1px 2px rgba(15, 33, 52, .12), 0 0 0 1px color-mix(in srgb, var(--c-ink) 4%, transparent); }

/* ------------------------------------------------------------------ Karten und Kennzahlen */
.zw-card { padding: 16px 18px; border: 1px solid var(--c-line); border-radius: 12px; background: var(--c-surface); }
.zw-card + .zw-card { margin-top: 12px; }
.zw-card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.zw-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.zw-stat { padding: 14px 16px; border: 1px solid var(--c-line); border-radius: 12px; background: var(--c-surface); }
.zw-stat small { display: block; color: var(--c-muted); font-size: 12px; }
.zw-stat strong { display: block; margin-top: 4px; font-size: 20px; font-weight: 700; letter-spacing: -.015em; font-variant-numeric: tabular-nums; }
.zw-stat .zw-meter { margin-top: 10px; }

/* ------------------------------------------------------------------ Tabellen */
.zw-table-wrap { border: 1px solid var(--c-line); border-radius: 12px; background: var(--c-surface); overflow: auto; }
.zw-table { width: 100%; border-collapse: collapse; }
.zw-table th { position: sticky; top: 0; z-index: 1; height: 36px; padding: 0 14px; background: var(--c-raised); border-bottom: 1px solid var(--c-line); color: var(--c-muted); font-size: 12px; font-weight: 620; text-align: left; white-space: nowrap; }
.zw-table td { height: 44px; padding: 6px 14px; border-bottom: 1px solid var(--c-line-soft); vertical-align: middle; }
.zw-table tr:last-child td { border-bottom: 0; }
.zw-table tr.clickable { cursor: pointer; }
.zw-table tbody tr:hover td { background: var(--c-hover); }
.zw-table tr.selected td { background: var(--c-accent-soft); }
.zw-kv { display: grid; grid-template-columns: max-content 1fr; gap: 7px 18px; margin: 0; }
.zw-kv dt { color: var(--c-muted); }
.zw-kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* ------------------------------------------------------------------ Formulare (Dialoge: gestapelt) */
.zw-form-grid { display: grid; gap: 14px; }
.zw-form-grid.two { grid-template-columns: 1fr 1fr; }
.zw-field { display: grid; gap: 5px; min-width: 0; }
.zw-field > label { font-size: 12px; font-weight: 600; color: var(--c-ink-2); }
.zw-field > small { color: var(--c-muted); font-size: 11.5px; line-height: 1.4; }
.zw-input { width: 100%; height: 34px; padding: 0 10px; border: 1px solid var(--c-line-strong); border-radius: 8px; background: var(--c-input); color: var(--c-ink); outline: none; font-size: 13px; transition: border-color .12s, box-shadow .12s; }
select.zw-input { padding-right: 28px; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238a9aa8' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 9px center; }
textarea.zw-input { height: auto; min-height: 90px; padding: 8px 10px; resize: vertical; line-height: 1.5; }
.zw-input:focus { border-color: var(--c-focus); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c-focus) 18%, transparent); }
.zw-input::placeholder { color: var(--c-muted); opacity: .8; }
.zw-input-short { max-width: 140px; }
.zw-search { height: 32px; padding: 0 10px 0 32px; border: 1px solid var(--c-line-strong); border-radius: 8px; background: var(--c-input) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%238a9aa8' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") 10px center no-repeat; color: var(--c-ink); outline: none; min-width: 200px; }
.zw-search:focus { border-color: var(--c-focus); }
.zw-form-message { margin: 0; padding: 9px 11px; border-radius: 8px; font-size: 12.5px; background: var(--c-bad-soft); color: var(--c-bad); }
.zw-form-message.info { background: var(--c-accent-soft); color: var(--c-accent); }
.zw-form-message.good { background: var(--c-good-soft); color: var(--c-good); }
.zw-toggle { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; user-select: none; }
.zw-toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.zw-toggle-track { position: relative; width: 36px; height: 20px; border-radius: 99px; background: var(--c-track); transition: background .15s; flex: none; }
.zw-toggle-track::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--c-knob); box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .15s; }
.zw-toggle input:checked + .zw-toggle-track { background: var(--c-accent); }
.zw-toggle input:checked + .zw-toggle-track::after { transform: translateX(16px); }
.zw-toggle input:focus-visible + .zw-toggle-track { outline: 2px solid var(--c-focus); outline-offset: 2px; }
input[type=checkbox], input[type=radio] { accent-color: var(--c-accent); }

/* ------------------------------------------------------------------ Einstellungen: Gruppen mit Zeilen
   Gruppentitel über einer ruhigen Fläche; jede Zeile: Beschriftung + Hinweis links, Bedienelement rechts. */
.zw-settings { display: grid; gap: 24px; max-width: 880px; }
.zw-group { min-width: 0; margin: 0; padding: 0; border: 0; }
.zw-group > legend { float: left; width: 100%; margin: 0 0 3px; padding: 0 2px; font-size: 13.5px; font-weight: 700; color: var(--c-ink); }
.zw-group > legend + * { clear: both; }
.zw-group > .zw-group-text { margin: 0 2px 8px; color: var(--c-muted); font-size: 12.5px; line-height: 1.45; max-width: 76ch; }
.zw-group-card { display: grid; border: 1px solid var(--c-line); border-radius: 12px; background: var(--c-surface); overflow: hidden; }
.zw-group-card > * { margin: 0; padding: 12px 16px; }
.zw-group-card > * + * { border-top: 1px solid var(--c-line-soft); }
:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) { display: grid; grid-template-columns: minmax(120px, 1fr) minmax(160px, 340px); grid-template-areas: "label control" "hint control"; column-gap: 28px; row-gap: 2px; align-items: center; min-height: 52px; }
:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) > label:first-child { grid-area: label; align-self: end; font-size: 13px; font-weight: 600; color: var(--c-ink); }
:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) > small { grid-area: hint; align-self: start; font-size: 12px; }
:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field):not(:has(> small)) > label:first-child { grid-row: 1 / span 2; align-self: center; }
:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) > :not(label:first-child):not(small) { grid-area: control; grid-row: 1 / span 2; justify-self: stretch; }
:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) > :is(.zw-input-short, input[type=number]):not(label:first-child):not(small) { justify-self: end; width: 140px; }
:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) > .zw-toggle:not(label:first-child) { justify-self: end; }
/* Textfelder und ausdrücklich breite Felder: untereinander */
:where(:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field).wide, :where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field):has(> textarea)) { grid-template-columns: 1fr; grid-template-areas: "label" "control" "hint"; }
:where(:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field).wide, :where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field):has(> textarea)) > :not(label:first-child):not(small) { grid-row: auto; }
:where(:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field).wide, :where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field):has(> textarea)) > label:first-child { grid-row: auto; margin-bottom: 4px; }
:where(:where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field).wide, :where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field):has(> textarea)) > small { margin-top: 4px; }
/* Raster in Gruppen werden zu Zeilen; Schalterlisten zu einzelnen Zeilen */
.zw-group-card.zw-group-card > :is(.zw-form-grid, .zw-form-row) { display: grid; grid-template-columns: 1fr; gap: 0; padding: 0; }
.zw-group-card > :is(.zw-form-grid, .zw-form-row) > * { padding: 12px 16px; }
.zw-group-card > :is(.zw-form-grid, .zw-form-row) > * + * { border-top: 1px solid var(--c-line-soft); }
.zw-group-card > .zw-toggle, .zw-group-card > .zw-check-list > .zw-toggle { display: flex; justify-content: space-between; flex-direction: row-reverse; gap: 24px; min-height: 48px; font-weight: 600; }
.zw-group-card > .zw-check-list { display: grid; gap: 0; padding: 0; }
.zw-group-card > .zw-check-list > * { padding: 12px 16px; }
.zw-group-card > .zw-check-list > * + * { border-top: 1px solid var(--c-line-soft); }
.zw-group-card > .zw-radio-list { gap: 12px; padding: 14px 16px; }
.zw-group-card > .zw-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 320px); gap: 0; padding: 0; }
.zw-group-card > .zw-split > .zw-form-grid { gap: 0; }
.zw-group-card > .zw-split > .zw-form-grid > * { padding: 12px 16px; }
.zw-group-card > .zw-split > .zw-form-grid > * + * { border-top: 1px solid var(--c-line-soft); }
.zw-group-card > .zw-split > :last-child { margin: 12px 16px 12px 0; }
.zw-group-card > .zw-table-wrap { padding: 0; border: 0; border-radius: 0; }
.zw-group-card > .zw-table-wrap + *, .zw-group-card > * + .zw-table-wrap { border-top: 1px solid var(--c-line-soft); }
/* Ältere Gruppen ohne Zeilenfläche (z. B. in Dialogen): als ruhige Fläche mit Abstand */
.zw-group:not(:has(> .zw-group-card)) { display: grid; gap: 10px; padding: 12px 16px 14px; border: 1px solid var(--c-line); border-radius: 12px; background: var(--c-surface); }
.zw-group:not(:has(> .zw-group-card)) > legend { float: none; padding: 0 4px; margin: 0 0 0 -4px; width: auto; }
.zw-group:not(:has(> .zw-group-card)) > p { margin: 0; }
.zw-dialog .zw-group:not(:has(> .zw-group-card)) { background: var(--c-raised); }
.zw-settings-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
.zw-settings-actions > .zw-muted { margin-right: auto; }
/* Speicherleiste: erscheint erst bei Änderungen */
.zw-savebar { position: sticky; bottom: 14px; z-index: 5; display: none; align-items: center; gap: 10px; padding: 10px 12px 10px 16px; border: 1px solid var(--c-line); border-radius: 12px; background: color-mix(in srgb, var(--c-surface) 94%, transparent); box-shadow: 0 10px 30px rgba(0, 10, 25, .14); backdrop-filter: blur(10px); }
.zw-savebar.dirty, .zw-savebar.busy { display: flex; animation: zw-savebar-in .18s ease-out; }
@keyframes zw-savebar-in { from { opacity: 0; transform: translateY(8px); } }
.zw-savebar > .zw-savebar-text { flex: 1; display: flex; align-items: center; gap: 8px; font-weight: 600; }
.zw-savebar > .zw-savebar-text::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--c-warn); }
.zw-settings-status { color: var(--c-muted); font-size: 12px; margin: -12px 2px 0; }

/* ------------------------------------------------------------------ Zustände */
.zw-empty { display: grid; justify-items: center; gap: 6px; padding: 42px 20px; color: var(--c-muted); text-align: center; }
.zw-empty strong { color: var(--c-ink); font-size: 14px; }
.zw-empty p { margin: 0; max-width: 420px; }
.zw-empty-icon { display: grid; place-items: center; width: 58px; height: 58px; margin-bottom: 6px; border-radius: 16px; background: var(--c-subtle); color: var(--c-muted); }
.zw-loading { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 40px; color: var(--c-muted); }
.zw-spinner { width: 20px; height: 20px; border: 2.5px solid color-mix(in srgb, var(--c-muted) 25%, transparent); border-top-color: var(--c-focus); border-radius: 50%; animation: zw-spin .8s linear infinite; }
.zw-spinner.small { width: 14px; height: 14px; border-width: 2px; border-top-color: var(--zw-brand, #ffcf3f); }
@keyframes zw-spin { to { transform: rotate(360deg); } }
.zw-progress { display: grid; gap: 5px; width: 100%; min-width: 150px; }
.zw-progress-label { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--c-muted); font-size: 11px; line-height: 1.35; }
.zw-progress-label > span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zw-progress-label strong { flex: none; color: var(--c-ink); font-variant-numeric: tabular-nums; }
.zw-progress-track { position: relative; height: 7px; overflow: hidden; border-radius: 999px; background: var(--c-subtle); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c-line) 75%, transparent); }
.zw-progress-fill { display: block; height: 100%; border-radius: inherit; background: var(--c-accent); transition: width .25s ease; }
.zw-progress.good .zw-progress-fill { background: var(--c-good); }
.zw-progress.warn .zw-progress-fill { background: var(--c-warn); }
.zw-progress.bad .zw-progress-fill { background: var(--c-bad); }
.zw-progress.indeterminate .zw-progress-fill { width: 42%; animation: zw-progress-indeterminate 1.15s ease-in-out infinite; }
@keyframes zw-progress-indeterminate { from { transform: translateX(-110%); } to { transform: translateX(340%); } }
@media (prefers-reduced-motion: reduce) { .zw-progress-fill { transition: none; }.zw-progress.indeterminate .zw-progress-fill { animation-duration: 2.4s; } }
.zw-error-box { display: flex; gap: 12px; align-items: flex-start; margin: 16px 0; padding: 14px 16px; border-radius: 12px; background: var(--c-bad-soft); color: var(--c-bad); }
.zw-error-box p { margin: 3px 0 0; color: var(--c-bad-ink); }
.zw-error-box .zw-btn { margin-left: auto; }
.zw-notice { display: flex; gap: 10px; align-items: flex-start; padding: 11px 13px; border-radius: 10px; background: var(--c-accent-soft); color: var(--c-notice-ink); margin-bottom: 14px; }
.zw-notice.warn { background: var(--c-warn-soft); color: var(--c-warn-ink); }
.zw-notice.bad { background: var(--c-bad-soft); color: var(--c-bad-ink); }
.zw-notice.good { background: var(--c-good-soft); color: var(--c-good-ink); }
.zw-notice p { margin: 0; }

/* ------------------------------------------------------------------ Dialoge */
.zw-overlay { position: absolute; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; background: var(--c-backdrop); animation: zw-fade .12s ease-out; }
@keyframes zw-fade { from { opacity: 0; } }
.zw-dialog { max-width: 100%; max-height: 100%; display: flex; flex-direction: column; border: 1px solid var(--c-line); border-radius: 14px; background: var(--c-surface); color: var(--c-ink); box-shadow: var(--c-shadow-pop); overflow: hidden; }
.zw-dialog header { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px 10px 20px; }
.zw-dialog-body { padding: 4px 20px 16px; overflow-y: auto; display: grid; gap: 12px; }
.zw-dialog-body > p { margin: 0; line-height: 1.55; }
.zw-dialog footer { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 16px; background: var(--c-raised); border-top: 1px solid var(--c-line); }

/* Nicht-modale Arbeitsflaechen: App-Kontext bleibt sichtbar und bedienbar. */
.zw-app-surface-host { position: relative; }
.zw-app-surface-layer { position: absolute; inset: 0; z-index: 96; pointer-events: none; overflow: hidden; }
.zw-app-surface { pointer-events: auto; position: absolute; display: flex; flex-direction: column; width: min(var(--zw-app-surface-width, 480px), calc(100% - 20px)); max-height: calc(100% - 20px); color: var(--c-ink); background: var(--c-surface); border: 1px solid var(--c-line); box-shadow: var(--c-shadow-pop); overflow: hidden; animation: zw-app-surface-in .16s ease-out; }
.zw-app-surface.flyout { inset: 0 0 0 auto; width: min(var(--zw-app-surface-width, 480px), 100%); max-height: none; border-width: 0 0 0 1px; border-radius: 0; }
.zw-app-surface.workspace { inset: 10px; width: auto; max-height: none; border-radius: 14px; }
.zw-app-surface.popover { border-radius: 14px; }
.zw-app-surface header { flex: none; display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; padding: 16px 16px 12px 20px; border-bottom: 1px solid var(--c-line); }
.zw-app-surface-title { min-width: 0; display: grid; gap: 3px; }
.zw-app-surface-title h3, .zw-app-surface-title p { margin: 0; }
.zw-app-surface-title h3 { line-height: 1.3; }
.zw-app-surface-body { flex: 1; min-height: 0; padding: 16px 20px 22px; overflow: auto; display: grid; align-content: start; gap: 12px; }
.zw-app-surface-body > p { margin: 0; line-height: 1.55; }
.zw-app-surface footer { flex: none; display: flex; justify-content: flex-end; gap: 8px; padding: 12px 16px; background: var(--c-raised); border-top: 1px solid var(--c-line); }
@keyframes zw-app-surface-in { from { opacity: 0; transform: translateX(10px); } }
@media (prefers-reduced-motion: reduce) { .zw-app-surface { animation: none; } }
/* Nicht blockierende Arbeitsfläche: Standard für Anzeigen, Bearbeiten und
   Anlegen. Der Inhalt dahinter bleibt erreichbar; nur confirm() verwendet
   weiterhin die zentrierte, blockierende .zw-overlay. */
.zw-overlay.zw-sheet-layer { place-items: stretch end; padding: 0; background: transparent; pointer-events: none; animation: none; }
.zw-overlay.zw-sheet-layer.leaving { opacity: 1; }
.zw-sheet { height: 100%; max-height: none; border-width: 0 0 0 1px; border-radius: 0; pointer-events: auto; box-shadow: -18px 0 48px rgba(2, 10, 22, .24); animation: zw-sheet-in .18s cubic-bezier(.2,.8,.2,1); }
.zw-sheet-layer.leaving .zw-sheet { opacity: 0; transform: translateX(26px); transition: opacity .14s ease, transform .14s ease; }
.zw-sheet > header { min-height: 58px; padding: 12px 12px 12px 20px; border-bottom: 1px solid var(--c-line); background: color-mix(in srgb, var(--c-surface) 92%, transparent); backdrop-filter: blur(16px); }
.zw-sheet > header .zw-page-title { min-width: 0; }
.zw-sheet > header h3 { margin: 0; font-size: 16px; letter-spacing: -.012em; }
.zw-sheet > header p { margin: 2px 0 0; font-size: 12px; }
.zw-sheet > .zw-dialog-body { flex: 1; align-content: start; padding: 18px 20px 28px; }
.zw-sheet > footer { position: sticky; bottom: 0; min-height: 58px; padding: 10px 16px; background: color-mix(in srgb, var(--c-raised) 94%, transparent); backdrop-filter: blur(16px); }
@keyframes zw-sheet-in { from { opacity: .55; transform: translateX(28px); } }

/* Gemeinsame native App-Rahmen. */
.zw-app-frame { display: grid; grid-template-columns: auto minmax(0,1fr) auto; width: 100%; height: 100%; min-height: 0; overflow: hidden; background: var(--c-canvas); color: var(--c-ink); container-type: inline-size; }
.zw-app-nav { min-width: 210px; max-width: 280px; overflow: auto; border-right: 1px solid var(--c-line); background: var(--c-raised); }
.zw-app-main { min-width: 0; min-height: 0; overflow: auto; }
.zw-app-inspector { width: clamp(260px,26cqw,380px); min-width: 0; overflow: auto; border-left: 1px solid var(--c-line); background: var(--c-surface); }
.zw-collection-view { display: grid; grid-template-rows: auto minmax(0,1fr); width: 100%; height: 100%; min-height: 0; }
.zw-collection-toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-height: 54px; padding: 9px 14px; border-bottom: 1px solid var(--c-line); background: color-mix(in srgb,var(--c-surface) 90%,transparent); }
.zw-collection-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; width: 100%; }
.zw-collection-head { position: relative; z-index: 11; display: flex; align-items: center; gap: 12px; min-height: 76px; padding: 13px 18px; border-bottom: 1px solid var(--c-line); background: color-mix(in srgb,var(--c-surface) 92%,transparent); }
.zw-collection-heading { display: grid; min-width: 0; gap: 2px; }.zw-collection-heading h2,.zw-collection-heading p { margin: 0; }.zw-collection-heading h2 { overflow: hidden; font-size: 20px; letter-spacing: -.025em; text-overflow: ellipsis; white-space: nowrap; }.zw-collection-heading p { color: var(--c-muted); font-size: 12px; }
.zw-collection-head-actions { display: flex; align-items: center; gap: 5px; margin-left: auto; }.zw-collection-head-actions > small { margin-right: 4px; color: var(--c-muted); font-size: 10px; }
.zw-collection-head-action,.zw-collection-search-toggle { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 11px; color: var(--c-ink-2); background: transparent; cursor: pointer; }.zw-collection-head-action:hover,.zw-collection-search-toggle:hover { color: var(--c-accent); background: var(--c-hover); }
.zw-choice-popover { position: relative; min-width: 0; }.zw-choice-popover > summary { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 7px 9px; border-radius: 12px; color: var(--c-ink); list-style: none; cursor: pointer; }.zw-choice-popover > summary::-webkit-details-marker { display: none; }.zw-choice-popover > summary:hover,.zw-choice-popover[open] > summary { background: var(--c-hover); }.zw-choice-popover > summary > span { display: grid; min-width: 0; gap: 1px; }.zw-choice-popover > summary strong { overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }.zw-choice-popover.cards > summary strong { font-size: 20px; letter-spacing: -.025em; }.zw-choice-popover > summary small { overflow: hidden; color: var(--c-muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }.zw-choice-popover > summary > svg:last-child { flex: none; transition: transform .16s ease; }.zw-choice-popover[open] > summary > svg:last-child { transform: rotate(180deg); }
.zw-choice-panel { position: absolute; z-index: 80; top: calc(100% + 8px); left: 0; width: min(320px,calc(100vw - 36px)); padding: 7px; border: 1px solid var(--c-line); border-radius: 15px; background: color-mix(in srgb,var(--c-raised) 97%,transparent); box-shadow: var(--c-shadow-pop); backdrop-filter: blur(20px); }.zw-choice-panel > header { padding: 8px 9px 10px; color: var(--c-muted); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; }.zw-choice-options { display: grid; gap: 3px; }.zw-choice-options > button { display: grid; grid-template-columns: auto minmax(0,1fr) 18px; align-items: center; gap: 9px; width: 100%; min-height: 42px; padding: 8px 9px; border: 0; border-radius: 10px; color: var(--c-ink); background: transparent; text-align: left; cursor: pointer; }.zw-choice-options > button:hover,.zw-choice-options > button.active { background: var(--c-hover); }.zw-choice-options > button.active { color: var(--c-accent); }.zw-choice-options > button > span:not(.zw-choice-icon) { display: grid; gap: 2px; }.zw-choice-options > button small { color: var(--c-muted); font-size: 10px; }.zw-choice-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; color: var(--c-accent); background: color-mix(in srgb,var(--c-accent) 10%,var(--c-surface)); }
.zw-choice-popover.cards .zw-choice-panel { width: min(460px,calc(100vw - 36px)); padding: 12px; }.zw-choice-popover.cards .zw-choice-options { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }.zw-choice-popover.cards .zw-choice-options > button { min-height: 92px; align-content: center; border: 1px solid var(--c-line); background: color-mix(in srgb,var(--c-surface) 72%,transparent); }.zw-choice-popover.cards .zw-choice-options > button:hover,.zw-choice-popover.cards .zw-choice-options > button.active { border-color: color-mix(in srgb,var(--c-accent) 48%,var(--c-line)); background: color-mix(in srgb,var(--c-accent) 8%,var(--c-surface)); }
.zw-nav-disclosure { position: relative; }.zw-nav-disclosure > summary { display: grid; grid-template-columns: 20px minmax(0,1fr) 14px; align-items: center; gap: 8px; min-height: 36px; padding: 6px 8px; border-radius: 10px; color: var(--c-ink-2); list-style: none; cursor: pointer; }.zw-nav-disclosure > summary::-webkit-details-marker { display: none; }.zw-nav-disclosure > summary:hover,.zw-nav-disclosure.active > summary { color: var(--c-accent); background: var(--c-hover); }.zw-nav-disclosure > summary > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.zw-nav-disclosure > summary > svg:last-child { transition: transform .16s ease; }.zw-nav-disclosure[open] > summary > svg:last-child { transform: rotate(180deg); }.zw-nav-disclosure-items { display: grid; gap: 3px; padding: 3px 0 4px 15px; }
.zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure > summary { position:relative;grid-template-columns:1fr;justify-items:center;padding-inline:0; }
.zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure > summary > span { position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0); }
.zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure > summary > svg:last-child { position:absolute;left:-4px;width:11px;height:11px; }
.zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure-items { gap:3px;padding:3px 0 5px; }
.zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure-items .zw-nav-disclosure > summary { min-height:32px;transform:scale(.9); }
.zw-collection-search { display: flex; align-items: center; gap: 7px; min-width: min(300px,100%); height: 34px; padding: 0 10px; border: 1px solid var(--c-line); border-radius: 10px; color: var(--c-muted); background: var(--c-input); }
.zw-collection-search:focus-within { border-color: color-mix(in srgb,var(--c-accent) 55%,var(--c-line)); box-shadow: 0 0 0 3px color-mix(in srgb,var(--c-accent) 12%,transparent); }
.zw-collection-search input { width: 100%; min-width: 0; padding: 0; border: 0; outline: 0; background: transparent; color: var(--c-ink); }
.zw-collection-search > button { display: grid; place-items: center; flex: none; width: 25px; height: 25px; padding: 0; border: 0; border-radius: 7px; color: var(--c-muted); background: transparent; cursor: pointer; }.zw-collection-search > button:hover { color: var(--c-ink); background: var(--c-hover); }
.zw-collection-tools > .zw-collection-search { display: none; }.zw-collection-tools.searching > .zw-collection-search { display: flex; flex: 1 1 320px; }.zw-collection-tools.searching > .zw-collection-search-toggle { display: none; }
.zw-native-search-host { position: relative !important; isolation: isolate; }
.zw-native-search-surface { position: absolute; inset: 0; z-index: 40; display: flex; flex-direction: column; gap: 18px; min-width: 0; padding: 20px 22px 28px; overflow: auto; color: var(--c-ink); background: color-mix(in srgb,var(--c-surface) 97%,var(--c-canvas)); animation: zw-native-search-in .16s ease-out; }
.zw-native-search-head { display: flex; align-items: flex-start; gap: 14px; }.zw-native-search-head > button { display: grid; place-items: center; flex: none; width: 34px; height: 34px; margin-top: 1px; padding: 0; border: 0; border-radius: 10px; color: var(--c-ink-2); background: transparent; cursor: pointer; }.zw-native-search-head > button:hover { color: var(--c-accent); background: var(--c-hover); }
.zw-native-search-head h2,.zw-native-search-head p { margin: 0; }.zw-native-search-head h2 { font-size: 24px; letter-spacing: -.03em; }.zw-native-search-head p { margin-top: 4px; color: var(--c-muted); font-size: 13px; }
.zw-native-search-box { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 10px 0 15px; border: 1px solid color-mix(in srgb,var(--c-accent) 58%,var(--c-line)); border-radius: 16px; background: var(--c-input); box-shadow: 0 0 0 5px color-mix(in srgb,var(--c-accent) 10%,transparent); }.zw-native-search-box > svg { flex: none; color: var(--c-muted); }.zw-native-search-box > input { flex: 1; min-width: 0; padding: 0; border: 0; outline: 0; color: var(--c-ink); background: transparent; font-size: 16px; }.zw-native-search-box .zw-choice-popover > summary { min-height: 34px; border: 0; background: transparent; }.zw-native-search-go { display: grid; place-items: center; flex: none; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 10px; color: var(--c-ink-2); background: transparent; cursor: pointer; }.zw-native-search-go:hover { color: var(--c-accent); background: var(--c-hover); }
.zw-native-search-examples { display: grid; gap: 8px; }.zw-native-search-examples > small { color: var(--c-muted); font-size: 12px; font-weight: 650; }.zw-native-search-examples > div { display: flex; flex-wrap: wrap; gap: 7px; }.zw-native-search-examples button { padding: 7px 11px; border: 1px solid var(--c-line); border-radius: 999px; color: var(--c-ink-2); background: transparent; cursor: pointer; }.zw-native-search-examples button:hover { color: var(--c-accent); border-color: color-mix(in srgb,var(--c-accent) 45%,var(--c-line)); background: var(--c-hover); }
.zw-native-search-tips { display: grid; gap: 10px; }.zw-native-search-tips h3 { margin: 4px 0 0; font-size: 15px; }.zw-native-search-tips > div { display: grid; gap: 3px; }.zw-native-search-tips button { display: grid; grid-template-columns: 30px minmax(0,1fr); align-items: center; gap: 10px; width: 100%; padding: 10px; border: 0; border-radius: 12px; color: var(--c-ink-2); background: transparent; text-align: left; cursor: pointer; }.zw-native-search-tips button:hover { background: var(--c-hover); }.zw-native-search-tips button > svg { color: var(--c-accent); }.zw-native-search-tips button span { display: grid; gap: 2px; }.zw-native-search-tips button strong { font-size: 14px; }.zw-native-search-tips button small { color: var(--c-muted); font-size: 12px; }
@keyframes zw-native-search-in { from { opacity: 0; transform: translateX(10px); } }
@media (prefers-reduced-motion: reduce) { .zw-native-search-surface { animation: none; } }
.zw-filter-chips { display: flex; align-items: center; gap: 5px; overflow-x: auto; scrollbar-width: none; }
.zw-filter-chip { display: inline-flex; align-items: center; gap: 5px; min-height: 30px; padding: 4px 9px; border: 1px solid transparent; border-radius: 999px; background: var(--c-subtle); color: var(--c-ink-2); cursor: pointer; white-space: nowrap; }
.zw-filter-chip:hover { background: var(--c-hover); }.zw-filter-chip.active { border-color: color-mix(in srgb,var(--c-accent) 28%,var(--c-line)); background: color-mix(in srgb,var(--c-accent) 11%,var(--c-surface)); color: var(--c-accent); }
.zw-filter-chip b { font-size: 11px; }.zw-collection-picker select { min-height: 32px; max-width: 190px; }
.zw-collection-selection { display: flex; align-items: center; gap: 7px; padding: 4px 8px; border-radius: 10px; background: color-mix(in srgb,var(--c-accent) 9%,var(--c-surface)); }
.zw-collection-panes { display: grid; grid-template-columns: minmax(240px,360px) minmax(0,1fr) auto; min-height: 0; }
.zw-collection-list,.zw-collection-detail,.zw-collection-inspector { min-width: 0; min-height: 0; overflow: auto; }
.zw-collection-list { border-right: 1px solid var(--c-line); background: var(--c-raised); }
.zw-collection-detail { background: var(--c-canvas); }
.zw-collection-inspector { width: clamp(260px,25cqw,380px); border-left: 1px solid var(--c-line); background: var(--c-surface); }
.zw-focus-board { display: grid; gap: 16px; width: 100%; }
.zw-focus-group { overflow: hidden; border: 1px solid var(--c-line); border-radius: 16px; background: var(--c-surface); }
.zw-focus-group > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--c-line-soft); }
.zw-focus-group > header h3,.zw-focus-group > header p { margin: 0; }
.zw-focus-group > header h3 { font-size: 14px; }
.zw-focus-group > header p { margin-top: 2px; color: var(--c-muted); font-size: 12px; }
.zw-focus-count { display: grid; place-items: center; min-width: 24px; height: 24px; padding: 0 7px; border-radius: 999px; color: var(--c-muted); background: var(--c-subtle); font-size: 12px; font-weight: 750; }
.zw-focus-group.urgent > header { border-color: color-mix(in srgb,var(--c-bad) 20%,var(--c-line)); background: color-mix(in srgb,var(--c-bad) 6%,var(--c-surface)); }
.zw-focus-group.today > header { border-color: color-mix(in srgb,var(--c-accent) 20%,var(--c-line)); background: color-mix(in srgb,var(--c-accent) 6%,var(--c-surface)); }
.zw-focus-content > .zw-empty { padding: 28px 18px; }
.zw-status-badge { display: inline-flex; align-items: center; gap: 6px; width: fit-content; min-height: 24px; padding: 2px 9px; border-radius: 999px; color: var(--c-ink-2); background: var(--c-subtle); font-size: 11px; font-weight: 700; white-space: nowrap; }
.zw-status-badge > i { width: 7px; height: 7px; border-radius: 50%; background: var(--c-muted); }
.zw-status-badge.good > i { background: var(--c-good); }.zw-status-badge.info > i { background: var(--c-accent); }.zw-status-badge.waiting > i { background: var(--c-muted); }.zw-status-badge.warning > i { background: var(--c-warn); }.zw-status-badge.critical > i { background: var(--c-bad); }.zw-status-badge.paused > i { background: var(--c-muted); }
.zw-status-badge.critical { color: var(--c-bad); background: color-mix(in srgb,var(--c-bad) 9%,var(--c-surface)); }.zw-status-badge.warning { color: color-mix(in srgb,var(--c-warn) 74%,var(--c-ink)); background: color-mix(in srgb,var(--c-warn) 10%,var(--c-surface)); }.zw-status-badge.paused { opacity: .82; }
.zw-relation-rail { display: grid; gap: 10px; margin: 16px 0; padding: 13px; border: 1px solid var(--c-line); border-radius: 16px; background: color-mix(in srgb,var(--c-surface) 88%,transparent); }
.zw-relation-rail > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; }.zw-relation-heading { display: flex; align-items: center; gap: 9px; min-width: 0; color: var(--c-ink-2); }.zw-relation-heading > svg { flex: none; color: var(--c-accent); }.zw-relation-heading h3,.zw-relation-heading p { margin: 0; }.zw-relation-heading h3 { font-size: 13px; }.zw-relation-heading p { margin-top: 2px; color: var(--c-muted); font-size: 11px; }.zw-relation-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.zw-relation-items { display: flex; flex-wrap: wrap; gap: 7px; }.zw-relation-item { display: inline-grid; grid-template-columns: 26px minmax(0,1fr) auto auto; align-items: center; gap: 7px; min-width: min(220px,100%); max-width: 100%; padding: 7px 9px; border: 1px solid var(--c-line); border-radius: 12px; color: var(--c-ink-2); background: var(--c-subtle); text-align: left; }.zw-relation-items button.zw-relation-item { cursor: pointer; }.zw-relation-items button.zw-relation-item:hover { border-color: color-mix(in srgb,var(--c-accent) 45%,var(--c-line)); background: var(--c-hover); }.zw-relation-icon { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 9px; color: var(--zw-relation-color,var(--c-accent)); background: color-mix(in srgb,var(--zw-relation-color,var(--c-accent)) 10%,transparent); }.zw-relation-copy { display: grid; min-width: 0; }.zw-relation-copy strong,.zw-relation-copy small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.zw-relation-copy strong { font-size: 12px; }.zw-relation-copy small,.zw-relation-empty { color: var(--c-muted); font-size: 11px; }.zw-relation-empty { margin: 0; padding: 6px 2px; }
@container (max-width: 640px) { .zw-relation-rail { margin: 12px 0; padding: 10px; border-radius: 14px; }.zw-relation-rail > header { align-items: flex-start; }.zw-relation-items { display: grid; }.zw-relation-item { width: 100%; min-width: 0; }.zw-relation-actions .zw-btn { min-height: 32px; padding: 5px 8px; } }

/* Fachobjekt: ruhiger Titel, genau eine primaere Aktion, Rest im Overflow. */
.zw-object-header { position: sticky; top: 0; z-index: 8; display: flex; align-items: center; gap: 11px; min-height: 70px; padding: 12px 16px; border-bottom: 1px solid var(--c-line); background: color-mix(in srgb,var(--c-canvas) 93%,transparent); backdrop-filter: blur(18px) saturate(1.12); }
.zw-object-icon { display: grid; place-items: center; flex: 0 0 38px; height: 38px; border-radius: 12px; color: var(--c-accent); background: color-mix(in srgb,var(--c-accent) 10%,var(--c-surface)); }
.zw-object-heading { min-width: 0; flex: 1; }.zw-object-context { display: block; margin-bottom: 2px; color: var(--c-muted); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.zw-object-titleline { display: flex; align-items: center; gap: 9px; min-width: 0; }.zw-object-titleline h1 { min-width: 0; overflow: hidden; margin: 0; font-size: clamp(18px,2cqw,25px); line-height: 1.15; letter-spacing: -.025em; text-overflow: ellipsis; white-space: nowrap; }
.zw-object-heading > p { overflow: hidden; margin: 3px 0 0; color: var(--c-muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.zw-object-meta { display: flex; align-items: center; gap: 5px; margin-top: 5px; overflow-x: auto; scrollbar-width: none; }
.zw-object-actions { position: relative; display: flex; align-items: center; gap: 7px; }.zw-object-overflow { position: relative; }.zw-object-overflow-trigger { display: grid; place-items: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 10px; background: transparent; color: var(--c-muted); cursor: pointer; }.zw-object-overflow-trigger:hover,.zw-object-overflow[data-open="true"] > .zw-object-overflow-trigger { color: var(--c-ink); background: var(--c-hover); }
.zw-object-menu { position: absolute; top: calc(100% + 7px); right: 0; z-index: 30; display: grid; min-width: 210px; max-height: min(70vh,520px); padding: 6px; overflow: auto; border: 1px solid var(--c-line); border-radius: 12px; background: var(--c-raised); box-shadow: var(--c-shadow-pop); }.zw-object-menu > :where(button,a) { justify-content: flex-start; width: 100%; }

/* Log-Ausgaben */
.zw-log { margin: 0; padding: 12px 14px; max-height: 320px; overflow: auto; border-radius: 10px; background: var(--c-code); color: var(--c-code-ink); font: 12px/1.6 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre-wrap; }

a { color: var(--c-accent); }
.zw-cards .zw-card + .zw-card { margin-top: 0; }

@container (max-width: 640px) {
  .zw-layout,.zw-layout.nav-expanded { grid-template-columns:1fr;grid-template-rows:auto minmax(0,1fr); }
  .zw-layout > .zw-side { width:auto;max-height:112px;border-right:0;border-bottom:1px solid var(--c-line); }
  .zw-side-head { display:none; }
  .zw-layout > .zw-side > .zw-side-body { flex-direction:row;align-items:flex-start;overflow-x:auto;overflow-y:hidden;padding:6px; }
  .zw-layout > .zw-side .zw-side-title { display: none; }
  .zw-side-btn,.zw-layout:not(.nav-expanded) .zw-side-btn { justify-content:flex-start;width:auto;padding-inline:10px;white-space:nowrap; }
  .zw-layout:not(.nav-expanded) .zw-side-btn > span,.zw-layout:not(.nav-expanded) .zw-side-badge { position:static;width:auto;height:auto;padding:1px 6px;overflow:visible;clip:auto; }
  .zw-layout:not(.nav-expanded) .zw-side-btn > span:first-of-type { padding:0; }
  .zw-layout > .zw-side .zw-nav-disclosure { flex:none; }
  .zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure > summary { grid-template-columns:20px minmax(0,1fr) 14px;justify-items:stretch;padding-inline:8px; }
  .zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure > summary > span { position:static;width:auto;height:auto;overflow:hidden;clip:auto; }
  .zw-layout:not(.nav-expanded) .zw-side .zw-nav-disclosure > summary > svg:last-child { position:static;width:13px;height:13px; }
  .zw-layout > .zw-side .zw-nav-disclosure-items { position:absolute;z-index:30;min-width:210px;padding:6px;border:1px solid var(--c-line);border-radius:12px;background:var(--c-raised);box-shadow:var(--c-shadow-pop); }
  .zw-main { padding: 0 14px 20px; }
  .zw-page-head { flex-wrap: wrap; }
  .zw-collection-head { min-height: 66px; padding-inline: 12px; }
  .zw-collection-head-actions > small { display: none; }
  .zw-choice-popover.cards .zw-choice-panel { width: min(390px,calc(100vw - 28px)); }
  .zw-choice-popover.cards .zw-choice-options { grid-template-columns: 1fr; }
  .zw-main > .zw-page-head { margin: 0 -14px 14px; padding: 14px 14px 10px; }
  .zw-page-icon { display: none; }
  .zw-form-grid.two { grid-template-columns: 1fr; }
  :where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) { grid-template-columns: 1fr; grid-template-areas: "label" "control" "hint"; }
  :where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) > :not(label:first-child):not(small) { grid-row: auto; justify-self: stretch; }
  :where(.zw-group-card > .zw-field, .zw-group-card > .zw-form-grid > .zw-field, .zw-group-card > .zw-split > .zw-form-grid > .zw-field, .zw-group-card > .zw-form-row > .zw-field) > label:first-child { grid-row: auto; }
  .zw-group-card > .zw-split { grid-template-columns: 1fr; }
  .zw-app-surface.flyout, .zw-app-surface.workspace { inset: 0; width: 100%; max-height: none; border: 0; border-radius: 0; }
  .zw-app-surface.popover { width: calc(100% - 16px); max-height: calc(100% - 16px); }
  .zw-app-surface-body { padding-inline: 16px; }
  .zw-app-frame { grid-template-columns: 1fr; grid-template-rows: auto minmax(0,1fr); }
  .zw-app-nav { display: flex; min-width: 0; max-width: none; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--c-line); }
  .zw-app-inspector { position: absolute; inset: 0 0 0 auto; z-index: 20; width: min(420px,100%); box-shadow: var(--c-shadow-pop); }
  .zw-collection-panes { grid-template-columns: 1fr; }
  .zw-collection-toolbar { padding-inline: 10px; }.zw-collection-search { flex: 1 1 100%; min-width: 0; }.zw-collection-tools > .zw-grow { display: none; }.zw-collection-picker { flex: 1; }.zw-collection-picker select { width: 100%; max-width: none; }
  .zw-collection-view.detail-open .zw-collection-list { display: none; }
  .zw-collection-inspector { position: absolute; inset: 0 0 0 auto; z-index: 20; width: min(420px,100%); box-shadow: var(--c-shadow-pop); }
  .zw-sheet { width: 100%!important; border-left: 0; }
  .zw-object-header { min-height: 60px; padding: 9px 10px; }.zw-object-icon { display: none; }.zw-object-titleline h1 { font-size: 18px; }.zw-object-heading > p { display: none; }.zw-object-actions .zw-btn:not(.primary) { display: none; }
}

/* zitro-Wortmarke wie auf zitro.cloud und im Kundencenter: Blatt, „zitro“, ®, Endung (.cloud …).
   Open Sans nur als kleine Teilmenge (assets/fonts/opensans-wordmark.woff, OFL). Größe über font-size. */
@font-face {
  font-family: "ZITRO Wordmark";
  font-style: normal;
  font-display: swap;
  font-weight: 300 700;
  src: url("/assets/fonts/opensans-wordmark.woff") format("woff");
}
.zw-wordmark {
  --zitro-ci: #ffc700;
  display: inline-flex;
  align-items: baseline;
  font-family: "ZITRO Wordmark", "Open Sans", Arial, sans-serif;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.05;
  white-space: nowrap;
  color: var(--zitro-ci);
  vertical-align: baseline;
}
.zw-wordmark > .zw-wordmark-leaf:not(.tiles) { display: inline-block; flex: none; width: 1ex; height: 1ex; margin-right: .26em; background: var(--zitro-ci); border-radius: 0 50% 0 50%; }
.zw-wordmark > .zw-wordmark-name { font-weight: 700; }
.zw-wordmark > .zw-wordmark-registered { align-self: flex-start; position: relative; top: -.1em; margin-left: .08em; margin-right: .16em; font-size: .32em; line-height: 1; font-weight: 300; }
.zw-wordmark > .zw-wordmark-suffix { font-weight: 300; color: var(--zitro-wordmark-suffix, var(--c-ink)); }
:root[data-theme="dark"] .zw-wordmark > .zw-wordmark-suffix { color: var(--zitro-wordmark-suffix, #eee); }
/* Hintergrund transparent; die Endung folgt dem Design (hell: dunkle Schrift, dunkel: #eee wie auf zitro.cloud). */
/* Helles Design: feine dunkle Kontur um Blatt und Gelb, damit es auf hellem Grund lesbar bleibt. */
:root:not([data-theme="dark"]) .zw-wordmark > .zw-wordmark-name,
:root:not([data-theme="dark"]) .zw-wordmark > .zw-wordmark-registered { -webkit-text-stroke: .022em var(--zw-mark-outline, rgba(20, 33, 44, .55)); }
:root:not([data-theme="dark"]) .zw-wordmark > .zw-wordmark-leaf:not(.tiles) { box-shadow: 0 0 0 .02em var(--zw-mark-outline, rgba(20, 33, 44, .55)); }

/* Logo von zitro.works: Blatt aus vier App-Kacheln. Größe über --s. Auf dunklem Grund (Leiste, Anmeldung)
   --zw-mark-outline: transparent setzen; im hellen Design sonst feine dunkle Kontur wie bei der Wortmarke. */
.zw-works-mark { --s: 32px; display: inline-grid; flex: none; grid-template: 1fr 1fr / 1fr 1fr; gap: calc(var(--s) * .078); width: var(--s); height: var(--s); vertical-align: middle; }
.zw-works-mark > i { display: block; background: #ffc700; }
.zw-works-mark > i:nth-child(2) { border-top-right-radius: 100%; }
.zw-works-mark > i:nth-child(3) { border-bottom-left-radius: 100%; }
:root:not([data-theme="dark"]) .zw-works-mark { filter: drop-shadow(0 0 .6px var(--zw-mark-outline, rgba(20, 33, 44, .7))); }
/* In der Wortmarke als eine Fläche mit Maske (Grundlinie wie beim einfachen Blatt). */
.zw-wordmark > .zw-wordmark-leaf.tiles { display: inline-block; flex: none; width: 1.12ex; height: 1.12ex; margin-right: .26em; background: var(--zitro-ci);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Crect width='14.75' height='14.75'/%3E%3Cpath d='M17.25 0A14.75 14.75 0 0 1 32 14.75H17.25Z'/%3E%3Cpath d='M14.75 32A14.75 14.75 0 0 1 0 17.25H14.75Z'/%3E%3Crect x='17.25' y='17.25' width='14.75' height='14.75'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Crect width='14.75' height='14.75'/%3E%3Cpath d='M17.25 0A14.75 14.75 0 0 1 32 14.75H17.25Z'/%3E%3Cpath d='M14.75 32A14.75 14.75 0 0 1 0 17.25H14.75Z'/%3E%3Crect x='17.25' y='17.25' width='14.75' height='14.75'/%3E%3C/svg%3E") center / contain no-repeat; }
:root:not([data-theme="dark"]) .zw-wordmark > .zw-wordmark-leaf.tiles { filter: drop-shadow(0 0 .02em var(--zw-mark-outline, rgba(20, 33, 44, .7))); }

/* ------------------------------------------------------------------ Zustand, Zeilen mit Aktionen, Aufklappen, Leiste rechts
   (docs/UI-HAUPTFRAME.md → „Zustand zuerst“). line() und statusLine() sind Zeilen in einer group(). */
.zw-line, .zw-status-item { display: flex; align-items: center; gap: 12px; min-height: 52px; flex-wrap: wrap; }
.zw-line-text { flex: 1; min-width: 180px; display: grid; gap: 1px; }
.zw-line-text > strong { font-size: 13px; font-weight: 620; color: var(--c-ink); }
.zw-line-text > small { color: var(--c-muted); font-size: 12px; line-height: 1.45; }
.zw-line-actions { display: flex; align-items: center; justify-content: flex-end; gap: 6px; flex-wrap: wrap; }
.zw-status-dot { flex: none; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--c-subtle); color: var(--c-muted); }
.zw-status-dot svg { stroke-width: 2.6; }
:is(.zw-status-item, .zw-banner).ok > .zw-status-dot { background: var(--c-good-soft); color: var(--c-good); }
:is(.zw-status-item, .zw-banner).warn > .zw-status-dot { background: var(--c-warn-soft); color: var(--c-warn); }
:is(.zw-status-item, .zw-banner).bad > .zw-status-dot { background: var(--c-bad-soft); color: var(--c-bad); }
:is(.zw-status-item, .zw-banner).info > .zw-status-dot { background: var(--c-accent-soft); color: var(--c-accent); }
.zw-banner { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; max-width: 880px; padding: 12px 16px; border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--c-good) 28%, var(--c-line)); background: color-mix(in srgb, var(--c-good) 8%, var(--c-surface)); }
.zw-banner.warn { border-color: color-mix(in srgb, var(--c-warn) 30%, var(--c-line)); background: color-mix(in srgb, var(--c-warn) 9%, var(--c-surface)); }
.zw-banner.bad { border-color: color-mix(in srgb, var(--c-bad) 30%, var(--c-line)); background: color-mix(in srgb, var(--c-bad) 8%, var(--c-surface)); }
.zw-banner.info { border-color: color-mix(in srgb, var(--c-accent) 26%, var(--c-line)); background: color-mix(in srgb, var(--c-accent) 7%, var(--c-surface)); }
.zw-banner > .zw-line-text > strong { font-size: 13.5px; }
.zw-banner > .zw-line-text > small { color: var(--c-ink-2); }
.zw-banner + * { margin-top: 0; }
details.zw-more { max-width: 880px; border: 1px dashed var(--c-line-strong); border-radius: 12px; }
details.zw-more[open] { border-style: solid; border-color: var(--c-line); background: color-mix(in srgb, var(--c-surface) 45%, transparent); }
details.zw-more > summary { display: flex; align-items: center; gap: 8px; padding: 11px 16px; list-style: none; cursor: pointer; color: var(--c-muted); font-size: 12.5px; border-radius: 12px; }
details.zw-more > summary::-webkit-details-marker { display: none; }
details.zw-more > summary::before { content: ""; flex: none; width: 6px; height: 6px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(-45deg); transition: transform .15s; }
details.zw-more[open] > summary::before { transform: rotate(45deg); }
details.zw-more > summary > strong { color: var(--c-ink); font-weight: 650; }
details.zw-more > summary:hover > strong { color: var(--c-accent); }
.zw-more-body { display: grid; gap: 18px; padding: 4px 16px 16px; }
.zw-more-body > .zw-settings { max-width: none; }
.zw-filter-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.zw-filter-chips .zw-chip { height: 28px; padding: 0 11px; }
.zw-chip-count { color: var(--c-muted); font-variant-numeric: tabular-nums; }
.zw-chip.active .zw-chip-count { color: inherit; }
.zw-list-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 12px; }
.zw-list-toolbar .zw-search { flex: 1; min-width: 180px; max-width: 320px; }
.zw-table tr.zw-table-group td { height: auto; padding: 9px 14px 5px; background: var(--c-raised); color: var(--c-muted); font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.zw-table tbody tr.zw-table-group:hover td { background: var(--c-raised); }
.zw-drawer-overlay { position: absolute; inset: 0; z-index: 90; display: flex; justify-content: flex-end; background: transparent; pointer-events: none; animation: none; }
.zw-drawer { height: 100%; display: flex; flex-direction: column; background: var(--c-canvas); border-left: 1px solid var(--c-line); box-shadow: var(--c-shadow-pop); pointer-events: auto; animation: zw-drawer-in .18s ease-out; }
@keyframes zw-drawer-in { from { transform: translateX(28px); opacity: .5; } }
.zw-drawer > header { display: flex; align-items: center; gap: 12px; padding: 16px 14px 14px 20px; border-bottom: 1px solid var(--c-line); background: var(--c-surface); }
.zw-drawer > header .zw-page-title { flex: 1; min-width: 0; }
.zw-drawer > header h3 { font-size: 16px; font-weight: 700; letter-spacing: -.012em; }
.zw-drawer > header p { margin: 2px 0 0; font-size: 12.5px; }
.zw-drawer-body { flex: 1; overflow-y: auto; display: grid; align-content: start; gap: 20px; padding: 18px 20px 28px; }
.zw-drawer-body > .zw-settings { max-width: none; }
@media (prefers-reduced-motion: reduce) { .zw-drawer, .zw-drawer-overlay { animation: none; } }
@container (max-width: 640px) {
  .zw-line, .zw-status-item { align-items: flex-start; }
  .zw-line-actions { justify-content: flex-start; }
}
/* Zeilen mit Schalter: der Schalter braucht keine breite Spalte, der Hinweis darf die Zeile nutzen. */
:where(.zw-group-card > .zw-field):has(> .zw-toggle) { grid-template-columns: minmax(0, 1fr) auto; }
/* In der Leiste rechts sind Zeilen schmaler: Bedienelement höchstens halb so breit. */
.zw-drawer-body :where(.zw-group-card > .zw-field) { grid-template-columns: minmax(110px, 1fr) minmax(150px, 230px); }
.zw-drawer-body :where(.zw-group-card > .zw-field):has(> .zw-toggle) { grid-template-columns: minmax(0, 1fr) auto; }
@container (max-width: 640px) {
  .zw-group-card > .zw-field:has(> .zw-toggle) { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "label control" "hint control"; }
}

/* Benachrichtigungen: Ereignisauswahl im Profil, Matrix der eigenen Mitteilungen */
.zw-check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px 14px; margin-top: 8px; }
.zw-check-grid[hidden] { display: none; }
.zw-notice-matrix td:not(:first-child), .zw-notice-matrix th:not(:first-child) { width: 90px; text-align: center; }
.zw-notice-matrix td .zw-muted { font-size: 12px; margin-top: 2px; }
.zw-notice-inline { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; }
.zw-notice-inline.spaced { margin-top: 10px; }
.zw-notice-inline .zw-input { width: auto; min-width: 0; }
.zw-list-toolbar > select.zw-input { width: auto; min-width: 140px; }
.zw-activity-table td { vertical-align: top; }
.zw-activity-path { max-width: 360px; word-break: break-word; }
.zw-activity-path small { display: inline; }
.zw-nowrap { white-space: nowrap; }
.zw-approval { width: min(420px, calc(100vw - 24px)); max-width: calc(100vw - 24px); min-width: 0; }
.zw-approval .zw-approval-numbers .zw-btn { min-width: 0; flex: 1; max-width: 96px; }
.zw-approval-numbers { display: flex; gap: 12px; justify-content: center; margin: 14px 0 4px; }
.zw-approval-numbers .zw-btn { min-width: 76px; height: 64px; font-size: 26px; font-weight: 700; }
.zw-login-approval { text-align: center; padding: 8px 0; }
.zw-login-approval .zw-approval-number { font-size: 44px; font-weight: 750; letter-spacing: .04em; margin: 6px 0; }
.zw-approval-overlay { position: fixed; z-index: 9500; }

/* ===================================================================== Seitenleiste nach Mail (shell/app-nav.js)
   Schmal 72 px mit Hinweisen, angeheftet 272 px. Maße wie .zw-mail-nav, Schrift ab 11 px, Abschnittstitel in Satzschreibung. */
.zw-anav-shell { position: relative; display: grid; grid-template-columns: 72px minmax(0, 1fr); height: 100%; min-height: 0; }
.zw-anav-shell.zw-anav-pinned { grid-template-columns: 272px minmax(0, 1fr); }
.zw-anav { display: flex; flex-direction: column; gap: 12px; min-width: 0; min-height: 0; overflow: hidden; padding: 14px 10px 12px; border-right: 1px solid var(--c-line); background: color-mix(in srgb, var(--c-ink) 3%, var(--c-raised)); color: var(--c-ink); }
.zw-anav.pinned { padding-inline: 12px; }
.zw-anav-brand { display: grid; place-items: center; }
.zw-anav-brand-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; color: #fff; background: linear-gradient(145deg, color-mix(in srgb, var(--anav-tone, #4e78e8) 82%, #fff), var(--anav-tone, #4e78e8)); box-shadow: 0 8px 22px color-mix(in srgb, var(--anav-tone, #4e78e8) 26%, transparent); }
.zw-anav-brand > div { display: none; }
.zw-anav.pinned .zw-anav-brand { grid-template-columns: 44px minmax(0, 1fr); justify-items: start; gap: 10px; }
.zw-anav.pinned .zw-anav-brand > div { display: grid; min-width: 0; }
.zw-anav-brand strong { font-size: 16px; font-weight: 650; }
.zw-anav-brand small { overflow: hidden; color: var(--c-muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.zw-anav-controls { display: grid; justify-items: center; gap: 4px; }
.zw-anav-control { display: grid; place-items: center; width: 36px; height: 30px; padding: 0; border: 0; border-radius: 9px; color: var(--c-muted); background: transparent; font: inherit; cursor: pointer; }
.zw-anav-control.toggle { width: 48px; height: 42px; border-radius: 13px; color: var(--c-ink); background: color-mix(in srgb, var(--c-surface) 78%, transparent); }
.zw-anav-control:hover:not(:disabled) { color: var(--c-accent); background: var(--c-accent-soft); }
.zw-anav-control:disabled { opacity: .45; cursor: default; }
.zw-anav-control > span { display: none; }
.zw-anav-controls > :not(.zw-anav-control) { justify-self: center; }
.zw-anav.pinned .zw-anav-controls { display: flex; align-items: center; gap: 4px; }
.zw-anav.pinned .zw-anav-control { display: flex; align-items: center; justify-content: center; gap: 6px; height: 34px; }
.zw-anav.pinned .zw-anav-control:has(> span) { flex: 1; width: auto; }
.zw-anav.pinned .zw-anav-control > span { display: inline; font-size: 12px; }
.zw-anav-scroll { display: flex; flex-direction: column; gap: 3px; flex: 1; min-height: 0; overflow-x: hidden; overflow-y: auto; margin-inline: -4px; padding-inline: 4px; scrollbar-width: thin; }
.zw-anav-section { display: grid; grid-template-columns: minmax(0, 1fr); gap: 3px; min-width: 0; }
.zw-anav-section.titled { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--c-line); }
.zw-anav-section-head { display: grid; justify-items: center; gap: 2px; }
.zw-anav-section-head > span { display: none; }
.zw-anav-section-head:empty, .zw-anav-section-head:not(:has(.zw-anav-section-action)) { display: none; }
.zw-anav.pinned .zw-anav-section-head > span { display: block; }
.zw-anav.pinned .zw-anav-section-head { display: flex; align-items: center; gap: 2px; min-height: 24px; padding: 0 4px 2px 8px; color: var(--c-muted); font-size: 12px; font-weight: 650; }
.zw-anav-section-head > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zw-anav-section-action { position: relative; display: grid; place-items: center; width: 26px; height: 26px; padding: 0; border: 0; border-radius: 7px; color: var(--c-muted); background: transparent; cursor: pointer; }
.zw-anav-section-action:hover { color: var(--c-ink); background: var(--c-hover); }
.zw-anav-section-action.active { color: var(--c-accent); }
.zw-anav-section-action.active::after { content: ''; position: absolute; top: 4px; right: 4px; width: 6px; height: 6px; border-radius: 50%; background: var(--c-accent); }
.zw-anav-empty { margin: 2px 8px 6px; color: var(--c-muted); font-size: 12.5px; }
/* Einträge: schmal ein 48×42-Feld mit Symbol, angeheftet Symbol | Name | Zähler. */
.zw-anav-item { position: relative; display: grid; place-items: center; width: 48px; min-height: 42px; margin-inline: auto; padding: 0; border: 0; border-radius: 13px; color: inherit; background: transparent; font: inherit; text-align: left; cursor: pointer; list-style: none; }
.zw-anav-item::-webkit-details-marker { display: none; }
.zw-anav-item:hover { background: color-mix(in srgb, var(--c-accent) 9%, transparent); }
.zw-anav-item.active { color: var(--c-accent); background: color-mix(in srgb, var(--c-accent) 14%, transparent); font-weight: 650; }
.zw-anav-item:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 1px; }
.zw-anav-label { display: none; }
.zw-anav-count { position: absolute; top: 1px; right: 0; min-width: 18px; padding: 0 5px; border-radius: 9px; color: var(--c-on-accent, #fff); background: var(--c-accent); font-size: 11px; font-weight: 700; line-height: 17px; text-align: center; }
.zw-anav-group { display: grid; justify-items: center; }
.zw-anav-group-head { position: relative; display: grid; justify-items: center; width: 100%; }
.zw-anav-toggle { position: absolute; left: 0; top: 0; bottom: 0; display: grid; place-items: center; width: 14px; padding: 0; border: 0; border-radius: 6px; color: var(--c-muted); background: transparent; cursor: pointer; }
.zw-anav-toggle > svg { width: 11px; height: 11px; transition: transform .16s ease; }
.zw-anav-toggle:hover { color: var(--c-ink); background: var(--c-hover); }
.zw-anav-toggle:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 1px; }
.zw-anav-group.open > .zw-anav-group-head > .zw-anav-toggle > svg { transform: rotate(180deg); }
.zw-anav-group-items[hidden] { display: none; }
.zw-anav-item.file-drop { outline: 2px dashed var(--c-accent); outline-offset: -2px; background: var(--c-accent-soft); }
.zw-anav-group-items { display: grid; justify-items: center; gap: 4px; margin-top: 3px; padding: 6px 4px; border-radius: 15px; background: color-mix(in srgb, var(--c-ink) 7%, var(--c-surface)); }
.zw-anav-item.child { width: 36px; min-height: 36px; border-radius: 11px; }
.zw-anav.pinned .zw-anav-item { grid-template-columns: 22px minmax(0, 1fr) auto; justify-items: start; gap: 8px; width: 100%; min-height: 36px; padding: 6px 8px; }
.zw-anav.pinned .zw-anav-label { display: block; overflow: hidden; max-width: 100%; text-overflow: ellipsis; white-space: nowrap; }
.zw-anav.pinned .zw-anav-count { position: static; justify-self: end; }
.zw-anav.pinned .zw-anav-item.has-group { padding-right: 34px; }
.zw-anav.pinned .zw-anav-toggle { left: auto; right: 6px; top: 50%; bottom: auto; width: 24px; height: 24px; transform: translateY(-50%); }
.zw-anav.pinned .zw-anav-toggle > svg { width: 13px; height: 13px; }
.zw-anav.pinned .zw-anav-group { justify-items: stretch; }
.zw-anav.pinned .zw-anav-group-items { justify-items: stretch; margin: 0; padding: 3px 0 4px 18px; background: transparent; }
.zw-anav-group.nested > .zw-anav-group-items { margin-top: 2px; padding: 4px 3px; }
.zw-anav.pinned .zw-anav-group.nested > .zw-anav-group-items { padding: 2px 0 2px 16px; }
.zw-anav.pinned .zw-anav-item.child { grid-template-columns: 22px minmax(0, 1fr) auto; width: 100%; min-height: 34px; }
/* Farbiger Kreis mit Kürzel (wie die Kontokreise in Mail). */
.zw-anav-avatar { display: grid; place-items: center; width: 22px; height: 22px; border: 2px solid var(--anav-color, var(--c-accent)); border-radius: 50%; color: var(--c-ink); background: color-mix(in srgb, var(--anav-color, var(--c-accent)) 18%, var(--c-surface)); font-size: 11px; font-style: normal; font-weight: 750; letter-spacing: -.02em; line-height: 1; }
.zw-anav-item.child .zw-anav-avatar { width: 20px; height: 20px; font-size: 11px; }
.zw-anav-foot { display: grid; gap: 4px; margin-top: auto; padding-top: 10px; }
.zw-anav-foot-item { display: grid; place-items: center; width: 48px; height: 38px; margin-inline: auto; padding: 0; border: 0; border-radius: 11px; color: var(--c-muted); background: transparent; font: inherit; cursor: pointer; }
.zw-anav-foot-item:hover { color: var(--c-ink); background: var(--c-hover); }
.zw-anav-foot-item.active { color: var(--c-accent); background: var(--c-accent-soft); font-weight: 650; }
.zw-anav-foot-item > span { display: none; }
.zw-anav.pinned .zw-anav-foot-item { display: flex; justify-content: flex-start; gap: 9px; width: 100%; height: 34px; padding-inline: 9px; font-size: 13px; }
.zw-anav.pinned .zw-anav-foot-item > span { display: inline; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zw-anav-tip { position: absolute; z-index: 90; max-width: 300px; padding: 7px 11px; border: 1px solid color-mix(in srgb, var(--c-line) 80%, transparent); border-radius: 11px; color: var(--c-ink); background: color-mix(in srgb, var(--c-surface) 97%, transparent); box-shadow: 0 13px 34px #0004; }
.zw-anav-tip { font-size: 12.5px; font-weight: 650; white-space: nowrap; pointer-events: none; transform: translateY(-50%); }
.zw-anav-tip[hidden] { display: none; }
/* Alles außer der Leiste steht in der zweiten Spalte – auch wenn die angeheftete Leiste schmal über dem Inhalt liegt. */
.zw-anav-shell > .zw-anav + * { grid-column: 2; }
@media (max-width: 760px) {
  .zw-anav-shell.zw-anav-pinned { grid-template-columns: 72px minmax(0, 1fr); }
  .zw-anav.pinned { position: absolute; z-index: 24; inset: 0 auto 0 0; width: 272px; box-shadow: 14px 0 38px #0004; }
}
/* Schmales Fenster (appNav overlayBelow): angeheftet liegt die Leiste über dem Inhalt. */
.zw-anav-shell.zw-anav-tight > .zw-anav.pinned { position: absolute; z-index: 24; inset: 0 auto 0 0; width: 272px; box-shadow: 14px 0 38px #0004; }
@media (hover: none) { .zw-anav-tip { display: none; } }

/* ===================================================================== Ruhige Bausteine (shell/patterns.js, docs/DESIGN-MUSTER.md)
   Dieselben Maße wie im Projekt Hub: Schrift ab 11 px, Satzschreibung, Zeilen statt Kästen, Rot nur mit Wort. */
.zw-p-head { display: flex; align-items: center; gap: 14px; min-height: 40px; }
.zw-p-head-text { min-width: 0; }
.zw-p-head-text h1 { margin: 0; font-size: 24px; font-weight: 700; line-height: 1.2; letter-spacing: -.015em; }
.zw-p-head-text > p { margin: 4px 0 0; color: var(--c-muted); font-size: 13.5px; }
.zw-p-sentence { margin: 0; color: var(--c-ink); font-size: 17px; line-height: 1.45; text-wrap: pretty; }
.zw-p-sentence strong { font-weight: 700; }
.zw-p-sentence .bad { color: var(--c-bad); font-weight: 650; }
.zw-p-sentence .warn { color: var(--c-warn); font-weight: 650; }
.zw-p-sentence .good { color: var(--c-good); font-weight: 650; }
.zw-p-sentence-rest { color: var(--c-ink-2); }
.zw-p-seg-n { margin-left: 6px; color: var(--c-muted); font-size: 12px; font-weight: 600; }
.zw-p-lgroup { display: flex; flex-direction: column; }
.zw-p-lgroup + .zw-p-lgroup { margin-top: 10px; }
.zw-p-grp { display: flex; align-items: baseline; gap: 8px; margin: 0; padding: 12px 2px 6px; border-bottom: 1px solid var(--c-line); color: var(--c-ink); font-size: 13.5px; font-weight: 700; }
.zw-p-grp.bad { color: var(--c-bad); }
.zw-p-grp.warn { color: var(--c-warn); }
.zw-p-grp-count { color: var(--c-muted); font-size: 13px; font-weight: 600; }
.zw-p-grp-note { margin-left: auto; color: var(--c-muted); font-size: 12.5px; font-weight: 500; }
.zw-p-grp > .zw-p-textlink { margin-left: auto; }
.zw-p-grp-note + .zw-p-textlink { margin-left: 12px; }
.zw-p-subgrp { display: flex; align-items: center; gap: 6px; padding: 14px 2px 2px; color: var(--c-ink-2); font-size: 12.5px; font-weight: 650; }
.zw-p-subgrp > span { color: var(--c-muted); font-weight: 500; }
.zw-p-dot { display: inline-block; flex: none; width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; vertical-align: 1px; }
.zw-p-avatars { display: inline-flex; align-items: center; }
.zw-p-avatars .zw-avatar.tiny + .zw-avatar.tiny { margin-left: -6px; box-shadow: 0 0 0 2px var(--c-surface); }
.zw-p-rows { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; }
.zw-p-row { position: relative; display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: start; column-gap: 12px; padding: 9px 6px 9px 2px; border-bottom: 1px solid var(--c-line-soft); }
.zw-p-row.nolead { grid-template-columns: minmax(0, 1fr) auto; padding-left: 6px; }
.zw-p-row:last-child { border-bottom: 0; }
.zw-p-row:hover { border-radius: 8px; background: var(--c-hover); }
.zw-p-row.active { border-radius: 8px; background: color-mix(in srgb, var(--c-accent) 12%, transparent); }
.zw-p-row > input[type=checkbox] { margin: 1px 0 0; }
.zw-p-row > .zw-p-lead { display: grid; place-items: center; width: 22px; height: 22px; color: var(--c-muted); }
.zw-p-row-body { display: grid; gap: 2px; min-width: 0; min-height: 20px; padding: 1px 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; }
button.zw-p-row-body { cursor: pointer; }
.zw-p-row-title { font-size: 14px; font-weight: 500; line-height: 1.35; overflow-wrap: anywhere; }
.zw-p-row-sub { overflow: hidden; color: var(--c-muted); font-size: 12.5px; text-overflow: ellipsis; white-space: nowrap; }
.zw-p-row.done .zw-p-row-title { color: var(--c-muted); }
.zw-p-row-meta { display: flex; align-items: center; gap: 10px; padding-top: 1px; color: var(--c-muted); font-size: 12.5px; white-space: nowrap; }
.zw-p-row-when.bad { color: var(--c-bad); }
.zw-p-row-when.warn { color: var(--c-warn); }
/* Knöpfe beim Überfahren bleiben per Tastatur erreichbar: unsichtbar abgelegt statt display:none, beim Fokus sichtbar. */
.zw-p-row-hover { display: inline-flex; align-items: center; gap: 2px; margin: -4px 0; }
.zw-p-row:not(:hover):not(:focus-within) .zw-p-row-hover { position: absolute; width: 1px; height: 1px; margin: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (hover: none) { .zw-p-row:not(:hover):not(:focus-within) .zw-p-row-hover { position: static; width: auto; height: auto; margin: -4px 0; overflow: visible; clip-path: none; } }
.zw-p-hover-btn { width: 28px; height: 28px; }
.zw-p-flag { display: inline-flex; align-items: center; gap: 3px; margin-left: 8px; font-size: 12px; font-weight: 600; vertical-align: 1px; }
.zw-p-flag.warn { color: var(--c-warn); }
.zw-p-flag.bad { color: var(--c-bad); }
.zw-p-flag.good { color: var(--c-good); }
.zw-p-flag.info { color: var(--c-accent); }
.zw-p-flag.muted { color: var(--c-muted); font-weight: 500; }
.zw-p-textlink { min-height: 24px; padding: 2px 0; border: 0; background: none; color: var(--c-accent); font: inherit; font-size: 13px; font-weight: 550; cursor: pointer; }
.zw-p-textlink:hover { text-decoration: underline; }
.zw-p-addlink { display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; min-height: 28px; margin-top: 4px; padding: 2px 0; border: 0; background: none; color: var(--c-accent); font: inherit; font-size: 13.5px; font-weight: 550; cursor: pointer; }
.zw-p-addlink:hover { text-decoration: underline; }
.zw-p-quiet { display: grid; justify-items: start; gap: 8px; max-width: 520px; padding: 22px 0; }
.zw-p-quiet strong { font-size: 15px; }
/* Datei aus Polaris wählen (sdk/objects/polaris-file-field.js): Suchfeld, Hinweis, Treffer als ruhige Zeilen. */
.zw-p-filefield { display: flex; flex-direction: column; gap: 6px; }
.zw-p-filehits { display: flex; flex-direction: column; gap: 2px; max-height: 240px; overflow: auto; }
.zw-p-filehit { display: grid; grid-template-columns: 22px minmax(0, 1fr); align-items: center; gap: 8px; width: 100%; padding: 6px; border: 0; border-radius: 9px; color: var(--c-ink); background: transparent; font: inherit; text-align: left; cursor: pointer; }
.zw-p-filehit:hover, .zw-p-filehit:focus-visible { background: var(--c-hover); }
.zw-p-filehit > svg { justify-self: center; color: var(--c-muted); }
.zw-p-filehit > span { display: grid; gap: 1px; min-width: 0; }
.zw-p-filehit strong { overflow: hidden; font-size: 13.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.zw-p-filehit small { overflow: hidden; color: var(--c-muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.zw-p-filehint { margin: 0; color: var(--c-muted); font-size: 12.5px; }
.zw-p-sharelink { display: flex; flex-direction: column; gap: 8px; }
.zw-p-sharelink-row { display: flex; gap: 8px; }
.zw-p-sharelink-row > .zw-input { flex: 1; min-width: 0; }
.zw-p-copied { min-height: 18px; margin: 0; color: var(--c-good); font-size: 12.5px; }
.zw-p-quiet p { margin: 0; color: var(--c-muted); font-size: 13.5px; line-height: 1.5; }
.zw-p-quiet.center { justify-items: center; max-width: 440px; margin: 40px auto 0; text-align: center; }
.zw-p-quiet-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--c-subtle); color: var(--c-ink-2); }
.zw-p-side-sec { display: flex; flex-direction: column; gap: 6px; }
.zw-p-side-sec-head { display: flex; align-items: center; gap: 8px; margin-bottom: 2px; }
.zw-p-side-sec-head h2 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 15px; font-weight: 700; }
.zw-p-side-sec > p { margin: 0; color: var(--c-muted); font-size: 13px; line-height: 1.5; }
.zw-p-split { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; align-items: start; }
.zw-p-split-main { min-width: 0; }
.zw-p-split-side { display: flex; flex-direction: column; gap: 28px; min-width: 0; padding-left: 28px; border-left: 1px solid var(--c-line-soft); }
@media (max-width: 1100px) { .zw-p-split { grid-template-columns: minmax(0, 1fr); } .zw-p-split-side { padding-left: 0; border-left: 0; } }
.zw-p-numlist { margin: 0; padding: 0; list-style: none; counter-reset: zw-p-num; }
.zw-p-numlist li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--c-line-soft); font-size: 13.5px; counter-increment: zw-p-num; }
.zw-p-numlist li:last-child { border-bottom: 0; }
.zw-p-numlist li::before { content: counter(zw-p-num); color: var(--c-muted); font-weight: 700; text-align: center; }
.zw-p-search-field { display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px; border: 1px solid var(--c-line-strong); border-radius: 10px; background: var(--c-input); color: var(--c-muted); }
.zw-p-search-field:focus-within { border-color: var(--c-accent); box-shadow: 0 0 0 3px var(--c-accent-soft); }
.zw-p-search-field > input { flex: 1; min-width: 0; height: 34px; padding: 0; border: 0; outline: 0; background: none; color: var(--c-ink); font: inherit; font-size: 14px; }
.zw-p-more-opts > summary { padding: 6px 0; color: var(--c-ink-2); font-weight: 600; cursor: pointer; }
.zw-p-more-opts > summary > span { color: var(--c-muted); font-weight: 500; }
.zw-p-more-opts[open] > summary { margin-bottom: 8px; }
.zw-p-page { display: flex; flex-direction: column; gap: 18px; max-width: 1180px; padding: 28px 36px 40px; }
/* Einstellungs-Dialoge */
.zw-p-pref { display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; }
.zw-p-pref-group { display: flex; flex-direction: column; }
.zw-p-pref-h { margin: 0; padding: 10px 2px 6px; color: var(--c-ink-2); font-size: 12.5px; font-weight: 650; }
.zw-p-pref-card { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--c-line); border-radius: 10px; background: var(--c-raised); }
.zw-p-pref-row { display: flex; align-items: center; gap: 12px; min-height: 46px; padding: 9px 14px; border: 0; border-bottom: 1px solid var(--c-line); background: none; color: var(--c-ink); font: inherit; text-align: left; }
.zw-p-pref-card > :last-child { border-bottom: 0; }
.zw-p-pref-ic { display: grid; flex: none; place-items: center; width: 28px; height: 28px; border-radius: 7px; background: var(--c-accent-soft); color: var(--c-accent); }
.zw-p-pref-tx { flex: 1; min-width: 0; }
.zw-p-pref-tx > strong { display: block; font-size: 13.5px; font-weight: 600; overflow-wrap: anywhere; }
.zw-p-pref-tx > span { display: block; margin-top: 1px; color: var(--c-muted); font-size: 12.5px; line-height: 1.4; }
.zw-p-pref-row > .zw-btn.small { height: 28px; padding: 0 11px; font-size: 12.5px; }
.zw-p-pref-row.add { width: 100%; min-height: 40px; color: var(--c-accent); font-weight: 600; cursor: pointer; }
.zw-p-pref-row.add:hover, .zw-p-pref-row.add:focus-visible { background: var(--c-hover); outline: none; }
.zw-p-pref-hint { margin: 0; padding: 6px 2px 0; color: var(--c-muted); font-size: 12.5px; line-height: 1.45; }
.zw-p-pref-adv > summary { display: flex; align-items: center; gap: 6px; padding: 12px 2px 0; color: var(--c-ink-2); font-size: 13px; font-weight: 600; cursor: pointer; list-style: none; }
.zw-p-pref-adv > summary::-webkit-details-marker { display: none; }
.zw-p-pref-adv[open] > summary > svg { transform: rotate(90deg); }
.zw-p-pref-adv-body { display: flex; flex-direction: column; gap: 6px; padding-top: 6px; }
