/* BWS demo design system — MOBILE FIRST. Base styles target phones; min-width queries enhance.
   Brand tokens come from brand.css (generated per site). Old desktop-first version: demo.v1-desktop-first.css */
:root {
  --brand: #b4232a; --brand-ink: #fff; --brand-dark: #7f1a1f;
  --accent: #f2b33d; --accent-ink: #1d1d1d;
  --bg: #fffaf3; --surface: #fff; --text: #1f1a17; --muted: #625a54; --line: #ece3d8;
  --font-display: Georgia, serif; --font-body: -apple-system, system-ui, sans-serif;
  --radius: 14px; --shadow: 0 1px 2px rgba(0,0,0,.05), 0 4px 14px rgba(0,0,0,.06);
  --max: 1160px; --header-h: 60px; --bar-h: 64px;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-l: env(safe-area-inset-left, 0px); --safe-r: env(safe-area-inset-right, 0px);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.55 var(--font-body); -webkit-font-smoothing: antialiased; overflow-x: hidden;
       padding-bottom: calc(var(--bar-h) + var(--safe-b)); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.12; margin: 0 0 .45em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 8.5vw, 4.2rem); }
h2 { font-size: clamp(1.55rem, 6vw, 2.5rem); }
h3 { font-size: 1.12rem; }
p { margin: 0 0 1em; }
.container { width: min(var(--max), 100% - 32px - var(--safe-l) - var(--safe-r)); margin-inline: auto; }
body.locked { overflow: hidden; }
.section { padding: 44px 0; }
.section.alt { background: var(--surface); }
.section.brand { background: var(--brand); color: var(--brand-ink); }
.section.dark { background: var(--brand-dark); color: #fff; }
.eyebrow { display: inline-block; font: 700 .74rem/1.2 var(--font-body); letter-spacing: .13em; text-transform: uppercase; color: var(--brand-dark); margin-bottom: .7rem; }
.section.brand .eyebrow, .section.dark .eyebrow { color: #fff; }
.lead { font-size: 1.06rem; color: var(--muted); max-width: 62ch; }
.section.brand .lead, .section.dark .lead { color: inherit; }
.center { text-align: center; } .center .lead { margin-inline: auto; }
.form-note { font-size: .86rem; color: var(--muted); }
.section.brand .form-note { color: inherit; }

/* demo ribbon (compact on phones) */
.demo-ribbon { background: #111; color: #fff; text-align: center; font: 600 .72rem/1.35 var(--font-body); padding: 6px 12px; }
.demo-ribbon b { color: #fff; font-weight: 800; text-decoration: underline; text-underline-offset: 2px; }

/* header */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--bg); border-bottom: 1px solid var(--line); }
.site-header .bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: var(--header-h); }
.brand-mark { display: flex; align-items: center; gap: 8px; min-height: 44px; text-decoration: none; font: 800 1.05rem/1.1 var(--font-display); min-width: 0; }
.brand-mark span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.1; }
@media (max-width: 400px) { .brand-mark { font-size: .95rem; } }
.brand-mark img { width: 40px; height: 40px; object-fit: contain; border-radius: 8px; flex: none; }
.header-tools { display: flex; gap: 6px; align-items: center; flex: none; }
.lang-toggle { min-height: 40px; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; font: 700 .8rem/1 var(--font-body); padding: 0 12px; cursor: pointer; white-space: nowrap; color: var(--text); }
.menu-toggle { width: 44px; height: 44px; border: 0; background: none; font-size: 1.5rem; cursor: pointer; color: var(--text); }
.nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; background: var(--bg); padding: 8px max(16px, var(--safe-r)) 16px max(16px, var(--safe-l)); border-bottom: 1px solid var(--line); box-shadow: 0 10px 20px rgba(0,0,0,.08); }
.nav.open { display: flex; }
.nav a { text-decoration: none; font-weight: 600; padding: 12px 8px; border-radius: 10px; min-height: 44px; display: flex; align-items: center; }
.nav .btn { margin-top: 6px; justify-content: center; }

