.hero-slider {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    position: relative;

    margin-left: calc(-50vw + 50%);
    margin-top: 0;

    z-index: 0;
}

/* TRACK */
.slides {
    display: flex;
    height: 100%;
    transition: transform 1.2s cubic-bezier(0.77, 0, 0.175, 1);
}

/* SLIDE */
.slide {
    min-width: 100vw;
    height: 100%;
    position: relative;
    overflow: hidden;
}

/* IMAGEN */
.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;

    transform: scale(1.05);
}

/* OVERLAY */
.overlay {
    position: absolute;
    inset: 0;

    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0.6),
        rgba(0,0,0,0.8)
    );
    backdrop-filter: saturate(1.8) contrast(1.2);
    

    opacity: 0.8;
    transition: opacity 5s;
}

/* solo el activo se aclara */
.slide.active .overlay {
    opacity: 0;
    background: #2f6f73d9;
}

/* TEXTO */
.caption {
    position: absolute;
    left: 80px;
    top: 50%;
    transform: translateY(-50%);

    display: flex;
    flex-direction: column;

    color: white;
    z-index: 2;

    text-align: left;

    opacity: 0;
}

.slide.active .caption {
    opacity: 1;
    transform: translateY(0);
}

.caption h2 {
    font-size: 28px;
    margin-bottom: 5px;
}

.caption p {
    font-size: 16px;
}

.hero-title {
    position: absolute;
    top: 80%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;

    display: flex;
    flex-direction: column;
    gap: 25px;

    align-items: center;
}

.caption h1,
.caption h2 {
    opacity: 0;
    filter: blur(8px);
    transform: translateY(20px);
}

.slide.active .caption h1,
.slide.active .caption h2 {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0);
    transition: all 0.6s ease;
}

.slide.active .caption h1 {
    animation-delay: 0.1s; 
}

.slide.active .caption h2 {
    animation-delay: 0.35s; 
}

.slide.exit .caption h1,
.slide.exit .caption h2 {
    opacity: 0;
    filter: blur(10px);
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.slide.active .left-in {
    animation: fromLeft 1s ease forwards;
}

.slide.active .bottom-in {
    animation: fromBottom 1s ease forwards;
}


.slide.active.anim-top .caption {
    animation: fromTop 1s ease forwards;
}

@keyframes fromTop {
    from {
        opacity: 0;
        transform: translateY(-40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide.active.anim-left .caption {
    animation: fromLeft 1s ease forwards;
}

@keyframes fromLeft {
    from {
        opacity: 0;
        transform: translateX(-60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide.active.anim-bottom .caption {
    animation: fromBottom 1s ease forwards;
}

@keyframes fromBottom {
    from {
        opacity: 0;
        transform: translateY(60px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}