/* Leaplove — mobile-first stylesheet shared by every public and business page. */

:root {
  --brand: #0f9f8a;
  --brand-dark: #0b7a6b;
  --brand-soft: #e3f6f2;
  --pink: #e23d7f;
  --pink-soft: #fde8f0;
  --sun: #f7b500;
  --sun-soft: #fff6db;
  --ink: #18212b;
  --ink-2: #4a5563;
  --ink-3: #7b8592;
  --line: #e4e8ec;
  --bg: #f5f7f6;
  --surface: #ffffff;
  --danger: #c62f3b;
  --danger-soft: #fdecee;
  --ok: #18865a;
  --ok-soft: #e4f6ec;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(24, 33, 43, .06), 0 4px 16px rgba(24, 33, 43, .06);
  --shadow-lg: 0 10px 40px rgba(24, 33, 43, .18);
  --tap: 46px;
  --header-h: 56px;
  --nav-h: 64px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.5;
  min-height: 100vh;
  min-height: 100dvh;
  padding-bottom: calc(var(--nav-h) + var(--safe-b));
  -webkit-tap-highlight-color: transparent;
}
body.no-nav { padding-bottom: var(--safe-b); }
img { max-width: 100%; display: block; }
a { color: var(--brand-dark); }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
small, .muted { color: var(--ink-3); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid rgba(15, 159, 138, .45); outline-offset: 2px; }

