/* ==========================================================================
   Article Diplo — Le Monde diplomatique-inspired variant for inff.cc
   Apply by adding class="article-canvas diplo" to the article element.
   ========================================================================== */

/* ── Container ─────────────────────────────────────────────────────────── */
.article-canvas.diplo {
  max-width: 740px;
  margin: 0 auto;
  padding: 2.5rem 2rem;
}

/* ── Surtitre (category + type badge) ──────────────────────────────────── */
.diplo .article-header-meta {
  margin-bottom: 1.2rem;
}

.diplo .meta-category-link {
  font-family: var(--font-display, 'Noto Sans TC', sans-serif);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent, #be2e0d);
  text-decoration: none;
  border-bottom: none;
}

/* ── Title — serif, large, regular weight ──────────────────────────────── */
.diplo .article-title {
  font-family: 'Noto Serif TC', Georgia, 'Times New Roman', serif;
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--fg, #222);
  margin: 0 0 1rem;
}

/* ── Subtitle / Chapo — serif, enlarged, distinct from body ────────────── */
.diplo .article-subtitle {
  font-family: 'Noto Serif TC', Georgia, serif;
  font-size: 1.35rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--fg, #333);
  margin: 0 0 1.5rem;
  padding: 0 0 1.5rem;
  border-bottom: 1px dashed var(--border-soft, #ccc);
}

/* ── Meta line — centered, muted ───────────────────────────────────────── */
.diplo .article-meta-line {
  text-align: center;
  font-family: var(--font-display, 'Noto Sans TC', sans-serif);
  font-size: 0.8rem;
  color: var(--muted, #999);
  letter-spacing: 0.02em;
  margin-bottom: 2rem;
}

/* ── Cover image with caption support ──────────────────────────────────── */
.diplo .article-cover {
  margin: 0 0 2rem;
}

.diplo .article-cover img {
  border-radius: 0;
}

.diplo .article-cover figcaption {
  font-family: var(--font-display, 'Noto Sans TC', sans-serif);
  font-size: 0.75rem;
  color: var(--muted, #999);
  margin-top: 0.5rem;
  line-height: 1.4;
}

/* ── Body text — serif, 読みやすい ─────────────────────────────────────── */
.diplo .article-body,
.diplo .article-body .payload-richtext {
  font-family: var(--font-body, 'Noto Sans TC', sans-serif);
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--fg, #333);
}



/* ── Headings in body — sans-serif contrast ────────────────────────────── */
.diplo .article-body h2,
.diplo .article-body .payload-richtext h2 {
  font-family: var(--font-display, 'Noto Sans TC', sans-serif);
  font-size: 1.4rem;
  font-weight: 700;
  margin: 2.5rem 0 1rem;
  color: var(--fg, #222);
}

.diplo .article-body h3,
.diplo .article-body .payload-richtext h3 {
  font-family: var(--font-display, 'Noto Sans TC', sans-serif);
  font-size: 1.15rem;
  font-weight: 700;
  margin: 2rem 0 0.8rem;
  color: var(--fg, #222);
}

/* ── Blockquote / Pull quote — exergue style ───────────────────────────── */
.diplo .article-body blockquote,
.diplo .article-body .payload-richtext blockquote {
  margin: 2rem 0;
  padding: 1.2rem 0 1.2rem 1.5rem;
  border-left: 4px solid var(--accent, #be2e0d);
  background: none;
  font-family: 'Noto Serif TC', Georgia, serif;
  font-size: 1.25rem;
  font-style: normal;
  line-height: 1.6;
  color: var(--fg, #333);
}

.diplo .article-body blockquote p:last-child,
.diplo .article-body .payload-richtext blockquote p:last-child {
  margin-bottom: 0;
}

/* ── Links ─────────────────────────────────────────────────────────────── */
.diplo .article-body a {
  color: var(--accent, #be2e0d);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.diplo .article-body a:hover {
  color: var(--hover, #fa3b0f);
}

/* ── Separator override ────────────────────────────────────────────────── */
.diplo hr {
  border: none;
  border-top: 1px dashed var(--border-soft, #ccc);
  margin: 2rem 0;
}

/* ── Prev/Next navigation — diplo style ────────────────────────────────── */
.diplo-nav {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  gap: 1rem;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-soft, #e5e7eb);
}

.diplo-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  text-decoration: none;
  color: inherit;
  padding: 0.75rem 0;
  transition: color 0.15s;
}

.diplo-nav-item:hover {
  color: var(--accent, #be2e0d);
}

.diplo-nav-item--next {
  text-align: right;
}

.diplo-nav-label {
  font-family: var(--font-display, 'Noto Sans TC', sans-serif);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted, #999);
}

.diplo-nav-title {
  font-family: 'Noto Serif TC', Georgia, serif;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.4;
}

/* ── Sources section override ──────────────────────────────────────────── */
.diplo .sources-section-title {
  font-family: var(--font-display, 'Noto Sans TC', sans-serif);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ── Dark mode adjustments ─────────────────────────────────────────────── */
[data-mode="dark"] .diplo .article-title {
  color: var(--fg, #e8e8e8);
}

[data-mode="dark"] .diplo .article-body blockquote {
  border-left-color: var(--accent, #e06040);
}

[data-mode="dark"] .diplo .article-body .payload-richtext > p:first-of-type::first-letter {
  color: var(--fg, #e8e8e8);
}

/* ── Mobile ────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .article-canvas.diplo {
    padding: 1.5rem 1rem;
  }

  .diplo .article-title {
    font-size: 1.8rem;
  }

  .diplo .article-subtitle {
    font-size: 1.1rem;
  }

  .diplo .article-body,
  .diplo .article-body .payload-richtext {
    font-size: 1.05rem;
  }



  .diplo-nav {
    flex-direction: column;
  }

  .diplo-nav-item--next {
    text-align: left;
    border-top: 1px dashed var(--border-soft, #ccc);
    padding-top: 0.75rem;
  }
}

/* ── TOC (chapter-rail) — larger text for diplo ────────────────────────── */
.diplo .chapter-rail {
  font-size: 13px;
  line-height: 1.5;
  width: 190px;
}

.diplo .chapter-rail-item {
  padding: 6px 0;
}

.diplo .chapter-rail-item.sub {
  font-size: 11.5px;
}

.diplo .chapter-rail-progress {
  font-size: 11px;
}
