:root {
  --red: #db1e2f;
  --red-dark: #af0421;
  --red-pale: #fff1f2;
  --ink: #231f20;
  --ink-2: #494446;
  --muted: #716b6d;
  --line: #dedddd;
  --line-dark: #bdbabb;
  --paper: #ffffff;
  --wash: #f6f6f5;
  --green: #16794b;
  --green-pale: #e9f6ef;
  --amber: #996300;
  --amber-pale: #fff5d9;
  --blue: #175ea8;
  --blue-pale: #edf5ff;
  --font:
    "Proxima Nova", "Hanken Grotesk", system-ui, -apple-system, "Segoe UI",
    sans-serif;
  --max: 1440px;
  --radius: 6px;
  --shadow: 0 18px 52px rgba(35, 31, 32, 0.16);
}

* {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
button,
input,
select {
  font: inherit;
}
button {
  color: inherit;
}
a {
  color: var(--red-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover {
  color: var(--red);
}
svg {
  width: 18px;
  height: 18px;
  stroke-width: 2;
}
.skip-link {
  position: fixed;
  left: 16px;
  top: -60px;
  z-index: 1000;
  padding: 10px 14px;
  background: var(--ink);
  color: white;
}
.skip-link:focus {
  top: 16px;
}
:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 2px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  max-width: var(--max);
  min-height: 68px;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: stretch;
  gap: 32px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: max-content;
  color: var(--ink);
  text-decoration: none;
}
.brand-word {
  font-weight: 900;
  font-size: 24px;
  line-height: 1;
}
.brand-dot,
.footer-mark span {
  color: var(--red);
}
.brand-context {
  padding-left: 14px;
  border-left: 1px solid var(--line-dark);
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}
.primary-nav {
  margin-left: auto;
  display: flex;
  align-items: stretch;
}
.nav-item {
  position: relative;
  border: 0;
  background: transparent;
  padding: 0 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.nav-item::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: -1px;
  height: 3px;
  background: transparent;
}
.nav-item:hover {
  color: var(--red-dark);
}
.nav-item.active::after {
  background: var(--red);
}
.menu-button {
  display: none;
  margin: auto 0 auto auto;
}
.research-strip {
  background: var(--ink);
  color: white;
}
.strip-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 8px 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  font-size: 11px;
  text-transform: uppercase;
}
.strip-inner b {
  color: #ff8a95;
  font-weight: 900;
}

main {
  min-height: 75vh;
}
.view {
  display: none;
}
.view.active {
  display: block;
}
.page {
  max-width: var(--max);
  margin: 0 auto;
  padding: 40px 28px 72px;
}
.page-narrow {
  max-width: 1120px;
}
.page-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 28px;
  margin-bottom: 28px;
  padding-bottom: 22px;
  border-bottom: 2px solid var(--ink);
}
.page-head h1 {
  margin: 3px 0 0;
  font-size: 38px;
  line-height: 1.08;
  font-weight: 900;
}
.page-head p {
  max-width: 72ch;
  margin: 10px 0 0;
  color: var(--ink-2);
  font-size: 16px;
}
.eyebrow {
  display: block;
  color: var(--red-dark);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  line-height: 1.2;
}
.head-actions {
  display: flex;
  gap: 8px;
}

.hero {
  background: var(--red);
  color: white;
  min-height: 540px;
  display: flex;
  align-items: stretch;
}
.hero-inner {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 58px 28px 46px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr);
  gap: 72px;
}
.hero-kicker {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 44px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}
.hero-kicker::after {
  content: "";
  height: 1px;
  flex: 1;
  background: rgba(255, 255, 255, 0.5);
}
.hero h1 {
  max-width: 900px;
  margin: 0;
  font-size: 64px;
  line-height: 0.99;
  font-weight: 900;
  text-transform: uppercase;
}
.hero-lead {
  max-width: 64ch;
  margin: 24px 0 0;
  font-size: 20px;
  line-height: 1.42;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
}
.hero .text-button {
  background: white;
  color: var(--red-dark);
  border-color: white;
}
.hero .text-button.secondary {
  background: transparent;
  color: white;
  border-color: rgba(255, 255, 255, 0.6);
}
.hero-side {
  align-self: end;
  border-top: 1px solid rgba(255, 255, 255, 0.6);
  border-bottom: 1px solid rgba(255, 255, 255, 0.6);
}
.hero-stat {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 14px;
  padding: 18px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.28);
}
.hero-stat:last-child {
  border-bottom: 0;
}
.hero-stat b {
  font-size: 34px;
  line-height: 1;
  font-weight: 900;
}
.hero-stat span {
  font-size: 13px;
  line-height: 1.35;
}

