

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: none;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(74, 108, 247, 0.15);
}

.btn-primary {
    background: linear-gradient(to right, var(--primary), #6e8ffa);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(to right, #6e8ffa, var(--primary));
    color: white;
    transform: translateY(-3px);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap; /* 允许元素在需要时换行 */
    gap: 10px; /* 设置元素之间的间距 */
}

.section-title {
    font-size: 22px;
    color: #333;
    margin: 0;
    flex: 1; /* 允许标题占据可用空间 */
    min-width: 200px; /* 确保标题有最小宽度 */
}

.section-title i {
    color: #3b82f6;
    margin-right: 8px;
}

.section-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap; /* 允许操作按钮在需要时换行 */
    gap: 5px; /* 设置操作按钮之间的间距 */
}

.section-action {
    padding: 5px 10px;
    color: #666;
    font-size: 14px;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.2s;
    white-space: nowrap; /* 防止按钮文本换行 */
}

.section-action:hover {
    color: #3b82f6;
    background-color: #f0f7ff;
}

.section-action.active {
    color: #3b82f6;
    font-weight: 500;
}

.apps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

/* 面包屑导航样式 */
.breadcrumb-container {
    background-color: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    padding: 10px 0;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    padding: 0;
    margin: 0;
    list-style: none;
    font-size: 14px;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    max-width: 200px; /* 设置最大宽度，根据需要调整 */
    overflow: hidden; /* 确保溢出内容被隐藏 */
}

.breadcrumb-item a, 
.breadcrumb-item span {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s;
    white-space: nowrap; /* 防止文本换行 */
    overflow: hidden; /* 隐藏溢出内容 */
    text-overflow: ellipsis; /* 显示省略号 */
    max-width: 100%; /* 确保内容不超过父容器 */
}

.breadcrumb-item a:hover {
    color: var(--primary);
}

.breadcrumb-item:not(:first-child)::before {
    content: "/";
    padding: 0 10px;
    color: var(--text-tertiary);
    flex-shrink: 0; /* 防止分隔符被压缩 */
}

.breadcrumb-item:last-child {
    color: var(--primary);
    font-weight: 500;
}

/* 保持面包屑容器的弹性布局 */
.breadcrumb {
    display: flex;
    flex-wrap: nowrap; /* 防止项目换行 */
    align-items: center;
    padding: 0;
    margin: 0;
    list-style: none;
    overflow-x: auto; /* 如果内容太多，允许水平滚动 */
    -webkit-overflow-scrolling: touch; /* 提升移动端滚动体验 */
}

/* 隐藏滚动条但保留功能（可选） */
.breadcrumb::-webkit-scrollbar {
    display: none;
}



/* 响应式调整 */
@media (max-width: 768px) {
    .breadcrumb {
        font-size: 12px;
    }
    
    .section-header {
        /* 不再强制设置为列布局，而是依靠flex-wrap实现自然换行 */
        /* flex-direction: column; */
        /* align-items: flex-start; */
        margin-bottom: 15px;
    }
    
    .section-title {
        font-size: 20px; /* 稍微减小标题字体大小 */
    }
    
    .section-action {
        padding: 4px 8px; /* 稍微减小按钮的内边距 */
        font-size: 13px; /* 稍微减小按钮字体大小 */
    }
    
    .breadcrumb-item:not(:first-child)::before {
        padding: 0 6px;
    }
}



/* 徽章容器 */
.post-user-badges {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    overflow: hidden;
    flex-shrink: 1;
}

/* 统一徽章基础样式 */
.user-gender-badge, .user-level-badge, .user-vip-badge, .user-title-badge {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    border-radius: 3px;
    font-size: 12px;
    padding: 0 3px;
    min-height: 20px;
    margin-right: 4px;
    white-space: nowrap;
}

/* 图标右侧间距 */
.user-gender-badge i {
    margin-right: 3px;
}

/* 为钻石图标添加右边距 */
.fa-diamond {
    margin-right: 2px;
}

/* 性别徽章样式 */
.male-badge {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    color: white;
}

