* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
}

body {
  margin: 0;
  background: #191a1c;
  color: #dedede;
  font: 14px/1.65 Arial, Helvetica, sans-serif;
}

a {
  color: #28758a;
  text-decoration: none;
}

a:hover {
  color: #ef7184;
}

code,
pre {
  font-family: Consolas, Monaco, "Courier New", monospace;
}

code {
  color: #f0a1ad;
  font-size: .94em;
}

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

.sidebar {
  height: 100vh;
  position: sticky;
  top: 0;
  overflow-y: auto;
  background: #151618;
  border-right: 1px solid #343538;
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
}

.sidebar-top {
  padding-bottom: 18px;
  border-bottom: 1px solid #343538;
  margin-bottom: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #f1f1f1;
  font-size: 19px;
  font-weight: 700;
  margin-bottom: 9px;
}

.brand-mark {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border: 2px solid #c94a5e;
  border-radius: 50%;
  color: #ef7184;
}

.docs-label,
.eyebrow {
  color: #92959a;
  font-size: 10px;
  letter-spacing: 1.2px;
  font-weight: 700;
}

.nav-section {
  margin-bottom: 20px;
}

.nav-heading {
  display: block;
  margin-bottom: 7px;
  color: #e0e0e1;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .4px;
}

.nav-child {
  display: block;
  padding: 4px 0 4px 13px;
  color: #aeb5ba;
  font-size: 12px;
  border-left: 1px solid transparent;
}

.nav-child.selected {
  color: #ef7184;
  border-left-color: #c94a5e;
}

.sidebar-footer {
  margin-top: auto;
  padding-top: 13px;
  border-top: 1px solid #343538;
  color: #a0a2a5;
  font-size: 10px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.red-dot {
  width: 7px;
  height: 7px;
  background: #c94a5e;
  border-radius: 50%;
}

.version {
  margin-left: auto;
  color: #888;
}

.article {
  width: 100%;
  max-width: 1040px;
  padding: 30px clamp(22px, 5vw, 62px) 70px;
}

.article-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  color: #85888c;
  font-size: 11px;
  margin-bottom: 42px;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 9px;
}

.breadcrumbs a {
  color: #c1c4c7;
}

.theme-toggle,
.mobile-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 11px;
  border: 1px solid #45474a;
  border-radius: 5px;
  background: #242629;
  color: #eee;
  font: 12px Arial, sans-serif;
  cursor: pointer;
}

.theme-toggle:hover,
.mobile-toggle:hover {
  background: #f0f0f0;
  color: #191a1c;
}

h1,
h2,
h3 {
  color: #eeeeef;
  line-height: 1.35;
}

h1 {
  font-size: clamp(27px, 4vw, 38px);
  letter-spacing: -.8px;
  margin: 10px 0 14px;
}

h2 {
  font-size: 21px;
  margin: 42px 0 17px;
  padding-bottom: 9px;
  border-bottom: 1px solid #383a3d;
}

h3 {
  font-size: 16px;
  margin: 25px 0 9px;
}

p {
  max-width: 850px;
  margin: 9px 0 15px;
  color: #c8c9cb;
  font-size: 13px;
  line-height: 1.85;
}

.lead {
  font-size: 15px;
  max-width: 780px;
  color: #c3c6ca;
}

ul,
ol {
  max-width: 850px;
  padding-left: 23px;
  color: #c8c9cb;
}

li {
  font-size: 13px;
  line-height: 1.8;
  padding: 2px 0;
}

pre {
  max-width: 850px;
  overflow: auto;
  background: #111316;
  border: 1px solid #383a3d;
  border-left: 2px solid #c94a5e;
  border-radius: 5px;
  padding: 16px 18px;
  margin: 14px 0 20px;
  color: #e2e4e6;
  font: 12px/1.8 Consolas, Monaco, monospace;
  tab-size: 2;
}

.highlight {
  color: #ff2b6a;
}

pre code {
  color: inherit;
  font-size: inherit;
}

.callout,
.note,
.warning,
.explain {
  max-width: 850px;
  padding: 13px 16px;
  margin: 17px 0;
  border: 1px solid #393b3f;
  border-radius: 5px;
  background: #202225;
  color: #c9cbce;
  font-size: 12px;
  line-height: 1.8;
}

.callout {
  border-left: 3px solid #c94a5e;
}

.warning {
  border-left: 3px solid #d29a4a;
}

.note {
  border-left: 3px solid #668b9a;
}

.explain ul {
  margin-bottom: 0;
}

.diagram {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 850px;
  margin: 22px 0;
  padding: 18px 14px;
  border: 1px solid #383a3d;
  border-radius: 6px;
  background: #1d1f21;
}

.diagram-box {
  flex: 1;
  min-width: 0;
  min-height: 72px;
  padding: 10px 7px;
  border: 1px solid #555a5e;
  border-radius: 4px;
  background: #222426;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.diagram-box strong {
  font-size: 12px;
  color: #e1e2e3;
}