.section-band {
  padding: 62px 0;
}
.section-band.wash {
  background: var(--wash);
}
.section-band.dark {
  background: var(--ink);
  color: white;
}
.section-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 28px;
}
.section-heading {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 18px;
  margin-bottom: 28px;
  align-items: start;
}
.section-number {
  color: var(--red);
  font-size: 12px;
  font-weight: 900;
  padding-top: 9px;
  border-top: 3px solid currentColor;
}
.section-heading h2 {
  margin: 0;
  max-width: 900px;
  font-size: 34px;
  line-height: 1.12;
  font-weight: 850;
}
.section-heading p {
  max-width: 74ch;
  margin: 12px 0 0;
  color: var(--ink-2);
  font-size: 17px;
}
.dark .section-heading p {
  color: rgba(255, 255, 255, 0.75);
}
.dark .section-number {
  color: #ff6b78;
}

.finding-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--line);
  background: var(--line);
  gap: 1px;
}
.finding {
  min-height: 210px;
  padding: 25px;
  background: white;
}
.finding b {
  display: block;
  margin-bottom: 12px;
  font-size: 18px;
  line-height: 1.2;
}
.finding p {
  margin: 0;
  color: var(--ink-2);
}
.finding .mini-index {
  color: var(--red);
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 24px;
}

.architecture {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(255, 255, 255, 0.35);
}
.architecture-step {
  position: relative;
  padding: 24px 22px 10px 0;
  min-height: 220px;
}
.architecture-step + .architecture-step {
  padding-left: 22px;
  border-left: 1px solid rgba(255, 255, 255, 0.28);
}
.architecture-step .step-no {
  color: #ff7581;
  font-weight: 900;
  font-size: 12px;
}
.architecture-step h3 {
  margin: 34px 0 10px;
  font-size: 21px;
}
.architecture-step p {
  margin: 0;
  color: rgba(255, 255, 255, 0.75);
  font-size: 14px;
}

.decision-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.decision-card {
  border: 1px solid var(--line);
  padding: 24px;
  background: white;
  border-radius: var(--radius);
}
.decision-card h3 {
  margin: 10px 0 10px;
  font-size: 20px;
}
.decision-card p {
  margin: 0 0 18px;
  color: var(--ink-2);
}
.decision-card .tool-line {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.text-button,
.icon-button {
  border: 1px solid var(--ink);
  background: var(--ink);
  color: white;
  min-height: 40px;
  cursor: pointer;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.text-button {
  padding: 9px 15px;
  border-radius: 3px;
  font-size: 13px;
}
.text-button:hover {
  background: var(--red-dark);
  border-color: var(--red-dark);
}
.text-button.secondary {
  background: white;
  color: var(--ink);
  border-color: var(--line-dark);
}
.text-button.secondary:hover {
  color: var(--red-dark);
  border-color: var(--red);
}
.text-button.small {
  min-height: 34px;
  padding: 6px 10px;
  font-size: 12px;
}
.icon-button {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 3px;
}
.icon-button:hover {
  background: var(--red);
  border-color: var(--red);
}

.toolbar {
  position: sticky;
  top: 102px;
  z-index: 20;
  display: grid;
  grid-template-columns:
    minmax(220px, 1.4fr) repeat(3, minmax(150px, 0.7fr))
    auto;
  gap: 10px;
  padding: 14px;
  margin-bottom: 14px;
  background: white;
  border: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(35, 31, 32, 0.07);
}
.control {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.control label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}
.input-shell {
  position: relative;
}
.input-shell svg {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  width: 16px;
}
input[type="search"],
select {
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  border: 1px solid var(--line-dark);
  border-radius: 3px;
  background: white;
  color: var(--ink);
}
.input-shell input {
  padding-left: 35px;
}
.toolbar-actions {
  display: flex;
  gap: 8px;
  align-items: end;
}
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 12px 0 18px;
}
.filter-chip {
  border: 1px solid var(--line-dark);
  background: white;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  cursor: pointer;
}
.filter-chip.active {
  background: var(--ink);
  border-color: var(--ink);
  color: white;
}
.result-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin: 14px 0;
  font-size: 13px;
  color: var(--muted);
}

