:root {
  --red: #9b1b30;
  --red-dark: #7f1527;
  --red-soft: #fbeef0;
  --ink: #15171c;
  --ink-2: #2a2d34;
  --text: #1f2329;
  --muted: #646b76;
  --line: #e4e6ea;
  --bg: #f2f3f5;
  --card: #fff;
  --green: #18794e;
  --green-soft: #edf7f1;
  --chip: #f1f2f4;
  --radius: 12px;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.45 var(--sans); }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -0.01em; color: var(--ink); }
h1 { font-size: 30px; font-weight: 800; }
h2 { font-size: 20px; font-weight: 800; }
h3 { font-size: 17px; font-weight: 700; margin-bottom: 12px; }
p { margin: 0 0 8px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
code, pre.code { font-family: var(--mono); font-size: 12.5px; background: var(--chip); border-radius: 6px; padding: 1px 5px; }
pre.code { padding: 10px 12px; white-space: pre-wrap; word-break: break-all; margin: 4px 0 14px; }
.mono { font-family: var(--mono); font-size: 13px; letter-spacing: 0.01em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.red { color: var(--red); }
.center { text-align: center; display: block; }
.nowrap { white-space: nowrap; }
.r { text-align: right; }
.c { text-align: center; }
.ic { flex: none; vertical-align: middle; }
[hidden] { display: none !important; }

.wrap { max-width: 1480px; margin: 0 auto; padding: 0 32px; }
.main { padding-top: 24px; padding-bottom: 80px; }

/* ---------- Topbar ---------- */
.topbar { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.topbar-in { display: flex; align-items: center; gap: 28px; height: 72px; }
.logo { display: flex; align-items: center; gap: 12px; flex: none; }
.logo-mark { width: 40px; height: 40px; border-radius: 9px; background: var(--red); display: grid; place-items: center; }
.logo-text { display: flex; flex-direction: column; line-height: 1.05; }
.logo-text b { font-size: 19px; letter-spacing: 0.06em; font-weight: 900; color: var(--ink); }
.logo-text small { font-size: 12.5px; color: var(--muted); }
.mainnav { display: flex; align-items: center; gap: 4px; }
.mainnav > a, .mainnav summary { padding: 8px 14px; border-radius: 8px; font-weight: 500; color: var(--ink-2); cursor: pointer; display: flex; align-items: center; gap: 4px; }
.mainnav > a:hover, .mainnav summary:hover { background: var(--chip); }
.mainnav .active { background: var(--red-soft); color: var(--red); font-weight: 600; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.dropdown { position: relative; }
.dropdown summary { list-style: none; }
.dropdown summary::-webkit-details-marker { display: none; }
.dropdown-menu { position: absolute; top: calc(100% + 6px); left: 0; min-width: 210px; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 30px rgba(0,0,0,.12); padding: 6px; z-index: 40; }
.dropdown-menu.right { left: auto; right: 0; }
.dropdown-menu a { display: flex; gap: 8px; align-items: center; padding: 9px 12px; border-radius: 7px; }
.dropdown-menu a:hover { background: var(--chip); }
.avatar-chip { display: flex; align-items: center; gap: 8px; padding: 4px 14px 4px 4px; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; font-weight: 600; font-size: 14px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; font-size: 12.5px; font-weight: 700; }
.steps { display: flex; align-items: center; gap: 12px; margin: 0 auto; padding: 0; list-style: none; color: var(--ink-2); font-weight: 500; }
.steps li { display: flex; align-items: center; gap: 10px; }
.steps li + li::before { content: ""; width: 48px; height: 1px; background: #c9ccd2; margin-right: 2px; }
.steps li span { width: 28px; height: 28px; border-radius: 50%; border: 1px solid #c9ccd2; display: grid; place-items: center; font-size: 13px; }
.steps li.current { color: var(--red); font-weight: 600; }
.steps li.current span { background: var(--red); border-color: var(--red); color: #fff; }
.steps li.done { color: var(--green); }
.steps li.done span { background: var(--green-soft); border-color: transparent; color: var(--green); }

/* ---------- Buttons & form ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 18px; border-radius: 9px; border: 1px solid transparent; font: 600 14px/1 var(--sans); cursor: pointer; white-space: nowrap; transition: background .15s, transform .05s; }
.btn:active { transform: translateY(1px); }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-dark); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #000; }
.btn-light { background: #fff; border-color: var(--line); color: var(--ink); }
.btn-light:hover { background: var(--chip); }
.btn-link-red { background: none; color: var(--red); padding: 0 8px; }
.btn-lg { height: 54px; font-size: 16px; padding: 0 24px; }
.btn-sm { height: 34px; padding: 0 12px; font-size: 13px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; pointer-events: none; }
.badge { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: #fff; color: var(--red); font-size: 12px; font-weight: 700; display: inline-grid; place-items: center; }
.badge.light { background: #fff; color: var(--red); }
.icon-btn { background: none; border: 0; padding: 8px; border-radius: 8px; cursor: pointer; color: var(--muted); display: inline-grid; place-items: center; }
.icon-btn:hover { background: var(--chip); color: var(--ink); }
.link-red { color: var(--red); font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
a.link-red.center { display: block; text-decoration: underline; text-underline-offset: 3px; margin-top: 12px; }
.inline { display: inline; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.field > span { font-weight: 600; font-size: 14.5px; color: var(--ink); }
.field small { margin-top: -4px; }
input[type=text], input[type=search], input[type=email], input[type=password], input[type=number], input[type=date], select, textarea {
  width: 100%; height: 48px; padding: 0 14px; border: 1px solid #d5d8dd; border-radius: 9px; font: 15px var(--sans); color: var(--text); background: #fff; }
textarea { height: auto; padding: 12px 14px; resize: vertical; }
select { appearance: none; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23646b76' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center; padding-right: 36px; }
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(155,27,48,.25); border-color: var(--red); }
.has-err input, .has-err select { border-color: var(--red); }
.err-msg, .field > span.err-msg { color: var(--red); font-size: 13px; font-weight: 500; }
.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; margin: 8px 0; }
.check input { width: 18px; height: 18px; accent-color: var(--red); margin: 1px 0 0; flex: none; }
.check.boxed { background: #f6f7f8; border: 1px solid var(--line); border-radius: 9px; padding: 14px 16px; margin-bottom: 18px; }
.check.pad { padding-top: 32px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 18px; }
.grid2.top { align-items: start; gap: 18px; }

/* ---------- Cards ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.card + .card { margin-top: 14px; }
.eyebrow { font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-bottom: 12px; display: block; }
.empty { text-align: center; padding: 40px 20px; }
.tag { display: inline-block; background: var(--chip); color: var(--muted); font-size: 12px; padding: 3px 8px; border-radius: 6px; font-family: var(--mono); }
.flash { padding: 12px 16px; border-radius: 10px; margin-bottom: 16px; font-weight: 500; }
.flash-ok { background: var(--green-soft); color: var(--green); }
.flash-err { background: var(--red-soft); color: var(--red); }

/* ---------- Hero ---------- */
.hero { background: var(--ink); color: #fff; border-radius: 14px; padding: 26px 28px 22px; margin-bottom: 26px; }
.hero h1 { color: #fff; font-size: 30px; }
.hero p { color: #b8bcc4; font-size: 14px; margin: 2px 0 0; }
.hero-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 18px; }
.seg { display: inline-flex; background: #2a2d34; border-radius: 9px; padding: 4px; gap: 2px; flex: none; }
.seg button, .seg label span { border: 0; background: none; color: #d7dae0; font: 600 13px var(--sans); padding: 9px 14px; border-radius: 7px; cursor: pointer; display: block; }
.seg button.on { background: #fff; color: var(--ink); }
.seg.light { background: #f1f2f4; }
.seg.light label { cursor: pointer; }
.seg.light input { position: absolute; opacity: 0; pointer-events: none; }
.seg.light label span { color: var(--ink-2); padding: 11px 26px; font-size: 14.5px; font-weight: 500; }
.seg.light input:checked + span { background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.12); font-weight: 600; }
.searchbar { display: flex; gap: 10px; }
.search-field { flex: 1; display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 9px; padding: 0 8px 0 16px; color: var(--muted); }
.search-field input { border: 0; height: 52px; padding: 0; font-size: 16px; outline: none; background: transparent; }
.search-field input:focus { outline: none; }
.scan-btn { border: 0; background: var(--chip); border-radius: 8px; width: 40px; height: 40px; display: grid; place-items: center; color: var(--ink); cursor: pointer; }
.chips { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; font-size: 13px; color: #b8bcc4; }
.chip { background: #2a2d34; color: #fff; padding: 6px 12px; border-radius: 999px; border: 1px solid #3a3e46; font-size: 13px; }
.chip:hover { background: #3a3e46; }

/* ---------- Catalog ---------- */
.catalog { display: grid; grid-template-columns: 250px minmax(0, 1fr) 380px; gap: 24px; align-items: start; }
.sidebar .card { padding: 18px; }
.cat summary { display: flex; justify-content: space-between; align-items: center; padding: 9px 10px; border-radius: 8px; cursor: pointer; font-weight: 600; list-style: none; }
.cat summary::-webkit-details-marker { display: none; }
.cat summary:hover { background: var(--chip); }
.cat[open] summary .ic { transform: rotate(180deg); }
.cat ul { list-style: none; margin: 2px 0 8px; padding: 0; max-height: 420px; overflow: auto; }
.cat li a, .cat-link { display: flex; justify-content: space-between; gap: 8px; padding: 7px 10px 7px 14px; border-radius: 7px; font-size: 13.5px; color: var(--ink-2); }
.cat-link { font-weight: 600; padding-left: 10px; color: var(--ink); }
.cat li a small { color: var(--muted); }
.cat li a:hover, .cat-link:hover { background: var(--chip); }
.cat li a.on, .cat-link.on { background: var(--red-soft); color: var(--red); font-weight: 600; }
.filters .check { font-size: 14px; }
.results-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 12px; }
.sort { display: flex; align-items: center; gap: 8px; }
.sort select { height: 38px; width: auto; font-size: 14px; }
.prod { display: flex; align-items: center; gap: 18px; padding: 16px 18px; }
.card.prod + .card.prod { margin-top: 10px; }
.thumb { width: 72px; height: 72px; border-radius: 10px; background: #f3f4f6; flex: none; display: grid; place-items: center; overflow: hidden; color: #8a909a; }
.thumb img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.thumb.sm { width: 56px; height: 56px; }
.noimg { display: grid; place-items: center; color: #8a909a; }
.prod-info { flex: 1; min-width: 0; }
.prod-top { display: flex; align-items: center; gap: 8px; }
.inlist { background: var(--red-soft); color: var(--red); font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 999px; display: inline-flex; align-items: center; gap: 3px; }
.fav-dot { color: var(--red); display: inline-flex; }
.prod-name { display: block; font-weight: 600; color: var(--ink); margin: 1px 0 2px; overflow-wrap: anywhere; }
a.prod-name:hover { color: var(--red); }
.prod-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--ink-2); }
.prod-loc { font-size: 13px; color: var(--ink-2); margin-top: 5px; }
.loc { font-family: var(--mono); font-size: 12.5px; background: var(--chip); padding: 3px 7px; border-radius: 6px; font-weight: 600; color: var(--ink); white-space: nowrap; }
.stock { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.stock i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.stock.in { color: var(--green); }
.stock.out { color: var(--red); }
.prod-add { display: flex; gap: 10px; align-items: center; flex: none; }
.stepper { display: inline-flex; align-items: center; border: 1px solid #d5d8dd; border-radius: 9px; height: 42px; background: #fff; }
.stepper button { background: none; border: 0; width: 38px; height: 100%; cursor: pointer; color: var(--ink); display: grid; place-items: center; }
.stepper input { width: 46px; height: 100%; border: 0; text-align: center; font-weight: 600; padding: 0; -moz-appearance: textfield; }
.stepper input:focus { outline: none; }
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepper.lg { height: 58px; }
.stepper.lg button { width: 50px; }
.stepper.lg input { width: 60px; font-size: 18px; }
.add-mini { display: none; }
.pager { display: flex; justify-content: center; gap: 8px; margin: 22px 0; }
.pg { min-width: 40px; height: 40px; padding: 0 12px; border-radius: 9px; border: 1px solid var(--line); background: #fff; display: grid; place-items: center; font-weight: 600; font-size: 14px; }
.pg.current { background: var(--ink); color: #fff; border-color: var(--ink); }
.pg.dots { border: 0; background: none; }
.cart-side { position: sticky; top: 96px; }
.cart-panel-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.cart-panel-head h3 { margin: 0; }
.mini-list { list-style: none; padding: 0; margin: 0 0 16px; max-height: 50vh; overflow: auto; }
.mini-list li { display: flex; gap: 12px; align-items: flex-start; padding: 11px 0; border-bottom: 1px solid var(--line); }
.mini-list li > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.mini-name { font-size: 13.5px; color: var(--ink); font-weight: 500; }
.qty-pill { background: var(--chip); border-radius: 6px; padding: 4px 8px; font-weight: 700; font-size: 13px; flex: none; min-width: 34px; text-align: center; }
.mini-list .x { background: none; border: 0; color: var(--muted); cursor: pointer; padding: 4px; }
.mini-list .x:hover { color: var(--red); }
.mobile-tabs, .mobile-cart, .mobile-cart-wrap, .show-sm, .show-sm-inline { display: none; }

/* ---------- Detail ---------- */
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 18px; color: var(--ink-2); }
.crumbs .sep { color: var(--muted); }
.detail { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; align-items: start; }
.detail-photo { aspect-ratio: 1.15; display: grid; place-items: center; position: relative; padding: 24px; }
.detail-photo img { max-width: 100%; max-height: 560px; object-fit: contain; }
.detail-photo .tag { position: absolute; left: 20px; bottom: 20px; }
.detail-main h1 { font-size: 36px; margin: 6px 0 22px; overflow-wrap: anywhere; }
.detail-main .mono.red { font-size: 15px; font-weight: 600; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; margin-bottom: 18px; }
.tile { background: #f3f4f6; border-radius: 10px; padding: 12px 14px; }
.tile small { display: block; color: var(--muted); font-size: 13px; }
.tile b { font-size: 22px; font-weight: 600; color: var(--ink); }
.tile.green { background: var(--green-soft); }
.tile.green small, .tile.green b { color: var(--green); }
.tile.redtile { background: var(--red-soft); }
.tile.redtile small, .tile.redtile b { color: var(--red); }
.detail-add { display: flex; gap: 14px; margin-top: 18px; }
.grow { flex: 1; }
.fav-btn { width: 58px; padding: 0; }
.fav-btn.on { color: var(--red); border-color: var(--red); background: var(--red-soft); }
.fav-btn.on .ic { fill: currentColor; }
.inlist-line { color: var(--red); font-weight: 500; display: flex; gap: 6px; align-items: center; }
.variants { display: flex; flex-wrap: wrap; gap: 8px; }
.variant { border: 1px solid #d5d8dd; border-radius: 9px; padding: 10px 16px; font-weight: 600; }
.variant:hover { border-color: var(--ink); }
.variant.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.specs { display: grid; grid-template-columns: 160px 1fr; gap: 10px 16px; margin: 0; }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; }

/* ---------- Checkout ---------- */
.checkout { display: grid; grid-template-columns: minmax(0, 1fr) 385px; gap: 26px; align-items: start; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.head-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.table-card { padding: 0; overflow: hidden; }
.list-table { width: 100%; border-collapse: collapse; }
.list-table th { text-align: left; font-size: 12px; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); font-weight: 600; padding: 14px 20px; background: #fafafb; border-bottom: 1px solid var(--line); }
.list-table td { padding: 14px 20px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.list-table tr:last-child td { border-bottom: 0; }
.list-table th.c, .list-table td.c { text-align: center; }
.list-table th.r, .list-table td.r { text-align: right; }
.list-table.compact td { padding: 7px 10px 7px 0; vertical-align: top; }
.list-table.clickable tbody tr { cursor: pointer; }
.list-table.clickable tbody tr:hover { background: #fafafb; }
.list-table tr.inactive { opacity: .55; }
.line-art { display: flex; gap: 16px; align-items: center; }
.line-art > div { display: flex; flex-direction: column; min-width: 0; }
.summary h3 { font-size: 21px; }
.summary-head { display: flex; justify-content: space-between; align-items: baseline; }
.sum-rows { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin: 0 0 18px; color: var(--ink-2); }
.sum-rows dd { margin: 0; font-weight: 700; color: var(--ink); }
.sticky { position: sticky; top: 96px; }
.share-box { margin-bottom: 14px; background: var(--green-soft); border-color: #cfe9da; }
.copy-row { display: flex; gap: 10px; }
.form-card h3.sec { display: flex; align-items: center; gap: 12px; font-size: 18px; margin-bottom: 18px; }
.form-card h3.sec span { width: 28px; height: 28px; border-radius: 7px; background: var(--ink); color: #fff; display: grid; place-items: center; font-size: 13px; }
.form-card.narrow { max-width: 720px; }
.form-card h3:not(.sec) { margin-top: 8px; }
.start-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.inline-field { display: flex; align-items: center; gap: 12px; font-weight: 500; }
.inline-field input { width: 180px; }
.row-actions { display: flex; gap: 10px; justify-content: flex-end; }
.dialog { border: 0; border-radius: 14px; padding: 24px; width: min(520px, calc(100vw - 32px)); box-shadow: 0 30px 60px rgba(0,0,0,.25); }
.dialog::backdrop { background: rgba(15,17,21,.45); }
.dialog-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 8px; }

/* ---------- Done ---------- */
.done { max-width: 720px; margin: 40px auto; text-align: center; }
.done-check { width: 84px; height: 84px; border-radius: 50%; background: var(--green-soft); color: var(--green); display: grid; place-items: center; margin: 0 auto 20px; }
.done h1 { font-size: 38px; margin-bottom: 12px; }
.done > p { font-size: 17px; }
.done-card { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; text-align: left; margin: 26px 0; }
.done-card .eyebrow { margin-bottom: 4px; }
.done-card b { font-size: 17px; }
.done-card b.big { font-size: 20px; }
.done-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.order-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.order-grid .eyebrow { margin-bottom: 3px; }

/* ---------- Admin ---------- */
.subnav { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 20px; overflow-x: auto; }
.subnav a { padding: 10px 14px; font-weight: 600; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.subnav a.on { color: var(--red); border-color: var(--red); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-bottom: 18px; }
.stats .card + .card { margin-top: 0; }
.stat small { color: var(--muted); display: block; }
.stat b { font-size: 26px; font-weight: 800; color: var(--ink); }
.filterbar { display: flex; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; align-items: center; }
.filterbar input[type=search] { max-width: 380px; height: 42px; }
.filterbar input[type=date] { height: 42px; width: auto; }
.filterbar label { display: flex; gap: 6px; align-items: center; }

/* ---------- Login ---------- */
.page-login .main { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.login { width: min(440px, 100%); }
.login-logo { display: flex; justify-content: center; margin-bottom: 22px; }
.login-card h1 { font-size: 26px; margin-bottom: 6px; }
.login-card .flash { margin-top: 12px; }
.login-card > p.muted { margin-bottom: 20px; }

/* ---------- Toast & scanner ---------- */
.toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 10px; font-weight: 500; opacity: 0; pointer-events: none; transition: .2s; z-index: 60; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.scanner { position: fixed; inset: 0; background: rgba(0,0,0,.85); z-index: 70; display: grid; place-items: center; }
.scanner-box { text-align: center; color: #fff; width: min(480px, 92vw); }
.scanner video { width: 100%; border-radius: 12px; background: #000; aspect-ratio: 4/3; object-fit: cover; }
.scanner p { margin: 14px 0; }

/* ---------- Responsive ---------- */
@media (max-width: 1280px) {
  .catalog { grid-template-columns: 230px minmax(0, 1fr); }
  .cart-side { display: none; }
  .mobile-cart { display: flex; }
}
@media (max-width: 900px) {
  .wrap { padding: 0 16px; }
  .topbar-in { height: 64px; gap: 12px; }
  .mainnav { display: none; position: absolute; top: 64px; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); flex-direction: column; align-items: stretch; padding: 8px 16px 14px; }
  .mainnav.open { display: flex; }
  .mainnav .dropdown-menu { position: static; box-shadow: none; border: 0; padding: 0 0 0 12px; }
  .hide-sm { display: none !important; }
  .show-sm { display: inline-grid; }
  .show-sm-inline { display: inline; }
  .steps { gap: 6px; font-size: 13px; }
  .steps li + li::before { width: 12px; }
  .steps li:not(.current) { font-size: 0; gap: 0; }
  .catalog, .checkout, .detail { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .main { padding-top: 0; padding-bottom: 110px; }
  .page-login .main, .checkout { padding-top: 16px; }
  .page-catalog .main { padding: 0 0 110px; }
  .page-catalog .results { padding: 0 16px; }
  .hero { border-radius: 0; padding: 14px 16px 16px; margin: 0 0 0; }
  .hero-top { margin-bottom: 12px; flex-direction: column; }
  .hero h1 { font-size: 22px; }
  .hero p, .chips, .searchbar .btn { display: none; }
  .seg { width: 100%; }
  .seg button { flex: 1 1 auto; padding: 8px 4px; font-size: 12.5px; min-width: 0; }
  .search-field input { height: 50px; }
  .mobile-tabs { display: flex; gap: 8px; overflow-x: auto; padding: 14px 16px 6px; scrollbar-width: none; }
  .mobile-tabs a { flex: none; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); background: #fff; font-weight: 600; font-size: 14px; }
  .mobile-tabs a.on { background: var(--ink); color: #fff; border-color: var(--ink); }
  .results-head { margin: 4px 0 10px; }
  .results-head h2 { font-size: 16px; }
  .sort label { display: none; }
  .prod { padding: 14px; gap: 12px; align-items: center; }
  .prod .thumb { width: 60px; height: 60px; }
  .prod-loc { display: none; }
  .prod-add .stepper, .prod-add .add-btn { display: none; }
  .add-mini { display: grid; place-items: center; width: 50px; height: 50px; border-radius: 10px; border: 0; background: var(--ink); color: #fff; font-weight: 700; font-size: 18px; cursor: pointer; }
  .add-mini.has { background: var(--red); }
  .mobile-cart { display: flex; position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 35; height: 58px; border-radius: 12px; background: var(--red); color: #fff; font: 700 17px var(--sans); align-items: center; gap: 12px; padding: 0 20px; border: 0; box-shadow: 0 10px 30px rgba(155,27,48,.35); justify-content: flex-start; cursor: pointer; }
  .mobile-cart .ic { margin-left: auto; }
  .mobile-cart-wrap { display: block; }
  .checkout aside .btn-lg { display: none; }
  .checkout aside .summary .mini-list { max-height: none; }
  .detail-main h1 { font-size: 26px; }
  .detail-add { flex-wrap: wrap; }
  .detail-add .grow { order: 3; flex-basis: 100%; }
  .grid2, .grid3, .order-grid, .done-card { grid-template-columns: 1fr; }
  .list-table th, .list-table td { padding: 12px 14px; }
  .list-table thead { display: none; }
  .head-actions .btn { height: 38px; padding: 0 12px; }
  h1 { font-size: 24px; }
  .specs { grid-template-columns: 120px 1fr; }
  .done h1 { font-size: 28px; }
  .cart-btn { display: none; }
  .steps-mode .logo-text { display: none; }
  .list-table.cart tbody tr { display: grid; grid-template-columns: 1fr auto; align-items: center; border-bottom: 1px solid var(--line); }
  .list-table.cart tbody tr:last-child { border-bottom: 0; }
  .list-table.cart td { border: 0; padding: 10px 14px; }
  .list-table.cart td:first-child { grid-column: 1 / -1; padding-bottom: 0; }
  .list-table.cart td.c:last-child { text-align: right; }
  .list-table.cart .line-art .thumb { display: none; }
}
@media (min-width: 901px) {
  .mainnav .dropdown-menu { display: block; }
  .mainnav details:not([open]) .dropdown-menu { display: none; }
}

/* ---------- Voertuigen ---------- */
.vehicles { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; align-items: start; }
.vehicle-list { padding: 10px; display: flex; flex-direction: column; max-height: calc(100vh - 140px); overflow: auto; position: sticky; top: 96px; }
.vehicle-list a { display: flex; justify-content: space-between; padding: 9px 12px; border-radius: 8px; font-weight: 600; }
.vehicle-list a small { color: var(--muted); font-weight: 500; }
.vehicle-list a:hover { background: var(--chip); }
.vehicle-list a.on { background: var(--red-soft); color: var(--red); }
.vehicle-title { margin-bottom: 12px; }
@media (max-width: 900px) {
  .vehicles { grid-template-columns: 1fr; }
  .vehicle-list { flex-direction: row; overflow-x: auto; position: static; max-height: none; }
  .vehicle-list a { flex: none; gap: 6px; }
}
.page-head .filterbar { margin: 0; flex-wrap: nowrap; }
.page-head .filterbar input[type=search] { width: 320px; }
@media (max-width: 900px) { .page-head .filterbar, .page-head .filterbar input[type=search] { width: 100%; max-width: none; } }

/* Gedeelde lijsten */
.list-search { display: flex; gap: 8px; }
.list-search input { width: 280px; }
.list-table td .show-sm { display: none; }
.list-add { margin-bottom: 14px; }
.list-add-form { display: flex; gap: 12px; align-items: flex-end; }
.list-add-form .field { margin-bottom: 0; flex: 1; }
.list-add-form .field.qty { flex: 0 0 96px; }
.list-merge { margin-top: 12px; }
.list-log { margin-top: 14px; }
.list-log h3 { font-size: 17px; margin-bottom: 10px; }
.list-log ul { list-style: none; margin: 0; padding: 0; max-height: 420px; overflow: auto; }
.list-log li { padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; line-height: 1.4; }
.list-log li:first-child { border-top: 0; padding-top: 0; }
.list-log time { display: block; }
@media (max-width: 900px) {
  .list-search, .list-search input { width: 100%; }
  .list-table td .show-sm { display: block; }
  .list-add-form { flex-wrap: wrap; }
  .list-add-form .field:first-of-type { flex-basis: 100%; }
  .list-merge .btn { white-space: normal; text-align: left; height: auto; padding-top: 8px; padding-bottom: 8px; }
  .list-add-form .btn { flex: 1; }
}
.suggest-wrap { position: relative; }
.suggest { position: absolute; top: 100%; left: 0; right: 0; margin-top: 4px; z-index: 40; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 16px 40px rgba(0,0,0,.14); max-height: 420px; overflow: auto; padding: 4px; }
.suggest p { padding: 10px 12px; margin: 0; }
.suggest button { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 12px; align-items: center; width: 100%; padding: 8px; border: 0; background: none; border-radius: 8px; text-align: left; cursor: pointer; font: inherit; color: var(--ink); }
.suggest button:hover, .suggest button.on { background: var(--bg, #f2f3f5); }
.suggest .thumb.sm { width: 44px; height: 44px; }
.suggest .mini-name { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-weight: 600; font-size: 14.5px; line-height: 1.3; overflow: hidden; }
.suggest .stock { font-size: 13px; white-space: nowrap; }
.to-list-btn { margin-top: 12px; }
.in-lists { margin: 10px 0 0; }
