/*==========================================================
  ESTILOS GLOBAIS E VARIÁVEIS
  ==========================================================*/
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

*:focus {
    outline: none;
}

@media (prefers-reduced-motion: reduce) {
    *,
    ::before,
    ::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

html, body {
    max-width: 100vw;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

:root {
    --primary-color: #004A8B;
    --secondary-color: #FF7B00;
    --background-light: #f8f9fa;
    --background-gray: #f0f0f0;
    --text-color: #333;
    --text-muted: #666;
    --whatsapp-color: #25D366;
    --whatsapp-dark: #128c7e;
    --border-color: #e0e0e0;
    --shadow-light: rgba(0, 0, 0, 0.05);
    --shadow-medium: rgba(0, 0, 0, 0.1);
    --transition-duration: 0.3s;
    --spacing-xs: 5px;
    --spacing-small: 10px;
    --spacing-medium: 20px;
    --spacing-large: 40px;
    --header-height: 70px;
    --font-size-small: 0.8rem;
    --font-size-normal: 1rem;
    --font-size-large: 1.1rem;
    --font-size-title: 2rem;
    --font-size-h1: 2.5rem;
    --font-size-h2: 2rem;
    --font-size-h3: 1.5rem;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-light);
    padding-top: var(--header-height);
    transition: padding var(--transition-duration) ease;
}

.announcement-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px var(--spacing-medium);
    z-index: 1100;
    font-weight: 600;
    font-size: 0.9rem;
    text-align: center;
    box-shadow: 0 2px 4px var(--shadow-medium);
}

.announcement-bar.hidden {
    display: none !important;
}

/* Adjust header when bar is visible */
.has-announcement-bar .header {
    top: 40px;
}

.has-announcement-bar body {
    padding-top: calc(var(--header-height) + 40px);
}

.has-announcement-bar .delivery-page {
    padding-top: calc(var(--header-height) + 40px + 50px);
}

.delivery-page {
    /* Altura base para compensar o header inicial */
    --header-total-height: 115px; 
    padding-top: var(--header-total-height);
    padding-bottom: 80px;
}

.delivery-page .header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Glassmorphism ao rolar */
.delivery-page .header.header-scrolled {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

/* Container da logo que vai sumir */
.header-main-row {
    height: 60px;
    display: flex;
    align-items: center;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border-bottom: 1px solid rgba(0,0,0,0.03);
}

/* Estado recolhido (ao rolar) */
.header-scrolled .header-main-row {
    height: 0;
    opacity: 0;
    pointer-events: none;
    margin-bottom: 0;
}

.delivery-page .category-nav {
    position: relative;
    top: 0 !important;
    background: transparent;
    padding: 10px 0;
    transition: all 0.3s ease;
}

.header.header-scrolled .category-nav {
    padding: 5px 0;
}


/*==========================================================
  BOTTOM NAVIGATION BAR (APP STYLE)
  ==========================================================*/
.app-bottom-nav {
    display: none; /* Oculto em desktop, visível no mobile via media query */
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 68px;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(0, 74, 139, 0.1);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    justify-content: space-around;
    align-items: center;
    padding: 0 8px;
    padding-bottom: env(safe-area-inset-bottom); /* Respeita o notch do iPhone */
}

.app-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    flex: 1;
    text-decoration: none;
    color: #b0bec5;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px 0;
    font-family: 'Poppins', sans-serif;
    position: relative;
    transition: color 0.25s ease;
    -webkit-tap-highlight-color: transparent;
}

.app-nav-item span {
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.2px;
    transition: color 0.25s ease;
}

.app-nav-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    position: relative;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.app-nav-item.active {
    color: var(--primary-color);
}

.app-nav-item.active .app-nav-icon {
    transform: translateY(-4px);
    color: var(--primary-color);
}

.app-nav-item:not(.app-nav-cart):active .app-nav-icon {
    transform: translateY(-4px) scale(0.92);
}

/* Aba central — Carrinho com destaque especial */
.app-nav-icon--cart {
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, var(--primary-color) 0%, #0066cc 100%);
    border-radius: 50%;
    box-shadow: 0 6px 20px rgba(0, 74, 139, 0.45);
    font-size: 1.3rem;
    color: #fff;
    margin-top: -24px;
    border: 3px solid #fff;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}

.app-nav-cart {
    color: var(--primary-color);
}

.app-nav-cart span {
    color: #b0bec5;
    font-size: 0.6rem;
}

.app-nav-cart:active .app-nav-icon--cart {
    transform: scale(0.9);
    box-shadow: 0 3px 10px rgba(0, 74, 139, 0.3);
}

/* Badge do carrinho */
.app-cart-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--secondary-color);
    color: #fff;
    font-size: 0.55rem;
    font-weight: 800;
    min-width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    animation: pop-in 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.app-cart-badge[data-count="0"],
.app-cart-badge:empty {
    display: none;
}

@keyframes pop-in {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}

/* Indicador de item ativo */
.app-nav-item.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 0 0 4px 4px;
    animation: slide-in-indicator 0.3s ease;
}

@keyframes slide-in-indicator {
    from { width: 0; opacity: 0; }
    to { width: 30px; opacity: 1; }
}

/* WhatsApp tab color */
#nav-whatsapp.app-nav-item:hover,
#nav-whatsapp.app-nav-item:active {
    color: var(--whatsapp-color);
}


.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-medium);
    width: 100%;
}

h1, h2, h3 {
    margin-bottom: var(--spacing-medium);
    font-weight: 700;
    color: var(--primary-color);
}

h1 { font-size: var(--font-size-h1); }
h2 { font-size: var(--font-size-h2); }
h3 { font-size: var(--font-size-h3); }

.section-padding {
    padding: 25px 0; /* Reduzido de 40px */
}

.hidden { display: none !important; }
.visible { display: flex !important; }

/*==========================================================
  ESTILOS DO CABEÇALHO
  ==========================================================*/
