/* ==========================================================================
   Soma design system
   ========================================================================== */
/* Body: Instrument Sans. Display: Bricolage Grotesque (weight and width axes),
   which also supplies the cedi sign that Instrument Sans lacks. */
@font-face {
  font-family: 'Instrument Sans';
  src: url('/fonts/instrument-sans.woff2') format('woff2');
  font-weight: 400 700;
  font-display: swap;
}
@font-face {
  font-family: 'Bricolage Grotesque';
  src: url('/fonts/bricolage.woff2') format('woff2');
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212;
}
@font-face {
  font-family: 'Bricolage Grotesque';
  src: url('/fonts/bricolage-ext.woff2') format('woff2');
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-display: swap;
  unicode-range: U+0100-02BA, U+1E00-1E9F, U+20A0-20AB, U+20AD-20C0;
}

/*
 * Palette: painted signboards on Soma green.
 *   soma green  #0D5C45  actions, wordmark, the board
 *   amber       #E9962B  highlights, prices
 *   ink         #231D18  text, dark surfaces
 *   lagoon blue #1D56A0  information
 */
:root {
  --brand: #0D5C45;
  --brand-600: #0A4C39;
  --brand-50: #E8F3EF;
  --brand-100: #CFE7DE;
  --accent: #E9962B;
  --accent-50: #FDF3E5;
  --ink: #231D18;
  --ink-2: #4A413A;
  --muted: #776C63;
  --line: #E6E2DE;
  --line-2: #F1EFEC;
  --bg: #FFFFFF;
  --panel: #F6F5F3;
  --card: #ffffff;
  --danger: #B3261E;
  --danger-50: #FBEAE8;
  --warn: #9A6200;
  --warn-50: #FDF4D6;
  --ok: #23704A;
  --ok-50: #E6F2EB;
  --info: #1D56A0;
  --info-50: #E8EFF9;
  --radius: 10px;
  --radius-sm: 8px;
  --shadow: none;
  --shadow-lg: 0 12px 40px rgba(35, 29, 24, .22);
  --font: 'Instrument Sans', 'Bricolage Grotesque', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --display: 'Bricolage Grotesque', 'Instrument Sans', system-ui, sans-serif;
  --topbar: 60px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
/* Nothing may make the page wider than the phone (that zooms the whole app out). */
html, body { max-width: 100%; }
/* "hidden" on <html> only: older phones do not know "clip", and "hidden" on <body> too would break sticky bars. */
html { overflow-x: hidden; }
@supports (overflow: clip) { html, body { overflow-x: clip; } }
body {
  overflow-wrap: anywhere; /* a long unbroken name or address wraps instead of widening the page */
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
/* Default icon size; component rules override it. Leaflet's own SVGs carry width attributes and are left alone. */
svg:not([width]) { width: 18px; height: 18px; flex: none; }
.brand-mark svg { color: #FFFFFF; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; }
h1, h2 { font-family: var(--display); font-weight: 800; font-stretch: 85%; letter-spacing: -0.01em; }
h1 { font-size: 30px; }
h2 { font-size: 22px; }
h3 { font-size: 16px; font-weight: 650; }
p { margin: 0; }
.hidden { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Layout ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  height: var(--topbar);
  display: flex; align-items: center; gap: 16px;
  padding: 0 20px;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 8px; color: var(--ink); }
.wordmark { font-family: var(--display); font-weight: 800; font-stretch: 80%; font-size: 26px; line-height: 1; letter-spacing: -0.02em; color: var(--brand); padding-bottom: 3px; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 30px; height: 30px; border-radius: 7px; background: var(--brand); display: grid; place-items: center; }
.brand-mark svg { width: 20px; height: 20px; }
.brand-tag { font-size: 11px; font-weight: 600; color: var(--muted); padding: 2px 8px; border: 1px solid var(--line); border-radius: 6px; }
.topbar .spacer { flex: 1; }
.topnav { display: flex; gap: 4px; }
.topnav a { padding: 8px 12px; border-radius: 9px; color: var(--ink-2); font-weight: 550; font-size: 14px; display: flex; gap: 8px; align-items: center; }
.topnav a:hover { background: var(--line-2); text-decoration: none; }
.topnav a.active { background: none; color: var(--ink); box-shadow: inset 0 -3px 0 var(--accent); border-radius: 0; }

.page { max-width: 1120px; margin: 0 auto; padding: 24px 20px 96px; }
.page.narrow { max-width: 720px; }
.page.wide { max-width: 1320px; }

.shell { display: grid; grid-template-columns: 240px 1fr; min-height: calc(100vh - var(--topbar)); min-height: calc(100dvh - var(--topbar)); }
.sidebar { background: var(--bg); border-right: 1px solid var(--line); padding: 16px 12px; position: sticky; top: var(--topbar); height: calc(100vh - var(--topbar)); height: calc(100dvh - var(--topbar)); overflow-y: auto; }
.sidebar a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 9px; color: var(--ink-2); font-weight: 550; font-size: 14px; margin-bottom: 2px; }
.sidebar a:hover { background: var(--line-2); text-decoration: none; }
.sidebar a.active { background: var(--panel); color: var(--ink); box-shadow: inset 3px 0 0 var(--brand); border-radius: 0 8px 8px 0; }
.sidebar a .count { margin-left: auto; background: var(--brand); color: #fff; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 1px 7px; }
.sidebar .section-label { font-size: 12.5px; font-weight: 650; color: var(--muted); padding: 16px 12px 6px; }
.shell main { padding: 24px 28px 80px; min-width: 0; }

.bottomnav { display: none; }

@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .shell main { padding: 16px 16px 96px; }
  .topnav { display: none; }
  .bottomnav {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    background: #fff; border-top: 1px solid var(--line);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
    overflow-x: auto;
  }
  .bottomnav a { flex: 1 0 auto; min-width: 64px; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 11px; font-weight: 600; color: var(--muted); padding: 6px 4px; border-radius: 10px; }
  .bottomnav a:hover { text-decoration: none; }
  .bottomnav a.active { color: var(--ink); }
  .bottomnav a.active svg { color: var(--brand); }
  .bottomnav svg { width: 22px; height: 22px; }
  .page { padding: 16px 16px 96px; }
  .topbar { padding: 0 14px; }
  .brand-tag { display: none; }
}

/* ---------- Primitives ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card.pad { padding: 20px; }
.card.flat { box-shadow: none; }
.row { display: flex; align-items: center; gap: 12px; }
.row.wrap { flex-wrap: wrap; }
.row.top { align-items: flex-start; }
.row.between { justify-content: space-between; }
.col { display: flex; flex-direction: column; gap: 12px; }
.stack-4 > * + * { margin-top: 4px; }
.stack-8 > * + * { margin-top: 8px; }
.stack-12 > * + * { margin-top: 12px; }
.stack-16 > * + * { margin-top: 16px; }
.stack-24 > * + * { margin-top: 24px; }
.grow { flex: 1; min-width: 0; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.strong { font-weight: 650; }
.right { text-align: right; }
.mono { font-variant-numeric: tabular-nums; }
.grid { display: grid; gap: 16px; }
.grid.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.auto { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
@media (max-width: 860px) {
  .grid.c3, .grid.c4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid.c2.stack-m { grid-template-columns: 1fr; }
}
@media (max-width: 520px) { .grid.c2:not(.keep), .grid.c3:not(.keep) { grid-template-columns: 1fr; } }
.divider { height: 1px; background: var(--line); margin: 16px 0; border: 0; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 18px; border-radius: 8px;
  border: 1px solid transparent; background: var(--brand); color: #fff;
  font-weight: 650; font-size: 15px; cursor: pointer; white-space: nowrap;
  transition: background .15s, box-shadow .15s, transform .05s;
}
.btn:hover { background: var(--brand-600); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible, .chip:focus-visible {
  outline: 3px solid rgba(29, 86, 160, .45); outline-offset: 2px;
}
.btn.secondary { background: #fff; color: var(--ink); border-color: var(--line); }
.btn.secondary:hover { background: var(--line-2); }
.btn.ghost { background: transparent; color: var(--ink-2); }
.btn.ghost:hover { background: var(--line-2); }
.btn.danger { background: var(--danger); }
.btn.danger:hover { background: #a82e24; }
.btn.danger-outline { background: #fff; color: var(--danger); border-color: #f0c9c4; }
.btn.accent { background: var(--accent); color: var(--ink); }
.btn.accent:hover { background: #D8871F; }
.btn.sm { height: 34px; padding: 0 12px; font-size: 13.5px; border-radius: 7px; }
.btn.lg { height: 52px; padding: 0 24px; font-size: 16px; border-radius: 9px; }
.btn.block { width: 100%; }
.btn.icon { width: 40px; padding: 0; }
.btn.icon.sm { width: 34px; }
.btn svg { width: 18px; height: 18px; flex: none; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field > label, .label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field .hint { font-size: 12.5px; color: var(--muted); }
.input, select.input, textarea.input {
  width: 100%; height: 44px; padding: 0 14px;
  border: 1px solid #D6D0CA; border-radius: 8px; background: #fff;
  transition: border-color .15s, box-shadow .15s;
}
textarea.input { height: auto; min-height: 84px; padding: 11px 14px; resize: vertical; }
.input:focus { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); outline: none; }
.input.invalid { border-color: var(--danger); }
.input-group { position: relative; }
.input-group svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); pointer-events: none; }
.input-group .input { padding-left: 40px; }
.form-error { background: var(--danger-50); color: var(--danger); border-radius: 10px; padding: 10px 14px; font-size: 14px; font-weight: 500; }

.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: #fff; }
.check:hover { border-color: var(--brand-100); }
.check input { margin: 3px 0 0; accent-color: var(--brand); width: 17px; height: 17px; flex: none; }
.check.on { border-color: var(--brand); background: var(--brand-50); }

.switch { position: relative; width: 50px; height: 28px; flex: none; }
.switch input { position: absolute; top: 0; left: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; z-index: 1; }
.switch input:focus-visible + span { outline: 3px solid rgba(29, 86, 160, .6); outline-offset: 3px; }
.switch span { position: absolute; top: 0; right: 0; bottom: 0; left: 0; background: #D6D0CA; border-radius: 99px; transition: .2s; cursor: pointer; }
.switch span::before { content: ''; position: absolute; width: 22px; height: 22px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.switch input:checked + span { background: var(--ok); }
.switch input:checked + span::before { transform: translateX(22px); }
.switch input:disabled + span { opacity: .5; cursor: not-allowed; }

.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 650; padding: 3px 8px; border-radius: 6px; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.badge svg { width: 13px; height: 13px; }
.badge.ok { background: var(--ok-50); color: var(--ok); }
.badge.warn { background: var(--warn-50); color: var(--warn); }
.badge.danger { background: var(--danger-50); color: var(--danger); }
.badge.info { background: var(--info-50); color: var(--info); }
.badge.brand { background: var(--brand-50); color: var(--brand); }
.badge.accent { background: var(--accent); color: var(--ink); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }

.chips { display: flex; gap: 8px; max-width: 100%; min-width: 0; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips.wrap { flex-wrap: wrap; overflow-x: visible; }
@media (max-width: 400px) { .grid.keep .zone-card { padding: 12px 10px; gap: 10px; } .grid.keep .zone-card .ic { width: 34px; height: 34px; } }
.chip { flex: none; height: 36px; padding: 0 13px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-weight: 550; font-size: 13.5px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.chip:hover { border-color: #C9C1B9; }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip svg { width: 16px; height: 16px; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.tabs button { background: none; border: 0; padding: 10px 14px; font-weight: 600; font-size: 14px; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; display: flex; gap: 8px; align-items: center; }
.tabs button.on { color: var(--ink); border-bottom-color: var(--brand); }
.tabs .n { background: var(--brand); color: #fff; font-size: 11px; border-radius: 99px; padding: 0 7px; line-height: 18px; }

.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; font-size: 13px; font-weight: 650; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--panel); }
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tr.clickable { cursor: pointer; }
.table tr.clickable:hover td { background: var(--panel); }

.empty { text-align: center; padding: 48px 20px; color: var(--muted); }
.empty svg { width: 40px; height: 40px; color: #C9C1B9; margin: 0 auto 12px; }
.empty h3 { color: var(--ink); margin-bottom: 4px; }

.skeleton { background: linear-gradient(90deg, #EFEDEA 25%, #F7F6F4 50%, #EFEDEA 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 10px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.spinner { width: 20px; height: 20px; border: 2.5px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
.spinner.dark { border-color: var(--line); border-top-color: var(--brand); }
@keyframes spin { to { transform: rotate(360deg); } }
.loading-block { display: grid; place-items: center; padding: 60px; }

/* ---------- Toast / modal / sheet ---------- */
.toasts { position: fixed; z-index: 1000; left: 50%; bottom: 24px; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
@media (max-width: 860px) { .toasts { bottom: 90px; } }
.toast { background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 10px; box-shadow: var(--shadow-lg); font-size: 14px; font-weight: 500; max-width: 90vw; animation: toastIn .2s ease-out; display: flex; gap: 10px; align-items: center; }
.toast.error { background: var(--danger); }
.toast svg { width: 18px; height: 18px; }
@keyframes toastIn { from { opacity: 0; transform: translateY(8px); } }

.overlay { position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 500; background: rgba(35, 29, 24, .5); display: flex; align-items: center; justify-content: center; padding: 20px; animation: fadeIn .15s; }
@keyframes fadeIn { from { opacity: 0; } }
.modal { background: #fff; border-radius: 10px; width: 100%; max-width: 520px; max-height: calc(100vh - 40px); max-height: calc(100dvh - 40px); display: flex; flex-direction: column; box-shadow: var(--shadow-lg); animation: modalIn .2s ease-out; }
.modal.wide { max-width: 760px; }
@keyframes modalIn { from { opacity: 0; transform: translateY(12px) scale(.98); } }
.modal-head { display: flex; align-items: center; gap: 12px; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.modal-head h2 { font-size: 18px; flex: 1; }
.modal-body { padding: 20px; overflow-y: auto; }
.modal-foot { padding: 14px 20px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; }
@media (max-width: 600px) {
  .overlay { align-items: flex-end; padding: 0; }
  .modal { border-radius: 10px 14px 0 0; max-height: 92vh; max-height: 92dvh; animation: sheetIn .22s ease-out; }
  @keyframes sheetIn { from { transform: translateY(40px); opacity: 0; } }
  .modal-foot .btn { flex: 1; }
}

/* ---------- Auth / landing: the painted menu board ---------- */
.auth-wrap { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-hero { background: var(--brand); color: #FFFFFF; padding: 40px 48px; display: flex; flex-direction: column; position: relative; }
.auth-hero .brand-mark { background: #FFFFFF; }
.auth-hero .brand-mark svg { color: var(--brand); }
.board-name { font-family: var(--display); font-weight: 800; font-stretch: 75%; color: #F7C47A; font-size: clamp(96px, 13vw, 184px); line-height: .82; letter-spacing: -0.03em; margin-top: auto; }
.board-line { font-family: var(--display); font-weight: 650; font-stretch: 90%; font-size: 24px; line-height: 1.25; max-width: 460px; margin-top: 18px; }
.menu-board { margin-top: 32px; max-width: 440px; border-top: 3px solid rgba(255,255,255,.85); padding-top: 12px; }
.menu-board .dish { display: grid; grid-template-columns: 130px 1fr; gap: 16px; align-items: baseline; font-size: 16px; line-height: 1.4; padding: 12px 0; border-bottom: 1px solid rgba(255, 255, 255, .2); }
.menu-board .dish:last-child { border-bottom: 0; }
.menu-board .dish .p { font-family: var(--display); font-weight: 800; font-stretch: 80%; font-size: 21px; line-height: 1.1; color: #F7C47A; }
.auth-hero .foot { margin-top: 28px; font-size: 14px; font-weight: 550; opacity: .85; }
.auth-panel { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 24px 24px; }
.auth-panel .credit { margin-top: auto; padding-top: 40px; }
.auth-panel > .auth-card { margin-top: auto; }
.credit { font-size: 13px; color: var(--muted); text-align: center; margin-top: 28px; }
.auth-card { width: 100%; max-width: 420px; }
.auth-card h2 { font-size: 30px; margin-bottom: 6px; }
.role-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.role-pick button { border: 1px solid var(--line); background: #fff; border-radius: 8px; padding: 12px 8px; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 600; font-size: 13.5px; color: var(--ink-2); }
.role-pick button svg { width: 22px; height: 22px; }
.role-pick button.on { border-color: var(--ink); background: var(--accent-50); color: var(--ink); box-shadow: 0 0 0 1px var(--ink) inset; }
@media (max-width: 900px) {
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-hero { padding: 22px 20px 26px; }
  .board-name { font-size: 104px; margin-top: 4px; }
  .board-line { font-size: 20px; margin-top: 10px; }
  .menu-board { display: none; }
  .auth-hero .foot { display: none; }
}

/* ---------- Customer ---------- */
.locbar { display: flex; align-items: center; gap: 10px; cursor: pointer; padding: 6px 10px; border-radius: 10px; max-width: 360px; }
.locbar:hover { background: var(--line-2); }
.locbar .t { font-size: 12px; color: var(--muted); font-weight: 550; }
.locbar .v { font-weight: 650; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 240px; }
.locbar svg { width: 18px; height: 18px; color: var(--brand); flex: none; }
.locbar > div { min-width: 0; }
@media (max-width: 860px) {
  .topbar { gap: 8px; }
  .topbar > * { min-width: 0; }
  .topbar .locbar { padding: 6px 4px; gap: 6px; flex: 1 1 auto; max-width: none; min-width: 0; overflow: hidden; justify-content: flex-start; }
  .locbar .v { max-width: 100%; font-size: 13.5px; }
  .locbar > svg:last-child { display: none; }
  .wordmark { font-size: 22px; }
  .topbar .spacer { display: none; }
  .topbar .bell, .topbar > .btn.ghost:not(.locbar), .topbar .brand { flex: none; }
}
@media (max-width: 380px) { .topbar .wordmark { display: none; } }

.home-head h1 { font-size: 34px; }
.home-head p { color: var(--muted); margin-top: 2px; }
.home-search { margin-top: 16px; max-width: 640px; }
.home-search .input { height: 54px; font-size: 16px; border: 2px solid var(--ink); border-radius: 10px; padding-left: 44px; }
.home-search .input:focus { box-shadow: 0 0 0 3px var(--accent); }
.home-search svg { left: 15px; width: 20px; height: 20px; color: var(--ink); }
.soon-line { font-size: 14px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 16px; }
@media (max-width: 860px) { .home-head h1 { font-size: 27px; } }

.vendor-card { overflow: hidden; cursor: pointer; display: flex; flex-direction: column; border-radius: 10px; }
.vendor-card:hover { border-color: #C9C1B9; }
.vendor-card:hover h3 { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.vendor-cover { height: 148px; position: relative; background: var(--panel); }
.vendor-cover img { width: 100%; height: 100%; object-fit: cover; }
/* No photo yet: the store's name painted on a signboard. */
.signboard { position: absolute; top: 0; right: 0; bottom: 0; left: 0; display: flex; align-items: flex-end; padding: 16px 16px 14px; overflow: hidden; }
.signboard span { font-family: var(--display); font-weight: 800; font-stretch: 75%; font-size: 40px; line-height: .9; letter-spacing: -0.01em; }
.store-hero .signboard { padding: 22px 24px 20px; }
.store-hero .signboard span { font-size: 72px; }
@media (max-width: 860px) { .store-hero .signboard span { font-size: 52px; } }
.signboard.s0 { background: #0D5C45; color: #F7C47A; }
.signboard.s1 { background: #7A3E2A; color: #F7C47A; }
.signboard.s2 { background: #274C77; color: #FFFFFF; }
.signboard.s3 { background: #231D18; color: #F7C47A; }
.signboard.s4 { background: #4A5D23; color: #FFFFFF; }
.vendor-cover .tags { position: absolute; top: 10px; left: 10px; display: flex; gap: 6px; }
.vendor-cover .tags .badge { background: #fff; color: var(--ink); }
.vendor-cover .tags .badge.ok svg { color: var(--ok); }
.vendor-cover .tags .badge.accent { background: var(--ink); color: var(--accent); }
.vendor-cover .closed { position: absolute; top: 0; right: 0; bottom: 0; left: 0; background: rgba(35,29,24,.62); color: #fff; display: grid; place-items: center; font-weight: 700; }
.vendor-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 5px; }
.vendor-body .meta { display: flex; gap: 12px; flex-wrap: wrap; font-size: 13.5px; color: var(--muted); align-items: center; }
.vendor-body .meta .sep { display: none; }
.stars { display: inline-flex; align-items: center; gap: 3px; color: var(--ink); font-weight: 650; }
.stars svg { width: 14px; height: 14px; color: #E0A800; fill: #E0A800; }

.store-hero { border-radius: 10px; overflow: hidden; position: relative; }
.store-hero .cover { height: 200px; background: var(--panel); position: relative; }
.store-hero .cover img { width: 100%; height: 100%; object-fit: cover; }
.store-hero .info { background: #fff; padding: 20px 24px; display: flex; gap: 18px; align-items: flex-start; border: 1px solid var(--line); border-top: 0; border-radius: 0 0 12px 12px; }
.store-logo { width: 76px; height: 76px; border-radius: 10px; background: #fff; border: 3px solid #fff; box-shadow: var(--shadow); margin-top: -52px; overflow: hidden; flex: none; display: grid; place-items: center; }
.store-logo img { width: 100%; height: 100%; object-fit: cover; }
.store-logo span { font-family: var(--display); font-weight: 800; font-stretch: 80%; font-size: 30px; }

.menu-layout { display: grid; grid-template-columns: 1fr 340px; gap: 24px; align-items: start; }
@media (max-width: 960px) { .menu-layout { grid-template-columns: 1fr; } .cart-side { display: none; } }
.menu-section h2 { font-size: 18px; margin: 8px 0 12px; }
.menu-item { display: flex; gap: 14px; padding: 16px; cursor: pointer; transition: border-color .15s; }
.menu-item:hover { border-color: var(--brand-100); }
.menu-item .thumb { width: 96px; height: 96px; border-radius: 10px; overflow: hidden; flex: none; background: var(--line-2); display: grid; place-items: center; color: #aab4af; }
.menu-item .thumb img { width: 100%; height: 100%; object-fit: cover; }
.menu-item .thumb svg { width: 28px; height: 28px; }
.menu-item .d { font-size: 13.5px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.menu-item .price { font-weight: 700; margin-top: auto; }
.menu-item .add { width: 34px; height: 34px; border-radius: 10px; background: var(--brand-50); color: var(--brand); display: grid; place-items: center; flex: none; align-self: flex-end; }
.menu-item .add svg { width: 18px; height: 18px; }
.menu-item.unavailable { opacity: .5; cursor: default; }

.cart-side { position: sticky; top: calc(var(--topbar) + 16px); }
.cart-line { display: flex; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line-2); }
.cart-line:last-child { border-bottom: 0; }
.qty { flex: none; display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.qty button { width: 32px; height: 32px; border: 0; background: #fff; cursor: pointer; display: grid; place-items: center; }
.qty button:hover { background: var(--line-2); }
.qty button svg { width: 16px; height: 16px; }
.qty span { min-width: 28px; text-align: center; font-weight: 650; font-size: 14px; }
.cart-fab { position: fixed; left: 16px; right: 16px; bottom: 84px; z-index: 55; display: none; }
@media (max-width: 960px) { .cart-fab { display: block; } }
.cart-fab .btn { width: 100%; height: 54px; border-radius: 10px; box-shadow: var(--shadow-lg); justify-content: space-between; padding: 0 18px; }

.opt-group { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.opt-group .head { padding: 12px 14px; background: var(--panel); display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); }
.opt-group label.opt { display: flex; align-items: center; gap: 12px; padding: 12px 14px; cursor: pointer; border-bottom: 1px solid var(--line-2); }
.opt-group label.opt:last-child { border-bottom: 0; }
.opt-group label.opt:hover { background: #fcfcfa; }
.opt-group input { accent-color: var(--brand); width: 18px; height: 18px; }

.summary-line { display: flex; justify-content: space-between; padding: 5px 0; font-size: 14.5px; }
.summary-line.total { font-weight: 750; font-size: 17px; padding-top: 12px; margin-top: 8px; border-top: 1px dashed var(--line); }

.zone-card { padding: 14px 16px; display: flex; gap: 14px; align-items: flex-start; cursor: pointer; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.zone-card.on { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink) inset; background: var(--accent-50); }
.zone-card .ic { width: 40px; height: 40px; border-radius: 8px; background: var(--line-2); display: grid; place-items: center; color: var(--ink-2); flex: none; }
.zone-card.on .ic { background: var(--ink); color: var(--accent); }
.zone-card .ic svg { width: 20px; height: 20px; }

/* ---------- Tracking ---------- */
.track-head { background: var(--brand); color: #fff; border-radius: 10px; padding: 22px 24px; position: relative; overflow: hidden; }
.track-head .status { font-family: var(--display); font-size: 34px; font-weight: 800; font-stretch: 80%; line-height: 1.05; color: #F7C47A; }
.progress { display: flex; gap: 4px; margin-top: 16px; }
.progress span { flex: 1; height: 6px; border-radius: 2px; background: rgba(255,255,255,.18); }
.progress span.on { background: var(--accent); }
.pin-box { background: #fff; color: var(--ink); border-radius: 10px; padding: 14px 16px; display: flex; align-items: center; gap: 14px; margin-top: 16px; }
.pin-box .digits { font-family: var(--display); font-size: 34px; font-weight: 800; font-stretch: 85%; letter-spacing: .3em; font-variant-numeric: tabular-nums; }
.timeline { position: relative; padding-left: 26px; }
.timeline::before { content: ''; position: absolute; left: 8px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.timeline .ev { position: relative; padding: 6px 0 14px; }
.timeline .ev::before { content: ''; position: absolute; left: -23px; top: 10px; width: 12px; height: 12px; border-radius: 50%; background: var(--brand); border: 3px solid var(--brand-50); }
.timeline .ev.pending::before { background: #fff; border: 2px solid var(--line); }
.timeline .ev.pending { color: var(--muted); }
.timeline .ev.bad::before { background: var(--danger); border-color: var(--danger-50); }

.map { height: 280px; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: #e9ece8; z-index: 1; }
.map.tall { height: 380px; }
.map-fallback { height: 100%; display: grid; place-items: center; color: var(--muted); font-size: 13px; text-align: center; padding: 20px; }
.map-pin { width: 30px; height: 30px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); display: grid; place-items: center; box-shadow: 0 2px 6px rgba(0,0,0,.3); border: 2px solid #fff; }
.map-pin svg { transform: rotate(45deg); width: 15px; height: 15px; color: #fff; }
.map-pin.brand { background: var(--brand); }
.map-pin.accent { background: var(--accent); }
.map-pin.ink { background: var(--ink); }
.leaflet-container { font-family: var(--font); }

.chat { display: flex; flex-direction: column; height: 360px; }
.chat .msgs { flex: 1; overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 8px; background: var(--panel); border-radius: 10px; }
.chat .msg { max-width: 78%; padding: 8px 12px; border-radius: 10px; font-size: 14px; background: #fff; border: 1px solid var(--line); align-self: flex-start; white-space: pre-wrap; word-break: break-word; }
.chat .msg.mine { align-self: flex-end; background: var(--ink); color: #fff; border-color: var(--ink); }
.chat .msg .who { font-size: 11px; font-weight: 650; opacity: .7; margin-bottom: 2px; }
.chat form { display: flex; gap: 8px; margin-top: 10px; }

.star-input { display: flex; gap: 6px; }
.star-input button { background: none; border: 0; cursor: pointer; padding: 2px; color: #d3d9d5; }
.star-input button svg { width: 30px; height: 30px; }
.star-input button.on { color: var(--accent); }
.star-input button.on svg { fill: var(--accent); }

/* ---------- Dashboards ---------- */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head p { color: var(--muted); margin-top: 4px; }
.stat { padding: 18px; }
.stat .k { font-size: 13px; color: var(--muted); font-weight: 550; display: flex; align-items: center; gap: 8px; }
.stat .k svg { width: 16px; height: 16px; }
.stat .v { font-family: var(--display); font-size: 30px; overflow-wrap: anywhere; font-weight: 800; font-stretch: 85%; margin-top: 6px; font-variant-numeric: tabular-nums; }
.stat .s { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.stat.hl { background: var(--brand); color: #fff; border-color: var(--brand); }
.stat.hl .v { color: #F7C47A; }
.stat.hl .k, .stat.hl .s { color: rgba(255,255,255,.72); }

.bars { display: flex; align-items: flex-end; gap: 6px; height: 160px; padding-top: 10px; }
.bars .b { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; min-width: 0; }
.bars .b .fill { width: 100%; max-width: 34px; background: var(--brand); border-radius: 6px 6px 3px 3px; min-height: 2px; transition: height .3s; }
.bars .b .fill.zero { background: var(--line); }
.bars .b .l { font-size: 10.5px; color: var(--muted); white-space: nowrap; }
.bars .b:hover .fill { background: var(--accent); }

.order-tile { padding: 16px; display: flex; flex-direction: column; gap: 10px; cursor: pointer; transition: border-color .15s; }
.order-tile:hover { border-color: var(--brand-100); }
.order-tile.new { border-left: 4px solid var(--accent); }
.order-tile .ref { font-weight: 750; font-variant-numeric: tabular-nums; letter-spacing: .02em; }

.alert { display: flex; gap: 12px; padding: 14px 16px; border-radius: 10px; font-size: 14px; align-items: flex-start; }
.alert svg { width: 20px; height: 20px; flex: none; margin-top: 1px; }
.alert.warn { background: var(--warn-50); color: #7a4f10; }
.alert.info { background: var(--info-50); color: #1f4580; }
.alert.danger { background: var(--danger-50); color: #8f2419; }
.alert.ok { background: var(--ok-50); color: #175c3a; }

.editor-group { border: 1px solid var(--line); border-radius: 10px; padding: 14px; background: var(--panel); }
.opt-row { display: grid; grid-template-columns: 1fr 110px 36px; gap: 8px; margin-top: 8px; }

/* Rider */
.online-card { padding: 22px; display: flex; align-items: center; gap: 16px; }
.online-card.on { background: var(--ok); color: #fff; border-color: var(--ok); }
.online-card .big { font-size: 20px; font-weight: 750; }
.offer { padding: 18px; border: 2px solid var(--accent); }
.offer .earn { font-size: 30px; font-weight: 800; color: var(--brand); letter-spacing: -0.02em; }
.route { display: grid; grid-template-columns: 22px 1fr; gap: 4px 10px; }
.route .pt { width: 12px; height: 12px; border-radius: 50%; margin: 5px auto 0; }
.route .pt.a { background: var(--brand); }
.route .pt.b { background: var(--accent); }
.route .ln { width: 2px; background: var(--line); margin: 0 auto; min-height: 16px; }
.countdown { height: 4px; background: var(--line); border-radius: 99px; overflow: hidden; }
.countdown span { display: block; height: 100%; background: var(--accent); transition: width 1s linear; }
.pin-input { display: flex; gap: 10px; justify-content: center; }
.pin-input input { width: 58px; height: 64px; text-align: center; font-size: 28px; font-weight: 750; border: 1.5px solid var(--line); border-radius: 13px; }
.pin-input input:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 3px rgba(13,92,69,.14); }

.notif-panel { position: fixed; right: 12px; top: calc(var(--topbar) - 4px); width: 380px; max-width: calc(100vw - 24px); max-height: 70vh; overflow-y: auto; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-lg); z-index: 200; }
.notif { padding: 12px 16px; border-bottom: 1px solid var(--line-2); cursor: pointer; display: flex; gap: 10px; }
.notif:hover { background: var(--panel); }
.notif.unread { background: var(--brand-50); }
.notif .t { font-weight: 650; font-size: 14px; }
.notif .b { font-size: 13px; color: var(--ink-2); }
.bell { position: relative; }
.bell .n { position: absolute; top: 4px; right: 4px; min-width: 17px; height: 17px; border-radius: 99px; background: var(--danger); color: #fff; font-size: 10.5px; font-weight: 700; display: grid; place-items: center; padding: 0 4px; border: 2px solid #fff; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--accent-50); color: var(--ink); display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; }
.menu-pop { position: fixed; right: 12px; top: calc(var(--topbar) - 4px); width: 240px; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-lg); z-index: 200; padding: 6px; }
.menu-pop button, .menu-pop a { width: 100%; display: flex; gap: 10px; align-items: center; padding: 10px 12px; border: 0; background: none; border-radius: 9px; cursor: pointer; font-weight: 550; font-size: 14px; color: var(--ink); text-align: left; }
.menu-pop button:hover, .menu-pop a:hover { background: var(--line-2); text-decoration: none; }
.menu-pop svg { width: 18px; height: 18px; color: var(--muted); }
.menu-pop .who { padding: 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }

.kv { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 8px 16px; font-size: 14px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 550; word-break: break-word; min-width: 0; }
.kv dd .badge { white-space: normal; text-align: left; }
@media (max-width: 520px) { .kv { grid-template-columns: 1fr; gap: 2px; } .kv dd { margin-bottom: 8px; } }

.photo-drop { border: 1.5px dashed var(--line); border-radius: 10px; padding: 14px; display: flex; gap: 12px; align-items: center; cursor: pointer; background: var(--panel); }
.photo-drop:hover { border-color: var(--brand); }
.photo-drop img { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; }
.photo-drop svg { width: 22px; height: 22px; color: var(--muted); }

input[type=checkbox], input[type=radio] { accent-color: var(--brand); }
.online-card.on .switch input:checked + span { background: rgba(255, 255, 255, .35); }

/* ---------- Ask Soma ---------- */
.assist-fab { position: fixed; right: 20px; bottom: 24px; z-index: 70; display: flex; align-items: center; gap: 8px; height: 48px; padding: 0 18px 0 14px; border-radius: 99px; border: 0; background: var(--ink); color: #fff; font-weight: 650; font-size: 14px; cursor: pointer; box-shadow: var(--shadow-lg); }
.assist-fab svg { width: 20px; height: 20px; }
.assist-fab:hover { background: var(--brand); }
.assist-panel { position: fixed; right: 20px; bottom: 84px; z-index: 300; width: 400px; max-width: calc(100vw - 24px); height: min(620px, calc(100vh - 120px)); height: min(620px, calc(100dvh - 120px)); background: var(--card); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; overflow: hidden; animation: modalIn .18s ease-out; }
.assist-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.assist-dot { width: 34px; height: 34px; border-radius: 50%; background: var(--accent); color: var(--ink); display: grid; place-items: center; flex: none; }
.assist-dot svg { width: 18px; height: 18px; }
.assist-msgs { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--panel); }
.assist-msgs .msg { max-width: 88%; padding: 9px 13px; border-radius: 10px; font-size: 14px; line-height: 1.45; background: #fff; border: 1px solid var(--line); align-self: flex-start; white-space: pre-wrap; word-break: break-word; }
.assist-msgs .msg.mine { align-self: flex-end; background: var(--ink); color: #fff; border-color: var(--ink); }
.assist-card { align-self: stretch; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.assist-foot { padding: 10px 12px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; }
@media (max-width: 860px) {
  .assist-fab { bottom: 84px; right: 14px; height: 44px; padding: 0 14px 0 12px; }
  .assist-fab span { display: none; }
  .assist-panel { right: 8px; left: 8px; bottom: 76px; width: auto; max-width: none; height: calc(100vh - 150px); height: calc(100dvh - 150px); }
  body.has-cartbar .assist-fab { bottom: 148px; }
}

/* Notifications prompt */
.push-ask { position: fixed; left: 20px; bottom: 24px; z-index: 80; width: 420px; flex-wrap: wrap; max-width: calc(100vw - 32px); display: flex; align-items: center; gap: 12px; padding: 12px 14px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-lg); animation: modalIn .18s ease-out; }
.push-ask-icon { width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: var(--ink); display: grid; place-items: center; flex: none; }
.push-ask-icon svg { width: 18px; height: 18px; }
.push-ask > .grow { flex: 1 1 200px; }
.push-ask > .row { width: 100%; justify-content: flex-end; }
@media (max-width: 860px) {
  /* At the top, so it never covers the cart bar, the Ask Soma button or the tab bar. */
  .push-ask { left: 8px; right: 8px; width: auto; max-width: none; bottom: auto; top: calc(var(--topbar) + 8px); }
}

/* Offline notice */
.offline-bar { position: fixed; top: 0; left: 0; right: 0; z-index: 900; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 8px 14px; background: var(--ink); color: var(--accent); font-size: 13.5px; font-weight: 600; }
.offline-bar svg { width: 16px; height: 16px; }

/* ---------- Public landing page ---------- */
.lp { background: var(--bg); color: var(--ink); }
.lp-wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.lp-nav { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); }
.lp-nav-in { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.lp-nav-links { display: flex; align-items: center; gap: 6px; }
.lp-hero { background: var(--brand); color: #fff; padding: 56px 0 64px; }
.lp-hero-in { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; }
.lp-hero h1 { font-size: clamp(40px, 6.4vw, 76px); line-height: .98; font-stretch: 75%; font-weight: 800; letter-spacing: -0.025em; color: #fff; max-width: 14ch; }
.lp-lead { font-size: 18px; line-height: 1.5; max-width: 46ch; margin-top: 20px; color: rgba(255,255,255,.9); }
.lp-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.lp-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.lp-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.lp-where { margin-top: 18px; color: #F7C47A; }
.lp-track { background: #fff; color: var(--ink); border-radius: 14px; padding: 20px; box-shadow: 0 18px 40px rgba(0,0,0,.22); border-top: 6px solid var(--accent); }
.lp-track-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; font-family: var(--display); font-size: 18px; }
.lp-tag { font-size: 12px; font-weight: 600; background: var(--accent-50); color: var(--warn); border-radius: 99px; padding: 3px 10px; }
.lp-track ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.lp-track li { display: grid; grid-template-columns: 26px 1fr; gap: 12px; padding-bottom: 16px; position: relative; }
.lp-track li:not(:last-child)::before { content: ''; position: absolute; left: 12px; top: 26px; bottom: 0; width: 2px; background: var(--line); }
.lp-track li.done:not(:last-child)::before { background: var(--brand); }
.lp-track .dot { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line); background: #fff; display: grid; place-items: center; }
.lp-track .done .dot { background: var(--brand); border-color: var(--brand); color: #fff; }
.lp-track .dot svg { width: 14px; height: 14px; }
.lp-track .now .dot { border-color: var(--accent); background: var(--accent); box-shadow: 0 0 0 5px var(--accent-50); }
.lp-track-foot { display: flex; align-items: center; gap: 8px; color: var(--muted); border-top: 1px solid var(--line-2); padding-top: 12px; }
.lp-track-foot svg { width: 16px; height: 16px; }
.lp-section { padding: 72px 0; }
.lp-section h2 { font-size: clamp(28px, 4vw, 42px); line-height: 1.05; max-width: 20ch; }
.lp-sub { color: var(--ink-2); font-size: 17px; margin-top: 12px; max-width: 52ch; }
.lp-steps { list-style: none; margin: 36px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.lp-steps li { display: grid; grid-template-columns: 52px 1fr; gap: 14px; }
.lp-n { font-family: var(--display); font-weight: 800; font-stretch: 75%; font-size: 64px; line-height: .8; color: var(--accent); }
.lp-steps h3 { font-size: 20px; margin-bottom: 6px; }
.lp-steps p { color: var(--ink-2); line-height: 1.5; max-width: 34ch; }
.lp-trust { background: var(--panel); border-block: 1px solid var(--line); padding: 28px 0; }
.lp-trust-in { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.lp-trust-item { display: flex; gap: 14px; align-items: flex-start; }
.lp-trust-item > svg { width: 26px; height: 26px; color: var(--brand); flex: none; margin-top: 2px; }
.lp-trust-item .small { color: var(--ink-2); margin-top: 2px; line-height: 1.45; }
.lp-whos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 32px; }
.lp-who { background: #fff; border: 1px solid var(--line); border-top-width: 6px; border-radius: 12px; padding: 24px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.lp-who.c { border-top-color: var(--brand); }
.lp-who.v { border-top-color: var(--accent); }
.lp-who.r { border-top-color: var(--info); }
.lp-who-ic svg { width: 30px; height: 30px; color: var(--ink-2); }
.lp-who h3 { font-size: 22px; }
.lp-who p { color: var(--ink-2); line-height: 1.5; flex: 1; }
.lp-help { background: var(--ink); color: #fff; padding: 44px 0; }
.lp-help-in { display: flex; flex-wrap: wrap; gap: 20px 40px; align-items: center; justify-content: space-between; }
.lp-help h2 { font-size: 28px; color: #fff; }
.lp-help p { color: rgba(255,255,255,.8); margin-top: 6px; }
.lp-help-btns { display: flex; flex-wrap: wrap; gap: 10px; }
.lp-foot { padding: 28px 0 36px; }
.lp-foot-in { display: flex; flex-wrap: wrap; gap: 10px 28px; align-items: center; }
.lp-foot .wordmark { font-size: 22px; }
@media (max-width: 860px) {
  .lp-hero { padding: 36px 0 44px; }
  .lp-hero-in, .lp-steps, .lp-trust-in, .lp-whos { grid-template-columns: 1fr; }
  .lp-hero-in { gap: 32px; }
  .lp-section { padding: 52px 0; }
  .lp-hide-sm { display: none; }
  .lp-cta .btn { flex: 1; }
}

/* Map: notice shown when the map pictures cannot load */
.map { position: relative; background: #e9efe9; }
.map-note { position: absolute; left: 10px; right: 10px; bottom: 28px; z-index: 600; background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; font-size: 13px; line-height: 1.4; box-shadow: 0 4px 14px rgba(0,0,0,.15); }
.map-note.hidden { display: none; }

/* Shown by boot-check.js when Soma cannot start */
.boot-msg { max-width: 420px; margin: 0 auto; padding: 120px 24px 24px; text-align: center; font-family: var(--font); }
.boot-msg h2 { font-size: 24px; margin-bottom: 10px; }
.boot-msg p { color: var(--ink-2); line-height: 1.5; margin-bottom: 18px; }

/* ---------- Added: messages under fields, load errors, notices ---------- */
.field-error { font-size: 13px; font-weight: 600; color: var(--danger); margin-top: 2px; }
.input.invalid, textarea.invalid, select.invalid { border-color: var(--danger); box-shadow: 0 0 0 1px var(--danger); }
.error-state { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 32px 20px; }
.error-state > svg { width: 36px; height: 36px; color: var(--danger); }
.error-state p { max-width: 38ch; margin: 0 0 8px; }
.reconnect { display: flex; align-items: center; gap: 8px; padding: 8px 14px; background: var(--warn-50); color: #7a4f10; border-radius: 8px; font-size: 13.5px; font-weight: 600; }
.reconnect svg { width: 16px; height: 16px; flex: none; }
.nudge { display: flex; align-items: center; gap: 12px; padding: 10px 16px; background: var(--warn-50); color: #7a4f10; border-bottom: 1px solid var(--line); }
.nudge > svg { width: 22px; height: 22px; flex: none; }
.nudge .btn { flex: none; }
.linklike { background: none; border: 0; padding: 0; font: inherit; font-weight: 650; color: var(--brand); text-decoration: underline; cursor: pointer; }
.menu-item .add.off { width: auto; padding: 0 10px; background: var(--line-2); color: var(--muted); font-size: 12px; font-weight: 650; }

/* "More" list on phones (the bottom bar has room for five tabs) */
.more-list { display: flex; flex-direction: column; margin: -8px -8px; }
.more-list a { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 10px 12px; border-radius: 9px; color: var(--ink); font-weight: 600; }
.more-list a:hover { background: var(--line-2); text-decoration: none; }
.more-list a.active { background: var(--panel); box-shadow: inset 3px 0 0 var(--brand); }
.more-list a svg { width: 20px; height: 20px; color: var(--ink-2); flex: none; }
.more-list .count, .bottomnav .count { background: var(--brand); color: #fff; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 1px 7px; }
.bottomnav a, .bottomnav button { position: relative; }
.bottomnav button { flex: 1 0 auto; min-width: 64px; display: flex; flex-direction: column; align-items: center; gap: 2px; font: inherit; font-size: 11px; font-weight: 600; color: var(--muted); padding: 6px 4px; border: 0; background: none; border-radius: 10px; cursor: pointer; }
.bottomnav button.active { color: var(--ink); }
.bottomnav button svg { width: 22px; height: 22px; }
.bottomnav .count { position: absolute; top: 0; right: 14px; line-height: 14px; font-size: 10px; padding: 0 5px; }
.bottomnav .count.dot { width: 10px; height: 10px; padding: 0; top: 4px; right: 20px; background: var(--accent); }

/* ---------- Added: keyboard focus on everything that can be tapped ---------- */
[role=button]:focus-visible, [role=tab]:focus-visible, .tabs button:focus-visible, .star-input button:focus-visible,
.qty button:focus-visible, .zone-card:focus-visible, .order-tile:focus-visible, .notif:focus-visible, .menu-item:focus-visible,
.photo-drop:focus-visible, .role-pick button:focus-visible, .bottomnav a:focus-visible, .bottomnav button:focus-visible,
.sidebar a:focus-visible, .topnav a:focus-visible, .more-list a:focus-visible, .pin-input input:focus-visible,
tr.clickable:focus-visible, .check:focus-within, .linklike:focus-visible, .modal:focus-visible {
  outline: 3px solid rgba(29, 86, 160, .6); outline-offset: 2px;
}
.modal:focus-visible { outline: none; }
.tabs button:focus-visible { outline-offset: -3px; }
.star-input button:focus-visible { border-radius: 8px; }

/* ---------- Added: touch targets of at least 44 pixels on phones ---------- */
@media (max-width: 860px), (pointer: coarse) {
  .btn.sm { min-height: 44px; height: 44px; }
  .btn.icon, .btn.icon.sm { width: 44px; min-height: 44px; height: 44px; }
  .chip { min-height: 44px; height: 44px; }
  .qty button { width: 44px; height: 44px; }
  .star-input button { min-width: 44px; min-height: 44px; display: grid; place-items: center; }
  .tabs button { min-height: 44px; }
  .menu-item .add { width: 44px; height: 44px; }
  .check input, .opt input { width: 22px; height: 22px; }
  .notif { min-height: 48px; }
  .switch { width: 56px; height: 32px; }
  .switch span::before { width: 26px; height: 26px; }
  .switch input:checked + span::before { transform: translateX(24px); }
}

/* ---------- Added: calm screens for people who ask for less motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .skeleton { animation: none !important; background: #EFEDEA; }
  .spinner { animation-duration: 1.6s !important; animation-iteration-count: infinite !important; }
}

/* Soma staff badge in chat: set by the server's role, never by a person's name. */
.chat .msg .who .support-badge { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; background: var(--brand); color: #fff; font-size: 11px; font-weight: 700; opacity: 1; }
.chat .msg .support-badge svg { width: 12px; height: 12px; }
.chat .msg.from-support { border-color: var(--brand); background: var(--brand-50); }
/* Where the money is: ready, waiting, under review. */
.money-split .split-line { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; padding: 8px 0; border-top: 1px solid var(--line-2); }
.money-split h3 + .split-line { border-top: 0; }
.money-split .split-line.ready .mono { color: var(--ok); }
.money-split .split-line.waiting .mono { color: var(--info); }
.money-split .split-line.review .mono { color: var(--warn); }
.pay-in input.input { max-width: 200px; }
.held-item .mono { font-size: 18px; }

/* Live rider tracking */
.map-pin.stale { opacity: .55; filter: grayscale(.8); }
.live-rider { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2, #f3f5f2); font-size: 14px; line-height: 1.35; }
.live-rider .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--ok, #1a8f4c); flex: none; box-shadow: 0 0 0 4px rgba(26,143,76,.18); }
.live-rider.stale .dot { background: #b7791f; box-shadow: 0 0 0 4px rgba(183,121,31,.18); }
.live-rider.none .dot { background: #9aa39c; box-shadow: none; }

/* Dashboard tables become stacked rows on phones, so nothing is cut off at the right edge. */
@media (max-width: 600px) {
  .stat { padding: 14px; }
  .stat .v { font-size: 24px; }
  table.table.cards thead { display: none; }
  table.table.cards, .table.cards tbody { display: block; }
  .table.cards tr { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 10px 14px; border-bottom: 1px solid var(--line-2); }
  .table.cards tr:last-child { border-bottom: 0; }
  .table.cards td { display: block; padding: 0; border: 0; width: auto !important; }
  .table.cards td.grow { flex: 1 1 120px; min-width: 0; }
  .table.cards td.full { flex: 1 1 100%; }
  .table.cards td.right { margin-left: auto; }
}

/* Long labels wrap instead of running off the screen. */
.btn.block { white-space: normal; height: auto; min-height: 44px; padding-top: 8px; padding-bottom: 8px; text-align: center; }
.offer .badge, .alert .badge { white-space: normal; text-align: left; }

/* Prices never break across lines, even when a long name next to them has to wrap. */
.summary-line .mono, .cart-line .mono, .order-tile .mono, .row .mono, .price { white-space: nowrap; flex: none; }
.row > .badge { flex: none; }

/* Admin lists keep each cell on one line and scroll sideways on a phone. */
.table.nowrap td { white-space: nowrap; }
.table.nowrap td .row.wrap { flex-wrap: nowrap; }

/* Place search and pin hints in the location picker */
.place-box { display: grid; gap: 6px; }
.place-search { width: 100%; }
.place-results { background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.place-results.hidden { display: none; }
.place-opt { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 44px; padding: 8px 12px; border: 0; border-bottom: 1px solid var(--line); background: #fff; font: inherit; text-align: left; cursor: pointer; }
.place-opt:last-child { border-bottom: 0; }
.place-opt:hover, .place-opt:focus-visible { background: #f4f1ec; }
.place-opt svg { width: 16px; height: 16px; flex: none; }
.place-none { padding: 12px; }
.map-foot { align-items: flex-start; gap: 10px; }
.map-where { font-weight: 600; }
.map-where.hidden { display: none; }

/* ---------- Phone polish (journey QA) ---------- */
@media (max-width: 600px) {
  .modal-foot { padding: 12px 16px; gap: 8px; }
  .modal-foot .btn { min-width: 0; padding-left: 10px; padding-right: 10px; }
  /* A long button label wraps instead of being cut off at the edge of the sheet. */
  .modal-foot .btn { white-space: normal; height: auto; min-height: 44px; padding-top: 8px; padding-bottom: 8px; line-height: 1.25; text-align: center; }
}
/* The logo is 30px wide; the tap area around it is 44px. */
.brand { position: relative; }
.brand::after { content: ''; position: absolute; left: -7px; right: -7px; top: 50%; height: 44px; transform: translateY(-50%); }
/* Messages sit above the cart bar instead of covering it. */
@media (max-width: 860px) { body.has-cartbar .toasts { bottom: 150px; } }
@media (max-width: 860px) { .topbar .bell { margin-left: auto; } }
@media (max-width: 860px), (pointer: coarse) {
  .leaflet-touch .leaflet-bar a { width: 40px; height: 40px; line-height: 40px; }
  .chat-send, form button[aria-label="Send"] { min-width: 44px; }
}
@media (max-width: 600px) { .chat { height: 280px; } }
.t-short { display: none; }
@media (max-width: 480px) { .t-long { display: none; } .t-short { display: inline; } }

/* Phone tap targets (journey QA 2): the admin search box, and the online switch whose visible track is only 32px high. */
@media (max-width: 860px) { .row > input.input[type=search] { height: 44px !important; } }
.switch input { top: -8px; height: calc(100% + 16px); }
