/**
 * user.css - 用户区域样式
 * 用户信息、积分显示、登录按钮等
 */

/* === 用户区域 === */
.user-area {
    position: relative;
    min-width: 120px;
    text-align: right;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 15px;
}

.user-stats {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.85rem;
    color: #ddd;
}

.stat-badge {
    background: #333;
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid #444;
}

.recharge-btn-small {
    background: linear-gradient(135deg, #f6d365 0%, #fda085 50%, #f6d365 100%);
    background-size: 200% 200%;
    color: #5c3d00;
    border: none;
    padding: 4px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: bold;
    animation: goldShimmer 2s ease-in-out infinite;
    box-shadow: 0 0 8px rgba(246, 211, 101, 0.5), 0 0 15px rgba(253, 160, 133, 0.3);
    text-shadow: 0 1px 1px rgba(255, 255, 255, 0.3);
}

@keyframes goldShimmer {
    0% { 
        background-position: 0% 50%;
        box-shadow: 0 0 8px rgba(246, 211, 101, 0.5), 0 0 15px rgba(253, 160, 133, 0.3);
    }
    50% { 
        background-position: 100% 50%;
        box-shadow: 0 0 15px rgba(246, 211, 101, 0.8), 0 0 25px rgba(253, 160, 133, 0.5);
    }
    100% { 
        background-position: 0% 50%;
        box-shadow: 0 0 8px rgba(246, 211, 101, 0.5), 0 0 15px rgba(253, 160, 133, 0.3);
    }
}

.recharge-btn-small:hover { 
    background: linear-gradient(135deg, #ffd700 0%, #ffa500 50%, #ffd700 100%);
    background-size: 200% 200%;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.8), 0 0 30px rgba(255, 165, 0, 0.5);
    transform: scale(1.05);
    transition: transform 0.2s ease;
}

.user-trigger {
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    color: #ececf1;
}

.user-avatar-small {
    width: 32px;
    height: 32px;
    background: #5436da;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
}

.user-dropdown {
    position: absolute;
    top: 45px;
    right: 0;
    background: #2b2c2f;
    border: 1px solid #444;
    border-radius: 6px;
    width: 200px;
    display: none;
    flex-direction: column;
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    z-index: 1000;
}
.user-dropdown.show { display: flex; }

.dropdown-item {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #333;
    cursor: pointer;
    font-size: 0.9rem;
    color: #ccc;
}
.dropdown-item:hover { background: #3a3b3e; color: white; }
.dropdown-item:last-child { border-bottom: none; }

.dropdown-header {
    padding: 12px;
    background: #202123;
    border-bottom: 1px solid #333;
    font-size: 0.85rem;
    color: #888;
}

/* 积分显示 */
.credits-display {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #aaa;
    font-size: 0.85rem;
}

.credits-label {
    opacity: 0.7;
}

.credits-value {
    color: var(--accent-color);
    font-weight: bold;
}

/* 积分分隔线 */
.credits-display .divider {
    color: #555;
    margin: 0 5px;
}

/* 会员状态徽章 */
.member-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.member-badge.free {
    background: rgba(156, 163, 175, 0.2);
    color: #9ca3af;
    border: 1px solid rgba(156, 163, 175, 0.3);
}

.member-badge.basic {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(37, 99, 235, 0.2));
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.member-badge.pro {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(139, 92, 246, 0.2));
    color: #a78bfa;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

.member-badge.ultimate {
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.2), rgba(245, 158, 11, 0.2));
    color: #fbbf24;
    border: 1px solid rgba(234, 179, 8, 0.3);
}

/* 登录按钮 */
.login-btn {
    background: linear-gradient(135deg, var(--accent-color), #0d8a6a);
    border: none;
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s;
    box-shadow: 0 2px 10px rgba(16, 163, 127, 0.3);
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(16, 163, 127, 0.4);
}

/* 用户头像 */
.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-color), #0d8a6a);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 0.9rem;
    cursor: pointer;
    transition: transform 0.2s;
}

.user-avatar:hover {
    transform: scale(1.1);
}
