/* ===========================
   RESET & BASE
   =========================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --primary:      #D32F2F;
    --primary-dark: #B71C1C;
    --primary-light:#FFCDD2;
    --secondary:    #FFC107;
    --dark:         #1A1A1A;
    --dark2:        #2C2C2C;
    --gray:         #757575;
    --gray-light:   #F5F5F5;
    --border:       #E0E0E0;
    --success:      #388E3C;
    --warning:      #F57C00;
    --white:        #FFFFFF;
    --shadow:       0 2px 8px rgba(0,0,0,.12);
    --shadow-lg:    0 8px 24px rgba(0,0,0,.16);
    --radius:       8px;
    --radius-lg:    14px;
    --transition:   .2s ease;
    --header-h:     104px;
    --nav-h:        46px;
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Roboto', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    background: var(--gray-light);
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

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

/* ===========================
   TYPOGRAPHY
   =========================== */
h1, h2, h3 { font-weight: 600; line-height: 1.3; color: var(--dark); }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1rem; }

/* ===========================
   BUTTONS
   =========================== */
.btn-primary, .btn-secondary, .btn-link, .btn-sm {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    font-family: inherit;
    font-size: .9rem;
    font-weight: 500;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
}
.btn-primary:hover { background: var(--primary-dark); text-decoration: none; }

.btn-secondary {
    background: var(--white);
    color: var(--primary);
    border: 1px solid var(--primary);
}
.btn-secondary:hover { background: var(--primary-light); text-decoration: none; }

.btn-link {
    background: transparent;
    color: var(--gray);
    padding: 6px 10px;
}
.btn-link:hover { color: var(--primary); text-decoration: none; }

.btn-sm {
    padding: 5px 10px;
    font-size: .8rem;
}
.btn-danger { background: var(--primary); color: var(--white); border: none; }

.btn-block { width: 100%; justify-content: center; }
.btn-lg { padding: 14px 24px; font-size: 1rem; }

