/* =================== hc-blog.css =================== */
/* v7.61.16 — Blog page premium styling.
   Fixes: signals strip slipping, TOC margin, share button polish. */

/* ─── INDEX PAGE ─────────────────────────────────────────────── */

.hc-blog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--hc-sp-4);
}

.hc-blog-latest-slot { min-height: 0; }
.hc-blog-latest-slot:empty { display: none; }

@media (max-width: 980px) {
  .hc-blog-grid { grid-template-columns: 1fr; }
}











/* ─── DETAIL PAGE ────────────────────────────────────────────── */





































/* v7.66 — blog detail: desktop TOC sidebar grid (base rule was missing, so the
   2-col magazine layout never rendered on desktop). */
.page-blog-detail .blog-detail__layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}
.page-blog-detail .blog-detail__layout:has(.blog-toc.is-hidden) {
  grid-template-columns: minmax(0, 1fr);
}
.page-blog-detail .blog-toc {
  position: sticky;
  top: 96px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
}

@media (max-width: 980px) {
  .page-blog-detail .blog-detail__layout,
  .page-blog-detail .blog-detail__layout:has(.blog-toc.is-hidden) { grid-template-columns: 1fr; }
  .page-blog-detail .blog-toc { position: static; max-height: none; }
}

/* ==========================================================
   v7.61.20 · Blog premium polish
   ========================================================== */

/* Index · featured card hover effect */
.hc-blog-featured {
position:relative;
  overflow:hidden;
  transition:transform 0.32s cubic-bezier(0.22,1,0.36,1);
}
.hc-blog-featured:hover {
transform:translateY(-2px);
}
.hc-blog-featured__cover {
transition:transform 0.62s cubic-bezier(0.22,1,0.36,1);
}


/* Index · topic chip count badge */
.hc-blog-topic-chip {
position:relative;
}
.hc-blog-topic-chip__count {
display:inline-block;
  margin-left:6px;
  padding:1px 6px;
  background:rgba(180,151,115,0.14);
  border-radius:100px;
  font:500 10px/1.4 "JetBrains Mono",ui-monospace,monospace;
  color:rgba(26,23,20,0.55);
}

