/* ========== 博客首页样式 ========== */

/* 页面宽度与评分页一致（Bootstrap xxl 容器宽 1320px） */
.blog-container {
    max-width: 1320px;
    margin: 72px auto 40px;
    padding: 0 20px 20px;
}

/* 大屏下侧边栏略宽于 1/4（约 28%），保证发布按钮不换行显示 */
@media (min-width: 1400px) {
    .blog-container .row > .col-md-9 {
        flex: 0 0 72%;
        max-width: 72%;
    }
    .blog-container .row > .col-md-3 {
        flex: 0 0 28%;
        max-width: 28%;
    }
}

/* 文章列表样式 */
.post-item {
    background: #fff;
    padding: 25px;
    margin-bottom: 20px;
    border: 1px solid #eee;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.post-item:hover {
    box-shadow: 0 2px 12px rgba(0,0,0,0.1);
}

/* 文章标题和元信息布局 */
.post-header {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    align-items: flex-start;
}

/* 调整头像样式 */
.post-header .avatar-sm {
    width: 70px;
    height: 70px;
    border-radius: 14px;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.avatar-wrapper {
    margin-right: 15px;
}

/* 标题和元信息容器 */
.post-main {
    flex: 1;
}

.post-title {
    font-size: 20px !important;
    margin-bottom: 10px !important;
    line-height: 1.4;
}

.post-title a {
    color: #2c3e50 !important;
    text-decoration: none;
    font-weight: 600 !important;
}

.post-title a:hover {
    color: #3498db;
}

.post-meta {
    color: #666;
    font-size: 15px !important;
    margin-bottom: 8px !important;
    display: flex;
    align-items: center;
    gap: 8px;
}

.post-excerpt {
    color: #444;
    font-size: 16px !important;
    line-height: 1.6;
    margin: 15px 0;
}

.post-footer {
    color: #666;
    font-size: 15px !important;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 侧边栏样式 */
.sidebar-card {
    background: #fff;
    padding: 20px;
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid #eee;
}

.sidebar-title {
    font-size: 18px !important;
    font-weight: 500;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.hot-keywords {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.keyword-tag {
    display: inline-flex;
    align-items: center;
    background: #f0f2f5;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.75rem !important;
    line-height: 2.4;
    color: #555;
    text-decoration: none;
    transition: all 0.3s ease;
}

.keyword-tag:hover {
    background: #e1e4e8;
    color: #3498db;
}

.category-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.category-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #e8f0fe;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
    line-height: 2.4;
    color: #1a73e8;
    text-decoration: none;
    transition: all 0.3s ease;
}

.category-tag:hover {
    background: #d2e3fc;
}


.new-post-btn:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

/* 用户信息卡片样式 */
.user-stats {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-top: 1px solid #eee;
}

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

.stat-value {
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.stat-label {
    font-size: 14px;
    color: #666;
}

.card {
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.card-body {
    padding: 20px;
}

.btn-primary {
    background-color: #007bff;
    border: none;
    padding: 8px 15px;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: #0056b3;
    transform: translateY(-1px);
}

.rounded-circle {
    border: 3px solid #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.user-card {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.user-info {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.follow-btn {
    width: 100%;
    margin-top: 10px;
    padding: 8px;
}

.follow-btn.following {
    background-color: #e9ecef;
    border-color: #e9ecef;
    color: #495057;
}

.user-avatar-wrapper {
    text-align: center;
}

.stat-link {
    text-decoration: none;
    color: inherit;
    text-align: center;
}

.stat-link:hover {
    color: #007bff;
}

/* 用户信息卡片样式（侧边栏） */
.user-info-card {
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid #eee;
}

.user-info-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
}

.user-avatar {
    width: 160px;
    height: 160px;
    border-radius: 40px;
    object-fit: cover;
    margin-bottom: 12px;
    border: 3px solid #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.user-info-text {
    text-align: center;
    width: 100%;
    margin-top: 5px;
}

.user-info-text h5 {
    margin: 0 0 5px 0;
    font-size: 16px;
    font-weight: 500;
}

.user-signature {
    color: #666;
    font-size: 14px;
    margin-top: 5px;
    line-height: 1.4;
    max-height: none;
    overflow: visible;
    display: block;
    white-space: normal;
    word-wrap: break-word;
    padding: 0 10px;
    margin-bottom: 10px;
}

.user-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
    padding: 0 15px;
}

.user-actions .btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    white-space: nowrap;
    padding: 2px 8px;
    font-size: 0.75rem;
    line-height: 2.4;
    border-radius: 10px;
}

/* 分类和标签胶囊：与全站统一（13.5px/2px 8px/圆角10/36px 高） */
.category-tag, .keyword-tag {
    font-size: 0.75rem !important;
    padding: 2px 8px;
}

/* 标签云（原模板内联字号已移除，统一胶囊规格） */
.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* 用户统计信息样式 */
.user-stats-wrapper {
    border-top: 1px solid #eee;
    margin-top: 10px;
    padding-top: 10px;
}
