/* Article-specific design; shared homepage styles remain the source of truth. */
.post-page .skip-link { position: absolute; top: 10px; left: 16px; z-index: 100; padding: 10px 16px; background: var(--cv-ink); color: var(--cv-cream); transform: translateY(-160%); }
.post-page .skip-link:focus { transform: none; }

.post-page .post-hero { padding: 88px 0 72px; border-bottom: 1px solid rgba(22, 19, 14, .18); }
.post-page .post-hero-copy { max-width: 980px; margin-inline: auto; text-align: center; }
.post-page .post-hero h1 { font-size: var(--cv-title-hero); line-height: 1; letter-spacing: .025em; text-transform: uppercase; text-wrap: balance; }
.post-page .post-hero h1 span { display: inline-block; color: var(--cv-accent); }
.post-page .post-hero-copy > p:last-child { max-width: 760px; margin: 32px auto 0; font-size: 18px; font-weight: 500; line-height: 1.55; color: var(--cv-ink-2); }
.post-page .post-body { padding: 80px 0 104px; }
.post-page .post-layout { display: grid; grid-template-columns: minmax(0, 780px); justify-content: center; }
.post-page .post-article { min-width: 0; color: var(--cv-ink-2); }
.post-page .post-article p { font-size: var(--cv-body-size); line-height: 1.7; }
.post-page .post-article p + p { margin-top: 22px; }
.post-page .article-intro { padding-bottom: 40px; }
.post-page .content-block { position: relative; scroll-margin-top: 28px; padding-top: 40px; border-top: 4px solid var(--cv-ink); }
.post-page .content-block::before { content: ""; position: absolute; top: -4px; left: 0; width: 64px; height: 4px; background: var(--cv-constructivist-red); transform: skewX(-28deg); }
.post-page .content-block + .content-block { margin-top: 56px; }
.post-page .post-article .section-number { margin-bottom: 14px; color: transparent; -webkit-text-stroke: 1px var(--cv-accent); font: 700 32px/1 var(--cv-display); }
.post-page .content-block h2 { margin-bottom: 24px; color: var(--cv-ink); font-size: var(--cv-title-section); line-height: 1.12; text-transform: uppercase; text-wrap: pretty; }
.post-page .content-block h3 { margin: 32px 0 12px; color: var(--cv-ink); font-size: 28px; line-height: 1.15; text-transform: uppercase; }
.post-page .content-block h4 { margin: 26px 0 12px; color: var(--cv-ink); font-size: 23px; line-height: 1.2; text-transform: uppercase; }
.post-page .article-quote { position: relative; margin: 32px 0; padding: 30px 32px; border: 4px solid var(--cv-ink); border-left: 10px solid var(--cv-accent); background: var(--cv-paper); box-shadow: 8px 8px 0 var(--cv-ink); }
.post-page .article-quote p { color: var(--cv-ink); font: 700 clamp(26px, 3vw, 34px)/1.2 var(--cv-display); }
.post-page .principle-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin: 30px 8px 36px 0; }
.post-page .principle-grid article { min-width: 0; padding: 24px; border: 3px solid var(--cv-ink); background: var(--cv-paper); box-shadow: 6px 6px 0 var(--cv-ink); }
.post-page .principle-grid article > span { display: inline-grid; place-items: center; width: 36px; height: 36px; background: var(--cv-ink); color: var(--cv-cream); font: 700 20px/1 var(--cv-display); }
.post-page .principle-grid article:nth-child(2) > span { background: var(--cv-accent); }
.post-page .principle-grid article:nth-child(3) > span { background: var(--cv-constructivist-red); }
.post-page .principle-grid h3 { margin: 18px 0 10px; font-size: 25px; }
.post-page .principle-grid p { font-size: 16px; line-height: 1.6; }
.post-page .code-block-wrap { position: relative; min-width: 0; margin: 32px 10px 38px 0; border: 4px solid var(--cv-ink); background: var(--cv-ink); box-shadow: 10px 10px 0 var(--cv-accent); }
.post-page .code-block-wrap::after { content: ""; position: absolute; top: 14px; right: -14px; width: 10px; height: 30%; background: var(--cv-constructivist-red); clip-path: polygon(0 0,100% 0,100% 90%,0 100%); pointer-events: none; }
.post-page .code-block-label { display: flex; justify-content: space-between; align-items: center; gap: 18px; padding: 18px 22px; background: var(--cv-paper); border-bottom: 4px solid var(--cv-ink); }
.post-page .code-block-label span { display: block; font: 700 20px/1.1 var(--cv-display); text-transform: uppercase; }
.post-page .code-block-label small { display: block; margin-top: 6px; font-size: 12px; }
.post-page .post-copy { flex: none; display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 10px 14px; border: 2px solid var(--cv-ink); border-radius: 0; background: var(--cv-accent); color: var(--cv-cream); cursor: pointer; font: 700 16px/1 var(--cv-display); text-transform: uppercase; }
.post-page .post-copy:hover { background: var(--cv-ink); }
.post-page .post-copy-status:empty { display: none; }
.post-page .post-copy-status { padding: 12px 22px; color: var(--cv-paper); }
.post-page .article-code { max-height: 600px; overflow: auto; margin: 0; padding: 26px; color: var(--cv-paper); font: 400 14px/1.8 ui-monospace, SFMono-Regular, Consolas, monospace; white-space: pre-wrap; overflow-wrap: anywhere; scrollbar-color: var(--cv-paper) var(--cv-ink); }
.post-page .workflow-line { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 32px 0; padding: 22px; border: 3px solid var(--cv-ink); background: var(--cv-paper); }
.post-page .workflow-line > div { min-width: 0; text-align: center; }
.post-page .workflow-line span { display: block; margin-bottom: 8px; color: var(--cv-accent); font: 700 20px/1 var(--cv-display); }
.post-page .workflow-line strong { font: 700 19px/1.2 var(--cv-display); text-transform: uppercase; }
.post-page .workflow-line i { color: var(--cv-constructivist-red); font-style: normal; }
.post-page .callout-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; margin: 30px 0; border: 3px solid var(--cv-ink); border-left: 8px solid var(--cv-accent); padding: 26px; background: var(--cv-paper); }
.post-page .callout-icon { display: grid; width: 40px; height: 40px; place-items: center; background: var(--cv-ink); color: var(--cv-cream); }
.post-page .callout-card strong { display: block; margin-bottom: 12px; font: 700 25px/1.15 var(--cv-display); text-transform: uppercase; }

