/* ---------------------------------------------------------------------------
   博客前台样式（2026-09-30）
   配色一律用主站 header.php 里定义的 CSS 变量（--primary / --secondary / ...），
   不在这里重复写死颜色——主站改配色，博客自动跟着变。
   只写「博客独有」的版面：列表卡片、正文排版、分页、归档。
   --------------------------------------------------------------------------- */

/* ---------- 列表页头部 ---------- */
.blog-hero {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08) 0%, rgba(118, 75, 162, 0.08) 100%);
    padding: 70px 0 60px;
    text-align: center;
}

.blog-hero .section-title {
    font-size: 38px;
    margin-bottom: 14px;
}

.blog-hero .section-desc {
    margin-bottom: 0;
}

/* ---------- 文章卡片列表 ---------- */
.blog-list {
    padding: 60px 0 90px;
}

.post-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 26px;
}

.post-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 26px 24px 22px;
    display: flex;
    flex-direction: column;
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.post-card:hover {
    transform: translateY(-4px);
    border-color: rgba(102, 126, 234, .45);
    box-shadow: var(--shadow-lg);
}

.post-card-date {
    font-size: 13px;
    color: var(--text-light);
    font-weight: 600;
    letter-spacing: .3px;
    margin-bottom: 10px;
}

.post-card-title {
    font-size: 19px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.post-card-title a {
    color: inherit;
}

.post-card:hover .post-card-title {
    color: var(--primary);
}

.post-card-summary {
    font-size: 14.5px;
    color: var(--text-gray);
    line-height: 1.7;
    margin-bottom: 16px;
    flex: 1;
}

.post-card-more {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.post-card-more::after {
    content: '\2192';
    transition: transform .2s ease;
}

.post-card:hover .post-card-more::after {
    transform: translateX(4px);
}

/* ---------- 空状态 ---------- */
.blog-empty {
    text-align: center;
    padding: 70px 20px;
    color: var(--text-gray);
}

.blog-empty .icon {
    font-size: 44px;
    margin-bottom: 14px;
}

/* ---------- 分页 ---------- */
.blog-pagination {
    display: flex;
    gap: 8px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 44px;
}

.blog-pagination a,
.blog-pagination span {
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text-gray);
    font-size: 14px;
    font-weight: 600;
}

.blog-pagination a:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.blog-pagination .current {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-color: transparent;
    color: #fff;
}

/* ---------- 归档入口（列表页底部固定一条，2026-09-30） ---------- */
.blog-archive-link {
    margin-top: 40px;
    text-align: center;
}

.blog-archive-link a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 22px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text-gray);
    font-size: 14px;
    font-weight: 600;
    transition: all 0.25s ease;
}

.blog-archive-link a:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-1px);
}

.blog-archive-link i {
    font-size: 13px;
}

/* ---------- 文章正文 ---------- */
.blog-article {
    padding: 50px 0 90px;
}

.article-shell {
    max-width: 1060px;
    margin: 0 auto;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 56px 72px;
    box-shadow: var(--shadow);
}

/* 卡片放宽后（2026-09-30，820 → 1060），内层内容统一约束到一条居中列：
   正文若跟着拉满 1060px，一行会到 100+ 字符，读起来很累。
   标题 / 元信息 / 正文 / 标签 / CTA 左边缘全部对齐在同一条 760px 列上，
   卡片多出来的宽度变成两侧对称留白，观感变宽、行长不变。
   768px 以下可用宽度不足 760px，max-width 自然失效，移动端不受影响。 */
.article-shell > * {
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
}

/* article-back 是 inline-flex（收缩到内容宽），margin auto 会把它推去正中；
   它应该贴内容列的左边缘，与标题对齐。 */
.article-shell > .article-back {
    margin-left: 0;
}

.article-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 22px;
}

.article-back:hover {
    gap: 12px;
}

.article-title {
    font-size: 36px;
    font-weight: 800;
    line-height: 1.25;
    color: var(--text-dark);
    margin-bottom: 16px;
}

.article-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    font-size: 13.5px;
    color: var(--text-light);
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 30px;
}

.article-meta i {
    margin-right: 6px;
}

/* Markdown 渲染出来的正文排版 */
.article-body {
    font-size: 16.5px;
    line-height: 1.85;
    color: #374151;
}

.article-body h2 {
    font-size: 26px;
    font-weight: 800;
    color: var(--text-dark);
    margin: 40px 0 16px;
    line-height: 1.3;
}

.article-body h3 {
    font-size: 21px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 32px 0 12px;
}

.article-body h4 {
    font-size: 17.5px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 26px 0 10px;
}

.article-body p {
    margin-bottom: 18px;
}

.article-body ul,
.article-body ol {
    margin: 0 0 20px 24px;
}

.article-body li {
    margin-bottom: 8px;
}

.article-body a {
    color: var(--primary);
    text-decoration: underline;
}

.article-body strong {
    color: var(--text-dark);
}

