:root {
  --ivory: #f6f1e7;
  --paper: #fbf8f2;
  --card: #ffffff;
  --jade-950: #0a2c26;
  --jade-900: #0e3b33;
  --jade-700: #1f5e52;
  --jade-500: #2e7d6b;
  --jade-200: #bcd9ce;
  --jade-100: #e2eee9;
  --brass: #93703c;
  --brass-light: #c9a66b; --brass-text: #7d5e2e;
  --brass-100: #f3e9d6;
  --ink: #17211d;
  --muted: #4b534c;
  --line: #e6dfcf;
  --danger: #a4372b;
  --danger-100: #f7e3df;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(14, 59, 51, .06), 0 8px 24px rgba(14, 59, 51, .08);
  --serif: "Fraunces", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; --logo-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 76px; }
body {
  margin: 0; background: var(--ivory); color: var(--ink);
  font: 16px/1.45 var(--sans); -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: var(--jade-700); }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono { font-family: var(--mono); }

/* ---------- Header ---------- */
.hero {
  background: var(--jade-900); color: var(--ivory);
  padding: 18px 16px 22px; position: relative; overflow: hidden;
}
.hero::after { /* soft ripple lines */
  content: ""; position: absolute; inset: auto -40px -60px auto; width: 260px; height: 160px;
  background: repeating-radial-gradient(ellipse at 100% 100%, transparent 0 14px, rgba(201, 166, 107, .14) 14px 15.5px);
  pointer-events: none;
}
.hero-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.brand img { width: 44px; height: 44px; border-radius: 50%; box-shadow: 0 0 0 1.5px rgba(201, 166, 107, .55); }
.brand-name { font-family: var(--serif); font-weight: 600; font-size: 1.45rem; letter-spacing: -.01em; line-height: 1; font-variation-settings: "opsz" 72; }
.brand-sub { font-family: var(--logo-mono); font-size: .68rem; letter-spacing: .22em; text-transform: uppercase; color: var(--brass-light); margin-top: 5px; }
.lang {
  border: 1px solid rgba(246, 241, 231, .3); background: transparent; color: var(--ivory);
  border-radius: 999px; padding: 6px 12px; font-size: .8rem; font-weight: 600; letter-spacing: .04em; min-height: 36px;
}
.hero-info { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; font-size: .88rem; color: rgba(246, 241, 231, .92); position: relative; z-index: 1; }
.hero-info a { color: inherit; text-decoration: none; border-bottom: 1px dotted rgba(246, 241, 231, .4); }
.hero-phones { white-space: nowrap; }
.hero-phones i { font-style: normal; color: rgba(246, 241, 231, .45); margin: 0 7px; }
.pill {
  display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 999px;
  font-size: .8rem; font-weight: 600; background: rgba(246, 241, 231, .1); color: var(--ivory);
}
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #7fd1ae; box-shadow: 0 0 0 3px rgba(127, 209, 174, .25); }
.pill.closed::before { background: #e59b8f; box-shadow: 0 0 0 3px rgba(229, 155, 143, .25); }
.pill.later::before { background: var(--brass-light); box-shadow: 0 0 0 3px rgba(201, 166, 107, .25); }

.notice {
  margin: 14px 16px 0; padding: 12px 14px; border-radius: var(--radius); background: var(--brass-100);
  color: #5d4520; font-size: .9rem; border: 1px solid #e8d7b5;
}
.notice.early { background: var(--brass-100, #f3e9d6); color: #4a3a12; border-color: #e6d3ae; margin: 0 0 12px; line-height: 1.45; }
.notice.early b { white-space: nowrap; }
.notice.banner { background: var(--brass-100, #f3e9d6); color: #5a4300; border-color: #e6d3ae; font-weight: 600; }
.notice.warn { background: var(--danger-100); color: #6b241c; border-color: #ecc7c0; }

/* ---------- Category nav ---------- */
.catnav {
  position: sticky; top: 0; z-index: 20; background: rgba(246, 241, 231, .94);
  backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.catnav-inner { display: flex; gap: 8px; align-items: center; padding: 10px 16px; overflow-x: auto; scrollbar-width: none; }
.catnav-inner::-webkit-scrollbar { display: none; }
.chip {
  flex: none; border: 1px solid var(--line); background: var(--paper); border-radius: 999px;
  padding: 7px 14px; font-size: .86rem; font-weight: 500; white-space: nowrap; min-height: 38px; color: var(--jade-900);
}
.chip.active { background: var(--jade-900); border-color: var(--jade-900); color: var(--ivory); }
.search-btn { flex: none; width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); display: grid; place-items: center; color: var(--jade-900); }
.searchbar { display: none; padding: 0 16px 10px; }
.searchbar.show { display: block; }
.searchbar input {
  width: 100%; border: 1.5px solid var(--jade-200); background: var(--card); border-radius: 12px; padding: 11px 14px; font-size: 16px; outline: none;
}
.searchbar input:focus { border-color: var(--jade-500); }

/* ---------- Menu ---------- */
main { max-width: 760px; margin: 0 auto; padding: 8px 16px 140px; }
.cat { padding-top: 22px; }
/* Best sellers: tag in the list + a sideways row of cards above the menu */
.tag-best { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; font-size: .66rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #7a5a24; background: var(--brass-100); border: 1px solid #e6d3ae; border-radius: 999px; padding: 2px 8px; }
.fav { padding-top: 22px; }
.fav h2 { font-family: var(--serif); font-weight: 600; font-size: 1.35rem; margin: 0; color: var(--jade-900); letter-spacing: -.01em; display: flex; align-items: center; gap: 8px; }
.fav h2 .star { width: 18px; height: 18px; color: var(--brass); }
.fav-row { display: flex; gap: 10px; overflow-x: auto; margin: 12px -16px 0; padding: 2px 16px 12px; scroll-snap-type: x proximity; scroll-padding: 0 16px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.fav-row::-webkit-scrollbar { display: none; }
.fav-card { flex: none; width: 152px; min-height: 138px; scroll-snap-align: start; background: var(--card); border-radius: 16px; border-top: 3px solid var(--brass); box-shadow: var(--shadow); display: flex; flex-direction: column; }
.fav-main { flex: 1; text-align: left; background: none; border: 0; padding: 12px 14px 4px; display: flex; flex-direction: column; gap: 4px; color: inherit; }
.fav-main .num { font: 500 .72rem var(--mono); color: var(--brass-text); width: auto; text-align: left; }
.fav-main b { font: 600 1rem/1.2 var(--serif); color: var(--jade-900); }
.fav-foot { display: flex; align-items: center; justify-content: space-between; padding: 0 10px 10px 14px; }
.fav-wrap { position: relative; }
/* Desktop arrows sit beside the heading, never on top of a card */
.fav-nav { position: absolute; top: -40px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--jade-900); display: none; place-items: center; box-shadow: 0 2px 8px rgba(14,59,51,.12); cursor: pointer; }
.fav-nav svg { width: 16px; height: 16px; }
.fav-nav.prev { right: 42px; }
.fav-nav.next { right: 0; }
.fav-nav:hover { background: var(--jade-900); color: #fff; border-color: var(--jade-900); }
@media (hover: hover) and (pointer: fine) { .fav-nav { display: grid; } }
.fav-foot .item-price { margin-left: 0; padding-left: 0; }
.fav-foot .add { position: relative; width: 36px; height: 36px; }
.cat h2 {
  font-family: var(--serif); font-weight: 600; font-size: 1.35rem; margin: 0; color: var(--jade-900);
  letter-spacing: -.01em; font-variation-settings: "opsz" 48; display: flex; align-items: baseline; gap: 10px;
}
.cat h2 .count { font-family: var(--mono); font-size: .72rem; color: var(--brass-text); font-weight: 500; letter-spacing: .05em; }
.cat .cat-note { margin: 4px 0 0; font-size: .84rem; color: var(--muted); }
.items { list-style: none; margin: 12px 0 0; padding: 0; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.item { display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 14px; border-top: 1px solid #f0ebe0; min-height: 64px; }
.item:first-child { border-top: 0; }
.item-main { flex: 1; min-width: 0; background: none; border: 0; padding: 0; text-align: left; display: flex; align-items: center; gap: 12px; }
.num { flex: none; font-family: var(--mono); font-size: .72rem; font-weight: 500; color: var(--brass-text); width: 24px; text-align: right; }
.item-name { font-weight: 500; line-height: 1.25; }
.item-meta { font-size: .8rem; color: var(--muted); margin-top: 2px; }
.item-price { font-family: var(--mono); font-weight: 500; font-size: .92rem; color: var(--jade-900); margin-left: auto; padding-left: 8px; white-space: nowrap; }
.add {
  flex: none; width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--jade-700); background: var(--card);
  color: var(--jade-700); display: grid; place-items: center; position: relative; transition: transform .12s;
}
.add:active { transform: scale(.92); }
.add svg { width: 18px; height: 18px; }
.add .qty-badge {
  position: absolute; top: -5px; right: -5px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px;
  background: var(--brass); color: #fff; font: 600 .72rem/20px var(--sans); text-align: center;
}
.item.in-cart .add { background: var(--jade-900); border-color: var(--jade-900); color: var(--ivory); }
.item.soldout { opacity: .5; }
.item.soldout .add { visibility: hidden; }
.item.unavailable .item-name, .item.unavailable .item-price { text-decoration: line-through; text-decoration-thickness: 1.5px; }
.choices.counts { gap: 8px; }
.count-row { display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 16px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--card); min-height: 56px; }
.count-row.on { border-color: var(--jade-700); background: var(--jade-100); }
.count-row .cn { font-weight: 500; }
.count-row .extra { margin-left: 0; }
.count-row .stepper { margin-left: auto; }
.count-row.on .extra { background: var(--brass); border-color: var(--brass); color: #fff; }
.choice-sep { grid-column: 1 / -1; height: 0; border-top: 1.5px solid #d3c8b0; margin: 6px 2px; }
.tag-soldout { font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--danger); }
.empty-search { text-align: center; color: var(--muted); padding: 40px 0; }
footer.site { text-align: center; color: var(--muted); font-size: .8rem; padding: 12px 16px 0; }

/* ---------- Cart bar ---------- */
.cartbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 12px 16px calc(12px + var(--safe-b));
  background: linear-gradient(to top, var(--ivory) 70%, rgba(246, 241, 231, 0)); pointer-events: none;
  transform: translateY(110%); transition: transform .25s ease;
}
.cartbar.show { transform: none; }
.cartbar button {
  pointer-events: auto; width: 100%; max-width: 728px; margin: 0 auto; display: flex; align-items: center; gap: 12px;
  background: var(--jade-900); color: var(--ivory); border: 0; border-radius: 16px; padding: 14px 18px; min-height: 58px;
  box-shadow: 0 10px 30px rgba(10, 44, 38, .35); font-weight: 600;
}
.cartbar .count { background: var(--brass); color: #fff; border-radius: 8px; min-width: 28px; height: 28px; display: grid; place-items: center; font-size: .9rem; }
.cartbar .total { margin-left: auto; font-family: var(--mono); }

/* ---------- Sheets (dialogs) ---------- */
dialog.sheet {
  width: 100%; max-width: 560px; max-height: 92dvh; margin: auto auto 0; padding: 0; border: 0;
  border-radius: 22px 22px 0 0; background: var(--paper); color: var(--ink); overflow: hidden;
  display: flex; flex-direction: column;
}
dialog.sheet:not([open]) { display: none; }
dialog.sheet[open] { animation: up .24s cubic-bezier(.2, .8, .2, 1); }
dialog.sheet::backdrop { background: rgba(10, 30, 26, .5); }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
@media (min-width: 640px) { dialog.sheet { margin: auto; border-radius: 22px; } }
.sheet-head { display: flex; align-items: flex-start; gap: 12px; padding: 20px 20px 12px; border-bottom: 1px solid var(--line); }
.sheet-head h3 { margin: 0; font-family: var(--serif); font-weight: 600; font-size: 1.3rem; line-height: 1.2; color: var(--jade-900); }
.sheet-head .sub { font-size: .85rem; color: var(--muted); margin-top: 3px; }
#itemSub { display: flex; align-items: baseline; gap: 10px; margin-top: 6px; }
#itemSub .num { font-size: .8rem; color: var(--muted); }
#itemSub .price { font-size: 1.12rem; font-weight: 500; color: var(--jade-900); }
.close { margin-left: auto; flex: none; width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--jade-100); color: var(--jade-900); display: grid; place-items: center; }
.sheet-body { padding: 16px 20px; overflow-y: auto; flex: 1; }
.sheet-foot { padding: 12px 20px calc(14px + var(--safe-b)); border-top: 1px solid var(--line); background: var(--paper); }

fieldset { border: 0; padding: 0; margin: 0 0 18px; }
legend, .label { font-weight: 600; font-size: .92rem; margin-bottom: 8px; padding: 0; display: flex; align-items: center; gap: 8px; }
.req { font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: #6e501f; background: var(--brass-100); padding: 2px 7px; border-radius: 6px; }
.choices { display: grid; gap: 8px; }
.choice { display: flex; align-items: center; gap: 12px; padding: 13px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--card); cursor: pointer; min-height: 52px; }
.choice input { accent-color: var(--jade-700); width: 20px; height: 20px; margin: 0; }
.choice:has(input:checked) { border-color: var(--jade-700); background: var(--jade-100); }
/* Extra-cost tag: always a visible brass pill; turns solid when that option is picked */
.choice .extra, .count-row .extra { margin-left: auto; flex: none; font: 700 .86rem var(--mono, ui-monospace, monospace); color: #7a5a24; background: var(--brass-100); border: 1px solid #e6d3ae; border-radius: 999px; padding: 3px 10px; white-space: nowrap; transition: background .15s, color .15s; }
.choice:has(input:checked) .extra { background: var(--brass); border-color: var(--brass); color: #fff; box-shadow: 0 2px 8px rgba(176, 141, 87, .35); }
.choices.grid2 .choice .extra { padding: 2px 8px; font-size: .8rem; }
#itemFoot { flex-wrap: wrap; }
.extras-line { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 4px 10px; justify-content: flex-end; font-size: .86rem; color: var(--muted); margin: -2px 2px 0; }
.extras-line .plus { color: #7a5a24; font-weight: 700; }
#itemSubmit.bump .amt { animation: bump .45s ease; display: inline-block; }
@keyframes bump { 0% { transform: scale(1); } 35% { transform: scale(1.18); } 100% { transform: scale(1); } }
textarea, .input, select {
  width: 100%; border: 1.5px solid var(--line); background: var(--card); border-radius: 12px; padding: 12px 14px; font-size: 16px; outline: none;
}
textarea:focus, .input:focus, select:focus { border-color: var(--jade-500); }
textarea { resize: none; min-height: 64px; }
.field { margin-bottom: 14px; }
.field .hint { font-size: .8rem; color: var(--muted); margin-top: 5px; }
.field.invalid .input { border-color: var(--danger); }
.field .err { display: none; color: var(--danger); font-size: .82rem; margin-top: 5px; }
.field.invalid .err { display: block; }

.stepper { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; background: var(--card); }
.stepper button { width: 44px; height: 44px; border: 0; background: none; font-size: 1.3rem; color: var(--jade-900); display: grid; place-items: center; }
.stepper button:disabled { color: #c9c3b6; }
.stepper output { min-width: 28px; text-align: center; font-weight: 600; font-family: var(--mono); }
.stepper.sm button { width: 36px; height: 36px; font-size: 1.1rem; }
.foot-row { display: flex; gap: 12px; align-items: center; }
.btn {
  display: flex; align-items: center; justify-content: center; gap: 10px; border: 0; border-radius: 14px;
  background: var(--jade-900); color: var(--ivory); font-weight: 600; min-height: 52px; padding: 0 18px; flex: 1;
}
.btn .amt { font-family: var(--mono); }
.sheet-foot > .btn { width: 100%; }
.btn:disabled { opacity: .5; }
.btn.brass { background: var(--brass); color: #fff; }
.btn.ghost { background: transparent; color: var(--jade-900); border: 1.5px solid var(--jade-200); }

/* Cart */
.lines { list-style: none; margin: 0 0 20px; padding: 0; }
.line { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.line-name { font-weight: 500; }
.line-name .num { display: inline; width: auto; margin-right: 6px; }
.line-opts { font-size: .82rem; color: var(--muted); grid-column: 1; }
.line-price { font-family: var(--mono); text-align: right; font-size: .92rem; }
.line-ctl { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; margin-top: 4px; }
.linkbtn { background: none; border: 0; color: var(--jade-700); font-size: .86rem; font-weight: 500; padding: 8px 0; text-decoration: underline; text-underline-offset: 3px; }
.linkbtn.danger { color: var(--danger); }
.section-title { font-family: var(--serif); font-weight: 600; font-size: 1.08rem; color: var(--jade-900); margin: 4px 0 10px; }
.totals { margin: 6px 0 0; font-size: .95rem; }
.totals div { display: flex; justify-content: space-between; padding: 3px 0; }
.totals dd { margin: 0; font-family: var(--mono); }
.totals dt { color: var(--muted); }
.totals .grand { border-top: 1px dashed var(--line); margin-top: 6px; padding-top: 9px; font-weight: 700; font-size: 1.08rem; }
.totals .grand dt { color: var(--ink); }
.secure { display: flex; align-items: center; justify-content: center; gap: 6px; font-size: .78rem; color: var(--muted); margin-top: 10px; }
.formerr { background: var(--danger-100); color: #6b241c; border-radius: 12px; padding: 10px 12px; font-size: .88rem; margin-bottom: 12px; display: none; }
.formerr.show { display: block; }
.empty-cart { text-align: center; color: var(--muted); padding: 28px 0; }

.toast {
  position: fixed; left: 50%; bottom: calc(92px + var(--safe-b)); transform: translate(-50%, 20px); opacity: 0;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 12px; font-size: .9rem; z-index: 60;
  transition: .25s; pointer-events: none; max-width: calc(100% - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Order status page ---------- */
.status-wrap { max-width: 560px; margin: 0 auto; padding: 20px 16px 48px; }
.ticket { background: var(--card); border-radius: 20px; box-shadow: var(--shadow); overflow: hidden; }
.ticket-top { padding: 24px 22px 20px; text-align: center; border-bottom: 2px dashed var(--line); position: relative; }
.ticket-top .kicker { font-family: var(--mono); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--brass-text); }
.ticket-top .ordnum { font-family: var(--mono); font-weight: 600; font-size: 2.3rem; color: var(--jade-900); letter-spacing: .02em; margin: 6px 0 2px; }
.ticket-top h1 { font-family: var(--serif); font-weight: 600; font-size: 1.5rem; margin: 10px 0 4px; color: var(--jade-900); }
.ticket-top p { margin: 0; color: var(--muted); }
.steps { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); padding: 0; margin: 20px 0 0; position: relative; }
.steps li { text-align: center; font-size: .78rem; color: var(--muted); position: relative; padding-top: 30px; }
.steps li::before { content: ""; position: absolute; top: 6px; left: 50%; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%; background: var(--line); z-index: 1; }
.steps li::after { content: ""; position: absolute; top: 13px; left: -50%; width: 100%; height: 2px; background: var(--line); }
.steps li:first-child::after { display: none; }
.steps li.done { color: var(--jade-900); font-weight: 600; }
.steps li.done::before { background: var(--jade-500); box-shadow: 0 0 0 4px var(--jade-100); }
.steps li.done::after { background: var(--jade-500); }
.steps li.now::before { animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgba(46, 125, 107, .15); } }
.ticket-body { padding: 18px 22px 22px; }
.pickup-box { display: flex; gap: 14px; align-items: center; background: var(--jade-100); border-radius: 14px; padding: 14px; margin-bottom: 16px; }
.pickup-box .big { font-family: var(--mono); font-weight: 600; font-size: 1.25rem; color: var(--jade-900); }
.pickup-box .small { font-size: .82rem; color: var(--jade-700); }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.actions a { text-decoration: none; }
.ready-flash { background: var(--jade-900); color: var(--ivory); }
.ready-flash .kicker { color: var(--brass-light); }
.ready-flash h1, .ready-flash .ordnum { color: var(--ivory); }
.ready-flash p { color: rgba(246, 241, 231, .8); }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--jade-100); border-top-color: var(--jade-500); animation: spin 1s linear infinite; margin: 8px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { *, *::before { animation: none !important; transition: none !important; } }

/* Step-by-step option groups */
.optgroup { scroll-margin-top: 12px; }
.optgroup:not([hidden]) { animation: reveal .22s ease; }
@keyframes reveal { from { opacity: 0; transform: translateY(6px); } }
.opt-hint { margin: -4px 0 10px; font-size: .82rem; color: var(--muted); }
.choice-sub { display: block; font-size: .8rem; color: var(--muted); margin-top: 1px; }
.choices.grid2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.choices.grid2 .choice { padding: 11px 12px; gap: 10px; min-height: 48px; font-size: .94rem; }
.choices.grid2 .choice.wide { grid-column: 1 / -1; } /* odd one out fills the row instead of leaving a hole */
.choice input[type="checkbox"] { accent-color: var(--jade-700); width: 20px; height: 20px; margin: 0; }

/* Scrolling */
body.locked { position: fixed; left: 0; right: 0; overflow: hidden; }
.sheet-body { overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
dialog.sheet { overscroll-behavior: contain; }
.catnav-inner { overscroll-behavior-x: contain; scroll-snap-type: none; }

/* "¿Quieres hacer cambios?" — quiet button that reveals the optional change lists */
.changes-btn { display: block; width: 100%; margin: 14px 0 6px; background: none; border: 1.5px dashed #cfc6b3; border-radius: 12px; padding: 14px; color: var(--muted); font-weight: 600; font-size: .95rem; }
.changes-btn span { font-weight: 400; }

/* Cart on phones: use (almost) the full screen so the order and form get the most room.
   iPhone Safari's toolbars eat into the old 92% height, which left only a small window. */
.sheet-body { min-height: 0; }
@media (max-width: 639px) {
  #cartSheet { height: calc(100vh - 16px); height: calc(100dvh - 16px); max-height: none; }
  #cartSheet .sheet-head { padding: 14px 18px 10px; }
  #cartSheet .sheet-body { padding: 12px 18px; }
  #cartSheet .sheet-foot { padding: 10px 18px calc(10px + var(--safe-b)); }
  #cartSheet .secure { margin-top: 6px; font-size: .74rem; }
  /* The whole cart scrolls as one page (the title scrolls away) and only the Pagar bar stays pinned,
     instead of a small scrolling box squeezed between a fixed title and a fixed footer. */
  #cartSheet[open] { overflow-y: auto; -webkit-overflow-scrolling: touch; }
  #cartSheet > * { flex-shrink: 0; }
  #cartSheet .sheet-body { overflow: visible; flex: 1 0 auto; }
  #cartSheet .field, #cartSheet .choice { scroll-margin-bottom: 130px; }
  #cartSheet .sheet-foot { position: sticky; bottom: 0; margin-top: auto; z-index: 2; box-shadow: 0 -8px 18px rgba(23, 33, 29, .06); }
}

/* In the restaurant ("En el local") */
.notice.here { background: var(--jade-900); color: var(--ivory); border-color: var(--jade-900); line-height: 1.4; }
.notice.here b { color: var(--brass-light, #ecd3a0); }
.dine-choices { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.dine-choices .choice { align-items: flex-start; padding: 14px 12px; }
.dine-choices .choice input { margin-top: 2px; }
.field.dine.invalid .choice { border-color: var(--danger); }
.here-toggle { display: block; margin: 2px 0 14px; }
.here-toggle.on { margin-top: -12px; margin-bottom: 18px; }
.field.dine .here-toggle { margin: 4px 0 6px; }
.label small { font-weight: 400; color: var(--muted); }
.ticket-top .callno { font-family: var(--mono); font-weight: 600; font-size: 5.2rem; line-height: 1; color: var(--jade-900); margin: 6px 0 4px; letter-spacing: .02em; }
.ready-flash .callno { color: var(--ivory); }
.ticket-top .fullno { font-family: var(--mono); font-size: .8rem; color: var(--muted); letter-spacing: .06em; }
.ready-flash .fullno { color: rgba(246, 241, 231, .85); }
.dine-tag { display: inline-block; margin-top: 10px; padding: 5px 12px; border-radius: 999px; background: var(--brass-100); color: #6b4e1f; font-weight: 700; font-size: .82rem; letter-spacing: .04em; }
.ready-flash .dine-tag { background: var(--brass-light, #ecd3a0); color: var(--jade-900); }
.ready-flash.here-ready { animation: readyPulse 1.4s ease-in-out 3; }
@keyframes readyPulse { 50% { background: #1f7a5a; } }
.sound-btn { display: inline-flex; align-items: center; gap: 8px; margin-top: 14px; padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--card); color: var(--jade-900); font: 600 .86rem inherit; font-family: inherit; }
.sound-btn.on { background: var(--jade-100); border-color: var(--jade-500); }
.ready-flash .sound-btn { background: transparent; color: var(--ivory); border-color: rgba(246, 241, 231, .4); }
.ready-flash .steps li { color: rgba(246, 241, 231, .85); }
.ready-flash .steps li.done { color: var(--ivory); }

/* Test (sandbox) mode */
.pill.test { background: #6d28d9; color: #fff; }
.notice.test { background: #ede9fe; color: #4c1d95; border-color: #c4b5fd; font-weight: 600; }
.test-tag { display: inline-block; margin-top: 10px; padding: 5px 12px; border-radius: 999px; background: #6d28d9; color: #fff; font-weight: 700; font-size: .82rem; }

/* In the restaurant: sticky bar on top of the menu */
.herebar { display: flex; align-items: center; gap: 10px; padding: 8px 16px; background: var(--jade-900); color: var(--ivory); }
.herebar[hidden] { display: none; }
.herebar svg { flex: none; color: var(--brass-light); }
.herebar div { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.herebar b { font-size: .88rem; font-weight: 700; }
.herebar span { font-size: .78rem; color: rgba(246, 241, 231, .82); }
html.here-on { scroll-padding-top: 124px; }

/* Minimum purchase notice in the cart */
.minbox { margin: 4px 0 22px; padding: 14px; border-radius: 14px; background: var(--brass-100); border: 1.5px solid #e6d3ae; color: #5d4520; }
.minbox b { display: block; font-size: 1rem; color: #4a3610; }
.minbox p { margin: 4px 0 10px; font-size: .9rem; line-height: 1.4; }
.minquick-l { font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #7a5a24; margin-bottom: 6px; }
.minquick { display: grid; gap: 8px; margin-bottom: 10px; }
.minquick button { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 11px 14px; border-radius: 12px; border: 1.5px solid #e6d3ae; background: #fff; color: var(--ink); font: 600 .95rem var(--sans, inherit); text-align: left; min-height: 48px; }
.minquick button .p { font-family: var(--mono, monospace); color: var(--jade-700); flex: none; }
.minquick button:active { background: var(--jade-100); border-color: var(--jade-700); }
.minbox .btn.ghost { width: 100%; }
/* Pickup method: in store / Servi-Carro */
.method-choices .choice { align-items: flex-start; padding: 14px 12px; }
.method-choices .choice input { margin-top: 2px; }
#fMethod { margin-bottom: 12px; }
#fMethod.invalid .choice { border-color: var(--danger); }
.method-tag { display: inline-block; margin-top: 10px; padding: 5px 12px; border-radius: 999px; background: var(--brass-100); color: #6b4e1f; font-weight: 700; font-size: .82rem; letter-spacing: .04em; }
/* Easier to read item options: bolder choices and question titles, darker and larger helper text */
.optgroup legend { font-weight: 700; font-size: 1rem; color: var(--ink); }
.choice > span:first-of-type, .count-row .cn { font-weight: 600; color: var(--ink); }
.choice-sub { font-size: .86rem; font-weight: 500; color: #3d443d; margin-top: 2px; }
.req { color: #6e501f; font-weight: 700; }
/* Two-line choices (title + note): stack as blocks so long notes wrap inside the box on every browser */
.choice > span:first-of-type { flex: 1; min-width: 0; }
.choice-note { display: block; margin-top: 3px; font-size: .84rem; line-height: 1.3; font-weight: 500; color: var(--muted); overflow-wrap: anywhere; }
.method-choices .choice b { white-space: nowrap; }
@media (max-width: 430px) { .method-choices.grid2 { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Dish photos (only on dishes that have one; the rest keep the compact row) ---------- */
.item.has-photo { align-items: center; padding: 14px 18px 14px 14px; min-height: 112px; }
.item.has-photo .item-main { align-items: flex-start; }
.item-text { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; min-width: 0; }
.item-text .tag-best, .item-text .tag-soldout { margin-top: 0; }
.item.has-photo .item-price { margin-left: 0; padding-left: 0; }
.item-photo { position: relative; flex: none; width: 84px; height: 84px; }
.item-photo > button[data-open] { display: block; width: 100%; height: 100%; padding: 0; border: 0; border-radius: 14px; overflow: hidden; background: var(--line); }
.item-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.item-photo .add { position: absolute; right: -6px; bottom: -6px; width: 36px; height: 36px; box-shadow: 0 2px 8px rgba(14,59,51,.25); }
.item.soldout .item-photo img { filter: grayscale(1); }
.fav-card.has-photo { overflow: hidden; }
.fav-photo { display: block; width: 100%; height: 96px; padding: 0; border: 0; background: var(--line); flex: none; }
.fav-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.fav-photo.empty { display: grid; place-items: center; background: var(--jade-900); }
.fav-photo.empty img { width: 46px; height: 46px; border-radius: 50%; opacity: .55; }
.item-hero { position: relative; flex: none; height: min(220px, 28dvh); background: var(--line); overflow: hidden; }
.item-hero img { display: block; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .25s; }
.item-hero img.ready { opacity: 1; }
/* Dish popup: the photo, title and choices scroll together as one page (so a small phone isn't stuck
   looking at the photo); only the Añadir bar stays pinned at the bottom and the ✕ stays pinned at the top. */
#itemSheet[open] { overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
#itemSheet .sheet-pin, #itemSheet .item-hero, #itemSheet .sheet-head, #itemSheet .sheet-body, #itemSheet .sheet-foot { flex-shrink: 0; }
#itemSheet .sheet-body { overflow: visible; flex: 1 0 auto; }
#itemSheet .sheet-foot { position: sticky; bottom: 0; margin-top: auto; z-index: 2; box-shadow: 0 -8px 18px rgba(23, 33, 29, .06); }
#itemSheet .sheet-pin { position: sticky; top: 0; height: 0; z-index: 3; }
#itemSheet .sheet-pin .close { position: absolute; top: 14px; right: 14px; margin: 0; }
#itemSheet .sheet-head { padding-right: 64px; }
#itemSheet.with-photo .sheet-pin .close { background: rgba(255,255,255,.94); box-shadow: 0 2px 10px rgba(0,0,0,.18); }
#itemSheet .choice, #itemSheet .count-row { scroll-margin-bottom: 110px; }

/* Prices, dish numbers and phones: digits line up in columns */
.mono, .num, .item-price, .price, .cartbar .total, .stepper output, .btn .amt, .line-price, .totals dd, .extra, .ordnum, .callno, .fullno, .pickup-box .big, .hero-phones, .phones, .mlist .pr, .mlist .n { font-variant-numeric: tabular-nums; }
/* Narrow phones: "Para recoger" and both phone numbers stay on one line */
@media (max-width: 380px) {
  .hero-info { font-size: .8rem; gap: 8px 10px; }
  .hero-phones i { margin: 0 4px; }
}
.secure { text-wrap: balance; }
/* Bold inside an already semi-bold label stays at the label's weight (otherwise Inter jumps to its heaviest, darkest cut) */
b, strong { font-weight: 700; }
.choice b { font-weight: inherit; }
/* Dish descriptions */
.item-desc { font-size: .84rem; line-height: 1.35; color: var(--muted); margin-top: 3px;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; } /* full text shows when the dish is opened */
.nw { white-space: nowrap; }
.item-sheet-desc { margin: 6px 0 0; font-size: .92rem; line-height: 1.4; color: var(--muted); max-width: 46ch; }


/* Order page, after pickup: ask for a Google review (pairs with the printed thank-you card) */
.review-card { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; margin: 4px 0 18px; padding: 18px 16px; border-radius: 14px; background: var(--brass-100); color: var(--ink); text-decoration: none; }
.review-card .stars { font-size: 20px; letter-spacing: 4px; color: #b08a4a; }
.review-card b { font: 600 20px var(--serif); color: var(--jade-900); }
.review-card span { font-size: 14.5px; color: var(--muted); }
.review-card .review-btn { margin-top: 10px; display: inline-flex; align-items: center; min-height: 44px; padding: 0 20px; border-radius: 999px; background: var(--jade-900); color: var(--ivory); font-weight: 600; font-size: 15px; }

/* Small line under a category title (e.g. rice: which price is white and which is fried) */
.cat-note { margin: -4px 0 10px; font-size: 13.5px; color: var(--muted); }

/* Dish popup: a real photo can be tapped to see it full size (magnifier badge in the corner) */
.item-hero.zoomable { cursor: zoom-in; }
.item-hero.zoomable::after { content: ""; position: absolute; left: 12px; bottom: 12px; width: 34px; height: 34px; border-radius: 50%;
  background: rgba(14,59,51,.72) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23f6f1e7' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6'/%3E%3Cpath d='M15 15l5 5M10.5 8v5M8 10.5h5'/%3E%3C/svg%3E") center/18px no-repeat; }
.item-hero.zoomable:focus-visible { outline: 3px solid var(--brass); outline-offset: -3px; }
