/* ============================================================================
   restablo.de Partner Portal — Design-System v2
   Helles, neutrales Thema · Brand-Rot #CC1236 · weiße Sidebar · Pill-Aktionen
   Farben an restabloPortal (_variables.scss) angeglichen, Stand 2026-10-06:
   Signal-Töne (--ok/--warn/--bad) für Punkte, Ränder, Flächen; für TEXT die
   dunkleren --*-text-Töne (≥ 4,5:1 auf Weiß bzw. auf der jeweiligen -bg-Fläche).
   ============================================================================ */

:root {
    /* Marke — wie restabloPortal $prim-color, Hover wie consent.scss (#A00E2B) */
    --brand: #CC1236;
    --brand-dark: #A00E2B;
    --brand-tint: rgba(204, 18, 54, 0.07);
    --brand-tint-strong: rgba(204, 18, 54, 0.13);
    /* Text — $black-color / $secondary-color / Sekundärtext */
    --ink: #282828;
    --ink-soft: #555555;
    --muted: #6F6F6F;           /* 5,0:1 auf Weiß, 4,7:1 auf --bg */
    /* Flächen & Ränder — $grey-color / $border-color / $promo-muted-bg */
    --bg: #F7F7F7;
    --surface: #FFFFFF;
    --line: #E0E0E0;
    --line-strong: #C9C9C9;
    --nav-active: #ECECEC;      /* aktiver Navigationspunkt — Grau statt Rot-Tint, dunkler als Hover (--bg) */
    --highlight: #F2F2F2;       /* leichter Grauton für hervorgehobene Zeilen (z. B. heutiger Tag) */
    /* Status — $green-color / $green-text-color / $red-color, Amber wie cart.scss */
    --ok: #27AE60;
    --ok-text: #1E7A45;
    --ok-bg: #E9F7EF;
    --warn: #B26A00;
    --warn-text: #8F5500;
    --warn-bg: #FFF3DF;
    --bad: #D52B4C;
    --bad-text: #B3162E;
    --bad-dark: #B3162E;
    --bad-bg: #FCEBEE;
    /* Info: restabloPortal kennt kein Blau → neutral */
    --info: #555555;
    --info-bg: #F2F2F2;
    --r-sm: 8px;
    --r: 14px;
    --r-pill: 999px;
    --shadow-sm: 0 1px 2px rgba(40, 40, 40, 0.05);
    --shadow: 0 6px 24px rgba(40, 40, 40, 0.07);
    --sidebar-w: 264px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
    font-family: "Segoe UI Variable Text", "Segoe UI", -apple-system, "Helvetica Neue", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.55;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.25; margin: 0 0 14px; font-weight: 650; }
h1 { font-size: 25px; letter-spacing: -0.02em; }
h2 { font-size: 18px; }
h3 { font-size: 15.5px; }
p { margin: 0 0 12px; }
code { background: var(--bg); border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; font-size: 13px; }

/* ============================== App-Shell ============================== */

.shell { display: flex; min-height: 100vh; }

.sidebar {
    flex: 0 0 var(--sidebar-w);
    background: var(--surface);
    border-right: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    padding: 18px 14px;
}
.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 3px; }

.sidebar-logo { display: block; padding: 2px 8px 14px; }
.sidebar-logo img { height: 34px; display: block; }

/* Scope-Switcher oben in der Sidebar — wie das Dropdown im alten Menü */
.scope-box {
    margin: 0 0 16px;
    padding: 10px;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--r);
}
.scope-box label {
    display: block;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
    margin: 0 2px 6px;
}
.scope-box select {
    width: 100%;
    padding: 8px 30px 8px 10px;
    border: 1px solid var(--line-strong);
    border-radius: var(--r-sm);
    background: var(--surface) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='11' height='7' viewBox='0 0 11 7'><path d='M1 1l4.5 4.5L10 1' fill='none' stroke='%237A8190' stroke-width='1.6' stroke-linecap='round'/></svg>") no-repeat right 10px center;
    appearance: none;
    -webkit-appearance: none;
    font-size: 13.5px;
    color: var(--ink);
    cursor: pointer;
}
.scope-box .scope-current {
    font-size: 13.5px; font-weight: 600; padding: 2px 2px 0;
}
.scope-badge {
    display: inline-block;
    margin-top: 6px;
    padding: 2px 10px;
    border-radius: var(--r-pill);
    font-size: 10.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.scope-badge--store   { background: var(--brand-tint-strong); color: var(--brand); }
.scope-badge--chain   { background: var(--warn-bg); color: var(--warn-text); }
.scope-badge--partner { background: var(--info-bg); color: var(--info); }
/* Badge links, „Support“ rechtsbündig daneben (alle Bereiche) */
.scope-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.scope-meta .scope-badge { margin-top: 0; }
.scope-support {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 2px 4px; border-radius: var(--r-sm);
    font-size: 12.5px; font-weight: 600; color: var(--ink-soft); white-space: nowrap;
}
.scope-support svg { width: 14px; height: 14px; flex: 0 0 14px; }
.scope-support:hover { color: var(--brand); text-decoration: none; }
.scope-support.active { color: var(--brand); }

.nav-group { margin: 4px 0 2px; }
.nav-label {
    padding: 10px 10px 4px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}
.nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: var(--r-sm);
    color: var(--ink-soft);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 1px;
}
.nav-item:hover { background: var(--bg); color: var(--ink); text-decoration: none; }
.nav-item.active {
    background: var(--nav-active);
    color: var(--brand);
    font-weight: 600;
    box-shadow: inset 3px 0 0 var(--brand);
}
.nav-item svg { width: 17px; height: 17px; flex: 0 0 17px; opacity: 0.8; }
/* Zahl unbestätigter Tischreservierungen am Menüpunkt (live, portal.js initPendingReservations) */
.nav-badge {
    margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px;
    background: var(--brand); color: #fff; font-size: 12px; font-weight: 700; line-height: 20px; text-align: center;
}
.nav-badge[hidden] { display: none; }
.nav-toggle .nav-badge { margin-left: 0; flex: 0 0 auto; }
/* Live-Abfrage angehalten (portal.js initPendingReservations: data-live-state="stopped" nach 4 h ohne Bedienung): Zahl blass +
   Hinweis am Menüpunkt bzw. im mobilen Menü-Knopf — sonst hält man eine stehengebliebene Zahl für aktuell. Bedienung setzt fort. */
.nav-badge[data-live-state="stopped"] { opacity: 0.45; }
.nav-item[data-live-state="stopped"] { flex-wrap: wrap; }
.nav-item[data-live-state="stopped"]::after {
    content: "Live-Anzeige pausiert. Maus bewegen oder tippen zum Fortsetzen";
    flex: 1 0 100%; padding-left: 27px; font-size: 11px; font-weight: 400; line-height: 1.3; color: var(--muted);
}
.nav-toggle[data-live-state="stopped"] .nav-toggle__current::after { content: " · Live pausiert"; color: var(--muted); font-weight: 400; }

/* Kontakt-Box unten in der Sidebar — wie der alte "Fragen?"-Block */
.sidebar-contact {
    margin-top: auto;
    padding: 14px;
    background: var(--bg);
    border-radius: var(--r);
    font-size: 13px;
    color: var(--ink-soft);
}
.sidebar-contact b { color: var(--ink); }
.sidebar-contact img { max-width: 75%; margin-bottom: 6px; }

/* ============================== Main ============================== */

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 30px;
    background: rgba(247, 247, 247, 0.85);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 20;
}
.topbar-title { font-size: 15px; font-weight: 600; color: var(--ink-soft); }
.topbar-user { display: flex; align-items: center; gap: 12px; font-size: 13.5px; }
.topbar-user .who b { display: block; line-height: 1.2; }
.topbar-user .who span { color: var(--muted); font-size: 12px; }
/* Benutzername = Link „Mein Profil“ (Kopfzeile + mobil) */
a.who--link { display: block; color: inherit; padding: 2px 6px; margin: -2px -6px; border-radius: var(--r-sm); }
a.who--link:hover { text-decoration: none; background: var(--bg); }
a.who--link:hover b, a.who--link.active b { color: var(--brand); }

.content { padding: 26px 30px 40px; max-width: 1280px; width: 100%; }

.page-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.page-head h1 { margin: 0; }
.page-sub { color: var(--muted); margin: -10px 0 18px; font-size: 14px; }

/* ============================== Footer (Alt: DisplayFooter) ============================== */

.footer {
    margin-top: auto;
    padding: 18px 30px;
    border-top: 1px solid var(--line);
    font-size: 12.5px;
    color: var(--muted);
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
}
.footer a { color: var(--ink-soft); }
/* Footer auf Login / Passwort vergessen / Fehlerseiten: ohne Linie, mittig unter der Karte */
.auth-main { width: 100%; display: grid; place-items: center; }
.footer--auth { margin-top: 24px; padding: 0; border-top: 0; justify-content: center; text-align: center; }

/* ============================== Karten / Panels ============================== */

.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r);
    box-shadow: var(--shadow-sm);
    padding: 20px 22px;
    margin-bottom: 18px;
}
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.panel-head h2, .panel-head h3 { margin: 0; }

.grid { display: grid; gap: 18px; }
/* min(100%, …): auf schmalen Handys (< 360px) lief eine Spalte sonst über den Rand (Kontakt, Profil) */
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
/* Panels im Grid: Abstand nur über gap (sonst gap + margin-bottom = doppelter Abstand, mobil untereinander auffällig) */
.grid--panels { margin-bottom: 18px; }
.grid--panels > .panel { margin-bottom: 0; min-width: 0; }

