/* The colors and fonts of the site in RapiDoc: the variables of the daisyUI theme, which switch with it. */

/* RapiDoc derives its surfaces from `--background` and `--foreground`; its accent comes from its `theme` attribute (`init.js`) */
rapi-doc {
  --background: var(--color-base-100);
  --foreground: var(--color-base-content);
  --font-sans: var(--default-font-family);
  --font-mono: var(--default-mono-font-family);
  --radius: var(--radius-box);
}

/* RapiDoc docks its menu beside the content from 768px wide, and floats it over the content below:
   docked, the menu stays in view below the sticky header of the site while the page scrolls (`auto-height`) */
#api-reference {
  container-type: inline-size;
}
@container (min-width: 768px) {
  rapi-doc::part(section-navbar) {
    position: sticky;
    top: 4rem;
    align-self: flex-start;
    max-height: calc(100vh - 4rem);
    overflow-y: auto;
  }
}
