/* ==========================================================================
   1. FUENTES Y VARIABLES (CONFIGURACIÓN GLOBAL)
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700;800&display=swap');

:root {
    /* Paleta de Colores */
    --bg-dark: #020610;
    --bg-card: #0d1117;
    --bg-card-hover: #151b24;
    --primary: #00D2FF;
    --primary-alt: #0072FF;
    --primary-glow: rgba(0, 210, 255, 0.35);
    --text-main: #FFFFFF;
    --text-dim: #94A3B8;
    --discord-color: #5865F2;
    
    /* Efectos y Animaciones */
    --transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    --glass: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   2. RESETS Y ESTILOS BASE
   ========================================================================== */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    outline: none; 
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Fondo Inmersivo Nexora Style */
.bg-mesh {
    position: fixed;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    z-index: -1;
    background: 
        linear-gradient(rgba(2, 6, 16, 0.88), rgba(2, 6, 16, 0.96)),
        url('https://images.unsplash.com/photo-1542751371-adc38448a05e?auto=format&fit=crop&q=80&w=2000');
    background-size: cover;
    background-position: center;
}

.container { 
    max-width: 1400px; 
    margin: 0 auto; 
    padding: 0 4rem; 
}

/* Helper para Bootstrap o espaciados manuales */
.pt-5 { padding-top: 3rem !important; }
.mb-5 { margin-bottom: 3rem !important; }
.text-center { text-align: center !important; }
.position-relative { position: relative !important; }

/* ==========================================================================
   3. COMPONENTES REUTILIZABLES (BOTONES, BADGES, REVEALS)
   ========================================================================== */
.btn-main {
    background: linear-gradient(90deg, var(--primary), var(--primary-alt)); 
    color: #000; 
    padding: 1.2rem 3rem; 
    border-radius: 12px;
    font-weight: 800; 
    text-decoration: none; 
    text-transform: uppercase; 
    transition: var(--transition);
    box-shadow: 0 4px 20px var(--primary-glow);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-main:hover { 
    transform: translateY(-3px); 
    filter: brightness(1.1); 
    box-shadow: 0 8px 25px var(--primary-glow);
}

.btn-outline {
    background: rgba(255, 255, 255, 0.02); 
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff; 
    padding: 1.2rem 3rem; 
    border-radius: 12px; 
    font-weight: 700;
    text-decoration: none; 
    text-transform: uppercase; 
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-outline:hover { 
    background: rgba(255, 255, 255, 0.08); 
    border-color: #fff; 
    transform: translateY(-3px);
}

.game-badge { 
    background: rgba(0, 210, 255, 0.1); 
    color: var(--primary); 
    padding: 0.5rem 1.2rem; 
    border-radius: 50px; 
    font-size: 0.75rem; 
    font-weight: 800; 
    text-transform: uppercase; 
    margin-bottom: 1.5rem; 
    display: inline-block; 
    border: 1px solid rgba(0, 210, 255, 0.2); 
}

/* Animaciones de Entrada (Scroll) */
.reveal { 
    opacity: 0; 
    transform: translateY(30px); 
    transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1); 
}

.reveal.active { 
    opacity: 1; 
    transform: translateY(0); 
}

/* ==========================================================================
   4. NAVEGACIÓN (NAVBAR)
   ========================================================================== */
nav {
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    padding: 2rem 0; 
    position: sticky; 
    top: 0; 
    z-index: 1000; 
    transition: var(--transition);
}

nav.scrolled {
    background: rgba(2, 6, 16, 0.85); 
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 1.2rem 0; 
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo-wrapper img { 
    height: 40px; 
    filter: drop-shadow(0 0 10px var(--primary-glow)); 
}

.nav-links { 
    display: flex; 
    gap: 2.5rem; 
    align-items: center; 
}

.nav-links a { 
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: #fff; 
    text-decoration: none; 
    font-weight: 600; 
    font-size: 0.9rem; 
    opacity: 0.6; 
    transition: var(--transition); 
}

/* Alineación y tamaño de íconos SVG (Lucide Icons) */
.nav-links a svg,
.nav-links .user-profile svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    stroke-width: 2;
    transition: var(--transition);
}

.nav-links a:hover, 
.nav-links a.active { 
    opacity: 1; 
    color: var(--primary); 
}

.nav-links a:hover svg,
.nav-links a.active svg {
    stroke: var(--primary);
}

/* ==========================================================================
   5. SECCIÓN HERO (VISTA DE ENTRADA)
   ========================================================================== */
.hero {
    min-height: calc(100vh - 100px);
    display: grid; 
    grid-template-columns: 1.2fr 0.8fr;
    align-items: center; 
    gap: 4rem; 
    padding: 4rem 0;
}

.hero-content h1 { 
    font-size: 5.5rem; 
    font-weight: 800; 
    line-height: 1.1; 
    margin-bottom: 2rem; 
    letter-spacing: -2px; 
}

.hero-content h1 span { 
    color: var(--primary); 
    text-shadow: 0 0 30px var(--primary-glow); 
}

.hero-content p { 
    font-size: 1.2rem; 
    color: var(--text-dim); 
    margin-bottom: 3rem; 
    max-width: 580px; 
}

.hero-btns { 
    display: flex; 
    gap: 1.5rem; 
    margin-bottom: 4rem; 
}

/* Grid de Estadísticas Optimizado y Ajustado de Tamaño */
.stats-grid { 
    display: flex; 
    gap: 3.5rem; 
    flex-wrap: wrap;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 2.5rem;
}
.stats-grid .stat-box h3 { 
    font-size: 1.1rem !important; 
    font-weight: 800 !important; 
    color: var(--primary) !important; 
    line-height: 1.1 !important; 
    text-shadow: 0 0 12px var(--primary-glow) !important; 
    margin-bottom: 0.6rem !important;
    letter-spacing: -0.5px !important;
}

.stat-box span { 
    color: var(--text-dim); 
    font-size: 0.78rem; 
    font-weight: 700; 
    text-transform: uppercase; 
    letter-spacing: 1.5px;
    display: block;
}

/* Elemento Visual Flotante */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

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

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

/* ==========================================================================
   6. SECCIÓN INFRAESTRUCTURA (SOLUCIONES / TARJETAS)
   ========================================================================== */
.section-header { 
    text-align: center; 
    margin-bottom: 4rem;
}

.section-header h2 { 
    font-size: 3.5rem; 
    font-weight: 800; 
    margin-bottom: 1rem; 
}

.section-header h2 span { 
    color: var(--primary); 
}

.section-header p {
    color: var(--text-dim);
    font-size: 1.1rem;
}

.game-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); 
    gap: 1.5rem; 
}

