/* Werkbank · Auftragszentrale — Demo von OBHOLZ SOLUTIONS
   Bildsprache: Werkstattzeichnung. Warmes Zeichenpapier, Graphit, ein Funke für alles, was die KI tut. */

@font-face { font-family: 'Inter'; src: url('../fonts/inter-var.woff2') format('woff2'); font-weight: 100 900; font-style: oblique 0deg 10deg; font-display: swap; }
@font-face { font-family: 'Plex Mono'; src: url('../fonts/plex-mono-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }

:root {
  --paper: oklch(0.958 0.005 80);
  --paper-2: oklch(0.938 0.006 80);
  --surface: oklch(0.994 0.002 80);
  --surface-2: oklch(0.979 0.003 80);
  --sunken: oklch(0.951 0.004 80);
  --line: oklch(0.905 0.005 80);
  --line-2: oklch(0.855 0.007 80);
  --ink: oklch(0.235 0.013 258);
  --ink-2: oklch(0.42 0.013 258);
  --ink-3: oklch(0.505 0.011 258);
  --ink-4: oklch(0.7 0.008 258);
  --hover: oklch(0.25 0.02 258 / 0.045);
  --active: oklch(0.25 0.02 258 / 0.07);

  --funke: oklch(0.645 0.2 38);
  --funke-btn: oklch(0.525 0.19 36);
  --funke-ink: oklch(0.52 0.18 36);
  --funke-tint: oklch(0.955 0.03 48);
  --funke-tint-2: oklch(0.925 0.055 46);
  --funke-mark: oklch(0.905 0.075 52 / 0.9);

  --s-anfrage: oklch(0.6 0.025 258);
  --s-angebot: oklch(0.55 0.15 290);
  --s-fertigung: var(--funke);
  --s-montage: oklch(0.56 0.13 245);
  --s-erledigt: oklch(0.6 0.13 155);
  --s-angebot-tint: oklch(0.955 0.025 290);
  --s-montage-tint: oklch(0.955 0.025 245);
  --s-erledigt-tint: oklch(0.96 0.03 155);

  --warn: oklch(0.565 0.2 27);
  --warn-tint: oklch(0.96 0.025 27);
  --ok: oklch(0.52 0.12 155);

  --r-s: 6px; --r: 8px; --r-m: 10px; --r-l: 12px;
  --shadow-1: 0 1px 0 oklch(0.2 0.02 258 / 0.03), 0 1px 2px oklch(0.2 0.02 258 / 0.06);
  --shadow-2: 0 1px 1px oklch(0.2 0.02 258 / 0.04), 0 3px 8px -2px oklch(0.2 0.02 258 / 0.08), 0 10px 24px -10px oklch(0.2 0.02 258 / 0.12);
  --shadow-3: 0 0 0 1px oklch(0.2 0.02 258 / 0.06), 0 6px 16px -4px oklch(0.2 0.02 258 / 0.12), 0 24px 56px -16px oklch(0.2 0.02 258 / 0.22);
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ease-io: cubic-bezier(0.65, 0, 0.35, 1);
  --font: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --strip: 30px;
  --tabbar: 0px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { height: 100%; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; height: 100%; overflow: hidden;
  background: var(--paper); color: var(--ink);
  font: 400 14px/1.45 var(--font);   /* V19.14 (Owner 24.10., P43): Grundschrift 14 px (vorher 13), nichts unter 12 px */
  font-feature-settings: 'cv05', 'cv08', 'calt';
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
a { color: inherit; }
h1, h2, h3, p, dl, dd { margin: 0; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
:focus-visible { outline: 2px solid var(--funke-btn); outline-offset: 2px; border-radius: 4px; }
::selection { background: var(--funke-tint-2); }
.num { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--mono); font-size: max(12px, 0.92em); letter-spacing: -0.01em; }

.ic { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.ic--xs { width: 12px; height: 12px; }
.ic--sm { width: 14px; height: 14px; }
.ic--funke { color: var(--funke); }

.skip { position: absolute; left: 8px; top: -90px; z-index: 200; background: var(--ink); color: #fff; padding: 8px 12px; border-radius: 8px; text-decoration: none; }
.skip:focus { top: 8px; }

/* ---------- Demo-Leiste ---------- */
.demo-strip {
  height: var(--strip); display: flex; align-items: center; justify-content: center; gap: 14px; position: relative;
  background: oklch(0.205 0.012 258); color: oklch(0.8 0.006 258); font-size: 12px; letter-spacing: 0.005em; white-space: nowrap;
}
.demo-strip strong { color: #fff; font-weight: 600; letter-spacing: 0.04em; font-size: 12px; }
.demo-strip__sep { margin: 0 8px; opacity: 0.5; }
.demo-strip__link { position: absolute; right: 14px; display: inline-flex; align-items: center; gap: 5px; color: #fff; text-decoration: none; opacity: 0.85; }
.demo-strip__link:hover { opacity: 1; text-decoration: underline; text-underline-offset: 3px; }
.demo-strip__text a { color: inherit; text-decoration: none; border-radius: 3px; }
.demo-strip__text a:hover { text-decoration: underline; text-underline-offset: 3px; }
.demo-strip a:focus-visible { outline-color: #fff; }
/* V19.13 (Rundgang 24.10., P30): bei 320 px reicht die Zeile nicht; „und Daten“ fällt weg, „erfundene Firma“ bleibt. */
@media (max-width: 360px) { .demo-strip__mehr { display: none; } }

/* ---------- Rahmen ---------- */
.app { display: grid; grid-template-columns: 236px minmax(0, 1fr); height: calc(100dvh - var(--strip) - var(--tabbar)); position: relative; }
.sidebar { display: flex; flex-direction: column; gap: 2px; padding: 12px 8px 10px 10px; min-height: 0; overflow-y: auto; scrollbar-width: none; }
.main {
  margin: 8px 8px 8px 0; min-width: 0; min-height: 0; position: relative;
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-l); box-shadow: var(--shadow-1);
}
.main:focus { outline: none; }
.m-top { display: none; }
.view { display: none; flex: 1; min-height: 0; flex-direction: column; }
.view.is-active { display: flex; animation: view-in 220ms var(--ease); }
@keyframes view-in { from { opacity: 0; transform: translateY(4px); } }

.brand { display: flex; align-items: center; gap: 10px; padding: 2px 6px 12px; }
.brand__mark { width: 28px; height: 28px; border-radius: 8px; background: oklch(0.22 0.013 258); display: grid; place-items: center; flex: none; box-shadow: inset 0 0 0 1px oklch(1 0 0 / 0.06), 0 1px 2px oklch(0 0 0 / 0.2); }
.brand__mark svg { width: 28px; height: 28px; }
.brand__mark path { fill: oklch(0.96 0.006 80); }
.brand__mark circle { fill: var(--funke); }
.brand__mark--sm { width: 26px; height: 26px; border-radius: 7px; }
.brand__mark--sm svg { width: 26px; height: 26px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.brand__name { font-weight: 650; font-size: 13.5px; letter-spacing: -0.01em; }
.brand__sub { color: var(--ink-3); font-size: 12px; }

.search-btn {
  display: flex; align-items: center; gap: 8px; height: 32px; padding: 0 8px 0 10px; margin: 0 0 10px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); color: var(--ink-3); box-shadow: var(--shadow-1);
  transition: border-color 140ms, color 140ms;
}
.search-btn span { flex: 1; text-align: left; }
.search-btn:hover { border-color: var(--line-2); color: var(--ink-2); }

.nav { display: flex; flex-direction: column; gap: 1px; }
.nav__item {
  display: flex; align-items: center; gap: 10px; height: 30px; padding: 0 8px; border-radius: var(--r-s);
  color: var(--ink-2); text-decoration: none; font-weight: 500; width: 100%; text-align: left;
  transition: background 120ms, color 120ms;
}
.nav__item > span:not([class]) { flex: 1; }
.nav__item:hover { background: var(--hover); color: var(--ink); }
.nav__item.is-on { background: var(--active); color: var(--ink); font-weight: 600; }
.nav__item .ic { color: var(--ink-3); }
.nav__item.is-on .ic, .nav__item:hover .ic { color: var(--ink); }
.nav__item .ic--funke, .nav__item:hover .ic--funke { color: var(--funke); }
.nav__badge { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--funke-btn); color: #fff; font-size: 12px; font-weight: 650; display: inline-grid; place-items: center; font-variant-numeric: tabular-nums; }
.nav__badge.is-bump { animation: bump 420ms var(--ease); }
@keyframes bump { 40% { transform: scale(1.3); } }
.nav__count { color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.nav__warn { color: var(--warn); display: inline-flex; }
.nav__item--sub { height: 28px; font-weight: 450; }
.nav-group { margin-top: 16px; display: flex; flex-direction: column; gap: 1px; }
.nav-group__label { color: var(--ink-3); font-size: 12px; font-weight: 550; padding: 0 8px 4px; }
.dot { width: 8px; height: 8px; border-radius: 2.5px; flex: none; margin: 0 4px; }
.dot--warn { background: var(--warn); }
.dot--angebot { background: var(--s-angebot); }
.dot--steel { background: linear-gradient(135deg, oklch(0.82 0.01 250), oklch(0.6 0.01 250)); }
.sidebar__spacer { flex: 1; min-height: 16px; }

.me { display: flex; align-items: center; gap: 10px; padding: 8px 4px 2px 6px; border-top: 1px solid var(--line); margin-top: 10px; }
.me__text { display: flex; flex-direction: column; line-height: 1.25; flex: 1; min-width: 0; }
.me__name { font-weight: 600; font-size: 12.5px; }
.me__role { color: var(--ink-3); font-size: 12px; }

.avatar {
  --h: 255; width: 26px; height: 26px;   /* V19.14: 26 px, damit die Initialen mit 12 px hineinpassen */ border-radius: 50%; flex: none; display: inline-grid; place-items: center;
  font-size: 12px; font-weight: 650; letter-spacing: 0.02em; color: oklch(0.32 0.07 var(--h));
  background: oklch(0.9 0.045 var(--h)); box-shadow: 0 0 0 1.5px var(--surface);
}
.me .avatar { width: 28px; height: 28px; font-size: 12px; }
.avatar--ah { --h: 255; }
.avatars { display: inline-flex; }
.avatars .avatar + .avatar { margin-left: -5px; }

/* ---------- Tour ---------- */
.tour { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-m); padding: 12px 12px 10px; box-shadow: var(--shadow-1); }
.tour__head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 8px; }
.tour__title { font-weight: 650; font-size: 12.5px; }
.tour__count { color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.tour__bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; margin-bottom: 8px; }
.tour__bar i { height: 3px; border-radius: 2px; background: var(--line); transition: background 300ms; }
.tour__bar i.is-done { background: var(--funke); }
.tour__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 1px; }
.tour__step { display: flex; align-items: center; gap: 8px; width: 100%; padding: 4px 4px; margin: 0 -4px; border-radius: 5px; text-align: left; color: var(--ink-2); font-size: 12.5px; }
.tour__step:hover { background: var(--hover); color: var(--ink); }
.tour__step i { width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--line-2); flex: none; display: grid; place-items: center; }
.tour__step.is-next { color: var(--ink); font-weight: 600; }
.tour__step.is-next i { border-color: var(--funke); box-shadow: 0 0 0 3px var(--funke-tint); }
.tour__step.is-done { color: var(--ink-3); }
.tour__step.is-done i { background: var(--funke); border-color: var(--funke); }
.tour__step.is-done i::after { content: ''; width: 6px; height: 3.5px; border: solid #fff; border-width: 0 0 1.5px 1.5px; transform: translateY(-1px) rotate(-45deg); }
.tour__end { font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }
.tour__end strong { color: var(--ink); display: block; font-size: 13px; margin-bottom: 2px; }
.tour__end .btn { margin-top: 10px; width: 100%; justify-content: center; }

/* ---------- Bausteine ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 12px; border-radius: 7px;
  font-weight: 560; font-size: 13px; white-space: nowrap; text-decoration: none;
  transition: background 140ms, box-shadow 140ms, transform 100ms, border-color 140ms, color 140ms;
}
.btn:active { transform: translateY(0.5px) scale(0.99); }
.btn--primary { background: var(--ink); color: oklch(0.98 0.004 80); box-shadow: 0 1px 1px oklch(0 0 0 / 0.2), inset 0 1px 0 oklch(1 0 0 / 0.1); }
.btn--primary:hover { background: oklch(0.3 0.013 258); }
.btn--funke { background: var(--funke-btn); color: #fff; box-shadow: 0 1px 1px oklch(0.4 0.15 36 / 0.4), inset 0 1px 0 oklch(1 0 0 / 0.18); }
.btn--funke:hover { background: oklch(0.49 0.19 36); }
.btn--funke .kbd, .btn--primary .kbd { color: #fff; }
.btn--quiet { border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); box-shadow: var(--shadow-1); }
.btn--quiet:hover { border-color: var(--line-2); color: var(--ink); }
.btn--ghost { color: var(--ink-2); }
.btn--ghost:hover { background: var(--hover); color: var(--ink); }
.btn--sm { height: 28px; padding: 0 10px; font-size: 12.5px; border-radius: 6px; }
.btn--lg { height: 38px; padding: 0 16px; font-size: 13.5px; border-radius: 9px; }
.btn[disabled] { opacity: 0.45; pointer-events: none; }
.btn .kbd { background: oklch(1 0 0 / 0.14); border-color: transparent; color: inherit; box-shadow: none; }
.btn--quiet .kbd, .btn--ghost .kbd { background: var(--sunken); color: var(--ink-3); }
.btn.is-pulse { animation: pulse 1.8s var(--ease) infinite; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 oklch(0.555 0.19 36 / 0.45); } 60% { box-shadow: 0 0 0 7px oklch(0.555 0.19 36 / 0); } }

.icon-btn { width: 30px; height: 30px; display: inline-grid; place-items: center; border-radius: 7px; color: var(--ink-3); flex: none; transition: background 120ms, color 120ms; }
.icon-btn:hover { background: var(--hover); color: var(--ink); }
.icon-btn[disabled] { opacity: 0.35; pointer-events: none; }

.kbd {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 4px;
  font: 500 12px/1 var(--font); color: var(--ink-3); background: var(--surface); border: 1px solid var(--line);
  box-shadow: inset 0 -1px 0 var(--line); white-space: nowrap;
}
.kbd--ghost { background: transparent; box-shadow: none; }

.chip {
  display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 6px; border-radius: 5px;
  font-size: 12px; font-weight: 500; color: var(--ink-2); background: var(--sunken); white-space: nowrap; max-width: 100%;
}
.chip .ic { width: 11px; height: 11px; }
.chip--funke { background: var(--funke-tint); color: var(--funke-ink); }
.chip--warn { background: var(--warn-tint); color: oklch(0.5 0.18 27); }
.chip--ok { background: var(--s-erledigt-tint); color: var(--ok); }
.chip--angebot { background: var(--s-angebot-tint); color: oklch(0.47 0.15 290); }
.chip--line { background: transparent; box-shadow: inset 0 0 0 1px var(--line); }
.chip--annahme { background: transparent; color: var(--ink-3); box-shadow: inset 0 0 0 1px var(--line-2); border-radius: 4px; height: 17px; font-size: 12px; padding: 0 5px; }

.seg { display: inline-flex; padding: 2px; border-radius: 8px; background: var(--sunken); gap: 2px; flex: none; }
.seg__btn { height: 26px; padding: 0 10px; border-radius: 6px; color: var(--ink-3); font-size: 12.5px; font-weight: 520; white-space: nowrap; transition: color 120ms, background 120ms; }
.seg__btn:hover { color: var(--ink); }
.seg__btn.is-on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-1), 0 0 0 1px oklch(0.2 0.02 258 / 0.04); }

.view-head { height: 52px; flex: none; display: flex; align-items: center; gap: 12px; padding: 0 12px 0 18px; border-bottom: 1px solid var(--line); }
.view-head__title { font-size: 15px; font-weight: 650; letter-spacing: -0.012em; }
.view-head__meta { color: var(--ink-3); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.view-head__spacer { flex: 1; }

/* ---------- Eingang ---------- */
.inbox { display: grid; grid-template-columns: 304px minmax(0, 1fr) 432px; flex: 1; min-height: 0; }
.mail-list { border-right: 1px solid var(--line); overflow-y: auto; padding: 6px; display: flex; flex-direction: column; gap: 1px; outline: none; }
.mail-list:focus-visible { box-shadow: inset 0 0 0 2px var(--funke-tint-2); }
.mail-item {
  display: grid; grid-template-columns: 8px minmax(0, 1fr); gap: 2px 6px; padding: 10px 10px 10px 6px; border-radius: var(--r);
  text-align: left; width: 100%; position: relative; transition: background 120ms;
}
.mail-item:hover { background: var(--hover); }
.mail-item.is-sel { background: var(--active); }
.mail-item.is-kb { box-shadow: inset 0 0 0 1.5px var(--funke-tint-2); }
.mail-item__dot { width: 6px; height: 6px; border-radius: 50%; margin-top: 6px; }
.mail-item.is-unread .mail-item__dot { background: var(--funke); }
.mail-item__top { display: flex; gap: 8px; align-items: baseline; min-width: 0; }
.mail-item__from { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; color: var(--ink-2); }
.mail-item.is-unread .mail-item__from { font-weight: 650; color: var(--ink); }
.mail-item__time { color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; flex: none; }
.mail-item__subj { grid-column: 2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--ink); font-size: 12.5px; }
.mail-item.is-unread .mail-item__subj { font-weight: 550; }
.mail-item__prev { grid-column: 2; color: var(--ink-3); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mail-item__tags { grid-column: 2; display: flex; gap: 4px; margin-top: 5px; flex-wrap: wrap; }
.mail-item.is-arriving { animation: arrive 700ms var(--ease) both; }
.mail-item.is-arriving::after { content: ''; position: absolute; inset: 0; border-radius: inherit; background: var(--funke-tint); animation: arrive-glow 2.2s var(--ease) forwards; pointer-events: none; mix-blend-mode: multiply; }
@keyframes arrive { from { opacity: 0; transform: translateY(-14px) scale(0.98); } }
@keyframes arrive-glow { 0%, 30% { opacity: 1; } 100% { opacity: 0; } }

.mail-view { overflow-y: auto; min-width: 0; position: relative; scroll-behavior: smooth; }
.mail-view__inner { padding: 26px 32px 48px; max-width: 760px; }
.mail-view__mtop { display: none; }
.mail-subj { font-size: 20px; font-weight: 650; letter-spacing: -0.018em; line-height: 1.25; margin-bottom: 14px; }
.mail-meta { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 0 10px; align-items: center; padding-bottom: 18px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.mail-meta .avatar { width: 34px; height: 34px; font-size: 12px; grid-row: span 2; }
.mail-meta__from { font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mail-meta__from span { font-weight: 400; color: var(--ink-3); }
.mail-meta__to { color: var(--ink-3); font-size: 12px; grid-column: 2; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mail-meta__date { color: var(--ink-3); font-size: 12px; grid-row: 1; grid-column: 3; font-variant-numeric: tabular-nums; }
.mail-body { font-size: 14.5px; line-height: 1.68; color: var(--ink); max-width: 62ch; }
.mail-body p { margin: 0 0 0.85em; }
.mail-fine { color: var(--ink-3); font-size: 13px; }

mark.src {
  color: inherit; padding: 0 1px; margin: 0 -1px; border-radius: 3px;
  background-image: linear-gradient(transparent 12%, var(--funke-mark) 12%, var(--funke-mark) 92%, transparent 92%);
  background-repeat: no-repeat; background-size: 0% 100%; background-position: 0 0; background-color: transparent;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
  transition: background-size 420ms var(--ease-io), background-color 160ms;
}
mark.src.is-found { background-size: 100% 100%; }
mark.src.is-hot { background-color: oklch(0.86 0.1 48 / 0.6); }
.pos {
  display: inline-grid; place-items: center; width: 17px; height: 17px; border-radius: 50%; margin: 0 1px 0 3px; vertical-align: 1px;
  font: 500 12px/1 var(--mono); color: var(--funke-ink); background: var(--surface); box-shadow: inset 0 0 0 1px var(--funke);
  transform: scale(0); transition: transform 300ms var(--ease), background 140ms, color 140ms; cursor: pointer;
}
.pos.is-on { transform: scale(1); }
.pos.is-hot { background: var(--funke); color: #fff; }
.mail-body .pos { margin-left: 2px; }

.att-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }
.att { width: 264px; border: 1px solid var(--line); border-radius: var(--r-m); overflow: hidden; background: var(--surface); box-shadow: var(--shadow-1); position: relative; }
.att__thumb { height: 168px; background: oklch(0.985 0.006 95); position: relative; display: block; width: 100%; }
.att__thumb svg { display: block; width: 100%; height: 100%; }
.att__foot { display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 10px; border-top: 1px solid var(--line); font-size: 12px; color: var(--ink-2); }
.att__foot span:first-of-type { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att__foot span:last-child { color: var(--ink-3); }
.att--pdf .att__thumb { height: 84px; display: grid; place-items: center; background: var(--sunken); }
.att--pdf .att__thumb span { font: 600 12px var(--mono); color: var(--ink-3); border: 1px solid var(--line-2); padding: 6px 8px 14px; border-radius: 3px; background: var(--surface); }
.sk-hit { fill: none; stroke: var(--funke); stroke-width: 1.4; stroke-dasharray: 3 2.5; opacity: 0; transition: opacity 300ms; }
.sk-hit.is-on { opacity: 1; }
.sk-pos circle { fill: var(--surface); stroke: var(--funke); stroke-width: 1; }
.sk-pos text { font: 500 12px var(--mono); fill: var(--funke-ink); text-anchor: middle; dominant-baseline: central; }
.sk-pos { opacity: 0; transition: opacity 260ms; }
.sk-pos.is-on { opacity: 1; }
.sk-pencil { fill: none; stroke: oklch(0.36 0.01 258 / 0.85); stroke-width: 1.35; stroke-linecap: round; stroke-linejoin: round; }
.sk-pencil--soft { stroke: oklch(0.36 0.01 258 / 0.5); stroke-width: 1; }
.sk-grid { stroke: oklch(0.82 0.04 230 / 0.55); stroke-width: 0.5; }

.einordnung { margin-top: 26px; border: 1px solid var(--line); border-radius: var(--r-m); padding: 14px 16px 14px 14px; display: grid; grid-template-columns: 28px 1fr; gap: 2px 10px; background: var(--surface-2); max-width: 62ch; }
.einordnung__ic { width: 28px; height: 28px; border-radius: 7px; background: var(--funke-tint); color: var(--funke); display: grid; place-items: center; grid-row: span 3; }
.einordnung__top { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-3); font-weight: 550; }
.einordnung__satz { font-size: 13.5px; font-weight: 550; color: var(--ink); }
.einordnung ul { margin: 6px 0 0; padding: 0 0 0 16px; color: var(--ink-2); font-size: 12.5px; }
.einordnung ul li { margin: 2px 0; }
.einordnung__act { grid-column: 2; margin-top: 10px; display: flex; gap: 8px; }

/* Auslese */
.auslese { border-left: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; min-width: 0; background: var(--surface-2); position: relative; }
.ausl-head { height: 46px; flex: none; display: flex; align-items: center; gap: 8px; padding: 0 10px 0 16px; border-bottom: 1px solid var(--line); background: var(--surface); }
.ausl-head__title { font-weight: 650; font-size: 13px; display: inline-flex; align-items: center; gap: 7px; }
.ausl-head__status { color: var(--ink-3); font-size: 12px; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.ausl-head__status b { color: var(--funke-ink); font-weight: 560; }
.ausl-progress { height: 2px; background: transparent; flex: none; position: relative; overflow: hidden; }
.ausl-progress i { position: absolute; inset: 0; background: var(--funke); transform-origin: 0 50%; transform: scaleX(0); transition: transform 400ms var(--ease); }
.ausl-progress.is-run::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, oklch(1 0 0 / 0.7), transparent); animation: sheen 1.1s linear infinite; }
@keyframes sheen { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.ausl-body { flex: 1; min-height: 0; overflow-y: auto; padding: 14px 14px 18px; scroll-behavior: smooth; }
.ausl-foot { flex: none; display: flex; gap: 8px; align-items: center; justify-content: flex-end; padding: 10px 14px; border-top: 1px solid var(--line); background: var(--surface); }
.ausl-foot__hint { margin-right: auto; color: var(--ink-3); font-size: 12px; }

.ausl-idle { padding: 34px 18px; text-align: center; color: var(--ink-2); }
.ausl-idle__ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; margin: 0 auto 14px; background: var(--funke-tint); color: var(--funke); }
.ausl-idle__ic .ic { width: 22px; height: 22px; }
.ausl-idle h2 { font-size: 15px; font-weight: 650; color: var(--ink); margin-bottom: 6px; }
.ausl-idle p { font-size: 12.5px; max-width: 30ch; margin: 0 auto 16px; }

.blatt { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-m); box-shadow: var(--shadow-1); overflow: hidden; }
.blatt + .blatt { margin-top: 12px; }
.sf { display: grid; grid-template-columns: 1fr auto; border-bottom: 1px solid var(--ink); position: relative; }
.sf__cell { padding: 8px 12px; border-right: 1px solid var(--line); min-width: 0; }
.sf__cell:last-child { border-right: 0; }
.sf__k { display: block; font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); font-weight: 600; margin-bottom: 1px; }
.sf__v { font-weight: 650; font-size: 15px; letter-spacing: -0.01em; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sf__v small { display: block; font-weight: 450; font-size: 12px; color: var(--ink-3); letter-spacing: 0; }
.sf__nr { font: 500 12.5px var(--mono); color: var(--ink); }
.sf__state { margin-top: 3px; display: block; }

.fg { padding: 10px 12px 4px; }
.fg + .fg { border-top: 1px solid var(--line); }
.fg__name { font-size: 12px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--ink-3); font-weight: 650; margin-bottom: 4px; display: flex; align-items: center; gap: 6px; }
.fr { display: grid; grid-template-columns: 104px minmax(0, 1fr) 20px; gap: 0 8px; align-items: start; padding: 5px 4px; margin: 0 -4px; border-radius: 6px; position: relative; transition: background 160ms; }
.fr.has-src { cursor: pointer; }
.fr.is-hot, .fr.has-src:hover { background: var(--funke-tint); }
.fr__k { color: var(--ink-3); font-size: 12px; padding-top: 1px; }
.fr__v { min-width: 0; }
.fr__val { display: block; font-size: 13.5px; font-weight: 550; color: var(--ink); line-height: 1.35; overflow-wrap: anywhere; }
.fr__val.mono { font-family: var(--mono); font-size: 12.5px; font-weight: 400; letter-spacing: -0.01em; }
.fr__z { display: block; color: var(--ink-3); font-size: 12px; line-height: 1.35; margin-top: 1px; }
.fr__pos { display: flex; gap: 2px; justify-content: flex-end; padding-top: 1px; }
.fr .pos { margin: 0; }
.fr.is-annahme .fr__val { text-decoration: underline dashed var(--ink-4); text-underline-offset: 4px; text-decoration-thickness: 1px; }
.fr__tag { margin-left: 6px; vertical-align: 1px; }
.fr.is-wait .fr__val, .fr.is-wait .fr__z { color: transparent; }
.fr.is-wait .fr__tag { visibility: hidden; }
.fr.is-wait.is-annahme .fr__val { text-decoration: none; }
.fr.is-wait .fr__val::before { content: ''; position: absolute; left: calc(104px + 8px); top: 9px; height: 9px; border-radius: 3px; width: var(--skw, 60%); max-width: calc(100% - 140px); background: linear-gradient(90deg, var(--sunken) 0%, oklch(0.975 0.004 80) 50%, var(--sunken) 100%); background-size: 200% 100%; animation: skel 1.4s linear infinite; }
@keyframes skel { from { background-position: 100% 0; } to { background-position: -100% 0; } }
.fr.is-land { animation: land 900ms var(--ease); }
.fr.is-land .fr__val, .fr.is-land .fr__z { animation: type-in 420ms var(--ease) both; }
@keyframes type-in { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes land { 0% { background: var(--funke-tint-2); } 100% { background: transparent; } }
.fr.is-plan .fr__val { color: var(--ok); }

.var-tab { margin: 2px 0 8px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; font-size: 12.5px; }
.var-tab__row { display: grid; grid-template-columns: 22px 1fr auto; gap: 8px; padding: 7px 10px; align-items: baseline; }
.var-tab__row + .var-tab__row { border-top: 1px solid var(--line); }
.var-tab__n { font: 600 12px var(--mono); color: var(--ink-3); }
.var-tab__p { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.var-tab__p small { display: block; font-weight: 450; color: var(--ink-3); font-size: 12px; }
.var-tab.is-wait { opacity: 0; transform: translateY(4px); }
.var-tab { transition: opacity 400ms, transform 400ms var(--ease); }

.rf { padding: 10px 12px 12px; border-top: 1px solid var(--line); }
.rf ol { margin: 6px 0 0; padding: 0; list-style: none; counter-reset: rf; display: flex; flex-direction: column; gap: 6px; }
.rf li { counter-increment: rf; display: grid; grid-template-columns: 18px 1fr; gap: 8px; font-size: 12.5px; color: var(--ink-2); line-height: 1.45; opacity: 0; transform: translateY(4px); transition: opacity 360ms, transform 360ms var(--ease); }
.rf li.is-on { opacity: 1; transform: none; }
.rf li::before { content: counter(rf); width: 18px; height: 18px; border-radius: 5px; background: var(--sunken); color: var(--ink-2); font: 600 12px/18px var(--mono); text-align: center; }
.rf__act { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; }

.zg { padding: 10px 12px 12px; border-top: 1px solid var(--line); }
.zg__fig { margin: 6px 0 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; position: relative;
  background-color: oklch(0.99 0.004 85);
  background-image: linear-gradient(oklch(0.9 0.02 230 / 0.35) 0.5px, transparent 0.5px), linear-gradient(90deg, oklch(0.9 0.02 230 / 0.35) 0.5px, transparent 0.5px);
  background-size: 12px 12px; }
.zg__fig svg { display: block; width: 100%; height: auto; }
.zg__exp { position: absolute; top: 6px; right: 6px; background: var(--surface); box-shadow: var(--shadow-1); border: 1px solid var(--line); }
.zg__cap { display: flex; justify-content: space-between; gap: 8px; color: var(--ink-3); font-size: 12px; margin-top: 6px; }

/* Zeichnung */
.dw { fill: none; stroke: var(--ink); stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; }
.dw--thin { stroke-width: 0.7; stroke: var(--ink-2); }
.dw--bar { stroke-width: 0.9; stroke: var(--ink-2); }
.dw--rail { stroke-width: 2.2; }
.dw--dim { stroke: var(--funke-ink); stroke-width: 0.7; }
.dw--hidden { stroke-dasharray: 4 3; stroke: var(--ink-3); stroke-width: 0.7; }
.dw--glass { stroke: oklch(0.6 0.08 220); stroke-width: 2.2; }
.dw-fill { fill: oklch(0.93 0.004 80); stroke: var(--ink); stroke-width: 1.1; stroke-linejoin: round; }
.dw-hatch { stroke: var(--ink); stroke-width: 1; }
.dw-hatchline { stroke: var(--ink-3); stroke-width: 0.6; }
/* V19.14 (Owner 24.10., P43): Zeichnungsschrift mindestens 12 px auf dem Bildschirm: --dwk = Viewbox-Breite / Anzeigebreite (zeichnung.js), Mindestwert 1 */
.zeichnung { --dwk: 1; }
.dw-pos { fill: var(--surface); stroke: var(--funke); stroke-width: 1; r: calc(9px * var(--dwk)); }
.dw-pos__t { font: 500 calc(12px * var(--dwk)) var(--mono); fill: var(--funke-ink); text-anchor: middle; dominant-baseline: central; }
.dw-txt { font: 400 calc(12px * var(--dwk)) var(--mono); fill: var(--ink-2); }
.dw-txt--dim { fill: var(--funke-ink); }
.dw-txt--b { font-family: var(--font); font-weight: 650; fill: var(--ink); }
.dw-txt--s { fill: var(--ink-3); }
.dw-sf { fill: var(--surface); stroke: var(--ink); stroke-width: 1; }
.dw-sf-l { stroke: var(--ink); stroke-width: 0.6; }
.zeichnung .draw { stroke-dasharray: 1; stroke-dashoffset: 0; }
.zeichnung.is-drawing .draw { stroke-dashoffset: 1; animation: draw 900ms var(--ease-io) forwards; animation-delay: calc(var(--i, 0) * 110ms); }
.zeichnung.is-drawing .fade { opacity: 0; animation: fade 500ms var(--ease) forwards; animation-delay: calc(400ms + var(--i, 0) * 110ms); }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fade { to { opacity: 1; } }

/* Flug-Etikett */
.ghost {
  position: fixed; left: 0; top: 0; z-index: 90; pointer-events: none; white-space: nowrap; max-width: 260px; overflow: hidden; text-overflow: ellipsis;
  font-size: 12.5px; font-weight: 550; color: var(--funke-ink); background: var(--surface);
  padding: 3px 8px; border-radius: 6px; box-shadow: 0 0 0 1px var(--funke), 0 6px 18px -4px oklch(0.55 0.19 36 / 0.35);
  will-change: transform, opacity;
}

/* Herkunftsfaden */
.threads { position: fixed; inset: 0; pointer-events: none; z-index: 40; opacity: 0; transition: opacity 160ms; }
.threads.is-on { opacity: 1; }
.threads__svg { width: 100%; height: 100%; overflow: visible; }
#thread-path { fill: none; stroke: var(--funke); stroke-width: 1.4; stroke-dasharray: 4 3; }
#thread-a, #thread-b { fill: var(--funke); }

/* Mobile Auslese-Leiste */
.m-strip { display: none; }

/* ---------- Tafel ---------- */
.stage-tabs { display: none; }
.board { flex: 1; min-height: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(226px, 1fr); gap: 10px; padding: 12px 14px 14px; overflow-x: auto; overflow-y: hidden; }
.col { display: flex; flex-direction: column; min-height: 0; border-radius: var(--r-m); background: oklch(0.25 0.02 258 / 0.028); padding: 4px 6px 0; transition: background 160ms, box-shadow 160ms; }
.col.is-target { background: var(--funke-tint); box-shadow: inset 0 0 0 1px var(--funke-tint-2); }
.col__head { display: flex; align-items: center; gap: 7px; height: 36px; padding: 0 4px; flex: none; }
.col__ic { width: 18px; height: 18px; border-radius: 5px; display: grid; place-items: center; color: #fff; flex: none; }
.col__ic .ic { width: 11px; height: 11px; stroke-width: 1.8; }
.col__name { font-weight: 620; font-size: 12.5px; }
.col__n { color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.col__sum { margin-left: auto; color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.col__list { flex: 1; min-height: 60px; overflow-y: auto; display: flex; flex-direction: column; gap: 7px; padding: 2px 0 12px; scrollbar-width: thin; }
.col__empty { color: var(--ink-4); font-size: 12px; text-align: center; padding: 18px 0; border: 1px dashed var(--line-2); border-radius: 8px; }
.st-anfrage { --st: var(--s-anfrage); }
.st-angebot { --st: var(--s-angebot); }
.st-fertigung { --st: var(--s-fertigung); }
.st-montage { --st: var(--s-montage); }
.st-erledigt { --st: var(--s-erledigt); }
.col__ic { background: var(--st); }

.card {
  display: block; width: 100%; text-align: left; background: var(--surface); border: 1px solid var(--line); border-radius: 9px;
  padding: 9px 11px 9px; box-shadow: var(--shadow-1); cursor: grab; position: relative; touch-action: pan-y; user-select: none;
  transition: border-color 140ms, box-shadow 160ms, transform 160ms var(--ease), opacity 160ms;
}
.card:hover { border-color: var(--line-2); box-shadow: var(--shadow-2); }
.card:focus-visible { outline-offset: 1px; }
.card.is-ghosted { opacity: 0.35; }
.card.is-picked { box-shadow: 0 0 0 2px var(--ink), 0 14px 28px -10px oklch(0.2 0.02 258 / 0.35); transform: translateY(-2px) rotate(-0.8deg); z-index: 2; }
.card.is-new { animation: card-new 1.6s var(--ease); }
@keyframes card-new { 0% { transform: translateY(-24px) scale(0.96); opacity: 0; box-shadow: 0 0 0 3px var(--funke), var(--shadow-3); } 30% { transform: none; opacity: 1; } 70% { box-shadow: 0 0 0 3px var(--funke-tint-2), var(--shadow-2); } }
.card.is-done { background: var(--surface-2); }
.card.is-done .card__kunde, .card.is-done .card__obj { color: var(--ink-3); }
.card__top { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.card__id { font: 400 12px var(--mono); color: var(--ink-3); letter-spacing: -0.01em; }
.card__neu { font-size: 12px; font-weight: 650; color: var(--funke-ink); letter-spacing: 0.04em; text-transform: uppercase; }
.pips { margin-left: auto; display: inline-flex; gap: 2px; }
.pips i { width: 7px; height: 3px; border-radius: 1px; background: var(--line); }
.pips i.on { background: var(--st); }
.card__kunde { font-weight: 620; font-size: 13px; line-height: 1.3; letter-spacing: -0.005em; }
.card__obj { color: var(--ink-2); font-size: 12.5px; line-height: 1.35; margin-top: 1px; }
.card__chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.card__bar { height: 3px; border-radius: 2px; background: var(--sunken); margin-top: 9px; overflow: hidden; }
.card__bar i { display: block; height: 100%; background: var(--funke); border-radius: inherit; width: 0; }
.card__foot { display: flex; align-items: center; gap: 6px; margin-top: 9px; padding-top: 8px; border-top: 1px solid var(--line); }
.card__wert { margin-left: auto; font-weight: 600; font-size: 12px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.card__menu { position: absolute; top: 5px; right: 5px; opacity: 0; width: 24px; height: 24px; background: var(--surface); }
.card:hover .card__menu, .card:focus-within .card__menu, .card__menu:focus-visible { opacity: 1; }
.card:hover .pips, .card:focus-within .pips { visibility: hidden; }
.drag-clone { position: fixed; left: 0; top: 0; z-index: 95; pointer-events: none; margin: 0; cursor: grabbing; box-shadow: var(--shadow-3); border-color: var(--line-2); }
.drop-ph { border: 1.5px dashed var(--funke); border-radius: 9px; background: oklch(0.955 0.03 48 / 0.5); flex: none; }

.menu { position: fixed; z-index: 96; min-width: 200px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-3); padding: 4px; animation: pop 140ms var(--ease); }
@keyframes pop { from { opacity: 0; transform: translateY(-4px) scale(0.98); } }
.menu__label { font-size: 12px; color: var(--ink-3); font-weight: 600; padding: 6px 8px 4px; }
.menu__item { display: flex; align-items: center; gap: 8px; width: 100%; height: 30px; padding: 0 8px; border-radius: 6px; font-size: 12.5px; text-align: left; }
.menu__item:hover, .menu__item:focus-visible { background: var(--hover); outline: none; }
.menu__item[aria-current='true'] { color: var(--ink-3); }
.menu__item .col__ic { width: 14px; height: 14px; border-radius: 4px; }

/* ---------- Schublade ---------- */
.scrim { position: fixed; inset: 0; z-index: 64; background: oklch(0.22 0.02 258 / 0.16); animation: fade 200ms both; }
.drawer {
  position: fixed; z-index: 70; top: calc(var(--strip) + 8px); right: 8px; bottom: 8px; width: min(540px, calc(100vw - 16px));
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-l); box-shadow: var(--shadow-3);
  display: flex; flex-direction: column; overflow: hidden; animation: drawer-in 300ms var(--ease);
}
.drawer.is-out { animation: drawer-out 200ms var(--ease-io) forwards; }
@keyframes drawer-in { from { transform: translateX(24px); opacity: 0; } }
@keyframes drawer-out { to { transform: translateX(24px); opacity: 0; } }
.drawer__head { padding: 12px 12px 14px 20px; border-bottom: 1px solid var(--line); flex: none; }
.drawer__bar { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.drawer__id { font: 500 12px var(--mono); color: var(--ink-3); }
.drawer__title { font-size: 19px; font-weight: 680; letter-spacing: -0.02em; line-height: 1.25; }
.drawer__sub { color: var(--ink-2); margin-top: 2px; }
.drawer__body { flex: 1; overflow-y: auto; padding: 16px 20px 28px; }
.stepper { display: grid; grid-template-columns: repeat(5, 1fr); gap: 3px; margin-top: 14px; }
.stepper__b { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; font-size: 12px; color: var(--ink-3); padding: 0 0 2px; border-radius: 4px; }
.stepper__b i { display: block; width: 100%; height: 4px; border-radius: 2px; background: var(--line); transition: background 240ms; }
.stepper__b.is-on i { background: var(--st); }
.stepper__b.is-cur { color: var(--ink); font-weight: 620; }
.stepper__b:hover { color: var(--ink); }
.facts { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 8px 12px; font-size: 13px; }
.facts dt { color: var(--ink-3); font-size: 12.5px; }
.facts dd { font-weight: 520; min-width: 0; overflow-wrap: anywhere; }
.facts dd small { display: block; color: var(--ink-3); font-weight: 400; font-size: 12px; }
.d-sec { margin-top: 22px; }
.d-sec__t { font-size: 12px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--ink-3); font-weight: 650; margin-bottom: 8px; }
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline li { position: relative; padding: 0 0 12px 22px; font-size: 12.5px; color: var(--ink-2); }
.timeline li::before { content: ''; position: absolute; left: 4px; top: 5px; width: 7px; height: 7px; border-radius: 50%; background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--ink-4); }
.timeline li::after { content: ''; position: absolute; left: 7px; top: 15px; bottom: 0; width: 1px; background: var(--line); }
.timeline li:last-child::after { display: none; }
.timeline li.is-ki::before { box-shadow: inset 0 0 0 1.5px var(--funke); background: var(--funke-tint); }
.timeline time { color: var(--ink-3); font-variant-numeric: tabular-nums; display: block; font-size: 12px; }
.d-note { border-radius: 9px; padding: 10px 12px; background: var(--funke-tint); color: var(--ink); font-size: 12.5px; display: flex; gap: 8px; }
.d-note .ic { color: var(--funke); margin-top: 1px; }

/* ---------- Woche ---------- */
.week { flex: 1; min-height: 0; overflow: auto; padding: 14px 16px 24px; }
.insights { display: grid; gap: 10px; margin-bottom: 14px; }
.insight { display: grid; grid-template-columns: 30px minmax(0, 1fr); grid-template-rows: auto auto auto 1fr; gap: 0 12px; padding: 12px 14px; border-radius: var(--r-m); border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow-1); transition: opacity 300ms, transform 300ms var(--ease); }
.insight__ic { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: var(--funke-tint); color: var(--funke); grid-row: span 3; }
.insight--warn { border-color: oklch(0.85 0.06 27); background: linear-gradient(180deg, var(--warn-tint), var(--surface) 70%); }
.insight--warn .insight__ic { background: oklch(0.93 0.04 27); color: var(--warn); }
.insight--ok .insight__ic { background: var(--s-erledigt-tint); color: var(--ok); }
.insight__k { font-size: 12px; color: var(--ink-3); font-weight: 600; display: flex; gap: 6px; align-items: center; }
.insight__t { font-weight: 640; font-size: 13.5px; margin: 1px 0 3px; letter-spacing: -0.005em; }
.insight__p { color: var(--ink-2); font-size: 12.5px; line-height: 1.5; }
.insight__act { grid-column: 2; display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; align-self: end; }

.wgrid { display: grid; grid-template-columns: 196px repeat(5, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--r-m); overflow: hidden; background: var(--surface); min-width: 860px; }
.wh { padding: 10px 10px 9px; border-left: 1px solid var(--line); border-bottom: 1px solid var(--line); position: relative; background: var(--surface); }
.wh--corner { border-left: 0; display: flex; align-items: flex-end; color: var(--ink-3); font-size: 12px; }
.wh__d { display: flex; align-items: baseline; gap: 6px; }
.wh__name { font-weight: 640; font-size: 12.5px; }
.wh__date { color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.wh__pct { margin-left: auto; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.wh.is-over .wh__pct { color: var(--warn); }
.wh__bar { height: 4px; border-radius: 2px; background: var(--sunken); margin-top: 7px; position: relative; overflow: hidden; }
.wh__bar i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--ink-3); border-radius: 2px; transition: width 500ms var(--ease), background 300ms; }
.wh.is-over .wh__bar i { background: var(--warn); }
.wh.is-today { background: linear-gradient(180deg, var(--funke-tint), var(--surface)); }
.wh.is-today::before { content: ''; position: absolute; left: -1px; right: 0; top: 0; height: 2px; background: var(--funke); }
.wh__today { font-size: 12px; font-weight: 650; color: var(--funke-ink); text-transform: uppercase; letter-spacing: 0.05em; }
.wgrp { grid-column: 1 / -1; padding: 5px 12px; font-size: 12px; font-weight: 650; letter-spacing: 0.07em; text-transform: uppercase; color: var(--ink-3); background: var(--surface-2); border-bottom: 1px solid var(--line); }
.wr { padding: 10px 12px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; justify-content: center; gap: 2px; min-width: 0; }
.wr__n { font-weight: 620; font-size: 12.5px; display: flex; align-items: center; gap: 6px; }
.wr__w { color: var(--ink-3); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wc { border-left: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 6px; display: flex; gap: 3px; min-height: 64px; min-width: 0; position: relative; }
.wc.is-today { background: oklch(0.975 0.012 50); }
.wc.is-over { background: repeating-linear-gradient(-45deg, var(--warn-tint) 0 6px, oklch(0.985 0.01 27) 6px 12px); box-shadow: inset 0 0 0 1px oklch(0.82 0.08 27); }
.wc__over { position: absolute; right: 6px; bottom: 3px; font-size: 12px; font-weight: 650; color: var(--warn); font-variant-numeric: tabular-nums; background: var(--surface); padding: 0 3px; border-radius: 3px; }
.wc__free { flex-grow: var(--g, 1); flex-basis: 0; border-radius: 6px; min-width: 0; }
.blk {
  flex-grow: var(--g, 1); flex-basis: 0; min-width: 0; border-radius: 6px; padding: 5px 6px; display: flex; flex-direction: column; justify-content: center;
  font-size: 12px; line-height: 1.25; overflow: hidden; text-align: left; position: relative;
  background: var(--sunken); color: var(--ink-2); box-shadow: inset 0 0 0 1px oklch(0.2 0.02 258 / 0.05);
  transition: transform 160ms var(--ease), box-shadow 160ms;
}
.blk:hover { box-shadow: inset 0 0 0 1px oklch(0.2 0.02 258 / 0.18); }
.blk b { font: 500 12px var(--mono); letter-spacing: -0.01em; white-space: nowrap; }
.blk span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.blk em { font-style: normal; font-size: 12px; font-weight: 550; font-variant-numeric: tabular-nums; }
.blk--fert { background: var(--funke-tint); color: oklch(0.42 0.13 36); box-shadow: inset 2px 0 0 var(--funke); }
.blk--mont { background: var(--s-montage-tint); color: oklch(0.4 0.11 245); box-shadow: inset 2px 0 0 var(--s-montage); }
.blk--auf { background: var(--s-angebot-tint); color: oklch(0.42 0.13 290); box-shadow: inset 2px 0 0 var(--s-angebot); }
.blk--serv { background: var(--s-erledigt-tint); color: oklch(0.4 0.1 155); box-shadow: inset 2px 0 0 var(--s-erledigt); }
.blk--werk { background: var(--sunken); color: var(--ink-2); box-shadow: inset 2px 0 0 var(--ink-4); }
.blk.is-moved { animation: moved 1.4s var(--ease); }
@keyframes moved { 0% { box-shadow: 0 0 0 2px var(--funke), 0 8px 18px -6px oklch(0.55 0.19 36 / 0.4); } 100% {} }
.blk.is-plan { background: repeating-linear-gradient(-45deg, var(--s-angebot-tint) 0 5px, var(--surface) 5px 10px); }
.week.is-past .blk { filter: saturate(0.2); opacity: 0.7; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 12px; color: var(--ink-3); font-size: 12px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 8px; border-radius: 2px; }
.legend .lg-fert { background: var(--funke-tint); box-shadow: inset 2px 0 0 var(--funke); }
.legend .lg-werk { background: var(--sunken); box-shadow: inset 2px 0 0 var(--ink-4); }
.legend .lg-mont { background: var(--s-montage-tint); box-shadow: inset 2px 0 0 var(--s-montage); }
.legend .lg-auf { background: var(--s-angebot-tint); box-shadow: inset 2px 0 0 var(--s-angebot); }
.legend .lg-serv { background: var(--s-erledigt-tint); box-shadow: inset 2px 0 0 var(--s-erledigt); }
.weeknav { display: flex; align-items: center; gap: 2px; }
.weeknav__label { font-weight: 600; font-size: 12.5px; min-width: 112px; text-align: center; font-variant-numeric: tabular-nums; }
.weeknav .btn { margin-left: 6px; }
.wmob { display: none; }

/* ---------- Assistent ---------- */
.assist {
  position: fixed; z-index: 60; top: calc(var(--strip) + 8px); right: 8px; bottom: 8px; width: min(430px, calc(100vw - 16px));
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-l); box-shadow: var(--shadow-3);
  display: flex; flex-direction: column; overflow: hidden; animation: drawer-in 280ms var(--ease);
}
.assist__head { height: 50px; flex: none; display: flex; align-items: center; gap: 10px; padding: 0 8px 0 16px; border-bottom: 1px solid var(--line); }
.assist__title { font-weight: 650; display: inline-flex; gap: 7px; align-items: center; font-size: 13.5px; }
.assist__meta { flex: 1; color: var(--ink-3); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.assist__log { flex: 1; overflow-y: auto; padding: 16px 16px 8px; display: flex; flex-direction: column; gap: 14px; scroll-behavior: smooth; }
.assist__form { flex: none; padding: 10px 12px 12px; border-top: 1px solid var(--line); position: relative; }
.assist__input { width: 100%; height: 42px; border-radius: 11px; border: 1px solid var(--line-2); background: var(--surface); padding: 0 46px 0 14px; font-size: 13.5px; box-shadow: var(--shadow-1); transition: border-color 140ms, box-shadow 140ms; }
.assist__input::placeholder { color: var(--ink-3); }
.assist__input:focus { outline: none; border-color: var(--funke); box-shadow: 0 0 0 3px var(--funke-tint); }
.assist__send { position: absolute; right: 18px; top: 16px; width: 30px; height: 30px; border-radius: 8px; background: var(--ink); color: #fff; display: grid; place-items: center; }
.assist__send:hover { background: oklch(0.32 0.013 258); }
.hello { padding: 8px 2px 4px; }
.hello__t { font-size: 17px; font-weight: 680; letter-spacing: -0.018em; margin-bottom: 4px; }
.hello__p { color: var(--ink-2); font-size: 13px; }
.suggest { display: flex; flex-wrap: wrap; gap: 6px; }
.suggest__b { height: 30px; padding: 0 11px; border-radius: 15px; border: 1px solid var(--line); background: var(--surface); font-size: 12.5px; color: var(--ink-2); transition: border-color 140ms, color 140ms, background 140ms; text-align: left; }
.suggest__b:hover { border-color: var(--funke); color: var(--ink); background: var(--funke-tint); }
.msg { max-width: 100%; animation: msg-in 260ms var(--ease); }
@keyframes msg-in { from { opacity: 0; transform: translateY(6px); } }
.msg--user { align-self: flex-end; max-width: 86%; background: var(--ink); color: oklch(0.97 0.004 80); padding: 8px 12px; border-radius: 13px 13px 4px 13px; font-size: 13px; }
.msg--ki { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 10px; }
.msg__av { width: 24px; height: 24px; border-radius: 7px; background: var(--funke-tint); color: var(--funke); display: grid; place-items: center; }
.msg__av .ic { width: 14px; height: 14px; }
.msg__body { display: flex; flex-direction: column; gap: 9px; font-size: 13.5px; line-height: 1.55; min-width: 0; padding-top: 2px; }
.msg__body p { margin: 0; }
.msg__body strong { font-weight: 640; }
.msg__body ol, .msg__body ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.msg__body li::marker { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.msg__body .blk-in { animation: msg-in 300ms var(--ease) both; }
.typing { display: inline-flex; gap: 4px; padding: 8px 0; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-4); animation: typing 1s infinite; }
.typing i:nth-child(2) { animation-delay: 0.15s; }
.typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes typing { 0%, 60%, 100% { opacity: 0.3; transform: none; } 30% { opacity: 1; transform: translateY(-2px); } }
.ochips { display: flex; flex-wrap: wrap; gap: 6px; }
.ochip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 9px 0 7px; border-radius: 7px; border: 1px solid var(--line); background: var(--surface); font-size: 12px; color: var(--ink-2); box-shadow: var(--shadow-1); }
.ochip:hover { border-color: var(--line-2); color: var(--ink); }
.ochip b { font: 500 12px var(--mono); color: var(--ink-3); }
.ochip .dot { margin: 0; width: 7px; height: 7px; border-radius: 2px; background: var(--st); }
.mini-tab { width: 100%; border-collapse: collapse; font-size: 12.5px; border: 1px solid var(--line); border-radius: 9px; overflow: hidden; display: table; }
.mini-tab th { text-align: left; font-weight: 600; color: var(--ink-3); font-size: 12px; padding: 6px 10px; background: var(--surface-2); border-bottom: 1px solid var(--line); }
.mini-tab td { padding: 7px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.mini-tab tr:last-child td { border-bottom: 0; }
.mini-tab .r { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mini-tab tfoot td { font-weight: 650; background: var(--surface-2); }
.callout { border-radius: 9px; padding: 10px 12px; background: var(--surface-2); border: 1px solid var(--line); font-size: 12.5px; color: var(--ink-2); }
.callout--funke { background: var(--funke-tint); border-color: var(--funke-tint-2); color: var(--ink); }
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.stat { border: 1px solid var(--line); border-radius: 9px; padding: 8px 10px; background: var(--surface); }
.stat__k { font-size: 12px; color: var(--ink-3); }
.stat__v { font-size: 17px; font-weight: 680; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat__d { font-size: 12px; color: var(--ok); font-weight: 600; }
.spark { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; align-items: end; height: 64px; padding: 8px 10px 0; border: 1px solid var(--line); border-radius: 9px 9px 0 0; border-bottom: 0; background: var(--surface); }
.spark i { display: block; border-radius: 3px 3px 0 0; background: var(--ink-4); height: calc(var(--v, 0) * 100%); transform-origin: 50% 100%; animation: spark-in 600ms var(--ease) both; animation-delay: calc(var(--i, 0) * 50ms); }
@keyframes spark-in { from { transform: scaleY(0); } }
.spark i:last-child { background: var(--funke); }
.spark-x { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; padding: 4px 10px 6px; border: 1px solid var(--line); border-top: 1px solid var(--line-2); border-radius: 0 0 9px 9px; font-size: 12px; color: var(--ink-3); text-align: center; font-variant-numeric: tabular-nums; }
.zettel { border: 1px solid var(--line); border-radius: 9px; overflow: hidden; font-size: 12.5px; }
.zettel__h { padding: 8px 12px; background: var(--ink); color: oklch(0.97 0.004 80); display: flex; justify-content: space-between; gap: 8px; font-weight: 600; }
.zettel__h span { font: 400 12px var(--mono); opacity: 0.8; }
.zettel dl { display: grid; grid-template-columns: 92px 1fr; gap: 5px 10px; padding: 10px 12px; }
.zettel dt { color: var(--ink-3); }
.zettel dd { font-weight: 520; }

/* ---------- Palette & Dialoge ---------- */
dialog { color: inherit; }
dialog::backdrop { background: oklch(0.22 0.02 258 / 0.22); backdrop-filter: blur(2px); }
.palette { width: min(620px, calc(100vw - 24px)); margin: 13vh auto auto; padding: 0; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-3); overflow: hidden; }
.palette[open] { animation: pal-in 180ms var(--ease); }
@keyframes pal-in { from { opacity: 0; transform: translateY(-6px) scale(0.985); } }
.palette__field { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 14px 0 16px; border-bottom: 1px solid var(--line); color: var(--ink-3); }
.palette__input { flex: 1; border: 0; background: none; font-size: 15px; height: 100%; color: var(--ink); }
.palette__input:focus { outline: none; }
.palette__input::placeholder { color: var(--ink-3); }
.palette__list { max-height: min(52vh, 420px); overflow-y: auto; padding: 6px; }
.palette__grp { font-size: 12px; color: var(--ink-3); font-weight: 600; padding: 8px 10px 4px; }
.palette__item { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 36px; padding: 6px 10px; border-radius: 8px; text-align: left; font-size: 13px; color: var(--ink-2); }
.palette__item .ic { color: var(--ink-3); }
.palette__item.is-act { background: var(--active); color: var(--ink); }
.palette__item.is-act .ic { color: var(--ink); }
.palette__item span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.palette__item small { color: var(--ink-3); font-size: 12px; }
.palette__item b { font: 500 12px var(--mono); color: var(--ink-3); margin-right: 2px; }
.palette__none { padding: 22px; text-align: center; color: var(--ink-3); }
.palette__foot { display: flex; gap: 14px; height: 34px; align-items: center; padding: 0 14px; border-top: 1px solid var(--line); color: var(--ink-3); font-size: 12px; background: var(--surface-2); }
.palette__foot .kbd { margin-right: 3px; }

.sheet { width: min(500px, calc(100vw - 24px)); padding: 0; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-3); max-height: calc(100dvh - 48px); }
.sheet[open] { animation: pal-in 200ms var(--ease); display: flex; flex-direction: column; }
.sheet--wide { width: min(900px, calc(100vw - 24px)); }
.sheet__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 12px 12px 18px; border-bottom: 1px solid var(--line); flex: none; }
.sheet__head h2 { font-size: 14px; font-weight: 650; }
.sheet__body { padding: 16px 18px 18px; overflow-y: auto; }
.sheet__foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 14px; border-top: 1px solid var(--line); background: var(--surface-2); flex: none; align-items: center; }
.sheet__foot small { margin-right: auto; color: var(--ink-3); font-size: 12px; }
.keys { padding: 10px 18px 18px; display: flex; flex-direction: column; }
.keys div { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.keys div:last-child { border-bottom: 0; }
.keys dt { display: flex; gap: 3px; align-items: center; color: var(--ink-3); order: 2; }
.keys dd { color: var(--ink); }
.draft { font-size: 13.5px; line-height: 1.6; }
.draft__meta { display: grid; grid-template-columns: 52px 1fr; gap: 4px 8px; font-size: 12.5px; padding-bottom: 12px; margin-bottom: 12px; border-bottom: 1px solid var(--line); }
.draft__meta dt { color: var(--ink-3); }
.draft p { margin: 0 0 0.8em; }
.draft__ki { color: var(--funke-ink); font-size: 12px; display: inline-flex; gap: 6px; align-items: center; margin-bottom: 12px; }
.big-draw { background-color: oklch(0.99 0.004 85); background-image: linear-gradient(oklch(0.9 0.02 230 / 0.35) 0.5px, transparent 0.5px), linear-gradient(90deg, oklch(0.9 0.02 230 / 0.35) 0.5px, transparent 0.5px); background-size: 14px 14px; border: 1px solid var(--line); border-radius: 10px; }
.big-draw svg { display: block; width: 100%; height: auto; }

/* ---------- Toasts ---------- */
.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 120; display: flex; flex-direction: column; gap: 8px; align-items: flex-end; pointer-events: none; }
.toast {
  pointer-events: auto; display: flex; align-items: center; gap: 10px; min-height: 42px; padding: 8px 8px 8px 12px; max-width: min(440px, calc(100vw - 32px));
  background: oklch(0.225 0.013 258); color: oklch(0.96 0.004 80); border-radius: 11px; box-shadow: var(--shadow-3); font-size: 13px;
  animation: toast-in 280ms var(--ease);
}
.toast.is-out { animation: toast-out 220ms var(--ease-io) forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px) scale(0.98); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(6px); } }
.toast .ic { color: oklch(0.8 0.12 48); }
.toast__t { flex: 1; min-width: 0; }
.toast__t small { display: block; color: oklch(0.78 0.006 258); font-size: 12px; }
.toast__b { height: 28px; padding: 0 10px; border-radius: 7px; background: oklch(1 0 0 / 0.1); color: #fff; font-weight: 560; font-size: 12.5px; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.toast__b:hover { background: oklch(1 0 0 / 0.18); }

.tabbar { display: none; }
.ring { width: 22px; height: 22px; border-radius: 50%; display: block; background: conic-gradient(var(--funke) calc(var(--p, 0) * 1%), var(--line) 0); position: relative; }
.ring::after { content: ''; position: absolute; inset: 3px; border-radius: 50%; background: var(--surface); }

/* ---------- Mittlere Breiten ---------- */
@media (max-width: 1360px) {
  .inbox { grid-template-columns: 272px minmax(0, 1fr) 400px; }
  .fr { grid-template-columns: 96px minmax(0, 1fr) 20px; }
  .fr.is-wait .fr__val::before { left: calc(96px + 8px); }
}
@media (max-width: 1180px) {
  .app { grid-template-columns: 60px minmax(0, 1fr); }
  .sidebar { padding: 12px 6px 10px 8px; align-items: center; }
  .brand { padding: 2px 0 12px; }
  .brand__text, .search-btn span, .search-btn .kbd, .nav__item > span:not(.nav__badge), .nav__item .kbd, .nav__count, .nav-group, .tour, .me__text, .me .icon-btn { display: none; }
  .search-btn { width: 36px; padding: 0; justify-content: center; }
  .nav__item { width: 40px; justify-content: center; padding: 0; position: relative; }
  .nav__badge { position: absolute; top: -2px; right: -4px; min-width: 16px; height: 16px; font-size: 12px; }
  .me { border: 0; padding: 0; justify-content: center; }
  .inbox { grid-template-columns: 260px minmax(0, 1fr) 380px; }
}
@media (max-width: 1020px) and (min-width: 761px) {
  .inbox { grid-template-columns: minmax(0, 1fr) 380px; }
  .inbox .mail-list { display: none; }
  .inbox[data-pane='list'] { grid-template-columns: minmax(0, 1fr); }
  .inbox[data-pane='list'] .mail-list { display: flex; }
  .inbox[data-pane='list'] .mail-view, .inbox[data-pane='list'] .auslese { display: none; }
  .mail-view__mtop { display: flex; }
}

/* ---------- Handy ---------- */
@media (max-width: 760px) {
  :root { --strip: 28px; --tabbar: calc(58px + env(safe-area-inset-bottom)); }
  .demo-strip { font-size: 12px; gap: 0; padding: 0 8px; }
  .demo-strip strong { font-size: 12px; }
  .demo-strip__sep { margin: 0 6px; }
  .demo-strip__link { display: none; }
  .demo-strip__text a { text-decoration: underline; text-decoration-color: oklch(1 0 0 / 0.35); text-underline-offset: 3px; }
  .app { grid-template-columns: minmax(0, 1fr); }
  .sidebar { display: none; }
  .main { margin: 0; border: 0; border-radius: 0; box-shadow: none; }
  .m-top { display: flex; align-items: center; gap: 8px; height: 50px; flex: none; padding: 0 6px 0 14px; border-bottom: 1px solid var(--line); background: var(--surface); }
  .m-top__title { flex: 1; font-weight: 680; font-size: 16px; letter-spacing: -0.015em; }
  .m-top .icon-btn { width: 40px; height: 40px; }
  .view-head { height: 46px; padding: 0 12px; gap: 8px; overflow-x: auto; scrollbar-width: none; }
  .view-head__title { display: none; }
  .view-head__meta { flex: 1; }
  .view-head__spacer { display: none; }
  .seg__btn { height: 30px; }

  .inbox { grid-template-columns: minmax(0, 1fr); position: relative; }
  .inbox .mail-list, .inbox .mail-view, .inbox .auslese { display: none; }
  .inbox[data-pane='list'] .mail-list { display: flex; border-right: 0; }
  .inbox[data-pane='mail'] .mail-view { display: block; }
  .inbox[data-pane='auftrag'] .auslese { display: flex; border-left: 0; }
  .view[data-view='eingang'] .view-head { display: none; }
  .inbox[data-pane='list'] ~ * { display: none; }
  .mail-item { padding: 12px 10px 12px 6px; }
  .mail-view__inner { padding: 14px 16px 120px; }
  .mail-view__mtop, .ausl-mtop { display: flex; }
  .mail-subj { font-size: 18px; }
  .mail-meta { grid-template-columns: 32px minmax(0, 1fr); }
  .mail-meta__date { grid-column: 2; grid-row: auto; }
  .mail-body { font-size: 15px; }
  .att { width: 100%; }
  .att__thumb { height: 190px; }
  .ausl-body { padding: 12px 12px 16px; }
  .ausl-foot { padding: 10px 12px; }
  .ausl-foot__hint { display: none; }
  .ausl-foot .btn { flex: 1; justify-content: center; height: 42px; }
  .ausl-foot .kbd { display: none; }
  .fr { grid-template-columns: 92px minmax(0, 1fr) 20px; padding: 6px 4px; }
  .fr.is-wait .fr__val::before { left: calc(92px + 8px); }
  .m-strip {
    display: flex; position: sticky; bottom: 10px; margin: 18px -4px 0; z-index: 5; align-items: center; gap: 8px;
    background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-3); padding: 8px 8px 8px 10px; min-height: 52px;
  }
  .m-strip__chips { flex: 1; min-width: 0; display: flex; gap: 4px; overflow: hidden; mask-image: linear-gradient(90deg, #000 85%, transparent); }
  .m-strip__chips .chip { flex: none; }
  .m-strip__label { font-size: 12px; color: var(--ink-3); white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; }
  .m-strip .btn { flex: none; }

  .stage-tabs { display: flex; gap: 6px; padding: 10px 12px 2px; overflow-x: auto; scrollbar-width: none; flex: none; }
  .stage-tab { flex: none; height: 32px; padding: 0 12px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); font-size: 12.5px; font-weight: 550; color: var(--ink-2); display: inline-flex; align-items: center; gap: 6px; }
  .stage-tab i { width: 7px; height: 7px; border-radius: 2px; background: var(--st); }
  .stage-tab[aria-selected='true'] { background: var(--ink); color: #fff; border-color: var(--ink); }
  .stage-tab span { color: inherit; opacity: 0.7; font-variant-numeric: tabular-nums; }
  .board { grid-auto-columns: calc(100vw - 40px); scroll-snap-type: x mandatory; padding: 10px 12px 16px; gap: 10px; scroll-padding: 12px; overscroll-behavior-x: contain; }
  .col { scroll-snap-align: start; }
  .card { padding: 11px 12px; }
  .card__menu { opacity: 1; width: 32px; height: 32px; top: 3px; right: 3px; }
  .card .pips { visibility: hidden; }
  #tafel-filter { flex: none; }
  .view[data-view='tafel'] .view-head__meta { display: none; }

  .week { padding: 12px 12px 20px; }
  .wgrid, .legend { display: none; }
  .wmob { display: block; }
  .insights { grid-template-columns: 1fr; }
  .weeknav__label { min-width: 0; padding: 0 4px; }
  .view[data-view='woche'] .view-head__meta { display: none; }
  .view[data-view='woche'] .view-head { justify-content: space-between; }
  .weeknav { margin-left: auto; }

  .assist, .drawer { top: 0; right: 0; bottom: 0; left: 0; width: 100%; border-radius: 0; border: 0; z-index: 110; }
  .assist__form { padding-bottom: calc(12px + env(safe-area-inset-bottom)); }
  .assist__send { top: 16px; }
  .drawer__head { padding: 10px 10px 14px 16px; }
  .drawer__body { padding: 14px 16px 40px; }
  .facts { grid-template-columns: 104px minmax(0, 1fr); }
  .stepper__b { font-size: 12px; }

  .toasts { left: 8px; right: 8px; bottom: calc(var(--tabbar) + 10px); align-items: stretch; }
  .toast { max-width: none; }

  .tabbar {
    display: grid; grid-template-columns: repeat(4, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
    height: var(--tabbar); padding-bottom: env(safe-area-inset-bottom);
    background: oklch(0.994 0.002 80 / 0.92); backdrop-filter: saturate(1.4) blur(14px); border-top: 1px solid var(--line);
  }
  .tabbar__item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 12px; font-weight: 550; color: var(--ink-3); text-decoration: none; position: relative; }
  .tabbar__item .ic { width: 20px; height: 20px; }
  .tabbar__item.is-on { color: var(--ink); }
  .tabbar__item.is-on::before { content: ''; position: absolute; top: 0; width: 28px; height: 2px; border-radius: 0 0 2px 2px; background: var(--funke); }
  .tabbar__badge { position: absolute; top: 7px; left: calc(50% + 6px); min-width: 16px; height: 16px; border-radius: 8px; background: var(--funke-btn); color: #fff; font-size: 12px; font-weight: 650; display: grid; place-items: center; padding: 0 4px; }
  .palette { margin-top: 8vh; }
  .sheet { max-height: calc(100dvh - 24px); }
}
.wmob__days { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 12px; }
.wmob__day { border: 1px solid var(--line); border-radius: 10px; padding: 7px 4px 8px; display: flex; flex-direction: column; align-items: center; gap: 3px; background: var(--surface); font-size: 12px; color: var(--ink-2); }
.wmob__day b { font-weight: 650; color: var(--ink); }
.wmob__day small { font-size: 12px; font-variant-numeric: tabular-nums; color: var(--ink-3); }
.wmob__day.is-over small { color: var(--warn); font-weight: 650; }
.wmob__day[aria-pressed='true'] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.wmob__day.is-today b::after { content: ''; display: inline-block; width: 5px; height: 5px; border-radius: 50%; background: var(--funke); margin-left: 4px; vertical-align: 2px; }
.wmob__res { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; background: var(--surface); }
.wmob__res.is-over { border-color: oklch(0.82 0.08 27); background: var(--warn-tint); }
.wmob__rh { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.wmob__rh b { font-weight: 640; }
.wmob__rh small { color: var(--ink-3); font-size: 12px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wmob__rh em { font-style: normal; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.wmob__res.is-over em { color: var(--warn); }
.wmob__track { display: flex; gap: 3px; min-height: 44px; }


/* ---------- Ergänzungen: Fenster-Kopf, Leerzustand, Bezug ---------- */
.pane-top { display: none; }
.mv-empty { height: 100%; min-height: 320px; display: grid; place-content: center; justify-items: center; gap: 12px; text-align: center; color: var(--ink-3); font-size: 13px; line-height: 1.55; }
.mv-empty__ic { width: 44px; height: 44px; border-radius: 12px; background: var(--sunken); display: grid; place-items: center; color: var(--ink-4); }
.mv-empty__ic .ic { width: 20px; height: 20px; }
.zg__wait { aspect-ratio: 420 / 326; display: grid; place-items: center; color: var(--ink-4); font-size: 12px; letter-spacing: 0.02em; }
.ausl-progress.is-done { opacity: 0; transition: opacity 600ms var(--ease) 400ms; }
.auslese .einordnung { margin: 0; max-width: none; background: var(--surface); }
.ref { display: flex; flex-direction: column; gap: 2px; width: 100%; text-align: left; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); box-shadow: var(--shadow-1); transition: border-color 140ms, box-shadow 140ms; }
button.ref:hover { border-color: var(--line-2); box-shadow: var(--shadow-2); }
.ref__top { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-3); margin-bottom: 2px; }
.ref__top .mono { font-size: 12px; }
.ref__st { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.ref__st i { width: 7px; height: 7px; border-radius: 2px; background: var(--st); }
.ref__t { margin-left: auto; font-variant-numeric: tabular-nums; }
.ref__k { font-size: 12px; color: var(--ink-3); }
.ref__o { font-weight: 620; font-size: 13px; color: var(--ink); }
.ref__z { font-size: 12px; color: var(--ink-2); }
.sk-hit.is-hot { opacity: 1; stroke-width: 2.2; stroke-dasharray: none; }
.big-draw--foto { background: oklch(0.3 0.01 60); padding: 0; }
.sheet__note { display: flex; gap: 8px; align-items: flex-start; margin-top: 12px; color: var(--ink-2); font-size: 12.5px; line-height: 1.5; }
.tour--sheet { border: 0; box-shadow: none; padding: 0; }
.tour--sheet .tour__step { padding: 8px 6px; font-size: 14px; }
.menu__sep { height: 1px; background: var(--line); margin: 4px -4px; }
.menu__item span { flex: 1; }
.menu__item span.col__ic { flex: none; display: grid; place-items: center; background: var(--st); color: #fff; }
.menu__item span.col__ic .ic { width: 10px; height: 10px; }
.facts__team { display: flex; flex-direction: column; gap: 5px; }
.facts__team span { display: inline-flex; align-items: center; gap: 7px; }
.facts dd .card__bar { margin-top: 6px; }
.facts--gap { margin-top: 16px; }
body.is-dragging, body.is-dragging * { cursor: grabbing !important; user-select: none; }
.has-assist .toasts { right: 454px; }
.tour.tour--sheet { display: block; }

/* Woche */
.insights { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.wgrid-wrap { overflow-x: auto; border-radius: var(--r-m); }
.wrow { display: contents; }
.wr__n .avatar { width: 24px; height: 24px; font-size: 12px; }
.wr__n .avatar + .avatar { margin-left: -10px; }
.wh__pct .ic { color: var(--warn); margin-right: 3px; vertical-align: -1px; }
.blk:focus-visible { outline: 2px solid var(--focus, var(--funke)); outline-offset: 1px; z-index: 1; }
.legend .lg-over { background: repeating-linear-gradient(-45deg, var(--warn-tint) 0 3px, oklch(0.985 0.01 27) 3px 6px); box-shadow: inset 0 0 0 1px oklch(0.82 0.08 27); }
.wmob__title { font-size: 13px; font-weight: 650; margin: 2px 2px 10px; color: var(--ink-2); }
.wmob__track .blk { min-height: 44px; }
.wc__free--line { border: 1px dashed var(--line-2); }

/* Assistent */
.msg__act { display: flex; flex-wrap: wrap; gap: 6px; }
.msg__act:empty { display: none; }
.msg__next { margin-top: 4px; padding-top: 10px; border-top: 1px dashed var(--line); }
.msg__body .suggest__b { height: auto; min-height: 30px; padding: 5px 11px; text-align: left; line-height: 1.35; }
.mini-tab small { color: var(--ink-3); font-size: 12px; }
.mini-tab .mono { font-size: 12px; color: var(--ink-3); }
.btn:disabled { opacity: 0.45; pointer-events: none; }

@media (max-width: 1020px) {
  .pane-top { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 6; }
  .pane-top .seg { display: none; }
  .auslese .pane-top { display: none; }
  .has-assist .toasts { right: 16px; }
  .wh__today { display: none; }
}
@media (max-width: 760px) {
  .pane-top .seg { display: inline-flex; margin-left: auto; }
  .auslese .pane-top { display: flex; }
  .pane-top .seg__btn { height: 32px; padding: 0 14px; }
  .has-assist .toasts { left: 8px; right: 8px; top: 8px; bottom: auto; }
  .stat__k { font-size: 12px; }
  .stat__v { font-size: 15px; }
  .stat { padding: 7px 8px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
  .zeichnung.is-drawing .draw { stroke-dashoffset: 0; }
  .zeichnung.is-drawing .fade { opacity: 1; }
}
@media (forced-colors: active) {
  mark.src.is-found { background: Mark; color: MarkText; }
  .pos { border: 1px solid CanvasText; }
}

/* ---------- V19.14 (Owner 24.10., P43): Tippflächen mindestens 44 px ----------
   Optik bleibt: Hover-Flächen werden höher, Zwischenräume und feste Zeilenhöhen geben entsprechend nach. */
:root { --hit: 44px; }
.demo-strip__text a { display: inline-flex; align-items: center; min-height: var(--hit); margin-block: calc((var(--strip) - var(--hit)) / 2); }
.demo-strip__link { min-height: var(--hit); }
.search-btn { height: auto; min-height: var(--hit); }
.nav__item, .nav__item--sub { height: auto; min-height: var(--hit); }
.tour__step { min-height: var(--hit); padding-block: 0; }
.btn, .btn--sm, .btn--lg { height: auto; min-height: var(--hit); }
.icon-btn, .m-top .icon-btn { width: var(--hit); height: var(--hit); }
.seg__btn, .pane-top .seg__btn { height: auto; min-height: var(--hit); min-width: var(--hit); }
.stepper__b { min-height: var(--hit); padding: 6px 0 8px; justify-content: center; }
.seg { border-radius: 10px; }
.view-head { min-height: 52px; height: auto; }
.menu__item { height: auto; min-height: var(--hit); }
.palette__item { min-height: var(--hit); }
.assist__input { height: var(--hit); }
.assist__send { width: var(--hit); height: var(--hit); right: 12px; top: 10px; }
.suggest__b, .msg__body .suggest__b { height: auto; min-height: var(--hit); }
.ochip { height: auto; min-height: var(--hit); }
.toast__b { height: auto; min-height: var(--hit); }
.stage-tab { height: auto; min-height: var(--hit); }
.card__menu { width: var(--hit); height: var(--hit); top: 2px; right: 2px; }
.fr { min-height: var(--hit); align-content: center; }
.ausl-foot .btn { height: auto; min-height: var(--hit); }
@media (max-width: 1180px) {
  .search-btn, .nav__item { width: var(--hit); }
}
