/* Public Knowledge — fixed left tree, minimal content. */
.knowledge-body {
  --kb-sidebar-width: 220px;
  --kb-header-offset: 108px;
  background: #fafaf8;
  color: #171717;
}

.knowledge-body .site-learn-tabs-wrap {
  position: relative;
  z-index: 2;
  max-width: none;
  padding-left: calc(var(--kb-sidebar-width) + 24px);
  padding-right: 24px;
}

.kb-workspace {
  display: block;
  max-width: none;
  padding: 0;
}

.kb-sidebar {
  position: fixed;
  top: var(--kb-header-offset);
  left: 0;
  bottom: 0;
  z-index: 1;
  width: var(--kb-sidebar-width);
  overflow: auto;
  border-right: 1px solid #e6e6e1;
  background: #fafaf8;
  overscroll-behavior: contain;
}

.kb-sidebar__drawer {
  height: 100%;
}

.kb-sidebar__drawer > summary {
  display: none;
}

.kb-sidebar__inner {
  min-width: 0;
  padding: 12px 10px 40px;
}

.kb-sidebar__home {
  display: block;
  padding: 6px 8px;
  color: #111;
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
}

.kb-sidebar__home:hover,
.kb-sidebar__home.is-active {
  color: #000;
}

.kb-sidebar__search {
  margin: 8px 0 14px;
}

.kb-sidebar__search input {
  width: 100%;
  padding: 7px 8px;
  border: 0;
  border-bottom: 1px solid #d8d8d2;
  border-radius: 0;
  outline: 0;
  background: transparent;
  color: #171717;
  font: inherit;
  font-size: 13px;
}

.kb-sidebar__search input:focus {
  border-bottom-color: #888;
}

.kb-tree {
  display: grid;
  gap: 0;
  font-size: 13px;
}

.kb-tree__group {
  min-width: 0;
}

.kb-tree__group > summary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  cursor: pointer;
  color: #333;
  font-weight: 600;
  list-style: none;
}

.kb-tree__group > summary::-webkit-details-marker {
  display: none;
}

.kb-tree__group > summary::before {
  width: 5px;
  height: 5px;
  flex: 0 0 auto;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  content: '';
  opacity: .55;
  transform: rotate(-45deg);
  transition: transform .15s ease;
}

.kb-tree__group[open] > summary::before {
  transform: rotate(45deg) translate(-1px, -1px);
}

.kb-tree__group > summary:hover {
  color: #111;
}

.kb-tree__items {
  display: grid;
  gap: 0;
  margin: 0 0 2px 10px;
  padding-left: 7px;
  border-left: 1px solid #e4e4df;
}

.kb-tree__items .kb-tree__items {
  margin-left: 6px;
}

