/* The chapter guide and home actions share one right edge. Inner pages and
   home viewports without a visible guide keep their normal button position. */
@media (min-width:1100px) {
  body.ms-modern.ms-home.ms-chapter-visible :is(.ms-book-dock,.ms-assistant) {
    left:auto;
    right:calc(var(--ms-chapter-rail-width,76px) + 12px);
  }
}

/* Leave overflow native: arrows, touch, wheel, and keyboard all use the same track. */
body.ms-modern :is([data-collection-track],[data-carousel-track],[data-about-track],
  [data-room-photo-track],[data-review-track],[data-reels-track],[data-ms-overflow-rail],
  .ms-studio-tabs) { scrollbar-width:none!important; }
body.ms-modern :is([data-collection-track],[data-carousel-track],[data-about-track],
  [data-room-photo-track],[data-review-track],[data-reels-track],[data-ms-overflow-rail],
  .ms-studio-tabs)::-webkit-scrollbar { display:none!important;width:0!important;height:0!important; }

/* Position announcements remain available to screen readers, outside the flex layout. */
body.ms-modern :is([data-collection-counter],[data-carousel-count],[data-hero-counter],
  [data-photo-counter],[data-lightbox-position]) {
  position:absolute!important;width:1px!important;height:1px!important;min-width:0!important;
  min-height:0!important;padding:0!important;border:0!important;margin:-1px!important;
  overflow:hidden!important;clip:rect(0,0,0,0)!important;clip-path:inset(50%)!important;white-space:nowrap!important;
}
body.ms-modern {
  --ms-gallery-hit:clamp(54px,4.5vw,66px);
  --ms-chevron-width:clamp(34px,3vw,44px);
  --ms-chevron-height:clamp(46px,4vw,58px);
  --ms-gallery-arrow-gap:clamp(20px,2.4vw,36px);
}
body.ms-modern button.ms-gallery-arrow:not([hidden]){
  display:inline-grid!important;place-items:center;flex:0 0 auto;box-sizing:border-box;
  width:var(--ms-gallery-hit)!important;height:var(--ms-gallery-hit)!important;
  padding:0!important;line-height:1;cursor:pointer;
}
body.ms-modern button.ms-gallery-arrow > svg.ms-gallery-chevron {
  display:block;position:static;width:var(--ms-chevron-width)!important;height:var(--ms-chevron-height)!important;
  max-width:none;max-height:none;fill:none;stroke:currentColor;stroke-width:2;
}
body.ms-modern button.ms-gallery-arrow:disabled{opacity:.4;cursor:default}
body.ms-modern :is(.ms-collection-controls,.ms-gallery-controls,.ms-carousel-controls,.ms-about-collection-controls,
  .ms-hero-controls,.ms-reels-rail-controls,.ms-google-reviews-controls,.ms-overflow-arrows){
  column-gap:var(--ms-gallery-arrow-gap)!important;
}
body.ms-modern .ms-site :is(.ms-carousel-controls,.ms-about-collection-controls,.ms-google-reviews-controls,
  .ms-reels-rail-controls,.ms-collection-controls) button.ms-gallery-arrow,
body.ms-modern .ms-overflow-arrows button.ms-gallery-arrow {
  background:transparent!important;border:0!important;border-radius:0!important;box-shadow:none!important;color:inherit;
}
body.ms-modern .ms-overflow-arrows{display:flex;align-items:center;justify-content:center;margin-block:8px;}
body.ms-modern .ms-overflow-arrows[hidden]{display:none!important}
body.ms-modern :is(.ms-owner-photo-label){justify-content:flex-end}
body.ms-modern .ms-lightbox :is(.ms-lightbox-prev,.ms-lightbox-next) svg {
  width:clamp(38px,4vw,50px)!important;height:clamp(58px,6vw,74px)!important;
}
body.ms-modern .ms-lightbox :is(.ms-lightbox-prev,.ms-lightbox-next):not([hidden]){
  width:clamp(54px,5vw,72px)!important;height:clamp(64px,7vw,88px)!important;padding:0!important;
}
/* Navigation strips need less height than photo collections. */
body.ms-modern .ms-overflow-arrows.ms-compact-arrows {
  --ms-gallery-hit:44px;--ms-chevron-width:28px;--ms-chevron-height:36px;
  margin-block:0;
}

body.ms-modern button.ms-gallery-arrow[hidden],
body.ms-modern .ms-gallery-controls[hidden]{display:none!important}
