/* Profile Dropdown Menu */

.profile-nav-wrapper {
    position: relative;
}

.profile-nav {
    position: relative;
    cursor: pointer;
    border: none;
    background: none;
    padding: 4px;
    border-radius: 50%;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-nav:hover {
    background: rgba(255, 255, 255, 0.1);
}

.profile-nav:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

.profile-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    min-width: 240px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    border: 1px solid var(--gray-200);
    overflow: hidden;
}

.profile-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-dropdown-header {
    padding: 1rem;
    border-bottom: 1px solid var(--gray-200);
    background: var(--gray-50);
}

.profile-dropdown-company {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.profile-dropdown-company .avatar-small {
    width: 40px;
    height: 40px;
    font-size: 1rem;
}

.profile-dropdown-company-info {
    flex: 1;
    min-width: 0;
}

.profile-dropdown-company-name {
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--gray-900);
    margin: 0 0 0.25rem 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-dropdown-company-email {
    font-size: 0.8125rem;
    color: var(--gray-600);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-dropdown-menu {
    padding: 0.5rem;
}

.profile-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 8px;
    color: var(--gray-700);
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 0.9375rem;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
}

.profile-dropdown-item:hover {
    background: var(--gray-50);
    color: var(--gray-900);
}

.profile-dropdown-item.danger {
    color: #dc2626;
}

.profile-dropdown-item.danger:hover {
    background: #fee2e2;
    color: #991b1b;
}

.profile-dropdown-item.admin-item {
    position: relative;
    background: linear-gradient(135deg, rgba(200, 16, 46, 0.1), rgba(200, 16, 46, 0.05));
    border-left: 3px solid #c8102e;
}

.profile-dropdown-item.admin-item:hover {
    background: linear-gradient(135deg, rgba(200, 16, 46, 0.15), rgba(200, 16, 46, 0.1));
}

.admin-badge-small {
    margin-left: auto;
    padding: 0.25rem 0.5rem;
    background: #c8102e;
    color: white;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.profile-dropdown-item svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.profile-dropdown-divider {
    height: 1px;
    background: var(--gray-200);
    margin: 0.5rem 0;
}

/* Backdrop */
.profile-dropdown-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999;
    background: transparent;
    display: none;
}

.profile-dropdown-backdrop.show {
    display: block;
}

/* Mobile */
@media (max-width: 768px) {
    .profile-dropdown {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        min-width: auto;
        border-radius: 0;
        border-left: none;
        border-right: none;
    }
}