.kpi { padding: 16px 20px; }
.kpi .kpi-label { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.kpi .kpi-value { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; margin-top: 4px; }
.kpi .kpi-note { font-size: 12.5px; color: var(--muted); margin-top: 2px; }

/* ============================== Tabellen ============================== */

.tbl-wrap { overflow-x: auto; margin: 0 -22px; padding: 0 22px; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.tbl th {
    text-align: left;
    padding: 9px 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
    border-bottom: 2px solid var(--line);
    white-space: nowrap;
}
table.tbl td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.tbl tbody tr:hover { background: var(--bg); }
table.tbl tbody tr:last-child td { border-bottom: 0; }
/* kurzes Hervorheben einer Zeile (z. B. Liefergebiet: "Bearbeiten" im Karten-Popup) */
@keyframes row-flash { 0%, 35% { background: var(--brand-tint-strong); } 100% { background: transparent; } }
table.tbl tbody tr.row-flash { animation: row-flash 1.8s ease-out; }
@media (prefers-reduced-motion: reduce) { table.tbl tbody tr.row-flash { animation-timing-function: steps(1, end); } }
/* Liefergebiet: Hinweis + "Änderung anfragen" unter der Karte */
.da-note { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 16px; }
/* Liefergebiet: Karten-Popup — Zonenname mit Stift (.op-iconbtn) dahinter */
.da-popup-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.da-popup-head .op-iconbtn { margin-left: 0; top: 0; flex: 0 0 30px; }
/* Ketten-Karte: Knopf im Popup zu den Liefergebieten der Filiale (Stand 2026-10-21); Leaflet färbt Links sonst blau */
.da-popup-actions { margin-top: 10px; }
.leaflet-container .da-popup-actions a.btn { color: var(--ink); }
/* Liefergebiete (Ketten-Bereich): nur die Karte, füllt den sichtbaren Bereich unter der Kopfzeile.
   Beschriftung je Filiale (.da-label) als dauerhafter Leaflet-Tooltip auf der größten Fläche. */
.da-chain { padding: 0; overflow: hidden; }
.da-map { width: 100%; border-radius: var(--r-sm); overflow: hidden; }
.da-map--chain { height: calc(100vh - 190px); min-height: 420px; border-radius: inherit; }
@media (max-width: 960px) { .da-map--chain { height: 70vh; min-height: 360px; } }
.leaflet-tooltip.da-label {
    background: rgba(255, 255, 255, .92); border: 1px solid #CC1236; border-radius: 4px; box-shadow: none;
    color: #282828; font-weight: 600; font-size: 12px; padding: 2px 6px;
}
.leaflet-tooltip.da-label::before { display: none; }
/* Liefergebiet mobil (≤ 720px, Basis .bk-list): zugeklappt Zone-Knopf + Status-Schalter in einer Zeile,
   aufgeklappt zusätzlich Mindestbestellwert/Lieferkosten. Der Name steht im Knopf → Spalte "Zone" entfällt. */
@media (max-width: 720px) {
    table.da-list tr.bk-row { display: flex; flex-wrap: wrap; align-items: center; column-gap: 14px; }
    table.da-list tr.bk-row > td { flex: 1 1 100%; }
    .op-collapsible table.da-list td.op-mtoggle { flex: 1 1 0; min-width: 0; }
    .op-collapsible table.da-list td[data-label="Status"] { display: block !important; flex: 0 0 auto; width: auto; }
    .op-collapsible table.da-list td[data-label="Status"]::before { display: none; }
    .op-collapsible table.da-list td[data-label="Zone"] { display: none !important; }
}
table.tbl .num { text-align: right; font-variant-numeric: tabular-nums; }
table.tbl th.right { text-align: right; }
table.tbl .nowrap { white-space: nowrap; }

/* Label-Wert-Tabellen (Alt: class="values") */
table.kv { width: 100%; border-collapse: collapse; font-size: 14px; }
table.kv td { padding: 9px 12px; border-bottom: 1px solid var(--line); }
table.kv td:first-child { width: 38%; color: var(--muted); font-weight: 500; }
table.kv tr:last-child td { border-bottom: 0; }
/* Mobil (≤ 720px) Beschriftung über dem Wert wie .kv-stack (Kontakt, Profil): sonst bricht die schmale
   Beschriftungsspalte mitten im Wort um ("E-Mail-/Adresse") und lange E-Mails liefen aus dem Panel. Desktop unverändert. */
@media (max-width: 720px) {
    table.kv.kv--mstack, table.kv.kv--mstack tbody, table.kv.kv--mstack tr, table.kv.kv--mstack td { display: block; width: auto; }
    table.kv.kv--mstack tr { padding: 9px 0; border-bottom: 1px solid var(--line); }
    table.kv.kv--mstack tr:first-child { padding-top: 0; }
    table.kv.kv--mstack tr:last-child { border-bottom: 0; padding-bottom: 0; }
    table.kv.kv--mstack td { padding: 0; border-bottom: 0; overflow-wrap: anywhere; }
    table.kv.kv--mstack td:first-child { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 2px; }
}
/* Feldliste mit Beschriftung über dem Wert — für schmale Panels mit langen Werten (Rechnungsdaten: E-Mail, IBAN, Gläubiger-ID).
   Je Eintrag ein <dl class="kv-stack">, mehrere Einträge durch eine Linie getrennt. */
.kv-stack { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px 20px; margin: 0; font-size: 14px; }
.kv-stack > div { min-width: 0; }
.kv-stack .kv-stack__wide { grid-column: 1 / -1; }
.kv-stack dt { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
.kv-stack dd { margin: 2px 0 0; overflow-wrap: anywhere; }
.kv-stack + .kv-stack { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 16px; }
/* Support: Anhänge (Datei-Feld wie .frm-input, Auswahlknopf wie .btn--ghost, Liste der gewählten Dateien) */
.ct-optional { font-weight: 400; color: var(--muted); }
.frm-file { display: block; width: 100%; max-width: 100%; font: inherit; font-size: 14px; color: var(--ink-soft); padding: 6px; border: 1px dashed var(--line-strong); border-radius: 8px; background: var(--surface); }
.frm-file:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.frm-file::file-selector-button { font: inherit; font-weight: 600; margin-right: 10px; padding: 6px 14px; border: 1px solid var(--line-strong); border-radius: 8px; background: #fff; color: var(--ink); cursor: pointer; }
.frm-file::file-selector-button:hover { border-color: var(--ink-soft); }
.ct-files { list-style: none; margin: 8px 0 0; padding: 0; font-size: 13px; color: var(--ink-soft); }
.ct-files__item { display: flex; align-items: center; gap: 8px; padding: 4px 4px 4px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); }
.ct-files__item + .ct-files__item { margin-top: 6px; }
.ct-files__item--bad { border-color: var(--bad); color: var(--bad-text); }
.ct-files__name { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.ct-files__remove { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: var(--muted); cursor: pointer; }
.ct-files__remove:hover { background: var(--bad-bg); color: var(--bad-text); }
.ct-files__remove:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
/* Kontakt: Absender (Name/E-Mail) als Feldliste statt gesperrter Eingabefelder — lange E-Mails brechen um statt abgeschnitten zu werden */
.ct-sender { margin-bottom: 16px; }
/* Support: rechte Spalte = Live-Chat (falls eingeschaltet) über „Direkt erreichen“, Abstand wie .grid--panels */
.ct-side { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.ct-side > .panel { margin-bottom: 0; }
/* Live-Chat (Zammad, portal.js initSupportChat): Chip = Zustand, Statuszeile, Knopf öffnet das Zammad-Fenster unten rechts */
.ct-chat__chip { white-space: nowrap; }
.ct-chat__intro { font-size: 14px; margin-bottom: 8px; }
.ct-chat__status { font-size: 14px; color: var(--ink-soft); margin-bottom: 14px; }
.ct-chat__status:last-child { margin-bottom: 0; }
.ct-chat[data-chat-state="ready"] .ct-chat__status,
.ct-chat[data-chat-state="active"] .ct-chat__status { color: var(--ok-text); }
.ct-chat .open-zammad-chat.zammad-chat-is-hidden { display: none; }

/* ============================== Status / Badges ============================== */

.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 2px 11px;
    border-radius: var(--r-pill);
    font-size: 12px;
    font-weight: 600;
    background: var(--bg);
    color: var(--ink-soft);
}
.chip--ok   { background: var(--ok-bg); color: var(--ok-text); }
.chip--warn { background: var(--warn-bg); color: var(--warn-text); }
.chip--bad  { background: var(--bad-bg); color: var(--bad-text); }
.chip--info { background: var(--info-bg); color: var(--info); }

.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.dot--on  { background: var(--ok); }
.dot--off { background: var(--bad); }
.dot--deak { background: var(--warn); }

.txt-ok { color: var(--ok-text); }
.txt-bad { color: var(--bad-text); }
.txt-warn { color: var(--warn-text); }

/* ============================== Buttons ============================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 20px;
    border-radius: var(--r-pill);
    border: 1px solid transparent;
    background: var(--ink);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background .12s, border-color .12s, color .12s, transform .06s;
}
.btn:hover { background: #000; text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn--brand { background: var(--brand); }
.btn--brand:hover { background: var(--brand-dark); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn--ghost:hover { background: var(--surface); border-color: var(--ink-soft); }
.btn--danger { background: var(--bad); }
.btn--danger:hover { background: var(--bad-dark); }
.btn--sm { padding: 5px 14px; font-size: 13px; }
.btn--block { width: 100%; }

/* ============================== Formulare ============================== */

.frm-row { margin-bottom: 14px; }
.frm-label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 5px; color: var(--ink-soft); }
.frm-input, .frm-select, .frm-textarea {
    width: 100%;
    padding: 9px 13px;
    border: 1px solid var(--line-strong);
    border-radius: var(--r-sm);
    background: var(--surface);
    font-size: 14px;
    font-family: inherit;
    color: var(--ink);
    transition: border-color .12s, box-shadow .12s;
}
.frm-input:focus, .frm-select:focus, .frm-textarea:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-tint);
}
.frm-textarea { min-height: 96px; resize: vertical; }
/* Gesperrtes Eingabefeld (z. B. Support-Betreff, bis eine Betreffkategorie gewählt ist) */
.frm-input:disabled { background: var(--bg); color: var(--muted); cursor: not-allowed; }
.frm-hint { font-size: 12px; color: var(--muted); margin-top: 4px; }

/* Passwortfeld mit Auge (Anmeldung, Passwort ändern): Klartext anzeigen/verbergen, Knopf rechts im Feld */
.frm-pw { position: relative; }
.frm-pw .frm-input { padding-right: 44px; }
.frm-pw .frm-input::-ms-reveal { display: none; } /* Edge: eigenes Auge ausblenden, sonst zwei */
.frm-pw__toggle {
    position: absolute; top: 50%; right: 4px; transform: translateY(-50%);
    display: inline-flex; align-items: center; justify-content: center;
    width: 36px; height: 32px; padding: 0; border: 0; border-radius: var(--r-sm);
    background: transparent; color: var(--muted); cursor: pointer;
}
.frm-pw__toggle:hover { color: var(--ink); }
.frm-pw__toggle:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
.frm-pw__toggle svg { width: 18px; height: 18px; }
.frm-pw__hide { display: none; }
.frm-pw__toggle[aria-pressed="true"] .frm-pw__show { display: none; }
.frm-pw__toggle[aria-pressed="true"] .frm-pw__hide { display: block; }

.alert { padding: 12px 16px; border-radius: var(--r-sm); font-size: 14px; margin-bottom: 16px; }
.alert--error { background: var(--bad-bg); color: var(--bad-text); }
.alert--ok { background: var(--ok-bg); color: var(--ok-text); }
.alert--info { background: var(--info-bg); color: var(--info); }
.alert--warn { background: var(--warn-bg); color: var(--warn-text); }

/* Inline-Edit-Feedback */
.inlineedit { transition: border-color .15s, box-shadow .15s; }
.inlineedit.is-saving { border-color: var(--warn); }
.inlineedit.is-saved  { border-color: var(--ok); box-shadow: 0 0 0 3px var(--ok-bg); }
.inlineedit.is-error  { border-color: var(--bad); box-shadow: 0 0 0 3px var(--bad-bg); }

.toast {
    position: fixed; bottom: 22px; right: 22px; z-index: 999;
    padding: 10px 20px;
    border-radius: var(--r-pill);
    background: var(--ink); color: #fff;
    font-size: 13.5px; font-weight: 600;
    box-shadow: var(--shadow);
    opacity: 0; transform: translateY(8px);
    transition: opacity .2s, transform .2s;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast--error { background: var(--bad); }
.toast--ok { background: var(--ok-text); }
/* Hinweis (z. B. Zeitraum gekürzt): länger sichtbar, darf umbrechen */
.toast--warn { background: var(--warn-text); max-width: min(460px, calc(100vw - 44px)); border-radius: var(--r-sm); line-height: 1.4; }

/* ============================== Auth-Seiten ============================== */

.auth-wrap {
    min-height: 100vh;
    display: grid;
    grid-template-rows: 1fr auto;   /* Karte mittig, Footer unten (seit 2026-10-21 auch auf den Anmeldeseiten) */
    place-items: center;
    padding: 28px;
    background:
        radial-gradient(1100px 500px at 85% -10%, rgba(204, 18, 54, 0.06), transparent 60%),
        var(--bg);
}
.auth-card {
    width: 100%;
    max-width: 440px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 20px;
    box-shadow: var(--shadow);
    padding: 36px 38px 30px;
}
.auth-card .logo { display: block; height: 40px; margin: 0 auto 22px; }
.auth-card h1 { font-size: 21px; text-align: center; margin-bottom: 6px; }
.auth-card .sub { text-align: center; color: var(--muted); font-size: 13.5px; margin-bottom: 22px; }
.auth-links { margin-top: 16px; text-align: center; font-size: 13px; }
.auth-links a { color: var(--ink-soft); }
.auth-card ul { font-size: 13.5px; color: var(--ink-soft); padding-left: 20px; }

/* Captcha „Passwort vergessen“ (CaptchaService, Port von restabloLegacy CaptchaImage): Bild 180×50 + „Neues Bild“ daneben,
   schmal (< 300px) bricht der Knopf unter das Bild */
.captcha { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 8px; }
.captcha__img { display: block; max-width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--r-sm); background: #fff; }
.captcha__input { max-width: 220px; text-transform: uppercase; letter-spacing: 0.15em; }

/* Login-Limit: verbleibende Sperrzeit (Countdown, portal.js initLoginLockCountdown); abgelaufen = grüner Hinweis */
.login-lock { margin-bottom: 16px; font-size: 13.5px; line-height: 1.45; }
.login-lock p { margin: 0; padding: 10px 14px; border-radius: var(--r-sm); }
.login-lock__active { display: flex; gap: 8px; align-items: flex-start; background: var(--warn-bg); color: var(--warn-text); }
.login-lock__icon { flex: none; width: 18px; height: 18px; margin-top: 1px; }
.login-lock__time { font-variant-numeric: tabular-nums; white-space: nowrap; }
.login-lock__done { background: var(--ok-bg); color: var(--ok-text); }

/* ============================== Hilfsmittel ============================== */

.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.right { text-align: right; }
.center { text-align: center; }
.mb-0 { margin-bottom: 0; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 18px; }
.flex { display: flex; gap: 10px; align-items: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wrap { flex-wrap: wrap; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 16px; }
.toolbar .frm-select, .toolbar .frm-input { width: auto; min-width: 170px; }

.empty { padding: 36px 20px; text-align: center; color: var(--muted); font-size: 14px; }

.modal-backdrop {
    position: fixed; inset: 0; z-index: 100;
    background: rgba(40, 40, 40, 0.45);
    display: grid; place-items: center;
    padding: 20px;
}
.modal {
    width: 100%; max-width: 560px; max-height: 86vh; overflow-y: auto;
    background: var(--surface);
    border-radius: var(--r);
    box-shadow: var(--shadow);
    padding: 24px 26px;
}

/* ============================== Responsive ============================== */

@media (max-width: 960px) {
    .shell { flex-direction: column; }
    .sidebar { position: relative; height: auto; flex: none; }
    .sidebar-contact { display: none; }
    .content { padding: 18px 16px 30px; }
    .topbar { padding: 12px 16px; }
    table.kv td:first-child { width: auto; }
}

/* Mobil (Sidebar steht über dem Inhalt): Navigationsmenü einklappbar (portal.js initNavToggle, nur mit JS = .nav-collapsible).
   Logo und Bereichsauswahl bleiben immer sichtbar; der Knopf zeigt nur die aktuelle Seite ("Menü" nur für Screenreader). Desktop: Knopf ausgeblendet. */
.nav-toggle { display: none; }
.nav-toggle svg { width: 18px; height: 18px; flex: 0 0 18px; }
.nav-toggle__current {
    flex: 1 1 auto; min-width: 0; font-weight: 600; color: var(--ink);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.nav-toggle__chev { color: var(--muted); transition: transform .15s; }
.nav-is-open .nav-toggle__chev { transform: rotate(180deg); }
@media (max-width: 960px) {
    .sidebar.nav-collapsible .nav-toggle {
        display: flex; align-items: center; gap: 10px; width: 100%;
        padding: 9px 12px; border: 1px solid var(--line-strong); border-radius: var(--r-sm);
        background: var(--surface); font: inherit; font-size: 14px; font-weight: 600; color: var(--ink);
        text-align: left; cursor: pointer;
    }
    .sidebar.nav-collapsible .nav-toggle:hover { background: var(--bg); }
    .sidebar.nav-is-open .nav-toggle { margin-bottom: 6px; }
    .sidebar.nav-collapsible:not(.nav-is-open) .sidebar-nav { display: none; }
}

/* Mobil: Benutzer + Abmelden oben rechts neben dem Logo (statt in der Kopfzeile). Name/E-Mail kürzen sich mit … */
.sidebar-user { display: none; }
@media (max-width: 960px) {
    .sidebar-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
    .sidebar-head .sidebar-logo { flex: 0 0 auto; padding: 0 0 0 8px; }
    .sidebar-user { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 13.5px; }
    .sidebar-user .who { min-width: 0; }
    .sidebar-user .who b, .sidebar-user .who span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .sidebar-user .who b { line-height: 1.2; }
    .sidebar-user .who span { color: var(--muted); font-size: 12px; }
    .sidebar-user .btn { flex: 0 0 auto; white-space: nowrap; }
    .topbar-user { display: none; }
}

/* hidden-Attribut gewinnt immer — sonst überstimmen Komponenten mit eigenem display
   (z. B. .btn = inline-flex) das Ein-/Ausblenden per JS (Autosave der Öffnungszeiten). */
[hidden] { display: none !important; }

.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }

/* ============================== Heute-Status (Kopfzeile) ============================== */

/* Store-Name + Heute-Status bleiben in einer Zeile: Name kürzt sich (…), Button bleibt direkt daneben */
.topbar-left { display: flex; flex-wrap: nowrap; align-items: center; gap: 12px; min-width: 0; flex: 1 1 auto; }
.topbar-left .topbar-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; flex: 0 1 auto; }
.topbar-user { flex: 0 0 auto; }
.today-status { display: flex; flex-wrap: nowrap; align-items: center; gap: 10px; flex: 0 1 auto; min-width: 0; }
.today-status > * { flex: 0 0 auto; }
.today-status .today-status__msg { flex: 0 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.today-status form { margin: 0; }
.today-status__msg { font-size: 13px; color: var(--ok-text); font-weight: 600; }
.today-status__msg--error { color: var(--bad-text); }

/* ============================== Öffnungszeiten ============================== */

/* Unternavigation (Übersicht / Abweichende Zeiten / Feiertage) als Buttons (.btn), aktiver = .btn--brand */
.op-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }

/* Bestellart-Gruppen (Scope-Leiste) */
.op-segments {
    display: inline-flex; flex-wrap: wrap; gap: 4px;
    margin: 0 0 14px; padding: 4px;
    border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--line);
}
.op-segments__item { padding: 5px 14px; border-radius: var(--r-pill); color: var(--ink-soft); font-size: 13.5px; font-weight: 500; }
.op-segments__item:hover { text-decoration: none; background: var(--bg); color: var(--ink); }
.op-segments__item[aria-current="page"] { background: var(--brand-tint-strong); color: var(--brand); font-weight: 650; }

.op-scope {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
    gap: 8px 16px; margin: 0 0 14px; padding: 12px 16px;
    border-radius: var(--r-sm); background: var(--surface); border: 1px solid var(--line);
}
.op-scope p { margin: 0; }
.op-scope__split { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; color: var(--ink-soft); }
.op-scope__copy { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.op-scope__copy label { color: var(--ink-soft); font-size: 14px; }
.op-scope__copy .frm-select { width: auto; padding: 6px 10px; }

/* Übersicht: ein Block je Gruppe. Getrennte Zeiten stehen nebeneinander, so viele wie passen
   (Mindestbreite 240px je Block); erst wenn der Platz nicht reicht, rutschen Blöcke in die nächste Zeile. */
.op-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
    gap: 12px; margin-bottom: 12px; align-items: start;
}
.op-grid--single { grid-template-columns: minmax(0, 560px); }
.op-block { margin-bottom: 0; min-width: 0; padding: 14px 14px 12px; container-type: inline-size; }
.op-block .panel-head { margin-bottom: 6px; flex-wrap: wrap; gap: 6px 10px; }
.op-block .panel-head .btn { white-space: nowrap; }
.op-block__actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px; margin-left: auto; }
.op-block__actions form { margin: 0; }
/* Block-Kopf: Titel + runder Stift (Bearbeiten, Text per aria-label/title) links, "Für heute schließen" rechtsbündig
   (Text, in schmalen Blöcken – 3 nebeneinander, Handy – als "Heute schließen"). */
