@import url("https://fonts.googleapis.com/css2?family=Oswald:wght@600;700&family=Roboto+Mono:wght@400;500;600;700&display=swap");

:root {
  color-scheme: dark;
  --ink: #030404;
  --panel: #070809;
  --panel-2: #0a0b0b;
  --paper: #f0ede6;
  --text: #dbd9d3;
  --muted: #969691;
  --dim: #6f7376;
  --line: #343638;
  --line-bright: #5e6162;
  --acid: #6496ed;
  --violet: #9b66ff;
  --red: #ff4c40;
  --display: "Oswald", "Arial Narrow", sans-serif;
  --mono: "Roboto Mono", "SFMono-Regular", monospace;
  --control-height: 46px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(90deg, rgba(100, 150, 237, 0.05) 1px, transparent 1px),
    linear-gradient(0deg, rgba(100, 150, 237, 0.04) 1px, transparent 1px),
    var(--ink);
  background-size: 42px 42px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 15px;
  line-height: 1.55;
  letter-spacing: 0;
}

button,
input {
  font: inherit;
  letter-spacing: 0;
}

code,
pre {
  font-family: var(--mono);
}

button {
  appearance: none;
}

.shell {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 22px;
  border-right: 1px solid var(--line);
  background: rgba(5, 6, 6, 0.98);
  overflow-y: auto;
}

.brand {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding-bottom: 20px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.brand-mark {
  width: 64px;
  height: 64px;
  border: 1px solid var(--line-bright);
  background: #000;
  object-fit: cover;
}

.brand-kicker {
  color: var(--acid);
  font-size: 12px;
  font-weight: 700;
  margin: 0 0 4px;
  text-transform: uppercase;
}

.brand h1 {
  margin: 0;
  color: var(--paper);
  font: 700 34px/1.05 var(--display);
  text-transform: uppercase;
}

.brand p,
.section-heading p,
.intro p,
.flow p,
.muted {
  margin: 6px 0 0;
  color: var(--muted);
}

.brand > div > p:last-child {
  font-size: 11px;
  line-height: 1.45;
}

.field-label {
  display: block;
  margin: 16px 0 7px;
  color: var(--dim);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
}

.input {
  width: 100%;
  min-height: var(--control-height);
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #050607;
  color: var(--paper);
  outline: none;
}

.input:focus {
  border-color: var(--acid);
  box-shadow: inset 3px 0 0 var(--acid);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.button-row.compact {
  margin-top: 0;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 13px;
  border: 1px solid var(--line-bright);
  border-radius: 0;
  background: #080a0c;
  color: var(--text);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.button:hover,
.button:focus-visible {
  border-color: var(--acid);
  color: var(--acid);
  outline: none;
}

.button.primary {
  border-color: var(--acid);
  background: var(--acid);
  color: #06101e;
}

.button.primary:hover,
.button.primary:focus-visible {
  border-color: var(--violet);
  background: var(--violet);
  color: #07080a;
}

.nav {
  display: grid;
  gap: 0;
  margin-top: 22px;
  border: 1px solid var(--line);
  border-bottom: 0;
}

.nav a {
  min-height: 42px;
  padding: 12px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.nav a:hover,
.nav a:focus-visible {
  background: #0c1018;
  color: var(--acid);
  outline: none;
}

.content {
  min-width: 0;
  width: min(1480px, 100%);
  padding: 28px;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.85fr);
  gap: 0;
  align-items: stretch;
  margin-bottom: 18px;
  border: 1px solid var(--line);
  background: #060708;
}

.intro-copy {
  display: grid;
  align-content: end;
  min-height: 250px;
  padding: 30px;
  border-right: 1px solid var(--line);
}

.eyebrow {
  color: var(--acid);
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 12px;
  text-transform: uppercase;
}

.intro h2 {
  max-width: 820px;
  margin: 0;
  color: var(--paper);
  font: 700 78px/1 var(--display);
  text-transform: uppercase;
}

.intro h2 span {
  color: var(--acid);
}

.intro-copy > p:last-child {
  max-width: 720px;
  margin-top: 18px;
  font-size: 15px;
}

.topology {
  position: relative;
  min-height: 250px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(94, 97, 98, 0.22) 1px, transparent 1px),
    linear-gradient(0deg, rgba(94, 97, 98, 0.18) 1px, transparent 1px),
    #030404;
  background-size: 28px 28px;
}

.topology::before {
  content: "SPAM";
  position: absolute;
  right: 18px;
  bottom: 4px;
  color: rgba(100, 150, 237, 0.12);
  font: 700 96px/0.8 var(--display);
  text-transform: uppercase;
}

.node {
  position: absolute;
  display: grid;
  place-items: center;
  width: 96px;
  height: 44px;
  border: 1px solid var(--line-bright);
  background: #080a0c;
  color: var(--paper);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  z-index: 2;
}

.node.client {
  left: 28px;
  top: 42px;
}

.node.api {
  left: calc(50% - 48px);
  top: calc(50% - 22px);
  border-color: var(--acid);
  background: var(--acid);
  color: #06101e;
}

.node.core {
  right: 28px;
  top: 42px;
}

.node.ord {
  right: 28px;
  bottom: 42px;
  border-color: var(--violet);
  color: #d6c6ff;
}

.link {
  position: absolute;
  height: 2px;
  background: var(--line-bright);
  transform-origin: left center;
}

.link.one {
  left: 118px;
  top: 64px;
  width: calc(50% - 118px);
  transform: rotate(18deg);
}

.link.two {
  left: calc(50% + 46px);
  top: 129px;
  width: calc(50% - 150px);
  transform: rotate(-25deg);
}

.link.three {
  left: calc(50% + 46px);
  top: 133px;
  width: calc(50% - 150px);
  transform: rotate(25deg);
}

.link.four {
  right: 76px;
  top: 90px;
  height: 90px;
  width: 2px;
}

.panel {
  margin-bottom: 18px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--panel);
}

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  min-height: 72px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
  background: var(--panel-2);
}