.header {
    background-color: #fff;
    box-shadow: 0 2px 5px var(--shadow-medium);
    z-index: 1000;
}

/* Removido o transform para manter fixo */
.delivery-page .header-scrolled {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.header .header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: var(--header-height);
}

.logo-link {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo-img {
    max-height: 50px;
    width: auto;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.header-scrolled .logo-img {
    max-height: 0;
    opacity: 0;
    transform: translateY(-20px);
}

.nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-grow: 1;
}

.nav-list {
    list-style: none;
    display: flex;
    gap: var(--spacing-medium);
}

.nav-link {
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 700;
    transition: color var(--transition-duration) ease;
    padding: var(--spacing-small);
}

.nav-link:hover { color: var(--secondary-color); }

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-small);
    flex-shrink: 0;
}

.icon-btn {
    font-size: var(--font-size-normal);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--primary-color);
    position: relative;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    min-height: 36px;
    transition: color var(--transition-duration) ease;
}

.icon-btn:hover { color: var(--secondary-color); }

.install-btn {
    background-color: var(--secondary-color);
    color: #fff;
    border-radius: 50%;
    transition: background-color var(--transition-duration) ease, transform 0.2s ease;
}

.install-btn:hover {
    background-color: #e66d00;
    transform: scale(1.1);
}

.installed .install-btn {
    display: none;
}

.hamburger-btn { display: none; }

/*==========================================================
  ESTILOS DA HERO SECTION (PÁGINA INICIAL)
  ==========================================================*/
.hero-section {
    background-image: url('../img/hero-background.jpg'); 
    background-size: cover;
    background-position: center center;
    padding: 80px 20px;
    text-align: center;
    color: white; 
}

.hero-section .hero-content {
    max-width: 800px;
    margin: 0 auto;
    background-color: rgba(0, 0, 0, 0.3);
    padding: 2rem;
    border-radius: 8px;
}

.hero-section h1 {
    font-size: var(--font-size-h1);
    margin-bottom: 1rem;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6); 
}

.hero-section p {
    font-size: var(--font-size-large);
    margin-bottom: 2rem;
    color: #fff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}


/*==========================================================
  ESTILOS GERAIS DE CONTEÚDO
  ==========================================================*/
.cta-button {
    background-color: var(--secondary-color);
    color: #fff;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background-color var(--transition-duration) ease;
}

.cta-button:hover { background-color: #e66d00; }

.services-section, .testimonials-section { background-color: var(--background-gray); }
.about-section, .hours-section { background-color: #fff; }

.services-grid, .testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-large);
    margin-top: var(--spacing-large);
}

.service-card {
    background-color: #fff;
    padding: var(--spacing-medium);
    border-radius: 20px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
    border: 1px solid rgba(0,0,0,0.03);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
}

.product-card {
    background-color: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.04);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    border: 1px solid rgba(0, 0, 0, 0.03);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 74, 139, 0.12);
}

.service-card:hover { transform: translateY(-5px); }

.service-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 12px;
}

.testimonial-text {
    font-style: italic;
    margin-bottom: 12px;
    color: #555;
    font-size: 0.95rem;
}

.testimonial-author {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.hours-content table {
    width: 100%;
    max-width: 600px;
    margin: var(--spacing-medium) auto;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.hours-content th, .hours-content td {
    border: 1px solid #ccc;
    padding: 10px;
    text-align: left;
}

.hours-content thead {
    background-color: var(--primary-color);
    color: #fff;
}

.horario-nota {
    font-size: var(--font-size-small);
    color: var(--text-muted);
    margin-top: var(--spacing-small);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-large);
}

.contact-info p {
    margin-bottom: var(--spacing-small);
    font-size: var(--font-size-small);
}

.contact-info i {
    color: var(--secondary-color);
    margin-right: var(--spacing-small);
    font-size: var(--font-size-normal);
}

.social-links { margin-top: var(--spacing-medium); }

.social-link {
    font-size: 20px;
    color: var(--primary-color);
    margin-right: 12px;
    transition: color var(--transition-duration) ease;
}

.social-link:hover { color: var(--secondary-color); }

.contact-form .form-group { margin-bottom: 12px; }

.contact-form label {
    display: block;
    font-weight: 700;
    margin-bottom: 3px;
    font-size: var(--font-size-small);
}

.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: inherit;
    font-size: var(--font-size-small);
}

.contact-form input:invalid,
.contact-form textarea:invalid {
    border-color: #e74c3c;
    box-shadow: 0 0 5px rgba(231, 76, 60, 0.5);
}

.contact-form input:focus:invalid,
.contact-form textarea:focus:invalid {
    outline: 2px solid #e74c3c;
}

.submit-button {
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    padding: 12px 25px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color var(--transition-duration) ease;
}

