/* OrderHub v2 · Clean SaaS hybrid design system (white-label ready) */
:root {
  --brand: #DE1316;
  --brand-hover: #B91012;
  --brand-subtle: #FDF2F2;
  --brand-muted: #F5C2C3;
  --primary: var(--brand);
  --primary-hover: var(--brand-hover);
  --primary-subtle: var(--brand-subtle);
  --primary-muted: var(--brand-muted);
  --surface: #FFFFFF;
  --surface-raised: #FAFAFB;
  --surface-sunken: #F4F4F5;
  --border: #E4E4E7;
  --border-strong: #D4D4D8;
  --text: #09090B;
  --text-secondary: #52525B;
  --text-muted: #A1A1AA;
  --success: #16A34A;
  --success-subtle: #F0FDF4;
  --warning: #CA8A04;
  --warning-subtle: #FEFCE8;
  --danger: #DC2626;
  --danger-subtle: #FEF2F2;
  --danger-muted: #FECACA;
  --info: #2563EB;
  --info-subtle: #EFF6FF;
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 14px;
  --radius-full: 999px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.04);
  --shadow: 0 1px 3px rgba(0,0,0,.06), 0 4px 12px rgba(0,0,0,.04);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --sidebar-w: 240px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: var(--font); background: var(--surface-sunken); color: var(--text); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; touch-action: manipulation; }

.skip-link {
  position: absolute;
  left: 12px;
  top: -48px;
  z-index: 100;
  padding: 8px 14px;
  background: var(--text);
  color: #fff;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  transition: top .15s ease;
}
.skip-link:focus {
  top: 12px;
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .mapbox-pin--rider .mapbox-pin-badge,
  .mapbox-pin--rider .mapbox-pin-dot { animation: none; }
  .track-leaflet-pin.rider .track-leaflet-pin-inner { animation: none; }
  .menu-card:hover { transform: none; }
}

.btn:focus-visible,
.fulfil-seg button:focus-visible,
.fulfil-seg a:focus-visible,
.cat-rail a:focus-visible,
.shop-nav-links a:focus-visible,
.btn-cart:focus-visible,
.menu-banner-nav:focus-visible,
.seg a:focus-visible,
.star-rate button:focus-visible,
.tag-chip:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.menu-banner-nav:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}
[x-cloak] { display: none !important; }
a { color: inherit; text-decoration: none; }
h1 { font-size: 24px; font-weight: 600; letter-spacing: -.02em; }
h2 { font-size: 15px; font-weight: 600; }
h3 { font-size: 14px; font-weight: 600; }

/* Status dots */
.status-dot { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.status-dot::before { content: ""; width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.status-dot.success::before { background: var(--success); }
.status-dot.warning::before { background: var(--warning); }
.status-dot.danger::before { background: var(--danger); }
.status-dot.muted::before { background: var(--text-muted); }

/* Badges */
.badge { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: var(--radius-full); font-size: 11.5px; font-weight: 500; border: 1px solid transparent; white-space: nowrap; }
.badge.success { background: var(--success-subtle); color: var(--success); border-color: #BBF7D0; }
.badge.warning { background: var(--warning-subtle); color: #A16207; border-color: #FEF08A; }
.badge.danger { background: var(--danger-subtle); color: var(--danger); border-color: #FECACA; }
.badge.info { background: var(--info-subtle); color: var(--info); border-color: #BFDBFE; }
.badge.neutral { background: var(--surface-sunken); color: var(--text-secondary); border-color: var(--border); }
.badge.brand { background: var(--brand-subtle); color: var(--brand-hover); border-color: var(--brand-muted); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 36px; padding: 0 14px; border-radius: var(--radius-sm); font-size: 13px; font-weight: 500; border: 1px solid transparent; cursor: pointer; font-family: var(--font); white-space: nowrap; line-height: 1; box-sizing: border-box; }
.btn.primary { background: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-hover); }
.btn.secondary { background: var(--surface); border-color: var(--border); color: var(--text); }
.btn.secondary:hover { background: var(--surface-raised); border-color: var(--border-strong); }
.btn.ghost { background: transparent; color: var(--text-secondary); }
.btn.ghost:hover { background: var(--surface-sunken); color: var(--text); }
.btn.danger { background: var(--danger-subtle); color: var(--danger); border-color: var(--danger-muted); }
.btn.danger:hover { background: color-mix(in srgb, var(--danger-subtle) 70%, var(--danger-muted)); }
.btn.ghost.danger { background: transparent; border-color: transparent; color: var(--danger); }
.btn.ghost.danger:hover { background: var(--danger-subtle); color: var(--danger); }
.btn.sm { min-height: 30px; padding: 0 10px; font-size: 12px; }
.btn.lg { padding: 11px 20px; font-size: 14px; }
.btn.block { width: 100%; }
.btn.icon { padding: 8px; }

/* Cards */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.card-pad { padding: 20px; }
.card + .card { margin-top: 16px; }
.grid > .card + .card { margin-top: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.card-head h2 { margin: 0; }

/* Layout utilities */
.flex { display: flex; align-items: center; gap: 10px; }
.flex.between { justify-content: space-between; }
.flex.wrap { flex-wrap: wrap; }
.stack > * + * { margin-top: 10px; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: 1fr 1fr; align-items: stretch; }
.grid-2 > .card { display: flex; flex-direction: column; min-height: 100%; align-self: stretch; }
.grid-3 { grid-template-columns: repeat(3, 1fr); align-items: stretch; }
.grid-3 > .card { display: flex; flex-direction: column; min-height: 100%; align-self: stretch; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.gap-sm { gap: 8px; }
.mt-0 { margin-top: 0; }
.mt-6 { margin-top: 6px; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: 8px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.muted { color: var(--text-muted); }
.small { font-size: 12.5px; }
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.num { text-align: right; font-variant-numeric: tabular-nums; }
.link { color: var(--brand); font-weight: 500; transition: color .15s ease; }
.link:hover { color: var(--brand-hover); }

/* KPI */
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 16px 18px; box-shadow: var(--shadow-sm); }
.kpi .label { font-size: 12px; color: var(--text-muted); font-weight: 500; }
.kpi .value { font-size: 28px; font-weight: 600; letter-spacing: -.02em; margin: 4px 0 2px; }
.kpi .value.is-compact { font-size: 20px; }
.kpi .value.is-warning { color: var(--warning); }
.kpi .value.is-danger { color: var(--danger); }
.kpi .delta { font-size: 12px; color: var(--text-secondary); }
.kpi .delta.up { color: var(--success); }
.kpi .delta.down { color: var(--danger); }

.kpi.clickable { cursor: pointer; text-align: left; font-family: var(--font); width: 100%; }
.kpi.clickable:hover { border-color: var(--border-strong); }
.kpi.clickable.is-active { border-color: var(--warning); box-shadow: 0 0 0 2px var(--warning-subtle); }
.badge.chip-filter {
  cursor: pointer; font-family: var(--font);
  transition: box-shadow .12s, border-color .12s;
}
.badge.chip-filter:hover { box-shadow: 0 0 0 2px rgba(0,0,0,.06); }
.badge.chip-filter.is-active {
  box-shadow: 0 0 0 2px currentColor;
  outline: none;
}
.kpi.attention { background: var(--danger-subtle); border-color: var(--danger-muted); }
.kpi.attention .label { color: var(--danger); }

/* Tables */
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; }
table.data th { text-align: left; font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: .04em; color: var(--text-muted); padding: 10px 14px; border-bottom: 1px solid var(--border); background: var(--surface-raised); }
table.data th .table-sort {
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  color: inherit;
  cursor: pointer;
  display: block;
  width: 100%;
  text-align: inherit;
}
table.data th .table-sort:hover { color: var(--text); }
table.data th .table-sort-label { display: inline; }
table.data th .table-sort-indicator {
  color: var(--brand);
  font-size: 10px;
  width: 10px;
  text-align: center;
}
table.data.pos-catalogue-table th {
  position: relative;
}
table.data.pos-catalogue-table th .table-sort {
  padding-right: 14px;
}
table.data.pos-catalogue-table th .table-sort-indicator {
  position: absolute;
  top: 50%;
  right: 14px;
  transform: translateY(-50%);
}
table.data.pos-catalogue-table th.num .table-sort {
  padding-right: 24px;
}
table.data.pos-catalogue-table {
  table-layout: fixed;
}
table.data.pos-catalogue-table th:nth-child(1),
table.data.pos-catalogue-table td:nth-child(1) { width: 44px; }
table.data.pos-catalogue-table th:nth-child(2),
table.data.pos-catalogue-table td:nth-child(2) { width: 12%; }
table.data.pos-catalogue-table th:nth-child(3),
table.data.pos-catalogue-table td:nth-child(3) { width: 34%; }
table.data.pos-catalogue-table th:nth-child(4),
table.data.pos-catalogue-table td:nth-child(4) { width: 10%; }
table.data.pos-catalogue-table th:nth-child(5),
table.data.pos-catalogue-table td:nth-child(5) { width: 8%; }
table.data.pos-catalogue-table th:nth-child(6),
table.data.pos-catalogue-table td:nth-child(6) { width: 12%; }
table.data.pos-catalogue-table th:nth-child(7),
table.data.pos-catalogue-table td:nth-child(7) { width: 24%; }
table.data.pos-catalogue-table td:nth-child(2) {
  font-variant-numeric: tabular-nums;
}
table.data.pos-catalogue-table td:nth-child(3) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
table.data.pos-catalogue-table-import {
  table-layout: fixed;
}
table.data.pos-catalogue-table-import th:nth-child(1),
table.data.pos-catalogue-table-import td:nth-child(1) {
  width: 36px;
  padding-left: 10px;
  padding-right: 4px;
}
table.data.pos-catalogue-table-import th:nth-child(2),
table.data.pos-catalogue-table-import td:nth-child(2) {
  width: 72px;
  padding-left: 4px;
}
table.data.pos-catalogue-table-import th:nth-child(3),
table.data.pos-catalogue-table-import td:nth-child(3) { width: 42%; }
table.data.pos-catalogue-table-import th:nth-child(4),
table.data.pos-catalogue-table-import td:nth-child(4) { width: 10%; }
table.data.pos-catalogue-table-import th:nth-child(5),
table.data.pos-catalogue-table-import td:nth-child(5) { width: 12%; }
table.data.pos-catalogue-table-import th:nth-child(6),
table.data.pos-catalogue-table-import td:nth-child(6) { width: 16%; }
table.data.pos-catalogue-table-import td:nth-child(2),
table.data.pos-catalogue-table-import td:nth-child(4),
table.data.pos-catalogue-table-import td:nth-child(5) {
  white-space: nowrap;
}
table.data.pos-catalogue-table-import td:nth-child(2) {
  font-variant-numeric: tabular-nums;
}
table.data.pos-catalogue-table-import td:nth-child(4) {
  font-variant-numeric: tabular-nums;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
table.data.pos-catalogue-table-import td.pos-catalogue-status {
  white-space: nowrap;
}
table.data.pos-catalogue-table-import td.pos-catalogue-status .badge + .badge {
  margin-left: 6px;
}
table.data th.num { text-align: right; }
table.data td { padding: 12px 14px; border-bottom: 1px solid var(--border); font-size: 13px; vertical-align: middle; }
table.data tr:last-child td { border-bottom: none; }
table.data tbody tr:hover td { background: var(--surface-raised); }
table.data tr.row-alert td { background: var(--danger-subtle); }
table.data tr.row-warn td { background: var(--warning-subtle); }

/* Forms */
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12px; font-weight: 500; margin-bottom: 5px; color: var(--text-secondary); }
.field input, .field select, .field textarea {
  width: 100%; padding: 0 12px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 13px; font-family: var(--font); background: var(--surface); color: var(--text);
  min-height: 36px; box-sizing: border-box;
}
.field textarea { min-height: 80px; padding-top: 9px; padding-bottom: 9px; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--brand-subtle); border-color: var(--brand);
}
.form-row { display: flex; gap: 14px; }
.form-row .field { flex: 1; }
.hint { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.hint.danger { color: var(--danger); }
.hint.success { color: var(--success); }
.back-link { display: inline-block; margin-bottom: 8px; }
.page-head h1.flush { margin: 0; }
table.data td.text-danger { color: var(--danger); }

/* Toggle */
.switch { position: relative; display: inline-block; width: 36px; height: 20px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .track { position: absolute; inset: 0; background: var(--border-strong); border-radius: var(--radius-full); cursor: pointer; transition: .15s; }
.switch .track::before { content: ""; position: absolute; width: 16px; height: 16px; left: 2px; top: 2px; background: #fff; border-radius: 50%; transition: .15s; box-shadow: var(--shadow-sm); }
.switch input:checked + .track { background: var(--success); }
.switch input:checked + .track::before { transform: translateX(16px); }

.fulfilment-toggles {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 148px;
  padding: 2px 0;
}
.hours-list { display: flex; flex-direction: column; }
.hours-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.hours-row:last-child { border-bottom: none; }
.hours-day {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 140px;
}
.hours-day.hours-holiday { min-width: 240px; }
.exclusion-list { display: flex; flex-direction: column; gap: 10px; }
.exclusion-row {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-raised);
  flex-wrap: wrap;
}
.exclusion-row .exclusion-remove { margin-bottom: 2px; flex-shrink: 0; }
.exclusion-map {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
}
.exclusion-map-surface {
  position: relative;
  height: 280px;
  background: linear-gradient(145deg, #E8E4DF 0%, #D4D0CB 40%, #C8D4D8 100%);
}
.exclusion-map-surface::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 30% 40%, rgba(255,255,255,.4) 0%, transparent 50%),
    radial-gradient(circle at 70% 60%, rgba(255,255,255,.3) 0%, transparent 40%);
}
.exclusion-map-radius {
  position: absolute;
  top: 50%;
  left: 48%;
  width: 210px;
  height: 210px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 2px dashed var(--brand);
  background: rgba(232, 93, 42, .12);
  z-index: 1;
}
.exclusion-map-surface .map-pin { z-index: 2; }
.exclusion-zone-mark {
  position: absolute;
  z-index: 2;
  min-width: 64px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  background: var(--danger-subtle);
  border: 1px solid var(--danger);
  color: var(--danger);
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.exclusion-map-surface .map-label {
  position: absolute;
  z-index: 2;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
}
.exclusion-map-legend {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-top: 1px solid var(--border);
  background: var(--surface-raised);
  font-size: 12px;
  color: var(--text-secondary);
}
.exclusion-map-legend span { display: inline-flex; align-items: center; gap: 6px; }
.lg-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.lg-dot.radius { background: color-mix(in srgb, var(--brand) 35%, transparent); border: 1.5px dashed var(--brand); }
.lg-dot.excluded { background: var(--danger); }
.lg-dot.store { background: var(--brand); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--brand); }
.collapse-block > .collapse-summary {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  user-select: none;
}
.collapse-block > .collapse-summary::-webkit-details-marker { display: none; }
.collapse-block > .collapse-summary h2 { margin: 0; flex: 1; }
.collapse-meta { margin-left: auto; }
.collapse-chevron {
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--text-muted);
  border-bottom: 2px solid var(--text-muted);
  transform: rotate(45deg);
  transition: transform .15s ease;
  flex-shrink: 0;
  margin-left: 4px;
}
.collapse-block[open] > .collapse-summary .collapse-chevron {
  transform: rotate(-135deg);
}
.collapse-block[open] > .collapse-summary {
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.hours-times {
  display: flex;
  gap: 12px;
  flex: 1;
  max-width: 360px;
}
.hours-times .field { flex: 1; }
.fulfilment-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 12.5px;
  color: var(--text-secondary);
}
.fulfilment-toggle > span {
  font-weight: 500;
  min-width: 72px;
}

/* Tabs */
.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--border); margin-bottom: 20px; }
.tabs a, .tabs button { padding: 10px 16px; font-size: 13px; font-weight: 500; color: var(--text-muted); border-bottom: 2px solid transparent; margin-bottom: -1px; background: none; border-top: none; border-left: none; border-right: none; cursor: pointer; font-family: var(--font); white-space: nowrap; }
.tabs a:hover, .tabs button:hover { color: var(--text); }
.tabs a.active, .tabs button.active { color: var(--text); border-color: var(--brand); }
.tabs a.active, .tabs button.active { font-weight: 600; }
.tabs.scroll { overflow-x: auto; flex-wrap: nowrap; }

/* Segmented control */
.seg { display: inline-flex; background: var(--surface-sunken); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 3px; }
.seg button, .seg a { padding: 7px 16px; border: none; background: transparent; border-radius: 5px; font-size: 13px; font-weight: 500; color: var(--text-secondary); cursor: pointer; font-family: var(--font); }
.seg .active { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }

/* Meter / progress */
.meter { background: var(--surface-sunken); border-radius: var(--radius-full); height: 6px; overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--brand); border-radius: var(--radius-full); }
.meter.success > span { background: var(--success); }

/* Bar chart */
.bars { display: flex; align-items: flex-end; gap: 10px; height: 140px; padding-top: 8px; }
.bars .bar-group { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.bars .pair { display: flex; gap: 3px; align-items: flex-end; height: 100%; }
.bars .bar { width: 14px; border-radius: 3px 3px 0 0; background: var(--brand); opacity: .85; }
.bars .bar.alt { background: var(--text-secondary); opacity: .5; }
.bars .x-label { font-size: 11px; color: var(--text-muted); }
.bars-fill { height: auto; flex: 1; min-height: 160px; }
.chart-card { display: flex; flex-direction: column; height: 100%; }
.table-fill { flex: 1; display: flex; flex-direction: column; justify-content: center; }
.table-fill table.data { height: 100%; }
.table-fill table.data td { padding-top: 14px; padding-bottom: 14px; }
.chart-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); }
.chart-stat { min-width: 0; }
.funnel-fill { flex: 1; display: flex; align-items: center; justify-content: center; min-height: 0; padding: 2px 0; }
.funnel-viz { width: 100%; max-width: 268px; display: flex; flex-direction: column; gap: 9px; }
.funnel-stage { display: grid; grid-template-columns: 64px 1fr 34px; align-items: center; gap: 8px; }
.funnel-name { font-size: 12px; font-weight: 500; color: var(--text-secondary); }
.funnel-pct { font-size: 11px; color: var(--text-muted); text-align: right; font-variant-numeric: tabular-nums; }
.funnel-track {
  display: flex; justify-content: center; align-items: center;
  height: 34px; background: var(--surface-sunken); border-radius: 8px; padding: 0 6px;
}
.funnel-bar {
  height: 26px; min-width: 52px; border-radius: 5px; background: var(--brand);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums;
  box-shadow: 0 1px 2px rgba(0,0,0,.06);
  transition: width .2s ease;
}
.funnel-stage:nth-child(2) .funnel-bar:not(.delivered) { opacity: .92; }
.funnel-stage:nth-child(3) .funnel-bar:not(.delivered) { opacity: .84; }
.funnel-bar.delivered { background: var(--success); opacity: 1; }
.funnel-footnote {
  margin-top: auto; padding-top: 12px; border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 11.5px;
}
.funnel-footnote .loss { color: var(--danger); font-weight: 600; white-space: nowrap; }
.funnel-footnote .muted { line-height: 1.35; }

.legend { display: flex; gap: 16px; font-size: 12px; color: var(--text-secondary); }
.legend .dot { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 5px; }

/* Steps */
.steps { display: flex; gap: 0; }
.steps .step { flex: 1; text-align: center; font-size: 11.5px; color: var(--text-muted); position: relative; padding-top: 24px; }
.steps .step::before { content: ""; width: 16px; height: 16px; border-radius: 50%; background: var(--border); position: absolute; top: 0; left: 50%; transform: translateX(-50%); }
.steps .step.done::before, .steps .step.now::before { background: var(--brand); }
.steps .step.now { color: var(--brand); font-weight: 600; }
.steps .step::after { content: ""; position: absolute; top: 7px; left: -50%; width: 100%; height: 2px; background: var(--border); z-index: -1; }
.steps .step:first-child::after { display: none; }
.steps .step.done::after { background: var(--brand); }
.steps.timed .step { padding-top: 28px; padding-bottom: 4px; font-size: 11px; line-height: 1.3; }
.steps.timed .step-label { display: block; }
.steps.timed .step-time { font-size: 10px; color: var(--text-muted); margin-top: 3px; font-variant-numeric: tabular-nums; }
.steps.timed .step.now .step-time { color: var(--brand); font-weight: 500; }
.steps.timed .step.done .step-time { color: var(--text-secondary); }

/* Alert strip */
.alert { display: flex; align-items: flex-start; gap: 10px; padding: 12px 16px; border-radius: var(--radius); font-size: 13px; border: 1px solid; }
.alert.warning { background: var(--warning-subtle); border-color: #FEF08A; color: #854D0E; }
.alert.danger { background: var(--danger-subtle); border-color: var(--danger-muted); color: #991B1B; }
.alert.info { background: var(--info-subtle); border-color: #BFDBFE; color: #1E40AF; }
.alert.loyalty-perk-alert {
  background: #09090B;
  border-color: #09090B;
  color: #fff;
}
.alert.loyalty-perk-alert strong { color: #fff; }

/* Avatar */
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--brand-subtle); color: var(--brand-hover); display: inline-grid; place-items: center; font-weight: 600; font-size: 11px; flex-shrink: 0; }

/* Search */
.search input { padding: 0 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 13px; width: 220px; min-height: 36px; font-family: var(--font); background: var(--surface); box-sizing: border-box; }
.search-wrap { position: relative; }
.search-results {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; min-width: 280px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); z-index: 40; max-height: 280px; overflow-y: auto;
}
.search-results[hidden] { display: none; }
.search-result {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  width: 100%; padding: 10px 12px; border: none; border-bottom: 1px solid var(--border);
  background: transparent; text-align: left; cursor: pointer; font-family: var(--font);
}
.search-result:last-child { border-bottom: none; }
.search-result:hover, .search-result:focus { background: var(--surface-raised); outline: none; }
.search-result strong { font-size: 13px; }
.search-result .meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.search-results-empty { padding: 12px; font-size: 12.5px; color: var(--text-muted); }

.review-stars { color: var(--warning); letter-spacing: .04em; font-size: 13px; }
.review-stars.lg { font-size: 22px; }
.rating-star {
  display: inline-block;
  width: 0.72em;
  height: 0.72em;
  margin-left: 0.12em;
  vertical-align: 0.08em;
  color: var(--text-muted);
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none'%3E%3Cpath d='M12 2.5 14.86 8.3 21.26 9.23 16.63 13.75 17.72 20.12 12 17.9 6.28 20.12 7.37 13.75 2.74 9.23 9.14 8.3Z' stroke='%23000' stroke-width='1.75' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none'%3E%3Cpath d='M12 2.5 14.86 8.3 21.26 9.23 16.63 13.75 17.72 20.12 12 17.9 6.28 20.12 7.37 13.75 2.74 9.23 9.14 8.3Z' stroke='%23000' stroke-width='1.75' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
.kpi .value .rating-star {
  width: 0.58em;
  height: 0.58em;
  vertical-align: 0.1em;
}
.kpi .delta .rating-star {
  width: 0.82em;
  height: 0.82em;
}
.review-score { display: flex; align-items: center; gap: 10px; }
.review-score strong { font-size: 28px; letter-spacing: -.02em; }
.review-comment {
  margin: 8px 0 0; font-size: 14px; line-height: 1.55;
  padding: 12px 14px; background: var(--surface-raised);
  border: 1px solid var(--border); border-radius: var(--radius);
}
.aspect-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px;
}
.aspect-item {
  padding: 10px 12px; background: var(--surface-raised);
  border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 13px;
}
.response-timeline { display: flex; flex-direction: column; gap: 10px; }
.response-item {
  padding: 12px 14px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--surface-raised);
}
@media (max-width: 900px) {
  .aspect-grid { grid-template-columns: 1fr 1fr; }
}
.spark {
  display: inline-flex; align-items: flex-end; gap: 3px;
  height: 36px; min-width: 72px;
}
.spark.lg { height: 64px; gap: 6px; width: 100%; }
.spark.lg .spark-bar { width: 100%; max-width: 40px; border-radius: 3px 3px 1px 1px; }
.spark-bar {
  display: block; width: 6px; border-radius: 2px 2px 1px 1px;
  background: var(--brand); opacity: .85;
}
.filter-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  margin-bottom: 16px;
}
select.filter-btn,
button.filter-btn {
  appearance: none;
  -webkit-appearance: none;
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%2371717A' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 32px 8px 14px;
  font-size: 13px;
  font-weight: 500;
  font-family: var(--font);
  color: var(--text);
  cursor: pointer;
  min-height: 36px;
}
button.filter-btn {
  display: inline-flex;
  align-items: center;
  text-align: left;
  line-height: 1.3;
}
.filter-combobox .filter-btn {
  width: 100%;
}
.filter-combobox {
  position: relative;
  min-width: 200px;
  flex: 0 0 auto;
}
.filter-combobox-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 30;
  min-width: max(100%, 220px);
  max-width: 320px;
  margin: 0;
  padding: 4px 0;
  list-style: none;
  max-height: 280px;
  overflow-y: auto;
  overflow-x: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md, 0 8px 24px rgba(0, 0, 0, 0.12));
}
.filter-combobox-menu li {
  list-style: none;
  margin: 0;
  padding: 0;
}
.filter-combobox-menu li label {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 8px 12px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text);
}
.filter-combobox-menu li label:hover {
  background: var(--surface-raised);
}
.filter-combobox-menu li label:has(input:checked) {
  background: var(--brand-subtle);
}
.filter-combobox-option-meta {
  margin-left: auto;
  padding-left: 12px;
  color: var(--text-muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.filter-combobox-actions {
  position: sticky;
  bottom: 0;
  padding: 8px 12px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}
.pilot-import-actions {
  min-width: min(100%, 360px);
}
.pilot-import-progress {
  max-width: 360px;
}
.pilot-import-progress .onboarding-progress-bar {
  width: 100%;
}
.pilot-import-progress-fill {
  background: var(--brand);
}
select.filter-btn:hover,
button.filter-btn:hover { border-color: var(--border-strong); background-color: var(--surface-raised); }
select.filter-btn:focus,
button.filter-btn:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-subtle); }
.btn.filter-btn-action {
  min-height: 36px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
}
.modal-backdrop {
  position: fixed; inset: 0; z-index: 80;
  background: rgba(9, 9, 11, .45);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.modal-backdrop[hidden] { display: none; }
.pay-gate-config[hidden] { display: none !important; }
.pay-gate-store-hint[hidden] { display: none !important; }
.modal {
  width: 100%; max-width: 480px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
}
.modal-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--border);
}
.modal-head h2 { margin: 0; font-size: 16px; }
.modal-body { padding: 18px; }
.modal-foot {
  display: flex; justify-content: flex-end; gap: 8px;
  padding: 14px 18px; border-top: 1px solid var(--border);
}
#orders-filters .field input,
#orders-filters .field select {
  width: auto;
  min-width: 0;
}