.article-body blockquote {
    border-left: 4px solid var(--primary);
    background: rgba(102, 126, 234, .06);
    padding: 14px 20px;
    margin: 0 0 20px;
    border-radius: 0 10px 10px 0;
    color: var(--text-gray);
}

.article-body code {
    background: #F3F4F6;
    padding: 2px 6px;
    border-radius: 5px;
    font-size: 14px;
}

.article-body pre {
    background: #1F2937;
    color: #E5E7EB;
    padding: 18px 20px;
    border-radius: 12px;
    overflow-x: auto;
    margin: 0 0 20px;
}

.article-body pre code {
    background: none;
    color: inherit;
    padding: 0;
}

.article-body img {
    border-radius: 12px;
    margin: 8px 0 20px;
    display: block;
}

.article-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 22px;
    font-size: 15px;
}

.article-body th,
.article-body td {
    border: 1px solid var(--border);
    padding: 10px 14px;
    text-align: left;
}

.article-body th {
    background: var(--bg-light);
    font-weight: 700;
    color: var(--text-dark);
}

.article-body hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 36px 0;
}

/* 标签 */
.article-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 34px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.article-tag {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--primary);
    background: rgba(102, 126, 234, .09);
    padding: 5px 12px;
    border-radius: 20px;
}

/* 正文末尾的行动号召 */
.article-cta {
    margin-top: 40px;
    padding: 30px 32px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(102, 126, 234, .1) 0%, rgba(118, 75, 162, .1) 100%);
    border: 1px solid rgba(102, 126, 234, .2);
}

.article-cta h3 {
    font-size: 19px;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.article-cta p {
    font-size: 14.5px;
    color: var(--text-gray);
    margin-bottom: 18px;
}

.article-cta .btn {
    padding: 12px 26px;
    font-size: 15px;
}

/* CTA 按钮行（2026-09-30）：此前两个按钮之间只有内联 margin-left: 10px，
 * 窄屏下折行堆叠时垂直方向零间距，两个按钮贴死。改 flex + gap 后
 * 桌面端并排、窄屏自动换行，两个方向的间距都由 gap 保证。 */
.article-cta-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

/* 文章主题 → 相关服务内链（Blog→Service 闭环，2026-09-30） */
.article-cta-services {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 20px;
}

.cta-service-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14.5px;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    width: fit-content;
    border-bottom: 1px solid transparent;
    transition: border-color .2s ease;
}

.cta-service-link i {
    font-size: 11px;
    transition: transform .2s ease;
}

.cta-service-link:hover {
    border-bottom-color: var(--primary);
}

.cta-service-link:hover i {
    transform: translateX(3px);
}

/* ---------- 归档 ---------- */
.archive-group {
    margin-bottom: 34px;
}

.archive-month {
    font-size: 17px;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.archive-month::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.archive-list {
    list-style: none;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
}

.archive-list li {
    border-bottom: 1px solid var(--border);
}

.archive-list li:last-child {
    border-bottom: none;
}

.archive-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 14px 20px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
}

.archive-list a:hover {
    background: var(--bg-light);
    color: var(--primary);
}

.archive-list .d {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-light);
    white-space: nowrap;
}

/* ---------- 主题簇导航（2026-10-13）----------
   文章正文后的「More on ...」块：同簇文章互链 + 回链 pillar 落地页。
   样式沿用 .article-tags 的分隔线节奏，视觉上与正文区隔开但不抢 CTA。 */
.article-cluster {
    margin-top: 34px;
    padding: 24px 26px;
    background: var(--bg-light);
    border: 1px solid var(--border);
    border-radius: 14px;
}

.cluster-heading {
    font-size: 17px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 14px;
}

.cluster-list {
    list-style: none;
    margin: 0 0 16px;
    padding: 0;
    display: grid;
    gap: 10px;
}

.cluster-list li {
    padding-left: 18px;
    position: relative;
    font-size: 15px;
    line-height: 1.6;
}

.cluster-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 9px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary);
}

.cluster-list a {
    color: var(--text-dark);
    font-weight: 500;
    text-decoration: none;
    transition: color .18s ease;
}

.cluster-list a:hover {
    color: var(--primary);
    text-decoration: underline;
}

.cluster-pillar {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14.5px;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    padding-top: 14px;
    border-top: 1px dashed var(--border);
    width: 100%;
}

.cluster-pillar:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
    .post-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .blog-hero {
        padding: 46px 0 38px;
    }

    .blog-hero .section-title {
        font-size: 27px;
    }

    .blog-list {
        padding: 36px 0 60px;
    }

    .post-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .blog-article {
        padding: 26px 0 60px;
    }

    .article-shell {
        padding: 26px 20px;
        border-radius: 14px;
    }

    .article-title {
        font-size: 26px;
    }

    .article-body {
        font-size: 16px;
    }

    .article-body h2 {
        font-size: 22px;
    }
}