.submit-button:hover { background-color: #003e6d; }

.map-section {
    text-align: center;
    background-color: var(--background-gray);
    padding: var(--spacing-large) 0;
}

.map-container {
    margin-top: var(--spacing-medium);
    border: 5px solid #fff;
    box-shadow: 0 4px 8px var(--shadow-medium);
    overflow: hidden;
    max-width: 100%;
    height: auto;
}

.map-container iframe {
    width: 100%;
    height: 350px;
}

.footer {
    background-color: var(--primary-color);
    color: #fff;
    text-align: center;
    padding: 1.5rem 0;
    font-size: 0.9rem;
    margin-bottom: 0; /* Ajustado via media query para mobile */
}

.footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.footer-links-row {
    display: flex;
    align-items: center;
    gap: 15px;
}

.footer-links-row a {
    display: flex;
    align-items: center;
    color: #fff;
    text-decoration: none;
    font-size: var(--font-size-normal);
}

.footer-links-row a i { margin-right: 8px; }

.footer-links-row a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.separator {
    display: block;
    width: 1px;
    height: 20px;
    background-color: #fff;
    margin: 0 10px;
}

/*==========================================================
  ESTILOS DA PÁGINA DE DELIVERY
  ==========================================================*/
.products-section { background-color: var(--background-gray); }

.how-it-works-section { background-color: #fff; }

.delivery-area-section { background-color: var(--background-gray); }

/*==========================================================
  BARRA DE CATEGORIAS + PESQUISA (STICKY NAV)
  ==========================================================*/
.category-nav {
    position: sticky;
    top: var(--header-height);
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 6px 0; /* Mais compacto */
    width: 100%;
    z-index: 990;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    transition: top 0.35s cubic-bezier(0.4, 0, 0.2, 1), 
                background-color 0.3s ease,
                box-shadow 0.3s ease;
}

/* Quando o header encolhe, o padding do corpo tambem diminui para nao deixar buraco */
.delivery-page.header-hidden-page {
    padding-top: 60px;
}

/* Sombra extra quando a barra cola no topo */
.header.header-scrolled .category-nav {
    box-shadow: none;
}

.category-nav-wrapper {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* Campo de Pesquisa */
.category-search-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 0 16px;
    height: 46px;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

.category-search-bar:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 74, 139, 0.1);
    background: #fff;
    transform: translateY(-1px);
}

.category-search-bar i {
    color: #a0aab4;
    font-size: 0.95rem;
    flex-shrink: 0;
}

.category-search-bar input {
    border: none;
    background: transparent;
    flex: 1;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    color: var(--text-color);
    outline: none;
    padding: 0;
}

.category-search-bar input::placeholder {
    color: #b0b8c4;
}

/* Remover botão nativo de clear (X) no Safari/Chrome */
.category-search-bar input::-webkit-search-cancel-button {
    -webkit-appearance: none;
}

/* Lista horizontal de categorias */
.category-nav-inner {
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding: 2px 2px 4px;
    scroll-snap-type: x mandatory;
}

.category-nav-inner::-webkit-scrollbar {
    display: none;
}

.category-link {
    background-color: #f1f5f9;
    border: 1.5px solid transparent;
    padding: 8px 18px;
    cursor: pointer;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.85rem;
    color: #64748b;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    flex-shrink: 0;
    text-decoration: none;
}

.category-link:hover {
    background-color: #e2e8f0;
    color: var(--primary-color);
}

.category-link.active {
    background-color: var(--primary-color);
    color: #fff;
    box-shadow: 0 4px 12px rgba(0, 74, 139, 0.3);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: var(--spacing-medium);
}

@media (min-width: 769px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }
}

/* Product Card styles are now global (defined above) */

.product-image-box {
    width: 100%;
    aspect-ratio: 1 / 1;
    background-color: #f8f9fa;
    position: relative;
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.product-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    mix-blend-mode: multiply;
}

.card-floating-add {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 74, 139, 0.3);
    z-index: 5;
    transition: all 0.2s cubic-bezier(0.17, 0.67, 0.83, 0.67);
}

.card-floating-add:hover {
    background-color: var(--secondary-color);
}

.card-floating-add:active {
    transform: scale(0.85);
}

.product-info {
    padding: 10px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.product-info h3 {
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.35;
    text-transform: none;
    color: #333;
    margin: 0 0 4px 0;
    /* Força altura fixa de 2 linhas para alinhar tudo */
    height: 2.7em; 
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-info p {
    display: none;
}

.product-info .product-price {
    font-size: 1rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin: 0;
}

/* Old button row hidden */
.product-card-actions {
    display: none !important;
}

.how-it-works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-large);
    margin-top: var(--spacing-large);
}

.step-card {
    padding: var(--spacing-medium);
    background-color: var(--background-light);
    border-radius: 8px;
    font-size: 0.9rem;
}

.step-card i {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 12px;
}

.step-card h3 { font-size: 1.2rem; }

.delivery-area-text { font-size: var(--font-size-normal); }

.cart-container {
    position: fixed;
    top: 0;
    right: 0;
    width: 320px;
    max-width: 100%;
    height: 100%;
    background-color: #fff;
    box-shadow: -2px 0 10px var(--shadow-medium);
    transform: translateX(100%);
    transition: transform var(--transition-duration) ease-in-out;
    z-index: 1002;
    display: flex;
    flex-direction: column;
}

.cart-container.open { transform: translateX(0); }

.cart-items {
    flex-grow: 1;
    overflow-y: auto;
    padding: var(--spacing-small);
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-small);
    border-bottom: 1px solid #ddd;
}

.cart-header h3 { margin: 0; font-size: var(--font-size-large); }

.close-cart-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-color);
    padding: 0;
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    border-bottom: 1px solid #eee;
    padding-bottom: 12px;
}

.cart-item-image {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}

.cart-item-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex-grow: 1;
    min-width: 0;
}

