:root {
  color-scheme: dark;
  font-family: 'Inter', system-ui, sans-serif;
  --bg-start: #061523;
  --bg-end: #071f34;
  --surface: #0d2236;
  --surface-2: #122d45;
  --text: #f7fbff;
  --text-strong: #ffffff;
  --muted: #9fb7d1;
  --primary: #4ecdc4;
  --primary-rgb: 78,205,196;
  --accent: #ff6b6b;
  --accent-rgb: 255,107,107;
  --danger: #ff6b6b;
  --danger-rgb: 255,107,107;
  --border: rgba(255,255,255,0.08);
  --border-accent: rgba(78,205,196,0.3);
  --tint-1: rgba(255,255,255,0.04);
  --tint-2: rgba(255,255,255,0.08);
  --tint-3: rgba(255,255,255,0.14);
  --shadow: 0 10px 40px rgba(0,0,0,0.5);
  --shadow-soft: 0 10px 30px rgba(0,0,0,0.4);
  --body-weight: 400;
  --font-heading: 'Inter', system-ui, sans-serif;
}

html[data-theme="claro"] {
  color-scheme: light;
  --bg-start: #efece2;
  --bg-end: #e8e4d6;
  --surface: #ffffff;
  --surface-2: #f3f1ea;
  --text: #2c2b25;
  --text-strong: #14130f;
  --muted: #767468;
  --primary: #5c7c5a;
  --primary-rgb: 92,124,90;
  --accent: #8a6b4f;
  --accent-rgb: 138,107,79;
  --danger: #b3402c;
  --danger-rgb: 179,64,44;
  --border: rgba(20,18,10,0.12);
  --border-accent: rgba(92,124,90,0.35);
  --tint-1: rgba(20,18,10,0.035);
  --tint-2: rgba(20,18,10,0.06);
  --tint-3: rgba(20,18,10,0.1);
  --shadow: 0 14px 30px rgba(20,18,10,0.16);
  --shadow-soft: 0 8px 20px rgba(20,18,10,0.14);
  --body-weight: 300;
}

html[data-theme="urbano"] {
  color-scheme: dark;
  --bg-start: #0a0a0a;
  --bg-end: #000000;
  --surface: #161616;
  --surface-2: #1e1e1e;
  --text: #f5f5f0;
  --text-strong: #ffffff;
  --muted: #a8a8a0;
  --primary: #ffcc00;
  --primary-rgb: 255,204,0;
  --accent: #ff3d1a;
  --accent-rgb: 255,61,26;
  --danger: #ff3d1a;
  --danger-rgb: 255,61,26;
  --border: rgba(255,255,255,0.14);
  --border-accent: rgba(255,204,0,0.4);
  --tint-1: rgba(255,255,255,0.05);
  --tint-2: rgba(255,255,255,0.1);
  --tint-3: rgba(255,255,255,0.18);
  --shadow: 0 8px 0 rgba(0,0,0,0.9);
  --shadow-soft: 0 6px 0 rgba(0,0,0,0.85);
  --body-weight: 600;
}

html[data-theme="cafeteria"] {
  color-scheme: light;
  --bg-start: #eeeeea;
  --bg-end: #e6e6e0;
  --surface: #ffffff;
  --surface-2: #f2f2ef;
  --text: #2e2e2c;
  --text-strong: #161615;
  --muted: #8a8a84;
  --primary: #5b7c8f;
  --primary-rgb: 91,124,143;
  --accent: #5b7c8f;
  --accent-rgb: 91,124,143;
  --danger: #c0392b;
  --danger-rgb: 192,57,43;
  --border: rgba(20,20,15,0.1);
  --border-accent: rgba(91,124,143,0.4);
  --tint-1: rgba(20,20,15,0.03);
  --tint-2: rgba(20,20,15,0.05);
  --tint-3: rgba(20,20,15,0.08);
  --shadow: 0 12px 28px rgba(20,20,15,0.13);
  --shadow-soft: 0 8px 20px rgba(20,20,15,0.1);
  --body-weight: 300;
}

