/* ==========================================================================
   The Host — design system
   Palette: espresso chrome, saffron as the single bold accent, herb green
   for vegetarian/trust signals, chili for offers. Boldness is spent on the
   food imagery and the primary action; everything else stays quiet.
   ========================================================================== */

:root {
    /* Surface */
    --paper: #fbf9f6;
    --surface: #ffffff;
    --surface-sunk: #f4f0ea;
    --espresso: #16130f;
    --espresso-soft: #241f1a;
    --espresso-line: #3a322a;

    /* Ink */
    --ink: #1c1814;
    --ink-muted: #6b6157;
    --ink-faint: #9a9088;
    --ink-invert: #fdfbf8;

    /* Accents */
    --saffron: #e39a0c;
    --saffron-deep: #c07f00;
    --saffron-wash: #fdf3dd;
    --herb: #16603f;
    --herb-wash: #e6f2ec;
    --chili: #b3261e;
    --chili-wash: #fdecea;

    /* Lines */
    --line: #e7e1d8;
    --line-strong: #d5cbbd;

    /* Radii — larger on media, tighter on controls */
    --r-sm: 6px;
    --r-md: 10px;
    --r-lg: 16px;
    --r-xl: 24px;
    --r-pill: 999px;

    /* Elevation — one shadow, used sparingly */
    --lift: 0 1px 2px rgba(22, 19, 15, .06), 0 8px 24px rgba(22, 19, 15, .06);
    --lift-sm: 0 1px 2px rgba(22, 19, 15, .08);

    --wrap: 1200px;
    --gutter: 20px;
}

/* --------------------------------------------------------------- Reset */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

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

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

h1, h2, h3, h4 {
    font-family: Fraunces, Georgia, "Times New Roman", serif;
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -.015em;
    margin: 0 0 .5em;
    color: var(--ink);
}

h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.65rem, 3.4vw, 2.4rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.4rem); }
h4 { font-size: 1.05rem; }

p { margin: 0 0 1em; max-width: 68ch; }

:focus-visible {
    outline: 3px solid var(--saffron);
    outline-offset: 2px;
    border-radius: 3px;
}

.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 999;
    background: var(--espresso); color: var(--ink-invert);
    padding: 12px 20px; border-radius: 0 0 var(--r-md) 0;
}
.skip-link:focus { left: 0; }

.visually-hidden {
    position: absolute !important; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* -------------------------------------------------------------- Layout */

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.wrap--narrow { max-width: 780px; }
.wrap--wide { max-width: 1400px; }

.section { padding-block: clamp(48px, 7vw, 88px); }
.section--tight { padding-block: clamp(32px, 4vw, 52px); }
.section--dark { background: var(--espresso); color: var(--ink-invert); }
.section--dark h1, .section--dark h2, .section--dark h3 { color: var(--ink-invert); }
.section--sunk { background: var(--surface-sunk); }

.stack > * + * { margin-top: 1rem; }
.grid { display: grid; gap: 24px; }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }

.row { display: flex; gap: 12px; align-items: center; }
.row--between { justify-content: space-between; }
.row--wrap { flex-wrap: wrap; }
.push { margin-left: auto; }

/* Section heading: a rule that carries the eye across, not a decorative eyebrow */
.section-head {
    display: flex; align-items: flex-end; justify-content: space-between;
    gap: 24px; margin-bottom: 32px; flex-wrap: wrap;
}
.section-head h2 { margin: 0; }
.section-head p { margin: .35em 0 0; color: var(--ink-muted); max-width: 52ch; }

/* --------------------------------------------------------------- Header */

.masthead {
    position: sticky; top: 0; z-index: 60;
    background: var(--espresso);
    color: var(--ink-invert);
    border-bottom: 1px solid var(--espresso-line);
}

.masthead__strip {
    background: var(--espresso-soft);
    font-size: .8rem;
    color: #c9beb0;
    border-bottom: 1px solid var(--espresso-line);
}
.masthead__strip .wrap {
    display: flex; justify-content: space-between; align-items: center;
    gap: 16px; min-height: 38px; flex-wrap: wrap;
}
.masthead__strip a:hover { color: var(--saffron); }

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