.female-badge {
    background: linear-gradient(135deg, #ff6b9c 0%, #ff3377 100%);
    color: white;
}

.unknown-badge {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%);
    color: white;
}

/* VIP徽章样式 */
.user-vip-badge {
    color: #ff9900;
    background: rgba(255, 153, 0, 0.1);
    border: 1px solid #ff9900;
}

.user-admin-badge {
    display: inline-block;
    padding: 2px 6px;
    font-size: 11px;
    border-radius: 3px;
    background-color: #d9534f;
    color: white;
    margin-right: 4px;
}

.user-admin-badge i {
    margin-right: 2px;
}


/* 用户等级样式 */
.user-level-badge {
    color: #fff;
    text-transform: uppercase;
}

/* 等级颜色 */
/* 等级颜色 */
.user-level-badge.lv1 { background-color: #689f38; } /* 深绿色 */
.user-level-badge.lv2 { background-color: #0288d1; } /* 深蓝色 */
.user-level-badge.lv3 { background-color: #8e24aa; } /* 深紫色 */
.user-level-badge.lv4 { background-color: #d84315; } /* 深橙红色 */
.user-level-badge.lv5 { background-color: #d32f2f; } /* 深红色 */
.user-level-badge.lv6 { background-color: #c2185b; } /* 深粉红色 */
.user-level-badge.lv7 { background-color: #7b1fa2; } /* 深紫色 */
.user-level-badge.lv8 { background-color: #512da8; } /* 深紫蓝色 */
.user-level-badge.lv9 { background-color: #303f9f; } /* 深靛蓝色 */
.user-level-badge.lv10 { background-color: #1976d2; } /* 深蓝色 */
.user-level-badge.lv11 { background-color: #0097a7; } /* 深青色 */
.user-level-badge.lv12 { background-color: #00796b; } /* 深蓝绿色 */
.user-level-badge.lv13 { background-color: #388e3c; } /* 深绿色 */
.user-level-badge.lv14 { background-color: #7cb342; } /* 中绿色 */
.user-level-badge.lv15 { background-color: #afb42b; } /* 橄榄绿 */
.user-level-badge.lv16 { background-color: #fbc02d; } /* 金黄色 */
.user-level-badge.lv17 { background-color: #ef6c00; } /* 深橙色 */
.user-level-badge.lv18 { background-color: #e64a19; } /* 红橙色 */
.user-level-badge.lv19 { background-color: #bf360c; } /* 赤褐色 */
.user-level-badge.lv20 { background-color: #000000; } /* 黑色 */




/* pagination分页样式 */
/* 分页样式优化 */
.pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap; /* 允许在需要时换行 */
    margin: 20px 0;
    list-style: none;
    padding: 0;
    font-size: 14px;
}

.pagination li {
    margin: 3px; /* 统一各方向间距 */
    display: inline-block;
}

.pagination a, 
.pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px; /* 减小最小宽度 */
    height: 32px; /* 减小高度 */
    padding: 0 8px;
    border-radius: var(--border-radius);
    background: white;
    color: var(--dark);
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid var(--border);
    box-sizing: border-box; /* 确保边框包含在宽度内 */
}

/* 上一页下一页按钮适应中文长度 */
.pagination li:first-child a,
.pagination li:first-child span,
.pagination li:last-child a,
.pagination li:last-child span {
    width: 64px; /* 固定合适宽度适应中文 */
    padding: 0 5px;
    font-size: 13px; /* 略微减小字体 */
}

.pagination a:hover {
    background: #f5f8ff;
    border-color: #c8d8ff;
}

.pagination .active span {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 2px 5px rgba(70, 163, 255, 0.15);
}

.pagination .disabled span {
    color: #b1b1b1;
    background: #f9f9f9;
    cursor: not-allowed;
}

/* 在小屏幕设备上进一步优化 */
@media (max-width: 576px) {
    .pagination a, 
    .pagination span {
        min-width: 28px;
        height: 28px;
        font-size: 12px;
    }
    
    .pagination li:first-child a,
    .pagination li:first-child span,
    .pagination li:last-child a,
    .pagination li:last-child span {
        width: 56px;
        font-size: 12px;
    }
}