html[data-theme="trattoria"] {
  color-scheme: light;
  --bg-start: #f7ecd8;
  --bg-end: #f0e2c6;
  --surface: #fffaf0;
  --surface-2: #f6ead2;
  --text: #3a2a1e;
  --text-strong: #2a1c12;
  --muted: #8a7561;
  --primary: #a5312f;
  --primary-rgb: 165,49,47;
  --accent: #3f6b45;
  --accent-rgb: 63,107,69;
  --danger: #c9711f;
  --danger-rgb: 201,113,31;
  --border: rgba(58,42,30,0.16);
  --border-accent: rgba(165,49,47,0.35);
  --tint-1: rgba(58,42,30,0.04);
  --tint-2: rgba(58,42,30,0.07);
  --tint-3: rgba(58,42,30,0.12);
  --shadow: 0 14px 30px rgba(58,42,30,0.2);
  --shadow-soft: 0 8px 20px rgba(58,42,30,0.16);
  --body-weight: 400;
  --font-heading: 'Playfair Display', 'Georgia', serif;
}
html[data-theme="trattoria"] .business-name {
  font-weight: 700;
  font-style: italic;
}
html[data-theme="trattoria"] .section-header h2,
html[data-theme="trattoria"] .menu-section-title {
  font-family: var(--font-heading);
  font-weight: 600;
}

/* Airier, more spaced-out feel to match "minimalista" - a single accent (no two-tone
   gradients, since --primary equals --accent here) and lighter borders/shadows. */
html[data-theme="cafeteria"] .hero,
html[data-theme="cafeteria"] .panel {
  padding: 32px 34px;
}
html[data-theme="cafeteria"] .product-card {
  padding: 20px;
  gap: 16px;
}
html[data-theme="cafeteria"] .section-header h2,
html[data-theme="cafeteria"] .business-name {
  font-weight: 500;
}

/* Bolder, sharper-edged "poster" feel - straighter corners, punchier headings,
   flat hard shadows instead of soft blurred ones. */
