:root {
  /* 正文混搭字体：英文 JetBrains Mono + 中文 fallback */
  --md-text-font:
    /* "JetBrains Mono", */
    "Noto Serif SC",
    "Noto Sans CJK SC",
    "Noto Sans SC",
    "PingFang SC",
    "Microsoft YaHei",
    sans-serif;

  /* 代码字体 */
  --md-code-font:
    "JetBrains Mono",
    "Noto Serif SC",
    "Noto Sans Mono CJK SC",
    monospace;

}





/* ===== Mermaid 居中 ===== */
.mermaid {
  display: block;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  max-width: 100%;
}

/* ===== 可选：让 Mermaid 图在深色/浅色主题下更协调 ===== */
/* Material 会自动切换 body[data-md-color-scheme="slate"] (深色) 和 default (浅色) */
[data-md-color-scheme="slate"] .mermaid {
  filter: brightness(0.9);
}

.row {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
}

.row .right {
  margin-left: auto;
  white-space: nowrap;
  font-size: 0.85em;
  color: var(--md-default-fg-color--light);
}

.text-image-row {
  display: flex;
  align-items: flex-start;
  /* 或 center，看你喜好 */
  gap: 16px;
  /* 文字和图片之间的间距 */
}

.text-image-row .text-part {
  flex: 1;
  /* 文字占满左侧剩余空间 */
}

.text-image-row .image-part img {
  max-width: 260px;
  /* 控制图片宽度 */
  height: auto;
}

/* 小屏（手机）优化 */

@media (max-width: 768px) {
  .text-image-row {
    flex-direction: column;
    /* 改成上下排布 */
    align-items: stretch;
    /* 文字占满整行 */
  }

  .text-image-row .text-part {
    flex: none;
  }

  .text-image-row .image-part {
    text-align: center;
    /* 图片居中，可选 */
  }

  .text-image-row .image-part img {
    max-width: 100%;
    /* 图片宽度跟随屏幕 */
    height: auto;
  }
}