body[data-page-kind="agent-reliability-atlas"] {
  --atlas-indigo: #5148e5;
  --atlas-teal: #008f78;
  --atlas-coral: #e96655;
  --atlas-sky: #1688b8;
  --atlas-lavender: #7765b9;
  --atlas-paper: #ffffff;
}
body[data-page-kind="agent-reliability-atlas"] .reading > .prose {
  max-width: 76rem;
}

body[data-page-kind="agent-reliability-atlas"] .prose > :where(p, ul, ol, blockquote, h2, h3) {
  max-width: 78ch;
}

body[data-page-kind="agent-reliability-atlas"] .atlas-section {
  margin: 0 auto;
  padding-top: 1rem;
}

body[data-page-kind="agent-reliability-atlas"] .atlas-section > h2,
body[data-page-kind="agent-reliability-atlas"] .atlas-section > p {
  max-width: 78ch;
  margin-inline: auto !important;
}

body[data-page-kind="agent-reliability-atlas"] .scientific-figure-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: .8rem 1.2rem;
  align-items: baseline;
  padding: .85rem 0 .75rem;
  border-bottom: 1px solid var(--ve-line);
  font-family: var(--ve-sans);
}

body[data-page-kind="agent-reliability-atlas"] .scientific-figure-head > span,
body[data-page-kind="agent-reliability-atlas"] .scientific-figure-head > em {
  color: var(--ve-muted);
  font: 500 .65rem/1.35 var(--ve-mono);
  letter-spacing: .045em;
  text-transform: uppercase;
}

body[data-page-kind="agent-reliability-atlas"] .scientific-figure-head > strong {
  color: var(--ve-ink);
  font: 600 clamp(1.05rem, 1.8vw, 1.42rem)/1.25 var(--ve-sans);
  letter-spacing: -.025em;
}

body[data-page-kind="agent-reliability-atlas"] .scientific-figure-head > em {
  justify-self: end;
  font-style: normal;
  text-align: right;
}

body[data-page-kind="agent-reliability-atlas"] .architecture-view .dv-svg {
  min-width: 860px;
  padding-block: 1rem;
}

body[data-page-kind="agent-reliability-atlas"] .atlas-matrix-figure {
  overflow: visible !important;
}

.atlas-priority-summary {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
  padding: 1rem 0 .5rem;
  font-family: var(--ve-sans);
}

.atlas-priority-summary > span {
  display: inline-flex;
  align-items: baseline;
  gap: .35rem;
  padding: .35rem .5rem;
  border: 1px solid var(--ve-line);
  background: var(--atlas-paper);
  color: var(--ve-ink-soft);
  font-size: .73rem;
}

.atlas-priority-summary small { color: var(--ve-muted); }
.priority-p0 { border-color: color-mix(in srgb, var(--atlas-coral) 52%, var(--ve-line)) !important; }
.priority-p1 { border-color: color-mix(in srgb, var(--atlas-indigo) 42%, var(--ve-line)) !important; }
.priority-p2 { border-color: color-mix(in srgb, var(--atlas-teal) 45%, var(--ve-line)) !important; }

.atlas-figure-instruction {
  max-width: 90ch !important;
  margin: .35rem 0 1rem !important;
  color: var(--ve-ink-soft);
  font-size: .92rem;
  text-align: left !important;
}

.atlas-matrix-scroll,
.atlas-table-scroll {
  width: 100%;
  max-width: 100%;
  overflow: auto;
  border-top: 1px solid var(--ve-ink);
  border-bottom: 1px solid var(--ve-ink);
  background: var(--atlas-paper);
}

.atlas-matrix-scroll:focus-visible,
.atlas-table-scroll:focus-visible {
  outline: 2px solid var(--atlas-indigo);
  outline-offset: 3px;
}

.atlas-matrix-scroll table {
  width: 100%;
  min-width: 1580px;
  margin: 0 !important;
  border: 0 !important;
  table-layout: fixed;
}

.atlas-matrix-scroll th,
.atlas-matrix-scroll td {
  min-width: 126px;
  padding: .72rem .62rem !important;
  border-right: 1px solid var(--ve-line);
  border-bottom: 1px solid var(--ve-line) !important;
  background: var(--atlas-paper);
  white-space: normal !important;
  vertical-align: top;
}

