/* SeruLabs. Tokens, type and colours come from docs/design.md. */

@font-face {
  font-family: "Archivo";
  src: url("/fonts/archivo-latin-var.woff2") format("woff2");
  font-weight: 400 800;
  font-stretch: 85% 115%;
  font-display: swap;
}

@font-face {
  font-family: "Atkinson Hyperlegible Mono";
  src: url("/fonts/atkinson-hyperlegible-mono-latin-var.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

/* Local fallback tuned to Archivo's width, to keep the swap from shifting text. */
@font-face {
  font-family: "Archivo Fallback";
  src: local("Arial"), local("Liberation Sans"), local("Helvetica"), local("Roboto");
  size-adjust: 97.9%;
  ascent-override: 89.7%;
  descent-override: 21.5%;
  line-gap-override: 0%;
}

/* The hero headline is wide and heavy; its fallback is a scaled Arial Bold. */
@font-face {
  font-family: "Archivo Display Fallback";
  src: local("Arial Bold"), local("Arial-BoldMT"), local("Liberation Sans Bold"), local("Helvetica Bold"), local("Roboto Bold");
  font-weight: 700;
  size-adjust: 111.6%;
  ascent-override: 78.7%;
  descent-override: 18.8%;
  line-gap-override: 0%;
}

/* ---------- Tokens ---------- */

:root {
  color-scheme: light dark;

  /* Paper (light scheme) */
  --bg: #F3F6F9;
  --surface: #FFFFFF;
  --hairline: #CBD6E2;
  --text: #0B1B2E;
  --muted: #4B627A;
  --control: #6E8399;
  --signal: #00747D;
  --signal-strong: #005C63;
  --on-signal: #F3F6F9;
  --amber: #A35F00;
  --amber-dot: #B86E00;
  --fault: #C62D22;

  /* Screens: dark in both schemes */
  --night: #0B1B2E;
  --frost: #E7EEF6;
  --scr-edge: #23405F;

  /* Type */
  --font: "Archivo", "Archivo Fallback", system-ui, sans-serif;
  --mono: "Atkinson Hyperlegible Mono", ui-monospace, "Cascadia Mono", "Roboto Mono", monospace;
  --fs-h1: clamp(2.25rem, 1.66rem + 2.61vw, 4rem);
  --fs-h2: clamp(1.75rem, 1.36rem + 1.74vw, 3rem);
  --fs-h3: clamp(1.3125rem, 1.24rem + 0.33vw, 1.5rem);
  --fs-lead: clamp(1.125rem, 1.05rem + 0.33vw, 1.3125rem);
  --fs-body: clamp(1.0625rem, 1.04rem + 0.11vw, 1.125rem);
  --fs-small: 0.875rem;

  /* Space */
  --gutter: 16px;
  --section-pad: clamp(64px, 40px + 5vw, 112px);
  --header-h: 64px;

  /* Radii: one per kind of thing */
  --r-control: 4px;
  --r-screen: 10px;
  --r-panel: 6px;
  --r-part: 2px;

  /* Motion */
  --ease-out: cubic-bezier(0.2, 0.7, 0.3, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0B1B2E;
    --surface: #11263D;
    --hairline: #23405F;
    --text: #E7EEF6;
    --muted: #9FB2C6;
    --control: #6F86A0;
    --signal: #4FE3E9;
    --signal-strong: #8DEFF2;
    --on-signal: #0B1B2E;
    --amber: #F3B341;
    --amber-dot: #F3B341;
    --fault: #FF5E4F;
  }
}

@media (min-width: 600px) {
  :root { --gutter: 24px; }
}

@media (min-width: 1024px) {
  :root { --gutter: 48px; --header-h: 72px; }
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--fs-body);
  font-weight: 400;
  line-height: 1.55;
  font-kerning: normal;
  overflow-wrap: break-word;
}

h1,
h2,
h3 {
  margin: 0;
  text-wrap: balance;
}

p,
ul {
  margin: 0;
}


a {
  color: var(--signal);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 3px;
  border-radius: var(--r-control);
}

main:focus {
  outline: none;
}

.wrap {
  width: 100%;
  max-width: calc(1200px + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 12px 16px;
  background: var(--surface);
  color: var(--text);
  font-weight: 650;
  border: 2px solid var(--signal);
  border-radius: var(--r-control);
  transform: translateY(-200%);
}

.skip-link:focus {
  transform: none;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: var(--r-control);
  font: inherit;
  font-size: 1rem;
  font-weight: 650;
  font-stretch: 104%;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s var(--ease-out), color 0.15s var(--ease-out), border-color 0.15s var(--ease-out);
}

.btn--primary {
  background: var(--signal);
  color: var(--on-signal);
}

.btn--primary:hover {
  background: var(--signal-strong);
}

.btn--quiet {
  padding: 0 2px;
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--control);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.35em;
}

.btn--quiet:hover {
  text-decoration-color: var(--text);
  text-decoration-thickness: 2px;
}

/* ---------- Header and navigation ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--hairline);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: var(--header-h);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-right: auto;
  color: var(--text);
  text-decoration: none;
}

/* Outlined wordmark, sized to the room the header leaves on each phone width. */
.wordmark__svg {
  display: block;
  width: auto;
  height: 17px;
}

@media (min-width: 400px) {
  .wordmark__svg { height: 22px; }
}

/* A fixed width (in em, so it still follows the font size) keeps the font
   swap from nudging the header. */
.btn--header {
  width: 8.4em;
  min-height: 44px;
  padding: 0;
  font-size: 0.9375rem;
  white-space: nowrap;
}

@media (max-width: 359px) {
  .site-header__inner { gap: 6px; }
  .wordmark__svg { height: 14.5px; }
  .btn--header { width: 8em; }
  .nav-menu__toggle { min-width: 56px; padding: 0 10px; }
}

.nav-wide {
  display: none;
}

.nav-list {
  display: flex;
  gap: 4px;
  padding: 0;
  list-style: none;
}

.nav-list a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  color: var(--text);
  font-weight: 550;
  font-stretch: 104%;
  text-decoration: none;
}

