@font-face {
  font-family: "Instrument Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/docs/fonts/instrument-sans.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/docs/fonts/ibm-plex-mono.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/docs/fonts/ibm-plex-mono-600.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/docs/fonts/ibm-plex-mono-700.woff2") format("woff2");
}

:root {
  color-scheme: light;
  --paper: #f4f1ea;
  --ink: #151713;
  --muted: #64675f;
  --line: #cfcec6;
  --soft: #e9e5dc;
  --acid: #dfff39;
  --orange: #ff6b35;
  --white: #fffef8;
  font-family: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
}
a {
  color: inherit;
}
code,
pre {
  font-family: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}
.skip-link {
  position: fixed;
  left: 1rem;
  top: -4rem;
  z-index: 20;
  background: var(--acid);
  padding: 0.75rem 1rem;
  font-weight: 700;
}
.skip-link:focus {
  top: 1rem;
}
:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  height: 70px;
  padding: 0 clamp(1rem, 4vw, 4.5rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(16px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: inherit;
  text-decoration: none;
  font:
    700 0.82rem/1 "IBM Plex Mono",
    monospace;
  letter-spacing: -0.04em;
}
.brand img {
  width: 24px;
  height: 24px;
}
.topbar nav {
  display: flex;
  align-items: center;
  gap: clamp(0.8rem, 2.5vw, 2.2rem);
  font-size: 0.84rem;
  font-weight: 650;
}
.topbar nav a {
  text-decoration: none;
}
.topbar nav a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.dashboard-link {
  border: 1px solid var(--ink);
  padding: 0.65rem 0.85rem;
}
.mobile-jump {
  display: none;
}

main {
  overflow: hidden;
}
.hero {
  min-height: 680px;
  padding: clamp(5rem, 10vw, 9rem) clamp(1rem, 6vw, 7rem) 5rem;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
  gap: clamp(3rem, 8vw, 9rem);
  align-items: end;
  border-bottom: 1px solid var(--line);
  position: relative;
}
.hero::before {
  content: "R";
  position: absolute;
  right: -3vw;
  top: -9rem;
  color: transparent;
  -webkit-text-stroke: 1px #dedbd2;
  font:
    800 min(48vw, 650px)/1 Arial,
    sans-serif;
  z-index: -1;
}
.eyebrow {
  margin: 0 0 1.2rem;
  font:
    700 0.72rem/1.2 "IBM Plex Mono",
    monospace;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
}
h1 {
  margin: 0;
  max-width: 900px;
  font-size: clamp(3.6rem, 8.4vw, 8.9rem);
  line-height: 0.84;
  letter-spacing: -0.075em;
  font-weight: 730;
}
.hero-lede {
  max-width: 670px;
  margin: 2.2rem 0 0;
  font-size: clamp(1.08rem, 1.6vw, 1.35rem);
  line-height: 1.55;
  color: #42463f;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.4rem;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 1.2rem;
  border: 1px solid var(--ink);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
}
.button.primary {
  background: var(--ink);
  color: var(--white);
}
.button.secondary {
  background: transparent;
}
.button:hover {
  transform: translateY(-2px);
  box-shadow: 4px 4px 0 var(--orange);
}
.status-panel {
  border-top: 5px solid var(--ink);
  background: var(--white);
  padding: 1.25rem;
  box-shadow: 12px 12px 0 var(--soft);
}
.status-heading {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
  font:
    700 0.75rem/1 "IBM Plex Mono",
    monospace;
  text-transform: uppercase;
}
.signal {
  width: 9px;
  height: 9px;
  background: #25ad57;
  border-radius: 50%;
  box-shadow: 0 0 0 4px #25ad5720;
}
.signal.pending {
  background: var(--orange);
  box-shadow: 0 0 0 4px #ff6b3525;
}
.signal.unavailable {
  background: #b42318;
  box-shadow: 0 0 0 4px #b4231825;
}
.status-panel dl {
  margin: 0;
}
.status-panel dl div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--line);
}
.status-panel dt {
  color: var(--muted);
  font-size: 0.8rem;
}
.status-panel dd {
  margin: 0;
  text-align: right;
  font:
    600 0.75rem/1.4 "IBM Plex Mono",
    monospace;
}
.status-panel > a {
  display: flex;
  justify-content: space-between;
  margin-top: 1.1rem;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
}

.release-gate {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 1.5rem;
  align-items: center;
  margin: 0;
  padding: 2.2rem clamp(1rem, 6vw, 7rem);
  color: #261108;
  background: var(--orange);
  border-bottom: 1px solid var(--ink);
}
.gate-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 2px solid currentColor;
  border-radius: 50%;
  font: 800 1.4rem/1 monospace;
}
.release-gate .eyebrow {
  color: #32150a;
  margin-bottom: 0.45rem;
}
.release-gate h2 {
  margin: 0;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  letter-spacing: -0.03em;
}
.release-gate p:not(.eyebrow) {
  max-width: 850px;
  margin: 0.65rem 0 0;
  line-height: 1.5;
}
.release-gate > a {
  white-space: nowrap;
  font-size: 0.8rem;
  font-weight: 750;
  text-underline-offset: 4px;
}

