/* Keep image-53 _2 sizing, margins and breakpoints from the original site. */
.cs-auto-gallery {
  position: relative;
  display: inline-block;
  vertical-align: middle;
  aspect-ratio: 3177 / 2555;
  line-height: 0;
  scroll-margin-top: 130px;
}
.cs-auto-gallery .cs-gallery-frame {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  max-width: none;
  height: 100%;
  object-fit: fill;
  pointer-events: none;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 91.6588% 100%, 91.6588% var(--cs-photo-top, 11.0763%), 0 var(--cs-photo-top, 11.0763%));
}
.cs-gallery-stage {
  position: absolute;
  /* Original artwork: photo starts at y=283, ends at x=2912. */
  top: var(--cs-photo-top, calc(283 / 2555 * 100%));
  right: calc(265 / 3177 * 100%);
  bottom: 0;
  left: 0;
  overflow: hidden;
  opacity: 0;
  touch-action: pan-y;
}
.cs-auto-gallery[data-ready] .cs-gallery-stage { opacity: 1; }
.cs-gallery-track {
  display: flex;
  width: 500%;
  height: 100%;
  transform: translateX(-20%);
  transition: transform 240ms cubic-bezier(0.77, 0, 0.175, 1);
}

.cs-gallery-track .cs-gallery-photo {
  display: block;
  flex: 0 0 20%;
  width: 20%;
  min-width: 0;
  max-width: none;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.cs-auto-gallery:focus-visible { outline: 3px solid #317b35; outline-offset: 4px; }
.cs-gallery-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
@media (prefers-reduced-motion: reduce) {
  .cs-auto-gallery .cs-gallery-track { transition: none; }
}


.cs-auto-gallery.image-53._2 { margin-bottom: calc(1vw + 60px); }
.cs-gallery-controls {
  position: absolute;
  top: calc(100% + 8px);
  left: -4px;
  display: flex;
  gap: 0;
  height: 44px;
  line-height: 1;
}
.cs-gallery-arrow {
  appearance: none;
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 4px;
  border: 0;
  background: transparent;
  color: white;
  cursor: pointer;
  touch-action: manipulation;
}
.cs-gallery-arrow::before {
  content: "";
  position: absolute;
  inset: 4px;
  background: #63bb5b;
  border-radius: 0;
}
.cs-gallery-arrow svg { position: relative; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cs-gallery-arrow:focus-visible { outline: 2px solid #317b35; outline-offset: 1px; border-radius: 0; }
@media (hover: hover) and (pointer: fine) {
  .cs-gallery-arrow:hover::before { background: #4c9c46; }
}
@media screen and (min-width: 768px) {
  .cs-gallery-controls {
    left: auto;
    right: calc(265 / 3177 * 100% - 4px);
  }
}
@media screen and (max-width: 991px) {
  .cs-auto-gallery.image-53._2 { margin-bottom: 44px; }
}

/* Keep the fountains central while filling the entire photo window. */
.cs-gallery-track .cs-water-photo-32 { object-position: 50% 65%; }
.cs-gallery-track .cs-water-photo-6 { object-position: 50% 78%; }

.cs-gallery-track .cs-landscaping-photo-13 { object-position: 60% 50%; }

.cs-gallery-track .cs-garden-photo-21 { object-position: 35% 50%; }
