/**
 * CVP Properties 4.0: property gallery as a swipeable slideshow.
 * Scroll or drag sideways, use the arrows or arrow keys. Click a photo to open it larger (lightbox).
 */

.gs { position: relative; }

/* the track: a row of big photos you slide through */
.gallery-grid.gs-track {
  display: flex !important;
  grid-template-columns: none !important;
  gap: 20px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 8px 0 26px;
  scroll-padding-left: 0;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  cursor: grab;
  outline: none;
}
.gallery-grid.gs-track::-webkit-scrollbar { display: none; }
.gallery-grid.gs-track.is-dragging { cursor: grabbing; scroll-snap-type: none; scroll-behavior: auto; }
.gallery-grid.gs-track:focus-visible { box-shadow: inset 0 0 0 3px rgba(31, 138, 126, .35); border-radius: 24px; }

.gs-track .gallery-item {
  flex: 0 0 calc((100% - 20px) / 2);   /* two photos fill the row at the start */
  height: auto;
  aspect-ratio: 4 / 3;
  margin: 0;
  scroll-snap-align: start;
  border-radius: 24px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 20px 50px rgba(21, 48, 58, .16);
  background: #dfe8e4;
}
.gs-track .gallery-item:hover { transform: none; }
.gs-track .gallery-item a { display: block; width: 100%; height: 100%; }
.gs-track .gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
}

/* caption taken from the photo title */
.gs-cap {
  position: absolute;
  left: 16px;
  bottom: 16px;
  max-width: calc(100% - 32px);
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(10, 32, 30, .5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, .28);
  color: #fff;
  font: 500 13.5px/1.2 'Inter', sans-serif;
  pointer-events: none;
}

/* arrows: in the margins left and right of the photos, never on top of them */
.gs-btn {
  position: absolute;
  top: calc(50% - 40px);
  z-index: 5;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 0;
  background: #fff;
  color: #15303a;
  font-size: 18px;
  box-shadow: 0 10px 30px rgba(21, 48, 58, .22);
  cursor: pointer;
  transition: transform .2s, opacity .2s, background .2s, color .2s;
}
.gs-btn:hover { background: #15303a; color: #fff; transform: scale(1.06); }
.gs-btn[disabled] { opacity: .28; pointer-events: none; }
.gs-prev { left: -70px; }
.gs-next { right: -70px; }

/* progress + counter + hint */
.gs-meta {
  display: flex;
  align-items: center;
  gap: 22px;
  margin: 4px 0 0;
  padding: 0 4px;
}
.gs-bar { flex: 1; height: 4px; border-radius: 4px; background: rgba(21, 48, 58, .12); overflow: hidden; }
.gs-fill { display: block; height: 100%; width: 10%; border-radius: 4px; background: linear-gradient(90deg, #c9a24a, #1f8a7e); transition: width .15s linear; }
.gs-count { font: 600 14px 'Inter', sans-serif; color: #15303a; letter-spacing: .5px; min-width: 56px; text-align: right; }
.gs-hint { text-align: center; margin: 14px 0 0; font: 500 13.5px 'Inter', sans-serif; color: #566267; }

@media (min-width: 768px) and (max-width: 1299px) {
  .gs-btn { top: auto; bottom: 20px; width: 44px; height: 44px; font-size: 16px; }
  .gs-prev { left: 0; }
  .gs-next { right: 0; }
  .gs-meta { padding: 0 60px; }
}
@media (max-width: 767px) {
  .gallery-grid.gs-track { gap: 14px; padding-left: 0; padding-right: 0; }
  .gs-track .gallery-item { flex-basis: 84%; border-radius: 20px; }
  .gs-btn { display: none; }
  .gs-meta { padding: 0 4px; }
}
@media (prefers-reduced-motion: reduce) {
  .gallery-grid.gs-track { scroll-behavior: auto; }
}
