/* ── Warm Digest — article page ───────────────────────────── */

.wd-post-main { padding-bottom: 0; }

/* Two-column layout */
.wd-wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px 80px;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 48px;
  align-items: start;
}
.wd-wrap--single {
  grid-template-columns: 740px;
  justify-content: center;
}
@media (max-width: 900px) {
  .wd-wrap { grid-template-columns: 1fr; padding: 0 16px 60px; }
}

/* ── Article ──────────────────────────────────────────────── */
.wd-article__header {
  padding: 32px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.wd-article__title {
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin: 0;
  color: var(--fg);
}
.wd-article__excerpt {
  font-size: 18px;
  line-height: 1.55;
  color: var(--fg-2);
  margin: 0;
}

/* Byline */
.wd-article__byline {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin: 16px 0 28px;
  font-size: 13px;
  color: var(--fg-2);
  flex-wrap: wrap;
}
.wd-article__author {
  display: flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
  color: var(--fg);
}
.wd-article__author img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
.wd-article__date::before,
.wd-article__read::before { content: "·"; margin-right: 10px; color: var(--border); }

/* Cover */
.wd-article__cover {
  margin: 0 0 32px;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-2);
}
.wd-article__cover img { width: 100%; height: auto; }
.wd-article__cover figcaption { font-size: 12px; color: var(--fg-3); text-align: center; padding: 8px 12px; }

/* Body */
.wd-article__content {
  font-size: 17px;
  line-height: 1.8;
  color: #1c1917;
}
.wd-article__content h2 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 2.2em 0 .6em;
  color: var(--fg);
  padding-left: 14px;
  border-left: 3px solid var(--accent);
}
.wd-article__content h3 {
  font-size: 18px;
  font-weight: 700;
  margin: 1.8em 0 .5em;
  color: var(--fg);
}
.wd-article__content p  { margin: 0 0 1.4em; }
.wd-article__content a  { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.wd-article__content strong { font-weight: 700; }
.wd-article__content em { font-style: italic; }
.wd-article__content blockquote {
  background: var(--bg-2);
  border-left: 3px solid var(--accent);
  border-radius: 0 8px 8px 0;
  margin: 2em 0;
  padding: 14px 18px;
  font-style: italic;
  color: var(--fg-2);
}
.wd-article__content pre {
  background: var(--bg-2);
  border-radius: 8px;
  padding: 18px 20px;
  overflow-x: auto;
  font-size: 14px;
  margin: 0 0 1.4em;
}
.wd-article__content code {
  font-size: .875em;
  background: var(--bg-2);
  padding: 2px 6px;
  border-radius: 4px;
}
.wd-article__content pre code { background: none; padding: 0; }
.wd-article__content img { border-radius: 8px; margin: .5em 0 1.4em; }
.wd-article__content ul,
.wd-article__content ol { padding-left: 1.5em; margin: 0 0 1.4em; }
.wd-article__content li { margin-bottom: .4em; }
.wd-article__content hr { border: none; border-top: 1px solid var(--border); margin: 2.5em 0; }

/* Tags */
.wd-article__tags {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.wd-pill {
  padding: 5px 14px;
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--fg-2);
  background: var(--bg);
  transition: border-color .15s, color .15s, background .15s;
}
.wd-pill:hover { border-color: var(--accent); color: var(--accent); background: #f0fdf4; }

/* ── Sidebar ──────────────────────────────────────────────── */
.wd-sidebar { padding-top: 56px; }
@media (max-width: 900px) { .wd-sidebar { display: none; } }

/* TOC */
.wd-toc {
  margin-bottom: 32px;
  padding: 16px;
  background: var(--bg-2);
  border-radius: var(--radius);
}
.wd-toc__label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin: 0 0 12px;
}
.wd-toc__nav ol { list-style: none; margin: 0; padding: 0; }
.wd-toc__nav li > ol { padding-left: 12px; margin-top: 2px; }
.wd-toc__nav a {
  display: block;
  font-size: 13px;
  line-height: 1.4;
  color: var(--fg-2);
  padding: 4px 6px;
  border-radius: 5px;
  transition: background .12s, color .12s;
}
.wd-toc__nav a:hover { background: var(--border); color: var(--fg); }
.wd-toc__nav a.is-active { background: #dcfce7; color: var(--accent); font-weight: 600; }
.wd-toc:not(:has(a)) { display: none; }

/* Sidebar label */
.wd-sidebar__label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin: 0 0 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

/* Horizontal cards */
.wd-sidebar__cards { display: flex; flex-direction: column; gap: 0; }

.wd-sidebar__card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  transition: opacity .15s;
}
.wd-sidebar__card:last-child { border-bottom: none; }
.wd-sidebar__card:hover { opacity: .75; }

.wd-sidebar__thumb {
  width: 64px;
  height: 64px;
  flex-shrink: 0;
  border-radius: 7px;
  overflow: hidden;
  background: var(--bg-2);
}
.wd-sidebar__thumb img { width: 100%; height: 100%; object-fit: cover; }

.wd-sidebar__card-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.wd-sidebar__card-tag {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--accent);
}
.wd-sidebar__card-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--fg);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.wd-sidebar__card-date { font-size: 11px; color: var(--fg-3); }

/* ── Related posts ────────────────────────────────────────── */
.wd-related { border-top: 1px solid var(--border); }
.wd-related__inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}
.wd-related__title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin: 0 0 20px;
}

/* ── Koenig card classes ───────────────────────────────────── */
.gh-content .kg-width-wide {
  margin-left: calc(50% - 50vw + 24px);
  margin-right: calc(50% - 50vw + 24px);
  max-width: calc(100vw - 48px);
}
.gh-content .kg-width-full {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  max-width: 100vw;
}
.gh-content .kg-image { max-width: 100%; height: auto; border-radius: 8px; }
.gh-content .kg-image-card { margin: 1.5em 0; }
.gh-content .kg-image-card figcaption { font-size: 13px; color: var(--fg-3); text-align: center; margin-top: 8px; }
.gh-content .kg-gallery-container { display: flex; flex-direction: column; gap: 8px; margin: 1.5em 0; }
.gh-content .kg-gallery-row { display: flex; gap: 8px; }
.gh-content .kg-gallery-image img { width: 100%; height: 100%; object-fit: cover; border-radius: 8px; }
.gh-content .kg-bookmark-card { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; margin: 1.5em 0; }
.gh-content .kg-bookmark-container { display: flex; color: inherit; text-decoration: none; }
.gh-content .kg-bookmark-content { padding: 14px; flex: 1; }
.gh-content .kg-bookmark-title { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.gh-content .kg-bookmark-description { font-size: 13px; color: var(--fg-2); }
.gh-content .kg-bookmark-metadata { display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 12px; color: var(--fg-3); }
.gh-content .kg-bookmark-thumbnail { width: 160px; flex-shrink: 0; }
.gh-content .kg-bookmark-thumbnail img { width: 100%; height: 100%; object-fit: cover; }
.gh-content .kg-callout-card { display: flex; gap: 14px; padding: 16px 20px; border-radius: 10px; background: var(--bg-2); border: 1px solid var(--border); margin: 1.5em 0; }
.gh-content .kg-callout-emoji { font-size: 20px; line-height: 1.4; flex-shrink: 0; }
.gh-content .kg-video-card { margin: 1.5em 0; }
.gh-content .kg-video-card video { width: 100%; border-radius: 8px; }
