@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

:root {
    --bg:           #FFF8F0;
    --surface:      #FFFFFF;
    --border:       #F2EDE3;
    --border-strong:#E5DFD2;
    --ink:          #1A1A1A;
    --ink-soft:     #525252;
    --ink-faint:    #A3A3A3;
    --red:          #E11D2E;
    --red-dark:     #B91626;
    --red-soft:     #FEF2F2;
    --yellow:       #FFC72C;
    --yellow-dark:  #E5B423;
    --green:        #16A34A;
    --shadow-sm:    0 1px 3px rgba(0,0,0,0.06);
    --shadow:       0 6px 20px rgba(0,0,0,0.08);
    --shadow-lg:    0 16px 50px rgba(0,0,0,0.18);
    --radius:       18px;
    --radius-sm:    12px;
    --radius-pill:  999px;
    --font:         'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font);
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    min-height: 100vh;
    min-height: 100dvh;
    /* Leave room for the floating cart bar + iOS home indicator */
    padding-bottom: calc(140px + env(safe-area-inset-bottom, 0px));
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ----------------------------------------------------------------- TOPBAR */
.topbar {
    position: sticky;
    top: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 22px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    font-size: 22px;
    color: var(--ink);
    letter-spacing: -0.02em;
}
.brand .logo { font-size: 24px; line-height: 1; }
.brand .name { color: var(--red); }

.table-chip,
#tableChip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--yellow);
    color: var(--ink);
    font-weight: 800;
    font-size: 13px;
    letter-spacing: 0.02em;
    padding: 8px 14px;
    border-radius: var(--radius-pill);
    box-shadow: 0 2px 0 rgba(0, 0, 0, 0.06);
}

/* ----------------------------------------------------------------- HERO */
.hero {
    padding: 28px 24px 18px;
    max-width: 1200px;
    margin: 0 auto;
}
.hero .greeting {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--red);
    margin-bottom: 8px;
}
.hero h1 {
    font-size: clamp(32px, 5vw, 44px);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.025em;
    margin: 0 0 6px;
    color: var(--ink);
}
.hero p {
    font-size: 16px;
    color: var(--ink-soft);
    margin: 0;
    font-weight: 500;
}
.hero .accent { color: var(--red); position: relative; }
.hero .accent::after {
    content: '';
    position: absolute;
    left: 0; right: 0; bottom: 4px;
    height: 8px;
    background: var(--yellow);
    z-index: -1;
    opacity: 0.7;
    border-radius: 4px;
}

