/* ==========================================================================
   40. HOME: TRAZABILIDAD Y DESTACADOS (#home)
   ========================================================================== */
#home .traceability {
    display: grid;
    place-items: center;
    height: 70vh;
    background-repeat: no-repeat;
    background-position: top center;
    background-size: cover;

    @media screen and (max-width: 767px) {
        margin-top: -7rem;
    }
}

/* Tarjeta Producto Destacado (Best Seller) */
#home .outstanding .best-seller-cta {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    position: relative;
    min-height: 320px;
    padding: 40px;
    margin-bottom: 2rem;
    background-color: var(--secondary-green);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    color: var(--cream-dark);
    border-radius: 24px;
    overflow: hidden;
}

#home .outstanding .best-seller-cta .title-header {
    z-index: 10;
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 600; /* SemiBold Mori */
    line-height: 16px;
}

#home .outstanding .best-seller-cta .title {
    z-index: 10;
    max-width: 60%;
    margin: 20px 0;
    font-family: var(--font-heading); /* PPRader */
    font-size: 32px;
    font-weight: 700; /* Bold Rader */
    text-transform: uppercase;
}

@media (max-width: 600px) {
    #home .outstanding .best-seller-cta {
        min-height: 375px;
    }
    #home .outstanding .best-seller-cta .title {
        width: 100%;
    }
}

/* ==========================================================================
   41. HOME: SLIDER DE CATEGORÍAS (.categories-slider)
   ========================================================================== */
#home .categories .categories-slider .category {
    display: grid;
    place-items: center;
    position: relative;
    width: 230px;
    height: 160px;
    background-color: var(--secondary-green);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    border-radius: 24px;
    overflow: hidden;
}

#home .categories .categories-slider .category .redirection {
    z-index: 10;
    padding: 30px;
    color: var(--cream-dark);
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 700;
    line-height: 32px;
    text-align: center;
    text-transform: uppercase;
}

@media (max-width: 960px) {
    #home .categories .categories-slider .category {
        width: 144px;
        height: 144px;
        margin: 0 auto;
    }
}

@media (max-width: 600px) {
    #home .categories .categories-slider .category {
        width: 100%;
        margin: 0 30px;
    }
}

/* ==========================================================================
   42. HOME: HISTORIAS (.stories-slider)
   ========================================================================== */
#home .stories .stories-slider {
    padding: 40px 0;
}

#home .stories .stories-slider .story {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    width: 230px;
    height: 300px;
    margin: 0;
    padding: 30px;
    background-color: var(--primary-green);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    border-radius: 24px;
    color: var(--cream-dark);
    line-height: 24px;
}

#home .stories .stories-slider .story .user-name {
    font-family: var(--font-main);
    font-weight: 800;
    font-size: 16px;
}

#home .stories .stories-slider .story .user-link {
    font-family: var(--font-main);
    font-weight: 600;
    font-size: 12px;
}

@media (max-width: 960px) {
    #home .stories .stories-slider .story {
        margin: 0 30px;
    }
}

@media (max-width: 500px) {
    #home .stories .stories-slider .story {
        width: 100%;
        margin: 0 30px;
    }
}

/* ==========================================================================
   43. HOME: BANNER HERO (.banner-slider)
   ========================================================================== */
#home .banner {
    height: 100vh;
}

#home .banner .banner-slider {
    list-style: none;
    padding: 0;
}

#home .banner .banner-slider .banner-element {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    height: 100vh;
    min-height: 680px;
    text-align: center;
    color: var(--cream-dark);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    text-transform: uppercase;
}

#home .banner .banner-slider .banner-element .category {
    z-index: 10;
    font-family: var(--font-heading);
    font-size: 32px;
    font-weight: 700; /* Bold Rader */
    line-height: 48px;
    letter-spacing: 0.62px;
}

#home .banner .banner-slider .banner-element .title {
    z-index: 10;
    margin: 40px 0 20px;
    font-family: var(--font-heading);
    font-size: 72px;
    font-weight: 700;
    line-height: 80px;
    letter-spacing: 1.38px;
}

#home .banner .banner-slider .banner-element .subtitle {
    z-index: 10;
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 500;
    line-height: 32px;
}