.architecture,
.contract {
  padding: clamp(5rem, 10vw, 9rem) clamp(1rem, 6vw, 7rem);
}
.section-intro {
  max-width: 760px;
}
.section-intro h2 {
  margin: 0;
  font-size: clamp(2.6rem, 5.4vw, 5.6rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
}
.section-intro > p:last-child {
  max-width: 620px;
  font-size: 1.1rem;
  line-height: 1.55;
  color: var(--muted);
}
.flow {
  margin-top: 4rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(36px, 5vw, 80px);
  align-items: stretch;
  padding: 0;
  list-style: none;
}
.flow li {
  position: relative;
  min-height: 230px;
  padding: 1.6rem;
  border: 1px solid var(--ink);
  display: flex;
  flex-direction: column;
}
.flow li:not(:last-child)::after {
  content: "→";
  position: absolute;
  top: 50%;
  right: calc(clamp(36px, 5vw, 80px) * -1);
  width: clamp(36px, 5vw, 80px);
  color: var(--ink);
  text-align: center;
  transform: translateY(-50%);
  font: 300 1.8rem/1 monospace;
}
.flow li h3 {
  margin: auto 0 0.55rem;
  font-size: 1.4rem;
  letter-spacing: -0.035em;
}
.flow li p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}
.node-index {
  font: 700 0.75rem/1 monospace;
}
.flow .node-dark {
  color: var(--white);
  background: var(--ink);
}
.flow .node-dark p {
  color: #c7c9c1;
}
.integration {
  display: grid;
  grid-template-columns: 220px minmax(0, 900px);
  gap: clamp(3rem, 8vw, 8rem);
  justify-content: center;
  padding: clamp(5rem, 10vw, 9rem) clamp(1rem, 6vw, 7rem);
  background: var(--white);
  border-block: 1px solid var(--line);
}
.guide,
.step-body {
  min-width: 0;
}
.toc {
  align-self: start;
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  border-left: 1px solid var(--line);
  padding-left: 1rem;
}
.toc p {
  margin: 0 0 0.3rem;
  font: 700 0.68rem/1 monospace;
  letter-spacing: 0.12em;
  color: var(--muted);
}
.toc a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.83rem;
}
.toc a:hover {
  color: var(--ink);
}
.section-intro.wide {
  max-width: 850px;
  margin-bottom: 4rem;
}
.step {
  scroll-margin-top: 100px;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 1.5rem;
  padding: 3rem 0;
  border-top: 1px solid var(--line);
}
.step-number {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  background: var(--acid);
  border-radius: 50%;
  font: 700 0.72rem/1 monospace;
}
.step-body h3 {
  margin: 0.35rem 0 1rem;
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  letter-spacing: -0.045em;
}
.step-body > p {
  line-height: 1.65;
  color: #4e514b;
}
.checklist {
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 0;
}
.checklist li {
  position: relative;
  padding: 0.85rem 0 0.85rem 2rem;
  border-top: 1px solid var(--line);
  line-height: 1.45;
}
.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0.35rem;
  color: #168b42;
  font-weight: 800;
}
.code-block {
  max-width: 100%;
  margin: 1.5rem 0;
  border: 1px solid #353832;
  background: #1a1c18;
  color: #e9eadf;
  overflow: hidden;
}
.code-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid #3b3e37;
  color: #b9bbb2;
  font: 600 0.68rem/1 monospace;
  text-transform: uppercase;
}
.code-title button {
  min-height: 32px;
  padding: 0 0.5rem;
  border: 0;
  background: transparent;
  color: var(--acid);
  cursor: pointer;
  font: inherit;
  text-transform: uppercase;
}
pre {
  margin: 0;
  padding: 1.1rem;
  overflow-x: auto;
  font-size: 0.75rem;
  line-height: 1.75;
}
.inline-note {
  padding: 1rem;
  border-left: 3px solid var(--orange);
  background: #f5f1e9;
}
.inline-note code {
  color: #252820;
  background: #f5f1e9;
}
.inline-note.strong {
  border-color: var(--ink);
  background: var(--acid);
  color: var(--ink);
  font-weight: 650;
}
.text-link {
  font-weight: 720;
  font-size: 0.9rem;
  text-underline-offset: 4px;
}
.url-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  margin: 1.5rem 0;
  border: 1px solid var(--line);
  background: var(--line);
}
.url-grid div {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 1.2rem;
  background: var(--white);
  min-width: 0;
}
.url-grid span {
  font: 700 0.65rem/1 monospace;
  color: var(--muted);
}
.url-grid strong {
  font-size: 0.95rem;
}
.url-grid code {
  overflow-wrap: anywhere;
  font-size: 0.72rem;
  color: var(--muted);
}
.verify-list {
  list-style: none;
  counter-reset: none;
  margin: 1.5rem 0;
  padding: 0;
}
.verify-list li {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 1rem;
  padding: 0.9rem 0;
  border-top: 1px solid var(--line);
  line-height: 1.45;
}
.verify-list span {
  font-weight: 750;
}