.cart-item-name {
    font-weight: 700;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.cart-item-price {
    color: var(--text-muted);
    font-size: var(--font-size-small);
    text-align: right;
    width: 70px;
    white-space: nowrap;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 5px;
    margin: 0 8px;
}

.quantity-decrease, .quantity-increase {
    background: var(--primary-color);
    color: #fff;
    border: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: 700;
    line-height: 1;
    font-size: var(--font-size-small);
}

.cart-item-remove button {
    background: #e74c3c;
    color: #fff;
    border: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: 700;
    line-height: 1;
    font-size: 0.9rem;
}

.cart-footer {
    padding: var(--spacing-small);
    border-top: 1px solid #ddd;
    text-align: center;
}

.cart-coupon-area {
    display: flex;
    gap: 5px;
    margin-bottom: 12px;
    flex-direction: column;
}

.cart-coupon-area label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.coupon-input-group {
    display: flex;
    gap: 5px;
}

.cart-coupon-area input {
    flex-grow: 1;
    border: 2px solid var(--border-color);
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.9rem;
    background-color: #f9f9f9;
}

.cart-coupon-area input:focus {
    border-color: var(--secondary-color);
    background-color: #fff;
}

.apply-coupon-btn {
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    padding: 8px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.2s;
}

.apply-coupon-btn:hover {
    background-color: #003e6d;
}

.cart-coupon-message {
    font-size: 0.85rem;
    min-height: 20px;
    margin-bottom: 5px;
    font-weight: 600;
}

.cart-total-summary {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
    text-align: right;
}

.summary-line {
    display: flex;
    justify-content: space-between;
    font-size: 0.95rem;
}

.summary-line.total-line {
    font-size: 1.3rem;
    font-weight: 700;
    border-top: 1px solid var(--border-color);
    padding-top: 8px;
    margin-top: 5px;
}

.checkout-btn {
    background-color: var(--whatsapp-color);
    color: #fff;
    padding: 12px 25px;
    border: none;
    border-radius: 5px;
    font-weight: 700;
    display: block;
    width: 100%;
    cursor: pointer;
    transition: background-color var(--transition-duration) ease;
}

.checkout-btn:hover { background-color: var(--whatsapp-dark); }

.cart-empty-message {
    text-align: center;
    font-style: italic;
    color: #999;
    font-size: 0.9rem;
}

/*==========================================================
  CHECKOUT PREMIUM — 3 ETAPAS
  ==========================================================*/
.checkout-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: rgba(10, 20, 40, 0.65);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: none;
    justify-content: center;
    align-items: flex-end;
    z-index: 2001;
    padding: 0;
}

@media (min-width: 520px) {
    .checkout-modal {
        align-items: center;
        padding: 16px;
    }
}

.checkout-modal-content {
    background: #fff;
    border-radius: 24px 24px 0 0;
    width: 100%;
    max-width: 480px;
    position: relative;
    box-shadow: 0 -8px 40px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    height: 92dvh;
    max-height: 92dvh;
    overflow: hidden;
    animation: checkout-slide-up 0.38s cubic-bezier(0.22, 1, 0.36, 1);
}

@media (min-width: 520px) {
    .checkout-modal-content {
        border-radius: 20px;
        animation: checkout-pop-in 0.32s cubic-bezier(0.22, 1, 0.36, 1);
        height: auto;
        max-height: 90vh;
    }
}

