/* Mobile browser zoom is disabled at the page level. Vertical and horizontal
   page scrolling remain available; pinch zoom is implemented only on a photo
   inside an open fullscreen viewer by photo-pinch-zoom-v1.js. */
@media (pointer: coarse), (max-width: 760px) {
  html {
    touch-action: pan-x pan-y !important;
  }

  .photo-lightbox[data-photo-lightbox].open,
  .photo-lightbox[data-photo-lightbox].open .photo-lightbox-dialog,
  .photo-lightbox[data-photo-lightbox].open .photo-lightbox-media,
  [data-catalog-lightbox].open,
  [data-catalog-lightbox].open .catalog-lightbox-dialog-v117,
  [data-catalog-lightbox].open .catalog-lightbox-media-v153,
  [data-admin-photo-viewer].open,
  [data-admin-photo-viewer].open [data-admin-photo-stage],
  #ios646-viewer.open.ios696-photo,
  #ios646-viewer.open.ios696-photo .ios646-media {
    touch-action: none !important;
    overscroll-behavior: contain !important;
  }

  .photo-lightbox[data-photo-lightbox].open [data-lightbox-image],
  [data-catalog-lightbox].open [data-catalog-lightbox-image],
  [data-admin-photo-viewer].open [data-admin-photo-image],
  #ios646-viewer.open.ios696-photo .ios646-media img {
    touch-action: none !important;
    -webkit-user-select: none !important;
    user-select: none !important;
    -webkit-user-drag: none !important;
  }
}
.photo-pinch-zoomed-v1 {
  transform: translate3d(var(--kz-photo-zoom-x, 0px), var(--kz-photo-zoom-y, 0px), 0) scale(var(--kz-photo-zoom-scale, 1)) !important;
  transform-origin: center center !important;
  transition: none !important;
  will-change: transform;
}
/* The frame and viewer are stationary; only the IMG is enlarged and moved. */
#ios646-viewer.open.ios696-photo .photo-status-image-frame-v780.photo-pinch-frame-active-v2 {
  overflow: visible !important;
  z-index: 2 !important;
}
/* Hide only the 'Новенькая/Новенький' stamp while the fullscreen photo is enlarged.
   The stamp is a sibling of the IMG inside the frame; removing the zoom class
   when scale returns to 1 restores the stamp automatically. */
#ios646-viewer.open.ios696-photo .photo-status-image-frame-v780.photo-pinch-frame-active-v2 > .new-profile-stamp-v713 {
  visibility: hidden !important;
  opacity: 0 !important;
}
#ios646-viewer.open.ios696-photo .photo-status-image-frame-v780 > img.photo-pinch-zoomed-v1 {
  transform: translate3d(var(--kz-photo-zoom-x, 0px), var(--kz-photo-zoom-y, 0px), 0) scale(var(--kz-photo-zoom-scale, 1)) !important;
  transform-origin: center center !important;
  transition: none !important;
  will-change: transform;
  position: relative !important;
  z-index: 3 !important;
}
