/* ============================================================
 * blog.css v3 - 借鉴 blog.pospal.cn 的页面设计
 * 顶部轮播 + 左图右文卡片 + 侧边栏 widget + 归档 list
 * 依赖：../public/css/tokens.css
 * 调色板已统一移至 tokens.css 的 --blog-* 系列
 * ============================================================ */

/* blog 调色板已统一移至 tokens.css 的 --blog-* 系列（与 5 模板 v3 蓝紫一致） */

/* ============== 1. 覆盖 v3 按钮为蓝色 ============== */
.btn--primary {
  background: var(--blog-blue);
  color: #fff;
  border: 1px solid var(--blog-blue);
  padding: 10px 22px;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.01em;
  transition: all 200ms cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 2px rgba(22, 119, 255, 0.15);
}
.btn--primary:hover {
  background: var(--blog-blue-600);
  border-color: var(--blog-blue-600);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px -4px rgba(22, 119, 255, 0.35);
}
.btn--secondary {
  background: var(--c-surface);
  color: var(--c-text);
  border: 1px solid var(--c-border);
  padding: 8px 18px;
  border-radius: 9999px;
  font-weight: 500;
  font-size: 13px;
  transition: all 200ms;
}
.btn--secondary:hover {
  background: var(--c-surface-2);
  border-color: var(--c-text);
}

