/* ====================================
   NAVIGATION BAR
   ==================================== */

.nav {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    border-bottom: 1px solid var(--border);
    background: rgba(9, 9, 11, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10;
}

.brand {
    font-weight: 800;
    font-size: 1.2rem;
    background: linear-gradient(to right, #ffffff, #71717a);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 800;
    font-size: 1.2rem;
    color: white;
    letter-spacing: -0.02em;
}

.logo-icon {
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
    background: rgba(255,255,255,0.1);
    padding: 4px 8px;
    border-radius: 4px;
}

.controls {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* ====================================
   SHARED NAVBAR COMPONENT
   ==================================== */

.navbar {
    position: sticky;
    top: 0;
    flex-shrink: 0;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    border-bottom: 1px solid var(--border);
    background: rgba(9, 9, 11, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 800;
    font-size: 1.2rem;
    color: white;
    letter-spacing: -0.02em;
    text-decoration: none;
}

.navbar-brand:hover {
    color: white;
    opacity: 0.9;
}

.navbar-logo {
    height: 32px;
    width: auto;
    display: block;
}

.navbar-text {
    margin-left: 4px;
}

.navbar-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* Hamburger Menu Button */
.hamburger-menu {
    display: none;
    background: transparent;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.2s;
    align-items: center;
    justify-content: center;
}

.hamburger-menu:hover {
    background: rgba(255, 255, 255, 0.1);
}

.hamburger-menu svg {
    width: 24px;
    height: 24px;
}

/* Mobile Menu Dropdown */
.mobile-menu {
    position: fixed;
    top: 60px;
    right: -100%;
    width: 280px;
    background: var(--bg-panel);
    border-left: 1px solid var(--border);
    box-shadow: -4px 0 12px rgba(0, 0, 0, 0.3);
    z-index: 99;
    display: flex;
    flex-direction: column;
    transition: right 0.3s ease-in-out;
    max-height: calc(100vh - 60px);
    overflow-y: auto;
    visibility: hidden;
    pointer-events: none;
}

.mobile-menu.open {
    right: 0;
    visibility: visible;
    pointer-events: auto;
}

.mobile-menu .menu-item {
    padding: 16px 24px;
    color: var(--text-main);
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s;
    display: block;
}

.mobile-menu .menu-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #3b82f6;
}

.mobile-menu .menu-item:last-child {
    border-bottom: none;
}

/* Dropdown Menu */
.dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
    min-width: 150px;
    z-index: 1000;
    overflow: hidden;
}

.dropdown-item {
    display: block;
    padding: 12px 16px;
    color: var(--text-main);
    text-decoration: none;
    transition: all 0.2s;
    font-size: 0.9rem;
    cursor: pointer;
}

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

.dropdown-item-danger:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

@media (max-width: 768px) {
    .navbar-text {
        display: none;
    }
    .navbar {
        padding: 0 1rem;
    }
    .nav-actions > div > div:first-child > span {
        display: none;
    }

    /* Hide username on mobile for dashboard */
    .dashboard-username {
        display: none !important;
    }

    /* Hide desktop buttons on mobile */
    .btn-dashboard,
    .btn-login {
        display: none !important;
    }

    /* Show hamburger menu on mobile */
    .hamburger-menu {
        display: flex !important;
    }
}

@media (max-width: 768px) {
    .desktop-only {
        display: none !important;
    }
}

@media (min-width: 769px) {
    .mobile-only {
        display: none !important;
    }
}

/* Dashboard hamburger always visible */
.dashboard-hamburger {
    display: flex !important;
}