/* Titel nimmt den Platz, darf bis aufs letzte Wort + Stift schrumpfen; reicht das nicht, rutscht
   "Heute schließen" in die nächste Zeile (bleibt rechtsbündig) */
.op-block .panel-head { flex-wrap: wrap; }
.op-block .panel-head h2 { flex: 1 1 0; min-width: min-content; }
.op-block__actions { flex-wrap: nowrap; flex: 0 0 auto; }
/* Stift direkt hinter dem letzten Wort des Titels (beide in .op-nowrap, brechen nur gemeinsam um) */
.op-nowrap { white-space: nowrap; }
.op-iconbtn { width: 30px; height: 30px; padding: 0; border-radius: 50%; margin-left: 6px; vertical-align: middle; position: relative; top: -2px; }
.op-iconbtn svg { width: 14px; height: 14px; flex: 0 0 14px; }
.op-closebtn__short { display: none; }
@container (max-width: 460px) {
    .op-closebtn { padding-left: 11px; padding-right: 11px; }
    .op-closebtn__long { display: none; }
    .op-closebtn__short { display: inline; }
}
.op-block .panel-head h2 { font-size: 16px; }

table.op-week { font-size: 13.5px; }
table.op-week th[scope="row"], table.op-week td { padding: 6px 8px; }
table.op-week th[scope="row"] {
    text-transform: none; letter-spacing: 0; font-size: 13.5px; font-weight: 500; color: var(--ink);
    border-bottom: 1px solid var(--line); white-space: nowrap; width: 1%;
}
table.op-week tbody tr:last-child th { border-bottom: 0; }
/* heutiger Tag: Highlight-Grauton (etwas dunkler als der Zeilen-Hover var(--bg)) */
table.op-week .op-is-today, table.op-week .op-is-today:hover { background: var(--highlight); }
table.op-week .op-is-today th[scope="row"] { font-weight: 700; }
table.op-week .chip { padding: 0 7px; font-size: 11px; margin-left: 4px; }
/* Zeitfenster brechen nur ZWISCHEN den Fenstern um, nie mitten in "11:30 – 14:30" */
.op-range { display: inline-block; white-space: nowrap; margin-right: 6px; }
.op-today-line + .op-today-line { margin-top: 6px; }
.op-inline-form { display: inline-block; margin: 6px 0 0; }
.op-inline-alert { margin: 6px 0 0; padding: 6px 8px; }

/* Kommende Abweichungen (nächste 7 Tage): Wochentag | Datum | Zeiten | "ändern" rechts,
   darunter ggf. der Feiertagsname. Je Datum ein <tbody> (Trennlinie zwischen den Tagen). */
.op-upcoming { margin-top: 10px; }
.op-upcoming h3 { margin: 0 0 4px; font-size: 13.5px; }
.op-upcoming__tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.op-upcoming__tbl tbody { border-top: 1px solid var(--line); }
.op-upcoming__tbl tbody:last-child { border-bottom: 1px solid var(--line); }
.op-upcoming__tbl th, .op-upcoming__tbl td { padding: 5px 8px 5px 0; vertical-align: middle; text-align: left; }
.op-upcoming__weekday { font-weight: 600; white-space: nowrap; width: 1%; }
.op-upcoming__date { white-space: nowrap; width: 1%; padding-right: 16px !important; }
.op-upcoming__time { width: auto; }
.op-upcoming__act { text-align: right !important; white-space: nowrap; width: 1%; padding-right: 0 !important; }
.op-upcoming__act .btn--sm { padding: 2px 12px; font-size: 12.5px; }
.op-upcoming__holiday td { padding-top: 0 !important; font-size: 12.5px; color: var(--muted); }
.op-upcoming__more { margin-top: 8px; }
/* Schmale Blöcke (3 Gruppen nebeneinander): Wochentag, Datum, "ändern" in einer Zeile, Zeiten darunter */
@container (max-width: 340px) {
    .op-upcoming__tbl, .op-upcoming__tbl tbody { display: block; }
    .op-upcoming__tbl tbody { padding: 3px 0; }
    .op-upcoming__tbl tr { display: grid; grid-template-columns: auto auto 1fr auto; column-gap: 8px; align-items: center; }
    .op-upcoming__tbl th, .op-upcoming__tbl td { padding: 1px 0 !important; width: auto; }
    .op-upcoming__weekday { grid-column: 1; grid-row: 1; }
    .op-upcoming__date { grid-column: 2; grid-row: 1; }
    .op-upcoming__act { grid-column: 4; grid-row: 1; }
    .op-upcoming__time { grid-column: 1 / -1; grid-row: 2; }
    .op-upcoming__weekday:empty, .op-upcoming__date:empty { display: none; }
    .op-upcoming__holiday td { grid-column: 1 / -1; }
}

/* Startseite (Details): Öffnungszeiten der nächsten 7 Tage — Stift (.op-iconbtn) direkt hinter dem Titel,
   Tabelle wie die Wochentabelle der Übersicht (table.op-week, heutiger Tag grau) plus Datumsspalte. */
.home-week__label { margin: 14px 0 2px; font-size: 13.5px; }
.home-week h2 + .home-week__label { margin-top: 0; }
table.op-week td.home-week__date { width: 1%; white-space: nowrap; color: var(--muted); padding-right: 14px; }
/* Mehrere Bestellarten (Stand 2026-10-21): eine Tabelle mit je einer Spalte pro Bestellart(en-Gruppe); passt sie nicht in die
   Karte (schmal, Handy), stattdessen die Einzeltabellen untereinander (.home-week__stack) */