/* buttons (44px+ tap targets) */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; font: 700 1rem/1.1 var(--font-body); padding: 12px 22px; border-radius: 999px; border: 2px solid transparent; text-decoration: none; cursor: pointer; text-align: center; }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-accent { background: var(--accent); color: var(--accent-ink); }
.btn-outline { border-color: currentColor; background: transparent; color: inherit; }
.btn-sm { min-height: 40px; padding: 8px 16px; font-size: .9rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }
.btn-row .btn { flex: 1 1 100%; }
@media (min-width: 520px) { .btn-row .btn { flex: 1 1 200px; } }

/* bottom action bar (phones) */
.action-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; display: flex; gap: 8px; padding: 8px max(12px, var(--safe-r)) calc(8px + var(--safe-b)) max(12px, var(--safe-l)); background: color-mix(in srgb, var(--bg) 96%, transparent); border-top: 1px solid var(--line); backdrop-filter: blur(8px); }
.action-bar a, .action-bar button { flex: 1; min-width: 0; min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; border-radius: 12px; font: 700 .95rem/1 var(--font-body); text-decoration: none; border: 1px solid var(--line); background: var(--surface); color: var(--text); cursor: pointer; }
.action-bar .primary { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); flex: 1.4; }
.action-bar [hidden] { display: none; }
.action-bar { transition: transform .2s ease, visibility 0s linear 0s; }
.action-bar.away { transform: translateY(110%); visibility: hidden; transition: transform .2s ease, visibility 0s linear .2s; }
.action-bar.no-anim { transition: none !important; }
.js body:has(.hero .btn-row) .action-bar:not(.ready) { transform: translateY(110%); visibility: hidden; transition: none; }
@media (max-width: 359px) { .action-bar a, .action-bar button { gap: 3px; font-size: .86rem; } .action-bar .primary { flex: 1.15; } }
.action-bar.has-cart .call-btn { flex: 0 0 56px; }
.action-bar.has-cart .call-btn .lbl { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.action-bar .cart-btn { flex: 2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 10px; font-size: .92rem; }

/* hero */
.hero .grid { display: grid; gap: 22px; padding: 28px 0 36px; }
.hero-media { border-radius: calc(var(--radius) * 1.3); overflow: hidden; aspect-ratio: 4/3; background: var(--line); }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero .badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 14px 0 20px; }
/* phones: actions first, trust badges after them */
@media (max-width: 859px) {
  .hero :has(> .badges):has(> .btn-row) { display: flex; flex-direction: column; }
  .hero :has(> .badges):has(> .btn-row) > .btn-row { order: 1; margin-top: 6px; }
  .hero :has(> .badges):has(> .btn-row) > .badges { order: 2; margin: 16px 0 0; }
  .hero :has(> .badges):has(> .btn-row) > :not(.btn-row):not(.badges) { order: 0; }
  .hero :has(> .badges):has(> .btn-row) > .eyebrow { align-self: flex-start; }
}
.badge { display: inline-flex; align-items: center; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px; font-size: .82rem; font-weight: 600; }
.hero.full { position: relative; color: #fff; overflow: hidden; background: var(--brand-dark); }
.hero.full .hero-bg { position: relative; aspect-ratio: 2/1; background: var(--line); }
.hero.full .hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: var(--hero-pos, 50% 50%); }
.hero.full .container { position: relative; padding: 18px 0 30px; }
.hero.full h1 { font-size: clamp(1.9rem, 8vw, 4.2rem); }
.hero.full .lead { color: #fff; opacity: .94; }
.hero.full .eyebrow { color: #fff; }
.hero.full .badge { background: rgba(255,255,255,.14); color: #fff; border-color: rgba(255,255,255,.35); }

/* grids + cards (single column on phones) */
.grid-2, .grid-3, .review-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.grid-4 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.grid-4 > :last-child:nth-child(odd) { grid-column: 1 / -1; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); color: var(--text); }
.card .body { padding: 14px 16px 16px; }
.card .media { aspect-ratio: 16/10; background: var(--line); }
.card .media img { width: 100%; height: 100%; object-fit: cover; }
.card h3 { margin-bottom: .25em; color: var(--text); }
.card p { color: var(--muted); font-size: .92rem; margin-bottom: .5em; }
.price { font-weight: 800; color: var(--brand-dark); white-space: nowrap; }
.dept { text-align: center; padding: 16px 12px; }
.dept .icon { font-size: 1.7rem; margin-bottom: 4px; }
.dept h3 { font-size: 1rem; }
.dept p { font-size: .84rem; margin: 0; }

/* split */
.split { display: grid; gap: 22px; align-items: center; }
.split .media { border-radius: calc(var(--radius) * 1.2); overflow: hidden; aspect-ratio: 4/3; }
.split .media img { width: 100%; height: 100%; object-fit: cover; }
.checklist { list-style: none; padding: 0; margin: 0 0 1.2em; }
.checklist li { padding-left: 30px; position: relative; margin-bottom: 10px; }
.checklist li::before { content: "✓"; position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-size: .78rem; display: grid; place-items: center; font-weight: 800; }
.section.brand .checklist li::before { background: var(--brand-ink); color: var(--brand); }

/* reviews */
.review { padding: 18px; margin: 0; }
.review blockquote { margin: 0 0 8px; font-size: 1.02rem; }
.review cite { font-style: normal; color: var(--muted); font-size: .86rem; }

/* visit / hours / directions */
.info-grid { display: grid; gap: 22px; }
.hours { width: 100%; border-collapse: collapse; }
.hours td { padding: 9px 0; border-bottom: 1px solid var(--line); }
.hours td:last-child { text-align: right; font-weight: 600; }
.section.brand .hours td { border-color: rgba(255,255,255,.25); }
.map-cta { display: grid; gap: 12px; align-content: center; padding: 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); color: var(--text); }
.map-cta .pin { font-size: 2rem; }
.map-cta p { margin: 0; color: var(--muted); }

/* forms (any form control, even outside .form, gets phone-friendly sizing; 16px stops iOS zoom) */
input, select, textarea { font: inherit; font-size: 16px; min-height: 44px; }
select { -webkit-appearance: none; appearance: none; padding-right: 40px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%23555' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 14px center; }
form.demo-form { display: grid; gap: 14px; text-align: left; }
form.demo-form label { display: grid; gap: 6px; font-weight: 600; font-size: .92rem; }
form.demo-form input, form.demo-form select, form.demo-form textarea { min-height: 48px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background-color: #fff; color: var(--text); width: 100%; }
/* forms */
.form { display: grid; gap: 14px; text-align: left; }
.form .row { display: grid; gap: 14px; }
.form label { display: grid; gap: 6px; font-weight: 600; font-size: .92rem; }
.form input, .form select, .form textarea { font: inherit; font-size: 16px; min-height: 48px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background-color: #fff; color: var(--text); width: 100%; }
form.demo-form select, .form select { padding-right: 40px; }
/* headings that only receive focus from script (form confirmation, focus return after the cart) show no ring */
[tabindex="-1"]:focus { outline: none; }
.form textarea { min-height: 110px; }
/* iOS Safari draws date/time fields natively: shorter than the other fields, centred, and wider than the column */
form.demo-form label, .form label { grid-template-columns: minmax(0, 1fr); }
input[type="date"], input[type="time"], input[type="datetime-local"] { -webkit-appearance: none; appearance: none; display: block; min-width: 0; text-align: left; }
input::-webkit-date-and-time-value { text-align: left; min-height: 1.55em; margin: 0; }

/* ---------------- storefront ---------------- */
.store-head { padding-top: 14px; padding-bottom: 36px; }
.store-head > .container > .eyebrow { display: none; }
.store-head h1 { font-size: clamp(1.7rem, 7.2vw, 3rem); margin-bottom: .25em; }
.store-head .lead { margin-bottom: .6em; }
.pickup-bar { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 9px 12px; margin: 8px 0 8px; font-size: .86rem; }
.menu-note { margin-top: 18px; }
.pickup-bar .pill { background: color-mix(in srgb, var(--brand) 12%, transparent); color: var(--brand-dark); border-radius: 999px; padding: 5px 11px; font-weight: 700; font-size: .82rem; }
.register-note { color: var(--muted); }
.cat-bar { position: sticky; top: var(--header-h); z-index: 30; background: var(--bg); border-bottom: 1px solid var(--line); margin: 0 -16px; padding: 8px 0; }
.cat-scroll { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; padding: 0 16px; scroll-padding-inline: 16px;
              -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
.cat-scroll::after { content: ""; flex: 0 0 12px; }
.cat-scroll::-webkit-scrollbar { display: none; }
.cat-scroll a { flex: none; text-decoration: none; min-height: 40px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: .9rem; white-space: nowrap; }
.cat-scroll a.active { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.menu-cat { padding-top: 18px; scroll-margin-top: 48px; } /* html scroll-padding already clears the header; this clears the chip bar */
.menu-cat h2 { font-size: 1.3rem; margin-bottom: 8px; }
.menu-list { display: grid; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.item { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.item:last-child { border-bottom: 0; }
.item.has-img { grid-template-columns: 64px 1fr auto; }
.item img { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; }
.item-text { min-width: 0; }
.item h3 { font: 700 1rem/1.25 var(--font-body); margin: 0 0 2px; }
.item p { margin: 0; color: var(--muted); font-size: .85rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item p:empty { display: none; }
.item-side { display: flex; align-items: center; gap: 10px; }
.item .price { font-size: .95rem; }
.item .ask { font-size: .8rem; color: var(--muted); font-weight: 600; text-align: right; white-space: nowrap; }
.add-btn { width: 44px; height: 44px; flex: none; border: 0; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-size: 1.5rem; font-weight: 700; line-height: 1; cursor: pointer; }
.add-btn.added { background: var(--accent); color: var(--accent-ink); }

/* cart sheet + checkout */
.sheet-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 60; opacity: 0; pointer-events: none; transition: opacity .2s; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; max-height: 85vh; max-height: 85dvh; overflow-y: auto; overscroll-behavior: contain; background: var(--bg); z-index: 70; border-radius: 18px 18px 0 0; transform: translateY(105%); visibility: hidden; transition: transform .25s ease, visibility 0s linear .25s; display: flex; flex-direction: column; padding-bottom: var(--safe-b); }
.cart-open .sheet { transform: none; visibility: visible; transition: transform .25s ease; } .cart-open .sheet-backdrop { opacity: 1; pointer-events: auto; }
.sheet header { display: flex; justify-content: space-between; align-items: center; padding: 14px max(18px, var(--safe-r)) 14px max(18px, var(--safe-l)); border-bottom: 1px solid var(--line); }
.sheet header h3 { margin: 0; }
.sheet .close { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); font-size: 1.1rem; cursor: pointer; color: var(--text); }
.sheet .lines { flex: 1 1 auto; min-height: 72px; overflow-y: auto; overscroll-behavior: contain; padding: 4px max(18px, var(--safe-r)) 4px max(18px, var(--safe-l)); }
.sheet .line b { display: block; }
.sheet .line-total { font-weight: 700; align-self: start; padding-top: 2px; }
.sheet .line { display: grid; grid-template-columns: 1fr auto; gap: 6px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.qty { display: flex; align-items: center; gap: 12px; margin-top: 8px; }
.qty span { min-width: 1.4em; text-align: center; font-weight: 700; }
.qty button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); font-weight: 700; font-size: 1.1rem; cursor: pointer; color: var(--text); }
.checkout:disabled { opacity: .45; cursor: not-allowed; }
.sheet footer { padding: 14px max(18px, var(--safe-r)) 18px max(18px, var(--safe-l)); border-top: 1px solid var(--line); display: grid; gap: 10px; }
.totals .grand { display: flex; justify-content: space-between; font-weight: 800; font-size: 1.1rem; }
.modal { position: fixed; inset: 0; z-index: 80; display: none; place-items: center; background: rgba(0,0,0,.5); padding: 16px; }
.modal.show { display: grid; }
.modal .panel { background: var(--bg); border-radius: 18px; max-width: 460px; width: 100%; padding: 24px; text-align: center; max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px - var(--safe-b)); overflow-y: auto; overscroll-behavior: contain; }
.modal .ticket { text-align: left; background: var(--surface); border: 1px dashed var(--line); border-radius: 10px; padding: 14px; margin: 14px 0; font-size: .92rem; }
.cart-float { display: none; }

/* footer */
.site-footer { background: var(--brand-dark); color: #fff; padding: 36px 0 24px; }
.site-footer a { color: #fff; opacity: .9; text-decoration: none; display: inline-block; padding: 6px 0; }
.site-footer h3, .site-footer h4 { color: #fff; }
.site-footer .cols { display: grid; gap: 24px; }
.site-footer .fine { margin-top: 24px; padding-top: 16px; border-top: 1px solid rgba(255,255,255,.15); font-size: .8rem; opacity: .75; }

/* ---------------- larger screens ---------------- */
@media (min-width: 620px) {
  .grid-2, .review-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .form .row { grid-template-columns: 1fr 1fr; }
  .card .media { aspect-ratio: 4/3; }
}
@media (min-width: 860px) {
  :root { --header-h: 70px; }
  body { padding-bottom: 0; }
  .action-bar { display: none; }
  .section { padding: 80px 0; }
  .menu-toggle { display: none; }
  .nav { display: flex; position: static; flex-direction: row; align-items: center; padding: 0; border: 0; box-shadow: none; background: none; gap: 4px; }
  .nav a { padding: 8px 12px; min-height: 40px; }
  .nav .btn { margin: 0 0 0 6px; }
  .demo-ribbon { font-size: .78rem; padding: 8px 16px; }
  .brand-mark img { width: 46px; height: 46px; }
  .hero .grid { grid-template-columns: 1.1fr 1fr; gap: 48px; padding: 72px 0; align-items: center; }
  .hero.full { background: #111; }
  .hero.full .hero-bg { position: absolute; inset: 0; aspect-ratio: auto; }
  .hero.full .hero-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.74), rgba(0,0,0,.25)); }
  .hero.full .container { padding: 120px 0; }
  .btn-row .btn { flex: none; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); gap: 20px; }
  .grid-4 { grid-template-columns: repeat(4, 1fr); gap: 16px; }
  .grid-4 > :last-child:nth-child(odd) { grid-column: auto; }
  .grid-4:has(> :nth-child(5):last-child) { grid-template-columns: repeat(5, 1fr); }
  .split { grid-template-columns: 1fr 1fr; gap: 56px; }
  .info-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .site-footer .cols { grid-template-columns: 1.4fr 1fr 1fr; }
  .cat-bar { margin: 0; border-radius: var(--radius); border: 1px solid var(--line); }
  .cat-scroll { padding: 0 10px; }
  .store-head { padding-top: 40px; }
  .store-head > .container > .eyebrow { display: inline-block; }
  .menu-list { grid-template-columns: 1fr 1fr; }
  .item:nth-child(odd) { border-right: 1px solid var(--line); }
  .sheet { left: auto; right: 0; top: 0; bottom: 0; max-height: none; width: min(420px, 100%); border-radius: 0; transform: translateX(105%); }
  .cart-open .sheet { transform: none; }
  .cart-float { display: inline-flex; position: fixed; right: 20px; bottom: 20px; z-index: 50; box-shadow: 0 10px 30px rgba(0,0,0,.25); }
  .cart-float[hidden] { display: none; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .sheet, .cart-open .sheet, .sheet-backdrop, .cart-open .sheet-backdrop, .action-bar, .action-bar.away { transition: none; } }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* one-language sites (build-spec "bilingual": false) */
.mono-lang .lang-toggle { display: none !important; }