.atlas-matrix-scroll thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  color: white !important;
  background: var(--ve-ink) !important;
}

.atlas-matrix-scroll th:first-child {
  position: sticky;
  left: 0;
  z-index: 3;
  width: 210px;
  min-width: 210px;
}

.atlas-matrix-scroll tbody th:first-child {
  background: #f7f7f4 !important;
}

.atlas-matrix-scroll th span,
.atlas-matrix-scroll th strong,
.atlas-matrix-scroll th small {
  display: block;
}

.atlas-matrix-scroll thead th span {
  color: #7ed9c9;
  font: 600 .58rem/1 var(--ve-mono);
}

.atlas-matrix-scroll th strong {
  margin: .26rem 0;
  font: 600 .73rem/1.25 var(--ve-sans);
}

.atlas-matrix-scroll th small,
.atlas-cell-count,
.atlas-none {
  color: var(--ve-muted);
  font: 500 .6rem/1.25 var(--ve-mono);
}

.atlas-matrix-scroll thead th small { color: #c6cad5; }
.atlas-cell-count { display: block; margin-bottom: .45rem; }
.atlas-chip-list { display: flex; flex-wrap: wrap; gap: .26rem; }

.atlas-issue-chip {
  display: inline-flex;
  gap: .25rem;
  padding: .24rem .3rem;
  border: 1px solid var(--ve-line) !important;
  background: rgba(255,255,255,.84);
  color: var(--ve-ink) !important;
  font: 600 .58rem/1.2 var(--ve-mono);
  text-decoration: none;
}

.atlas-issue-chip:hover,
.atlas-issue-chip:focus-visible { background: white; border-color: var(--atlas-indigo) !important; }
.atlas-issue-chip span { color: var(--ve-muted); font-weight: 500; }
.density-1 { background: color-mix(in srgb, var(--atlas-sky) 5%, white) !important; }
.density-2 { background: color-mix(in srgb, var(--atlas-sky) 9%, white) !important; }
.density-3 { background: color-mix(in srgb, var(--atlas-sky) 13%, white) !important; }
.density-4 { background: color-mix(in srgb, var(--atlas-sky) 18%, white) !important; }

.atlas-scenario-nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 2rem 0 2.5rem;
  border-top: 1px solid var(--ve-ink);
}

.atlas-scenario-nav a {
  display: grid;
  grid-template-columns: 2rem 1fr;
  gap: .25rem .75rem;
  padding: 1rem .85rem;
  border: 0 !important;
  border-bottom: 1px solid var(--ve-line) !important;
  color: var(--ve-ink) !important;
  text-decoration: none;
}

.atlas-scenario-nav a:nth-child(3n+2),
.atlas-scenario-nav a:nth-child(3n+3) { border-left: 1px solid var(--ve-line) !important; }
.atlas-scenario-nav span { grid-row: 1 / 3; color: var(--atlas-teal); font: 600 .66rem/1.4 var(--ve-mono); }
.atlas-scenario-nav strong { font: 600 .88rem/1.3 var(--ve-sans); }
.atlas-scenario-nav small { color: var(--ve-muted); font: 500 .65rem/1.3 var(--ve-mono); }

.atlas-scenario {
  margin: 1rem 0 !important;
  scroll-margin-top: 4.5rem;
}

.atlas-scenario > summary {
  display: grid !important;
  grid-template-columns: 6.5rem minmax(0, 1fr) auto;
  gap: .75rem 1rem;
  align-items: baseline;
}

.atlas-scenario > summary span,
.atlas-scenario > summary small { color: var(--ve-muted); font: 500 .65rem/1.3 var(--ve-mono); }
.atlas-scenario > summary strong { font: 600 1rem/1.35 var(--ve-sans); }
.atlas-scenario-body { padding: 1rem 0 1.5rem; }
.atlas-consequence { max-width: 80ch !important; padding-left: 1rem; border-left: 3px solid var(--atlas-coral); }
.atlas-situation { max-width: 80ch; margin: 1.4rem auto; }
.atlas-record-label { color: var(--atlas-teal); font: 600 .65rem/1.3 var(--ve-mono); letter-spacing: .06em; text-transform: uppercase; }

