/* --------- ESTILOS GENERALES EXISTENTES --------- */
.body{
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
}

main{
    min-height: 65vh;
    /* padding-inline: 12vw; */
    /* padding-top: 3vh; */
    padding-bottom: 3vh;
}
/* h1, h2, h3, h4, h5, h6, p {
    margin: 0;
} */
*{
    margin: 0;
    padding: 0;
}

/* --------- CARRUSEL --------- */

.carousel-wrap{
    /* width: 100%; */
    height: 50vh;
    min-height: 450px;
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
    margin-inline: auto;
}

.slide{
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    opacity: 0;
    transform: scale(1.03);
    animation: fade 12s infinite linear;
}

.slide:nth-child(1) {
    animation: fade 12s infinite linear, moveUpDown 20s ease-in-out infinite;
    animation-delay: 0s, 0s; /* fade, moveUpDown */
}

.slide:nth-child(2) {
    animation: fade 12s infinite linear, moveUpDown 30s ease-in-out infinite;
    animation-delay: 4s, 4s; /* fade, moveUpDown */
}

.slide:nth-child(3) {
    animation: fade 12s infinite linear, moveUpDown 30s ease-in-out infinite;
    animation-delay: 8s, 8s; /* fade, moveUpDown */
}

@keyframes fade{
    0%   { opacity: 0; }
    6%   { opacity: 1; transform: scale(1); }
    30%  { opacity: 1; }
    36%  { opacity: 0; }
    100% { opacity: 0; }
}
@keyframes moveUpDown {
    0% {
        background-position: center top;
    }
    50% {
        background-position: center bottom;
    }
    100% {
        background-position: center top;
    }
}

/* Texto fijo encima del carrusel */
.caption{
    position: absolute;
    left: 0;
    display: flex;
    text-align: start;
    padding: 2rem;
    z-index: 5;
    pointer-events: none;
}

.caption .box{
    background: rgba(0,0,0,0.20);
    padding: 1rem;
    border-radius: 10px;
    backdrop-filter: blur(4px);
    color: #fff;
}

.caption h1{
    font-size: clamp(1.4rem, 3vw, 2.3rem);
    margin-bottom: 1rem;
    /* padding-right: 40%; */
    font-family: 'encabezado';
}

.caption p{
    font-size: clamp(.9rem, 2vw, 1.2rem);
    opacity: .9;
    font-family: 'parrafo';
}

/* Dots del carrusel */
.dots{
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 15px;
    display: flex;
    gap: 10px;
    z-index: 6;
}

.dot{
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(255,255,255,0.35);
}

/* Accesibilidad */
@media (prefers-reduced-motion: reduce){
    .slide{
        animation: none;
        opacity: 1;
    }
}

/* Responsividad */
@media (max-width: 700px){
    main{
        padding-inline: 4vh;
    }
    .caption .box{
        padding: .8rem;
    }
}


/* -------PRODUCTOS---------- */
.products{
    /* width: 100%; */
    height: auto;
    margin-block: 5vh;
    border-top: 1px solid black;
    border-bottom: 1px solid black;
}
.products h2{
    padding-top: 2vh;
    font-family: 'encabezado';
    font-size: 35px;
    position: relative;
    text-align: center;
}

