/* =========================================
   1. VARIÁVEIS E BASE (MOBILE-FIRST)
   ========================================= */
:root {
    --color-primary: #7A1A2A;   /* Bordô - Use para Títulos e Destaques Fortes */
    --color-secondary: #D4AF37; /* Dourado - Use para ícones e linhas finas */
    --color-dark: #2C3034;      /* Chumbo - Para textos de leitura longa */
    --color-light: #FDFCFB;     /* Creme mais claro - Para um fundo mais limpo */
    --color-white: #ffffff;
    --color-whatsapp: #25D366;

    --transition-default: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    --font-titles: 'Playfair Display', serif; /* Fonte clássica de luxo */
    --font-body: 'Poppins', sans-serif;       /* Fonte moderna e limpa */
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--color-dark);
    background-color: var(--color-light);
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

/* Aplicando a Playfair Display para Títulos de impacto */
h1, h2, .produto-nome {
    font-family: var(--font-titles);
    font-weight: 700;
    letter-spacing: -0.02em;
}

.drop-shadow {
    filter: drop-shadow(0 0.2rem 0.2rem rgba(0,0,0,0.15));
}

/* =========================================
   2. NAVBAR
   ========================================= */
.bg-primary-custom {
    background-color: var(--color-light);
}

header nav {
    outline-color: #7A1A2A;
}

.nav-logo {
    width: auto;
    height: 2.5rem; 
    object-fit: contain;
    transition: var(--transition-default);
}

.navbar-brand:hover .nav-logo {
    transform: scale(1.05);
}

.navbar-nav .nav-link {
    color: var(--color-dark);
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
    position: relative;
    padding: 0.5rem 0;
    transition: var(--transition-default);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus {
    color: var(--color-primary) !important;
}

.navbar-clean {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(212, 175, 55, 0.2); /* Linha dourada ultra fina */
}

/* Enfeite no Título (Destaque para sabores excepcionais) */
.text-highlight {
    color: var(--color-secondary);
    position: relative;
    display: inline-block;
}

/* Linha rústica abaixo do destaque do título */
.text-highlight::after {
    content: "";
    position: absolute;
    width: 100%;
    height: 4px;
    bottom: 5px;
    left: 0;
    background: var(--color-secondary);
    opacity: 0.4;
    border-radius: 2px;
}

/* Moldura decorativa para a foto Hero (Desktop) */
.hero-image-wrapper {
    position: relative;
    padding: 1rem;
}

/* O "Sua casa do Queijos e Cia" bem elaborado */
.hero-fancy-subtitle {
    font-family: var(--font-titles);
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: var(--color-dark);
    font-weight: 700;
    line-height: 1.2;
}

/* Mantendo a moldura de quadro no Carrossel */
.hero-img-frame {
    border: 8px solid var(--color-white);
    border-radius: 4px;
    overflow: hidden; /* Garante que as fotos não vazem da borda redonda */
    background-color: var(--color-white);
}


/* Padronizando o tamanho das fotos do carrossel para não pular a tela */
.hero-img-frame img {
    aspect-ratio: 4/5; /* Formato retrato chique */
    object-fit: cover; /* Faz a foto preencher a moldura sem distorcer */
}

/* Ajustes finos no mobile para a nova logo */
@media (max-width: 991px) {
    .hero-main-logo {
        max-width: 200px;
        margin-top: 1rem;
    }
    
    .hero-fancy-subtitle {
        font-size: 2rem !important;
    }
}
.hero-fancy-subtitle span {
    font-style: italic; /* Dá o toque elegante na parte do "Queijos & Cia" */
}

/* Cantoneiras douradas para a foto */
.hero-image-wrapper::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 80px;
    height: 80px;
    border-top: 3px solid var(--color-secondary);
    border-right: 3px solid var(--color-secondary);
    z-index: -1;
}

.hero-image-wrapper::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80px;
    height: 80px;
    border-bottom: 3px solid var(--color-secondary);
    border-left: 3px solid var(--color-secondary);
    z-index: -1;
}

/* Sombra suave e borda na imagem hero */
.hero-img {
    border: 8px solid var(--color-white);
    box-shadow: 0 1rem 3rem rgba(0,0,0,0.1);
}


/* Botão CTA Principal */
.btn-cta {
    background-color: var(--color-light);
    color: var(--color-dark);
    border: 0.15rem solid var(--color-dark);
    transition: var(--transition-default);
}

.btn-cta:hover {
    background-color: transparent;
    color: var(--color-primary);
    border-color: var(--color-dark);
    transform: translateY(-0.2rem);
}

