/* Grexon Fulfillment — Kundenportal (ADR 0002). Eigenes Theme, getrennt von desk.css/scanner.css.
   Server-rendered, modern, Token-basiert (hell/dunkel). Grexon-Orange als Akzent. */

:root {
  --bg: #f4f5f7;
  --surface: #ffffff;
  --surface-2: #f7f9fb;
  --border: #e6e8ec;
  --border-strong: #d3d7dd;
  --text: #1a1d21;
  --muted: #6b7280;
  --orange: #f94b0c;
  --orange-soft: #fff1ec;
  --accent: #1f7a4d;          /* „available/gut" grün */
  --accent-soft: #e8f5ee;
  --warn: #b4540a;
  --warn-soft: #fdf0e3;
  --shadow: 0 1px 2px rgba(16,24,40,.06), 0 1px 3px rgba(16,24,40,.05);
  --radius: 12px;
  --side-w: 248px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme=light]) {
    --bg: #0f1216; --surface: #171a1f; --surface-2: #1d2228; --border: #272c33; --border-strong: #363c45;
    --text: #e8eaed; --muted: #99a1ad; --orange: #ff6a37; --orange-soft: #2a1a12;
    --accent: #58c98b; --accent-soft: #14241b; --warn: #e0a45c; --warn-soft: #2a2014;
    --shadow: none;
  }
}
[data-theme=dark] {
  --bg: #0f1216; --surface: #171a1f; --surface-2: #1d2228; --border: #272c33; --border-strong: #363c45;
  --text: #e8eaed; --muted: #99a1ad; --orange: #ff6a37; --orange-soft: #2a1a12;
  --accent: #58c98b; --accent-soft: #14241b; --warn: #e0a45c; --warn-soft: #2a2014;
  --shadow: none;
}

* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }

/* ---- Shell: Sidebar + Main ---- */
.portal-shell { display: grid; grid-template-columns: var(--side-w) 1fr; min-height: 100vh; }
.portal-side {
  position: sticky; top: 0; height: 100vh; background: var(--surface); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; padding: 1.1rem .8rem; gap: .4rem;
}
.brand { display: flex; align-items: center; gap: .6rem; padding: .2rem .5rem 1rem; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px; background: var(--orange); color: #fff;
  display: grid; place-items: center; font-weight: 800; font-size: 20px;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-size: 16px; letter-spacing: -.01em; }
.brand-text small { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }

.side-nav { display: flex; flex-direction: column; gap: .15rem; }
.side-nav a {
  display: flex; align-items: center; gap: .65rem; padding: .55rem .7rem; border-radius: 9px;
  text-decoration: none; color: var(--muted); font-weight: 600; font-size: 14px;
}
.side-nav a span { width: 1.1rem; text-align: center; }
.side-nav a:hover { background: var(--surface-2); color: var(--text); }
.side-nav a.active { background: var(--orange-soft); color: var(--orange); }
/* Line-Icons (icons-Tag): inline, skaliert mit der Schrift, in Flex nicht stauchen */
.ic { vertical-align: -0.14em; flex: none; }
.side-nav a .ic { width: 18px; height: 18px; vertical-align: 0; }
.theme-toggle .ic { width: 15px; height: 15px; }
.theme-toggle .ic-sun { display: none; }  /* hell: Mond zeigen (→ dunkel) */
:root[data-theme="dark"] .theme-toggle .ic-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .ic-sun { display: inline-block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .ic-moon { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .ic-sun { display: inline-block; }
}

.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: .5rem; padding-top: .8rem; border-top: 1px solid var(--border); }
.who { padding: 0 .3rem; }
.who-name { font-weight: 600; font-size: 13px; }
.who-cust { color: var(--muted); font-size: 12px; }
.side-foot form { margin: 0; }
/* Sprach-Umschalter (Flaggen) in der Sidebar */
.lang-row { display: flex; gap: .4rem; padding: .1rem .3rem; }
.lang-btn { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 22px; padding: 0; border: 1px solid var(--border); border-radius: 5px; background: var(--surface); cursor: pointer; overflow: hidden; }
.lang-btn img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lang-btn.active { border-color: var(--orange); box-shadow: 0 0 0 1px var(--orange); cursor: default; }
.lang-btn:not(.active):hover { border-color: var(--border-strong); }
.ghost, .logout {
  width: 100%; text-align: left; padding: .5rem .7rem; border: 1px solid var(--border); border-radius: 9px;
  background: var(--surface); color: var(--text); cursor: pointer; font: inherit; font-size: 13px; font-weight: 600; text-decoration: none;
}
.ghost:hover { border-color: var(--border-strong); }

