/* Elimina cualquier estilo global del body */
body {
    margin: 0;
    padding: 0;
}

/* Todo encapsulado dentro de hero-section */
.hero-section {
    width: 100%;
    height: 100dvh;
    font-family: 'Poppins', sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-wrapper {
    text-align: left;
    perspective: 1000px;
    z-index: 5;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 40%;
}

.hero-text p {
    position: relative;
    z-index: 5;
    font-weight: 900;
    font-size: 10vw;
    color: #ffffff;
    text-transform: uppercase;
    line-height: 0.9;
    margin: 0;
    animation: idleFloat 6s ease-in-out infinite;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transform-style: preserve-3d;
}

.hero-text {
    position: relative;
    display: inline-block;
    z-index: 5;
}

.hero-text::after {
    content: "";
    position: absolute;
    top: -50px;
    left: -50px;
    width: calc(100% + 100px);
    height: calc(100% + 100px);
    pointer-events: none;
    z-index: 2;

    /* Halftone SVG pattern */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='6' height='6'%3E%3Ccircle cx='3' cy='3' r='1.8' fill='#0062ff'/%3E%3C/svg%3E");
    background-repeat: repeat;
    opacity: 0.1;
    mix-blend-mode: screen;

    /* Prueba multiply, overlay */
    z-index: 3;
    pointer-events: none;
}

.hero-text p::before,
.hero-text p::after {
    content: '';
    position: absolute;
    top: -50px;
    left: -50px;
    width: calc(100% + 100px);
    height: calc(100% + 100px);
    background-image: radial-gradient(#0062ff 1px, transparent 2px),
    radial-gradient(#0062ff 1px, transparent 1px);
    background-size: 6px 6px;
    background-position: 0 0, 3px 3px;
    z-index: -1;
    animation: pixelNoise 2s infinite linear;
    opacity: 0.2;
    pointer-events: none;
}

@keyframes idleFloat {
    0% {
        transform: rotateX(7deg) rotateY(-7deg) translateY(0px) scale(1);
    }

    25% {
        transform: rotateX(-8deg) rotateY(8deg) translateY(-8px) scale(1.015);
    }

    50% {
        transform: rotateX(7deg) rotateY(-6deg) translateY(0px) scale(1);
    }

    75% {
        transform: rotateX(-8deg) rotateY(8deg) translateY(9px) scale(1.01);
    }

    100% {
        transform: rotateX(8deg) rotateY(-8deg) translateY(0px) scale(1);
    }
}

@keyframes pixelNoise {
    0% {
        background-position: 0 0, 3px 3px;
    }

    100% {
        background-position: 6px 6px, 9px 9px;
    }
}

/* Fondo con shader */
#shader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

/* Asegura que el canvas cubra toda la pantalla */
#shader canvas {
    width: 100% !important;
    height: 100% !important;
    display: block;
}

/* Asegura que el body pueda hacer scroll si hay contenido */
body {
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
}

/* ========== AJUSTES DE ESPACIADO ========== */
/* Pantallas GRANDES - MUCHO espacio entre secciones */
@media (min-width: 1200px) {
    .hero-section {
        margin-bottom: 12em;

        /* Aumentado de 4em a 12em para MUCHO espacio */
    }

    .hero-section:first-child {
        margin-top: 6em;

        /* Espacio superior generoso en la primera sección */
    }

    .hero-section:last-child {
        margin-bottom: 6em;

        /* Espacio inferior generoso en la última sección */
    }

    /* Si hay múltiples secciones, mantener el espacio consistente */
    .hero-section + .hero-section {
        margin-top: 2em;
    }
}

/* Desktop mediano - Espacio amplio */
@media (min-width: 992px) and (max-width: 1199px) {
    .hero-section {
        margin-bottom: 10em;

        /* Aumentado para desktop mediano */
    }

    .hero-section:first-child {
        margin-top: 5em;
    }

    .hero-section:last-child {
        margin-bottom: 5em;
    }
}

/* Tablets horizontales / desktop pequeño - Espacio moderado-grande */
@media (min-width: 769px) and (max-width: 991px) {
    .hero-section {
        margin-bottom: 8em;

        /* Espacio amplio para tablets grandes */
    }

    .hero-section:first-child {
        margin-top: 4em;
    }

    .hero-section:last-child {
        margin-bottom: 4em;
    }
}

/* Tablets verticales - Espacio moderado */
@media (min-width: 481px) and (max-width: 768px) {
    .hero-section {
        height: auto;
        padding-top: 1.5em;
        padding-bottom: 1.5em;
        margin-bottom: 2em;

        /* Espacio moderado entre secciones */
    }

    .hero-section:first-child {
        margin-top: 1em;
        padding-top: 1em;
    }

    .hero-section:last-child {
        margin-bottom: 1em;
        padding-bottom: 1em;
    }

    .hero-wrapper {
        margin-top: -0.5em;
        margin-bottom: -0.5em;
        height: auto;
        min-height: 35vh;
    }
}

/* MÓVILES - Espacio MÍNIMO (como ya tenías) */
@media (max-width: 480px) {
    .hero-section {
        padding-top: 9.5em;
        padding-bottom: 9.5em;
        margin-bottom: 0.5em;
        box-sizing: border-box;

        /* Mínimo espacio entre secciones */
    }

    .hero-wrapper {
        margin-top: 0em;
        margin-bottom: 0;
        min-height: 25vh;
        position: relative;
        transform: none;
    }

    .hero-text p {
        font-size: 14vw;
        animation: idleFloat 6s ease-in-out infinite;

        /* Animación original intacta */
    }

    .hero-section:first-child {
        margin-top: 0.25em;
        padding-top: 0.25em;
    }

    .hero-section:last-child {
        margin-bottom: 0.25em;
        padding-bottom: 0.25em;
    }
}

/* Ajuste adicional para móviles muy pequeños */
@media (max-width: 360px) {
    .hero-section {
        padding-top: 7.5em;
        padding-bottom: 7.5em;
        margin-bottom: 0.25em;
        box-sizing: border-box;
    }

    .hero-wrapper {
        margin-top: 0em;
        margin-bottom: 0em;
        min-height: 20vh;
    }
}

/* End subrayado del texto */
/* ===== FIX HIGHLIGHT + ANIMACIÓN ===== */
.text-swift-up span.highlight i {
    position: relative;
    z-index: 2;
    color: #fff;
}

/* fondo ahora vive en el <i>, no en el span */
.text-swift-up span.highlight i::after {
    content: "";
    position: absolute;
    inset: 0;
    background: #fff;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
    z-index: -1;
}

/* activación */
.text-swift-up span.highlight.active i::after {
    transition: transform 0.4s ease, opacity 0.3s ease;
}

.text-swift-up span.highlight.active i {
    color: #000;
    -webkit-text-fill-color: #000;
}

/* estado normal (subrayado visible) */
.text-swift-up span.highlight.active i::after {
    transform: scaleX(1);
}

/* interacción: lo apagamos momentáneamente */
.text-swift-up span.highlight.interact i::after {
    transform: scaleX(0);
}

.text-swift-up span.highlight.interact i {
    color: #fff;
    -webkit-text-fill-color: #fff;
}













