:root {
  color-scheme: dark;
  --background: #1f2328;
  --text: #d9d6d1;
  --muted: #a7a5a1;
  --accent: #9fc7d5;
  --line: #3d4249;
  --code: #2b3036;
  --sans: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, serif;
}

* { box-sizing: border-box; }

html { font-size: 17px; }

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: var(--serif);
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.16em;
}

a:hover { color: var(--text); }

img {
  display: block;
  max-width: 100%;
  height: auto;
}

.skip-link {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  padding: 0.5rem 0.75rem;
  background: var(--text);
  color: var(--background);
  z-index: 10;
}

.site-shell {
  width: min(680px, calc(100% - 2rem));
  margin: 0 auto;
}

.site-header {
  padding: 3.25rem 0 1.4rem;
  border-bottom: 1px solid var(--line);
}

.site-title {
  display: inline-block;
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  text-decoration: none;
}

.site-header nav {
  display: flex;
  gap: 0.55rem;
  margin-top: 0.55rem;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.86rem;
}

.site-header nav a {
  color: var(--muted);
  text-decoration: none;
}

.site-header nav a:hover,
.site-header nav a[aria-current="page"] {
  color: var(--accent);
}

.page,
.post {
  padding: 2.7rem 0 4.5rem;
}

.page-header {
  margin-bottom: 2.4rem;
}

h1, h2, h3 {
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.24;
}

h1 {
  margin: 0;
  font-size: 2rem;
  letter-spacing: -0.025em;
}

.page-header > p {
  max-width: 590px;
  margin: 0.75rem 0 0;
  color: var(--muted);
}

.post-list-item {
  padding: 0 0 2.25rem;
  margin-bottom: 2.25rem;
  border-bottom: 1px solid var(--line);
}

.post-list-item h2 {
  margin: 0 0 0.25rem;
  font-size: 1.25rem;
}

.post-list-item h2 a {
  color: var(--text);
  text-decoration: none;
}

.post-list-item h2 a:hover { color: var(--accent); }

.post-list-item > p:last-child {
  margin: 0.8rem 0 0;
  color: var(--muted);
}

.post-meta {
  margin: 0;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.78rem;
}

.elsewhere { padding-top: 0.25rem; }

.elsewhere h2 {
  margin: 0 0 1rem;
  font-size: 1.1rem;
}

.elsewhere ul {
  margin: 0;
  padding-left: 1.2rem;
}

.elsewhere li { margin: 0.5rem 0; }

.post-header { margin-bottom: 2.8rem; }

.post-header h1 {
  margin-bottom: 0.6rem;
  font-size: clamp(1.85rem, 5vw, 2.5rem);
}

.prose {
  font-size: 1.03rem;
}

.prose > :first-child { margin-top: 0; }
.prose h1 { display: none; }

.prose h2,
.prose h3 {
  margin: 2.2em 0 0.6em;
  letter-spacing: -0.015em;
}

.prose h2 { font-size: 1.38rem; }
.prose h3 { font-size: 1.12rem; }
.prose p { margin: 1.15em 0; }
.prose ul, .prose ol { padding-left: 1.4rem; }
.prose li { margin: 0.35rem 0; }
.prose img { margin: 2rem auto; }

.project-list li {
  margin-bottom: 1rem;
}

.project-list a {
  font-family: var(--sans);
  font-weight: 700;
}

.prose blockquote {
  margin: 1.7rem 0;
  padding-left: 1rem;
  border-left: 3px solid var(--line);
  color: var(--muted);
}

.prose code {
  padding: 0.1em 0.28em;
  background: var(--code);
  border-radius: 2px;
  font-size: 0.86em;
}

.prose pre {
  overflow-x: auto;
  margin: 1.7rem 0;
  padding: 1rem;
  background: #15191d;
  color: #ece8e1;
  border-radius: 3px;
  font-size: 0.82rem;
  line-height: 1.55;
}

.prose pre code {
  padding: 0;
  background: transparent;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  padding: 1.4rem 0 3rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.76rem;
}

.site-footer a { color: var(--muted); }

.not-found {
  min-height: 60vh;
  padding: 4rem 0;
}

@media (max-width: 520px) {
  html { font-size: 16px; }
  .site-header { padding-top: 2rem; }
  .page, .post { padding-top: 2.2rem; }
}
