.top-navbar {
    background-color: #333;
    color: #fff;
    padding: 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    position: relative;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.navbar-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    height: 60px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-left, .nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-link {
    color: #e0e0e0;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.2s;
    font-size: 16px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.nav-link:hover {
    color: #fff;
}

.home-link {
    font-size: 1.2em;
    color: #fff;
}

#username-display {
    color: cyan;
}

.desktop-links {
    display: flex;
    gap: 20px;
}

/* Mobile Menu */
.mobile-menu {
    display: none;
    background-color: #444;
    padding: 10px 0;
}

.mobile-menu.open {
    display: block;
}

.mobile-link {
    display: block;
    color: #fff;
    text-decoration: none;
    padding: 10px 20px;
    border-bottom: 1px solid #555;
}

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

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 10;
}

.hamburger span {
    width: 30px;
    height: 3px;
    background: #fff;
    border-radius: 10px;
    transition: all 0.3s linear;
    position: relative;
    transform-origin: 1px;
}

/* Dropdown */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 5px;
}

.dropdown-menu {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    background-color: #fff;
    min-width: 160px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    z-index: 1;
    border-radius: 4px;
    margin-top: 10px;
}

.dropdown-menu a {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
}

.dropdown-menu a:hover {
    background-color: #f1f1f1;
}

.dropdown.open .dropdown-menu {
    display: block;
}

/* Media Queries */
@media (max-width: 768px) {
    .desktop-links {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
}
/* Dropdown arrow rotation */
.dropdown.open .arrow {
    transform: rotate(180deg);
}
.arrow {
    display: inline-block;
    transition: transform 0.2s;
    font-size: 0.8em;
}

/* Ensure dropdown menu doesn't overflow for long emails */
.dropdown-menu {
    max-width: 250px;
    overflow-wrap: break-word;
}