.article-credits{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px 28px;padding:22px 24px;margin:0 0 30px;border:1px solid #dce6e1;border-radius:14px;background:#f6f9f7;color:#203c34}
.article-credits .credit-label{display:block;font-size:12px;letter-spacing:.06em;text-transform:uppercase;color:#587168;margin-bottom:5px}
.article-credits a{font-weight:700;color:#165c49;text-decoration:underline;text-underline-offset:3px}
.article-credits small{display:block;font-size:13px;line-height:1.5;margin-top:4px}
.article-credits p{grid-column:1/-1;font-size:13px;margin:0;color:#587168}
@media(max-width:600px){.article-credits{grid-template-columns:1fr;padding:18px;gap:16px}}

/* Statutory parallel text: each Chinese/English article shares one table row. */
.article-shell--statute{max-width:1320px;padding:42px 36px}
.article-shell--statute>.article-body{max-width:none;min-width:0}
.statute-version{padding:22px 24px;margin-bottom:24px;background:#f0f6f3;border-left:4px solid #236b55;border-radius:8px}
.statute-version p:last-child{margin-bottom:0}
.statute-toc{padding:20px 24px;border:1px solid #dce6e1;border-radius:10px;margin:24px 0}
.statute-toc ul{columns:2;column-gap:32px;margin-bottom:0}
.statute-toc li{break-inside:avoid;margin-bottom:10px}
.statute-scroll-hint{font-size:14px;color:#587168}
.statute-parallel{max-width:100%;overflow-x:auto;border:1px solid #dce6e1;border-radius:10px;overscroll-behavior-x:contain}
.statute-parallel:focus-visible{outline:3px solid #236b55;outline-offset:3px}
.article-body .statute-table{table-layout:fixed;min-width:760px;margin:0;font-size:15px;line-height:1.8}
.article-body .statute-table caption{text-align:left;padding:14px 18px;background:#f6f9f7;font-size:13px;color:#496158;caption-side:top}
.article-body .statute-table th,.article-body .statute-table td{width:50%;vertical-align:top;padding:20px 22px;border-color:#dce6e1;overflow-wrap:anywhere}
.article-body .statute-table td[lang="zh-CN"]{font-family:"Noto Sans SC","Microsoft YaHei",sans-serif;line-height:1.95}
.article-body .statute-table h3{font-size:18px;line-height:1.4;margin:0 0 14px;color:#174c3d}
.article-body .statute-table p{margin:0 0 14px}
.article-body .statute-table p:last-child{margin-bottom:0}
.statute-table tr[id]{scroll-margin-top:105px}
.article-body .statute-table .statute-chapter th{background:#eaf2ee;font-size:16px}
@media(max-width:768px){.article-shell--statute{padding:26px 16px}.statute-toc ul{columns:1}.statute-version,.statute-toc{padding:18px}.article-body .statute-table th,.article-body .statute-table td{padding:16px}}
@media print{.statute-parallel{overflow:visible;border:0}.article-body .statute-table{min-width:0;font-size:10pt}.article-shell--statute{padding:0;max-width:none}.statute-scroll-hint,.statute-toc{display:none}.article-body .statute-table th,.article-body .statute-table td{padding:10px}.statute-table thead{display:table-header-group}}

/* ---------------------------------------------------------------------------
   2026-10-30 补齐主站通用类
   .section-container / .section-label / .section-title / .section-desc 的主定义
   写在 index.php、about.php 等「页面级 <style>」里，主站 header.php 并未包含。
   博客页只通过 header.php 渲染，拿不到这些定义 → 列表容器铺满全屏、卡片贴边。
   这里在博客样式里自带一份，数值与 about.php / services.php 保持一致（1100px / 24px）。
   --------------------------------------------------------------------------- */
.section-container {
    max-width: 1100px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

.section-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.12) 0%, rgba(118, 75, 162, 0.12) 100%);
    color: var(--primary, #667eea);
    font-size: 13px;
    font-weight: 700;
    border-radius: 50px;
    margin-bottom: 20px;
    letter-spacing: 1px;
    border: 1px solid rgba(102, 126, 234, 0.2);
}

.section-title {
    font-size: 38px;
    font-weight: 800;
    color: var(--text-dark, #1a1a2e);
    margin-bottom: 16px;
    letter-spacing: -0.5px;
    line-height: 1.25;
}

.section-desc {
    color: var(--text-gray, #6b7280);
    font-size: 17px;
    max-width: 620px;
    margin: 0 auto;
    line-height: 1.8;
}

@media (max-width: 768px) {
    .section-container {
        padding-left: 16px;
        padding-right: 16px;
    }
}

@media (max-width: 480px) {
    .section-container {
        padding-left: 14px;
        padding-right: 14px;
    }
}

/* 博客页隐藏右下角悬浮客服：它 fixed 宽 200px + right 20px，而正文容器 1100px
   居中后两侧只剩 170px，宽屏下会压住第三列卡片 / 正文右侧。
   博客页导航已有「免费咨询」入口，这里的悬浮窗属于重复且遮挡阅读。 */
.floating-contact {
    display: none;
}