/* ===========================
   HEADER
   =========================== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 500;
    background: #fb8713;
    color: #000;
    box-shadow: var(--shadow-lg);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    height: 60px;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #000;
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: 700;
}
.logo:hover { text-decoration: none; color: #000; }
.logo-img { height: 44px; width: auto; object-fit: contain; display: block; }
.logo-text { color: #000; font-weight: 700; }
.logo-text strong { color: #000; }

.header-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.header-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #000;
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: .85rem;
    padding: 8px 12px;
    border-radius: var(--radius);
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
}
.header-btn:hover { color: #000; background: rgba(0,0,0,.1); text-decoration: none; }
.header-btn .material-icons { font-size: 1.3rem; }

.cart-toggle { position: relative; }
.cart-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    font-size: .65rem;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Restaurant bar */
.restaurant-bar {
    background: #e0740e;
    border-top: 1px solid rgba(0,0,0,.08);
}
.restaurant-bar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 24px;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
    gap: 8px;
}
.restaurant-info {
    display: flex;
    align-items: center;
    gap: 4px;
    color: rgba(0,0,0,.75);
    font-size: .8rem;
}
.restaurant-info .material-icons { font-size: 1rem; color: #000; }
.restaurant-meta {
    display: flex;
    align-items: center;
    gap: 16px;
}
.meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
    color: rgba(0,0,0,.8);
    font-size: .82rem;
}
.meta-item .material-icons { font-size: 1rem; }

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: .78rem;
    font-weight: 600;
}
.status-badge.open   { background: rgba(0,0,0,.12); color: #000; }
.status-badge.closed { background: rgba(0,0,0,.15); color: rgba(0,0,0,.7); }

/* Status classes for orders */
.status-pending   { background: #FFF8E1; color: #F57C00; }
.status-confirmed { background: #E3F2FD; color: #1565C0; }
.status-preparing { background: #FFF3E0; color: #E65100; }
.status-delivery  { background: #E8F5E9; color: #1B5E20; }
.status-delivered { background: #E8F5E9; color: #1B5E20; }
.status-cancelled { background: #FFEBEE; color: #B71C1C; }

/* ===========================
   CART SIDEBAR
   =========================== */
.cart-overlay {
    position: fixed; inset: 0;
    background: rgba(0,0,0,.5);
    z-index: 900;
    opacity: 0; pointer-events: none;
    transition: opacity .3s;
}
.cart-overlay.active { opacity: 1; pointer-events: all; }

.cart-sidebar {
    position: fixed;
    right: 0; top: 0; bottom: 0;
    width: 360px;
    background: var(--white);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform .3s ease;
    box-shadow: -4px 0 20px rgba(0,0,0,.15);
}
.cart-sidebar.open { transform: translateX(0); }

.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    background: var(--dark);
    color: var(--white);
}
.cart-header h2 {
    display: flex; align-items: center; gap: 8px;
    font-size: 1rem; color: var(--white);
}
.cart-close {
    background: transparent; border: none; cursor: pointer;
    color: #aaa; display: flex; align-items: center;
}
.cart-close:hover { color: var(--white); }

.cart-items { flex: 1; overflow-y: auto; padding: 16px; }

.cart-empty {
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    height: 200px; color: var(--gray); gap: 8px;
}
.cart-empty .material-icons { font-size: 3rem; color: var(--border); }

.cart-item {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 0; border-bottom: 1px solid var(--border);
}
.cart-item-info { flex: 1; }
.cart-item-name { font-weight: 500; font-size: .9rem; }
.cart-item-price { font-size: .8rem; color: var(--gray); }
.cart-item-controls {
    display: flex; align-items: center; gap: 6px;
}
.cart-item-controls button {
    width: 26px; height: 26px; border: 1px solid var(--border);
    background: var(--white); border-radius: 50%;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: .9rem; transition: var(--transition);
}
.cart-item-controls button:hover { background: var(--primary); color: var(--white); border-color: var(--primary); }
.cart-item-qty { font-weight: 600; min-width: 20px; text-align: center; }

.cart-footer { padding: 16px; border-top: 1px solid var(--border); background: var(--white); }
.cart-summary { margin-bottom: 14px; }
.summary-row {
    display: flex; justify-content: space-between;
    padding: 4px 0; font-size: .88rem; color: var(--gray);
}
.total-row { font-weight: 700; font-size: 1rem; color: var(--dark); border-top: 1px solid var(--border); padding-top: 8px; margin-top: 4px; }

/* ===========================
   MAIN CONTENT
   =========================== */
.main-content { min-height: calc(100vh - var(--header-h) - var(--nav-h) - 200px); }

/* ===========================
   MENU PAGE
   =========================== */
.menu-page { width: 100%; }

/* --- Barra de categorias fixa --- */
.category-nav-wrap {
    position: fixed;
    top: 104px;                 /* fallback — JS sobrescreve com altura real do header */
    left: 0;
    right: 0;
    z-index: 200;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 8px rgba(0,0,0,.10);
}
/* Espaçador para o conteúdo não ficar atrás da barra fixa */
.category-nav-spacer {
    height: calc(var(--nav-h) + 20px);
}

.category-nav {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.category-nav::-webkit-scrollbar { display: none; }

.cat-nav-item {
    flex-shrink: 0;
    padding: 14px 18px;
    color: var(--gray);
    font-size: .82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    transition: color .2s, border-color .2s;
    white-space: nowrap;
}
.cat-nav-item:hover { color: var(--dark); text-decoration: none; }
.cat-nav-item.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    text-decoration: none;
}

/* --- Conteúdo do menu --- */
.menu-content { max-width: 1200px; margin: 0 auto; padding: 0 0 60px; }

/* --- Seção de categoria --- */
.product-section { margin-bottom: 32px; }
/* Espaço entre o banner e os produtos abaixo, e embaixo dos produtos */
.product-section > div:last-child { padding-top: 20px; padding-bottom: 20px; }

.category-banner {
    position: relative;
    height: 180px;
    background: linear-gradient(135deg, var(--cat-bg, #1a0a0a) 0%, #2a1a1a 100%);
    overflow: hidden;
    display: flex;
    align-items: flex-end;
}
.category-banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        45deg,
        transparent, transparent 40px,
        rgba(255,255,255,.02) 40px,
        rgba(255,255,255,.02) 80px
    );
}
.category-banner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.7) 0%, transparent 60%);
}
.category-banner-inner {
    position: relative;
    z-index: 1;
    padding: 0 28px 22px;
}
.category-banner-inner h2 {
    color: var(--white);
    font-size: 1.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    text-shadow: 0 2px 12px rgba(0,0,0,.5);
    margin: 0;
}

/* Banner com imagem — desktop: proporção 1200×90 / mobile: altura fixa 90px */
.category-banner-img {
    position: relative;
    width: 100%;
    aspect-ratio: 1200 / 90;
    overflow: hidden;
    display: block;
    border-radius: 6px;
}
.category-banner-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.category-banner-img-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(0,0,0,.55) 0%, transparent 60%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 24px;
    gap: 2px;
}
.category-banner-img-overlay span {
    color: #fff;
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    text-shadow: 0 1px 6px rgba(0,0,0,.5);
}
.category-banner-img-overlay small {
    color: rgba(255,255,255,.8);
    font-size: .78rem;
    text-shadow: 0 1px 4px rgba(0,0,0,.5);
}

/* Descrição no banner gradiente */
.category-banner-desc {
    color: rgba(255,255,255,.75);
    font-size: .82rem;
    margin-top: 4px;
}

/* Placeholder de imagem dentro dos cards Tailwind */
.product-img-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #f0f0f0, #e0e0e0);
    color: #ccc;
}
.product-img-placeholder .material-icons { font-size: 2.2rem; }

/* ===========================
   PRODUCT MODAL
   =========================== */
.modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0,0,0,.6); z-index: 800;
    opacity: 0; pointer-events: none; transition: opacity .25s;
}
.modal-overlay.active { opacity: 1; pointer-events: all; }

