/* =========================================
   1. VARIABLES Y CONFIGURACIÓN GENERAL
   ========================================= */
:root {
    /* Paleta de Colores */
    --bg-dark: #050a18;       /* Azul muy oscuro (Casi negro) */
    --text-white: #ffffff;
    --text-gray: #a0a0a0;     /* Gris para textos secundarios */
    --card-bg: #ffffff;       /* Fondo blanco para tarjetas */
    --text-dark: #333333;     /* Texto oscuro para fondo blanco */
    
    /* Degradados de Marca (Estilo Fénix) */
    --gradient-brand: linear-gradient(90deg, #ff8a00, #e52e71, #00d2ff);
    --gradient-btn: linear-gradient(90deg, #00c6ff, #0072ff);
}

/* Reset básico para limpiar márgenes del navegador */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif; /* Fuente moderna */
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-white);
    overflow-x: hidden; /* Evita scroll horizontal indeseado */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* =========================================
   2. BARRA DE NAVEGACIÓN (NAVBAR)
   ========================================= */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 50px;
    position: fixed; /* Fija para que acompañe el scroll (opcional) o absolute */
    width: 100%;
    top: 0;
    z-index: 1000;
    transition: background 0.3s ease;
}

/* --- LOGO RESPONSIVO --- */
.logo {
    display: flex;
    flex-direction: column; /* Apila imagen y subtítulo */
    align-items: flex-start;
    text-decoration: none;
    cursor: pointer;
    max-width: 250px; /* Límite de seguridad para el contenedor */
}

.logo img {
    height: auto;
    width: auto;
    
    /* AQUÍ ESTÁ EL TRUCO DEL TAMAÑO: */
    max-height: 20px;  /* Altura máxima en PC (ajusta este número si lo quieres más grande/chico) */
    max-width: 100px;
    
    object-fit: contain;
    display: block;
    margin-bottom: 2px;
}

.logo-sub {
    font-size: 0.6rem;
    color: var(--text-gray);
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 500;
}

/* Enlaces del menú */
.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-gray);
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--text-white);
}

/* Botón especial del menú */
.btn-nav {
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 8px 25px;
    border-radius: 50px;
    transition: all 0.3s ease;
}

.btn-nav:hover {
    border-color: #00d2ff;
    color: #00d2ff !important;
    background: rgba(0, 210, 255, 0.1);
}

/* Menú hamburguesa (oculto en escritorio) */
.menu-toggle {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: var(--text-white);
    transition: all 0.3s ease;
}

/* =========================================
   3. SECCIÓN HERO (PORTADA)
   ========================================= */
.hero {
    min-height: 100vh; /* Ocupa toda la altura de la pantalla */
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px; /* Espacio para que el navbar no tape el texto */
    
    /* Fondo con degradado radial sutil */
    background: radial-gradient(circle at 80% 20%, #1a2542 0%, var(--bg-dark) 70%);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Dos columnas iguales */
    align-items: center;
    gap: 40px;
    width: 100%;
}

.hero-text h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 25px;
    font-weight: 700;
}

/* Texto con degradado (Inteligencia Artificial) */
.text-gradient {
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-text p {
    color: var(--text-gray);
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 40px;
    max-width: 90%;
}

/* Botón principal CTA */
.btn-gradient {
    display: inline-block;
    padding: 15px 40px;
    border-radius: 50px;
    background: var(--gradient-brand);
    color: white;
    text-decoration: none;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(229, 46, 113, 0.4); /* Sombra brillante */
    transition: transform 0.3s, box-shadow 0.3s;
}

.btn-gradient:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(229, 46, 113, 0.6);
}

/* Imagen del Fénix flotante */
.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.floating-img {
    width: 100%;
    max-width: 550px;
    animation: float 6s ease-in-out infinite;
    filter: drop-shadow(0 0 20px rgba(0, 210, 255, 0.2));
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}

/* Efecto de luz de fondo (opcional) */
.glow-effect {
    position: absolute;
    width: 400px;
    height: 400px;
    background: rgba(229, 46, 113, 0.15);
    filter: blur(100px);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
}

/* =========================================
   4. SECCIÓN SERVICIOS
   ========================================= */
.services-section {
    background-color: var(--card-bg); /* Fondo blanco */
    padding: 100px 0;
    color: var(--text-dark);
    position: relative;
    z-index: 2; /* Para asegurar que esté sobre elementos flotantes */
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    text-align: center;
}

.service-card {
    padding: 30px 20px;
    background: #fff;
    border-radius: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.icon-box {
    font-size: 3.5rem;
    margin-bottom: 25px;
    display: inline-block;
}

/* Colores degradados para los iconos */
.gradient-1 i { 
    background: -webkit-linear-gradient(#ff8a00, #e52e71); 
    -webkit-background-clip: text; 
    -webkit-text-fill-color: transparent; 
}
.gradient-2 i { 
    background: -webkit-linear-gradient(#e52e71, #9d50bb); 
    -webkit-background-clip: text; 
    -webkit-text-fill-color: transparent; 
}
.gradient-3 i { 
    background: -webkit-linear-gradient(#9d50bb, #00d2ff); 
    -webkit-background-clip: text; 
    -webkit-text-fill-color: transparent; 
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #e52e71;
    font-weight: 700;
}

.service-card p {
    color: #666;
    line-height: 1.6;
    font-size: 0.95rem;
}

/* =========================================
   5. FOOTER
   ========================================= */
.dark-footer {
    background-color: var(--bg-dark);
    padding: 60px 0 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 40px;
    gap: 20px;
}

.footer-brand h4 {
    font-size: 1.5rem;
    color: var(--text-white);
    letter-spacing: 1px;
}

.footer-links {
    list-style: none;
    display: flex;
    gap: 25px;
}

.footer-links a {
    color: var(--text-gray);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: #00d2ff;
}

.copyright {
    text-align: center;
    font-size: 0.8rem;
    color: #555;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 20px;
}

/* =========================================
   6. MEDIA QUERIES (RESPONSIVE / CELULARES)
   ========================================= */
@media (max-width: 900px) {
    .navbar {
        padding: 15px 30px;
    }
    
    .hero-text h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    /* Navbar en móvil */
    .navbar {
        padding: 15px 20px;
        background: rgba(5, 10, 24, 0.95); /* Fondo oscuro en móvil */
    }

    /* Logo más pequeño en móvil */
    .logo img {
        max-height: 35px; /* Reducción de tamaño para pantallas pequeñas */
    }
    .logo-sub {
        font-size: 0.5rem;
    }

    /* Menú móvil (ocultamos los links por ahora, necesitarías JS para abrirlo) */
    .nav-links {
        display: none; 
    }
    .menu-toggle {
        display: block; /* Muestra el icono hamburguesa */
    }

    /* Hero en columna */
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 30px;
    }

    .hero {
        padding-top: 100px;
        min-height: auto;
        padding-bottom: 50px;
    }

    .hero-text p {
        margin: 0 auto 30px auto; /* Centrar párrafo */
    }

    .hero-image {
        margin-top: 20px;
    }

    .floating-img {
        max-width: 80%; /* Imagen más pequeña en móvil */
    }

    /* Footer en columna */
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 15px;
    }
}

/* Este código es para que el menú aparezca al activarse */
@media (max-width: 768px) {
    .nav-links.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 70px; /* Debajo del navbar */
        left: 0;
        width: 100%;
        background-color: var(--bg-dark);
        padding: 20px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        animation: slideDown 0.3s ease forwards;
    }

    @keyframes slideDown {
        from { opacity: 0; transform: translateY(-10px); }
        to { opacity: 1; transform: translateY(0); }
    }
}