:root {
  color-scheme: light;
  --paper: #efeee8;
  --ink: #0a0a0a;
  --muted: #67665f;
  --line: #0a0a0a;
  --alert: #df1b12;
  --ok: #08733f;
  font-family: Arial, Helvetica, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); }
a { color: inherit; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.masthead { min-height: 68vh; display: grid; grid-template-columns: 3fr 1fr; grid-template-rows: auto 1fr auto; border-bottom: 3px solid var(--line); padding: 20px 24px 28px; }
.eyebrow { grid-column: 1 / -1; font: 700 11px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .12em; border-bottom: 1px solid var(--line); padding-bottom: 12px; }
h1 { align-self: center; margin: 4vh 0; font-size: clamp(3rem, 9vw, 8rem); letter-spacing: -.075em; line-height: .78; font-weight: 900; }
.hero-state { align-self: end; justify-self: stretch; display: grid; grid-template-columns: 88px 1fr; border: 2px solid var(--line); }
.state-mark { display: grid; place-items: center; min-height: 88px; background: var(--ink); color: var(--paper); font: 900 54px/1 Arial; }
.hero-state > div { display: flex; flex-direction: column; justify-content: center; padding: 14px; border-left: 2px solid var(--line); }
.hero-state strong { font-size: clamp(1.25rem, 3vw, 2.5rem); line-height: .9; }
.hero-state small { margin-top: 8px; font: 700 10px/1.35 ui-monospace, monospace; letter-spacing: .08em; }
body[data-state="down"] .state-mark, body[data-state="investigating"] .state-mark { background: var(--alert); }
body[data-state="operational"] .state-mark { background: var(--ok); }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 2px solid var(--line); }
.metrics > div { min-height: 150px; padding: 18px 20px; display: flex; flex-direction: column; justify-content: space-between; border-right: 1px solid var(--line); }
.metrics > div:last-child { border-right: 0; }
.metrics span, footer, th { font: 700 10px/1.2 ui-monospace, monospace; letter-spacing: .1em; }
.metrics output { font-size: clamp(2rem, 5vw, 5rem); font-weight: 900; letter-spacing: -.06em; }
.panel { border-bottom: 2px solid var(--line); }
.panel > header { display: grid; grid-template-columns: 70px 1fr; border-bottom: 1px solid var(--line); }
.panel > header span { padding: 18px; font: 700 12px/1 ui-monospace, monospace; border-right: 1px solid var(--line); }
h2 { margin: 0; padding: 14px 20px 10px; font-size: clamp(1.6rem, 4vw, 4rem); letter-spacing: -.04em; line-height: 1; }
.explanation-grid, .details-grid { display: grid; grid-template-columns: 1fr 1fr; }
.explanation-grid > *, .details-grid > * { margin: 0; padding: 28px 24px; border-right: 1px solid var(--line); font-size: 1rem; line-height: 1.45; }
.local-action { display: grid; gap: 14px; }
button { appearance: none; border: 2px solid var(--ink); border-radius: 0; background: var(--ink); color: var(--paper); padding: 16px; font: 800 12px/1 ui-monospace, monospace; letter-spacing: .04em; cursor: pointer; text-align: left; }
button:hover { background: transparent; color: var(--ink); }
button:disabled { cursor: wait; opacity: .55; }
#comparison { font: 700 12px/1.4 ui-monospace, monospace; min-height: 3em; }
.local-details { border-top: 1px solid var(--line); padding-top: 14px; }
.local-details h3 { margin: 0 0 8px; font: 800 12px/1 ui-monospace, monospace; letter-spacing: .08em; }
.local-validator { display: grid; gap: 4px; padding: 10px 0; border-top: 1px solid #bbb9b0; }
.local-validator b, .local-validator span, .local-details small { font: 700 10px/1.4 ui-monospace, monospace; }
.local-validator span { overflow-wrap: anywhere; }
.local-details small { display: block; margin-top: 10px; color: var(--muted); }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; min-width: 760px; font: 12px/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; }
th, td { padding: 14px 16px; text-align: left; border-right: 1px solid var(--line); border-bottom: 1px solid #bbb9b0; }
th { background: var(--ink); color: var(--paper); }
td:last-child, th:last-child { border-right: 0; }
.pass { color: var(--ok); font-weight: 800; }
.fail { color: var(--alert); font-weight: 800; }
.inconclusive { color: var(--muted); font-weight: 800; }
.availability { display: grid; grid-template-columns: repeat(3, 1fr); }
.availability > div { min-height: 170px; padding: 20px; border-right: 1px solid var(--line); }
.availability label { font: 700 11px/1 ui-monospace, monospace; letter-spacing: .08em; }
.availability output { display: block; margin-top: 28px; font-size: clamp(2.6rem, 7vw, 7rem); font-weight: 900; letter-spacing: -.07em; }
.availability small { font: 11px/1.3 ui-monospace, monospace; }
.timeline { display: grid; grid-template-columns: repeat(48, 1fr); gap: 2px; padding: 16px 20px; border-top: 1px solid var(--line); }
.timeline i { height: 22px; display: block; background: var(--ink); }
.timeline i[data-state="down"] { background: var(--alert); }
.timeline i[data-state="degraded"], .timeline i[data-state="unknown"] { background: #858278; }
.details-grid { grid-template-columns: repeat(4, 1fr); }
.details-grid p { font: 12px/1.5 ui-monospace, monospace; }
.details-grid b { display: block; margin-bottom: 8px; }
footer { display: flex; justify-content: space-between; gap: 20px; padding: 22px 24px 36px; }
@media (max-width: 850px) {
  .masthead { min-height: auto; grid-template-columns: 1fr; }
  h1 { margin: 12vh 0; }
  .hero-state { grid-column: 1; }
  .metrics { grid-template-columns: 1fr 1fr; }
  .metrics > div:nth-child(2) { border-right: 0; }
  .metrics > div { border-bottom: 1px solid var(--line); }
  .explanation-grid, .details-grid { grid-template-columns: 1fr; }
  .explanation-grid > *, .details-grid > * { border-right: 0; border-bottom: 1px solid var(--line); }
  .availability { grid-template-columns: 1fr; }
  .availability > div { border-right: 0; border-bottom: 1px solid var(--line); }
  footer { flex-direction: column; }
}
@media (max-width: 600px) {
  .table-wrap { overflow-x: visible; }
  table { min-width: 0; }
  thead {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
  }
  tbody { display: grid; }
  tbody tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    border-bottom: 2px solid var(--line);
  }
  tbody tr:last-child { border-bottom: 0; }
  td {
    min-width: 0;
    padding: 12px;
    border-right: 1px solid var(--line);
    border-bottom: 1px solid #bbb9b0;
    overflow-wrap: anywhere;
  }
  td:nth-child(2n) { border-right: 0; }
  td:nth-last-child(-n + 2) { border-bottom: 0; }
  td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 8px;
    color: var(--muted);
    font: 700 9px/1 ui-monospace, monospace;
    letter-spacing: .08em;
  }
  .validator-empty { grid-template-columns: 1fr; }
  .validator-empty td {
    border: 0;
  }
  .validator-empty td::before { content: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .state-mark { transition: background-color .2s linear; }
}