.product-modal {
    position: fixed;
    left: 50%; top: 50%;
    transform: translate(-50%, -50%) scale(.95);
    background: var(--white);
    border-radius: var(--radius-lg);
    width: 90%; max-width: 480px;
    max-height: 90vh; overflow-y: auto;
    z-index: 850;
    opacity: 0; pointer-events: none;
    transition: opacity .25s, transform .25s;
}
.product-modal.active { opacity: 1; pointer-events: all; transform: translate(-50%, -50%) scale(1); }

.modal-close {
    position: absolute; top: 12px; right: 12px;
    background: rgba(0,0,0,.5); color: var(--white);
    border: none; border-radius: 50%; width: 32px; height: 32px;
    cursor: pointer; display: flex; align-items: center; justify-content: center; z-index: 1;
}
.modal-img-wrap { height: 220px; overflow: hidden; background: #f0f0f0; }
.modal-img-wrap img { width: 100%; height: 100%; object-fit: cover; }
.modal-img-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #f5f5f5, #e0e0e0); color: #bbb; }
.modal-img-placeholder .material-icons { font-size: 4rem; }

.modal-body { padding: 20px; }
.modal-body h3 { font-size: 1.1rem; margin-bottom: 8px; }
.modal-desc { color: var(--gray); font-size: .85rem; margin-bottom: 10px; line-height: 1.6; }
.modal-price { font-size: 1.1rem; font-weight: 700; color: var(--primary); margin-bottom: 16px; }

.modal-notes-label { display: block; font-size: .82rem; font-weight: 500; margin-bottom: 4px; }
.modal-notes { width: 100%; padding: 8px; border: 1px solid var(--border); border-radius: var(--radius); font-family: inherit; font-size: .85rem; resize: vertical; min-height: 60px; margin-bottom: 16px; }

.modal-qty {
    display: flex; align-items: center; justify-content: center;
    gap: 20px; margin-bottom: 16px;
}
.modal-qty button {
    width: 36px; height: 36px; border: 1px solid var(--border);
    background: var(--white); border-radius: 50%;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem; transition: var(--transition);
}
.modal-qty button:hover { background: var(--primary); color: var(--white); border-color: var(--primary); }
#modalQty { font-size: 1.2rem; font-weight: 700; min-width: 40px; text-align: center; }

.modal-add-btn { font-size: .95rem; padding: 12px; }

/* ===========================
   AUTH PAGES
   =========================== */
.auth-body { background: linear-gradient(135deg, var(--dark) 0%, var(--dark2) 100%); min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.auth-container { width: 100%; max-width: 420px; }
.auth-logo { display: flex; align-items: center; gap: 8px; color: var(--white); font-size: 1.3rem; text-decoration: none; justify-content: center; margin-bottom: 24px; }
.auth-logo:hover { text-decoration: none; color: var(--secondary); }
.auth-logo .logo-text strong { color: var(--primary); }

.auth-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow-lg);
}
.auth-title { font-size: 1.4rem; margin-bottom: 6px; text-align: center; }
.auth-subtitle { color: var(--gray); text-align: center; margin-bottom: 24px; font-size: .9rem; }

