/* =========== RESET BÁSICO Y ESTILOS GLOBALES =========== */
:root {
    /*--color-primary: #386641; /* Verde principal */
    --color-primary: #664288; 
    /*--color-secondary: #6A994E; /* Verde más claro */
    --color-secondary: #775398; 
    --color-light-green: #F2E8CF; /* Verde muy claro para fondos */
    --color-text: #333;
    --color-text-light: #f8f9fa;
    --color-white: #ffffff;
    --color-gray: #6c757d;
    --font-family-base: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family-base);
    color: var(--color-text);
    background-color: #fdfdfd;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    width: 90%;
    max-width: 1140px;
    margin-left: auto;
    margin-right: auto;
}

/* =========== CABECERA Y NAVEGACIÓN (Reutilizada) =========== */
.main-header {
    background-color: var(--color-white);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: #ad8fc2;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    height: 125px;
}

.logo {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--color-primary);
}

/*.logo img {

    border-radius: 20%;
    width: 150px;
    position: relative  
    
} */

.logo_1 img {
  
    width: 200px;
    position: relative;
       
}

.logo_2 img {

    width: 100px;
    position: relative;
        
}

.nav-desktop {
    display: none;
    align-items: center;
    gap: 1.5rem;
}

.nav-desktop a {
    font-weight: 500;
    color: var(--color-text);
    transition: color 0.3s ease;
}

.nav-desktop a:hover {
    color: var(--color-primary);
}

.menu-button {
    display: block;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text);
}

.nav-mobile {
    display: none;
    background-color: var(--color-white);
    border-top: 1px solid #eee;
}

.nav-mobile.is-open {
    display: block;
}

.nav-mobile a {
    display: block;
    padding: 1rem 5%;
    font-weight: 500;
}

.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 9999px;
    font-weight: 700;
    text-align: center;
    display: inline-block;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-white);
}

.btn-primary:hover {
    background-color: var(--color-secondary);
    transform: translateY(-2px);
}

/* ========================================================== */
/* =========== INICIO: ESTILOS PÁGINA DE PRODUCTOS -- IMAGEN DE FONDO ENCABEZADO=========== */
/* ========================================================== */
.page-header-products {
    background: url('../img/productos_fondo.png?auto=compress&cs=tinysrgb&w=1260&h=650&dpr=1') no-repeat center center/cover;
    position: relative;
    padding: 6rem 0;
    text-align: center;
    color: var(--color-white);
    min-height: 400px;
}

.page-header-overlay {
    background-color: rgba(0, 0, 0, 0.4);
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    
}

.page-header-products h1 {
    font-size: 3rem;
    font-weight: 700;
}

.product-category {
    padding: 4rem 0;
}

.product-category.bg-light {
    background-color: #f8f9fa;
}

.category-title {
    font-size: 2.25rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--color-primary);
}

/* --- NUEVO: Layout de Grilla Responsiva (Mobile-First) --- */
.product-grid {
    display: grid;
    /* Móvil: 1 columna por defecto */
    grid-template-columns: 1fr;
    gap: 2.5rem;
}

.product-card {
    background-color: var(--color-white);
    border-radius: 8px;
    text-align: center;
    padding: 2rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    /*agregado*/
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Asegura que el botón se alinee abajo */
    /*--------*/
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.product-card img {
    height: 250px;
    /*agregado*/
    object-fit: cover; /* Asegura que las imágenes se vean bien */
    margin: 0 auto 1.5rem auto;
    border-radius: 8px;
}

.product-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.product-card p {
    color: var(--color-gray);
    font-size: 0.95rem;
    /*agregado*/
    margin-bottom: 1rem;
}

/* ========================================================== */
/* =========== INICIO: ESTILO DE PRECIO AÑADIDO ============== */
/* ========================================================== */
.product-price {
    font-size: 1.25rem;
    font-weight: 700; /* Equivalente a bold */
    color: var(--color-primary);
    margin-top: auto; /* Empuja el precio hacia arriba si hay espacio */
    margin-bottom: 1rem; /* Espacio antes del botón */
    /*margin-top: 1rem; */
    
}

/*agregado*/
.product-card .btn {
    margin-top: 1rem; /* Espacio sobre el botón */
}
/*--------*/


.product-card .product-price {

    font-size: 1.15rem ;
}

/* ======================================================== */
/* =========== FIN: ESTILO DE PRECIO AÑADIDO ================ */
/* ======================================================== */


/* --- NUEVO: Clases para Animaciones con JS --- */
.card-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.card-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .card-reveal {
        transition: none;
    }
    .product-card:hover {
        transform: none;
    }
    .btn:hover {
        transform: none;
    }
}

