@charset "UTF-8";

:root {
    --carousel-height: 65vh;
    --panel-padding: 2.5rem;
    --border-radius: 16px;
}

/* Contenedor Principal del Carrusel */
.featured-carousel {
    position: relative;
    width: 100%;
    height: var(--carousel-height);
    min-height: 500px;
    overflow: hidden;
    background: #1a1a1a;
    border-radius: var(--border-radius);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

/* Contenedor de los Slides */
.slider {
    position: relative;
    width: 100%;
    height: 100%;
}

/* Estilo de cada Slide */
.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

/* Contenedor de la Imagen del Slide */
.slide__image-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.slide__image-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.4) 100%);
    opacity: 0.8;
}

.slide__image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Panel de Contenido Centrado */
.slide__content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%); /* Centrado perfecto */
    width: 90%;
    max-width: 650px; /* Ancho ajustado para el centro */
    padding: var(--panel-padding);
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px) saturate(150%);
    -webkit-backdrop-filter: blur(12px) saturate(150%);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255,255,255,0.1);
    text-align: center; /* Alineación de texto centrada */
}

/* Título del Slide */
.slide__title {
    font-size: 3rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0,0,0,0.7);
    letter-spacing: -1px;
    overflow-wrap: break-word; /* Break long words only if necessary */
}

/* Descripción del Slide */
.slide__description {
    font-size: 1.1rem;
    font-weight: 300;
    margin: 0 auto 2rem; /* Auto en márgenes laterales para centrar si hay max-width */
    line-height: 1.7;
    max-width: 95%; 
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3; /* Limit to 3 lines */
    -webkit-box-orient: vertical;
    overflow-wrap: break-word; /* More compatible word breaking */
    hyphens: auto; /* Assist with breaking */
}

/* Botón "Call to Action" */
.slide__button {
    display: inline-block;
    padding: 0.8rem 2.2rem;
    background-color: rgba(255, 255, 255, 0.9);
    color: #000;
    text-decoration: none;
    font-weight: 600;
    border-radius: 50px;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    text-transform: uppercase;
    letter-spacing: 1.2px;
    font-size: 0.8rem;
    border: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.slide__button:hover {
    background-color: #fff;
    color: #000;
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}

/* Badge de Promoción */
.slide__promo-badge {
    position: absolute;
    top: 2rem;
    right: 2rem;
    z-index: 5;
    padding: 0.6rem 1.2rem;
    background: rgba(217, 48, 37, 0.8); /* Rojo de promoción con transparencia */
    backdrop-filter: blur(5px);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Controles de Navegación (Prev/Next) */
.prev, .next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.3);
    transition: background 0.3s, transform 0.3s;
}
.prev:hover, .next:hover {
    background: rgba(0, 0, 0, 0.6);
    transform: translateY(-50%) scale(1.1);
}
.prev svg, .next svg {
    width: 25px;
    height: 25px;
}
.prev { left: 30px; }
.next { right: 30px; }


/* Indicadores como barras de progreso */
.trail {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 12px;
}

.trail .indicator {
    width: 40px;
    height: 4px;
    border-radius: 2px;
    background-color: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    overflow: hidden;
}

.trail .indicator .progress {
    width: 100%;
    height: 100%;
    background-color: #fff;
    transform: scaleX(0);
    transform-origin: left;
}
.trail .indicator.active .progress {
    transform: scaleX(1);
}


/* Media Queries */
@media (max-width: 992px) {
    .slide__content {
        padding: 2rem;
    }
    .slide__title { font-size: 2.5rem; }
    .slide__description { font-size: 1rem; }
}

@media (max-width: 768px) {
    .featured-carousel {
        height: 65vh;
        max-height: 500px;
    }
    .slide__content {
        padding: 1.2rem; /* Reducir aún más el padding */
        max-width: calc(100% - 2.4rem); /* Ajustar el max-width al nuevo padding */
    }
    .slide__title { font-size: 1.8rem; } /* Título más pequeño */
    .slide__description { font-size: 0.85rem; } /* Descripción más pequeña */
    .slide__button { font-size: 0.75rem; padding: 0.7rem 1.8rem; } /* Botón ligeramente más pequeño */
    .slide__promo-badge {
        top: 1rem; /* Ajustar posición del badge */
        right: 1rem;
        padding: 0.4rem 0.8rem;
        font-size: 0.65rem;
    }
    .prev, .next {
        width: 35px; /* Botones de navegación más pequeños */
        height: 35px;
    }
    .prev svg, .next svg {
        width: 18px; /* Tamaño del icono SVG */
        height: 18px;
    }
    .prev { left: 8px; } /* Ajuste de posición */
    .next { right: 8px; } /* Ajuste de posición */
    .trail {
        width: 60%;
        bottom: 15px; /* Ajuste de posición */
    }
    .trail .indicator {
        width: 25px; /* Indicadores más pequeños */
    }
}
