:root {
  --red: #c41230;
  --red-dark: #9e0e26;
  --red-soft: #fff0f2;
  --cream: #faf6f0;
  --cream-2: #f3ebe0;
  --card: #ffffff;
  --ink: #1a1410;
  --ink-2: #3d3229;
  --muted: #6e6258;
  --line: #e8ddd0;
  --ok: #1a7f4b;
  --amber: #d4a017;
  --radius: 12px;
  --shadow: 0 10px 32px rgba(26, 20, 16, 0.1);
  --font: "Inter", system-ui, -apple-system, sans-serif;
  --display: "Source Serif 4", Georgia, serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.45;
  min-height: 100vh;
}
a { color: inherit; }
button, input, select, textarea { font: inherit; }
img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }

.demo-strip {
  background: #1a1410;
  color: #f5f0e6;
  font-size: 0.82rem;
  padding: 0.65rem 1.1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.demo-strip strong { color: #f0c36a; }

.demo-pill {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: #fff3cd;
  color: #7a5a00;
  border: 1px solid #f0d78c;
  border-radius: 999px;
  padding: 0.12rem 0.5rem;
  vertical-align: middle;
}

.store-header {
  background: var(--card);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 40;
}
.header-inner {
  max-width: 980px;
  margin: 0 auto;
  padding: 0.65rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  min-width: 0;
}
.logo-img {
  width: auto;
  height: 44px;
  object-fit: contain;
  flex-shrink: 0;
}
.logo-name {
  display: block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  color: var(--red);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.logo-tag {
  display: block;
  font-size: 0.7rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
@media (max-width: 420px) {
  .logo-text { display: none; }
}
.header-nav {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
}
.nav-phone {
  text-decoration: none;
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--ink-2);
}
@media (max-width: 520px) {
  .nav-phone { display: none; }
}
.cart-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--red);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.55rem 0.95rem;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.88rem;
}
.cart-btn:hover { background: var(--red-dark); }
.cart-count {
  background: #fff;
  color: var(--red);
  min-width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
}

#app { max-width: 980px; margin: 0 auto; padding: 1rem 1rem 3rem; }

.hero {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 1rem;
  min-height: 200px;
  background: #1a1410;
  color: #fff;
  display: grid;
  align-items: end;
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.85;
}
.hero-content {
  position: relative;
  z-index: 1;
  padding: 1.35rem 1.2rem 1.25rem;
  background: linear-gradient(transparent, rgba(26,20,16,.88) 45%);
}
.hero h1 {
  margin: 0 0 0.3rem;
  font-family: var(--display);
  font-size: clamp(1.45rem, 4vw, 1.9rem);
  letter-spacing: -0.02em;
}
.hero p { margin: 0; color: rgba(255,255,255,.88); font-size: 0.92rem; max-width: 28rem; }
.hero-badge {
  display: inline-block;
  margin-top: 0.65rem;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 999px;
  padding: 0.28rem 0.7rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.why-direct {
  background: #fff8e8;
  border: 1px solid #f0d78c;
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  font-size: 0.88rem;
  color: #5c4800;
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}
.why-direct strong { color: #3d3000; }
.why-icon {
  flex-shrink: 0;
  width: 36px; height: 36px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid #ecd89a;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
}

.cat-nav {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  padding: 0.15rem 0 0.85rem;
  margin-bottom: 0.35rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  position: sticky;
  top: 64px;
  z-index: 30;
  background: var(--cream);
}
.cat-nav::-webkit-scrollbar { display: none; }
.cat-chip {
  flex-shrink: 0;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-2);
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.cat-chip.active {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

.menu-section { margin-bottom: 1.5rem; scroll-margin-top: 120px; }
.menu-section h2 {
  margin: 0 0 0.75rem;
  font-family: var(--display);
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}
.menu-list { display: grid; gap: 0.65rem; }
@media (min-width: 640px) {
  .menu-list { grid-template-columns: 1fr 1fr; }
}

.menu-item {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.85rem;
  display: grid;
  grid-template-columns: 1fr 76px;
  gap: 0.75rem;
  cursor: pointer;
  text-align: left;
  width: 100%;
  font: inherit;
  color: inherit;
  transition: box-shadow .15s, border-color .15s;
}
.menu-item:hover {
  border-color: #f0b8c0;
  box-shadow: var(--shadow);
}
.menu-item h3 {
  margin: 0 0 0.25rem;
  font-size: 0.98rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}
.menu-item .desc {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.menu-item .price {
  margin-top: 0.45rem;
  font-weight: 700;
  color: var(--red);
  font-size: 0.95rem;
}
.menu-thumb {
  width: 76px;
  height: 76px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--cream-2);
}
.menu-thumb.placeholder {
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  background: linear-gradient(145deg, var(--cream-2), #e8d9c8);
}

/* Modal */
.modal-scrim {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 70;
}
.item-modal {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(480px, 100%);
  max-height: min(92vh, 720px);
  background: #fff;
  z-index: 80;
  border-radius: 16px 16px 0 0;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -8px 40px rgba(0,0,0,.18);
  overflow: hidden;
}
@media (min-width: 560px) {
  .item-modal {
    top: 50%;
    bottom: auto;
    transform: translate(-50%, -50%);
    border-radius: 16px;
    max-height: min(88vh, 680px);
  }
}
.modal-hero {
  height: 160px;
  background: var(--cream-2);
  position: relative;
  flex-shrink: 0;
}
.modal-hero img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.modal-close {
  position: absolute;
  top: 0.65rem; right: 0.65rem;
  width: 36px; height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.92);
  font-size: 1.35rem;
  cursor: pointer;
  line-height: 1;
  color: var(--ink);
  box-shadow: 0 2px 8px rgba(0,0,0,.12);
}
.modal-body {
  padding: 1rem 1.1rem 0.5rem;
  overflow: auto;
  flex: 1;
}
.modal-body h2 {
  margin: 0 0 0.25rem;
  font-size: 1.2rem;
  font-family: var(--display);
}
.modal-price { font-weight: 700; color: var(--red); margin-bottom: 0.5rem; }
.modal-desc { font-size: 0.88rem; color: var(--muted); margin: 0 0 1rem; }
.opt-group { margin-bottom: 1rem; }
.opt-group h3 {
  margin: 0 0 0.45rem;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.opt-list { display: grid; gap: 0.4rem; }
.opt-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.65rem 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  gap: 0.5rem;
}
.opt-card:has(input:checked) {
  border-color: var(--red);
  background: var(--red-soft);
}
.opt-card input { accent-color: var(--red); }
.opt-card span:last-child { color: var(--muted); font-size: 0.85rem; white-space: nowrap; }
.field { margin-bottom: 0.85rem; }
.field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 0.3rem;
}
.field input, .field select, .field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0.65rem 0.75rem;
  background: #fff;
}
.field textarea { min-height: 72px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid rgba(196,18,48,.25);
  border-color: var(--red);
}
.modal-foot {
  padding: 0.85rem 1.1rem 1.1rem;
  border-top: 1px solid var(--line);
  display: flex;
  gap: 0.65rem;
  align-items: center;
  flex-shrink: 0;
}
.qty-ctrl {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.25rem;
}
.qty-ctrl button {
  width: 34px; height: 34px;
  border: none; background: var(--cream);
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.1rem;
  font-weight: 600;
}
.qty-ctrl span { min-width: 1.5rem; text-align: center; font-weight: 650; }

/* Cart */
.cart-scrim {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.35);
  z-index: 50;
}
.cart-drawer {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: min(400px, 100%);
  background: #fff;
  z-index: 60;
  transform: translateX(100%);
  transition: transform .22s ease;
  display: flex;
  flex-direction: column;
  box-shadow: -8px 0 30px rgba(0,0,0,.12);
}
.cart-drawer.open { transform: translateX(0); }
.cart-drawer-head, .cart-drawer-foot {
  padding: 1rem 1.1rem;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
.cart-drawer-head h2 { margin: 0; font-size: 1.05rem; }
.cart-drawer-foot {
  border-bottom: none;
  border-top: 1px solid var(--line);
  flex-direction: column;
  align-items: stretch;
  gap: 0.45rem;
}
.cart-drawer-body { flex: 1; overflow: auto; padding: 0.75rem 1.1rem; }
.icon-btn {
  border: none; background: transparent; font-size: 1.5rem; line-height: 1;
  cursor: pointer; color: var(--muted); padding: 0.2rem 0.4rem;
}
.icon-btn:hover { color: var(--ink); }
.cart-line {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  gap: 0.7rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--line);
}
.cart-line:last-child { border-bottom: none; }
.cart-thumb {
  width: 56px; height: 56px; border-radius: 8px;
  background: var(--cream-2); object-fit: cover;
}
.cart-thumb.ph {
  display: grid; place-items: center; font-size: 1.25rem;
}
.cart-line h3 { margin: 0; font-size: 0.9rem; }
.cart-line p { margin: 0.15rem 0 0; font-size: 0.78rem; color: var(--muted); }
.qty-row { display: flex; align-items: center; gap: 0.35rem; margin-top: 0.4rem; }
.qty-row button {
  width: 26px; height: 26px; border-radius: 6px; border: 1px solid var(--line);
  background: #fff; cursor: pointer;
}
.cart-line-price { font-weight: 650; font-size: 0.95rem; text-align: right; }
.remove-link {
  border: none; background: none; color: var(--muted); font-size: 0.75rem;
  cursor: pointer; text-decoration: underline; padding: 0; margin-top: 0.25rem;
}
.cart-empty { text-align: center; color: var(--muted); padding: 2rem 0.5rem; }
.cart-total-row {
  display: flex; justify-content: space-between;
  font-size: 0.9rem; color: var(--ink-2);
}
.cart-total-row.grand {
  font-weight: 700; font-size: 1.05rem; color: var(--ink);
  padding-top: 0.35rem; margin-top: 0.15rem;
  border-top: 1px dashed var(--line);
}
.tip-row {
  display: flex; flex-wrap: wrap; gap: 0.35rem; margin: 0.15rem 0 0.35rem;
}
.tip-chip {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0.35rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
}
.tip-chip.active {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}
.pickup-row select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0.55rem 0.65rem;
  margin-bottom: 0.35rem;
}