.portal-main { padding: 1.6rem 2rem 3rem; max-width: 1400px; }
.page-head { margin-bottom: 1.2rem; }
.page-head h1 { margin: 0; font-size: 1.5rem; letter-spacing: -.02em; }
.page-head .sub { margin: .2rem 0 0; color: var(--muted); }
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: .6rem; }
.crumbs a { color: var(--orange); text-decoration: none; }

/* ---- Flash-Meldungen ---- */
.flashes { list-style: none; margin: 0 0 1rem; padding: 0; display: flex; flex-direction: column; gap: .5rem; }
.flashes li { padding: .6rem .9rem; border-radius: 9px; border: 1px solid var(--border); background: var(--surface); font-weight: 600; }
.flashes li.error { background: var(--warn-soft); border-color: var(--warn); color: var(--warn); }
.flashes li.success { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }

/* ---- KPI-Karten ---- */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: .8rem; margin-bottom: 1.4rem; }
.kpi {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem;
  display: flex; flex-direction: column; gap: .25rem; text-decoration: none; color: inherit; box-shadow: var(--shadow);
}
a.kpi:hover { border-color: var(--border-strong); }
.kpi-label { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
.kpi-num { font-size: 2rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.05; }
.kpi-num.accent { color: var(--accent); }
.kpi-num.warn { color: var(--warn); }
.kpi-foot { font-size: 12px; color: var(--muted); }

/* ---- Tiles (Zähler) ---- */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: .8rem; }
.tile {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem;
  text-decoration: none; color: inherit; display: flex; flex-direction: column; gap: .2rem; box-shadow: var(--shadow);
}
.tile:hover { border-color: var(--border-strong); }
.tile-num { font-size: 1.6rem; font-weight: 800; }
.tile-label { color: var(--muted); font-size: 13px; }

/* ---- Karten ---- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.1rem 1.2rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.card h2 { margin: 0 0 .8rem; font-size: 1.05rem; }
dl.fields { display: grid; grid-template-columns: max-content 1fr; gap: .4rem 1.2rem; margin: 0; }
dl.fields dt { color: var(--muted); font-size: 13px; }
dl.fields dd { margin: 0; }

/* ---- Toolbar ---- */
.toolbar { display: flex; gap: .5rem; align-items: center; margin-bottom: 1rem; flex-wrap: wrap; }
.toolbar input[type=search] { flex: 0 1 320px; padding: .5rem .7rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text); font: inherit; }
.hint { color: var(--muted); font-size: 13px; margin: -.4rem 0 .8rem; }

/* ---- Tabellen ---- */
table.grid { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
table.grid th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); background: var(--surface-2); padding: .6rem .8rem; border-bottom: 1px solid var(--border); }
table.grid td { padding: .65rem .8rem; border-bottom: 1px solid var(--border); }
table.grid tr:last-child td { border-bottom: none; }
table.grid .num { text-align: right; font-variant-numeric: tabular-nums; }
table.grid .muted { color: var(--muted); }
table.grid .warn { color: var(--warn); font-weight: 700; }
table.grid .accent { color: var(--accent); font-weight: 700; }
tr.row-link { cursor: pointer; }
tr.row-link:hover td { background: var(--surface-2); }
td.empty { text-align: center; color: var(--muted); padding: 1.6rem; }
a.link { color: var(--orange); text-decoration: none; border-bottom: 1px dotted var(--border-strong); }

