/* HERO SECTION */
.hero-home {
    position: relative;
    width: 100%;
    height: calc(100vh - var(--navbar-height)); /* Ajusta la altura del héroe para que se muestre debajo del navbar */
    overflow: hidden;
}

.hero-swiper .swiper-slide {
    width: 100%;
    height: calc(100vh - var(--navbar-height)); /* Asegúrate de que los slides también ocupen esta altura */
    background-size: cover;
    background-position: center center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white; /* Color de texto por defecto */
    text-align: center;
}

/* Efecto de superposición oscura sobre la imagen */
.hero-swiper .swiper-slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3); /* Capa oscura, opacidad reducida */
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2; /* Asegura que el contenido esté por encima de la capa oscura */
    max-width: 800px;
    padding: 20px;
}

.hero-content h1,
.hero-content p {
    margin-bottom: 20px;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: bold;
}

.hero-content p {
    font-size: 1.25rem;
    line-height: 1.6;
}

/* Paginación de Swiper */
.hero-swiper .swiper-pagination-bullet {
    background: #fff;
    opacity: 0.6;
}

.hero-swiper .swiper-pagination-bullet-active {
    background: #007bff;
    opacity: 1;
}

/* Navegación de Swiper */
.hero-swiper .swiper-button-next,
.hero-swiper .swiper-button-prev {
    color: #fff;
}

/* Clases de color de texto */
.hero-text-light {
    color: #f8f9fa; /* Blanco claro */
}

.hero-text-dark {
    color: #212529; /* Negro oscuro */
}



/* FEATURED SECTION */
.featured-section {
    padding: 60px 0;
    text-align: center;
}

.featured-section h2 {

    font-size: 2.5rem;

    margin-bottom: 40px;

}



/* Product Grid (from productos_dashboard.css) */

.product-grid {

    display: grid;

    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); /* 4 columns on larger screens */

    gap: 20px;

}



/* Product Card (from productos_dashboard.css) */

.product-card {

    background-color: #fff;

    border: none;

    border-bottom: 1px solid #e0e0e0; /* Subtle bottom border */

    overflow: hidden;

    transition: box-shadow .3s ease-in-out;

    display: flex;

    flex-direction: column;

    position: relative; /* For badge positioning */

    text-decoration: none; /* Remove underline for anchor tag cards */

    color: inherit; /* Inherit text color */

}



.product-card:hover {

    box-shadow: 0 4px 12px rgba(0,0,0,0.08);

}



.product-image-container {

    width: 100%;

    padding-top: 100%; /* 1:1 Aspect Ratio - reverted from 120% */

    position: relative;

    overflow: hidden;

    background-color: #f8f8f8; /* Light background for images */

}



.product-image {



    position: absolute;



    top: 0;



    left: 0;



    width: 100%;



    height: 100%;



    object-fit: cover;



    transition: transform 0.3s ease;



}







.product-image-front {



    opacity: 1;



    transition: opacity 0.3s ease-in-out;



}







.product-image-back {



    opacity: 0; /* Hidden by default */



    position: absolute; /* Stack on top of front image */



    top: 0;



    left: 0;



    width: 100%;



    height: 100%;



    object-fit: cover;



    transition: opacity 0.3s ease-in-out;



}







.product-card:hover .product-image-front {



    opacity: 0; /* Hide front image on hover */



}







.product-card:hover .product-image-back {



    opacity: 1; /* Show back image on hover */



}



.product-card:hover .product-image {

    transform: scale(1.05); /* Slight zoom on hover */

}