html[data-theme="urbano"] .hero,
html[data-theme="urbano"] .panel,
html[data-theme="urbano"] .product-card,
html[data-theme="urbano"] .cart-item,
html[data-theme="urbano"] .upsell-item,
html[data-theme="urbano"] .accordion-section,
html[data-theme="urbano"] .modal,
html[data-theme="urbano"] .card-actions .add-btn,
html[data-theme="urbano"] .details-btn,
html[data-theme="urbano"] .button {
  border-radius: 6px;
}
html[data-theme="urbano"] .business-name {
  text-transform: uppercase;
  letter-spacing: 0.01em;
  font-weight: 800;
}
html[data-theme="urbano"] .section-header h2,
html[data-theme="urbano"] .menu-section-title {
  text-transform: uppercase;
  font-weight: 800;
  letter-spacing: 0.02em;
}
html[data-theme="urbano"] .card-actions .add-btn,
html[data-theme="urbano"] .button-primary {
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: linear-gradient(180deg, var(--bg-start) 0%, var(--bg-end) 100%); color: var(--text); }
body { font-family: 'Inter', sans-serif; font-weight: var(--body-weight); }
button, input { font: inherit; }
.page-shell { max-width: 1160px; margin: 0 auto; padding: 24px 20px; }
.closed-shell { max-width: 480px; margin: 0 auto; padding: 60px 24px; text-align: center; }
.closed-shell .business-logo { width: 96px; height: 96px; border-radius: 20px; object-fit: cover; margin-bottom: 16px; }
.closed-badge { display: inline-block; margin-top: 14px; background: rgba(var(--accent-rgb),0.16); color: var(--accent); border-radius: 999px; padding: 8px 18px; font-weight: 700; }
.closed-message { margin-top: 18px; color: var(--muted); line-height: 1.5; white-space: pre-line; }
.hero { position: relative; border: 1px solid rgba(var(--primary-rgb), 0.3); background: var(--surface); box-shadow: var(--shadow-soft); border-radius: 28px; padding: 28px 30px; margin-bottom: 24px; display: flex; justify-content: center; }
.hero .hamburger-btn { position: absolute; top: 24px; left: 24px; margin-top: 0; }
.hero-info { min-width: 0; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; max-width: 480px; }
.business-logo { width: 64px; height: 64px; border-radius: 16px; object-fit: cover; border: 1px solid var(--border); flex-shrink: 0; margin-bottom: 4px; }
.business-slogan { margin: 0; color: var(--muted); font-size: 0.95rem; }
.business-address { margin-top: 4px; color: var(--muted); font-size: 0.9rem; text-decoration: none; }
.business-address:hover { color: var(--primary); text-decoration: underline; }
.business-hours { display: inline-flex; margin-top: 4px; background: rgba(var(--primary-rgb),0.16); color: var(--primary); border-radius: 999px; padding: 6px 14px; font-size: 0.85rem; font-weight: 700; }
.business-name {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 2.6vw, 2.1rem);
  line-height: 1.1;
  color: var(--primary);
}
.featured-banner { position: relative; overflow: hidden; border-radius: 24px; box-shadow: var(--shadow-soft); margin-bottom: 22px; }
.featured-banner[hidden] { display: none; }
.featured-banner-track { display: flex; transition: transform 0.4s ease; }
.featured-slide {
  flex: 0 0 100%;
  display: grid;
  grid-template-columns: 96px 1fr;
  align-items: center;
  gap: 16px;
  padding: 18px 20px;
  border: none;
  background: linear-gradient(120deg, rgba(var(--primary-rgb),0.18), rgba(var(--accent-rgb),0.18)), var(--surface);
  color: inherit;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
}
.featured-slide-photo { width: 96px; height: 96px; object-fit: cover; border-radius: 16px; }
.coupon-slide-badge {
  width: 96px; height: 96px; border-radius: 16px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white; font-size: 1.4rem; font-weight: 800;
}
.featured-slide-info { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.featured-slide-label { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--primary); }
.featured-slide-info strong { font-size: 1.15rem; color: var(--text-strong); }
.featured-slide-price { font-size: 1.05rem; font-weight: 700; color: var(--primary); }
.original-price { color: var(--muted); font-weight: 400; margin-right: 6px; }
.featured-banner-dots { display: flex; justify-content: center; gap: 8px; padding: 10px 0; background: var(--surface); }
.featured-banner-dots:empty { display: none; padding: 0; }
.featured-dot { width: 8px; height: 8px; padding: 0; border-radius: 999px; border: none; background: var(--border-accent); cursor: pointer; }
.featured-dot.active { background: var(--primary); }