/* ---- Status-Badges ---- */
.badge { display: inline-block; padding: .12rem .55rem; border-radius: 999px; font-size: 12px; font-weight: 700; border: 1px solid var(--border-strong); color: var(--muted); background: var(--surface-2); }
.badge.s-shipped, .badge.s-complete { color: var(--accent); background: var(--accent-soft); border-color: var(--accent); }
.badge.s-cancelled, .badge.s-short { color: var(--warn); background: var(--warn-soft); border-color: var(--warn); }
.badge.s-open, .badge.s-new, .badge.s-allocated, .badge.s-picking, .badge.s-picked, .badge.s-packed, .badge.s-partial { color: var(--orange); background: var(--orange-soft); border-color: var(--orange); }

/* ---- Formulare (Avis anlegen) ---- */
.page-head.with-action { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; flex-wrap: wrap; }
.btn { display: inline-block; padding: .55rem .9rem; border-radius: 9px; text-decoration: none; font-weight: 700; font-size: 14px; cursor: pointer; border: 1px solid var(--border); background: var(--surface); color: var(--text); }
.primary.btn, a.primary { background: var(--orange); border-color: var(--orange); color: #fff; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: .8rem 1rem; }
.form-grid label, .info-banner + table label { display: flex; flex-direction: column; gap: .25rem; font-size: 12px; color: var(--muted); font-weight: 600; }
.form-grid label.wide { grid-column: 1 / -1; }
.form-grid input { padding: .5rem .6rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text); font: inherit; }
.info-banner { background: var(--orange-soft); border: 1px solid var(--orange); color: var(--text); border-radius: 10px; padding: .7rem .9rem; margin-bottom: .9rem; font-size: 13px; }
/* Produktsuche (Typeahead) im Avis-Formular */
.product-search { position: relative; max-width: 560px; margin-bottom: .9rem; }
.product-search input { width: 100%; padding: .55rem .7rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text); font: inherit; }
.suggest { position: absolute; z-index: 20; left: 0; right: 0; margin: .25rem 0 0; padding: .25rem; list-style: none; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 10px; box-shadow: var(--shadow); max-height: 300px; overflow: auto; }
.suggest li { padding: .45rem .6rem; border-radius: 7px; cursor: pointer; font-size: 14px; }
.suggest li:hover { background: var(--surface-2); }
/* Tastatur-Auswahl (↑/↓): deutlicher als :hover, mit Akzent-Balken. */
.suggest li.active { background: var(--accent-soft); box-shadow: inset 3px 0 0 var(--accent); }
.suggest li.none { color: var(--muted); cursor: default; }
.empty-lines { padding: .9rem .2rem; }
table.grid select, table.grid input { width: 100%; padding: .4rem .5rem; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); font: inherit; }
table.grid input.qty { max-width: 6rem; }
.row-del { width: auto; padding: .35rem .55rem; }
table.grid input:disabled { background: var(--surface-2); color: var(--muted); cursor: not-allowed; }
.lot-na .lot-activate { padding: .3rem .6rem; font-size: 12px; white-space: nowrap; }
.mhd-cell .muted { display: inline-block; padding: .4rem .2rem; }
.lot-msg { margin: 0 0 .8rem; padding: .55rem .8rem; border-radius: 9px; font-size: 13px; font-weight: 600; border: 1px solid var(--border); background: var(--surface); }
.lot-msg.ok { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.lot-msg.warn { background: var(--warn-soft); border-color: var(--warn); color: var(--warn); }
.form-actions { display: flex; gap: .6rem; justify-content: flex-end; align-items: center; margin-top: 1rem; }
/* In Form-Aktionen sind die Buttons normal breit + gleich hoch (nicht der full-width-Sidebar-.ghost). */
.form-actions .ghost { width: auto; text-align: center; padding: .6rem 1.1rem; }
.form-actions .primary { margin-top: 0; padding: .6rem 1.1rem; border: 1px solid var(--orange); }
#add-line { margin-top: .6rem; }

/* ---- Login ---- */
.login-body { display: grid; place-items: center; min-height: 100vh; padding: 1rem; }
.login-card { width: 100%; max-width: 360px; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 1.6rem; box-shadow: var(--shadow); }
.brand-lg { padding: 0 0 1rem; }
.login-card h1 { margin: .2rem 0 1rem; font-size: 1.3rem; }
.login-card form { display: flex; flex-direction: column; gap: .3rem; }
.login-card label { font-size: 12px; color: var(--muted); font-weight: 600; margin-top: .5rem; }
.login-card input, .login-card select { padding: .6rem .7rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text); font: inherit; width: 100%; }

