/* 图片容器居中（适用于 figure 或自定义 .post-image--center）*/
/* 兼容 Volantis：正文容器为 #post-body */
.post-content figure,
#post-body figure,
.post-content .post-image--center,
.post-image--center {
  text-align: center;
  margin: 1.2em 0;
}

/* 图片基本样式，保证响应式 */
.post-content figure img,
#post-body figure img,
.post-content .post-image--center img,
.post-image--center img {
  max-width: 100%;
  height: auto;
  display: inline-block;
}

/* caption / 描述文字样式（灰色、小字号、居中） */
.post-content figure figcaption,
#post-body figure figcaption,
.post-image--center figcaption,
.post-content .post-image--center .figure-caption,
.post-content .figure-caption {
  color: #777;                /* 灰色文字 */
  font-size: 0.9rem;          /* 略小字号 */
  margin-top: 0.4rem;
  line-height: 1.4;
  text-align: center;
}

/* =========================
   LXGW Neo XiHei 字体接入
   ========================= */
/*
  使用方式：
  1. 将以下文件放入 source/fonts/ 目录（推荐 woff2）：
     - LXGWNeoXiHei-Regular.woff2 （或相应命名）
     - LXGWNeoXiHei-Bold.woff2    （可选）
  2. 保持本 @font-face 的 URL 指向 /fonts/...，Cloudflare/Hexo 会自动部署到 /fonts/。
  3. 若使用 CDN（如 jsDelivr），可把 url('/fonts/..') 替换为 CDN 链接。
*/
@font-face {
  font-family: 'LXGW Neo XiHei';
  /* 仅使用 TTF，避免浏览器优先选择 woff2 后不回退 */
  src: url('/fonts/LXGWNeoXiHei.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'LXGW Neo XiHei';
  /* 若无独立 Bold 文件，则同样指向 Regular TTF，由浏览器合成粗体 */
  src: url('/fonts/LXGWNeoXiHei.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* 统一站点与文章的无衬线字体（不影响代码块/图标） */
:root {
  --font-sans-cn: 'LXGW Neo XiHei', 'PingFang SC', 'Microsoft YaHei', 'Noto Sans CJK SC', 'Hiragino Sans GB', 'Source Han Sans SC', 'WenQuanYi Micro Hei', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, 'Segoe UI Emoji', 'Apple Color Emoji', 'Noto Color Emoji', sans-serif;
}

html, body {
  /* 直接声明族名在最前，确保触发加载；变量作为后备 */
  font-family: 'LXGW Neo XiHei', var(--font-sans-cn), 'PingFang SC', 'Microsoft YaHei', 'Noto Sans CJK SC', 'Hiragino Sans GB', 'Source Han Sans SC', 'WenQuanYi Micro Hei', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, 'Segoe UI Emoji', 'Apple Color Emoji', 'Noto Color Emoji', sans-serif !important;
}

/* 文章主体与标题使用新字体 */
#post-body,
.article,
.article .header .title,
.article h1, .article h2, .article h3, .article h4, .article h5, .article h6,
#post-body h1, #post-body h2, #post-body h3, #post-body h4, #post-body h5, #post-body h6 {
  font-family: 'LXGW Neo XiHei', var(--font-sans-cn), 'PingFang SC', 'Microsoft YaHei', 'Noto Sans CJK SC', 'Hiragino Sans GB', 'Source Han Sans SC', 'WenQuanYi Micro Hei', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, 'Segoe UI Emoji', 'Apple Color Emoji', 'Noto Color Emoji', sans-serif !important;
}

/* 导航与菜单文字（避免影响 Font Awesome 图标） */
.navbar, .menu, .menu a, .site-brand, .site-title, .site-subtitle {
  font-family: 'LXGW Neo XiHei', var(--font-sans-cn), 'PingFang SC', 'Microsoft YaHei', 'Noto Sans CJK SC', 'Hiragino Sans GB', 'Source Han Sans SC', 'WenQuanYi Micro Hei', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, 'Segoe UI Emoji', 'Apple Color Emoji', 'Noto Color Emoji', sans-serif !important;
}

/* 保留代码/等宽字体栈，不被覆盖 */
code, pre, kbd, samp {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace !important;
}