.matrix-shell {
  border: 1px solid var(--line);
  overflow: auto;
  background: white;
}
.matrix {
  width: 100%;
  min-width: 1180px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
}
.matrix th {
  position: sticky;
  top: 0;
  z-index: 3;
  background: var(--ink);
  color: white;
  padding: 12px 10px;
  text-align: left;
  font-size: 10px;
  text-transform: uppercase;
  font-weight: 900;
}
.matrix th:first-child {
  left: 0;
  z-index: 5;
  min-width: 248px;
}
.matrix td {
  padding: 11px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.matrix tr:last-child td {
  border-bottom: 0;
}
.matrix tr:hover td {
  background: #fffafa;
}
.matrix td:first-child {
  position: sticky;
  left: 0;
  z-index: 2;
  background: white;
  box-shadow: 1px 0 0 var(--line);
}
.matrix tr:hover td:first-child {
  background: #fffafa;
}
.tool-cell {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
}
.tool-cell input {
  width: 16px;
  height: 16px;
  accent-color: var(--red);
}
.tool-cell button {
  border: 0;
  padding: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
  font-weight: 850;
}
.tool-cell button:hover {
  color: var(--red-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.tool-cell small {
  display: block;
  color: var(--muted);
  font-weight: 500;
  margin-top: 2px;
}
.group-row td {
  position: static !important;
  background: var(--wash) !important;
  color: var(--red-dark);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}
.score-cell {
  min-width: 128px;
}
.score-number {
  font-size: 18px;
  font-weight: 900;
}
.score-note {
  display: block;
  color: var(--muted);
  font-size: 10px;
}
.score-bar {
  width: 84px;
  height: 5px;
  margin-top: 5px;
  background: var(--line);
  overflow: hidden;
}
.score-bar span {
  display: block;
  height: 100%;
  background: var(--red);
}
.signal-score {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 68px;
}
.signal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid currentColor;
}
.s3 {
  color: var(--green);
}
.s3 .signal-dot {
  background: var(--green);
}
.s2 {
  color: var(--amber);
}
.s2 .signal-dot {
  background: var(--amber);
}
.s1 {
  color: var(--blue);
}
.s1 .signal-dot {
  background: var(--blue);
}
.s0,
.su {
  color: var(--muted);
}
.s0 .signal-dot {
  background: white;
}
.su .signal-dot {
  border-style: dashed;
}
.pill {
  display: inline-flex;
  align-items: center;
  max-width: 190px;
  min-height: 24px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--wash);
  color: var(--ink-2);
  font-size: 10px;
  font-weight: 800;
  line-height: 1.2;
}
.pill.good {
  background: var(--green-pale);
  color: var(--green);
}
.pill.warn {
  background: var(--amber-pale);
  color: var(--amber);
}
.pill.info {
  background: var(--blue-pale);
  color: var(--blue);
}
.pill.bad {
  background: var(--red-pale);
  color: var(--red-dark);
}
.surface-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: 220px;
}
.surface-tag {
  padding: 3px 6px;
  border: 1px solid var(--line);
  border-radius: 2px;
  font-size: 10px;
  white-space: nowrap;
}
.unknown {
  color: var(--muted);
  font-style: italic;
}
.matrix-mobile {
  display: none;
}
.mobile-benchmark-card {
  border: 1px solid var(--line);
  padding: 18px;
  background: white;
}
.mobile-benchmark-card h2 {
  margin: 4px 0 2px;
  font-size: 22px;
  line-height: 1.15;
}
.mobile-benchmark-card input {
  width: 20px;
  height: 20px;
  accent-color: var(--red);
}
.mobile-score {
  display: grid;
  grid-template-columns: 54px 1fr auto;
  align-items: center;
  gap: 10px;
  margin: 16px 0;
  padding: 12px;
  background: var(--wash);
}
.mobile-score > b {
  color: var(--red-dark);
  font-size: 34px;
  line-height: 1;
}
.mobile-score > span {
  color: var(--muted);
  font-size: 11px;
}
.mobile-signals {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 16px;
  border: 1px solid var(--line);
}
.mobile-signals > div {
  display: grid;
  gap: 5px;
  min-height: 66px;
  padding: 9px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.mobile-signals > div:nth-child(2n) {
  border-right: 0;
}
.mobile-signals > div:nth-last-child(-n + 2) {
  border-bottom: 0;
}
.mobile-signals > div > span:first-child {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.profile-controls {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 10px;
  margin-bottom: 18px;
}
.profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.profile-card {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  min-height: 440px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  background: white;
}
.profile-card:hover {
  border-color: var(--red);
}
.profile-card-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.profile-card h2 {
  margin: 4px 0 3px;
  font-size: 24px;
  line-height: 1.15;
}
.profile-card .vendor {
  color: var(--muted);
  font-size: 12px;
}
.profile-card .profile-intro {
  margin: 18px 0;
  color: var(--ink-2);
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 8;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.profile-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 0 0 18px;
  background: var(--line);
  border: 1px solid var(--line);
}
.profile-fact {
  background: var(--wash);
  padding: 10px;
  min-width: 0;
}
.profile-fact span {
  display: block;
  color: var(--muted);
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
}
.profile-fact b {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  overflow-wrap: anywhere;
}
.profile-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.test-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--ink);
  border: 1px solid var(--ink);
  margin-bottom: 28px;
}
.test-metric {
  padding: 20px;
  background: white;
}
.test-metric b {
  display: block;
  font-size: 30px;
  line-height: 1;
}
.test-metric span {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}
.test-ledger {
  display: grid;
  gap: 12px;
}
.test-row {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr) 180px;
  gap: 20px;
  padding: 20px;
  border: 1px solid var(--line);
  border-top: 4px solid var(--line-dark);
}
.test-row.l2 {
  border-top-color: var(--green);
}
.test-row.l1 {
  border-top-color: var(--amber);
}
.test-row.blocked {
  border-top-color: var(--red);
}
.test-row h3 {
  margin: 4px 0 5px;
  font-size: 18px;
}
.test-row p {
  margin: 0;
  color: var(--ink-2);
}
.test-evidence {
  color: var(--muted);
  font-size: 12px;
}
.test-evidence b {
  display: block;
  color: var(--ink);
  margin-bottom: 4px;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.catalog-card {
  border: 1px solid var(--line);
  padding: 16px;
  background: white;
  min-height: 180px;
}
.catalog-card h3 {
  margin: 3px 0 3px;
  font-size: 17px;
}
.catalog-card .vendor {
  color: var(--muted);
  font-size: 11px;
}
.catalog-card p {
  margin: 14px 0;
  color: var(--ink-2);
  font-size: 13px;
}
.catalog-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 24px;
}