.nav-list a:hover {
  text-decoration: underline;
  text-decoration-color: var(--control);
  text-underline-offset: 0.4em;
}

.nav-menu__toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 68px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--control);
  border-radius: var(--r-control);
  color: var(--text);
  font-size: 0.9375rem;
  font-weight: 650;
  font-stretch: 104%;
  list-style: none;
  cursor: pointer;
  user-select: none;
  transition: border-color 0.15s var(--ease-out);
}

.nav-menu__toggle::-webkit-details-marker {
  display: none;
}

.nav-menu__toggle:hover {
  border-color: var(--text);
}

.nav-menu__open,
.nav-menu[open] .nav-menu__closed {
  display: none;
}

.nav-menu[open] .nav-menu__open {
  display: inline;
}

.nav-menu__panel {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  padding: 4px var(--gutter) 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--hairline);
}

.nav-menu__list {
  max-width: 1200px;
  margin-inline: auto;
  padding: 0;
  list-style: none;
}

.nav-menu__list li + li {
  border-top: 1px solid var(--hairline);
}

.nav-menu__list a {
  display: flex;
  align-items: center;
  min-height: 56px;
  color: var(--text);
  font-size: 1.125rem;
  font-weight: 600;
  font-stretch: 106%;
  text-decoration: none;
}

@media (min-width: 1000px) {
  .nav-wide {
    display: block;
    margin-right: 12px;
  }

  .nav-menu {
    display: none;
  }

  .btn--header {
    width: 9.2em;
    font-size: 1rem;
  }
}

/* ---------- Status indicators ---------- */

.status-list {
  display: flex;
  flex-wrap: wrap;
  column-gap: 20px;
  padding: 0;
  list-style: none;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  color: var(--text);
  font-size: var(--fs-small);
  font-weight: 550;
  font-stretch: 102%;
}

.status::before {
  content: "";
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--amber-dot);
}

.status--open::before {
  background: var(--signal);
}

a.status {
  min-height: 44px;
  text-decoration: underline;
  text-decoration-color: var(--control);
  text-underline-offset: 0.3em;
}

a.status:hover {
  text-decoration-color: var(--text);
}

/* ---------- Hero ---------- */

.hero {
  padding: 8px 0 var(--section-pad);
}

.hero__status {
  margin-bottom: 8px;
}

.hero__title {
  margin-bottom: 24px;
  font-family: "Archivo", "Archivo Display Fallback", system-ui, sans-serif;
  font-size: var(--fs-h1);
  font-weight: 720;
  font-stretch: 112%;
  line-height: 1.04;
  letter-spacing: -0.018em;
}

.hero__screen {
  margin-bottom: 28px;
}

.hero__lead {
  max-width: 34em;
  margin-bottom: 32px;
  color: var(--muted);
  font-size: var(--fs-lead);
  line-height: 1.5;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 28px;
}

@media (min-width: 1180px) {
  .hero {
    padding-top: 24px;
  }

  .hero__grid {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    grid-template-rows: auto auto auto 1fr;
    grid-template-areas:
      "status status"
      "title  title"
      "lead   screen"
      "act    screen";
    column-gap: 48px;
  }

  /* Capped so the full-width headline stays on two lines up to 1920 px. */
  .hero__title {
    margin-bottom: 28px;
    font-size: min(var(--fs-h1), 3.5rem);
  }

  .hero__status { grid-area: status; }
  .hero__title { grid-area: title; }
  .hero__lead { grid-area: lead; }
  .hero__actions { grid-area: act; align-self: start; }

  .hero__screen {
    grid-area: screen;
    align-self: start;
    margin: 0;
  }
}

/* ---------- Screens (dark in both schemes) ---------- */

.screen {
  --signal: #4FE3E9;
  position: relative;
  overflow: hidden;
  background: var(--night);
  color: var(--frost);
  border: 1px solid var(--scr-edge);
  border-radius: var(--r-screen);
}

.scene {
  position: relative;
}

.scene__img {
  display: block;
  width: 100%;
  height: auto;
}

.scene__img:focus-visible {
  outline-offset: -4px;
}

/* The moving parts, on their own layer so the still drawing isn't repainted. */
.scene__fx {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  will-change: transform;
}

.scene--wide {
  display: none;
}

.hero__screen {
  max-width: 520px;
}

.hero__tag {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
}

@media (min-width: 720px) {
  .scene--wide {
    display: block;
  }

  .scene--phone {
    display: none;
  }

  .hero__screen {
    max-width: 760px;
  }
}

@media (min-width: 1180px) {
  .hero__screen {
    max-width: none;
  }
}

.screen__replay {
  position: absolute;
  right: 10px;
  bottom: 10px;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid #6F86A0;
  border-radius: var(--r-control);
  background: var(--night);
  color: var(--frost);
  font: inherit;
  font-size: var(--fs-small);
  font-weight: 600;
  font-stretch: 104%;
  cursor: pointer;
  transition: border-color 0.15s var(--ease-out);
}