.home-week { container-type: inline-size; }
/* Markierungen (Stand 2026-10-21): Feiertagsname klein unter dem Wochentag, Chip „abweichend“/„automatisch“ hinter der Zeit */
.home-week__holiday { display: block; font-size: 11.5px; font-weight: 400; color: var(--muted); white-space: normal; }
table.op-week .home-week__chip { margin-left: 6px; white-space: nowrap; }
.home-week__stack { display: none; }
/* Die Karte ist im 3-Spalten-Raster nur ~340–400px breit → bei mehreren Bestellarten über 2 Spalten (sobald das Raster ≥ 2 Spalten hat:
   2 × 320px + 18px Abstand); dense füllt die Lücke (bei 2 Spalten: Bestellzustellung neben Store Daten, Öffnungszeiten darunter) */
.home-grid { container-type: inline-size; align-items: start; }   /* Karten nicht auf gleiche Höhe strecken */
.home-grid--single { grid-template-columns: minmax(0, 640px); }  /* Kette: nur eine Karte, nicht über die ganze Seite */
.home-grid--multi { grid-auto-flow: row dense; }
@container (min-width: 658px) {
    .home-grid--multi > .home-week { grid-column: span 2; }
}
/* nur 2 Spalten (unter 3 × 320 + 2 × 18 px): Store Daten allein in der ersten Zeile wäre halb leer → volle Breite */
@container (min-width: 658px) and (max-width: 995px) {
    .home-grid--multi > .home-data { grid-column: 1 / -1; }
}
table.op-week.home-week__matrix thead th { padding: 0 8px 6px; font-size: 12px; font-weight: 600; color: var(--muted); text-align: left; vertical-align: bottom; white-space: normal; }
@container (max-width: 419px) {
    .home-week__matrix { display: none; }
    .home-week__stack { display: block; }
}
/* „Daten korrigieren?“ unten in der Daten-Karte (Partial _DataFix; Store, Kette, Partner — Stand 2026-10-21): eine Zeile, durch eine
   Linie abgesetzt — Text und Knopf „Support kontaktieren“ zusammen als rechtsbündiger Block (sehr schmal: Knopf darunter, ebenfalls rechts) */
.home-fix { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px 12px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.home-fix__title { font-size: 14px; font-weight: 600; color: var(--ink-soft); }
.home-fix .btn { flex: none; }
/* Mein Profil (Stand 2026-10-21): Zeile „Passwort“ = Änderungsdatum links, Knopf „Passwort ändern“ rechts (schmal darunter) */
.profile-pw { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; }
/* Schnittstelle in „Store Daten“ (vorher Karte „Bestellzustellung“): mehrere untereinander */
.home-send + .home-send { margin-top: 6px; }
/* Partner-Startseite (Stand 2026-10-12): mehrzeilige Adresse, Karte „Stores“ = Anzahl je Status, Zahl rechtsbündig */
.home-address { white-space: pre-line; }
.home-partner table.kv td { overflow-wrap: anywhere; } /* lange E-Mail bricht um statt aus der Karte zu laufen */
@media (min-width: 721px) { .home-partner table.kv td:first-child { width: 1%; white-space: nowrap; padding-right: 24px; } }
table.kv.home-stores__tbl td:first-child { width: auto; color: var(--ink-soft); }
table.kv.home-stores__tbl td:first-child .dot { margin-right: 6px; }
table.kv.home-stores__tbl td:last-child { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
table.kv.home-stores__tbl tr:nth-last-child(2) td { border-bottom: 0; }
table.kv.home-stores__tbl tr.home-stores__sum td { border-top: 2px solid var(--line); font-weight: 700; color: var(--ink); }

/* Bearbeiten-Tabellen (regelmäßige / abweichende Zeiten / Feiertage) */
table.op-edit th[scope="row"] {
    text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 650; color: var(--ink);
    border-bottom: 1px solid var(--line); white-space: nowrap;
}
table.op-edit select, table.op-edit input[type="date"], .op-timerange input {
    font: inherit; font-size: 14px; padding: 6px 9px;
    border: 1px solid var(--line-strong); border-radius: var(--r-sm);
    background: var(--surface); color: var(--ink);
}
table.op-edit select:focus, table.op-edit input:focus {
    outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint);
}
.op-timerange { display: inline-flex; align-items: center; gap: 6px; }
.op-timerange input { width: 6.6rem; }
table.op-edit td, table.op-edit th { padding-left: 8px; padding-right: 8px; }
table.op-edit tbody tr:last-child th { border-bottom: 0; }

/* Zeiten ausgegraut, wenn der Tag geschlossen ist / "wie an Feiertagen" (Werte bleiben erhalten) */
.op-row:has(input[data-open-toggle]:not(:checked)) .op-timerange,
.op-row:has(option[value="closed"]:checked) .op-timerange,
.op-row:has(option[value="clos"]:checked) .op-timerange,
.op-row:has(option[value="norm"]:checked) .op-timerange { opacity: .35; }

.op-switch, .op-check { display: inline-flex; align-items: center; gap: 7px; cursor: pointer; font-size: 14px; }
.op-switch input, .op-check input { width: 17px; height: 17px; accent-color: var(--brand); }
/* "Geöffnet" als Schiebeschalter (Checkbox mit role="switch"): grau = geschlossen, Markenrot = geöffnet */
.op-switch input[data-open-toggle] {
    -webkit-appearance: none; appearance: none; position: relative; flex: 0 0 38px;
    width: 38px; height: 22px; margin: 0; border-radius: var(--r-pill);
    background: var(--line-strong); cursor: pointer; transition: background .15s;
}
.op-switch input[data-open-toggle]::before {
    content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%;
    background: var(--surface); box-shadow: 0 1px 2px rgba(0, 0, 0, .25); transition: transform .15s;
}
.op-switch input[data-open-toggle]:checked { background: var(--brand); }
.op-switch input[data-open-toggle]:checked::before { transform: translateX(16px); }
.op-switch input[data-open-toggle]:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
/* Spalte "Geöffnet": Kästchen (und Überschrift) mittig; mobil (Karten) wieder linksbündig, siehe unten */
table.op-edit .op-col-open { text-align: center; width: 1%; white-space: nowrap; }
/* "Gilt für" der neuen abweichenden Zeit: ein Kästchen je Bestellart */
.op-types { display: inline-flex; flex-wrap: wrap; gap: 4px 12px; }
.op-check--sm { font-size: 13px; gap: 5px; white-space: nowrap; }
.op-check--sm input { width: 15px; height: 15px; }
.op-check input:disabled + span { color: var(--muted); }

table.op-edit tbody tr.op-row > td, table.op-edit tbody tr.op-row > th { transition: background-color .4s ease; }
table.op-edit tr.op-row--new > td { background: var(--bg); }
table.op-edit tr.op-has-error > td, table.op-edit tr.op-has-error > th { background: var(--bad-bg); }
table.op-edit tr.op-row-error td { padding-top: 2px; color: var(--bad-text); font-size: 13px; font-weight: 600; }
table.op-edit tr.op-is-saving > td, table.op-edit tr.op-is-saving > th { opacity: .7; }
table.op-edit tr.op-is-saved > td, table.op-edit tr.op-is-saved > th { background: var(--ok-bg); }
table.op-edit tr.op-row:target > td, table.op-edit tr.op-row:target > th { background: var(--warn-bg); }
table.op-edit tr.op-row:target { scroll-margin-top: 90px; }
.op-empty { padding: 22px 12px; text-align: center; }
/* Feiertage: ein tbody je Feiertag (mehrere Zeilen = unterschiedliche Regeln je Bestellart) */
table.op-holiday tbody.op-holiday__block { border-top: 2px solid var(--line); }
table.op-holiday tbody.op-holiday__block tr.op-row > td, table.op-holiday tbody.op-holiday__block tr.op-row > th { border-bottom: 0; }
table.op-holiday tbody.op-holiday__block tr.op-row + tr.op-row > td,
table.op-holiday tbody.op-holiday__block tr.op-row + tr.op-row > th { padding-top: 0; }
.op-holiday__reset { white-space: nowrap; text-align: right; width: 1%; }
.op-holiday__type { white-space: nowrap; font-weight: 500; }
/* "Feiertagszeit": Hinweis (Standardfall) bzw. klickbares Label mit Pfeil (eigene Regel → zurücksetzen), gleiche Größe */
.op-default-label, .op-reset {
    display: inline-flex; align-items: center; gap: 4px;
    font: inherit; font-size: 11.5px; line-height: 1.4; padding: 2px 8px;
    border: 1px solid transparent; border-radius: var(--r-pill);
}
.op-default-label { color: var(--muted); background: var(--bg); }
.op-reset { border-color: var(--line-strong); background: var(--surface); color: var(--ink-soft); cursor: pointer; }
.op-reset__icon { font-size: 14px; line-height: 1; }
.op-reset:hover, .op-reset:focus-visible { border-color: var(--brand); color: var(--brand); background: var(--brand-tint); }

/* Abweichende Zeiten: Entfernen als runder Mülleimer-Icon-Knopf */
.op-trash {
    display: inline-flex; align-items: center; justify-content: center;
    width: 30px; height: 30px; padding: 0; border-radius: 50%;
    border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink-soft); cursor: pointer;
}
.op-trash svg { width: 15px; height: 15px; }
/* letzte Spalte (Hinzufügen / Mülleimer) rechtsbündig – auch mobil */
table.op-edit td.op-special__action { text-align: right; white-space: nowrap; width: 1%; }
@media (max-width: 720px) { table.op-edit td.op-special__action { width: 100%; } }
.op-trash:hover, .op-trash:focus-visible { border-color: var(--bad); color: var(--bad); }
.op-trash[hidden] { display: none !important; }

.op-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 16px; }

/* Abweichende Zeiten, neue Zeile: Zeitraum von–bis. Ohne JS zwei Datumsfelder (.op-daterange__inputs),
   mit JS (html.has-rangepicker) nur der Knopf, der den Kalender .op-cal öffnet (portal.js initRangePicker). */
.op-daterange { display: inline-block; }
.op-daterange__inputs { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.op-daterange__btn {
    display: none; align-items: center; gap: 8px; min-height: 34px; padding: 6px 11px;
    font: inherit; font-size: 14px; color: var(--ink); white-space: nowrap; text-align: left;
    border: 1px solid var(--line-strong); border-radius: var(--r-sm); background: var(--surface); cursor: pointer;
}
.op-daterange__btn svg { width: 16px; height: 16px; flex: 0 0 16px; color: var(--muted); }
.op-daterange__btn:hover, .op-daterange__btn[aria-expanded="true"] { border-color: var(--brand); }
.op-daterange__btn:focus-visible { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint); }
.op-daterange:not(.op-daterange--set) [data-range-label] { color: var(--muted); }
.has-rangepicker .op-daterange__btn { display: inline-flex; }
.has-rangepicker .op-daterange__inputs { display: none; }