.game-card {
    background: var(--bg-card); 
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px; 
    padding: 2.5rem 2rem; 
    transition: var(--transition);
    display: flex; 
    flex-direction: column; 
    align-items: flex-start; 
    gap: 1rem;
}

.game-card:hover { 
    border-color: var(--primary); 
    background: var(--bg-card-hover);
    box-shadow: 0 10px 30px rgba(0, 210, 255, 0.08); 
    transform: translateY(-5px); 
}

.game-icon-circle {
    width: 60px; 
    height: 60px; 
    background: #161B22; 
    border-radius: 14px;
    display: flex; 
    justify-content: center; 
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.05); 
    margin-bottom: 0.5rem;
}

.game-icon-circle i {
    transition: var(--transition);
}

.game-card:hover .game-icon-circle i { 
    color: var(--primary);
    filter: drop-shadow(0 0 8px var(--primary-glow)); 
    transform: scale(1.1);
}

.game-card h3 { 
    font-size: 1.3rem; 
    font-weight: 800; 
    color: #fff; 
}

.game-card p { 
    color: var(--text-dim); 
    font-size: 0.9rem; 
    line-height: 1.6; 
    opacity: 0.8; 
}

/* ==========================================================================
   7. SECCIÓN PRECIOS (PRICING PLANES)
   ========================================================================== */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
    margin-top: 4rem;
}

