:root {
  --bg: #fdfdfc;
  --fg: #1a1a1a;
  --muted: #6b6b6b;
  --line: #e6e6e3;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1e1e1e;
    --fg: #d4d4d4;
    --muted: #8a8a8a;
    --line: #333333;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.65 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  text-rendering: optimizeLegibility;
}

main {
  max-width: 38rem;
  margin: 0 auto;
  padding: 6rem 1.5rem 4rem;
}

h1, h2, h3 { margin: 0; font-weight: 600; }

h1 { font-size: 1.5rem; letter-spacing: -0.01em; }

h2 {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.25rem;
}

h3 { font-size: 1rem; }

p { margin: 0 0 1rem; }

header p { margin: 0.25rem 0 0; }

section {
  margin-top: 3.5rem;
}

header + section { margin-top: 2.5rem; }

.muted { color: var(--muted); }

a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--muted);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: text-decoration-color 0.15s;
}

a:hover, a:focus-visible { text-decoration-color: currentColor; }

a:focus-visible { outline: 1px solid var(--muted); outline-offset: 3px; }

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  margin-top: 1.5rem;
}

.entry + .entry { margin-top: 1.5rem; }

.entry-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 0.4rem;
}

.entry-head span {
  flex: none;
  font-size: 0.875rem;
  font-variant-numeric: tabular-nums;
}

.entry p { margin: 0; }

ul {
  margin: 0.75rem 0 0;
  padding: 0;
  list-style: none;
}

li + li { margin-top: 0.75rem; }

b { font-weight: 600; }

dl {
  display: grid;
  grid-template-columns: 7rem 1fr;
  gap: 0.6rem 1rem;
  margin: 0;
}

dt { color: var(--muted); }

dd { margin: 0; }

@media (max-width: 30rem) {
  main { padding-top: 3.5rem; }
  dl { grid-template-columns: 1fr; gap: 0; }
  dd { margin-bottom: 0.75rem; }
}

@media print {
  main { padding-top: 0; }
  nav a::after { content: " (" attr(href) ")"; color: var(--muted); }
}
