/* blog.css — shared styles for blog index + article pages */

/* ── Blog index ───────────────────────────────────────────────── */

.tm-blog-index {
  min-height: 70vh;
  padding: clamp(56px, 8vw, 104px) 0 clamp(72px, 10vw, 128px);
}

.tm-blog-header {
  margin-bottom: 56px;
}

.tm-blog-h1 {
  margin: 8px 0 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: -0.035em;
  color: var(--ink);
  line-height: 1.1;
}

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

.tm-post-card {
  border-top: 1px solid var(--rule);
}
.tm-post-list li:last-child {
  border-bottom: 1px solid var(--rule);
}

.tm-post-card-link {
  display: block;
  padding: 40px 0;
  text-decoration: none;
  color: inherit;
  transition: none;
}
.tm-post-card-link:hover .tm-post-title { color: var(--accent); }
.tm-post-card-link:hover .tm-post-read  { color: var(--accent); }

.tm-post-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--muted-2);
}

.tm-post-title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  letter-spacing: -0.025em;
  color: var(--ink);
  line-height: 1.2;
  transition: color 160ms ease;
}

.tm-post-subtitle {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 500;
  color: var(--ink-soft);
  letter-spacing: -0.01em;
  line-height: 1.4;
}

.tm-post-desc {
  margin: 0 0 20px;
  font-family: var(--font-body);
  font-size: var(--text-md);
  color: var(--muted);
  line-height: 1.6;
  max-width: 640px;
}

.tm-post-read {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--ink-soft);
  transition: color 160ms ease;
}

/* ── Article page ─────────────────────────────────────────────── */

.tm-article-page {
  padding: clamp(40px, 6vw, 72px) 0 clamp(72px, 10vw, 128px);
}

.tm-article-container {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

.tm-article-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  margin-bottom: 36px;
  transition: color 160ms ease;
}
.tm-article-back:hover { color: var(--accent); }

.tm-article-header {
  margin-bottom: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--rule);
}

.tm-article-title {
  margin: 0 0 20px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.9rem, 5vw, 2.75rem);
  letter-spacing: -0.035em;
  color: var(--ink);
  line-height: 1.1;
}

.tm-article-titlesub {
  margin: 0 0 20px;
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 2.5vw, 1.25rem);
  font-weight: 500;
  color: var(--ink-soft);
  letter-spacing: -0.01em;
  line-height: 1.4;
}

.tm-article-subtitle {
  margin: 0 0 28px;
  font-family: var(--font-body);
  font-size: var(--text-md);
  color: var(--muted);
  line-height: 1.65;
  font-style: italic;
}
.tm-article-subtitle em { font-style: normal; }

.tm-article-byline {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.tm-article-author {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--ink-soft);
}

.tm-article-date {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--muted-2);
}

/* ── Article body ─────────────────────────────────────────────── */

.tm-article-body {
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.78;
  color: var(--ink-soft);
}

.tm-article-body p {
  margin: 0 0 1.5em;
}

.tm-article-body h2 {
  margin: 2.4em 0 0.75em;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.15rem, 2.5vw, 1.35rem);
  letter-spacing: -0.015em;
  color: var(--ink);
  line-height: 1.3;
}

.tm-article-body em {
  font-style: italic;
  color: var(--ink);
}

.tm-article-body strong {
  font-weight: 600;
  color: var(--ink);
}

.tm-article-body a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.tm-article-body a:hover { opacity: 0.8; }

/* ── Article images ───────────────────────────────────────────── */

.tm-article-fig {
  margin: 2em 0 2.25em;
}

.tm-article-img {
  width: 100%;
  max-width: 680px;
  height: auto;
  display: block;
  border-radius: var(--radius-lg);
  border: 1px solid color-mix(in oklab, var(--accent) 15%, transparent);
}

.tm-article-figcaption {
  margin-top: 10px;
  font-size: var(--text-sm);
  color: var(--muted-2);
  font-style: italic;
  line-height: 1.5;
}

.tm-article-diagram {
  margin: 0 0 2em;
}
.tm-article-diagram .tm-article-img {
  border: none;
}

/* ── Article footer note ──────────────────────────────────────── */

.tm-article-footer {
  margin-top: 56px;
  padding-top: 32px;
  border-top: 1px solid var(--rule);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--muted);
  line-height: 1.6;
}
.tm-article-footer p { margin: 0; }
.tm-article-footer a { color: var(--accent); }