.primary-btn, .secondary-btn {
  display: inline-flex; justify-content: center; align-items: center;
  border-radius: 10px; padding: 0.75rem 1rem; font-weight: 650; cursor: pointer;
  text-decoration: none; border: none; width: 100%;
}
.primary-btn { background: var(--red); color: #fff; }
.primary-btn:hover { background: var(--red-dark); }
.primary-btn:disabled { opacity: .45; cursor: not-allowed; }
.secondary-btn { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.secondary-btn:hover { background: #f5f5f5; }

/* Checkout */
.checkout { max-width: 640px; margin: 0 auto; }
.checkout h1 { margin: 0 0 0.35rem; font-size: 1.45rem; font-family: var(--display); letter-spacing: -0.02em; }
.checkout-sub { color: var(--muted); margin: 0 0 1.1rem; font-size: 0.9rem; }
.steps { display: flex; gap: 0.5rem; margin-bottom: 1.1rem; flex-wrap: wrap; }
.step-pill {
  font-size: 0.78rem; font-weight: 600;
  padding: 0.35rem 0.7rem; border-radius: 999px;
  background: #eee; color: var(--muted);
}
.step-pill.on { background: var(--ink); color: #fff; }
.step-pill.done { background: #d9f0e4; color: var(--ok); }
.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem;
  margin-bottom: 1rem;
}
.panel h2 { margin: 0 0 0.85rem; font-size: 1.05rem; }
.field-row { display: grid; gap: 0.75rem; }
@media (min-width: 560px) {
  .field-row.two { grid-template-columns: 1fr 1fr; }
}
.actions { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.actions .primary-btn, .actions .secondary-btn { width: auto; min-width: 140px; }
.test-banner {
  background: #fff8e6;
  border: 1px solid #f0d78c;
  color: #6b5200;
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  font-size: 0.85rem;
  margin-bottom: 1rem;
}
.test-banner code {
  background: #fff;
  border: 1px solid #ecd89a;
  border-radius: 4px;
  padding: 0.05rem 0.3rem;
  font-size: 0.8rem;
}
.pay-key {
  font-size: 0.72rem;
  color: var(--muted);
  margin: 0 0 0.85rem;
  word-break: break-all;
}
/* Official-style black Apple Pay button: logo + “Pay” (system font, fixed logo aspect). */
.apple-pay-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 100%;
  min-height: 48px;
  height: 48px;
  background: #000;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 0 16px;
  cursor: pointer;
  margin-bottom: 0.85rem;
  -webkit-appearance: none;
  appearance: none;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
  line-height: 1;
  box-sizing: border-box;
}
.apple-pay-btn:hover,
.apple-pay-btn:focus-visible {
  background: #1a1a1a;
}
.apple-pay-btn:active {
  background: #333;
}
.apple-pay-btn .apple-pay-logo {
  display: block;
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  overflow: visible;
}
.apple-pay-btn .apple-pay-text {
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1;
  color: #fff;
  /* Avoid inherited Inter; keep Apple-like mark */
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
}
.pay-or {
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
  margin: 0 0 0.85rem;
  position: relative;
}
.pay-or::before, .pay-or::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 40%;
  height: 1px;
  background: var(--line);
}
.pay-or::before { left: 0; }
.pay-or::after { right: 0; }
.stripe-box {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.85rem;
  background: #fafafa;
  margin-bottom: 0.85rem;
}
.stripe-box-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.65rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.err { color: var(--red); font-size: 0.8rem; margin-top: 0.3rem; }
.order-summary { font-size: 0.9rem; }
.order-summary .line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.35rem 0;
}
.order-summary .line span:last-child {
  margin-left: auto;
  text-align: right;
}
.order-summary .total {
  border-top: 1px solid var(--line);
  margin-top: 0.4rem;
  padding-top: 0.55rem;
  font-weight: 700;
  font-size: 1.05rem;
}
.confirm { text-align: center; padding: 1.5rem 0.5rem; }
.confirm-check {
  width: 64px; height: 64px; border-radius: 50%;
  background: #d9f0e4; color: var(--ok);
  display: grid; place-items: center;
  font-size: 1.8rem; margin: 0 auto 1rem;
}
.confirm h1 { margin-bottom: 0.4rem; }
.confirm p { color: var(--muted); max-width: 28rem; margin: 0 auto 0.5rem; }
.confirm-box {
  text-align: left;
  background: #fafafa;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1rem;
  margin: 1.25rem auto;
  max-width: 360px;
  font-size: 0.9rem;
}
.notify-note {
  background: var(--red-soft);
  border: 1px solid #f5c2cb;
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  font-size: 0.85rem;
  color: var(--red-dark);
  margin: 0 auto 1.25rem;
  max-width: 360px;
  text-align: left;
}
.store-footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 1.25rem;
  margin-top: 1rem;
}
.footer-inner {
  max-width: 980px; margin: 0 auto;
  font-size: 0.8rem; color: var(--muted);
  text-align: center;
}
.footer-inner p { margin: 0.25rem 0; }
.source-note {
  font-size: 0.75rem;
  color: var(--muted);
  margin: 0.5rem 0 0;
}
body.cart-open, body.modal-open { overflow: hidden; }
