/* --- CONFIGURACIÓN DE TIPOGRAFÍA --- */
@font-face {
    font-family: 'Artifakt Element';
    src: url('ArtifaktElement-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
}

:root {
    --color-fondo: #0a0a0a;
    --color-texto: #f4f4f4;
    --color-acento: #ffffff;
}

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

body, html {
    font-family: 'Artifakt Element', Arial, sans-serif;
    background-color: var(--color-fondo);
    color: var(--color-texto);
    overflow-x: hidden;
}

#master-container {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden; 
}

.capa-pantalla {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100vh;
    overflow: hidden;
    display: flex;
}

/* --- SECCIÓN 1: HERO --- */
#hero { align-items: center; justify-content: center; z-index: 3; }
.hero-bg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-size: cover; background-position: center; z-index: 1; }
.hero-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(135deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 100%); z-index: 2; }
.hero-content { position: relative; z-index: 3; max-width: 900px; text-align: center; padding: 0 20px; margin-top: 20px; }
.hero-title { font-size: clamp(2.2rem, 4.5vw, 3.5rem); font-weight: 700; letter-spacing: -1px; margin-bottom: 20px; text-transform: uppercase; color: #fff; }
.subtitle-small { font-size: clamp(1.2rem, 2.5vw, 1.8rem); background: linear-gradient(90deg, #ffffff, #888888); -webkit-background-clip: text; -webkit-text-fill-color: transparent; text-transform: none; display: block; margin-top: 5px; }
.hero-description { font-size: 1.05rem; line-height: 1.7; color: #aaaaaa; margin-bottom: 35px; font-weight: 400; }

/* BOTÓN PLATAFORMA ESQUINA SUPERIOR DERECHA */
.plataforma-wrapper {
    position: absolute;
    top: 30px; 
    right: 50px;
    z-index: 1150; 
}

.btn-plataforma {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #ffffff;
    text-decoration: none;
    padding: 8px 16px;
    font-size: 0.78rem; 
    font-weight: 400;
    letter-spacing: 0.5px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(8px);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.btn-plataforma i { font-size: 0.9rem; color: #aaaaaa; transition: color 0.3s; }
.btn-plataforma:hover { background: rgba(255, 255, 255, 0.09); border-color: rgba(255, 255, 255, 0.3); transform: translateY(-1px); box-shadow: 0 5px 15px rgba(0,0,0,0.3); }
.btn-plataforma:hover i { color: #ffffff; }

.hero-contact-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 15px; max-width: 650px; margin: 0 auto; }
.contact-item { background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.08); padding: 12px 20px; border-radius: 12px; display: flex; align-items: center; gap: 12px; transition: all 0.3s ease; }
.contact-item i { color: #fff; font-size: 1.1rem; }
.contact-item a { color: #cccccc; text-decoration: none; font-size: 0.9rem; transition: color 0.3s; }
.contact-item:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.2); transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0,0,0,0.3); }
.contact-item:hover a { color: #fff; }

/* --- BARRA NAVEGACIÓN Y CONFIGURACIÓN LOGO --- */
.navbar { position: fixed; top: 0; left: 0; width: 100%; height: 95px; padding: 20px 50px; z-index: 1100; background: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%); pointer-events: none; }
.logo-container { position: fixed; z-index: 1150; display: flex; align-items: center; pointer-events: auto; }
.logo-img { height: 55px; width: auto; filter: brightness(0) invert(1); clip-path: inset(3% 3% 3% 3%); }

/* --- PUNTOS LATERALES --- */
.dot-navigation { position: fixed; right: 30px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 20px; z-index: 1200; }
.dot { position: relative; width: 10px; height: 10px; background-color: rgba(255, 255, 255, 0.3); border: none; border-radius: 50%; cursor: pointer; transition: all 0.3s ease; }
.dot.active, .dot:hover { background-color: var(--color-acento); transform: scale(1.3); box-shadow: 0 0 10px rgba(255, 255, 255, 0.8); }
.dot span { position: absolute; right: 25px; top: 50%; transform: translateY(-50%) translateX(10px); background-color: rgba(0, 0, 0, 0.8); color: #fff; padding: 5px 12px; font-size: 0.8rem; border-radius: 4px; opacity: 0; pointer-events: none; white-space: nowrap; transition: all 0.3s ease; border: 1px solid rgba(255,255,255,0.1); }
.dot:hover span { opacity: 1; transform: translateY(-50%) translateX(0); }

/* --- SECCIÓN 2: SERVICIOS --- */
.seccion-servicios { justify-content: center; align-items: center; visibility: hidden; opacity: 0; z-index: 1; pointer-events: none; }
.seccion-servicios::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-image: url('fondo-servicios.png'); background-size: cover; background-position: center; opacity: 0.12; pointer-events: none; z-index: 0; }

.container-ramillete { width: 100%; max-width: 1200px; display: flex; flex-direction: column; align-items: center; z-index: 1; padding: 0 20px; }
.header-servicios { text-align: center; margin-bottom: 20px; width: 100%; position: relative; z-index: 1; }
.titulo-servicios { font-size: clamp(2.4rem, 4vw, 3.4rem); font-weight: 700; letter-spacing: -1px; margin-bottom: 12px; color: #ffffff; }
.subtitulo-servicios { font-size: 1.1rem; color: #ffffff; max-width: 700px; margin: 0 auto; font-weight: 700; line-height: 1.6; text-shadow: 0 2px 15px rgba(0,0,0,0.9); }

.workspace-servicios { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 30px; position: relative; z-index: 10; }
.escenario-ramillete { position: relative; width: 60%; height: 480px; display: flex; justify-content: center; align-items: center; z-index: 20; margin-top: 15px; }
.lote-burbujas { position: absolute; width: 100%; height: 100%; display: none; visibility: hidden; justify-content: center; align-items: center; pointer-events: none; }

/* BURBUJAS INTERACTIVAS */
.burbuja { position: absolute; background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 50%; display: flex; justify-content: center; align-items: center; backdrop-filter: blur(14px); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5); cursor: pointer; transition: background 0.4s, border-color 0.4s, box-shadow 0.4s; }
.inner-burbuja { display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; width: 100%; height: 100%; padding: 15px; }
.burbuja i { color: #fff; margin-bottom: 5px; font-size: 1.5rem; }
.burbuja span { color: #ccc; font-size: 0.75rem; padding: 0 5px; line-height: 1.2; }
.burbuja:hover { background: rgba(255, 255, 255, 0.06); border-color: rgba(255, 255, 255, 0.3); }
.burbuja.activa { border-color: rgba(255, 255, 255, 0.6) !important; box-shadow: 0 0 35px rgba(255, 255, 255, 0.25) !important; background: rgba(255, 255, 255, 0.09) !important; z-index: 9999 !important; }

/* VIÑETA FLOTANTE DE BURBUJA */
.vineta-desc { position: absolute; bottom: 122%; left: 50%; transform: translateX(-50%) translateY(10px); width: 240px; background: rgba(12, 12, 12, 0.98); border: 1px solid rgba(255, 255, 255, 0.2); padding: 14px 16px; border-radius: 14px; font-size: 0.8rem; color: #f4f4f4; line-height: 1.4; text-align: center; pointer-events: none; opacity: 0; backdrop-filter: blur(16px); box-shadow: 0 15px 35px rgba(0,0,0,0.8); z-index: 10000 !important; transition: opacity 0.4s cubic-bezier(0.165, 0.84, 0.44, 1), transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1); }
.vineta-desc::after { content: ''; position: absolute; top: 100%; left: 50%; transform: translateX(-50%); border-width: 6px; border-style: solid; border-color: rgba(12, 12, 12, 0.98) transparent transparent transparent; }
.burbuja.activa .vineta-desc { opacity: 1; transform: translateX(-50%) translateY(0); }

/* COORDENADAS BURBUJAS */
.burbuja.centro { width: 145px; height: 145px; z-index: 10; background: rgba(255, 255, 255, 0.04); border-color: rgba(255, 255, 255, 0.12); }
.burbuja.centro span { font-size: 0.85rem; font-weight: 700; color: #fff; }
.c-azul { box-shadow: 0 0 35px rgba(0, 113, 227, 0.12); }
.c-verde { box-shadow: 0 0 35px rgba(52, 199, 89, 0.12); }
.burbuja.satelite.s1 { width: 125px; height: 125px; z-index: 8; }
.burbuja.satelite.s2 { width: 110px; height: 110px; z-index: 6; }
.burbuja.satelite.s3 { width: 120px; height: 120px; z-index: 7; }
.burbuja.satelite.s4 { width: 100px; height: 100px; z-index: 5; }

.pos-top-left         { transform: translate(-150px, -130px); }
.pos-top-right        { transform: translate(150px, -120px); }
.pos-bottom-right     { transform: translate(140px, 130px); }
.pos-bottom-left      { transform: translate(-140px, 120px); }
.pos-top-straight     { transform: translate(0px, -175px); } 
.pos-bottom-right-alt { transform: translate(145px, 130px); }
.pos-left-straight    { transform: translate(-165px, 0px); }

.burbuja-logo-final { position: relative; width: 170px; height: 170px; background: rgba(10, 10, 10, 0.8); border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 50%; display: flex; justify-content: center; align-items: center; backdrop-filter: blur(20px); }
.logo-ramillete { width: 60%; height: auto; filter: brightness(0) invert(1); clip-path: inset(3% 3% 3% 3%); }
.resplandor-logo { position: absolute; width: 100%; height: 100%; border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, rgba(255,255,255,0) 70%); z-index: -1; }

.menu-side-container { width: 38%; display: flex; justify-content: center; z-index: 10; }
.menu-side-card { background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 24px; padding: 25px; width: 100%; max-width: 380px; backdrop-filter: blur(20px); box-shadow: 0 20px 45px rgba(0,0,0,0.5); }
.opciones-side-grid { display: flex; flex-direction: column; gap: 12px; }
.opcion-side-btn { background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 16px; padding: 16px 20px; display: flex; align-items: center; text-decoration: none; transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1); }
.opcion-side-btn > i { font-size: 1.4rem; color: #aaa; transition: color 0.3s; }
.opcion-side-btn .arrow-icon { font-size: 1.6rem; color: transparent; margin-left: auto; transform: translateX(-5px); transition: all 0.3s; }
.opcion-text { margin-left: 18px; display: flex; flex-direction: column; gap: 2px; }
.opcion-text h4 { font-size: 0.95rem; font-weight: 700; color: #e5e5ea; transition: color 0.3s; }
.opcion-text span { font-size: 0.75rem; color: #666; }
.opcion-side-btn:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.2); transform: translateY(-2px); box-shadow: 0 10px 20px rgba(0,0,0,0.4); }
.opcion-side-btn:hover > i { color: #fff; }
.opcion-side-btn:hover .opcion-text h4 { color: #fff; }
.opcion-side-btn:hover .arrow-icon { color: #fff; transform: translateX(0); }

/* --- SECCIÓN 3: NOSOTROS --- */
.seccion-nosotros { justify-content: center; align-items: center; background-color: #080808; visibility: hidden; opacity: 0; z-index: 1; }
.seccion-nosotros::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-image: url('fondo-nosotros.jpg'); background-size: cover; background-position: center; opacity: 0.1; pointer-events: none; z-index: 0; }

.container-nosotros { width: 100%; max-width: 1200px; display: flex; justify-content: space-between; align-items: center; gap: 40px; z-index: 1; padding: 0 40px; }
.nosotros-left { width: 40%; }
.titulo-nosotros { font-size: clamp(2.3rem, 4vw, 3.4rem); font-weight: 700; line-height: 1.15; letter-spacing: -1px; color: #ffffff; }
.highlight-text { background: linear-gradient(90deg, #ffffff, #666666); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

.nosotros-right { width: 55%; display: flex; flex-direction: column; gap: 15px; max-height: 85vh; }
.card-nosotros { background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 20px; padding: 24px 30px; backdrop-filter: blur(20px); box-shadow: 0 15px 35px rgba(0,0,0,0.4); }
.icon-nosotros-box { width: 40px; height: 40px; background: rgba(255, 255, 255, 0.04); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 10px; display: flex; justify-content: center; align-items: center; margin-bottom: 12px; }
.icon-nosotros-box i { color: #fff; font-size: 1.15rem; }
.card-nosotros p { font-size: 0.92rem; line-height: 1.55; color: #cccccc; font-weight: 400; }

/* --- SECCIÓN 4: CONTACTO FINAL --- */
.seccion-contacto { justify-content: center; align-items: center; background-color: #050505; visibility: hidden; opacity: 0; z-index: 1; pointer-events: none; }
.container-contacto { width: 100%; max-width: 900px; text-align: center; padding: 0 20px; z-index: 1; }
.quote-block { margin-bottom: 50px; }
.quote-text { font-size: clamp(1.8rem, 3.8vw, 2.8rem); font-weight: 700; line-height: 1.25; letter-spacing: -1px; color: #ffffff; margin-bottom: 15px; }
.quote-author { font-size: 1.05rem; color: #555555; text-transform: uppercase; letter-spacing: 2px; font-weight: 700; display: block; }
.contact-final-grid { max-width: 700px; margin: 0 auto; }

/* ==========================================================================
   ARQUITECTURA DE TRANSICIONES PREMIUM PARA MÓVILES (REEMPLAZA ESTA SECCIÓN)
   ========================================================================== */
@media (max-width: 900px) {
    /* Mantenemos el contenedor maestro fijo para las transiciones */
    #master-container {
        position: relative;
        width: 100%;
        height: 100vh;
        overflow: hidden; 
    }

    /* Redimensionamiento milimétrico de las pantallas inmersivas */
    .capa-pantalla {
        position: absolute !important;
        top: 0; left: 0; width: 100%; height: 100vh;
        overflow: hidden;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 60px 24px;
    }

    /* --- ELIMINACIONES DE SEGURIDAD EN MÓVIL --- */
    .plataforma-wrapper { 
        display: none !important; 
    }

    /* El logo inicia visible pero con posición absoluta controlada por el script */
    .logo-container {
        position: absolute;
        z-index: 1150;
        display: flex;
    }
    .logo-img { height: 45px; }

    /* --- OPTIMIZACIÓN SECCIÓN 1 (HERO) --- */
    .hero-content { max-width: 100%; margin-top: 40px; }
    .hero-title { font-size: 1.8rem !important; line-height: 1.2; }
    .subtitle-small { font-size: 1.1rem !important; }
    .hero-description { font-size: 0.85rem; line-height: 1.5; margin-bottom: 20px; color: #aaaaaa; }
    .hero-contact-grid { grid-template-columns: 1fr; width: 100%; gap: 10px; }
    .contact-item { padding: 10px 15px; border-radius: 10px; gap: 10px; }
    .contact-item a { font-size: 0.82rem; }

    /* --- OPTIMIZACIÓN SECCIÓN 2 (SERVICIOS Y BOTONES) --- */
    .titulo-servicios { font-size: 1.5rem !important; letter-spacing: -0.5px; margin-bottom: 6px; }
    .subtitulo-servicios { font-size: 0.85rem !important; line-height: 1.4; color: #cccccc; margin-bottom: 10px; }
    .workspace-servicios { flex-direction: column; gap: 10px; width: 100%; position: relative; z-index: 100; }
    
    /* Forzado de clicks activos para los botones de servicios */
    .menu-side-container { width: 100%; pointer-events: auto !important; z-index: 110; }
    .menu-side-card { max-width: 100%; padding: 12px; border-radius: 16px; pointer-events: auto !important; }
    .opcion-side-btn { padding: 12px; border-radius: 12px; pointer-events: auto !important; display: flex !important; }
    .opcion-text h4 { font-size: 0.85rem; }
    
    .escenario-ramillete { 
        width: 100%; 
        height: 260px; 
        transform: scale(0.68) !important; /* Ramillete compactado para no pisar textos */
        margin-top: -15px !important;
        pointer-events: auto !important;
    }

    /* --- OPTIMIZACIÓN SECCIÓN 3 (NOSOTROS CON SCROLL INTERNO GSAP) --- */
    .container-nosotros { flex-direction: column; gap: 15px; padding: 0 !important; width: 100%; }
    .nosotros-left { width: 100%; text-align: center; }
    .titulo-nosotros { font-size: 1.5rem !important; line-height: 1.2; }
    
    /* Altura fija controlada para que el motor de GSAP desplace el texto de forma fluida */
    .nosotros-right { 
        width: 100%; 
        height: 42vh !important; 
        overflow-y: hidden; /* Ocultamos el scroll nativo tosco para usar el cinemático */
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    .card-nosotros { padding: 18px 20px; border-radius: 14px; }
    .card-nosotros p { font-size: 0.85rem; line-height: 1.5; color: #cccccc; }
    .icon-nosotros-box { width: 34px; height: 34px; margin-bottom: 6px; }

    /* --- OPTIMIZACIÓN SECCIÓN 4 (CONTACTO) --- */
    .quote-block { margin-bottom: 25px; }
    .quote-text { font-size: 1.25rem; line-height: 1.35; }
    .contact-final-grid { display: grid; grid-template-columns: repeat(2, 1fr) !important; gap: 10px; width: 100%; }
    .contact-final-grid .contact-item { padding: 12px 10px; border-radius: 10px; }
    .contact-final-grid .contact-item a { font-size: 0.75rem; }

    /* Ajuste de los puntos de navegación en pantallas de iPhone */
    .dot-navigation { right: 15px; gap: 15px; }
    .dot { width: 8px; height: 8px; }
}

@media (max-width: 380px) {
    .escenario-ramillete { transform: scale(0.58) !important; height: 220px; }
    .nosotros-right { height: 38vh !important; }
}