.auth-form .form-group { margin-bottom: 16px; }
.auth-form label { display: block; font-size: .85rem; font-weight: 500; margin-bottom: 6px; color: var(--dark2); }

.input-wrap { position: relative; }
.input-icon { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--gray); font-size: 1.1rem; pointer-events: none; }
.input-wrap input { padding-left: 36px; width: 100%; }

input[type=text], input[type=email], input[type=password], input[type=tel], select, textarea {
    width: 100%; padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius); font-family: inherit; font-size: .9rem;
    outline: none; transition: border-color .2s;
    background: var(--white);
}
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(211,47,47,.15); }

.auth-switch { text-align: center; margin-top: 20px; font-size: .88rem; color: var(--gray); }

/* ===========================
   CHECKOUT PAGE
   =========================== */
.checkout-page { max-width: 1100px; margin: 0 auto; padding: 24px; }
.page-title {
    display: flex; align-items: center; gap: 8px;
    font-size: 1.4rem; margin-bottom: 24px; color: var(--dark);
}

.checkout-grid { display: grid; grid-template-columns: 1fr 340px; gap: 24px; align-items: start; }

.checkout-section {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 20px; margin-bottom: 16px;
    box-shadow: var(--shadow);
}
.checkout-section h2 {
    display: flex; align-items: center; gap: 8px;
    font-size: 1rem; margin-bottom: 16px;
    padding-bottom: 10px; border-bottom: 1px solid var(--border);
}

.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: .83rem; font-weight: 500; margin-bottom: 5px; color: #555; }
.form-row { display: flex; gap: 12px; }
.form-row .form-group { flex: 1; }
.flex-2 { flex: 2 !important; }
.flex-1 { flex: 1 !important; }

