/* Livadora Kundenservice · Designsystem (CI wie Versand: #F2F3EE, #1C1C1C, #DCFD6F, Inter)
   Ebenen: Grund (--bg) → Fläche (--surface, --shadow-1) → schwebend (--shadow-2/3). Nur transform/opacity animieren. */
:root {
  --bg: #F2F3EE; --ink: #1C1C1C; --accent: #DCFD6F; --accent-deep: #C4E84F;
  --surface: #FFFFFF; --surface-2: #F8F9F5; --muted: #6E706A; --faint: #9A9C94;
  --line: #E4E6DD; --line-strong: #C9CCC0;
  --warn-bg: #FFF4D9; --warn-line: #F0C46A; --warn-ink: #7A5200;
  --err: #B3392A; --err-bg: #FCEAE6; --err-line: #F1B9AE; --ok: #2F6B3A; --ok-bg: #E7F3E4;
  --radius: 14px; --radius-sm: 10px; --radius-xs: 7px;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px;
  --shadow-1: 0 1px 1px rgba(28,28,28,.04), 0 2px 6px rgba(52,58,32,.05);
  --shadow-2: 0 1px 2px rgba(28,28,28,.05), 0 8px 24px -6px rgba(52,58,32,.14);
  --shadow-3: 0 2px 4px rgba(28,28,28,.06), 0 18px 40px -12px rgba(52,58,32,.25);
  --spring: cubic-bezier(.2,.9,.3,1.25);
  --top-h: 56px;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body.lv { margin: 0; background: var(--bg); color: var(--ink); font: 14px/1.55 Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-feature-settings: "cv11"; -webkit-font-smoothing: antialiased; }
:where(.lv) :where(button, input, select, textarea) { font: inherit; color: inherit; }
:where(.lv) a { color: inherit; }
.num, time { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.leer { color: var(--faint); font-style: italic; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ── Kopfzeile ─────────────────────────────────────────── */
.lv-top { position: sticky; top: 0; z-index: 30; height: var(--top-h); display: flex; align-items: center; gap: var(--s4); padding: 0 var(--s4);
  background: rgba(242,243,238,.9); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.lv-brand { display: flex; align-items: baseline; gap: var(--s2); text-decoration: none; flex: none; }
.lv-brand b { font-weight: 800; letter-spacing: .14em; font-size: 14px; }
.lv-apps { display: flex; gap: 2px; padding: 3px; background: rgba(28,28,28,.05); border-radius: 99px; flex: none; }
.lv-apps a { text-decoration: none; padding: 4px 12px; border-radius: 99px; font-size: 13px; font-weight: 600; color: var(--muted); transition: background-color .15s, color .15s; }
.lv-apps a:hover { color: var(--ink); }
.lv-apps a.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-1); }
.lv-apps a:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.lv-search { flex: 1; max-width: 560px; display: flex; align-items: center; gap: var(--s2); height: 36px; padding: 0 var(--s3);
  background: var(--surface); border: 1px solid var(--line); border-radius: 99px; color: var(--muted); box-shadow: var(--shadow-1); }
.lv-search:focus-within { border-color: var(--line-strong); box-shadow: 0 0 0 3px rgba(220,253,111,.55); }
.lv-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; color: var(--ink); }
.kbd { font-size: 11px; font-weight: 600; padding: 1px 6px; border-radius: 5px; background: var(--surface-2); border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.lv-top-right { margin-left: auto; display: flex; align-items: center; gap: var(--s2); flex: none; }
.chip { font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 99px; background: var(--surface); border: 1px solid var(--line); color: var(--muted);
  white-space: nowrap; display: inline-flex; align-items: center; gap: 5px; text-decoration: none; }
.chip-dark { background: var(--ink); border-color: var(--ink); color: var(--accent); }
.chip-warn { background: var(--warn-bg); border-color: var(--warn-line); color: var(--warn-ink); }
.avatar { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 12px; background: var(--ink); color: var(--accent); flex: none; }
.avatar-lg { width: 40px; height: 40px; font-size: 14px; }
.lv-menu { position: relative; }
.lv-menu > button { border: 0; background: none; padding: 0; cursor: pointer; border-radius: 50%; }
.lv-menu > button:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.lv-menu-pop { position: absolute; right: 0; top: calc(100% + 8px); min-width: 230px; padding: var(--s2); background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-3); opacity: 0; transform: translateY(-4px) scale(.98); pointer-events: none;
  transition: opacity .15s, transform .2s var(--spring); z-index: 40; }
.lv-menu.open .lv-menu-pop { opacity: 1; transform: none; pointer-events: auto; }
.lv-menu-pop .kopf { padding: var(--s2) var(--s3) var(--s3); border-bottom: 1px solid var(--line); margin-bottom: var(--s1); }
.lv-menu-pop .kopf b { display: block; } .lv-menu-pop .kopf span { font-size: 12px; color: var(--muted); }
.lv-menu-pop a { display: flex; align-items: center; gap: var(--s3); padding: 8px var(--s3); border-radius: var(--radius-xs); text-decoration: none; font-weight: 500; }
.lv-menu-pop a:hover { background: var(--surface-2); }
.lv-menu-pop a:focus-visible { outline: 2px solid var(--ink); }
.lv-menu-pop hr { border: 0; border-top: 1px solid var(--line); margin: var(--s1) 0; }

/* ── Knöpfe, Schlagworte, Karten ───────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--line-strong);
  background: var(--surface); font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; text-decoration: none;
  transition: transform .2s var(--spring), background-color .15s, box-shadow .15s, opacity .15s; }
.btn:hover { background: var(--surface-2); box-shadow: var(--shadow-1); }
.btn:active { transform: scale(.97); }
.btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-ink { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-ink:hover { background: #000; }
.btn-accent { background: var(--accent); border-color: var(--accent-deep); color: var(--ink); }
.btn-accent:hover { background: var(--accent-deep); }
.btn-danger { color: var(--err); border-color: var(--err-line); }
.btn-icon { width: 34px; padding: 0; }
.btn-sm { height: 28px; padding: 0 10px; font-size: 12px; }
.tag { font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 99px; background: var(--surface); border: 1px solid var(--line); color: var(--muted); white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; }
.tag-marie { background: var(--accent); border-color: var(--accent-deep); color: var(--ink); }
.tag-warn { background: var(--warn-bg); border-color: var(--warn-line); color: var(--warn-ink); }
.tag-err { background: var(--err-bg); border-color: var(--err-line); color: var(--err); }
.tag-ok { background: var(--ok-bg); border-color: #BFDDB8; color: var(--ok); }
.tag-ink { background: var(--ink); border-color: var(--ink); color: #fff; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s4); box-shadow: var(--shadow-1); }
.card h3 { margin: 0 0 var(--s3); font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); display: flex; align-items: center; gap: var(--s2); }
.card h3 a { margin-left: auto; text-transform: none; letter-spacing: 0; color: var(--muted); font-weight: 600; text-decoration: none; }
.card h3 a:hover { color: var(--ink); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 4px var(--s3); margin: var(--s3) 0 0; font-size: 13px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; text-align: right; font-weight: 500; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.hinweis { padding: var(--s3); border-radius: var(--radius-sm); font-size: 12.5px; display: flex; gap: var(--s2); }
.hinweis-err { background: var(--err-bg); border: 1px solid var(--err-line); color: var(--err); }
.hinweis-warn { background: var(--warn-bg); border: 1px solid var(--warn-line); color: var(--warn-ink); }

/* ── Toast ─────────────────────────────────────────────── */
.lv-toast { position: fixed; left: 50%; bottom: var(--s5); transform: translate(-50%, 12px); opacity: 0; z-index: 60; pointer-events: none;
  padding: var(--s3) var(--s4); background: var(--ink); color: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-3); font-weight: 500;
  transition: opacity .2s, transform .3s var(--spring); }
