/* Vorrat – ruhiges, schlankes Design */
:root {
  --bg: #f5f3ee;
  --surface: #ffffff;
  --surface-2: #f0ede6;
  --line: #e9e5dc;
  --ink: #1c211e;
  --ink-2: #4b524d;
  --muted: #8a8f89;
  --accent: #2e6b4b;
  --accent-ink: #ffffff;
  --accent-soft: #e3efe7;
  --warn: #a8700f;
  --warn-soft: #faefd8;
  --orange: #c2531d;
  --orange-soft: #fbe5da;
  --danger: #b3261e;
  --danger-soft: #f8dfdc;
  --shadow-sm: 0 1px 2px rgba(30, 28, 20, .05), 0 1px 1px rgba(30, 28, 20, .03);
  --shadow: 0 10px 34px rgba(30, 28, 20, .16);
  --r: 16px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131615; --surface: #1c201e; --surface-2: #252a27; --line: #2c322f;
    --ink: #ecebe6; --ink-2: #c4c7c2; --muted: #8d938e; --accent: #74c497; --accent-ink: #0c1a12; --accent-soft: #1f3529;
    --warn: #e2b04f; --warn-soft: #362c1b; --orange: #f08a5d; --orange-soft: #3a251c;
    --danger: #f2766d; --danger-soft: #3d2221; --shadow-sm: none; --shadow: 0 10px 34px rgba(0,0,0,.55);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { font: 15px/1.35 ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; -webkit-font-smoothing: antialiased; overscroll-behavior-y: none; }
button, input, select { font: inherit; color: inherit; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.hint { font-size: 13px; color: var(--muted); }
.meta { display: block; font-size: 12.5px; color: var(--muted); margin-top: 1px; }

/* Buttons */
.btn { border: 0; border-radius: 12px; padding: 10px 14px; font-weight: 600; cursor: pointer; background: var(--surface-2); white-space: nowrap; }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.ghost { background: transparent; box-shadow: inset 0 0 0 1px var(--line); }
.btn.danger { background: var(--danger-soft); color: var(--danger); }
.btn.wide { width: 100%; padding: 13px; }
.btn.mini { font-size: 13px; padding: 7px 11px; border-radius: 10px; }
.btn:active, .icon-btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; }
.link { background: none; border: 0; color: var(--accent); font-weight: 600; margin-top: 14px; cursor: pointer; }
.icon-btn { background: none; border: 0; padding: 8px; border-radius: 12px; color: var(--muted); cursor: pointer; display: grid; place-items: center; }
.icon-btn.square { width: 44px; height: 44px; background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); flex: none; }
.icon-btn.square.primary { background: var(--accent); color: var(--accent-ink); }

/* Anmeldung */
.auth { min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px; }
.auth-card { width: 100%; max-width: 360px; text-align: center; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 26px; font-weight: 750; letter-spacing: -.02em; }
.brand-mark { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--accent); color: var(--accent-ink); font-weight: 800; }
.brand-mark.sm { width: 26px; height: 26px; border-radius: 8px; font-size: 14px; }
.auth form { text-align: left; margin-top: 20px; display: grid; gap: 12px; }
label { display: grid; gap: 5px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
input, select { width: 100%; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 11px 12px; font-size: 16px; outline: none; }
input:focus, select:focus { border-color: var(--accent); }
.error { color: var(--danger); min-height: 1em; margin: 0; font-size: 14px; }

/* Kopfzeile */
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; max-width: 720px; margin: 0 auto; padding: calc(env(safe-area-inset-top, 0px) + 10px) 16px 6px; background: var(--bg); }
.title { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 17px; letter-spacing: -.01em; }
.live { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); opacity: .5; }
.live.on { background: #3fb86b; opacity: 1; box-shadow: 0 0 0 3px rgba(63,184,107,.18); }

main { max-width: 720px; margin: 0 auto; padding: 0 16px calc(160px + var(--safe-b)); }
.toolbar { display: flex; gap: 8px; margin: 4px 0 10px; }
.search { flex: 1; position: relative; }
.search > svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); }
.search input { padding-left: 38px; height: 44px; border: 0; box-shadow: var(--shadow-sm); }
#shop-form .search input { padding-left: 14px; }
.search.has-mic input { padding-right: 44px; }
.mic { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 10px; background: none; color: var(--muted); display: grid; place-items: center; cursor: pointer; }
.mic svg { width: 20px; height: 20px; }
.mic.rec { background: var(--danger); color: #fff; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--danger) 25%, transparent); } }

/* Übersicht + Filter */
.summary { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--muted); margin: 2px 2px 10px; align-items: center; }
.summary b { color: var(--ink); font-weight: 700; }
.sum-warn { border: 0; background: var(--orange-soft); color: var(--orange); border-radius: 20px; padding: 2px 9px; font-size: 13px; cursor: pointer; }
.sum-warn b { color: inherit; }
.fchips { display: flex; gap: 6px; overflow-x: auto; margin: 0 -16px 12px; padding: 0 16px 2px; scrollbar-width: none; }
.fchips::-webkit-scrollbar { display: none; }
.fchip { flex: none; border: 0; background: var(--surface); box-shadow: var(--shadow-sm); border-radius: 20px; padding: 7px 12px; font-size: 13.5px; font-weight: 600; color: var(--ink-2); cursor: pointer; white-space: nowrap; }
.fchip i { font-style: normal; color: var(--muted); font-weight: 600; margin-left: 2px; }
.fchip.on { background: var(--ink); color: var(--bg); }
.fchip.on i { color: inherit; opacity: .7; }

