@font-face {
  font-family: Inter;
  src: url('/learn/fonts/inter-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Inter;
  src: url('/learn/fonts/inter-latin-500-normal.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Inter;
  src: url('/learn/fonts/inter-latin-600-normal.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Playfair Display';
  src: url('/learn/fonts/playfair-display-latin-500-normal.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Playfair Display';
  src: url('/learn/fonts/playfair-display-latin-600-normal.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/learn/fonts/ibm-plex-mono-latin-500-normal.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: dark;
  /* One name for the display face. These pages are generated separately from
     the app and cannot read src/styles/tokens.css, so this is the /learn-side
     mirror of --font-display — keep the two in step (a guard test pins it). */
  --font-display: 'Playfair Display', Georgia, serif;
  --bg: #0b0712;
  --bg-deep: #07040c;
  --surface: #130c1d;
  --surface-2: #1a1127;
  --surface-3: #211632;
  --line: rgba(206, 187, 242, 0.15);
  --line-strong: rgba(206, 187, 242, 0.28);
  --ink: #f3eef9;
  --ink-soft: #d8d0e4;
  --muted: #b8aec7;
  --quiet: #978da7;
  --violet: #aa8aff;
  --violet-soft: #c8b6ff;
  --violet-wash: rgba(157, 119, 255, 0.12);
  --gold: #d4ad68;
  --gold-hi: #edce93;
  --gold-ink: #1a1005;
  --ok: #86d3a0;
  --danger: #f19a9a;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --wide: 1180px;
  --reading: 750px;
}

* {
  box-sizing: border-box;
}

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

body {
  min-width: 320px;
  margin: 0;
  background:
    radial-gradient(circle at 78% 6%, rgba(116, 77, 187, 0.12), transparent 31rem),
    radial-gradient(circle at 8% 34%, rgba(85, 49, 137, 0.08), transparent 26rem),
    var(--bg);
  color: var(--ink-soft);
  font: 400 16px/1.65 Inter, system-ui, sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

::selection {
  background: rgba(170, 138, 255, 0.32);
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--violet-soft);
  outline-offset: 4px;
}

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

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 600;
  transform: translateY(-150%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.kb-wide {
  width: min(calc(100% - 40px), var(--wide));
  margin-inline: auto;
}

.eyebrow {
  display: block;
  color: var(--violet-soft);
  font: 500 12px/1.4 'IBM Plex Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.kb-topbar {
  position: sticky;
  z-index: 40;
  top: 0;
  border-bottom: 1px solid rgba(206, 187, 242, 0.11);
  background: rgba(11, 7, 18, 0.84);
  backdrop-filter: blur(18px) saturate(125%);
}

.topbar-inner {
  display: grid;
  grid-template-columns: auto minmax(220px, 340px) auto;
  align-items: center;
  gap: 30px;
  min-height: 74px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
}

.wordmark > span:last-child {
  display: grid;
  gap: 1px;
}

.wordmark strong {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.1;
}

.wordmark small {
  color: var(--quiet);
  font: 500 12px/1.25 'IBM Plex Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.wordmark-logo {
  display: block;
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: 50%;
  filter: drop-shadow(0 5px 14px rgba(255, 215, 0, 0.13));
}

.kb-global-search {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
}

.kb-global-search:focus-within {
  border-color: rgba(170, 138, 255, 0.66);
  box-shadow: 0 0 0 3px rgba(170, 138, 255, 0.09);
}

.kb-global-search input {
  min-width: 0;
  flex: 1;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  padding: 0 8px 0 38px;
  font-size: 14px;
}

.kb-global-search input::placeholder,
.kb-search input::placeholder {
  color: var(--quiet);
}

.kb-global-search button {
  min-width: 68px;
  height: 34px;
  margin-right: 4px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: var(--surface-3);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 600;
}

.search-glyph {
  position: absolute;
  left: 15px;
  width: 13px;
  height: 13px;
  border: 1.5px solid var(--muted);
  border-radius: 50%;
  pointer-events: none;
}

.search-glyph::after {
  position: absolute;
  right: -4px;
  bottom: -3px;
  width: 6px;
  height: 1.5px;
  content: '';
  background: var(--muted);
  transform: rotate(45deg);
  transform-origin: left center;
}

.topbar-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 20px;
  white-space: nowrap;
}

.topbar-nav a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
}

.topbar-nav a:hover {
  color: var(--ink);
}

.topbar-nav .topbar-studio {
  padding: 9px 16px;
  border: 1px solid rgba(212, 173, 104, 0.42);
  border-radius: 999px;
  color: var(--gold-hi);
}

.topbar-nav .topbar-studio:hover {
  border-color: var(--gold);
  background: rgba(212, 173, 104, 0.08);
  color: var(--gold-hi);
}

.kb-hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.kb-hero::after {
  position: absolute;
  inset: auto -10% -180px;
  height: 260px;
  content: '';
  background: radial-gradient(ellipse, rgba(123, 82, 202, 0.1), transparent 66%);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(360px, 0.82fr);
  gap: clamp(48px, 8vw, 110px);
  align-items: center;
  padding-block: clamp(76px, 9vw, 124px) clamp(72px, 8vw, 110px);
}

.hero-copy h1,
.article-header h1 {
  max-width: 820px;
  margin: 14px 0 20px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(45px, 6vw, 76px);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 0.99;
}

.hero-lede {
  max-width: 680px;
  margin: 0;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: clamp(20px, 2.2vw, 27px);
  line-height: 1.42;
}

.hero-note {
  max-width: 640px;
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.kb-search {
  max-width: 700px;
  margin-top: 34px;
}

.kb-search > label {
  display: block;
  margin-bottom: 9px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
}

.search-field {
  position: relative;
  display: flex;
  min-height: 60px;
  align-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 17px;
  background: rgba(27, 18, 40, 0.92);
  box-shadow: var(--shadow);
}

.search-field:focus-within {
  border-color: rgba(170, 138, 255, 0.72);
  box-shadow: 0 0 0 4px rgba(170, 138, 255, 0.1), var(--shadow);
}

.search-field .search-glyph {
  left: 21px;
  width: 17px;
  height: 17px;
}

.search-field input {
  min-width: 0;
  flex: 1;
  align-self: stretch;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  padding: 0 12px 0 54px;
  font-size: 16px;
}

.search-submit,
.search-clear {
  min-height: 42px;
  border: 0;
  border-radius: 11px;
  font-weight: 600;
}

.search-submit {
  margin-right: 8px;
  padding: 0 18px;
  background: var(--violet);
  color: #130921;
}

.search-clear {
  padding: 0 12px;
  background: transparent;
  color: var(--muted);
}

.search-status {
  display: flex;
  gap: 5px;
  margin: 8px 2px 0;
  color: var(--quiet);
  font-size: 13px;
}

.search-status [data-result-count] {
  color: var(--violet-soft);
}

.popular-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  align-items: baseline;
  margin-top: 22px;
  font-size: 14px;
  line-height: 1.5;
}

.popular-links > span {
  color: var(--quiet);
  font: 500 12px/1.4 'IBM Plex Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.popular-links a {
  color: var(--muted);
  text-decoration-color: rgba(170, 138, 255, 0.34);
  text-underline-offset: 4px;
}

.popular-links a:hover {
  color: var(--ink);
}

.hero-signal {
  position: relative;
  min-width: 0;
  padding: 25px 25px 20px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(145deg, rgba(38, 24, 57, 0.96), rgba(16, 10, 25, 0.95)),
    var(--surface);
  box-shadow: 0 38px 100px rgba(0, 0, 0, 0.38);
  transform: rotate(1.2deg);
}

.hero-signal::before {
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(255, 255, 255, 0.035);
  border-radius: 18px;
  content: '';
  pointer-events: none;
}

.signal-caption {
  position: relative;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: var(--quiet);
  font: 500 12px/1.4 'IBM Plex Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.signal-caption b {
  color: var(--violet-soft);
  font-weight: 500;
}

.signal-scope {
  position: relative;
  display: flex;
  height: 112px;
  align-items: center;
  justify-content: space-between;
  gap: 5px;
  margin: 20px 0 18px;
  padding: 0 2px;
}

.signal-scope::before {
  position: absolute;
  right: 0;
  left: 0;
  height: 1px;
  content: '';
  background: rgba(206, 187, 242, 0.16);
}

.signal-scope i {
  position: relative;
  width: 3px;
  height: 32%;
  border-radius: 99px;
  background: linear-gradient(to top, rgba(170, 138, 255, 0.22), var(--violet-soft), rgba(212, 173, 104, 0.74));
  box-shadow: 0 0 10px rgba(170, 138, 255, 0.18);
  transform-origin: center;
  animation: signal-rise 700ms cubic-bezier(0.22, 0.8, 0.2, 1) both;
}

.signal-scope i:nth-child(2n) { height: 66%; animation-delay: 35ms; }
.signal-scope i:nth-child(3n) { height: 92%; animation-delay: 70ms; }
.signal-scope i:nth-child(4n) { height: 45%; animation-delay: 105ms; }
.signal-scope i:nth-child(5n) { height: 76%; animation-delay: 140ms; }
.signal-scope i:nth-child(7n) { height: 56%; animation-delay: 175ms; }

@keyframes signal-rise {
  from { opacity: 0; transform: scaleY(0.08); }
  to { opacity: 1; transform: scaleY(1); }
}

.hero-signal ol {
  position: relative;
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hero-signal li {
  display: grid;
  grid-template-columns: 32px 1fr auto;
  gap: 10px;
  align-items: baseline;
  padding: 10px 0;
  border-top: 1px solid rgba(206, 187, 242, 0.1);
}

.hero-signal li > span {
  color: var(--gold);
  font: 500 12px/1 'IBM Plex Mono', monospace;
}

.hero-signal li strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
}

.hero-signal li small {
  color: var(--quiet);
  font-size: 12px;
}

.journey,
.browse {
  padding-block: clamp(72px, 8vw, 110px);
}

.block-heading {
  max-width: 720px;
}

.block-heading h2,
.quick-fix h2,
.related-guides h2,
.studio-cta h2,
.search-empty h2 {
  margin: 8px 0 8px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(31px, 4vw, 47px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.block-heading p,
.quick-fix p,
.browse-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

.journey-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 38px;
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.journey-grid::before {
  position: absolute;
  z-index: 1;
  top: -4px;
  right: 0;
  left: 0;
  height: 7px;
  content: '';
  background: linear-gradient(90deg, var(--violet), rgba(170, 138, 255, 0.15) 42%, var(--gold));
  opacity: 0.36;
  clip-path: polygon(0 43%, 8% 43%, 10% 0, 12% 100%, 14% 43%, 41% 43%, 43% 18%, 45% 68%, 47% 43%, 72% 43%, 74% 3%, 77% 93%, 80% 43%, 100% 43%, 100% 57%, 80% 57%, 77% 100%, 74% 10%, 72% 57%, 47% 57%, 45% 82%, 43% 31%, 41% 57%, 14% 57%, 12% 100%, 10% 14%, 8% 57%, 0 57%);
}

.journey-grid > a {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 280px;
  flex-direction: column;
  padding: 30px 26px 26px;
  border-right: 1px solid var(--line);
  text-decoration: none;
  transition: background 180ms ease, transform 180ms ease;
}

.journey-grid > a:last-child {
  border-right: 0;
}

.journey-grid > a:hover {
  z-index: 2;
  background: var(--violet-wash);
  transform: translateY(-3px);
}

.journey-number {
  color: var(--gold);
  font: 500 12px/1 'IBM Plex Mono', monospace;
  letter-spacing: 0.12em;
}

.journey-grid strong {
  max-width: 190px;
  margin-top: 42px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  line-height: 1.1;
}

.journey-grid p {
  margin: 12px 0 26px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.journey-grid b {
  margin-top: auto;
  color: var(--violet-soft);
  font-size: 14px;
  font-weight: 500;
}

.quick-fix {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.28fr);
  gap: clamp(38px, 7vw, 94px);
  padding: clamp(34px, 5vw, 58px);
  border: 1px solid rgba(212, 173, 104, 0.24);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 12% 20%, rgba(212, 173, 104, 0.08), transparent 22rem),
    linear-gradient(135deg, rgba(31, 21, 39, 0.94), rgba(16, 10, 24, 0.95));
  box-shadow: var(--shadow);
}

.quick-fix-intro .eyebrow {
  color: var(--gold-hi);
}

.quick-fix h2 {
  font-size: clamp(34px, 4vw, 50px);
}

.quick-fix-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  align-self: start;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.quick-fix-links a {
  display: grid;
  grid-template-columns: 22px 1fr auto;
  gap: 9px;
  align-items: center;
  min-height: 66px;
  padding: 12px 14px;
  background: rgba(16, 10, 24, 0.96);
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.45;
  text-decoration: none;
}

.quick-fix-links a:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.quick-fix-links a > span {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border: 1px solid rgba(241, 154, 154, 0.36);
  border-radius: 50%;
  color: var(--danger);
  font: 500 12px/1 'IBM Plex Mono', monospace;
}

.quick-fix-links a b {
  color: var(--quiet);
  font-weight: 400;
}

.browse-heading {
  display: flex;
  max-width: none;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
}

.browse-studio {
  flex: none;
  padding: 11px 17px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
}

.browse-studio:hover {
  border-color: rgba(212, 173, 104, 0.48);
  color: var(--gold-hi);
}

.category-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 30px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--line);
}

.category-nav a {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  gap: 8px;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
}

.category-nav a:hover {
  border-color: rgba(170, 138, 255, 0.46);
  background: var(--violet-wash);
  color: var(--ink);
}

.category-nav a > span {
  color: var(--violet-soft);
  font: 500 13px/1 'IBM Plex Mono', monospace;
}

.category-nav small {
  display: inline-grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.045);
  color: var(--quiet);
  font: 500 12px/1 'IBM Plex Mono', monospace;
}

.guide-section {
  display: grid;
  grid-template-columns: 285px minmax(0, 1fr);
  gap: clamp(36px, 6vw, 76px);
  padding-block: 58px;
  border-bottom: 1px solid var(--line);
}

.guide-section:last-child {
  border-bottom: 0;
}

.guide-section-head {
  position: sticky;
  top: 112px;
  display: grid;
  grid-template-columns: 38px 1fr;
  gap: 14px;
  align-self: start;
}

.section-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(170, 138, 255, 0.38);
  border-radius: 50%;
  color: var(--violet-soft);
  font: 500 15px/1 'IBM Plex Mono', monospace;
}

.guide-section-head h2 {
  margin: 6px 0 7px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 27px;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.1;
}

.guide-section-head p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

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

.topic-card {
  position: relative;
  display: grid;
  min-width: 0;
  grid-template-columns: 30px minmax(0, 1fr) 20px;
  gap: 12px;
  align-items: start;
  min-height: 178px;
  padding: 21px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(19, 12, 29, 0.7);
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.topic-card:hover {
  border-color: rgba(170, 138, 255, 0.43);
  background: var(--surface-2);
  transform: translateY(-2px);
}

.topic-card-mark {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid rgba(170, 138, 255, 0.26);
  border-radius: 50%;
  color: var(--violet-soft);
  font: 500 12px/1 'IBM Plex Mono', monospace;
}

.topic-card-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.topic-card-kicker {
  margin-top: 5px;
  color: var(--quiet);
  font: 500 12px/1.4 'IBM Plex Mono', monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.topic-card-copy strong {
  margin-top: 10px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.016em;
  line-height: 1.22;
}

.topic-card-copy > span:last-child {
  display: -webkit-box;
  margin-top: 9px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.topic-card-arrow {
  color: var(--quiet);
  font-size: 15px;
  transition: color 160ms ease, transform 160ms ease;
}

.topic-card:hover .topic-card-arrow {
  color: var(--violet-soft);
  transform: translate(2px, -2px);
}

.search-empty {
  margin-top: 42px;
  padding: 60px 24px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  text-align: center;
}

.search-empty > span {
  color: var(--violet-soft);
  font: 500 34px/1 'IBM Plex Mono', monospace;
}

.search-empty h2 {
  margin-top: 18px;
  font-size: 31px;
}

.search-empty p {
  max-width: 540px;
  margin: 0 auto;
  color: var(--muted);
}

.search-empty button {
  min-height: 42px;
  margin-top: 22px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--ink);
}

.is-searching [data-search-hide] {
  display: none !important;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding-top: 34px;
  color: var(--quiet);
  font-size: 13px;
}

.breadcrumbs a {
  color: var(--muted);
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: var(--ink);
}

.article-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: clamp(48px, 8vw, 105px);
  padding-block: 48px 100px;
}

.article-rail {
  position: sticky;
  top: 104px;
  align-self: start;
}

.rail-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
}

.rail-back:hover {
  color: var(--ink);
}

.rail-heading {
  display: grid;
  grid-template-columns: 38px 1fr;
  gap: 12px;
  align-items: center;
  margin: 25px 0 17px;
  padding-bottom: 17px;
  border-bottom: 1px solid var(--line);
}

.rail-heading > span {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(170, 138, 255, 0.36);
  border-radius: 50%;
  color: var(--violet-soft);
  font: 500 13px/1 'IBM Plex Mono', monospace;
}

.rail-heading div {
  display: grid;
  gap: 2px;
}

.rail-heading small {
  color: var(--quiet);
  font: 500 12px/1.35 'IBM Plex Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.rail-heading strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
}

.article-rail nav {
  display: grid;
  gap: 3px;
}

.article-rail nav a {
  display: grid;
  grid-template-columns: 14px 1fr;
  gap: 8px;
  min-height: 40px;
  padding: 9px;
  border-radius: 8px;
  color: var(--quiet);
  font-size: 13px;
  line-height: 1.4;
  text-decoration: none;
}

.article-rail nav a > span {
  color: rgba(170, 138, 255, 0.42);
  font-size: 8px;
  transform: translateY(4px);
}

.article-rail nav a:hover {
  background: rgba(255, 255, 255, 0.035);
  color: var(--ink-soft);
}

.article-rail nav a[aria-current='page'] {
  background: var(--violet-wash);
  color: var(--violet-soft);
}

.article-rail nav a[aria-current='page'] > span {
  color: var(--gold);
}

.article-rail .kb-global-search {
  margin-top: 22px;
}

.article-rail .kb-global-search button {
  display: none;
}

.article-column {
  min-width: 0;
  max-width: 820px;
}

.article-header {
  padding-bottom: 35px;
  border-bottom: 1px solid var(--line);
}

.article-header h1 {
  margin-top: 13px;
  font-size: clamp(44px, 6vw, 68px);
  line-height: 1.03;
}

.article-lede {
  max-width: 750px;
  margin: 0;
  color: var(--violet-soft);
  font-family: var(--font-display);
  font-size: clamp(20px, 2.4vw, 26px);
  line-height: 1.45;
}

.article-body {
  max-width: var(--reading);
  padding-block: 35px 14px;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: 19px;
  line-height: 1.82;
}

.article-body p {
  margin: 0 0 24px;
}

.article-body p:first-child::first-letter {
  float: left;
  margin: 10px 9px 0 0;
  color: var(--gold-hi);
  font-family: var(--font-display);
  font-size: 54px;
  font-weight: 600;
  line-height: 0.66;
}

.article-body b {
  color: var(--ink);
  font-weight: 600;
}

.article-body kbd {
  padding: 2px 6px;
  border: 1px solid var(--line-strong);
  border-bottom-width: 2px;
  border-radius: 5px;
  background: var(--surface-2);
  color: var(--violet-soft);
  font: 500 0.78em/1.2 'IBM Plex Mono', monospace;
}

.studio-cta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 42px;
  align-items: end;
  margin-top: 38px;
  padding: 30px;
  border: 1px solid rgba(212, 173, 104, 0.26);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 92% 20%, rgba(212, 173, 104, 0.1), transparent 16rem),
    var(--surface-2);
}