.layout { display: grid; grid-template-columns: minmax(0, 2fr) 1fr; gap: 22px; }
.panel { background: var(--surface); border: 1px solid rgba(var(--primary-rgb), 0.3); box-shadow: var(--shadow-soft); border-radius: 28px; padding: 22px; }
.section-header { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 16px; }
.section-label { margin: 0; text-transform: uppercase; letter-spacing: 0.2em; font-size: 0.72rem; color: var(--muted); }
.section-header h2 { margin: 0; font-size: 1.6rem; }
.badge { background: rgba(var(--primary-rgb),0.16); color: var(--primary); border-radius: 999px; padding: 8px 14px; font-size: 0.88rem; font-weight: 700; }
.search-input { width: 100%; margin-bottom: 18px; border-radius: 16px; border: 1px solid var(--border); background: var(--tint-1); color: var(--text-strong); padding: 12px 16px; font-family: inherit; font-size: 0.95rem; }
.search-input::placeholder { color: var(--muted); }
.products-list { display: block; }
.products-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.product-card { display: flex; flex-direction: column; justify-content: space-between; gap: 12px; background: var(--surface); border: 1px solid rgba(var(--primary-rgb), 0.3); box-shadow: var(--shadow-soft); border-radius: 22px; padding: 16px; }
.product-card-main { display: flex; flex-direction: column; gap: 12px; cursor: pointer; }
.product-photo { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 14px; }
.product-photo-placeholder { display: flex; align-items: center; justify-content: center; background: var(--tint-1); font-size: 2rem; color: var(--muted); }
.product-card strong { display: block; font-size: 1rem; color: var(--text-strong); }
.product-card .price { font-size: 1.1rem; color: var(--primary); font-weight: 700; }
.product-card .prep-time { display: block; font-size: 0.78rem; color: var(--muted); font-weight: 400; }
.card-actions { margin-top: auto; display: flex; gap: 8px; }
.card-actions .add-btn { flex: 1; border: none; border-radius: 14px; background: linear-gradient(135deg, var(--primary), var(--accent)); color: white; padding: 12px 14px; font-size: 1.4rem; font-weight: 700; line-height: 1; cursor: pointer; transition: transform 0.2s ease, opacity 0.2s ease; }
.card-actions .add-btn:hover { transform: translateY(-1px); opacity: 0.95; }
.details-btn { flex-shrink: 0; min-height: 44px; padding: 0 14px; border: 1px solid var(--border); border-radius: 14px; background: var(--tint-1); color: var(--muted); font-size: 0.85rem; font-weight: 600; white-space: nowrap; cursor: pointer; }
.details-btn:hover { color: var(--text-strong); border-color: var(--tint-3); }
.description-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.description-list li { line-height: 1.5; }
.product-card.sold-out { opacity: 0.6; }
.product-card.sold-out .product-photo { filter: grayscale(0.6); }
.product-photo-wrap { position: relative; }
.sold-out-badge, .featured-badge { display: inline-block; margin-bottom: 6px; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 4px 10px; border-radius: 999px; }
.sold-out-badge { background: rgba(0,0,0,0.75); color: white; }
.featured-badge { background: linear-gradient(135deg, var(--primary), var(--accent)); color: white; text-transform: none; letter-spacing: normal; }
.product-photo-wrap .sold-out-badge, .product-photo-wrap .featured-badge { position: absolute; top: 10px; left: 10px; margin-bottom: 0; }
.bundle-badge { display: inline-block; margin-top: 4px; font-size: 0.72rem; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: rgba(var(--accent-rgb),0.16); color: var(--accent); }
.sold-out-btn { flex: 1; border: 1px solid var(--border); border-radius: 14px; background: var(--tint-1); color: var(--muted); padding: 12px 14px; font-size: 0.85rem; cursor: not-allowed; }
.upsell-suggestions:empty { display: none; }
.upsell-suggestions { margin-top: 16px; }
.upsell-list { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.upsell-item { display: flex; align-items: center; gap: 10px; background: var(--tint-1); border: 1px solid var(--border); border-radius: 14px; padding: 10px 12px; }
.upsell-item span:first-child { flex: 1; color: var(--text-strong); font-size: 0.9rem; }
.upsell-price { color: var(--primary); font-weight: 700; font-size: 0.9rem; }
.upsell-item button { flex-shrink: 0; width: 32px; height: 32px; border: none; border-radius: 10px; background: linear-gradient(135deg, var(--primary), var(--accent)); color: white; font-size: 1.1rem; font-weight: 700; cursor: pointer; }
.cart-items { display: flex; flex-direction: column; gap: 12px; }
.cart-item { display: grid; grid-template-columns: 1fr auto; gap: 12px; background: var(--surface); border: 1px solid rgba(var(--primary-rgb), 0.3); box-shadow: var(--shadow-soft); border-radius: 18px; padding: 14px; }
.cart-item strong { display: block; color: var(--text-strong); margin-bottom: 6px; }
.cart-item small { color: var(--muted); }
.cart-item-controls { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.cart-item-controls .qty-btn { width: 28px; height: 28px; border: none; border-radius: 8px; background: var(--tint-2); color: var(--text-strong); font-size: 1rem; font-weight: 700; cursor: pointer; line-height: 1; }
.cart-item-controls .qty-value { min-width: 18px; text-align: center; color: var(--text-strong); font-weight: 600; }
.cart-item-controls > div { display: flex; align-items: center; gap: 6px; }
.cart-item-controls .remove-btn { border: none; background: transparent; color: var(--muted); cursor: pointer; font-size: 0.8rem; text-decoration: underline; }
.coupon-box { margin-top: 16px; }
.coupon-inputs { display: flex; gap: 8px; }
.coupon-inputs input { flex: 1; border-radius: 14px; border: 1px solid var(--border); background: var(--tint-1); color: var(--text-strong); padding: 10px 14px; font-family: inherit; font-size: 0.9rem; text-transform: uppercase; }
.coupon-inputs input::placeholder { color: var(--muted); text-transform: none; }
.coupon-inputs button { flex-shrink: 0; border: none; border-radius: 14px; background: var(--tint-2); color: var(--text-strong); padding: 10px 16px; font-weight: 700; font-size: 0.85rem; cursor: pointer; }
.coupon-message { margin: 6px 0 0; font-size: 0.82rem; }
.coupon-message:empty { display: none; }
.coupon-message.coupon-message-ok { color: var(--primary); }
.coupon-message.coupon-message-error { color: var(--accent); }
.coupon-message.coupon-message-info { color: var(--muted); }
.summary { margin-top: 18px; border-top: 1px solid var(--border); padding-top: 16px; display: grid; gap: 10px; }
.summary-row { display: flex; justify-content: space-between; color: var(--muted); }
.summary-row[hidden] { display: none; }
.summary-row.discount-row { color: var(--primary); }
.summary-row.total { font-size: 1.1rem; color: var(--text-strong); font-weight: 700; }
.accordion { display: grid; gap: 10px; margin-top: 18px; }
.accordion-section { border: 1px solid var(--border); border-radius: 18px; background: var(--tint-1); overflow: hidden; }
.accordion-section summary { cursor: pointer; padding: 14px 16px; font-weight: 700; list-style: none; }
.accordion-section summary::-webkit-details-marker { display: none; }
.accordion-section summary::after { content: '+'; float: right; color: var(--primary); }
.accordion-section[open] summary::after { content: '−'; }
.accordion-body { display: grid; gap: 12px; padding: 0 16px 16px; }
.accordion-body label { color: var(--muted); font-size: 0.9rem; }
.accordion-body input, .accordion-body textarea { width: 100%; border-radius: 16px; border: 1px solid var(--border); background: var(--tint-1); color: var(--text-strong); padding: 14px 16px; font-family: inherit; }
.delivery-options { display: flex; gap: 8px; flex-wrap: wrap; }
.delivery-options label {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--tint-1);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.delivery-options label:has(input:checked) {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-color: transparent;
  color: white;
}
.delivery-options label:has(input:focus-visible) {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.delivery-options input[type="radio"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.map { border-radius: 22px; margin-top: 18px; min-height: 260px; overflow: hidden; border: 1px solid var(--border); }
.delivery-pin { font-size: 28px; line-height: 1; text-align: center; filter: drop-shadow(0 2px 3px rgba(0,0,0,0.4)); cursor: grab; }
.button { width: 100%; border: none; border-radius: 18px; padding: 14px 18px; font-size: 1rem; font-weight: 700; cursor: pointer; }
.button-primary { background: linear-gradient(135deg, var(--primary), var(--accent)); color: white; }
.button-primary:disabled { background: var(--tint-2); color: var(--muted); cursor: not-allowed; }
.hint { color: var(--muted); font-size: 0.9rem; line-height: 1.5; }
/* Outside-hours: "warning" (toggle ON) is a plain muted hint, same weight as any
   other .hint - "blocked" (toggle OFF) needs to explain why the button went gray. */
#outside-hours-hint[data-variant="blocked"] { color: var(--accent); font-weight: 600; }
#outside-hours-hint[data-variant="blocked"] a { color: inherit; text-decoration: underline; }
.gift-hint { margin-top: 12px; padding: 10px 14px; border-radius: 14px; background: rgba(var(--primary-rgb),0.14); color: var(--primary); font-weight: 600; }
.cart-close { display: none; border: none; background: var(--tint-2); color: var(--text-strong); width: 36px; height: 36px; border-radius: 50%; font-size: 1rem; cursor: pointer; flex-shrink: 0; }
.cart-fab { display: none; }
.cart-backdrop { display: none; }

.hamburger-btn {
  border: none;
  background: var(--tint-2);
  color: var(--text-strong);
  width: 44px;
  height: 44px;
  border-radius: 14px;
  font-size: 1.2rem;
  cursor: pointer;
  flex-shrink: 0;
}

.nav-backdrop {
  display: block;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 65;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}
.nav-backdrop.open { opacity: 1; pointer-events: auto; }

.nav-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  width: min(320px, 85vw);
  z-index: 70;
  overflow-y: auto;
  background: var(--surface);
  border-right: 3px solid var(--primary);
  box-shadow: var(--shadow);
  transform: translateX(-100%);
  transition: transform 0.28s ease;
  padding: 22px;
}
.nav-drawer.open { transform: translateX(0); }

body.nav-open { overflow: hidden; }

.nav-category { margin-bottom: 18px; }
.nav-category-link {
  display: block;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  padding: 10px 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-strong);
  cursor: pointer;
}
.nav-subcategory-link {
  display: block;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  padding: 8px 0 8px 16px;
  font-size: 0.92rem;
  color: var(--muted);
  cursor: pointer;
  border-left: 2px solid var(--border);
}
.nav-subcategory-link:hover, .nav-category-link:hover { color: var(--primary); }

.menu-section { margin-bottom: 28px; }
.menu-section:last-child { margin-bottom: 0; }
.menu-section-title { margin: 0 0 14px; font-size: 1.3rem; color: var(--text-strong); scroll-margin-top: 16px; }
.menu-subsection { margin-bottom: 18px; }
.menu-subsection-title { margin: 0 0 10px; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); scroll-margin-top: 16px; }

@media (max-width: 940px) {
  .layout { grid-template-columns: 1fr; }

  /* The cart-fab bar is fixed to the bottom of the screen on mobile, permanently
     covering whatever content is last on the page (privacy link, creator credit) -
     reserve space so the page can scroll far enough to show them above it. */
  .page-shell { padding-bottom: 96px; }

  .cart-panel {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    max-height: 85vh;
    max-height: 85dvh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 24px 24px 0 0;
    background: var(--surface);
    border-top: 3px solid var(--primary);
    box-shadow: var(--shadow);
    transform: translateY(100%);
    transition: transform 0.28s ease;
    margin: 0;
  }
  .cart-panel.open { transform: translateY(0); }

  .cart-panel::before {
    content: '';
    display: block;
    width: 44px;
    height: 4px;
    margin: 10px auto 0;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
  }

  .cart-close { display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--primary), var(--accent)); color: white; }

  .cart-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 55;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s ease;
  }
  .cart-backdrop.open { opacity: 1; pointer-events: auto; }

  .cart-fab {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    position: fixed;
    left: 14px;
    right: 14px;
    bottom: 16px;
    z-index: 40;
    border: none;
    border-radius: 18px;
    padding: 16px 20px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    box-shadow: var(--shadow-soft);
  }

  body.cart-open { overflow: hidden; }
}