.op-cal {
    position: absolute; z-index: 60; width: 300px; max-width: calc(100vw - 16px); padding: 12px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow);
    font-size: 14px; color: var(--ink);
}
.op-cal__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.op-cal__title { font-weight: 650; }
.op-cal__nav {
    display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0;
    border: 1px solid var(--line-strong); border-radius: 50%; background: var(--surface); color: var(--ink-soft); cursor: pointer;
}
.op-cal__nav svg { width: 16px; height: 16px; }
.op-cal__nav:hover:not(:disabled), .op-cal__nav:focus-visible { border-color: var(--brand); color: var(--brand); outline: none; }
.op-cal__nav:disabled { opacity: .35; cursor: default; }
.op-cal__grid { display: grid; grid-template-columns: repeat(7, 1fr); row-gap: 2px; }
.op-cal__wd { padding: 4px 0; text-align: center; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.op-cal__day {
    position: relative; height: 36px; padding: 0; border: 0; border-radius: var(--r-sm); background: none;
    font: inherit; font-size: 14px; color: var(--ink); cursor: pointer;
}
.op-cal__day:hover:not(:disabled):not(.is-in) { background: var(--highlight); }
.op-cal__day:disabled { color: var(--line-strong); cursor: default; }
.op-cal__day.is-today { font-weight: 700; box-shadow: inset 0 0 0 1px var(--line-strong); }
.op-cal__day.is-in { border-radius: 0; background: var(--brand-tint-strong); }
.op-cal__day.is-start, .op-cal__day.is-end { background: var(--brand); color: #fff; font-weight: 650; box-shadow: none; }
.op-cal__day.is-start { border-radius: var(--r-sm) 0 0 var(--r-sm); }
.op-cal__day.is-end { border-radius: 0 var(--r-sm) var(--r-sm) 0; }
.op-cal__day.is-start.is-end { border-radius: var(--r-sm); }
.op-cal__day:focus-visible { z-index: 1; outline: 2px solid var(--brand); outline-offset: -2px; }
.op-cal__day.is-start:focus-visible, .op-cal__day.is-end:focus-visible { outline-color: var(--ink); }
/* Punkt = an diesem Tag gibt es schon einen Eintrag */
.op-cal__day.is-taken::after {
    content: ""; position: absolute; left: 50%; bottom: 4px; width: 4px; height: 4px; margin-left: -2px;
    border-radius: 50%; background: var(--warn);
}
.op-cal__day.is-start.is-taken::after, .op-cal__day.is-end.is-taken::after { background: #fff; }
/* Vorschau über der Höchstzahl Tage ([data-range-max-days]): diese Tage fallen beim Klick weg */
.op-cal__day.is-over { color: var(--warn-text); text-decoration: line-through; }
.op-cal__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 8px; font-size: 12.5px; color: var(--muted); }
.op-cal__done {
    padding: 4px 12px; border: 1px solid var(--line-strong); border-radius: var(--r-pill); background: var(--surface);
    font: inherit; font-size: 13px; color: var(--ink); cursor: pointer;
}
.op-cal__done:hover, .op-cal__done:focus-visible { border-color: var(--brand); color: var(--brand); outline: none; }
@media (max-width: 720px) {
    .op-daterange, .op-daterange__btn { width: 100%; }
    .op-daterange__inputs input { flex: 1; min-width: 0; }
}

/* Statuszeile über den automatisch speichernden Tabellen */
.op-autosave-status { margin: 0 0 10px; font-size: 13px; color: var(--muted); }
.op-autosave-status--ok { color: var(--ok-text); }
.op-autosave-status--error { color: var(--bad-text); font-weight: 600; }

@media (max-width: 960px) {
    .topbar { flex-wrap: wrap; }
}

/* Schmale Bildschirme: Bearbeiten-Tabellen als Karten (Beschriftung aus data-label) */
@media (max-width: 720px) {
    table.op-edit thead { display: none; }
    table.op-edit, table.op-edit tbody, table.op-edit tr, table.op-edit th, table.op-edit td { display: block; width: 100%; }
    table.op-edit tr.op-row { padding: 10px 0; border-bottom: 1px solid var(--line); }
    table.op-edit th[scope="row"] { border: 0; padding: 4px 0; }
    table.op-edit td { border: 0; padding: 4px 0; }
    table.op-edit td.op-col-open { text-align: left; width: 100%; }
    table.op-edit td[data-label]::before {
        content: attr(data-label); display: block; margin-bottom: 3px;
        font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted);
    }
    .op-timerange { width: 100%; }
    .op-timerange input { flex: 1; width: auto; min-width: 0; }
    table.op-edit select, table.op-edit input[type="date"] { width: 100%; }
}

/* Mobil: Kärtchen auf-/zuklappen (Abweichende Zeiten, Feiertage; portal.js initCollapse, nur mit JS = .op-collapsible).
   Zugeklappt sieht man nur das Datum; die neue Zeile zeigt nur das Datumsfeld, bis ein Tag eingegeben ist. */
table.op-edit td.op-mtoggle, table.op-edit tr.op-mtoggle-row { display: none; }
.op-mtoggle__btn {
    display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%;
    padding: 4px 0; border: 0; background: none; font: inherit; font-size: 15px; font-weight: 600;
    color: var(--ink); text-align: left; cursor: pointer;
}
.op-mtoggle__sub { display: block; font-size: 13px; font-weight: 400; color: var(--muted); }
.op-mtoggle__btn svg { width: 18px; height: 18px; flex: 0 0 18px; color: var(--muted); transition: transform .15s; }
.op-is-open .op-mtoggle__btn svg { transform: rotate(180deg); }
@media (max-width: 720px) {
    .op-collapsible table.op-edit td.op-mtoggle { display: block; }
    .op-collapsible table.op-edit tr.op-mtoggle-row { display: block; padding: 10px 0 6px; }
    .op-collapsible table.op-edit tr.op-mtoggle-row > td { padding: 0; }
    .op-collapsible table.op-edit tr[data-autosave-new] > td.op-mtoggle { display: none; }
    .op-collapsible table.op-edit tr[data-mcollapse-item]:not([data-autosave-new]):not(.op-is-open) > td:not(.op-mtoggle),
    .op-collapsible table.op-edit tr[data-autosave-new]:not(.op-has-date) > td:not(.op-col-date),
    .op-collapsible table.op-edit tbody[data-mcollapse-item]:not(.op-is-open) > tr:not(.op-mtoggle-row) { display: none; }
    /* Feiertage: Name + Datum stehen im Knopf, die Zeilenüberschrift wäre doppelt */
    .op-collapsible table.op-holiday th[scope="row"] { display: none; }
}

/* nur für Screenreader sichtbar */
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ============================== Tischreservierungen (/reservations) ============================== */

/* Übersicht: "Heute" getrennt von den nächsten 7 Tagen */
.bk-overview { display: flex; flex-wrap: wrap; gap: 10px 28px; margin-bottom: 16px; }
.bk-overview__group { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.bk-overview__label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
a.bk-chip { padding: 4px 12px; font-size: 12.5px; border: 1px solid var(--line); }
a.bk-chip:hover { text-decoration: none; border-color: var(--line-strong); }
a.bk-chip.chip--info { border-color: var(--ink-soft); color: var(--ink); }
/* Bestätigen + Ablehnen nebeneinander (Tischreservierungen) */
.bk-action form + form { margin-left: 6px; }

/* Formular "Manuelle Reservierung": Datum (Kalender wie Öffnungszeiten), Uhrzeit (Stunde : Minute), Personen —
   alle drei gleich hoch wie .frm-input */
.bk-form .bk-field { display: flex; width: 100%; }
.bk-form .op-daterange__btn { width: 100%; height: 40px; padding: 0 13px; }
html:not(.has-rangepicker) .bk-form .op-daterange__inputs { display: flex; width: 100%; }

.bk-time {
    align-items: center; gap: 2px; height: 40px; padding: 0 8px 0 13px;
    border: 1px solid var(--line-strong); border-radius: var(--r-sm); background: var(--surface);
    transition: border-color .12s, box-shadow .12s;
}
.bk-time:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint); }
.bk-time__icon { width: 16px; height: 16px; flex: 0 0 16px; margin-right: 6px; color: var(--muted); }
.bk-time select {
    -webkit-appearance: none; appearance: none; width: 2.8em; padding: 4px 0;
    border: 0; border-radius: 4px; background: transparent; cursor: pointer;
    font: inherit; font-size: 14px; font-variant-numeric: tabular-nums; color: var(--ink); text-align: center; text-align-last: center;
}
.bk-time select:hover:not(:disabled) { background: var(--highlight); }
.bk-time select:focus { outline: none; background: var(--brand-tint); }
.bk-time select:disabled { color: var(--muted); cursor: default; }
.bk-time__sep { font-weight: 650; color: var(--ink-soft); }

.bk-stepper { position: relative; }
.bk-stepper input { height: 40px; }
.bk-stepper--js input { padding-right: 42px; -moz-appearance: textfield; appearance: textfield; }
.bk-stepper--js input::-webkit-outer-spin-button, .bk-stepper--js input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.bk-stepper input:invalid:not(:placeholder-shown) { border-color: var(--bad); }
.bk-stepper__btns {
    position: absolute; top: 1px; right: 1px; bottom: 1px; width: 32px; display: flex; flex-direction: column;
    border-left: 1px solid var(--line); border-radius: 0 var(--r-sm) var(--r-sm) 0; overflow: hidden;
}
.bk-stepper__btns[hidden] { display: none; }
.bk-stepper__btns button {
    flex: 1; display: flex; align-items: center; justify-content: center; padding: 0;
    border: 0; background: var(--surface); color: var(--ink-soft); cursor: pointer;
}
.bk-stepper__btns button + button { border-top: 1px solid var(--line); }
.bk-stepper__btns button:hover { background: var(--highlight); color: var(--brand); }
.bk-stepper__btns svg { width: 14px; height: 14px; }

/* Listen (Zur Bestätigung / Tagesansicht): Desktop Tabelle, mobil Kärtchen wie die abweichenden Öffnungszeiten.
   Mit JS (.op-collapsible, portal.js initCollapse) zugeklappt nur .op-mtoggle (Zeit · Name / Plätze).
   Auch von der Bestellliste genutzt (/orders: table.bk-list.or-list, Ergänzung unten bei .or-list). */
table.bk-list td.op-mtoggle { display: none; }
.op-mtoggle__sub .chip { margin-left: 4px; padding: 0 8px; font-size: 11px; }
@media (max-width: 720px) {
    table.bk-list thead { display: none; }
    table.bk-list, table.bk-list tbody, table.bk-list tr, table.bk-list td { display: block; width: 100%; }
    table.bk-list tbody tr:hover { background: none; }
    table.bk-list tr.bk-row { padding: 10px 0; border-bottom: 1px solid var(--line); }
    table.bk-list tbody tr.bk-row:last-child { border-bottom: 0; }
    table.bk-list td { border: 0; padding: 4px 0; text-align: left; }
    table.bk-list td.num { text-align: left; }
    table.bk-list td[data-label]::before {
        content: attr(data-label); display: block; margin-bottom: 3px;
        font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted);
    }
    table.bk-list td.bk-action { text-align: right; }
    .op-collapsible table.bk-list td.op-mtoggle { display: block; }
    .op-collapsible table.bk-list tr[data-mcollapse-item]:not(.op-is-open) > td:not(.op-mtoggle) { display: none; }
    /* Uhrzeit, Plätze und Name stehen schon im Knopf */
    .op-collapsible table.bk-list td[data-label="Uhrzeit"],
    .op-collapsible table.bk-list td[data-label="Plätze"],
    .op-collapsible table.bk-list td[data-label="Name"] { display: none !important; }
    /* Bestellungen: Zeit, Typ und Nummer stehen ebenfalls im Knopf */
    .op-collapsible table.or-list td[data-label="Zeit"],
    .op-collapsible table.or-list td[data-label="Typ"],
    .op-collapsible table.or-list td[data-label="Nummer"] { display: none !important; }
    /* Gutscheine: Code, Wert, Name und Status stehen im Knopf, aufgeklappt nur der Rest */
    .op-collapsible table.vc-list td[data-label="Code"],
    .op-collapsible table.vc-list td[data-label="Wert"],
    .op-collapsible table.vc-list td[data-label="Name"],
    .op-collapsible table.vc-list td[data-label="Status"] { display: none !important; }
    /* Kette/Filialen: Filiale, Adresse und Status stehen im Knopf, aufgeklappt Nr., Online seit + Knöpfe */
    .op-collapsible table.sl-list td[data-label="Filiale"],
    .op-collapsible table.sl-list td[data-label="Store"],
    .op-collapsible table.sl-list td[data-label="Adresse"],
    .op-collapsible table.sl-list td[data-label="Status"] { display: none !important; }
    table.sl-list td.sl-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; white-space: normal; }
    .op-collapsible table.sl-list tr[data-mcollapse-item]:not(.op-is-open) > td.sl-actions { display: none; }
    /* Rechnungen: Nummer, Gesamt, Status und Zeitraum stehen im Knopf, aufgeklappt Datum, Netto, Brutto + Download */
    .op-collapsible table.iv-list td[data-label="Nummer"],
    .op-collapsible table.iv-list td[data-label="Zeitraum"],
    .op-collapsible table.iv-list td[data-label="Gesamt"],
    .op-collapsible table.iv-list td[data-label="Status"] { display: none !important; }

    /* Formular wie die neue Zeile der abweichenden Zeiten: Beschriftungen klein in Großbuchstaben, Knopf rechts,
       ohne gewählten Tag nur das Datum */
    .bk-form .grid { gap: 0; }
    .bk-form .frm-row { margin-bottom: 10px; }
    .bk-form .frm-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 3px; }
    .bk-submit { display: flex; justify-content: flex-end; }
    .bk-submit .btn { padding: 5px 14px; font-size: 13px; }
    .bk-form--nodate .frm-row:not(.bk-date-row), .bk-form--nodate .bk-submit { display: none; }
}
.bk-time.bk-time--error { border-color: var(--bad); }
.frm-hint--error { color: var(--bad-text); font-weight: 600; }
/* Warnhinweis am Feld (Tischreservierung: Telefon/E-Mail) — blockiert das Absenden nicht */
.frm-hint--warn { color: var(--warn-text); font-weight: 600; }
.frm-input.frm-input--warn { border-color: var(--warn); }