.atlas-analysis-grid,
.atlas-platform-notes > div {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin: 1.5rem 0;
  border: 1px solid var(--ve-ink);
  background: var(--ve-ink);
}

.atlas-analysis-grid > section,
.atlas-platform-notes > div > div {
  padding: 1rem 1.1rem;
  background: var(--atlas-paper);
}

.atlas-analysis-grid h4,
.atlas-platform-notes h4,
.atlas-record-body h4 {
  margin: 0 0 .55rem;
  color: var(--ve-ink);
  font: 600 .88rem/1.3 var(--ve-sans);
}

.atlas-analysis-grid :is(ul, ol),
.atlas-record-body :is(ul, ol) { margin-bottom: 0; }

.atlas-platform-notes { margin: 1.6rem 0; }
.atlas-platform-notes > div { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.atlas-platform-notes p { margin: .4rem 0 0 !important; font-size: .86rem; text-align: left !important; }

.atlas-code {
  margin: 1.75rem 0;
  border-top: 1px solid var(--ve-ink);
  border-bottom: 1px solid var(--ve-ink);
}

.atlas-code > div {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: .7rem 1rem;
  align-items: baseline;
  padding: .75rem 0;
  font-family: var(--ve-sans);
}

.atlas-code > div span,
.atlas-code > div small { color: var(--ve-muted); font: 500 .62rem/1.3 var(--ve-mono); text-transform: uppercase; }
.atlas-code > div strong { font: 600 .88rem/1.3 var(--ve-sans); }
.atlas-code pre { max-height: 30rem; margin: 0 !important; border: 0 !important; border-top: 1px solid var(--ve-line) !important; }

.atlas-table-scroll { margin: 1.75rem 0; }
.atlas-platform-table { min-width: 1120px; margin: 0 !important; border: 0 !important; }
.atlas-platform-table caption { padding: .8rem 0; color: var(--ve-muted); font: 500 .66rem/1.4 var(--ve-mono); text-align: left; }
.atlas-decision { max-width: 80ch; margin: 1.5rem auto; padding: 1rem 1.1rem; border-left: 3px solid var(--atlas-teal); background: #f5faf8; }

.atlas-filters {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(180px, .55fr) minmax(230px, .7fr);
  gap: 1rem;
  margin: 1.8rem 0 .6rem;
  padding: 1rem;
  border: 1px solid var(--ve-ink);
  background: #f7f7f4;
}

.atlas-filters label { display: grid; gap: .4rem; }
.atlas-filters label > span { color: var(--ve-muted); font: 600 .63rem/1.3 var(--ve-mono); letter-spacing: .04em; text-transform: uppercase; }
.atlas-filters :is(input, select) { width: 100%; min-height: 2.55rem; padding: .55rem .65rem; border: 1px solid var(--ve-line-strong); border-radius: 0; background: white; color: var(--ve-ink); font: 500 .83rem/1.3 var(--ve-sans); }
.atlas-filter-status { margin: 0 0 1.5rem !important; color: var(--ve-muted); font: 500 .68rem/1.4 var(--ve-mono); text-align: left !important; }

.atlas-volume { margin: 2.4rem 0; }
.atlas-volume > header { display: grid; grid-template-columns: 6rem minmax(0, .65fr) minmax(0, 1fr); gap: 1rem; align-items: baseline; padding: .8rem 0; border-top: 1px solid var(--ve-ink); }
.atlas-volume > header span { color: var(--atlas-teal); font: 600 .65rem/1.3 var(--ve-mono); }
.atlas-volume > header h3 { margin: 0 !important; font: 600 1.05rem/1.25 var(--ve-sans); }
.atlas-volume > header p { margin: 0 !important; color: var(--ve-muted); font-size: .88rem; text-align: left !important; }

.atlas-issue {
  margin: 0 !important;
  border: 0 !important;
  border-top: 1px solid var(--ve-line) !important;
  border-radius: 0 !important;
  background: white !important;
  scroll-margin-top: 4.5rem;
}

.atlas-issue:last-child { border-bottom: 1px solid var(--ve-line) !important; }
.atlas-issue > summary { display: grid !important; grid-template-columns: 4rem minmax(0, 1fr) auto; gap: .8rem 1rem; align-items: baseline; padding: .82rem 0 !important; background: white !important; cursor: pointer; }
.atlas-record-code { color: var(--atlas-teal); font: 600 .68rem/1.3 var(--ve-mono); }
.atlas-record-title { display: grid; gap: .2rem; }
.atlas-record-title strong { font: 600 .9rem/1.3 var(--ve-sans); }
.atlas-record-title small { color: var(--ve-muted); font: 500 .64rem/1.3 var(--ve-mono); }
.atlas-priority { align-self: start; padding: .22rem .34rem; border: 1px solid var(--ve-line); color: var(--ve-ink); font: 600 .62rem/1 var(--ve-mono); }
.atlas-record-body { padding: .4rem 0 1.4rem 5rem; }
.atlas-record-body > section > p { max-width: 84ch; margin: .35rem 0 1rem !important; font-size: .94rem; }
.atlas-record-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; margin: 1rem 0; border: 1px solid var(--ve-line); background: var(--ve-line); }
.atlas-record-grid > section { padding: .9rem 1rem; background: white; }
.atlas-record-body li { font-size: .88rem; text-align: left !important; }

.atlas-glossary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; margin: 1.5rem 0; border: 1px solid var(--ve-ink); background: var(--ve-ink); }
.atlas-glossary > div { padding: 1rem; background: white; }
.atlas-glossary dt { color: var(--ve-ink); font: 600 .9rem/1.3 var(--ve-sans); }
.atlas-glossary dd { margin: .35rem 0 0; color: var(--ve-ink-soft); font-size: .9rem; }
.atlas-references { padding: 0; list-style: none; border-top: 1px solid var(--ve-ink); }
.atlas-references li { margin: 0; border-bottom: 1px solid var(--ve-line); }
.atlas-references a { display: grid; grid-template-columns: minmax(210px, .5fr) minmax(0, 1fr); gap: 1rem; padding: .85rem 0; border: 0 !important; text-decoration: none; }
.atlas-references a strong { font: 600 .86rem/1.3 var(--ve-sans); }
.atlas-references a span { color: var(--ve-muted); font-size: .86rem; }