/* Kategorien & Zeilen */
.cat { margin-bottom: 14px; }
.cat-h { display: flex; align-items: center; gap: 6px; margin: 0 4px 6px; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); cursor: pointer; user-select: none; }
.cat-h.plain { cursor: default; }
.cat-h .n { margin-left: auto; font-weight: 600; letter-spacing: 0; }
.cat-h .chev { width: 14px; height: 14px; transition: transform .15s; }
.cat.closed .chev { transform: rotate(-90deg); }
.cat.closed .rows { display: none; }
.rows { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow-sm); overflow: hidden; }
.row { display: flex; align-items: center; gap: 11px; padding: 7px 8px 7px 10px; min-height: 54px; position: relative; }
.rows > .row + .row::before, .rows > .grow + .grow::before { content: ""; position: absolute; left: 60px; right: 0; top: 0; border-top: 1px solid var(--line); }
.grow { position: relative; }
.grow.open { background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); }
.thumb { width: 38px; height: 38px; border-radius: 10px; object-fit: cover; flex: none; background: var(--surface-2); display: grid; place-items: center; font-size: 18px; cursor: zoom-in; }
span.thumb { cursor: default; }
.thumb.lg { width: 58px; height: 58px; border-radius: 13px; font-size: 26px; }
.info { flex: 1; min-width: 0; cursor: pointer; }
.info .l1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.info .l1 b { font-weight: 650; }
.v { color: var(--muted); }
.pill { display: inline-block; font-size: 11.5px; font-weight: 650; padding: 1px 8px; border-radius: 20px; margin-top: 3px; background: var(--accent-soft); color: var(--accent); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; vertical-align: top; }
.pill.bald { background: var(--warn-soft); color: var(--warn); }
.pill.pruefen { background: var(--orange-soft); color: var(--orange); }
.pill.weg { background: var(--danger-soft); color: var(--danger); }

/* Mengen-Stepper */
.stepper { display: flex; align-items: center; flex: none; gap: 2px; }
.stepper button { width: 32px; height: 32px; border: 0; background: var(--surface-2); border-radius: 50%; cursor: pointer; display: grid; place-items: center; padding: 0; }
.stepper button svg { width: 15px; height: 15px; stroke-width: 2.2; }
.stepper button:active { background: var(--line); }
.stepper .q { min-width: 30px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; background: none; border-radius: 8px; width: auto; padding: 0 2px; }
.stepper button.q:active { background: var(--surface-2); }
.stepper button.strike { color: var(--danger); background: var(--danger-soft); }