.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand__mark {
    width: 38px; height: 38px; border-radius: 50%;
    background: var(--saffron); color: var(--espresso);
    display: grid; place-items: center;
    font-family: Fraunces, serif; font-weight: 700; font-size: 1.15rem;
}
/* Image logos are cropped to the same circle as the lettermark, so swapping
   one for the other never shifts the header layout. */
.brand__mark--img {
    object-fit: cover;
    background: var(--espresso-soft);
    padding: 0;
    display: block;
    flex-shrink: 0;
}

.brand__name {
    font-family: Fraunces, serif; font-size: 1.5rem; font-weight: 600;
    color: var(--ink-invert); letter-spacing: -.02em; line-height: 1;
}
.brand__name span { color: var(--saffron); }

.nav { display: flex; gap: 4px; align-items: center; }
.nav a {
    padding: 9px 14px; border-radius: var(--r-pill);
    color: #ddd3c6; font-size: .94rem; font-weight: 500;
    transition: background .15s, color .15s;
}
.nav a:hover { background: var(--espresso-soft); color: var(--ink-invert); }
.nav a.is-active { color: var(--saffron); background: rgba(227, 154, 12, .12); }

.masthead__tools { display: flex; align-items: center; gap: 8px; margin-left: auto; }

.icon-btn {
    width: 42px; height: 42px; border-radius: 50%;
    border: 1px solid var(--espresso-line); background: transparent;
    color: var(--ink-invert); display: grid; place-items: center;
    position: relative; transition: background .15s, border-color .15s;
}
.icon-btn:hover { background: var(--espresso-soft); border-color: var(--saffron); }

.cart-count {
    position: absolute; top: -4px; right: -4px;
    min-width: 20px; height: 20px; padding: 0 5px;
    border-radius: var(--r-pill);
    background: var(--saffron); color: var(--espresso);
    font-size: .72rem; font-weight: 700;
    display: grid; place-items: center;
    border: 2px solid var(--espresso);
}
.cart-count[hidden] { display: none; }

.burger { display: none; }