@media only screen and (max-width: 720px) {
    #home .banner .banner-slider .banner-element {
        padding: 0 2rem;
    }
    #home .banner .banner-slider .banner-element .category {
        font-size: 20px;
        line-height: 30px;
    }
    #home .banner .banner-slider .banner-element .title {
        font-size: 48px;
        line-height: 60px;
        letter-spacing: 1px;
        margin: 20px 0 10px;
    }
}

/* ==========================================================================
   44. HOME: FILTROS DE TIENDA (#home .store)
   ========================================================================== */
#home .store .store-nav .store-filter {
    display: flex;
    align-items: center;
    gap: 40px;
    margin: 0;
    padding: 0;
    list-style: none;
}

#home .store .store-nav .store-filter .filter-element button {
    padding-bottom: 10px;
    background-color: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: inherit;
    font-family: var(--font-main);
    font-size: 24px;
    font-weight: 600;
    line-height: 18px;
    cursor: pointer;
    transition: var(--transition-fast);
}

#home .store .store-nav .store-filter .filter-element button.selected,
#home .store .store-nav .store-filter .filter-element button:hover {
    border-bottom-color: var(--primary-green);
}

/* ==========================================================================
   45. HOME: SLIDER DE POSTS (#home .posts)
   ========================================================================== */
#home .posts .posts-slider .post {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    position: relative;
    width: 230px;
    height: 300px;
    margin: 0;
    padding: 30px;
    background-color: var(--primary-green);
    color: var(--cream-dark);
    border-radius: 24px;
    line-height: 24px;
    overflow: hidden;
}

#home .posts .posts-slider .post .thumbnail {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#home .posts .posts-slider .post .post-category {
    position: absolute;
    top: 15px;
    left: 15px;
}

#home .posts .posts-slider .post .title {
    font-family: var(--font-main);
    font-size: 20px;
    font-weight: 600;
    line-height: 24px;
}

#home .posts .posts-slider .post .redirection {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    position: sticky;
    transition: all 1s;
}

#home .posts .posts-slider .post:hover .thumbnail {
    backdrop-filter: brightness(50%);
}

#home .posts .posts-slider .post:hover .redirection {
    bottom: 15px;
}

@media (max-width: 960px) {
    #home .posts .posts-slider .post { margin: 0 30px; }
}

@media (max-width: 500px) {
    #home .posts .posts-slider .post { width: 100%; margin: 0 30px; }
}

/* ==========================================================================
   46. HOME: HOT SPOTS - GRID LAYOUT
   ========================================================================== */
#home .front-page-hot-spots {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: auto auto;
    grid-gap: 10px;
}

#home .front-page-hot-spots .content-element {
    display: flex;
    justify-content: center;
    align-items: center;
}

#home .front-page-hot-spots .content-element.a { grid-column: 1/2; grid-row: 1; }
#home .front-page-hot-spots .content-element.b { grid-column: 2/4; grid-row: 1; }
#home .front-page-hot-spots .content-element.c { grid-column: 1/3; grid-row: 2; }
#home .front-page-hot-spots .content-element.d { grid-column: 3/4; grid-row: 2; }

/* ==========================================================================
   47. HOME: HOT SPOTS - COMPONENTE (.extra-content)
   ========================================================================== */
#home .front-page-hot-spots .content-element .info-container {
    position: relative;
}

#home .front-page-hot-spots .content-element .info-container img {
    width: 250px;
    object-fit: cover;
    height: auto;
}

#home .front-page-hot-spots .content-element .info-container .extra-content {
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 40%;
    right: 20%;
    width: 40px;
    height: 40px;
    background-color: var(--primary-green);
    border-radius: 50%;
}

#home .front-page-hot-spots .content-element .info-container .extra-content::before {
    content: "+";
    color: var(--primary-dark-green);
    font-size: 29px;
    font-weight: 400;
}

/* Posicionamiento específico de puntos */
#home .front-page-hot-spots .content-element.a .info-container .extra-content,
#home .front-page-hot-spots .content-element.c .info-container .extra-content {
    top: 30%;
    left: 30%;
}

#home .front-page-hot-spots .content-element.b .info-container .extra-content,
#home .front-page-hot-spots .content-element.d .info-container .extra-content {
    top: 55%;
    left: 80% !important;
}

/* ==========================================================================
   48. HOME: HOT SPOTS - POPUPS (.information)
   ========================================================================== */
