/* Smooth scrolling para todos los enlaces ancla */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px; /* Offset para compensar el navbar fijo */
}

/* Fondo azul para toda la página */
body {
    background: linear-gradient(135deg, #000428, #013a6b, #090c0e) !important;
}

/* Estilos para la barra de navegación */
.nav-bar {
    background: rgb(4 10 17 / 50%) !important;
    backdrop-filter: blur(8px);
    box-shadow: 0 16px 32px 0 rgba(0, 10, 40, 0.28) !important;
    border-bottom: none !important;
    transition: background 0.4s ease, box-shadow 0.4s ease !important;
}

.nav-bar.solid-dark {
    background: linear-gradient(135deg, rgba(0, 4, 40, 0.92), rgba(1, 58, 107, 0.92), rgba(9, 12, 14, 0.92)) !important;
    backdrop-filter: blur(12px) !important;
}

.nav-inner {
    transition: padding 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Estilo para el logo Nexserver */
.logo-nexserver {
    font-family: 'Segoe UI', 'Inter', Arial, sans-serif !important;
    font-size: 1.8rem !important;
    /* Tamaño normal (scrolled) */
    font-weight: normal !important;
    letter-spacing: 1px !important;
    color: #9d9d9d !important;
    transition: font-size 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.logo-img {
    transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Efecto de expansión cuando está en el top (solo desktop) */
@media (min-width: 1024px) {
    .nav-bar:not(.scrolled) .nav-inner {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }

    .nav-bar:not(.scrolled) .logo-nexserver {
        font-size: 2.8rem !important;
    }

    .nav-bar:not(.scrolled) .logo-img {
        height: 6rem !important;
    }
}

/* Enlaces de navegación visibles sobre fondo oscuro */
.nav-bar nav a {
    color: #e5e7eb !important;
}

.nav-bar nav a.active {
    color: #379bea !important;
}

.nav-bar nav a:hover {
    color: #379bea !important;
}

/* Enlaces del menú desplegable con color oscuro */
.nav-bar .nav-dropdown-menu a {
    color: #3281ed !important;
}

.nav-bar .nav-dropdown-menu a:hover {
    color: #379bea !important;
}

.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Navigation Dropdown Menus */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 0.5rem;
    min-width: 220px;
    background: white;
    border: 1px solid #f0f2f4;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 100;
}

.dark .nav-dropdown-menu {
    background: #1a2430;
    border-color: #2a3441;
}

.nav-dropdown:hover .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-dropdown-menu a {
    display: block;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    color: #617289;
    transition: all 0.2s ease;
    border-radius: 0.25rem;
}

.dark .nav-dropdown-menu a {
    color: #9ca3af;
}

.nav-dropdown-menu a:hover {
    background: #f6f7f8;
    color: #136dec;
    padding-left: 1.25rem;
}

.dark .nav-dropdown-menu a:hover {
    background: #2a3441;
    color: #136dec;
}

.nav-dropdown-menu a.active-dropdown {
    color: #136dec !important;
    font-weight: bold;
    background: #f6f7f8;
}

.dark .nav-dropdown-menu a.active-dropdown {
    background: #2a3441;
}

footer .active-dropdown {
    color: #136dec !important;
    font-weight: bold;
}

.nav-dropdown-menu a:first-child {
    margin-top: 0.25rem;
}

.nav-dropdown-menu a:last-child {
    margin-bottom: 0.25rem;
}

/* Mobile Menu */
.mobile-menu {
    background: rgb(18 53 93 / 95%);
    backdrop-filter: blur(8px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    animation: slideDown 0.3s ease-out;
}

.mobile-menu nav a {
    color: #e5e7eb !important;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile dropdown - always visible */
@media (max-width: 1023px) {
    .nav-dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        margin-top: 0.5rem;
        margin-left: 1rem;
        box-shadow: none;
        border: none;
        background: transparent;
    }

    .dark .nav-dropdown-menu {
        background: transparent;
    }

    .nav-dropdown-menu a {
        padding: 0.5rem 0;
        font-size: 0.8125rem;
        color: #3281ed !important;
    }

    .nav-dropdown-menu a:hover {
        background: transparent;
        padding-left: 0.5rem;
        color: #379bea !important;
    }
}

/* Botón scroll to top */
.boton-scroll-top {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.boton-scroll-top.visible {
    opacity: 1 !important;
    pointer-events: auto !important;
}

.boton-scroll-top:hover {
    transform: translateY(-4px);
}