:root {
  color-scheme: light;
  --paper: #f7f8f6;
  --ink: #182b38;
  --muted: #66747a;
  --rule: #d7dfdf;
  --accent: #2e5d72;
  --warm: #b77957;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-underline-offset: .18em; }
a:hover { color: var(--accent); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.page-shell { max-width: 1100px; margin: auto; padding: 0 clamp(1.25rem, 5vw, 4rem); }
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  min-height: 76px;
  border-bottom: 1px solid var(--rule);
}
.wordmark {
  font-size: .92rem;
  font-weight: 700;
  letter-spacing: .01em;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}
.wordmark-mark { color: var(--warm); }
.site-header nav { display: flex; gap: clamp(1rem, 3vw, 2rem); align-items: center; }
.site-header nav a {
  color: var(--muted);
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .015em;
  text-decoration: none;
}
.site-header nav a:hover { color: var(--ink); }
.eyebrow {
  color: var(--accent);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .15em;
  line-height: 1.4;
  text-transform: uppercase;
}
h1, h2, h3 { font-family: Georgia, "Times New Roman", serif; }
.archive { min-height: 250px; margin-top: clamp(2.5rem, 5vw, 4rem); border-top: 2px solid var(--ink); }
.year-group { display: grid; grid-template-columns: 130px 1fr; gap: 1rem; border-bottom: 1px solid var(--rule); }
.year-group h2 { margin: 0; padding: 1.75rem 0; font-size: 1.8rem; font-weight: 400; letter-spacing: -.04em; }
.post-list { margin: 0; padding: .7rem 0; list-style: none; }
.post-list li { display: grid; grid-template-columns: 82px 1fr; gap: 1.2rem; align-items: baseline; padding: 1rem 0; }
.post-list li + li { border-top: 1px solid var(--rule); }
.post-list time { color: var(--muted); font-size: .8rem; font-variant-numeric: tabular-nums; text-transform: uppercase; white-space: nowrap; }
.post-list a { font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.15rem, 2vw, 1.45rem); line-height: 1.3; letter-spacing: -.015em; text-decoration: none; }
.post-list a:hover { text-decoration: underline; }
.empty-state { padding: 3.5rem 0 5rem; }
.empty-state p { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 2rem; }
.empty-state span { color: var(--muted); }
.site-footer { display: flex; justify-content: space-between; gap: 1rem; padding: 2.5rem 0 3.5rem; border-top: 1px solid var(--rule); color: var(--muted); font-size: .82rem; }
.site-footer a { color: var(--muted); }
.post { max-width: 740px; padding: clamp(3.5rem, 7vw, 6rem) 0 5rem; }
.post .eyebrow { margin: 0 0 1.25rem; }
.post .eyebrow a { text-decoration: none; }
.post h1 { margin: 0; font-size: clamp(2.7rem, 6.5vw, 5rem); font-weight: 400; letter-spacing: -.055em; line-height: 1.08; }
.post-deck { margin: 1.5rem 0 0; color: var(--muted); font-size: 1.25rem; }
.prose { margin-top: 3.5rem; font-family: Georgia, "Times New Roman", serif; font-size: 1.12rem; line-height: 1.78; }
.prose > *:first-child { margin-top: 0; }
.prose h2, .prose h3, .prose h4 { margin: 2.5em 0 .7em; line-height: 1.2; }
.prose h2 { font-size: 1.7rem; }
.prose h3 { font-size: 1.35rem; }
.prose h4 { font-family: Georgia, "Times New Roman", serif; font-size: 1.15rem; }
.prose p, .prose ul, .prose ol, .prose blockquote { margin: 0 0 1.4em; }
.prose blockquote { margin-left: 0; padding-left: 1.2rem; border-left: 3px solid var(--warm); color: #45565f; }
.prose img { max-width: 100%; height: auto; }
.prose pre { overflow-x: auto; padding: 1.25rem; background: #e9eeed; border-radius: 5px; font-size: .88rem; line-height: 1.55; }
.prose :not(pre) > code { padding: .12rem .32rem; background: #e9eeed; border-radius: 3px; font-size: .86em; }
.prose pre code { background: none; padding: 0; }
.back-link { margin-top: 4rem; padding-top: 1.5rem; border-top: 1px solid var(--rule); font-size: .92rem; }
.not-found { min-height: 50vh; padding: 5rem 0; }
.not-found h1 { font-size: clamp(3rem, 8vw, 5.5rem); font-weight: 400; letter-spacing: -.055em; margin: 0; }
.not-found p:not(.eyebrow) { color: var(--muted); }

@media (max-width: 620px) {
  .site-header { min-height: 72px; gap: 1rem; }
  .site-header nav { gap: 1rem; }
  .year-group { display: block; }
  .year-group h2 { padding: 1.4rem 0 .2rem; }
  .post-list { padding-top: 0; }
  .post-list li { grid-template-columns: 65px 1fr; gap: .75rem; }
  .site-footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
