:root {
  --paper: #f5f3ef;
  --surface: #fff;
  --ink: #211a17;
  --muted: #655c56;
  --wine: #781f2a;
  --wine-dark: #55151d;
  --gold: #9a6a24;
  --charcoal: #171311;
  --line: #d8d2cb;
  --soft: #eae6e1;
  --success: #2f6a45;
  --danger: #a31f2f;
  --shadow: 0 8px 24px rgb(33 26 23 / 12%);
  --shell: min(1320px, calc(100vw - 64px));
  --ease: cubic-bezier(.16, 1, .3, 1);
  --z-header: 20;
  --z-backdrop: 40;
  --z-cart: 50;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.55 "Manrope", system-ui, sans-serif;
}

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

button,
input,
textarea { font: inherit; }

button,
a { -webkit-tap-highlight-color: transparent; }

a { color: inherit; text-decoration: none; }

button { color: inherit; }

img { display: block; max-width: 100%; }

[hidden] { display: none !important; }

:focus-visible {
  outline: 3px solid #c2872d;
  outline-offset: 3px;
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 10px;
  left: 10px;
  min-height: 44px;
  padding: 10px 16px;
  transform: translateY(-150%);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 800;
}

.skip-link:focus { transform: none; }

.site-header {
  position: sticky;
  z-index: var(--z-header);
  top: 0;
  border-bottom: 1px solid rgb(255 255 255 / 12%);
  background: var(--charcoal);
  color: #fff;
}

.nav {
  display: flex;
  min-height: 72px;
  align-items: center;
  gap: 30px;
}

.wordmark {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 9px;
  font-family: "Prata", Georgia, serif;
  font-size: 24px;
  line-height: 1;
  white-space: nowrap;
}

.wordmark small {
  color: #d5ad69;
  font: 700 9px/1 "Manrope", sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-inline: auto;
}

.nav-links a,
.header-phone {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  padding: 0 13px;
  color: #e7e0dc;
  font-size: 14px;
  font-weight: 700;
}

.nav-links a:hover,
.header-phone:hover { color: #fff; }

.nav-links a[aria-current="page"] { color: #f0c67c; }

.menu-toggle,
.nav-backdrop { display: none; }

.delivery-hero {
  position: relative;
  min-height: 590px;
  overflow: hidden;
  background: var(--charcoal);
  color: #fff;
}

.hero-photo {
  position: absolute;
  inset: 0 0 0 44%;
  background: url("/assets/delivery/food-antipasti.webp") center / cover no-repeat;
}

.hero-photo::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--charcoal) 0, rgb(23 19 17 / 15%) 65%);
  content: "";
}

.hero-copy {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 590px;
  align-items: flex-start;
  justify-content: center;
  flex-direction: column;
  padding-block: 80px;
}

.hero-copy > * { max-width: 660px; }

.hero-location {
  margin: 0 0 18px;
  color: #e4bd79;
  font-size: 13px;
  font-weight: 800;
}

h1,
h2 { text-wrap: balance; }

h1 {
  margin: 0;
  font: 400 clamp(48px, 6.4vw, 88px)/1.03 "Prata", Georgia, serif;
  letter-spacing: -.03em;
}

.hero-copy > p:not(.hero-location) {
  max-width: 570px;
  margin: 25px 0 0;
  color: #e1d9d3;
  font-size: 18px;
  text-wrap: pretty;
}

.primary-button {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  margin-top: 28px;
  border-radius: 999px;
  padding: 0 22px;
  background: var(--wine);
  color: #fff;
  font-weight: 800;
  transition: background 180ms var(--ease), transform 180ms var(--ease);
}

