/* ==========================================================================
   Laskento — shared styles
   Loaded on every page. Page-specific selectors (e.g. #content, .dropdown)
   only match where those elements exist, so it is safe to share globally.
   ========================================================================== */

/* Thin themed scrollbar
   -------------------------------------------------------------------------- */
html {
  scrollbar-width: thin;
  scrollbar-color: rgb(45 47 57) transparent;
}
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
/* Transparent border + padding-box clip floats a slim ~4px pill in the
   gutter instead of a chunky full-width bar. */
::-webkit-scrollbar-thumb {
  background-color: rgb(45 47 57);
  border-radius: 9999px;
  border: 2px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover {
  background-color: rgb(96 100 108);
  background-clip: padding-box;
}

/* Documentation — scroll the content area, not the document, so the
   scrollbar sits below the navbar instead of spanning its full height.
   Reserve the gutter so opening a section doesn't change the layout width.
   -------------------------------------------------------------------------- */
#scroll-area {
  scrollbar-gutter: stable;
  scrollbar-width: thin;                       /* Firefox: this scroller, not just <html> */
  scrollbar-color: rgb(45 47 57) transparent;
}

/* Documentation — inline content links
   -------------------------------------------------------------------------- */
.docs-link {
  color: rgb(237 238 243);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: rgb(96 100 108);
}
.docs-link:hover { text-decoration-color: rgb(237 238 243); }

/* Documentation — code blocks wrap instead of scrolling horizontally
   -------------------------------------------------------------------------- */
#content pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
  overflow-x: hidden;
  border: 0;
}
#content pre code { white-space: inherit; word-break: inherit; }

/* Documentation — sidebar dropdown reveal
   -------------------------------------------------------------------------- */
.dropdown-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.25s ease;
}
.dropdown-body > div { overflow: hidden; }
.dropdown.open .dropdown-body { grid-template-rows: 1fr; }
.dropdown.open .chevron { transform: rotate(90deg); }
.dropdown.open .dropdown-head {
  color: rgb(237 238 243);
  background-color: rgb(24 25 31);
}