/* ============================== Statistik (/statistics, Stand 2026-10-06) ==============================
   Kennzahlen-Kacheln oben, darunter schlanke Tabellen (max. 3 Spalten) ohne horizontales Scrollen:
   Nebenwerte (Ø, Online-Anteil, Art.-Nr., Top-Produkte) als graue Zeile .st-sub, "€" nur im Spaltenkopf. */
.st-kpi-title { margin: -6px 0 10px; font-size: 14px; }
.st-kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.st-kpis .kpi { padding: 14px 16px; }
.st-kpis > .panel { margin-bottom: 0; }
.st-kpis .kpi-value { font-size: 23px; font-variant-numeric: tabular-nums; white-space: nowrap; }
/* Kacheln einer Reihe teilen sich die Zeilen (subgrid): bricht eine Beschriftung um („Online-Umsatzanteil“),
   stehen die Werte trotzdem auf einer Linie. Ohne subgrid-Unterstützung normale Kacheln. */
@supports (grid-template-rows: subgrid) {
    .st-kpis { grid-auto-rows: auto; }
    .st-kpis > .kpi { grid-row: span 3; display: grid; grid-template-rows: subgrid; row-gap: 0; }
    .st-kpis .kpi-label { align-self: end; }
}

.st-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); margin-bottom: 18px; }
.st-grid > .panel { margin-bottom: 0; min-width: 0; }

table.st-tbl th, table.st-tbl td { padding: 7px 10px; }
table.st-tbl td.num { white-space: nowrap; }
table.st-tbl .st-val { display: block; font-weight: 600; }
table.st-tbl .st-sub { display: block; margin-top: 1px; font-size: 12px; font-weight: 400; color: var(--muted); white-space: normal; }
table.st-tbl .st-sub > span { white-space: nowrap; } /* Umbruch nur zwischen den Teilen (Ø · online) */
@media (min-width: 721px) { table.st-tbl td.num .st-sub { white-space: nowrap; } } /* Desktop: Nebenzeile der Zahl einzeilig, die Textspalte bricht um */
table.st-tbl .st-top {
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden;
}

/* Scrollboxen mit festem Tabellenkopf (Rahmen per Schatten, weil collapsed borders nicht mitwandern) */
.st-scroll { max-height: 440px; overflow-y: auto; }
.st-scroll thead th { position: sticky; top: 0; z-index: 1; background: var(--surface); border-bottom: 0; box-shadow: inset 0 -2px 0 var(--line); }

/* Kette: „Umsatz nach Filiale“ — Monatskalender rechts im Panel-Kopf (bricht schmal unter die Überschrift).
   Jede Filiale = tbody.st-item; mit JS (.op-collapsible, portal.js initCollapse) klappt der Name (button.st-toggle)
   auf allen Breiten die Zeile .st-detail mit den Top-Gerichten auf. Ohne JS ist alles offen, kein Pfeil. */
.st-panel-head { flex-wrap: wrap; }
.st-panel-head .frm-select { width: auto; padding: 6px 10px; }
.st-panel-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.st-panel-tools .btn { min-height: 32px; }
@media (max-width: 720px) { .st-panel-tools .op-daterange, .st-panel-tools .op-daterange__btn { width: auto; } }
.st-month .op-daterange__btn { min-height: 32px; padding: 5px 11px; font-size: 13.5px; }
table.st-chain tbody.st-item > tr > td { border-bottom: 0; }
table.st-chain tbody.st-item { border-bottom: 1px solid var(--line); }
table.st-chain tbody.st-item:last-child { border-bottom: 0; }
table.st-chain tbody.st-item:hover { background: var(--bg); }
table.st-chain tbody tr:hover { background: none; }
.st-toggle {
    display: inline-flex; align-items: flex-start; gap: 6px; padding: 0; border: 0; background: none;
    font: inherit; color: inherit; text-align: left; cursor: pointer;
}
.st-toggle svg { display: none; width: 16px; height: 16px; flex: 0 0 16px; margin-top: 2px; color: var(--muted); transition: transform .15s; }
.op-collapsible .st-toggle svg { display: block; }
.op-collapsible .st-toggle--none { padding-left: 22px; } /* ohne Top-Gerichte: Name bündig mit den Klappzeilen */
.op-is-open .st-toggle svg { transform: rotate(90deg); color: var(--brand); }
.st-toggle:hover strong, .st-toggle:focus-visible strong { color: var(--brand); }
.st-toggle:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 3px; }
.op-collapsible tbody.st-item:not(.op-is-open) > tr.st-detail { display: none; }
table.st-chain tr.st-detail > td { padding-top: 0; padding-bottom: 10px; }
.op-collapsible table.st-chain tr.st-detail > td { padding-left: 32px; }
.st-detail__label { display: block; margin-bottom: 3px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.st-toplist { margin: 0; padding-left: 20px; font-size: 13px; }
.st-toplist li { padding: 1px 0; }
.st-toplist .st-sku { color: var(--muted); font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: reduce) { .st-toggle svg { transition: none; } }

/* Store-Bild in den Listen von Kette und Partner (/branches, /storelist, Stand 2026-10-13, wie Alt WSeite_StoreList_*: Übersichts-Logo vom CDN).
   Quadrat mit weißem Grund und Rahmen, Bild eingepasst (contain); fehlt das Bild oder lädt es nicht (img wird entfernt), bleibt das
   Laden-Symbol als Platzhalter. Mobil steht das kleine Bild (.sl-logo--sm) im Kärtchen-Knopf vor dem Namen. */
.sl-logo {
    position: relative; display: inline-block; flex: 0 0 auto; width: 48px; height: 48px; overflow: hidden;
    border: 1px solid var(--line); border-radius: var(--r-sm); background: #fff center / 22px no-repeat
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23C9C9C9' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l1.5-5h15L21 9'/%3E%3Cpath d='M3 9h18v2a3 3 0 0 1-6 0 3 3 0 0 1-6 0 3 3 0 0 1-6 0z'/%3E%3Cpath d='M5 13v8h14v-8M10 21v-5h4v5'/%3E%3C/svg%3E");
}
.sl-logo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #fff; }
.sl-logo--sm { width: 40px; height: 40px; background-size: 18px; }
.sl-store { display: flex; align-items: center; gap: 12px; min-width: 0; }
.sl-store > div { min-width: 0; }
/* Desktop: Bild + Name nicht zu schmal quetschen; dafür stehen „Als Store öffnen“ / „Bestellseite“ untereinander (sonst lief die Tabelle über) */
@media (min-width: 721px) {
    table.sl-list .sl-store { min-width: 190px; }
    table.sl-list td.sl-actions { white-space: normal; width: 1%; }
    table.sl-list td.sl-actions .btn { display: flex; width: max-content; margin: 3px 0 3px auto; }
}
table.sl-list .sl-mtitle { flex: 1 1 auto; min-width: 0; }
/* Google-Suche (wie Alt: Symbol hinter dem Namen, „Name, Straße, Ort“). Mobil steht der Name im Kärtchen-Knopf → dort Knopf bei den Aktionen. */
.sl-google { display: inline-flex; vertical-align: -2px; margin-left: 6px; padding: 1px; border-radius: 3px; opacity: .85; }
.sl-google:hover, .sl-google:focus-visible { opacity: 1; }
.sl-google img { display: block; width: 15px; height: 15px; }
@media (min-width: 721px) { table.sl-list td.sl-actions .btn.sl-google-btn { display: none; } }
/* Knopf nur mobil sichtbar: Bild links, Text füllt, Pfeil rechts */
table.sl-list .op-mtoggle__btn { justify-content: flex-start; }

/* Partner-Statistik (/statistics, bis 2026-10-15 „Umsatz“ /storeturnover, Stand 2026-10-12): Aufbau wie „Umsatz nach Filiale“, aber ohne Klappzeilen.
   Unter dem Namen Nr. · online seit, ggf. Chip „inaktiv“ und Vertragsende; Zeilen ohne Bestellungen grau. */
table.st-turnover .st-chip { margin-left: 4px; padding: 0 7px; font-size: 11px; vertical-align: 1px; }
table.st-turnover .st-contract { white-space: nowrap; margin-left: 4px; }
table.st-turnover tr.st-turnover__none .st-val { color: var(--muted); font-weight: 400; }

/* Monatskalender (portal.js initMonthPicker): .op-cal mit 3×4 Monaten, Jahr blättern; Monate ohne Daten-Option gesperrt */
.op-cal__grid--months { grid-template-columns: repeat(3, 1fr); gap: 4px; }
.op-cal__grid--months .op-cal__day { height: 40px; }
.op-cal__grid--months .op-cal__day.is-sel { background: var(--brand); color: #fff; font-weight: 650; box-shadow: none; }
.op-cal__grid--months .op-cal__day.is-sel:focus-visible { outline-color: var(--ink); }

@media (max-width: 720px) {
    .st-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .st-kpis .kpi { padding: 12px 14px; }
    .st-kpis .kpi-value { font-size: 20px; }
    .st-scroll { max-height: 380px; }
    table.st-tbl th, table.st-tbl td { padding: 7px 6px; }
}

/* ============================== Gutscheine (/coupons, Stand 2026-10-07) ==============================
   Formular: Gültigkeit = Zeitraum-Knopf wie bei den abweichenden Öffnungszeiten (ohne Tageslimit), so hoch wie .frm-input.
   Rabatt = Wertfeld + angehängter Umschalter %/€ (Radio-Knöpfe als Segmente). */
.vc-form .op-daterange { display: flex; width: 100%; }
.vc-form .op-daterange__btn { width: 100%; height: 40px; padding: 0 13px; }
html:not(.has-rangepicker) .vc-form .op-daterange__inputs { display: flex; flex-wrap: nowrap; width: 100%; }
html:not(.has-rangepicker) .vc-form .op-daterange__inputs input { flex: 1; min-width: 0; }

/* Code-Feld mit angehängtem Würfel-Knopf (neuer freier Code; Text nur für Screenreader, ohne JS ausgeblendet) */
.vc-codefield { display: flex; }
.vc-codefield .frm-input { flex: 1; min-width: 0; height: 40px; }
.vc-codefield--btn .frm-input { border-top-right-radius: 0; border-bottom-right-radius: 0; } /* Knopf sichtbar (JS) */
.vc-codefield .frm-input:focus { position: relative; z-index: 1; }
.vc-codegen {
    display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 40px; margin-left: -1px; padding: 0;
    border: 1px solid var(--line-strong); border-radius: 0 var(--r-sm) var(--r-sm) 0;
    background: var(--bg); color: var(--ink-soft); font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer;
}
.vc-codegen[hidden] { display: none; }
.vc-codegen svg { width: 19px; height: 19px; flex: 0 0 19px; }
.vc-codegen:hover { color: var(--brand); background: var(--surface); }
.vc-codegen:focus-visible { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint); position: relative; z-index: 1; }
.vc-codegen[aria-busy="true"] { cursor: progress; opacity: .6; }
.vc-codegen[aria-busy="true"] svg { animation: vc-spin .6s linear infinite; }
@keyframes vc-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .vc-codegen[aria-busy="true"] svg { animation: none; } }

