:root {
  --bg: #f4f5f9;
  --surface: #ffffff;
  --surface-2: #f8f9fc;
  --text: #0f172a;
  --text-2: #334155;
  --muted: #64748b;
  --faint: #94a3b8;
  --line: #e3e7ef;
  --line-strong: #cfd6e3;
  --accent: #4f46e5;
  --accent-hover: #4338ca;
  --accent-soft: #eef0ff;
  --accent-ring: rgba(79, 70, 229, .16);
  --ok: #047857;
  --ok-soft: #e7f6ef;
  --warn: #b45309;
  --warn-soft: #fdf3e2;
  --err: #b91c1c;
  --err-soft: #fdecec;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px -12px rgba(15, 23, 42, .12);
  --shadow-lg: 0 24px 48px -16px rgba(15, 23, 42, .25);
  --font: "Inter", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", "Cascadia Mono", "SF Mono", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html, body { overflow-x: hidden; overflow-x: clip; max-width: 100%; }   /* clip statt hidden: sonst bleibt die Kopfzeile beim Scrollen nicht stehen */
body {
  margin: 0; background: var(--bg); color: var(--text); font: 15px/1.5 var(--font);
  -webkit-font-smoothing: antialiased; touch-action: pan-y; min-height: 100vh;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 28px; }
main.container { flex: 1; padding-top: 32px; padding-bottom: 32px; outline: none; }

/* ---------- Rahmen: Seitenleiste am Rechner, Kopfzeile am Handy ---------- */
:root { --leiste: 244px; --kopf: 0px; }
body { display: grid; grid-template-columns: var(--leiste) minmax(0, 1fr); align-items: start; }
.haupt { min-width: 0; min-height: 100vh; display: flex; flex-direction: column; }
.shell { position: sticky; top: 0; height: 100vh; z-index: 30; display: flex; flex-direction: column;
  background: var(--surface); border-right: 1px solid var(--line); }
.shell-kopf { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 20px 16px 16px 18px; }
.brand { white-space: nowrap; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; display: flex; align-items: center; gap: 11px; color: var(--text); min-width: 0; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; background: var(--accent); color: #fff; flex: none;
  display: grid; place-items: center; box-shadow: 0 4px 10px -4px rgba(79,70,229,.6); }
.brand-text { display: grid; line-height: 1.2; min-width: 0; }
.brand-text b { font-size: 17px; font-weight: 800; letter-spacing: -.02em; }
.brand-text small { font-size: 11.5px; color: var(--muted); font-weight: 500; overflow: hidden; text-overflow: ellipsis; }
.shell .menu-btn { display: none; }
.shell-panel { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 16px; padding: 2px 12px 14px; }

.sb-sprung { display: flex; align-items: center; gap: 8px; width: 100%; height: 38px; padding: 0 7px 0 11px; flex: none;
  border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface-2); color: var(--muted);
  font-size: 13.5px; cursor: pointer; text-align: left; transition: border-color .12s, color .12s; }
.sb-sprung span:nth-child(2) { flex: 1; }
.sb-sprung:hover { border-color: #b9c2d3; color: var(--text-2); }
.sb-sprung:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--accent-ring); }
.sb-nav { display: grid; gap: 16px; }
.sb-gruppe { display: grid; gap: 1px; }
.sb-titel { font-size: 12px; font-weight: 600; color: var(--faint); padding: 0 10px 5px; }
.sb-link { display: flex; align-items: center; gap: 11px; padding: 8px 10px; border-radius: 9px; color: var(--text-2); font-weight: 500; font-size: 14.5px; }
.sb-link svg { color: var(--faint); flex: none; }
.sb-link:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }
.sb-link:hover svg { color: var(--text-2); }
.sb-link.active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.sb-link.active svg { color: var(--accent); }
.sb-link:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--accent-ring); }