.kb-tree__link {
  display: block;
  overflow: hidden;
  padding: 4px 8px;
  color: #666;
  line-height: 1.35;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.kb-tree__link:hover {
  color: #111;
}

.kb-tree__link.is-active {
  color: #111;
  font-weight: 650;
  background: #ecece7;
}

.kb-tree__overview {
  color: #888;
}

.kb-content {
  min-width: 0;
  margin-left: var(--kb-sidebar-width);
  padding: 28px 40px 80px;
}

.kb-shell {
  max-width: 680px;
}

.kb-shell--article {
  max-width: 680px;
}

.kb-hero {
  margin-bottom: 28px;
}

.kb-eyebrow {
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #777;
}

.kb-hero h1,
.kb-section-head h1,
.kb-article h1 {
  margin: 0;
  letter-spacing: -.03em;
  color: #111;
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  line-height: 1.15;
}

.kb-hero > p:not(.kb-eyebrow) {
  max-width: 540px;
  margin: 10px 0 0;
  font-size: 16px;
  line-height: 1.5;
  color: #666;
}

.kb-search {
  display: flex;
  gap: 8px;
  width: 100%;
  max-width: 520px;
  margin-top: 20px;
}

.kb-search input {
  min-width: 0;
  flex: 1;
  padding: 10px 12px;
  border: 1px solid #d4d4cf;
  border-radius: 0;
  background: #fff;
  color: #171717;
  font: inherit;
}

.kb-search button {
  padding: 0 16px;
  border: 0;
  border-radius: 0;
  background: #111;
  color: #fff;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.kb-section-list {
  display: grid;
  gap: 0;
  margin-top: 28px;
  border-top: 1px solid #e6e6e1;
}

.kb-section-list a {
  display: grid;
  gap: 2px;
  padding: 14px 0;
  border-bottom: 1px solid #e6e6e1;
  color: inherit;
  text-decoration: none;
}

.kb-section-list a:hover .kb-section-list__title {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.kb-section-list__title {
  font-size: 16px;
  font-weight: 650;
  letter-spacing: -.01em;
}

.kb-section-list__desc {
  font-size: 14px;
  line-height: 1.45;
  color: #777;
}

.kb-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 22px;
  font-size: 12px;
  color: #888;
}

.kb-breadcrumbs a {
  color: inherit;
  text-decoration: none;
}

.kb-breadcrumbs a:hover {
  color: #111;
}

.kb-section-head {
  margin-bottom: 24px;
}

.kb-section-head p {
  max-width: 620px;
  margin-top: 10px;
  font-size: 16px;
  line-height: 1.5;
  color: #666;
}

.kb-article-list {
  display: grid;
  gap: 0;
  margin-top: 8px;
  border-top: 1px solid #e6e6e1;
}

.kb-article-list > a {
  display: grid;
  gap: 3px;
  padding: 14px 0;
  border-bottom: 1px solid #e6e6e1;
  color: inherit;
  text-decoration: none;
}

.kb-article-list > a:hover strong {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.kb-article-list strong {
  font-size: 16px;
  font-weight: 650;
}

.kb-article-list span {
  color: #777;
  font-size: 14px;
  line-height: 1.45;
}

.kb-article__head {
  margin-bottom: 28px;
}

.kb-article__summary {
  max-width: 640px;
  margin-top: 12px;
  font-size: 17px;
  line-height: 1.5;
  color: #555;
}

.kb-prose {
  font-size: 16px;
  line-height: 1.7;
}

.kb-prose h2 {
  margin: 36px 0 10px;
  font-size: 24px;
  letter-spacing: -.02em;
}

.kb-prose h3 {
  margin: 26px 0 8px;
  font-size: 18px;
}

.kb-prose p {
  margin: 0 0 16px;
}

.kb-prose ul,
.kb-prose ol {
  margin: 0 0 18px;
  padding-left: 22px;
}

.kb-prose a,
.kb-references a,
.kb-related a {
  color: #151515;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.kb-references,
.kb-related {
  margin-top: 40px;
  padding-top: 22px;
  border-top: 1px solid #e6e6e1;
}

.kb-references h2,
.kb-related h2 {
  margin: 0 0 12px;
  font-size: 18px;
}

.kb-references li {
  margin-bottom: 10px;
  line-height: 1.5;
}

.kb-references li span {
  color: #777;
  font-size: 13px;
}

.kb-related ul {
  padding-left: 18px;
}

.kb-empty {
  margin-top: 20px;
  color: #777;
}

.kb-search-count {
  margin: 20px 0 0;
  color: #777;
  font-size: 14px;
}

@media (max-width: 860px) {
  .knowledge-body {
    --kb-sidebar-width: 0px;
  }

  .knowledge-body .site-learn-tabs-wrap {
    padding-left: 24px;
  }

  .kb-sidebar {
    position: static;
    width: auto;
    overflow: visible;
    border-right: 0;
    margin: 0 16px 20px;
  }

  .kb-sidebar__drawer {
    height: auto;
    border-bottom: 1px solid #e6e6e1;
  }

  .kb-sidebar__drawer > summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    cursor: pointer;
    font-size: 13px;
    font-weight: 650;
    list-style: none;
  }

  .kb-sidebar__drawer > summary::-webkit-details-marker {
    display: none;
  }

  .kb-sidebar__drawer > summary::after {
    content: '+';
    color: #777;
    font-size: 16px;
    font-weight: 400;
  }

  .kb-sidebar__drawer[open] > summary::after {
    content: '−';
  }

  .kb-sidebar__inner {
    max-height: min(60vh, 520px);
    padding: 0 0 12px;
    overflow: auto;
    border-top: 1px solid #e6e6e1;
  }

  .kb-sidebar__home {
    margin-top: 8px;
  }

  .kb-content {
    margin-left: 0;
    padding: 8px 20px 64px;
  }
}

@media (min-width: 861px) {
  .kb-sidebar__drawer:not([open]) > .kb-sidebar__inner {
    display: block;
  }

  .kb-sidebar__drawer {
    display: block;
  }
}

@media (max-width: 700px) {
  .kb-search {
    flex-direction: column;
  }

  .kb-search button {
    min-height: 44px;
  }
}