/* ---------- App bar ---------- */
.appbar {
  position: sticky; top: 0; z-index: 40;
  height: var(--header-h);
  display: flex; align-items: center; gap: 8px;
  padding: 0 12px;
  padding-top: env(safe-area-inset-top, 0px);
  height: calc(var(--header-h) + env(safe-area-inset-top, 0px));
  background: rgba(255, 255, 255, .94);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.appbar .brand { display: flex; align-items: center; gap: 6px; text-decoration: none; color: var(--ink); min-width: 0; }
.appbar .brand img { height: 30px; width: auto; }
.appbar .brand .wordmark { height: 40px; margin-left: -6px; }
.appbar .title { font-weight: 700; font-size: 1.05rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.appbar .spacer { flex: 1; }
.appbar .top-links { display: none; gap: 4px; }
.appbar .top-links a { text-decoration: none; color: var(--ink-2); font-weight: 600; padding: 8px 12px; border-radius: 999px; }
.appbar .top-links a[aria-current="page"], .appbar .top-links a:hover { background: var(--brand-soft); color: var(--brand-dark); }

.icon-btn {
  width: var(--tap); height: var(--tap); flex: 0 0 auto;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; background: transparent; color: var(--ink); border-radius: 50%;
  cursor: pointer; text-decoration: none;
}
.icon-btn:hover { background: #f0f2f4; }
.icon { width: 22px; height: 22px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon.sm { width: 18px; height: 18px; }
.icon.lg { width: 28px; height: 28px; }

/* ---------- Bottom nav (phones) ---------- */
.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: grid; grid-template-columns: repeat(4, 1fr);
  height: calc(var(--nav-h) + var(--safe-b));
  padding-bottom: var(--safe-b);
  background: rgba(255, 255, 255, .97);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.bottom-nav a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  text-decoration: none; color: var(--ink-3); font-size: .72rem; font-weight: 600;
}
.bottom-nav a[aria-current="page"] { color: var(--brand); }
.bottom-nav a .icon { width: 24px; height: 24px; }

/* ---------- Layout ---------- */
.page { width: 100%; max-width: 720px; margin: 0 auto; padding: 16px; }
.page.wide { max-width: 1040px; }
.stack > * + * { margin-top: 16px; }
.row { display: flex; gap: 10px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.grow { flex: 1 1 auto; min-width: 0; }
.grid-2 { display: grid; gap: 12px; grid-template-columns: 1fr; }
.section-title { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); margin: 24px 0 10px; }

.card {
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 16px; border: 1px solid rgba(24, 33, 43, .04);
}
.card.flat { box-shadow: none; border: 1px solid var(--line); }
.card + .card { margin-top: 12px; }

/* ---------- Forms ---------- */
label, .label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; color: var(--ink-2); }
.field { margin-bottom: 14px; }
.field .hint { font-size: .82rem; color: var(--ink-3); margin-top: 4px; }
input[type=text], input[type=email], input[type=password], input[type=tel], input[type=url], input[type=number], input[type=search], select, textarea {
  width: 100%; min-height: var(--tap);
  padding: 10px 14px;
  font: inherit; font-size: 16px; /* 16px stops iOS zooming into fields */
  color: var(--ink); background: #fff;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%237b8592' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(15, 159, 138, .15); }
input[readonly] { background: #f6f7f8; color: var(--ink-2); }
.check { display: flex; align-items: center; gap: 10px; min-height: var(--tap); font-weight: 500; color: var(--ink); margin: 0; cursor: pointer; }
.check input { width: 22px; height: 22px; accent-color: var(--brand); margin: 0; }

.input-group { display: flex; gap: 8px; }
.input-group > input, .input-group > select { flex: 1 1 auto; min-width: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--tap); padding: 10px 18px;
  border: 1.5px solid transparent; border-radius: 999px;
  font: inherit; font-weight: 700; font-size: 1rem; line-height: 1.1;
  cursor: pointer; text-decoration: none; white-space: nowrap;
  background: var(--brand); color: #fff;
  transition: background .15s, transform .05s, box-shadow .15s;
}
.btn:hover { background: var(--brand-dark); }
.btn:active { transform: scale(.98); }
.btn[disabled], .btn.is-loading { opacity: .6; pointer-events: none; }
.btn.block { width: 100%; }
.btn.secondary { background: #fff; color: var(--ink); border-color: var(--line); }
.btn.secondary:hover { background: #f3f5f6; }
.btn.ghost { background: transparent; color: var(--brand-dark); }
.btn.ghost:hover { background: var(--brand-soft); }
.btn.danger { background: var(--danger); }
.btn.danger-ghost { background: transparent; color: var(--danger); border-color: #f2c7cc; }
.btn.pink { background: var(--pink); }
.btn.sm { min-height: 36px; padding: 6px 12px; font-size: .9rem; }
.btn.icon-only { width: var(--tap); padding: 0; flex: 0 0 auto; }
.btn .icon { width: 20px; height: 20px; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-row > .btn { flex: 1 1 0; }

.spinner {
  width: 22px; height: 22px; border-radius: 50%;
  border: 3px solid rgba(15, 159, 138, .2); border-top-color: var(--brand);
  animation: spin .8s linear infinite; display: inline-block;
}
.btn .spinner { width: 18px; height: 18px; border-color: rgba(255,255,255,.4); border-top-color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Segmented tabs ---------- */
.tabs {
  display: flex; gap: 4px; padding: 4px; background: #e9eeec; border-radius: 999px;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs button {
  flex: 1 0 auto; min-height: 40px; padding: 8px 14px; border: 0; border-radius: 999px;
  background: transparent; font: inherit; font-weight: 600; font-size: .92rem; color: var(--ink-2);
  cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.tabs button[aria-selected="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.tabs .icon { width: 18px; height: 18px; }
@media (max-width: 440px) { .tabs .icon { display: none; } .tabs button { padding: 8px 6px; font-size: .9rem; } }

/* ---------- Chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; flex: 0 0 auto;
  min-height: 36px; padding: 6px 14px; border-radius: 999px;
  background: #fff; border: 1.5px solid var(--line); color: var(--ink-2);
  font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer; text-decoration: none;
}
.chip[aria-pressed="true"], .chip.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; background: var(--sun-soft); color: #7a5600; }
.tag.teal { background: var(--brand-soft); color: var(--brand-dark); }
.tag.pink { background: var(--pink-soft); color: #a3215a; }
.tag.grey { background: #eef1f3; color: var(--ink-2); }
.tag.ok { background: var(--ok-soft); color: var(--ok); }
.tag.bad { background: var(--danger-soft); color: var(--danger); }

/* ---------- Location bar ---------- */
.locbar {
  display: flex; align-items: center; gap: 8px; width: 100%;
  min-height: var(--tap); padding: 6px 6px 6px 12px;
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  font: inherit; color: var(--ink); text-align: left; cursor: pointer;
}
.locbar .icon { color: var(--pink); }
.locbar .loc-text { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.locbar .loc-text small { font-weight: 500; }
.locbar .loc-change { color: var(--brand-dark); font-weight: 700; font-size: .9rem; padding: 0 8px; }

/* ---------- Messages ---------- */
.alert { padding: 12px 14px; border-radius: var(--radius-sm); font-size: .95rem; margin-bottom: 14px; display: flex; gap: 10px; align-items: flex-start; }
.alert.error { background: var(--danger-soft); color: #8d1f29; }
.alert.success { background: var(--ok-soft); color: #11603f; }
.alert.info { background: var(--brand-soft); color: #0a5e52; }
.alert.warn { background: var(--sun-soft); color: #6b4c00; }

.toast-wrap { position: fixed; left: 0; right: 0; bottom: calc(var(--nav-h) + var(--safe-b) + 12px); z-index: 100; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; padding: 0 16px; }
body.no-nav .toast-wrap { bottom: calc(var(--safe-b) + 16px); }
.toast { pointer-events: auto; max-width: 480px; width: 100%; background: var(--ink); color: #fff; padding: 12px 16px; border-radius: 12px; box-shadow: var(--shadow-lg); font-weight: 500; animation: toast-in .2s ease-out; }
.toast.error { background: var(--danger); }
.toast.success { background: #11603f; }
@keyframes toast-in { from { transform: translateY(10px); opacity: 0; } }

.empty { text-align: center; padding: 36px 16px; color: var(--ink-3); }
.empty .icon { width: 44px; height: 44px; color: #c3cad1; margin: 0 auto 10px; }
.empty h3 { color: var(--ink-2); }
.loading-block { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 32px; color: var(--ink-3); }
.skeleton { background: linear-gradient(90deg, #eef1f3 25%, #f6f8f9 37%, #eef1f3 63%); background-size: 400% 100%; animation: shimmer 1.2s ease infinite; border-radius: 8px; }
@keyframes shimmer { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }

/* ---------- Bottom sheet / modal ---------- */
.sheet-backdrop {
  position: fixed; inset: 0; z-index: 80; background: rgba(15, 20, 26, .5);
  display: flex; align-items: flex-end; justify-content: center;
  animation: fade .15s ease-out;
}
.sheet {
  width: 100%; max-width: 640px; max-height: 92vh; max-height: 92dvh;
  background: var(--surface); border-radius: 20px 20px 0 0;
  display: flex; flex-direction: column; overflow: hidden;
  animation: sheet-up .22s cubic-bezier(.2, .9, .3, 1);
  padding-bottom: var(--safe-b);
}
.sheet-head { display: flex; align-items: center; gap: 8px; padding: 10px 8px 6px 16px; border-bottom: 1px solid var(--line); }
.sheet-head h2 { margin: 0; font-size: 1.1rem; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet-body { padding: 16px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
.sheet-foot { padding: 12px 16px; border-top: 1px solid var(--line); background: #fff; }
.sheet-grip { width: 40px; height: 4px; border-radius: 4px; background: #d5dade; margin: 8px auto 0; }
@keyframes sheet-up { from { transform: translateY(40px); opacity: .4; } }
@keyframes fade { from { opacity: 0; } }
body.sheet-open { overflow: hidden; }

/* ---------- Scanner ---------- */
.scanner { position: relative; background: #000; border-radius: var(--radius); overflow: hidden; aspect-ratio: 3 / 4; max-height: 60vh; width: 100%; }
.scanner video { width: 100%; height: 100%; object-fit: cover; }
.scanner .frame { position: absolute; left: 10%; right: 10%; top: 35%; height: 30%; border: 3px solid rgba(255,255,255,.9); border-radius: 12px; box-shadow: 0 0 0 9999px rgba(0,0,0,.35); }
.scanner .frame::after { content: ""; position: absolute; left: 6px; right: 6px; top: 50%; height: 2px; background: var(--pink); box-shadow: 0 0 8px var(--pink); animation: scanline 1.6s ease-in-out infinite alternate; }
@keyframes scanline { from { transform: translateY(-30px); } to { transform: translateY(30px); } }
.scanner .scan-hint { position: absolute; left: 0; right: 0; bottom: 14px; text-align: center; color: #fff; font-weight: 600; text-shadow: 0 1px 4px rgba(0,0,0,.6); }

/* ---------- Home ---------- */
.hero {
  background:
    radial-gradient(120% 80% at 100% 0%, rgba(226, 61, 127, .14), transparent 60%),
    radial-gradient(100% 80% at 0% 100%, rgba(15, 159, 138, .18), transparent 60%),
    #fff;
  padding: 22px 16px 20px; border-bottom: 1px solid var(--line);
}
.hero-inner { max-width: 720px; margin: 0 auto; }
.hero h1 { font-size: 1.7rem; margin-bottom: 6px; }
.hero h1 em { font-style: normal; color: var(--pink); }
.hero p.lead { color: var(--ink-2); margin-bottom: 16px; }
.search-box { display: grid; gap: 10px; }
.search-input { position: relative; }
.search-input .icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }
.search-input input { padding-left: 44px; min-height: 52px; font-size: 17px; border-radius: 14px; }
.quick-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.quick {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center;
  min-height: 92px; padding: 12px 6px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line);
  text-decoration: none; color: var(--ink); font-weight: 700; font-size: .88rem; box-shadow: var(--shadow); cursor: pointer; font-family: inherit;
}
.quick .bubble { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; }
.quick .bubble.teal { background: var(--brand-soft); color: var(--brand-dark); }
.quick .bubble.pink { background: var(--pink-soft); color: var(--pink); }
.quick .bubble.sun { background: var(--sun-soft); color: #b07c00; }
.why { display: grid; gap: 10px; }
.why-item { display: flex; gap: 12px; align-items: flex-start; }
.why-item .num { flex: 0 0 auto; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 1.2rem; background: var(--brand-soft); }
.why-item h3 { margin: 0 0 2px; font-size: 1rem; }
.why-item p { margin: 0; color: var(--ink-2); font-size: .93rem; }
.photo-card { border-radius: var(--radius); overflow: hidden; aspect-ratio: 16 / 9; background: #e7ece9; }
.photo-card img { width: 100%; height: 100%; object-fit: cover; }
.cta-card { background: linear-gradient(135deg, #0f9f8a, #0b7a6b); color: #fff; border: 0; }
.cta-card p { color: rgba(255,255,255,.88); }
.cta-card .btn { background: #fff; color: var(--brand-dark); }
.cta-card .btn.ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.site-footer { text-align: center; color: var(--ink-3); font-size: .85rem; padding: 28px 16px 12px; }
.site-footer a { color: var(--ink-2); }

/* ---------- Results ---------- */
.results-head { display: flex; align-items: center; gap: 10px; margin: 18px 0 10px; }
.results-head h2 { margin: 0; font-size: 1.05rem; flex: 1; }
.view-toggle { display: inline-flex; background: #e9eeec; border-radius: 999px; padding: 3px; }
.view-toggle button { border: 0; background: transparent; padding: 6px 12px; border-radius: 999px; font: inherit; font-weight: 600; font-size: .85rem; color: var(--ink-2); display: inline-flex; align-items: center; gap: 4px; cursor: pointer; min-height: 34px; }
.view-toggle button[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.12); }

.product-card { padding: 0; overflow: hidden; }
.product-card .p-head { display: flex; gap: 12px; padding: 14px 14px 10px; }
.thumb { width: 64px; height: 64px; flex: 0 0 auto; border-radius: 12px; background: #f1f4f3; display: grid; place-items: center; overflow: hidden; color: #b3bcc4; }
.thumb img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.thumb.sm { width: 44px; height: 44px; border-radius: 10px; }
.p-title { font-weight: 700; line-height: 1.3; margin: 0 0 4px; font-size: 1rem; }
.p-meta { font-size: .85rem; color: var(--ink-3); display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.store-list { border-top: 1px solid var(--line); }
.store-row { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-top: 1px solid #f0f2f4; cursor: pointer; }
.store-row:first-child { border-top: 0; }
.store-row:hover { background: #fafbfb; }
.store-row .s-name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.store-row .s-sub { font-size: .82rem; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.price { font-weight: 800; color: var(--brand-dark); white-space: nowrap; font-size: 1.05rem; }
.price.none { color: var(--ink-3); font-weight: 600; font-size: .85rem; }
.more-stores { width: 100%; border: 0; border-top: 1px solid #f0f2f4; background: #fafbfb; padding: 10px; font: inherit; font-weight: 600; color: var(--brand-dark); cursor: pointer; min-height: 44px; }

.biz-card { cursor: pointer; }
.biz-card .b-head { display: flex; gap: 12px; align-items: flex-start; }
.logo-box { width: 56px; height: 56px; flex: 0 0 auto; border-radius: 14px; background: var(--brand-soft); color: var(--brand-dark); display: grid; place-items: center; overflow: hidden; font-weight: 800; font-size: 1.3rem; }
.logo-box img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.logo-box.xs { width: 40px; height: 40px; border-radius: 10px; font-size: .95rem; }
.logo-box.lg { width: 72px; height: 72px; border-radius: 18px; font-size: 1.6rem; }
.b-name { font-weight: 700; font-size: 1.05rem; margin: 0 0 2px; line-height: 1.3; }
.b-type { font-size: .85rem; color: var(--ink-3); margin: 0; }
.b-facts { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: .85rem; color: var(--ink-2); margin-top: 8px; }
.b-facts span { display: inline-flex; align-items: center; gap: 4px; }
.b-facts .icon { width: 16px; height: 16px; color: var(--ink-3); }
.b-desc { color: var(--ink-2); font-size: .92rem; margin: 8px 0 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.b-actions { display: flex; gap: 8px; margin-top: 12px; }
.b-actions .btn { flex: 1 1 0; min-height: 40px; font-size: .9rem; padding: 6px 10px; }
.open-now { color: var(--ok); font-weight: 700; }

.detail-list { display: grid; gap: 2px; margin: 0; }
.detail-list a, .detail-list div.item { display: flex; align-items: center; gap: 12px; padding: 12px 4px; text-decoration: none; color: var(--ink); border-bottom: 1px solid #f0f2f4; min-height: 48px; }
.detail-list .icon { color: var(--brand); }
.hours-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.hours-table td { padding: 6px 0; border-bottom: 1px solid #f0f2f4; }
.hours-table td:last-child { text-align: right; color: var(--ink-2); }
.hours-table tr.today td { font-weight: 700; color: var(--ink); }

.inv-item { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid #f0f2f4; }
.inv-item:last-child { border-bottom: 0; }
.inv-item .grow .p-title { margin: 0; font-size: .97rem; }

#map { width: 100%; height: calc(100vh - 230px); height: calc(100dvh - 230px); min-height: 360px; border-radius: var(--radius); overflow: hidden; background: #e7ece9; }
.map-pin { width: 34px; height: 34px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--pink); border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0,0,0,.35); cursor: pointer; }
.map-pin.me { background: var(--brand); border-radius: 50%; transform: none; width: 20px; height: 20px; }
.mapboxgl-popup-content { border-radius: 12px !important; padding: 12px 14px !important; font-family: inherit; }

/* ---------- Dashboard ---------- */
.dash-head { display: flex; align-items: center; gap: 12px; }
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px; text-align: center; }
.stat b { display: block; font-size: 1.3rem; }
.stat span { font-size: .75rem; color: var(--ink-3); font-weight: 600; }
.switch { position: relative; width: 48px; height: 28px; flex: 0 0 auto; }
.switch input { opacity: 0; width: 100%; height: 100%; position: absolute; inset: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch .track { position: absolute; inset: 0; background: #cfd6dc; border-radius: 999px; transition: background .15s; }
.switch .track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; background: #fff; border-radius: 50%; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .15s; }
.switch input:checked + .track { background: var(--brand); }
.switch input:checked + .track::after { transform: translateX(20px); }
.switch input:focus-visible + .track { outline: 3px solid rgba(15, 159, 138, .45); outline-offset: 2px; }
details.more { border: 1px dashed var(--line); border-radius: var(--radius-sm); padding: 0 14px; margin-bottom: 14px; }
details.more summary { cursor: pointer; font-weight: 700; color: var(--brand-dark); min-height: var(--tap); display: flex; align-items: center; list-style: none; }
details.more summary::-webkit-details-marker { display: none; }
details.more summary::after { content: "+"; margin-left: auto; font-size: 1.3rem; }
details.more[open] summary::after { content: "–"; }
.hours-grid { display: grid; grid-template-columns: 88px 1fr; gap: 8px 10px; align-items: center; }
.hours-grid label { margin: 0; }
.typeahead { position: relative; }
.typeahead-list { position: absolute; z-index: 20; left: 0; right: 0; top: 100%; margin-top: 4px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg); max-height: 260px; overflow-y: auto; }
.typeahead-list button { display: block; width: 100%; text-align: left; border: 0; background: #fff; padding: 10px 14px; font: inherit; cursor: pointer; border-bottom: 1px solid #f0f2f4; }
.typeahead-list button:hover, .typeahead-list button:focus { background: var(--brand-soft); }
.typeahead-list b { color: var(--brand-dark); margin-right: 6px; }
.choice-card { display: flex; gap: 14px; align-items: center; text-align: left; width: 100%; border: 1.5px solid var(--line); background: #fff; border-radius: var(--radius); padding: 16px; font: inherit; color: var(--ink); cursor: pointer; }
.choice-card:hover, .choice-card[aria-pressed="true"] { border-color: var(--brand); background: #f7fcfb; }
.choice-card .bubble { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; flex: 0 0 auto; }
.result-pick { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: #fff; margin-bottom: 8px; }

.auth-wrap { max-width: 440px; margin: 0 auto; padding: 24px 16px; }
.auth-logo { display: flex; justify-content: center; margin: 4px 0 16px; }
.auth-logo img { height: 56px; width: auto; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 52px; }
.pw-wrap .icon-btn { position: absolute; right: 2px; top: 50%; transform: translateY(-50%); color: var(--ink-3); }

/* ---------- Larger screens ---------- */
@media (min-width: 640px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .hero { padding: 40px 24px 32px; }
  .hero h1 { font-size: 2.2rem; }
  .search-box { grid-template-columns: 1fr 260px auto; align-items: center; }
  .sheet-backdrop { align-items: center; padding: 24px; }
  .sheet { border-radius: 20px; max-height: 88vh; }
  .sheet-grip { display: none; }
  .page { padding: 24px; }
}
@media (min-width: 900px) {
  body { padding-bottom: 0; }
  .bottom-nav { display: none; }
  .toast-wrap { bottom: 24px; }
  .appbar { padding: 0 24px; }
  .appbar .top-links { display: flex; }
  .results-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }
  .results-grid > .card + .card { margin-top: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
section[id] { scroll-margin-top: 72px; }
