.menu-header {
    background: white;
    border-bottom: 1px solid #e5e7eb;
    position: relative;
    z-index: 50;
}

.menu-header-container {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    max-width: 1200px;
    margin: 0 auto;
}

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

/* User Avatar Styles */
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.user-avatar-large {
    width: 35px;
    height: 35px;
}

.user-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.user-avatar-fallback {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* background: #2563eb;*/
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

/* Dropdown Menu */
.dropdown-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    width: 250px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border: 1px solid #f3f4f6;
    overflow: hidden;
    opacity: 1;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 100;
}

.dropdown-header {
    /* background: linear-gradient(135deg, #2563eb 0%, #1A2A5A 100%);*/
    padding: 6px;
    color: white;
}

.logout-btn {
    /*  background: linear-gradient(135deg, #2563eb 0%, #1A2A5A 100% !important);*/

}

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

.user-details {
    flex: 1;
    min-width: 0;
}

.user-name {
    font-weight: 600;
    color: white;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* User Menu Items */
.user-menu-items {
    /*   padding: 8px 0;*/
}

.user-menu-item {
    width: 100%;
    /*   padding: 12px 16px;*/
    border: none;
    background-color: #FFFFFF !important;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: background-color 0.15s ease;
    text-align: left;
}

.user-menu-item:hover {
    background-color: #f9fafb;
}

.user-menu-item:hover .menu-label {
    /*  color: #2563eb;*/
}

.user-menu-item:hover .user-menu-icon {
    transform: scale(1.1);
}

.user-menu-icon {
    font-size: 20px;
    transition: transform 0.15s ease;
    flex-shrink: 0;
}

.user-menu-content {
    flex: 1;
    min-width: 0;
}

.menu-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2px;
}

.menu-label {
    font-size: 14px;
    font-weight: 500;
    color: #111827;
    transition: color 0.15s ease;
}

.menu-badge {
    background: #ef4444;
    color: white;
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 500;
}

.separator {
    height: 1px;
    background: #f3f4f6;
    margin: 4px 0;
}


/* Logout */
.logout-section {
    padding: 8px;
}

.logout-btn {
    width: 100%;
    padding: 8px 12px;
    border: none;
    background: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #dc2626;
    border-radius: 8px;
    transition: background-color 0.15s ease;
}

.logout-btn:hover {
    background-color: #fef2f2;
}

.logout-icon {
    font-size: 16px;
}

.logout-text {
    font-size: 14px;
    font-weight: 500;
}

/* Dark mode styles */
.dark-mode {
    background-color: #111827;
    color: #f9fafb;
}

.dark-mode .menu-header {
    background: #1f2937;
    border-color: #374151;
}

.dark-mode .dropdown-menu {
    background: #1f2937;
    border-color: #374151;
}

.dark-mode .user-menu-item:hover {
    background-color: #374151;
}

.dark-mode .separator {
    background: #374151;
}

.dark-mode .logout-btn:hover {
    background-color: #7f1d1d;
}

.dark-mode .theme-toggle:hover {
    color: #60a5fa;
}

/* Responsive */
@media (max-width: 768px) {
    .dropdown-menu {
        width: 280px;
        right: -20px;
    }

    .menu-header {
        padding: 12px 16px;
    }
}

@media (max-width: 480px) {
    .dropdown-menu {
        width: 260px;
        right: -40px;
    }
}