.orders-filter-card {
  padding: 10px 14px;
}

.orders-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.orders-filter-bar .field {
  margin-bottom: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.orders-filter-bar .field label {
  margin-bottom: 0;
  white-space: nowrap;
}

.orders-filter-bar .field input[type="date"] {
  width: 132px;
}

.orders-filter-bar .field input[type="time"] {
  width: 104px;
}

.orders-filter-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.filter-action .btn {
  height: 38px;
  padding: 0 14px;
  line-height: 1;
  box-sizing: border-box;
}
.filter-action label {
  visibility: hidden;
  user-select: none;
}

/* Mock note */
.mock-note { position: fixed; bottom: 14px; right: 14px; background: var(--text); color: #fff; font-size: 11px; padding: 6px 12px; border-radius: var(--radius-full); opacity: .9; z-index: 99; }
.version-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; background: var(--brand-subtle); color: var(--brand-hover); border-radius: var(--radius-full); font-size: 11px; font-weight: 600; border: 1px solid var(--brand-muted); }

/* ========== ADMIN LAYOUT ========== */
.admin { display: flex; min-height: 100vh; }
.admin-sidebar {
  width: var(--sidebar-w); flex-shrink: 0; background: var(--surface);
  border-right: 1px solid var(--border); display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh;
}
.admin-logo { display: flex; align-items: center; gap: 10px; padding: 18px 16px; font-weight: 600; font-size: 15px; border-bottom: 1px solid var(--border); }
.admin-logo .logo-mark { width: 28px; height: 28px; background: var(--brand); color: #fff; border-radius: var(--radius-sm); display: grid; place-items: center; font-size: 11px; font-weight: 700; overflow: hidden; padding: 0; }
.admin-logo .logo-mark img { width: 100%; height: 100%; object-fit: cover; display: block; }
.admin-logo .brand-logo {
  display: block;
  height: 36px;
  width: auto;
  max-width: 168px;
  object-fit: contain;
}
.admin-sidebar nav { padding: 8px 10px 12px; flex: 1; overflow-y: auto; }
.nav-group { margin-bottom: 4px; }
.nav-group + .nav-group { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); }
.nav-group-label { font-size: 11px; font-weight: 600; letter-spacing: .02em; color: var(--text-muted); padding: 4px 10px 6px; }
.nav-link {
  display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: var(--radius-sm);
  font-size: 13px; color: var(--text-secondary); margin-bottom: 1px; border-left: 2px solid transparent;
  transition: background .15s ease, color .15s ease;
}
.nav-link:hover { background: var(--surface-raised); color: var(--brand-hover); }
.nav-link.active { background: var(--brand-subtle); color: var(--brand-hover); font-weight: 500; border-left-color: var(--brand); }
.admin-user { padding: 14px 16px; border-top: 1px solid var(--border); display: flex; align-items: center; gap: 10px; font-size: 12px; }
.admin-user strong { display: block; font-size: 13px; }
a.admin-user { text-decoration: none; color: inherit; cursor: pointer; transition: background .15s ease; }
a.admin-user:hover { background: var(--surface-raised); }
a.admin-user.active { background: var(--brand-subtle); }
.store-sidebar-head {
  padding: 14px 16px 12px;
  border-bottom: 1px solid var(--border);
}
.store-sidebar-head strong { display: block; font-size: 15px; margin-bottom: 4px; }
.admin-main { flex: 1; padding: 24px 28px 48px; max-width: 1280px; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.page-head h1 { font-size: 24px; font-weight: 600; letter-spacing: -.02em; line-height: 1.2; }
.page-head .sub { color: var(--text-muted); font-size: 13px; margin-top: 4px; }
.head-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* Kanban board */
.board { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; align-items: start; }
.lane { background: var(--surface-sunken); border-radius: var(--radius-lg); padding: 10px; border: 1px solid var(--border); }
.lane-head { display: flex; justify-content: space-between; align-items: center; padding: 4px 6px 10px; font-weight: 600; font-size: 12px; color: var(--text-secondary); }
.ticket { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; margin-bottom: 8px; box-shadow: var(--shadow-sm); }
.ticket:last-child { margin-bottom: 0; }
.ticket.highlight { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand-muted); }
.ticket .t-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; font-size: 13px; }
.ticket .items { font-size: 12px; color: var(--text-secondary); margin: 6px 0; line-height: 1.45; }
.ticket .t-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; gap: 8px; }
.timer { font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: var(--radius-full); background: var(--surface-sunken); color: var(--text-secondary); }
.timer.late { background: var(--danger-subtle); color: var(--danger); }

/* Menu manager panes */
.menu-layout { display: grid; grid-template-columns: 220px 1fr; gap: 16px; }
.cat-list a { display: flex; justify-content: space-between; padding: 8px 10px; border-radius: var(--radius-sm); font-size: 13px; color: var(--text-secondary); margin-bottom: 2px; }
.cat-list a:hover { background: var(--surface-raised); }
.cat-list a.active { background: var(--brand-subtle); color: var(--brand-hover); font-weight: 500; }

