.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 15px;
  padding: 15px;
  max-width: 1400px;
  margin: auto;
}

.gallery-item {
  position: relative;
  cursor: pointer;
  overflow: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gallery-item img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.gallery-item:hover img {
  transform: scale(1.05);
  filter: brightness(85%);
}

.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 999;
}

.lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
  box-shadow: 10px 10px 20px rgba(0, 0, 0, 1);
}

.lightbox-close {
  position: absolute;
  top: 100px;
  right: 30px;
  color: #fff;
  cursor: pointer;
  background: #000;
  padding: 0 15px;
  font-size: 35px;
  transition: background 0.3s;
  border-radius: 10px;
  box-shadow: 5px 5px 20px rgba(0, 0, 0, 1);
}

.lightbox-close:hover {
  background: rgba(255, 75, 0, 0.7);
}