/* Aufgeklappte Unterpunkte */
.sub { padding: 0 12px 12px 59px; display: grid; gap: 6px; animation: fade .15s ease-out; }
@keyframes fade { from { opacity: 0; transform: translateY(-3px); } }
.sub-line { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-2); min-height: 30px; }
.sub-t { flex: 1; min-width: 0; cursor: pointer; }
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--accent); }
.dot.bald { background: var(--warn); } .dot.pruefen { background: var(--orange); } .dot.weg { background: var(--danger); }
.dot.closed { background: transparent; box-shadow: inset 0 0 0 1.5px var(--muted); }
.lvl-bald { color: var(--warn); font-weight: 600; } .lvl-pruefen { color: var(--orange); font-weight: 600; } .lvl-weg { color: var(--danger); font-weight: 600; }
.link-btn { border: 0; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); border-radius: 9px; padding: 5px 10px; font-size: 12.5px; font-weight: 650; color: var(--accent); cursor: pointer; display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.link-btn svg { width: 14px; height: 14px; }
.sub-hint { font-size: 12.5px; color: var(--muted); }
.sub-acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.chip-btn { border: 0; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); border-radius: 20px; padding: 6px 11px; font-size: 13px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 5px; color: var(--ink-2); }
.chip-btn svg { width: 15px; height: 15px; }
.chip-btn.danger { color: var(--danger); }

.empty { text-align: center; color: var(--muted); padding: 44px 20px; line-height: 1.5; }
.empty .big { font-size: 40px; display: block; margin-bottom: 8px; }

/* Gestrichen */
.removed { margin-top: 18px; }
.removed summary { cursor: pointer; color: var(--muted); font-weight: 600; font-size: 13.5px; padding: 8px 4px; list-style: none; }
.removed summary::-webkit-details-marker { display: none; }
.removed summary::before { content: "▸ "; }
.removed[open] summary::before { content: "▾ "; }
.removed .row { background: var(--surface); border-radius: 14px; margin-bottom: 6px; opacity: .85; box-shadow: var(--shadow-sm); }
.removed .info .l1 b { text-decoration: line-through; text-decoration-color: var(--muted); }