.elegant-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.divider-line {
    height: 1px;
    flex: 1;
    max-width: 300px;
    background: linear-gradient(to right, transparent, var(--color-secondary), transparent);
}

.divider-icon {
    color: var(--color-secondary);
    opacity: 0.9;
    transform: rotate(45deg); /* Losango */
}

/* Ajuste no padding do Hero para não ficar um buraco */
@media (max-width: 991px) {
    /* Zera o espaço no topo da vitrine especificamente no mobile */
    #vitrine.produtos-section {
        padding-top: 0 !important;
    }

    /* Ajusta o espaçamento do divisor para que ele "cole" na vitrine */
    .elegant-divider {
        padding: 0 !important;
        margin-bottom: 0 !important;
        padding-bottom: 0 !important;
        background-color: var(--color-white); /* Mantém a cor do Hero */
    }

    /* Ajusta a margem da vitrine para compensar o divisor */
    .section-header {
        margin-top: 1rem !important;
        margin-bottom: 2rem !important;
    }
}

/* =========================================
   3. MEDIA QUERIES (DESKTOP)
   ========================================= */
@media (min-width: 992px) {
    /* Logo cresce de forma fluida para telas grandes */
    .nav-logo {
        height: 3.5rem; 
    }
    
    /* Efeito de sublinhado nos links ativo apenas no PC */
    .navbar-nav .nav-link::after {
        content: '';
        position: absolute;
        width: 0;
        height: 0.2rem;
        bottom: 0;
        left: 50%;
        background-color: var(--color-secondary);
        transition: var(--transition-default);
        transform: translateX(-50%);
    }

    .navbar-nav .nav-link:hover::after {
        width: 100%;
    }
}

/* =========================================
   UTILITÁRIOS E CORES
   ========================================= */
.bg-light-custom { background-color: var(--color-light); }
.text-primary-custom { color: var(--color-primary); }

.text-highlight {
    color: var(--color-secondary);
    background: linear-gradient(120deg, rgba(212, 175, 55, 0.1) 0%, rgba(212, 175, 55, 0.1) 100%);
    background-repeat: no-repeat;
    background-size: 100% 0.3em;
    background-position: 0 88%;
}

section { padding: 2rem 0; }
.section-header { margin-bottom: 3rem; }
.section-header h2 {
    font-size: clamp(2rem, 4vw, 2.5rem);
    color: var(--color-primary);
    font-weight: 700;
}

/* =========================================
   4. HERO SECTION
   ========================================= */
.hero-section {
    min-height: 80vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--color-white) 0%, var(--color-light) 100%);
}

.custom-shape-divider-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    transform: rotate(180deg); /* Inverte para a curva subir suavemente */
}

.custom-shape-divider-bottom svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 80px; /* Altura da onda */
}

.custom-shape-divider-bottom .shape-fill {
    /* Usa a cor de fundo da seção vitrine para a transição ficar invisível */
    fill: var(--color-secondary); 
}


/* Detalhe de marca-texto dourado */
.text-highlight::after {
    content: "";
    position: absolute;
    width: 105%; /* Um pouquinho maior que o texto */
    height: 8px;
    bottom: 2px;
    left: -2%;
    background: var(--color-secondary);
    opacity: 0.25; /* Bem suave, como um marca-texto dourado */
    z-index: -1; /* Fica atrás da letra */
    border-radius: 2px;
    transform: rotate(-1deg); /* Levemente inclinado para parecer manual */
}

/* Ajuste para celular */
@media (max-width: 767px) {
    .custom-shape-divider-bottom svg {
        height: 40px;
    }
}

.hero-content {
    display: flex;
    align-items: center;
    text-align: center;
    gap: 2rem;
}

.hero-text { 
    width: 100%;
    flex: 1; 
}

.hero-image-wrapper { 
    flex: 1; 
    text-align: center; 
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.hero-img { width: 100%; max-width: 35rem; height: auto; object-fit: contain; }

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--color-dark);
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: #555;
    margin-bottom: 2rem;
}

.btn-large {
    font-size: 1.1rem;
    padding: 1rem 2.5rem;
}

/* Ajuste Fino para Mobile */
@media (max-width: 991px) {
    .hero-section {
        padding-top: 0rem !important;   /* Diminui a distância do NAV */
        padding-bottom: 1rem !important;
        min-height: auto !important;    /* Remove a altura mínima forçada */
    }

    .hero-title {
        font-size: 2rem !important;     /* Diminui um pouco o título no celular */
        margin-top: 1rem !important;
        margin-bottom: 0.5rem !important;
    }

    .hero-content {
        gap: 0rem !important; /* Distância mínima entre texto e imagem */
        padding-top: 0 !important;
        flex-direction: column; /* Texto em cima, Imagem embaixo no mobile */
    }

    .hero-subtitle {
        margin-bottom: 0.5rem !important;
        font-size: 0.95rem !important;
        margin-bottom: 0.5rem !important;
        line-height: 1.4;
    }

    .hero-image-wrapper {
        max-width: 300px !important;    /* Foto menor para caber na tela sem scroll */
        margin-top: 0 !important;
        padding-top: 0 !important;
    }
    
    .hero-img {
        border-width: 8px !important;   /* Moldura mais fina para ganhar espaço */
    }
}