.btn-location {
    width: 100%; padding: 12px;
    background: #E8F5E9; color: #1B5E20;
    border: 1px dashed #388E3C;
    border-radius: var(--radius); cursor: pointer;
    font-family: inherit; font-size: .9rem; font-weight: 500;
    display: flex; align-items: center; justify-content: center; gap: 8px;
    transition: var(--transition); margin-bottom: 14px;
}
.btn-location:hover { background: #C8E6C9; }
.btn-location.loading { opacity: .7; cursor: default; }

.location-status { font-size: .82rem; margin-bottom: 10px; min-height: 20px; }
.location-status.success { color: var(--success); }
.location-status.error   { color: var(--primary); }

.payment-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.payment-opt { display: block; }
.payment-opt input { display: none; }
.payment-label {
    display: flex; align-items: center; gap: 8px;
    padding: 12px 14px; border: 2px solid var(--border);
    border-radius: var(--radius); cursor: pointer;
    transition: var(--transition); font-size: .88rem;
}
.payment-opt input:checked + .payment-label {
    border-color: var(--primary); background: var(--primary-light);
    color: var(--primary-dark); font-weight: 500;
}
.payment-label .material-icons { font-size: 1.2rem; }

.coupon-row { display: flex; gap: 8px; }
.coupon-row input { flex: 1; font-size: .9rem; }

#couponMsg { font-size: .83rem; margin-top: 8px; min-height: 20px; }
.coupon-ok  { color: var(--success); }
.coupon-err { color: var(--primary); }

/* Order Summary card */
.order-summary-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow);
    position: sticky;
    top: 130px;
}
.order-summary-card h2 { font-size: 1rem; margin-bottom: 14px; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.summary-items { margin-bottom: 12px; }
.summary-item-row { display: flex; justify-content: space-between; font-size: .85rem; padding: 4px 0; }
.summary-divider { border: none; border-top: 1px solid var(--border); margin: 10px 0; }
.discount-row span { color: var(--success); }
.text-success { color: var(--success) !important; }

.loyalty-info {
    display: flex; align-items: center; gap: 6px;
    margin-top: 14px; padding: 10px; background: #FFF8E1;
    border-radius: var(--radius); font-size: .82rem; color: #F57C00;
}
.loyalty-info .material-icons { color: var(--secondary); }

/* ===========================
   ORDER CONFIRM
   =========================== */
.confirm-page { max-width: 700px; margin: 40px auto; padding: 0 24px 60px; }
.confirm-card { background: var(--white); border-radius: var(--radius-lg); padding: 36px; box-shadow: var(--shadow-lg); text-align: center; }
.confirm-icon { margin-bottom: 16px; }
.confirm-icon .material-icons { font-size: 5rem; color: var(--success); }
.confirm-card h1 { margin-bottom: 8px; }
.confirm-number { color: var(--gray); margin-bottom: 28px; }

/* Timeline */
.status-timeline { display: flex; align-items: center; justify-content: center; gap: 0; margin: 24px 0; flex-wrap: wrap; }
.timeline-step { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.timeline-dot {
    width: 44px; height: 44px; border-radius: 50%;
    border: 2px solid var(--border); background: var(--white);
    display: flex; align-items: center; justify-content: center;
    color: #ccc; transition: var(--transition);
}
.timeline-step.done .timeline-dot { border-color: var(--success); background: #E8F5E9; color: var(--success); }
.timeline-label { font-size: .68rem; color: var(--gray); text-align: center; max-width: 60px; }
.timeline-step.done .timeline-label { color: var(--success); font-weight: 500; }
.timeline-line { flex: 1; min-width: 20px; height: 2px; background: var(--border); }
.timeline-line.done { background: var(--success); }

.confirm-details { text-align: left; margin-top: 28px; }
.confirm-section { margin-bottom: 20px; padding: 16px; background: var(--gray-light); border-radius: var(--radius); }
.confirm-section h3 { display: flex; align-items: center; gap: 6px; font-size: .9rem; margin-bottom: 10px; }
.confirm-item { display: flex; justify-content: space-between; padding: 4px 0; font-size: .88rem; }
.confirm-row { display: flex; justify-content: space-between; padding: 3px 0; font-size: .88rem; }
.confirm-total { font-weight: 700; font-size: 1rem; border-top: 1px solid var(--border); padding-top: 8px; margin-top: 4px; }
.confirm-actions { display: flex; gap: 12px; justify-content: center; margin-top: 28px; flex-wrap: wrap; }

/* ===========================
   ORDERS PAGE
   =========================== */
.orders-page { max-width: 800px; margin: 0 auto; padding: 24px; }
.orders-list { display: flex; flex-direction: column; gap: 14px; }
.order-card { background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow); overflow: hidden; }
.order-card-header { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.order-number { font-weight: 700; font-size: .95rem; margin-right: 8px; }
.order-date { font-size: .8rem; color: var(--gray); }
.order-card-body { padding: 12px 16px; }
.order-card-row { display: flex; justify-content: space-between; font-size: .88rem; padding: 4px 0; }
.order-card-footer { padding: 10px 16px; background: var(--gray-light); }
.order-card-footer .btn-link { font-size: .85rem; padding: 4px 0; }

/* ===========================
   ALERTS
   =========================== */
.alert {
    display: flex; align-items: center; gap: 8px;
    padding: 12px 16px; border-radius: var(--radius);
    font-size: .88rem; margin-bottom: 16px;
}
.alert-error   { background: #FFEBEE; color: var(--primary-dark); border: 1px solid var(--primary-light); }
.alert-success { background: #E8F5E9; color: #1B5E20; border: 1px solid #A5D6A7; }

/* Empty state */
.empty-state { text-align: center; padding: 60px 20px; color: var(--gray); }
.empty-state .material-icons { font-size: 4rem; color: var(--border); margin-bottom: 12px; display: block; }
.empty-state p { margin-bottom: 20px; }

/* ===========================
   FOOTER
   =========================== */
.site-footer { background: #fb8713; color: rgba(0,0,0,.75); margin-top: 40px; }
.footer-inner {
    display: grid; grid-template-columns: 2fr 1fr 2fr;
    gap: 32px; padding: 40px 24px;
    max-width: 1200px; margin: 0 auto;
}
.footer-brand .logo-text { font-size: 1.1rem; display: block; margin-top: 8px; margin-bottom: 10px; color: #000; }
.footer-brand p { font-size: .85rem; color: rgba(0,0,0,.6); }
.footer-links, .footer-contact { display: flex; flex-direction: column; gap: 8px; }
.footer-links h4, .footer-contact h4 { color: #000; font-size: .9rem; margin-bottom: 4px; }
.footer-links a { color: rgba(0,0,0,.7); font-size: .85rem; transition: var(--transition); }
.footer-links a:hover { color: #000; text-decoration: none; }
.footer-contact p { display: flex; align-items: flex-start; gap: 6px; font-size: .83rem; color: rgba(0,0,0,.75); }
.footer-contact .material-icons { font-size: .95rem; margin-top: 2px; color: #000; flex-shrink: 0; }
.footer-bottom { text-align: center; padding: 14px 24px; border-top: 1px solid rgba(0,0,0,.1); font-size: .8rem; color: rgba(0,0,0,.55); }

/* ===========================
   RESPONSIVE
   =========================== */
.btn-label { display: inline; }

@media (max-width: 900px) {
    .checkout-grid { grid-template-columns: 1fr; }
    .checkout-summary-col { order: -1; }
    .order-summary-card { position: static; }
    .footer-inner { grid-template-columns: 1fr; gap: 20px; }
}

@media (max-width: 600px) {
    :root { --header-h: 110px; }
    .header-inner { padding: 0 14px; }
    .btn-label { display: none; }
    .cart-sidebar { width: 100%; }
    .payment-options { grid-template-columns: 1fr; }
    .form-row { flex-direction: column; }
    .confirm-card { padding: 20px; }
    .status-timeline { gap: 4px; }
    .checkout-page, .orders-page { padding: 14px; }
    .restaurant-bar-inner { flex-direction: column; align-items: flex-start; gap: 4px; }

    /* Menu mobile */
    .cat-nav-item { padding: 12px 14px; font-size: .75rem; }
    .category-banner { height: 130px; }
    .category-banner-inner h2 { font-size: 1.3rem; }
    .category-banner-inner { padding: 0 16px 16px; }
    /* Banner com foto: trava em 90px no mobile em vez de encolher junto com a largura */
    .category-banner-img { aspect-ratio: unset; height: 90px; }
}

/* ===========================
   MODAIS FLUXO DE ENTREGA
   =========================== */
.dlv-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.5);
    z-index: 900;
}
.dlv-overlay.active { display: block; }

.dlv-modal {
    display: none;
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    z-index: 950;
    width: 90%; max-width: 380px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 12px 48px rgba(0,0,0,.28);
    animation: dlvIn .18s ease;
}
.dlv-modal.active { display: block; }
.dlv-modal-lg { max-width: 480px; }

@keyframes dlvIn {
    from { opacity: 0; transform: translate(-50%, -47%); }
    to   { opacity: 1; transform: translate(-50%, -50%); }
}

.dlv-modal-body { padding: 30px 26px 24px; position: relative; }
.dlv-modal-x {
    position: absolute; top: 14px; right: 16px;
    background: none; border: none;
    font-size: 1.5rem; color: #aaa; cursor: pointer; line-height: 1;
}
.dlv-modal-x:hover { color: #333; }

/* Check modal */
.dlv-check-body { text-align: center; }
.dlv-check-title { font-size: 1rem; font-weight: 600; line-height: 1.55; color: #222; margin-bottom: 14px; }
.dlv-check-sub   { font-size: .83rem; color: #888; margin-bottom: 26px; line-height: 1.6; }
.dlv-check-sub span { color: var(--primary); font-weight: 600; }

/* Address form */
.dlv-addr-title { font-size: 1.15rem; font-weight: 700; color: #111; margin-bottom: 2px; }
.dlv-addr-city  { font-size: .82rem; font-weight: 700; color: #444; margin-bottom: 18px; }

.dlv-input {
    display: block; width: 100%;
    border: none; border-bottom: 1.5px solid #ddd;
    padding: 9px 0; margin-bottom: 12px;
    font-size: .8rem; font-family: inherit; color: #333;
    background: transparent; outline: none;
    letter-spacing: .05em;
}
.dlv-input::placeholder { color: #bbb; font-size: .78rem; letter-spacing: .06em; }
.dlv-input:focus { border-bottom-color: #333; }

.dlv-form-row { display: flex; gap: 12px; margin-top: 20px; }
.dlv-form-row > * { flex: 1; }

/* Auth modal */
.dlv-auth-body  { text-align: center; }
.dlv-auth-icon  { font-size: 3rem; color: #888; margin-bottom: 10px; }
.dlv-auth-title { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.dlv-auth-sub   { font-size: .82rem; color: #888; margin-bottom: 22px; line-height: 1.6; }

/* Buttons */
.dlv-btn-dark {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 13px 20px; background: #1a1a1a; color: #fff;
    border: none; border-radius: 6px;
    font-size: .78rem; font-weight: 700; letter-spacing: .08em;
    cursor: pointer; text-decoration: none;
}
.dlv-btn-dark:hover { background: #000; color: #fff; text-decoration: none; }
.dlv-btn-dark:disabled { opacity: .4; cursor: not-allowed; }

.dlv-btn-outline {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 12px 20px; background: transparent; color: #333;
    border: 1.5px solid #ddd; border-radius: 6px;
    font-size: .78rem; font-weight: 700; letter-spacing: .07em;
    cursor: pointer; text-decoration: none;
}
.dlv-btn-outline:hover { border-color: #888; color: #111; text-decoration: none; }

.dlv-btn-ghost {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 10px; background: none; border: none; color: #999;
    font-size: .78rem; font-weight: 700; letter-spacing: .07em; cursor: pointer;
}
.dlv-btn-ghost:hover { color: #333; }

.dlv-btn-blk { display: flex; width: 100%; margin-bottom: 10px; }
.w-full { display: flex; width: 100%; margin-bottom: 10px; }

/* ===========================
   LIGHTBOX DE FOTO
   =========================== */
.lb-wrap {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1100;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.lb-wrap.active { display: flex; }

.lb-bg {
    position: absolute;
    inset: -40px;
    background-size: cover;
    background-position: center;
    filter: blur(28px) brightness(.35) saturate(1.4);
    transform: scale(1.08);
}

.lb-img {
    position: relative;
    z-index: 1;
    max-width: 92vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 24px 80px rgba(0,0,0,.7);
    animation: lbIn .22s ease;
}
@keyframes lbIn {
    from { opacity: 0; transform: scale(.93); }
    to   { opacity: 1; transform: scale(1); }
}

.lb-close {
    position: absolute;
    top: 18px; left: 18px;
    z-index: 2;
    width: 38px; height: 38px;
    background: rgba(255,255,255,.18);
    backdrop-filter: blur(6px);
    border: none; border-radius: 50%;
    color: #fff; font-size: 1.5rem;
    line-height: 1; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: background .15s;
}
.lb-close:hover { background: rgba(255,255,255,.32); }
