/*--------------------------------------------------------------
# Video Slider Section
--------------------------------------------------------------*/
.video-slider .video-swiper {
  padding-bottom: 60px;
}

.video-slider .video-card {
  background-color: var(--surface-color);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 6px 24px color-mix(in srgb, var(--default-color), transparent 92%);
  border: 1px solid color-mix(in srgb, var(--default-color), transparent 92%);
  height: 100%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-slider .video-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 36px color-mix(in srgb, var(--default-color), transparent 85%);
}

.video-slider .video-thumb {
  display: block;
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: color-mix(in srgb, var(--default-color), transparent 92%);
}

.video-slider .video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.video-slider .video-card:hover .video-thumb img {
  transform: scale(1.06);
}

.video-slider .video-thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top,
    color-mix(in srgb, #000, transparent 35%) 0%,
    transparent 55%);
  opacity: 0.85;
  transition: opacity 0.3s ease;
}

.video-slider .video-card:hover .video-thumb::after {
  opacity: 1;
}

.video-slider .video-thumb .play-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background-color: var(--accent-color);
  color: var(--contrast-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  z-index: 2;
  box-shadow: 0 6px 20px color-mix(in srgb, var(--accent-color), transparent 55%);
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.video-slider .video-card:hover .play-badge {
  transform: translate(-50%, -50%) scale(1.12);
}

/* Ring that pulses out from the play button */
.video-slider .video-thumb .play-badge::before {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  border: 2px solid color-mix(in srgb, var(--accent-color), transparent 45%);
  animation: video-pulse 2.4s ease-out infinite;
}

@keyframes video-pulse {
  0%   { transform: scale(0.85); opacity: 0.9; }
  70%  { transform: scale(1.25); opacity: 0; }
  100% { transform: scale(1.25); opacity: 0; }
}

.video-slider .video-thumb .video-tag {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  background-color: color-mix(in srgb, #000, transparent 45%);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
  padding: 5px 12px;
  border-radius: 20px;
  text-transform: uppercase;
}

.video-slider .video-body {
  padding: 22px 24px 26px 24px;
}

.video-slider .video-body h4 {
  font-size: 18px;
  margin-bottom: 8px;
  color: var(--heading-color);
}

.video-slider .video-body p {
  font-size: 14px;
  margin-bottom: 0;
  color: color-mix(in srgb, var(--default-color), transparent 25%);
}

/* A slide with no video attached yet reads as inactive */
.video-slider .video-card.is-placeholder .video-thumb {
  cursor: default;
}

.video-slider .video-card.is-placeholder .play-badge {
  background-color: color-mix(in srgb, var(--default-color), transparent 55%);
  box-shadow: none;
}

.video-slider .video-card.is-placeholder .play-badge::before {
  animation: none;
  border-color: transparent;
}

.video-slider .swiper-pagination {
  bottom: 0;
}

.video-slider .swiper-pagination .swiper-pagination-bullet {
  background-color: color-mix(in srgb, var(--default-color), transparent 70%);
  opacity: 1;
}

.video-slider .swiper-pagination .swiper-pagination-bullet-active {
  background-color: var(--accent-color);
}

.video-slider .swiper-button-next,
.video-slider .swiper-button-prev {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: var(--surface-color);
  color: var(--accent-color);
  box-shadow: 0 4px 16px color-mix(in srgb, var(--default-color), transparent 85%);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.video-slider .swiper-button-next:hover,
.video-slider .swiper-button-prev:hover {
  background-color: var(--accent-color);
  color: var(--contrast-color);
}

.video-slider .swiper-button-next::after,
.video-slider .swiper-button-prev::after {
  font-size: 18px;
  font-weight: 700;
}

/*--------------------------------------------------------------
# Photo Gallery Section
--------------------------------------------------------------*/
/* The tile spans below are sized so the default seven images fill a
   complete rectangle with no gaps: the feature tile takes four cells,
   tiles 2 and 3 take two each, and the remaining four take one each,
   giving 12 cells across three rows of four.
   If you change how many images are in $gallery, check the grid still
   fills - "dense" backfills gaps but cannot invent a missing tile. */
.photo-gallery .gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 180px;
  grid-auto-flow: dense;
  gap: 16px;
}

.photo-gallery .gallery-item {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 14px;
  background-color: color-mix(in srgb, var(--default-color), transparent 92%);
}

/* First tile is the feature: twice as wide and tall */
.photo-gallery .gallery-item:first-child {
  grid-column: span 2;
  grid-row: span 2;
}

/* Tiles 2 and 3 sit beside the feature as full-width banners */
.photo-gallery .gallery-item:nth-child(2),
.photo-gallery .gallery-item:nth-child(3) {
  grid-column: span 2;
}

.photo-gallery .gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.photo-gallery .gallery-item:hover img {
  transform: scale(1.08);
}

.photo-gallery .gallery-item .gallery-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background-color: color-mix(in srgb, var(--accent-color), transparent 25%);
  color: var(--contrast-color);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.photo-gallery .gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.photo-gallery .gallery-item .gallery-overlay i {
  font-size: 26px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--contrast-color);
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(8px);
  transition: transform 0.3s ease;
}

.photo-gallery .gallery-item:hover .gallery-overlay i {
  transform: translateY(0);
}

.photo-gallery .gallery-item .gallery-overlay span {
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  padding: 0 12px;
}

/*--------------------------------------------------------------
# Responsive
--------------------------------------------------------------*/
/* Three columns: 12 cells over four rows, dense flow tucking the
   single tiles into the column beside the feature tile. */
@media (max-width: 992px) {
  .photo-gallery .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 160px;
  }
}

/* Two columns: every tile single except the feature, which goes
   full width and one row tall - 8 cells over four rows. */
@media (max-width: 768px) {
  .photo-gallery .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 150px;
    gap: 12px;
  }

  .photo-gallery .gallery-item:first-child {
    grid-column: span 2;
    grid-row: span 1;
  }

  .photo-gallery .gallery-item:nth-child(2),
  .photo-gallery .gallery-item:nth-child(3) {
    grid-column: span 1;
  }

  .video-slider .video-thumb .play-badge {
    width: 54px;
    height: 54px;
    font-size: 26px;
  }
}

@media (max-width: 575px) {
  .photo-gallery .gallery-grid {
    grid-auto-rows: 130px;
  }
}