/* Vertreter-Ansicht („als Kunde") — auffälliger Hinweis-Balken über dem Portal */
.portal-banner { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; background: var(--orange-soft); border: 1px solid var(--orange); color: var(--text); border-radius: 10px; padding: .55rem .9rem; margin-bottom: 1rem; font-size: 14px; }
.portal-banner .who-cust { font-weight: 700; }
.portal-banner form { margin: 0; }
.portal-banner .spacer { margin-left: auto; }
.portal-banner a, .portal-banner button { font-size: 13px; padding: .35rem .7rem; border: 1px solid var(--orange); border-radius: 8px; background: var(--surface); color: var(--text); text-decoration: none; cursor: pointer; font-weight: 600; }
.primary { margin-top: 1rem; padding: .65rem; border: none; border-radius: 9px; background: var(--orange); color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.primary:hover { filter: brightness(1.05); }

/* ---- Schmal (Tablet/Handy): Sidebar oben ---- */
@media (max-width: 760px) {
  .portal-shell { grid-template-columns: 1fr; }
  .portal-side { position: static; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; }
  .side-nav { flex-direction: row; flex-wrap: wrap; }
  .side-foot { margin: 0 0 0 auto; flex-direction: row; border: none; padding: 0; align-items: center; }
  .side-foot .who { display: none; }
  .portal-main { padding: 1.1rem; }
}

/* ---- Stores / Channel-Anbindung (ADR 0006) ---- */
.badge.s-connected { color: var(--accent); background: var(--accent-soft); border-color: var(--accent); }
.badge.s-error { color: var(--warn); background: var(--warn-soft); border-color: var(--warn); }
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; }
.store-card { display: flex; flex-direction: column; gap: .6rem; }
.store-card h3 { margin: 0; font-size: 1.05rem; }
.store-card .store-caps { font-size: 13px; margin: 0; }
.store-card .btn { align-self: flex-start; }
.store-form label { display: block; margin-bottom: .7rem; font-weight: 600; }
.store-form input { width: 100%; max-width: 420px; padding: .55rem .7rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text); font: inherit; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1.2rem; margin: 0; }
.kv dt { color: var(--muted); font-weight: 600; }
.kv dd { margin: 0; }
.danger-form { margin-top: .5rem; }
.ghost.danger, button.danger { color: var(--warn); border-color: var(--warn); }
.wh-form { display: flex; flex-direction: column; gap: .6rem; }
.wh-option { display: flex; gap: .6rem; align-items: flex-start; padding: .7rem .8rem; border: 1px solid var(--border); border-radius: 10px; cursor: pointer; }
.wh-option:hover { border-color: var(--border-strong); }
.wh-option input { margin-top: .25rem; }

/* ---- Produktbilder ---- */
.bild-galerie { display: flex; flex-wrap: wrap; gap: .6rem; }
.bild-galerie .bild { width: 120px; height: 120px; object-fit: cover; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); }

/* ---- Store-Connect: Umgebungswahl + Sandbox-Badge ---- */
.badge.s-sandbox { color: var(--warn); background: var(--warn-soft); border-color: var(--warn); }
.env-choice { border: 1px solid var(--border); border-radius: 10px; padding: .6rem .8rem; margin: .2rem 0 .4rem; }
.env-choice legend { padding: 0 .4rem; font-weight: 700; font-size: 13px; color: var(--muted); }
.env-opt { display: flex; gap: .55rem; align-items: flex-start; padding: .35rem 0; font-weight: 400; }
.env-opt input { margin-top: .2rem; flex: none; }
.env-opt span { font-size: 13px; line-height: 1.4; }

