/* NavMenu Styles - Fix for user dropdown overlapping */

.user-menu {
    position: relative;
}

.user-dropdown {
    z-index: 1050 !important;
    min-width: 250px;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border: none;
    border-radius: 0.375rem;
    margin-top: 0.5rem;
    position: absolute !important;
    right: 0;
    top: 100%;
}

.user-dropdown .dropdown-item {
    padding: 0.5rem 1rem;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    transition: background-color 0.15s ease-in-out;
}

.user-dropdown .dropdown-item:hover {
    background-color: #f8f9fa;
}

.user-dropdown .dropdown-item:focus {
    background-color: #e9ecef;
    outline: none;
}

.user-dropdown .dropdown-item-text {
    padding: 0.5rem 1rem;
    color: #6c757d;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 220px;
    font-size: 0.875rem;
}

.user-name {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: inline-block;
}

.top-row {
    z-index: 1000;
    position: relative;
}

.nav-scrollable {
    z-index: 100;
    position: relative;
}

/* Prevent dropdown from interfering with navigation */
.navbar .dropdown-menu {
    transform: translateY(0);
}

/* Mobile responsive adjustments */
@media (max-width: 767px) {
    .user-name {
        max-width: 100px;
    }
    
    .user-dropdown {
        min-width: 200px;
        right: 10px;
    }
    
    .user-dropdown .dropdown-item-text {
        max-width: 170px;
    }
}

/* Ensure proper layering on all screen sizes */
@media (min-width: 768px) {
    .user-dropdown {
        max-width: 280px;
    }
}

/* Fix for Bootstrap dropdown z-index issues */
.dropdown-menu.show {
    z-index: 1050 !important;
}