
:root {
    --primario: #1c4b81;
    --primario-claro: #2563eb;
    --primario-oscuro: #1e3a8a;
    --secundario: #64748b;
    --acento: #06b6d4;
    --superficie: #ffffff;
    --superficie-alternativa: #f8fafc;
    --superficie-cristal: rgba(255, 255, 255, 0.1);
    --texto-primario: #0f172a;
    --texto-secundario: #475569;
    --texto-silenciado: #94a3b8;
    --borde: rgba(148, 163, 184, 0.2);
    --sombra-pequena: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --sombra-mediana: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --sombra-grande: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --sombra-extra-grande: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --gradiente-primario: linear-gradient(135deg, var(--primario) 0%, var(--primario-claro) 100%);
    --gradiente-cristal: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--texto-primario);
    background: var(--superficie-alternativa);
    overflow-x: hidden;
}

/* Navegación con Efecto Cristal */
.barra-navegacion-cristal {
    background: white;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--borde);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.barra-navegacion-cristal.desplazada {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--sombra-grande);
}

.marca-navegacion {
    font-weight: 800;
    font-size: 1.75rem;
    color: var(--primario) !important;
    letter-spacing: -0.025em;
}

.enlace-navegacion {
    font-weight: 500;
    color: var(--texto-secundario) !important;
    transition: all 0.3s ease;
    position: relative;
}

.enlace-navegacion:hover {
    color: var(--primario) !important;
}

.enlace-navegacion::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradiente-primario);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.enlace-navegacion:hover::after {
    width: 100%;
}

/* SECCIÓN HERO CON MUCHO MÁS MOVIMIENTO */
.seccion-hero {
    height: 100vh;
    min-height: 600px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #0f172a 0%, var(--primario) 50%, var(--primario-claro) 100%);
}

