/* =========================================================================
   Blog post — Article page. Editorial reading column, FAQ accordion,
   related reading, and the standard drench CTA. Inherits tokens, type,
   .nav, .footer, and surfaces from ../../styles.css.
   Component prefix: .pp- (post page) and .prose for the reading column.
   Sections: hero (drench) · body (light) · faq (light) · related (light)
            · cta (drench).
   ========================================================================= */

/* Section grid overlay — same chrome as the rest of the site. */
.s__grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background-image:
    repeating-linear-gradient(to right,
      var(--grid-line-drench) 0 1px,
      transparent 1px calc(100% / 12));
}
.s[data-surface="light"] .s__grid,
.s[data-surface="white"] .s__grid {
  background-image:
    repeating-linear-gradient(to right,
      var(--grid-line-light) 0 1px,
      transparent 1px calc(100% / 12));
}

/* ============================================================
   POST HERO — Drench. Title is editorial, not the full triplet
   the home/landing uses; one short kicker line carries breadcrumbs.
   ============================================================ */
.pp-hero {
  min-height: 78vh;
  padding-top: calc(var(--section-y) + 60px);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}
.pp-hero__inner {
  position: relative;
  z-index: 3;
  width: 100%;
  display: grid;
  gap: clamp(20px, 3vw, 36px);
  align-content: end;
}

.pp-hero__ticker {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  opacity: 0.85;
  margin: 0;
  flex-wrap: wrap;
}
.pp-hero__crumb {
  color: var(--white);
  opacity: 0.85;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  padding-bottom: 1px;
  transition: opacity 180ms var(--ease-out-quart),
              border-color 180ms var(--ease-out-quart);
}
.pp-hero__crumb:hover {
  opacity: 1;
  border-bottom-color: var(--white);
}
.pp-hero__sep { opacity: 0.5; }

.pp-hero__display {
  font-size: clamp(2.5rem, 6.8vw, 5.75rem);
  line-height: 0.92;
  letter-spacing: -0.04em;
  max-width: 18ch;
}
.pp-hero__display .echo {
  color: var(--white);
  opacity: 0.55;
}
.pp-hero__lede {
  max-width: 56ch;
  font-size: clamp(1.0625rem, 1.4vw, 1.375rem);
  line-height: 1.5;
  opacity: 0.92;
}
.pp-hero__byline {
  opacity: 0.78;
  margin: 0;
}
.pp-hero__byline strong {
  color: var(--white);
  font-weight: 500;
}

/* ============================================================
   POST BODY — Light. Single editorial reading column.
   Constrained line length, tuned vertical rhythm.
   ============================================================ */
.pp-body__inner {
  position: relative;
  z-index: 2;
  display: grid;
  justify-items: start;
}

.prose {
  max-width: 68ch;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: clamp(1.0625rem, 1.2vw, 1.1875rem);
  line-height: 1.65;
}

.prose > * + * { margin-top: 1.2em; }

.prose p { margin: 0; color: var(--graphite); text-wrap: pretty; }
.prose p strong { color: var(--ink); font-weight: 500; }
.prose p em { font-style: italic; }

.prose__lede {
  font-size: clamp(1.1875rem, 1.5vw, 1.4375rem);
  line-height: 1.5;
  color: var(--ink) !important;
  font-weight: 400;
}

.prose h2 {
  margin-top: 2.4em;
  font-family: var(--font-display);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  font-size: clamp(1.625rem, 2.6vw, 2.25rem);
  line-height: 1.05;
  color: var(--ink);
  text-wrap: balance;
  max-width: 22ch;
  scroll-margin-top: 96px;
}

.prose h3 {
  margin-top: 1.8em;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.01em;
  font-size: clamp(1.25rem, 1.7vw, 1.5rem);
  line-height: 1.15;
  color: var(--ink);
  max-width: 36ch;
  scroll-margin-top: 96px;
}

.prose__list {
  margin: 0;
  padding-left: 1.2em;
  display: grid;
  gap: 0.6em;
  color: var(--graphite);
}
.prose__list li { padding-left: 0.2em; }
.prose__list li strong { color: var(--ink); font-weight: 500; }
.prose__list li::marker { color: var(--rocket-blue); font-weight: 500; }

ol.prose__list { list-style: decimal; }
ul.prose__list { list-style: disc; }

/* Pull quote — used for the "One control layer" verdict line. */
.prose__pull {
  margin: 1.6em 0;
  padding: 0 0 0 clamp(16px, 2vw, 22px);
  border-left: 3px solid var(--rocket-blue);
}
.prose__pull p {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--ink) !important;
  margin: 0;
  text-wrap: balance;
  max-width: 22ch;
}