/* Detail · reading progress bar (top of page) */
.hc-blog-progress {
position:fixed;
  top:0;
  left:0;
  right:0;
  height:3px;
  background:transparent;
  z-index:99;
  pointer-events:none;
}
.hc-blog-progress__fill {
height:100%;
  background:linear-gradient(90deg,#c8a96a,#a78648);
  width:0%;
  transition:width 0.05s linear;
}

/* Detail · TOC scroll-spy active */
.hc-blog-toc__item {
display:block;
  padding:6px 12px;
  color:rgba(26,23,20,0.62);
  font-size:13px;
  text-decoration:none;
  border-left:2px solid transparent;
  transition:color 0.18s ease, border-color 0.18s ease;
}
.hc-blog-toc__item:hover {
color:var(--hc-ink, #1a1714);
}
.hc-blog-toc__item.is-active {
color:var(--hc-ink, #1a1714);
  border-left-color:#c8a96a;
  font-weight:500;
}

/* Detail · pull-quote with decorative marks */
.hc-blog-quote {
position:relative;
  padding:24px 32px;
  font:italic 400 18px/1.5 "Playfair Display",Georgia,serif;
  color:var(--hc-ink, #1a1714);
  text-align:center;
  border-top:0.5px solid rgba(180,151,115,0.22);
  border-bottom:0.5px solid rgba(180,151,115,0.22);
  margin:24px 0;
}
.hc-blog-quote::before, .hc-blog-quote::after {
font:400 38px/1 "Playfair Display",Georgia,serif;
  color:#c8a96a;
  position:absolute;
}
.hc-blog-quote::before {
content:"«"; left:8px; top:8px;
}
.hc-blog-quote::after {
content:"»"; right:8px; bottom:0;
}

/* Detail · callout variants (warning/info/pro-tip) */
.hc-blog-callout {
display:flex;
  gap:12px;
  padding:14px 18px;
  border-radius:10px;
  margin:18px 0;
  border-left:3px solid;
  font-size:14px;
  line-height:1.5;
}
.hc-blog-callout--warning {
background:rgba(184,115,28,0.06);
  border-color:#b8731c;
  color:var(--hc-ink, #1a1714);
}
.hc-blog-callout--warning::before {
content:"⚠"; font-size:18px; color:#b8731c;
}
.hc-blog-callout--info {
background:rgba(180,151,115,0.06);
  border-color:#c8a96a;
}
.hc-blog-callout--info::before {
content:"ℹ"; font-size:18px; color:#c8a96a;
}
.hc-blog-callout--tip {
background:rgba(61,107,79,0.06);
  border-color:var(--hc-success, #3d6b4f);
}
.hc-blog-callout--tip::before {
content:"✦"; font-size:16px; color:var(--hc-success, #3d6b4f);
}

/* Detail · share buttons hover */
.hc-blog-share__btn {
transition:transform 0.18s ease, color 0.18s ease;
}
.hc-blog-share__btn:hover {
transform:translateY(-1px);
  color:var(--hc-ink, #1a1714);
}
.hc-blog-share__btn.is-copied {
color:var(--hc-success, #3d6b4f);
}
.hc-blog-share__btn.is-copied::after {
content:" ✓";
}

/* Detail · author byline */
.hc-blog-author {
display:grid;
  grid-template-columns:auto 1fr auto;
  gap:14px;
  align-items:center;
  padding:18px;
  background:rgba(212,184,150,0.06);
  border-radius:12px;
  margin:24px 0;
}
.hc-blog-author__avatar {
width:48px;
  height:48px;
  border-radius:50%;
  background:linear-gradient(135deg,#c8a96a,#a78648);
  color:var(--hc-ink, #1a1714);
  display:grid;
  place-items:center;
  font:600 16px/1 "Inter",sans-serif;
}
.hc-blog-author__name {
font:500 14px/1.2 "Inter",sans-serif;
  color:var(--hc-ink, #1a1714);
}
.hc-blog-author__role {
font:500 11px/1.2 "JetBrains Mono",ui-monospace,monospace;
  letter-spacing:0.06em;
  text-transform:uppercase;
  color:rgba(26,23,20,0.55);
}

/* ──────────────────────────────────────────────────────────────
   Article prose — typography for the editorial body of a blog post.
   Scoped to .blog-detail__body .trust-content so it only affects the
   rendered article HTML (post.body) and nothing else on the page.
   Built on project design tokens (serif headings / sans body / gold
   accent) for a magazine-grade reading rhythm.
   ────────────────────────────────────────────────────────────── */
.blog-detail__body .trust-content {
  width: 100%;
  max-width: 72ch;
  min-width: 0;
  font-family: var(--hc-sans);
  font-size: var(--hc-fs-lg, 16px);
  line-height: var(--hc-lh-loose, 1.7);
  color: var(--hc-ink-soft, rgba(26, 23, 20, 0.7));
  overflow-wrap: anywhere;
}

/* Vertical rhythm: space comes from the *top* of block elements so
   the flow stays even regardless of which tag follows which. */
.blog-detail__body .trust-content > * + * {
  margin-top: var(--hc-sp-4, 16px);
}

.blog-detail__body .trust-content p {
  margin: 0;
}

.blog-detail__body .trust-content h2,
.blog-detail__body .trust-content h3,
.blog-detail__body .trust-content h4 {
  font-family: var(--hc-serif);
  font-weight: 500;
  color: var(--hc-ink, #1a1714);
  line-height: var(--hc-lh-snug, 1.25);
  letter-spacing: -0.01em;
}

.blog-detail__body .trust-content h2 {
  margin-top: var(--hc-sp-8, 64px);
  font-size: var(--hc-fs-3xl, 28px);
  padding-bottom: var(--hc-sp-3, 12px);
  border-bottom: 1px solid var(--hc-line, rgba(26, 23, 20, 0.08));
}

.blog-detail__body .trust-content h3 {
  margin-top: var(--hc-sp-7, 48px);
  font-size: var(--hc-fs-2xl, 22px);
}

.blog-detail__body .trust-content h4 {
  margin-top: var(--hc-sp-6, 32px);
  font-size: var(--hc-fs-xl, 18px);
}

/* First heading shouldn't push a huge gap below the cover/meta. */
.blog-detail__body .trust-content > h2:first-child,
.blog-detail__body .trust-content > h3:first-child {
  margin-top: 0;
}

.blog-detail__body .trust-content ul,
.blog-detail__body .trust-content ol {
  margin: var(--hc-sp-4, 16px) 0 0;
  padding-left: var(--hc-sp-5, 24px);
  display: grid;
  gap: var(--hc-sp-2, 8px);
}

.blog-detail__body .trust-content li {
  padding-left: var(--hc-sp-1, 4px);
}

.blog-detail__body .trust-content ul li::marker {
  color: var(--hc-accent, #8b7355);
}

.blog-detail__body .trust-content a {
  color: var(--hc-accent-dark, #5d4d3a);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}

.blog-detail__body .trust-content strong,
.blog-detail__body .trust-content b {
  color: var(--hc-ink, #1a1714);
  font-weight: 600;
}

.blog-detail__body .trust-content img {
  display: block;
  width: 100%;
  height: auto;
  margin-top: var(--hc-sp-5, 24px);
  border-radius: 14px;
}

.blog-detail__body .trust-content blockquote {
  margin: var(--hc-sp-5, 24px) 0 0;
  padding: var(--hc-sp-4, 16px) var(--hc-sp-5, 24px);
  border-left: 3px solid var(--hc-gold, #d4b896);
  background: var(--hc-gold-soft, rgba(212, 184, 150, 0.15));
  border-radius: 0 12px 12px 0;
  font-size: var(--hc-fs-xl, 18px);
  color: var(--hc-ink, #1a1714);
}

.blog-detail__body .trust-content table {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  border-collapse: collapse;
  margin-top: var(--hc-sp-5, 24px);
  font-size: var(--hc-fs-md, 14px);
  -webkit-overflow-scrolling: touch;
}

.blog-detail__body .trust-content th,
.blog-detail__body .trust-content td {
  padding: var(--hc-sp-3, 12px);
  border: 1px solid var(--hc-line, rgba(26, 23, 20, 0.08));
  text-align: left;
  overflow-wrap: normal;
}

.blog-detail__body .trust-content th {
  background: var(--hc-bg-warm, #f0ebe1);
  color: var(--hc-ink, #1a1714);
  font-weight: 600;
}

/* ──────────────────────────────────────────────────────────────
   Article meta bar — author / date / reading-time / tag pills that
   sit under the H1. The template emits .article-meta-pill spans with
   no styling, so they collapse into one run of text. Lay them out as
   spaced chips.
   ────────────────────────────────────────────────────────────── */
.article-meta-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--hc-sp-2, 8px);
  margin-top: var(--hc-sp-4, 16px);
}

.article-meta-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--hc-sp-1, 4px);
  padding: 6px var(--hc-sp-3, 12px);
  border: 1px solid var(--hc-line, rgba(26, 23, 20, 0.08));
  border-radius: 999px;
  font: 500 var(--hc-fs-xs, 12px) / 1 "JetBrains Mono", ui-monospace, monospace;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--hc-ink-mid, rgba(26, 23, 20, 0.55));
  white-space: nowrap;
}

.article-meta-pill--accent {
  background: var(--hc-gold-soft, rgba(212, 184, 150, 0.15));
  border-color: var(--hc-gold-border, rgba(212, 184, 150, 0.38));
  color: var(--hc-accent-dark, #5d4d3a);
}

/* ──────────────────────────────────────────────────────────────
   Route summary — the three "what's inside" hint pills above the
   article. Same problem: emitted unstyled. Render as a soft card row.
   ────────────────────────────────────────────────────────────── */
.hz-summary-shell {
  margin: var(--hc-sp-5, 24px) 0;
  padding: var(--hc-sp-4, 16px) var(--hc-sp-5, 24px);
  background: var(--hc-bg-2, #f7f3ec);
  border: 1px solid var(--hc-line, rgba(26, 23, 20, 0.08));
  border-radius: 16px;
}

.hz-summary-shell__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--hc-sp-2, 8px) var(--hc-sp-5, 24px);
}

.hz-summary-pill {
  font-size: var(--hc-fs-md, 14px);
  line-height: var(--hc-lh-snug, 1.25);
  color: var(--hc-ink-soft, rgba(26, 23, 20, 0.7));
}

.hz-summary-pill b {
  color: var(--hc-ink, #1a1714);
  font-weight: 600;
}

/* ──────────────────────────────────────────────────────────────
   Table of contents — built client-side from h2/h3. Until JS runs it
   carries .is-hidden; style both the hidden state and the rendered
   list so it never shows as a raw run of link text.
   ────────────────────────────────────────────────────────────── */
.blog-toc.is-hidden { display: none; }

.blog-toc__title {
  font: 600 var(--hc-fs-xs, 12px) / 1 "JetBrains Mono", ui-monospace, monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--hc-ink-mid, rgba(26, 23, 20, 0.55));
  margin-bottom: var(--hc-sp-3, 12px);
}

.blog-toc__link {
  display: block;
  padding: var(--hc-sp-1, 4px) 0;
  font-size: var(--hc-fs-md, 14px);
  line-height: var(--hc-lh-snug, 1.25);
  color: var(--hc-ink-soft, rgba(26, 23, 20, 0.7));
  text-decoration: none;
  border-left: 2px solid transparent;
  padding-left: var(--hc-sp-3, 12px);
  transition: color var(--hc-dur-fast, 0.15s) var(--hc-ease, ease),
              border-color var(--hc-dur-fast, 0.15s) var(--hc-ease, ease);
}

.blog-toc__link:hover {
  color: var(--hc-accent-dark, #5d4d3a);
  border-left-color: var(--hc-gold, #d4b896);
}

.blog-toc__link--lvl3 {
  padding-left: var(--hc-sp-5, 24px);
  font-size: var(--hc-fs-sm, 13px);
}

/* Article share buttons (#blogShare .share-btn) had no styles → raw SVG + bare
   text. Clean outline pills with icon + label. */
.share-btns {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 0.5px solid var(--hc-line-2, rgba(180, 151, 115, 0.3));
  border-radius: 999px;
  background: var(--hc-paper, #ffffff);
  color: var(--hc-ink-soft, rgba(26, 23, 20, 0.7));
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
.share-btn:hover {
  border-color: var(--hc-accent, #8b7355);
  color: var(--hc-accent, #8b7355);
}
.share-btn svg {
  flex: 0 0 auto;
}
