/* 1. FUENTES */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;500;700;900&family=Rajdhani:wght@300;400;500;600;700&display=swap');

/* 2. ESTILOS GLOBALES */
body {
    background-color: #050505;
    color: #e0e0e0;
    font-family: 'Rajdhani', sans-serif;
    scroll-behavior: smooth;
}

/* FONDO CYBER GRID */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(rgba(0, 240, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 240, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: -1;
    pointer-events: none;
}

/* Efecto Viñeta */
body::after {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 60%, #050505 100%);
    z-index: -1;
    pointer-events: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 0.05em;
}

::selection {
    background: #FF00FF;
    color: #000;
}

/* 3. EFECTOS NEÓN y HUD */
.tech-neon-glow {
    text-shadow: 0 0 5px #00F0FF, 0 0 15px #00F0FF;
    color: #00F0FF;
}

.tech-neon-pink {
    text-shadow: 0 0 5px #FF00FF, 0 0 15px #FF00FF;
    color: #FF00FF;
}

.btn-neon {
    position: relative;
    background: rgba(0, 240, 255, 0.1);
    color: #00F0FF;
    border: 1px solid #00F0FF;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 24px;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
    transition: all 0.3s ease;
}

.btn-neon:hover {
    background: #00F0FF;
    color: #000;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.8);
    text-shadow: none;
}

.card-elegant-glow {
    background: rgba(10, 10, 10, 0.8);
    border: 1px solid rgba(0, 240, 255, 0.2);
    position: relative;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    overflow: hidden;
}

/* HUD Corners */
.card-elegant-glow::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 20px;
    height: 20px;
    border-top: 2px solid #00F0FF;
    border-left: 2px solid #00F0FF;
    transition: all 0.3s ease;
    pointer-events: none;
    /* FIX: Evitar bloquear clicks */
}

.card-elegant-glow::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 20px;
    height: 20px;
    border-bottom: 2px solid #00F0FF;
    border-right: 2px solid #00F0FF;
    transition: all 0.3s ease;
    pointer-events: none;
    /* FIX: Evitar bloquear clicks */
}

.card-elegant-glow:hover {
    border-color: #FF00FF;
    box-shadow: 0 0 30px rgba(255, 0, 255, 0.15);
    transform: translateY(-5px);
}

.card-elegant-glow:hover::before,
.card-elegant-glow:hover::after {
    border-color: #FF00FF;
    width: 100%;
    height: 100%;
    opacity: 0.1;
    /* Llenado sutil */
}

/* 4. ESTILOS ESPECÍFICOS DE NAVEGACIÓN (Dropdowns) */
.dropdown {
    position: relative;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 300px;
    background-color: rgba(5, 5, 5, 0.95);
    border: 1px solid #00F0FF;
    padding: 10px 0;
    z-index: 50;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%);
}

.dropdown:hover .dropdown-menu {
    display: block;
    animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-menu a {
    display: block;
    padding: 12px 24px;
    color: #b4b4b4;
    text-decoration: none;
    transition: all 0.2s;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 500;
    border-left: 2px solid transparent;
}

.dropdown-menu a:hover {
    background-color: rgba(0, 240, 255, 0.1);
    color: #00F0FF;
    padding-left: 30px;
    border-left: 2px solid #00F0FF;
    text-shadow: 0 0 8px rgba(0, 240, 255, 0.5);
}

/* Indicador de Dropdown */
.dropdown-link::after {
    content: '+';
    font-size: 0.9em;
    margin-left: 8px;
    color: #FF00FF;
    font-weight: bold;
}

/* 5. SCROLLBAR PERSONALIZADO */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #050505;
}

::-webkit-scrollbar-thumb {
    background: #00F0FF;
    border: 1px solid #00F0FF;
}

::-webkit-scrollbar-thumb:hover {
    background: #FF00FF;
    border-color: #FF00FF;
}

/* 6. MENÚ MÓVIL (Asegurar que solo se vean en móvil) */
#menu-button {
    display: none;
}

@media (max-width: 1023px) {
    #menu-button {
        display: block;
    }

    #desktop-menu {
        display: none;
    }

    .mobile-sub-menu {
        display: none;
        padding-left: 20px;
        margin-top: 5px;
        border-left: 1px solid #00F0FF;
    }

    .mobile-sub-menu a {
        padding: 10px 0;
        display: block;
        color: #b4b4b4;
        font-family: 'Rajdhani', sans-serif;
    }

    .mobile-dropdown-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        cursor: pointer;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        padding-bottom: 5px;
    }

    .mobile-dropdown-header i {
        transition: transform 0.3s;
        color: #FF00FF;
    }

    .mobile-dropdown-header.active i {
        transform: rotate(180deg);
    }
}

/* 7. ESTILOS DEL WIDGET DE CHAT (RENOVADO) */
.chat-message {
    padding: 0.75rem;
    /* p-3 */
    margin-bottom: 0.5rem;
    /* mb-2 */
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    /* shadow-md */
    position: relative;
    display: flex;
    flex-direction: column;
    border-radius: 4px;
    font-family: 'Rajdhani', sans-serif;
}

.chat-avatar {
    width: 2rem;
    /* w-8 */
    height: 2rem;
    /* h-8 */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    /* text-lg */
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #00F0FF;
    color: #00F0FF;
    clip-path: polygon(20% 0, 100% 0, 100% 80%, 80% 100%, 0 100%, 0 20%);
}

.chat-label {
    font-size: 0.75rem;
    /* text-xs */
    font-weight: 700;
    /* font-bold */
    margin-bottom: 0.25rem;
    /* mb-1 */
    letter-spacing: 0.05em;
    /* tracking-wider */
    text-transform: uppercase;
}

.chat-timestamp {
    font-size: 0.75rem;
    /* text-xs */
    opacity: 0.6;
    margin-top: 0.25rem;
    /* mt-1 */
    text-align: right;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    /* font-mono */
}

.chat-message-user {
    background: rgba(0, 240, 255, 0.1);
    border: 1px solid #00F0FF;
    color: #00F0FF;
    margin-left: auto;
}

.chat-message-bot {
    background: rgba(255, 0, 255, 0.1);
    border: 1px solid #FF00FF;
    color: #FF00FF;
}

.message-container {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
    /* mb-4 */
    column-gap: 0.75rem;
    /* gap-x-3 */
}

.justify-end {
    justify-content: flex-end;
}

.chat-message-thinking {
    color: #b4b4b4;
    /* text-tech-gray */
    font-style: italic;
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    background: transparent;
    border: 1px dashed #555;
}

#chat-message-list::-webkit-scrollbar {
    width: 4px;
}

/* Animación para el botón flotante */
.animate-float {
    animation: float 4s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}