/* Customer quote — figure + figcaption, attributed below. */
.prose__quote {
  margin: 1.6em 0;
  padding: clamp(20px, 2.4vw, 30px);
  background: var(--white-smoke);
  border-left: 3px solid var(--rocket-blue);
  display: grid;
  gap: 14px;
}
.prose__quote blockquote { margin: 0; }
.prose__quote blockquote p {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.1875rem, 1.7vw, 1.4375rem);
  line-height: 1.4;
  color: var(--ink) !important;
  margin: 0;
  text-wrap: pretty;
}
.prose__quote figcaption {
  color: var(--graphite);
  opacity: 0.85;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ============================================================
   .fig — Article graphics. Three required per article: an
   architectural diagram, a numbers panel, and a customer quote
   card. Each .fig breaks out of the 68ch prose column to fill
   the wider article container.
   ============================================================ */
.fig {
  margin: clamp(32px, 4.5vw, 56px) 0;
  max-width: 960px;
  width: 100%;
}
.fig__caption {
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--graphite);
  opacity: 0.78;
  max-width: 60ch;
}

/* DIAGRAM — Architecture as a wireframe SVG. */
.fig--diagram {
  background: var(--white);
  border: 1px solid rgba(10, 10, 10, 0.12);
  padding: clamp(20px, 3vw, 36px);
}
.fig__svg {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
}

/* NUMBERS PANEL — 4-up grid of Arteks display numerals. */
.fig--numbers {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  border-top: 2px solid var(--rocket-blue);
  border-bottom: 2px solid var(--rocket-blue);
}
.fig__cell {
  padding: clamp(22px, 3vw, 38px) clamp(14px, 1.6vw, 22px);
  border-right: 1px solid rgba(10, 10, 10, 0.14);
  display: grid;
  gap: 12px;
  align-content: start;
}
.fig__cell:last-child { border-right: none; }
.fig__num {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.25rem, 5.4vw, 4.5rem);
  line-height: 0.88;
  letter-spacing: -0.045em;
  color: var(--rocket-blue);
  text-transform: uppercase;
}
.fig__lbl {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  color: var(--graphite);
  max-width: 22ch;
  line-height: 1.4;
  text-transform: uppercase;
}

@media (max-width: 720px) {
  .fig--numbers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fig__cell { border-right: none; border-bottom: 1px solid rgba(10, 10, 10, 0.14); }
  .fig__cell:nth-child(odd) { border-right: 1px solid rgba(10, 10, 10, 0.14); }
  .fig__cell:nth-last-child(-n+2) { border-bottom: none; }
}

/* QUOTE CARD — Portrait + display-weight quote + attribution badge. */
.fig--quote {
  display: grid;
  grid-template-columns: clamp(96px, 12vw, 144px) 1fr;
  gap: clamp(20px, 3vw, 36px);
  align-items: start;
  background: var(--white-smoke);
  border-left: 3px solid var(--rocket-blue);
  padding: clamp(24px, 3vw, 40px);
}
.fig__portrait {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  background: var(--white);
}
.fig__quote-body {
  display: grid;
  gap: clamp(16px, 2vw, 24px);
}
.fig__quote-body blockquote { margin: 0; }
.fig__quote-body blockquote p {
  margin: 0 !important;
  font-family: var(--font-display) !important;
  font-weight: 400 !important;
  font-size: clamp(1.125rem, 1.6vw, 1.4375rem) !important;
  line-height: 1.4 !important;
  letter-spacing: -0.01em;
  color: var(--ink) !important;
  text-wrap: pretty;
}
.fig--quote figcaption {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 22px);
  flex-wrap: wrap;
}
.fig__attr-name {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ink);
  font-size: 0.9375rem;
}
.fig__attr-role {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  color: var(--graphite);
  text-transform: uppercase;
}
.fig__attr-logo {
  height: 26px;
  width: auto;
  display: block;
  opacity: 0.88;
  margin-left: auto;
}

@media (max-width: 600px) {
  .fig--quote { grid-template-columns: 1fr; }
  .fig__portrait { max-width: 120px; }
  .fig__attr-logo { margin-left: 0; }
}

/* Verdict — used as the close of section 1 ("Never go dark."). */
.prose__verdict {
  color: var(--ink) !important;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.125rem, 1.4vw, 1.3125rem);
  line-height: 1.25;
}

/* ============================================================
   FAQ — Light. details/summary accordion. Marker is a custom
   plus/minus drawn from currentColor so it matches the type.
   ============================================================ */
.pp-faq__inner {
  position: relative;
  z-index: 2;
  display: grid;
  gap: clamp(36px, 4vw, 56px);
}
.pp-faq__head {
  display: grid;
  gap: 14px;
  max-width: 36ch;
}
.pp-faq__eyebrow { color: var(--rocket-blue); margin: 0; }
.pp-faq__title {
  color: var(--ink);
  font-size: clamp(1.75rem, 3.6vw, 3rem);
  line-height: 1.0;
  max-width: 22ch;
}

.pp-faq__list {
  display: grid;
  gap: 0;
  border-top: 1px solid rgba(10, 10, 10, 0.18);
  max-width: 76ch;
}
.pp-faq__item {
  border-bottom: 1px solid rgba(10, 10, 10, 0.18);
  padding: clamp(18px, 2.2vw, 28px) 0;
}
.pp-faq__item summary {
  list-style: none;
  cursor: pointer;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.0625rem, 1.4vw, 1.25rem);
  line-height: 1.25;
  color: var(--ink);
  text-wrap: balance;
}
.pp-faq__item summary::-webkit-details-marker { display: none; }
.pp-faq__item summary::after {
  content: "+";
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--rocket-blue);
  transition: transform 240ms var(--ease-out-quart);
}
.pp-faq__item[open] summary::after {
  content: "−";
  transform: rotate(0deg);
}
.pp-faq__item p {
  margin: 16px 0 0 0;
  color: var(--graphite);
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.15vw, 1.0625rem);
  line-height: 1.6;
  max-width: 64ch;
  text-wrap: pretty;
}
.pp-faq__item p strong { color: var(--ink); font-weight: 500; }

