﻿:root {
    --apple-bg: rgba(255, 255, 255, 0.82);
    --apple-text: #1d1d1f;
    --apple-blur: saturate(180%) blur(20px);
    --apple-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --apple-button-bg: #01498e;
    --apple-button-text: #fff;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--apple-font);
    background-color: #fff;
    color: var(--apple-text);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Header Estilo Apple Fijo (Transparente) */
.apple-header {
    position: fixed;
    top: 0;
    width: 100%;
    height: 60px;
    z-index: 1000;
    border-bottom: none;
    transition: background-color 0.3s ease, backdrop-filter 0.3s ease, border-bottom 0.3s ease;
}

.apple-header.scrolled {
    background-color: var(--apple-bg);
    backdrop-filter: var(--apple-blur);
    -webkit-backdrop-filter: var(--apple-blur);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.header-content {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 40px;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container img {
    height: 42px;
    filter: invert(19%) sepia(85%) saturate(3195%) hue-rotate(196deg) brightness(93%) contrast(101%);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 25px;
}

.btn-matricula {
    background-color: #01498e;
    color: #fff;
    padding: 12px 28px;
    border-radius: 980px;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
    border: none;
}

.btn-matricula:hover {
    transform: scale(1.05);
    filter: brightness(1.2);
}

.menu-icon {
    color: #01498e;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: var(--transition);
}

.menu-icon svg {
    width: 28px;
    height: 28px;
    transition: transform 0.3s ease;
}

.menu-icon:hover svg {
    transform: scale(1.1);
}

.menu-icon:hover {
    opacity: 0.8;
}

/* Secuencia de Scroll Cinematic */
#scroll-sequence-container {
    height: 300vh;
    /* Reducido para completar la animación más rápido y dejar pausa final controlada */
    position: relative;
    background: #000;
    overflow: visible;
    /* Permitir que el contenido absoluto escape si es necesario */
}

#sticky-sequence {
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    perspective: 1500px;
    background-color: #fff;
}

#sequence-canvas {
    position: absolute;
    top: 10px;
    /* Separación fija del menú */
    width: 100%;
    height: calc(100vh);
    object-fit: cover;
    display: block;
    will-change: transform, filter;
    transition: filter 0.5s ease;
    transform-origin: top center;
    /* El zoom crece hacia abajo, no sube */
}

/* Overlay de Textos Premium */
.sequence-overlay {
    position: relative;
    width: 100%;
    height: 100%;
    z-index: 10;
    pointer-events: none;
}

.scene-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 10vw;
    font-weight: 900;
    letter-spacing: -0.05em;
    color: #fff;
    opacity: 0;
    white-space: nowrap;
    text-shadow: 0 10px 50px rgba(0, 0, 0, 0.8);
    will-change: opacity, transform;
}

/* Escena del Formulario (Revelado Suave) */
.reveal-form-scene {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 1.2s cubic-bezier(0.19, 1, 0.22, 1);
    z-index: 20;
}

.reveal-form-scene.active {
    opacity: 1;
    pointer-events: auto;
}

.final-content-wrapper {
    display: flex;
    width: 100%;
    max-width: 1400px;
    padding: 0 60px;
    justify-content: space-between;
    align-items: center;
    gap: 80px;
}

.final-text-side {
    flex: 1.2;
    color: #fff;
    text-align: left;
    transform: translateX(-50px);
    opacity: 0;
    transition: transform 0.8s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.8s ease;
}

.reveal-form-scene.active .final-text-side {
    transform: translateX(0);
    opacity: 1;
}