/* ----------------------------------------------------------------- MY ORDERS (tracker) */
.my-orders {
    max-width: 1200px;
    margin: 0 auto;
    padding: 6px 22px 18px;
}
.my-orders > header {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 12px;
}
.my-orders h2 {
    font-size: 18px;
    font-weight: 900;
    color: var(--ink);
    margin: 0;
    letter-spacing: -0.01em;
}
.my-orders-count {
    font-size: 12px;
    font-weight: 700;
    color: var(--ink-faint);
}
.my-orders-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
}
.my-order {
    background: var(--surface);
    border: 1.5px solid var(--border-strong);
    border-radius: var(--radius-sm);
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    box-shadow: var(--shadow-sm);
    transition: border-color 0.2s, box-shadow 0.2s;
}
.my-order.pending   { border-color: #F59E0B; }
.my-order.preparing { border-color: #2563EB; }
.my-order.ready     { border-color: var(--green); }
.my-order.served    { border-color: #6B7280; opacity: 0.85; }
.my-order.cancelled { border-color: var(--red); opacity: 0.78; }
.my-order .mo-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.my-order .mo-id {
    font-weight: 900;
    font-size: 16px;
    color: var(--ink);
    letter-spacing: -0.01em;
}
.my-order .mo-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
}
.my-order.pending   .mo-status { background: #FEF3C7; color: #92400E; }
.my-order.preparing .mo-status { background: #DBEAFE; color: #1E40AF; }
.my-order.ready     .mo-status { background: #D1FAE5; color: #065F46; }
.my-order.served    .mo-status { background: #E5E7EB; color: #374151; }
.my-order.cancelled .mo-status { background: var(--red-soft); color: var(--red); }
.my-order .mo-items {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink-soft);
    line-height: 1.4;
}
.my-order .mo-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border-top: 1px dashed var(--border-strong);
    padding-top: 8px;
}
.my-order .mo-meta {
    font-size: 11px;
    font-weight: 700;
    color: var(--ink-faint);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.my-order .mo-total {
    font-weight: 900;
    font-size: 15px;
    color: var(--ink);
    font-variant-numeric: tabular-nums;
}
.my-order .mo-cancel {
    background: var(--surface);
    border: 1.5px solid var(--red);
    color: var(--red);
    padding: 8px 14px;
    border-radius: var(--radius-pill);
    font-family: inherit;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
.my-order .mo-cancel:hover { background: var(--red); color: #FFF; }
.my-order .mo-cancel:disabled { opacity: 0.5; cursor: not-allowed; }
.my-order .mo-status-hint {
    font-size: 11px;
    font-weight: 700;
    color: var(--ink-faint);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
@media (max-width: 520px) {
    .my-orders { padding: 4px 18px 14px; }
    .my-orders-list { grid-template-columns: 1fr; }
}

/* ----------------------------------------------------------------- CATEGORY NAV */
.categories {
    position: sticky;
    top: 64px;
    z-index: 20;
    display: flex;
    gap: 10px;
    padding: 14px 22px;
    overflow-x: auto;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    scrollbar-width: none;
}
.categories::-webkit-scrollbar { display: none; }
.cat-pill {
    flex: 0 0 auto;
    padding: 11px 22px;
    border-radius: var(--radius-pill);
    background: var(--surface);
    color: var(--ink);
    border: 2px solid var(--border-strong);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
    font-family: inherit;
}
.cat-pill:hover { border-color: var(--ink); }
.cat-pill.active {
    background: var(--red);
    color: #FFF;
    border-color: var(--red);
    box-shadow: 0 4px 14px rgba(225, 29, 46, 0.35);
}

/* ----------------------------------------------------------------- MENU */
.menu {
    max-width: 1200px;
    margin: 0 auto;
    padding: 8px 22px 24px;
}
.loading {
    padding: 80px 0;
    text-align: center;
    color: var(--ink-faint);
    font-weight: 600;
}
.category-block { margin-bottom: 44px; }
.category-head {
    margin: 28px 0 18px;
    display: flex;
    align-items: baseline;
    gap: 14px;
}
.category-head h2 {
    font-size: clamp(24px, 3.6vw, 32px);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    margin: 0;
    color: var(--ink);
    line-height: 1;
}
.category-head .count { font-size: 13px; font-weight: 700; color: var(--ink-faint); }
.category-head .stripe { flex: 1; height: 4px; background: var(--red); border-radius: 2px; }

/* ----------------------------------------------------------------- ITEM CARDS */
.item-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 18px;
}
.item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    cursor: pointer;
    text-align: left;
    width: 100%;
    padding: 0;
    border-color: var(--border);
    font: inherit;
    color: inherit;
}
.item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}
.item:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }
.item img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    background: var(--border);
    display: block;
}
.item-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--yellow);
    color: var(--ink);
    padding: 6px 11px;
    border-radius: var(--radius-pill);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    z-index: 2;
}
.item-badge.hot { background: var(--red); color: #FFF; }
.item-in-cart {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--green);
    color: #FFF;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 13px;
    font-weight: 900;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.18);
    z-index: 2;
}
.item-body {
    padding: 14px 16px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}
.item-name {
    font-weight: 800;
    font-size: 17px;
    line-height: 1.25;
    color: var(--ink);
    letter-spacing: -0.01em;
}
.item-desc {
    font-size: 13px;
    color: var(--ink-soft);
    line-height: 1.45;
    font-weight: 500;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}
.item-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
    gap: 8px;
}
.item-price {
    font-weight: 900;
    font-size: 20px;
    color: var(--ink);
    letter-spacing: -0.01em;
}
.item-cta { display: block; padding: 0; pointer-events: none; }
.add-btn {
    width: 100%;
    background: var(--red);
    color: #FFF;
    border: none;
    padding: 14px 16px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 0;
}
.item:hover .add-btn { background: var(--red-dark); }