/* Search overlay */
.searchbox { position: relative; flex: 1; max-width: 340px; }
.searchbox input {
    width: 100%; height: 42px; padding: 0 16px 0 40px;
    border-radius: var(--r-pill);
    border: 1px solid var(--espresso-line);
    background: var(--espresso-soft); color: var(--ink-invert);
    font-size: .92rem;
}
.searchbox input::placeholder { color: #8d8278; }
.searchbox input:focus { border-color: var(--saffron); background: #2c2620; }
.searchbox__icon {
    position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
    color: #8d8278; pointer-events: none;
}

.suggest {
    position: absolute; top: calc(100% + 8px); left: 0; right: 0;
    background: var(--surface); color: var(--ink);
    border-radius: var(--r-md); box-shadow: var(--lift);
    overflow: hidden; z-index: 80; max-height: 380px; overflow-y: auto;
}
.suggest:empty { display: none; }
.suggest a {
    display: flex; gap: 12px; align-items: center;
    padding: 10px 14px; border-bottom: 1px solid var(--line);
}
.suggest a:last-child { border-bottom: 0; }
.suggest a:hover { background: var(--saffron-wash); }
.suggest img { width: 44px; height: 44px; border-radius: var(--r-sm); object-fit: cover; }
.suggest strong { display: block; font-size: .92rem; font-weight: 600; }
.suggest small { color: var(--ink-muted); font-size: .8rem; }

/* Mobile drawer */
.drawer {
    position: fixed; inset: 0; z-index: 90;
    background: rgba(22, 19, 15, .55);
    opacity: 0; pointer-events: none; transition: opacity .2s;
}
.drawer.is-open { opacity: 1; pointer-events: auto; }
.drawer__panel {
    position: absolute; top: 0; right: 0; bottom: 0; width: min(320px, 86vw);
    background: var(--espresso); color: var(--ink-invert);
    padding: 24px; overflow-y: auto;
    transform: translateX(100%); transition: transform .25s ease;
    display: flex; flex-direction: column; gap: 6px;
}
.drawer.is-open .drawer__panel { transform: none; }
.drawer__panel a {
    padding: 13px 14px; border-radius: var(--r-md);
    color: #ddd3c6; font-weight: 500;
}
.drawer__panel a:hover, .drawer__panel a.is-active {
    background: var(--espresso-soft); color: var(--saffron);
}
.drawer__close {
    align-self: flex-end; background: none; border: 0;
    color: var(--ink-invert); font-size: 1.6rem; line-height: 1;
    padding: 4px 8px; margin-bottom: 8px;
}

/* -------------------------------------------------------------- Buttons */

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 13px 24px; border-radius: var(--r-pill);
    border: 1px solid transparent; background: var(--saffron); color: var(--espresso);
    font-weight: 600; font-size: .95rem; line-height: 1;
    transition: background .15s, transform .12s, box-shadow .15s;
    text-align: center;
}
.btn:hover { background: var(--saffron-deep); }
.btn:active { transform: translateY(1px); }

.btn--ghost { background: transparent; border-color: var(--line-strong); color: var(--ink); }
.btn--ghost:hover { background: var(--surface); border-color: var(--ink); }

.btn--dark { background: var(--espresso); color: var(--ink-invert); }
.btn--dark:hover { background: var(--espresso-soft); }

.btn--light { background: var(--surface); color: var(--ink); }
.btn--light:hover { background: var(--surface-sunk); }

.btn--outline-light { background: transparent; border-color: rgba(253,251,248,.35); color: var(--ink-invert); }
.btn--outline-light:hover { background: rgba(253,251,248,.12); border-color: var(--ink-invert); }

.btn--danger { background: var(--chili); color: #fff; }
.btn--danger:hover { background: #96201a; }

.btn--sm { padding: 9px 16px; font-size: .86rem; }
.btn--lg { padding: 16px 32px; font-size: 1.02rem; }
.btn--block { width: 100%; }
.btn[disabled], .btn.is-disabled {
    opacity: .5; pointer-events: none;
}

.linky { color: var(--saffron-deep); font-weight: 600; border-bottom: 1px solid currentColor; }
.linky:hover { color: var(--ink); }

/* --------------------------------------------------------------- Badges */

.badge {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 4px 10px; border-radius: var(--r-pill);
    font-size: .74rem; font-weight: 600; letter-spacing: .01em;
    background: var(--surface-sunk); color: var(--ink-muted);
    white-space: nowrap;
}
.badge--saffron { background: var(--saffron-wash); color: var(--saffron-deep); }
.badge--herb { background: var(--herb-wash); color: var(--herb); }
.badge--chili { background: var(--chili-wash); color: var(--chili); }
.badge--slate { background: #eceaf0; color: #4d4a57; }
.badge--blue { background: #e6effb; color: #1c4e8a; }
.badge--amber { background: var(--saffron-wash); color: var(--saffron-deep); }
.badge--violet { background: #efe9fa; color: #5b3fa3; }
.badge--indigo { background: #e8eafc; color: #3a3f9e; }
.badge--green { background: var(--herb-wash); color: var(--herb); }
.badge--red { background: var(--chili-wash); color: var(--chili); }

.badge--float {
    position: absolute; top: 12px; left: 12px; z-index: 2;
    background: var(--espresso); color: var(--ink-invert);
    box-shadow: var(--lift-sm);
}
.badge--offer { background: var(--chili); color: #fff; }

/* ----------------------------------------------------------------- Hero */

.hero {
    position: relative;
    min-height: min(78vh, 640px);
    display: flex; align-items: center;
    background: var(--espresso);
    color: var(--ink-invert);
    overflow: hidden;
}
.hero__media { position: absolute; inset: 0; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; opacity: .5; }
.hero__media::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(105deg, rgba(22,19,15,.94) 8%, rgba(22,19,15,.72) 46%, rgba(22,19,15,.35) 100%);
}
.hero__inner { position: relative; z-index: 2; padding-block: 72px; }
.hero__content { max-width: 620px; }
.hero h1 { color: var(--ink-invert); margin-bottom: .35em; }
.hero h1 em { font-style: normal; color: var(--saffron); }
.hero__lead { font-size: clamp(1rem, 1.7vw, 1.15rem); color: #ddd3c6; max-width: 46ch; }
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 32px; }

.hero__facts {
    display: flex; gap: 32px; flex-wrap: wrap;
    margin-top: 44px; padding-top: 28px;
    border-top: 1px solid rgba(253,251,248,.16);
}
.hero__fact strong {
    display: block; font-family: Fraunces, serif;
    font-size: 1.5rem; color: var(--saffron); line-height: 1.1;
}
.hero__fact span { font-size: .84rem; color: #b8ada0; }

.open-pill {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 16px; border-radius: var(--r-pill);
    background: rgba(253,251,248,.1); border: 1px solid rgba(253,251,248,.2);
    font-size: .84rem; font-weight: 500; margin-bottom: 24px;
}
.open-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: #47b881; }
.open-pill.is-closed .dot { background: var(--chili); }

/* ------------------------------------------------------------ Food card */

.food-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    overflow: hidden;
    display: flex; flex-direction: column;
    transition: box-shadow .18s, border-color .18s;
    position: relative;
}
.food-card:hover { box-shadow: var(--lift); border-color: var(--line-strong); }

.food-card__media { position: relative; aspect-ratio: 4 / 3; background: var(--surface-sunk); overflow: hidden; }
.food-card__media img { width: 100%; height: 100%; object-fit: cover; }

.food-card__body { padding: 16px 18px 18px; display: flex; flex-direction: column; flex: 1; gap: 8px; }
.food-card__cat { font-size: .76rem; color: var(--ink-faint); font-weight: 600; }
.food-card__name {
    font-family: Fraunces, serif; font-size: 1.12rem; font-weight: 600;
    line-height: 1.25; margin: 0;
}
.food-card__name a:hover { color: var(--saffron-deep); }
.food-card__desc {
    font-size: .87rem; color: var(--ink-muted); margin: 0;
    display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2;
    -webkit-box-orient: vertical; overflow: hidden;
}
.food-card__meta { display: flex; gap: 6px; flex-wrap: wrap; }
.food-card__foot {
    display: flex; align-items: center; justify-content: space-between;
    gap: 12px; margin-top: auto; padding-top: 10px;
}

.price { display: flex; align-items: baseline; gap: 7px; }
.price strong { font-size: 1.12rem; font-weight: 700; letter-spacing: -.01em; }
.price del { font-size: .85rem; color: var(--ink-faint); }

.stars { display: inline-flex; align-items: center; gap: 3px; font-size: .8rem; color: var(--ink-muted); }
.stars svg { color: var(--saffron); }

.sold-out {
    position: absolute; inset: 0; z-index: 3;
    background: rgba(251,249,246,.86);
    display: grid; place-items: center;
    backdrop-filter: blur(1px);
}
.sold-out span {
    background: var(--espresso); color: var(--ink-invert);
    padding: 9px 18px; border-radius: var(--r-pill);
    font-size: .82rem; font-weight: 600;
}

/* ------------------------------------------------------- Category cards */

.cat-rail { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }

.cat-card {
    position: relative; display: block;
    border-radius: var(--r-lg); overflow: hidden;
    background: var(--espresso); aspect-ratio: 3 / 4;
    min-height: 200px;
}
.cat-card img {
    width: 100%; height: 100%; object-fit: cover;
    opacity: .72; transition: transform .35s, opacity .2s;
}
.cat-card:hover img { transform: scale(1.05); opacity: .85; }
.cat-card__label {
    position: absolute; inset: auto 0 0 0; z-index: 2;
    padding: 20px 16px 16px;
    background: linear-gradient(to top, rgba(22,19,15,.92), transparent);
    color: var(--ink-invert);
}
.cat-card__label strong {
    display: block; font-family: Fraunces, serif;
    font-size: 1.08rem; font-weight: 600; line-height: 1.2;
}
.cat-card__label span { font-size: .78rem; color: #c9beb0; }

/* ------------------------------------------------------------- Offers */

.offer-card {
    position: relative; overflow: hidden;
    border-radius: var(--r-lg);
    background: var(--espresso); color: var(--ink-invert);
    padding: 28px; display: flex; flex-direction: column; gap: 10px;
    min-height: 200px;
}
.offer-card--saffron { background: var(--saffron); color: var(--espresso); }
.offer-card--herb { background: var(--herb); }
.offer-card--chili { background: var(--chili); }
.offer-card h3 { color: inherit; margin: 0; }
.offer-card p { margin: 0; opacity: .9; font-size: .92rem; }
.offer-card__value {
    font-family: Fraunces, serif; font-size: 2.4rem; font-weight: 700;
    line-height: 1; letter-spacing: -.02em;
}
.offer-card__code {
    display: inline-flex; align-items: center; gap: 8px;
    align-self: flex-start; margin-top: auto;
    padding: 8px 16px; border-radius: var(--r-sm);
    border: 1px dashed currentColor;
    font-weight: 700; letter-spacing: .08em; font-size: .86rem;
}

/* ---------------------------------------------------------------- Cards */

.card {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--r-lg); padding: 24px;
}
.card--flush { padding: 0; overflow: hidden; }
.card__head {
    padding: 18px 24px; border-bottom: 1px solid var(--line);
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.card__head h3 { margin: 0; font-size: 1.05rem; }
.card__body { padding: 24px; }

.panel {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--r-lg); overflow: hidden;
}

/* ---------------------------------------------------------------- Forms */

.field { margin-bottom: 18px; }
.field > label, .label {
    display: block; margin-bottom: 7px;
    font-size: .86rem; font-weight: 600; color: var(--ink);
}
.field__hint { font-size: .8rem; color: var(--ink-muted); margin-top: 6px; }

.input, .select, .textarea {
    width: 100%; padding: 12px 14px;
    border: 1px solid var(--line-strong); border-radius: var(--r-md);
    background: var(--surface); color: var(--ink);
    font-family: inherit; font-size: .95rem;
    transition: border-color .15s, box-shadow .15s;
}
.input:focus, .select:focus, .textarea:focus {
    outline: none; border-color: var(--saffron);
    box-shadow: 0 0 0 3px rgba(227,154,12,.18);
}
.input[aria-invalid="true"], .is-invalid { border-color: var(--chili); }
.textarea { min-height: 110px; resize: vertical; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236b6157' d='M1 1l5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; }

.error { color: var(--chili); font-size: .82rem; margin-top: 6px; }

.check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: .92rem; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--saffron); flex-shrink: 0; }

/* Selectable tiles (add-ons, addresses, payment methods) */
.choice {
    display: flex; gap: 12px; align-items: flex-start;
    padding: 14px 16px; border: 1px solid var(--line-strong);
    border-radius: var(--r-md); cursor: pointer;
    transition: border-color .15s, background .15s;
    background: var(--surface);
}
.choice:hover { border-color: var(--ink-faint); }
.choice input { margin-top: 3px; accent-color: var(--saffron); width: 18px; height: 18px; flex-shrink: 0; }
.choice:has(input:checked) { border-color: var(--saffron); background: var(--saffron-wash); }
.choice strong { display: block; font-size: .94rem; }
.choice small { color: var(--ink-muted); font-size: .84rem; }

.chip-row { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 15px; border-radius: var(--r-pill);
    border: 1px solid var(--line-strong); background: var(--surface);
    font-size: .87rem; font-weight: 500; color: var(--ink);
    transition: all .15s; cursor: pointer;
}
.chip:hover { border-color: var(--ink-faint); }
.chip.is-active { background: var(--espresso); border-color: var(--espresso); color: var(--ink-invert); }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip:has(input:checked) { background: var(--espresso); border-color: var(--espresso); color: var(--ink-invert); }

/* Quantity stepper */
.qty {
    display: inline-flex; align-items: center;
    border: 1px solid var(--line-strong); border-radius: var(--r-pill);
    overflow: hidden; background: var(--surface);
}
.qty button {
    width: 38px; height: 38px; border: 0; background: transparent;
    font-size: 1.15rem; color: var(--ink); line-height: 1;
    display: grid; place-items: center;
}
.qty button:hover { background: var(--surface-sunk); }
.qty input {
    width: 46px; height: 38px; border: 0; text-align: center;
    font-weight: 600; font-size: .95rem; background: transparent;
    -moz-appearance: textfield;
}
.qty input::-webkit-outer-spin-button,
.qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* --------------------------------------------------------------- Alerts */

.alert {
    display: flex; gap: 12px; align-items: flex-start;
    padding: 14px 18px; border-radius: var(--r-md);
    border: 1px solid; margin-bottom: 20px; font-size: .92rem;
}
.alert--success { background: var(--herb-wash); border-color: #b9dbc9; color: #0e4a30; }
.alert--error { background: var(--chili-wash); border-color: #f2c4c0; color: #8b1c16; }
.alert--info { background: var(--saffron-wash); border-color: #f0dcae; color: #7a5200; }
.alert p:last-child { margin-bottom: 0; }

.toast-host {
    position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
    z-index: 200; display: flex; flex-direction: column; gap: 8px;
    width: min(420px, calc(100vw - 32px));
}
.toast {
    background: var(--espresso); color: var(--ink-invert);
    padding: 13px 18px; border-radius: var(--r-md);
    box-shadow: var(--lift); font-size: .9rem;
    display: flex; gap: 10px; align-items: center;
}
.toast--error { background: var(--chili); }

/* ---------------------------------------------------------------- Table */

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.table { width: 100%; border-collapse: collapse; font-size: .91rem; }
.table th {
    text-align: left; padding: 12px 16px;
    font-size: .78rem; font-weight: 700; color: var(--ink-muted);
    border-bottom: 1px solid var(--line-strong);
    white-space: nowrap;
}
.table td { padding: 14px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: var(--paper); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }

/* ----------------------------------------------------------- Cart/totals */

.totals { display: flex; flex-direction: column; gap: 10px; }
.totals__row {
    display: flex; justify-content: space-between; gap: 16px;
    font-size: .93rem; color: var(--ink-muted);
}
.totals__row strong { color: var(--ink); font-weight: 600; }
.totals__row--discount { color: var(--herb); }
.totals__row--discount strong { color: var(--herb); }
.totals__grand {
    display: flex; justify-content: space-between; align-items: baseline;
    padding-top: 14px; margin-top: 4px; border-top: 1px solid var(--line-strong);
    font-family: Fraunces, serif; font-size: 1.25rem; font-weight: 700;
}

.nudge {
    display: flex; gap: 10px; align-items: center;
    padding: 12px 16px; border-radius: var(--r-md);
    background: var(--saffron-wash); border: 1px dashed var(--saffron);
    color: #7a5200; font-size: .88rem; font-weight: 500;
}

.cart-line {
    display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; gap: 16px;
    padding: 18px 0; border-bottom: 1px solid var(--line); align-items: start;
}
.cart-line:last-child { border-bottom: 0; }
.cart-line__img { width: 92px; height: 92px; border-radius: var(--r-md); object-fit: cover; background: var(--surface-sunk); }
.cart-line__addons { font-size: .84rem; color: var(--ink-muted); margin: 4px 0 0; }
.cart-line__side { text-align: right; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }

/* ------------------------------------------------------------- Timeline */

.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before {
    content: ""; position: absolute; left: 13px; top: 12px; bottom: 12px;
    width: 2px; background: var(--line-strong);
}
.timeline li {
    position: relative; padding: 0 0 26px 44px;
    color: var(--ink-faint);
}
.timeline li:last-child { padding-bottom: 0; }
.timeline__dot {
    position: absolute; left: 4px; top: 2px;
    width: 20px; height: 20px; border-radius: 50%;
    background: var(--surface); border: 2px solid var(--line-strong);
    display: grid; place-items: center; z-index: 1;
}
.timeline li.is-done { color: var(--ink); }
.timeline li.is-done .timeline__dot { background: var(--herb); border-color: var(--herb); color: #fff; }
.timeline li.is-current .timeline__dot { background: var(--saffron); border-color: var(--saffron); }
.timeline strong { display: block; font-size: .96rem; font-weight: 600; }
.timeline small { font-size: .82rem; }

/* ---------------------------------------------------------- Empty state */

.empty { text-align: center; padding: 64px 24px; }
.empty__icon {
    width: 72px; height: 72px; margin: 0 auto 20px;
    border-radius: 50%; background: var(--surface-sunk);
    display: grid; place-items: center; color: var(--ink-faint);
}
.empty h3 { margin-bottom: .3em; }
.empty p { color: var(--ink-muted); margin-inline: auto; }

/* ------------------------------------------------------------ Pagination */

.pager { display: flex; gap: 6px; align-items: center; justify-content: center; margin-top: 32px; flex-wrap: wrap; }
.pager__pages { display: flex; gap: 4px; flex-wrap: wrap; }
.pager__link {
    min-width: 40px; height: 40px; padding: 0 12px;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--line-strong); border-radius: var(--r-md);
    background: var(--surface); font-size: .88rem; font-weight: 500;
}
.pager__link:hover { border-color: var(--ink); }
.pager__link.is-current { background: var(--espresso); border-color: var(--espresso); color: var(--ink-invert); }
.pager__link.is-disabled { opacity: .4; pointer-events: none; }
.pager__dots { padding: 0 6px; color: var(--ink-faint); }

/* --------------------------------------------------------------- Footer */

.footer { background: var(--espresso); color: #b8ada0; padding-block: 56px 0; margin-top: 64px; }
.footer h4 { color: var(--ink-invert); font-family: inherit; font-size: .82rem; font-weight: 700; margin-bottom: 16px; }
.footer a:hover { color: var(--saffron); }
.footer__grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 40px; }
.footer__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; font-size: .89rem; }
.footer__bar {
    margin-top: 44px; padding-block: 20px;
    border-top: 1px solid var(--espresso-line);
    display: flex; justify-content: space-between; gap: 16px;
    flex-wrap: wrap; font-size: .84rem;
}
.social { display: flex; gap: 10px; }
.social a {
    width: 36px; height: 36px; border-radius: 50%;
    border: 1px solid var(--espresso-line);
    display: grid; place-items: center;
}
.social a:hover { background: var(--saffron); border-color: var(--saffron); color: var(--espresso); }

/* --------------------------------------------------- Mobile bottom nav */

.tabbar {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 70;
    background: var(--surface); border-top: 1px solid var(--line);
    display: none; padding-bottom: env(safe-area-inset-bottom);
}
.tabbar a {
    flex: 1; padding: 9px 4px 8px;
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    font-size: .68rem; font-weight: 600; color: var(--ink-muted);
    position: relative;
}
.tabbar a.is-active { color: var(--saffron-deep); }
.tabbar .cart-count { top: 2px; right: 50%; margin-right: -22px; border-color: var(--surface); }

/* Sticky mobile add-to-cart */
.sticky-buy {
    position: sticky; bottom: 0; z-index: 40;
    background: var(--surface); border-top: 1px solid var(--line);
    padding: 12px var(--gutter); margin-inline: calc(var(--gutter) * -1);
    display: flex; gap: 12px; align-items: center;
}

/* ----------------------------------------------------------- Responsive */

@media (max-width: 1024px) {
    .footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 900px) {
    .nav { display: none; }
    .burger { display: grid; }
    .searchbox { max-width: none; }
    .masthead__bar { min-height: 64px; gap: 12px; }
    .hero { min-height: auto; }
    .hero__inner { padding-block: 56px; }
}

@media (max-width: 640px) {
    :root { --gutter: 16px; }
    body { padding-bottom: 62px; }
    .tabbar { display: flex; }
    .footer { margin-bottom: 62px; }
    .footer__grid { grid-template-columns: 1fr; }
    .masthead__strip { display: none; }
    .searchbox { display: none; }
    .grid--3, .grid--4 { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
    .cat-rail { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
    .cart-line { grid-template-columns: 72px 1fr; }
    .cart-line__img { width: 72px; height: 72px; }
    .cart-line__side { grid-column: 1 / -1; flex-direction: row; justify-content: space-between; align-items: center; text-align: left; }
    .section { padding-block: 40px; }
    .food-card__body { padding: 12px 14px 14px; }
    .food-card__name { font-size: 1rem; }
    .hero__facts { gap: 20px; }
}

/* ----------------------------------------------------------------- Print */

@media print {
    .masthead, .footer, .tabbar, .no-print { display: none !important; }
    body { background: #fff; padding: 0; }
    .card, .panel { border: 1px solid #ccc; box-shadow: none; }
}


/* Grid children must be allowed to shrink, or wide content overflows the page. */
.grid > *, .cat-rail > * { min-width: 0; }
img, canvas, svg, video { max-width: 100%; }