/* ── Etiqueta Luminosa "Inca-tec" ── */
@keyframes neon-pulse {

    0%,
    100% {
        text-shadow:
            0 0 4px #fff,
            0 0 10px #fff,
            0 0 18px #38d9f5,
            0 0 32px #38d9f5,
            0 0 55px #38d9f5,
            0 0 80px #38d9f5;
        box-shadow:
            0 0 6px #38d9f5,
            0 0 18px #38d9f5,
            0 0 35px rgba(56, 217, 245, 0.5),
            inset 0 0 8px rgba(56, 217, 245, 0.15);
        border-color: rgba(56, 217, 245, 0.9);
    }

    50% {
        text-shadow:
            0 0 2px #fff,
            0 0 6px #fff,
            0 0 10px #38d9f5,
            0 0 20px #38d9f5,
            0 0 35px rgba(56, 217, 245, 0.6);
        box-shadow:
            0 0 3px #38d9f5,
            0 0 10px rgba(56, 217, 245, 0.6),
            0 0 20px rgba(56, 217, 245, 0.3),
            inset 0 0 4px rgba(56, 217, 245, 0.08);
        border-color: rgba(56, 217, 245, 0.5);
    }
}

.incatec-tag {
    display: inline-block;
    margin-bottom: 18px;
    padding: 5px 16px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: #fff;
    background: rgba(56, 217, 245, 0.07);
    border: 1.5px solid rgba(56, 217, 245, 0.9);
    border-radius: 4px;
    animation: neon-pulse 2.5s ease-in-out infinite;
    position: relative;
}

/* Brillo de fondo difuso detrás del tag */
.incatec-tag::before {
    content: '';
    position: absolute;
    inset: -4px -8px;
    border-radius: 8px;
    background: radial-gradient(ellipse at center, rgba(56, 217, 245, 0.18) 0%, transparent 70%);
    z-index: -1;
    pointer-events: none;
}

.final-title {
    font-size: 72px;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 20px;
    letter-spacing: -2px;
}

.final-title span {
    display: block;
    font-size: 38px;
    color: #fff;
    font-weight: 400;
    letter-spacing: 0;
    margin-top: 10px;
}

.final-description {
    font-size: 18px;
    line-height: 1.6;
    max-width: 480px;
    margin-bottom: 40px;
    opacity: 0.8;
}

.btn-leer-mas {
    display: inline-block;
    background: #01498e;
    color: #fff;
    padding: 16px 45px;
    border-radius: 980px;
    text-decoration: none;
    font-weight: 600;
    font-size: 18px;
    transition: var(--transition);
}

.btn-leer-mas:hover {
    transform: scale(1.05);
    background-color: #015bb3;
}

.final-form-side {
    flex: 0.8;
    display: flex;
    justify-content: flex-end;
    transform: translateX(50px);
    opacity: 0;
    transition: transform 0.8s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.8s ease;
}

.reveal-form-scene.active .final-form-side {
    transform: translateX(0);
    opacity: 1;
}

#div_pform {
    width: 100%;
    max-width: 400px;
    margin-top: 90px;
    /* Aún más compacto */
}

#formulario {
    background: linear-gradient(180deg, rgba(1, 73, 142, 0.95) 0%, rgba(5, 15, 30, 0.98) 100%);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 20px 50px rgba(0, 73, 142, 0.3);
}

.sp_texto_destacado h2 {
    color: #fff;
    font-size: 13px;
    /* Texto más pequeño y elegante */
    font-weight: 700;
    margin-bottom: 10px;
    text-align: left;
    line-height: 1.4;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.text {
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.6);
    color: #fff;
    height: 30px;
    margin-bottom: 15px;
    width: 100%;
    border-radius: 0;
    padding: 0 2px;
    font-size: 13px;
    /* Fuente pequeña */
    transition: var(--transition);
}

.text::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.text:focus {
    border-bottom-color: #fff;
    outline: none;
}

#btn_enviar {
    background: #01498e;
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    height: 48px;
    width: 100%;
    margin-top: 15px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
}

#btn_enviar:hover {
    transform: translateY(-2px);
    background: #015bb3;
    box-shadow: 0 5px 15px rgba(1, 73, 142, 0.4);
}

#thank {
    text-align: center;
    font-size: 16px;
    color: #fff;
    font-weight: 500;
    margin: 15px 0;
}

#prog {
    color: #fff;
    font-size: 12px;
    display: block;
    margin-bottom: 5px;
    opacity: 0.8;
}

