:root {
  --bg: #fafafa;
  --fg: #1a1a1a;
  --muted: #6b6b6b;
  --border: #e3e3e3;
  --accent: #0f6cbd;
  --code-bg: #f0f2f4;
  --maxw: 760px;
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.65;
  font-size: 17px;
}

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

.site-header {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 2.5rem 1.25rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
  border-bottom: 1px solid var(--border);
}

.brand {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--fg);
}

.tagline {
  color: var(--muted);
  font-size: 0.9rem;
}

.nav {
  margin-left: auto;
  display: flex;
  gap: 1rem;
  font-size: 0.95rem;
}

.main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

.lede {
  color: var(--muted);
  max-width: 60ch;
}

.post-list {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
}

.post-list h2 {
  margin: 0 0 0.25rem;
  font-size: 1.3rem;
  line-height: 1.3;
}
.post-list h2 a {
  color: var(--fg);
}
.post-list h2 a:hover {
  color: var(--accent);
  text-decoration: none;
}

.date {
  color: var(--muted);
  font-size: 0.85rem;
}

.summary {
  margin: 0.35rem 0 0.5rem;
  color: #3a3a3a;
}

.tags {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.25rem 0 0;
  padding: 0;
}
.tags a {
  display: inline-block;
  font-size: 0.8rem;
  color: var(--accent);
  background: #eaf2fa;
  border-radius: 4px;
  padding: 0.1rem 0.5rem;
}
.tags a:hover {
  text-decoration: none;
  background: #d8e8f7;
}

.tag-cloud {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 1.5rem 0 0;
  padding: 0;
}
.tag-cloud a {
  display: inline-block;
  font-size: 0.95rem;
  background: #eaf2fa;
  border-radius: 6px;
  padding: 0.3rem 0.7rem;
}
.tag-cloud a:hover {
  text-decoration: none;
  background: #d8e8f7;
}
.tag-cloud .count {
  color: var(--muted);
  font-size: 0.8rem;
}

.post-header h1 {
  margin: 0 0 0.5rem;
  line-height: 1.25;
  font-size: 2rem;
}
.meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.post-body {
  max-width: 100%;
}

.post-body h1,
.post-body h2,
.post-body h3 {
  line-height: 1.3;
  margin-top: 1.6em;
}

.post-body img {
  max-width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.post-body pre {
  background: var(--code-bg);
  padding: 0.9rem 1rem;
  overflow-x: auto;
  border-radius: 6px;
  font-size: 0.88rem;
  line-height: 1.5;
}

.post-body code {
  background: var(--code-bg);
  padding: 0.1rem 0.3rem;
  border-radius: 4px;
  font-size: 0.88em;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}
.post-body pre code {
  background: none;
  padding: 0;
}

.post-body blockquote {
  margin: 1.25em 0;
  padding: 0.25em 1em;
  border-left: 3px solid var(--accent);
  color: var(--muted);
  background: #f4f6f8;
  border-radius: 0 6px 6px 0;
}

.site-footer {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.9rem;
}
.fine-print {
  font-size: 0.8rem;
  color: #9a9a9a;
}

@media (max-width: 600px) {
  .nav {
    margin-left: 0;
    width: 100%;
  }
  .post-header h1 {
    font-size: 1.6rem;
  }
}