/* ========== CUSTOMER LAYOUT ========== */
:root {
  --shop-content-width: 1200px;
  --shop-header-height: 78px;
}
.shop-header {
  background: var(--header-bg, var(--brand));
  color: var(--header-ink, #fff);
  border-bottom: none;
  position: sticky;
  top: 0;
  z-index: 50;
}
.shop-header-inner {
  max-width: var(--shop-content-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 12px 20px;
}
.shop-header--with-toolbar { border-bottom: none; }
.shop-brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 16px; color: var(--header-ink, #fff); }
.shop-brand .logo-mark {
  width: 30px; height: 30px; background: var(--header-ink, #fff); color: var(--header-bg, var(--brand));
  border-radius: var(--radius-sm); display: grid; place-items: center;
  font-size: 11px; font-weight: 700; overflow: hidden; padding: 0;
}
.shop-brand .logo-mark img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shop-brand .brand-logo {
  display: block;
  height: 54px;
  width: auto;
  max-width: 280px;
  object-fit: contain;
}
.shop-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  flex-shrink: 0;
}
.btn-auth {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  padding: 0 14px;
  border-radius: var(--radius-sm);
  border: 1px solid color-mix(in srgb, var(--header-ink, #fff) 45%, transparent);
  background: transparent;
  color: var(--header-ink, #fff);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.btn-auth:hover {
  background: color-mix(in srgb, var(--header-ink, #fff) 14%, transparent);
  border-color: var(--header-ink, #fff);
  color: var(--header-ink, #fff);
}
.shop-nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 36px;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--header-ink, #fff) 35%, transparent);
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--header-ink, #fff) 12%, transparent);
  color: var(--header-ink, #fff);
  cursor: pointer;
}
.shop-nav-links--desktop { display: none; }
.shop-nav-toggle:hover { background: color-mix(in srgb, var(--header-ink, #fff) 22%, transparent); }
.shop-nav-toggle-bars {
  display: grid;
  gap: 4px;
  width: 18px;
}
.shop-nav-toggle-bars span {
  display: block;
  height: 2px;
  border-radius: 1px;
  background: currentColor;
  transition: transform .15s ease, opacity .15s ease;
}
.shop-nav-toggle-bars.is-open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.shop-nav-toggle-bars.is-open span:nth-child(2) { opacity: 0; }
.shop-nav-toggle-bars.is-open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.shop-nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(9, 9, 11, .45);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
}
.shop-nav-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}
.shop-nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 61;
  width: min(320px, 88vw);
  background: #09090B;
  color: #fff;
  box-shadow: -8px 0 32px rgba(0,0,0,.35);
  transform: translateX(100%);
  transition: transform .22s ease;
  display: flex;
  flex-direction: column;
  padding: 0;
  border: none;
}
.shop-nav-drawer.is-open {
  transform: translateX(0);
}
.shop-nav-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(255,255,255,.12);
  background: #09090B;
  color: #fff;
}
.shop-nav-drawer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-weight: 600;
  font-size: 15px;
  color: #fff;
}
.shop-nav-drawer-brand .brand-logo {
  display: block;
  height: 50px;
  width: auto;
  max-width: 255px;
  object-fit: contain;
}
.shop-nav-drawer-brand .logo-mark {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--brand);
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 700;
}
.shop-nav-drawer-brand span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.shop-nav-drawer-close {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,.12);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
}
.shop-nav-drawer-close:hover { background: rgba(255,255,255,.22); }
.shop-nav-drawer-inner {
  display: grid;
  gap: 4px;
  padding: 12px;
  overflow-y: auto;
}
.shop-nav-drawer-inner a {
  display: block;
  padding: 14px 14px;
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 15px;
  font-weight: 500;
}
.shop-nav-drawer-inner a:hover {
  background: rgba(255,255,255,.1);
  color: #fff;
}
.shop-nav-drawer-inner a.active {
  background: var(--brand);
  color: #fff;
}
.shop-nav-drawer-section {
  display: grid;
  gap: 2px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,.12);
}
.shop-nav-drawer-section-title {
  margin: 0 0 4px;
  padding: 4px 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
}
.shop-nav-drawer-section a {
  font-size: 14px;
  font-weight: 400;
  padding: 10px 14px;
}
.shop-nav-links { display: flex; gap: 20px; font-size: 13px; color: rgba(255,255,255,.82); align-items: center; }
.shop-nav-links a:hover, .shop-nav-links a.active { color: #fff; }
.points-chip {
  padding: 5px 12px; border-radius: var(--radius-full);
  background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.28);
  font-size: 12px; font-weight: 500; color: #fff;
}
.btn-cart {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 42px;
  height: 36px;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  background: var(--header-ink, #fff);
  color: var(--header-bg, var(--brand));
  font-size: 13px;
  font-weight: 600;
  transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.shop-nav-links a.btn-cart:hover,
.shop-nav-links a.btn-cart:focus-visible,
.btn-cart:hover {
  background: var(--header-bg, var(--brand-hover));
  color: var(--header-ink, #fff);
  box-shadow: 0 1px 2px rgba(0,0,0,.12);
}
.btn-cart-icon { display: block; flex-shrink: 0; }
.btn-cart-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.shop-wrap {
  max-width: var(--shop-content-width);
  margin: 0 auto;
  padding: 32px 20px;
}

/* Shop storefront: treat muted/secondary copy as black */
.shop-body {
  --text-secondary: #09090B;
  --text-muted: #09090B;
  background: var(--body-bg, var(--surface-sunken));
}
.shop-body .muted,
.shop-body .small.muted,
.shop-body .cart-panel-empty,
.shop-body .cart-line .mods,
.shop-body .store-toolbar-meta .muted,
.shop-body .store-toolbar-meta .small {
  color: var(--toolbar-ink, #09090B);
}
.shop-body .menu-card .desc,
.shop-body .menu-card .liked {
  color: var(--card-desc, var(--card-ink, #09090B));
}
.shop-body .cat-rail a:not(.active):not(:hover) {
  color: var(--pill-ink, #09090B);
}

.menu-loyalty-banner {
  margin-top: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 16px;
  padding: 16px 18px;
  border-radius: var(--radius-lg);
  background: var(--brand);
  border: 1px solid var(--brand-hover);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.menu-loyalty-banner strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
}
.menu-loyalty-banner-sub {
  margin-top: 2px;
  font-size: 12.5px;
  color: rgba(255,255,255,.88);
}
.menu-loyalty-banner-btn {
  background: #fff !important;
  color: var(--brand) !important;
  border-color: transparent !important;
  font-weight: 600;
}
.menu-loyalty-banner-btn:hover {
  background: var(--brand-subtle) !important;
  color: var(--brand-hover) !important;
}


/* Shop footer: brand band + store lookup + link grid */
.shop-footer {
  margin-top: 0;
  background: var(--footer-bg, #09090B);
  border-top: 1px solid color-mix(in srgb, var(--footer-ink, #fff) 8%, transparent);
  color: var(--footer-ink, #fff);
  position: relative;
}
.shop-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand-hover) 55%, rgba(255,255,255,.25) 100%);
}
.shop-footer-inner {
  max-width: var(--shop-content-width);
  margin: 0 auto;
  padding: 40px 20px 28px;
  display: grid;
  gap: 32px;
}
.shop-footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
  gap: 28px 40px;
  align-items: stretch;
  padding-bottom: 28px;
  border-bottom: 1px solid color-mix(in srgb, var(--footer-ink, #fff) 10%, transparent);
}
.shop-footer-brand-block {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
  min-height: 100%;
}
.shop-footer-brand-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.shop-footer-logo {
  display: block;
  height: 77px;
  width: auto;
  max-width: 336px;
  object-fit: contain;
}
.shop-footer-mark {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--brand);
  color: var(--footer-ink, #fff);
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 8px 24px rgba(0,0,0,.25);
}
.shop-footer-name {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--footer-ink, #fff);
  line-height: 1.2;
}
.shop-footer-tag {
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.45;
  color: color-mix(in srgb, var(--footer-ink, #fff) 72%, transparent);
  max-width: 36ch;
}
.shop-footer-brand-copy {
  min-width: 0;
}
.shop-footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 0;
}
.shop-footer-social-link {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--footer-ink, #fff) 18%, transparent);
  background: color-mix(in srgb, var(--footer-ink, #fff) 8%, transparent);
  color: var(--footer-ink, #fff);
  display: grid;
  place-items: center;
  transition: transform .15s ease, background .15s ease, border-color .15s ease, color .15s ease;
}
.shop-footer-social-link svg {
  width: 26px;
  height: 26px;
}
.shop-footer-social-link:hover {
  transform: translateY(-2px);
  background: var(--brand);
  border-color: var(--brand);
  color: var(--footer-ink, #fff);
}
.shop-footer-lookup {
  background: color-mix(in srgb, var(--footer-ink, #fff) 6%, transparent);
  border: 1px solid color-mix(in srgb, var(--footer-ink, #fff) 12%, transparent);
  border-radius: var(--radius-lg);
  padding: 16px;
}
.shop-footer-lookup-label {
  display: block;
  margin-bottom: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--footer-ink, #fff) 90%, transparent);
}
.shop-footer-lookup-field {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  background: #fff;
  border: 1px solid color-mix(in srgb, var(--footer-ink, #fff) 14%, transparent);
  border-radius: var(--radius);
}
.shop-footer-lookup-field:focus-within {
  border-color: var(--brand-muted);
  box-shadow: 0 0 0 3px rgba(222,19,22,.18);
}
.shop-footer-lookup-icon {
  color: color-mix(in srgb, var(--footer-ink, #fff) 55%, transparent);
  font-size: 15px;
  line-height: 1;
}
.shop-footer-lookup-field input {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--footer-ink, #fff);
  font: inherit;
  font-size: 13.5px;
  padding: 11px 0;
  outline: none;
  min-width: 0;
}
.shop-footer-lookup-field input::placeholder { color: color-mix(in srgb, var(--footer-ink, #fff) 45%, transparent); }
.shop-footer-lookup-results {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
  display: grid;
  gap: 6px;
}
.shop-footer-lookup-result {
  width: 100%;
  text-align: left;
  border: 1px solid color-mix(in srgb, var(--footer-ink, #fff) 8%, transparent);
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--footer-ink, #fff) 4%, transparent);
  color: var(--footer-ink, #fff);
  padding: 10px 12px;
  cursor: pointer;
  font: inherit;
  transition: border-color .15s ease, background .15s ease;
}
.shop-footer-lookup-result:hover {
  border-color: color-mix(in srgb, var(--footer-ink, #fff) 22%, transparent);
  background: color-mix(in srgb, var(--footer-ink, #fff) 8%, transparent);
}
.shop-footer-lookup-result-name {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.3;
}
.shop-footer-lookup-result-meta {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: color-mix(in srgb, var(--footer-ink, #fff) 62%, transparent);
  line-height: 1.35;
}
.shop-footer-lookup-empty {
  margin: 10px 0 0;
  font-size: 12.5px;
  color: color-mix(in srgb, var(--footer-ink, #fff) 62%, transparent);
}
.shop-footer-lookup-all {
  display: inline-block;
  margin-top: 10px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--primary, var(--brand));
  text-decoration: none;
}
.shop-footer-lookup-all:hover { color: var(--primary-hover, var(--brand-hover)); text-decoration: underline; }
.shop-footer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 48px;
}
.shop-footer-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.shop-footer-col-title {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--footer-ink, #fff) 55%, transparent);
}
.shop-footer-col a {
  color: color-mix(in srgb, var(--footer-ink, #fff) 92%, transparent);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.45;
  text-decoration: none;
  padding-left: 0;
  transition: color .15s ease, padding-left .15s ease;
}
.shop-footer-col a:hover {
  color: var(--footer-ink, #fff);
  padding-left: 4px;
}
.shop-footer-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px 20px;
  padding-top: 20px;
  border-top: 1px solid color-mix(in srgb, var(--footer-ink, #fff) 10%, transparent);
  font-size: 12px;
  color: color-mix(in srgb, var(--footer-ink, #fff) 55%, transparent);
}
.shop-footer-powered strong {
  color: color-mix(in srgb, var(--footer-ink, #fff) 85%, transparent);
  font-weight: 600;
}
.shop-info-page { max-width: none; }
.shop-info-title {
  margin: 0 0 24px;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.2;
}
.shop-info-section { margin-bottom: 22px; }
.shop-info-section h2 {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 600;
}
.shop-info-section p {
  margin: 0 0 10px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-secondary);
}
.shop-info-section p:last-child { margin-bottom: 0; }
.shop-info-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

/* Help page */
.help-page .shop-info-title { margin-bottom: 6px; }
.help-page-intro { margin: 0 0 20px; }
.help-search-section { margin-bottom: 20px; }
.help-search-section .store-search { max-width: none; }
.help-block { margin-bottom: 20px; }
.help-block-title {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 600;
}
.help-popular-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 28px;
}
.help-popular-grid h3 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
}
.help-popular-grid p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-secondary);
}
.help-categories-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.help-category-card {
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
}
.help-category-card .checkout-row { padding: 10px 0; }
.help-category-card .checkout-row a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}
.help-category-card .checkout-row a:hover { color: var(--primary); }
.help-empty {
  margin: 0;
  font-size: 14px;
  color: var(--text-secondary);
}
.help-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 20px;
  font-size: 13px;
  color: var(--text-muted);
}
.help-breadcrumbs a {
  color: var(--text-muted);
  text-decoration: none;
}
.help-breadcrumbs a:hover { color: var(--primary); }
.help-breadcrumbs-current {
  color: var(--text);
  font-weight: 500;
}
.help-breadcrumbs-sep { color: var(--text-muted); }
.help-subpage-title { margin-bottom: 16px; }
.help-faq-list {
  padding: 4px 20px;
  margin-bottom: 0;
}
.help-faq-link {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
}
.help-faq-link:last-child { border-bottom: none; }
.help-faq-link:hover { color: var(--primary); }
.help-faq-chevron {
  color: var(--text-muted);
  font-size: 18px;
  line-height: 1;
  flex-shrink: 0;
}
.help-article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 20px;
  font-size: 13px;
  color: var(--text-muted);
}
.help-article-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.help-article-body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
}
.help-article-body p {
  margin: 0 0 14px;
}
.help-article-body p:last-child { margin-bottom: 0; }
.help-article-list {
  margin: 0;
  padding-left: 1.25rem;
}
.help-article-list li { margin-bottom: 10px; }
.help-article-list li:last-child { margin-bottom: 0; }
.help-article-title-link,
.help-category-title-link {
  color: inherit;
  text-decoration: none;
}
.help-article-title-link:hover,
.help-category-title-link:hover { color: var(--primary); }
@media (max-width: 900px) {
  .help-popular-grid { grid-template-columns: 1fr; }
  .help-categories-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .shop-footer-inner { padding: 32px 16px 24px; gap: 24px; }
  .shop-footer-top { grid-template-columns: 1fr; gap: 20px; padding-bottom: 22px; }
  .shop-footer-grid { grid-template-columns: 1fr; gap: 22px; }
  .shop-footer-meta { flex-direction: column; align-items: flex-start; }
  .shop-info-title { font-size: 24px; }
}

/* Auth (login / signup) */
.auth-body {
  min-height: 100vh;
  background: var(--surface-sunken);
}
.auth-body--login {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100vh;
  background: var(--header-bg, var(--surface-sunken));
}
.auth-body--login .auth-top {
  justify-content: center;
}
.auth-body--login .auth-page {
  padding: 8px 20px 32px;
}
.auth-body--login .auth-top .shop-brand,
.auth-body--login .auth-top .auth-brand,
.auth-body--login .auth-top .link {
  color: var(--header-ink, var(--text));
}
.auth-top {
  max-width: 1120px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.auth-top .shop-brand,
.auth-top .auth-brand {
  color: var(--text);
}
.auth-top .shop-brand .logo-mark,
.auth-top .auth-brand .logo-mark {
  background: var(--brand);
  color: #fff;
}
.auth-page {
  display: flex;
  justify-content: center;
  padding: 12px 20px 64px;
}
.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 28px 24px 24px;
}
.auth-card-head { margin-bottom: 20px; }
.auth-card-head h1 {
  font-size: 22px;
  margin: 0 0 6px;
  letter-spacing: -.02em;
}
.auth-card-head p { margin: 0; font-size: 13.5px; line-height: 1.45; }
.auth-form .field { margin-bottom: 12px; }
.auth-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.auth-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--text-secondary);
  margin: 0 0 12px;
  cursor: pointer;
  line-height: 1.4;
}
.auth-check input {
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--brand);
}
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0;
  color: var(--text-muted);
  font-size: 12px;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.auth-social { display: flex; flex-direction: column; gap: 8px; }
.auth-foot {
  text-align: center;
  margin: 18px 0 0;
  font-size: 13.5px;
  color: var(--text-secondary);
}
@media (max-width: 520px) {
  .auth-card { padding: 22px 16px 18px; }
  .auth-grid-2 { grid-template-columns: 1fr; gap: 0; }
  .auth-card-head h1 { font-size: 20px; }
}

/* Store banner */
.store-banner { background: var(--brand-subtle); border: 1px solid var(--brand-muted); border-radius: var(--radius); padding: 10px 14px; font-size: 13px; margin-bottom: 20px; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center; }

/* Store locator split */
.locator-split { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; min-height: 480px; background: var(--surface); }
.store-list { border-right: 1px solid var(--border); overflow-y: auto; }
.store-list-head { padding: 16px; border-bottom: 1px solid var(--border); }
.store-row { padding: 14px 16px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.store-row:hover { background: var(--surface-raised); }
.store-row.dim { opacity: .55; }
.store-row .meta { font-size: 12px; color: var(--text-muted); margin-top: 3px; }
.map-placeholder { background: linear-gradient(145deg, #E8E4DF 0%, #D4D0CB 40%, #C8D4D8 100%); position: relative; display: flex; align-items: center; justify-content: center; }
.store-address-field { position: relative; }
.store-address-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.store-address-row input { flex: 1; min-width: 0; }
.store-locate-btn {
  flex-shrink: 0;
  white-space: nowrap;
}
.store-locate-hint {
  margin: 6px 0 0;
}
.store-address-popup {
  z-index: 90;
}
.store-address-popup-modal {
  max-width: 440px;
}
.store-address-popup .mapbox-suggest {
  z-index: 95;
}
.pac-container {
  z-index: 10000;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  font-family: inherit;
  margin-top: 4px;
}
.pac-item {
  padding: 8px 12px;
  font-size: 13px;
  cursor: pointer;
}
.pac-item:hover { background: var(--surface-sunken); }
.store-locator-map {
  width: 100%;
  height: 100%;
  min-height: 100%;
  position: relative;
  background: linear-gradient(145deg, #f4f4f5 0%, #e4e4e7 45%, #d4d4d8 100%);
}
.store-locator-map .mapboxgl-map,
.store-locator-map .mapboxgl-canvas-container,
.store-locator-map .mapboxgl-canvas,
.brand-add-store-map .mapboxgl-map,
.track-map-canvas.mapboxgl-map,
#trackMap.mapboxgl-map { width: 100% !important; height: 100% !important; }
.brand-add-store-map {
  width: 100%;
  min-height: 240px;
  margin-top: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #e4e4e7;
}
.exclusion-zone-map {
  min-height: 360px;
  margin-top: 0;
}
.mapbox-pin {
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  filter: drop-shadow(0 4px 10px rgba(9, 9, 11, 0.18));
}
.mapbox-pin-badge {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: #fff;
  background: var(--brand);
  border: 3px solid #fff;
  box-shadow: 0 2px 8px rgba(9, 9, 11, 0.18);
  flex-shrink: 0;
}
.mapbox-pin--user .mapbox-pin-badge,
.mapbox-pin--home .mapbox-pin-badge {
  background: #3f3f46;
}
.mapbox-pin--warning .mapbox-pin-badge {
  background: var(--warning, #f59e0b);
  color: #18181b;
}
.mapbox-pin--rider .mapbox-pin-badge {
  animation: track-pulse 2s ease-in-out infinite;
}
.mapbox-pin-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--brand);
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(9, 9, 11, 0.18);
  flex-shrink: 0;
}
.mapbox-pin--user .mapbox-pin-dot,
.mapbox-pin--home .mapbox-pin-dot {
  width: 12px;
  height: 12px;
  background: #52525B;
}
.mapbox-pin--rider .mapbox-pin-dot {
  animation: track-pulse 2s ease-in-out infinite;
}
.mapbox-pin-label {
  margin-bottom: 8px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}
.mapbox-suggest {
  position: absolute;
  z-index: 40;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  display: grid;
  gap: 0;
  max-height: 240px;
  overflow: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.mapbox-suggest-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 13px;
  color: var(--text);
  cursor: pointer;
  border-bottom: 1px solid var(--border);
}
.mapbox-suggest-item:last-child { border-bottom: none; }
.mapbox-suggest-item:hover { background: var(--surface-sunken); }
.gmap-marker {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: translate(-50%, -100%);
  pointer-events: none;
  z-index: 1;
}
.gmap-pin-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--brand);
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(9, 9, 11, 0.18);
  flex-shrink: 0;
}
.gmap-marker--user .gmap-pin-dot {
  width: 12px;
  height: 12px;
  background: #52525B;
  box-shadow: 0 2px 6px rgba(9, 9, 11, 0.2);
}
.gmap-pin-label {
  margin-bottom: 8px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}
.map-placeholder::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(circle at 30% 40%, rgba(255,255,255,.4) 0%, transparent 50%), radial-gradient(circle at 70% 60%, rgba(255,255,255,.3) 0%, transparent 40%); }
.map-pin { position: absolute; width: 12px; height: 12px; background: var(--brand); border: 2px solid #fff; border-radius: 50%; box-shadow: var(--shadow); }
.map-pin:nth-child(1) { top: 35%; left: 45%; }
.map-pin:nth-child(2) { top: 50%; left: 55%; }
.map-pin:nth-child(3) { top: 42%; left: 38%; }
.map-pin:nth-child(4) { top: 60%; left: 48%; }
.map-label { position: relative; z-index: 1; background: var(--surface); padding: 8px 14px; border-radius: var(--radius-sm); font-size: 12px; color: var(--text-muted); border: 1px solid var(--border); box-shadow: var(--shadow-sm); }

/* Menu layout */
.menu-layout-customer { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; align-items: start; }
.menu-layout-customer > * { min-width: 0; }
.menu-layout-customer.no-cart { grid-template-columns: 1fr; }
.menu-main { min-width: 0; }
.cat-rail-wrap {
  position: sticky;
  top: var(--shop-header-height);
  z-index: 40;
  margin: 0 0 18px;
  background: var(--body-bg, transparent);
  border-bottom: none;
  border-radius: 0;
}
.cat-rail-wrap::before,
.cat-rail-wrap::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 56px;
  z-index: 2;
  pointer-events: none;
}
.cat-rail-wrap::before {
  left: 0;
  background: linear-gradient(to right, var(--body-bg, var(--surface-sunken)) 35%, transparent);
}
.cat-rail-wrap::after {
  right: 0;
  background: linear-gradient(to left, var(--body-bg, var(--surface-sunken)) 35%, transparent);
}
.cat-rail-wrap .menu-banner-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.cat-rail-wrap .menu-banner-nav.prev { left: 4px; }
.cat-rail-wrap .menu-banner-nav.next { right: 4px; }
.cat-rail {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  margin: 0;
  padding: 10px 48px 12px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.cat-rail::-webkit-scrollbar { display: none; }
.cat-rail .cat-label { display: none; }
.cat-rail a {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border: 1px solid color-mix(in srgb, var(--pill-ink, var(--text)) 12%, transparent);
  border-radius: var(--radius-full);
  background: var(--pill-bg, var(--surface));
  color: var(--pill-ink, var(--text-secondary));
  font-size: 13px;
  font-weight: 500;
  line-height: 1.25;
  white-space: nowrap;
}
.cat-rail a:hover {
  background: var(--pill-active-bg, var(--brand));
  color: var(--pill-active-ink, #fff);
  border-color: var(--pill-active-bg, var(--brand));
}
.cat-rail a.active {
  border-color: var(--pill-active-bg, var(--brand));
  background: var(--pill-active-bg, var(--brand));
  color: var(--pill-active-ink, #fff);
}
.cat-rail a.active:hover {
  background: var(--pill-active-bg, var(--brand-hover));
  border-color: var(--pill-active-bg, var(--brand-hover));
  color: var(--pill-active-ink, #fff);
}
.menu-promos-section,
.featured-section,
.menu-main > section,
#promotions,
#extra,
#burgers,
#sides,
#drinks,
#desserts {
  scroll-margin-top: calc(var(--shop-header-height) + 54px);
}
.menu-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.menu-main > section > h2,
.menu-main > section > h3,
.featured-head h2 {
  color: var(--card-heading, var(--text));
}
.menu-card {
  background: var(--card-bg, var(--surface));
  border: 1px solid color-mix(in srgb, var(--card-ink, var(--text)) 12%, transparent);
  color: var(--card-ink, var(--text));
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  transition: box-shadow .15s, transform .2s ease;
}
.menu-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.menu-card.sold-out { opacity: .6; }
.menu-card .thumb {
  flex: 0 0 120px;
  width: 120px;
  min-height: 120px;
  align-self: stretch;
  background: linear-gradient(135deg, #EDE9E4, #D9D2CA);
  position: relative;
  flex-shrink: 0;
}
.menu-card .thumb.t-beef { background: linear-gradient(145deg, #C45C3A 0%, #8B3A22 55%, #3D2318 100%); }
.menu-card .thumb.t-cheese { background: linear-gradient(145deg, #E8A54B 0%, #C45C3A 50%, #5C3317 100%); }
.menu-card .thumb.t-plant { background: linear-gradient(145deg, #7BA05B 0%, #3D5C3A 60%, #1F2E1C 100%); }
.menu-card .thumb.t-chicken { background: linear-gradient(145deg, #D4A574 0%, #A65D3A 55%, #4A2C1A 100%); }
.menu-card .thumb.t-double { background: linear-gradient(145deg, #B85C38 0%, #6B2E1A 50%, #2A1810 100%); }
.menu-card .thumb.t-side { background: linear-gradient(145deg, #E8C36A 0%, #C48A2A 60%, #5C3A12 100%); }
.menu-card .thumb.t-drink { background: linear-gradient(145deg, #F0C94A 0%, #DE1316 45%, #7A2E12 100%); }
.menu-card .thumb::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.18), transparent 55%); }
.menu-card .thumb .quick-add {
  position: absolute; right: 8px; bottom: 8px; z-index: 1;
  width: 30px; height: 30px; border-radius: 50%;
  border: none; background: var(--card-add, #fff); color: var(--card-ink, var(--text));
  display: grid; place-items: center; font-size: 18px; font-weight: 500;
  box-shadow: var(--shadow); cursor: pointer; text-decoration: none;
}
.menu-card .quick-add:hover { background: var(--brand); color: #fff; }
.menu-card .thumb .quick-add.is-added { background: var(--success); color: #fff; border-color: var(--success); }
.menu-card .thumb.has-photo {
  background: #fff;
  overflow: hidden;
}
.menu-card .thumb.has-photo::after {
  display: none;
}
.menu-card .thumb.has-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.42);
  filter: saturate(1.18) contrast(1.08) brightness(1.03);
  display: block;
}
.menu-card .body {
  padding: 12px 14px;
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  justify-content: flex-start;
}
.menu-card .name { font-weight: 500; font-size: 14px; color: var(--card-ink, var(--text)); }
.menu-card .desc { color: var(--card-desc, var(--card-ink, var(--text-muted))); font-size: 12.5px; line-height: 1.4; }
.menu-card .row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 8px;
  gap: 8px;
  flex-wrap: nowrap;
  min-width: 0;
}
.menu-card .price {
  font-weight: 600;
  font-size: 14px;
  color: var(--card-ink, var(--text));
  white-space: nowrap;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}
.menu-card .row .btn { flex-shrink: 0; }
.menu-card .liked { font-size: 12px; color: var(--card-desc, var(--card-ink, var(--text-muted))); }
.menu-card .quick-add { width: 32px; height: 32px; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface); display: grid; place-items: center; font-size: 18px; color: var(--text); cursor: pointer; }

/* Store head toolbar (continues sticky shop header) */
.store-head {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 16px;
}
.store-head--toolbar {
  margin: -34px 0 20px;
  border: 1px solid color-mix(in srgb, var(--toolbar-ink, var(--text)) 10%, transparent);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  background: var(--toolbar-bg, var(--surface));
  color: var(--toolbar-ink, var(--text));
  box-shadow: 0 10px 28px rgba(9, 9, 11, .12), 0 2px 8px rgba(9, 9, 11, .06);
  position: relative;
  z-index: 45;
  overflow: visible;
}
.store-hero {
  position: relative;
  height: 108px;
  overflow: hidden;
  margin: 0;
  border-radius: 0;
  background:
    linear-gradient(120deg, rgba(9,9,11,.55) 0%, rgba(9,9,11,.15) 55%, transparent 100%),
    linear-gradient(145deg, #DE1316 0%, #8B1012 45%, #3D0A0B 100%);
}
.store-hero-inner { position: absolute; inset: 0; display: flex; align-items: flex-end; padding: 14px 16px; gap: 12px; }
.store-avatar {
  width: 48px; height: 48px; border-radius: 50%; background: #09090B; color: #fff;
  display: grid; place-items: center; font-weight: 700; font-size: 13px;
  border: 2px solid #fff; box-shadow: var(--shadow); flex-shrink: 0;
}
.store-hero-copy { color: #fff; min-width: 0; }
.store-hero-copy h1 { font-size: 17px; letter-spacing: -.02em; margin: 0 0 2px; color: #fff; line-height: 1.2; }
.store-hero-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; opacity: .92; }
.store-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin: 0;
  padding: 12px 14px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}
.store-head--toolbar .store-toolbar {
  border-top: none;
  max-width: none;
  margin: 0;
  padding: 12px 16px;
  background: transparent;
  color: inherit;
}
.store-head--toolbar .store-search {
  background: var(--search-bg, color-mix(in srgb, var(--toolbar-ink, var(--text)) 6%, var(--toolbar-bg, var(--surface))));
  border-color: var(--search-border, var(--search-ink, var(--toolbar-ink, var(--text))));
  border-width: 2px;
  color: var(--search-ink, var(--toolbar-ink, var(--text)));
}
.store-head--toolbar .store-search input {
  color: var(--search-ink, var(--toolbar-ink, var(--text)));
}
.store-head--toolbar .store-search input::placeholder {
  color: var(--search-placeholder, var(--search-ink, var(--toolbar-ink, var(--text))));
  opacity: 1;
}
.store-head--toolbar .store-toolbar-meta,
.store-head--toolbar .store-toolbar-meta .link {
  color: var(--toolbar-ink, var(--text));
}
.store-head--toolbar .fulfil-seg {
  background: color-mix(in srgb, var(--toolbar-ink, var(--text)) 8%, var(--toolbar-bg, var(--surface)));
}
.store-head--toolbar .fulfil-seg button,
.store-head--toolbar .fulfil-seg a {
  color: var(--toolbar-ink, var(--text));
}
.store-head--toolbar .fulfil-seg .active {
  background: var(--primary);
  color: #fff;
  box-shadow: none;
}
.store-toolbar-title {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 0 1 180px;
}
.store-toolbar-title strong {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.store-toolbar-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}
.store-search {
  flex: 1; min-width: 200px; display: flex; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-full);
  padding: 9px 14px; font-size: 13px; color: var(--text-muted);
}
.store-search:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-subtle);
}
.store-search input { border: none; background: transparent; outline: none; width: 100%; font: inherit; color: var(--text); }
.store-search input:focus { outline: none; }
.fulfil-seg { display: inline-flex; background: var(--surface-sunken); border-radius: var(--radius-full); padding: 3px; gap: 2px; }
.fulfil-seg button, .fulfil-seg a {
  border: none; background: transparent; padding: 7px 14px; border-radius: var(--radius-full);
  font-size: 13px; font-weight: 500; color: var(--text-secondary); cursor: pointer; text-decoration: none;
}
.fulfil-seg .active {
  background: var(--primary-subtle);
  color: var(--primary-hover);
  box-shadow: inset 0 0 0 1px var(--primary);
}
.deal-strip { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 20px; scrollbar-width: none; }
.deal-strip::-webkit-scrollbar { display: none; }
.deal-chip {
  flex: 0 0 auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 10px 14px; min-width: 160px; font-size: 12.5px;
}
.deal-chip strong { display: block; font-size: 13px; margin-bottom: 2px; }

/* Menu banner carousel + promotions */
.menu-banner-carousel {
  position: relative;
  margin-bottom: 16px;
}
.menu-banner-track {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 2px 2px 4px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.menu-banner-track::-webkit-scrollbar { display: none; }
.menu-banner-card {
  position: relative;
  flex: 0 0 min(78%, 520px);
  height: 168px;
  border-radius: var(--radius);
  overflow: hidden;
  scroll-snap-align: start;
  color: #fff;
  text-decoration: none;
  background: var(--img, #3F3F46);
  box-shadow: var(--shadow-sm);
}
.menu-banner-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
}
.menu-banner-img[src]:not([src=""]) { opacity: 1; }
.menu-banner-label {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 36px 14px 12px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -.01em;
  background: linear-gradient(transparent, rgba(0,0,0,.55));
  line-height: 1.25;
}
.menu-banner-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 28px;
  height: 28px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  box-shadow: var(--shadow-sm);
  display: grid;
  place-items: center;
  padding: 0;
}
.menu-banner-nav:hover { background: var(--surface-raised); }
.menu-banner-nav.prev { left: 6px; }
.menu-banner-nav.next { right: 6px; }
.menu-promos-section { margin-bottom: 28px; }
.menu-promos-title { font-size: 16px; margin: 0 0 4px; }
@media (max-width: 700px) {
  .menu-banner-nav { display: none; }
  .menu-banner-card { flex-basis: 86%; height: 148px; }
}
.featured-section {
  margin-bottom: 28px;
  min-width: 0;
  max-width: 100%;
}
.featured-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.featured-head h2 { font-size: 16px; margin: 0; }
.featured-nav {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}
.featured-nav .menu-banner-nav {
  position: static;
  transform: none;
  top: auto;
}
.featured-carousel {
  position: relative;
  min-width: 0;
  max-width: 100%;
}
.featured-track {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 4px 2px 8px;
  margin: 0;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  min-width: 0;
}
.featured-track::-webkit-scrollbar { display: none; }
.featured-card {
  flex: 0 0 300px;
  width: 300px;
  max-width: 300px;
  scroll-snap-align: start;
}
.featured-card:hover { transform: none; }
.menu-card.no-image {
  min-height: 108px;
}
.menu-card.no-image .body {
  padding: 14px 16px;
  justify-content: space-between;
}
.menu-card.no-image .liked {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (max-width: 700px) {
  .featured-nav { display: none; }
  .featured-card {
    flex-basis: 82vw;
    width: 82vw;
    max-width: 82vw;
  }
}

/* Sticky cart panel (menu) */
.cart-panel {
  position: sticky;
  top: 72px;
  z-index: 30;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  align-self: start;
  width: 100%;
}
.cart-panel-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.cart-panel-head h2 { font-size: 15px; margin: 0; }
.cart-panel-items { padding: 4px 0 2px; }
.cart-line {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.cart-panel-items .cart-line:last-child { border-bottom: none; }
.cart-line-hit {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  flex: 1;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
}
.cart-line-hit:hover .name {
  color: var(--brand);
}
.cart-line .thumb {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: linear-gradient(145deg, #C45C3A, #3D2318);
  flex-shrink: 0;
}
.cart-line .thumb.t-beef { background: linear-gradient(145deg, #C45C3A 0%, #8B3A22 55%, #3D2318 100%); }
.cart-line .thumb.t-cheese { background: linear-gradient(145deg, #E8A54B 0%, #C45C3A 50%, #5C3317 100%); }
.cart-line .thumb.t-plant { background: linear-gradient(145deg, #7BA05B 0%, #3D5C3A 60%, #1F2E1C 100%); }
.cart-line .thumb.t-chicken { background: linear-gradient(145deg, #D4A574 0%, #A65D3A 55%, #4A2C1A 100%); }
.cart-line .thumb.t-double { background: linear-gradient(145deg, #B85C38 0%, #6B2E1A 50%, #2A1810 100%); }
.cart-line .thumb.t-side { background: linear-gradient(145deg, #E8C36A 0%, #C48A2A 60%, #5C3A12 100%); }
.cart-line .thumb.t-drink { background: linear-gradient(145deg, #F0C94A, #DE1316); }
.cart-line .thumb.has-photo,
.cart-item .thumb.has-photo,
.checkout-summary-card .thumb.has-photo {
  position: relative;
  overflow: hidden;
  background: #fff;
}
.cart-line .thumb.has-photo img,
.cart-item .thumb.has-photo img,
.checkout-summary-card .thumb.has-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.42);
  filter: saturate(1.18) contrast(1.08) brightness(1.03);
  display: block;
}
.cart-line-copy {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 48px;
  gap: 4px;
}
.cart-line .name {
  font-weight: 500;
  line-height: 1.35;
  color: var(--text);
  white-space: pre-line;
  min-height: calc(1.35em * 2);
}
.cart-line-sub {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.35;
}
.cart-line .mods { min-width: 0; }
.cart-line-aside {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
  flex-shrink: 0;
  min-height: 48px;
}
.cart-line .price {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  line-height: 1.35;
}
.cart-line-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.cart-qty-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface-sunken, #f3f3f3);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.cart-line-remove {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-muted);
  cursor: pointer;
}
.cart-line-remove:hover {
  color: var(--danger, #DE1316);
  border-color: currentColor;
  background: var(--surface-raised, #f6f6f6);
}
.cart-panel-empty { text-align: center; padding: 28px 12px; color: var(--text-muted); font-size: 13px; }
.cart-panel-foot { margin-top: 4px; padding-top: 14px; border-top: 1px solid var(--border); }
.cart-panel-foot .btn { margin-top: 12px; }

/* Cart page */
.cart-page-layout {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
  align-items: start;
}
.cart-item {
  display: grid; grid-template-columns: 72px 1fr auto; gap: 14px; align-items: start;
  padding: 16px 0; border-bottom: 1px solid var(--border);
}
.cart-item:last-child { border-bottom: none; }
.cart-item .thumb {
  width: 72px; height: 72px; border-radius: var(--radius); background: linear-gradient(145deg, #C45C3A, #3D2318);
  flex-shrink: 0;
}
.cart-item .thumb.t-beef { background: linear-gradient(145deg, #C45C3A 0%, #8B3A22 55%, #3D2318 100%); }
.cart-item .thumb.t-cheese { background: linear-gradient(145deg, #E8A54B 0%, #C45C3A 50%, #5C3317 100%); }
.cart-item .thumb.t-plant { background: linear-gradient(145deg, #7BA05B 0%, #3D5C3A 60%, #1F2E1C 100%); }
.cart-item .thumb.t-chicken { background: linear-gradient(145deg, #D4A574 0%, #A65D3A 55%, #4A2C1A 100%); }
.cart-item .thumb.t-double { background: linear-gradient(145deg, #B85C38 0%, #6B2E1A 50%, #2A1810 100%); }
.cart-item .thumb.t-side { background: linear-gradient(145deg, #E8C36A 0%, #C48A2A 60%, #5C3A12 100%); }
.cart-item .thumb.t-drink { background: linear-gradient(145deg, #F0C94A, #DE1316); }
.cart-item-body { min-width: 0; }
.cart-item-edit {
  display: block;
  color: inherit;
  text-decoration: none;
}
.cart-item-edit:hover .title { text-decoration: underline; }
.cart-item .title {
  font-weight: 600;
  font-size: 14.5px;
  line-height: 1.35;
  white-space: pre-line;
}
.cart-item .mods { font-size: 12.5px; color: var(--text-muted); margin: 4px 0 10px; line-height: 1.4; }
.cart-item-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.cart-item .line-total { font-weight: 600; font-size: 14.5px; text-align: right; }
.upsell-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 8px; }
.upsell-card {
  background: var(--surface-raised); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 12px; font-size: 12.5px;
}
.upsell-card .name { font-weight: 500; margin-bottom: 4px; }
.tip-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.tip-pills label {
  border: 1px solid var(--border); border-radius: var(--radius-full); padding: 8px 14px;
  font-size: 13px; font-weight: 500; cursor: pointer; background: var(--surface);
}
.tip-pills input { display: none; }
.tip-pills label:has(input:checked) {
  border-color: var(--primary);
  background: var(--primary-subtle);
  color: var(--primary-hover);
}
.checkout-row {
  display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border);
  font-size: 13.5px;
}
.checkout-row:last-child { border-bottom: none; }
.checkout-row .icon {
  width: 36px; height: 36px; border-radius: 50%; background: var(--surface-sunken);
  display: grid; place-items: center; font-size: 14px; flex-shrink: 0; color: var(--text-secondary);
}
.checkout-row .grow { flex: 1; min-width: 0; }
.checkout-row .sub { font-size: 12.5px; color: var(--text-muted); margin-top: 2px; }
.time-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
.time-card {
  border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; cursor: pointer;
  background: var(--surface); font-size: 13px;
}
.time-card.active, .time-card:has(input:checked) {
  border-color: var(--primary);
  background: var(--primary-subtle);
  color: var(--primary);
}
.time-card.active .muted,
.time-card:has(input:checked) .muted { color: var(--primary); }
.shop-body .time-card.active,
.shop-body .time-card:has(input:checked),
.shop-body .time-card.active .muted,
.shop-body .time-card:has(input:checked) .muted,
.shop-body .time-card.active strong,
.shop-body .time-card:has(input:checked) strong {
  color: var(--primary);
}
.time-card input { display: none; }
.time-card strong { display: block; margin-bottom: 2px; }
.map-mini {
  height: 88px; border-radius: var(--radius); margin-bottom: 10px;
  background:
    radial-gradient(circle at 42% 48%, var(--text) 0 5px, transparent 6px),
    linear-gradient(145deg, #E8E4DF 0%, #D4D0CB 40%, #C8D4D8 100%);
  border: 1px solid var(--border);
}
.checkout-edit-block {
  padding: 0 0 12px;
  margin-top: -4px;
  border-bottom: 1px solid var(--border);
}
.checkout-edit-block .field { margin-bottom: 12px; }
.checkout-edit-block .form-row { margin-bottom: 0; }

/* Account area */
.account-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 24px;
  align-items: start;
}
.account-nav {
  position: sticky; top: 72px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 10px; 
}
.account-nav .nav-label { font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--text-muted); padding: 8px 12px 6px; }
.account-nav a {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-sm);
  font-size: 13.5px; color: var(--text-secondary); margin-bottom: 2px;
}
.account-nav a:hover { background: var(--surface-raised); color: var(--text); }
.account-nav a.active { background: var(--brand-subtle); color: var(--brand-hover); font-weight: 500; }
.account-nav .nav-ico { width: 18px; text-align: center; opacity: .7; font-size: 13px; }
.account-nav .logout,
.account-nav button.logout {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 10px 12px; border-radius: var(--radius-sm);
  font-size: 13.5px; color: var(--danger); margin-top: 8px;
  border-top: 1px solid var(--border); padding-top: 12px;
  background: none; border-left: none; border-right: none; border-bottom: none;
  cursor: pointer; font-family: inherit; text-align: left;
}
.account-nav button.logout:hover { background: var(--surface-raised); }
.account-profile-card { text-align: center; padding: 20px 16px 12px; border-bottom: 1px solid var(--border); margin-bottom: 8px; }
.account-avatar {
  width: 56px; height: 56px; border-radius: 50%; background: var(--brand); color: #fff;
  display: grid; place-items: center; font-weight: 600; margin: 0 auto 10px; font-size: 16px;
}
.account-section { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; margin-bottom: 14px; }
.account-section h2 { font-size: 15px; margin: 0 0 14px; }
.account-field-row {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 16px;
  padding: 12px 0; border-bottom: 1px solid var(--border); font-size: 13.5px;
}
.account-field-row:last-child { border-bottom: none; }
.account-field-row .label { font-size: 12px; color: var(--text-muted); margin-bottom: 2px; }
.address-card, .pay-card {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
  padding: 14px; border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 10px;
  background: var(--surface-raised);
}
.address-card.default, .pay-card.default { border-color: var(--brand-muted); background: var(--brand-subtle); }
.order-card {
  display: grid; grid-template-columns: 1fr auto; gap: 12px; padding: 14px 0;
  border-bottom: 1px solid var(--border); font-size: 13.5px;
}
.order-card:last-child { border-bottom: none; }

/* Order tracking */
.track-page { min-height: calc(100vh - 57px); position: relative; }
.track-page.is-splash,
.track-page.is-live:has(.is-panel-only) {
  display: grid;
  place-items: center;
  justify-items: center;
  min-height: calc(100vh - 57px);
  width: 100%;
  padding: 28px 16px 40px;
  box-sizing: border-box;
  background:
    radial-gradient(ellipse 70% 55% at 50% 18%, color-mix(in srgb, var(--brand) 14%, transparent), transparent 68%),
    linear-gradient(180deg, var(--surface-sunken) 0%, var(--surface) 100%);
}
.track-splash {
  width: min(420px, 100%);
  text-align: center;
  padding: 8px 8px 0;
}
.track-splash-inner {
  display: grid;
  gap: 14px;
  justify-items: center;
  animation: track-splash-in 0.45s ease-out both;
}
@keyframes track-splash-in {
  from { opacity: 0; transform: translateY(10px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.track-splash-mark {
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  margin: 4px 0 6px;
  border-radius: 999px;
  color: #fff;
  background: var(--brand);
  box-shadow:
    0 0 0 12px color-mix(in srgb, var(--brand) 12%, transparent),
    0 14px 32px color-mix(in srgb, var(--brand) 28%, transparent);
}
.track-splash-mark svg { width: 40px; height: 40px; }
.track-page.is-live .track-split.is-panel-only {
  display: block;
  width: min(520px, 100%);
  max-width: 520px;
  margin: 0 auto;
  background: transparent;
  min-height: 0;
}
.track-page.is-live .track-split.is-panel-only .track-panel {
  width: 100%;
  max-width: none;
  max-height: none;
  min-height: 0;
  margin: 0;
  padding: 28px 26px 32px;
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  border-left: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-sm, 0 8px 24px rgba(9, 9, 11, 0.06));
  box-sizing: border-box;
  animation: track-splash-in 0.4s ease-out both;
}
.track-page.is-live .track-split.is-panel-only .track-panel-top {
  margin-bottom: 2px;
}
.track-page.is-live .track-split.is-panel-only .track-back-btn {
  margin: 2px 0 14px;
  padding-left: 0;
}
.track-page.is-live .track-split.is-panel-only .track-panel h1 {
  font-size: clamp(22px, 4vw, 28px);
  text-wrap: balance;
}
.track-page.is-live .track-split.is-panel-only .track-status-copy {
  text-wrap: pretty;
}
.track-page.is-live .track-split.has-map {
  grid-template-columns: 1.1fr 0.9fr;
  place-self: stretch;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
}
.track-page.is-live:has(.has-map) {
  display: block;
  padding: 0;
  background: var(--surface);
}
.track-splash-eyebrow {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.track-splash-title {
  margin: 0;
  font-size: clamp(30px, 5.5vw, 40px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 700;
}
.track-splash-order {
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-muted);
  max-width: 34ch;
}
.track-splash-pos {
  width: 100%;
  margin-top: 4px;
  padding: 16px 18px;
  border-radius: calc(var(--radius) + 2px);
  border: 1px solid var(--border);
  background: var(--surface);
  text-align: center;
  box-shadow: var(--shadow-sm, 0 6px 18px rgba(9, 9, 11, 0.05));
}
.track-splash-pos p {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.45;
  color: var(--text-secondary);
  text-wrap: pretty;
}
.track-splash-pos-label {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
}
.track-splash-pos.is-pilot {
  border-color: color-mix(in srgb, var(--success) 35%, var(--border));
  background: var(--success-subtle, #ecfdf5);
}
.track-splash-pos.is-manual {
  border-color: color-mix(in srgb, var(--warning, #d97706) 35%, var(--border));
  background: var(--warning-subtle, #fffbeb);
}
.track-splash-cta {
  margin-top: 6px;
  min-width: 200px;
  min-height: 44px;
  font-weight: 600;
}
.track-splash-hint { margin: 0; font-size: 12.5px; }
.track-points-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  background: var(--brand-subtle);
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
}
.track-points-chip-inline { margin-left: auto; }
.track-panel-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}
.track-pos-pill {
  display: inline-flex;
  align-items: center;
  margin: 0 0 14px;
  padding: 6px 10px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--border);
  background: var(--surface);
}
.track-pos-pill.is-pilot {
  border-color: color-mix(in srgb, var(--success) 35%, var(--border));
  color: var(--success, #15803d);
  background: var(--success-subtle, #ecfdf5);
}
.track-pos-pill.is-manual {
  border-color: color-mix(in srgb, var(--warning, #d97706) 35%, var(--border));
  color: #92400e;
  background: var(--warning-subtle, #fffbeb);
}
.track-split {
  display: grid; grid-template-columns: 1.15fr 400px; min-height: calc(100vh - 57px);
  max-width: 1280px; margin: 0 auto;
}
.track-map {
  position: relative; min-height: 420px; height: 100%;
  background: #E8E4DF;
  overflow: hidden;
}
.track-map-canvas {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0;
}
.track-map .mapboxgl-canvas-container,
.track-map .mapboxgl-map {
  width: 100%; height: 100%;
}
.track-map .mapboxgl-ctrl-attrib {
  font-size: 10px;
}
.track-leaflet-pin { background: transparent; border: none; }
.track-leaflet-pin-inner {
  width: 48px; height: 48px; border-radius: 50%;
  display: grid; place-items: center; color: #fff;
  box-shadow: var(--shadow); background: var(--text);
}
.track-leaflet-pin.store .track-leaflet-pin-inner,
.track-leaflet-pin.rider .track-leaflet-pin-inner { background: var(--brand); }
.track-leaflet-pin.rider .track-leaflet-pin-inner {
  border: 3px solid #fff; animation: track-pulse 2s ease-in-out infinite;
}
.track-map-label {
  position: absolute; z-index: 500; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-full); padding: 6px 12px; font-size: 12px; font-weight: 500;
  box-shadow: var(--shadow-sm); white-space: nowrap;
  left: 50%; top: 16px; transform: translateX(-50%);
}
.track-map-help {
  position: absolute; top: 14px; right: 14px; z-index: 500;
}
.track-visual {
  position: relative; min-height: 420px; height: 100%;
  border-right: 1px solid var(--border); background: var(--surface-sunken);
}
.track-visual .track-map,
.track-visual .track-stage-art { display: none; height: 100%; min-height: 420px; }
.track-visual[data-stage="confirmed"] .track-stage-art[data-for="confirmed"],
.track-visual[data-stage="preparing"] .track-stage-art[data-for="preparing"] { display: flex; }
.track-visual[data-stage="on-the-way"] .track-map { display: block; }
.track-page[data-stage="on-the-way"] .track-cancel,
.track-page[data-stage="delivered"] .track-cancel { display: none; }
.track-pin-banner {
  display: none;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  margin-bottom: 14px;
  background: var(--info-subtle);
  border: 1px solid #BFDBFE;
  border-radius: var(--radius);
  font-size: 13px;
  line-height: 1.4;
}
.track-pin-banner.is-visible,
.track-page[data-stage="on-the-way"] .track-pin-banner.is-visible { display: flex; }
.track-pin-code {
  font-size: 22px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.12em;
  color: var(--info);
  padding: 6px 12px;
  background: var(--surface);
  border: 1px dashed #BFDBFE;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.track-split[data-stage="delivered"],
.track-split:has([data-stage="delivered"]) {
  grid-template-columns: 1fr;
  max-width: none;
  margin: 0;
  background: transparent;
}
.track-split[data-stage="delivered"] .track-visual,
.track-split:has([data-stage="delivered"]) .track-visual { display: none; }
.track-split[data-stage="delivered"] .track-panel,
.track-split:has([data-stage="delivered"]) .track-panel {
  width: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 24px 22px 28px;
  background: var(--surface);
  border-left: none;
  border-radius: 0;
  box-shadow: none;
  box-sizing: border-box;
}
.track-page[data-stage="delivered"] {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 20px 40px;
}
.track-split[data-stage="delivered"] .track-progress,
.track-split[data-stage="delivered"] .track-status-copy,
.track-split[data-stage="delivered"] .track-driver,
.track-split:has([data-stage="delivered"]) .track-progress,
.track-split:has([data-stage="delivered"]) .track-status-copy,
.track-split:has([data-stage="delivered"]) .track-driver { display: none; }
.track-split[data-stage="delivered"] .track-eta,
.track-split:has([data-stage="delivered"]) .track-eta { color: var(--success); margin-bottom: 18px; }
.track-split[data-stage="delivered"] .track-eta strong,
.track-split:has([data-stage="delivered"]) .track-eta strong { color: var(--success); }
.track-split[data-stage="delivered"] .track-points,
.track-split:has([data-stage="delivered"]) .track-points {
  background: var(--success-subtle);
  border-color: #BBF7D0;
  margin-bottom: 16px;
}
body.track-body .btn.primary { background: var(--brand); color: #fff; border-color: var(--brand); }
body.track-body .btn.primary:hover { background: var(--brand-hover); border-color: var(--brand-hover); }
body.track-body .btn.secondary { background: var(--surface); border-color: var(--border); color: var(--text); }
body.track-body .btn.ghost { background: transparent; border-color: transparent; color: var(--text-secondary); }
body.track-body .btn.ghost:hover { background: var(--surface-sunken); color: var(--text); }
.track-back-btn { margin-bottom: 8px; padding-left: 0; }
.track-review { margin-bottom: 12px; }
.track-stage-art {
  align-items: center; justify-content: center; flex-direction: column; gap: 18px;
  padding: 32px 24px; text-align: center;
  background:
    radial-gradient(ellipse at 50% 30%, var(--brand-subtle) 0%, transparent 55%),
    linear-gradient(180deg, #F7F3EF 0%, var(--surface-sunken) 100%);
}
.track-stage-art svg { width: min(280px, 70%); height: auto; display: block; }
.track-stage-art .art-caption { font-size: 15px; font-weight: 600; color: var(--text); }
.track-stage-art .art-sub { font-size: 13px; color: var(--text-muted); max-width: 280px; line-height: 1.45; }
.track-review-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
}
.track-review-card h2 { font-size: 15px; margin: 0 0 4px; }
.track-rate-row {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 10px 0; border-bottom: 1px solid var(--border);
}
.track-rate-row:last-of-type { border-bottom: none; }
.track-rate-label { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.star-rate { display: flex; gap: 2px; flex-shrink: 0; }
.star-rate button {
  border: none; background: transparent; padding: 2px 3px; cursor: pointer;
  font-size: 22px; line-height: 1; color: #D4D4D8;
}
.star-rate button.is-on { color: var(--brand); }
.star-rate:hover button { color: var(--brand); }
.star-rate:hover button:hover ~ button { color: #D4D4D8; }
.track-review-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.tag-chip {
  border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius-full);
  padding: 6px 12px; font-size: 12.5px; cursor: pointer; color: var(--text-secondary);
}
.tag-chip.is-on {
  border-color: var(--brand-muted); background: var(--brand-subtle); color: var(--brand-hover); font-weight: 500;
}
.track-review textarea {
  width: 100%; resize: vertical; min-height: 72px; font: inherit;
  border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 12px;
  background: var(--surface);
}
@keyframes track-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(232,93,42,.45); }
  50% { box-shadow: 0 0 0 12px rgba(232,93,42,0); }
}
@keyframes track-check-pop {
  0% { transform: scale(.6); opacity: 0; }
  60% { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes track-ring {
  0% { stroke-dashoffset: 120; opacity: .3; }
  100% { stroke-dashoffset: 0; opacity: 1; }
}
@keyframes track-store-spin {
  to { transform: rotate(360deg); }
}
@keyframes track-store-bar {
  0%, 100% { transform: scaleX(.45); }
  50% { transform: scaleX(1); }
}
.track-svg.enterprise-art,
.track-svg.store-illu { width: min(260px, 72%); }
.track-svg .store-ring {
  transform-origin: 120px 100px;
  animation: track-store-spin 2.4s linear infinite;
}
.track-svg .store-bar {
  transform-origin: 72px 173px;
  animation: track-store-bar 2s ease-in-out infinite;
}
.track-svg .store-mark {
  transform-box: fill-box;
  transform-origin: center;
}
.track-svg .check-pop { transform-origin: 120px 100px; animation: track-check-pop 1.1s ease-out both; }
.track-svg .ring-draw { stroke-dasharray: 302; animation: track-ring 1.4s ease-out both; }
.track-points-ico {
  display: grid; place-items: center; width: 28px; height: 28px; flex-shrink: 0;
  border-radius: var(--radius-sm); background: var(--surface); color: var(--brand);
  border: 1px solid var(--brand-muted);
}
.track-points-ico svg { display: block; }
.track-panel {
  background: var(--surface); padding: 24px 22px 28px; overflow-y: auto;
  max-height: calc(100vh - 57px);
}
.track-panel .order-id { font-size: 12.5px; color: var(--text-muted); margin-bottom: 6px; }
.track-panel h1 { font-size: 24px; letter-spacing: -.02em; margin: 0 0 4px; }
.track-eta { font-size: 14px; color: var(--text-secondary); margin-bottom: 16px; }
.track-eta strong { color: var(--text); }
.track-progress {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin: 8px 0 18px; position: relative;
}
.track-progress::before {
  content: ""; position: absolute; top: 15px; left: 12%; right: 12%; height: 2px;
  background: var(--border); z-index: 0;
}
.track-progress::after {
  content: ""; position: absolute; top: 15px; left: 12%; height: 2px;
  background: var(--brand); z-index: 0; width: 12%;
  transition: width .3s ease;
}
.track-split[data-stage="confirmed"] .track-progress::after { width: 12%; }
.track-split[data-stage="preparing"] .track-progress::after { width: 38%; }
.track-split[data-stage="on-the-way"] .track-progress::after { width: 64%; }
.track-split[data-stage="delivered"] .track-progress::after { width: 76%; }
.track-progress .tp-step {
  position: relative; z-index: 1; text-align: center; font-size: 11px; color: var(--text-muted);
}
.track-progress .tp-step .dot {
  width: 32px; height: 32px; border-radius: 50%; margin: 0 auto 8px;
  background: var(--surface); border: 1.5px solid var(--border);
  display: grid; place-items: center; color: var(--text-muted);
}
.track-progress .tp-step .dot svg { display: block; }
.track-progress .tp-step.done .dot,
.track-progress .tp-step.now .dot {
  background: var(--brand); border-color: var(--brand); color: #fff;
}
.track-progress .tp-step.now { color: var(--brand); font-weight: 600; }
.track-progress .tp-step.done { color: var(--text-secondary); }
.track-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.track-actions .btn.danger-outline {
  border-color: #FECACA; color: var(--danger); background: #fff;
}
.track-actions .btn.danger-outline:hover { background: #FEF2F2; }
.track-cancel-sheet {
  display: none; margin-bottom: 14px; padding: 14px; border: 1px solid #FECACA;
  background: #FEF2F2; border-radius: var(--radius); font-size: 13.5px;
}
.track-cancel-sheet.is-open { display: block; }
.track-cancel-sheet h3 { font-size: 14px; margin: 0 0 6px; }
.track-cancel-sheet p { margin: 0 0 12px; color: var(--text-secondary); line-height: 1.45; }
.track-demo-stages {
  position: fixed; left: 14px; bottom: 14px; z-index: 40;
  display: flex; gap: 6px; flex-wrap: wrap; max-width: calc(100% - 60px);
}
.track-demo-stages button {
  border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius-full);
  padding: 5px 10px; font-size: 11px; cursor: pointer; box-shadow: var(--shadow-sm); color: var(--text-secondary);
}
.track-demo-stages button.active { border-color: var(--brand); color: var(--brand-hover); background: var(--brand-subtle); }
.track-status-copy { font-size: 13.5px; color: var(--text-secondary); margin-bottom: 18px; line-height: 1.45; }
.track-driver {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px;
  background: var(--surface-raised); border: 1px solid var(--border); border-radius: var(--radius);
  margin-bottom: 12px;
}
.track-driver .avatar {
  width: 44px; height: 44px; border-radius: 50%; background: var(--text); color: #fff;
  display: grid; place-items: center; font-weight: 600; font-size: 14px; flex-shrink: 0;
}
.track-driver .grow { flex: 1; min-width: 0; }
.track-driver .actions { display: flex; gap: 8px; }
.track-points {
  display: flex; align-items: center; gap: 10px; padding: 12px 14px; margin-bottom: 12px;
  background: var(--brand-subtle); border: 1px solid var(--brand-muted); border-radius: var(--radius);
  font-size: 13px;
}
.track-details-toggle {
  width: 100%; display: flex; justify-content: space-between; align-items: center;
  padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface-raised); font-size: 13.5px; font-weight: 500; cursor: pointer; margin-bottom: 14px;
}
.track-details[open] .track-details-toggle { border-radius: var(--radius) var(--radius) 0 0; margin-bottom: 0; }
.track-details-body {
  border: 1px solid var(--border); border-top: none; border-radius: 0 0 var(--radius) var(--radius);
  padding: 12px 14px 14px; margin-bottom: 12px;
}
.track-addr { font-size: 13.5px; margin-bottom: 12px; }
.track-addr .label { font-size: 11.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px; }
.track-addr .note { font-size: 12.5px; color: var(--text-muted); margin-top: 6px; line-height: 1.4; }
body.track-body { background: var(--surface); }
body.track-body .shop-wrap {
  max-width: none;
  padding: 0;
}
body.track-body .shop-footer { display: none; }

/* Item detail */
.item-hero { height: 280px; background: linear-gradient(135deg, #EDE9E4, #D9D2CA); border-radius: var(--radius-lg); margin-bottom: 20px; }
.item-hero.t-beef { background: linear-gradient(145deg, #C45C3A 0%, #8B3A22 55%, #3D2318 100%); }
.item-hero.t-cheese { background: linear-gradient(145deg, #E8A54B 0%, #C45C3A 50%, #5C3317 100%); }
.item-hero.t-plant { background: linear-gradient(145deg, #7BA05B 0%, #3D5C3A 60%, #1F2E1C 100%); }
.item-hero.t-chicken { background: linear-gradient(145deg, #D4A574 0%, #A65D3A 55%, #4A2C1A 100%); }
.item-hero.t-double { background: linear-gradient(145deg, #B85C38 0%, #6B2E1A 50%, #2A1810 100%); }
.item-hero.t-side { background: linear-gradient(145deg, #E8C36A 0%, #C48A2A 60%, #5C3A12 100%); }
.item-hero.t-drink { background: linear-gradient(145deg, #F0C94A 0%, #DE1316 45%, #7A2E12 100%); }
.item-hero.has-photo {
  background: #fff;
  overflow: hidden;
  position: relative;
}
.item-hero.has-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.28);
  filter: saturate(1.18) contrast(1.08) brightness(1.03);
  display: block;
}
.opt-group { border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); margin-bottom: 12px; overflow: hidden; }
.opt-group .og-head { padding: 12px 16px; background: var(--surface-raised); border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.opt-row { display: flex; align-items: center; gap: 10px; padding: 11px 16px; border-bottom: 1px solid var(--border); font-size: 13.5px; }
.opt-row:last-child { border-bottom: none; }
.opt-row .price { margin-left: auto; color: var(--text-secondary); font-variant-numeric: tabular-nums; font-size: 13px; }
.opt-row input { accent-color: var(--brand); width: 16px; height: 16px; }
.opt-nested {
  margin: 8px 12px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md, 10px);
  background: var(--surface-raised);
  overflow: hidden;
}
.opt-nested .og-head { padding: 10px 14px; }
.opt-nested .opt-row { padding: 10px 14px; }
.item-footer {
  position: sticky; bottom: 0; background: var(--surface); border-top: 1px solid var(--border);
  padding: 14px 20px calc(14px + env(safe-area-inset-bottom, 0px));
  margin: 20px -20px -80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  box-shadow: 0 -4px 12px rgba(0,0,0,.04);
}
.item-footer .item-add-btn {
  width: 100%;
  max-width: 420px;
  min-height: 52px;
  padding: 14px 20px;
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--radius-md, 10px);
}
.item-modal-backdrop {
  align-items: flex-end;
  padding: 0;
  z-index: 90;
}
@media (min-width: 640px) {
  .item-modal-backdrop {
    align-items: center;
    padding: 20px;
  }
}
.item-modal {
  max-width: 720px;
  width: 100%;
  max-height: min(92vh, 880px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  margin: 0;
}
@media (min-width: 640px) {
  .item-modal {
    border-radius: var(--radius-lg);
  }
}
.item-modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 3;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  box-shadow: var(--shadow);
}
.item-modal-close:hover { background: var(--surface-raised); }
.item-customise--modal {
  display: flex;
  flex-direction: column;
  max-height: min(92vh, 880px);
}
.item-customise-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.item-customise--modal .item-customise-scroll {
  padding: 18px 18px 8px;
}
.item-customise--modal .item-hero {
  height: 340px;
  margin: -18px -18px 16px;
  border-radius: 0;
}
.item-customise--modal .item-footer {
  position: relative;
  margin: 0;
  flex-shrink: 0;
  padding: 14px 18px calc(14px + env(safe-area-inset-bottom, 0px));
}
body:has(.item-modal-backdrop) {
  overflow: hidden;
}
.qty-stepper { display: inline-flex; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; width: auto; }
.qty-stepper button { padding: 8px 14px; border: none; background: var(--surface); cursor: pointer; font-size: 16px; color: var(--text-secondary); }
.qty-stepper button:disabled { opacity: 0.4; cursor: not-allowed; }
.qty-stepper span { padding: 8px 16px; font-weight: 600; border-left: 1px solid var(--border); border-right: 1px solid var(--border); min-width: 44px; text-align: center; }

/* Checkout */
.checkout-layout { display: grid; grid-template-columns: 1.2fr 0.95fr; gap: 28px; align-items: start; }
.checkout-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 14px;
}
.checkout-section h2 { font-size: 15px; }
.checkout-main { min-width: 0; }
.checkout-promo-row {
  display: flex;
  align-items: end;
  gap: 8px;
  flex-wrap: wrap;
}
.checkout-summary-card .checkout-summary-line {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 10px;
  align-items: start;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.checkout-summary-card .checkout-summary-line:last-of-type { border-bottom: none; }
.checkout-summary-card .thumb {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: linear-gradient(145deg, #C45C3A, #3D2318);
}
.checkout-summary-card .thumb.t-beef { background: linear-gradient(145deg, #C45C3A 0%, #8B3A22 55%, #3D2318 100%); }
.checkout-summary-card .thumb.t-cheese { background: linear-gradient(145deg, #E8A54B 0%, #C45C3A 50%, #5C3317 100%); }
.checkout-summary-card .thumb.t-plant { background: linear-gradient(145deg, #7BA05B 0%, #3D5C3A 60%, #1F2E1C 100%); }
.checkout-summary-card .thumb.t-chicken { background: linear-gradient(145deg, #D4A574 0%, #A65D3A 55%, #4A2C1A 100%); }
.checkout-summary-card .thumb.t-double { background: linear-gradient(145deg, #B85C38 0%, #6B2E1A 50%, #2A1810 100%); }
.checkout-summary-card .thumb.t-side { background: linear-gradient(145deg, #E8C36A 0%, #C48A2A 60%, #5C3A12 100%); }
.checkout-summary-card .thumb.t-drink { background: linear-gradient(145deg, #F0C94A, #DE1316); }
.checkout-summary-copy { min-width: 0; }
.checkout-summary-copy .name {
  font-weight: 500;
  line-height: 1.35;
  white-space: pre-line;
}
.checkout-summary-copy .mods {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
  line-height: 1.35;
}
.checkout-summary-card .price {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.checkout-summary-card .summary-lines {
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.checkout-payment-block {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.checkout-payment-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--text);
  margin-bottom: 12px;
}
.checkout-payment-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.checkout-payment-brand {
  flex-shrink: 0;
  min-width: 44px;
  height: 28px;
  padding: 0 8px;
  border-radius: 4px;
  background: var(--surface-sunken);
  color: var(--text-secondary);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .02em;
  display: grid;
  place-items: center;
}
.checkout-payment-brand.is-visa {
  background: #1A1F71;
  color: #fff;
  font-style: italic;
  font-size: 12px;
  letter-spacing: -.02em;
}
.checkout-payment-title {
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.3;
}
.checkout-payment-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 1px;
  line-height: 1.3;
}
.checkout-payment-change {
  margin-left: auto;
  border: none;
  background: transparent;
  color: var(--primary);
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  padding: 4px 0;
  flex-shrink: 0;
}
.checkout-payment-change:hover { color: var(--primary-hover); }
.checkout-payment-options {
  margin-top: 10px;
  margin-bottom: 0;
}
.checkout-place-btn {
  margin-top: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
}
.checkout-place-btn span:last-child {
  font-variant-numeric: tabular-nums;
}
.upsell-card .upsell-thumb {
  height: 72px;
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  background: linear-gradient(145deg, #C45C3A, #3D2318);
}
.upsell-card .upsell-thumb.t-beef { background: linear-gradient(145deg, #C45C3A 0%, #8B3A22 55%, #3D2318 100%); }
.upsell-card .upsell-thumb.t-cheese { background: linear-gradient(145deg, #E8A54B 0%, #C45C3A 50%, #5C3317 100%); }
.upsell-card .upsell-thumb.t-plant { background: linear-gradient(145deg, #7BA05B 0%, #3D5C3A 60%, #1F2E1C 100%); }
.upsell-card .upsell-thumb.t-chicken { background: linear-gradient(145deg, #D4A574 0%, #A65D3A 55%, #4A2C1A 100%); }
.upsell-card .upsell-thumb.t-double { background: linear-gradient(145deg, #B85C38 0%, #6B2E1A 50%, #2A1810 100%); }
.upsell-card .upsell-thumb.t-side { background: linear-gradient(145deg, #E8C36A 0%, #C48A2A 60%, #5C3A12 100%); }
.upsell-card .upsell-thumb.t-drink { background: linear-gradient(145deg, #F0C94A, #DE1316); }
.tip-pills label.is-active,
.tip-pills label:has(input:checked) {
  border-color: var(--primary);
  background: var(--primary-subtle);
  color: var(--primary-hover);
}
.summary-sticky { position: sticky; top: 72px; }
.summary-line { display: flex; justify-content: space-between; font-size: 13.5px; padding: 4px 0; }
.summary-line.total { border-top: 1px solid var(--border); margin-top: 8px; padding-top: 12px; font-size: 16px; font-weight: 600; }
.loyalty-toggle { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; background: var(--surface-raised); border-radius: var(--radius-sm); margin: 10px 0; font-size: 13px; }

/* Loyalty account */
.loyalty-hero { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px; margin-bottom: 20px; }
.loyalty-hero .balance { font-size: 40px; font-weight: 600; letter-spacing: -.03em; }
.loyalty-hero .balance span { font-size: 16px; font-weight: 500; color: var(--text-muted); }

/* Admin loyalty programme */
.loyalty-page .page-head h1 { letter-spacing: -.03em; }
.loyalty-live-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: var(--radius-full);
  background: var(--success-subtle); border: 1px solid #BBF7D0;
  font-size: 12px; font-weight: 500; color: var(--success);
}
.loyalty-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  padding: 0;
  background:
    linear-gradient(135deg, var(--brand-subtle) 0%, var(--surface) 42%, var(--surface) 100%);
  border: 1px solid var(--brand-muted);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.loyalty-strip-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 18px;
  border-left: 1px solid color-mix(in srgb, var(--brand-muted) 70%, transparent);
  position: relative;
}
.loyalty-strip-item:first-child { border-left: none; }
.loyalty-strip-item .strip-label {
  font-size: 11px; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--text-muted);
}
.loyalty-strip-item strong { font-size: 13.5px; font-weight: 600; letter-spacing: -.01em; }
.loyalty-rule-list { display: flex; flex-direction: column; gap: 0; }
.loyalty-rule-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.loyalty-rule-row[hidden] { display: none !important; }
.loyalty-rule-row:last-of-type { border-bottom: none; }
.loyalty-rule-row strong { font-size: 13.5px; }
.loyalty-input {
  width: 88px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 500;
  background: var(--surface-raised);
  text-align: right;
}
.loyalty-input:focus {
  outline: 2px solid var(--brand-subtle);
  border-color: var(--brand);
  background: var(--surface);
}
.loyalty-input-wide {
  width: 200px;
  text-align: left;
}
.loyalty-rules-card {
  max-width: 680px;
  background:
    linear-gradient(180deg, var(--surface) 0%, var(--surface) 100%);
}
.loyalty-rules-foot {
  display: flex; align-items: center; gap: 12px;
  margin-top: 8px; padding-top: 18px;
  border-top: 1px solid var(--border);
}
.tier-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  align-items: stretch;
}
.tier-grid > .card + .card { margin-top: 0; }
.tier-card {
  position: relative;
  overflow: hidden;
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 100%;
  transition: transform .15s ease, box-shadow .15s ease;
}
.tier-card::before {
  content: "";
  position: absolute; left: 0; right: 0; top: 0; height: 4px;
}
.tier-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.tier-card.bronze {
  background: linear-gradient(180deg, #FAF8F6 0%, var(--surface) 48%);
}
.tier-card.bronze::before { background: #A8A29E; }
.tier-card.silver {
  background: linear-gradient(180deg, #F7F9FC 0%, var(--surface) 48%);
}
.tier-card.silver::before { background: #64748B; }
.tier-card.gold {
  background: linear-gradient(180deg, #FFFBEB 0%, var(--surface) 48%);
  border-color: #FDE68A;
}
.tier-card.gold::before { background: linear-gradient(90deg, #EAB308, #CA8A04); }
.tier-card .tier-count {
  font-size: 32px;
  font-weight: 600;
  letter-spacing: -.03em;
  margin: 14px 0 2px;
  font-variant-numeric: tabular-nums;
}
.tier-share {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--text-muted); margin-bottom: 4px;
}
.tier-share::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: currentColor; opacity: .55;
}
.tier-card.bronze .tier-share { color: #78716C; }
.tier-card.silver .tier-share { color: #64748B; }
.tier-card.gold .tier-share { color: #A16207; }
.tier-meta {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  margin-bottom: auto;
  padding: 12px;
  background: rgba(255,255,255,.7);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  flex: 1;
}
.tier-meta > div { display: flex; flex-direction: column; gap: 2px; }
.tier-meta strong { font-size: 13px; font-weight: 500; }
.tier-card > .btn {
  margin-top: 12px;
  width: 100%;
}
.tier-card-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.tier-card-actions .btn {
  flex: 1;
  margin-top: 0;
  width: auto;
}
.tier-dist-card {
  background: linear-gradient(180deg, var(--surface-raised), var(--surface));
}
.tier-dist { overflow: hidden; border-radius: var(--radius-full); height: 12px; display: flex; }
.tier-dist > span { display: block; height: 100%; }
.tier-legend {
  display: flex; flex-wrap: wrap; gap: 16px;
  margin-top: 12px;
}
.tier-legend span {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12.5px; color: var(--text-secondary);
}
.tier-legend i {
  width: 10px; height: 10px; border-radius: 3px; display: inline-block;
}
.tier-multiselect {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 12px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  max-height: 160px;
  overflow-y: auto;
}
.tier-multiselect .tier-option {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  padding: 6px 12px;
  font-size: 12.5px;
  font-weight: 500;
  font-family: var(--font);
  cursor: pointer;
}
.tier-multiselect .tier-option:hover {
  border-color: var(--border-strong);
  color: var(--text);
}
.tier-multiselect .tier-option.is-selected {
  background: var(--brand-subtle);
  border-color: var(--brand-muted);
  color: var(--brand-hover);
}
.pts-chip {
  display: inline-flex; align-items: center;
  padding: 3px 9px; border-radius: var(--radius-full);
  background: var(--brand-subtle); color: var(--brand-hover);
  border: 1px solid var(--brand-muted);
  font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums;
}
.activity-row {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 12px 14px;
  margin: 0 -6px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  transition: background .12s, border-color .12s;
}
.activity-row + .activity-row { margin-top: 2px; }
.activity-row:hover {
  background: var(--surface-raised);
  border-color: var(--border);
}
.activity-row-body { flex: 1; min-width: 0; }
.activity-row .badge { margin-left: 8px; vertical-align: middle; }
.activity-time {
  font-size: 12px; color: var(--text-muted);
  font-variant-numeric: tabular-nums; min-width: 42px; text-align: right;
}
.tab-panel[hidden] { display: none; }
.tab-panel:not([hidden]) {
  animation: loyalty-in .2s ease;
}
@keyframes loyalty-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: none; }
}
@media (max-width: 900px) {
  .loyalty-strip { grid-template-columns: 1fr 1fr; }
  .loyalty-strip-item {
    border-left: none;
    border-top: 1px solid color-mix(in srgb, var(--brand-muted) 70%, transparent);
  }
  .loyalty-strip-item:nth-child(-n+2) { border-top: none; }
  .loyalty-strip-item:nth-child(2) {
    border-left: 1px solid color-mix(in srgb, var(--brand-muted) 70%, transparent);
  }
  .loyalty-strip-item:nth-child(4) {
    border-left: 1px solid color-mix(in srgb, var(--brand-muted) 70%, transparent);
  }
  .tier-grid { grid-template-columns: 1fr; }
}
.reward-row { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--border); }
.reward-row:last-child { border-bottom: none; }
.reward-row.locked { opacity: .5; }
.activity-item { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
.activity-item:last-child { border-bottom: none; }

.row-actions { display: flex; align-items: center; justify-content: flex-end; gap: 6px; white-space: nowrap; width: 100%; }
table.data td:has(.row-actions) { text-align: right; }

/* Order detail panel */
.order-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}
.detail-block {
  padding: 14px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
}
.detail-block-title {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.detail-block-body .small { color: var(--text-secondary); margin-top: 2px; }
.detail-block.is-unassigned { opacity: .6; }
.detail-block.is-unassigned .btn { pointer-events: none; opacity: .5; }

/* CRM */
.crm-profile-head { display: flex; gap: 14px; align-items: center; }
.avatar.lg { width: 44px; height: 44px; font-size: 14px; }
.customer-cell { display: flex; align-items: center; gap: 10px; }

/* App settings · branding */
.logo-variant-preview {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 88px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.logo-variant-preview.is-light { background: var(--surface-raised); }
.logo-variant-preview.is-dark { background: var(--text); }
.logo-variant-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}
.field .logo-variant-actions label.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.2;
  color: var(--text);
}
.brand-logo-row .field > .hint {
  margin-top: 10px;
}
.logo-variant-preview img {
  max-width: 80%;
  max-height: 64px;
  object-fit: contain;
}
.brand-preview-logo {
  height: 28px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
}
.color-field {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  padding: 4px 10px 4px 4px;
}
.color-field input[type="color"] {
  width: 28px;
  height: 28px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
}
.color-field input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.color-field input[type="color"]::-webkit-color-swatch {
  border: 1px solid rgba(0,0,0,.1);
  border-radius: 5px;
}
.color-field input[type="text"] {
  flex: 1;
  border: none;
  background: transparent;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  padding: 4px 0;
  outline: none;
  width: auto;
}
.brand-preview {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-raised);
}
.brand-preview-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.brand-preview-bar strong { flex: 1; font-size: 14px; }
.brand-preview-cart {
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  background: var(--text);
  color: #ffffff;
  font-size: 12px;
  font-weight: 500;
}
.brand-preview-body { padding: 16px 14px; }
.crm-detail-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  grid-template-areas:
    "profile insights"
    "orders loyalty"
    "extras notes";
  gap: 16px;
  align-items: stretch;
}
.crm-detail-layout > .card { margin-top: 0; }
.crm-profile-card { grid-area: profile; }
.crm-insights-card { grid-area: insights; display: flex; flex-direction: column; min-height: 100%; }
.crm-insights-card .def-list {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.crm-insights-card .def-row {
  grid-template-columns: 118px 1fr;
  align-items: center;
  padding: 10px 0;
  border-bottom: none;
  flex: 1;
  display: grid;
  gap: 10px;
  min-height: 0;
}
.crm-insights-card .def-row + .def-row {
  border-top: 1px solid var(--border);
}
.crm-insights-card .def-row dd {
  text-align: left;
  line-height: 1.35;
}
.crm-orders-card { grid-area: orders; align-self: stretch; }
.crm-loyalty-card { grid-area: loyalty; display: flex; flex-direction: column; align-self: stretch; min-height: 100%; }
.crm-loyalty-activity {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.crm-extras {
  grid-area: extras;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  align-items: stretch;
}
.crm-extras > .card {
  margin-top: 0;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.crm-devices-card { padding: 16px; }
.crm-devices-card .crm-activity-log { margin-top: auto; }
.crm-devices-card .card-head { margin-bottom: 10px; }
.crm-devices-card .activity-item { padding: 7px 0; font-size: 12.5px; }
.crm-wallet-balance { margin-bottom: 16px; }
.crm-wallet-amount { font-size: 28px; font-weight: 600; letter-spacing: -.02em; margin-top: 2px; }
.crm-topup { margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--border); }
.crm-topup-presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.crm-topup-presets .active-preset {
  border-color: var(--brand);
  background: var(--brand-subtle);
  color: var(--brand-hover);
}
.crm-topup-row { display: flex; gap: 8px; }
.crm-topup-row input {
  flex: 1; min-width: 0; padding: 8px 10px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); font-size: 13px; font-family: var(--font); background: var(--surface);
}
.crm-wallet-history { margin-top: auto; }
.crm-device-list { margin-bottom: 10px; padding-bottom: 2px; border-bottom: 1px solid var(--border); }
.crm-device-row {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 7px 0; border-bottom: 1px solid var(--border); font-size: 12.5px; line-height: 1.35;
}
.crm-device-row:last-child { border-bottom: none; }
.crm-device-row strong { font-size: 12.5px; font-weight: 600; }
.crm-device-row .small { font-size: 11.5px; }
.crm-device-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; text-align: right; flex-shrink: 0; }
.crm-log-label { margin-bottom: 4px; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; }
.crm-notes-card { grid-area: notes; }
.def-list { margin: 0; }
.def-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13.5px;
  align-items: start;
}
.def-row:last-child { border-bottom: none; padding-bottom: 0; }
.def-row:first-child { padding-top: 0; }
.def-row dt { color: var(--text-muted); font-weight: 500; }
.def-row dd { margin: 0; color: var(--text); }
.crm-loyalty-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.crm-loyalty-pts { font-size: 20px; font-weight: 600; letter-spacing: -.02em; margin-top: 2px; }
.pts { font-weight: 600; font-variant-numeric: tabular-nums; font-size: 13px; }
.pts.up { color: var(--success); }
.pts.down { color: var(--danger); }
.note-list .note-item { padding: 12px 0; border-bottom: 1px solid var(--border); background: transparent; border-radius: 0; border-left: none; border-right: none; border-top: none; }
.note-list .note-item:first-child { padding-top: 0; }
.note-list .note-item:last-child { border-bottom: none; padding-bottom: 0; }
.note-list .note-item + .note-item { margin-top: 0; }
.note-list .note-item p { margin-top: 6px; font-size: 13px; line-height: 1.5; color: var(--text-secondary); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 11px; padding: 2px 8px; border-radius: var(--radius-full); background: var(--surface-sunken); border: 1px solid var(--border); color: var(--text-secondary); font-weight: 500; }
.note-item { padding: 12px; background: var(--surface-raised); border-radius: var(--radius); border: 1px solid var(--border); font-size: 13px; }
.note-item + .note-item { margin-top: 8px; }

/* Mobile cart bar */
.mobile-cart-bar {
  display: none; position: fixed; bottom: 0; left: 0; right: 0; background: var(--text); color: #fff;
  padding: 12px 20px calc(12px + env(safe-area-inset-bottom, 0px)); z-index: 60;
  justify-content: space-between; align-items: center; font-size: 14px; font-weight: 500;
}
.mobile-cart-bar:hover { background: #18181B; }

/* Hub index */
.hub-hero { text-align: center; padding: 48px 20px 36px; }
.role-perms {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}
.modal-wide { max-width: 560px; }
.role-perm-grid {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  max-height: 280px;
  overflow-y: auto;
}
.role-perm-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  background: var(--surface);
  line-height: 1.25;
  font-size: 13px;
}
.role-perm-row:last-child { border-bottom: none; }
.role-perm-row:hover { background: var(--surface-raised); }
.role-perm-row > div { flex: 1; min-width: 0; }
.role-perm-row strong { display: block; font-size: 13px; }
.role-perm-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--brand);
  flex-shrink: 0;
  margin: 0;
  order: -1;
}
.store-picker {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  overflow: hidden;
}
.store-picker-selected {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 10px 0;
}
.store-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px 4px 10px;
  border-radius: var(--radius-full);
  background: var(--brand-subtle);
  border: 1px solid var(--brand-muted);
  color: var(--brand-hover);
  font-size: 12px;
  font-weight: 500;
}
.store-chip-remove {
  border: none;
  background: transparent;
  color: var(--brand-hover);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  padding: 0 2px;
}
.store-picker-search {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 8px 10px;
}
.store-picker-search input {
  flex: 1;
  width: auto;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font: inherit;
  font-size: 13px;
  background: var(--surface-raised);
}
.store-picker-results {
  border-top: 1px solid var(--border);
  max-height: 180px;
  overflow-y: auto;
}
.store-result {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: none;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  font: inherit;
  text-align: left;
}
.store-result:last-child { border-bottom: none; }
.store-result:hover { background: var(--surface-raised); }
.store-picker-empty {
  padding: 12px;
  font-size: 12.5px;
  color: var(--text-muted);
}
.integration-soon {
  opacity: .55;
  pointer-events: none;
  filter: grayscale(.35);
}
.integration-soon .switch {
  pointer-events: none;
  opacity: .7;
}
.integration-group-title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 12px;
}
.hub-hero .logo-mark { display: inline-grid; place-items: center; width: 48px; height: 48px; background: var(--brand); border-radius: var(--radius-lg); color: #fff; font-size: 14px; font-weight: 700; margin-bottom: 16px; overflow: hidden; padding: 0; }
.hub-hero .logo-mark img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hub-hero .brand-logo {
  display: block;
  height: 40px;
  width: auto;
  max-width: 200px;
  margin: 0 auto 16px;
  object-fit: contain;
}
.hub-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 900px; margin: 0 auto; }
.hub-link { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--border); }
.hub-link:last-child { border-bottom: none; }
.hub-link strong { font-weight: 500; }
.hub-link:hover strong { color: var(--brand); }

/* Responsive */
@media (max-width: 900px) {
  .grid-2, .grid-3, .grid-4, .hub-grid, .checkout-layout, .locator-split, .menu-layout-customer, .menu-layout, .board, .order-detail-grid, .cart-page-layout, .account-layout, .menu-grid, .upsell-row, .time-cards, .track-split { grid-template-columns: 1fr; }
  .locator-split { min-height: auto; }
  .map-placeholder { min-height: 200px; }
  .store-locator-map { min-height: 200px; }
  .store-list { border-right: none; border-bottom: 1px solid var(--border); }
  .cat-rail-wrap { top: var(--shop-header-height); margin-bottom: 14px; }
  .menu-promos-section,
  .featured-section,
  #burgers,
  #sides,
  #drinks,
  #desserts { scroll-margin-top: calc(var(--shop-header-height) + 50px); }
  .shop-wrap { padding: 28px 16px; }
  .cart-panel { display: none; }
  .admin-sidebar { display: none; }
  .mobile-cart-bar { display: flex; }
  .store-hero { height: 96px; }
  .store-hero-copy h1 { font-size: 15px; }
  .store-hero-meta { font-size: 11px; gap: 4px 8px; }
  .store-avatar { width: 40px; height: 40px; font-size: 11px; }
  .store-toolbar { gap: 8px; padding: 10px 12px; }
  .store-head--toolbar { margin: -28px 0 16px; }
  .store-head--toolbar .store-toolbar { padding: 10px 12px; }
  .store-toolbar-title { flex: 1 1 100%; }
  .store-toolbar-meta { margin-left: 0; width: 100%; }
  .menu-banner-card { height: 152px; flex-basis: 88%; }
  .menu-promos-section { margin-bottom: 22px; }
  .cart-item { grid-template-columns: 64px 1fr; }
  .cart-item .line-total { grid-column: 2; text-align: left; }
  .track-panel { max-height: none; }
  .track-page.is-splash,
  .track-page.is-live:has(.is-panel-only) { padding: 20px 14px 32px; }
  .track-page.is-live .track-split.is-panel-only .track-panel { padding: 22px 18px 26px; }
  .track-map,
  .track-visual .track-map,
  .track-visual .track-stage-art,
  .track-visual { min-height: 280px; }
  .track-visual { border-right: none; border-bottom: 1px solid var(--border); }
  .track-split:has([data-stage="delivered"]) .track-panel {
    width: min(520px, calc(100% - 24px));
    margin: 12px;
    padding: 24px 16px 32px;
  }
  .account-nav {
    display: flex; position: static; overflow-x: auto; gap: 4px; padding: 8px;
    flex-wrap: nowrap; align-items: stretch;
  }
  .account-nav .account-profile-card,
  .account-nav .nav-label,
  .account-nav .logout { display: none; }
  .account-nav a { flex: 0 0 auto; white-space: nowrap; margin: 0; }
  .crm-detail-layout {
    grid-template-columns: 1fr;
    grid-template-areas:
      "profile"
      "insights"
      "orders"
      "loyalty"
      "extras"
      "notes";
  }
  .crm-extras { grid-template-columns: 1fr; }
  .crm-profile-card,
  .crm-insights-card,
  .crm-orders-card,
  .crm-loyalty-card,
  .crm-notes-card { grid-column: auto; grid-row: auto; }
  .def-row { grid-template-columns: 120px 1fr; }
}

@media (max-width: 720px) {
  .shop-header-inner { padding: 10px 14px; gap: 10px; }
  :root { --shop-header-height: 74px; }
  .shop-header-actions { margin-left: auto; }
  .shop-brand { flex-shrink: 0; min-width: 0; }
  .shop-brand-fallback span:not(.logo-mark) {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 42vw;
  }
  .points-chip { padding: 5px 10px; font-size: 11.5px; }
}

/* Banners */
.banner-thumb-stack {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.banner-thumb {
  width: 44px;
  height: 28px;
  border-radius: 4px;
  border: 2px solid var(--surface);
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  box-shadow: 0 0 0 1px var(--border);
}
.banner-slides {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px;
  background: var(--surface-raised);
  min-height: 56px;
}
.banner-slide-empty {
  font-size: 13px;
  color: var(--text-muted);
  padding: 12px 4px;
  text-align: center;
}
.banner-slide-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.banner-slide-preview {
  width: 72px;
  height: 40px;
  border-radius: 4px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}
.banner-slide-meta {
  flex: 1;
  min-width: 0;
}
.banner-slide-meta strong {
  display: block;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Catalogue / menu image linking */
.img-link-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 16px;
  align-items: start;
}
@media (max-width: 960px) {
  .img-link-layout { grid-template-columns: 1fr; }
}
.img-lib-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  max-height: 520px;
  overflow-y: auto;
}
.img-lib-grid-modal {
  grid-template-columns: repeat(3, 1fr);
  max-height: 280px;
}
.img-lib-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  cursor: pointer;
  text-align: left;
  font-family: var(--font);
  color: inherit;
}
.img-lib-card:hover { background: var(--surface-raised); }
.img-lib-card.is-selected {
  border-color: var(--brand);
  box-shadow: 0 0 0 1px var(--brand);
}
.img-lib-swatch {
  display: block;
  width: 100%;
  height: 56px;
  border-radius: 4px;
}
.img-lib-name {
  font-size: 12px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.img-mini {
  width: 36px;
  height: 24px;
  border-radius: 4px;
  flex-shrink: 0;
  border: 1px solid var(--border);
}
table.data tr.is-row-selected td {
  background: var(--brand-subtle);
}
.bulk-upload-zone {
  border: 1.5px dashed var(--border-strong, var(--border));
  border-radius: var(--radius-lg);
  padding: 28px 20px;
  text-align: center;
  background: var(--surface);
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.bulk-upload-zone:hover,
.bulk-upload-zone.is-dragover {
  border-color: var(--brand);
  background: var(--brand-subtle);
}

/* Setup wizard · multi-step form stepper */
.setup-wizard {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 22px 20px;
  box-shadow: var(--shadow-sm);
}
.setup-wizard-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.setup-wizard-eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.setup-wizard-progress {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
}
.setup-wizard-track {
  display: flex;
  align-items: flex-start;
  list-style: none;
  margin: 0;
  padding: 0;
}
.setup-wizard-step {
  flex: 1;
  position: relative;
  min-width: 0;
}
.setup-wizard-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 15px;
  left: calc(50% + 16px);
  right: calc(-50% + 16px);
  height: 2px;
  background: var(--border);
  z-index: 0;
  transition: background .2s;
}
.setup-wizard-step.done:not(:last-child)::after {
  background: var(--brand);
}
.setup-wizard-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
  border: none;
  background: transparent;
  padding: 0 6px;
  cursor: default;
  font-family: var(--font);
  position: relative;
  z-index: 1;
}
.setup-wizard-step.done .setup-wizard-btn,
.setup-wizard-step.now .setup-wizard-btn {
  cursor: pointer;
}
.setup-wizard-step.done .setup-wizard-btn:hover .setup-wizard-marker {
  background: var(--brand-hover);
  border-color: var(--brand-hover);
}
.setup-wizard-step.now .setup-wizard-btn:hover .setup-wizard-marker {
  box-shadow: 0 0 0 4px var(--brand-muted);
}
.setup-wizard-step:not(.done):not(.now) .setup-wizard-btn {
  pointer-events: none;
}
.setup-wizard-btn:focus-visible {
  outline: none;
}
.setup-wizard-btn:focus-visible .setup-wizard-marker {
  box-shadow: 0 0 0 3px var(--brand-muted);
}
.setup-wizard-marker {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  border: 2px solid var(--border-strong);
  background: var(--surface-raised);
  color: var(--text-muted);
  transition: border-color .15s, background .15s, color .15s, box-shadow .15s;
}
.setup-wizard-step.done .setup-wizard-marker {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}
.setup-wizard-step.now .setup-wizard-marker {
  border-color: var(--brand);
  background: var(--brand-subtle);
  color: var(--brand-hover);
  box-shadow: 0 0 0 3px rgba(232, 93, 42, .18);
}
.setup-wizard-check {
  display: none;
  width: 14px;
  height: 14px;
}
.setup-wizard-step.done .setup-wizard-num { display: none; }
.setup-wizard-step.done .setup-wizard-check { display: block; }
.setup-wizard-label {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.35;
  max-width: 9em;
}
.setup-wizard-step.done .setup-wizard-label {
  color: var(--text-secondary);
}
.setup-wizard-step.now .setup-wizard-label {
  color: var(--text);
  font-weight: 600;
}