.fondo-hero {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="grid" width="50" height="50" patternUnits="userSpaceOnUse"><path d="M 50 0 L 0 0 0 50" fill="none" stroke="rgba(255,255,255,0.02)" stroke-width="0.5"/></pattern><pattern id="network" width="200" height="200" patternUnits="userSpaceOnUse"><g fill="none" stroke="rgba(255,255,255,0.08)" stroke-width="1"><circle cx="50" cy="50" r="3" fill="rgba(255,255,255,0.1)"/><circle cx="150" cy="50" r="2" fill="rgba(255,255,255,0.08)"/><circle cx="100" cy="100" r="4" fill="rgba(255,255,255,0.12)"/><circle cx="50" cy="150" r="2.5" fill="rgba(255,255,255,0.09)"/><circle cx="150" cy="150" r="3.5" fill="rgba(255,255,255,0.11)"/><circle cx="25" cy="25" r="2" fill="rgba(255,255,255,0.07)"/><circle cx="175" cy="25" r="2.5" fill="rgba(255,255,255,0.08)"/><circle cx="25" cy="175" r="3" fill="rgba(255,255,255,0.1)"/><circle cx="175" cy="175" r="2" fill="rgba(255,255,255,0.07)"/><circle cx="100" cy="25" r="1.5" fill="rgba(255,255,255,0.06)"/><circle cx="100" cy="175" r="2.5" fill="rgba(255,255,255,0.08)"/><circle cx="25" cy="100" r="2" fill="rgba(255,255,255,0.07)"/><circle cx="175" cy="100" r="3" fill="rgba(255,255,255,0.09)"/><line x1="50" y1="50" x2="150" y2="50" stroke-dasharray="2,3" opacity="0.4"/><line x1="50" y1="50" x2="100" y2="100" stroke-dasharray="1,2" opacity="0.3"/><line x1="150" y1="50" x2="100" y2="100" stroke-dasharray="2,2" opacity="0.35"/><line x1="100" y1="100" x2="50" y2="150" stroke-dasharray="1,3" opacity="0.3"/><line x1="100" y1="100" x2="150" y2="150" stroke-dasharray="2,1" opacity="0.4"/><line x1="50" y1="150" x2="150" y2="150" stroke-dasharray="3,2" opacity="0.25"/><line x1="25" y1="25" x2="50" y2="50" stroke-dasharray="1,2" opacity="0.2"/><line x1="175" y1="25" x2="150" y2="50" stroke-dasharray="2,3" opacity="0.25"/><line x1="25" y1="175" x2="50" y2="150" stroke-dasharray="1,1" opacity="0.3"/><line x1="175" y1="175" x2="150" y2="150" stroke-dasharray="2,2" opacity="0.2"/><line x1="100" y1="25" x2="100" y2="100" stroke-dasharray="3,1" opacity="0.15"/><line x1="100" y1="175" x2="100" y2="100" stroke-dasharray="1,3" opacity="0.2"/><line x1="25" y1="100" x2="100" y2="100" stroke-dasharray="2,2" opacity="0.18"/><line x1="175" y1="100" x2="100" y2="100" stroke-dasharray="1,2" opacity="0.22"/><line x1="25" y1="25" x2="100" y2="25" stroke-dasharray="2,4" opacity="0.1"/><line x1="175" y1="25" x2="100" y2="25" stroke-dasharray="3,2" opacity="0.12"/><line x1="25" y1="175" x2="100" y2="175" stroke-dasharray="1,3" opacity="0.15"/><line x1="175" y1="175" x2="100" y2="175" stroke-dasharray="2,1" opacity="0.18"/><line x1="25" y1="25" x2="25" y2="100" stroke-dasharray="1,4" opacity="0.08"/><line x1="25" y1="175" x2="25" y2="100" stroke-dasharray="2,3" opacity="0.1"/><line x1="175" y1="25" x2="175" y2="100" stroke-dasharray="3,1" opacity="0.12"/><line x1="175" y1="175" x2="175" y2="100" stroke-dasharray="1,2" opacity="0.14"/><path d="M50,50 Q75,25 100,50 T150,50" fill="none" stroke="rgba(6,182,212,0.1)" stroke-width="1" opacity="0.3"/><path d="M50,150 Q100,125 150,150" fill="none" stroke="rgba(6,182,212,0.08)" stroke-width="1" opacity="0.25"/><path d="M100,25 Q125,50 100,100 Q75,150 100,175" fill="none" stroke="rgba(6,182,212,0.06)" stroke-width="1" opacity="0.2"/></g></pattern><radialGradient id="nodeGlow" cx="50%" cy="50%" r="50%"><stop offset="0%" style="stop-color:rgba(255,255,255,0.3);stop-opacity:1" /><stop offset="100%" style="stop-color:rgba(255,255,255,0);stop-opacity:0" /></radialGradient><filter id="glow"><feGaussianBlur stdDeviation="2" result="coloredBlur"/><feMerge><feMergeNode in="coloredBlur"/><feMergeNode in="SourceGraphic"/></feMerge></filter></defs><rect width="100%" height="100%" fill="url(%23grid)"/><rect width="100%" height="100%" fill="url(%23network)" opacity="0.6"/><g filter="url(%23glow)"><circle cx="200" cy="200" r="8" fill="rgba(6,182,212,0.4)" opacity="0.8"><animate attributeName="r" values="6;10;6" dur="4s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.6;1;0.6" dur="4s" repeatCount="indefinite"/></circle><circle cx="800" cy="300" r="6" fill="rgba(6,182,212,0.3)" opacity="0.7"><animate attributeName="r" values="4;8;4" dur="6s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.5;0.9;0.5" dur="6s" repeatCount="indefinite"/></circle><circle cx="300" cy="700" r="7" fill="rgba(6,182,212,0.35)" opacity="0.75"><animate attributeName="r" values="5;9;5" dur="5s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.6;1;0.6" dur="5s" repeatCount="indefinite"/></circle><circle cx="700" cy="150" r="5" fill="rgba(6,182,212,0.25)" opacity="0.6"><animate attributeName="r" values="3;7;3" dur="7s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.4;0.8;0.4" dur="7s" repeatCount="indefinite"/></circle><circle cx="500" cy="500" r="10" fill="rgba(6,182,212,0.5)" opacity="0.9"><animate attributeName="r" values="8;12;8" dur="3s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.7;1;0.7" dur="3s" repeatCount="indefinite"/></circle><circle cx="150" cy="600" r="4" fill="rgba(6,182,212,0.2)" opacity="0.5"><animate attributeName="r" values="2;6;2" dur="8s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.3;0.7;0.3" dur="8s" repeatCount="indefinite"/></circle><circle cx="850" cy="750" r="6" fill="rgba(6,182,212,0.3)" opacity="0.65"><animate attributeName="r" values="4;8;4" dur="4.5s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.5;0.9;0.5" dur="4.5s" repeatCount="indefinite"/></circle></g><g stroke="rgba(6,182,212,0.15)" stroke-width="1" fill="none"><path d="M200,200 Q350,150 500,500 Q650,350 800,300"><animate attributeName="stroke-dasharray" values="0,1000;1000,0;0,1000" dur="15s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.1;0.4;0.1" dur="15s" repeatCount="indefinite"/></path><path d="M300,700 Q400,400 500,500 Q600,200 700,150"><animate attributeName="stroke-dasharray" values="0,800;800,0;0,800" dur="12s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.1;0.3;0.1" dur="12s" repeatCount="indefinite"/></path><path d="M150,600 Q300,500 500,500 Q700,400 850,750"><animate attributeName="stroke-dasharray" values="0,1200;1200,0;0,1200" dur="18s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.05;0.25;0.05" dur="18s" repeatCount="indefinite"/></path><line x1="200" y1="200" x2="300" y2="700"><animate attributeName="stroke-dasharray" values="0,500;500,0;0,500" dur="10s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.1;0.3;0.1" dur="10s" repeatCount="indefinite"/></line><line x1="800" y1="300" x2="700" y2="150"><animate attributeName="stroke-dasharray" values="0,300;300,0;0,300" dur="8s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.1;0.4;0.1" dur="8s" repeatCount="indefinite"/></line><line x1="500" y1="500" x2="150" y2="600"><animate attributeName="stroke-dasharray" values="0,400;400,0;0,400" dur="11s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.1;0.35;0.1" dur="11s" repeatCount="indefinite"/></line><line x1="500" y1="500" x2="850" y2="750"><animate attributeName="stroke-dasharray" values="0,450;450,0;0,450" dur="13s" repeatCount="indefinite"/><animate attributeName="opacity" values="0.1;0.3;0.1" dur="13s" repeatCount="indefinite"/></line></g></svg>');
}