@keyframes checkout-slide-up {
    from { opacity: 0; transform: translateY(60px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes checkout-pop-in {
    from { opacity: 0; transform: scale(0.94) translateY(20px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}

/* Header do modal */
.checkout-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0066cc 100%);
    padding: 14px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #fff;
    flex-shrink: 0;
    min-height: 54px;
}

.checkout-header h3 {
    margin: 0;
    font-size: 1rem;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    flex: 1;
    text-align: center;
    justify-content: center;
}

.checkout-back-btn {
    background: rgba(255,255,255,0.15);
    border: none;
    border-radius: 50%;
    width: 34px;
    height: 34px;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    flex-shrink: 0;
}
.checkout-back-btn:hover { background: rgba(255,255,255,0.25); }

.close-checkout-modal {
    background: rgba(255,255,255,0.15);
    border: none;
    border-radius: 50%;
    width: 34px;
    height: 34px;
    font-size: 1.2rem;
    cursor: pointer;
    color: #fff;
    line-height: 1;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.close-checkout-modal:hover { background: rgba(255,255,255,0.25); }

/* Progress bar */
.checkout-progress {
    display: flex;
    align-items: center;
    padding: 14px 20px 10px;
    background: #f8fbff;
    border-bottom: 1px solid #eef2f8;
    flex-shrink: 0;
}

.checkout-step-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    flex: 0;
}

.checkout-step-indicator .step-dot {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #e4eaf2;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    color: #93a3bc;
    transition: background 0.3s, color 0.3s, box-shadow 0.3s;
}

.checkout-step-indicator span {
    font-size: 0.65rem;
    font-weight: 600;
    color: #93a3bc;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    transition: color 0.3s;
    white-space: nowrap;
}

.checkout-step-indicator.step-active .step-dot {
    background: var(--primary-color);
    color: #fff;
    box-shadow: 0 4px 12px rgba(0,74,139,0.35);
}
.checkout-step-indicator.step-active span { color: var(--primary-color); }

.checkout-step-indicator.step-done .step-dot {
    background: #22c55e;
    color: #fff;
}
.checkout-step-indicator.step-done span { color: #22c55e; }

.checkout-step-line {
    flex: 1;
    height: 2px;
    background: #e4eaf2;
    margin: 0 4px;
    margin-bottom: 18px; /* aligned with dot center */
    border-radius: 2px;
    transition: background 0.3s;
}
.checkout-step-line.line-done { background: #22c55e; }
.checkout-step-line.line-active { background: var(--primary-color); }

/* Wrapper das etapas — ocupa todo o espaço restante */
.checkout-steps-wrapper {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Cada etapa ocupa 100% do wrapper */
.checkout-step {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
    animation: step-fade-in 0.28s ease;
}

@keyframes step-fade-in {
    from { opacity: 0; transform: translateX(18px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* ===== STEP 1: Lista de itens ===== */
.checkout-order-review {
    flex: 1;
    overflow-y: auto;
    padding: 16px 16px 0;
    -webkit-overflow-scrolling: touch;
}

.checkout-items-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 14px;
}

.checkout-review-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f8fbff;
    border: 1px solid #eef2f8;
    border-radius: 12px;
    padding: 10px 12px;
}

.checkout-review-item img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

.checkout-review-item .cr-info {
    flex: 1;
    min-width: 0;
}

.checkout-review-item .cr-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: #2a3550;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.checkout-review-item .cr-qty {
    font-size: 0.75rem;
    color: #7a8da8;
    margin-top: 2px;
}

.checkout-review-item .cr-price {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--secondary-color);
    white-space: nowrap;
    flex-shrink: 0;
}

/* Cupom */
.checkout-coupon-box {
    border: 1.5px dashed #d1dde8;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 14px;
}

.coupon-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    cursor: pointer;
    background: #f4f8fc;
    color: var(--primary-color);
    font-size: 0.85rem;
    font-weight: 600;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.coupon-toggle i:first-child { color: var(--secondary-color); }
.coupon-chevron { margin-left: auto; transition: transform 0.25s; font-size: 0.75rem; }
.coupon-chevron.open { transform: rotate(180deg); }

.coupon-body { padding: 10px 14px 12px; background: #fff; }

/* Resumo de valores */
.checkout-values-summary {
    background: linear-gradient(135deg, #f0f6ff 0%, #fff 100%);
    border: 1px solid #dde8f5;
    border-radius: 14px;
    padding: 14px 16px;
    margin-bottom: 4px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.checkout-values-summary .summary-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #556;
}

.checkout-values-summary .total-final-line {
    border-top: 1.5px solid #dde8f5;
    padding-top: 10px;
    margin-top: 2px;
}

.checkout-values-summary .total-final-line strong {
    font-size: 1rem;
    color: var(--text-color);
}

.discount-amount { color: #22c55e !important; font-weight: 700; }

.total-highlight {
    font-size: 1.3rem !important;
    font-weight: 800;
    color: var(--primary-color) !important;
}

/* ===== STEP 2: Formulário de entrega ===== */
.checkout-form-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 18px 16px 24px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Float Label (label que sobe ao focar) */
.float-label-group {
    position: relative;
    margin-bottom: 14px;
}

.float-label-group input {
    width: 100%;
    border: 1.5px solid #d5dfe8;
    border-radius: 10px;
    padding: 20px 14px 6px;
    font-size: 0.95rem;
    font-family: 'Poppins', sans-serif;
    color: #2a3550;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
    height: 52px;
    box-sizing: border-box;
}

.float-label-group input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0,74,139,0.1);
}

.float-label-group label {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.95rem;
    color: #93a3bc;
    pointer-events: none;
    transition: all 0.2s ease;
    background: transparent;
    padding: 0 2px;
    font-weight: 500;
    font-family: 'Poppins', sans-serif;
}

/* Label sobe quando o input tem valor (placeholder=" " trick) */
.float-label-group input:not(:placeholder-shown) + label,
.float-label-group input:focus + label {
    top: 6px;
    transform: none;
    font-size: 0.68rem;
    color: var(--primary-color);
    font-weight: 600;
    letter-spacing: 0.2px;
}

.form-row-split {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 10px;
}

.form-col-sm { /* coluna menor (número) */ }
.form-col-xl { /* coluna maior (rua) */ }

@media (max-width: 380px) {
    .form-row-split { grid-template-columns: 1fr; }
}

/* ===== STEP 3: Pagamento ===== */
.payment-label {
    font-size: 0.85rem;
    font-weight: 700;
    color: #556;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    margin-bottom: 12px;
    margin-top: 2px;
}

.payment-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 18px;
}

.payment-card {
    cursor: pointer;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.payment-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.payment-card-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 8px;
    background: #f4f8fc;
    border: 2px solid #e2eaf4;
    border-radius: 12px;
    transition: all 0.22s ease;
    font-size: 0.82rem;
    font-weight: 600;
    color: #4a5a75;
}

.payment-card-body i {
    font-size: 1.5rem;
    color: #7a8da8;
    transition: color 0.22s;
}

.payment-card input[type="radio"]:checked + .payment-card-body {
    background: #eef5ff;
    border-color: var(--primary-color);
    color: var(--primary-color);
    box-shadow: 0 4px 14px rgba(0,74,139,0.18);
}

.payment-card input[type="radio"]:checked + .payment-card-body i {
    color: var(--primary-color);
}

/* Pix — verde */
#pay-pix:checked + .payment-card-body {
    background: #f0fff6;
    border-color: #16a34a;
    color: #16a34a;
    box-shadow: 0 4px 14px rgba(22,163,74,0.18);
}
#pay-pix:checked + .payment-card-body i { color: #16a34a; }

/* Troco */
.troco-box {
    background: #fffbeb;
    border: 1.5px solid #fde68a;
    border-radius: 12px;
    padding: 12px 14px;
    margin-bottom: 16px;
    animation: step-fade-in 0.25s ease;
}

/* Resumo Final */
.checkout-final-summary {
    background: #f0f6ff;
    border: 1px solid #dde8f5;
    border-radius: 14px;
    overflow: hidden;
    margin-bottom: 4px;
}

.final-summary-header {
    background: var(--primary-color);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 6px 14px;
}

.final-summary-lines {
    padding: 10px 14px 6px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    max-height: 110px;
    overflow-y: auto;
}

.final-summary-line-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    color: #4a5a75;
}

.final-summary-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px 12px;
    border-top: 1px solid #dde8f5;
    margin-top: 2px;
}

.final-summary-total span {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
}

/* ===== Footer de cada step — NUNCA ROLA ===== */
.checkout-step-footer {
    flex-shrink: 0;
    padding: 14px 16px;
    padding-bottom: calc(14px + env(safe-area-inset-bottom));
    background: #fff;
    border-top: 1px solid #eef2f8;
    box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.08);
    z-index: 2;
}

.checkout-next-btn {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 14px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    width: 100%;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s, transform 0.15s;
    box-shadow: 0 4px 16px rgba(0,74,139,0.25);
}

.checkout-next-btn:hover {
    background: #0057a8;
    transform: translateY(-1px);
}

.submit-order-btn {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: #fff;
    border: none;
    padding: 14px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    width: 100%;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 4px 16px rgba(22, 163, 74, 0.3);
    transition: opacity 0.2s, transform 0.15s;
}

.submit-order-btn:hover {
    opacity: 0.93;
    transform: translateY(-1px);
}

.submit-order-btn i { font-size: 1.3rem; }

/* Responsividade Extra para Telas Muito Pequenas (iPhone SE, etc) */
@media (max-width: 380px) {
    .payment-cards-grid { grid-template-columns: repeat(3,1fr); gap: 6px; }
    .payment-card-body { padding: 10px 4px; font-size: 0.75rem; }
    .payment-card-body i { font-size: 1.2rem; }
}

/*==========================================================
  OUTROS MODAIS (Produto, Prompt)
  ==========================================================*/
.modal-subscribe-prompt {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal-subscribe-prompt.visible { display: flex; }

.modal-subscribe-prompt .modal-content {
    background-color: #fff;
    padding: var(--spacing-large);
    border-radius: 8px;
    max-width: 450px;
    width: 90%;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transform: translateY(20px);
    opacity: 0;
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
}

.modal-subscribe-prompt.visible .modal-content {
    transform: translateY(0);
    opacity: 1;
}

.modal-subscribe-prompt h3 { margin-top: 0; }

.prompt-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.prompt-buttons button {
    padding: 12px 25px;
    border: none;
    border-radius: 5px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color var(--transition-duration) ease;
}

.prompt-button-accept {
    background-color: var(--secondary-color);
    color: #fff;
}

.prompt-button-decline {
    background-color: var(--background-gray);
    color: var(--text-muted);
}

.product-details-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    backdrop-filter: blur(3px);
}

.product-details-modal.open {
    display: flex;
}

.product-details-modal .modal-content {
    background-color: #fff;
    padding: var(--spacing-medium);
    border-radius: 12px;
    max-width: 90%;
    width: 600px;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    max-height: 90vh;
    overflow-y: auto;
}




.close-product-modal-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-muted);
    z-index: 10;
}