.atlas-release { max-width: 78ch; margin: 4rem auto 1rem; padding: 1.4rem 0; border-top: 3px solid var(--atlas-coral); border-bottom: 1px solid var(--ve-ink); }
.atlas-release > span { color: var(--atlas-coral); font: 600 .65rem/1.3 var(--ve-mono); letter-spacing: .07em; text-transform: uppercase; }
.atlas-release h2 { margin: .5rem 0 .7rem !important; font: 600 clamp(1.6rem, 3vw, 2.5rem)/1.06 var(--ve-sans); letter-spacing: -.04em; }
.atlas-release p { margin: 0 !important; }
.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0,0,0,0) !important; white-space: nowrap !important; border: 0 !important; }

@media (max-width: 820px) {
  body[data-page-kind="agent-reliability-atlas"] .scientific-figure-head { grid-template-columns: 1fr; gap: .25rem; }
  body[data-page-kind="agent-reliability-atlas"] .scientific-figure-head > em { justify-self: start; text-align: left; }
  body[data-page-kind="agent-reliability-atlas"] .architecture-view .dv-svg { min-width: 720px; }
  .atlas-scenario-nav { grid-template-columns: 1fr; }
  .atlas-scenario-nav a:nth-child(n) { border-left: 0 !important; }
  .atlas-platform-notes > div { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .atlas-filters { grid-template-columns: 1fr; }
  .atlas-volume > header { grid-template-columns: 1fr; gap: .3rem; }
}

@media (max-width: 560px) {
  .atlas-scenario > summary { grid-template-columns: 1fr; gap: .3rem; }
  .atlas-analysis-grid,
  .atlas-platform-notes > div,
  .atlas-record-grid,
  .atlas-glossary { grid-template-columns: 1fr; }
  .atlas-record-body { padding-left: 0; }
  .atlas-issue > summary { grid-template-columns: 3rem minmax(0, 1fr) auto; gap: .6rem; }
  .atlas-record-title small { grid-column: 1 / -1; }
  .atlas-references a { grid-template-columns: 1fr; gap: .25rem; }
}
