/* Keep document scrolling native; draw its control over the page. */
html.overlay-scrollbar-enabled {
  scrollbar-width: none;
}
html.overlay-scrollbar-enabled::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}
.page-scrollbar {
  position: fixed;
  top: 6px;
  right: 2px;
  bottom: 6px;
  width: 16px;
  z-index: 30;
  border-radius: 999px;
  background: transparent;
  touch-action: none;
  user-select: none;
  cursor: pointer;
  transition: background .18s ease;
}
.page-scrollbar[hidden] { display: none; }
.page-scrollbar-thumb {
  position: absolute;
  top: 0;
  right: 3px;
  width: 5px;
  min-height: 40px;
  border-radius: 999px;
  background: rgba(159, 227, 214, .55);
  box-shadow: 0 0 0 1px rgba(6, 42, 58, .28);
  transition: width .18s ease, background .18s ease, box-shadow .18s ease;
}
.page-scrollbar:hover,
.page-scrollbar:focus-visible,
.page-scrollbar.is-dragging {
  background: rgba(8, 22, 62, .5);
}
.page-scrollbar:hover .page-scrollbar-thumb,
.page-scrollbar:focus-visible .page-scrollbar-thumb,
.page-scrollbar.is-dragging .page-scrollbar-thumb {
  width: 10px;
  background: #9fe3d6;
  box-shadow: 0 0 0 1px rgba(6, 42, 58, .45), 0 0 12px rgba(126, 212, 196, .3);
}
.page-scrollbar:focus { outline: none; }
@media (prefers-reduced-motion: reduce) {
  .page-scrollbar, .page-scrollbar-thumb { transition: none; }
}
@media (forced-colors: active) {
  .page-scrollbar-thumb { background: ButtonText; }
  .page-scrollbar:hover .page-scrollbar-thumb,
  .page-scrollbar:focus-visible .page-scrollbar-thumb,
  .page-scrollbar.is-dragging .page-scrollbar-thumb { background: Highlight; }
}
