/* Articles (blog) — loaded after /styles.css, reuses its tokens */

.articles-hero {
  padding: 7.5rem 0 3rem;
}

.articles-hero .hero-lead {
  margin-bottom: 0;
}

.articles-main {
  padding: 3.5rem 0 5rem;
}

/* Article pages have no hero, so clear the fixed header (4rem + 2px border) */
.articles-article {
  padding-top: calc(4rem + 2.5rem);
}

.articles-wrap {
  width: min(100% - 2rem, 760px);
  margin-inline: auto;
}

/* Article */

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
}

.post-latest-tag {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-label);
}

.post h1,
.post h2.post-title {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}

.post h2.post-title a {
  color: inherit;
}

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

.post-body {
  font-size: 1.05rem;
  line-height: 1.75;
}

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

.post-body h2 {
  font-size: 1.5rem;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin-top: 2em;
}

.post-body h3 {
  font-size: 1.2rem;
  margin-top: 1.6em;
}

.post-body ul,
.post-body ol {
  padding-left: 1.4em;
}

.post-body li + li {
  margin-top: 0.35em;
}

.post-body a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.post-body blockquote {
  border-left: 3px solid var(--color-brand-magenta);
  padding: 0.25em 0 0.25em 1em;
  color: var(--color-text-muted);
}

.post-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--color-surface-elevated);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

.post-body pre {
  background: #231a2e;
  color: #f3edf6;
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  overflow-x: auto;
  font-size: 0.9rem;
  line-height: 1.55;
}

.post-body pre code {
  background: none;
  padding: 0;
  color: inherit;
}

.post-body img {
  border-radius: var(--radius);
  height: auto;
}

.post-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.post-body th,
.post-body td {
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid var(--color-border);
}

.post-continue {
  margin-top: 2rem;
}

/* Article index list */

.articles-list-section {
  margin-top: 4rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--color-border);
}

.articles-list-section h2 {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.articles-list {
  list-style: none;
}

.articles-list li {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 0.25rem 1.25rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--color-border);
}

.articles-list time {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
  padding-top: 0.1rem;
}

.articles-list a {
  font-weight: 600;
}

.articles-list p {
  grid-column: 2;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.post-nav {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 3rem;
  font-size: 0.95rem;
}

.post-nav a {
  max-width: 48%;
}

.post-nav .next {
  margin-left: auto;
  text-align: right;
}

.post-nav span {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
}

.articles-status {
  color: var(--color-text-muted);
}

@media (max-width: 768px) {
  .articles-hero {
    padding-top: 6.5rem;
  }

  .articles-list li {
    grid-template-columns: 1fr;
  }

  .articles-list p {
    grid-column: 1;
  }
}