.contract {
  background: var(--paper);
}
.function-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 4rem;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.function-grid article {
  min-height: 140px;
  padding: 1.3rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.function-grid code {
  font-size: 0.78rem;
  font-weight: 700;
  background: var(--acid);
  padding: 0.2rem 0.35rem;
}
.function-grid p {
  margin: 2.2rem 0 0;
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.87rem;
}
.machine-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 3rem;
}
.machine-links a {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.25rem 0.8rem;
  padding: 1.2rem;
  border: 1px solid var(--ink);
  text-decoration: none;
}
.machine-links a:hover {
  background: var(--acid);
}
.machine-links span {
  grid-row: span 2;
  font: 800 0.7rem/1 monospace;
  border: 1px solid;
  padding: 0.35rem;
  align-self: start;
}
.machine-links strong {
  font-size: 0.95rem;
}
.machine-links small {
  color: var(--muted);
  line-height: 1.4;
}

.security {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.8fr);
  gap: clamp(3rem, 10vw, 10rem);
  padding: clamp(5rem, 10vw, 9rem) clamp(1rem, 6vw, 7rem);
  color: var(--white);
  background: var(--ink);
}
.security .eyebrow {
  color: #9da197;
}
.security h2 {
  margin: 0;
  font-size: clamp(3rem, 6vw, 6rem);
  line-height: 0.92;
  letter-spacing: -0.065em;
}
.security-copy > p:not(.eyebrow) {
  max-width: 630px;
  color: #bfc2b9;
  line-height: 1.65;
}
.button.inverse {
  margin-top: 1.2rem;
  border-color: var(--white);
  color: var(--white);
}
.security-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.security-list li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 1rem;
  padding: 1.1rem 0;
  border-top: 1px solid #3d4138;
  line-height: 1.5;
}
.security-list span {
  color: var(--acid);
  font: 700 0.7rem/1.5 monospace;
}

footer {
  min-height: 120px;
  padding: 2rem clamp(1rem, 6vw, 7rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  border-top: 1px solid var(--line);
}
footer p {
  color: var(--muted);
  font-size: 0.82rem;
}
footer > div:last-child {
  display: flex;
  gap: 1.2rem;
  font-size: 0.78rem;
  font-weight: 650;
}

@media (max-width: 900px) {
  .topbar nav > a:not(.dashboard-link) {
    display: none;
  }
  .mobile-jump {
    position: sticky;
    top: 70px;
    z-index: 9;
    display: block;
    border-bottom: 1px solid var(--line);
    background: var(--white);
  }
  .mobile-jump summary {
    padding: 0.8rem 1rem;
    cursor: pointer;
    font:
      700 0.75rem/1 "IBM Plex Mono",
      monospace;
  }
  .mobile-jump nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid var(--line);
  }
  .mobile-jump a {
    padding: 0.8rem 1rem;
    border-bottom: 1px solid var(--line);
    text-decoration: none;
    font-size: 0.82rem;
  }
  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
  }
  .status-panel {
    max-width: 520px;
  }
  .release-gate {
    grid-template-columns: auto 1fr;
  }
  .release-gate > a {
    grid-column: 2;
  }
  .flow {
    grid-template-columns: minmax(0, 1fr);
  }
  .flow li:not(:last-child)::after {
    content: "↓";
    top: auto;
    right: 0;
    bottom: calc(clamp(36px, 5vw, 80px) * -1);
    width: 100%;
    height: clamp(36px, 5vw, 80px);
    display: grid;
    place-items: center;
    transform: none;
  }
  .integration {
    grid-template-columns: minmax(0, 1fr);
  }
  .toc {
    display: none;
  }
  .function-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .machine-links {
    grid-template-columns: 1fr;
  }
  .security {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 580px) {
  .topbar {
    height: 62px;
  }
  .mobile-jump {
    top: 62px;
  }
  .dashboard-link {
    padding: 0.55rem 0.65rem;
  }
  .hero {
    padding-top: 4.5rem;
  }
  h1 {
    font-size: clamp(3.2rem, 17vw, 5.2rem);
  }
  .release-gate {
    grid-template-columns: 1fr;
  }
  .release-gate > a {
    grid-column: 1;
  }
  .gate-mark {
    width: 38px;
    height: 38px;
  }
  .step {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.7rem;
  }
  .code-title button {
    min-height: 44px;
  }
  .url-grid,
  .function-grid {
    grid-template-columns: 1fr;
  }
  .verify-list li {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }
  footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

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