select#programa {
    height: 36px;
    border-radius: 8px;
    padding: 0 10px;
    font-size: 13px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.9);
    width: 100%;
}

.btn-wsp {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 64px;
    height: 64px;
    background: #25d366;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1001;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
    transition: var(--transition);
}

.btn-wsp:hover {
    transform: scale(1.1) rotate(5deg);
}

/* Nueva Sección de Cuadrícula Tecnológica (Maqueta Refinada) */
.info-grid-section {
    background-color: #F1F1F3;
    padding: 140px 0;
    position: relative;
    z-index: 30;
}

.container-grid {
    max-width: 1100px;
    /* Contenedor más estrecho para tarjetas pequeñas */
    margin: 0 auto;
    padding: 0 20px;
}

.grid-section-title {
    font-size: 32px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 60px;
    color: #424245;
    letter-spacing: -1px;
}

.tech-grid-top {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 250px;
    gap: 15px;
    margin-bottom: 15px;
}

.tech-grid-bottom {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-auto-rows: 250px;
    gap: 15px;
}

.grid-card {
    background: #ffffff;
    border-radius: 22px;
    /* Radio de borde más pequeño */
    overflow: hidden;
    position: relative;
    display: flex;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.06);
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.5s ease;
}

/* Fila 1 (4 columnas): Robot (2 col = 50%) + 2 Cuadrados (1 col cada uno = 25%) */
.card-wide-main {
    grid-column: span 2;
    flex-direction: row;
}

.card-sq {
    grid-column: span 1;
}

/* Fila 2: Ecosistema (3/5) + Lab View (2/5) */
.card-ecosistema {
    grid-column: span 3;
    position: relative;
}

.card-lab-view {
    grid-column: span 2;
}

.grid-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    /* Priorizar la parte superior de las fotos */
}

/* Eliminado el efecto de hover zoom */

/* Contenido Interno */
.card-content {
    padding: 40px 0px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #fdfdfd;
}

/* Overlay para tarjeta de Salas */
.card-ecosistema {
    position: relative;
}

.card-content-overlay {
    position: absolute;
    top: 30px;
    right: 40px;
    width: 45%;
    text-align: right;
    z-index: 10;
}

.card-content-overlay p {
    color: #424245 !important;
    font-size: 16px;
    line-height: 1.4;
}

.card-content-overlay strong {
    font-weight: 700;
}

.card-wide-main .card-image {
    width: 48%;
    display: flex;
    align-items: flex-end;
    /* Pegar robot abajo */
    justify-content: flex-start;
    /* Pegar robot a la izquierda */
    position: relative;
    overflow: visible;
}

.card-wide-main .card-image img {
    height: 95%;
    /* Ajustado para que la cara no se corte por arriba */
    width: auto;
    object-fit: contain;
    object-position: center bottom;
    padding-top: 10px;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.1));
    margin-bottom: -2px;
}

.card-wide-main .card-content {
    width: 52%;
}

/* Estilos Específicos Maqueta */
.card-head-style .vertical-text {
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%) rotate(90deg);
    font-size: 60px;
    font-weight: 900;
    color: rgba(0, 0, 0, 0.03);
    letter-spacing: 5px;
}

/* Responsividad */
@media (max-width: 1200px) {
    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 400px;
    }

    .card-wide-main,
    .card-md,
    .card-sq {
        grid-column: span 2;
    }

    .card-sq {
        grid-column: span 1;
    }
}

@media (max-width: 768px) {
    .grid-section-title {
        font-size: 24px;
        margin-bottom: 30px;
        padding: 0 10px;
    }

    .tech-grid-top,
    .tech-grid-bottom {
        grid-template-columns: 1fr;
        grid-auto-rows: auto;
        gap: 20px;
    }

    .card-wide-main,
    .card-md,
    .card-sq,
    .card-ecosistema,
    .card-lab-view {
        grid-column: span 1 !important;
        flex-direction: column;
        height: auto;
        min-height: 300px;
    }

    .card-wide-main .card-image,
    .card-wide-main .card-content {
        width: 100%;
    }

    .card-wide-main .card-image {
        height: 250px;
        justify-content: center;
    }

    .card-wide-main .card-content {
        padding: 20px;
    }

    .card-content-overlay {
        position: relative;
        top: 0;
        right: 0;
        width: 100%;
        text-align: left;
        padding: 20px;
        background: #fff;
    }
}