/* =========================================
    5. VITRINE (GRID FLUIDO ALINHADO)
   ========================================= */

/* Subtítulos das Vitrines */
.vitrine-subtitle {
    font-family: var(--font-titles);
    color: var(--color-primary);
    font-size: clamp(1.8rem, 3vw, 2.2rem);
    font-weight: 700;
    position: relative;
    display: inline-block;
    padding-bottom: 0.5rem;
    margin-bottom: 0.5rem;
}

.vitrine-subtitle::after {
    content: "";
    position: absolute;
    width: 60px;
    height: 3px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--color-secondary);
    border-radius: 2px;
}

/* Container Principal com Grid Moderno (Substitui o column-count) */
.produtos-masonry {
    display: grid;
    /* Grid fluido sem precisar de media queries. Cria colunas conforme o espaço! */
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 2rem;
    align-items: stretch; /* Garante que todos os cards na mesma linha tenham a mesma altura */
}

/* O Card se torna um Flex Container */
.produto-card {
    background: var(--color-white);
    border-radius: 1.2rem;
    overflow: hidden;
    display: flex;
    flex-direction: column; /* Empilha foto e informações */
    height: 100%;           /* Ocupa 100% da altura esticada pelo Grid */
    transition: var(--transition-default);
    box-shadow: 0 0.5rem 1.5rem rgba(0,0,0,0.05);
}

.produto-card:hover { 
    transform: translateY(-0.5rem); 
    box-shadow: 0 1rem 2.5rem rgba(0,0,0,0.1);
}

/* A Imagem em si */
.produto-img {
    width: 100%;
    height: 100%;
    object-fit: contain; 
    display: block;
    transition: var(--transition-default);
}

.produto-img-wrapper {
    height: 350px; /* Altura fixa para manter o padrão das fotos */
    background-color: #f0ece6;
    display: flex;
    align-items: center;     
    justify-content: center; 
    border-bottom: 2px solid var(--color-light);
    overflow: hidden;
    position: relative; 
    cursor: pointer;    
}

.badge-item {
    background-color: rgba(255, 255, 255, 0.9);
    color: var(--color-primary);
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 5px;
}

.badge-item i {
    font-size: 0.7rem;
    color: var(--color-secondary);
}

.produto-badges {
    position: absolute;
    top: 15px;
    left: 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 3;
}

.zoom-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.4); 
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0; 
    transition: var(--transition-default);
    z-index: 2;
}

.produto-img-wrapper:hover .zoom-overlay {
    opacity: 1; 
}

.zoom-overlay i {
    color: var(--color-white);
    font-size: 3rem;
    transform: scale(0.5); 
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.produto-img-wrapper:hover .zoom-overlay i {
    transform: scale(1); 
}

/* Área de informações Flex */
.produto-info {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1; /* Faz esta área preencher o restante do cartão */
}

.produto-nome { 
    font-size: 1.25rem; 
    font-weight: 700; 
    margin-bottom: 0.5rem; 
    color: var(--color-dark); 
}

/* O "Pulo do Gato": a mola que empurra o rodapé para baixo */
.produto-desc { 
    font-size: 0.9rem; 
    color: #666; 
    margin-bottom: 1.5rem; 
    flex-grow: 1; /* Estica para preencher o vazio e empurrar o preço para baixo */
}

.produto-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #eee;
    padding-top: 1rem;
    /* margin-top: auto; (pode manter, mas o flex-grow acima já resolve) */
}

.produto-preco {
    font-family: var(--font-titles);
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--color-primary);
}

.btn-whatsapp-small {
    background-color: var(--color-whatsapp);
    color: var(--color-white);
    padding: 0.5rem 1.2rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 50px;
    transition: var(--transition-default);
}
.btn-whatsapp-small:hover { background-color: #128C7E; color: var(--color-white); }

/* =========================================
   6. LOJA
   ========================================= */
.loja-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: stretch; /* Garante que a foto e a caixa da direita tenham a mesma altura */
}

.loja-col-direita {
    margin-top: 0 !important;
}

.fachada-img {
    width: 100%;
    aspect-ratio: 9 / 9;
    object-fit: cover;
    border-radius: 1rem;
    margin-bottom: 10%;
}

