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

body {
  margin: 0;
  background: #fff;
  color: #303030;
  font-family: -apple-system, system-ui, "Segoe UI", Roboto, Ubuntu, sans-serif;
  font-size: 1.333rem;
  font-weight: 300;
  line-height: 1.6;
}

/* ── Site header ─────────────────────────────────────── */

.site-header {
  text-align: center;
  padding: 2rem 1.5rem 1.25rem;
}

.site-name {
  display: block;
  font-size: clamp(2.5rem, 8vw, 4rem);
  font-weight: 900;
  color: #000;
  text-decoration: none;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.site-name:hover {
  color: #000;
}

.site-nav {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
}

.site-nav a {
  color: #0083ff;
  text-decoration: none;
  text-transform: uppercase;
}

.site-nav a:hover {
  text-decoration: underline;
}

.site-nav .sep {
  color: #ccc;
  margin: 0 0.4em;
  user-select: none;
}

.header-rule {
  border: none;
  border-top: 1px solid #e0e0e0;
  margin: 0;
}

/* ── Content column ──────────────────────────────────── */

.site-content {
  max-width: 775px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 5rem;
}

/* ── Index page (river of posts + pagination) ────────── */

.index-post {
  padding-bottom: 3rem;
  margin-bottom: 3rem;
  border-bottom: 1px solid #e0e0e0;
}

.index-post:last-of-type {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}

.index-post-title {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 700;
  margin: 0 0 0.4rem;
  line-height: 1.2;
}

.index-post-title a {
  color: #0083ff;
  text-decoration: none;
}

.index-post-title a:hover {
  text-decoration: underline;
}

.pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #e0e0e0;
}

.pagination a {
  color: #0083ff;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.9rem;
}

.pagination a:hover {
  text-decoration: underline;
}

.empty {
  color: #ababab;
  text-align: center;
}

/* ── Post header (title + date + tags) ───────────────── */

.post-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.post-title {
  font-size: clamp(1.6rem, 4vw, 2.25rem);
  font-weight: 700;
  color: #0083ff;
  margin: 0 0 0.4rem;
  line-height: 1.2;
}

.post-date {
  display: block;
  color: #ababab;
  font-size: 1rem;
  font-weight: 400;
}

.post-tags {
  list-style: none;
  margin: 0.75rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem 0.6rem;
}

.post-tags a {
  color: #0083ff;
  font-size: 0.8rem;
  font-weight: 400;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.post-tags a:hover {
  text-decoration: underline;
}

/* ── Post body ───────────────────────────────────────── */

.post-body a {
  color: #0083ff;
  text-decoration: none;
}

.post-body a:hover {
  text-decoration: underline;
}

.post-body h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #303030;
  margin: 2.5rem 0 0.5rem;
  line-height: 1.25;
}

.post-body h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #303030;
  margin: 2rem 0 0.4rem;
}

.post-body h4 {
  font-size: 1rem;
  font-weight: 700;
  color: #303030;
  margin: 1.5rem 0 0.25rem;
}

.post-body p {
  margin: 0 0 1.25rem;
}

.post-body ul,
.post-body ol {
  padding-left: 1.5rem;
  margin: 0 0 1.25rem;
}

.post-body li {
  margin-bottom: 0.35rem;
}

.post-body img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1.5rem auto;
  border-radius: 4px;
}

.post-body hr {
  border: none;
  border-top: 1px solid #e0e0e0;
  margin: 2.5rem auto;
  width: 40%;
}

.post-body blockquote {
  margin: 1.5rem 0;
  padding: 0 0 0 1.25rem;
  border-left: 3px solid #e0e0e0;
  color: #666;
}

.post-body code {
  font-family: "SF Mono", "Fira Code", Menlo, "Courier New", monospace;
  font-size: 0.83em;
  background: #f2f2f2;
  padding: 0.15em 0.35em;
  border-radius: 3px;
}

.post-body pre {
  background: #f2f2f2;
  padding: 1rem 1.25rem;
  border-radius: 5px;
  overflow-x: auto;
  line-height: 1.5;
  margin: 0 0 1.25rem;
}

.post-body pre code {
  background: none;
  padding: 0;
  font-size: 0.85rem;
}

/* -----------------------------------------------------------------
   Site footer (copyright line)
   -----------------------------------------------------------------
   Rendered by templates/footer.js and appears on the public blog
   index, every tag index page, and every individual post page.

   Layout notes:
   - max-width matches .site-content (720px) so the rule above the
     copyright line sits directly under the content column rather
     than spanning the whole viewport.
   - Top margin (3rem) gives the footer breathing room after the
     last post; bottom margin (2rem) keeps it off the viewport edge.
     The 1.5rem horizontal padding matches .site-content so the
     column edges line up on narrow screens.
   - Small muted text (0.85rem, #777) so the line reads as ancillary
     metadata rather than competing with post content.
*/
.site-footer {
  max-width: 720px;
  margin: 3rem auto 2rem;
  padding: 1.5rem 1.5rem 0;
  border-top: 1px solid #e5e5e5;
  font-size: 0.85rem;
  color: #777;
  text-align: center;
}