.screen__replay:hover {
  border-color: var(--frost);
}

.screen__replay[hidden] {
  display: none;
}

/* Scene parts. The markup is the final frame. */

.scn-grid { fill: none; stroke: #23405F; stroke-width: 1; opacity: 0.42; }
.scn-pole { stroke: #3A5B80; stroke-width: 1.6; stroke-linecap: round; }
.scn-closure,
.scn-splitter { fill: #18314E; stroke: #9FB2C6; stroke-width: 1; }
.scn-port { fill: #4FE3E9; }

.scn-cable,
.scn-glow,
.scn-lit,
.scn-pulse { fill: none; stroke-linecap: round; }
.scn-cable { stroke: #3A5B80; stroke-width: 1.6; }
.scn-glow { stroke: #4FE3E9; stroke-width: 5; opacity: 0.22; }
.scn-lit { stroke: #4FE3E9; stroke-width: 1.6; }
.scn-drain { stroke-linecap: butt; stroke-dasharray: 1 2; stroke-dashoffset: -1.05; }
.scn-pulse { stroke: #C9F7F9; stroke-width: 3; stroke-dasharray: 3 37; }
.scn-pulses { opacity: 0; }

.scn-ont-off { fill: #4A6584; }
.scn-ont-on { fill: #4FE3E9; }
.scn-ont-glow { fill: #4FE3E9; opacity: 0.25; }
.scn-ont-lit { opacity: 0; }

.scn-bridge { stroke: #4FE3E9; stroke-width: 1.6; opacity: 0; }
.scn-end { stroke: #FF5E4F; stroke-width: 2.2; stroke-linecap: round; }
.scn-flash { fill: #FF5E4F; opacity: 0; }

.scn-bracket { fill: none; stroke: #FF5E4F; stroke-width: 1.6; stroke-dasharray: 5 4; }
.scn-leader { fill: none; stroke: #FF5E4F; stroke-width: 1; }
.scn-callout-box { fill: #0B1B2E; stroke: #2E4E72; stroke-width: 1; }
.scn-fault-mark { fill: #FF5E4F; }
.scn-sent-dot { fill: #4FE3E9; }

.scn-id {
  fill: #9FB2C6;
  font-family: var(--mono);
  font-size: 18px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.scn-id--key { fill: #E7EEF6; font-weight: 600; }

.scn-co {
  fill: #E7EEF6;
  font-family: var(--font);
  font-size: 18px;
  font-weight: 560;
  font-stretch: 90%;
  font-variant-numeric: tabular-nums;
}

.scn-co--fault { fill: #FF5E4F; font-weight: 680; }
.scn-co--sent { fill: #4FE3E9; }

.scene--phone .scn-id,
.scene--phone .scn-co { font-size: 15.5px; }

/* The storyboard. Only when scripts can run it and motion is welcome. Each
   animation is declared paused (healthy first frame); site.js plays it when
   the screen is in view. */
@media (scripting: enabled) and (prefers-reduced-motion: no-preference) {
  .scn-pulses { animation: scn-pulse-life 5.4s linear both paused; }
  .scn-pulse { animation: scn-flow 1.1s linear 5 both paused; }
  .scn-s12-pulses { animation: scn-off 0.12s linear 2.5s both paused; }

  .scn-bridge { animation: scn-off 0.08s linear 2.5s both paused; }
  .scn-flash { animation: scn-flash 0.5s var(--ease-out) 2.5s both paused; }
  .scn-end { animation: scn-on 0.12s linear 2.5s both paused; }
  .scn-vfl { animation: scn-on 0.6s var(--ease-out) 2.55s both paused; }

  .scn-drain { animation: scn-drain 0.4s ease-in 2.55s both paused; }
  .scn-drain--drop { animation-duration: 0.25s; animation-delay: 2.85s; }

  .scn-ont-lit { animation: scn-off 0.12s ease-out both paused; }
  .scn-ont-d1 { animation-delay: 2.95s; }
  .scn-ont-d2 { animation-delay: 3s; }
  .scn-ont-d3 { animation-delay: 3.05s; }
  .scn-ont-d4 { animation-delay: 3.1s; }

  .scn-bracket-layer { animation: scn-on 0.3s var(--ease-out) 3.4s both paused; }
  .scn-callout-main { animation: scn-rise 0.3s var(--ease-out) 3.8s both paused; }
  .scn-notified { animation: scn-rise 0.3s var(--ease-out) 4.8s both paused; }

  @keyframes scn-flow {
    from { stroke-dashoffset: 0; }
    to { stroke-dashoffset: -40; }
  }

  @keyframes scn-pulse-life {
    0%, 88% { opacity: 1; }
    100% { opacity: 0; }
  }

  @keyframes scn-on {
    from { opacity: 0; }
    to { opacity: 1; }
  }

  @keyframes scn-off {
    from { opacity: 1; }
    to { opacity: 0; }
  }

  @keyframes scn-rise {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: none; }
  }

  @keyframes scn-flash {
    0% { opacity: 0; transform: scale(0.3); }
    15% { opacity: 1; }
    100% { opacity: 0; transform: scale(1.9); }
  }

  @keyframes scn-drain {
    from { stroke-dashoffset: 0; }
    to { stroke-dashoffset: -1.05; }
  }
}

/* ---------- Sections ---------- */

.section {
  padding: var(--section-pad) 0;
}

h2 {
  max-width: 22ch;
  margin-bottom: 16px;
  font-size: var(--fs-h2);
  font-weight: 680;
  font-stretch: 110%;
  line-height: 1.1;
  letter-spacing: -0.012em;
}

h3 {
  font-size: var(--fs-h3);
  font-weight: 650;
  font-stretch: 106%;
  line-height: 1.2;
}

.intro {
  max-width: 34em;
  color: var(--muted);
  font-size: var(--fs-lead);
  line-height: 1.5;
}

/* ---------- Pillars on a 1:4 splitter ---------- */

.pillars {
  --g: 34px;        /* fibre gutter */
  --o: 4px;         /* first strand */
  --sp: 5px;        /* strand spacing */
  --strand: 1.5px;
  --rule-y: 18px;   /* where a strand turns into its row */
  --x-in: calc(var(--o) + 1.5 * var(--sp));
}

@media (min-width: 1024px) {
  .pillars {
    --g: 96px;
    --o: 14px;
    --sp: 7px;
  }
}

.pillars__head {
  position: relative;
  padding: 0 0 32px var(--g);
}

/* The single strand coming in from above. */
.pillars__head::before,
.splitter::before {
  content: "";
  position: absolute;
  left: calc(var(--x-in) - var(--strand) / 2);
  border-left: var(--strand) solid var(--signal);
}

.pillars__head::before {
  top: calc(var(--fs-h2) * 0.55);
  bottom: 0;
}

.splitter {
  position: relative;
  height: 64px;
}

.splitter::before {
  top: 0;
  height: 12px;
}

.splitter__box {
  position: absolute;
  top: 12px;
  left: calc(var(--x-in) - 24px);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 28px;
  border: 1px solid var(--control);
  border-radius: var(--r-part);
  background: var(--surface);
  color: var(--muted);
  font-family: var(--mono);
  font-size: var(--fs-small);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.splitter .strands {
  top: 40px;
}

.strands {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: var(--g);
}

.strands i {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--o) - var(--strand) / 2);
  border-left: var(--strand) solid var(--signal);
}

.strands i:nth-child(2) { left: calc(var(--o) + var(--sp) - var(--strand) / 2); }
.strands i:nth-child(3) { left: calc(var(--o) + 2 * var(--sp) - var(--strand) / 2); }
.strands i:nth-child(4) { left: calc(var(--o) + 3 * var(--sp) - var(--strand) / 2); }

.strands .strand-turn {
  bottom: auto;
  right: 6px;
  height: calc(var(--rule-y) + var(--strand) / 2);
  border-bottom: var(--strand) solid var(--signal);
  border-bottom-left-radius: 8px;
}

/* The connector where the strand meets its row. */
.strand-turn::after {
  content: "";
  position: absolute;
  right: -6px;
  bottom: calc(-3px - var(--strand) / 2);
  width: 6px;
  height: 6px;
  background: var(--signal);
}

.pillar {
  position: relative;
  padding: calc(var(--rule-y) + 24px) 0 44px var(--g);
}

.pillar::before {
  content: "";
  position: absolute;
  top: calc(var(--rule-y) - 0.5px);
  left: var(--g);
  right: 0;
  border-top: 1px solid var(--hairline);
}

.pillar:last-child {
  padding-bottom: 0;
}

.pillar h3 {
  margin-bottom: 6px;
}

.pillar__lead {
  max-width: 26em;
  margin-bottom: 20px;
  color: var(--muted);
  font-size: var(--fs-lead);
  line-height: 1.45;
}

.pillar__points {
  display: grid;
  gap: 12px;
  max-width: 40em;
  padding: 0;
  list-style: none;
}

.pillar__points li,
.dash-list li {
  position: relative;
  padding-left: 22px;
}

.pillar__points li::before,
.dash-list li::before {
  content: "";
  position: absolute;
  top: 0.78em;
  left: 0;
  width: 10px;
  border-top: 1.5px solid var(--control);
}

.pillar__more {
  margin-top: 20px;
  font-weight: 600;
}

@media (min-width: 1024px) {
  .pillar__more {
    grid-column: 2;
  }

  .pillar {
    display: grid;
    grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
    column-gap: 48px;
    padding-top: calc(var(--rule-y) + 32px);
    padding-bottom: 56px;
  }

  .pillar__lead {
    margin-bottom: 0;
  }
}

/* ---------- Shared bits ---------- */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.dash-list {
  display: grid;
  gap: 10px;
  padding: 0;
  list-style: none;
}

/* "Example" and similar labels: a small outlined tag, sentence case. */
.label-tag {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 8px;
  border: 1px solid var(--control);
  border-radius: 3px;
  color: var(--muted);
  font-size: var(--fs-small);
  font-weight: 550;
  line-height: 1;
  white-space: nowrap;
}

.screen .label-tag {
  border-color: #3A5B80;
  color: #9FB2C6;
}

.screen__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  min-height: 60px;
  padding: 8px 10px 8px 16px;
  border-bottom: 1px solid var(--scr-edge);
}

.screen__title {
  font-size: 1rem;
  font-weight: 650;
  font-stretch: 104%;
}

.screen__replay--bar {
  position: static;
  margin-left: auto;
}

/* ---------- How it works ---------- */

.how__grid {
  display: grid;
  gap: 40px;
  margin-top: 40px;
}

.steps {
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.step {
  position: relative;
  padding: 10px 0 10px 48px;
  border-left: 2px solid var(--hairline);
  counter-increment: step;
}

.step + .step {
  margin-top: 2px;
}

/* The Signal rule a step gets as its log lines appear. */
.step::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -2px;
  width: 2px;
  background: var(--signal);
  transform-origin: top;
}

.step::after {
  content: counter(step);
  position: absolute;
  top: 10px;
  left: 18px;
  color: var(--muted);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

.step strong {
  font-weight: 680;
}

.how__note {
  max-width: 34em;
  margin-top: 24px;
  color: var(--muted);
}

.log {
  margin: 0;
  padding: 14px 16px 18px;
  list-style: none;
  font-family: var(--mono);
  font-size: var(--fs-small);
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
}

.log > li {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 12px;
  padding: 5px 0;
}

.log__time,
.log__tag {
  color: #9FB2C6;
}

.log__msg {
  grid-column: 1 / -1;
  color: var(--frost);
}

.log__line--fault .log__msg { color: #FF5E4F; }
.log__line--amber .log__msg { color: #F3B341; }
.log__line--signal .log__msg { color: #4FE3E9; }

.log > .log__gap {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  color: #9FB2C6;
}

.log__gap::before,
.log__gap::after {
  content: "";
  flex: 1;
  border-top: 1px solid var(--scr-edge);
}

@media (min-width: 600px) {
  .log {
    padding: 16px 20px 20px;
  }

  .log > li {
    grid-template-columns: 9ch 8ch 1fr;
    padding: 4px 0;
  }

  .log__msg {
    grid-column: auto;
  }
}

.how__example {
  min-width: 0;
}

.how__example .chat-panel {
  margin-top: 40px;
}

.chat-panel__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin-bottom: 16px;
}

.toggle {
  display: inline-flex;
  margin: 0 0 16px;
  padding: 0;
  border: 1px solid var(--control);
  border-radius: var(--r-control);
}

.toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.toggle label {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  color: var(--text);
  font-size: 1rem;
  font-weight: 550;
  cursor: pointer;
  transition: background-color 0.15s var(--ease-out), color 0.15s var(--ease-out);
}

.toggle label + input + label {
  border-left: 1px solid var(--control);
}

.toggle input:checked + label {
  background: var(--text);
  color: var(--bg);
  font-weight: 650;
}

.toggle input:focus-visible + label {
  outline: 2px solid var(--signal);
  outline-offset: 2px;
}

.chat {
  max-width: 34em;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: var(--r-panel);
  background: var(--bg);
}

.chat__head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--hairline);
  background: var(--surface);
}

.chat__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--control);
  border-radius: 50%;
  font-size: 0.8125rem;
  font-weight: 700;
  font-stretch: 108%;
}

.chat__name {
  font-weight: 650;
}

.chat__body {
  padding: 16px 14px 20px;
}

.bubble {
  max-width: 30em;
  padding: 12px 14px 8px;
  border: 1px solid var(--hairline);
  border-radius: 4px 16px 16px 16px;
  background: var(--surface);
}

.bubble__time {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: var(--fs-small);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.bubble + .bubble {
  margin-top: 12px;
}

@supports selector(:has(*)) {
  .chat-panel:has(#msg-en:checked) .bubble--sw,
  .chat-panel:has(#msg-sw:checked) .bubble--en,
  .how__grid:has(#ex-cut:checked) .ex-wireless,
  .how__grid:has(#ex-wireless:checked) .ex-cut {
    display: none;
  }

  .bubble + .bubble {
    margin-top: 0;
  }
}

.chat-panel__caption {
  max-width: 34em;
  margin-top: 12px;
  color: var(--muted);
  font-size: 1rem;
}

@media (min-width: 1024px) {
  .how__grid,
  .capacity__grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    align-items: start;
    column-gap: 48px;
  }

  .how__example .chat-panel {
    margin-top: 48px;
  }

  .log,
  .readings {
    font-size: 0.9375rem;
  }
}

/* ---------- Capacity ---------- */

.capacity__grid {
  display: grid;
  gap: 40px;
  margin-top: 40px;
}

/* The How it works steps, without the Signal rules: nothing here plays. */
.steps--plain .step::before {
  display: none;
}

.step__head {
  margin-bottom: 4px;
}

.step__label {
  margin-left: 4px;
  color: var(--muted);
  font-size: var(--fs-small);
  font-weight: 550;
}

.readings__period {
  padding: 14px 16px 0;
  color: #9FB2C6;
  font-family: var(--mono);
  font-size: var(--fs-small);
}

.readings {
  margin: 0;
  padding: 8px 16px 18px;
  list-style: none;
  font-family: var(--mono);
  font-size: var(--fs-small);
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
}

.readings > li {
  display: grid;
  padding: 5px 0;
}

.readings__tag {
  color: #9FB2C6;
}

.readings__msg {
  color: var(--frost);
}

.readings__line--amber .readings__msg { color: #F3B341; }
.readings__line--signal .readings__msg { color: #4FE3E9; }

.capacity__ideas h3 {
  margin-bottom: 12px;
  font-size: 1.125rem;
}

.capacity__closing {
  max-width: 34em;
  margin-bottom: 20px;
}

@media (min-width: 600px) {
  .readings__period {
    padding: 16px 20px 0;
  }

  .readings {
    padding: 8px 20px 20px;
  }

  .readings > li {
    grid-template-columns: 9ch 1fr;
    column-gap: 12px;
    padding: 4px 0;
  }
}

@media (min-width: 1024px) {
  .capacity__grid {
    grid-template-rows: auto auto 1fr;
    row-gap: 40px;
  }

  .capacity__grid > * {
    grid-column: 1;
  }

  .capacity__grid > .capacity-screen {
    grid-column: 2;
    grid-row: 1 / span 3;
  }
}

/* ---------- More features ---------- */

.features__list {
  display: grid;
  gap: 20px;
  max-width: 40em;
  margin-top: 32px;
  padding: 0;
  list-style: none;
}

.features__list strong {
  display: block;
  font-weight: 680;
}

@media (min-width: 1024px) {
  .features__list {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 32px;
    max-width: none;
  }

  .features__list li {
    padding-top: 16px;
    border-top: 1px solid var(--hairline);
  }
}

/* ---------- For engineers ---------- */

.arch {
  margin: 40px 0 56px;
}

.arch__svg {
  display: block;
  width: 100%;
  height: auto;
}

.arch__svg--wide {
  display: none;
}

.arch__svg--tall {
  max-width: 440px;
}

@media (min-width: 1024px) {
  .arch__svg--wide { display: block; }
  .arch__svg--tall { display: none; }
}

.ar-boundary { fill: none; stroke: var(--control); stroke-width: 1.5; stroke-dasharray: 7 5; }
.ar-box { fill: var(--surface); stroke: var(--hairline); stroke-width: 1; }
.ar-box--key { stroke: var(--control); }
.ar-box--inner { fill: var(--bg); }
.ar-link { fill: none; stroke: var(--control); stroke-width: 1; }
.ar-backup { fill: none; stroke: var(--control); stroke-width: 1.25; }
.ar-strand { fill: none; stroke: var(--signal); stroke-width: 2; }
.ar-arrow { fill: var(--signal); }
.ar-arrow--muted { fill: var(--control); }
.ar-flash { fill: none; stroke: var(--signal); stroke-width: 2.5; opacity: 0; }

.ar-pulse,
.ar-pulse-glow {
  fill: none;
  stroke: var(--signal);
  stroke-linecap: round;
  stroke-dasharray: 0.06 2;
  stroke-dashoffset: 0.07;
}

.ar-pulse { stroke-width: 4; }
.ar-pulse-glow { stroke-width: 12; opacity: 0.25; }

.ar-t {
  fill: var(--text);
  font-family: var(--font);
  font-size: 17.5px;
  font-weight: 500;
  font-stretch: 94%;
}

.arch__svg--wide .ar-t { font-size: 16px; }
.ar-t--strong { font-weight: 680; font-stretch: 100%; }
.ar-t--muted { fill: var(--muted); }

.points {
  display: grid;
  gap: 28px;
}

.point h3 {
  margin-bottom: 8px;
}

.spec-title {
  margin: 56px 0 16px;
}

.spec {
  margin: 0;
  border-bottom: 1px solid var(--hairline);
}

.spec--security {
  margin-top: 32px;
}

.spec__row {
  padding: 14px 0;
  border-top: 1px solid var(--hairline);
}

.spec dt {
  font-weight: 680;
}

.spec dd {
  max-width: 40em;
  margin: 4px 0 0;
}

@media (min-width: 768px) {
  .points {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 48px;
    row-gap: 36px;
  }

  .spec__row {
    display: grid;
    grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
    column-gap: 48px;
  }

  .spec dd {
    margin: 0;
  }
}

/* ---------- Coming next ---------- */

.next__status {
  margin: 8px 0 16px;
}

.next__body {
  max-width: 34em;
}

.next__list {
  margin-top: 20px;
}

.next__closing {
  margin: 24px 0 20px;
  font-weight: 650;
}

.otdr {
  margin-top: 40px;
  max-width: 680px;
}

.otdr__tag {
  position: absolute;
  top: 12px;
  right: 12px;
}

.otdr__svg {
  display: block;
  width: 100%;
  height: auto;
}

.otdr__svg--wide { display: none; }

@media (min-width: 600px) {
  .otdr__svg--wide { display: block; }
  .otdr__svg--narrow { display: none; }
}

@media (min-width: 1024px) {
  .next__grid {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    align-items: center;
    column-gap: 48px;
  }

  .otdr {
    margin-top: 0;
    max-width: none;
  }
}

.ot-grid { fill: none; stroke: #23405F; stroke-width: 1; }
.ot-axis { fill: none; stroke: #6F86A0; stroke-width: 1.2; }
.ot-trace,
.ot-trace-glow {
  fill: none;
  stroke: #4FE3E9;
  stroke-linejoin: round;
  stroke-linecap: round;
  stroke-dasharray: 1 1;
  stroke-dashoffset: 0;
}
.ot-trace { stroke-width: 2; }
.ot-trace-glow { stroke-width: 6; opacity: 0.22; }
.ot-break-line { fill: none; stroke: #FF5E4F; stroke-width: 1.5; stroke-dasharray: 4 4; }
.ot-break-mark { fill: #FF5E4F; }

.ot-tick {
  fill: #9FB2C6;
  font-family: var(--mono);
  font-size: 17.5px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.ot-tick--fault { fill: #FF5E4F; font-weight: 650; }

/* ---------- Join the pilot ---------- */

.pilot__info h3 {
  margin: 32px 0 12px;
}

.pilot__info .intro + h3 {
  margin-top: 40px;
}

.pilot__info p:not(.intro) {
  max-width: 34em;
}

.pilot__panel {
  margin-top: 48px;
  padding: 24px 20px;
  border: 1px solid var(--hairline);
  border-radius: var(--r-panel);
  background: var(--surface);
}

@media (min-width: 600px) {
  .pilot__panel { padding: 32px; }
}

@media (min-width: 1024px) {
  .pilot__grid {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    align-items: start;
    column-gap: 48px;
  }

  .pilot__panel { margin-top: 0; }
}

.form-intro {
  margin-bottom: 24px;
  font-size: var(--fs-h3);
  font-weight: 650;
  font-stretch: 106%;
  line-height: 1.2;
}

.form-nojs {
  display: none;
}

@media (scripting: none) {
  .form-nojs { display: block; }
  .form { display: none; }
}

.field {
  margin: 0 0 20px;
  padding: 0;
  border: 0;
}

.field label,
.field legend {
  display: block;
  margin-bottom: 6px;
  padding: 0;
  font-weight: 620;
}

.field__optional {
  color: var(--muted);
  font-weight: 400;
}

.field input[type="text"],
.field input[type="tel"],
.field input[type="email"],
.field select,
.field textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid var(--control);
  border-radius: var(--r-control);
  background: var(--bg);
  color: var(--text);
  font: inherit;
  line-height: 1.4;
}

.field textarea {
  min-height: 120px;
  resize: vertical;
}

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  outline-offset: 1px;
}

.field [aria-invalid="true"] {
  border-color: var(--fault);
  box-shadow: inset 0 0 0 1px var(--fault);
}

.field__error {
  margin-top: 6px;
  color: var(--fault);
  font-weight: 600;
}

.field--choices legend {
  margin-bottom: 4px;
}

.choice {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
}

.choice input {
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--signal);
}

.choice label {
  margin: 0;
  font-weight: 400;
  cursor: pointer;
}

.field-pair {
  margin-bottom: 20px;
}

.field-pair .field {
  margin-bottom: 16px;
}

.field-pair__hint {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 1rem;
}

.field-pair > .field__error {
  margin-top: -6px;
}

.form__submit {
  margin-top: 8px;
}

.form__help {
  margin-top: 12px;
  color: var(--muted);
  font-size: 1rem;
}

.form__sent:not(:empty) {
  margin-top: 20px;
  padding-left: 14px;
  border-left: 2px solid var(--signal);
}

.form__alt {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--hairline);
}

/* ---------- About ---------- */

.about__quote {
  margin: 32px 0 0;
}

.byline {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.monogram {
  flex: none;
  width: 72px;
  height: 72px;
}

.byline__name {
  font-weight: 620;
}

.mono-disc { fill: var(--surface); stroke: var(--hairline); stroke-width: 1; }
.mono-ring { fill: none; stroke: var(--signal); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.mono-tip { fill: var(--signal); }

.mono-text {
  fill: var(--text);
  font-family: var(--font);
  font-size: 30px;
  font-weight: 620;
  font-stretch: 112%;
  letter-spacing: -0.01em;
}

.pull-quote {
  margin: 0;
}

.pull-quote p {
  max-width: 30em;
  font-size: clamp(1.5rem, 1.2rem + 1.3vw, 2.25rem);
  font-weight: 500;
  font-stretch: 104%;
  line-height: 1.3;
  letter-spacing: -0.008em;
  text-indent: -0.42em;
}

.about__text {
  display: grid;
  gap: 16px;
  margin-top: 40px;
}

.about__text p {
  max-width: 34em;
}

.about__closing {
  font-weight: 680;
}

@media (min-width: 768px) {
  .monogram {
    width: 96px;
    height: 96px;
  }
}

@media (min-width: 1024px) {
  .about__text {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 48px;
  }

  .about__closing {
    grid-column: 1 / -1;
  }
}

/* ---------- Questions ---------- */

.faq__list {
  max-width: 70ch;
  margin-top: 32px;
  border-bottom: 1px solid var(--hairline);
}

.faq__item {
  border-top: 1px solid var(--hairline);
}

.faq__item summary {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 14px 48px 14px 0;
  font-weight: 620;
  list-style: none;
  cursor: pointer;
}

.faq__item summary::-webkit-details-marker {
  display: none;
}

/* Plus that becomes a minus. */
.faq__item summary::before,
.faq__item summary::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 12px;
  width: 14px;
  border-top: 2px solid var(--text);
  transition: transform 0.18s var(--ease-out);
}

.faq__item summary::after {
  transform: rotate(90deg);
}

.faq__item[open] summary::after {
  transform: rotate(0deg);
}

.faq__answer {
  padding: 0 48px 20px 0;
}

/* ---------- Fibre scroll line ---------- */

.scroll-line {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: 2px;
  background: var(--hairline);
  pointer-events: none;
}

.scroll-line[hidden] {
  display: none;
}

.scroll-line__fill {
  position: absolute;
  inset: 0;
  background: var(--signal);
  transform: translateX(-100%);
  will-change: transform;
}

/* Its leading edge: the standard glow, a wider low-opacity stroke. */
.scroll-line__fill::after {
  content: "";
  position: absolute;
  top: -2px;
  right: -6px;
  width: 12px;
  height: 6px;
  border-radius: 3px;
  background: var(--signal);
  opacity: 0.35;
}

/* ---------- Storyboards: agent log, architecture pulse, OTDR trace ---------- */
/* Each animation is declared paused; site.js plays it when it comes into view. */

@media (scripting: enabled) and (prefers-reduced-motion: no-preference) {
  .log > li { animation: sb-line 0.22s var(--ease-out) both paused; }
  .log > li:nth-child(1) { animation-delay: 0.2s; }
  .log > li:nth-child(2) { animation-delay: 0.6s; }
  .log > li:nth-child(3) { animation-delay: 1s; }
  .log > li:nth-child(4) { animation-delay: 1.4s; }
  .log > li:nth-child(5) { animation-delay: 1.8s; }
  .log > li:nth-child(6) { animation-delay: 2.2s; }
  .log > li:nth-child(7) { animation-delay: 2.6s; }
  .log > li:nth-child(8) { animation-delay: 3s; }
  .log > li:nth-child(9) { animation-delay: 3.4s; }
  .log > li:nth-child(10) { animation-delay: 3.8s; }
  .log > li:nth-child(11) { animation-delay: 4.4s; }
  .log > li:nth-child(12) { animation-delay: 5s; }
  .log > li:nth-child(13) { animation-delay: 5.4s; }

  .step::before { animation: sb-rule 0.3s var(--ease-out) both paused; }
  .step--detect::before { animation-delay: 0.2s; }
  .step--group::before { animation-delay: 0.6s; }
  .step--power::before { animation-delay: 1s; }
  .step--billing::before { animation-delay: 1.4s; }
  .step--locate::before { animation-delay: 1.8s; }
  .step--act::before { animation-delay: 3.4s; }
  .step--close::before { animation-delay: 5s; }

  .ar-pulse--out { animation: sb-pulse 1s ease-in-out both paused; }
  .ar-flash--cloud { animation: sb-flash 0.4s var(--ease-out) 1s both paused; }
  .ar-pulse--split { animation: sb-pulse 1s ease-in-out 1.4s both paused; }
  .ar-flash--people,
  .ar-flash--team { animation: sb-flash 0.5s var(--ease-out) 2.35s both paused; }

  .ot-trace,
  .ot-trace-glow { animation: sb-draw 1.2s ease-in-out both paused; }
  .ot-break { animation: sb-show 0.3s var(--ease-out) 1.05s both paused; }

  .bubble { animation: ui-fade 0.16s var(--ease-out); }

  @keyframes sb-line {
    from { opacity: 0; transform: translateX(-6px); }
    to { opacity: 1; transform: none; }
  }

  @keyframes sb-rule {
    from { transform: scaleY(0); }
    to { transform: scaleY(1); }
  }

  @keyframes sb-pulse {
    from { stroke-dashoffset: 0.07; }
    to { stroke-dashoffset: -1.02; }
  }

  @keyframes sb-flash {
    0% { opacity: 0; }
    30% { opacity: 1; }
    100% { opacity: 0; }
  }

  @keyframes sb-draw {
    from { stroke-dashoffset: 1; }
    to { stroke-dashoffset: 0; }
  }

  @keyframes sb-show {
    from { opacity: 0; }
    to { opacity: 1; }
  }

  @keyframes ui-fade {
    from { opacity: 0; }
    to { opacity: 1; }
  }
}

/* ---------- Privacy policy and 404 ---------- */

.page-title {
  max-width: 20ch;
  font-family: "Archivo", "Archivo Display Fallback", system-ui, sans-serif;
  font-size: var(--fs-h2);
  font-weight: 700;
  font-stretch: 112%;
  line-height: 1.08;
  letter-spacing: -0.015em;
}

.prose .wrap > * {
  max-width: 44rem;
}

.prose__updated {
  margin: 12px 0 8px;
  color: var(--muted);
}

.prose h2 {
  margin: 40px 0 12px;
  font-size: var(--fs-h3);
  font-weight: 650;
  font-stretch: 106%;
}

.prose p + p,
.prose ul + p {
  margin-top: 12px;
}

.prose ul {
  margin: 12px 0;
}

.prose strong {
  font-weight: 650;
}

.not-found {
  padding-bottom: var(--section-pad);
}

.not-found__fibre {
  display: block;
  width: 100%;
  height: 72px;
  margin: 56px 0 40px;
}

.nf-lit,
.nf-glow,
.nf-end,
.nf-dark {
  fill: none;
  stroke-linecap: round;
}

.nf-lit { stroke: var(--signal); stroke-width: 2; }
.nf-glow { stroke: var(--signal); stroke-width: 6; opacity: 0.22; }
.nf-end { stroke: #FF5E4F; stroke-width: 2.4; }
.nf-dark { stroke: var(--control); stroke-width: 2; }

.not-found__text p {
  max-width: 34em;
  margin: 16px 0 28px;
}

/* ---------- Footer ---------- */

.site-footer {
  padding: 48px 0 64px;
  border-top: 1px solid var(--hairline);
  color: var(--muted);
  font-size: 1rem;
}

.site-footer__inner {
  display: grid;
  gap: 8px;
}

.site-footer .wordmark {
  min-height: 0;
  margin: 0;
}

.site-footer .wordmark__svg {
  height: 17px;
}

.site-footer__contact {
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
  padding: 0;
  list-style: none;
}

.site-footer__contact a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* ---------- Motion preferences ---------- */

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }

  .nav-menu[open] .nav-menu__panel {
    animation: menu-in 0.16s var(--ease-out);
  }

  @keyframes menu-in {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: none; }
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}

/* Names with a hyphen (M-Pesa, Wi-Fi) stay on one line. */
.nowrap {
  white-space: nowrap;
}