.section-heading h2,
.flow h3,
.text-grid h3 {
  margin: 0;
  color: var(--paper);
}

.section-heading h2 {
  font: 700 32px/1.12 var(--display);
  text-transform: uppercase;
}

.search {
  max-width: 360px;
}

.tabs,
.language-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tabs {
  padding: 14px 16px 0;
}

.tab,
.language-tab {
  min-height: 36px;
  padding: 0 11px;
  border: 1px solid var(--line-bright);
  border-radius: 0;
  background: #050607;
  color: var(--muted);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.tab:hover,
.language-tab:hover,
.tab:focus-visible,
.language-tab:focus-visible {
  border-color: var(--acid);
  color: var(--acid);
  outline: none;
}

.tab.active,
.language-tab.active {
  border-color: var(--acid);
  background: var(--acid);
  color: #06101e;
}

.endpoint-list {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.endpoint {
  border: 1px solid var(--line);
  background: #050607;
  overflow: hidden;
}

.endpoint.active {
  border-color: var(--acid);
  box-shadow: inset 3px 0 0 var(--acid);
}

.endpoint-header {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) 90px;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 12px;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.endpoint-header:hover,
.endpoint-header:focus-visible {
  background: #0a0d12;
  outline: none;
}

.method {
  display: inline-grid;
  place-items: center;
  min-height: 30px;
  border: 1px solid transparent;
  color: #030405;
  font-size: 12px;
  font-weight: 800;
}

.method.get {
  background: var(--acid);
}

.method.post {
  background: var(--red);
}

.path {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
}

.auth {
  color: var(--dim);
  font-size: 12px;
  text-align: right;
  text-transform: uppercase;
}

.endpoint-detail {
  padding: 14px 12px;
  border-top: 1px solid var(--line);
  background: #07090b;
}

.endpoint-detail p,
.text-grid p,
.flow p,
.panel > p {
  font-size: 14px;
}

.code-block,
.output {
  overflow: auto;
  margin: 14px 0;
  padding: 14px;
  border: 1px solid #2b3036;
  border-radius: 0;
  background: #020303;
  color: #dfe8f4;
  font-size: 13px;
  line-height: 1.6;
  white-space: pre;
}

.output {
  min-height: 150px;
  white-space: pre-wrap;
}

.text-grid,
.flow-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
}

.text-grid > div,
.flow {
  min-width: 0;
  padding: 18px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #060708;
}

.text-grid > div:nth-child(2n),
.flow:nth-child(2n) {
  border-right: 0;
}

.text-grid h3,
.flow h3 {
  font: 700 24px/1.15 var(--display);
  text-transform: uppercase;
}

.text-grid ol {
  margin: 12px 0 0;
  padding-left: 22px;
  color: var(--text);
}

.text-grid li + li {
  margin-top: 8px;
}

.empty {
  margin: 0;
  color: var(--muted);
}

#status-output {
  margin: 0 16px 16px;
}

#operations .code-block {
  margin: 16px;
}

#operations > p {
  margin: 0;
  padding: 0 16px 16px;
  color: var(--muted);
}

@media (max-width: 980px) {
  .shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .content {
    padding: 18px;
  }

  .intro,
  .text-grid,
  .flow-grid {
    grid-template-columns: 1fr;
  }

  .intro-copy {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .text-grid > div,
  .flow {
    border-right: 0;
  }

  .intro h2 {
    font-size: 64px;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 14px;
  }

  .content,
  .sidebar {
    padding: 12px;
  }

  .brand {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .brand-mark {
    width: 54px;
    height: 54px;
  }

  .brand h1 {
    font-size: 28px;
  }

  .intro-copy {
    min-height: 220px;
    padding: 18px;
  }

  .intro h2 {
    font-size: 48px;
  }

  .section-heading {
    display: grid;
  }

  .search {
    max-width: none;
  }

  .endpoint-header {
    grid-template-columns: 64px minmax(0, 1fr);
  }

  .auth {
    grid-column: 2;
    text-align: left;
  }

  .nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .topology {
    min-height: 220px;
  }

  .node.client {
    left: 16px;
  }

  .node.core,
  .node.ord {
    right: 16px;
  }
}