.product-details-modal .modal-body {
    display: flex;
    flex-direction: row;
    gap: var(--spacing-medium);
    align-items: flex-start;
}

.product-modal-image {
    width: 50%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
    border-radius: 8px;
}

.product-modal-info {
    width: 50%;
    display: flex;
    flex-direction: column;
}

.product-modal-info h3 {
    margin-top: 0;
    margin-bottom: var(--spacing-small);
}

.product-modal-description {
    font-size: var(--font-size-normal);
    color: var(--text-muted);
    margin-bottom: var(--spacing-small);
    display: block !important;
}

.product-variations {
    margin: var(--spacing-small) 0;
}

.product-variations select {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: var(--font-size-normal);
    font-family: inherit;
}

.product-modal-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: var(--spacing-small);
}

.quantity-selector-modal {
    margin-bottom: var(--spacing-medium);
}

.quantity-selector-modal label {
    font-weight: 700;
    font-size: 0.9rem;
    display: block;
    margin-bottom: 5px;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.quantity-btn-modal {
    background-color: var(--primary-color);
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

#quantity-input-modal {
    width: 50px;
    height: 30px;
    text-align: center;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 700;
    -moz-appearance: textfield;
}

#quantity-input-modal::-webkit-outer-spin-button,
#quantity-input-modal::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.modal-buttons-container {
    display: flex;
    gap: 10px;
    width: 100%;
    flex-direction: column; /* Botões empilhados no mobile ficam melhor */
}

.modal-buttons-container button {
    width: 100%;
    padding: 12px 10px;
    border-radius: 6px;
    border: none;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color var(--transition-duration) ease, transform 0.2s ease;
}

.modal-buttons-container button:hover:not(:disabled) {
    transform: translateY(-2px);
}

.modal-buttons-container button:disabled {
    background-color: #cccccc;
    color: #666666;
    cursor: not-allowed;
}

.add-to-cart-button {
    background-color: #fff;
    color: var(--primary-color);
    border: 2px solid var(--primary-color) !important;
}

.add-to-cart-button:hover:not(:disabled) {
    background-color: #f0f8ff;
}

.buy-now-button {
    background-color: var(--whatsapp-color);
    color: white;
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.2);
}

.buy-now-button:hover:not(:disabled) {
    background-color: var(--whatsapp-dark);
}

/*==========================================================
  BOTÕES FLUTUANTES E ONESIGNAL
  ==========================================================*/
.whatsapp-float-btn, .delivery-float-btn {
    position: fixed;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
    font-size: 2rem;
    z-index: 999;
    transition: transform 0.2s ease;
    right: var(--spacing-medium);
}

.whatsapp-float-btn:hover, .delivery-float-btn:hover {
    transform: scale(1.1);
}

.OneSignal-bell-container {
    bottom: 20px !important;
    right: 20px !important;
}

.whatsapp-float-btn {
    background-color: var(--whatsapp-color);
    bottom: 95px;
}

.delivery-float-btn {
    background-color: var(--secondary-color);
    bottom: 170px;
}

/*==========================================================
  BARRA DE FEEDBACK DO CARRINHO
  ==========================================================*/
.cart-feedback-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #212529;
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    z-index: 998;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    transform: translateY(100%);
    transition: transform 0.4s ease-in-out;
}

.cart-feedback-bar.visible {
    transform: translateY(0);
}

.feedback-bar-info {
    display: flex;
    flex-direction: column;
}

.feedback-bar-info span {
    line-height: 1.3;
}

#feedback-bar-item-count {
    font-size: 0.9rem;
    font-weight: 500;
}

#feedback-bar-total-price {
    font-size: 1.1rem;
    font-weight: 700;
}

.feedback-bar-button {
    background-color: var(--whatsapp-color);
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s ease;
}

.feedback-bar-button:hover {
    background-color: var(--whatsapp-dark);
}


/*==========================================================
  MEDIA QUERIES (RESPONSIVIDADE)
  ==========================================================*/