/* ============== 2. HERO 轮播（pospal 风格大背景） ============== */
.blog-hero-slider {
  position: relative;
  width: 100%;
  height: 420px;
  border-radius: 18px;
  overflow: hidden;
  margin: 32px 0 48px;
  box-shadow: 0 12px 32px -8px rgba(15, 23, 42, 0.15);
}
.blog-hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 800ms cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  padding: 0 80px;
  color: #fff;
  background-size: cover;
  background-position: center;
}
.blog-hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0) 80%);
  pointer-events: none;
}
.blog-hero-slide.is-active { opacity: 1; z-index: 1; }
.blog-hero-slide__body {
  position: relative;
  z-index: 1;
  max-width: 560px;
}
.blog-hero-slide__cat {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-bottom: 16px;
}
.blog-hero-slide__title {
  font-family: var(--f-serif);
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  line-height: 1.1;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}
.blog-hero-slide__desc {
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 24px;
  opacity: 0.95;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.blog-hero-slide__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 26px;
  background: #fff;
  color: var(--blog-blue);
  border-radius: 9999px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: all 200ms;
}
.blog-hero-slide__cta:hover {
  transform: translateX(4px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}
.blog-hero-dots {
  position: absolute;
  bottom: 24px;
  left: 80px;
  display: flex;
  gap: 8px;
  z-index: 2;
}
.blog-hero-dot {
  width: 28px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 200ms;
  border: 0;
  padding: 0;
}
.blog-hero-dot.is-active {
  background: #fff;
  width: 40px;
}
.blog-hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  border: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 200ms;
}
.blog-hero-arrow:hover { background: #fff; transform: translateY(-50%) scale(1.08); }
.blog-hero-arrow--prev { left: 20px; }
.blog-hero-arrow--next { right: 20px; }
@media (max-width: 768px) {
  .blog-hero-slider { height: 360px; }
  .blog-hero-slide { padding: 0 32px; }
  .blog-hero-dots { left: 32px; }
  .blog-hero-arrow--prev { left: 8px; }
  .blog-hero-arrow--next { right: 8px; }
}

/* ============== 3. HERO 简版（archive / category / article 用） ============== */
.blog-breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 14px;
  color: #6b7280;
  margin-bottom: 20px;
}
.blog-breadcrumb a {
  color: var(--blog-blue, #2563eb);
  text-decoration: none;
  transition: opacity .2s;
}
.blog-breadcrumb a:hover { opacity: .7; }
.blog-breadcrumb__current { color: #374151; }

.blog-hero {
  position: relative;
  padding: 96px 0 64px;
  text-align: center;
  background: linear-gradient(180deg, #FAFBFF 0%, var(--blog-purple-50) 60%, #FFFFFF 100%);
  overflow: hidden;
}
.blog-hero::before {
  content: "";
  position: absolute;
  top: -120px; right: -120px;
  width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.10) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}
.blog-hero::after {
  content: "";
  position: absolute;
  bottom: -180px; left: -150px;
  width: 560px; height: 560px;
  background: radial-gradient(circle, rgba(22, 119, 255, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}
.blog-hero > .container { position: relative; z-index: 1; }
.blog-hero__kicker {
  display: inline-block;
  padding: 8px 22px;
  background: var(--blog-blue-50);
  color: var(--blog-blue);
  border-radius: 9999px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 24px;
}
.blog-hero__title {
  font-family: var(--f-serif);
  font-size: clamp(2.25rem, 5vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.035em;
  font-weight: 600;
  color: var(--c-text);
  max-width: 900px;
  margin: 0 auto 24px;
}
.blog-hero__title em {
  font-style: italic;
  font-weight: 500;
  background: linear-gradient(135deg, var(--blog-blue) 0%, var(--blog-purple) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.blog-hero__sub {
  font-size: 1.0625rem;
  line-height: 1.8;
  color: var(--c-text-2);
  max-width: 680px;
  margin: 0 auto 32px;
}
.blog-hero__stats {
  display: flex;
  gap: 28px;
  margin-top: 28px;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 14px;
  color: var(--c-muted);
}
.blog-hero__stats b {
  font-family: var(--f-serif);
  font-size: 22px;
  font-weight: 600;
  color: var(--c-text);
  margin-right: 6px;
  display: block;
  line-height: 1;
}

/* ============== 4. 分类 tab 条（pospal 水平 tab） ============== */
.blog-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--c-border);
  margin-bottom: 32px;
  overflow-x: auto;
  scrollbar-width: none;
}
.blog-tabs::-webkit-scrollbar { display: none; }
.blog-tab {
  padding: 14px 22px;
  font-size: 15px;
  font-weight: 500;
  color: var(--c-text-2);
  cursor: pointer;
  position: relative;
  white-space: nowrap;
  transition: color 200ms;
  background: none;
  border: 0;
  font-family: inherit;
}
.blog-tab:hover { color: var(--c-text); }
.blog-tab.is-active {
  color: var(--blog-blue);
  font-weight: 700;
}
.blog-tab.is-active::after {
  content: "";
  position: absolute;
  bottom: -1px; left: 0; right: 0;
  height: 2px;
  background: var(--blog-blue);
}

/* ============== 5. 左图右文文章卡（pospal 核心借鉴） ============== */
.post-list { display: flex; flex-direction: column; }
.post-row {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
  padding: 24px 0;
  border-bottom: 1px solid var(--c-border);
  align-items: flex-start;
  color: inherit;
  text-decoration: none;
  transition: background 200ms;
}
.post-row:first-child { padding-top: 0; }
.post-row:last-child { border-bottom: 0; }
.post-row:hover { background: var(--c-surface-2); }
.post-row__cover {
  position: relative;
  aspect-ratio: 16/9;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}
.post-row__cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.18), transparent 60%);
  pointer-events: none;
}
.post-row__cover-icon {
  width: 48px; height: 48px;
  opacity: 0.95;
  position: relative;
  z-index: 1;
}
.post-row__cover-mark {
  position: absolute;
  top: 10px; left: 10px;
  background: rgba(255,255,255,0.95);
  color: var(--c-text);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  z-index: 1;
  letter-spacing: 0.02em;
  text-decoration: none;
}
.post-row__cover-mark--red    { background: var(--c-accent-red);    color: var(--c-accent-red-fg); }
.post-row__cover-mark--blue   { background: var(--c-accent-blue);   color: var(--c-accent-blue-fg); }
.post-row__cover-mark--green  { background: var(--c-accent-green);  color: var(--c-accent-green-fg); }
.post-row__cover-mark--yellow { background: var(--c-accent-yellow); color: var(--c-accent-yellow-fg); }
.post-row__cover-mark--purple { background: var(--c-accent-purple); color: var(--c-accent-purple-fg); }
/* 封面色块底色渐变（与 hero 轮播色板一致） */
.post__cover--dark   { background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%); }
.post__cover--red    { background: linear-gradient(135deg, #EF4444 0%, #DB2777 100%); }
.post__cover--yellow { background: linear-gradient(135deg, #F59E0B 0%, #EF4444 100%); }
.post__cover--blue   { background: linear-gradient(135deg, #1677FF 0%, #0891B2 100%); }
.post__cover--green  { background: linear-gradient(135deg, #10B981 0%, #0891B2 100%); }
.post__cover--purple { background: linear-gradient(135deg, #7C3AED 0%, #DB2777 100%); }
.post-row__cover-deco {
  position: absolute;
  bottom: 8px; right: 12px;
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 600;
  opacity: 0.7;
  letter-spacing: 0.05em;
  z-index: 1;
}
.post-row__body { display: flex; flex-direction: column; gap: 10px; min-height: 158px; }
.post-row__cats { display: flex; gap: 6px; align-items: center; }
.post-row__cat {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.post-row__cat--red    { background: var(--c-accent-red);    color: var(--c-accent-red-fg); }
.post-row__cat--blue   { background: var(--c-accent-blue);   color: var(--c-accent-blue-fg); }
.post-row__cat--green  { background: var(--c-accent-green);  color: var(--c-accent-green-fg); }
.post-row__cat--yellow { background: var(--c-accent-yellow); color: var(--c-accent-yellow-fg); }
.post-row__cat--purple { background: var(--c-accent-purple); color: var(--c-accent-purple-fg); }
.post-row h3 {
  font-family: var(--f-serif);
  font-size: 22px;
  line-height: 1.3;
  letter-spacing: -0.01em;
  font-weight: 600;
  color: var(--c-text);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-row__excerpt {
  font-size: 14px;
  line-height: 1.7;
  color: var(--c-text-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-row__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  color: var(--c-muted);
  margin-top: auto;
  flex-wrap: wrap;
}
.post-row__author {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--c-text-2);
  font-weight: 500;
}
.post-row__avatar {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blog-blue), var(--blog-purple));
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  flex-shrink: 0;
}
@media (max-width: 768px) {
  .post-row { grid-template-columns: 1fr; gap: 16px; }
  .post-row__body { min-height: auto; }
  .post-row h3 { font-size: 18px; }
}

/* ============== 6. 旧版 2 列 grid 卡片（保留用于 inline 相关） ============== */
.blog__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

/* ============== 7. 2 列布局（主内容 + 320px 侧栏） ============== */
.blog-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 48px;
  align-items: start;
}
@media (max-width: 1024px) {
  .blog-layout { grid-template-columns: 1fr; gap: 32px; }
}

/* ============== 8. 侧边栏 widget 体系（pospal 风格） ============== */
.blog-sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: 88px;
}
.sidebar-widget {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 0;
}
.sidebar-widget__title {
  font-family: var(--f-serif);
  font-size: 16px;
  font-weight: 600;
  color: var(--c-text);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sidebar-widget__title::before {
  content: "";
  width: 4px; height: 14px;
  background: linear-gradient(180deg, var(--blog-blue), var(--blog-purple));
  border-radius: 2px;
  flex-shrink: 0;
}
.sidebar-widget--qr {
  text-align: center;
  background: linear-gradient(135deg, var(--c-blue-50), var(--c-purple-50));
  border-color: transparent;
  padding: 24px 20px;
}
.sidebar-widget__qr {
  width: 140px; height: 140px;
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  font-size: 11px;
  color: var(--c-muted);
}
.sidebar-widget__qr--inner {
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(45deg, #ccc 25%, transparent 25%),
    linear-gradient(-45deg, #ccc 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #ccc 75%),
    linear-gradient(-45deg, transparent 75%, #ccc 75%);
  background-size: 10px 10px;
  background-position: 0 0, 0 5px, 5px -5px, -5px 0;
  border-radius: 6px;
}
.sidebar-widget__qr-text {
  font-size: 13px;
  color: var(--c-text);
  font-weight: 600;
  margin-bottom: 4px;
}
.sidebar-widget__qr-sub {
  font-size: 11px;
  color: var(--c-muted);
}
.sidebar-widget__list { list-style: none; padding: 0; margin: 0; }
.sidebar-widget__list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--c-border);
}
.sidebar-widget__list li:last-child { border-bottom: 0; padding-bottom: 0; }
.sidebar-widget__list li:first-child { padding-top: 0; }
.sidebar-widget__rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  background: var(--c-blue-50);
  color: var(--c-accent-blue-fg);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}
.sidebar-widget__link {
  display: block;
  color: var(--c-text);
  font-size: 13px;
  line-height: 1.5;
  font-weight: 500;
  text-decoration: none;
  transition: color 200ms;
}
.sidebar-widget__link:hover { color: var(--blog-blue); }
.sidebar-widget__meta { font-size: 11px; color: var(--c-muted); margin-top: 2px; }
.sidebar-widget__sub {
  display: block;
  text-align: center;
  padding: 13px;
  background: linear-gradient(135deg, var(--blog-blue) 0%, var(--blog-purple) 100%);
  color: #fff;
  border-radius: 10px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  transition: all 200ms;
}
.sidebar-widget__sub:hover { transform: translateY(-2px); box-shadow: 0 8px 20px -4px rgba(22, 119, 255, 0.3); color: #fff; }
@media (max-width: 1024px) {
  .blog-sidebar { position: static; }
}

/* ============== 9. 彩色标签网格（pospal 风格） ============== */
.tag-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-grid__tag {
  padding: 4px 11px;
  border-radius: 6px;
  font-size: 12px;
  text-decoration: none;
  background: var(--c-surface-2);
  color: var(--c-text-2);
  border: 1px solid var(--c-border);
  transition: all 200ms;
}
.tag-grid__tag--hot    { background: var(--c-accent-red);    color: var(--c-accent-red-fg);    border-color: transparent; }
.tag-grid__tag--warm   { background: var(--c-accent-yellow); color: var(--c-accent-yellow-fg); border-color: transparent; }
.tag-grid__tag--cool   { background: var(--c-accent-blue);   color: var(--c-accent-blue-fg);   border-color: transparent; }
.tag-grid__tag--green  { background: var(--c-accent-green);  color: var(--c-accent-green-fg);  border-color: transparent; }
.tag-grid__tag--purple { background: var(--c-accent-purple); color: var(--c-accent-purple-fg); border-color: transparent; }
.tag-grid__tag:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-1);
  color: var(--c-text);
}

/* ============== 10. 归档 list（按月分组，横向 list） ============== */
.archive-group { margin-bottom: 56px; }
.archive-group__title {
  font-family: var(--f-serif);
  font-size: 24px;
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--c-text);
  display: inline-block;
}
.archive-count {
  font-family: var(--f-sans);
  font-size: 14px;
  font-weight: 400;
  color: var(--c-muted);
  margin-left: 8px;
}

/* ============== 11. 文章详情页（article.html） ============== */
.article-layout > .container {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 48px;
  align-items: start;
}
@media (max-width: 1024px) {
  .article-layout > .container { grid-template-columns: 1fr; gap: 32px; }
}
.blog-toc {
  position: sticky;
  top: 96px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  padding: 20px 22px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: 14px;
}
.blog-toc__title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-serif);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--c-muted);
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--c-border);
}
.blog-toc__nav ol { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.blog-toc__nav li { counter-increment: toc; margin-bottom: 4px; }
.blog-toc__nav a {
  display: block;
  padding: 7px 10px 7px 30px;
  font-size: 13px;
  line-height: 1.4;
  color: var(--c-text-2);
  text-decoration: none;
  border-radius: 6px;
  position: relative;
  transition: all 200ms;
}
.blog-toc__nav a::before {
  content: counter(toc, decimal-leading-zero);
  position: absolute;
  left: 8px; top: 7px;
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--c-muted);
}
.blog-toc__nav a:hover { background: var(--c-blue-50); color: var(--c-accent-blue-fg); }
.blog-toc__nav a.is-active {
  background: linear-gradient(135deg, var(--blog-blue), var(--blog-purple));
  color: #fff;
  font-weight: 600;
}
.blog-toc__nav a.is-active::before { color: rgba(255,255,255,0.7); }
@media (max-width: 1024px) {
  .blog-toc { position: static; max-height: none; }
}

/* ============== 12. 作者卡片 ============== */
.author-card {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  max-width: 720px;
  margin: 56px auto 0;
  padding: 24px 28px;
  background: linear-gradient(135deg, rgba(22,119,255,0.04), rgba(124,58,237,0.04));
  border: 1px solid var(--c-border);
  border-radius: 14px;
}
.author-card__avatar {
  flex-shrink: 0;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blog-blue), var(--blog-purple));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}
.author-card__body { flex: 1; }
.author-card__name {
  font-family: var(--f-serif);
  font-size: 18px;
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.author-card__role {
  font-family: var(--f-sans);
  font-size: 11px;
  font-weight: 500;
  padding: 3px 10px;
  background: var(--c-blue-50);
  color: var(--c-accent-blue-fg);
  border-radius: 9999px;
  letter-spacing: 0.04em;
}
.author-card__bio {
  font-size: 14px;
  line-height: 1.7;
  color: var(--c-text-2);
  margin: 0 0 12px;
}
.author-card__meta {
  display: flex;
  gap: 18px;
  font-size: 13px;
  color: var(--c-muted);
}
.author-card__meta b {
  font-family: var(--f-serif);
  font-size: 16px;
  font-weight: 600;
  color: var(--c-text);
  margin-right: 4px;
}
@media (max-width: 640px) {
  .author-card { flex-direction: column; align-items: center; text-align: center; padding: 20px; }
  .author-card__name { justify-content: center; }
  .author-card__meta { justify-content: center; flex-wrap: wrap; gap: 12px; }
}

/* ============== 13. article body 衬线标题 ============== */
.article-body {
  max-width: 720px;
  margin: 0 auto;
  font-size: 1.0625rem;
  line-height: var(--lh-loose);
  color: var(--c-text-2);
}
.article-body h2 {
  font-family: var(--f-serif);
  font-size: var(--fs-h2);
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 600;
  color: var(--c-text);
  margin: 64px 0 24px;
  padding-top: 16px;
  border-top: 1px solid var(--c-border);
}
.article-body h2:first-child { border-top: 0; padding-top: 0; }
.article-body h3 {
  font-family: var(--f-serif);
  font-size: var(--fs-h3);
  font-weight: 600;
  color: var(--c-text);
  margin: 40px 0 16px;
}
.article-body p { margin: 0 0 20px; }
.article-body b { color: var(--c-text); font-weight: 600; }
.article-body ul, .article-body ol { padding-left: 24px; margin: 0 0 20px; }
.article-body li { margin-bottom: 8px; }
/* ============== 表格（GFM markdown table 渲染）============== */
.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 14px;
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.article-body th,
.article-body td {
  padding: 10px 14px;
  border: 1px solid var(--c-border);
  text-align: left;
  vertical-align: top;
  line-height: 1.6;
}
.article-body th {
  font-weight: 600;
  background: var(--c-surface-2);
  white-space: nowrap;
}
.article-body tbody tr:nth-child(even) {
  background: var(--c-surface-2);
}
.article-body code {
  background: var(--c-surface-2);
  padding: 2px 7px;
  border-radius: 4px;
  font-family: var(--f-mono);
  font-size: 0.88em;
  color: var(--c-accent-red-fg);
}
.article-body pre {
  background: #1F2937;
  color: #E9EAF3;
  padding: 24px;
  border-radius: 12px;
  overflow-x: auto;
  margin: 24px 0;
  font-family: var(--f-mono);
  font-size: 14px;
  line-height: 1.7;
  border: 1px solid rgba(255,255,255,0.08);
  position: relative;
}
.article-body pre[class*="language-"]::before {
  content: attr(class);
  position: absolute;
  top: 8px; right: 14px;
  font-family: var(--f-sans);
  font-size: 10px;
  font-weight: 600;
  color: rgba(255,255,255,0.3);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.article-body pre code {
  background: transparent;
  color: inherit;
  padding: 0;
  font-size: inherit;
}

/* ============== 14. hero meta + share + related ============== */
.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  font-size: 13px;
  color: var(--c-muted);
  margin-top: 20px;
  justify-content: center;
}
.hero__meta b {
  font-family: var(--f-serif);
  font-size: 18px;
  font-weight: 600;
  color: var(--c-text);
  margin-right: 4px;
  line-height: 1;
}
.hero__meta span { display: inline-flex; align-items: baseline; }
.hero__meta-date {
  font-family: var(--f-sans);
  font-size: 13px;
  font-weight: 400;
  color: var(--c-muted);
}
.share-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin: 56px 0 0;
  padding: 20px 0 0;
  border-top: 1px solid var(--c-border);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}
.share-bar strong { font-size: 14px; color: var(--c-text-2); margin-right: 4px; }
.related-section {
  margin-top: 64px;
  padding-top: 48px;
  border-top: 1px solid var(--c-border);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}
.related-section .blog__grid { margin-top: 24px; gap: 20px; }
.blog__more { margin: 48px 0 0; text-align: center; }

/* ============== 15. Nav active/hover 蓝色高亮 ============== */
.site-nav a { color: var(--c-text-2); transition: color var(--transition); }
.site-nav a:hover, .site-nav a.is-active { color: var(--blog-blue); font-weight: 700; }

/* ============== 16. 响应式 ============== */
@media (max-width: 1024px) { .blog-sidebar { position: static; } }
@media (max-width: 768px) {
  .blog-hero { padding: 64px 0 48px; }
  .blog-hero__title { font-size: 30px; }
  .blog__grid { grid-template-columns: 1fr; gap: 20px; }
  .article-body h2 { font-size: 24px; margin-top: 48px; }
}

/* ============== 17. 媒体扩展（封面图 / 视频 / 视频号卡片） ============== */
/* 详情页 hero 封面图（coverImage 提供时替代纯文字 hero） */
.blog-hero__cover {
  width: 100%;
  max-height: 360px;
  object-fit: cover;
  border-radius: 12px;
  margin: 0 auto 16px;
  display: block;
}
/* 详情页正文上方视频播放器（video 字段，mp4 直接播放，poster 用 coverImage） */
.article-video {
  width: 100%;
  max-height: 480px;
  border-radius: 12px;
  margin: 0 0 24px;
  background: #000;
  box-shadow: 0 8px 24px rgba(0,0,0,0.14);
  display: block;
}
/* 详情页视频号文字卡（wechatVideo 为非链接文案时） */
.wechat-video-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px 20px;
  margin: 0 0 24px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(7,193,96,0.13), rgba(7,193,96,0.07));
  border: 1px solid rgba(7,193,96,0.27);
}
.wechat-video-card__badge { font-size: 13px; color: #07c160; font-weight: 600; }
.wechat-video-card__text { color: var(--c-muted, #666); margin: 0; line-height: 1.6; }
/* 视频号嵌入卡片（http 链接 -> 封面图 + 播放按钮，点击跳转微信播放，视觉接近直接播放） */
.wechat-video-card--embed {
  display: block;
  margin: 0 0 24px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.14);
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.wechat-video-card--embed:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(0,0,0,0.2); }
.wechat-video-card__thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #07c160, #0a8a45);
}
.wechat-video-card__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.wechat-video-card__thumb-fallback { width: 100%; height: 100%; }
.wechat-video-card__play {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 68px; height: 68px;
  border-radius: 50%;
  background: rgba(0,0,0,0.55);
  color: #fff; font-size: 26px;
  display: flex; align-items: center; justify-content: center;
  padding-left: 4px;
  transition: transform 0.2s ease, background 0.2s ease;
}
.wechat-video-card--embed:hover .wechat-video-card__play {
  transform: translate(-50%, -50%) scale(1.12);
  background: rgba(7,193,96,0.92);
}
.wechat-video-card__thumb .wechat-video-card__badge {
  position: absolute; top: 12px; left: 12px;
  background: rgba(0,0,0,0.6); color: #fff;
  padding: 3px 10px; border-radius: 4px;
  font-size: 12px; font-weight: 600;
}
.wechat-video-card__meta {
  display: flex; justify-content: space-between; align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--c-surface);
}
.wechat-video-card__title {
  font-weight: 600; color: var(--c-text, #1a1a1a);
  font-size: 15px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.wechat-video-card__cta { color: #07c160; font-size: 13px; font-weight: 600; white-space: nowrap; }
/* 列表/相关文章封面图模式（PostCover image prop 提供时替代色块） */
.post-row__cover--image { overflow: hidden; }
.post-row__cover--image img { width: 100%; height: 100%; object-fit: cover; }