:root {
  color-scheme: light dark;
  --bg: #fdfcf9;
  --fg: #23211d;
  --muted: #6c6862;
  --line: #e2ddd3;
  --link: #9a4a1c;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161513;
    --fg: #e8e4dc;
    --muted: #9b968d;
    --line: #2e2b27;
    --link: #e2a06a;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0 auto;
  padding: 2.5rem 1.25rem 3rem;
  max-width: 42rem;
  background: var(--bg);
  color: var(--fg);
  font-family: "Noto Serif SC", "Songti SC", Georgia, "Times New Roman", serif;
  font-size: 1.0625rem;
  line-height: 1.85;
  text-rendering: optimizeLegibility;
}

a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

.site-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1rem;
  margin-bottom: 2.25rem;
  border-bottom: 1px solid var(--line);
}

.brand {
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--fg);
  text-decoration: none;
}

.site-header nav a { color: var(--muted); font-size: .9375rem; text-decoration: none; }
.site-header nav a:hover { color: var(--link); }

h1 { font-size: 1.75rem; line-height: 1.35; margin: 0 0 .5rem; letter-spacing: .02em; }
h2 { font-size: 1.125rem; margin: 2.5rem 0 .75rem; letter-spacing: .02em; }
h3 { font-size: 1rem; margin: 1.75rem 0 .5rem; }

.lede { color: var(--muted); margin: 0 0 1rem; }

ul.posts { list-style: none; margin: 0; padding: 0; }

ul.posts li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .5rem .75rem;
  padding: .7rem 0;
  border-bottom: 1px dotted var(--line);
}

ul.posts li a { flex: 1 1 auto; }

ul.posts time, .meta {
  color: var(--muted);
  font-size: .875rem;
  font-variant-numeric: tabular-nums;
}

article { margin-top: .5rem; }

article p { margin: 0 0 1.1rem; }

blockquote {
  margin: 1.5rem 0;
  padding: .25rem 0 .25rem 1rem;
  border-left: 3px solid var(--line);
  color: var(--muted);
}

code {
  font-family: "Cascadia Mono", Consolas, "SF Mono", monospace;
  font-size: .9em;
  padding: .1em .35em;
  border: 1px solid var(--line);
  border-radius: 4px;
}

pre {
  overflow-x: auto;
  padding: .9rem 1rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  font-size: .875rem;
  line-height: 1.7;
}

pre code { border: 0; padding: 0; font-size: inherit; }

footer {
  margin-top: 3.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: .875rem;
}

footer p { margin: .2rem 0; }

.back { display: inline-block; margin-bottom: 1.5rem; font-size: .9375rem; }