@media (max-width: 768px) {
    .product-details-modal .modal-content {
        max-width: 95%;
    }

    .product-details-modal .modal-body {
        flex-direction: column;
    }

    .product-modal-image,
    .product-modal-info {
        width: 100%;
    }

    .header .header-container {
        padding: 0 var(--spacing-small);
        flex-wrap: nowrap;
        justify-content: space-between;
    }

    /* ✅ Ativa a Bottom Navigation Bar */
    .app-bottom-nav {
        display: flex;
    }

    .delivery-page {
        padding-top: calc(var(--header-height) + 40px);
        padding-bottom: 90px; /* Espaço para a bottom nav */
    }

    /* Esconde botões redundantes do header */
    .tracking-btn,
    .icon-btn.cart-btn,
    .icon-btn.hamburger-btn {
        display: none;
    }


    .logo-img { max-height: 40px; }
    
    .nav {
        position: fixed;
        top: 0;
        right: -80%;
        width: 80%;
        height: 100vh;
        background-color: var(--primary-color);
        box-shadow: -2px 0 10px var(--shadow-medium);
        transition: right var(--transition-duration) ease-in-out;
        z-index: 1001;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        padding-top: calc(var(--header-height) + 20px);
    }

    .nav.open { right: 0; }

    .nav-list {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        gap: 0;
        padding: var(--spacing-medium);
    }

    .nav-list .nav-link {
        color: #fff;
        padding: 15px var(--spacing-small);
        display: block;
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    }
    
    .hamburger-btn { 
        display: block; 
        order: 3;
    }

    .hamburger-btn.open {
        position: fixed;
        top: 15px;
        right: 15px;
        z-index: 1002;
        color: #fff;
    }

    .header-actions {
        display: flex;
        align-items: center;
        gap: 8px;
        order: 2;
    }

    .install-btn {
        order: 1;
    }

    .cart-btn {
        order: 2;
    }

    .hero-content h1 { font-size: 1.8rem; }
    .hero-content p { font-size: 0.9rem; }
    .delivery-page .delivery-title { font-size: 2rem; }
    .delivery-page .delivery-description { font-size: 1rem; }
    .contact-grid { grid-template-columns: 1fr; }
    .footer-links { margin-top: 10px; }
    .footer-links a { font-size: 0.9rem; }
    .separator { display: none; }
    .footer-links-row {
        flex-direction: column;
        gap: 5px;
    }

    /* Footer com margem para não sobrepor a bottom nav */
    .footer {
        margin-bottom: 68px;
    }

    /* Na página principal (index.html), body também precisa de padding */
    body:not(.delivery-page) {
        padding-bottom: 68px;
    }

    /* OneSignal fica acima da bottom nav */
    .OneSignal-bell-container {
        bottom: 80px !important;
        right: 10px !important;
    }

    /* Oculta botões flutuantes antigos em mobile (removidos do HTML mas mantido por segurança) */
    .whatsapp-float-btn, .delivery-float-btn {
        display: none !important;
    }

    .services-grid, .testimonials-grid, .how-it-works-grid { grid-template-columns: 1fr; }

    .product-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: var(--spacing-medium);
    }

    .modal-subscribe-prompt .modal-content {
        padding: var(--spacing-small);
        width: 95%;
    }

    .prompt-buttons {
        flex-direction: column;
        gap: 5px;
    }

    .prompt-buttons button {
        font-size: 0.9rem;
        padding: 8px 15px;
    }

    .category-nav-inner { padding: 0 var(--spacing-small); }
    
    .modal-buttons-container {
        flex-direction: row; /* Volta ao lado a lado se couber */
    }
}

