.validation-page {
  --val-paper: #f5f5f0;
  --val-ink: #060706;
  --val-muted: #8c8d87;
  --val-rule: rgba(245, 245, 240, 0.12);
  --val-orange: #ff7a45;
  background: var(--val-ink);
}

.val-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(7.5rem, 15vh, 11rem) 0 clamp(3rem, 7vw, 5.75rem);
  border-bottom: 1px solid var(--val-rule);
  background:
    radial-gradient(circle at 83% 22%, rgba(255, 122, 69, 0.16), transparent 24rem),
    linear-gradient(rgba(245, 245, 240, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(245, 245, 240, 0.025) 1px, transparent 1px);
  background-size: auto, 48px 48px, 48px 48px;
}

.val-hero::after {
  position: absolute;
  top: 14%;
  right: -8rem;
  width: 28rem;
  height: 28rem;
  border: 1px solid rgba(255, 122, 69, 0.18);
  border-radius: 50%;
  box-shadow: 0 0 0 4rem rgba(255, 122, 69, 0.025), 0 0 0 8rem rgba(255, 122, 69, 0.018);
  content: "";
  pointer-events: none;
}

.val-hero .pg-crumb {
  position: relative;
  z-index: 1;
  margin-bottom: clamp(3rem, 7vw, 5.5rem);
}

.val-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  align-items: end;
  gap: clamp(2rem, 6vw, 7rem);
  grid-template-columns: minmax(0, 1fr) minmax(250px, 0.4fr);
}

.val-hero h1 {
  max-width: 12.5ch;
  margin: 0;
  color: var(--val-paper);
  font: 600 clamp(3.25rem, 7.2vw, 6.9rem)/0.94 "Manrope", "DM Sans", sans-serif;
  letter-spacing: -0.064em;
}

.val-hero .pg-lede {
  max-width: 61ch;
  margin-top: 1.8rem;
}

.val-hero-actions {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  margin-top: 2rem;
}

.val-text-link {
  color: var(--val-paper);
  font-size: 0.86rem;
  font-weight: 600;
}

.val-text-link span {
  margin-left: 0.35rem;
  color: var(--val-orange);
}

.val-hero-readout {
  border-top: 1px solid var(--val-orange);
}

.val-hero-readout > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--val-rule);
}

.val-hero-readout span,
.val-scope-line {
  color: var(--val-muted);
  font: 500 0.62rem/1.4 "JetBrains Mono", monospace;
  letter-spacing: 0.1em;
}

.val-hero-readout strong {
  color: var(--val-paper);
  font: 500 1rem/1 "JetBrains Mono", monospace;
}

.val-scope-line {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 1rem;
  margin-top: clamp(3.5rem, 8vw, 6rem);
  padding-top: 1.1rem;
  border-top: 1px solid var(--val-rule);
  grid-template-columns: repeat(4, 1fr);
}

.val-results-strip {
  padding: clamp(3rem, 6vw, 5rem) 0;
  border-bottom: 1px solid var(--val-rule);
}

.val-strip-label,
.val-source-line {
  margin: 0;
  color: var(--val-muted);
  font: 500 0.62rem/1.55 "JetBrains Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.val-metrics {
  display: grid;
  margin: 1.3rem 0 1.5rem;
  border-top: 1px solid var(--val-rule);
  border-bottom: 1px solid var(--val-rule);
  grid-template-columns: repeat(4, 1fr);
}

.val-metrics article {
  min-height: 14rem;
  padding: 1.45rem 1.5rem 1.3rem 0;
  border-right: 1px solid var(--val-rule);
}

.val-metrics article:not(:first-child) {
  padding-left: 1.5rem;
}

.val-metrics article:last-child {
  border-right: 0;
}

.val-metrics span {
  color: var(--val-orange);
  font: 500 0.62rem/1.2 "JetBrains Mono", monospace;
  letter-spacing: 0.12em;
}

.val-metrics strong {
  display: block;
  margin: 1.2rem 0 2.4rem;
  color: var(--val-paper);
  font: 500 clamp(2.65rem, 5vw, 4.9rem)/0.9 "Manrope", sans-serif;
  letter-spacing: -0.065em;
}

.val-metrics sup {
  color: var(--val-orange);
  font-size: 0.36em;
  vertical-align: top;
}

