:root {
  color-scheme: light dark;
  --bg: #fdfdfc;
  --fg: #1d1d1f;
  --muted: #6e6e73;
  --accent: #0b57d0;
  --rule: #e4e4e7;
  --code-bg: #f3f3f5;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111113;
    --fg: #e6e6e9;
    --muted: #9a9aa1;
    --accent: #8ab4f8;
    --rule: #2a2a2e;
    --code-bg: #1c1c20;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--fg);
  font: 1.0625rem/1.65 ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-text-size-adjust: 100%;
}

body {
  max-width: 38rem;
  margin: 0 auto;
  padding: 3rem 1.25rem 4rem;
}

a { color: var(--accent); text-underline-offset: 0.15em; }
a:hover { text-decoration-thickness: 2px; }

h1, h2, h3 { line-height: 1.25; margin: 2rem 0 0.75rem; }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.1rem; }

code, pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--code-bg);
  border-radius: 4px;
}
code { padding: 0.1em 0.3em; }
pre { padding: 1rem; overflow-x: auto; }
pre code { padding: 0; background: none; }

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

img { max-width: 100%; height: auto; }
hr { border: 0; border-top: 1px solid var(--rule); margin: 2rem 0; }

/* Site chrome */

.site-header {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 3rem;
}
.site-title {
  color: var(--fg);
  font-weight: 600;
  text-decoration: none;
}
.site-header nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-header nav a { color: var(--muted); }

.site-footer {
  margin-top: 4rem;
  padding-top: 1rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.875rem;
}

.meta { color: var(--muted); font-size: 0.9rem; margin-top: -0.5rem; }

.post-list { list-style: none; padding: 0; }
.post-list li {
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  padding: 0.4rem 0;
}
.post-list time {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
