/* Keep the collection row stable while each native horizontal swipe settles. */
@media (max-width: 760px) {
  .nb-shop-page[data-shop-collection] .nb-shop-grid:not(.is-list) {
    height: auto;
    max-height: none;
    align-items: stretch;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    touch-action: pan-x pan-y pinch-zoom;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 12px;
    overflow-anchor: none;
    transition: none;
  }

  .nb-shop-page[data-shop-collection] .nb-shop-grid:not(.is-list) > .product-card {
    align-self: stretch;
    height: auto;
    grid-template-rows: auto 1fr auto;
  }

  /* Let the last product settle at the same inset as the first product. */
  .nb-shop-page[data-shop-collection] .nb-shop-grid:not(.is-list)::after {
    content: "";
    flex: 0 0 var(--nb-slider-end-space, 0px);
    pointer-events: none;
  }
}
