/* ==========================================================================
   CONFIGURACIÓN BASE
   ========================================================================== */
body {
    font-family: 'Inter', sans-serif;
    background: #0a0a0f; /* Color sólido de respaldo */
    color: #e2e8f0;
    overflow-x: hidden; /* Evita el scroll horizontal por animaciones de entrada */
}

/* ==========================================================================
   ARTECH DESIGN - SISTEMA DE FONDO (NAZARETH IDENTITY)
   Basado en la paleta: Cian, Azul Eléctrico, Violeta y Lima del Logo
   ========================================================================== */
.mesh-bg {
    /* Identificación de Colores Extraídos del Logo Nazareth:
       - Cian Energía: rgba(6, 182, 212, 0.15) 
       - Azul Profundo: rgba(29, 78, 216, 0.12)
       - Violeta Tech: rgba(126, 34, 206, 0.15)
       - Lima Conectividad: rgba(132, 204, 22, 0.08)
    */
    background: 
        radial-gradient(at 0% 0%, rgba(6, 182, 212, 0.18) 0px, transparent 50%),   /* Cian en esquina superior izq */
        radial-gradient(at 100% 0%, rgba(29, 78, 216, 0.15) 0px, transparent 50%),  /* Azul en esquina superior der */
        radial-gradient(at 100% 100%, rgba(126, 34, 206, 0.15) 0px, transparent 50%),/* Violeta en esquina inferior der */
        radial-gradient(at 0% 100%, rgba(132, 204, 22, 0.1) 0px, transparent 50%),  /* Lima en esquina inferior izq */
        #05070a; /* Fondo ultra oscuro neutro para dar contraste al logo blanco */
    
    background-size: 200% 200%; /* Aumentamos el tamaño para que el movimiento sea más fluido */
    animation: meshMove 15s ease-in-out infinite alternate;
}

/* Animación optimizada para que los colores "respiren" */
@keyframes meshMove {
    0% { background-position: 0% 0%, 100% 0%, 100% 100%, 0% 100%; }
    50% { background-position: 10% 90%, 90% 10%, 20% 80%, 80% 20%; }
    100% { background-position: 100% 100%, 0% 100%, 0% 0%, 100% 0%; }
}

/* Ajuste extra para el texto: Usamos el Cian del logo para el Glow */
.glow-text {
    text-shadow: 0 0 25px rgba(6, 182, 212, 0.4);
}

/* ==========================================================================
   EFECTOS DE CRISTAL (GLASSMORPHISM)
   ========================================================================== */
/* Cristal ligero para tarjetas o elementos secundarios */
.glass {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Cristal denso para navegación o modales (mayor opacidad y desenfoque) */
.glass-heavy {
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ==========================================================================
   ANIMACIONES DE REVELADO (SCROLL REVEAL)
   Responsivo: Estas animaciones ayudan a que el contenido fluya al bajar scroll
   ========================================================================== */
/* Entrada desde abajo */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

/* Entrada desde la izquierda */
.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

/* Entrada desde la derecha */
.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

/* Efecto de escala/zoom */
.reveal-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

/* Clase activa (activada por JS al entrar en el viewport) */
.reveal.active, .reveal-left.active, .reveal-right.active, .reveal-scale.active {
    opacity: 1;
    transform: translate(0) scale(1);
}

/* ==========================================================================
   INTERACCIÓN Y EFECTOS ESPECIALES
   ========================================================================== */
/* Botón magnético con transición suave */
.magnetic-btn {
    transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}

/* Texto con resplandor neón */
.glow-text {
    text-shadow: 0 0 20px rgba(99, 102, 241, 0.5);
}

/* Borde animado con gradiente rotativo */
.gradient-border {
    position: relative;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(236, 72, 153, 0.1));
    border-radius: 1rem;
}

.gradient-border::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 1rem;
    padding: 1px;
    background: linear-gradient(135deg, #6366f1, #ec4899, #06b6d4);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: borderRotate 4s linear infinite;
    opacity: 0.5;
}

@keyframes borderRotate {
    0% { background: linear-gradient(0deg, #6366f1, #ec4899, #06b6d4); }
    33% { background: linear-gradient(120deg, #6366f1, #ec4899, #06b6d4); }
    66% { background: linear-gradient(240deg, #6366f1, #ec4899, #06b6d4); }
    100% { background: linear-gradient(360deg, #6366f1, #ec4899, #06b6d4); }
}

/* Efecto de elevación en tarjetas al pasar el mouse */
.hover-card {
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}
.hover-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(99, 102, 241, 0.2);
}

/* ==========================================================================
   PERSONALIZACIÓN DE SCROLLBAR (EXPERIENCIA DE USUARIO)
   ========================================================================== */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #0a0a0f; }
::-webkit-scrollbar-thumb {
    background: rgba(99, 102, 241, 0.5);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(99, 102, 241, 0.8); }

/* ==========================================================================
   DELAYS PARA ANIMACIONES ESCALONADAS (STAGGER)
   ========================================================================== */
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
.stagger-5 { transition-delay: 0.5s; }
.stagger-6 { transition-delay: 0.6s; }

/* Tipografía tabular para contadores numéricos */
.counter { font-variant-numeric: tabular-nums; }