/* -****-- NUEVO: Clases para Animaciones con JS --****- */


/* ======================================================== */
/* =========== FIN: ESTILOS PÁGINA DE PRODUCTOS ============= */
/* ======================================================== */


/* =========== PIE DE PÁGINA COMPLETO ====== */
.main-footer {
    background-color: #212529;
    color: var(--color-text-light);
    padding: 3rem 0 2rem 0;
    
}
.main-footer .container div {

    margin-left: 27px;
    margin-right: 27px;
}


/*AGREGADO PARA QUE TODO LOS ELEMENTOS DE PIE DE PAGINA SE PONGA A LADO DEL OTRO*/
.footer-grid{

    display: flex;
    flex-wrap: wrap;
    gap: 150px;

}
/*
.footer-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(2, 1fr);
} */

.footer-grid h4 {
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-grid ul li {
    margin-bottom: 0.5rem;
}

.footer-grid ul a {
    color: #ced4da;
    transition: color 0.3s ease;
}

.footer-grid ul a:hover {
    color: var(--color-secondary);
}

.social-icons {
    display: flex;
    gap: 1rem;
}
.social-icons a svg {
    width: 24px;
    height: 24px;
}

.footer-bottom {
    border-top: 1px solid #495057;
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    font-size: 0.9rem;
    color: var(--color-gray);
}


/*----------------------MARCA PERU LOGO --------------------*/
.marca-peru {
    grid-column: span 1;
    display: flex;
    justify-content: center;
    align-items: center;
    
    
}

.marca-peru img {
    max-width: 160px;
    transition: transform 0.3s ease, filter 0.3s ease;
    cursor: pointer;
}
    
   
.marca-peru img:hover {
    transform: scale(1.1);
    filter: brightness(1.2);
}
/*----------------------MARCA PERU LOGO --------------------*/


/* =========== DISEÑO RESPONSIVO (Media Queries) =========== */
/*
@media (min-width: 640px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .nav-desktop {
        display: flex;
    }
    .menu-button {
        display: none;
    }
    .footer-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .product-category .product-grid {
        grid-template-columns: repeat(2, 1fr); 
        max-width: 900px;
        margin: 0 auto;
    }

} /*

/* =========== DISEÑO RESPONSIVO (Media Queries) =========== */

/* --- TABLET: 2 Columnas para las grillas --- */
@media (min-width: 768px) {
    .nav-desktop {
        display: flex;
    }
    .menu-button {
        display: none;
    }
    
    #seccion-2 .product-grid,
    #seccion-3 .product-grid,
    #seccion-4 .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
    }
}

/* --- DESKTOP: 3 Columnas y ajustes finales --- */
@media (min-width: 1024px) {
    /* La card principal de leche se mantiene centrada y más grande */
    #seccion-leche .product-grid {
        grid-template-columns: 1fr;
        max-width: 500px; /* Ancho máximo para la card principal */
        margin: 0 auto;
    }

    /* Las otras secciones usan 3 columnas */
    #seccion-2 .product-grid,
    #seccion-3 .product-grid,
    #seccion-4 .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}