@media (max-width: 480px) {
    .container { padding: 0 var(--spacing-small); }
    .hero-content h1 { font-size: 1.5rem; }
    .hero-content p { font-size: 0.8rem; }
    .cta-button {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    .footer-links a { font-size: 0.8rem; }
    .separator { height: 15px; }
    .cart-container { width: 100%; }
    
    .modal-buttons-container {
        flex-direction: column; /* Empilha em telas muito pequenas */
    }
}

@media (min-width: 769px) {
    .nav {
        position: static;
        transform: none;
        padding: 0;
        width: auto;
        height: auto;
        background-color: transparent;
        box-shadow: none;
        order: 1;
    }

    .nav-list {
        flex-direction: row;
        align-items: center;
        gap: var(--spacing-medium);
    }

    .nav-list .nav-link {
        color: var(--primary-color);
        padding: 0 var(--spacing-small);
        border-bottom: none;
    }

    .hamburger-btn { display: none; }

    .header-container {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .logo-link { order: 1; }
    .header-actions { order: 2; }

    .product-grid { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
    .contact-grid { grid-template-columns: 1fr 1fr; }
    .hero-content h1 { font-size: 3rem; }
    .hero-content p { font-size: 1.2rem; }
    .delivery-page .delivery-title { font-size: 2.5rem; }
    .delivery-page .delivery-description { font-size: 1.1rem; }
}

/* Estilos para produtos esgotados */
.product-card.esgotado {
    opacity: 0.6;
    cursor: not-allowed;
}

.product-card.esgotado .product-image {
    filter: grayscale(100%);
}

.product-card.esgotado .product-price {
    color: #ef4444;
    font-weight: bold;
}

/*==========================================================
  ANIMAÇÕES
  ==========================================================*/
@keyframes bounce-cart {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.25);
  }
}


/*==========================================================
  MODAL DE RASTREAMENTO (STEPPER)
  ==========================================================*/

/* Botão de rastreamento no header */
.tracking-btn {
    color: var(--primary-color);
    transition: color var(--transition-duration) ease, transform 0.2s ease;
}
.tracking-btn:hover {
    color: var(--secondary-color);
    transform: scale(1.1);
}

/* Header do modal */
.modal-header {
    border-bottom: 2px solid var(--background-gray);
    padding-bottom: 15px;
    margin-bottom: 25px;
}
.modal-header h3 {
    font-size: 1.2rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

/* Classes utilitárias necessárias para o modal */
.text-center { text-align: center; }
.py-10 { padding-top: 40px; padding-bottom: 40px; }
.mt-8 { margin-top: 32px; }
.mt-10 { margin-top: 40px; }
.mb-8 { margin-bottom: 32px; }
.font-bold { font-weight: 700; }
.font-black { font-weight: 900; }
.text-gray-500 { color: #6b7280; }
.text-gray-400 { color: #9ca3af; }
.text-blue-600 { color: #2563eb; }
.text-red-500 { color: #ef4444; }
.text-blue-900 { color: #1e3a8a; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 1.875rem; }
.text-xs { font-size: 0.75rem; }
.uppercase { text-transform: uppercase; }
.px-4 { padding-left: 16px; padding-right: 16px; }

/* Spinner de carregamento */
.fa-spin { animation: fa-spin 1s infinite linear; }
@keyframes fa-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.tracking-modal-container {
    padding: 30px !important;
    max-width: 500px !important;
}

.order-info {
    padding: 15px;
    background-color: #f8fbff;
    border-radius: 12px;
    border: 1px dashed var(--primary-color);
}

.stepper-horizontal {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
    padding: 20px 0;
}

.stepper-horizontal::before {
    content: '';
    position: absolute;
    top: 36px;
    left: 40px;
    right: 40px;
    height: 3px;
    background-color: #e9ecef;
    z-index: 1;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
    flex: 1;
}

.step-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.step-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #fff;
    border: 3px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #adb5bd;
    margin-bottom: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 0 0 4px #fff;
}

.step-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
}

/* Estado Ativo/Finalizado */
.step.active .step-icon {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
    box-shadow: 0 0 0 4px #fff, 0 0 15px rgba(0, 74, 139, 0.4);
}


.step.active .step-label {
    color: var(--primary-color);
}

.step.completed .step-icon {
    background-color: #28a745;
    border-color: #28a745;
    color: #fff;
}

.step.completed .step-label {
    color: #28a745;
}

.step.active .step-icon i {
    animation: pulse-icon 2s infinite;
}

@keyframes pulse-icon {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

/*==========================================================
  BANNER DE INSTALAÇÃO PWA
  ==========================================================*/
.pwa-install-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #fff;
    box-shadow: 0 -5px 25px rgba(0,0,0,0.15);
    z-index: 2100;
    padding: 15px;
    border-top: 3px solid var(--secondary-color);
    animation: slide-up-banner 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

@keyframes slide-up-banner {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.pwa-banner-content {
    display: flex;
    align-items: center;
    gap: 15px;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.pwa-banner-content img {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.pwa-banner-text {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.pwa-banner-text strong {
    font-size: 1rem;
    color: #333;
}

.pwa-banner-text span {
    font-size: 0.75rem;
    color: #777;
}

.pwa-btn-primary {
    background-color: var(--secondary-color);
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(255, 123, 0, 0.3);
}

.pwa-btn-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #ccc;
    cursor: pointer;
    padding: 5px;
}

.pwa-install-banner.hidden {
    display: none;
}

/* Tracking Lead Capture */
.lead-icon-container i {
    filter: drop-shadow(0 4px 8px rgba(0, 74, 139, 0.2));
}

.lead-input-wrapper {
    display: flex;
    align-items: center;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    padding: 12px 18px;
    gap: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.lead-input-wrapper:focus-within {
    border-color: var(--primary-color);
    background: #fff;
    box-shadow: 0 8px 20px rgba(0, 74, 139, 0.1);
    transform: translateY(-2px);
}

.lead-input-wrapper i {
    color: #25d366;
    font-size: 1.4rem;
}

.lead-input-wrapper input {
    border: none;
    background: none;
    outline: none;
    width: 100%;
    font-weight: 700;
    color: #1e293b;
    font-size: 1rem;
}

.lead-btn-primary {
    width: 100%;
    background: linear-gradient(135deg, var(--primary-color) 0%, #0056a3 100%);
    color: #fff;
    border: none;
    border-radius: 16px;
    padding: 16px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 15px rgba(0, 74, 139, 0.3);
}

.lead-btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 74, 139, 0.4);
    filter: brightness(1.1);
}

.lead-btn-primary:active {
    transform: scale(0.97);
}

/*==========================================================
  MODAL DE NOTIFICAÇÕES (AVISOS)
  ==========================================================*/
.notifications-modal-container {
    max-width: 450px !important;
    padding: 0 !important;
    overflow: hidden !important;
    border: none !important;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
}

.notifications-modal-container .modal-header {
    padding: 20px;
    background: linear-gradient(135deg, var(--primary-color), #0062bc);
    color: #fff;
    margin-bottom: 0;
    border-bottom: none;
}

.notifications-modal-container .modal-header h3 {
    color: #fff;
    margin: 0;
    font-size: 1.2rem;
}

.notifications-list {
    padding: 20px;
    max-height: 400px;
    overflow-y: auto;
}

.notification-item {
    display: flex;
    gap: 15px;
    padding: 15px;
    background: #fff;
    border-radius: 12px;
    margin-bottom: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    border-left: 4px solid var(--secondary-color);
    transition: transform 0.2s ease;
}

.notification-item:hover {
    transform: translateX(5px);
}

.notification-icon {
    width: 40px;
    height: 40px;
    background: #fff5eb;
    color: var(--secondary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.notification-text strong {
    display: block;
    font-size: 1rem;
    color: var(--primary-color);
    margin-bottom: 4px;
}

.notification-text p {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    line-height: 1.4;
}

.notification-text small {
    font-size: 0.75rem;
    color: #999;
}

.notifications-footer {
    padding: 15px 20px;
    background: #f8f9fa;
    text-align: center;
    border-top: 1px solid #eee;
}

.notifications-footer .cta-button {
    width: 100%;
    max-width: 200px;
}

@media (max-width: 768px) {
    .notifications-modal-container {
        width: 90% !important;
    }
}