/* Gutschein anlegen: Bestätigungs-Pop-up (portal.js initSubmitConfirm) */
.vc-confirm__title { margin: 0 0 14px; font-size: 18px; }
.vc-confirm__warn {
    display: flex; gap: 10px; align-items: flex-start; margin-bottom: 14px; padding: 11px 13px;
    border-radius: var(--r-sm); background: var(--warn-bg); color: var(--warn-text); font-size: 14px; line-height: 1.45;
}
.vc-confirm__warn svg { width: 20px; height: 20px; flex: 0 0 20px; margin-top: 1px; }
.vc-confirm__warn p { margin: 0; }
.vc-confirm__summary { margin-bottom: 18px; }
.vc-confirm__summary td { padding: 7px 10px; vertical-align: top; }
.vc-confirm__summary td:last-child { overflow-wrap: anywhere; }
.vc-confirm__summary tr:first-child td:last-child { font-family: monospace; font-weight: 600; }
.vc-confirm__actions { flex-wrap: wrap; }

/* Bestellarten/Kategorien als Schiebeschalter (Checkbox role="switch"), Optik wie "Geöffnet" (.op-switch) */
.vc-switches { display: flex; flex-wrap: wrap; gap: 10px 24px; }
.vc-switches--grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 16px; }
.vc-switch { display: inline-flex; align-items: center; gap: 9px; font-size: 14px; } /* nur der Schalter ist klickbar, nicht der Text */
.vc-switch input {
    -webkit-appearance: none; appearance: none; position: relative; flex: 0 0 38px;
    width: 38px; height: 22px; margin: 0; border-radius: var(--r-pill);
    background: var(--line-strong); cursor: pointer; transition: background .15s;
}
.vc-switch input::before {
    content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%;
    background: var(--surface); box-shadow: 0 1px 2px rgba(0, 0, 0, .25); transition: transform .15s;
}
.vc-switch input:checked { background: var(--brand); }
.vc-switch input:checked::before { transform: translateX(16px); }
.vc-switch input:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .vc-switch input, .vc-switch input::before { transition: none; } }

.vc-discount { display: flex; }
.vc-discount .frm-input { flex: 1; min-width: 0; height: 40px; border-top-right-radius: 0; border-bottom-right-radius: 0; }
.vc-discount .frm-input:focus { position: relative; z-index: 1; }
.vc-unit {
    display: inline-flex; gap: 2px; padding: 3px; margin-left: -1px; height: 40px;
    border: 1px solid var(--line-strong); border-radius: 0 var(--r-sm) var(--r-sm) 0; background: var(--bg);
}
.vc-unit label { display: flex; cursor: pointer; }
.vc-unit input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.vc-unit span {
    display: flex; align-items: center; justify-content: center; min-width: 38px; padding: 0 10px;
    border-radius: 5px; font-weight: 650; color: var(--ink-soft);
}
.vc-unit label:hover span { color: var(--ink); background: var(--surface); }
.vc-unit input:checked + span { background: var(--brand); color: #fff; }
.vc-unit input:focus-visible + span { outline: 2px solid var(--brand); outline-offset: 2px; }

/* ============================== Speisekarte (Artikel / Auswahl, alte Struktur + Matrix) ==============================
   Stand 2026-10-08, Markup: Pages/Shared/_MenuList.cshtml, JS: portal.js initMenuList.
   Je Kategorie ein Panel (.mc-section), je Artikel .mc-item: Kopf (Text links, Artikel-Status + MwSt rechts) und eine Zeile je
   Größe (.mc-size) im Raster wie der Spaltenkopf .mc-cols: Größe | Art.-Nr. | Preise (--mc-prices) | Status.
   Mobil (≤ 720px): kein Spaltenkopf, Beschriftung am Feld (.mc-field__label), Felder zweispaltig. */
.mc { --mc-grid: minmax(90px, 1fr) 120px repeat(var(--mc-prices, 1), 124px) 150px; }
.mc-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.mc-intro { max-width: 860px; margin: -6px 0 16px; }
/* Artikel-Seite: Kurzbeschreibung links, Support-Knopf rechts (mobil untereinander) */
.mc-intro--box { max-width: none; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 20px; }
.mc-intro--box > p { margin: 0; flex: 1 1 420px; max-width: 760px; }
.mc-intro__support { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }

.mc-toolbar {
    position: sticky; top: 64px; z-index: 15;
    display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
    margin: 0 0 16px; padding: 10px 12px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-sm);
}
.mc-toolbar .op-segments { margin: 0; }
/* Filter als Knöpfe statt Links (gleiche Optik wie .op-segments__item) */
button.op-segments__item { border: 0; background: transparent; font: inherit; font-size: 13.5px; cursor: pointer; }
button.op-segments__item:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
.mc-toolbar__search { flex: 1 1 240px; width: auto; min-width: 0; }
.mc-toolbar__category { flex: 0 1 260px; width: auto; min-width: 0; }
.mc-toolbar__count { margin-left: auto; white-space: nowrap; }
.mc-toolbar [hidden] { display: none !important; }

.mc-section { scroll-margin-top: 140px; padding-bottom: 8px; }
.mc-section__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 8px 14px; margin-bottom: 10px; }
.mc-section__head h2 { margin: 0; }
.mc-section__parent { font-size: 12px; font-weight: 600; color: var(--muted); margin-bottom: 2px; }
.mc-section__notes { display: flex; flex-wrap: wrap; gap: 6px; }

.mc-cols, .mc-size { display: grid; grid-template-columns: var(--mc-grid); gap: 6px 12px; align-items: center; }
.mc-cols {
    padding: 0 0 7px; border-bottom: 2px solid var(--line);
    font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted);
}
.mc-cols__num { text-align: right; padding-right: 22px; }