.diagram-box small {
  font-size: 10px;
  color: #96999d;
  margin-top: 4px;
}

.diagram-box.broker {
  border-color: #a83b4d;
  background: #241c1f;
}

.diagram-box.broker strong {
  color: #f07889;
}

.diagram-connection {
  flex: .65;
  min-width: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
}

.diagram-connection span {
  font-size: 9px;
  color: #96999d;
  white-space: nowrap;
}

.diagram-connection i {
  height: 1px;
  width: 100%;
  background: #777b80;
  position: relative;
}

.diagram-connection i::after {
  content: "";
  position: absolute;
  right: 0;
  top: -3px;
  width: 6px;
  height: 6px;
  border-top: 1px solid #aeb1b5;
  border-right: 1px solid #aeb1b5;
  transform: rotate(45deg);
}

.steps {
  counter-reset: item;
}

.steps li {
  margin: 8px 0;
}

.step-block {
  max-width: 900px;
  margin: 30px 0 38px;
  padding: 0 0 10px;
  border-bottom: 1px solid #34363a;
}

.step-heading {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.step-number {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid #a83b4d;
  border-radius: 5px;
  color: #f07889;
  font-size: 12px;
  font-weight: 700;
}

.step-heading h3 {
  margin: 0 0 2px;
  font-size: 18px;
}

.step-location {
  margin: 0;
  color: #92969b;
  font-size: 11px;
}

.article-end {
  max-width: 850px;
  border-top: 1px solid #383a3d;
  margin-top: 45px;
  padding-top: 15px;
  display: flex;
  justify-content: space-between;
  color: #898c90;
  font-size: 11px;
}

.article-end a {
  color: #e07888;
}

.mobile-toggle {
  display: none;
}

:root[data-theme="light"] body {
  background: #fff;
  color: #292929;
}

:root[data-theme="light"] .sidebar {
  background: #fafafa;
  border-color: #ddd;
}

:root[data-theme="light"] .sidebar-top,
:root[data-theme="light"] .sidebar-footer {
  border-color: #e1e1e1;
}

:root[data-theme="light"] .brand,
:root[data-theme="light"] .nav-heading,
:root[data-theme="light"] h1,
:root[data-theme="light"] h2,
:root[data-theme="light"] h3 {
  color: #222;
}

:root[data-theme="light"] .nav-child {
  color: #28758a;
}

:root[data-theme="light"] .nav-child.selected {
  color: #a92f43;
}

:root[data-theme="light"] p,
:root[data-theme="light"] li {
  color: #333;
}

:root[data-theme="light"] pre {
  background: #f5f5f5;
  border-color: #d8d8d8;
  color: #333;
}

:root[data-theme="light"] .diagram,
:root[data-theme="light"] .callout,
:root[data-theme="light"] .note,
:root[data-theme="light"] .warning,
:root[data-theme="light"] .explain {
  background: #fafafa;
  border-color: #ddd;
  color: #333;
}

:root[data-theme="light"] .diagram-box {
  background: #fff;
  border-color: #8baab2;
}

:root[data-theme="light"] .diagram-box strong {
  color: #2c5862;
}

:root[data-theme="light"] .diagram-box small {
  color: #777;
}

:root[data-theme="light"] .diagram-box.broker {
  background: #fffafa;
  border-color: #c94a5e;
}

:root[data-theme="light"] .diagram-box.broker strong {
  color: #a92f43;
}

:root[data-theme="light"] .diagram-connection span {
  color: #777;
}

:root[data-theme="light"] .article-end {
  border-color: #ddd;
}

:root[data-theme="light"] .theme-toggle {
  background: #242629;
  color: #f2f2f2;
}

@media (max-width: 850px) {
  .docs-layout {
    grid-template-columns: 245px minmax(0, 1fr);
  }

  .sidebar {
    padding-left: 14px;
    padding-right: 12px;
  }

  .article {
    padding: 25px 23px 60px;
  }
}

@media (max-width: 650px) {
  .docs-layout {
    display: block;
  }

  .sidebar {
    position: fixed;
    z-index: 10;
    left: 0;
    top: 0;
    width: 280px;
    transform: translateX(-101%);
    transition: transform .2s ease;
    box-shadow: 4px 0 18px #0005;
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .article {
    padding: 24px 18px 80px;
  }

  .mobile-toggle {
    display: inline-flex;
    position: fixed;
    right: 14px;
    bottom: 14px;
    z-index: 12;
    box-shadow: 0 2px 8px #0005;
  }

  .diagram {
    gap: 5px;
    padding: 10px 5px;
  }

  .diagram-connection {
    min-width: 20px;
    flex: .4;
  }

  .diagram-connection span {
    font-size: 8px;
  }

  .diagram-box {
    padding: 7px 3px;
  }

  .diagram-box strong {
    font-size: 10px;
  }

  .diagram-box small {
    font-size: 8px;
  }

  .article-meta {
    margin-bottom: 30px;
  }
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
