:root {
  --content-page-bg: linear-gradient(160deg, #fff8f1 0%, #f7e8d7 52%, #f1d8bc 100%);
  --content-panel-bg: rgba(255, 251, 245, 0.92);
  --content-panel-border: rgba(175, 129, 90, 0.14);
  --content-text-main: #5a3924;
  --content-text-muted: #8d6d56;
  --content-link: #e08a4e;
  --content-link-hover: #c96f37;
  --shadow-soft: 0 20px 45px rgba(140, 95, 56, 0.16);
}

body.content-page {
  margin: 0;
  min-height: 100vh;
  font-family: "Trebuchet MS", "Avenir Next", sans-serif;
  color: var(--content-text-main);
  /* 统一白色页面背景(与全站一致) */
  background: #ffffff;
}

.content-page a {
  color: var(--content-link);
}

.content-page a:hover {
  color: var(--content-link-hover);
}

.content-shell.page-shell {
  width: min(100%, 860px);
  margin: 0 auto;
  padding: 0 18px 48px;
}

.page-blog-index .content-shell.page-shell {
  width: min(100%, 980px);
}
.page-blog-article .content-shell.page-shell {
  width: min(100%, 720px);
}

.page-card,
.article-card {
  padding: 32px;
  border-radius: 28px;
  background: var(--content-panel-bg);
  border: 1px solid var(--content-panel-border);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(10px);
}

.page-blog-article .article-card {
  padding: 34px 40px;
  background: #ffffff;
  backdrop-filter: none;
}

.eyebrow {
  margin: 0 0 8px;
  color: #c4753c;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.eyebrow:empty {
  display: none;
}

.content-page h1,
.content-page h2,
.content-page h3 {
  margin: 0;
}

.content-page h1 {
  font-size: clamp(2.35rem, 5vw, 4rem);
  line-height: 0.95;
}

/* Blog 标题统一规则：所有 blog 页（英文 + 多语言）共用 */
.page-blog-index h1,
.page-blog-article h1 {
  font-size: clamp(2rem, 4.6vw, 3.35rem);
  line-height: 1.02;
  white-space: normal;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.page-static .content-page h1,
.page-static h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 1.05;
  white-space: normal;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.content-page h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin-bottom: 12px;
}

.content-page h3 {
  font-size: 1.08rem;
  margin-bottom: 8px;
}

.intro,
.lede,
.meta-line,
.content-page p,
.content-page li {
  color: var(--content-text-muted);
  line-height: 1.7;
}

.intro {
  margin: 16px 0 0;
  font-size: 1rem;
}

.lede {
  margin: 18px 0 0;
  font-size: 1.03rem;
  line-height: 1.75;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.meta-pill {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 249, 241, 0.96);
  border: 1px solid rgba(195, 152, 114, 0.18);
  color: var(--content-text-muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.section {
  margin-top: 32px;
}

.section:first-of-type {
  margin-top: 28px;
}

.content-page ul,
.content-page ol {
  margin: 14px 0 0;
  padding-left: 22px;
}

.content-page li + li {
  margin-top: 8px;
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.post-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px;
  border-radius: 24px;
  background: rgba(255, 246, 236, 0.92);
  border: 1px solid rgba(195, 152, 114, 0.18);
  text-decoration: none;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.post-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px rgba(140, 95, 56, 0.14);
}

.post-card h3 {
  color: var(--content-text-main);
}

.post-card p,
.post-card .post-meta {
  margin: 0;
}

.post-meta {
  font-size: 0.84rem;
  color: #b17245;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.faq-list {
  display: grid;
  gap: 18px;
  margin-top: 20px;
}

.faq-item {
  padding: 20px 22px;
  border-radius: 20px;
  background: rgba(255, 246, 236, 0.92);
  border: 1px solid rgba(195, 152, 114, 0.18);
}

.faq-item p {
  margin: 10px 0 0;
}

.nav-row,
.cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.nav-link,
.pill-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border-radius: 999px;
  text-decoration: none;
  background: rgba(255, 249, 241, 0.96);
  border: 1px solid rgba(195, 152, 114, 0.18);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  color: var(--content-link);
  font-weight: 700;
}

.nav-link:hover,
.pill-link:hover {
  color: var(--content-link-hover);
}

.inline-table {
  width: 100%;
  margin-top: 16px;
  border-collapse: collapse;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255, 248, 240, 0.94);
}

.inline-table th,
.inline-table td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(195, 152, 114, 0.16);
  text-align: left;
  vertical-align: top;
}