#home .front-page-hot-spots .content-element .info-container .extra-content .information {
    position: absolute;
    top: 50%;
    right: 0%;
    z-index: 10;
    padding: 0.5rem 1.5rem;
    background-color: var(--pure-white);
    border-radius: 2rem;
    transform: translate(105%, -50%);
}

#home .front-page-hot-spots .content-element .info-container .extra-content .information__title {
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 800; /* ExtraBold Mori */
    line-height: 16px;
    white-space: nowrap;
}

#home .front-page-hot-spots .content-element .info-container .extra-content .information ul {
    display: none;
    margin: 0;
    padding: 0;
    list-style: none;
}

#home .front-page-hot-spots .content-element .info-container .extra-content .information ul li {
    margin: 0.75rem 0;
    padding: 0;
}

/* Variación: Popup a la Izquierda */
#home .front-page-hot-spots .content-element .info-container .extra-content.left {
    right: auto;
    left: 20%;
}

#home .front-page-hot-spots .content-element .info-container .extra-content.left .information {
    position: absolute;
    top: 50%;
    right: 0%;
    z-index: 10;
    padding: 0.5rem 1.5rem;
    background-color: var(--pure-white);
    border-radius: 2rem;
    transform: translate(-25%, -50%);
}

#home .front-page-hot-spots .content-element .info-container .extra-content.left .information__title {
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 800;
    line-height: 16px;
    white-space: nowrap;
}

/* ==========================================================================
   49. HOME: HOT SPOTS - RESPONSIVO
   ========================================================================== */
@media (max-width: 1250px) {
    #home .front-page-hot-spots .content-element .info-container img { width: 200px; height: auto;}
}

@media (max-width: 720px) {
    #home .front-page-hot-spots .content-element .info-container img { width: 150px; height: auto;}
}

/* ==========================================================================
   50. HOME: HOT SPOTS - INTERACCIONES DESKTOP
   ========================================================================== */
@media (min-width: 1251px) {
    /* Cambio de símbolo al interactuar */
    #home .front-page-hot-spots .content-element .info-container .extra-content:hover::before,
    #home .front-page-hot-spots .content-element .info-container .extra-content:focus::before,
    #home .front-page-hot-spots .content-element .info-container .extra-content:active::before {
        content: "-";
    }

    /* Animación del Popup (Normal) */
    #home .front-page-hot-spots .content-element .info-container .extra-content:hover .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content:focus .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content:active .information {
        top: 0%;
        min-width: 250px;
        padding-top: 1rem;
        transform: translate(105%, 0%);
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content:hover .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content:focus .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content:active .information__content {
        display: block;
    }

    /* Animación del Popup (Izquierda) */
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:hover .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:focus .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:active .information {
        transform: translate(-25%, 0%);
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content.left:hover .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:focus .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:active .information__content {
        display: block;
    }
}

/* ==========================================================================
   51. HOME: HOT SPOTS - RESPONSIVO Y ESTADOS MÓVILES
   ========================================================================== */