.mc-item { padding: 12px 0 10px; border-bottom: 1px solid var(--line); scroll-margin-top: 140px; }
.mc-item:last-of-type { border-bottom: 0; }
.mc-item[hidden], .mc-section[hidden] { display: none; }
.mc-item__head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 6px 18px; margin-bottom: 6px; }
.mc-item__text { flex: 1 1 280px; min-width: 0; }
.mc-item__name { font-size: 15px; margin: 0; }
.mc-item__title { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.mc-item__noadd { font-size: 12px; color: var(--muted); }
.mc-item__desc { font-size: 13px; color: var(--ink-soft); margin: 2px 0 0; max-width: 70ch; }
.mc-item__usedin { margin: 3px 0 0; font-size: 12px; color: var(--muted); }
.mc-item__meta { display: flex; flex-wrap: wrap; gap: 2px 14px; font-size: 12px; color: var(--muted); margin: 3px 0 0; }
.mc-item__ctrl { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px 12px; }


.frm-select.mc-select, .frm-select.mc-status, .frm-input.mc-input { padding: 6px 9px; font-size: 13.5px; border-radius: 7px; }
.frm-select.mc-select { width: auto; max-width: 190px; }

.mc-sizes { display: flex; flex-direction: column; gap: 4px; }
.mc-size { padding: 3px 0; }
.mc-size__name { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; font-size: 13.5px; color: var(--ink-soft); min-width: 0; overflow-wrap: anywhere; }
.mc-size__extra { grid-column: 1 / -1; font-size: 12.5px; color: var(--muted); }
/* Pfand: gut sichtbar direkt an der Größe (Amber wie „heute aus“, Flaschen-Icon) */
/* MwSt-Auswahl: Desktop in der Infozeile rechts neben den Zusatzstoffen (Alt: eine, Matrix: Lieferung + je Bestellart);
   mobil verschiebt portal.js sie in die Klappansicht (.mc-sizes, erste Karte) */
.mc-item__meta { align-items: center; }
.mc-vat { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.mc-vat__title { font-weight: 650; color: var(--ink-soft); }
.mc-vat__field { display: inline-flex; align-items: center; gap: 5px; }
.frm-select.mc-vat__select { padding: 2px 4px 2px 6px; font-size: 12px; border-radius: 6px; }
@media (max-width: 720px) {
    /* Mobil in der Klappansicht: Karte wie eine Variante, Beschriftung links, Auswahl rechts */
    .mc-sizes > .mc-vat {
        display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 10px; align-items: center;
        padding: 8px 10px; background: var(--bg); border-radius: var(--r-sm); font-size: 13px;
    }
    .mc-sizes > .mc-vat .mc-vat__title,
    .mc-sizes > .mc-vat .mc-vat__label { font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
    .mc-sizes > .mc-vat--channels .mc-vat__title { grid-column: 1 / -1; }
    .mc-sizes > .mc-vat .mc-vat__field { display: contents; }
    .mc-sizes > .mc-vat .frm-select.mc-vat__select { width: 100%; max-width: none; padding: 6px 9px; font-size: 13.5px; border-radius: 7px; }
}

/* Links aus tblAdditives.AdditivesName im Inhaltsstoffe-Pop-up (Extensions/SafeHtml) */
.mc-addpop__list a { color: var(--brand); text-decoration: underline; }

/* Zusatzstoffe: kleiner Info-Knopf in der Meta-Zeile, Klartext im Pop-up (portal.js openInfoModal) */
.mc-info-btn {
    display: inline-flex; align-items: center; gap: 4px; padding: 1px 9px 1px 6px;
    border: 1px solid var(--line-strong); border-radius: var(--r-pill); background: var(--surface);
    color: var(--ink-soft); font: inherit; font-size: 12px; line-height: 1.5; cursor: pointer;
}
.mc-info-btn:hover { border-color: var(--ink-soft); color: var(--ink); }
.mc-info-btn:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.mc-info-btn svg { width: 13px; height: 13px; flex: 0 0 13px; }
.modal--sm { max-width: 440px; }
.mc-addpop__title { margin: 0; font-size: 18px; }
.mc-addpop__sub { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.mc-addpop__group { margin: 16px 0 6px; font-size: 12px; font-weight: 650; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.mc-addpop__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
.mc-addpop__list li { display: grid; grid-template-columns: 2.6em 1fr; gap: 8px; font-size: 14px; line-height: 1.4; }
.mc-addpop__list code { font-weight: 650; color: var(--ink); }
.mc-addpop__note { margin: 16px 0 0; font-size: 12px; color: var(--muted); }
.mc-addpop__actions { display: flex; justify-content: flex-end; margin-top: 14px; }

.mc-deposit-badge {
    display: inline-flex; align-items: center; gap: 5px; padding: 2px 10px 2px 7px;
    border-radius: var(--r-pill); background: var(--warn-bg); color: var(--warn-text);
    font-size: 12px; font-weight: 650; line-height: 1.5; white-space: nowrap;
}
.mc-deposit-badge svg, .mc-deposit__icon { width: 14px; height: 14px; flex: 0 0 14px; }
.mc-deposit--edit {
    padding: 5px 10px; border-radius: var(--r-sm); background: var(--warn-bg); color: var(--warn-text); font-size: 13px;
}
.mc-deposit--edit .mc-input, .mc-deposit--edit .mc-select { background: var(--surface); }
.mc-size--empty { display: block; }

.mc-field { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.mc-field__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mc-ro { font-size: 13.5px; }
.mc-field--price .mc-ro { text-align: right; padding-right: 22px; }
.mc-money { position: relative; display: flex; align-items: center; gap: 5px; }
.mc-money .mc-input { text-align: right; min-width: 0; }
.mc-money__unit { font-size: 13px; color: var(--muted); }
.mc-money--sm { display: inline-flex; width: 112px; vertical-align: middle; }
.mc-deposit { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.mc-input::placeholder { color: #A3A3A3; }

/* Status: Farbbalken links am Auswahlfeld (grün aktiv, amber heute aus, rot deaktiviert) */
.frm-select.mc-status { border-left-width: 4px; }
.mc-status[data-state="on"] { border-left-color: var(--ok); }
.mc-status[data-state="deak"] { border-left-color: var(--warn); }
.mc-status[data-state="off"] { border-left-color: var(--bad); }
.mc-status-ro { display: inline-flex; align-items: center; gap: 7px; font-size: 13.5px; }
.mc-field--article { flex-direction: row; align-items: center; gap: 6px; }
.mc-field--article .mc-field__label { position: static; width: auto; height: auto; clip: auto; font-size: 12.5px; color: var(--muted); }
.mc-field--article .mc-status { width: auto; }
.mc-hint { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--warn-text); }
.mc-size > .mc-hint { grid-column: 1 / -1; justify-self: end; text-align: right; }
.mc-hint[hidden] { display: none; }

@media (max-width: 960px) {
    .mc-toolbar { top: 0; }
}

/* Desktop (> 720px): Artikel mit nur einer Variante in EINER Zeile — Text links, Art.-Nr./Preise in ihren Spalten, in der
   Status-Spalte nur der Artikel-Status. Eine Variante hat keinen eigenen Status mehr (Matrix: Artikel + Variante = ein Status,
   MenuMatrixBuilder „ActiveSingle“; Alt: Status der Zeile im Artikelkopf). Kopf, Varianten-Liste und Variante lösen sich per
   display: contents ins Raster des Artikels auf. */
@media (min-width: 721px) {
    .mc-item--single { display: grid; grid-template-columns: var(--mc-grid); gap: 4px 12px; align-items: start; }
    .mc-item--single > .mc-item__head,
    .mc-item--single .mc-item__ctrl,
    .mc-item--single > .mc-sizes,
    .mc-item--single .mc-size { display: contents; }
    .mc-item--single .mc-item__text { grid-column: 1; grid-row: 1; }
    .mc-item--single .mc-size > .mc-field--sku,
    .mc-item--single .mc-size > .mc-field--price { grid-row: 1; margin-top: -2px; }
    .mc-item--single .mc-field--article { grid-column: -2; grid-row: 1; margin-top: -2px; }
    .mc-item--single .mc-field--article .mc-field__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .mc-item--single .mc-field--article .mc-status { width: 100%; }
    .mc-item--single .mc-size__name { grid-column: 1; grid-row: 2; }
    .mc-item--single .mc-hint, .mc-item--single .mc-size__extra { grid-column: 1 / -1; justify-self: end; text-align: right; }
    .mc-item--single .mc-size__extra { justify-self: start; text-align: left; }
}


/* Klapp-Knopf für Varianten/Preise: nur mobil (≤ 720px) und nur mit JS (.mc-collapsible) */
.mc-sizes-toggle { display: none; }
.mc-sizes-toggle[hidden], .mc-sizes-toggle__off[hidden] { display: none !important; }
.mc-sizes-toggle__off { padding: 0 9px; font-size: 11.5px; }

@media (max-width: 720px) {
    .mc-cols { display: none; }
    .mc-toolbar { position: static; }
    .mc-toolbar__count { margin-left: 0; }
    .mc-item__ctrl { justify-content: flex-start; width: 100%; }
    .mc-size {
        grid-template-columns: 1fr 1fr; gap: 8px 10px;
        padding: 8px 10px; background: var(--bg); border-radius: var(--r-sm);
    }
    .mc-size__name { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-weight: 600; color: var(--ink); }
    .mc-size__name--empty { display: none; }
    .mc-field__label {
        position: static; width: auto; height: auto; clip: auto;
        font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
    }
    .mc-field--price .mc-ro { text-align: left; padding-right: 0; }
    .mc-field--status { grid-column: 1 / -1; }
    .mc-size > .mc-hint { justify-self: start; text-align: left; }
    .frm-select.mc-select { max-width: none; }
    .mc-collapsible .mc-sizes-toggle {
        display: flex; align-items: center; gap: 8px; width: 100%; margin: 8px 0 2px; padding: 9px 12px;
        border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--bg);
        font: inherit; font-size: 13.5px; font-weight: 600; color: var(--ink); text-align: left; cursor: pointer;
    }
    .mc-collapsible .mc-sizes-toggle:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
    .mc-sizes-toggle__chev { width: 18px; height: 18px; flex: 0 0 18px; margin-left: auto; color: var(--muted); transition: transform .15s; }
    .mc-sizes-toggle__off { flex: 0 0 auto; white-space: nowrap; }
    .mc-is-open .mc-sizes-toggle__chev { transform: rotate(180deg); }
    .mc-collapsible .mc-item:not(.mc-is-open) > .mc-sizes { display: none; }
    /* Filter „Nicht aktiv“: Varianten der Treffer offen, Knopf überflüssig (Suche klappt nicht auf) */
    .mc-collapsible.mc-expand-all .mc-item > .mc-sizes { display: flex; }
    .mc-collapsible.mc-expand-all .mc-sizes-toggle { display: none; }
    .mc-is-open > .mc-sizes { margin-top: 6px; }
    /* Ohne Varianten: im Aufklappmenü nur die Preise (Art.-Nr. ausgeblendet; einen Varianten-Status gibt es dort nicht) */
    .mc-collapsible .mc-item--single .mc-field--sku { display: none; }
    /* Artikel-Status: Beschriftung links, Feld rechts */
    .mc-item__ctrl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 10px; align-items: center; width: 100%; }
    .mc-field--article { display: contents; }
    .mc-field--article .mc-field__label {
        font-size: 12.5px; font-weight: 400; letter-spacing: 0; text-transform: none; color: var(--muted);
    }
    .mc-item__ctrl > .mc-hint { grid-column: 1 / -1; }
}

/* ============================== Angebote (/promotions, Stand 2026-10-12) ==============================
   Markup: Pages/Promotions.cshtml — Liste, je Angebot ein Panel (.pr-item). Kein Formular: Anlegen/Bearbeiten macht der Support,
   im Portal nur Ein-/Ausschalten per Schieber (.pr-toggle, .vc-switch) und an jedem Angebot ein Support-Knopf (.pr-support). */
.pr-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr)); gap: 16px; align-items: start; }
.pr-item { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.pr-item--off { background: var(--bg); }
.pr-item--off .pr-item__title, .pr-item--off .pr-item__mech { color: var(--ink-soft); }
.pr-item__head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.pr-item__title { margin: 0 auto 0 0; font-size: 16px; overflow-wrap: anywhere; }
.pr-item__mech { margin: 0; font-weight: 600; }
.pr-conds { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.pr-conds li { padding: 3px 10px; border-radius: var(--r-pill); background: var(--bg); border: 1px solid var(--line); font-size: 12.5px; color: var(--ink-soft); }
.pr-meta { display: flex; flex-wrap: wrap; gap: 4px 24px; margin: 0; font-size: 13px; }
.pr-meta div { display: flex; gap: 6px; }
.pr-meta dt { color: var(--muted); }
.pr-meta dd { margin: 0; }
.pr-item__alert { margin: 0; font-size: 13px; }
.pr-item__note { margin: 0; }
.pr-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 2px 0 0; padding-top: 12px; border-top: 1px solid var(--line); }
.pr-actions .pr-item__note { flex: 1 1 100%; }
.pr-support { margin-left: auto; }
.pr-toggle { margin: 0; }
.pr-toggle.is-saving { opacity: .6; pointer-events: none; }

/* ============================== Cookie-Banner (Stand 2026-10-22) ==============================
   Optik wie restabloPortal consent.scss (helle Leiste unten, Kategorien im Raster, gleich große Antwort-Knöpfe, Markenrot nur auf
   „Alle akzeptieren“, „Einstellungen“/„Auswahl akzeptieren“ als Textlinks, Radius 8px). Markup: Pages/Shared/_CookieConsent.cshtml,
   Logik: portal.js initCookieConsent (Ablauf wie restabloLegacy script-consent.js). Ein-/Ausblenden über das hidden-Attribut. */
.cookie-banner {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    width: 100%;
    background: #fff;
    color: var(--ink);
    border-top: 1px solid var(--line);
    box-shadow: 0 -8px 32px rgba(40, 40, 40, .12);
    z-index: 55;                 /* unter Pop-ups (.modal-backdrop 100) — das Info-Pop-up liegt darüber */
    animation: cookie-banner-in .25s ease-out;
}
.cookie-banner .cookie-content {
    max-width: 700px;
    width: 100%;
    margin: 0 auto;
    padding: 16px 20px 20px;
    text-align: left;
    max-height: 70vh;            /* flache Viewports: die Leiste scrollt selbst */
    overflow-y: auto;
}
.cookie-banner .cookie-content p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--ink-soft); }
.cookie-banner .cookie-content a { color: var(--brand); text-decoration: underline; }

.cookie-banner #cookieOptions { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.cookie-banner .check-area {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
    gap: 6px 24px;
    align-content: start;
}
.cookie-banner .check-area[hidden] { display: none; }

.cookie-banner .button-area { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; }
.cookie-banner .button-area button {
    flex: 0 1 auto;
    min-width: 176px;
    padding: 11px 24px 9px;
    margin: 0;
    font: inherit;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
    text-align: center;
    background: var(--bg);
    color: var(--ink);
    border: 1px solid var(--line-strong);
    border-radius: var(--r-sm);
    box-shadow: none;
    cursor: pointer;
    transition: background-color .18s ease, border-color .18s ease, color .18s ease;
}
.cookie-banner .button-area button:hover { background: #fff; border-color: var(--ink); }
.cookie-banner button:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.cookie-banner .button-area #acceptAll { background: var(--brand); border-color: var(--brand); color: #fff; }
.cookie-banner .button-area #acceptAll:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.cookie-banner .button-area #cookieToggleOptions,
.cookie-banner .button-area #acceptEssential {
    min-width: 0;
    padding: 11px 4px 9px;
    background: transparent;
    border: none;
    border-radius: 0;
    color: var(--ink-soft);
    font-weight: 400;
    text-decoration: underline;
}
.cookie-banner .button-area #cookieToggleOptions:hover,
.cookie-banner .button-area #acceptEssential:hover { background: transparent; color: var(--ink); }

/* Kategorie: Kästchen + Name + ⓘ */
.cookie-banner .form-checkbox {
    position: relative;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    font-size: 14px;
    color: var(--ink);
    cursor: pointer;
}
.cookie-banner .form-checkbox input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.cookie-banner .form-checkbox > span:first-of-type {
    position: relative;
    display: inline-block;
    flex: 0 0 auto;
    width: 1.3rem;
    height: 1.3rem;
    margin-right: 7px;
    background: #fff;
    border: 1px solid var(--line-strong);
    border-radius: 3px;
}
.cookie-banner .form-checkbox > span:first-of-type::after {
    content: '\2714';
    position: absolute; inset: 0;
    display: block;
    color: #fff;
    font-size: 1.1rem;
    line-height: 103%;
    text-align: center;
    opacity: 0;
    transition: opacity 250ms linear;
}
.cookie-banner .form-checkbox input:checked ~ span:first-of-type { background: var(--brand); border-color: var(--brand); }
.cookie-banner .form-checkbox input:checked ~ span:first-of-type::after { opacity: 1; }
.cookie-banner .form-checkbox input:focus-visible ~ span:first-of-type { outline: 2px solid var(--brand); outline-offset: 2px; }
/* „Notwendig“ ist gesetzt und nicht abwählbar (disabled-Attribut + Cursor, nicht Farbe allein) */
.cookie-banner .form-checkbox input:disabled ~ * { cursor: default; }
.cookie-banner .form-checkbox:has(input:disabled) { cursor: default; }
.cookie-banner .info-button {
    display: inline-flex;
    align-items: center;
    padding: 3px 5px;
    margin: 0;
    background: transparent;
    border: none;
    cursor: pointer;
}
.cookie-banner .info-icon { display: inline-block; width: 16px; aspect-ratio: 1 / 1; }

@media (max-width: 570px) {
    .cookie-banner .button-area button { flex: 1 1 100%; min-width: 0; }
    .cookie-banner .button-area #cookieToggleOptions,
    .cookie-banner .button-area #acceptEssential { flex: 0 1 auto; }
}

@keyframes cookie-banner-in {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
    .cookie-banner { animation: none; }
}

/* Info-Pop-up einer Kategorie (portal.js openConsentInfo) */
.cookie-info__title { margin: 0 0 8px; font-size: 18px; }
.cookie-info p { margin: 0; font-size: 14px; line-height: 1.5; color: var(--ink-soft); }
.cookie-info__list { margin: 14px 0 0; padding: 0; display: grid; gap: 4px; font-size: 13.5px; }
.cookie-info__list dt { margin-top: 8px; font-weight: 650; color: var(--ink); }
.cookie-info__list dt:first-child { margin-top: 0; }
.cookie-info__list dd { margin: 0; color: var(--ink-soft); line-height: 1.45; }
.cookie-info__dur { display: block; color: var(--muted); font-size: 12.5px; }
.cookie-info__actions { display: flex; justify-content: flex-end; margin-top: 16px; }

/* Footer: „Cookie-Einstellungen“ ist ein Knopf (öffnet den Banner), sieht aus wie die Links daneben */
.footer .footer-link {
    padding: 0; margin: 0;
    font: inherit;
    color: var(--ink-soft);
    background: none;
    border: 0;
    cursor: pointer;
}
.footer .footer-link:hover { text-decoration: underline; }
