/* ========== 个人主页（对外展示） ========== */

.profile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 300;
    backdrop-filter: blur(6px);
    animation: fadeIn 0.2s ease-out;
}

.profile-panel {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    width: 420px;
    max-height: 85vh;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.3s ease-out;
}

.profile-header {
    position: relative;
    height: 120px;
    background: linear-gradient(135deg, var(--accent) 0%, #5a52e0 50%, #a78bfa 100%);
}

.profile-cover {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.2) 100%);
}

.profile-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    color: white;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
    z-index: 2;
}

.profile-close:hover {
    background: rgba(248, 113, 113, 0.4);
    border-color: rgba(248, 113, 113, 0.5);
}

.profile-avatar {
    position: absolute;
    bottom: -40px;
    left: 24px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--accent), #5a52e0);
    border: 4px solid var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 32px;
    color: white;
    box-shadow: 0 4px 20px rgba(124, 115, 255, 0.4);
}

.profile-body {
    padding: 52px 24px 24px;
}

.profile-name {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 4px;
}

.profile-role {
    display: inline-block;
    padding: 3px 12px;
    background: var(--accent-light);
    color: var(--accent);
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.profile-divider {
    height: 1px;
    background: var(--border);
    margin: 20px 0;
}

.profile-info-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.profile-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.profile-info-label {
    font-size: 13px;
    color: var(--text-muted);
}

.profile-info-value {
    font-size: 14px;
    color: var(--text-primary);
    font-weight: 500;
}

.profile-actions {
    margin-top: 24px;
    display: flex;
    justify-content: center;
}

.profile-actions .btn {
    padding: 10px 32px;
    font-size: 14px;
}

/* ========== 个人中心（个人详细设置） ========== */

.personal-center-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 300;
    backdrop-filter: blur(6px);
    animation: fadeIn 0.2s ease-out;
}

.personal-center-panel {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    width: 500px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.3s ease-out;
    overflow: hidden;
}

.personal-center-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.personal-center-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.personal-center-close {
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    color: var(--text-muted);
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
}

.personal-center-close:hover {
    border-color: var(--error);
    color: var(--error);
    background: rgba(248, 113, 113, 0.1);
}

.personal-center-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
}

.pc-section {
    margin-bottom: 28px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

.pc-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.pc-section-title {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
    margin-bottom: 16px;
}

.pc-avatar-row {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.pc-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--accent), #5a52e0);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 22px;
    color: white;
    flex-shrink: 0;
    box-shadow: 0 4px 15px rgba(124, 115, 255, 0.3);
}

.pc-avatar-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pc-username {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.pc-role {
    font-size: 12px;
    color: var(--text-muted);
}

.pc-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.personal-center-content .form-group {
    margin-bottom: 16px;
}

.personal-center-content .form-group input {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-size: 14px;
    box-sizing: border-box;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.personal-center-content .form-group input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-light);
    outline: none;
}

.personal-center-content .form-group input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pc-info-row {
    display: flex;
    gap: 24px;
    margin-bottom: 16px;
}

.pc-info-item {
    flex: 1;
}

.pc-info-label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.pc-info-val {
    font-size: 14px;
    color: var(--text-primary);
    font-weight: 500;
}

.pc-password-error {
    padding: 10px 14px;
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.3);
    border-radius: var(--radius-lg);
    color: var(--error);
    font-size: 13px;
    margin-bottom: 12px;
}

.pc-section .btn {
    width: 100%;
    padding: 12px;
    font-size: 14px;
}

/* ========== 成员项可点击样式 ========== */

.member-item {
    cursor: pointer;
}

/* ========== 侧边栏用户区域可点击 ========== */

.sidebar-user {
    cursor: pointer;
}

.sidebar-user .btn-logout {
    z-index: 1;
    position: relative;
}