@media (max-width: 1250px) {
    /* Reestructuración del Grid */
    #home .front-page-hot-spots {
        grid-template-columns: repeat(2, 1fr);
    }

    #home .front-page-hot-spots .content-element.a { grid-column: 1/2; grid-row: 1; }
    #home .front-page-hot-spots .content-element.b { grid-column: 2/3; grid-row: 2; }
    #home .front-page-hot-spots .content-element.c { grid-column: 1/2; grid-row: 3; }
    #home .front-page-hot-spots .content-element.d { grid-column: 2/3; grid-row: 4; }

    /* Estilo del Botón en Móvil */
    #home .front-page-hot-spots .content-element .info-container .extra-content {
        display: flex;
        justify-content: center;
        align-items: center;
        position: absolute;
        top: 0%;
        left: 0%;
        width: 40px;
        height: 40px;
        background-color: var(--primary-green);
        border-radius: 50%;
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content::before {
        content: "+";
        color: var(--primary-dark-green);
        font-size: 24px;
        font-weight: 600;
    }

    /* Estado del Popup en Móvil (Oculto) */
    #home .front-page-hot-spots .content-element .info-container .extra-content .information {
        position: absolute;
        right: 0%;
        z-index: 10;
        padding: 0.5rem 1.5rem;
        background-color: var(--pure-white);
        border-radius: 2rem;
        opacity: 0;
        transform: translate(82%, 90%);
        transition: opacity 0.2s ease-in;
    }

    /* Ajuste para Puntos a la Derecha (Extra Content Left) */
    #home .front-page-hot-spots .content-element .info-container .extra-content.left {
        right: 0%;
        left: auto;
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content.left .information {
        transform: translate(0%, 90%);
    }

    /* ==========================================================================
       52. ESTADO ACTIVO (.active) - Lógica de Toggle
       ========================================================================== */
    #home .front-page-hot-spots .content-element .info-container .extra-content.active::before {
        content: "-";
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content.active .information {
        display: block;
        opacity: 1;
        min-width: 250px;
        padding-top: 1rem;
        transform: translate(82%, 20%);
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content.active .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left.active .information__content {
        display: block;
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content.left.active .information {
        transform: translate(0%, 20%);
    }
}

/* ==========================================================================
   53. HOME: HOT SPOTS - INTERACTIVIDAD TABLET (1024px - 1250px)
   ========================================================================== */
@media (max-width: 1250px) and (min-width: 1024px) {

    /* Cambio de símbolo al interactuar */
    #home .front-page-hot-spots .content-element .info-container .extra-content:hover::before,
    #home .front-page-hot-spots .content-element .info-container .extra-content:focus::before,
    #home .front-page-hot-spots .content-element .info-container .extra-content:active::before {
        content: "-";
    }

    /* Visualización del Popup con coordenadas de Tablet */
    #home .front-page-hot-spots .content-element .info-container .extra-content:hover .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content:focus .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content:active .information {
        display: block;
        opacity: 1;
        min-width: 250px;
        padding-top: 1rem;
        transform: translate(82%, 20%);
    }

    /* Mostrar contenido interno */
    #home .front-page-hot-spots .content-element .info-container .extra-content:hover .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content:focus .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content:active .information__content {
        display: block;
    }

    /* Ajuste específico para puntos posicionados a la izquierda */
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:hover .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:focus .information,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:active .information {
        transform: translate(0%, 20%);
    }

    #home .front-page-hot-spots .content-element .info-container .extra-content.left:hover .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:focus .information__content,
    #home .front-page-hot-spots .content-element .info-container .extra-content.left:active .information__content {
        display: block;
    }
}

/* ==========================================================================
   325. HOME: SECCIÓN TRAZABILIDAD
   ========================================================================= */
#home .traceability {
    height: 550px;
}

/* ==========================================================================
   NEW. HOME: BANNER HERO - SOLUCIÓN DE IMAGEN DE FONDO
   ========================================================================== */
/* Asegura que la imagen se comporte como un background-image: cover */
.banner-element {
    position: relative;
    overflow: hidden;
    height: 100vh; /* Ajusta a la altura de tu banner */
}

.banner-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Esto simula el background-size: cover */
    object-position: center;
    z-index: -1; /* Queda detrás del texto y el background-layer */
}

/* Evita que el slider salte mientras carga el JS (Slick) */
.banner-slider:not(.slick-initialized) .banner-element:not(:first-child) {
    display: none;
}

#banner-fast-clone img {
    width: 100%;
    height: 100vh;
    object-fit: cover;
}


.categories .category {
    position: relative;
    overflow: hidden;
    height: 250px; /* Ajusta a tu diseño */
}

.cat-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}



/* Efecto hover opcional que antes no se apreciaba bien con background-image */
.category:hover .cat-bg-img {
    transform: scale(1.1);
}

/* Asegura que el contenedor retenga la imagen */
.best-seller-cta.relative-wrapper {
    position: relative;
    overflow: hidden;
    z-index: 1; /* Necesario para que el texto y fondo queden encima */
}

/* La imagen de rendimiento */
.outstanding-bg-img img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1; /* Manda la imagen al fondo, simulando background-image */
}

/* ==========================================================================
   SECCIÓN: TRAZABILIDAD (Optimización de Fondo)
   ========================================================================== */
.traceability.relative-wrapper {
    position: relative;
    overflow: hidden;
    /* Si antes tenías un padding o min-height en .traceability, se mantendrá */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* La imagen asume el rol de background-size: cover */
.traceability-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 1; /* Se va al fondo */
}

/* El texto y botón flotan sobre la imagen */
.traceability .content-overlay {
    position: relative;
    z-index: 2; /* Se coloca sobre la imagen */
}

@media (max-width: 767px) {
  .slider-container .slick-track .slider-element.slick-slide {
    justify-content: center;
    display: flex;
  }
}