/* ========================================
   社区个人主页标准布局设计
   参考：知乎、GitHub、微博等成熟社区
   ======================================== */

/* 认证徽章系统样式优化 */
.certification-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.875rem;
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.025em;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.certification-badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.certification-badge::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.certification-badge:hover::before {
    left: 100%;
}

/* 基础认证状态 */
.certification-badge.certified {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #92400e;
    border-color: #f59e0b;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.2);
}

.certification-badge.certified:hover {
    background: linear-gradient(135deg, #fde68a, #fcd34d);
}

/* 创作身份标签样式优化 */
.certification-badge.cert-type-visual_artist {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    color: #1e40af;
    border-color: #3b82f6;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
}

.certification-badge.cert-type-visual_artist:hover {
    background: linear-gradient(135deg, #bfdbfe, #93c5fd);
}

.certification-badge.cert-type-musician {
    background: linear-gradient(135deg, #fce7f3, #fbcfe8);
    color: #be185d;
    border-color: #ec4899;
    box-shadow: 0 2px 8px rgba(236, 72, 153, 0.2);
}

.certification-badge.cert-type-musician:hover {
    background: linear-gradient(135deg, #fbcfe8, #f9a8d4);
}

.certification-badge.cert-type-writer {
    background: linear-gradient(135deg, #ecfdf5, #d1fae5);
    color: #065f46;
    border-color: #10b981;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.2);
}

.certification-badge.cert-type-writer:hover {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
}

.certification-badge.cert-type-designer {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #92400e;
    border-color: #f59e0b;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.2);
}

.certification-badge.cert-type-designer:hover {
    background: linear-gradient(135deg, #fde68a, #fcd34d);
}

.certification-badge.cert-type-photographer {
    background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
    color: #374151;
    border-color: #6b7280;
    box-shadow: 0 2px 8px rgba(107, 114, 128, 0.2);
}

.certification-badge.cert-type-photographer:hover {
    background: linear-gradient(135deg, #e5e7eb, #d1d5db);
}

.certification-badge.cert-type-curator {
    background: linear-gradient(135deg, #ede9fe, #ddd6fe);
    color: #7c3aed;
    border-color: #8b5cf6;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.2);
}

.certification-badge.cert-type-curator:hover {
    background: linear-gradient(135deg, #ddd6fe, #c4b5fd);
}

.certification-badge.cert-type-art_critic {
    background: linear-gradient(135deg, #fdf4ff, #fae8ff);
    color: #a855f7;
    border-color: #c084fc;
    box-shadow: 0 2px 8px rgba(192, 132, 252, 0.2);
}

.certification-badge.cert-type-art_critic:hover {
    background: linear-gradient(135deg, #fae8ff, #f3e8ff);
}

.certification-badge.cert-type-art_educator {
    background: linear-gradient(135deg, #ecfeff, #cffafe);
    color: #0e7490;
    border-color: #06b6d4;
    box-shadow: 0 2px 8px rgba(6, 182, 212, 0.2);
}

.certification-badge.cert-type-art_educator:hover {
    background: linear-gradient(135deg, #cffafe, #a5f3fc);
}

.certification-badge.cert-type-digital_artist {
    background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
    color: #0c4a6e;
    border-color: #0284c7;
    box-shadow: 0 2px 8px rgba(2, 132, 199, 0.2);
}

.certification-badge.cert-type-digital_artist:hover {
    background: linear-gradient(135deg, #e0f2fe, #bae6fd);
}

.certification-badge.cert-type-craftsman {
    background: linear-gradient(135deg, #fafaf9, #f5f5f4);
    color: #a8a29e;
    border-color: #d6d3d1;
    box-shadow: 0 2px 8px rgba(214, 211, 209, 0.2);
}

.certification-badge.cert-type-craftsman:hover {
    background: linear-gradient(135deg, #f5f5f4, #e7e5e4);
}

/* 图标样式优化 */
.certification-badge i {
    font-size: 0.875rem;
    opacity: 0.8;
    flex-shrink: 0;
}

/* 认证状态页面的标签样式优化 */
.cert-identity-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.cert-identity-tags .certification-badge {
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    border-radius: 24px;
    animation: badgeFadeIn 0.3s ease-out;
}

@keyframes badgeFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 详细信息页面的标签样式 */
.identity-tags-display {
    margin-top: 0.75rem;
}

.identity-tags-display .certification-badge {
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.8125rem;
    padding: 0.375rem 0.75rem;
    border-radius: 18px;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .certification-badge {
        font-size: 0.75rem;
        padding: 0.25rem 0.625rem;
        gap: 0.25rem;
    }

    .certification-badge i {
        font-size: 0.75rem;
    }

    .cert-identity-tags {
        gap: 0.375rem;
    }

    .identity-tags-display .certification-badge {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
        margin-right: 0.375rem;
        margin-bottom: 0.375rem;
    }

    .my-user-certification-tags .certification-badge {
        font-size: 0.6875rem;
        padding: 0.1875rem 0.375rem;
    }

    .my-user-certification-tags .certification-badge i {
        font-size: 0.6875rem;
    }
}

/* ========================================
   简洁轻量的个人主页设计
   设计理念：简洁、清爽、实用
   ======================================== */

/* 1. 基础样式 - 扁平化设计 */
.user-profile-page {
    background: #f8f9fa;
    min-height: 100vh;
}

.user-profile-page .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* 2. 头部卡片 - 简洁设计 */
.profile-cover-section {
    margin-bottom: 1.5rem;
}

.profile-cover-bg {
    display: none; /* 移除封面背景 */
}

.profile-cover-content {
    padding-top: 1.5rem;
}

/* 3. 个人信息卡片 - 扁平化设计 */
.profile-header-wrapper {
    background: white;
    border-radius: 8px;
    padding: 2rem;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 1.5rem;
    align-items: start;
    border: 1px solid #e9ecef;
}

/* 4. 头像区域 - 扁平化设计 */
.profile-avatar-section {
    position: relative;
}

.profile-avatar-wrapper {
    width: 80px;
    height: 80px;
}

.profile-avatar {
    width: 80px !important;
    height: 80px !important;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e9ecef;
}

.avatar-ring {
    display: none;
}

/* 5. 用户信息区域 */
.profile-info-section {
    flex: 1;
    min-width: 0;
}

.profile-main-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.profile-username {
    font-size: 1.5rem !important;
    font-weight: 600;
    color: #1a202c !important;
    margin: 0;
    line-height: 1.3;
}

.profile-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.625rem;
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 500;
    background: #e9ecef;
    color: #495057;
}

.badge-verified {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.badge-certified {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.profile-bio {
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.5;
    margin: 0;
    max-width: 600px;
}

/* 6. 统计数据 - 移至侧边栏，头部不再显示 */
.profile-stats {
    display: none;
}


/* 认证状态页面的特殊样式 */
.certification-status .status-card {
    position: relative;
    overflow: hidden;
}

.certification-status .status-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2);
}

/* 不同认证状态的顶部装饰线 */
.certification-status .status-card.status-0::before {
    background: linear-gradient(90deg, #fbbf24, #f59e0b);
}

.certification-status .status-card.status-1::before {
    background: linear-gradient(90deg, #10b981, #059669);
}

.certification-status .status-card.status-2::before {
    background: linear-gradient(90deg, #ef4444, #dc2626);
}

.certification-status .status-card.status-3::before {
    background: linear-gradient(90deg, #6b7280, #4b5563);
}

.certification-status .status-card.status-4::before {
    background: linear-gradient(90deg, #fd7e14, #ea580c);
}

.certification-status .status-card.status-5::before {
    background: linear-gradient(90deg, #17a2b8, #0891b2);
}

.certification-status .cert-identity-tags .certification-badge {
    position: relative;
    z-index: 1;
}

/* 认证状态页面时间线优化 */
.certification-status .timeline-item {
    position: relative;
    padding-left: 3rem;
    margin-bottom: 1.5rem;
}

.certification-status .timeline-item::before {
    content: '';
    position: absolute;
    left: 1rem;
    top: 0.5rem;
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background: #e5e7eb;
    border: 2px solid #ffffff;
    box-shadow: 0 0 0 2px #e5e7eb;
}

.certification-status .timeline-item.completed::before {
    background: #10b981;
    box-shadow: 0 0 0 2px #10b981;
}

.certification-status .timeline-item.completed + .timeline-item::after {
    content: '';
    position: absolute;
    left: 1.375rem;
    top: -1rem;
    width: 2px;
    height: 2rem;
    background: #10b981;
    z-index: -1;
}

/* 材料展示卡片优化 */
.certification-status .material-item {
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.certification-status .material-item:hover {
    transform: translateX(4px);
    border-left-color: #667eea;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 认证状态页面的整体布局优化 */
.certification-status .status-section {
    padding: 3rem 0;
}

.certification-status .status-card {
    max-width: 1000px;
    margin: 0 auto;
}

/* 个人主页头部认证标签的特殊样式 */
.user-header-card .certification-badge {
    margin-left: 0.5rem;
    margin-bottom: 0.25rem;
    vertical-align: middle;
}

/* 7. 操作按钮区域 - 简洁设计 */
.profile-actions-section {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    align-items: stretch;
}

.profile-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid;
    white-space: nowrap;
}

.btn-follow-primary {
    background: #495057;
    color: white;
    border-color: #495057;
}

.btn-follow-primary:hover {
    background: #343a40;
    border-color: #343a40;
}

.btn-following {
    background: white;
    color: #6c757d;
    border-color: #dee2e6;
}

.btn-following:hover {
    background: #f8f9fa;
    color: #dc3545;
    border-color: #dc3545;
}

.btn-message {
    background: white;
    color: #6c757d;
    border-color: #dee2e6;
}

.btn-message:hover {
    background: #f8f9fa;
    border-color: #adb5bd;
}

.profile-btn i {
    font-size: 0.875rem;
}

/* 5. 右侧：统计和操作 */
.user-info-right {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: flex-end;
}

.user-stats-row {
    display: flex;
    gap: 2rem;
}

.stat-box {
    text-align: center;
}

.stat-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: all 0.2s ease;
    padding: 0.5rem;
    border-radius: 8px;
}

.stat-link:hover {
    background: #f7fafc;
    transform: translateY(-2px);
}

.stat-num {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a202c;
    line-height: 1.2;
}

.stat-name {
    font-size: 0.875rem;
    color: #718096;
    margin-top: 0.25rem;
}

.user-actions-row {
    display: flex;
    gap: 0.75rem;
}

.btn-primary,
.btn-secondary {
    padding: 0.625rem 1.5rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: #3b82f6;
    color: white;
    border-color: #3b82f6;
}

.btn-primary:hover {
    background: #2563eb;
    border-color: #2563eb;
}

.btn-primary.btn-unfollow {
    background: #ef4444;
    border-color: #ef4444;
}

.btn-primary.btn-unfollow:hover {
    background: #dc2626;
    border-color: #dc2626;
}

.btn-secondary {
    background: white;
    color: #4a5568;
    border-color: #e2e8f0;
}

.btn-secondary:hover {
    background: #f7fafc;
    border-color: #cbd5e0;
}

/* 8. 导航标签栏 - 扁平化切换标签 */
.profile-nav-section {
    padding: 1rem 0;
    margin-bottom: 1.5rem;
}

.profile-nav-tabs {
    display: inline-flex;
    gap: 0.375rem;
    background: #f8f9fa;
    padding: 0.25rem;
    border-radius: 6px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    border: 1px solid #e9ecef;
}

.profile-nav-tabs::-webkit-scrollbar {
    display: none;
}

.nav-tab {
    padding: 0.5rem 1rem;
    color: #6c757d;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    border-radius: 4px;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.nav-tab:hover {
    color: #495057;
    background: #e9ecef;
}

.nav-tab.active {
    background: white;
    color: #212529;
    font-weight: 600;
    border: 1px solid #e9ecef;
}

/* 9. 内容区域 - 扁平化布局 */
.profile-content-area {
    padding: 0 0 2rem;
}

.profile-content-area .container {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1.5rem;
    align-items: start;
}

.content-layout {
    display: contents;
}

.content-main {
    min-width: 0;
}

.content-box {
    background: white;
    border-radius: 6px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: 1px solid #e9ecef;
}

.content-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #212529;
    margin: 0 0 1rem 0;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e9ecef;
}

.content-desc {
    font-size: 0.875rem;
    color: #6c757d;
    margin: 0 0 1rem 0;
    line-height: 1.5;
}

/* 8. 信息列表 */
.info-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    margin: 0;
}

.info-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f7fafc;
}

.info-item:last-child {
    border-bottom: none;
}

.info-item dt {
    font-size: 0.875rem;
    font-weight: 500;
    color: #4a5568;
}

.info-item dd {
    font-size: 0.875rem;
    color: #1a202c;
    font-weight: 600;
    margin: 0;
}

.info-item dd a {
    color: #3b82f6;
    text-decoration: none;
}

.info-item dd a:hover {
    color: #2563eb;
}

/* 9. 邀请链接 */
.invite-box {
    display: flex;
    gap: 0.75rem;
}

.invite-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #f7fafc;
    font-size: 0.875rem;
    color: #4a5568;
    font-family: monospace;
}

.invite-input:focus {
    outline: none;
    border-color: #3b82f6;
    background: white;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.btn-copy {
    padding: 0.75rem 1.25rem;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-copy:hover {
    background: #2563eb;
}

/* 10. 侧边栏 - 扁平化卡片 */
.content-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    position: sticky;
    top: 70px;
}

.sidebar-box {
    background: white;
    border-radius: 6px;
    padding: 1.5rem;
    border: 1px solid #e9ecef;
}

.sidebar-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #212529;
    margin: 0 0 1rem 0;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e9ecef;
}

.sidebar-desc {
    font-size: 0.875rem;
    color: #718096;
    margin: 0 0 1rem 0;
    line-height: 1.6;
}

.sidebar-info-list {
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
    margin: 0;
}

.sidebar-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 4px;
    transition: background-color 0.15s ease;
}

.sidebar-info-item:hover {
    background: #e9ecef;
}

.sidebar-info-item dt {
    font-size: 0.875rem;
    font-weight: 500;
    color: #6b7280;
    margin-right: 0.5rem;
}

.sidebar-info-item dd {
    font-size: 0.875rem;
    color: #1a202c;
    font-weight: 600;
    margin: 0;
}

.sidebar-invite-box {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.sidebar-invite-input {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    background: #f8f9fa;
    font-size: 0.75rem;
    color: #495057;
    font-family: monospace;
}

.sidebar-invite-input:focus {
    outline: none;
    border-color: #adb5bd;
    background: white;
}

.sidebar-copy-btn {
    padding: 0.5rem 1rem;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s ease;
}

.sidebar-copy-btn:hover {
    background: #5a6268;
}

/* 10.7. 简化的基本信息样式 */
.sidebar-info-simple {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.info-simple-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.875rem;
    color: #4a5568;
}

.info-icon {
    font-size: 1rem;
    flex-shrink: 0;
}

.info-text {
    flex: 1;
}

/* 10.5. 侧边栏统计样式 - 简洁设计 */
.sidebar-stats-box {
    padding: 1.5rem;
}

.sidebar-stats-horizontal {
    display: flex;
    align-items: center;
    justify-content: space-around;
    gap: 0.5rem;
}

.stat-h-item {
    text-align: center;
    flex: 1;
}

.stat-h-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.stat-h-value {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a202c;
    line-height: 1;
    margin-bottom: 0.375rem;
}

.stat-h-link:hover .stat-h-value {
    color: #3b82f6;
}

.stat-h-label {
    font-size: 0.75rem;
    color: #9ca3af;
    font-weight: 400;
}

.stat-h-divider {
    width: 1px;
    height: 32px;
    background: #e5e7eb;
    flex-shrink: 0;
}

/* 10.6. 侧边栏按钮样式 */
.sidebar-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.sidebar-btn {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid;
    display: block;
}

.sidebar-btn.btn-follow {
    background: #3b82f6;
    color: white;
    border-color: #3b82f6;
}

.sidebar-btn.btn-follow:hover {
    background: #2563eb;
    border-color: #2563eb;
}

.sidebar-btn.btn-unfollow {
    background: #fed7d7;
    color: #c53030;
    border-color: #feb2b2;
}

.sidebar-btn.btn-unfollow:hover {
    background: #ef4444;
    color: white;
    border-color: #ef4444;
}

.sidebar-btn.btn-message {
    background: #e2e8f0;
    color: #4a5568;
    border-color: #cbd5e0;
}

.sidebar-btn.btn-message:hover {
    background: #cbd5e0;
    color: #2d3748;
}

/* 11. 响应式设计 - 移动端优化 */
@media (max-width: 1024px) {
    .profile-content-area .container {
        grid-template-columns: 1fr 300px;
        gap: 1.5rem;
    }
    
    .profile-header-wrapper {
        grid-template-columns: auto 1fr;
        gap: 1.5rem;
    }
    
    .profile-actions-section {
        grid-column: 1 / -1;
        flex-direction: row;
        justify-content: flex-start;
    }
}

@media (max-width: 768px) {
    .user-profile-page .container {
        padding: 0 1rem;
    }
    
    /* 封面区域 */
    .profile-cover-bg {
        height: 150px;
    }
    
    .profile-cover-content {
        margin-top: -60px;
    }
    
    /* 头部卡片 */
    .profile-header-wrapper {
        grid-template-columns: 1fr;
        padding: 1.5rem;
        text-align: center;
        gap: 1.5rem;
    }
    
    .profile-avatar-section {
        display: flex;
        justify-content: center;
    }
    
    .profile-avatar-wrapper {
        width: 100px;
        height: 100px;
    }
    
    .profile-avatar {
        width: 100px !important;
        height: 100px !important;
    }
    
    .avatar-ring {
        width: 108px;
        height: 108px;
    }
    
    .profile-info-section {
        text-align: center;
    }
    
    .profile-username {
        font-size: 1.5rem !important;
    }
    
    .profile-badges {
        justify-content: center;
    }
    
    .profile-bio {
        max-width: 100%;
        margin: 0 auto;
    }
    
    .profile-stats {
        justify-content: center;
        gap: 1.5rem;
        flex-wrap: wrap;
    }
    
    .stat-item {
        min-width: 70px;
    }
    
    .stat-value {
        font-size: 1.25rem;
    }
    
    .stat-label {
        font-size: 0.8125rem;
    }
    
    /* 操作按钮 */
    .profile-actions-section {
        flex-direction: row;
        gap: 0.5rem;
    }
    
    .profile-btn {
        flex: 1;
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
    }
    
    /* 导航标签 */
    .profile-nav-section {
        padding: 0.75rem 0;
        margin-bottom: 1.5rem;
    }
    
    .nav-tab {
        padding: 0.5rem 1rem;
        font-size: 0.8125rem;
    }
    
    /* 内容区域 */
    .profile-content-area .container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .content-sidebar {
        position: static;
        top: 0;
        order: -1;
    }
    
    .content-box {
        padding: 1.5rem;
    }
    
    .topic-images {
        max-width: 100%;
    }
    
    .topic-image {
        width: 100px;
        height: 100px;
    }
}

@media (max-width: 480px) {
    .user-profile-page .container {
        padding: 0 0.875rem;
    }
    
    /* 封面区域 */
    .profile-cover-bg {
        height: 120px;
    }
    
    .profile-cover-content {
        margin-top: -50px;
    }
    
    /* 头部卡片 */
    .profile-header-wrapper {
        padding: 1.25rem;
        gap: 1.25rem;
        border-radius: 16px;
    }
    
    .profile-avatar-wrapper {
        width: 80px;
        height: 80px;
    }
    
    .profile-avatar {
        width: 80px !important;
        height: 80px !important;
        border: 3px solid white;
    }
    
    .avatar-ring {
        width: 86px;
        height: 86px;
    }
    
    .profile-username {
        font-size: 1.375rem !important;
    }
    
    .badge {
        font-size: 0.75rem;
        padding: 0.25rem 0.75rem;
    }
    
    .profile-bio {
        font-size: 0.875rem;
    }
    
    .profile-stats {
        gap: 1rem;
    }
    
    .stat-value {
        font-size: 1.125rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    /* 操作按钮 */
    .profile-actions-section {
        flex-direction: column;
        gap: 0.625rem;
    }
    
    .profile-btn {
        width: 100%;
        padding: 0.75rem;
        font-size: 0.875rem;
    }
    
    /* 导航标签 */
    .nav-tab {
        padding: 0.5rem 0.875rem;
        font-size: 0.8125rem;
    }
    
    /* 内容卡片 */
    .content-box {
        padding: 1.25rem;
        border-radius: 12px;
    }
    
    .content-title {
        font-size: 1.125rem;
        margin-bottom: 1.25rem;
        padding-bottom: 0.875rem;
    }
    
    .topic-image {
        width: 85px;
        height: 85px;
    }
    
    /* 侧边栏 */
    .sidebar-box {
        padding: 1.25rem;
        border-radius: 12px;
    }
    
    .sidebar-title {
        font-size: 0.9375rem;
    }
    
    .sidebar-stats-horizontal {
        flex-direction: column;
        gap: 1rem;
    }
    
    .stat-h-item {
        display: flex;
        justify-content: space-between;
        width: 100%;
        text-align: left;
        padding: 0.5rem;
    }
    
    .stat-h-value {
        font-size: 1.5rem;
    }
    
    .stat-h-label {
        font-size: 0.75rem;
    }
    
    .stat-h-divider {
        display: none;
    }
    
    .sidebar-invite-input {
        font-size: 0.75rem;
        padding: 0.75rem;
    }
    
    .sidebar-copy-btn {
        padding: 0.625rem 1rem;
        font-size: 0.8125rem;
    }
}

/* 12. 帖子列表样式 - 扁平化卡片 */
.topic-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.topic-item {
    padding: 1.5rem;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    transition: border-color 0.15s ease;
}

.topic-item:hover {
    border-color: #dee2e6;
}

.topic-header {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    align-items: flex-start;
}

.topic-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #e9ecef;
}

.topic-meta {
    flex: 1;
    min-width: 0;
}

.topic-title-row {
    margin-bottom: 0.625rem;
}

.topic-label {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    background: #dc3545;
    color: white;
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 500;
    margin-right: 0.5rem;
}

.topic-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1a202c;
    text-decoration: none;
    line-height: 1.5;
}

.topic-title:hover {
    color: #3b82f6;
}

.topic-info {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
    color: #6b7280;
    flex-wrap: wrap;
    align-items: center;
}

.topic-author {
    color: #4b5563;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.topic-author:hover {
    color: #3b82f6;
}

.topic-group {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
}

.topic-group:hover {
    color: #2563eb;
}

.topic-stats {
    display: flex;
    gap: 1.25rem;
    font-size: 0.875rem;
    color: #9ca3af;
    margin-left: auto;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.topic-excerpt {
    font-size: 0.9375rem;
    color: #4b5563;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.topic-images {
    display: flex;
    gap: 0.625rem;
    margin-top: 1.25rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e0 #f1f5f9;
    padding-bottom: 0.5rem;
}

.topic-images::-webkit-scrollbar {
    height: 6px;
}

.topic-images::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

.topic-images::-webkit-scrollbar-thumb {
    background: #cbd5e0;
    border-radius: 3px;
}

.topic-images::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

.topic-image {
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
}

.topic-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.2s ease;
}

.topic-image:hover img {
    opacity: 0.9;
}

/* 更多图片遮罩 */
.topic-image.has-more {
    position: relative;
}

.image-more-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
}

.more-count {
    font-size: 1.5rem;
    font-weight: 600;
    color: white;
}

/* 13. 小组网格样式 - 扁平化 */
.group-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}

.group-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    transition: border-color 0.15s ease;
}

.group-item:hover {
    border-color: #dee2e6;
}

.group-icon img {
    width: 60px;
    height: 60px;
    border-radius: 6px;
    object-fit: cover;
    border: 1px solid #e9ecef;
}

.group-info {
    flex: 1;
    min-width: 0;
}

.group-name {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
}

.group-name a {
    color: #1a202c;
    text-decoration: none;
}

.group-name a:hover {
    color: #3b82f6;
}

.group-desc {
    font-size: 0.875rem;
    color: #718096;
    margin: 0 0 0.5rem 0;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.group-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
}

.group-count {
    color: #a0aec0;
}

.group-action {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
}

.group-action:hover {
    color: #2563eb;
}

/* 14. 用户网格样式 - 扁平化 */
.user-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
}

.user-card-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    text-align: center;
    transition: border-color 0.15s ease;
}

.user-card-item:hover {
    border-color: #dee2e6;
}

.user-card-avatar img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 0.75rem;
}

.user-card-info {
    width: 100%;
}

.user-card-name {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
}

.user-card-name a {
    color: #1a202c;
    text-decoration: none;
}

.user-card-name a:hover {
    color: #3b82f6;
}

.user-card-stats {
    display: flex;
    justify-content: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: #718096;
    margin-bottom: 0.75rem;
}

.user-card-btn {
    width: 100%;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid #e2e8f0;
    background: white;
    color: #4a5568;
    cursor: pointer;
    transition: all 0.2s ease;
}

.user-card-btn:hover {
    background: #3b82f6;
    color: white;
    border-color: #3b82f6;
}

.user-card-btn.followed {
    background: #fed7d7;
    color: #c53030;
    border-color: #feb2b2;
}

.user-card-btn.followed:hover {
    background: #ef4444;
    color: white;
    border-color: #ef4444;
}

/* 15. 文章列表样式 - 扁平化 */
.article-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.article-item {
    padding: 1.5rem;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    transition: border-color 0.15s ease;
}

.article-item:hover {
    border-color: #dee2e6;
}

.article-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 0.75rem 0;
    line-height: 1.4;
}

.article-title a {
    color: #1a202c;
    text-decoration: none;
}

.article-title a:hover {
    color: #3b82f6;
}

.article-excerpt {
    font-size: 0.875rem;
    color: #718096;
    line-height: 1.6;
    margin-bottom: 1rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.article-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
    color: #a0aec0;
}

.article-stats {
    display: flex;
    gap: 1rem;
}

/* 16. 照片网格样式 - 扁平化 */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.photo-card {
    background: white;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid #e9ecef;
    transition: border-color 0.15s ease;
}

.photo-card:hover {
    border-color: #dee2e6;
}

.photo-link {
    display: block;
}

.photo-link img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.photo-info {
    padding: 1rem;
    background: white;
}

.photo-title {
    font-size: 0.875rem;
    font-weight: 500;
    color: #1a202c;
    margin: 0 0 0.5rem 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.photo-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.75rem;
    color: #a0aec0;
}

/* 17. 留言板样式 - 扁平化 */
.guestbook-form {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.gb-textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-size: 0.875rem;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 0.75rem;
}

.gb-textarea:focus {
    outline: none;
    border-color: #adb5bd;
}

.form-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
}

.btn-submit {
    padding: 0.625rem 1.25rem;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s ease;
}

.btn-submit:hover {
    background: #5a6268;
}

.btn-cancel {
    padding: 0.625rem 1.25rem;
    background: #e9ecef;
    color: #495057;
    border: none;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s ease;
}

.btn-cancel:hover {
    background: #dee2e6;
}

.guestbook-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.gb-item {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.gb-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.gb-main {
    flex: 1;
    min-width: 0;
}

.gb-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.gb-username {
    font-size: 0.875rem;
    font-weight: 600;
    color: #1a202c;
    text-decoration: none;
}

.gb-username:hover {
    color: #3b82f6;
}

.gb-time {
    font-size: 0.75rem;
    color: #a0aec0;
}

.gb-content {
    font-size: 0.875rem;
    color: #4a5568;
    line-height: 1.6;
    margin-bottom: 0.75rem;
}

.gb-reply {
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 4px;
    font-size: 0.875rem;
    color: #495057;
    margin-bottom: 0.75rem;
    border: 1px solid #e9ecef;
}

.reply-label {
    font-weight: 600;
    color: #718096;
}

.gb-actions {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
}

.gb-actions a {
    color: #718096;
    text-decoration: none;
}

.gb-actions a:hover {
    color: #3b82f6;
}

.reply-form-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.reply-form-content {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
}

.reply-form-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1a202c;
    margin: 0 0 1rem 0;
}

/* 18. 空状态和分页 - 简洁设计 */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: #9ca3af;
}

.empty-state p {
    font-size: 0.9375rem;
    margin: 0;
}

.pagination-wrapper {
    margin-top: 2rem;
    text-align: center;
    padding: 1rem 0;
}

/* 19. 性能优化和动画 */
.content-box,
.sidebar-box {
    contain: layout style;
    will-change: transform, box-shadow;
}

.user-avatar,
.profile-avatar,
.topic-avatar img {
    image-rendering: -webkit-optimize-contrast;
}

/* 20. 加载动画 */
@keyframes shimmer {
    0% {
        background-position: -468px 0;
    }
    100% {
        background-position: 468px 0;
    }
}

.loading-skeleton {
    animation: shimmer 1.2s ease-in-out infinite;
    background: linear-gradient(to right, #f3f4f6 8%, #e5e7eb 18%, #f3f4f6 33%);
    background-size: 800px 104px;
}

/* 21. 平滑滚动 - 仅在个人主页内生效 */
.user-profile-page {
    scroll-behavior: smooth;
}

/* 22. 选择文本样式 - 仅在个人主页内生效 */
.user-profile-page ::selection {
    background: rgba(59, 130, 246, 0.2);
    color: #1a202c;
}

.user-profile-page ::-moz-selection {
    background: rgba(59, 130, 246, 0.2);
    color: #1a202c;
}