/* ----------------------------------------------------------------- CART FAB */
.cart-fab {
    position: fixed;
    bottom: 18px;
    left: 18px;
    right: 18px;
    max-width: 760px;
    margin: 0 auto;
    background: var(--ink);
    color: #FFF;
    border: none;
    border-radius: var(--radius-pill);
    padding: 18px 26px;
    font-family: inherit;
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 25;
    transition: transform 0.25s ease, background 0.2s ease;
    animation: barIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.cart-fab:hover { background: var(--red); }
.cart-fab #cartCount {
    background: var(--yellow);
    color: var(--ink);
    font-weight: 900;
    font-size: 14px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex: 0 0 28px;
}
.cart-fab.pulse #cartCount { animation: pulse 0.4s ease; }
@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50%      { transform: scale(1.3); }
}
@keyframes barIn {
    from { transform: translateY(120%); }
    to   { transform: translateY(0); }
}
.cart-fab .cart-label { flex: 1; text-align: left; font-size: 15px; letter-spacing: 0.02em; }
.cart-fab #cartTotal { font-weight: 900; font-size: 18px; letter-spacing: -0.01em; }
.cart-fab .arrow {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--red);
    color: #FFF;
    display: grid;
    place-items: center;
    font-size: 16px;
    font-weight: 900;
    flex: 0 0 28px;
}

/* ----------------------------------------------------------------- SHEET (base) */
.sheet-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(26, 26, 26, 0.55);
    backdrop-filter: blur(4px);
    z-index: 50;
}
.sheet {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 620px;
    max-height: 92vh;
    max-height: 92dvh;
    background: var(--surface);
    border-radius: 24px 24px 0 0;
    z-index: 60;
    display: flex;
    flex-direction: column;
    box-shadow: 0 -16px 50px rgba(0, 0, 0, 0.25);
    animation: rise 0.32s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
    padding-bottom: env(safe-area-inset-bottom, 0px);
}
@keyframes rise {
    from { transform: translate(-50%, 100%); }
    to   { transform: translate(-50%, 0); }
}
[hidden] { display: none !important; }

.sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 22px 16px;
    border-bottom: 1px solid var(--border);
}
.sheet-header h2 {
    font-size: 22px;
    font-weight: 900;
    margin: 0;
    color: var(--ink);
    letter-spacing: -0.02em;
}
.icon-btn {
    background: var(--bg);
    color: var(--ink);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-family: inherit;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: background 0.2s;
}
.icon-btn:hover { background: var(--border); }

.sheet-body { padding: 16px 22px; overflow-y: auto; flex: 1 1 auto; min-height: 0; }
.sheet-footer {
    padding: 16px 22px 22px;
    border-top: 1px solid var(--border);
    background: var(--surface);
    flex-shrink: 0;
}

.primary {
    width: 100%;
    background: var(--red);
    color: #FFF;
    border: none;
    padding: 18px 22px;
    border-radius: var(--radius-pill);
    font-family: inherit;
    font-size: 16px;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
    box-shadow: 0 6px 20px rgba(225, 29, 46, 0.35);
}
.primary:disabled { opacity: 0.4; cursor: not-allowed; box-shadow: none; }
.primary:hover:not(:disabled) { background: var(--red-dark); }
.primary:active:not(:disabled) { transform: scale(0.98); }
.primary.danger {
    background: var(--ink);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}