.studio-cta .eyebrow {
  color: var(--gold-hi);
}

.studio-cta h2 {
  margin-top: 7px;
  font-size: 31px;
}

.studio-cta p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.studio-cta > div:last-child {
  display: grid;
  gap: 9px;
  justify-items: center;
}

.studio-cta a {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  gap: 8px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--gold-ink);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.studio-cta a:hover {
  background: var(--gold-hi);
}

.studio-cta small {
  max-width: 190px;
  color: var(--quiet);
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
}

.related-guides {
  margin-top: 70px;
}

.related-guides h2 {
  font-size: 34px;
}

.related-guides > div {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.topic-card.is-related {
  min-height: 165px;
}

.article-pager {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: 70px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.article-pager a {
  display: grid;
  gap: 7px;
  min-height: 108px;
  align-content: center;
  padding: 18px 20px;
  text-decoration: none;
}

.article-pager a + a {
  border-left: 1px solid var(--line);
}

.article-pager a:hover {
  background: rgba(170, 138, 255, 0.07);
}

.article-pager small {
  color: var(--quiet);
  font: 500 12px/1.4 'IBM Plex Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.article-pager strong {
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
}

.article-pager .is-next {
  justify-items: end;
  text-align: right;
}

.kb-footer {
  border-top: 1px solid var(--line);
  background: rgba(7, 4, 12, 0.58);
}

.footer-inner {
  display: flex;
  min-height: 116px;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
}

.footer-brand > img {
  display: block;
  width: 34px;
  height: 34px;
  flex: none;
  border-radius: 50%;
}

.footer-brand > span {
  display: grid;
  gap: 3px;
}

.footer-inner strong {
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 15px;
}

.footer-inner span {
  color: var(--quiet);
  font-size: 12px;
}

.footer-inner nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-inner nav a {
  color: var(--quiet);
  font-size: 13px;
  text-decoration: none;
}

.footer-inner nav a:hover {
  color: var(--ink);
}

@media (max-width: 1050px) {
  .topbar-inner {
    grid-template-columns: auto minmax(200px, 1fr) auto;
    gap: 18px;
  }

  .topbar-nav > a:not(.topbar-studio) {
    display: none;
  }

  .hero-grid {
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 46px;
  }

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

  .journey-grid > a:nth-child(2) {
    border-right: 0;
  }

  .journey-grid > a:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .quick-fix {
    grid-template-columns: 1fr;
  }

  .guide-section {
    grid-template-columns: 230px minmax(0, 1fr);
    gap: 36px;
  }
}

@media (max-width: 800px) {
  html {
    scroll-padding-top: 90px;
  }

  .kb-wide {
    width: min(calc(100% - 28px), var(--wide));
  }

  .topbar-inner {
    display: flex;
    min-height: 68px;
  }

  .topbar-inner > .kb-global-search {
    display: none;
  }

  .topbar-nav {
    margin-left: auto;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    padding-top: 62px;
  }

  .hero-copy h1 {
    max-width: 680px;
  }

  .hero-signal {
    width: min(100%, 520px);
    transform: none;
  }

  .browse-heading {
    display: block;
  }

  .browse-studio {
    display: inline-flex;
    margin-top: 18px;
  }

  .guide-section {
    grid-template-columns: 1fr;
    gap: 24px;
    padding-block: 42px;
  }

  .guide-section-head {
    position: static;
    max-width: 580px;
  }

  .article-layout {
    grid-template-columns: 1fr;
    gap: 0;
    padding-top: 22px;
  }

  .article-rail {
    display: none;
  }
}

@media (max-width: 600px) {
  .wordmark strong {
    font-size: 15px;
  }

  .wordmark small {
    display: none;
  }

  .wordmark-logo {
    width: 36px;
    height: 36px;
  }

  .topbar-nav .topbar-studio {
    padding: 8px 12px;
    font-size: 13px;
  }

  .hero-grid {
    gap: 36px;
    padding-block: 52px 64px;
  }

  .hero-copy h1,
  .article-header h1 {
    font-size: clamp(39px, 12vw, 54px);
    line-height: 1.02;
  }

  .hero-lede,
  .article-lede {
    font-size: 19px;
  }

  .search-field {
    flex-wrap: wrap;
    padding: 7px;
  }

  .search-field input {
    min-height: 45px;
    padding-left: 47px;
  }

  .search-field .search-glyph {
    top: 21px;
    left: 21px;
  }

  .search-submit {
    min-width: 84px;
    margin: 0;
  }

  .search-clear {
    margin-left: auto;
  }

  .search-status > span:last-child {
    display: none;
  }

  .popular-links {
    align-items: center;
  }

  .popular-links > span {
    width: 100%;
  }

  .hero-signal {
    padding: 22px 18px 16px;
  }

  .signal-scope {
    height: 84px;
    gap: 3px;
  }

  .hero-signal li {
    grid-template-columns: 27px 1fr;
  }

  .hero-signal li small {
    display: none;
  }

  .journey,
  .browse {
    padding-block: 64px;
  }

  .journey-grid {
    grid-template-columns: 1fr;
  }

  .journey-grid > a {
    min-height: 225px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .journey-grid > a:last-child {
    border-bottom: 0;
  }

  .journey-grid strong {
    margin-top: 26px;
  }

  .quick-fix {
    gap: 28px;
    padding: 28px 20px;
  }

  .quick-fix-links {
    grid-template-columns: 1fr;
  }

  .category-nav {
    flex-wrap: nowrap;
    margin-right: -14px;
    margin-left: -14px;
    padding-right: 14px;
    padding-left: 14px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .category-nav::-webkit-scrollbar {
    display: none;
  }

  .category-nav a {
    flex: none;
  }

  .topic-grid,
  .related-guides > div {
    grid-template-columns: 1fr;
  }

  .topic-card {
    min-height: 154px;
    padding: 18px;
  }

  .breadcrumbs {
    padding-top: 24px;
  }

  .breadcrumbs span[aria-current='page'] {
    width: 100%;
    color: var(--muted);
  }

  .article-header {
    padding-bottom: 28px;
  }

  .article-body {
    padding-top: 29px;
    font-size: 17px;
    line-height: 1.78;
  }

  .article-body p:first-child::first-letter {
    font-size: 48px;
  }

  .studio-cta {
    grid-template-columns: 1fr;
    gap: 25px;
    padding: 24px 20px;
  }

  .studio-cta > div:last-child {
    justify-items: start;
  }

  .studio-cta small {
    max-width: none;
    text-align: left;
  }

  .article-pager {
    grid-template-columns: 1fr;
  }

  .article-pager a + a {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .article-pager .is-next {
    justify-items: start;
    text-align: left;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    padding-block: 28px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
