/* Scroll polish only — no layout rules live here. */

html,
body,
#smooth-wrapper {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar,
#smooth-wrapper::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

#smooth-wrapper {
  scroll-behavior: auto;
  overscroll-behavior-y: none;
}

#smooth-wrapper.modal-open {
  overflow: hidden;
}

/* Images fade in once decoded, so slow thumbnails never flash grey. */
img[loading='lazy'] {
  background-color: color-mix(in srgb, currentColor 6%, transparent);
}

.featured-media img,
.archive-media img,
.preview-image-wrap img {
  opacity: 1;
  transition: opacity 0.5s ease, transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), filter 0.4s ease;
}

img[data-loading='true'] {
  opacity: 0;
}

/* Native find-in-page and keyboard scrolling still work because the real
   scroll container is #smooth-wrapper. */