@media (max-width: 1020px) {
  .post-page .post-hero { padding: 64px 0; }
  .post-page .post-hero h1 { font-size: clamp(2.8rem, 7.5vw, 4.3rem); }
  .post-page .post-layout { grid-template-columns: minmax(0, 1fr); gap: 44px; max-width: 780px; }
}
@media (max-width: 700px) {
  .post-page .post-hero { padding: 44px 0 48px; }
  .post-page .post-hero h1 { font-size: clamp(2.05rem, 10vw, 3.4rem); }
  .post-page .post-hero-copy > p:last-child { margin-top: 24px; }
  .post-page .post-body { padding: 40px 0 64px; }
  .post-page .post-article p { line-height: 1.5625; }
  .post-page .content-block { padding-top: 28px; }
  .post-page .content-block + .content-block { margin-top: 40px; }
  .post-page .content-block h2 { font-size: 36px; }
  .post-page .content-block h3 { font-size: 26px; }
  .post-page .article-quote { padding: 24px 20px; margin-right: 8px; }
  .post-page .principle-grid { grid-template-columns: minmax(0,1fr); }
  .post-page .principle-grid p { font-size: 17px; }
  .post-page .code-block-label { align-items: flex-start; flex-direction: column; padding: 18px; }
  .post-page .article-code { padding: 20px 18px; font-size: 13px; }
  .post-page .workflow-line { flex-direction: column; gap: 14px; }
  .post-page .workflow-line i { transform: rotate(90deg); }
  .post-page .callout-card { grid-template-columns: minmax(0,1fr); padding: 22px; }

}

.post-page .eyebrow { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 24px; font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.post-page .eyebrow::before { content: ""; width: 12px; height: 12px; background: var(--cv-constructivist-red); }

/* Give the opening article a quieter transition from the hero. */
.post-page .article-intro + .content-block { border-top: 0; }
.post-page .article-intro + .content-block::before { display: none; }

/* Equal side tracks preserve the original centered article column. */
.post-page .post-layout--sidebar {
  grid-template-columns: minmax(0, 1fr) 740px minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}
.post-page .post-layout--sidebar > .post-article { grid-column: 2; }
.post-page .post-sidebar {
  position: sticky;
  top: 28px;
  min-width: 0;
  max-height: calc(100vh - 56px);
  overflow-y: auto;
  padding: 0;
}
.post-page .post-sidebar-panel {
  padding: 0 0 0 14px;
  border-left: 1px solid rgba(22, 19, 14, .18);
}
.post-page .post-sidebar-panel h2 {
  margin: 0 0 12px;
  color: var(--cv-ink-2);
  font: 700 16px/1.2 var(--cv-display);
  letter-spacing: .06em;
  text-transform: uppercase;
}
.post-page .post-sidebar-panel ol {
  list-style: none;
  counter-reset: post-contents;
  padding: 0;
  margin: 0;
}
.post-page .post-sidebar-panel li { counter-increment: post-contents; }
.post-page .post-sidebar-panel a {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 6px;
  padding: 10px 0;
  color: var(--cv-ink-2);
  font-size: 13px;
  line-height: 1.5;
  text-decoration: none;
}
.post-page .post-sidebar-panel a::before {
  content: counter(post-contents, decimal-leading-zero);
  color: inherit;
  font-weight: 400;
}
.post-page .post-sidebar-panel a:hover { color: var(--cv-accent); text-decoration: underline; }
.post-page .post-sidebar-panel a:focus-visible {
  outline: 3px solid var(--cv-accent);
  outline-offset: 3px;
}
@media (max-width: 1200px) {
  .post-page .post-layout--sidebar { grid-template-columns: minmax(0, 740px); gap: 36px; }
  .post-page .post-layout--sidebar > .post-article { grid-column: 1; }
  .post-page .post-sidebar { position: static; max-height: none; }
}

/* Give the desktop article more breathing room beside its contents list. */
@media (min-width: 1201px) {
  .post-page .post-layout--sidebar {
    grid-template-columns: minmax(0, 1fr) 680px minmax(0, 1fr);
    column-gap: 64px;
  }
}