/*------------- CONTENEDOR DE PRODUCTOS ----------- */
.productsContainer{
    height: auto;
    display: flex;
    align-items: center;
    justify-content: space-evenly;
    margin-block: 5vh;
    padding: 0%;
}
.product_card{
    /* width: 90%; */
    background-color: #f0f0f0;
    border-radius: 5px;
    text-align: center;
}
.product_card:hover{
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
    transform: translateY(-5px);
    transition: transform 0.3s ease, box-shadow 0.1s ease;
    border: none;
}
.product_card.yellow:hover{
    background: linear-gradient(to right, #ffe8a2, rgb(247, 236, 208));
}
.product_card.green:hover{
    background: linear-gradient(to right, #f7fff3, #cffabe);
}
.product_info{
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.product_info h3 a{
    font-family: 'encabezado';
    color: black;
    margin-block: 50px;
    text-decoration: none;
}
.product_name p{
    font-family: 'parrafo';
    font-weight: bold;
}
.productsContainer a img {
    width: 80%;
    max-width: 300px;
    height: auto;
    cursor: pointer;
}
.product_details p{
    font-family: 'parrafo';
    font-size: 18px;
}
.product_card button{
    /* height: 20%; */
    background-color: white;
    border-radius: 5px;
    /* font-size: 18px; */
    font-family: 'encabezado';
    cursor: pointer;
    transition: transform 0.3s ease-in-out;
    border: 1px solid black;
}
.product_card button:hover{
    background-color: #8B9B81;
    color: white;
}

.description {
    width: 100%;
    height: 60vh;           /* misma altura que la imagen */
    position: relative;      /* para que los hijos absolutos se posicionen relativo a este contenedor */
}

.description .img {
    width: 100%;
    height: 100%;            /* ocupa toda la altura del contenedor */
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-image: url('/assets/images/Te-matcha-598e90cd.jpeg');
}

.description .text {
    position: absolute;
    top: 50%;
    right: 2rem;             /* mover el texto a la derecha */
    transform: translateY(-50%);
    z-index: 5;
    pointer-events: none;
    max-width: 30%;          /* tamaño máximo del cuadro */
    text-align: end;
}

.description .text .box {
    background: rgba(0,0,0,0.45);
    padding: 1rem;
    border-radius: 10px;
    backdrop-filter: blur(4px);
    color: #fff;
    font-size: 18px;
}
.beneficios{
    width: 100%;
    height: auto;
    margin-top: 10vh;
    margin-bottom: 5vh;
}
.beneficios h2{
    font-family: 'encabezado';
    text-align: center;
    font-size: 35px;
}
.benContainer{
    width: 100%;
    height: 50vh;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10vh;
}
.benContainer .benImg{
    width: auto;
    height: 45vh;
    border-radius: 25px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}
.benContainer .ben1{
    font-size: 25px;
    font-family: 'parrafo';
    text-align: end;
}
.benContainer .ben2{
    font-size: 25px;
    font-family: 'parrafo';
    text-align: start;
}
/* ---------------------------------------------------- */
/*                      MOBILE                          */
/* ---------------------------------------------------- */
@media (max-width: 576px){
    
    main{
        padding-inline: 4vw;
        margin-top: calc(var(--headerHeight) + 20px);
    }
    .product_card{
        width: 45%;
        /* max-width: 170px; */
    }
    .product_name a{
        font-size: 10px;
    }
    .product_details{
        display: none;
    }
    .product_card button{
        height: 30px;
        font-size: 10px;
    }
    .caption .box{
        text-align: center;
    }
    .caption .box p{
        font-size: 18px;
    }
    .caption .box .wide_subtext{
        display: none;
        
    }
    

    
}


/* ---------------------------------------------------- */
/*                      TABLET                          */
/* ---------------------------------------------------- */
@media (min-width: 577px) and (max-width: 1023px){
    main{
        margin-top: calc(var(--headerHeight) + 20px);
        padding-inline: 6vw;
    }
    .product_card{
        width: 45%;
        /* max-width: 300px; */
    }
    .product_name a{
        font-size: 12px;
    }
    .product_details{
        display: none;
    }
    .product_card button{
        height: 40px;
    }
    .caption .box{
        max-width: 40%;
    }
    .caption .box .short_subtext{
        display: none;
    }
}


/* ---------------------------------------------------- */
/*                  DESKTOP - ESTRECHO                  */
/* ---------------------------------------------------- */
@media (min-width: 1024px) and (max-width: 1223px){
    main{
        padding-inline: 8vw;
        margin-top: calc(var(--headerHeight) + 20px);
    }
    .product_card{
        width: 45%;
        max-width: 400px;
    }
    .product_card button{
        height: 40px;
        font-size: 18px;
    }
    .caption .box{
        max-width: 40%;
    }
    .caption .box .short_subtext{
        display: none;
    }
}



/* ---------------------------------------------------- */
/*                      DESKTOP                         */
/* ---------------------------------------------------- */
@media (min-width: 1224px) {
    main{
        padding-inline: 10vw;
        margin-top: calc(var(--headerHeight) + 20px);
    }
    .product_card{
        width: 45%;
        max-width: 400px;
    }
    .product_card button{
        height: 40px;
        font-size: 18px;
    }
    .caption .box{
        max-width: 40%;
    }
    .caption .box .short_subtext{
        display: none;
    }
}