.primary.danger:hover:not(:disabled) { background: #333; }

/* ----------------------------------------------------------------- ITEM MODAL */
.item-modal { padding: 0; }
.item-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 5;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface);
    color: var(--ink);
    border: none;
    cursor: pointer;
    display: grid;
    place-items: center;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
    transition: background 0.2s;
}
.item-modal-close:hover { background: var(--bg); }
.item-modal-scroll {
    overflow-y: auto;
    flex: 1 1 auto;
    min-height: 0;
    background: var(--surface);
    -webkit-overflow-scrolling: touch;
}
.item-modal-hero {
    width: 100%;
    aspect-ratio: 16 / 9;
    max-height: 38vh;
    max-height: 38dvh;
    object-fit: cover;
    background: var(--border);
    display: block;
}
.item-modal-content { padding: 0; }
.item-modal-titlebar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
    padding: 20px 22px 6px;
}
.item-modal-titlebar h2 {
    font-size: 24px;
    font-weight: 900;
    margin: 0;
    letter-spacing: -0.02em;
    color: var(--ink);
    line-height: 1.15;
}
.item-modal-base-price {
    font-size: 20px;
    font-weight: 900;
    color: var(--ink);
    white-space: nowrap;
}
.item-modal-desc {
    padding: 0 22px 20px;
    color: var(--ink-soft);
    font-size: 14px;
    font-weight: 500;
    margin: 0;
}
.item-modal-section {
    padding: 18px 22px;
    border-top: 8px solid var(--bg);
}
.item-modal-section:first-of-type { border-top: 1px solid var(--border); }
.modal-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 4px;
}
.modal-section-head h3 {
    margin: 0;
    font-size: 17px;
    font-weight: 800;
    color: var(--ink);
    letter-spacing: -0.01em;
}
.opt-tag {
    background: var(--bg);
    color: var(--ink-soft);
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.modal-section-desc {
    margin: 0 0 14px;
    color: var(--ink-faint);
    font-size: 13px;
    font-weight: 500;
}
.modal-notes,
.modal-select {
    width: 100%;
    background: var(--bg);
    border: 1.5px solid var(--border-strong);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    color: var(--ink);
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
    resize: vertical;
    transition: border-color 0.2s;
}
.modal-notes:focus,
.modal-select:focus { outline: none; border-color: var(--red); }
.modal-select { appearance: none; -webkit-appearance: none; padding-right: 38px; background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%231A1A1A'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 10px center; background-size: 20px; }

.addon-list,
.crosssell-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.addon-row {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 12px;
    padding: 10px 4px;
    border-bottom: 1px solid var(--border);
}
.addon-row:last-child { border-bottom: none; }
.addon-row .addon-name {
    font-weight: 600;
    font-size: 15px;
    color: var(--ink);
}
.addon-row .addon-price {
    font-weight: 700;
    font-size: 14px;
    color: var(--ink-soft);
    white-space: nowrap;
}

.addon-stepper {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.addon-stepper button {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1.5px solid var(--border-strong);
    background: var(--surface);
    color: var(--ink);
    font-family: inherit;
    font-size: 18px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.addon-stepper button:hover:not(:disabled) {
    background: var(--red);
    color: #FFF;
    border-color: var(--red);
}
.addon-stepper button:disabled { opacity: 0.35; cursor: not-allowed; }
.addon-stepper.has-qty button[data-act="dec"] {
    background: var(--ink);
    color: #FFF;
    border-color: var(--ink);
}
.addon-stepper.has-qty button[data-act="inc"] {
    background: var(--red);
    color: #FFF;
    border-color: var(--red);
}
.addon-stepper .qty-display {
    min-width: 18px;
    text-align: center;
    font-weight: 800;
    font-size: 15px;
    color: var(--ink);
}
.addon-stepper.no-qty .qty-display { display: none; }
.addon-stepper.no-qty button[data-act="dec"] { display: none; }

.crosssell-row {
    display: grid;
    grid-template-columns: 56px 1fr auto auto;
    align-items: center;
    gap: 12px;
    padding: 10px 4px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
}
.crosssell-row:last-child { border-bottom: none; }
.crosssell-row img {
    width: 56px;
    height: 56px;
    object-fit: cover;
    border-radius: 10px;
    background: var(--border);
}
.crosssell-row .crosssell-name { font-weight: 600; font-size: 14px; color: var(--ink); line-height: 1.3; }
.crosssell-row .crosssell-price { font-weight: 700; font-size: 13px; color: var(--ink-soft); white-space: nowrap; }
.crosssell-row input[type="checkbox"] {
    width: 22px;
    height: 22px;
    accent-color: var(--red);
    cursor: pointer;
}

.item-modal-footer {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px 18px;
    border-top: 1px solid var(--border);
    background: var(--surface);
    flex-shrink: 0;
}
.footer-qty {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    border: 1.5px solid var(--border-strong);
    border-radius: var(--radius-pill);
    padding: 4px;
    background: var(--surface);
    flex: 0 0 auto;
}
.footer-qty button {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface);
    color: var(--ink);
    border: none;
    font-family: inherit;
    font-size: 20px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    display: grid;
    place-items: center;
}
.footer-qty button:hover:not(:disabled) { background: var(--bg); }
.footer-qty button:disabled { color: var(--ink-faint); cursor: not-allowed; }
.footer-qty span {
    min-width: 30px;
    text-align: center;
    font-weight: 900;
    font-size: 17px;
    color: var(--ink);
}
.item-modal-add {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-transform: none;
    padding: 16px 18px;
    font-size: 15px;
    letter-spacing: 0.02em;
}
.item-modal-add .dot { opacity: 0.6; }
.item-modal-add #itemModalSubmitPrice { font-weight: 900; }

/* ----------------------------------------------------------------- CART SHEET */
.cart-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.cart-list li.cart-row {
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 14px;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: border-color 0.2s, background 0.2s;
}
.cart-list li.cart-row:hover { border-color: var(--red); }
.cart-row .cr-head {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 10px;
    align-items: baseline;
}
.cart-row .cr-qty {
    background: var(--red);
    color: #FFF;
    border-radius: 6px;
    padding: 2px 8px;
    font-size: 13px;
    font-weight: 900;
    min-width: 30px;
    text-align: center;
}
.cart-row .cr-name {
    font-size: 15px;
    font-weight: 800;
    color: var(--ink);
    line-height: 1.25;
}
.cart-row .cr-line-total {
    font-weight: 900;
    font-size: 16px;
    color: var(--ink);
}
.cart-row .cr-addons {
    list-style: none;
    margin: 6px 0 0;
    padding: 0 0 0 40px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.cart-row .cr-addons li {
    font-size: 12px;
    color: var(--ink-soft);
    font-weight: 500;
}
.cart-row .cr-addons li::before { content: '+ '; color: var(--green); font-weight: 800; }
.cart-row .cr-notes {
    margin: 6px 0 0 40px;
    color: var(--ink-soft);
    font-size: 12px;
    font-weight: 500;
    font-style: italic;
}
.cart-row .cr-edit-hint {
    margin: 8px 0 0 40px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--red);
}
.empty {
    color: var(--ink-faint);
    padding: 36px 0;
    text-align: center;
    font-weight: 600;
}

.notes {
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.notes span {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--ink-soft);
}
.notes textarea {
    width: 100%;
    background: var(--bg);
    border: 1.5px solid var(--border-strong);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    color: var(--ink);
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
    resize: vertical;
    transition: border-color 0.2s;
}
.notes textarea:focus { outline: none; border-color: var(--red); }

.totals {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-top: 22px;
    padding-top: 16px;
    border-top: 2px dashed var(--border-strong);
}
.totals > span:first-child {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ink-soft);
}
.totals strong {
    font-size: 28px;
    font-weight: 900;
    color: var(--red);
    letter-spacing: -0.02em;
    font-family: inherit;
    font-feature-settings: 'tnum';
}

/* ----------------------------------------------------------------- CONFIRM */
.confirm { padding: 44px 28px 24px; text-align: center; }
.confirm .check {
    width: 88px;
    height: 88px;
    margin: 0 auto 22px;
    background: var(--green);
    color: #FFF;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 44px;
    font-weight: 900;
    box-shadow: 0 16px 36px rgba(22, 163, 74, 0.35);
    animation: pop 0.5s cubic-bezier(0.18, 1.5, 0.5, 1);
}
@keyframes pop {
    from { transform: scale(0.5); opacity: 0; }
    to   { transform: scale(1);   opacity: 1; }
}
.confirm h2 {
    font-size: 30px;
    font-weight: 900;
    margin: 0 0 14px;
    color: var(--ink);
    letter-spacing: -0.02em;
}
.confirm p {
    margin: 6px 0;
    font-size: 15px;
    color: var(--ink-soft);
    font-weight: 500;
}
.confirm p strong { color: var(--ink); font-weight: 800; }
.muted { color: var(--ink-faint); }

/* ----------------------------------------------------------------- ERROR */
.error-banner {
    background: var(--red);
    color: #FFF;
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    margin: 14px 22px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: var(--shadow);
}

/* ----------------------------------------------------------------- ANIMATIONS */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) both; }

