/* ========================================
   HERO SLIDER - CLINICANIMAL
   Basado en diseño Figma
   ======================================== */

/* Variables */
:root {
    --slider-primary-color: #264067;
    --slider-secondary-color: #0A9BC7;
    --slider-button-color: #FF8B00;
    --slider-text-dark: #264067;
    --slider-text-light: #FFFFFF;
    --slider-transition: all 0.5s ease;
}

/* ========================================
   SLIDER WRAPPER
   ======================================== */

.hero-slider-wrapper {
    position: relative;
    width: 100vw !important;
    max-width: 100vw !important;
    overflow: hidden;
    background-color: #f5f5f5;
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
    padding: 0;
}

.hero-slider {
    position: relative;
    width: 100%;
    display: block;
}

/* ========================================
   SLIDE INDIVIDUAL
   ======================================== */

.hero-slide {
    position: relative;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease, visibility 0.8s ease;
    display: none;
}

.hero-slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 1;
    display: block;
}

/* Enlace completo de la slide - Overlay invisible */
.hero-slide-link-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    display: block;
    text-decoration: none;
    cursor: pointer;
    background: transparent;
}

.hero-slide-link-wrapper:hover {
    background: rgba(0, 0, 0, 0.02);
}

/* Imagen de fondo */
.hero-slide-image {
    position: relative;
    width: 100%;
    display: block;
    z-index: 0;
}

.hero-slide-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    object-position: center center;
}

/* ========================================
   CONTENIDO DEL SLIDE
   ======================================== */

.hero-slide-content {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    pointer-events: none;
}

.hero-slide-content-inner {
    max-width: 600px;
    animation: slideInContent 0.8s ease-out;
    background-color: rgba(255, 255, 255, 0.9);
    padding: 24px 32px;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(8px);
    pointer-events: auto;
}

@keyframes slideInContent {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Posicionamiento del contenido */
.hero-slide-content.position-left {
    justify-content: flex-start;
}

.hero-slide-content.position-center {
    justify-content: center;
}

.hero-slide-content.position-center .hero-slide-content-inner {
    text-align: center;
}

.hero-slide-content.position-right {
    justify-content: flex-end;
}

.hero-slide-content.position-right .hero-slide-content-inner {
    text-align: right;
}

/* Color del texto */
.hero-slide-content.color-dark .hero-slide-subtitle,
.hero-slide-content.color-dark .hero-slide-title,
.hero-slide-content.color-dark .hero-slide-description {
    color: var(--slider-text-dark);
}

.hero-slide-content.color-light .hero-slide-subtitle,
.hero-slide-content.color-light .hero-slide-title,
.hero-slide-content.color-light .hero-slide-description {
    color: var(--slider-text-dark);
}

/* Fondos personalizados según el tema */
.hero-slide-content.color-dark .hero-slide-content-inner {
    background-color: rgba(255, 255, 255, 0.9);
}

.hero-slide-content.color-light .hero-slide-content-inner {
    background-color: rgba(255, 255, 255, 0.9);
}

/* ========================================
   ELEMENTOS DE TEXTO
   ======================================== */

.hero-slide-subtitle {
    font-family: 'Montserrat', sans-serif;
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 12px 0;
    text-transform: none;
    line-height: 1.3;
}

.hero-slide-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
    margin: 0 0 20px 0;
}

.hero-slide-description {
    font-family: 'Montserrat', sans-serif;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 20px 0;
}

.hero-slide-description p {
    margin: 0;
}

/* Destacar texto en cian */
.hero-slide-title .highlight,
.hero-slide-description .highlight {
    color: var(--slider-secondary-color);
}

/* ========================================
   BOTÓN Y FECHA
   ======================================== */

.hero-slide-button-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.hero-slide-button {
    display: inline-block;
    background-color: var(--slider-button-color);
    color: #FFFFFF;
    font-family: 'Montserrat', sans-serif;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    padding: 14px 32px;
    border-radius: 8px;
    transition: var(--slider-transition);
    text-transform: uppercase;
}

.hero-slide-button:hover {
    background-color: #e67a00;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 139, 0, 0.3);
}

.hero-slide-date {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--slider-text-dark);
    background-color: rgba(255, 255, 255, 0.95);
    padding: 8px 16px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.hero-slide-content.color-light .hero-slide-date {
    color: var(--slider-text-dark);
    background-color: rgba(255, 255, 255, 0.95);
}

/* ========================================
   FLECHAS DE NAVEGACIÓN
   ======================================== */

