:root {
  --bg: #fafafa;
  --surface: #ffffff;
  --text: #18181b;
  --muted: #52525b;
  --border: #e4e4e7;
  --accent: #0f172a;
  --link: #2563eb;
  --code-bg: #f4f4f5;
  --pre-bg: #18181b;
  --pre-text: #e4e4e7;
  --tag-bg: #f1f5f9;
  --tag-text: #334155;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #09090b;
    --surface: #121215;
    --text: #f4f4f5;
    --muted: #a1a1aa;
    --border: #27272a;
    --accent: #f8fafc;
    --link: #60a5fa;
    --code-bg: #1e1e24;
    --pre-bg: #141418;
    --pre-text: #e4e4e7;
    --tag-bg: #1e293b;
    --tag-text: #cbd5e1;
  }
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
.container {
  max-width: 760px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}
header.site-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 1rem;
  padding-bottom: 1.5rem;
  margin-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
}
.brand {
  font-weight: 700;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
}
.brand span {
  color: var(--muted);
  font-weight: 400;
  font-size: 0.9rem;
  margin-left: 0.5rem;
}
nav a {
  color: var(--muted);
  text-decoration: none;
  margin-left: 1.25rem;
  font-size: 0.95rem;
  transition: color 0.15s ease;
}
nav a:hover, nav a.active {
  color: var(--text);
}
h1, h2, h3 {
  line-height: 1.35;
  letter-spacing: -0.02em;
  color: var(--text);
}
h1 { font-size: 1.85rem; margin-top: 0; margin-bottom: 0.75rem; }
h2 { font-size: 1.35rem; margin-top: 2.25rem; margin-bottom: 0.75rem; }
h3 { font-size: 1.1rem; margin-top: 1.75rem; margin-bottom: 0.5rem; }
p { margin: 0 0 1.25rem; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
.intro {
  color: var(--muted);
  font-size: 1.02rem;
  margin-bottom: 2.5rem;
}
.post-card {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border);
}
.post-card:first-of-type {
  padding-top: 0.5rem;
}
.post-meta {
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 0.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
}
.tag {
  background: var(--tag-bg);
  color: var(--tag-text);
  padding: 0.1rem 0.55rem;
  border-radius: 4px;
  font-size: 0.78rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}
.post-card h2 {
  margin: 0.25rem 0 0.5rem;
  font-size: 1.3rem;
}
.post-card h2 a {
  color: var(--text);
  text-decoration: none;
}
.post-card h2 a:hover {
  color: var(--link);
}
.post-excerpt {
  color: var(--muted);
  margin: 0;
  font-size: 0.96rem;
}
code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.88em;
  background: var(--code-bg);
  padding: 0.15em 0.4em;
  border-radius: 4px;
}
pre {
  background: var(--pre-bg);
  color: var(--pre-text);
  padding: 1.1rem 1.25rem;
  border-radius: 8px;
  overflow-x: auto;
  font-size: 0.88rem;
  line-height: 1.6;
  margin: 1.25rem 0 1.5rem;
  border: 1px solid var(--border);
}
pre code {
  background: transparent;
  padding: 0;
  color: inherit;
  font-size: inherit;
}
blockquote {
  margin: 1.5rem 0;
  padding: 0.5rem 1.25rem;
  border-left: 3px solid var(--link);
  background: var(--surface);
  color: var(--muted);
}
table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.92rem;
}
th, td {
  text-align: left;
  padding: 0.65rem 0.8rem;
  border-bottom: 1px solid var(--border);
}
th {
  font-weight: 600;
  color: var(--text);
  background: var(--code-bg);
}
footer.site-footer {
  margin-top: 4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.85rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}
