/* Estilos de la sección hero. Todo va dentro de .app-hero para no chocar con otras secciones. */

.app-hero {
    display: block;
    overflow: hidden;
    min-height: 600px;
}

.app-hero .hero {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 1.5rem;
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 3rem;
    align-items: center;
    min-height: 80vh;
}

/* ---------- Texto ---------- */

.app-hero .hero__content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.app-hero .badge,
.app-hero h1,
.app-hero .desc,
.app-hero .cta,
.app-hero .stats {
    animation: hero-fadeUp 0.8s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.app-hero .badge {
    animation-delay: 0.05s;
}

.app-hero h1 {
    animation-delay: 0.15s;
}

.app-hero .desc {
    animation-delay: 0.25s;
}

.app-hero .cta {
    animation-delay: 0.35s;
}

.app-hero .stats {
    animation-delay: 0.45s;
}

.app-hero .badge {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin: 0 0 1.25rem;
    padding: 0.45rem 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: #6ea89f;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(110, 168, 159, 0.25);
    border-radius: 999px;
    backdrop-filter: blur(8px);
}

.app-hero .badge__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.6);
    animation: hero-pulse 2s infinite;
}

.app-hero h1 {
    margin: 0 0 1.25rem;
    font-family: "Special Gothic Condensed One", sans-serif;
    font-size: clamp(2.3rem, 4.5vw, 3.8rem);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: normal;
    background: linear-gradient(120deg, #223746 40%, #6ea89f 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.app-hero .desc {
    margin: 0 0 2.25rem;
    max-width: 520px;
    font-size: 1.15rem;
    line-height: 1.3;
    color: #223746;
}

/* ---------- CTA ---------- */

.app-hero .cta {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0;
    padding: 1rem 2.25rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
    background: linear-gradient(135deg, #6ea89f 0%, #6ea89f 100%);
    border-radius: 14px;
    box-shadow: 0 12px 24px -8px #223746;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.app-hero .cta svg {
    transition: transform 0.3s ease;
}

.app-hero .cta::after {
    content: '';
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    transform: skewX(-20deg);
    animation: hero-shine 4s ease-in-out infinite;
}

.app-hero .cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 30px -8px #6ea89f;
}

.app-hero .cta:hover svg {
    transform: translateX(4px);
}

/* ---------- Estadísticas ---------- */

.app-hero .stats {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-top: 2.75rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.app-hero .stats li {
    display: flex;
    flex-direction: column;
}

.app-hero .stats strong {
    font-size: 1.4rem;
    font-weight: 800;
    color: #0f172a;
}

.app-hero .stats span {
    font-size: 0.85rem;
    color: #64748b;
}

/* ---------- Slider antes / después ---------- */

.app-hero .hero__visual {
    position: relative;
    display: flex;
    justify-content: center;
    animation: hero-fadeUp 1s 0.2s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.app-hero .slider {
    --pos: 50%;
    position: relative;
    width: 100%;
    max-width: 560px;
    cursor: ew-resize;
    user-select: none;
    touch-action: pan-y;
}

.app-hero .img--after {
    display: block;
    width: 100%;
    height: auto;
    pointer-events: none;
}

.app-hero .img--before {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: fill;
    pointer-events: none;
    clip-path: inset(0 calc(100% - var(--pos)) 0 0);
    transition: clip-path 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.app-hero .divider {
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--pos);
    width: 3px;
    margin-left: -1.5px;
    background: #fff;
    box-shadow: 0 0 12px rgba(0, 0, 0, 0.35);
    transition: left 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.app-hero .handle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    color: #1e293b;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

/* Sin transición mientras el usuario mueve el divisor */

.app-hero .slider.is-active .img--before,
.app-hero .slider.is-active .divider {
    transition: none;
}

.app-hero .tag {
    position: absolute;
    bottom: 1.25rem;
    padding: 0.3rem 0.8rem;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #fff;
    background: #6ea89f;
    border-radius: 999px;
    backdrop-filter: blur(6px);
}

.app-hero .tag--before {
    left: 22%;
}

.app-hero .tag--after {
    right: 22%;
}

/* Input invisible: da control por teclado sin romper el diseño */

.app-hero .range {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    pointer-events: none;
}

.app-hero .slider:has(.range:focus-visible) {
    outline: 3px solid #f59e0b;
    outline-offset: 4px;
}

/* ---------- Chips flotantes ---------- */

.app-hero .chip {
    position: absolute;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: #0f172a;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 14px;
    box-shadow: 0 12px 28px -8px rgba(15, 23, 42, 0.25);
    backdrop-filter: blur(8px);
    animation: hero-bob 5s ease-in-out infinite;
}

.app-hero .chip--top {
    top: 8%;
    left: 2%;
}

/* ---------- Animaciones ---------- */

@keyframes hero-fadeUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes hero-float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    50% {
        transform: translate(30px, -30px) scale(1.1);
    }
}

@keyframes hero-bob {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes hero-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.6);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(34, 197, 94, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

@keyframes hero-shine {
    0%, 60% {
        left: -120%;
    }
    100% {
        left: 160%;
    }
}

@keyframes hero-morph {
    0%, 100% {
        border-radius: 35% 65% 55% 45% / 45% 55% 45% 55%;
    }
    50% {
        border-radius: 55% 45% 40% 60% / 55% 40% 60% 45%;
    }
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
    .app-hero .hero {
        grid-template-columns: 1fr;
        text-align: center;
        min-height: auto;
        padding-top: 2.5rem;
    }

    .app-hero .hero__content {
        align-items: center;
    }

    .app-hero .stats {
        justify-content: center;
    }

    .app-hero .chip--top {
        left: 0;
    }

    .app-hero .chip--bottom {
        right: 0;
    }

}

/* ---------- Accesibilidad: sin movimiento ---------- */

@media (prefers-reduced-motion: reduce) {
    .app-hero *,
    .app-hero *::before,
    .app-hero *::after {
        animation: none !important;
        transition: none !important;
    }

}