.hero-slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background-color: rgba(51, 178, 226,0.5);
    color: #FFFFFF;
    border: none;
    /*border-radius: 50%;*/
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--slider-transition);
}

.hero-slider-arrow:hover {
    background-color: rgba(51, 178, 226,0.9);
    transform: translateY(-50%) scale(1.1);
}

.hero-slider-prev {
    left: 20px;
}

.hero-slider-next {
    right: 20px;
}

.hero-slider-arrow svg {
    width: 24px;
    height: 24px;
}

/* ========================================
   INDICADORES (DOTS)
   ======================================== */

.hero-slider-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 12px;
    align-items: center;
}

.hero-slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(51, 178, 226, 0.5);
    border: none;
    cursor: pointer;
    transition: var(--slider-transition);
    padding: 0;
}

.hero-slider-dot:hover {
    background-color: rgba(51, 178, 226, 0.8);
    transform: scale(1.2);
}

.hero-slider-dot.active {
    background-color: #FFFFFF;
    width: 32px;
    border-radius: 6px;
}

/* ========================================
   MENSAJE VACÍO
   ======================================== */

.hero-slider-empty {
    padding: 60px 20px;
    text-align: center;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.hero-slider-empty p {
    font-family: 'Montserrat', sans-serif;
    font-size: 16px;
    color: #666;
    margin: 0;
}

/* ========================================
   RESPONSIVE
   ======================================== */

/* Tablet */
@media (max-width: 1024px) {
    .hero-slide-title {
        font-size: 40px;
    }
    
    .hero-slide-description {
        font-size: 18px;
    }
    
    .hero-slide-content-inner {
        max-width: 500px;
        padding: 20px 28px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .hero-slide-content {
        padding: 0 16px;
    }
    
    .hero-slide-content-inner {
        max-width: 100%;
        padding: 16px 20px;
    }
    
    .hero-slide-subtitle {
        font-size: 14px;
    }
    
    .hero-slide-title {
        font-size: 28px;
        margin-bottom: 12px;
    }
    
    .hero-slide-description {
        font-size: 16px;
        margin-bottom: 16px;
    }
    
    .hero-slide-button {
        font-size: 14px;
        padding: 12px 24px;
    }
    
    .hero-slide-date {
        font-size: 12px;
        padding: 6px 12px;
    }
    
    .hero-slide-button-wrapper {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .hero-slide-content.position-center .hero-slide-button-wrapper {
        align-items: center;
    }
    
    .hero-slide-content.position-right .hero-slide-button-wrapper {
        align-items: flex-end;
    }
    
    .hero-slider-arrow {
        width: 40px;
        height: 40px;
    }
    
    .hero-slider-prev {
        left: 12px;
    }
    
    .hero-slider-next {
        right: 12px;
    }
    
    .hero-slider-dots {
        bottom: 20px;
        gap: 8px;
    }
    
    .hero-slider-dot {
        width: 10px;
        height: 10px;
    }
    
    .hero-slider-dot.active {
        width: 24px;
    }
}

/* Mobile Small */
@media (max-width: 480px) {
    .hero-slide-content-inner {
        padding: 12px 16px;
    }
    
    .hero-slide-subtitle {
        font-size: 12px;
    }
    
    .hero-slide-title {
        font-size: 24px;
    }
    
    .hero-slide-description {
        font-size: 14px;
    }
    
    /* Forzar contenido siempre centrado en móvil pequeño */
    .hero-slide-content {
        justify-content: center !important;
    }
    
    .hero-slide-content-inner {
        text-align: center !important;
    }
    
    .hero-slide-button-wrapper {
        align-items: center !important;
    }
}

/* ========================================
   ANIMACIONES ADICIONALES
   ======================================== */

.hero-slide.transitioning {
    z-index: 2;
}

/* Loading state */
.hero-slider-wrapper.loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* ========================================
   ACCESIBILIDAD
   ======================================== */

.hero-slider-arrow:focus,
.hero-slider-dot:focus {
    outline: 2px solid var(--slider-secondary-color);
    outline-offset: 2px;
    background-color: rgba(51, 178, 226, 0.8);
}

/* Reducir movimiento para usuarios con preferencias de accesibilidad */
@media (prefers-reduced-motion: reduce) {
    .hero-slide,
    .hero-slide-content-inner,
    .hero-slider-arrow,
    .hero-slider-dot {
        transition: none;
        animation: none;
    }
}

