/* Imagen que rota para reemplazar el gif */
.img-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.img-wrapper img {
    width: 100%;
    height: auto;
    max-width: 256px;
    animation: tiltGrow 2.8s ease-in-out infinite;
}

/* Estaba medio extraño el efecto de rotacion entonces esta parte es generada con IA*/
@keyframes tiltGrow {
    /* inicio leve */
    0%  { transform: translateY(-2px) translateX(-1px) rotate(2deg); }

    /* crecimiento */
    15% { transform: translateY(2px) translateX(3px) rotate(-6deg); }
    30% { transform: translateY(-4px) translateX(2px) rotate(10deg); }

    /* más intensidad */
    50% { transform: translateY(5px) translateX(-6px) rotate(-16deg); }

    /* pico */
    70% { transform: translateY(-8px) translateX(7px) rotate(22deg); }

    /* pequeño rebote */
    85% { transform: translateY(3px) translateX(-3px) rotate(-10deg); }

    /* reinicio suave */
    100% { transform: translateY(-2px) translateX(-1px) rotate(2deg); }
}

/* Parallax */
.main {
    padding-bottom: 0;
    margin-bottom: 0;
}

.parallax-section {
    position: relative;
    padding: 100px 0;

    left: 50%;
    margin-left: -50vw;
    width: 100vw;

    margin-bottom: 0;
    overflow: hidden;
}

.parallax-section::before {
    content: "";
    position: absolute;

    top: 50%;
    left: 50%;
    width: 100vw;
    height: 150%;

    transform: translate(-50%, calc(-50% + var(--parallax-offset, 0px)));

    background-image: url('/Herramientas/assets/imgs/catalogo/fondo_parallax.webp');
    background-size: cover;
    background-position: center;

    z-index: -1;
    will-change: transform;
}

/* Botones */
.button-container {
    display: block;
    width: 100%;
    max-width: 400px;
    margin: 20px auto;
}

.img-wipe {
    position: relative;
    width: 100%;
    aspect-ratio: 400 / 105;
    overflow: hidden;
    cursor: pointer;
}

.img-wipe img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.img-top {
    clip-path: inset(0 100% 0 0);
    transition: clip-path 0.4s cubic-bezier(.4,0,.2,1);
}

.button-container:hover .img-top {
    clip-path: inset(0 0 0 0);
}