/* Overrides for the Helium theme: what the theme API cannot express. */

@media (min-width: 1020px) {
  #top-bar > .row:first-child {
    display: none;
  }
}

#top-bar {
  padding: 0 32px 0 22px;
}

#top-bar > a.icon-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.01em;
}

#top-bar > a.icon-link::after {
  content: "Dixtra";
}

#top-bar .row.links a.text-link {
  font-size: 14px;
  font-weight: 700;
  margin-left: 24px;
}

@media (min-width: 1020px) {
  #sidebar {
    box-shadow: none;
    border-right: 1px solid var(--component-border);
  }
}

#sidebar ul.nav-list {
  padding: 16px 12px 24px 12px;
  margin: 0;
}

#sidebar .nav-list li {
  margin-left: 0;
  margin-bottom: 3px;
  line-height: 1.35;
}

#sidebar .nav-list li.nav-header,
#sidebar .nav-list li.level1.nav-header,
#sidebar .nav-list li.nav-header.level2 {
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--secondary-color);
  margin: 18px 0 6px 0;
  padding: 4px 10px;
}

#sidebar .nav-list li.level1.nav-header {
  margin-top: 4px;
}

#sidebar .nav-list .level2,
#sidebar .nav-list .level3 {
  margin-left: 0;
  font-size: 14px;
}

#sidebar .nav-list li a {
  padding: 5px 10px;
  border-radius: 5px;
  font-weight: 400;
}

#sidebar .nav-list .active a,
#sidebar .nav-list .active a:hover {
  font-weight: 700;
  background-color: var(--primary-color);
  color: var(--bg-color);
}

@media (min-width: 1250px) {
  #page-nav {
    display: inline-block;
    right: 20px;
    width: 265px;
    max-height: calc(100dvh - var(--top-bar-height) - 100px);
    padding-bottom: 4px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    border: 1px solid var(--component-border);
    border-radius: 6px;
  }

  #page-nav + main.content {
    max-width: 1180px;
    padding: 15px 300px 45px 45px;
  }
}

#page-nav .nav-list li {
  margin-bottom: 6px;
  line-height: 1.35;
}

#page-nav p.header {
  position: sticky;
  top: 0;
  z-index: 1;
  margin: 0;
  box-shadow: 0 2px 5px rgba(15, 23, 42, 0.12);
}

#page-nav p.footer:empty {
  display: none;
}

#page-nav::-webkit-scrollbar {
  width: 8px;
}

#page-nav::-webkit-scrollbar-thumb {
  background-color: var(--primary-medium);
  border-radius: 4px;
}

#page-nav::-webkit-scrollbar-track {
  background: transparent;
}

#page-nav .nav-list li a,
#page-nav .nav-list li code {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

#page-nav .nav-list .level1 code {
  font-weight: 700;
}

#page-nav .nav-list .level2 {
  margin-left: 12px;
  font-size: 12.5px;
}

h1,
h2,
h3,
h4 {
  color: var(--primary-color);
  line-height: 1.3;
}

h1.title {
  color: var(--primary-color);
  padding-top: calc(28px + var(--top-bar-height));
  padding-bottom: 12px;
  margin-bottom: 24px;
}

h2.section {
  margin-top: 44px;
  margin-bottom: 14px;
  padding-top: 18px;
  border-top: 1px solid var(--component-border);
}

h1.title ~ h2.section:first-of-type {
  border-top: none;
  padding-top: 0;
  margin-top: 28px;
}

h3.section {
  margin-top: 26px;
  margin-bottom: 10px;
}

h2 code,
h3 code,
h4 code {
  font-size: inherit;
  background: transparent;
  border: none;
  padding: 0;
}

h2 code {
  color: var(--primary-color);
  font-weight: 700;
}

h3 code {
  color: var(--secondary-color);
  font-weight: 700;
}

p code,
li code,
td code {
  background-color: var(--primary-light);
  border: 1px solid var(--component-border);
  border-radius: 4px;
  padding: 1px 5px;
  font-size: 0.875em;
  color: var(--primary-color);
}

pre {
  padding: 14px 18px;
  margin: 8px 0 20px 0;
  border-radius: 6px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  line-height: 1.55;
  overflow-x: auto;
}

pre code {
  font-size: var(--code-font-size);
}

table {
  width: 100%;
  border-radius: 6px;
  overflow: hidden;
}

th {
  background-color: var(--primary-light);
  color: var(--primary-color);
  text-align: left;
  padding: 8px 12px;
}

td {
  padding: 8px 12px;
  border-top: 1px solid var(--component-border);
}

#header {
  padding: 56px 32px 48px;
}

#header-left h1 {
  color: #f8fafc;
  font-size: 52px;
  letter-spacing: -0.02em;
}

#header-left h2 {
  color: #cbd5e1;
  font-weight: 400;
  line-height: 1.35;
}

#header-left div.row.links {
  gap: 14px;
  height: 44px;
}

#header-left .button-link {
  font-size: 16px;
  font-weight: 700;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
}

#header-left .button-link:nth-child(2) {
  background-color: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(203, 213, 225, 0.4);
}

#header-left .button-link:nth-child(2):hover {
  background-color: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

#header-right {
  color: #e2e8f0;
}

#header-right .large {
  color: #ffffff;
}

#docs {
  border-color: rgba(203, 213, 225, 0.35);
  border-radius: 6px;
  background-color: rgba(15, 23, 42, 0.35);
  min-width: 210px;
}

#docs p {
  border-bottom-color: rgba(203, 213, 225, 0.35);
  font-weight: 700;
  color: #f8fafc;
  padding: 8px 14px;
}

#header li {
  padding: 3px 14px;
}

#header #docs ul {
  padding: 4px 0 8px 0;
}

.teasers {
  margin-top: 48px;
  gap: 24px;
}

.teaser {
  background-color: var(--primary-light);
  border: 1px solid var(--component-border);
  border-radius: 8px;
  padding: 24px 28px;
}

.teaser h2 {
  color: var(--primary-color);
  font-size: 22px;
  margin-bottom: 10px;
}

.teaser p {
  font-size: 15.5px;
  line-height: 1.55;
}
