/* --- Configurações Gerais --- */
:root {
    --cor-acerola: #D9381E; /* Vermelho vibrante */
    --cor-folha: #4A7c59;   /* Verde natural */
    --cor-fundo: #FAFAFA;
    --cor-texto: #333;
    --cor-zap: #25D366;
}

* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; 
}

body { 
    background-color: var(--cor-fundo); 
    color: var(--cor-texto); 
    line-height: 1.6; 
}

/* --- Cabeçalho --- */
header {
    background-color: var(--cor-acerola);
    color: white;
    padding: 1rem;
    text-align: center;
    position: sticky; /* Fica fixo no topo */
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

header h1 { font-size: 1.5rem; }
header p { font-size: 0.9rem; opacity: 0.9; }

/* --- Seção Hero (Destaque Principal) --- */
.hero {
    /* Fundo com gradiente escuro para ler o texto e imagem de fundo */
    /* ↓↓↓ ESPAÇO PARA A FOTO DE FUNDO: Mude o nome do arquivo aqui dentro ↓↓↓ */
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('https://res.cloudinary.com/djtguoi8i/image/upload/red-3929193_640_erlzeh.png');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 4rem 1rem;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero h2 { 
    font-size: 2.5rem; 
    margin-bottom: 1rem; 
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5); 
}

.frete-aviso {
    margin-top: 15px;
    font-size: 1.1rem;
    /* Estilo mais minimalista, sem fundo ou borda, com sombra para legibilidade */
    text-shadow: 1px 1px 3px rgba(0,0,0,0.7);
}

.btn-cta {
    background-color: var(--cor-zap);
    color: white;
    padding: 15px 30px;
    text-decoration: none;
    font-weight: bold;
    border-radius: 50px;
    display: inline-block;
    margin-top: 1rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
    transition: transform 0.2s;
}

.btn-cta:hover { transform: scale(1.05); }

/* --- Layout Container --- */
.container { 
    max-width: 1000px; 
    margin: 0 auto; 
    padding: 2rem 1rem; 
}

.section-header { text-align: center; }

.section-title {
    text-align: center;
    color: var(--cor-acerola);
    margin-bottom: 2rem;
    font-size: 1.8rem;
    border-bottom: 2px solid var(--cor-folha);
    display: inline-block;
    padding-bottom: 5px;
}

/* --- Grid de Produtos --- */
.produtos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

/* --- Carrossel de Produtos (Novo) --- */
.produtos-carousel {
    display: flex;
    overflow-x: auto;
    gap: 1.5rem;
    padding: 1rem 0.5rem; /* Espaço para a sombra do card não cortar */
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.produtos-carousel .card {
    min-width: 280px; /* Largura fixa para os cards no carrossel */
    flex: 0 0 auto;   /* Garante que não encolham */
    scroll-snap-align: center; /* Centraliza o card ao soltar */
}

/* Estilo da barra de rolagem (igual polpas) */
.produtos-carousel::-webkit-scrollbar { height: 6px; }
.produtos-carousel::-webkit-scrollbar-thumb { background-color: #ccc; border-radius: 10px; }
.produtos-carousel::-webkit-scrollbar-track { background-color: #f1f1f1; }

.card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
    border: 1px solid #eee;
    transition: transform 0.2s;
}

/* Destaque para o Carro Chefe (Acerola) */
.card.destaque {
    border: 2px solid var(--cor-acerola);
    transform: scale(1.02); /* Levemente maior */
}

.card-img {
    height: 200px;
    background-color: #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    position: relative;
}

/* Cores de fundo placeholder para as imagens */
.img-acerola { background-color: #ffcccb; }
.img-maracuja { background-color: #fffacd; }
.img-caju { background-color: #ffe4b5; }
.img-morango { background-color: #ffb6c1; }
.img-morango-congelado { background-color: #c21e56; color: white; } /* Cor mais forte para diferenciar */
.img-uva { background-color: #e6e6fa; }
.img-acerola-cong { background-color: #b22222; color: white; } /* Vermelho escuro */
.img-amora { background-color: #4b0082; color: white; } /* Roxo escuro */
.img-framboesa { background-color: #e30b5d; color: white; } /* Rosa escuro */
.img-frutas-vermelhas { background-color: #800000; color: white; } /* Vinho */
.img-mirtilo { background-color: #483d8b; color: white; } /* Azul escuro */

.img-text { font-weight: bold; opacity: 0.5; }

.card-body { padding: 1.5rem; }
.card-title { font-size: 1.3rem; color: var(--cor-folha); margin-bottom: 0.5rem; }
.card-price { font-size: 1.2rem; font-weight: bold; color: var(--cor-acerola); }

.tag-destaque {
    background-color: var(--cor-acerola);
    color: white;
    padding: 5px 10px;
    font-size: 0.8rem;
    border-radius: 20px;
    margin-bottom: 10px;
    display: inline-block;
}

/* Botão dentro dos Cards */
.btn-card {
    display: block;
    background-color: var(--cor-zap);
    color: white;
    text-decoration: none;
    padding: 10px;
    border-radius: 5px;
    margin-top: 10px;
    font-weight: bold;
    transition: background 0.2s;
}
.btn-card:hover { background-color: #1ebe57; }

/* --- Controles de Quantidade --- */
.qtd-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 15px 0;
    background: #f0f0f0;
    padding: 5px;
    border-radius: 25px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.btn-qtd {
    background-color: var(--cor-folha);
    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;
    transition: transform 0.1s;
}

.btn-qtd:active { transform: scale(0.9); }

.qtd-valor { font-weight: bold; font-size: 1.2rem; min-width: 20px; }
.subtotal { font-size: 0.9rem; color: #666; margin-top: 5px; font-weight: bold; }

/* --- Lista de Sabores (Cardápio) --- */
.lista-sabores-container {
    margin-top: 3rem;
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.lista-sabores {
    list-style: none;
    display: flex; /* Muda de Grid para Flex (linha) */
    overflow-x: auto; /* Permite rolagem horizontal */
    gap: 15px;
    text-align: center;
    padding-bottom: 15px; /* Espaço para a barra de rolagem não colar */
    scroll-snap-type: x mandatory; /* Faz o scroll parar certinho no card */
    -webkit-overflow-scrolling: touch; /* Rolagem suave no iPhone */
}

/* Estiliza a barra de rolagem para ficar bonita */
.lista-sabores::-webkit-scrollbar { height: 6px; }
.lista-sabores::-webkit-scrollbar-thumb { background-color: #ccc; border-radius: 10px; }
.lista-sabores::-webkit-scrollbar-track { background-color: #f1f1f1; }

.lista-sabores li {
    flex: 0 0 160px; /* Largura fixa para cada card no carrossel */
    scroll-snap-align: start; /* Alinha o card ao inicio ao soltar o scroll */
    background-color: #f9f9f9;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #eee;
    color: var(--cor-folha);
    font-weight: 500;
    cursor: pointer; /* Mostra a mãozinha ao passar o mouse */
    transition: all 0.2s;
}

.lista-sabores li.ativo {
    background-color: white;
    border-color: var(--cor-acerola);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: scale(1.02);
}

.controls-polpa {
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.lista-sabores li:hover {
    background-color: #e0e0e0;
    transform: scale(1.05);
}

/* Configuração da Imagem (Efeito de Expansão) */
.lista-sabores li img {
    display: block !important; /* Garante que a foto apareça sempre */
    height: 80px !important;   /* Altura inicial (miniatura) */
    transition: all 0.3s ease; /* Faz a animação de crescer ser suave */
}

.lista-sabores li.ativo img {
    height: 250px !important; /* Altura expandida quando clica */
}

/* Títulos das Categorias do Carrossel */
.titulo-categoria {
    color: var(--cor-acerola);
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    border-left: 4px solid var(--cor-folha);
    padding-left: 10px;
    text-align: left;
}

/* --- Barra de Resumo do Pedido (Fixo Embaixo) --- */
.resumo-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: white;
    border-top: 3px solid var(--cor-acerola);
    padding: 15px;
    box-shadow: 0 -4px 15px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 999;
    transform: translateY(100%); /* Escondido por padrão */
    transition: transform 0.3s ease-out;
}
.resumo-bar.visible { transform: translateY(0); }

/* Botão Limpar Carrinho */
.btn-limpar {
    background: none;
    border: 1px solid #ccc;
    color: #666;
    padding: 10px 15px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 0.9rem;
    margin-right: 10px;
    transition: all 0.2s;
}
.btn-limpar:hover { background-color: #f0f0f0; color: #333; border-color: #999; }

/* --- Agenda / Onde Encontrar --- */
.agenda {
    background-color: #e9f5ec;
    padding: 2rem;
    border-radius: 10px;
    margin-top: 3rem;
}

.agenda-title {
    border: none; 
    display: block;
}

.agenda ul { list-style: none; }

.agenda li {
    background: white;
    margin-bottom: 10px;
    padding: 15px;
    border-radius: 5px;
    border-left: 5px solid var(--cor-folha);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap; /* Permite quebrar linha no celular */
}

.agenda-note {
    text-align: center; 
    margin-top: 1rem; 
    font-size: 0.9rem;
}

/* --- Sobre Nós --- */
.sobre-nos {
    margin-top: 3rem;
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    text-align: center;
}

.sobre-nos p {
    color: #555;
    margin-bottom: 1rem;
    font-size: 1.05rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* --- Rodapé --- */
footer {
    background-color: #222;
    color: white;
    padding: 3rem 1rem;
    padding-bottom: 120px; /* Espaço para a barra de resumo ficar sobre o rodapé sem esconder texto */
    margin-top: 3rem;
}

.footer-container {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    text-align: center; /* Centralizado no celular fica melhor */
}

.footer-col h4 {
    color: var(--cor-acerola);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.footer-copy {
    text-align: center;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.8rem;
    opacity: 0.7;
}

/* Link do Desenvolvedor (Efeito Neon) */
.dev-link {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
}
.dev-link:hover {
    color: var(--cor-zap);
    text-shadow: 0 0 10px rgba(37, 211, 102, 0.8);
}

/* Ícones de Redes Sociais no Rodapé */
.footer-icon {
    width: 24px;
    height: 24px;
    vertical-align: middle;
}

/* --- Botão Flutuante do WhatsApp --- */
.zap-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--cor-zap);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.3);
    text-decoration: none;
    z-index: 200;
    transition: transform 0.3s;
}

.zap-float:hover {
    transform: scale(1.1);
}

/* Ajuste para telas muito pequenas */
@media (max-width: 400px) {
    .hero h2 { font-size: 2rem; }
    .agenda li { flex-direction: column; text-align: center; }
}

/* --- Toggle Atacado/Varejo --- */
.switch-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 1.5rem;
    font-weight: bold;
    color: var(--cor-folha);
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
}

.switch input { opacity: 0; width: 0; height: 0; }

.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 34px;
}

.slider:before {
    position: absolute; content: "";
    height: 20px; width: 20px; left: 4px; bottom: 4px;
    background-color: white; transition: .4s; border-radius: 50%;
}

input:checked + .slider { background-color: var(--cor-acerola); }
input:checked + .slider:before { transform: translateX(22px); }

/* --- Modal de Confirmação --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001; /* Acima de tudo */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0s 0.3s;
}

.modal-overlay.visible {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease;
}

.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.visible .modal-content {
    transform: scale(1);
}

.modal-content h4 {
    color: var(--cor-acerola);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.modal-botoes {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.btn-modal-confirmar, .btn-modal-cancelar {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-modal-confirmar {
    background-color: var(--cor-acerola);
    color: white;
}
.btn-modal-confirmar:hover {
    background-color: #b82f18;
}

.btn-modal-cancelar {
    background-color: #eee;
    color: #333;
}
.btn-modal-cancelar:hover {
    background-color: #ddd;
}