/* ---- Fulfillment Plus ---- */
.fp-filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.fp-filters .chip { display: inline-flex; align-items: center; gap: .4rem; padding: .35rem .7rem; border: 1px solid var(--border); border-radius: 999px; text-decoration: none; color: var(--text); font-size: 13px; font-weight: 600; background: var(--surface); }
.fp-filters .chip:hover { border-color: var(--accent); }
.fp-filters .chip.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.fp-filters .chip span { font-variant-numeric: tabular-nums; opacity: .8; }
/* FP-Unternavigation (Programm ↔ Verkäufe) — Chips als Tab-Leiste */
.fp-tabs { display: flex; gap: .5rem; margin: 0 0 1.2rem; border-bottom: 1px solid var(--border); padding-bottom: .8rem; }
.fp-tabs .chip { display: inline-flex; align-items: center; padding: .35rem .9rem; border: 1px solid var(--border); border-radius: 999px; text-decoration: none; color: var(--text); font-size: 13px; font-weight: 600; background: var(--surface); }
.fp-tabs .chip:hover { border-color: var(--accent); }
.fp-tabs .chip.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.fp-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .6rem; margin: 0; }
.fp-toggle { display: inline-flex; align-items: center; gap: .35rem; font-weight: 600; font-size: 13px; white-space: nowrap; }
.fp-field { display: inline-flex; flex-direction: column; gap: .15rem; font-size: 11px; color: var(--muted); font-weight: 600; }
.fp-price { width: 110px; padding: .35rem .5rem; border: 1px solid var(--border); border-radius: 7px; font: inherit; background: var(--surface); color: var(--text); }
.fp-listed { font-size: 12px; color: var(--muted); white-space: nowrap; }
.fp-warn { font-size: 11px; font-weight: 700; color: var(--warn); background: var(--warn-soft); border: 1px solid var(--warn); border-radius: 6px; padding: .1rem .4rem; align-self: center; }
.fp-row button { margin-left: auto; }