/* ELEMENTOS FLOTANTES MEJORADOS */
.elemento-flotante {
    position: absolute;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    animation: flotar 6s ease-in-out infinite;
}

.elemento-flotante:nth-child(1) {
    top: 20%;
    left: 10%;
    width: 80px;
    height: 80px;
    animation-delay: 0s;
}

.elemento-flotante:nth-child(2) {
    top: 60%;
    right: 15%;
    width: 60px;
    height: 60px;
    animation-delay: 2s;
}

.elemento-flotante:nth-child(3) {
    bottom: 30%;
    left: 20%;
    width: 100px;
    height: 100px;
    animation-delay: 4s;
}

/* NUEVOS CÍRCULOS FLOTANTES */
.circulo-flotante {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.02) 100%);
    border: 1px solid rgba(255,255,255,0.1);
    animation: flotarCirculo 8s ease-in-out infinite;
}

.circulo-flotante:nth-child(4) {
    top: 15%;
    right: 20%;
    width: 120px;
    height: 120px;
    animation-delay: 1s;
}

.circulo-flotante:nth-child(5) {
    bottom: 20%;
    right: 30%;
    width: 80px;
    height: 80px;
    animation-delay: 3s;
}

.circulo-flotante:nth-child(6) {
    top: 40%;
    left: 5%;
    width: 150px;
    height: 150px;
    animation-delay: 5s;
}

@keyframes flotarCirculo {
    0%, 100% { 
        transform: translateY(0px) translateX(0px) rotate(0deg); 
        opacity: 0.3;
    }
    25% { 
        transform: translateY(-15px) translateX(10px) rotate(90deg); 
        opacity: 0.6;
    }
    50% { 
        transform: translateY(-30px) translateX(-5px) rotate(180deg); 
        opacity: 0.4;
    }
    75% { 
        transform: translateY(-10px) translateX(-15px) rotate(270deg); 
        opacity: 0.7;
    }
}

/* PARTÍCULAS ANIMADAS */
.particula {
    position: absolute;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    pointer-events: none;
    animation: particula 10s linear infinite;
}

.particula:nth-child(7) {
    top: 10%;
    left: 30%;
    width: 4px;
    height: 4px;
    animation-delay: 0s;
}

.particula:nth-child(8) {
    top: 70%;
    left: 60%;
    width: 6px;
    height: 6px;
    animation-delay: 2s;
}

.particula:nth-child(9) {
    top: 30%;
    right: 10%;
    width: 3px;
    height: 3px;
    animation-delay: 4s;
}

.particula:nth-child(10) {
    bottom: 40%;
    left: 40%;
    width: 5px;
    height: 5px;
    animation-delay: 6s;
}

@keyframes particula {
    0% { 
        transform: translateY(0px) scale(0);
        opacity: 0;
    }
    10% {
        transform: translateY(-10px) scale(1);
        opacity: 1;
    }
    90% {
        transform: translateY(-100px) scale(1);
        opacity: 1;
    }
    100% { 
        transform: translateY(-120px) scale(0);
        opacity: 0;
    }
}

/* ELEMENTOS GEOMÉTRICOS PULSANTES */
.elemento-pulsante {
    position: absolute;
    background: linear-gradient(45deg, rgba(255,255,255,0.1), rgba(6,182,212,0.2));
    animation: pulsar 4s ease-in-out infinite;
}

.elemento-pulsante.triangulo {
    width: 0;
    height: 0;
    background: none;
    border-left: 25px solid transparent;
    border-right: 25px solid transparent;
    border-bottom: 43px solid rgba(255,255,255,0.1);
    top: 25%;
    right: 40%;
    animation-delay: 1s;
}

.elemento-pulsante.diamante {
    width: 40px;
    height: 40px;
    transform: rotate(45deg);
    top: 55%;
    left: 70%;
    animation-delay: 3s;
}

