/* Brand accent — override mdBook theme accent colors. */
.light, html:not(.js) {
  --sidebar-active: #fb8c00;
  --sidebar-header-border-color: #fb8c00;
  --links: #fb8c00;
}
.coal, .navy, .ayu, .rust {
  --sidebar-active: #fb8c00;
  --sidebar-header-border-color: #fb8c00;
  --links: #fb8c00;
}
@media (prefers-color-scheme: dark) {
  html:not(.js) {
    --sidebar-active: #fb8c00;
    --sidebar-header-border-color: #fb8c00;
    --links: #fb8c00;
  }
}

/* External-link icon for sidebar links pointing outside the docs. */
#mdbook-sidebar ol.chapter a[href^="http"]::after {
  content: "";
  display: inline-block;
  width: 0.75em;
  height: 0.75em;
  margin-left: 0.25em;
  vertical-align: middle;
  background-color: currentColor;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3Cpolyline points='15 3 21 3 21 9'/%3E%3Cline x1='10' y1='14' x2='21' y2='3'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3Cpolyline points='15 3 21 3 21 9'/%3E%3Cline x1='10' y1='14' x2='21' y2='3'/%3E%3C/svg%3E");
  mask-size: contain;
  mask-repeat: no-repeat;
}

/* Logo icon in the header bar beside the book title. */
.menu-title::before {
  content: "";
  display: inline-block;
  width: 1.2em;
  height: 1.2em;
  margin-right: 0.4em;
  vertical-align: middle;
  background: url("images/logo-simple.svg") no-repeat center / contain;
  opacity: 0.4;
}
.coal .menu-title::before,
.navy .menu-title::before,
.ayu .menu-title::before,
.rust .menu-title::before {
  filter: invert(1);
}
@media (prefers-color-scheme: dark) {
  html:not(.js) .menu-title::before {
    filter: invert(1);
  }
}

/* Keep command names readable in Command Reference. */
h1#command-reference + .table-wrapper table th:first-child,
h1#command-reference + .table-wrapper table td:first-child,
h1#command-reference + table th:first-child,
h1#command-reference + table td:first-child {
  width: 35%;
  white-space: nowrap;
}