.method-lead {
  margin: 0 0 36px;
  padding: 28px;
  border-top: 4px solid var(--red);
  background: var(--wash);
  font-size: 19px;
  line-height: 1.52;
}
.method-numbers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  margin: 28px 0 48px;
}
.method-number {
  min-height: 160px;
  padding: 20px;
  background: white;
}
.method-number b {
  display: block;
  color: var(--red);
  font-size: 38px;
  line-height: 1;
}
.method-number strong {
  display: block;
  margin: 8px 0 5px;
}
.method-number p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}
.method-copy {
  max-width: 78ch;
  font-size: 17px;
}
.method-copy p {
  margin: 0 0 18px;
}
.method-steps {
  display: grid;
  gap: 0;
  margin: 34px 0 58px;
  counter-reset: steps;
}
.method-step {
  counter-increment: steps;
  display: grid;
  grid-template-columns: 64px 1fr;
  padding: 18px 0;
  border-top: 1px solid var(--line);
}
.method-step::before {
  content: counter(steps, decimal-leading-zero);
  color: var(--red);
  font-weight: 900;
  font-size: 18px;
}
.method-step h3 {
  margin: 0 0 4px;
  font-size: 17px;
}
.method-step p {
  margin: 0;
  color: var(--ink-2);
}
.glossary-head {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  align-items: end;
  margin-bottom: 18px;
}
.glossary-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border: 1px solid var(--line);
  background: var(--line);
  gap: 1px;
}
.glossary-item {
  padding: 18px;
  background: white;
}
.glossary-item h3 {
  margin: 0 0 6px;
  color: var(--red-dark);
  font-size: 15px;
}
.glossary-item p {
  margin: 0;
  font-size: 13px;
}
.glossary-item small {
  display: block;
  margin-top: 7px;
  color: var(--muted);
}

.overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(35, 31, 32, 0.5);
}
.detail-drawer {
  position: fixed;
  z-index: 70;
  top: 0;
  right: 0;
  width: min(820px, 94vw);
  height: 100dvh;
  transform: translateX(102%);
  transition: transform 0.24s ease;
  background: white;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-rows: auto 1fr;
}
.detail-drawer.open {
  transform: translateX(0);
}
.drawer-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: start;
  padding: 22px 24px;
  border-bottom: 1px solid var(--line);
}
.drawer-head h2 {
  margin: 3px 0 0;
  font-size: 30px;
}
.drawer-content {
  overflow-y: auto;
  padding: 0 24px 80px;
}
.drawer-hero {
  margin: 0 -24px 26px;
  padding: 24px;
  background: var(--red);
  color: white;
}
.drawer-hero p {
  max-width: 70ch;
  margin: 12px 0 0;
  font-size: 17px;
  white-space: pre-line;
}
.drawer-tabs {
  position: sticky;
  top: 0;
  z-index: 3;
  display: flex;
  overflow-x: auto;
  margin: 0 -24px 24px;
  padding: 0 24px;
  background: white;
  border-bottom: 1px solid var(--line);
}
.drawer-tab {
  flex: 0 0 auto;
  border: 0;
  border-bottom: 3px solid transparent;
  padding: 13px 11px 10px;
  background: white;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.drawer-tab.active {
  color: var(--red-dark);
  border-bottom-color: var(--red);
}
.drawer-panel {
  display: none;
}
.drawer-panel.active {
  display: block;
}
.drawer-panel h3 {
  margin: 28px 0 10px;
  font-size: 19px;
}
.drawer-panel h3:first-child {
  margin-top: 0;
}
.drawer-panel p {
  color: var(--ink-2);
  white-space: pre-line;
}
.fact-table {
  width: 100%;
  border-collapse: collapse;
}
.fact-table th,
.fact-table td {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.fact-table th {
  width: 190px;
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
}
.coverage-list {
  display: grid;
  gap: 8px;
}
.coverage-row {
  display: grid;
  grid-template-columns: 150px 95px 1fr;
  gap: 12px;
  padding: 11px;
  background: var(--wash);
}
.coverage-row p {
  margin: 0;
  font-size: 12px;
}
.pro-con {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.pro-con section {
  border: 1px solid var(--line);
  padding: 16px;
}
.pro-con h3 {
  margin-top: 0;
}
.clean-list {
  margin: 0;
  padding-left: 18px;
}
.clean-list li {
  margin: 0 0 8px;
}
.steps-list {
  counter-reset: test;
  list-style: none;
  padding: 0;
}
.steps-list li {
  counter-increment: test;
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.steps-list li::before {
  content: counter(test, decimal-leading-zero);
  color: var(--red);
  font-weight: 900;
}
.source-list {
  list-style: none;
  padding: 0;
}
.source-list li {
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}

.compare-dock {
  position: fixed;
  z-index: 50;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  width: min(760px, calc(100vw - 28px));
  padding: 12px 14px;
  border: 1px solid var(--line-dark);
  background: white;
  box-shadow: var(--shadow);
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}
.compare-dock b {
  display: block;
  font-size: 13px;
}
.compare-dock span {
  color: var(--muted);
  font-size: 11px;
}
.dock-actions {
  display: flex;
  gap: 7px;
  flex: 0 0 auto;
}
.comparison-dialog {
  width: min(1380px, 96vw);
  max-height: 92vh;
  border: 0;
  padding: 0;
  box-shadow: var(--shadow);
}
.comparison-dialog::backdrop {
  background: rgba(35, 31, 32, 0.62);
}
.dialog-head {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: start;
  padding: 20px 24px;
  background: white;
  border-bottom: 1px solid var(--line);
}
.dialog-head h2 {
  margin: 3px 0 0;
}
#comparisonContent {
  padding: 18px 24px 30px;
  overflow: auto;
}
.comparison-table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
}
.comparison-table th,
.comparison-table td {
  padding: 12px;
  border: 1px solid var(--line);
  vertical-align: top;
  text-align: left;
}
.comparison-table th {
  background: var(--ink);
  color: white;
  font-size: 13px;
}
.comparison-table td:first-child {
  width: 170px;
  background: var(--wash);
  font-weight: 850;
}

.toast {
  position: fixed;
  z-index: 100;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 20px);
  opacity: 0;
  pointer-events: none;
  background: var(--ink);
  color: white;
  padding: 10px 14px;
  transition: 0.2s ease;
  font-size: 13px;
}
.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}
.empty-state {
  padding: 50px 20px;
  border: 1px dashed var(--line-dark);
  text-align: center;
  color: var(--muted);
}