.elemento-pulsante.hexagono {
    width: 60px;
    height: 34.64px;
    background: rgba(255,255,255,0.08);
    position: relative;
    top: 80%;
    right: 25%;
    animation-delay: 2s;
}

.elemento-pulsante.hexagono:before,
.elemento-pulsante.hexagono:after {
    content: "";
    position: absolute;
    width: 0;
    border-left: 30px solid transparent;
    border-right: 30px solid transparent;
}

.elemento-pulsante.hexagono:before {
    bottom: 100%;
    border-bottom: 17.32px solid rgba(255,255,255,0.08);
}

.elemento-pulsante.hexagono:after {
    top: 100%;
    border-top: 17.32px solid rgba(255,255,255,0.08);
}

@keyframes pulsar {
    0%, 100% { 
        transform: scale(1) rotate(0deg);
        opacity: 0.3;
    }
    50% { 
        transform: scale(1.2) rotate(180deg);
        opacity: 0.8;
    }
}

@keyframes flotar {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

/* CONTENIDO DEL HERO CON ANIMACIONES MEJORADAS */
.contenido-hero {
    position: relative;
    z-index: 10;
    text-align: center;
    color: white;
    animation: flotarHero 6s ease-in-out infinite;
}

@keyframes flotarHero {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.titulo-hero {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: brilloTitulo 3s ease-in-out infinite alternate;
}

@keyframes brilloTitulo {
    0% { 
        filter: brightness(1);
        text-shadow: 0 0 20px rgba(255,255,255,0.3);
    }
    100% { 
        filter: brightness(1.2);
        text-shadow: 0 0 30px rgba(255,255,255,0.5);
    }
}

.subtitulo-hero {
    font-size: clamp(1.1rem, 2vw, 1.5rem);
    font-weight: 400;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    animation: desvaneceSubtitulo 4s ease-in-out infinite alternate;
}

@keyframes desvaneceSubtitulo {
    0% { opacity: 0.8; }
    100% { opacity: 1; }
}

.boton-hero {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    color: white;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    animation: pulsarBoton 5s ease-in-out infinite;
}

@keyframes pulsarBoton {
    0%, 100% { 
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.4);
    }
    50% { 
        box-shadow: 0 0 0 10px rgba(255, 255, 255, 0);
    }
}

.boton-hero:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px) scale(1.05);
    color: white;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

/* Sección de Servicios */
.seccion-servicios {
    padding: 8rem 0;
    background: var(--superficie);
    position: relative;
}

.encabezado-seccion {
    text-align: center;
    margin-bottom: 5rem;
}

.titulo-seccion {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--texto-primario);
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.subtitulo-seccion {
    font-size: 1.25rem;
    color: var(--texto-secundario);
    max-width: 600px;
    margin: 0 auto;
}

/* Tarjetas de Servicios Modernas */
.tarjeta-servicio {
    background: var(--superficie);
    border: 1px solid var(--borde);
    border-radius: 24px;
    padding: 3rem 2rem;
    height: 100%;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.tarjeta-servicio::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradiente-primario);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.tarjeta-servicio:hover {
    transform: translateY(-8px);
    box-shadow: var(--sombra-extra-grande);
    border-color: rgba(28, 75, 129, 0.2);
}

.tarjeta-servicio:hover::before {
    transform: scaleX(1);
}

.icono-servicio {
    width: 64px;
    height: 64px;
    background: var(--gradiente-primario);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    color: white;
}

.titulo-servicio {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--texto-primario);
    margin-bottom: 1rem;
    letter-spacing: -0.01em;
}

.descripcion-servicio {
    color: var(--texto-secundario);
    line-height: 1.7;
    margin-bottom: 2rem;
}

.boton-servicio {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primario);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.boton-servicio:hover {
    color: var(--primario-claro);
    gap: 0.75rem;
}

/* Pie de Página */
.pie-pagina {
    background: var(--texto-primario);
    color: white;
    padding: 3rem 0 2rem;
    text-align: center;
}

.contenido-pie {
    opacity: 0.8;
}

/* Diseño Responsivo */
@media (max-width: 768px) {
    .seccion-hero {
        height: 80vh;
        min-height: 500px;
    }
    
    .seccion-servicios {
        padding: 4rem 0;
    }
    
    .tarjeta-servicio {
        padding: 2rem 1.5rem;
        margin-bottom: 2rem;
    }
    
    .elemento-flotante,
    .circulo-flotante,
    .particula,
    .elemento-pulsante {
        display: none;
    }
}

/* Desplazamiento Suave */
html {
    scroll-behavior: smooth;
}

/* Barra de Desplazamiento Personalizada */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--superficie-alternativa);
}

::-webkit-scrollbar-thumb {
    background: var(--primario);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primario-oscuro);
}