/* ============================================================
   RELATED — Light. Three editorial rows. Same affordance model
   as the case-studies and blog index rows.
   ============================================================ */
.pp-related__inner {
  position: relative;
  z-index: 2;
  display: grid;
  gap: clamp(36px, 4vw, 56px);
}
.pp-related__head {
  display: grid;
  gap: 14px;
  max-width: 36ch;
}
.pp-related__eyebrow { color: var(--rocket-blue); margin: 0; }
.pp-related__title {
  color: var(--ink);
  font-size: clamp(1.75rem, 3.6vw, 3rem);
  line-height: 1.0;
}

.pp-related__rows {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
  border-top: 1px solid rgba(10, 10, 10, 0.18);
}
.pp-related__row {
  border-bottom: 1px solid rgba(10, 10, 10, 0.18);
}
.pp-related__link {
  display: grid;
  gap: clamp(8px, 1.2vw, 14px);
  padding: clamp(22px, 3vw, 36px) 0;
  color: var(--ink);
  position: relative;
  transition: padding-left 280ms var(--ease-out-quart);
}
.pp-related__kicker {
  color: var(--rocket-blue);
}
.pp-related__title-line {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  font-size: clamp(1.25rem, 2vw, 1.875rem);
  line-height: 1.05;
  color: var(--ink);
  text-wrap: balance;
  max-width: 28ch;
  transition: color 220ms var(--ease-out-quart);
}
.pp-related__cta {
  color: var(--rocket-blue);
  display: inline-flex;
  gap: 10px;
  align-items: center;
  margin-top: 4px;
}
.pp-related__link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 0;
  height: 2px;
  background: var(--rocket-blue);
  transform: translateY(-50%);
  transition: width 280ms var(--ease-out-quart);
  pointer-events: none;
}
.pp-related__link:hover,
.pp-related__link:focus-visible {
  outline: none;
  padding-left: 20px;
}
.pp-related__link:hover::before,
.pp-related__link:focus-visible::before {
  width: 12px;
}
.pp-related__link:hover .pp-related__title-line,
.pp-related__link:focus-visible .pp-related__title-line {
  color: var(--rocket-blue);
}
.pp-related__link:focus-visible {
  outline: 2px solid var(--rocket-blue);
  outline-offset: 4px;
}

/* ============================================================
   CTA — Drench. Same as the studies and blog index.
   ============================================================ */
.pp-cta {
  min-height: 60vh;
  display: flex;
  align-items: center;
}
.pp-cta__inner {
  position: relative;
  z-index: 2;
  display: grid;
  gap: clamp(18px, 2.5vw, 32px);
  max-width: 32ch;
}
.pp-cta__eyebrow { opacity: 0.7; margin: 0; }
.pp-cta__display {
  font-size: clamp(3rem, 10vw, 7.5rem);
  line-height: 0.86;
  letter-spacing: -0.045em;
}
.pp-cta__lede { max-width: 48ch; }
.pp-cta__actions {
  margin-top: clamp(8px, 2vw, 24px);
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.pp-cta__btn {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 14px 22px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: background-color 180ms var(--ease-out-quart),
              color 180ms var(--ease-out-quart),
              transform 240ms var(--ease-out-quart);
}
.pp-cta__btn--primary {
  background: var(--white);
  color: var(--rocket-blue);
  border: 1px solid var(--white);
}
.pp-cta__btn--primary:hover {
  background: transparent;
  color: var(--white);
  transform: translateY(-1px);
}
.pp-cta__btn--ghost {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.5);
}
.pp-cta__btn--ghost:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}
.pp-cta__btn:focus-visible {
  outline: 2px solid var(--white);
  outline-offset: 3px;
}

/* Entrance choreography — same one-shot pattern. */
.reveal { opacity: 1; transform: none; }
html.has-js .reveal {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 720ms var(--ease-out-quint),
    transform 720ms var(--ease-out-quint);
  transition-delay: calc(var(--i, 0) * 80ms);
  will-change: opacity, transform;
}
html.has-js .reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .pp-cta__btn,
  .pp-related__link,
  .pp-related__title-line,
  .pp-related__link::before,
  .pp-faq__item summary::after { transition: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* Narrow viewports — keep the prose column comfortable. */
@media (max-width: 720px) {
  .pp-hero__display { font-size: clamp(2.25rem, 9vw, 3.5rem); }
  .prose { font-size: 1.0625rem; }
  .prose h2 { font-size: clamp(1.4375rem, 5.5vw, 1.875rem); max-width: 26ch; }
  .prose h3 { font-size: clamp(1.125rem, 4.5vw, 1.375rem); }
}