.val-metrics p {
  max-width: 25ch;
  margin: 0;
  color: var(--val-muted);
  font-size: 0.78rem;
  line-height: 1.5;
}

.val-evidence-section {
  border-bottom: 1px solid var(--val-rule);
}

.val-section-head {
  display: grid;
  align-items: end;
  gap: 1.2rem 3rem;
  grid-template-columns: minmax(0, 0.9fr) minmax(300px, 0.55fr);
}

.val-section-head .ap-eyebrow {
  grid-column: 1 / -1;
}

.val-section-head .ap-title {
  max-width: 15ch;
}

.val-section-head .ap-body {
  margin: 0;
  font-size: 0.95rem;
}

.val-figure-pair {
  display: grid;
  gap: 1px;
  margin-top: clamp(2.5rem, 6vw, 5rem);
  border: 1px solid var(--val-rule);
  background: var(--val-rule);
  grid-template-columns: 1.25fr 0.75fr;
}

.val-figure {
  min-width: 0;
  margin: 0;
  background: #090a09;
}

.val-figure .nadir-figure {
  height: clamp(20rem, 38vw, 33rem);
  border-bottom: 1px solid var(--val-rule);
  background:
    radial-gradient(circle at 50% 35%, rgba(255, 122, 69, 0.045), transparent 52%),
    #070807;
}

.val-figure figcaption {
  display: grid;
  gap: 0.45rem;
  min-height: 9.5rem;
  padding: 1.35rem 1.5rem;
}

.val-figure figcaption span,
.val-method-line span {
  color: var(--val-orange);
  font: 500 0.57rem/1.4 "JetBrains Mono", monospace;
  letter-spacing: 0.1em;
}

.val-figure figcaption strong {
  color: var(--val-paper);
  font-size: 1rem;
}

.val-figure figcaption p {
  max-width: 50ch;
  margin: 0;
  color: var(--val-muted);
  font-size: 0.78rem;
  line-height: 1.5;
}

.val-method-line {
  display: grid;
  border-right: 1px solid var(--val-rule);
  border-bottom: 1px solid var(--val-rule);
  border-left: 1px solid var(--val-rule);
  grid-template-columns: repeat(4, 1fr);
}

.val-method-line span {
  display: grid;
  gap: 0.4rem;
  padding: 1rem 1.2rem;
  border-right: 1px solid var(--val-rule);
  color: var(--val-muted);
}

.val-method-line span:last-child {
  border-right: 0;
}

.val-method-line b {
  color: var(--val-paper);
  font: 500 0.72rem/1.4 "JetBrains Mono", monospace;
}