@media (max-width: 1024px) {
    .scene-text {
        font-size: 18vw;
    }

    #formulario {
        padding: 30px;
    }
}

@media (max-width: 768px) {
    .header-content {
        padding: 0 20px;
    }

    .logo-container img {
        height: 34px;
    }

    .btn-matricula {
        padding: 6px 14px;
        font-size: 12px;
    }

    #scroll-sequence-container {
        height: 700vh !important;
        /* Forzar altura para evitar saltos */
        position: relative;
    }

    /* Ajustes Final Form Scene Responsive */
    .reveal-form-scene {
        padding: 80px 10px 40px;
        /* Más espacio para el logo y ancho lateral */
        align-items: flex-start;
        overflow-y: auto;
        background: rgba(0, 0, 0, 0.55);
        /* Capa oscura más efectiva para el texto blanco */
    }

    .final-content-wrapper {
        flex-direction: column;
        padding: 0;
        gap: 25px;
        align-items: center;
        text-align: center;
        width: 100%;
        max-width: 100%;
    }

    .final-text-side {
        flex: none;
        width: 100%;
        text-align: center;
        transform: translateY(-20px);
        text-shadow: 0 2px 15px rgba(0, 0, 0, 1);
        /* Sombra absoluta */
    }

    .reveal-form-scene.active .final-text-side {
        transform: translateY(0);
    }

    .final-title {
        font-size: 32px;
        line-height: 1.1;
        margin-bottom: 12px;
        text-shadow: 0 4px 20px rgba(0, 0, 0, 1);
    }

    .final-title span {
        font-size: 18px;
        color: #fff !important;
    }

    .final-description {
        font-size: 15px;
        line-height: 1.4;
        margin: 0 auto 15px;
        max-width: 100%;
        color: #fff !important;
        text-shadow: 0 2px 10px rgba(0, 0, 0, 1);
        opacity: 1;
    }

    .final-form-side {
        flex: none;
        width: 100%;
        justify-content: center;
        transform: translateY(20px);
    }

    .reveal-form-scene.active .final-form-side {
        transform: translateY(0);
    }

    #div_pform {
        margin-top: 0;
        width: 100%;
        max-width: 100%;
        /* Formulario a todo lo ancho */
    }

    #formulario {
        padding: 20px 15px;
        /* Más espacio interno */
        border-radius: 15px;
    }
}

/* Sección de Tecnología Avanzada y Slider Infinito */
.advanced-tech-section {
    background-color: #ffffff;
    padding: 120px 0 50px 0;
    overflow: hidden;
    position: relative;
    z-index: 30;
}

.advanced-header {
    max-width: 900px;
    margin: 0 auto 80px;
    text-align: center;
    padding: 0 20px;
}

.advanced-header .sub-title {
    display: block;
    font-size: 18px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 15px;
}

.advanced-header .main-title {
    font-size: 58px;
    font-weight: 700;
    line-height: 1.1;
    color: #1d1d1f;
    margin-bottom: 30px;
    letter-spacing: -2px;
}

.advanced-header .description {
    font-size: 21px;
    line-height: 1.5;
    color: #424245;
    margin-bottom: 40px;
    font-weight: 400;
}