.service-card {
    background: rgba(10, 15, 25, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 3.5rem 2.5rem;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
    background: rgba(15, 20, 35, 0.85);
    box-shadow: 0 20px 40px rgba(0, 210, 255, 0.12);
}

.service-card.popular {
    border: 2px solid var(--primary);
    background: rgba(0, 210, 255, 0.03);
    box-shadow: 0 15px 35px rgba(0, 210, 255, 0.1);
}

.plan-badge {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 900;
    letter-spacing: 1.5px;
    margin-bottom: 2rem;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.service-card.popular .plan-badge {
    background: var(--primary);
    color: #000;
    font-weight: 800;
}

.service-card .price {
    font-size: 4.5rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.2rem;
    letter-spacing: -2px;
}

.service-card .price small {
    font-size: 1.1rem;
    color: var(--text-dim);
    font-weight: 600;
    letter-spacing: 0;
}

.service-card .features-list {
    list-style: none;
    width: 100%;
    margin: 2rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 2rem;
}

.service-card .features-list li {
    margin-bottom: 1.2rem;
    color: var(--text-dim);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    text-align: left;
}

.service-card:hover .features-list li {
    color: #fff;
}

.service-card .features-list li i {
    color: var(--primary);
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

.service-card .btn-main,
.service-card .btn-outline {
    width: 100%;
    margin-top: auto;
}

/* ==========================================================================
   8. ACCORDEÓN FAQ
   ========================================================================== */
.faq-grid { 
    max-width: 850px; 
    margin: 0 auto; 
    display: flex; 
    flex-direction: column; 
    gap: 1rem; 
}

.faq-card { 
    background: rgba(255, 255, 255, 0.01); 
    border: 1px solid rgba(255, 255, 255, 0.05); 
    border-radius: 14px; 
    overflow: hidden; 
    transition: var(--transition); 
}

.faq-header { 
    padding: 1.5rem 2rem; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    cursor: pointer; 
}

.faq-header h4 { 
    font-size: 1.1rem; 
    font-weight: 600; 
}

.faq-header i { 
    color: var(--primary); 
    transition: var(--transition); 
}

.faq-content { 
    max-height: 0; 
    overflow: hidden; 
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1); 
}

.faq-card.active { 
    border-color: var(--primary); 
    background: rgba(0, 210, 255, 0.02); 
}

.faq-card.active .faq-content { 
    max-height: 300px; 
}

.faq-card.active .faq-header i { 
    transform: rotate(180deg); 
}

.faq-body { 
    padding: 0 2rem 1.5rem 2rem; 
    color: var(--text-dim); 
    font-size: 0.95rem; 
    line-height: 1.6;
}

/* ==========================================================================
   9. PERFIL DE USUARIO DROPDOWN (MENÚ DESPLEGABLE DE SESIÓN)
   ========================================================================== */
.user-dropdown-container {
    position: relative;
    display: inline-block;
    z-index: 1100;
}

.user-profile {
    display: flex; 
    align-items: center; 
    background: rgba(255, 255, 255, 0.04); 
    padding: 0.5rem 1.2rem; 
    border-radius: 50px; 
    border: 1px solid rgba(255, 255, 255, 0.08); 
    cursor: pointer; 
    transition: var(--transition); 
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.user-profile:hover {
    background: rgba(255, 255, 255, 0.08); 
    border-color: var(--primary);
}

.user-profile img {
    width: 32px; 
    height: 32px; 
    border-radius: 50%; 
    border: 2px solid var(--primary);
}

.user-profile span {
    font-weight: 700; 
    font-size: 0.9rem; 
    margin: 0 0.8rem; 
    color: white;
}

.user-profile i.fa-chevron-down {
    font-size: 0.7rem; 
    color: var(--text-dim);
}

.dropdown-menu {
    position: absolute; 
    top: calc(100% + 12px); 
    right: 0; 
    width: 260px; 
    background: #0D1117; 
    border: 1px solid rgba(255, 255, 255, 0.08); 
    border-radius: 18px; 
    padding: 1.5rem 1rem 1rem 1rem; 
    display: none; 
    z-index: 1200; 
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}

.user-dropdown-container.active .dropdown-menu {
    display: block;
    animation: dropdownFade 0.3s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

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

.dropdown-header {
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    margin-bottom: 1.2rem;
}

.dropdown-header img {
    width: 70px; 
    height: 70px; 
    border-radius: 50%; 
    border: 2px solid var(--primary); 
    margin-bottom: 0.8rem; 
    object-fit: cover;
}

.dropdown-header h4 {
    color: white; 
    font-size: 1.1rem; 
    font-weight: 800; 
}

.dropdown-item {
    display: flex; 
    align-items: center; 
    padding: 0.8rem 1rem; 
    color: #e2e8f0; 
    text-decoration: none; 
    border-radius: 10px; 
    transition: var(--transition); 
    font-weight: 600; 
    font-size: 0.9rem; 
    gap: 1rem;
}

.dropdown-item i {
    font-size: 1.1rem; 
    color: #94a3b8; 
    width: 20px; 
    text-align: center;
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.05); 
    color: white;
}

.dropdown-divider {
    height: 1px; 
    background: rgba(255, 255, 255, 0.08); 
    margin: 0.5rem 0;
}

.logout-item { color: #ff4b4b; }
.logout-item i { color: #ff4b4b; }
.logout-item:hover { background: rgba(255, 75, 75, 0.1); }

/* ==========================================================================
   10. SECCIÓN EXCLUSIVA: MAPA MUNDIAL GLOBAL DE BAJA LATENCIA (FORZADO)
   ========================================================================== */
.map {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: block;
}

/* Contenedor propio e inmune a errores de colapso */
.map-container-rel {
    position: relative !important;
    display: block !important;
    width: 100% !important;
    height: auto !important;
}

/* Forzar que el SVG o IMG de adentro ocupe el espacio correcto */
.map-container-rel img,
.map-container-rel svg,
.map-container-rel div:first-child {
    width: 100% !important;
    height: auto !important;
    display: block !important;
}

/* Cajas flotantes oscuras */
.map_box {
    position: absolute !important;
    background-color: #111424 !important;
    color: #ffffff !important;
    padding: 6px 12px !important;
    font-size: 12px !important;
    font-weight: 600;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.7);
    white-space: nowrap !important;
    z-index: 999 !important; /* Asegura que queden por encima del mapa */
}

/* Coordenadas relativas exactas sobre los puntos del mapa */
.map-container-rel .usamfl {
    left: 24.5% !important;
    top: 47% !important;
}

.map-container-rel .usanyc {
    left: 26% !important;
    top: 36% !important;
}

/* Colores dinámicos del ping */
.ping-good { color: #00ff88 !important; } 
.ping-ok   { color: #ffcc00 !important; } 
.ping-bad  { color: #ff4d4d !important; }
/* ==========================================================================
   11. PIE DE PÁGINA (ULTRA FOOTER)
   ========================================================================== */
.ultra-footer { 
    padding: 6rem 0 3rem 0; 
    background: #01040A; 
    border-top: 1px solid rgba(255, 255, 255, 0.05); 
    margin-top: 8rem;
}

.footer-main-grid { 
    display: grid; 
    grid-template-columns: 1.3fr 0.9fr 0.9fr 1.1fr; 
    gap: 4rem; 
    margin-bottom: 4rem; 
}

.footer-about img { 
    height: 40px; 
    margin-bottom: 1.5rem; 
}

.footer-about p {
    color: var(--text-dim);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.footer-socials { 
    display: flex; 
    gap: 0.8rem; 
}

.footer-socials a { 
    width: 40px; 
    height: 40px; 
    background: rgba(255, 255, 255, 0.02); 
    border: 1px solid rgba(255, 255, 255, 0.05); 
    border-radius: 10px; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    color: #fff; 
    transition: var(--transition); 
}

.footer-socials a:hover { 
    background: var(--primary); 
    color: #000; 
    transform: translateY(-3px);
}

.footer-col h4 { 
    font-size: 0.9rem; 
    font-weight: 800; 
    margin-bottom: 1.5rem; 
    text-transform: uppercase; 
    color: #fff; 
    letter-spacing: 1px;
}

.footer-col ul { 
    list-style: none; 
}

.footer-col ul li { 
    margin-bottom: 0.8rem; 
}

.footer-col ul li a { 
    color: var(--text-dim); 
    text-decoration: none; 
    font-size: 0.9rem; 
    transition: var(--transition); 
}

.footer-col ul li a:hover { 
    color: var(--primary); 
    padding-left: 6px; 
}

.footer-form { 
    display: flex; 
    flex-direction: column; 
    gap: 0.8rem; 
}

.footer-form input { 
    background: rgba(255, 255, 255, 0.02); 
    border: 1px solid rgba(255, 255, 255, 0.06); 
    padding: 1rem 1.2rem; 
    border-radius: 10px; 
    color: #fff; 
    transition: var(--transition);
}

.footer-form input:focus {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.04);
}

.footer-form button { 
    background: var(--primary); 
    color: #000; 
    border: none; 
    padding: 1rem; 
    border-radius: 10px; 
    font-weight: 800; 
    cursor: pointer; 
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
}

.footer-form button:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

.footer-legal-bar { 
    padding-top: 2rem; 
    border-top: 1px solid rgba(255, 255, 255, 0.04); 
    display: flex; 
    justify-content: space-between; 
    font-size: 0.8rem; 
    color: var(--text-dim); 
    align-items: center; 
}

/* ==========================================================================
   12. MEDIA QUERIES (DISEÑO RESPONSIVO)
   ========================================================================== */
@media (max-width: 1200px) {
    .container { padding: 0 2.5rem; }
    .hero-content h1 { font-size: 4.5rem; }
    .footer-main-grid { grid-template-columns: 1fr 1fr; gap: 3rem; }
}

@media (max-width: 992px) {
    .hero { 
        grid-template-columns: 1fr; 
        text-align: center; 
        padding: 2rem 0 5rem 0;
        gap: 2rem;
    }
    .hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .hero-content p { max-width: 100%; }
    .hero-btns { justify-content: center; }
    .stats-grid { justify-content: center; gap: 3rem; }
    .hero-visual { display: none; }
    .section-header h2 { font-size: 2.8rem; }
}

@media (max-width: 768px) {
    .container { padding: 0 1.5rem; }
    nav { padding: 1.5rem 0; }
    .nav-links { display: none; }
    .hero-content h1 { font-size: 3.5rem; }
    .stats-grid { gap: 2rem; flex-direction: column; align-items: center; }
    .footer-main-grid { grid-template-columns: 1fr; gap: 2.5rem; }
    .footer-legal-bar { flex-direction: column; gap: 1rem; text-align: center; }
    
    /* Adaptabilidad de las cajas del mapa en móviles */
    .map_box {
        padding: 4px 8px !important;
        font-size: 11px !important;
    }
}