:root {
  --bg: #fbfbfa;
  --ink: #222321;
  --muted: #70736d;
  --line: #dedfd9;
  --soft: #f1f3ef;
  --accent: #3a6758;
  --accent-2: #8a4f38;
  --code-bg: #eeeeea;
  --measure: 720px;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--ink);
  font-family: ui-serif, Georgia, "Times New Roman", "Noto Serif CJK SC", "Songti SC", serif;
  font-size: 18px;
  line-height: 1.72;
}

body {
  margin: 0;
}

a {
  color: inherit;
  text-decoration-color: color-mix(in srgb, var(--accent) 55%, transparent);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--accent);
}

img,
video,
iframe {
  max-width: 100%;
}

img {
  height: auto;
}

.site-shell {
  width: min(100% - 40px, 1040px);
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  padding: 34px 0 28px;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: grid;
  gap: 2px;
  text-decoration: none;
}

.brand-title {
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1.22rem;
  font-weight: 700;
  line-height: 1.2;
}

.brand-subtitle {
  color: var(--muted);
  font-size: 0.82rem;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px 18px;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 0.84rem;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--ink);
}

.home-intro{
  display: none;
}
.home-intro,
.archive-head {
  max-width: var(--measure);
  margin-bottom: 42px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent-2);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.home-intro h1,
.archive-head h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(1.8rem, 5vw, 3.15rem);
  font-weight: 500;
  line-height: 1.18;
}

.post-list {
  max-width: 880px;
  border-top: 1px solid var(--line);
}

.post-row {
  display: grid;
  grid-template-columns: 126px minmax(0, 1fr);
  gap: 34px;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}

.post-row time,
.article-header time {
  color: var(--muted);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 0.78rem;
}

.post-row h2 {
  margin: -4px 0 8px;
  font-size: 1.32rem;
  font-weight: 500;
  line-height: 1.36;
}

.post-row h2 a {
  text-decoration: none;
}

.post-excerpt {
  max-width: 620px;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.7;
}

.article {
  max-width: var(--measure);
}

.article-header {
  margin-bottom: 36px;
}

.article-header h1 {
  margin: 8px 0 14px;
  font-size: clamp(2rem, 6vw, 3.35rem);
  font-weight: 500;
  line-height: 1.14;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: var(--muted);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 0.78rem;
}

.article-meta a {
  text-decoration: none;
}

.article-body {
  overflow-wrap: break-word;
}

.article-body h2,
.article-body h3,
.article-body h4 {
  margin: 2.1em 0 0.55em;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.35;
}

.article-body h2 {
  font-size: 1.45rem;
}

.article-body h3 {
  font-size: 1.16rem;
}

.article-body p,
.article-body ul,
.article-body ol,
.article-body blockquote,
.article-body pre,
.article-body table {
  margin: 1.05em 0;
}

.article-body blockquote {
  margin-left: 0;
  padding-left: 20px;
  border-left: 3px solid var(--accent);
  color: #555850;
}

.article-body code {
  padding: 0.12em 0.28em;
  border-radius: 4px;
  background: var(--code-bg);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.86em;
}

.article-body pre {
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--soft);
  line-height: 1.55;
}

.article-body pre code {
  padding: 0;
  background: transparent;
}

.article-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.article-body th,
.article-body td {
  padding: 8px 10px;
  border: 1px solid var(--line);
  text-align: left;
}

.article-body hr {
  margin: 2.4em 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  max-width: 880px;
  margin-top: 34px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 0.86rem;
}

.pager a {
  text-decoration: none;
}

.pager a:last-child {
  justify-self: end;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 28px 0 36px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 0.78rem;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 720px) {
  html {
    font-size: 17px;
  }

  .site-shell {
    width: min(100% - 28px, 1040px);
  }

  .site-header {
    align-items: flex-start;
    flex-direction: column;
    padding-top: 24px;
  }

  .site-nav {
    justify-content: flex-start;
  }

  .site-main {
    /* padding: 42px 0 56px; */
  }

  .post-row {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 22px 0;
  }

  .post-row h2 {
    margin-top: 0;
  }

  .site-footer {
    flex-direction: column;
    gap: 6px;
  }
}