.site-footer {
  background: var(--ink);
  color: white;
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 50px 28px;
  display: grid;
  grid-template-columns: 220px 1fr auto;
  gap: 32px;
  align-items: end;
}
.footer-mark {
  font-size: 38px;
  font-weight: 900;
}
.footer-inner p {
  max-width: 65ch;
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
}
.footer-meta {
  font-size: 11px;
  text-transform: uppercase;
}
.footer-links {
  grid-column: 2 / -1;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.footer-links a {
  color: white;
  font-size: 13px;
  font-weight: 700;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.footer-links a:hover {
  color: var(--red-light);
}

@media (max-width: 1080px) {
  .primary-nav {
    position: fixed;
    top: 68px;
    right: 14px;
    left: 14px;
    display: none;
    padding: 8px;
    background: white;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  .primary-nav.open {
    display: grid;
  }
  .nav-item {
    min-height: 44px;
    text-align: left;
  }
  .nav-item::after {
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 3px;
    height: auto;
    right: auto;
  }
  .menu-button {
    display: inline-flex;
  }
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 42px;
  }
  .hero-side {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    align-self: auto;
  }
  .hero-stat {
    grid-template-columns: 1fr;
    padding: 15px;
    border-bottom: 0;
    border-right: 1px solid rgba(255, 255, 255, 0.28);
  }
  .hero-stat:last-child {
    border-right: 0;
  }
  .finding-grid,
  .decision-grid,
  .catalog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .architecture {
    grid-template-columns: repeat(2, 1fr);
  }
  .architecture-step:nth-child(odd) {
    border-left: 0;
    padding-left: 0;
  }
  .architecture-step:nth-child(n + 3) {
    border-top: 1px solid rgba(255, 255, 255, 0.28);
  }
  .toolbar {
    grid-template-columns: 1fr 1fr;
    top: 102px;
  }
  .toolbar-actions {
    grid-column: span 2;
  }
  .footer-inner {
    grid-template-columns: 160px 1fr;
  }
  .footer-meta {
    grid-column: 2;
  }
}

@media (max-width: 720px) {
  body {
    font-size: 14px;
  }
  .header-inner {
    min-height: 62px;
    padding: 0 16px;
  }
  .brand-context {
    display: none;
  }
  .research-strip {
    overflow: hidden;
  }
  .strip-inner {
    padding: 7px 16px;
    flex-wrap: nowrap;
    overflow-x: auto;
  }
  .strip-inner span {
    white-space: nowrap;
  }
  .page {
    padding: 28px 16px 56px;
  }
  .page-head {
    grid-template-columns: 1fr;
  }
  .page-head h1 {
    font-size: 31px;
  }
  .head-actions {
    justify-content: flex-start;
  }
  .hero {
    min-height: auto;
  }
  .hero-inner {
    padding: 38px 16px 34px;
  }
  .hero-kicker {
    margin-bottom: 28px;
  }
  .hero h1 {
    font-size: 42px;
    line-height: 1.02;
  }
  .hero-lead {
    font-size: 17px;
  }
  .hero-side {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-stat:nth-child(2) {
    border-right: 0;
  }
  .hero-stat:nth-child(-n + 2) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.28);
  }
  .section-band {
    padding: 44px 0;
  }
  .section-inner {
    padding: 0 16px;
  }
  .section-heading {
    grid-template-columns: 44px 1fr;
    gap: 12px;
  }
  .section-heading h2 {
    font-size: 27px;
  }
  .section-heading p {
    font-size: 15px;
  }
  .finding-grid,
  .decision-grid,
  .profile-grid,
  .catalog-grid,
  .glossary-grid {
    grid-template-columns: 1fr;
  }
  .finding {
    min-height: auto;
  }
  .architecture {
    grid-template-columns: 1fr;
  }
  .architecture-step,
  .architecture-step + .architecture-step,
  .architecture-step:nth-child(3) {
    padding: 20px 0;
    border-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.28);
    min-height: auto;
  }
  .architecture-step h3 {
    margin-top: 18px;
  }
  .toolbar {
    position: static;
    grid-template-columns: 1fr;
  }
  .toolbar-actions {
    grid-column: auto;
  }
  .matrix-shell {
    display: none;
  }
  .matrix-mobile {
    display: grid;
    gap: 10px;
  }
  .profile-controls,
  .glossary-head {
    grid-template-columns: 1fr;
  }
  .profile-card {
    min-height: 0;
  }
  .profile-facts {
    grid-template-columns: 1fr 1fr;
  }
  .test-summary,
  .method-numbers {
    grid-template-columns: 1fr 1fr;
  }
  .test-row {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .coverage-row {
    grid-template-columns: 1fr;
    gap: 5px;
  }
  .pro-con {
    grid-template-columns: 1fr;
  }
  .detail-drawer {
    width: 100vw;
  }
  .drawer-head,
  .drawer-content {
    padding-left: 16px;
    padding-right: 16px;
  }
  .drawer-hero,
  .drawer-tabs {
    margin-left: -16px;
    margin-right: -16px;
  }
  .drawer-hero {
    padding-left: 16px;
    padding-right: 16px;
  }
  .drawer-tabs {
    padding-left: 16px;
  }
  .compare-dock {
    align-items: stretch;
  }
  .compare-dock > div:first-child {
    display: none;
  }
  .dock-actions {
    width: 100%;
  }
  .dock-actions .text-button {
    flex: 1;
  }
  .footer-inner {
    grid-template-columns: 1fr;
    padding: 40px 16px;
  }
  .footer-meta {
    grid-column: auto;
  }
  .footer-links {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .detail-drawer,
  .toast {
    transition: none;
  }
}

@media print {
  .site-header,
  .compare-dock,
  .site-footer,
  .toolbar,
  .head-actions {
    display: none !important;
  }
  .view {
    display: none !important;
  }
  .view.active {
    display: block !important;
  }
  .page {
    max-width: none;
    padding: 0;
  }
  .matrix-shell {
    overflow: visible;
    border: 0;
  }
  .matrix {
    min-width: 0;
    font-size: 8pt;
  }
  .matrix th,
  .matrix td {
    position: static !important;
  }
}
