.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
  gap: 20px;
  padding: 2rem;
}

.gallery a {
  text-decoration: none;
  color: black;
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  transition: transform 0.3s;
}

.gallery a:hover {
  transform: scale(1.05);
}

.gallery img {
  width: 100%;
  display: block;
  height: 700px;
  object-fit: cover;
}

.caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0,0,0,0.6);
  color: white;
  padding: 10px;
  text-align: center;
  font-weight: bold;
}