.loja-info h2 { color: var(--color-primary); margin-bottom: 2rem; font-weight: 700; }
.info-bloco h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.5rem; }
.info-bloco { margin-bottom: 1.5rem; }

.loja-mapa {
    aspect-ratio: 1 / 1;
    border-radius: 1rem;
    overflow: hidden;
}

/* =========================================
   7. AVALIAÇÕES (REVIEWS)
   ========================================= */
.review-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08) !important;
}

/* =========================================
   8. RODAPÉ REESTRUTURADO
   ========================================= */
.footer-custom {
    background-color: var(--color-light); /* Fundo creme premium */
    padding: 5rem 0 2rem;
    border-top: 1px solid rgba(212, 175, 55, 0.2); /* Linha dourada fina */
}

/* Ajuste de tamanho da logo no rodapé */
.footer-logo {
    height: 4rem; /* Altura controlada para não dominar a seção */
    width: auto;
    object-fit: contain;
    margin-bottom: 1.5rem;
    filter: brightness(0); /* Opcional: deixa a logo totalmente preta para um visual mais sóbrio */
    opacity: 0.9;
}

/* No mobile, podemos deixar ela um pouco menor se necessário */
@media (max-width: 767px) {
    .footer-logo {
        height: 3.5rem;
    }
}
.footer-title {
    font-family: 'Playfair Display', serif; /* Mantém a fonte clássica nos títulos */
    color: var(--color-primary);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    position: relative;
}

/* Detalhe dourado abaixo do título do rodapé */
.footer-title::after {
    content: "";
    position: absolute;
    width: 30px;
    height: 2px;
    background-color: var(--color-secondary);
    bottom: -8px;
    left: 0;
}

.footer-tagline {
    font-size: 0.9rem;
    color: #666;
    max-width: 300px;
}

.footer-links li, .footer-info li {
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

.footer-links a {
    text-decoration: none;
    color: var(--color-dark);
    transition: var(--transition-default);
}

.footer-links a:hover {
    color: var(--color-primary);
    padding-left: 5px;
}

.footer-info i {
    color: var(--color-secondary);
    width: 20px;
}

.social-icon {
    width: 40px;
    height: 40px;
    background-color: var(--color-white);
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    transition: var(--transition-default);
    text-decoration: none;
}

.social-icon:hover {
    background-color: var(--color-primary);
    color: var(--color-white);
    transform: translateY(-3px);
}

.footer-bottom p {
    letter-spacing: 0.5px;
}

/* =========================================
   MEDIA QUERIES APENAS PARA LAYOUT
   ========================================= */
@media (min-width: 992px) {
    /* Destrava o grid da história e loja para o lado a lado no PC */
    .historia-grid, .loja-grid {
        grid-template-columns: 1fr 1fr;
    }
    .loja-mapa { aspect-ratio: 16 / 9; }

    .loja-col-direita {
        margin-top: 6.5rem; /* Empurra o bloco inteiro para baixo até alinhar com a foto */
    }
}

/* =========================================
   9. ANIMAÇÕES E MICROINTERAÇÕES (FRUFRUS)
   ========================================= */

/* EFEITO 1: "Respiração" (Flutuação) na Foto do Hero */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); } /* Sobe 10px suavemente */
    100% { transform: translateY(0px); }
}

.hero-img {
    animation: float 6s ease-in-out infinite;
}

/* EFEITO 2: Reflexo de Brilho nos Botões (Como um flash de luz passando) */
@keyframes shine {
    0% { left: -100%; }
    20% { left: 200%; }
    100% { left: 200%; }
}

.btn-cta, .btn-whatsapp-small {
    position: relative;
    overflow: hidden; /* Não deixa o brilho vazar do botão */
}

.btn-cta::after, .btn-whatsapp-small::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    /* Cria a faixa de luz semi-transparente */
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.4) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg); /* Dá a inclinação da luz */
    animation: shine 4s infinite; /* Repete a cada 4 segundos */
}

/* EFEITO 3: Entrada Suave (Fade In Up) no Texto Inicial ao carregar a página */
@keyframes fadeInUp {
    from { 
        opacity: 0; 
        transform: translateY(30px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

.hero-text {
    animation: fadeInUp 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

/* EFEITO 4: O "Marca-Texto" Dourado crescendo ao passar o mouse */
.vitrine-subtitle::after {
    transition: var(--transition-default);
}

.vitrine-divisor:hover .vitrine-subtitle::after {
    width: 100px; /* A linha dourada estica quando passa o mouse perto do título */
    background-color: var(--color-primary); /* Muda pra bordô */
}