:root {
  --bg: #f6f6f3;
  --paper: #ffffff;
  --ink: #111111;
  --text: #333333;
  --muted: #7b7b80;
  --line: #e2e2dc;
  --accent: #c40012;
  --soft: #efefea;
  --shadow: 0 18px 60px rgba(0, 0, 0, .08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
}

a { color: inherit; text-decoration: none; }

.blog-shell {
  min-height: 100vh;
}

.blog-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .88);
  border-bottom: 1px solid rgba(0, 0, 0, .06);
  backdrop-filter: blur(18px);
}

.blog-topbar__inner {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.blog-brand {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  color: var(--ink);
  font-weight: 900;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.blog-brand span {
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  letter-spacing: .06em;
}

.blog-nav {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.blog-lang {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
}

.blog-lang button {
  appearance: none;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  padding: 8px 11px;
}

.blog-lang button.is-active {
  background: var(--ink);
  color: #fff;
}

.blog-main {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 72px 0 90px;
}

.blog-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 36px;
  align-items: end;
  margin-bottom: 42px;
}

.eyebrow {
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .16em;
  margin-bottom: 18px;
  text-transform: uppercase;
}

h1, h2, h3, p { margin: 0; }

h1 {
  color: var(--ink);
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 950;
  letter-spacing: 0;
  line-height: .98;
}

.blog-lede {
  max-width: 780px;
  margin-top: 22px;
  color: #3f3f3f;
  font-size: clamp(17px, 2vw, 22px);
  font-weight: 700;
  line-height: 1.65;
}

.blog-count {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: var(--shadow);
  padding: 22px;
}

.blog-count strong {
  display: block;
  color: var(--accent);
  font-size: 42px;
  line-height: 1;
}

.blog-count span {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-weight: 800;
}

.post-list {
  display: grid;
  gap: 18px;
}

.post-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 24px;
  min-height: 260px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  overflow: hidden;
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}

.post-card:hover {
  border-color: rgba(196, 0, 18, .45);
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}

.post-card__body {
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 22px;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  font-weight: 800;
}

.post-pill {
  border-radius: 999px;
  background: var(--soft);
  color: var(--ink);
  padding: 7px 10px;
}

.post-pill.red {
  background: var(--accent);
  color: #fff;
}

.post-card h2 {
  color: var(--ink);
  font-size: clamp(28px, 4vw, 46px);
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1.08;
}

.post-card p {
  margin-top: 14px;
  max-width: 660px;
  color: #3f3f3f;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.75;
}

.post-card__cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.9) contrast(1.04);
}

.post-card__arrow {
  color: var(--accent);
  font-weight: 900;
}

.article-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 38px;
  align-items: start;
}

.article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  overflow: hidden;
}

.article-head {
  padding: clamp(30px, 6vw, 66px);
  border-bottom: 1px solid var(--line);
}

.article-head h1 {
  max-width: 860px;
}

.article-body {
  padding: clamp(28px, 5vw, 58px);
}

.article-body section + section {
  margin-top: 44px;
}

.article-body h2 {
  color: var(--ink);
  font-size: clamp(26px, 3vw, 40px);
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1.12;
  margin-bottom: 16px;
}

.article-body p {
  font-size: 17px;
  font-weight: 650;
  line-height: 1.9;
  margin-top: 14px;
}

.article-body strong {
  color: var(--accent);
  font-weight: 950;
}

.figure {
  margin: 26px 0 0;
}

.figure img {
  display: block;
  width: 100%;
  border-radius: 8px;
  background: var(--soft);
}

.figure figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.5;
}

.quote {
  margin: 30px 0;
  border-left: 5px solid var(--accent);
  background: var(--soft);
  border-radius: 8px;
  padding: 24px;
  color: var(--ink);
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 950;
  line-height: 1.25;
}

.article-side {
  position: sticky;
  top: 88px;
  display: grid;
  gap: 10px;
}

.side-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 16px;
}

.side-card b {
  display: block;
  color: var(--ink);
  font-size: 14px;
  margin-bottom: 8px;
}

.side-card a,
.side-card span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.6;
}

[data-lang-block] { display: none; }
html[data-lang="zh"] [data-lang-block="zh"],
html[data-lang="en"] [data-lang-block="en"] { display: block; }

@media (max-width: 780px) {
  .blog-topbar__inner,
  .blog-main { width: min(100% - 32px, 1120px); }

  .blog-brand span { display: none; }
  .blog-nav { gap: 10px; }
  .blog-hero,
  .post-card,
  .article-wrap { grid-template-columns: 1fr; }

  .post-card__cover { order: -1; height: 220px; }
  .post-card__body { padding: 24px; }
  .article-side { position: static; }
}