/* ----------------------------------------------------------------- RESPONSIVE */

/* ── Desktop ≥ 1024 ── (default styles already tuned for this) */
@media (min-width: 1024px) {
    .item-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
}

/* ── Tablet 768–1023 ── */
@media (min-width: 768px) and (max-width: 1023px) {
    .menu, .hero { padding-left: 24px; padding-right: 24px; }
    .item-grid { grid-template-columns: repeat(3, 1fr); gap: 16px; }
}

/* ── Mobile portrait ≤ 767 ── */
@media (max-width: 767px) {
    .topbar { padding: 14px 18px; }
    .brand { font-size: 20px; }
    .hero { padding: 22px 18px 14px; }
    .hero h1 { font-size: clamp(24px, 6.5vw, 32px); }
    .hero p { font-size: 14px; }
    .categories { top: 60px; padding: 12px 18px; gap: 8px; }
    .cat-pill { padding: 10px 18px; font-size: 13px; }
    .menu { padding: 4px 18px 24px; }
    .category-head h2 { font-size: clamp(20px, 5vw, 26px); }
    .item-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .item-name { font-size: 15px; }
    .item-desc { font-size: 12px; }
    .item-price { font-size: 17px; }
    .add-btn { padding: 12px; font-size: 12px; }
    .cart-fab { left: 12px; right: 12px; padding: 14px 18px; font-size: 14px; gap: 12px; }
    .cart-fab .cart-label { font-size: 13px; }
    .item-modal-titlebar { padding: 16px 18px 4px; }
    .item-modal-titlebar h2 { font-size: 20px; }
    .item-modal-base-price { font-size: 18px; }
    .item-modal-desc { padding: 0 18px 16px; font-size: 13px; }
    .item-modal-section { padding: 16px 18px; }
    .item-modal-footer { padding: 12px 14px 16px; gap: 10px; }
    .item-modal-add { padding: 14px 12px; font-size: 14px; }
    .footer-qty button { width: 36px; height: 36px; font-size: 18px; }
    .sheet-header { padding: 18px 18px 12px; }
    .sheet-header h2 { font-size: 20px; }
    .sheet-body { padding: 14px 18px; }
    .sheet-footer { padding: 14px 18px 18px; }
}

/* ── Very narrow phones ≤ 360 ── */
@media (max-width: 360px) {
    .item-grid { grid-template-columns: 1fr; }
    .hero h1 { font-size: 22px; }
    .cart-fab .cart-label { display: none; }
    .footer-qty { padding: 3px; }
    .footer-qty button { width: 34px; height: 34px; }
}

/* ── Short / landscape (e.g. phone landscape) ── */
@media (max-height: 500px) and (orientation: landscape) {
    .hero { padding: 14px 24px 8px; }
    .hero .greeting { font-size: 11px; margin-bottom: 4px; }
    .hero h1 { font-size: 22px; line-height: 1.1; margin-bottom: 2px; }
    .hero p { font-size: 13px; }
    .categories { top: 56px; padding: 10px 22px; }
    .topbar { padding: 10px 22px; }
    .brand { font-size: 18px; }
    .item-modal-hero {
        aspect-ratio: auto;
        height: 30vh;
        max-height: 30dvh;
    }
    .item-modal-titlebar { padding: 14px 22px 4px; }
    .item-modal-titlebar h2 { font-size: 20px; }
    .item-modal-section { padding: 14px 22px; }
    .item-modal-footer { padding: 12px 18px 14px; }
    .cart-fab { bottom: 12px; }
}
