:root {
  --muted: light-dark(#6b6b6b, #9a9a9a);
  --accent: light-dark(#2f6b4f, #69bf93);
  --serif: ui-serif, Charter, "Iowan Old Style", Georgia, serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

body { margin: 0; background: light-dark(#fdfdfc, #161616); color: light-dark(#1f1f1f, #e6e6e6); font: 1.05rem/1.6 system-ui, sans-serif; }
main { max-width: 44rem; margin: auto; padding: 3rem 1.25rem; }

a { color: var(--accent); text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); }
a:hover { text-decoration-color: currentColor; }

h1, h2, h3 { text-wrap: balance; }
p, li, dd { text-wrap: pretty; }

h1 { margin: 0; font: 600 clamp(2.2rem, 1.6rem + 2vw, 3rem)/1.1 var(--serif); }
h1 + p { margin-top: .25rem; font-size: 1.15rem; color: var(--muted); }
header p { margin-bottom: .5rem; }
nav { display: flex; flex-wrap: wrap; gap: 0 1rem; }

section { border-top: 1px solid light-dark(#e4e2df, #2e2e2e); margin-top: 2rem; }
h2 { font: 500 .8rem var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }

h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 .4rem; margin: 1.25rem 0 .25rem; font-size: 1rem; }
h3 :is(span, small) { font-weight: normal; color: var(--muted); }
h3 span::before { content: "· "; }
h3 small { margin-left: auto; font-family: var(--mono); font-size: .8rem; }
h3 + p { margin-top: 0; }

ul, ol { padding-left: 1.2rem; }
li { margin-bottom: .5rem; }
dt { font-weight: bold; }
dd { margin: 0 0 .75rem; }

.stats { display: flex; gap: 2.5rem; font: .8rem var(--mono); color: var(--muted); }
.stats strong { display: block; font: 600 2rem/1.1 var(--serif); color: var(--accent); }

@media (min-width: 60rem) {
  main { max-width: 64rem; display: grid; grid-template-columns: 20rem 1fr; column-gap: 4rem; align-items: start; }
  nav { flex-direction: column; margin-top: 1rem; }
  section:first-of-type { margin-top: 0; }
}

@media (min-width: 60rem) and (min-height: 32rem) {
  header { position: sticky; top: 3rem; }
}

@media (max-width: 30rem) {
  h3 { flex-direction: column; }
  h3 span::before { content: none; }
  h3 small { margin-left: 0; }
}
