.gallery-wrapper {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;        
  justify-content: center;
  gap: 1rem;         
}
.gallery-item {
  flex: 1 1 calc(25% - 1rem); /* 4 items per row on large screens */
  max-width: calc(25% - 1rem);
}
.gallery-img {
  width: 100%;
  max-width: 300px;
  height: 175px;
  border-radius: 5px;
  object-fit: cover;
  transition: transform 0.3s ease;
}
.gallery-img:hover {
  transform: scale(1.03);
}
.gallery-caption {
  margin-top: 0.5rem;
  font-size: 0.95rem;
  color: #364def;
  font-weight: 700;
}

/* Medium screens: 3 per row */
@media (max-width: 992px) {
  .gallery-item {
    flex: 1 1 calc(33.333% - 1rem);
    max-width: calc(33.333% - 1rem);
  }
}

/* Small screens: 2 per row */
@media (max-width: 768px) {
  .gallery-item {
    flex: 1 1 calc(50% - 1rem);
    max-width: calc(50% - 1rem);
  }
}

/* Extra small: 1 per row */
@media (max-width: 576px) {
  .gallery-item {
    flex: 1 1 100%;
    max-width: 100%;
    text-align: center;
  }
}