.lv-toast.zeigen { opacity: 1; transform: translate(-50%, 0); }
.lv-toast.fehler { background: var(--err); }

/* ── Posteingang: App-Raster ───────────────────────────── */
.pe { display: grid; grid-template-columns: 216px 336px minmax(0,1fr) 304px; height: calc(100vh - var(--top-h)); }
.pe.ohne-leiste { grid-template-columns: 216px 336px minmax(0,1fr); }
.pe-views { padding: var(--s4) var(--s3); overflow: auto; border-right: 1px solid var(--line); }
.pe-views h6 { margin: var(--s5) var(--s2) var(--s2); font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); }
.pe-views h6:first-child { margin-top: 0; }
.view { display: flex; align-items: center; gap: var(--s3); padding: 7px var(--s3); border-radius: var(--radius-sm); color: var(--muted); text-decoration: none;
  font-weight: 500; white-space: nowrap; transition: background-color .15s, color .15s; }
.view i { font-size: 15px; width: 16px; text-align: center; }
.view .n { margin-left: auto; font-size: 12px; font-weight: 600; color: var(--faint); font-variant-numeric: tabular-nums; }
.view:hover { background: rgba(255,255,255,.7); color: var(--ink); }
.view:focus-visible { outline: 2px solid var(--ink); outline-offset: 1px; }
.view.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-1); font-weight: 600; }
.view.on .n { color: var(--ink); }
.view .n.hot { min-width: 22px; height: 20px; padding: 0 7px; border-radius: 99px; background: var(--ink); color: var(--accent); display: inline-grid; place-items: center; }

.pe-list { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); background: var(--surface-2); }
.pe-list-head { padding: var(--s4) var(--s4) var(--s3); border-bottom: 1px solid var(--line); background: var(--bg); }
.pe-list-head h1 { margin: 0; font-size: 20px; font-weight: 800; letter-spacing: -.03em; line-height: 1.2; }
.pe-list-head .sub { color: var(--muted); font-size: 13px; }
.pe-rows { overflow: auto; flex: 1; }
.pe-row { display: grid; grid-template-columns: 8px minmax(0,1fr) auto; gap: 2px var(--s3); padding: var(--s3) var(--s4); border-bottom: 1px solid var(--line);
  text-decoration: none; background: var(--surface-2); transition: background-color .15s; }