.inline-table th {
  color: var(--content-text-main);
  font-size: 0.9rem;
}

.inline-table td {
  color: var(--content-text-muted);
  font-size: 0.92rem;
}

/* ========== Blog 文章页扩展元素（迁自原英文 inline 样式） ========== */

/* 目录框（toc）：用于教程类长文 */
.page-blog-article .toc {
  margin-top: 24px;
  padding: 22px;
  border-radius: 24px;
  background: rgba(255, 247, 238, 0.95);
  border: 1px solid rgba(195, 152, 114, 0.16);
}
.page-blog-article .toc h2 {
  font-size: 1.18rem;
  margin-bottom: 12px;
}
.page-blog-article .toc ol {
  margin: 0;
  padding-left: 22px;
}
.page-blog-article .toc a {
  color: var(--content-link);
  text-decoration: none;
}
.page-blog-article .toc a:hover {
  color: var(--content-link-hover);
}

/* 提示框 / CTA 框 / 相关链接框：共享外观 */
.page-blog-article .tip-box,
.page-blog-article .cta-box,
.page-blog-article .related-box {
  margin-top: 24px;
  padding: 22px;
  border-radius: 24px;
  background: rgba(255, 245, 234, 0.95);
  border: 1px solid rgba(195, 152, 114, 0.16);
}
.page-blog-article .tip-box h3,
.page-blog-article .cta-box h3,
.page-blog-article .related-box h3 {
  font-size: 1.12rem;
  margin-bottom: 10px;
}

/* CTA 按钮（橙色实心按钮） */
.page-blog-article .cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 14px;
  padding: 12px 20px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
  color: #fff8f0;
  background: var(--content-link);
  box-shadow: 0 12px 24px rgba(224, 138, 78, 0.24);
}
.page-blog-article .cta-button:hover {
  background: var(--content-link-hover);
}

/* 主题卡片（用于 best-2048-themes-2026 等横评类） */
.page-blog-article .theme-card {
  margin-top: 18px;
  padding: 22px;
  border-radius: 22px;
  background: rgba(255, 249, 241, 0.96);
  border: 1px solid rgba(195, 152, 114, 0.18);
}
.page-blog-article .theme-card h3 {
  font-size: 1.18rem;
  margin-bottom: 8px;
}

/* 决策框（"按以下方式选第一个主题"） */
.page-blog-article .decision-box {
  margin-top: 22px;
  padding: 22px;
  border-radius: 22px;
  background: rgba(255, 245, 234, 0.95);
  border: 1px solid rgba(195, 152, 114, 0.16);
}
.page-blog-article .decision-box h3 {
  font-size: 1.12rem;
  margin-bottom: 10px;
}
.page-blog-article .decision-box ul {
  margin: 0;
  padding-left: 22px;
}

/* 表格容器（用于 math-playground 对比表，移动端可横向滚动） */
.page-blog-article .table-wrap {
  margin-top: 18px;
  overflow-x: auto;
  border-radius: 18px;
  background: rgba(255, 248, 240, 0.94);
}
.page-blog-article .table-wrap table {
  width: 100%;
  border-collapse: collapse;
}
.page-blog-article .table-wrap th,
.page-blog-article .table-wrap td {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(195, 152, 114, 0.16);
  text-align: left;
}
.page-blog-article .table-wrap th {
  background: rgba(255, 245, 234, 0.95);
  color: var(--content-text-main);
}

