/* 用户个人资料显示区域 */
.user-profile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 5px 15px;
    border-radius: 20px;
    position: relative;
    min-height: 40px;
}

/* 用户信息容器 */
.user-info {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-grow: 1;
}

.user-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.7);
    flex-shrink: 0;
}

#user-name {
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
    margin: 0 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100px;
}

/* 用户资料中的退出按钮样式调整 */
#user-profile-btn .header-btn {
    margin-left: 5px;
    padding: 5px 10px;
    font-size: 0.85rem;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 15px;
    box-shadow: none;
}

#user-profile-btn .header-btn:hover {
    background-color: rgba(255, 255, 255, 0.25);
}

/* 联系我们弹出框 */
.contact-us-popup {
    display: none;
    position: absolute;
    right: 10px;
    top: 50px;
    background-color: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    z-index: 100;
    min-width: 200px;
    color: var(--text-color);
    border-top: 3px solid var(--primary-button-bg);
    animation: fadeIn 0.3s ease-out;
}

/* 额外添加动画效果 */
.header-btn {
    position: relative;
    overflow: hidden;
}

.header-btn:after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%);
    transform-origin: 50% 50%;
}

.header-btn:focus:not(:active):after {
    animation: ripple 1s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    20% {
        transform: scale(2, 2);
        opacity: 0.5;
    }
    100% {
        opacity: 0;
        transform: scale(3, 3);
    }
}
