@font-face { font-family: 'IBM Plex Sans'; font-weight: 400; font-display: swap; src: url('/fonts/ibm-plex-sans-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Sans'; font-weight: 500; font-display: swap; src: url('/fonts/ibm-plex-sans-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Sans'; font-weight: 600; font-display: swap; src: url('/fonts/ibm-plex-sans-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-weight: 400; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-weight: 500; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-500-normal.woff2') format('woff2'); }

/* The product's own palette: blue black, neon white, cyan for actions, severity colours from the app. */
:root {
  --bg: #07090c;
  --surface: #0b0e13;
  --line: #1a1f28;
  --line-2: #252b36;
  --ink: #eef1f5;
  --ink-2: #a3abb8;
  --ink-3: #687180;
  --accent: #22d3ee;
  --accent-ink: #00161b;
  --medium: #ffc53d;
  --high: #ff8a3d;
  --critical: #ff3d8b;
  --sans: 'IBM Plex Sans', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
  --gutter: clamp(16px, 4vw, 56px);
  --max: 1320px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img, video { display: block; max-width: 100%; }
.num { font-family: var(--mono); font-weight: 500; }

/* Header */
.top {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px var(--gutter);
  /* Solid rather than blurred: a blur behind the header is redrawn on every video frame. */
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; font-size: 15px; letter-spacing: 0.01em; }
.brand img { width: 28px; height: 28px; }
.top nav { display: flex; align-items: center; gap: 28px; font-size: 15px; }
.top nav a:not(.button) { text-decoration: none; color: var(--ink-2); }
.top nav a:not(.button):hover { color: var(--ink); }

.button {
  display: inline-block;
  padding: 13px 22px;
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: var(--accent-ink);
  font: 500 16px/1 var(--sans);
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 0 22px rgba(34, 211, 238, 0.22);
  transition: box-shadow 0.15s, transform 0.15s;
}
.button:hover { box-shadow: 0 0 30px rgba(34, 211, 238, 0.42); }
.button:active { transform: translateY(1px); }
.button.small { padding: 9px 14px; font-size: 14px; }
.button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

main > section { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* Hero */
.hero { padding-top: clamp(48px, 7vw, 96px) !important; padding-bottom: clamp(36px, 4.5vw, 56px) !important; }
h1 {
  margin: 0;
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.025em;
}
/* Each half of the headline on its own line. */
h1 span { display: block; }
.lede { max-width: 54ch; margin: 24px 0 32px; color: var(--ink-2); font-size: clamp(18px, 1.6vw, 21px); }

/* The wall */
.note { margin: 0 0 18px; color: var(--ink-3); font-size: 15px; }
.tiles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px 20px;
}
.tile video {
  width: 100%;
  aspect-ratio: 8 / 5;
  object-fit: cover;
  background: #000;
  border: 1px solid var(--line-2);
  border-radius: 4px;
}
.tile .situation { margin: 14px 0 4px; font-size: 15px; font-weight: 500; line-height: 1.35; }
.tile .outcome { margin: 0; font-size: 14px; line-height: 1.45; color: var(--ink-2); }
.grade { font-weight: 500; white-space: nowrap; }
.tile.critical .grade { color: var(--critical); }
.tile.high .grade { color: var(--high); }
.tile.medium .grade { color: var(--medium); }
/* A thin bar in the grade's colour along the bottom of each replay ties the colour to the clip. */
.tile.critical video { box-shadow: inset 0 -2px 0 var(--critical); }
.tile.high video { box-shadow: inset 0 -2px 0 var(--high); }
.tile.medium video { box-shadow: inset 0 -2px 0 var(--medium); }

/* How a test works */
.how { padding-top: clamp(96px, 12vw, 160px) !important; }
h2 { margin: 0; font-size: clamp(30px, 3.6vw, 46px); font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; }
.steps { list-style: none; margin: 40px 0 0; padding: 0; border-top: 1px solid var(--line); }
.steps li {
  display: grid;
  grid-template-columns: 64px minmax(0, 0.9fr) minmax(0, 1.4fr);
  gap: 24px;
  align-items: baseline;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}
.steps .n { font-family: var(--mono); color: var(--accent); font-size: 14px; }
.steps h3 { margin: 0; font-size: 21px; font-weight: 500; }
.steps p { margin: 0; color: var(--ink-2); }

/* Physics and the one number */
.physics { padding-top: clamp(96px, 12vw, 160px) !important; padding-bottom: clamp(80px, 10vw, 140px) !important; }
.physics .big { margin: 0; max-width: 30ch; font-size: clamp(26px, 3.2vw, 40px); line-height: 1.22; letter-spacing: -0.015em; font-weight: 500; }
.physics .fact { margin: 28px 0 0; color: var(--ink-2); font-size: 18px; }
.physics .fact .num { color: var(--ink); }

footer {
  width: min(calc(100% - 2 * var(--gutter)), calc(var(--max) - 2 * var(--gutter)));
  margin: 0 auto;
  padding: 28px 0 40px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--line);
  color: var(--ink-3);
  font-size: 14px;
}

/* Smaller screens */
@media (max-width: 1100px) {
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .top nav a:not(.button) { display: none; }
  .steps li { grid-template-columns: 40px minmax(0, 1fr); }
  .steps p { grid-column: 2; }
  footer { flex-direction: column; }
}
@media (max-width: 560px) {
  .tiles { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
