/* 博客页样式：与店面版式解耦。
   ——博客页是独立静态 HTML，不逐套版式做设计；这套通用样式让文章好读、
      链接可点、列表整齐。站点品牌色由构建期注入（--green）。 */

:root {
  --green: #4a7c59;
  --text: #2b2723;
  --muted: #7a736a;
  --line: #e5e0d8;
  --bg: #faf8f4;
  --surface: #ffffff;
  --radius: 12px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
}

a { color: var(--green); }

.blog-head {
  /* 和店面顶栏一致：文章页滚到哪儿，返回店铺的入口都在顶上。 */
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 6%;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.blog-head .brand {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: .01em;
}
.blog-nav { display: flex; gap: 18px; font-size: 14px; }
.blog-nav a { color: var(--muted); text-decoration: none; }
.blog-nav a:hover { color: var(--green); }

.blog-main { max-width: 780px; margin: 0 auto; padding: 48px 20px 72px; }
.eyebrow {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .14em;
  color: var(--green);
  text-transform: uppercase;
}
.blog-title { margin: 0 0 8px; font-family: Georgia, "Times New Roman", serif; font-size: 34px; font-weight: 400; line-height: 1.2; }
.blog-lede { margin: 0 0 36px; color: var(--muted); font-size: 15px; }

.blog-list { display: grid; gap: 22px; }
.blog-card {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 20px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: box-shadow .15s ease;
}
.blog-card:hover { box-shadow: 0 4px 18px rgba(0,0,0,.07); }
.blog-card-cover { width: 100%; height: 100%; min-height: 140px; object-fit: cover; }
/* 没有上传封面时的图位：和首页卡片那张插画占位一个意思——占住位置、看着像配图，
   而不是塌成一条空白。真图一上传就被 <img> 顶掉，不用改别的。
   画的是一轮日头加一道地平线：纯 CSS，不引插画代码（那是 app.js 里的 MOTIFS，
   构建期拿不到），所以任何版式下都有东西可看，不是一块糊的灰。 */
.blog-card-cover-art, .post-cover-art {
  position: relative;
  display: block;
  overflow: hidden;
  background:
    radial-gradient(120px 90px at 30% 26%, rgba(0,0,0,.07), transparent 70%),
    radial-gradient(90px 70px at 78% 84%, rgba(0,0,0,.05), transparent 70%),
    var(--surface, #efece6);
}
/* 日头偏右上、地平线压平：正中间一个圆加下方一团会被看成「头像占位图标」，
   那反而更像图裂了。偏一点、平一点，读起来是风景。 */
.blog-card-cover-art::before, .post-cover-art::before {
  content: "";
  position: absolute;
  left: 62%;
  top: 16%;
  width: 21%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: rgba(0,0,0,.09);
}
.blog-card-cover-art::after, .post-cover-art::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 40%;
  background: rgba(0,0,0,.075);
  clip-path: polygon(0 68%, 22% 40%, 44% 62%, 66% 32%, 88% 58%, 100% 46%, 100% 100%, 0 100%);
}
.blog-card-body { padding: 18px 20px 16px; }
.blog-card-date { margin: 0 0 6px; font-size: 12px; color: var(--muted); }
.blog-card-body h2 { margin: 0 0 8px; font-size: 19px; line-height: 1.3; }
.blog-card-excerpt { margin: 0 0 12px; font-size: 14px; color: var(--muted); }
.blog-card-more { font-size: 13px; color: var(--green); font-weight: 600; }

/* 文章详情 */
.blog-card-date { margin: 0 0 8px; font-size: 12px; color: var(--muted); }
.post-title { margin: 0 0 20px; font-family: Georgia, "Times New Roman", serif; font-size: 32px; font-weight: 400; line-height: 1.25; }
.post-cover { width: 100%; max-height: 420px; object-fit: cover; border-radius: var(--radius); margin: 0 0 26px; }
.post-cover-art { height: 220px; max-height: 220px; }
.post-body { font-size: 16.5px; }
.post-body h1, .post-body h2, .post-body h3 { font-family: Georgia, "Times New Roman", serif; font-weight: 400; line-height: 1.3; margin: 1.6em 0 .6em; }
.post-body h2 { font-size: 24px; }
.post-body h3 { font-size: 20px; }
.post-body p { margin: 0 0 1.1em; }
.post-body ul, .post-body ol { margin: 0 0 1.1em; padding-left: 1.4em; }
.post-body blockquote { margin: 1.2em 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--green); color: var(--muted); }
.post-body img { max-width: 100%; height: auto; border-radius: var(--radius); }
/* 正文配图。图片本身由 AI 生成为 3:2，读列宽度铺满即可；`figure` 自己带上下留白，
   免得和上一个段落的 `margin-bottom` 叠成一条空档。 */
.post-body figure { margin: 1.9em 0; }
.post-body figure img { margin: 0; }
.post-body figcaption { margin-top: 9px; font-size: 13px; line-height: 1.5; color: var(--muted); text-align: center; }
.post-body pre { overflow-x: auto; padding: 14px 16px; border-radius: var(--radius); background: #f2efe9; font-size: 14px; }
.post-body code { font-family: "SF Mono", Consolas, Menlo, monospace; font-size: .9em; }
.post-body hr { border: none; border-top: 1px solid var(--line); margin: 1.8em 0; }
.post-body a { text-decoration: underline; }

.blog-foot {
  padding: 26px 6%;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 13px;
  color: var(--muted);
}
.blog-foot a { color: var(--muted); }

@media (max-width: 640px) {
  .blog-card { grid-template-columns: 1fr; }
  .blog-card-cover { max-height: 180px; }
  .blog-main { padding: 32px 16px 56px; }
  .blog-title { font-size: 28px; }
  .post-title { font-size: 26px; }
}