.val-table-grid {
  display: grid;
  gap: 1.5rem;
  margin-top: clamp(2.5rem, 6vw, 5rem);
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.val-table-block {
  min-width: 0;
  border-top: 2px solid var(--val-paper);
}

.val-table-title {
  display: grid;
  align-items: baseline;
  gap: 0.45rem 1rem;
  padding: 1rem 0;
  grid-template-columns: auto 1fr auto;
}

.val-table-title span,
.val-table-title em {
  color: var(--val-muted);
  font: 500 0.56rem/1.3 "JetBrains Mono", monospace;
  letter-spacing: 0.08em;
}

.val-table-title strong {
  color: var(--val-paper);
  font-size: 0.88rem;
}

.val-table-title em {
  font-style: normal;
}

.val-table-scroll {
  overflow-x: auto;
}

.val-table-block table {
  width: 100%;
  border-collapse: collapse;
  font: 500 0.69rem/1.35 "JetBrains Mono", monospace;
  white-space: nowrap;
}

.val-table-block th,
.val-table-block td {
  padding: 1rem 0.8rem;
  border-top: 1px solid var(--val-rule);
  color: #b4b4af;
  text-align: right;
}

.val-table-block th:first-child {
  padding-left: 0;
  color: var(--val-paper);
  text-align: left;
}

.val-table-block thead th {
  color: #62635f;
  font-size: 0.55rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.val-table-block tbody tr:hover {
  background: rgba(255, 122, 69, 0.035);
}

.val-caveat {
  margin: 2rem 0 0;
  padding: 1.25rem 0 0;
  border-top: 1px solid var(--val-rule);
  color: var(--val-muted);
  font-size: 0.72rem;
  line-height: 1.55;
}

.val-caveat b {
  color: var(--val-paper);
}

.val-figure-pair-even {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.val-figure-full {
  margin-top: clamp(2.5rem, 6vw, 5rem);
  border: 1px solid var(--val-rule);
}

.val-figure-full .nadir-figure {
  height: clamp(22rem, 43vw, 38rem);
}

.val-latency-ledger {
  display: grid;
  border-right: 1px solid var(--val-rule);
  border-bottom: 1px solid var(--val-rule);
  border-left: 1px solid var(--val-rule);
  grid-template-columns: repeat(4, 1fr);
}

.val-latency-ledger > div {
  display: grid;
  gap: 0.45rem;
  padding: 1.25rem;
  border-right: 1px solid var(--val-rule);
}

.val-latency-ledger > div:last-child {
  border-right: 0;
}

.val-latency-ledger span,
.val-latency-ledger em {
  color: var(--val-muted);
  font: 500 0.55rem/1.35 "JetBrains Mono", monospace;
  letter-spacing: 0.08em;
}

.val-latency-ledger strong {
  color: var(--val-paper);
  font: 500 1.25rem/1.15 "JetBrains Mono", monospace;
}

.val-latency-ledger em {
  font-style: normal;
  letter-spacing: 0;
}

.val-stream-section {
  padding: clamp(4rem, 9vw, 7.5rem) 0;
  border-bottom: 1px solid var(--val-rule);
  background: #030403;
}

.val-stream-head {
  display: grid;
  align-items: end;
  gap: 2rem 4rem;
  margin-bottom: 2.5rem;
  grid-template-columns: 1fr minmax(260px, 0.42fr);
}

.val-stream-head p:last-child {
  margin: 0;
  color: var(--val-muted);
  font-size: 0.78rem;
  line-height: 1.55;
}

.val-stream-wall {
  display: grid;
  gap: 1px;
  border: 1px solid var(--val-rule);
  background: var(--val-rule);
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.val-feed {
  position: relative;
  min-width: 0;
  aspect-ratio: 1.55;
  overflow: hidden;
  background: #080a08;
}

.val-feed canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.val-feed > div {
  position: absolute;
  right: 0.75rem;
  bottom: 0.65rem;
  left: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  color: rgba(245, 245, 240, 0.72);
  font: 500 0.52rem/1.2 "JetBrains Mono", monospace;
  letter-spacing: 0.05em;
}

.val-feed b {
  padding: 0.3rem 0.42rem;
  border: 1px solid rgba(245, 245, 240, 0.18);
  border-radius: 999px;
  color: var(--val-paper);
  font: inherit;
}

.val-feed[data-tier="CAUTION"] b {
  border-color: rgba(255, 194, 69, 0.5);
  color: #ffc245;
}

.val-feed[data-tier="CRITICAL"] b {
  border-color: rgba(255, 91, 74, 0.62);
  color: #ff6e5d;
}

.val-stream-note {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 1rem 0 0;
  color: var(--val-muted);
  font: 500 0.57rem/1.4 "JetBrains Mono", monospace;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.val-stream-note i {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: #43c977;
  box-shadow: 0 0 0 0.25rem rgba(67, 201, 119, 0.1);
}

.val-method-section {
  border-bottom: 1px solid var(--val-rule);
}

.val-protocol {
  display: grid;
  margin: clamp(2.5rem, 6vw, 5rem) 0 0;
  padding: 0;
  border-top: 1px solid var(--val-rule);
  list-style: none;
  grid-template-columns: repeat(4, 1fr);
}

.val-protocol li {
  display: grid;
  align-content: start;
  min-height: 17rem;
  padding: 1.25rem;
  border-right: 1px solid var(--val-rule);
  gap: 3rem;
}

.val-protocol li:first-child {
  padding-left: 0;
}

.val-protocol li:last-child {
  border-right: 0;
}

.val-protocol b {
  color: var(--val-orange);
  font: 500 0.62rem/1 "JetBrains Mono", monospace;
}

.val-protocol strong {
  color: var(--val-paper);
  font-size: 0.92rem;
}

.val-protocol p {
  margin: 0.6rem 0 0;
  color: var(--val-muted);
  font-size: 0.76rem;
  line-height: 1.55;
}

.val-boundary {
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid rgba(255, 122, 69, 0.35);
  background:
    linear-gradient(120deg, rgba(255, 122, 69, 0.09), transparent 55%),
    #0a0908;
}

.val-boundary h3 {
  max-width: 18ch;
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 3.4rem);
  letter-spacing: -0.04em;
}

.val-boundary > div {
  display: grid;
  gap: 2rem;
  margin: 2.5rem 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.val-boundary p {
  margin: 0;
  color: var(--val-muted);
  font-size: 0.86rem;
  line-height: 1.6;
}

.val-boundary p strong {
  display: block;
  margin-bottom: 0.4rem;
  color: var(--val-paper);
}

.val-boundary small {
  display: block;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 122, 69, 0.2);
  color: var(--val-orange);
  font: 500 0.58rem/1.55 "JetBrains Mono", monospace;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

@media (max-width: 900px) {
  .val-hero-grid,
  .val-section-head,
  .val-stream-head {
    grid-template-columns: 1fr;
  }

  .val-hero-readout {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
  }

  .val-hero-readout > div:nth-child(odd) {
    padding-right: 1rem;
    border-right: 1px solid var(--val-rule);
  }

  .val-hero-readout > div:nth-child(even) {
    padding-left: 1rem;
  }

  .val-scope-line,
  .val-metrics,
  .val-method-line,
  .val-latency-ledger,
  .val-protocol {
    grid-template-columns: repeat(2, 1fr);
  }

  .val-metrics article:nth-child(2),
  .val-method-line span:nth-child(2),
  .val-latency-ledger > div:nth-child(2),
  .val-protocol li:nth-child(2) {
    border-right: 0;
  }

  .val-metrics article:nth-child(-n + 2),
  .val-method-line span:nth-child(-n + 2),
  .val-latency-ledger > div:nth-child(-n + 2) {
    border-bottom: 1px solid var(--val-rule);
  }

  .val-table-grid,
  .val-figure-pair,
  .val-figure-pair-even {
    grid-template-columns: 1fr;
  }

  .val-stream-wall {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .val-hero {
    padding-top: 6.75rem;
  }

  .val-hero h1 {
    font-size: clamp(2.8rem, 15vw, 4.2rem);
  }

  .val-hero-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .val-scope-line,
  .val-metrics,
  .val-method-line,
  .val-latency-ledger,
  .val-protocol,
  .val-boundary > div {
    grid-template-columns: 1fr;
  }

  .val-metrics article,
  .val-metrics article:not(:first-child) {
    min-height: 0;
    padding: 1.5rem 0;
    border-right: 0;
    border-bottom: 1px solid var(--val-rule);
  }

  .val-metrics strong {
    margin-bottom: 1.4rem;
  }

  .val-method-line span,
  .val-latency-ledger > div,
  .val-protocol li {
    border-right: 0;
    border-bottom: 1px solid var(--val-rule);
  }

  .val-protocol li,
  .val-protocol li:first-child {
    min-height: 0;
    padding: 1.3rem 0;
    gap: 1.5rem;
  }

  .val-stream-wall {
    grid-template-columns: 1fr;
  }

  .val-feed {
    aspect-ratio: 1.45;
  }

  .val-table-title {
    grid-template-columns: auto 1fr;
  }

  .val-table-title em {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .val-stream-note i {
    box-shadow: none;
  }
}

.val-gradual-callout {
  margin: 0 auto 48px;
  max-width: var(--ap-page, 1280px);
  padding: 28px 32px;
  border-top: 1px solid rgba(255, 122, 69, 0.35);
  border-bottom: 1px solid rgba(245, 245, 247, 0.08);
  background: linear-gradient(180deg, rgba(255, 122, 69, 0.08), transparent);
}
.val-gradual-callout dl {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 18px;
  margin: 16px 0 0;
}
.val-gradual-callout dt {
  font-family: var(--ap-mono, "JetBrains Mono", monospace);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ap-text-dim, #86868b);
}
.val-gradual-callout dd {
  margin: 6px 0 0;
  font-family: var(--display, "DM Sans", sans-serif);
  font-size: 28px;
  font-weight: 600;
  color: var(--ap-text, #f5f5f7);
}
@media (max-width: 900px) {
  .val-gradual-callout dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