/* ---- Dashboard: Versand-Karte + Verlauf + Top-Produkte ---- */
:root {
  --map-zero: #eef0f3;
  --heat-1: color-mix(in srgb, var(--orange) 15%, var(--map-zero));
  --heat-2: color-mix(in srgb, var(--orange) 32%, var(--map-zero));
  --heat-3: color-mix(in srgb, var(--orange) 52%, var(--map-zero));
  --heat-4: color-mix(in srgb, var(--orange) 74%, var(--map-zero));
  --heat-5: var(--orange);
}
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) { --map-zero: #23282f; } }
[data-theme=dark] { --map-zero: #23282f; }

.kpi-num.orange { color: var(--orange); }
.section-title { margin: 1.6rem 0 .8rem; font-size: 1.05rem; }

.dash-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 1rem; align-items: stretch; }
.dash-grid .card { margin-bottom: 1rem; }
@media (max-width: 1100px) { .dash-grid { grid-template-columns: 1fr; } }

.map-card { display: flex; flex-direction: column; }
.map-head { display: flex; align-items: baseline; gap: .7rem; flex-wrap: wrap; margin-bottom: .6rem; }
.map-head h2 { margin: 0; }
.map-sub { font-size: 13px; }
.map-toggle { margin-left: auto; display: inline-flex; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.map-toggle button { padding: .3rem .85rem; border: 0; background: var(--surface); color: var(--muted); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.map-toggle button.active { background: var(--orange); color: #fff; }
.map-wrap { flex: 1; display: grid; place-items: center; min-height: 320px; }
.map-wrap[hidden] { display: none; }
.map-wrap .geo-map { width: 100%; max-height: 460px; height: auto; }
.geo-map [data-region] { fill: var(--map-zero); stroke: var(--surface); stroke-width: 1px; vector-effect: non-scaling-stroke; transition: fill .15s; }
.geo-map [data-region]:hover { stroke: var(--text); cursor: pointer; }
.map-foot { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin-top: .6rem; font-size: 12px; color: var(--muted); }
.map-legend { display: inline-flex; align-items: center; gap: .25rem; }
.heat-chip { width: 18px; height: 10px; border-radius: 3px; display: inline-block; border: 1px solid var(--border); }
.heat-chip.h1 { background: var(--heat-1); } .heat-chip.h2 { background: var(--heat-2); }
.heat-chip.h3 { background: var(--heat-3); } .heat-chip.h4 { background: var(--heat-4); }
.heat-chip.h5 { background: var(--heat-5); }
.map-tooltip { position: fixed; z-index: 50; pointer-events: none; background: var(--text); color: var(--bg); padding: .35rem .6rem; border-radius: 7px; font-size: 12.5px; font-weight: 600; box-shadow: var(--shadow); white-space: nowrap; }
.map-tooltip small { opacity: .75; font-weight: 400; }

.top-card .top-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.top-row { display: flex; align-items: center; gap: .7rem; padding: .55rem 0; text-decoration: none; color: inherit; border-bottom: 1px solid var(--border); }
.top-list li:last-child .top-row { border-bottom: none; }
.top-row:hover .top-name { color: var(--orange); }
.top-thumb { width: 42px; height: 42px; border-radius: 9px; object-fit: cover; background: var(--surface-2); border: 1px solid var(--border); flex: none; }
.top-thumb-empty { display: inline-block; }
.top-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .1rem; }
.top-name { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-sku { font-size: 12px; }
.top-bar { height: 5px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.top-bar i { display: block; height: 100%; background: var(--orange); border-radius: 3px; }
.top-units { font-weight: 800; font-size: 1.05rem; text-align: right; }
.top-units small { display: block; font-size: 10px; color: var(--muted); font-weight: 600; }

/* Mini-Thumbnails in Listen (Produkte, Auftrags-Positionen) */
td.thumb-cell { width: 44px; padding: .3rem .4rem .3rem .8rem; }
.row-thumb { width: 34px; height: 34px; border-radius: 7px; object-fit: cover; background: var(--surface-2); border: 1px solid var(--border); display: block; }

.ship-chart { display: flex; align-items: stretch; gap: .45rem; height: 170px; padding-top: .4rem; }
.ship-col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: .25rem; min-width: 0; }
.ship-count { font-size: 11.5px; font-weight: 700; color: var(--text); }
.ship-count.zero { color: var(--muted); font-weight: 400; }
.ship-bar { width: 100%; max-width: 46px; border-radius: 6px 6px 2px 2px; background: color-mix(in srgb, var(--orange) 45%, var(--surface)); min-height: 2px; }
.ship-bar.today { background: var(--orange); }
.ship-day { font-size: 10.5px; color: var(--muted); text-align: center; line-height: 1.25; }
.ship-day.today { color: var(--orange); font-weight: 700; }

/* ---- User-Management (ADR 0009) ---- */
.karte { border: 1px solid var(--border); border-radius: 12px; padding: 1rem 1.1rem; background: var(--surface); margin-bottom: 1.4rem; }
.karte h2 { margin: 0 0 .7rem; font-size: 1.1rem; }
.karte .meta { color: var(--muted); font-size: 13px; margin: .7rem 0 0; }
.invite-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .7rem; }
.invite-form label { display: flex; flex-direction: column; gap: .25rem; font-size: 12px; font-weight: 600; color: var(--muted); }
.invite-form input, .invite-form select { padding: .5rem .6rem; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); font: inherit; }
.invite-form input[type=email] { min-width: 240px; }
.inline-form { display: inline; margin: 0; }
.inline-form select { padding: .3rem .5rem; border: 1px solid var(--border); border-radius: 7px; background: var(--surface); color: var(--text); font: inherit; }
table.grid td.right, .right { text-align: right; }
.pw-help { margin: .2rem 0 .6rem; padding-left: 1.1rem; font-size: 12px; color: var(--muted); }