.btn-matricula-cta {
    display: inline-block;
    background: #01498e;
    color: #ffffff;
    padding: 12px 28px;
    border-radius: 980px;
    text-decoration: none;
    font-size: 17px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-matricula-cta:hover {
    background: #013d75;
    transform: scale(1.05);
}

/* Slider Infinito de 3 Filas */
.slider-wrapper {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 50px;
}

.slider-row {
    width: 100%;
    overflow: hidden;
    position: relative;
    display: flex;
}

.infinite-slider {
    display: flex;
    gap: 12px;
    width: fit-content;
    will-change: transform;
}

/* Todas las filas se mueven a la misma velocidad */
.row-1 .infinite-slider {
    animation: scrollLeft 160s linear infinite;
}

.row-2 .infinite-slider {
    animation: scrollRight 220s linear infinite;
}

.row-3 .infinite-slider {
    animation: scrollLeft 160s linear infinite;
}

/* Eliminado el pause al hover para movimiento constante */

.slider-item {
    height: 140px;
    /* Tamaño más pequeño */
    flex-shrink: 0;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.04);
    background: #f5f5f7;
}

/* Diferentes tamaños de tiles reducidos */
.slider-item.w-sm {
    width: 100px;
}

.slider-item.w-md {
    width: 200px;
}

.slider-item.w-lg {
    width: 320px;
}

.slider-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.slider-item:hover img {
    transform: scale(1.05);
}

@keyframes scrollLeft {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

@keyframes scrollRight {
    0% {
        transform: translateX(-50%);
    }

    100% {
        transform: translateX(0);
    }
}

/* Responsividad */
@media (max-width: 768px) {
    .advanced-header .sub-title {
        font-size: 14px;
        margin-bottom: 10px;
    }

    .advanced-header .main-title {
        font-size: 24px;
        letter-spacing: -1px;
        margin-bottom: 20px;
    }

    .advanced-header .description {
        font-size: 16px;
        line-height: 1.4;
    }

    .slider-item {
        height: 90px;
    }

    .slider-item.w-sm {
        width: 80px;
    }

    .slider-item.w-md {
        width: 150px;
    }

    .slider-item.w-lg {
        width: 220px;
    }
}

/* Footer minimalista */
footer {
    background-color: #ffffff;
    padding: 40px 0 30px;
    /* Altura reducida */
    text-align: center;
    border-top: 1px solid #f5f5f7;
    position: relative;
    z-index: 30;
}

.footer-logo {
    height: 60px;
    /* Logo más grandecito */
    margin-bottom: 15px;
    opacity: 1;
    /* Más visibilidad */
}

.footer-text {
    font-size: 13px;
    color: #86868b;
    font-weight: 400;
}

/* Animaciones por Scroll */
/* Menú Lateral (Side Menu) */
.side-menu {
    position: fixed;
    top: 0;
    right: -300px;
    /* Oculto por defecto */
    width: 300px;
    height: 100vh;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 2000;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.05);
    transition: transform 0.5s cubic-bezier(0.19, 1, 0.22, 1);
    display: flex;
    flex-direction: column;
    padding: 30px;
}

.side-menu.active {
    transform: translateX(-300px);
}

.side-menu-header {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 50px;
}

.close-menu {
    cursor: pointer;
    color: #1d1d1f;
    transition: var(--transition);
}

.close-menu:hover {
    transform: rotate(90deg);
    opacity: 0.7;
}

.side-nav {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.side-link {
    font-size: 24px;
    font-weight: 600;
    color: #1d1d1f;
    text-decoration: none;
    transition: var(--transition);
    opacity: 0.8;
}

.side-link:hover {
    opacity: 1;
    transform: translateX(10px);
    color: #01498e;
}

/* Backdrop */
.menu-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(4px);
    z-index: 1999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.menu-backdrop.active {
    opacity: 1;
    pointer-events: auto;
}

.menu-icon {
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    color: #1d1d1f;
    /* Color oscuro sólido */
}

.menu-icon svg {
    stroke: currentColor;
    stroke-width: 2.5;
    /* Líneas un poco más gruesas */
}

.menu-icon:hover {
    opacity: 0.7;
}

.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s cubic-bezier(0.19, 1, 0.22, 1), transform 1s cubic-bezier(0.19, 1, 0.22, 1);
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}