/* Heute: frühester Lieferbeginn und Einzug, immer sichtbar */
.sb-heute { margin-top: auto; flex: none; display: grid; gap: 2px; padding: 4px; border-radius: 13px;
  background: var(--accent-soft); border: 1px solid #d8dcff; }
.sb-heute:empty { display: none; }
.sb-heute-kopf { display: flex; justify-content: space-between; align-items: baseline; padding: 7px 9px 3px; font-size: 12.5px; font-weight: 700; color: var(--accent); }
.sb-heute-kopf span + span { font-weight: 500; color: var(--text-2); font-variant-numeric: tabular-nums; }
.sb-heute-kopf:hover { text-decoration: none; }
.sb-heute-kopf:hover span:first-child { text-decoration: underline; }
.sb-datum { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "k c" "v c"; align-items: center; column-gap: 8px;
  width: 100%; padding: 7px 9px; border: 0; border-radius: 9px; background: transparent; text-align: left; cursor: pointer; }
.sb-datum .k { grid-area: k; font-size: 12px; color: var(--text-2); }
.sb-datum .v { grid-area: v; font-size: 15.5px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; letter-spacing: -.01em; white-space: nowrap; }
.sb-datum .c { grid-area: c; color: var(--accent); opacity: 0; transition: opacity .12s; display: grid; }
.sb-datum:hover { background: #fff; }
.sb-datum:hover .c, .sb-datum:focus-visible .c, .sb-datum.done .c { opacity: 1; }
.sb-datum.done .c { color: var(--ok); }
.sb-datum:focus-visible { outline: none; background: #fff; box-shadow: 0 0 0 3px var(--accent-ring); }

.sb-user { display: flex; align-items: center; gap: 9px; padding: 12px 2px 0 6px; border-top: 1px solid var(--line); flex: none; }
.sb-avatar { width: 28px; height: 28px; border-radius: 50%; background: var(--text); color: #fff; display: grid; place-items: center; font-size: 12.5px; font-weight: 700; flex: none; }
.sb-name { flex: 1; min-width: 0; font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.btn.sb-raus { padding: 0 8px; gap: 6px; color: var(--muted); font-weight: 500; }
.btn.sb-raus:hover { color: var(--text); }

/* Schmaler Scrollbalken, nur beim Darüberfahren sichtbar */
.shell-panel { scrollbar-width: thin; scrollbar-color: transparent transparent; }
.shell-panel:hover, .shell-panel:focus-within { scrollbar-color: var(--line-strong) transparent; }
.shell-panel::-webkit-scrollbar { width: 6px; }
.shell-panel::-webkit-scrollbar-thumb { background: transparent; border-radius: 6px; }
.shell-panel:hover::-webkit-scrollbar-thumb { background: var(--line-strong); }
.sb-schiene { display: none; }
button.sb-link { border: 0; background: transparent; width: 100%; cursor: pointer; font: inherit; text-align: left; }
.sb-fenster { position: fixed; z-index: 55; width: 236px; }
.sb-fenster .sb-heute { margin: 0; box-shadow: var(--shadow-lg); }

/* Einklapp-Knopf */
.shell .leiste-btn { width: 32px; height: 32px; padding: 0; flex: none; color: var(--faint); border-radius: 8px; }
.shell .leiste-btn:hover { color: var(--text-2); }
body { transition: grid-template-columns .18s ease; }
@media (prefers-reduced-motion: reduce) { body { transition: none; } }

/* Niedrige Fenster: Leiste enger, damit nichts scrollen muss */
@media (min-width: 1100px) and (max-height: 860px) {
  .shell-kopf { padding-top: 14px; padding-bottom: 12px; }
  .shell-panel { gap: 12px; }
  .sb-nav { gap: 10px; }
  .sb-link { padding: 6px 10px; }
  .sb-titel { padding-bottom: 3px; }
  .sb-heute-kopf { padding-top: 5px; }
  .sb-datum { padding: 5px 9px; }
  .sb-datum .v { font-size: 14.5px; }
  .sb-user { padding-top: 10px; }
}

/* Eingeklappt: nur Symbole */
@media (min-width: 1100px) {
  body.leiste-zu { --leiste: 68px; }
  body.leiste-zu .shell-kopf { flex-direction: column; justify-content: flex-start; gap: 10px; padding: 18px 0 12px; }
  body.leiste-zu .brand { gap: 0; }
  body.leiste-zu .brand-text { display: none; }
  body.leiste-zu .shell-panel { padding: 2px 10px 14px; gap: 12px; }
  body.leiste-zu .sb-sprung { justify-content: center; padding: 0; }
  body.leiste-zu .sb-sprung span { display: none; }
  body.leiste-zu .sb-titel { display: none; }
  body.leiste-zu .sb-nav { gap: 8px; }
  body.leiste-zu .sb-gruppe + .sb-gruppe { border-top: 1px solid var(--line); padding-top: 8px; }
  body.leiste-zu .sb-link { justify-content: center; padding: 9px 0; }
  body.leiste-zu .sb-link span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  body.leiste-zu .sb-link svg { color: var(--text-2); }
  body.leiste-zu .sb-link.active svg { color: var(--accent); }
  /* unten: nur zwei Symbole – „Heute“ öffnet ein Fenster daneben, darunter Abmelden */
  body.leiste-zu .shell .sb-heute, body.leiste-zu .sb-user { display: none; }
  body.leiste-zu .sb-schiene { display: grid; gap: 2px; margin-top: auto; padding-top: 8px; border-top: 1px solid var(--line); }
  body.leiste-zu .sb-schiene [aria-expanded="true"] { background: var(--accent-soft); }
  body.leiste-zu .sb-schiene [aria-expanded="true"] svg { color: var(--accent); }
}
@media (min-width: 1100px) and (max-height: 760px) {
  body.leiste-zu .sb-link { padding: 7px 0; }
  body.leiste-zu .shell-kopf { padding: 12px 0 10px; gap: 8px; }
}
@media (max-width: 1099px) { .sb-fenster { display: none !important; } }
@media (max-width: 1099px) { .shell .leiste-btn { display: none; } }

/* ---------- Schnellsprung (Strg+K) ---------- */
.sprung { position: fixed; inset: 0; z-index: 60; background: rgba(15, 23, 42, .36); display: flex; justify-content: center; align-items: flex-start; padding: 12vh 16px 16px; }
.sprung-karte { width: min(620px, 100%); max-height: 72vh; display: flex; flex-direction: column; overflow: hidden;
  background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg); }
.sprung-feld { display: flex; align-items: center; gap: 10px; padding: 0 14px 0 18px; border-bottom: 1px solid var(--line); color: var(--muted); }
.sprung-input { flex: 1; min-width: 0; height: 58px; border: 0; outline: none; background: transparent; font-size: 17px; color: var(--text); }
.sprung-input::placeholder { color: var(--faint); }
.sprung-liste { overflow-y: auto; padding: 6px; }
.sprung-opt { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 10px; cursor: pointer; }
.sprung-opt .i { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; flex: none;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--text-2); }
.sprung-opt .t { flex: 1; min-width: 0; display: grid; }
.sprung-opt b { font-size: 14.5px; font-weight: 600; }
.sprung-opt small { font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sprung-opt.on { background: var(--accent-soft); }
.sprung-opt.on .i { background: #fff; border-color: #d8dcff; color: var(--accent); }
.sprung-leer { padding: 24px 14px; text-align: center; color: var(--muted); font-size: 14px; }
.sprung-fuss { display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 10px 18px; border-top: 1px solid var(--line); background: var(--surface-2); color: var(--muted); font-size: 12px; }

/* ---------- Lieferbeginn ---------- */
.lb-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; align-items: start; }
.lb-grid.eins { grid-template-columns: minmax(0, 620px); }
/* Rückfrage Heiligabend/Silvester */
.ha-frage { display: flex; align-items: center; justify-content: space-between; gap: 10px 14px; flex-wrap: wrap; margin-top: 12px;
  padding: 11px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); font-size: 13.5px; color: var(--text-2); line-height: 1.45; }
.ha-frage.offen { background: var(--warn-soft); border-color: #f3dcb4; }
.ha-frage .ha-text { flex: 1 1 260px; min-width: 0; }
.ha-frage .ha-hinweis { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.ha-frage.offen .ha-hinweis { color: var(--warn); }
.ha-frage .seg { box-shadow: none; flex: none; }
.sb-ha { display: block; margin: 2px 9px 4px; font-size: 12px; font-weight: 600; color: var(--warn); }
.lb-spalte { display: grid; gap: 22px; align-content: start; min-width: 0; }
.lb-grid .notice, .lb-grid .form-ok { font-size: 14px; line-height: 1.55; }

/* ---------- Knöpfe ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px;
  padding: 0 16px; border-radius: var(--radius-sm); border: 1px solid var(--line-strong); background: var(--surface);
  color: var(--text); font-weight: 600; font-size: 14px; cursor: pointer; white-space: nowrap;
  transition: background .12s, border-color .12s, box-shadow .12s, color .12s; }
.btn:hover { background: var(--surface-2); border-color: #b9c2d3; text-decoration: none; }
.btn:focus-visible, .seg button:focus-visible, .copy:focus-visible, .toggle:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--accent-ring); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.danger { color: var(--err); }
.btn.danger:hover { background: var(--err-soft); border-color: #f1b8b8; }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn.block { width: 100%; }
.btn svg { flex: none; }

/* ---------- Überschriften ---------- */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
h1 { font-size: 34px; line-height: 1.1; letter-spacing: -.025em; margin: 0 0 6px; font-weight: 800; }
.lead { color: var(--muted); margin: 0; font-size: 15.5px; }
h2 { font-size: 17px; margin: 0; letter-spacing: -.01em; font-weight: 700; }
h3 { font-size: 14px; margin: 0; font-weight: 700; }
.kbd { display: inline-block; font: 600 11px/1 var(--mono); border: 1px solid var(--line-strong);
  border-bottom-width: 2px; border-radius: 5px; padding: 3px 5px; color: var(--text-2); background: #fff; vertical-align: 1px; }

/* ---------- Karten ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 18px 22px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.card-head .sub { color: var(--muted); font-size: 13px; margin-top: 2px; }
.card-body { padding: 22px; }
.stack { display: grid; gap: 20px; }

/* ---------- Segmentschalter ---------- */
.seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 4px; gap: 2px; box-shadow: var(--shadow); }
.seg button { border: 0; background: transparent; padding: 8px 18px; border-radius: 999px; font-weight: 700;
  color: var(--text-2); cursor: pointer; font-size: 14px; display: inline-flex; gap: 6px; align-items: center; }
.seg button.on { background: var(--accent); color: #fff; box-shadow: 0 4px 12px -4px rgba(79,70,229,.55); }

/* ---------- Formulare ---------- */
.field { display: grid; gap: 7px; position: relative; }
.field + .field { margin-top: 16px; }
.label { font-size: 12px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--text-2); display: flex; justify-content: space-between; gap: 8px; }
.label .hint { text-transform: none; letter-spacing: 0; font-weight: 500; color: var(--faint); }
.input, select.input { width: 100%; height: 48px; border: 1px solid var(--line-strong); border-radius: 12px;
  background: var(--surface-2); padding: 0 14px; font-size: 16px; outline: none;
  transition: border-color .12s, box-shadow .12s, background .12s; }
.input:hover { border-color: #b9c2d3; }
.input:focus { border-color: var(--accent); background: #fff; box-shadow: 0 0 0 4px var(--accent-ring); }
.input:disabled { opacity: .6; cursor: not-allowed; }
.input::placeholder { color: var(--faint); }
.input.lg { height: 54px; font-size: 18px; font-weight: 500; }
select.input { appearance: none; padding-right: 38px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' stroke='%2364748b' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; }
.row { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
.row.nr { grid-template-columns: 1fr 120px; }
.row .field + .field { margin-top: 0; }
.form-error { color: var(--err); background: var(--err-soft); border: 1px solid #f4c7c7; border-radius: 10px; padding: 10px 12px; font-size: 14px; }
.form-ok { color: var(--ok); background: var(--ok-soft); border: 1px solid #bfe5d3; border-radius: 10px; padding: 10px 12px; font-size: 14px; }
.checkbox { display: flex; gap: 10px; align-items: center; cursor: pointer; font-weight: 500; }
.checkbox input { width: 18px; height: 18px; accent-color: var(--accent); }

/* ---------- Vorschlagsliste ---------- */
.suggest { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 20; background: #fff;
  border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); max-height: 340px; overflow-y: auto;
  padding: 6px; overscroll-behavior: contain; }
.suggest .opt { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; cursor: pointer; }
.suggest .opt.on, .suggest .opt:hover { background: var(--accent-soft); }
.suggest .opt .main { font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.suggest .opt .main mark { background: none; color: var(--accent); }
.suggest .opt .side { margin-left: auto; color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 55%; }
.suggest .empty { padding: 12px; color: var(--muted); font-size: 14px; }
.cc { display: inline-block; font: 700 11px/1 var(--mono); color: var(--text-2); background: var(--surface-2);
  border: 1px solid var(--line); border-radius: 5px; padding: 3px 5px; }

/* ---------- Suche: Aufteilung ---------- */
.search-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.search-card .card-body { padding: 26px; }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 18px; flex-wrap: wrap; }
.country-pick { display: flex; align-items: center; gap: 8px; }
.country-pick .dd { min-width: 230px; }
.country-pick .dd-btn { height: 40px; font-size: 14px; border-radius: 10px; background-color: #fff; }

/* Ergebnis */
.result-empty { padding: 36px 26px; text-align: center; color: var(--muted); }
.result-empty .ico { width: 52px; height: 52px; border-radius: 14px; background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center; margin: 0 auto 14px; }
.result-empty strong { display: block; color: var(--text); margin-bottom: 4px; font-size: 15px; }
.addr { padding: 8px 10px 4px; }
.addr-line { display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 12px; }
.addr-line + .addr-line { border-top: 1px dashed var(--line); border-radius: 0; }
.addr-line .k { font-size: 11.5px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); }
.addr-line .v { font-size: 17px; font-weight: 600; overflow-wrap: anywhere; cursor: pointer; }
.addr-line .v.empty { color: var(--faint); font-weight: 500; font-style: italic; cursor: default; }
.copy { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 9px;
  border: 1px solid var(--line-strong); background: #fff; font-size: 13px; font-weight: 600; color: var(--text-2); cursor: pointer; transition: all .12s; }
.copy:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
.copy.done { border-color: #9ad4b8; color: var(--ok); background: var(--ok-soft); }
.copy:disabled { opacity: .45; cursor: not-allowed; background: #fff; color: var(--faint); border-color: var(--line); }
.addr-actions { display: flex; gap: 10px; padding: 14px 22px 22px; flex-wrap: wrap; }
.addr-actions .btn { flex: 1 1 180px; }
.preview { margin: 0 22px; padding: 14px 16px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line);
  font-size: 14.5px; line-height: 1.55; color: var(--text-2); white-space: pre-line; }

.hits { max-height: 420px; overflow-y: auto; margin: 16px -6px 0; overscroll-behavior: contain; }
.hit { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 11px 12px; border-radius: 10px; cursor: pointer; border: 1px solid transparent; }
.hit:hover, .hit.on { background: var(--accent-soft); }
.hit.sel { border-color: var(--accent); background: var(--accent-soft); }
.hit .s { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hit .p { color: var(--muted); font-size: 13.5px; grid-column: 1; }
.hit .cc { grid-row: 1 / span 2; grid-column: 2; align-self: center; }
.hits-info { color: var(--muted); font-size: 13px; margin-top: 12px; }

.recent { margin-top: 22px; }
.recent-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: #fff; border-radius: 999px;
  padding: 6px 12px; font-size: 13px; color: var(--text-2); cursor: pointer; max-width: 100%; }
.chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chip:hover { border-color: var(--accent); color: var(--accent); }
.section-label { font-size: 12px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); display: flex; justify-content: space-between; align-items: center; }
.linkbtn { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 12.5px; padding: 0; }
.linkbtn:hover { color: var(--accent); }
.linkbtn.w-lotse { color: var(--accent); font-weight: 600; }
.linkbtn.w-lotse:hover { text-decoration: underline; }

/* ---------- Fußzeile ---------- */
.footer { color: var(--muted); font-size: 13px; padding-top: 18px; padding-bottom: 28px; border-top: 1px solid var(--line); line-height: 1.7; }
.footer a { color: var(--muted); text-decoration: underline; }
.footer .dot { margin: 0 6px; color: var(--faint); }

/* ---------- Anmeldung ---------- */
.auth-wrap { max-width: 440px; margin: 20px auto 40px; }
.auth-wrap .card-body { padding: 30px; }
.auth-icon { width: 48px; height: 48px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 18px; }
.auth-wrap h1 { font-size: 26px; }
.auth-wrap .lead { margin-bottom: 22px; }
.steps { display: flex; gap: 6px; margin-bottom: 20px; }
.steps span { flex: 1; height: 4px; border-radius: 4px; background: var(--line); }
.steps span.on { background: var(--accent); }
.code-input { letter-spacing: .5em; font: 600 24px var(--mono); text-align: center; height: 60px; }
.qr { display: grid; place-items: center; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: #fff; width: 210px; margin: 0 auto 14px; }
.qr svg { width: 180px; height: 180px; display: block; }
.secret { font: 600 14px var(--mono); background: var(--surface-2); border: 1px dashed var(--line-strong); border-radius: 10px;
  padding: 10px 12px; text-align: center; word-break: break-all; letter-spacing: .08em; }
.codes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 14px 0; }
.codes code { font: 600 14px var(--mono); background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px; padding: 9px; text-align: center; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; }
.mt { margin-top: 16px; } .mt-s { margin-top: 10px; } .mb { margin-bottom: 16px; }
.flex { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }

/* ---------- Kennzahlen ---------- */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; box-shadow: var(--shadow); min-width: 0; }
.tile .k { font-size: 12px; color: var(--muted); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.tile .v { font-size: 24px; font-weight: 800; letter-spacing: -.02em; margin-top: 4px; font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tile .s { font-size: 12.5px; color: var(--muted); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.two-col { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 20px; align-items: start; }

/* Fortschritt */
.job { display: grid; gap: 10px; }
.job-top { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.job-title { font-weight: 700; }
.bar { height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; position: relative; }
.bar > i { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 99px; transition: width .4s; }
.bar.indet > i { width: 35% !important; animation: indet 1.3s ease-in-out infinite; }
@keyframes indet { 0% { left: -35%; } 100% { left: 100%; } }
.spin { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--accent-soft); border-top-color: var(--accent); animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Status-Abzeichen */
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; white-space: nowrap; background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.ok { background: var(--ok-soft); color: var(--ok); border-color: #c5e8d7; }
.badge.warn { background: var(--warn-soft); color: var(--warn); border-color: #f3dcb4; }
.badge.err { background: var(--err-soft); color: var(--err); border-color: #f4c7c7; }
.badge.run { background: var(--accent-soft); color: var(--accent); border-color: #d6d9fb; }

/* Länderliste */
.tabs { display: flex; gap: 4px; flex-wrap: wrap; padding: 10px 14px 0; border-bottom: 1px solid var(--line); }
.tabs button { border: 0; background: none; padding: 10px 12px; font-weight: 600; font-size: 14px; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; display: inline-flex; gap: 6px; align-items: center; }
.tabs button.on { color: var(--accent); border-bottom-color: var(--accent); }
.tabs .count { font-size: 11px; background: var(--surface-2); border: 1px solid var(--line); color: var(--muted); border-radius: 99px; padding: 1px 7px; }
.tabs button.on .count { background: var(--accent-soft); color: var(--accent); border-color: #d6d9fb; }
.list-tools { display: flex; gap: 10px; align-items: center; padding: 14px 22px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.list-tools .input { height: 38px; font-size: 14px; max-width: 260px; border-radius: 10px; }
.regions { max-height: 560px; overflow-y: auto; }
.region { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; gap: 14px; align-items: center; padding: 12px 22px; border-bottom: 1px solid var(--line); }
.region:last-child { border-bottom: 0; }
.region.changed { background: #fbfbff; }
.region .name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.region .meta { color: var(--muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.region .err-text { color: var(--err); font-size: 12.5px; }
.toggle { position: relative; width: 40px; height: 24px; border-radius: 99px; background: var(--line-strong); border: 0; cursor: pointer; flex: none; transition: background .15s; }
.toggle::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .15s; }
.toggle.on { background: var(--accent); }
.toggle.on::after { transform: translateX(16px); }
.pending-bar { position: sticky; bottom: 16px; z-index: 10; margin-top: 16px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap;
  background: #111827; color: #fff; padding: 12px 14px 12px 18px; border-radius: 14px; box-shadow: var(--shadow-lg); }
.pending-bar .btn { height: 36px; }
.pending-bar .btn.ghost { color: #cbd5e1; }
.pending-bar .btn.ghost:hover { background: rgba(255,255,255,.08); }

/* Protokoll */
.log { max-height: 360px; overflow-y: auto; font-size: 13px; }
.log-item { display: grid; grid-template-columns: 14px minmax(0, 1fr); gap: 10px; padding: 9px 22px; border-bottom: 1px solid var(--line); }
.log-item:last-child { border-bottom: 0; }
.log-item .dotc { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; background: var(--faint); }
.log-item.ok .dotc { background: var(--ok); } .log-item.warn .dotc { background: var(--warn); } .log-item.error .dotc { background: var(--err); }
.log-item .t { color: var(--faint); font-size: 12px; }

/* Einstellungen */
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.set-row:first-child { padding-top: 0; }
.set-row:last-of-type { border-bottom: 0; }
.set-row .t { font-weight: 600; }
.set-row .d { color: var(--muted); font-size: 13px; }
.set-row .dd { min-width: 170px; }
.set-row .dd-btn { height: 38px; font-size: 14px; border-radius: 10px; }

/* App-Updates */
.drop { display: block; border: 2px dashed var(--line-strong); border-radius: 14px; padding: 34px 20px; text-align: center; cursor: pointer; transition: all .15s; background: var(--surface-2); }
.drop:hover, .drop.over { border-color: var(--accent); background: var(--accent-soft); }
.drop .ico { width: 46px; height: 46px; border-radius: 12px; background: #fff; border: 1px solid var(--line); display: grid; place-items: center; margin: 0 auto 12px; color: var(--accent); }
.pkg { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.pkg-head { padding: 16px 18px; background: var(--surface-2); border-bottom: 1px solid var(--line); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.ver { font: 700 13px var(--mono); padding: 3px 8px; border-radius: 6px; background: #fff; border: 1px solid var(--line); }
.ver.new { color: var(--accent); border-color: #d6d9fb; background: var(--accent-soft); }
.pkg-body { padding: 16px 18px; display: grid; gap: 14px; }
.pkg ul { margin: 6px 0 0; padding-left: 18px; }
.pkg li { margin: 3px 0; }
.files { font: 12.5px/1.8 var(--mono); color: var(--text-2); max-height: 180px; overflow-y: auto; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; }
.files .n { color: var(--ok); font-weight: 700; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 600; padding: 10px 22px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.tbl td { padding: 12px 22px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .r { text-align: right; }

/* Benutzer */
.user { display: flex; align-items: center; gap: 14px; padding: 14px 22px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.user:last-child { border-bottom: 0; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 700; flex: none; }
.user .info { min-width: 0; flex: 1; }
.user .info .n { font-weight: 600; }
.user .info .e { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Hinweis / Modal / Toast ---------- */
.notice { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--accent-soft); border: 1px solid #d6d9fb; color: #3730a3; font-size: 14px; }
.notice.warn { background: var(--warn-soft); border-color: #f3dcb4; color: #7c3d0a; }
.notice svg { flex: none; margin-top: 2px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: #111827; color: #fff;
  padding: 11px 16px; border-radius: 12px; font-size: 14px; font-weight: 500; opacity: 0; pointer-events: none;
  transition: all .2s; z-index: 100; box-shadow: var(--shadow-lg); display: flex; gap: 8px; align-items: center; max-width: calc(100vw - 32px); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast b { color: #a5b4fc; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.modal-backdrop { position: fixed; inset: 0; background: rgba(15, 23, 42, .45); z-index: 90; display: grid; place-items: center; padding: 16px; }
.modal { background: #fff; border-radius: 16px; width: 100%; max-width: 460px; box-shadow: var(--shadow-lg); overflow: hidden; }
.modal .card-body { display: grid; gap: 14px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; background: var(--surface-2); border-top: 1px solid var(--line); flex-wrap: wrap; }
.overlay { position: fixed; inset: 0; background: rgba(244, 245, 249, .92); z-index: 95; display: grid; place-items: center; text-align: center; padding: 16px; }
.overlay .spin { width: 40px; height: 40px; border-width: 3px; margin: 0 auto 16px; }

/* ---------- Eigenes Auswahlmenü ---------- */
.dd { position: relative; display: block; }
.dd-btn { display: flex; align-items: center; justify-content: space-between; gap: 10px; text-align: left; cursor: pointer; }
.dd-btn .dd-val { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dd-btn svg { flex: none; color: var(--muted); transition: transform .15s; }
.dd.open .dd-btn { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-ring); background: #fff; }
.dd.open .dd-btn svg { transform: rotate(180deg); }
.dd-panel { position: absolute; top: calc(100% + 6px); left: 0; z-index: 40; min-width: 100%; width: max-content; max-width: min(340px, calc(100vw - 32px));
  background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); overflow: hidden;
  display: flex; flex-direction: column; max-height: min(380px, 60vh); animation: ddin .12s ease-out; }
.dd-panel.right { left: auto; right: 0; }
.dd-panel.up { top: auto; bottom: calc(100% + 6px); }
@keyframes ddin { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.dd-search { padding: 8px; border-bottom: 1px solid var(--line); }
.dd-search .input { height: 38px; font-size: 15px; border-radius: 9px; }
.dd-list { overflow-y: auto; padding: 6px; overscroll-behavior: contain; }
.dd-opt { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; cursor: pointer; font-size: 14.5px; white-space: nowrap; }
.dd-opt > span:first-child { flex: 1; overflow: hidden; text-overflow: ellipsis; }
.dd-opt.on { background: var(--surface-2); }
.dd-opt:hover { background: var(--accent-soft); }
.dd-opt.sel { color: var(--accent); font-weight: 600; }
.dd-opt svg { color: var(--accent); flex: none; }
.dd-empty { padding: 12px; color: var(--muted); font-size: 14px; }

/* ---------- E-Mail-Vorlagen ---------- */
.tpl-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr); gap: 20px; align-items: start; }
.tpl-tools { padding: 16px; border-bottom: 1px solid var(--line); display: grid; gap: 10px; }
.tpl-tools .input { height: 42px; font-size: 15px; }
.tpl-cats { display: flex; flex-wrap: wrap; gap: 6px; }
.tpl-cats .chip { padding: 4px 11px; font-size: 12.5px; }
.chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.tpl-list { max-height: 620px; overflow-y: auto; overscroll-behavior: contain; }
.tpl-item { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 12px 14px 12px 10px;
  border-bottom: 1px solid var(--line); cursor: pointer; border-left: 3px solid transparent; }
.tpl-item:last-child { border-bottom: 0; }
.tpl-item:hover { background: var(--surface-2); }
.tpl-item.sel { background: var(--accent-soft); border-left-color: var(--accent); }
.tpl-star { border: 0; background: none; font-size: 18px; line-height: 1; color: var(--faint); cursor: pointer; padding: 4px; }
.tpl-star.on { color: #f59e0b; }
.tpl-title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tpl-cat { font-size: 11px; font-weight: 600; color: var(--accent); background: #fff; border: 1px solid #d6d9fb; border-radius: 99px; padding: 1px 7px; margin-left: 4px; vertical-align: 1px; }
.tpl-snip { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.tpl-item .copy { padding: 0 10px; }
.tpl-subject { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); font-weight: 600; }
.tpl-subject span { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.tpl-body { white-space: pre-wrap; overflow-wrap: anywhere; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2);
  font-size: 15px; line-height: 1.6; max-height: 460px; overflow-y: auto; }
.tpl-ph { padding: 14px; border: 1px dashed #c7cbf7; border-radius: 12px; background: #fafaff; }
.tpl-ph-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin-top: 10px; }
.tpl-ph-grid .field + .field { margin-top: 0; }
.tpl-ph-grid .input { height: 40px; font-size: 15px; background: #fff; }
.tpl-textarea { height: auto; min-height: 220px; padding: 12px 14px; line-height: 1.55; resize: vertical; font-size: 15px; }

/* ---------- Anrede-Auswahl ---------- */
.anrede { padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; margin-top: 10px; }
.anrede-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; margin-top: 10px; }
.anrede-row .input { height: 40px; font-size: 15px; background: var(--surface-2); }
.anrede-ohne { display: flex; align-items: center; height: 40px; padding: 0 12px; font-size: 14px;
  color: var(--faint); border: 1px dashed var(--line-strong); border-radius: 12px; }
.anrede-vorschau { margin-top: 10px; padding: 9px 12px; border-radius: 8px; background: var(--accent-soft);
  color: var(--accent); font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.anrede .section-label { flex-wrap: wrap; gap: 8px; }
.seg-sm { padding: 3px; box-shadow: none; }
.seg-sm button { white-space: nowrap; }
.seg-sm button { padding: 5px 11px; font-size: 12.5px; font-weight: 600; text-transform: none; letter-spacing: 0; }
@media (max-width: 560px) { .anrede-row { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Lieferantenwechsel-Rechner ---------- */
.search-links { display: grid; gap: 22px; align-content: start; min-width: 0; }

.wechsel .card-head { padding-bottom: 14px; }
.wechsel h2 { font-size: 17px; }

.w-kopf { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: end; }
.w-kopf .btn { height: 48px; }
.w-wochen { grid-column: 1 / -1; max-width: 170px; }
.w-kopf input[type="number"] { -moz-appearance: textfield; }

.w-schalter { display: grid; gap: 9px; }
.w-schalter .checkbox { font-size: 14.5px; font-weight: 500; color: var(--text-2); align-items: flex-start; }
.w-schalter .checkbox input { margin-top: 1px; flex: none; }

.w-treffer { padding: 14px 16px; border-radius: 12px; background: var(--accent-soft); border: 1px solid #d8dcff; }
.w-datum { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  font-size: 21px; font-weight: 700; color: var(--accent); letter-spacing: -.01em; }
.w-datum .copy { flex: none; background: #fff; }
.w-rechnung { margin-top: 5px; font-size: 13.5px; color: var(--text-2); overflow-wrap: anywhere; }

.w-zeitraum { margin-top: 10px; font-size: 13px; color: var(--muted); }

.w-liste { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 4px; font-size: 13.5px; color: var(--text-2); }
.w-liste li { padding-left: 14px; position: relative; }
.w-liste li::before { content: "·"; position: absolute; left: 4px; color: var(--faint); }

.w-hinweis { margin-top: 8px; font-size: 13px; color: var(--muted); line-height: 1.5; }
.w-leer { font-size: 14px; color: var(--muted); }


/* ---------- Platzhalter einfügen ---------- */
.ph-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 12px 0 10px; }
.ph-chips-titel { font-size: 12px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); margin-right: 2px; }
.ph-chips .chip { padding: 5px 11px; font-size: 12.5px; }
code { font-family: var(--mono); font-size: .9em; background: var(--surface-2); border: 1px solid var(--line); border-radius: 5px; padding: 1px 4px; }

/* ---------- Dokumente ---------- */
.doc-drop { padding: 26px 20px; }
.doc-search { max-width: 260px; height: 38px; font-size: 14px; border-radius: 10px; }
.doc-cats { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 22px; border-bottom: 1px solid var(--line); }
.doc-cats .chip { padding: 4px 11px; font-size: 12.5px; }
.doc { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 22px; border-bottom: 1px solid var(--line); }
.doc:last-child { border-bottom: 0; }
.doc:hover { background: var(--surface-2); }
.doc-ico { width: 42px; height: 48px; border-radius: 8px; display: grid; place-items: center; font: 800 10px var(--mono); letter-spacing: .02em;
  color: var(--c); background: color-mix(in srgb, var(--c) 10%, #fff); border: 1px solid color-mix(in srgb, var(--c) 28%, #fff); }
.doc-name { font-weight: 600; color: var(--text); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-name:hover { color: var(--accent); }
.doc-meta { color: var(--muted); font-size: 12.5px; margin-top: 3px; display: flex; align-items: center; flex-wrap: wrap; }
.doc-actions { display: flex; gap: 6px; align-items: center; }
.doc-actions .btn.ghost { padding: 0 10px; }
.upl { margin-top: 12px; padding: 12px 14px; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.upl.err { padding: 0; border: 0; background: none; }

/* ---------- Mobil ---------- */
@media (max-width: 960px) {
  .search-grid, .two-col, .tpl-grid { grid-template-columns: minmax(0, 1fr); }
  .tpl-list { max-height: 340px; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* Unter 1100 Pixel: Kopfzeile mit Menü statt Seitenleiste */
@media (max-width: 1099px) {
  :root { --kopf: 60px; }
  body { display: block; }
  .haupt { min-height: calc(100vh - 60px); }
  .shell { height: 60px; border-right: 0; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.94);
    backdrop-filter: saturate(1.4) blur(10px); }
  .shell-kopf { height: 60px; padding: 0 12px 0 20px; }
  .brand-mark { width: 30px; height: 30px; border-radius: 9px; }
  .brand-text small { display: none; }
  .shell .menu-btn { display: inline-flex; }
  .shell-panel { display: none; position: fixed; top: 60px; left: 0; right: 0; max-height: calc(100vh - 60px);
    background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg); padding: 14px 16px 16px; }
  .shell.open .shell-panel { display: flex; }
  .sb-link { padding: 11px 12px; font-size: 15px; }
  .sb-heute { margin-top: 0; }
  .lb-grid { grid-template-columns: minmax(0, 1fr); }
}
/* Wechsel-Lotse, Lieferbeginn und „Heute“ sind fürs Arbeiten am Rechner gedacht – am Handy ausblenden */
@media (max-width: 960px) { .nur-pc { display: none !important; } }
@media (max-width: 600px) {
  .dd-panel { width: 100%; max-width: none; }
  .dd-opt { padding: 12px 10px; font-size: 16px; }
  .container { padding: 0 16px; }
  .shell-kopf { padding: 0 8px 0 16px; }
  main.container { padding-top: 22px; }
  h1 { font-size: 30px; }
  .search-card .card-body, .card-body { padding: 20px 18px; }
  .card-head { padding: 16px 18px; }
  .seg { width: 100%; }
  .seg button { flex: 1; justify-content: center; padding: 9px 8px; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .country-pick .dd, .country-pick { width: 100%; }
  .row, .row.nr { grid-template-columns: minmax(0, 1fr) 96px; }
  .row.two { grid-template-columns: minmax(0, 1fr); }
  .addr-line { grid-template-columns: minmax(0, 1fr) auto; padding: 10px 8px; }
  .addr-line .k { grid-column: 1 / -1; margin-bottom: -6px; }
  .addr-actions { padding: 14px 18px 18px; }
  .preview { margin: 0 18px; }
  .region { grid-template-columns: auto minmax(0, 1fr) auto; padding: 12px 18px; }
  .region .rbtn { display: none; }
  .list-tools, .log-item, .user, .tbl td, .tbl th { padding-left: 18px; padding-right: 18px; }
  .tile .v { font-size: 20px; }
  .set-row { flex-direction: column; align-items: stretch; }
  .set-row .dd { width: 100%; }
  .auth-wrap .card-body { padding: 24px 20px; }
  .hide-m { display: none; }
  .doc { padding: 12px 14px; gap: 6px 12px; grid-template-columns: auto minmax(0, 1fr); }
  .doc-actions { grid-column: 2; }
  .doc-name { white-space: normal; overflow-wrap: anywhere; }
  .doc-search { max-width: none; width: 100%; }
  .doc-cats { padding: 12px 18px; }
  .doc-actions .btn { padding: 0 9px; }
  .label .hint.hm { display: none; }
}
.modal { max-height: calc(100vh - 32px); display: flex; flex-direction: column; }
.modal > .card-body { overflow-y: auto; }