/* Leer-Hinweis */
.empties { max-width: 720px; margin: 0 auto 10px; padding: 0 16px; }
.empties .box { background: var(--accent-soft); border-radius: var(--r); padding: 12px; }
.empties .t { font-weight: 700; margin-bottom: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.chip { border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); border-radius: 20px; padding: 5px 11px; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.chip.off { background: transparent; color: var(--accent); text-decoration: line-through; }
.empties .acts { display: flex; gap: 8px; }
.empties .acts .btn { flex: 1; padding: 9px; }

.legend { font-size: 13px; color: var(--muted); margin: 4px 4px 12px; }

/* Einkauf */
.check { width: 26px; height: 26px; border-radius: 8px; border: 2px solid var(--line); background: var(--surface); flex: none; display: grid; place-items: center; cursor: pointer; padding: 0; }
.check svg { width: 16px; height: 16px; stroke-width: 3; opacity: 0; color: var(--accent-ink); }
.row.done .check, .check.on { background: var(--accent); border-color: var(--accent); }
.row.done .check svg, .check.on svg { opacity: 1; }
.row.done .info b { text-decoration: line-through; color: var(--muted); }
.x-btn { border: 0; background: none; color: var(--muted); padding: 6px; cursor: pointer; }
.x-btn svg { width: 17px; height: 17px; }
.shop-actions { display: grid; gap: 8px; margin-top: 12px; }

/* Statistik */
.card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow-sm); padding: 14px; margin-bottom: 12px; }
.card h3 { margin: 0 0 10px; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tiles.four { grid-template-columns: repeat(4, 1fr); }
.tile { background: var(--surface-2); border-radius: 12px; padding: 10px; display: grid; gap: 2px; min-width: 0; align-content: start; }
.tile b { font-size: 22px; font-weight: 750; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.tile span { font-size: 12px; color: var(--muted); line-height: 1.25; }
.tile.small b { font-size: 15px; line-height: 1.3; padding: 4px 0 3px; }
.tile.warn b { color: var(--orange); }
@media (max-width: 400px) { .tiles.four { grid-template-columns: repeat(2, 1fr); } }
.seg { display: flex; background: var(--surface-2); border-radius: 12px; padding: 3px; margin: 0 0 12px; gap: 2px; }
.seg button { flex: 1; border: 0; background: none; border-radius: 9px; padding: 7px 2px; font-size: 13px; font-weight: 600; color: var(--ink-2); cursor: pointer; white-space: nowrap; }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.bars li { display: flex; align-items: center; gap: 10px; }
.bars .rk { width: 16px; text-align: right; font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.bars .bl { flex: 1; min-width: 0; display: grid; gap: 4px; }
.bars .bn { font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bars .bt { height: 6px; background: var(--surface-2); border-radius: 4px; overflow: hidden; }
.bars .bt i { display: block; height: 100%; background: var(--accent); border-radius: 4px; }
.bars .bv { font-variant-numeric: tabular-nums; min-width: 24px; text-align: right; }
.wk-svg { width: 100%; height: auto; display: block; stroke: none; }
.wk-svg text { stroke: none; }
.wk { cursor: pointer; }
.wk-bar { fill: var(--accent); }
.wk:hover .wk-bar, .wk:active .wk-bar { fill: color-mix(in srgb, var(--accent) 75%, var(--ink)); }
.wk-zero { fill: var(--line); }
.wk-svg .wk-base { stroke: var(--line); stroke-width: 1; }
.wk-lbl { fill: var(--muted); font-size: 10px; }
.wk-tip { margin-top: 6px; text-align: center; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .two { grid-template-columns: 1fr; gap: 0; } }
.feed { list-style: none; margin: 0; padding: 0; font-size: 13.5px; color: var(--ink-2); }
.feed li { padding: 7px 0; border-top: 1px solid var(--line); display: flex; gap: 6px; flex-wrap: wrap; align-items: baseline; }
.feed li:first-child { border-top: 0; padding-top: 0; }
.feed .who { font-weight: 700; color: var(--ink); }
.feed .when { margin-left: auto; color: var(--muted); font-size: 12px; }

/* FAB & Tabs */
.fab { position: fixed; right: max(18px, calc(50vw - 342px)); bottom: calc(82px + var(--safe-b)); width: 58px; height: 58px; border-radius: 20px; border: 0; background: var(--accent); color: var(--accent-ink); box-shadow: var(--shadow); display: grid; place-items: center; cursor: pointer; z-index: 25; }
.fab svg { width: 26px; height: 26px; }
.fab:active { transform: scale(.95); }
.tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; justify-content: center; gap: 2px; padding: 6px 8px calc(6px + var(--safe-b)); background: color-mix(in srgb, var(--surface) 90%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
.tabs button { position: relative; flex: 1; max-width: 150px; border: 0; background: none; display: grid; justify-items: center; gap: 2px; padding: 6px 0; font-size: 11px; font-weight: 600; color: var(--muted); cursor: pointer; border-radius: 12px; }
.tabs button svg { width: 22px; height: 22px; }
.tabs button.active { color: var(--accent); }
.tabs button.active svg { stroke-width: 2.2; }
.badge { position: absolute; top: 1px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 10px; background: var(--danger); color: #fff; font-size: 11px; line-height: 18px; font-style: normal; }
.badge.soft { background: var(--accent); color: var(--accent-ink); }

/* Sheet */
.sheet-bg { position: fixed; inset: 0; background: rgba(10,12,10,.38); z-index: 40; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 41; max-width: 560px; margin: 0 auto; max-height: 92dvh; overflow-y: auto; background: var(--surface); border-radius: 24px 24px 0 0; padding: 6px 16px calc(18px + var(--safe-b)); box-shadow: var(--shadow); animation: up .2s ease-out; }
@keyframes up { from { transform: translateY(30px); opacity: 0; } }
.grip { width: 38px; height: 4px; border-radius: 4px; background: var(--line); margin: 4px auto 10px; }
.sheet h2 { margin: 2px 0 12px; font-size: 19px; display: flex; align-items: center; gap: 10px; letter-spacing: -.01em; }
.sheet h2 .thumb { width: 44px; height: 44px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.fields { display: grid; gap: 10px; }
.sheet .acts { display: grid; gap: 8px; margin-top: 14px; }
.sheet .acts.row2 { grid-template-columns: 1fr 1fr; }
.open-box { background: var(--surface-2); border-radius: 14px; padding: 12px; display: grid; gap: 8px; }
.open-box .st { font-weight: 650; }
.rec-card { border: 1px solid var(--line); border-radius: 16px; padding: 12px; display: grid; gap: 10px; margin-bottom: 10px; position: relative; }
.rec-card .del { position: absolute; top: 6px; right: 6px; }
.rec-top { display: flex; gap: 10px; align-items: flex-end; }
.rec-top .grid2 { flex: 1; }
.qty-line { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mhd-line { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: end; }
.mhd-line .btn { height: 45px; display: inline-flex; align-items: center; gap: 6px; }
.mhd-line .btn svg { width: 18px; height: 18px; }
.mhd-line .btn.busy { opacity: .6; pointer-events: none; }
.mhd-note { font-size: 12.5px; color: var(--accent); }
.mhd-note:empty { display: none; }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; margin: 24px auto 10px; }
@keyframes spin { to { transform: rotate(360deg); } }
.preview { width: 100%; max-height: 180px; object-fit: contain; border-radius: 12px; background: var(--surface-2); }
.set-sec { border-top: 1px solid var(--line); padding: 12px 0; display: grid; gap: 8px; }
.set-sec:first-of-type { border-top: 0; }
.set-sec h4 { margin: 0; font-size: 14px; }

/* Anzahl setzen */
.qs { display: flex; align-items: center; justify-content: center; gap: 22px; margin: 8px 0 6px; text-align: center; }
.qs-b { width: 54px; height: 54px; border-radius: 50%; border: 0; background: var(--surface-2); display: grid; place-items: center; cursor: pointer; }
.qs-n { font-size: 46px; font-weight: 800; font-variant-numeric: tabular-nums; min-width: 80px; letter-spacing: -.03em; }
.qs-quick { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; margin: 8px 0; }

/* Aufnahme: Packung + MHD */
.cap-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cap-tile { border-radius: 16px; padding: 10px; display: grid; justify-items: center; align-content: start; gap: 4px; text-align: center; font: inherit; color: inherit; }
.cap-tile.done { background: var(--surface-2); }
.cap-tile.add { background: transparent; border: 2px dashed var(--accent); color: var(--accent); cursor: pointer; align-content: center; min-height: 170px; }
.cap-tile.add svg { width: 34px; height: 34px; margin-bottom: 4px; }
.cap-tile img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 11px; }
.cap-tile b { font-size: 14px; }
.cap-st { font-size: 12.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.cap-st.ok { color: var(--accent); font-weight: 650; }
.cap-st.warn { color: var(--orange); }
.cap-big { width: 100%; aspect-ratio: 1; display: grid; place-items: center; font-size: 54px; font-weight: 800; color: var(--accent); background: var(--surface); border-radius: 11px; }
.dot-spin { width: 11px; height: 11px; border-radius: 50%; border: 2px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; display: inline-block; }

/* Prüfliste für viele Produkte */
.rv-list { border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.rv { border-top: 1px solid var(--line); }
.rv:first-child { border-top: 0; }
.rv-row { display: flex; align-items: center; gap: 9px; padding: 7px 8px; min-height: 52px; }
.rv.off .rv-row > :not(.check) { opacity: .4; }
.rv.open { background: var(--surface-2); }
.rv-edit { padding: 2px 10px 12px; }
.unsure { color: var(--orange); font-weight: 650; }
.rv-foot { position: sticky; bottom: calc(-18px - var(--safe-b)); margin: 12px -16px calc(-18px - var(--safe-b)); padding: 10px 16px calc(14px + var(--safe-b)); background: linear-gradient(to bottom, transparent, var(--surface) 30%); }

.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(152px + var(--safe-b)); z-index: 60; background: var(--ink); color: var(--bg); padding: 10px 10px 10px 16px; border-radius: 14px; display: flex; gap: 12px; align-items: center; box-shadow: var(--shadow); font-weight: 550; max-width: calc(100vw - 32px); }
.toast button { background: none; border: 0; color: #9fdcb7; font-weight: 750; cursor: pointer; padding: 4px 6px; }
@media (prefers-color-scheme: dark) { .toast button { color: var(--accent-ink); } }
.lightbox { position: fixed; inset: 0; z-index: 70; background: rgba(0,0,0,.85); display: grid; place-items: center; }
.lightbox img { width: 70vmin; height: 70vmin; object-fit: contain; border-radius: 14px; }
#shop-list .rows > .row + .row::before { left: 48px; }

/* Anmeldung & Registrierung */
.auth-card #auth-body { margin-top: 6px; }
.auth-card form { text-align: left; margin-top: 18px; display: grid; gap: 12px; }
.auth-h { font-size: 20px; margin: 14px 0 6px; letter-spacing: -.01em; }
.big-ico { font-size: 44px; margin-top: 18px; }
.auth-alt { margin-top: 14px; font-size: 14px; color: var(--muted); }
.auth-alt .link { margin: 0; }
.legal-links { margin-top: 28px; font-size: 12.5px; color: var(--muted); }
.legal-links a, .consent a, .link-row a { color: var(--accent); }
.note { border-radius: 12px; padding: 10px 12px; font-size: 13.5px; text-align: left; }
.note.warn { background: var(--orange-soft); color: var(--orange); }
.lbl-hint { font-weight: 500; color: var(--muted); opacity: .8; }
.pw-wrap { position: relative; display: block; }
.pw-wrap input { padding-right: 44px; }
.pw-eye { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--muted); padding: 8px; cursor: pointer; display: grid; }
.pw-eye svg { width: 19px; height: 19px; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; font-weight: 500; color: var(--ink-2); line-height: 1.4; text-align: left; }
.consent input { width: 20px; height: 20px; flex: none; margin: 0; accent-color: var(--accent); }
textarea { width: 100%; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 11px 12px; font: inherit; font-size: 16px; color: var(--ink); resize: vertical; outline: none; }
textarea:focus { border-color: var(--accent); }

/* Einstellungen */
.mini-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.mini-list li { display: flex; align-items: center; gap: 8px; font-size: 14px; min-width: 0; }
.mini-list .hint { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-list .right { margin-left: auto; flex: none; }
.avatar { width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: 13px; display: grid; place-items: center; flex: none; }
.tag { font-size: 11px; font-weight: 700; background: var(--accent-soft); color: var(--accent); border-radius: 10px; padding: 1px 7px; }
.inline-form { display: flex; gap: 8px; }
.inline-form input { flex: 1; min-width: 0; }
.link-row { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 14px; font-weight: 600; }
.set-sec .btn { justify-self: start; text-decoration: none; }
.stars { display: flex; gap: 4px; justify-content: center; margin: 4px 0 12px; }
.stars button { border: 0; background: none; font-size: 38px; line-height: 1; color: var(--line); cursor: pointer; padding: 2px; }
.stars button.on { color: #e7a92c; }
.fchips.wrap { flex-wrap: wrap; overflow: visible; margin: 0 0 12px; padding: 0; }

/* Barcode-Scanner */
.sheet h2 svg { width: 24px; height: 24px; color: var(--accent); }
.scan-box { position: relative; border-radius: 18px; overflow: hidden; background: #0d0f0e; aspect-ratio: 4 / 3; }
.scan-box video { width: 100%; height: 100%; object-fit: cover; display: block; }
.scan-frame { position: absolute; inset: 20% 10%; border-radius: 14px; box-shadow: 0 0 0 999px rgba(0,0,0,.38); border: 3px solid rgba(255,255,255,.9); }
.scan-frame i { position: absolute; left: 6%; right: 6%; top: 50%; height: 2px; background: #ff5a4f; box-shadow: 0 0 10px #ff5a4f; animation: scanline 1.6s ease-in-out infinite; }
@keyframes scanline { 0%, 100% { transform: translateY(-30px); } 50% { transform: translateY(30px); } }
.scan-st { text-align: center; font-weight: 600; margin: 12px 0 0; color: var(--ink-2); min-height: 1.4em; }
.acts .btn svg, .acts.row2 .btn svg { width: 18px; height: 18px; vertical-align: -4px; margin-right: 6px; }
.choose { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 10px; }
.choose-b { border: 0; background: var(--surface-2); border-radius: 18px; padding: 18px 12px; display: grid; justify-items: center; gap: 6px; cursor: pointer; text-align: center; }
.choose-b svg { width: 34px; height: 34px; color: var(--accent); }
.choose-b b { font-size: 15px; }
.choose-b span { font-size: 12.5px; color: var(--muted); line-height: 1.3; }
