/* ==================== 博客详情页 Hero ==================== */
.blog-hero {
    position: relative;
    width: 100%;
    min-height: 450px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0;
}

.blog-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.blog-hero-content {
    position: relative;
    z-index: 2;
    text-align: left;
    color: #fff;
    max-width: 1400px;
    width: 95%;
    padding: 60px 2.5%;
}

/* Hero 面包屑 */
.blog-hero-breadcrumb {
    margin-bottom: 20px;
    font-family: "poppins";
}

.blog-hero-breadcrumb .breadcrumbs {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    background: transparent;
}

.blog-hero-breadcrumb .breadcrumbs nav {
    padding: 10px 0;
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.blog-hero-breadcrumb .breadcrumbs a {
    color: rgba(255, 255, 255, 0.8);
}

.blog-hero-breadcrumb .breadcrumbs .current {
    color: #fff;
}

/* 副标题 */
.blog-hero-subtitle {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 15px;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.15);
    padding: 6px 16px;
    border-radius: 4px;
}

/* 标题 */
.blog-hero-title {
    font-size: 48px;
    font-weight: 700;
    line-height: 1.2;
    margin: 0 0 25px 0;
    color: #fff;
    max-width: 1400px;
}

/* 标签云 */
.blog-hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.hero-tag {
    display: inline-block;
    padding: 8px 18px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 20px;
    font-size: 13px;
    color: #fff;
    transition: all 0.3s;
}

.hero-tag:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #fff;
}

/* ==================== Meta 信息栏 ==================== */
.blog-meta-bar {
    background: #f8f9fa;
    border-bottom: 1px solid #e5e5e5;
    padding: 15px 0;
}

.blog-meta-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2.5%;
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 14px;
    color: #666;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.meta-item i {
    color: #999;
    font-size: 13px;
}

.meta-separator {
    color: #ccc;
}

/* ==================== 内容区域 ==================== */
.blog-content-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 2.5%;
}

.blog-main-content {
    width: 100%;
}

/* 隐藏原生标题（如果区块内容中包含） */
.blog-main-content .wp-block-post-title,
.blog-main-content h1.entry-title {
    display: none !important;
}

/* 文章内容 H2 标题样式 */
.blog-main-content h2,
.blog-main-content .wp-block-heading {
    font-size: 36px !important;
    font-weight: 600;
    line-height: 1.3;
    margin: 40px 0 20px 0;
    color: #333;
}

/* 文章内容 H3 标题样式 */
.blog-main-content h3 {
    font-size: 28px;
    font-weight: 600;
    line-height: 1.4;
    margin: 30px 0 15px 0;
    color: #333;
}

/* 文章内容 H4 标题样式 */
.blog-main-content h4 {
    font-size: 22px;
    font-weight: 600;
    line-height: 1.4;
    margin: 25px 0 12px 0;
    color: #333;
}

/* 原文链接 */
.blog-original-link {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #e5e5e5;
}

.blog-original-link a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #226184;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.3s;
}

.blog-original-link a:hover {
    color: #1a4a66;
}

.blog-original-link i {
    font-size: 12px;
}

/* ==================== 相关文章 ==================== */
.blog-related-posts {
    background: #f8f9fa;
    padding: 60px 0;
    margin-top: 40px;
}

.related-posts-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2.5%;
}

.related-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 30px;
    color: #333;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    align-items: stretch;
}

.related-post-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.related-post-card:hover {
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
}

.related-post-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.related-post-image {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #f0f0f0;
}

.related-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.related-post-card:hover .related-post-image img {
    transform: scale(1.05);
}

.related-post-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e0e0e0;
}

.related-post-placeholder i {
    font-size: 40px;
    color: #999;
}

.related-post-tag {
    position: absolute;
    bottom: 0;
    left: 0;
    background: #fff;
    color: #1a1a2e;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    padding: 15px 20px;
    border-top-right-radius: 16px;
}

/* 伪元素创建圆角缺口效果 */
.related-post-tag::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 100%;
    width: 16px;
    height: 16px;
    background: transparent;
    border-bottom-left-radius: 16px;
    box-shadow: -8px 8px 0 8px #fff;
}

.related-post-tag::after {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 0;
    width: 16px;
    height: 16px;
    background: transparent;
    border-bottom-left-radius: 16px;
    box-shadow: -8px 8px 0 8px #fff;
}

.related-post-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.related-post-title {
    font-size: 20px;
    font-weight: 600;
    line-height: 1.4;
    margin: 0 0 12px 0;
    color: #1a1a2e;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-post-excerpt {
    font-size: 14px;
    line-height: 1.6;
    color: #666;
    margin: 0 0 16px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-post-date {
    font-size: 13px;
    color: #999;
    margin-bottom: 20px;
}

.related-post-btn {
    display: block;
    width: 100%;
    padding: 14px 24px;
    background: transparent;
    color: #1a1a2e;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    border: 1px solid #1a1a2e;
    border-radius: 50px;
    transition: all 0.2s ease;
    margin-top: auto;
    box-sizing: border-box;
    cursor: pointer;
}

.related-post-btn:hover {
    background: #1a1a2e;
    color: #fff;
}

/* ==================== 响应式 ==================== */
@media screen and (max-width: 1024px) {
    .blog-hero {
        min-height: 350px;
    }
    
    .blog-hero-title {
        font-size: 32px;
    }
    
    .related-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 768px) {
    .blog-hero {
        min-height: 300px;
    }
    
    .blog-hero-content {
        padding: 60px 5%;
    }
    
    .blog-hero-title {
        font-size: 24px;
    }
    
    .blog-hero-subtitle {
        font-size: 11px;
        padding: 5px 12px;
    }
    
    .hero-tag {
        padding: 6px 14px;
        font-size: 12px;
    }
    
    .blog-meta-content {
        flex-wrap: wrap;
        gap: 10px;
        font-size: 13px;
    }
    
    .meta-separator {
        display: none;
    }
    
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .related-title {
        font-size: 24px;
    }
}