.pe-row:hover { background: var(--surface); }
.pe-row:focus-visible { outline: 2px solid var(--ink); outline-offset: -2px; }
.pe-row.on { background: var(--surface); box-shadow: inset 3px 0 0 var(--ink); }
.pe-row .dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; }
.pe-row .dot.unread { background: var(--ink); }
.pe-row .who { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pe-row .time { font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.pe-row .subj, .pe-row .prev, .pe-row .tags { grid-column: 2 / 4; }
.pe-row .subj { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 500; }
.pe-row .prev { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pe-row .tags { display: flex; gap: var(--s1); margin-top: 6px; flex-wrap: wrap; }
.pe-empty { padding: var(--s6) var(--s4); text-align: center; color: var(--muted); }
.pe-empty i { font-size: 28px; display: block; margin-bottom: var(--s2); color: var(--faint); }

.pe-conv { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.pe-conv-head { display: flex; align-items: center; gap: var(--s3); padding: var(--s3) var(--s5); border-bottom: 1px solid var(--line); }
.pe-conv-head h2 { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pe-conv-head .meta { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pe-conv-actions { margin-left: auto; display: flex; gap: var(--s2); flex: none; }
.pe-conv-actions select { width: auto; max-width: 156px; height: 34px; border-radius: 99px; border: 1px solid var(--line-strong); background: var(--surface); padding: 0 12px; font-weight: 600; font-size: 13px; }
.pe-thread { flex: 1; min-height: 140px; overflow: auto; padding: var(--s5); display: flex; flex-direction: column; gap: var(--s4); }
.msg { max-width: 720px; min-width: 0; }
.msg-meta { display: flex; align-items: center; gap: var(--s2); font-size: 12px; color: var(--muted); margin-bottom: 6px; flex-wrap: wrap; }
.msg-meta b { color: var(--ink); font-weight: 600; }
.bubble { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s4); box-shadow: var(--shadow-1); overflow-wrap: anywhere; }
.mail-eigen { white-space: pre-line; }
.mail-zitat { margin-top: var(--s3); font-size: 12.5px; color: var(--muted); }
.mail-zitat summary { cursor: pointer; font-weight: 600; list-style: none; }
.mail-zitat summary::-webkit-details-marker { display: none; }
.mail-zitat summary::before { content: "⋯ "; }
.mail-zitat div { white-space: pre-line; margin-top: var(--s2); padding-left: var(--s3); border-left: 2px solid var(--line); }
.msg.us { align-self: flex-end; }
.msg.us .msg-meta { justify-content: flex-end; }
.msg.us .bubble { background: var(--ink); color: #F2F3EE; border-color: var(--ink); }
.msg.us .mail-zitat { color: rgba(242,243,238,.6); }
.msg.us .mail-zitat div { border-color: rgba(242,243,238,.2); }
.msg.auto .bubble { background: transparent; color: var(--muted); border-style: dashed; box-shadow: none; font-size: 13px; }
.msg.notiz .bubble { background: var(--warn-bg); border-color: var(--warn-line); color: var(--ink); }
.anhaenge { display: flex; gap: var(--s2); flex-wrap: wrap; margin-top: var(--s2); }

.composer { flex: none; margin: 0 var(--s4) var(--s4); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-2); overflow: hidden; }
.composer-tabs { display: flex; gap: var(--s1); padding: var(--s2) var(--s3) 0; border-bottom: 1px solid var(--line); }
.composer-tabs button { border: 0; background: none; padding: 8px 10px; font-size: 13px; font-weight: 600; color: var(--muted); border-bottom: 2px solid transparent; cursor: pointer; }
.composer-tabs button.on { color: var(--ink); border-color: var(--ink); }
.composer-tabs button:focus-visible { outline: 2px solid var(--ink); }
.marie-strip { display: flex; align-items: flex-start; gap: var(--s3); padding: 10px var(--s4); background: linear-gradient(90deg, rgba(220,253,111,.35), rgba(220,253,111,.08)); border-bottom: 1px solid var(--line); font-size: 13px; }
.marie-strip.sicher { background: linear-gradient(90deg, rgba(220,253,111,.75), rgba(220,253,111,.25)); }
.marie-strip .m { width: 26px; height: 26px; border-radius: 8px; background: var(--ink); color: var(--accent); display: grid; place-items: center; font-weight: 800; font-size: 12px; flex: none; }
.marie-strip ul { margin: 2px 0 0; padding-left: 16px; color: #4E5049; }
.composer textarea { display: block; width: 100%; border: 0; outline: 0; resize: none; padding: var(--s3) var(--s4); min-height: 120px; max-height: 260px; background: transparent; line-height: 1.6; }
.composer.notiz-modus { border-color: var(--warn-line); }
.composer.notiz-modus textarea { background: var(--warn-bg); }
.composer-foot { display: flex; align-items: center; gap: var(--s2); padding: var(--s3) var(--s4); border-top: 1px solid var(--line); background: var(--surface-2); }
.composer-foot .hint { color: var(--faint); font-size: 12px; margin-right: auto; white-space: nowrap; overflow: hidden; }

.pe-side { overflow: auto; padding: var(--s3); border-left: 1px solid var(--line); display: flex; flex-direction: column; gap: var(--s3); }
.cust { display: flex; gap: var(--s3); align-items: center; min-width: 0; }
.cust .name { font-weight: 700; font-size: 15px; }
.cust .mail { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.order-top { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s2); }
.order-top b { font-size: 16px; font-weight: 800; letter-spacing: -.02em; }
.items { list-style: none; margin: var(--s3) 0 0; padding: 0; display: grid; gap: var(--s2); }
.items li { display: flex; gap: var(--s3); align-items: center; font-size: 13px; }
.thumb { width: 38px; height: 38px; border-radius: 9px; background: linear-gradient(135deg, #E9EBE3, #D9DCD1); flex: none; display: grid; place-items: center; color: var(--muted); overflow: hidden; }
.items .p { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.track { margin-top: var(--s3); padding: var(--s3); border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--line); }
.steps { display: grid; grid-template-columns: repeat(4,1fr); gap: 4px; margin: var(--s2) 0 6px; }
.steps span { height: 5px; border-radius: 99px; background: var(--line); }
.steps span.done { background: var(--ink); }
.track .t { font-size: 13px; font-weight: 600; } .track .d { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s2); }
.act { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: var(--s3); border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface-2);
  font-size: 12.5px; font-weight: 600; cursor: pointer; text-align: left; transition: transform .2s var(--spring), background-color .15s, border-color .15s; }
.act i { font-size: 16px; }
.act:hover { background: var(--surface); border-color: var(--line-strong); }
.act:active { transform: scale(.97); }
.act:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.act.primary { background: var(--accent); border-color: var(--accent-deep); }
.history { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s2); font-size: 13px; }
.history a { display: flex; justify-content: space-between; gap: var(--s2); text-decoration: none; }
.history a:hover { text-decoration: underline; }
.history span { color: var(--muted); white-space: nowrap; }

/* ── Dialog (Bestätigung für Aktionen) ─────────────────── */
dialog.lv-dialog { border: 0; padding: 0; border-radius: var(--radius); box-shadow: var(--shadow-3); width: min(440px, calc(100vw - 32px)); background: var(--surface); color: var(--ink); }
dialog.lv-dialog::backdrop { background: rgba(28,28,28,.35); backdrop-filter: blur(2px); }
.lv-dialog form { padding: var(--s5); display: grid; gap: var(--s3); }
.lv-dialog h4 { margin: 0; font-size: 17px; letter-spacing: -.02em; }
.lv-dialog label { display: grid; gap: 4px; font-size: 13px; font-weight: 600; }
.lv-dialog input, .lv-dialog textarea { border: 1px solid var(--line-strong); border-radius: var(--radius-xs); padding: 8px 10px; font-weight: 400; }
.lv-dialog input:focus, .lv-dialog textarea:focus { outline: 2px solid var(--ink); outline-offset: 0; }
.lv-dialog-kopf { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); }
.lv-dialog-zu { border: 0; background: transparent; color: var(--ink); width: 32px; height: 32px; border-radius: 999px; display: grid; place-items: center; cursor: pointer;
  transition: transform .18s cubic-bezier(.34,1.56,.64,1), opacity .18s; }
.lv-dialog-zu:hover { background: var(--line); }
.lv-dialog-zu:focus-visible { outline: 2px solid var(--ink); outline-offset: 1px; }
.lv-dialog-zu:active { transform: scale(.92); }
/* Seitenfenster (nicht modal): rechts über der Bestellspalte, Verlauf bleibt bedienbar */
dialog.lv-dialog--seite { position: fixed; inset: 72px 16px auto auto; margin: 0; z-index: 60; width: min(400px, calc(100vw - 32px));
  max-height: calc(100vh - 88px); overflow: auto;
  box-shadow: 0 1px 2px rgba(28,28,20,.06), 0 12px 32px -8px rgba(28,28,20,.18), 0 32px 64px -24px rgba(28,28,20,.22);
  animation: lv-seite-rein .22s cubic-bezier(.34,1.3,.64,1); }
@keyframes lv-seite-rein { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
@media (max-width: 900px) { dialog.lv-dialog--seite { inset: auto 8px 8px 8px; width: auto; max-height: 70vh; } }
.pe-dlg-zwei { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s2); }
.pe-dlg-plz { grid-template-columns: 110px 1fr; }
.pe-dlg-info { margin: 0; font-size: 13px; }
#pe-dialog-inhalt { display: grid; gap: var(--s3); }
.lv-dialog input, .lv-dialog textarea, .lv-dialog select { width: 100%; min-width: 0; box-sizing: border-box; }
.lv-dialog label, .pe-dlg-zwei > * { min-width: 0; }
dialog.lv-dialog--seite { overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.lv-dialog--seite form { padding-bottom: 0; }
.lv-dialog--seite .knoepfe { position: sticky; bottom: 0; margin: 0 calc(-1 * var(--s5)); padding: var(--s3) var(--s5) var(--s5);
  background: linear-gradient(to bottom, transparent, var(--surface) 12px); }
.lv-dialog input:disabled { background: var(--bg, #F4F4F1); color: var(--ink); border-color: var(--line); }
.lv-dialog .knoepfe { display: flex; justify-content: flex-end; gap: var(--s2); margin-top: var(--s2); }

/* ── Seiten (Einstellungen u. a.) ───────────────────────── */
.lv-page { max-width: 1080px; margin: 0 auto; padding: var(--s6) var(--s4) var(--s7); }
.lv-page h1 { margin: 0; font-size: clamp(26px, 4vw, 36px); font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
.lv-page .lead { margin: var(--s2) 0 var(--s5); color: var(--muted); font-size: 15px; max-width: 640px; line-height: 1.7; }
.lv-tabelle { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-1); overflow: hidden; }
.lv-tabelle th, .lv-tabelle td { padding: var(--s3) var(--s4); text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.lv-tabelle th { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); background: var(--surface-2); }
.lv-tabelle tr:last-child td { border-bottom: 0; }
.lv-tabelle td.mitte, .lv-tabelle th.mitte { text-align: center; }
.lv-tabelle .titel { font-weight: 600; } .lv-tabelle .sub { font-size: 12px; color: var(--muted); }
.schalter { position: relative; display: inline-block; width: 38px; height: 22px; flex: none; }
.schalter input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.schalter span { position: absolute; inset: 0; border-radius: 99px; background: var(--line-strong); transition: background-color .15s; }
.schalter span::after { content: ""; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-1); transition: transform .25s var(--spring); }
.schalter input:checked + span { background: var(--ink); }
.schalter input:checked + span::after { transform: translateX(16px); background: var(--accent); }
.schalter input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.schalter input:disabled + span { opacity: .45; }
.abschnitt { margin-top: var(--s6); }
.abschnitt h2 { margin: 0 0 var(--s3); font-size: 18px; font-weight: 700; letter-spacing: -.02em; }
.leiste-unten { position: sticky; bottom: var(--s4); margin-top: var(--s5); display: flex; justify-content: flex-end; gap: var(--s2); }

@media (max-width: 1280px) { .pe { grid-template-columns: 200px 300px minmax(0,1fr) 280px; } }
@media (max-width: 1100px) { .pe, .pe.ohne-leiste { grid-template-columns: 64px 300px minmax(0,1fr); } .pe-side { display: none; }
  .pe-views h6, .view span.t, .view .n:not(.hot) { display: none; } .view { justify-content: center; padding: 9px 0; } }
@media (max-width: 760px) { .lv-search, .lv-apps { display: none; } .pe, .pe.ohne-leiste { grid-template-columns: 1fr; height: auto; }
  .pe-views { display: flex; gap: var(--s1); overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--line); padding: var(--s2) var(--s4); }
  .pe-views h6 { display: none; } .view span.t { display: inline; } .view { justify-content: flex-start; padding: 6px 12px; }
  .pe.mit-ticket .pe-list { display: none; } .pe:not(.mit-ticket) .pe-conv { display: none; } .pe-thread { min-height: 0; } }

/* ── Posteingang: Schlagworte, Werkzeugleiste, Anhänge ──── */
.pe-tags { display: flex; gap: var(--s1); flex-wrap: wrap; margin-top: 6px; align-items: center; }
.pe-tags .tag button { border: 0; background: none; padding: 0 0 0 2px; cursor: pointer; color: inherit; opacity: .5; font-size: 13px; line-height: 1; }
.pe-tags .tag button:hover, .pe-tags .tag button:focus-visible { opacity: 1; }
.pe-tag-neu input { border: 1px dashed var(--line-strong); border-radius: 99px; padding: 2px 10px; font-size: 11px; width: 110px; background: transparent; }
.pe-tag-neu input:focus { outline: 2px solid var(--ink); border-style: solid; background: var(--surface); }
.pe-werkzeug { display: flex; gap: var(--s2); align-items: center; padding: var(--s2) var(--s4); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.pe-werkzeug select { height: 28px; border: 1px solid var(--line-strong); border-radius: 99px; padding: 0 10px; font-size: 12px; font-weight: 600; background: var(--surface); max-width: 220px; }
.pe-werkzeug label.btn { cursor: pointer; }
.pe-verfeinern { flex: 1; min-width: 220px; display: flex; align-items: center; gap: var(--s2); padding: 0 4px 0 10px; height: 30px; border-radius: 99px;
  background: linear-gradient(90deg, rgba(220,253,111,.45), rgba(220,253,111,.12)); border: 1px solid var(--accent-deep); }
.pe-verfeinern input { flex: 1; min-width: 0; border: 0; background: transparent; font-size: 12.5px; outline: 0; }
.pe-verfeinern .btn { height: 24px; }
.pe-verfeinern.laeuft { opacity: .6; pointer-events: none; }
.pe-dateien { display: flex; gap: var(--s1); flex-wrap: wrap; padding: 0 var(--s4); }
.pe-dateien:not(:empty) { padding-top: var(--s2); }
.pe-dateien .tag button { border: 0; background: none; cursor: pointer; padding: 0 0 0 4px; }
.msg.us .anhaenge .tag { background: rgba(255,255,255,.1); color: #F2F3EE; border-color: rgba(255,255,255,.2); }
.pe-baustein { position: relative; }
.pe-baustein-pop { position: absolute; top: calc(100% + 6px); left: 0; width: 340px; max-height: min(300px, 45vh); display: flex; flex-direction: column; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-3); z-index: 20; overflow: hidden; }
.pe-baustein-pop input { border: 0; border-bottom: 1px solid var(--line); padding: 10px 12px; outline: 0; }
.pe-baustein-pop ul { list-style: none; margin: 0; padding: var(--s1); overflow: auto; }
.pe-baustein-pop li { padding: 7px 10px; border-radius: var(--radius-xs); cursor: pointer; font-size: 13px; }
.pe-baustein-pop li:hover, .pe-baustein-pop li.aktiv { background: var(--surface-2); }
.pe-baustein-pop li.aktiv { box-shadow: inset 2px 0 0 var(--ink); }
.pe-schnell { display: flex; gap: 4px; }
.pe-chip { border: 1px solid var(--accent-deep); background: rgba(255,255,255,.6); border-radius: 99px; padding: 1px 8px; font-size: 11px; font-weight: 600; cursor: pointer; }
.pe-chip:hover { background: #fff; } .pe-chip:focus-visible { outline: 2px solid var(--ink); }
.composer.ziehen { box-shadow: 0 0 0 3px var(--accent), var(--shadow-2); }
.lv-toast .rueck { margin-left: var(--s3); background: var(--accent); color: var(--ink); border: 0; border-radius: 99px; padding: 3px 10px; font-weight: 700; cursor: pointer; pointer-events: auto; }
.lv-toast.mit-knopf { pointer-events: auto; }
@media (max-width: 1280px) { .pe-schnell { display: none; } }
/* Werkzeugleiste: Marie-Zeile über volle Breite, Schnellknöpfe nie umbrechen */
.pe-verfeinern { flex: 1 1 100%; order: 3; }
.pe-chip { white-space: nowrap; }
@media (max-width: 1280px) { .pe-schnell { display: flex; } }
@media (max-width: 1100px) { .pe-schnell { display: none; } }
.pe-baustein-pop[hidden] { display: none; }
/* klappt nach unten über das Textfeld auf – der Antwortbereich schneidet nach oben ab */
.pe-baustein-pop { box-shadow: 0 1px 2px rgba(28,28,20,.06), 0 12px 32px -8px rgba(28,28,20,.2); max-width: calc(100vw - 32px); }
.pe-conv-actions #pe-zuweisen { height: 34px; border-radius: 99px; border: 1px solid var(--line-strong); background: var(--surface); padding: 0 12px; font-weight: 600; font-size: 13px; max-width: 170px; }
.marie-aktion { display: flex; align-items: center; gap: var(--s3); flex-wrap: wrap; margin-bottom: 6px; }
/* Gesprächskopf: Betreff oben, Bedienelemente darunter rechts – nichts verdrängt den Betreff */
.pe-conv-head { flex-wrap: wrap; row-gap: var(--s2); }
.pe-conv-head > div:first-of-type { flex: 1 1 100%; }
.pe-conv-actions { margin-left: 0; width: 100%; justify-content: flex-end; flex-wrap: wrap; }
.marie-aktion { justify-content: space-between; }
/* Gesprächskopf v3: Titel · Infozeile · (Schlagworte | Bedienung) */
.pe-conv-head { display: block; padding: var(--s3) var(--s5) var(--s2); }
.pe-conv-head .kopf-titel { display: flex; align-items: center; gap: var(--s2); min-width: 0; }
.pe-conv-head .kopf-titel h2 { flex: 0 1 auto; min-width: 0; }
.pe-conv-head .anwesend { flex: none; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--warn-bg); color: var(--warn-ink); border: 1px solid var(--warn-line); }
.kopf-zeile { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); margin-top: 6px; flex-wrap: wrap; }
.kopf-zeile .pe-tags { margin-top: 0; }
.kopf-zeile .pe-conv-actions { width: auto; margin-left: auto; gap: 6px; }
.kopf-feld { display: inline-flex; align-items: center; gap: 4px; height: 28px; padding: 0 4px 0 10px; border: 1px solid var(--line-strong); border-radius: 99px; background: var(--surface); font-size: 12px; color: var(--muted); }
.kopf-feld:focus-within { outline: 2px solid var(--ink); outline-offset: 1px; }
.kopf-feld select { border: 0; background: transparent; font-weight: 600; font-size: 12px; color: var(--ink); padding: 0 2px; outline: 0; max-width: 140px; height: 26px; }
.pe-conv-actions .kopf-feld select, .pe-conv-actions .kopf-feld #pe-zuweisen { height: 26px; border: 0; background: transparent; padding: 0 2px; max-width: 140px; box-shadow: none; border-radius: 0; }

/* Grundregel: [hidden] gewinnt immer (sonst überschreiben display-Regeln von .btn usw. das Attribut) */
[hidden] { display: none !important; }

/* ── Retouren (Team) ─────────────────────────────────────── */
.rt-bereich { display: grid; gap: var(--s3); }
.rt-karte { display: grid; gap: var(--s3); }
.rt-karte.rt-warn { border-left: 3px solid var(--warn-line); }
.rt-karte.rt-err { border-left: 3px solid var(--err-line); }
.rt-kopf { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--s3); }
.rt-titel { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.rt-titel b { font-size: 15px; letter-spacing: -.01em; }
.rt-betrag { text-align: right; font-weight: 800; font-size: 17px; letter-spacing: -.02em; line-height: 1.2; white-space: nowrap; }
.rt-betrag small { display: block; font-size: 11px; font-weight: 600; color: var(--faint); letter-spacing: .02em; text-transform: uppercase; }
.rt-bestellung { border-top: 1px solid var(--line); padding-top: var(--s2, 8px); font-size: 13px; }
.rt-bestellung > summary { cursor: pointer; font-weight: 600; list-style-position: inside; }
.rt-bestellung > summary a { font-weight: 500; }
.rt-fakten { display: grid; grid-template-columns: max-content 1fr; gap: 2px 12px; margin: 8px 0; }
.rt-fakten dt { color: var(--muted); } .rt-fakten dd { margin: 0; overflow-wrap: anywhere; }
.rt-positionen { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.rt-positionen li { display: grid; grid-template-columns: 40px 1fr auto; gap: 10px; align-items: center; }
.rt-positionen img, .rt-ohnebild { width: 40px; height: 40px; border-radius: 8px; object-fit: cover; background: var(--surface-2); border: 1px solid var(--line); }
.rt-pname { line-height: 1.35; overflow-wrap: anywhere; } .rt-pname .tag { margin-left: 4px; }
.rt-preis { text-align: right; white-space: nowrap; } .rt-preis s { font-size: 11px; }
.rt-summe { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.rt-stufen { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; font-size: 11px; }
.rt-stufen li { padding: 2px 7px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.rt-stufen li.fertig { color: inherit; background: var(--surface-2); }
.rt-stufen li.jetzt { color: #fff; background: var(--ink); border-color: var(--ink); font-weight: 600; }
.rt-artikel { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 13px; }
.rt-artikel li { display: grid; gap: 1px; line-height: 1.4; }
.rt-artikel li span:first-child { font-weight: 600; overflow-wrap: anywhere; }
.rt-artikel .muted { font-size: 12px; }
.rt-dialog .rt-artikel { padding: 10px 12px; border-radius: var(--radius-xs); background: var(--surface-2); border: 1px solid var(--line); margin-top: var(--s3); }
.rt-kommentar { margin: 0; font-size: 13px; color: var(--muted); font-style: italic; }
.rt-klein { margin: 0; font-size: 12px; }
.rt-fotos { display: flex; gap: 6px; flex-wrap: wrap; }
.rt-fotos a { width: 56px; height: 56px; border-radius: var(--radius-xs); overflow: hidden; border: 1px solid var(--line); display: grid; place-items: center;
  background: var(--surface-2); font-size: 11px; font-weight: 700; color: var(--muted); text-decoration: none; transition: transform .2s var(--spring); }
.rt-fotos a:hover { transform: scale(1.04); } .rt-fotos a:active { transform: scale(.98); }
.rt-fotos a:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.rt-fotos img { width: 100%; height: 100%; object-fit: cover; }
.rt-knoepfe { display: flex; flex-wrap: wrap; gap: var(--s2); align-items: center; }
.rt-nachweis { font-size: 12px; color: var(--muted); }
.rt-nachweis summary { cursor: pointer; font-weight: 600; }
.rt-nachweis p { margin: 6px 0 0; line-height: 1.5; }
.rt-link-knopf { justify-self: start; }
.rt-dialog .rt-haken { display: grid; gap: 8px; margin: var(--s3) 0; }
.rt-dialog .rt-haken label { display: flex; gap: 10px; align-items: center; font-size: 14px; cursor: pointer; }
.rt-dialog .rt-haken input { width: 18px; height: 18px; accent-color: var(--ink); }
.rt-feld { display: grid; gap: 4px; font-size: 13px; font-weight: 600; margin-top: var(--s2); }
.rt-feld input, .rt-feld textarea { font: inherit; font-weight: 400; font-size: 14px; padding: 8px 10px; border: 1px solid var(--line-strong); border-radius: var(--radius-xs); background: var(--surface); }
.rt-feld input:focus, .rt-feld textarea:focus { outline: 2px solid var(--ink); outline-offset: 0; }
.rt-abzug { margin-top: var(--s3); font-size: 13px; } .rt-abzug summary { cursor: pointer; font-weight: 600; }
.rt-dialog-fehler { margin: var(--s3) 0 0; padding: 8px 12px; border-radius: var(--radius-xs); background: var(--err-bg); color: var(--err); font-size: 13px; font-weight: 600; }
.rt-seite-kopf { display: grid; grid-template-columns: 1fr minmax(320px, 440px); gap: var(--s5); align-items: end; }
@media (max-width: 860px) { .rt-seite-kopf { grid-template-columns: 1fr; } }
.rt-scan { display: grid; gap: var(--s2); }
.rt-scan label { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.rt-scan-zeile { display: flex; gap: var(--s2); }
.rt-scan-zeile input { flex: 1; min-width: 0; height: 40px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 99px; font: inherit; background: var(--surface-2); }
.rt-scan-zeile input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(220,253,111,.6); background: var(--surface); }
.rt-scan-log { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 13px; max-height: 120px; overflow: auto; }
.rt-scan-log li.ok { color: var(--ok); } .rt-scan-log li.err { color: var(--err); }
.rt-tabs { display: flex; gap: 2px; padding: 3px; background: rgba(28,28,28,.05); border-radius: 99px; width: max-content; max-width: 100%; overflow-x: auto; margin: var(--s5) 0 var(--s4); }
.rt-tabs a { text-decoration: none; padding: 6px 14px; border-radius: 99px; font-size: 13px; font-weight: 600; color: var(--muted); display: flex; gap: 6px; align-items: center; white-space: nowrap; }
.rt-tabs a:hover { color: var(--ink); } .rt-tabs a:active { transform: scale(.98); }
.rt-tabs a:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.rt-tabs a.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-1); }
.rt-tabs a span { font-size: 11px; padding: 0 6px; border-radius: 99px; background: var(--ink); color: var(--accent); }
.rt-raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: var(--s3); align-items: start; }
.rt-leer { display: grid; justify-items: center; gap: 6px; padding: var(--s6); color: var(--muted); grid-column: 1 / -1; text-align: center; }
.rt-leer i { font-size: 26px; color: var(--ok); } .rt-leer b { color: var(--ink); }

/* ── Beanstandungen ─────────────────────────────────────── */
.bs-karte { display: grid; gap: var(--s3); border-left: 3px solid var(--line-strong); }
.bs-karte.bs-dringend { border-left-color: var(--err-line); }
.bs-kv { margin: 0; }
.bs-nachweis summary { cursor: pointer; font-size: 13px; font-weight: 700; display: flex; gap: 6px; align-items: center; list-style: none; }
.bs-nachweis summary::-webkit-details-marker { display: none; }
.bs-nachweis summary:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; border-radius: 6px; }
.bs-nachweis pre { white-space: pre-wrap; font: 12.5px/1.55 Inter, ui-sans-serif, system-ui, sans-serif; margin: var(--s2) 0; padding: 10px 12px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-xs); max-height: 260px; overflow: auto; }
.bs-stand { display: flex; flex-wrap: wrap; gap: var(--s2); align-items: center; }

/* ── Lesebereich: neueste Nachricht im Blick, Antwortfeld klappt ein ────── */
.msg-meta { appearance: none; border: 0; background: none; padding: 0; margin: 0 0 6px; font: inherit; font-size: 12px; color: var(--muted); text-align: left;
  display: flex; align-items: center; gap: 6px; width: 100%; cursor: pointer; min-width: 0; }
.msg-meta:hover b { text-decoration: underline; text-underline-offset: 2px; }
.msg-meta:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; border-radius: 6px; }
.msg-meta .tag { font-size: 11px; }
.msg-vorschau { display: none; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--faint); }
.msg.zu .msg-vorschau { display: block; }
.msg.zu .bubble, .msg.zu .anhaenge { display: none; }
.msg.zu .msg-meta { padding: 8px 12px; margin: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.msg.us.zu .msg-meta { background: var(--surface-2); }
.msg.neueste .bubble { border-color: #A9CC34; box-shadow: 0 0 0 3px rgba(220,253,111,.5), var(--shadow-1); }
.pe-alle { align-self: center; appearance: none; border: 1px dashed var(--line-strong); background: transparent; border-radius: 99px; padding: 6px 14px;
  font: inherit; font-size: 12.5px; font-weight: 600; color: var(--muted); cursor: pointer; display: inline-flex; gap: 6px; align-items: center;
  transition: transform .2s var(--spring); }
.pe-alle:hover { color: var(--ink); transform: translateY(-1px); } .pe-alle:active { transform: scale(.98); }
.pe-alle:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.composer-tabs { align-items: center; }
.composer-entwurf { font-size: 11.5px; font-weight: 700; color: var(--ok); background: var(--ok-bg); border-radius: 99px; padding: 2px 8px; margin-left: var(--s2); }
.composer-klappe { margin-left: auto; appearance: none; border: 0; background: none; width: 32px; height: 32px; border-radius: 8px; cursor: pointer; color: var(--muted);
  display: grid; place-items: center; transition: transform .25s var(--spring); }
.composer-klappe:hover { color: var(--ink); background: var(--surface-2); }
.composer-klappe:active { transform: scale(.94); }
.composer-klappe:focus-visible { outline: 2px solid var(--ink); }
.composer.offen .composer-klappe i { transform: rotate(180deg); display: inline-block; }
.composer:not(.offen) .pe-werkzeug, .composer:not(.offen) .pe-dateien, .composer:not(.offen) .marie-strip ul { display: none; }
.composer:not(.offen) .marie-strip { padding-top: 6px; padding-bottom: 6px; }
.composer:not(.offen) textarea { min-height: 0; max-height: 76px; height: 76px; overflow: hidden; color: var(--muted); cursor: text;
  -webkit-mask-image: linear-gradient(#000 55%, transparent); mask-image: linear-gradient(#000 55%, transparent); }
.composer.offen textarea { min-height: 180px; max-height: 52vh; height: 34vh; }

/* ── Seitenleiste ──────────────────────────────────────────
   Panel 232 px breit, zugeklappt um 176 px nach links geschoben; der Inhalt wird gegengeschoben, damit die Symbole
   stehen bleiben und nur die Beschriftung „herausfährt“ (nur transform/opacity). */
:root { --rail: 56px; }
body.lv { padding-left: var(--rail); }
.lv-rail { position: fixed; left: 0; top: var(--top-h); bottom: 0; width: var(--rail); z-index: 25; }
.lv-rail-panel { position: absolute; top: 0; bottom: 0; left: 0; width: 232px; overflow: hidden; background: var(--surface);
  border-right: 1px solid var(--line); transform: translateX(-176px); transition: transform .28s var(--spring), box-shadow .2s; }
.lv-rail-innen { width: 232px; height: 100%; overflow-y: auto; padding: var(--s3) var(--s2); display: flex; flex-direction: column; gap: 2px;
  transform: translateX(176px); transition: transform .28s var(--spring); }
.lv-rail:hover .lv-rail-panel, .lv-rail:focus-within .lv-rail-panel { transform: none; box-shadow: var(--shadow-3); }
.lv-rail:hover .lv-rail-innen, .lv-rail:focus-within .lv-rail-innen { transform: none; }
.lv-rail a { display: flex; align-items: center; gap: 14px; height: 40px; padding: 0 12px; border-radius: 10px; text-decoration: none;
  color: var(--muted); font-weight: 600; font-size: 13.5px; white-space: nowrap; transition: background-color .15s, color .15s; }
.lv-rail a i { font-size: 17px; width: 16px; text-align: center; flex: none; }
.lv-rail a span { opacity: 0; transition: opacity .18s; }
.lv-rail:hover a span, .lv-rail:focus-within a span { opacity: 1; }
.lv-rail a:hover { color: var(--ink); background: var(--surface-2); }
.lv-rail a:active { transform: scale(.98); }
.lv-rail a:focus-visible { outline: 2px solid var(--ink); outline-offset: -2px; }
.lv-rail a.on { color: var(--ink); background: var(--accent); }
.lv-rail hr { border: 0; border-top: 1px solid var(--line); margin: var(--s2) 6px; }
@media (max-width: 720px) { body.lv { padding-left: 0; } .lv-rail { display: none; } }
@media print { body.lv { padding-left: 0; } .lv-rail { display: none; } }
.msg.zu { align-self: stretch; max-width: none; width: 100%; }

/* Bestellkarte: Produktbild und Versandstand */
.thumb.mit-bild { padding: 0; overflow: hidden; background: #fff; }
.thumb.mit-bild img { width: 100%; height: 100%; object-fit: cover; display: block; }
.track .t { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.track .quelle { font-size: 11px; font-weight: 600; color: var(--faint); text-transform: uppercase; letter-spacing: .04em; }
.track .stufen { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; font-size: 10.5px; color: var(--faint); margin-top: 4px; }
.track.stoerung .steps span.done { background: var(--err); }

/* Neuversand-Dialog */
.nv-dialog { width: min(560px, 94vw); }
dialog.nv-dialog.lv-dialog--seite { width: min(480px, calc(100vw - 32px)); }
.nv-form h5 { margin: var(--s4) 0 var(--s2); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.nv-ziel { font-size: 13px; }
.nv-liste { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; max-height: 220px; overflow: auto; }
.nv-liste li { display: flex; align-items: center; gap: var(--s2); }
.nv-wahl { flex: 1; display: flex; align-items: center; gap: 10px; padding: 6px 8px; border: 1px solid var(--line); border-radius: var(--radius-xs); cursor: pointer; min-width: 0; }
.nv-wahl:has(input:checked) { border-color: var(--ink); background: var(--surface-2); }
.nv-wahl input { width: 16px; height: 16px; accent-color: var(--ink); flex: none; }
.nv-wahl img, .nv-ph { width: 34px; height: 34px; border-radius: 7px; object-fit: cover; background: var(--surface-2); flex: none; }
.nv-name { display: grid; font-size: 13.5px; min-width: 0; } .nv-name small { color: var(--muted); font-size: 12px; }
.nv-menge { width: 56px; padding: 6px; border: 1px solid var(--line-strong); border-radius: var(--radius-xs); font: inherit; }
#nv-suche { width: 100%; padding: 8px 10px; border: 1px solid var(--line-strong); border-radius: var(--radius-xs); font: inherit; margin-bottom: 6px; }
.nv-feld { display: grid; gap: 4px; font-size: 13px; font-weight: 600; margin-top: var(--s3); }
.nv-feld small { font-weight: 500; color: var(--muted); }
.nv-feld textarea { padding: 8px 10px; border: 1px solid var(--line-strong); border-radius: var(--radius-xs); font: inherit; font-weight: 400; }
.nv-fehler { margin: var(--s2) 0 0; padding: 8px 12px; border-radius: var(--radius-xs); background: var(--err-bg); color: var(--err); font-size: 13px; font-weight: 600; }

/* Neue Nachricht */
.pe-list-head { position: relative; }
.pe-neu-knopf { position: absolute; top: var(--s4); right: var(--s4); }
.pe-neu-knopf:active { transform: scale(.97); }
dialog.nn-dialog.lv-dialog--seite { width: min(520px, calc(100vw - 32px)); }
.nn-treffer { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; max-height: 220px; overflow: auto; }
.nn-treffer button { width: 100%; text-align: left; border: 1px solid var(--line); background: var(--surface-2); border-radius: var(--radius-xs);
  padding: 8px 10px; display: grid; gap: 2px; cursor: pointer; transition: transform .15s cubic-bezier(.34,1.56,.64,1), background-color .15s; }
.nn-treffer button:hover { background: var(--surface); border-color: var(--line-strong); }
.nn-treffer button:focus-visible { outline: 2px solid var(--ink); outline-offset: 1px; }
.nn-treffer button:active { transform: scale(.99); }
.nn-treffer b { font-size: 13.5px; } .nn-treffer small { color: var(--muted); font-size: 12px; }
.nn-quelle { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.nn-quelle span { font-size: 10.5px; font-weight: 700; letter-spacing: .02em; padding: 1px 6px; border-radius: 99px; background: var(--bg); color: var(--muted); }
.nn-gewaehlt { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); padding: 8px 10px; border-radius: var(--radius-xs);
  background: var(--surface-2); border: 1px solid var(--line); font-size: 13px; }
.nn-modus { display: flex; gap: var(--s2); flex-wrap: wrap; }
.nn-modus label { display: flex; align-items: center; gap: 6px; font-weight: 500; }
.nn-modus input { width: auto; }
.lv-dialog select { border: 1px solid var(--line-strong); border-radius: var(--radius-xs); padding: 8px 10px; font-weight: 400; background: var(--surface); }
.lv-dialog textarea { resize: vertical; line-height: 1.6; font-family: inherit; font-size: 14px; font-weight: 400; }
.lv-dialog input[type=radio], .lv-dialog input[type=checkbox] { accent-color: var(--ink); }
.nn-treffer:empty { display: none; }
.nn-fehler { margin: 0; padding: 8px 12px; border-radius: var(--radius-xs); background: var(--err-bg); color: var(--err); font-size: 13px; font-weight: 600; }

/* Bestellung finden (Tickets ohne Bestellung) */
.bs-info { font-size: 12.5px; margin: 0 0 var(--s2); }
.bs-liste { list-style: none; margin: 0 0 var(--s2); padding: 0; display: grid; gap: 6px; }
.bs-liste:empty { display: none; }
.bs-liste li { border: 1px solid var(--line); border-radius: var(--radius-xs); padding: 8px 10px; background: var(--surface-2); display: grid; gap: 4px; }
.bs-kopf { display: flex; justify-content: space-between; gap: var(--s2); align-items: baseline; }
.bs-kopf b { font-size: 13.5px; }
.bs-liste small { color: var(--muted); font-size: 12px; line-height: 1.45; }
.bs-passt { color: var(--ok, #2F6B1F); font-weight: 600; }
.bs-abweichung { color: var(--warn-ink, #7A5200); font-weight: 600; }
.bs-suche input { width: 100%; box-sizing: border-box; border: 1px solid var(--line-strong); border-radius: var(--radius-xs); padding: 7px 10px; font: inherit; font-size: 13px; }
.bs-suche input:focus-visible { outline: 2px solid var(--ink); outline-offset: 0; }
.bs-liste .btn { justify-self: start; }

.nn-anhaenge { display: flex; align-items: center; gap: var(--s2); flex-wrap: wrap; }
.nn-datei-knopf { cursor: pointer; }
.nn-datei-knopf:focus-within { outline: 2px solid var(--ink); outline-offset: 1px; }
.nn-dateien { display: flex; gap: 4px; flex-wrap: wrap; }
.nn-dateien .tag button { border: 0; background: none; cursor: pointer; padding: 0 0 0 4px; }

.bs-zeit { margin: 0; font-size: 13px; display: flex; flex-wrap: wrap; gap: 2px 6px; align-items: baseline; }
.bs-zeit-knapp { color: var(--warn-ink, #7A5200); }
.bs-quelle { flex-basis: 100%; color: var(--faint); font-size: 11.5px; }

/* Umtausch */
dialog.ut-dialog.lv-dialog--seite { width: min(560px, calc(100vw - 32px)); }
.ut-block { border: 1px solid var(--line); border-radius: var(--radius-xs); padding: var(--s2) var(--s3) var(--s3); margin: 0; display: grid; gap: 6px; min-width: 0; }
.ut-block legend { font-size: 13px; font-weight: 700; padding: 0 4px; }
.ut-zeile { display: grid !important; grid-template-columns: auto 36px minmax(0,1fr) 64px; align-items: center; gap: var(--s2); font-weight: 500 !important; }
.ut-zeile img, .ut-zeile .nv-ph { width: 36px; height: 36px; border-radius: 8px; object-fit: cover; background: var(--surface-2); }
.ut-zeile small, .ut-neu small { display: block; font-weight: 400; }
.ut-zeile input[type=checkbox] { width: auto; accent-color: var(--ink); }
.ut-neu { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.ut-neu:empty { display: none; }
.ut-neu li { display: grid; grid-template-columns: minmax(0,1fr) 64px auto; gap: var(--s2); align-items: center; font-size: 13px; }
.ut-rechnung { margin: 4px 0 0; }
/* Umtausch: Art wählen (Wunsch / Defekt / schon vereinbart) */
.ut-arten { display: grid; gap: 6px; }
.ut-art { display: grid !important; grid-template-columns: auto minmax(0,1fr); column-gap: var(--s2); align-items: start; padding: 8px 10px;
  border: 1px solid var(--line); border-radius: var(--radius-xs); background: var(--surface); cursor: pointer; font-weight: 500 !important; }
.ut-art input { width: auto; margin-top: 3px; accent-color: var(--ink); grid-row: span 2; }
.ut-art small { color: var(--muted); font-weight: 400; line-height: 1.45; }
.ut-art.an { border-color: var(--ink); box-shadow: 0 0 0 2px rgba(220,253,111,.7); }
.ut-art:hover { border-color: var(--line-strong); }
.ut-art:focus-within { outline: 2px solid var(--ink); outline-offset: 2px; }
.ut-basis { display: grid !important; gap: 4px; border: 1px solid var(--line); border-radius: var(--radius-xs); padding: 8px 10px; font-weight: 500 !important; }
.ut-basis input { width: auto; }
.btn-link { border: 0; background: none; padding: 0; color: inherit; text-decoration: underline; cursor: pointer; font: inherit; }
.btn-link:focus-visible { outline: 2px solid var(--ink); }

.track-partner { margin-top: 6px; font-size: 12px; color: var(--muted); line-height: 1.5; }
.track-partner a { color: var(--ink); font-weight: 600; }
.track-partner a:focus-visible { outline: 2px solid var(--ink); outline-offset: 1px; }
.track-partner.wichtig { color: var(--warn-ink, #7A5200); }

/* Flüssige Seitenwechsel (Chrome/Edge): kein Weißblitz, Leiste, Ansichten und Ticketliste bleiben stehen, Inhalt blendet kurz über */
@view-transition { navigation: auto; }
.lv-top { view-transition-name: lv-kopf; }
.lv-rail { view-transition-name: lv-leiste; }
.pe-views { view-transition-name: pe-ansichten; }
.pe-list { view-transition-name: pe-liste; }
::view-transition-group(*) { animation-duration: 0s; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 120ms; animation-timing-function: cubic-bezier(.2,.8,.2,1); }
::view-transition-old(pe-liste), ::view-transition-new(pe-liste),
::view-transition-old(lv-leiste), ::view-transition-new(lv-leiste),
::view-transition-old(lv-kopf), ::view-transition-new(lv-kopf),
::view-transition-old(pe-ansichten), ::view-transition-new(pe-ansichten) { animation: none; }
::view-transition-old(pe-liste), ::view-transition-old(lv-leiste), ::view-transition-old(lv-kopf), ::view-transition-old(pe-ansichten) { display: none; }
@media (prefers-reduced-motion: reduce) { ::view-transition-old(root), ::view-transition-new(root) { animation: none; } }

/* Bewertungen (Modul bewertungen) */
.bw-raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: var(--s3); align-items: start; }
.bw-karte { display: grid; gap: 10px; }
.bw-karte.bw-kritisch { border-left: 3px solid var(--warn-line); }
.bw-kopf { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.bw-sterne { color: var(--ink); font-size: 15px; letter-spacing: 1px; }
.bw-titel { margin: 0; font-size: 15px; }
.bw-text { margin: 0; white-space: pre-line; line-height: 1.55; }
.bw-meta { margin: 0; }
.bw-grund { font: inherit; font-size: 13px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); max-width: 220px; }
.bw-video { display: inline-flex; gap: 6px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; }
.bw-stand { display: grid; gap: 6px; align-content: start; }
.bw-tabelle { width: 100%; border-collapse: collapse; font-size: 13px; }
.bw-tabelle th, .bw-tabelle td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.bw-faellig { display: grid; gap: 12px; margin-bottom: var(--s3); }
.bw-faellig-kopf { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
.bw-schalter { display: inline-flex; gap: 8px; align-items: center; font-size: 14px; font-weight: 600; cursor: pointer; }
.bw-schalter input { width: 18px; height: 18px; accent-color: var(--ink); }
/* Interne Notizen strukturiert (25.11.2026): Überschrift, Feld-Wert-Liste, Abschnitte */
.nz { display: grid; gap: 4px; line-height: 1.5; }
.nz-titel { font-weight: 700; font-size: 14.5px; margin-bottom: 4px; }
.nz-zeile { display: grid; grid-template-columns: minmax(110px, max-content) 1fr; gap: var(--s3); font-size: 14px; }
.nz-k { color: var(--muted); font-weight: 600; }
.nz-text { font-size: 14px; }
.nz-abstand { height: 6px; }
@media (max-width: 600px) { .nz-zeile { grid-template-columns: 1fr; gap: 0; } }
