/* Custom DocFX overrides for smaller headings and a slimmer side nav. */

/* Headings: reduce size to match a lighter style */
.article h1 {
  font-size: 24px;
  font-weight: 700;
  line-height: 1.3;
}

.article h2 {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.35;
}

.article h3 {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
}

.article h4 {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
}

/* Logo: align with main content column on desktop */
.navbar-brand {
  margin-left: 0;
}

/* ==========================================================================
   Side Navigation / TreeView
   ========================================================================== */

/* Base sidebar styling */
.sidetoc {
  background: #fafafa;
  border-left: 1px solid #e7e7e7;
  border-right: 1px solid #e8e8e8;
}

.sidefilter {
  background: #fafafa;
  border-right: 1px solid #e8e8e8;
  border-bottom: 1px solid #e8e8e8;
  padding: 10px 12px;
}

/* TOC container */
.sidetoc .toc {
  margin: 0;
  padding: 8px 0;
}

/* Base link styling */
.sidetoc .toc a,
.sidefilter .filter a {
  font-size: 13px;
  font-weight: 400;
  color: #374151;
  text-decoration: none;
  padding: 6px 12px;
  display: block;
  border-radius: 4px;
  margin: 1px 8px;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.sidetoc .toc a:hover {
  background: #e5e7eb;
  color: #111827;
  text-decoration: none;
}

.sidetoc .toc a.active {
  background: #dbeafe;
  color: #1d4ed8;
  font-weight: 500;
}

/* Override default bold labels in the TOC */
.sidetoc .toc strong,
.sidetoc .toc .toc-label {
  font-weight: 400;
}

/* List reset */
.sidetoc .toc ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

/* Base list item styling */
.sidetoc .toc li {
  position: relative;
}

/* Hide expand/collapse chevrons */
.sidetoc .toc .expand-stub {
  display: none;
}

/* ==========================================================================
   Flat Navigation (Link-Based Structure)
   ========================================================================== */

/* All TOC items */
.sidetoc .toc > ul > li > a {
  padding-left: 16px;
  font-weight: 500;
  color: #1f2937;
  font-size: 13px;
}

/* ==========================================================================
   Breadcrumbs
   ========================================================================== */

.breadcrumb {
  background: transparent;
  padding: 8px 0 16px 0;
  margin: 0;
  font-size: 12px;
}

.breadcrumb li {
  color: #6b7280;
}

.breadcrumb li a {
  color: #4b5563;
  text-decoration: none;
}

.breadcrumb li a:hover {
  color: #1d4ed8;
  text-decoration: underline;
}

.breadcrumb li + li::before {
  content: "/";
  padding: 0 6px;
  color: #9ca3af;
}


/* ==========================================================================
   Layout - Sidebar and Content Positioning
   ========================================================================== */

@media (min-width: 992px) {
  .sidetoc {
    width: 240px;
  }

  .sidefilter {
    width: 240px;
  }

  .body-content {
    margin-left: 260px;
  }

  /* Ensure article content doesn't overlap */
  .article {
    max-width: 900px;
  }
}

/* Navbar: turn nested toc items into dropdowns */
#navbar .nav.level1 > li {
  position: relative;
}

#navbar .expand-stub {
  display: none;
}

#navbar .expand-stub + a::after {
  content: " \25BE";
  font-size: 10px;
  margin-left: 4px;
}

#navbar .nav.level1 > li > ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 260px;
  margin: 0;
  padding: 6px 0;
  list-style: none;
  background: #222;
  border: 1px solid #1b1b1b;
  z-index: 1001;
}

#navbar .nav.level1 > li > ul > li > a {
  display: block;
  padding: 6px 16px;
  color: #f5f5f5;
  white-space: nowrap;
}

#navbar .nav.level1 > li > ul > li > a:hover,
#navbar .nav.level1 > li > ul > li > a:focus {
  background: #111;
  color: #fff;
}

#navbar .nav.level1 > li:hover > ul,
#navbar .nav.level1 > li:focus-within > ul {
  display: block;
}

@media (max-width: 767px) {
  #navbar .nav.level1 > li > ul {
    position: static;
    display: block;
    background: transparent;
    border: 0;
    padding: 0 0 0 12px;
  }

  #navbar .nav.level1 > li > ul > li > a {
    padding: 6px 10px;
    color: #9d9d9d;
  }
}