.primary-button:hover { background: #912a37; transform: translateY(-1px); }
.primary-button:active { transform: translateY(1px); }

.terms {
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.terms-inner {
  display: grid;
  min-height: 150px;
  align-items: center;
  gap: 34px;
  grid-template-columns: 160px minmax(0, 1fr) minmax(210px, 290px);
  padding-block: 28px;
}

.terms h2 {
  margin: 0;
  font: 400 23px/1.2 "Prata", Georgia, serif;
}

.terms dl {
  display: grid;
  margin: 0;
  grid-template-columns: repeat(3, 1fr);
}

.terms dl > div {
  min-height: 76px;
  border-inline-start: 1px solid var(--line);
  padding: 8px 24px;
}

.terms dt { color: var(--muted); font-size: 13px; }
.terms dd { margin: 7px 0 0; color: var(--wine); font-size: 21px; font-weight: 800; }
.terms p { margin: 0; color: var(--muted); font-size: 13px; }

.catalog-section { padding-block: clamp(54px, 7vw, 96px) 120px; }

.catalog-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 34px;
}

.catalog-heading h2 {
  margin: 0;
  font: 400 clamp(36px, 4.6vw, 62px)/1.05 "Prata", Georgia, serif;
  letter-spacing: -.025em;
}

.catalog-heading p { margin: 10px 0 0; color: var(--muted); }

.cart-trigger {
  display: flex;
  min-height: 52px;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 999px;
  padding: 0 18px;
  background: var(--wine);
  color: #fff;
  cursor: pointer;
  font-weight: 800;
}

.cart-trigger b {
  display: grid;
  min-width: 25px;
  height: 25px;
  place-items: center;
  border-radius: 999px;
  background: #fff;
  color: var(--wine);
  font-size: 12px;
}

.cart-trigger strong { padding-left: 4px; border-left: 1px solid rgb(255 255 255 / 28%); }

.catalog-tabs {
  display: inline-flex;
  gap: 4px;
  margin-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.catalog-tabs button {
  position: relative;
  min-width: 130px;
  min-height: 48px;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-weight: 800;
}

.catalog-tabs button[aria-selected="true"] { color: var(--wine); }
.catalog-tabs button[aria-selected="true"]::after { position: absolute; right: 0; bottom: -1px; left: 0; height: 3px; background: var(--wine); content: ""; }

.catalog-layout {
  display: grid;
  align-items: start;
  gap: 38px;
  grid-template-columns: minmax(0, 1fr) 380px;
}

.category-list { min-width: 0; }

.category { border-bottom: 1px solid var(--line); }

.category-toggle {
  display: grid;
  width: 100%;
  min-height: 82px;
  align-items: center;
  border: 0;
  padding: 14px 0;
  background: transparent;
  cursor: pointer;
  grid-template-columns: minmax(0, 1fr) auto 44px;
  text-align: left;
}

.category-toggle strong { font-size: 21px; }
.category-count { margin-right: 18px; color: var(--muted); font-size: 13px; }

.category-icon {
  position: relative;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
}

.category-icon::before,
.category-icon::after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 14px;
  height: 2px;
  transform: translate(-50%, -50%);
  background: var(--wine);
  content: "";
  transition: transform 180ms var(--ease);
}

.category-icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.category-toggle[aria-expanded="true"] .category-icon::after { transform: translate(-50%, -50%) rotate(0); }

.category-content { padding: 0 0 34px; }

.food-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.food-card {
  display: grid;
  min-width: 0;
  overflow: hidden;
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 4px 8px rgb(33 26 23 / 8%);
  grid-template-rows: auto 1fr;
}

.food-photo { aspect-ratio: 4 / 3; overflow: hidden; background: var(--soft); }
.food-photo img { width: 100%; height: 100%; object-fit: cover; }

.food-body {
  display: grid;
  min-height: 154px;
  gap: 18px;
  grid-template-rows: 1fr auto;
  padding: 18px;
}

.food-title { margin: 0; font-size: 16px; line-height: 1.35; }
.food-unit { margin: 5px 0 0; color: var(--muted); font-size: 13px; }
.food-action { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.price { white-space: nowrap; font-size: 17px; font-weight: 800; }

.add-button,
.quantity button {
  min-width: 44px;
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  background: var(--wine);
  color: #fff;
  cursor: pointer;
  font-weight: 800;
}

.add-button { padding: 0 15px; }
.add-button:hover,
.quantity button:hover { background: #912a37; }

.quantity {
  display: grid;
  align-items: center;
  grid-template-columns: 44px 34px 44px;
}

.quantity span { text-align: center; font-weight: 800; }

.compact-list { display: grid; }

.menu-row,
.drink-card {
  display: grid;
  min-height: 76px;
  align-items: center;
  gap: 18px;
  border-bottom: 1px solid var(--soft);
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.menu-row h3,
.drink-card h3 { margin: 0; font-size: 15px; line-height: 1.35; }
.menu-row p,
.drink-card p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }

.cart {
  position: sticky;
  top: 94px;
  overflow: hidden;
  border-radius: 14px;
  background: var(--charcoal);
  box-shadow: var(--shadow);
  color: #fff;
}

.cart-header {
  display: flex;
  min-height: 70px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgb(255 255 255 / 12%);
  padding: 12px 18px;
}

.cart-header h2 { margin: 0; font: 400 25px/1.2 "Prata", Georgia, serif; }

.cart-close,
.cart-back {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 20%);
  border-radius: 50%;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.cart-close { visibility: hidden; }
.cart-close span { position: relative; width: 16px; height: 16px; }
.cart-close span::before,
.cart-close span::after { position: absolute; top: 7px; left: 0; width: 16px; height: 2px; transform: rotate(45deg); background: currentColor; content: ""; }
.cart-close span::after { transform: rotate(-45deg); }

.cart-scroll { max-height: calc(100vh - 116px); overflow-y: auto; overscroll-behavior: contain; }
.cart-empty { padding: 42px 24px; color: #c9bfba; text-align: center; }
.cart-empty strong { display: block; margin-bottom: 6px; color: #fff; font-size: 18px; }
.cart-lines { padding: 4px 20px; }
.cart-line { border-bottom: 1px solid rgb(255 255 255 / 12%); padding-block: 15px; }
.cart-line-top { display: flex; justify-content: space-between; gap: 15px; }
.cart-line h3 { margin: 0; font-size: 13px; line-height: 1.4; }
.cart-line-price { white-space: nowrap; font-size: 13px; font-weight: 800; }
.cart-line-bottom { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; }
.cart-line .quantity { grid-template-columns: 36px 30px 36px; }
.cart-line .quantity button { min-width: 36px; min-height: 36px; background: #332925; }
.remove-button { min-height: 44px; border: 0; background: transparent; color: #ddd2cc; cursor: pointer; font-size: 12px; text-decoration: underline; text-underline-offset: 3px; }
.cart-progress { margin: 15px 20px; padding: 14px; background: #2b231f; color: #ddd3ce; font-size: 12px; }
.progress-track { height: 5px; margin-top: 10px; overflow: hidden; border-radius: 999px; background: rgb(255 255 255 / 14%); }
.progress-fill { height: 100%; background: #d8aa5d; transition: width 200ms var(--ease); }
.cart-totals { display: grid; gap: 7px; margin: 0 20px; border-block: 1px solid rgb(255 255 255 / 12%); padding-block: 15px; }
.total-row { display: flex; justify-content: space-between; color: #d7cec9; font-size: 13px; }
.total-row--grand { margin-top: 5px; color: #fff; font-size: 17px; font-weight: 800; }
.checkout-start,
.submit-button { width: calc(100% - 40px); min-height: 52px; margin: 18px 20px 22px; border: 0; border-radius: 999px; background: var(--wine); color: #fff; cursor: pointer; font-weight: 800; }
.checkout-start:disabled,
.submit-button:disabled { cursor: not-allowed; opacity: .55; }

.checkout-form { display: grid; gap: 15px; padding: 20px; }
.checkout-lead { margin: 0 0 3px; color: #d8cfca; font-size: 13px; }
.field { display: grid; gap: 6px; }
.field label,
.payment-method legend { font-size: 12px; font-weight: 800; }
.field label span { color: #bfb4ae; font-weight: 500; }
.field input,
.field textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid #6b5e57;
  border-radius: 10px;
  padding: 11px 12px;
  background: #28211e;
  color: #fff;
}
.field textarea { min-height: 78px; resize: vertical; }
.field input::placeholder,
.field textarea::placeholder { color: #c0b5af; opacity: 1; }
.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] { border-color: #ff8591; }
.field p,
.field-error { min-height: 17px; margin: 0; color: #ff9aa3; font-size: 12px; }
.payment-method { display: grid; gap: 8px; margin: 0; border: 0; padding: 0; }
.payment-method legend { margin-bottom: 7px; }
.payment-method label { display: grid; min-height: 64px; align-items: center; gap: 10px; border: 1px solid #665952; border-radius: 10px; padding: 10px 12px; cursor: pointer; grid-template-columns: 20px 1fr; }
.payment-method label:has(input:checked) { border-color: #e1b366; background: #30251f; }
.payment-method input { width: 18px; height: 18px; margin: 0; accent-color: #d8aa5d; }
.payment-method strong,
.payment-method small { display: block; }
.payment-method strong { font-size: 13px; }
.payment-method small { margin-top: 2px; color: #c8bdb7; font-size: 11px; }
.payment-method[aria-invalid="true"] label { border-color: #ff8591; }
.consent { display: grid; align-items: start; gap: 9px; color: #d2c7c1; font-size: 12px; grid-template-columns: 19px 1fr; }
.consent input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--wine); }
.submit-button { width: 100%; margin: 2px 0 0; }
.submit-status { min-height: 20px; margin: 0; color: #d8cfca; font-size: 12px; }
.submit-status[data-state="error"] { color: #ff9aa3; }
.submit-status[data-state="success"] { color: #9fd4b1; }

.mobile-cart,
.cart-backdrop { display: none; }

.site-footer { background: var(--wine-dark); color: #fff; }
.site-footer .shell { display: flex; min-height: 130px; align-items: center; justify-content: space-between; gap: 25px; }
.site-footer p { color: #e5d8d2; }
.site-footer > .shell > a:last-child { min-height: 44px; display: inline-flex; align-items: center; font-weight: 800; }

@media (max-width: 1080px) {
  :root { --shell: min(100% - 40px, 980px); }
  .header-phone { display: none; }
  .terms-inner { grid-template-columns: 140px 1fr; }
  .terms-inner > p { grid-column: 2; }
  .catalog-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; }
  .food-grid { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
  :root { --shell: min(100% - 28px, 720px); }
  .nav { min-height: 66px; }
  .nav-links {
    position: fixed;
    z-index: 31;
    top: 66px;
    right: 0;
    bottom: 0;
    display: flex;
    width: min(86vw, 360px);
    align-items: stretch;
    flex-direction: column;
    gap: 0;
    padding: 22px;
    transform: translateX(102%);
    background: var(--charcoal);
    transition: transform 220ms var(--ease);
  }
  .nav-links.is-open { transform: none; }
  .nav-links a { min-height: 54px; border-bottom: 1px solid rgb(255 255 255 / 12%); padding-inline: 4px; font-size: 17px; }
  .menu-toggle { display: grid; width: 44px; height: 44px; place-content: center; gap: 5px; margin-left: auto; border: 1px solid rgb(255 255 255 / 22%); border-radius: 50%; background: transparent; }
  .menu-toggle span { display: block; width: 19px; height: 2px; background: #fff; transition: transform 180ms var(--ease), opacity 180ms var(--ease); }
  .menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav-backdrop { position: fixed; z-index: 30; inset: 66px 0 0; border: 0; background: rgb(0 0 0 / 60%); }
  body.menu-open .nav-backdrop { display: block; }

  .delivery-hero,
  .hero-copy { min-height: 560px; }
  .hero-photo { inset: 0; opacity: .55; }
  .hero-photo::after { background: linear-gradient(90deg, rgb(23 19 17 / 90%), rgb(23 19 17 / 25%)), linear-gradient(0deg, rgb(23 19 17 / 80%), transparent 55%); }
  .hero-copy { justify-content: end; padding-block: 70px 55px; }
  .hero-copy > p:not(.hero-location) { color: #fff; }

  .terms-inner { display: block; padding-block: 28px; }
  .terms h2 { margin-bottom: 20px; }
  .terms-inner > p { margin-top: 18px; }

  .catalog-layout { display: block; }
  .cart-trigger { display: none; }
  .cart {
    position: fixed;
    z-index: var(--z-cart);
    top: 0;
    right: 0;
    bottom: 0;
    width: min(100%, 520px);
    border-radius: 0;
    visibility: hidden;
    transform: translateX(102%);
    transition: transform 220ms var(--ease), visibility 220ms;
  }
  .cart.is-open { visibility: visible; transform: none; }
  .cart-header { min-height: 72px; padding-top: max(12px, env(safe-area-inset-top)); }
  .cart-close { visibility: visible; }
  .cart-scroll { height: calc(100dvh - 72px); max-height: none; padding-bottom: max(22px, env(safe-area-inset-bottom)); }
  .cart-backdrop { position: fixed; z-index: var(--z-backdrop); inset: 0; border: 0; background: rgb(0 0 0 / 64%); }
  .cart-backdrop.is-visible { display: block; }
  .mobile-cart {
    position: fixed;
    z-index: 35;
    right: 14px;
    bottom: max(14px, env(safe-area-inset-bottom));
    left: 14px;
    min-height: 58px;
    align-items: center;
    justify-content: space-between;
    border: 0;
    border-radius: 999px;
    padding: 0 20px;
    background: var(--wine);
    box-shadow: 0 8px 24px rgb(33 26 23 / 28%);
    color: #fff;
    font-weight: 800;
  }
  .mobile-cart.is-visible { display: flex; }
  .site-footer { padding-bottom: 90px; }
}

@media (max-width: 640px) {
  .wordmark { font-size: 21px; }
  .delivery-hero,
  .hero-copy { min-height: 520px; }
  h1 { font-size: clamp(42px, 13vw, 62px); }
  .hero-copy > p:not(.hero-location) { font-size: 16px; }
  .terms dl { display: block; }
  .terms dl > div { display: flex; min-height: 55px; align-items: center; justify-content: space-between; gap: 16px; border-inline-start: 0; border-bottom: 1px solid var(--line); padding: 10px 0; }
  .terms dd { margin: 0; font-size: 17px; }
  .catalog-heading { display: block; }
  .catalog-heading h2 { font-size: 40px; }
  .catalog-tabs { display: flex; }
  .catalog-tabs button { min-width: 0; flex: 1; }
  .category-toggle strong { font-size: 17px; }
  .category-count { margin-right: 6px; }
  .category-content { padding-bottom: 24px; }
  .food-grid { gap: 12px; }
  .food-card { display: block; }
  .food-photo { aspect-ratio: 1; }
  .food-body { min-height: 142px; padding: 15px; }
  .menu-row,
  .drink-card { gap: 10px; grid-template-columns: minmax(0, 1fr) auto; padding-block: 10px; }
  .menu-row .price,
  .drink-card .price { align-self: end; grid-column: 1; grid-row: 2; }
  .menu-row .add-button,
  .menu-row .quantity,
  .drink-card .add-button,
  .drink-card .quantity { grid-column: 2; grid-row: 1 / 3; }
  .site-footer .shell { align-items: flex-start; flex-direction: column; gap: 8px; padding-block: 30px; }
  .site-footer p { margin: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
