:root {
  --ink: #1A1A1A;
  --soft-ink: #3D3D3D;
  --muted: #6B6B6B;
  --hairline: #C8C8C8;
  --accent: #7A0019;
  --paper: #FAFAF7;
  --white: #FFFFFF;

  --serif-display: "Cormorant Garamond", "Times New Roman", serif;
  --serif-body: "Source Serif 4", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  background: var(--white);
  color: var(--soft-ink);
  font-family: var(--serif-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--hairline);
  transition: border-color 0.15s ease;
}

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

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 1px;
}

.eyebrow {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}

.hairline {
  border: 0;
  border-top: 0.5px solid var(--hairline);
  width: 100%;
}

/* MASTHEAD — shared across all blog pages */
.masthead {
  max-width: 760px;
  margin: 0 auto;
  padding: 28px 32px 0;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 24px;
}

.masthead .site-name {
  font-family: var(--serif-display);
  font-weight: 500;
  font-size: 28px;
  color: var(--ink);
  line-height: 1.05;
  letter-spacing: -0.005em;
  margin-bottom: 2px;
}

.masthead .site-name a {
  border-bottom: none;
}

.masthead .site-name a:hover {
  border-bottom: none;
  color: var(--accent);
}

.masthead .tagline {
  font-style: italic;
  font-size: 13px;
  color: var(--muted);
}

.masthead nav {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: right;
}

.masthead nav a {
  margin-left: 18px;
  color: var(--soft-ink);
  border-bottom: none;
  padding-bottom: 2px;
}

.masthead nav a:first-child {
  margin-left: 0;
}

.masthead nav a:hover,
.masthead nav a[aria-current="page"] {
  color: var(--accent);
  border-bottom: 1px solid var(--accent);
}

.masthead-rule {
  max-width: 760px;
  margin: 18px auto 0;
  padding: 0 32px;
}

.masthead-rule hr {
  border: 0;
  border-top: 0.5px solid var(--hairline);
}

/* BLOG INDEX */
.blog-index {
  max-width: 760px;
  margin: 0 auto;
  padding: 36px 32px 60px;
  width: 100%;
  flex: 1;
}

.blog-index .index-eyebrow {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.blog-index h1 {
  font-family: var(--serif-display);
  font-weight: 500;
  font-size: 40px;
  color: var(--ink);
  line-height: 1.1;
  letter-spacing: -0.005em;
  margin-bottom: 12px;
}

.blog-index .intro {
  font-style: italic;
  font-size: 15px;
  color: var(--muted);
  max-width: 600px;
  margin-bottom: 36px;
}

.post-list {
  list-style: none;
  border-top: 0.5px solid var(--hairline);
}

.post-list li {
  padding: 24px 0;
  border-bottom: 0.5px solid var(--hairline);
}

.post-list .post-date {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}

.post-list .post-title {
  font-family: var(--serif-display);
  font-weight: 500;
  font-size: 24px;
  line-height: 1.2;
  color: var(--ink);
  margin-bottom: 8px;
}

.post-list .post-title a {
  border-bottom: none;
}

.post-list .post-title a:hover {
  color: var(--accent);
  border-bottom: none;
}

.post-list .post-dek {
  font-size: 14px;
  color: var(--soft-ink);
  line-height: 1.55;
}

.post-list .post-dek a {
  border-bottom: 0;
}

/* POST PAGE */
.post {
  max-width: 680px;
  margin: 0 auto;
  padding: 36px 32px 80px;
  width: 100%;
  flex: 1;
}

.post header {
  margin-bottom: 32px;
}

.post .post-eyebrow {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.post h1 {
  font-family: var(--serif-display);
  font-weight: 500;
  font-size: 40px;
  color: var(--ink);
  line-height: 1.12;
  letter-spacing: -0.005em;
  margin-bottom: 14px;
}

.post .post-meta {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.post .post-meta .dot {
  margin: 0 8px;
  color: var(--hairline);
}

.post .dek {
  font-style: italic;
  font-size: 17px;
  line-height: 1.55;
  color: var(--muted);
  margin-top: 18px;
  padding-top: 18px;
  border-top: 0.5px solid var(--hairline);
}

.post article {
  font-family: var(--serif-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--soft-ink);
}

.post article > * + * {
  margin-top: 1.1em;
}

.post article h2 {
  font-family: var(--serif-display);
  font-weight: 600;
  font-size: 24px;
  color: var(--ink);
  line-height: 1.2;
  letter-spacing: -0.005em;
  margin-top: 1.8em;
  margin-bottom: 0.4em;
}

.post article h3 {
  font-family: var(--serif-display);
  font-weight: 600;
  font-size: 19px;
  color: var(--ink);
  line-height: 1.25;
  margin-top: 1.6em;
  margin-bottom: 0.3em;
}

.post article p {
  hyphens: auto;
}

.post article a {
  border-bottom: 1px solid var(--hairline);
}

.post article a:hover {
  border-bottom-color: var(--accent);
  color: var(--accent);
}

.post article blockquote {
  border-left: 2px solid var(--accent);
  padding-left: 18px;
  font-style: italic;
  color: var(--muted);
  margin: 1.4em 0;
}

.post article ul,
.post article ol {
  padding-left: 22px;
}

.post article li {
  margin-top: 0.4em;
}

.post article code {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.92em;
  background: var(--paper);
  padding: 1px 5px;
  border-radius: 2px;
}

.post article pre {
  background: var(--paper);
  border: 0.5px solid var(--hairline);
  padding: 14px 16px;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.55;
  margin: 1.2em 0;
}

.post article pre code {
  background: transparent;
  padding: 0;
}

.post article hr {
  border: 0;
  border-top: 0.5px solid var(--hairline);
  margin: 2em 0;
}

.post-footer {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 32px 60px;
  width: 100%;
}

.post-footer hr {
  border: 0;
  border-top: 0.5px solid var(--hairline);
  margin-bottom: 20px;
}

.post-footer .back {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  border-bottom: none;
}

.post-footer .back:hover {
  border-bottom: 1px solid var(--accent);
}

/* FOOTER */
.site-footer {
  text-align: center;
  padding: 24px 16px 28px;
  border-top: 0.5px solid var(--hairline);
  margin-top: auto;
}

.footer-rule {
  width: 80px;
  border: 0;
  border-top: 1px solid var(--accent);
  margin: 0 auto 10px;
}

.site-footer p {
  font-style: italic;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

/* MOBILE */
@media (max-width: 640px) {
  .masthead {
    grid-template-columns: 1fr;
    padding: 20px 20px 0;
    gap: 10px;
  }

  .masthead nav {
    text-align: left;
  }

  .masthead nav a {
    margin-left: 0;
    margin-right: 16px;
  }

  .masthead-rule {
    padding: 0 20px;
  }

  .blog-index,
  .post,
  .post-footer {
    padding-left: 20px;
    padding-right: 20px;
  }

  .blog-index h1,
  .post h1 {
    font-size: 32px;
  }

  .post-list .post-title {
    font-size: 21px;
  }
}