/* 列表页博文卡片的标签（如 "General Strategy"） */
.page-blog-index .post-kicker {
  display: inline-block;
  margin-bottom: 8px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(224, 138, 78, 0.16);
  color: var(--content-link);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* 列表页学习要点清单 */
.page-blog-index .topic-list {
  margin: 14px 0 0;
  padding-left: 22px;
}

@media (max-width: 768px) {
  .content-shell.page-shell {
    padding: 0 14px 40px;
  }

  .page-card,
  .article-card {
    padding: 24px 20px;
    border-radius: 24px;
  }

  .post-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== 博客嵌入游戏 + Play CTA (T4 漏斗) ===== */
.blog-game-embed {
  margin: 22px auto 30px;
  text-align: center;
}
.article-card .blog-play-cta {
  display: inline-block;
  margin-bottom: 12px;
  padding: 13px 28px;
  font-weight: 800;
  font-size: 1.05rem;
  line-height: 1;
  color: #fff;
  background: #e08a4e;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 6px 16px rgba(224, 138, 78, 0.34);
  transition: transform 0.12s ease, filter 0.12s ease;
}
.article-card .blog-play-cta:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
  color: #fff;
}
.blog-game-frame {
  display: block;
  width: 100%;
  max-width: 460px;
  height: 640px;
  margin: 0 auto;
  border: 0;
  border-radius: 18px;
  background: #faf8f5;
  box-shadow: 0 10px 30px rgba(90, 57, 36, 0.12);
}
@media (max-width: 520px) {
  .blog-game-frame {
    height: 580px;
  }
}
.article-card .blog-bottom-cta {
  text-align: center;
  margin: 28px 0 6px;
}
/* ===== 博客文章面包屑(T-A 阅读体验)===== */
.blog-breadcrumb {
  margin: 0 auto 14px;
  padding: 0 6px;
  font-size: 0.85rem;
  color: var(--content-text-muted);
  line-height: 1.5;
}
.blog-breadcrumb a {
  color: var(--content-text-muted);
  text-decoration: none;
}
.blog-breadcrumb a:hover {
  color: var(--content-link);
  text-decoration: underline;
}
.blog-breadcrumb .bc-sep {
  margin: 0 7px;
  opacity: 0.55;
}
.blog-breadcrumb .bc-current {
  color: var(--content-text-main);
  font-weight: 600;
}
/* ===== B: 文章上部"玩更多主题"图标条(内链上移 + 主题预览图当图标)===== */
.blog-theme-strip {
  margin: 4px auto 26px;
}
.blog-theme-strip-title {
  margin: 0 0 12px;
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--content-text-muted);
  text-align: center;
}
.blog-theme-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}
.article-card .blog-theme-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 84px;
  text-decoration: none;
  color: var(--content-text-main);
  font-size: 0.74rem;
  font-weight: 700;
  text-align: center;
  transition: transform 0.14s ease, color 0.14s ease;
}
.article-card .blog-theme-chip:hover {
  transform: translateY(-3px);
  color: var(--content-link);
}
.blog-theme-chip img {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(90, 57, 36, 0.14);
  border: 1px solid rgba(175, 129, 90, 0.18);
}
.blog-theme-chip span {
  line-height: 1.2;
}
/* ===== C: 博客首页"玩任意主题"游戏瓦片网格 ===== */
.blog-theme-hub {
  margin: 34px 0 10px;
  padding: 26px 24px 22px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 244, 228, 0.55), rgba(255, 250, 242, 0.3));
  border: 1px solid rgba(175, 129, 90, 0.16);
}
.blog-theme-hub-title {
  margin: 0 0 6px;
  text-align: center;
  font-size: 1.3rem;
}
.blog-theme-hub-sub {
  margin: 0 auto 22px;
  max-width: 560px;
  text-align: center;
  font-size: 0.92rem;
  color: var(--content-text-muted);
  line-height: 1.5;
}
.blog-grid-chips {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px 10px;
}
.blog-theme-hub .blog-grid-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  text-decoration: none;
  color: var(--content-text-main);
  font-size: 0.76rem;
  font-weight: 700;
  text-align: center;
  transition: transform 0.14s ease, color 0.14s ease;
}
.blog-theme-hub .blog-grid-chip:hover {
  transform: translateY(-3px);
  color: var(--content-link);
}
/* D: variations hub 页(page-static)的网格更宽松,主题更多 */
.variants-hub {
  margin-top: 8px;
}
.variants-hub .blog-grid-chips {
  gap: 22px 10px;
}
/* variants 页 Size 选择器(尺寸在上、主题在下)*/
.variants-size-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin: 2px 0 24px;
}
.variants-size-bar-label {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--content-text-muted);
}
.variants-size-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.variants-size-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  padding: 8px 14px;
  border-radius: 12px;
  border: 1px solid rgba(175, 129, 90, 0.28);
  background: rgba(255, 244, 228, 0.5);
  color: var(--content-text-main);
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.14s ease, color 0.14s ease, transform 0.14s ease;
}
.variants-size-btn:hover {
  background: var(--content-link, #c4753c);
  color: #fff;
  transform: translateY(-2px);
}
/* 旧版还原:Size 选择器 = 药丸按钮 + N×N 网格图案,选中态高亮(选尺寸→再点主题才跳)*/
.variants-size-opts {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 20px 0 28px;
}
.variants-size-opt {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--content-text-main);
  background: transparent;
  border: 1.5px solid rgba(160, 116, 75, 0.35);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  transition: background 0.14s ease, border-color 0.14s ease, color 0.14s ease;
}
.variants-size-opt:hover {
  background: rgba(255, 240, 224, 0.6);
  border-color: var(--content-link, #c4753c);
}
.variants-size-ico {
  width: 30px;
  height: 30px;
  border-radius: 7px;
  flex: none;
  background-color: rgba(255, 255, 255, 0.5);
  border: 1.5px solid rgba(160, 116, 75, 0.5);
  background-image:
    linear-gradient(to right, rgba(160, 116, 75, 0.34) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(160, 116, 75, 0.34) 1px, transparent 1px);
  background-size: calc(100% / var(--n)) calc(100% / var(--n));
}
.variants-size-opt.is-selected {
  background: var(--content-link, #c4753c);
  border-color: var(--content-link, #c4753c);
  color: #fff8f0;
}
.variants-size-opt.is-selected .variants-size-ico {
  border-color: rgba(255, 248, 240, 0.6);
  background-color: rgba(255, 255, 255, 0.18);
  background-image:
    linear-gradient(to right, rgba(255, 248, 240, 0.45) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 248, 240, 0.45) 1px, transparent 1px);
}
/* 选中尺寸后,该尺寸无对应组合页的主题卡灰显不可点 */
.blog-grid-chip.is-soon {
  opacity: 0.4;
  pointer-events: none;
}
.blog-grid-chip img {
  width: 72px;
  height: 72px;
  border-radius: 16px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(90, 57, 36, 0.14);
  border: 1px solid rgba(175, 129, 90, 0.18);
}
.blog-grid-chip span {
  line-height: 1.2;
}
.blog-theme-hub-all {
  margin: 22px 0 0;
  text-align: center;
}
.blog-theme-hub-all a {
  font-weight: 800;
  font-size: 0.92rem;
  text-decoration: none;
  color: var(--content-link);
}
.blog-theme-hub-all a:hover {
  text-decoration: underline;
}
@media (max-width: 640px) {
  .blog-grid-chips {
    grid-template-columns: repeat(4, 1fr);
    gap: 14px 6px;
  }
  .blog-grid-chip img {
    width: 60px;
    height: 60px;
  }
}
@media (max-width: 380px) {
  .blog-grid-chips {
    grid-template-columns: repeat(3, 1fr);
  }
}
