:root {
  --bg: #f8f8f6;
  --text: #1a1a19;
  --text-soft: #4a4a45;
  --muted: #6e6e68;
  --rule: #e2e2dc;
  --accent: #0f6b5f;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "SF Mono", Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151514;
    --text: #ecece8;
    --text-soft: #bcbcb5;
    --muted: #8e8e87;
    --rule: #2c2c29;
    --accent: #6cc4b3;
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 1rem/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul, dl, dd {
  margin: 0;
}

a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  text-decoration-color: color-mix(in srgb, var(--accent) 40%, transparent);
  transition: text-decoration-color 120ms ease;
}

a:hover {
  text-decoration-color: currentColor;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

::selection {
  background: color-mix(in srgb, var(--accent) 22%, transparent);
}

.page {
  max-width: 42rem;
  margin: 0 auto;
  padding: 5.5rem 1.5rem 6rem;
}

/* Intro */

.masthead {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
}

h1 {
  font-size: 1.75rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.masthead nav {
  display: flex;
  gap: 1.25rem;
  font-size: 0.9375rem;
}

.tagline {
  margin-top: 0.375rem;
  font-size: 1.125rem;
  color: var(--text-soft);
}

.lede {
  max-width: 36rem;
  margin-top: 1.75rem;
}

/* Sections */

.block {
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 0 1.5rem;
  margin-top: 3rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
}

h2 {
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.6rem;
  color: var(--muted);
}

.entries {
  display: grid;
  gap: 1.5rem;
}

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

h3 {
  font-size: 1rem;
  font-weight: 600;
}

.when {
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  white-space: nowrap;
}

.entry p {
  margin-top: 0.25rem;
  color: var(--text-soft);
}

.lines {
  padding: 0;
  list-style: none;
}

.pairs {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 0.25rem 1rem;
}

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

.copy {
  margin-left: 0.75rem;
  padding: 0 0.5rem;
  font: inherit;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--text-soft);
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 0;
  cursor: pointer;
  transition: color 120ms ease, border-color 120ms ease;
}

.copy:hover {
  color: var(--text);
  border-color: var(--muted);
}

@media (max-width: 36rem) {
  .page {
    padding: 3rem 1.25rem 4rem;
  }

  .block {
    grid-template-columns: 1fr;
    gap: 0.5rem;
    margin-top: 2.5rem;
  }
}