@media (max-width: 640px) {
  .page-shell { padding: 18px 14px 96px; }
  .hero { padding: 18px; }
  .hero .hamburger-btn { top: 14px; left: 14px; }
  .products-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .product-card { padding: 12px; gap: 8px; }
  .product-card strong { font-size: 0.9rem; }
  .product-card .price { font-size: 0.95rem; }

  .featured-slide { grid-template-columns: 72px 1fr; gap: 12px; padding: 14px; }
  .featured-slide-photo, .coupon-slide-badge { width: 72px; height: 72px; }
  .coupon-slide-badge { font-size: 1.1rem; border-radius: 14px; }
  .featured-slide-info strong { font-size: 1rem; }
  .featured-slide-price { font-size: 0.95rem; }
}

.modal-backdrop {
  display: block;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 75;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.modal-backdrop.open { opacity: 1; pointer-events: auto; }

.modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(0.96);
  width: min(420px, 90vw);
  max-height: 85vh;
  max-height: 85dvh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  z-index: 80;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 22px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.modal.open { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.modal .cart-close { display: inline-flex; align-items: center; justify-content: center; float: right; background: var(--tint-2); }
.modal-photo { width: 100%; height: 180px; object-fit: cover; border-radius: 16px; margin-bottom: 14px; }
.modal h3 { margin: 4px 0 10px; }
.modal .price { font-size: 1.2rem; color: var(--primary); font-weight: 700; margin: 14px 0; }
.modal-option-group { margin-bottom: 14px; }
.modal-option-group-title { font-weight: 700; margin-bottom: 6px; }
.modal-option-group summary::after { content: '⌄'; display: inline-block; font-size: 1.3rem; line-height: 1; transition: transform 0.2s ease; }
.modal-option-group[open] summary::after { content: '⌄'; transform: rotate(180deg); }
.option-group-alert { color: var(--danger); font-weight: 700; }
.option-group-hint { color: var(--muted); font-weight: 400; }
.option-group-invalid { border-color: var(--danger); background: rgba(var(--danger-rgb), 0.08); animation: option-group-shake 0.4s ease; }
.accordion-body input.field-invalid { border-color: var(--danger); animation: option-group-shake 0.4s ease; }
@keyframes option-group-shake {
  10%, 90% { transform: translateX(-1px); }
  20%, 80% { transform: translateX(2px); }
  30%, 50%, 70% { transform: translateX(-4px); }
  40%, 60% { transform: translateX(4px); }
}
.modal-error { color: var(--danger); font-weight: 600; font-size: 0.85rem; margin: 10px 0 0; }
.modal-error[hidden] { display: none; }
.tomorrow-confirm { background: var(--tint-2); border: 1px solid rgba(var(--primary-rgb), 0.3); border-radius: 16px; padding: 14px 16px; margin: 10px 0 0; }
.tomorrow-confirm[hidden] { display: none; }
.tomorrow-confirm p { margin: 0 0 12px; font-weight: 600; color: var(--text-strong); }
.tomorrow-confirm-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.tomorrow-confirm-actions .button { flex: 1; min-width: 140px; }
.required-tag { font-size: 0.7rem; font-weight: 600; color: var(--accent); text-transform: uppercase; }
.modal-option { display: block; padding: 6px 0; color: var(--text); cursor: pointer; }
.modal-option input { margin-right: 8px; }
.cart-item-options { display: block; color: var(--muted); font-size: 0.8rem; }

.confirm-modal { width: min(440px, 92vw); }
.confirm-summary { background: var(--tint-1); border: 1px solid var(--border); border-radius: 16px; padding: 14px 16px; margin: 14px 0; font-size: 0.92rem; line-height: 1.6; }
.confirm-summary .confirm-row { display: flex; justify-content: space-between; gap: 10px; }
.confirm-summary .confirm-section-title { font-weight: 700; margin: 10px 0 4px; color: var(--text-strong); }
.confirm-summary .confirm-section-title:first-child { margin-top: 0; }
.confirm-summary .confirm-total { font-weight: 700; color: var(--primary); border-top: 1px solid var(--border); margin-top: 8px; padding-top: 8px; }
.confirm-error { color: var(--accent); font-size: 0.9rem; margin: -4px 0 12px; }
#confirm-modal-edit { background: var(--tint-2); color: var(--text-strong); margin-top: 10px; }

body.modal-open { overflow: hidden; }

.suggestions-list {
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--tint-2);
  overflow: hidden;
}

.suggestion-item {
  padding: 12px 14px;
  color: var(--text-strong);
  cursor: pointer;
  border-bottom: 1px solid var(--border);
}

.suggestion-item:last-child { border-bottom: none; }

.suggestion-item:hover { background: var(--tint-2); }
