:root {
  --serif: "Source Serif 4", "Source Serif Pro", Charter, "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans:  -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", system-ui, sans-serif;

  --fg:         #1a1a1a;
  --fg-soft:    #4a4a4a;
  --fg-muted:   #7a7a7a;
  --rule:       #ece8de;
  --bg:         #fbf9f4;
  --bg-tint:    #f4efe2;
  --link:       #2f5a87;
  --link-hover: #b35021;
}

@media (prefers-color-scheme: dark) {
  :root {
    --fg:         #ece6d4;
    --fg-soft:    #b9b3a3;
    --fg-muted:   #8a8678;
    --rule:       #2a2620;
    --bg:         #14120e;
    --bg-tint:    #1d1a14;
    --link:       #9ec0e6;
    --link-hover: #f0b48a;
  }
}

* { box-sizing: border-box; }

html { font-size: 17px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--serif);
  font-feature-settings: "kern", "liga", "onum";
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--bg-tint); }

header.site {
  max-width: 42rem;
  margin: 0 auto;
  padding: 1.75rem 1.5rem 0;
  font-family: var(--sans);
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  color: var(--fg-muted);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

header.site a {
  color: var(--fg-muted);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

header.site a:hover {
  color: var(--fg);
  border-bottom-color: var(--fg);
}

main {
  max-width: 42rem;
  margin: 2.5rem auto 6rem;
  padding: 0 1.5rem;
}

h1 {
  font-size: 2.6rem;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
}

h2 {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-muted);
  margin: 3rem 0 1.1rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--rule);
}

p.intro {
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--fg-soft);
  margin: 0 0 0.5rem;
  max-width: 34rem;
}

p.count {
  font-family: var(--sans);
  font-size: 0.78rem;
  color: var(--fg-muted);
  letter-spacing: 0.04em;
  margin: 0.25rem 0 0;
  font-feature-settings: "tnum";
}

p.updated {
  font-family: var(--sans);
  font-size: 0.72rem;
  color: var(--fg-muted);
  letter-spacing: 0.04em;
  margin: 4rem 0 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  font-feature-settings: "tnum";
}

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

li {
  padding: 0.32rem 0;
  font-size: 1.02rem;
  line-height: 1.45;
}

a {
  color: var(--link);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.12s ease, border-color 0.12s ease;
}

a:hover {
  color: var(--link-hover);
  border-bottom-color: var(--link-hover);
}

.author {
  color: var(--fg-muted);
  font-style: italic;
}

@media (max-width: 30rem) {
  html { font-size: 16.5px; }
  main { margin-top: 1.5rem; }
  h1 { font-size: 2.1rem; }
  header.site { padding-top: 1.25rem; }
}