.product-actions-overlay {
    position: absolute;
    top: 10px; /* Adjust as needed */
    right: 10px; /* Position on the right */
    display: flex;
    flex-direction: column; /* Stack vertically */
    gap: 8px; /* Space between icons */
    z-index: 15; /* Ensure it's above images and badges */
    opacity: 0; /* Hidden by default */
    transform: translateX(20px); /* Start slightly off-screen */
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.product-card:hover .product-actions-overlay {
    opacity: 1; /* Show on hover */
    transform: translateX(0); /* Slide into view */
}

.product-action-btn {
    width: 36px; /* Fixed width for icon buttons */
    height: 36px; /* Fixed height for icon buttons */
    border-radius: 50%; /* Make them circular */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.product-action-btn:hover {
    background-color: var(--primary); /* Use theme primary color */
    color: white;
}



.product-badge {

    position: absolute;

    top: 10px;

    left: 10px;

    background-color: #ff3333; /* Red for sale */

    color: #fff;

    padding: 5px 8px;

    font-size: 0.8rem;

    font-weight: 700;

    border-radius: 3px;

    z-index: 10;

}



.product-info {

    padding: 15px;

    flex-grow: 1;

    display: flex;

    flex-direction: column;

    align-items: center; /* Centrar elementos horizontalmente */

}



.product-category {

    font-size: 0.8rem;

    color: #767677; /* Adidas grey */

    text-transform: uppercase;

    margin-bottom: 5px;

    order: 3; /* Order to appear after name */

}



.product-name {

    font-size: 1rem;

    font-weight: 500; /* Medium weight */

    color: #000;

    margin-bottom: 5px;

    line-height: 1.3;

    order: 2; /* Order to appear after price */

    text-align: center; /* Centrar el nombre del producto */

}



.product-price-wrapper {

    display: flex;

    align-items: baseline;

    margin-bottom: 8px;

    order: 1; /* Order to appear first */

    gap: 8px; /* Espacio entre el precio actual y el anterior */

}



.product-price {

    font-size: 1.1rem;

    font-weight: 700;

    color: #000; /* Darker for Adidas style */

}



.product-old-price {

    font-size: 0.9rem;

    color: #767677;

    text-decoration: line-through;

    font-weight: 400;

}



.product-stock {

    font-size: 0.85rem;

    color: #555;

    margin-top: 5px;

    order: 4; /* Para que aparezca después de la categoría */

}



/* Discount Badge - reutilizando .product-badge pero con color y centrado */

.product-card .discount-badge {

    position: absolute;

    top: 10px;

    left: 50%; /* Centrar horizontalmente */

    transform: translateX(-50%); /* Ajuste para el centrado */

    background-color: #dc3545; /* Rojo de Bootstrap para peligro/descuento */

    color: white;

    padding: 3px 8px;

    border-radius: 4px;

    font-size: 0.8rem;

    font-weight: bold;

    z-index: 10;

}



/* Responsive adjustments */

@media (max-width: 768px) {

    .product-grid {

        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); /* 2 columns on mobile */

    }

}



@media (min-width: 769px) and (max-width: 992px) {

    .product-grid {

        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); /* 3 columns on tablet */

    }

}



/* MARKETING BANNER */
.marketing-banner {
    background-size: cover;
    background-position: center;
    color: white;
    padding: 100px 0;
    text-align: center;
    position: relative;
    border-radius: 10px;
    margin: 50px auto;
    max-width: 1200px;
}

.marketing-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5); /* Overlay oscuro */
    border-radius: 10px;
}

.marketing-banner .content {
    position: relative;
    z-index: 1;
}

.marketing-banner h2 {
    font-size: 3rem;
    margin-bottom: 20px;
}

.marketing-banner p {
    font-size: 1.3rem;
    margin-bottom: 30px;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }
    .hero-content p {
        font-size: 1rem;
    }
    .featured-section h2 {
        font-size: 2rem;
    }
    .marketing-banner h2 {
        font-size: 2.2rem;
    }
    .marketing-banner p {
        font-size: 1.1rem;
    }
}

@media (max-width: 768px) {
    .hero-home,
    .hero-swiper .swiper-slide {
        height: 400px; /* Altura fija para dispositivos pequeños y medianos */
    }
    .hero-swiper .swiper-button-next,
    .hero-swiper .swiper-button-prev {
        display: none;
    }
    .product-carousel {
        padding: 0 15px;
    }
}
/* Asegurar que los títulos y subtítulos sean visibles inicialmente */
.hero-slide-title, .hero-slide-subtitle {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Keyframes for Fill Effects */

@keyframes zoomInEffect {
    0% { background-size: 100% 100%; }
    50% { background-size: 110% 110%; }
    100% { background-size: 100% 100%; }
}

@keyframes zoomOutEffect {
    0% { background-size: 100% 100%; }
    50% { background-size: 90% 90%; }
    100% { background-size: 100% 100%; }
}

@keyframes panLeftEffect {
    0% { background-position: center center; }
    50% { background-position: 10% center; }
    100% { background-position: center center; }
}

@keyframes panRightEffect {
    0% { background-position: center center; }
    50% { background-position: 90% center; }
    100% { background-position: center center; }
}

@keyframes panUpEffect {
    0% { background-position: center center; }
    50% { background-position: center 10%; }
    100% { background-position: center center; }
}

@keyframes panDownEffect {
    0% { background-position: center center; }
    50% { background-position: center 90%; }
    100% { background-position: center center; }
}

/* Apply animations to active slides */
.hero-swiper .swiper-slide.swiper-slide-active.fill-effect-zoom-in {
    animation: zoomInEffect 10s ease-in-out infinite;
}

.hero-swiper .swiper-slide.swiper-slide-active.fill-effect-zoom-out {
    animation: zoomOutEffect 10s ease-in-out infinite;
}

.hero-swiper .swiper-slide.swiper-slide-active.fill-effect-pan-left {
    animation: panLeftEffect 10s ease-in-out infinite;
}

.hero-swiper .swiper-slide.swiper-slide-active.fill-effect-pan-right {
    animation: panRightEffect 10s ease-in-out infinite;
}

.hero-swiper .swiper-slide.swiper-slide-active.fill-effect-pan-up {
    animation: panUpEffect 10s ease-in-out infinite;
}

.hero-swiper .swiper-slide.swiper-slide-active.fill-effect-pan-down {
    animation: panDownEffect 10s ease-in-out infinite;
}
