/* Masonry Gallery */
.gallery {
  column-count: 4;
  column-gap: 16px;
  padding: 20px;
  width: 70%;
  margin: 0 auto;
}

.gallery-item {
  display: inline-block;
  width: 100%;
  margin: 0 0 16px;
  background: #1a1a1a;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,.5);
  cursor: pointer;
  transition: transform .25s ease;

  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  -moz-column-break-inside: avoid;
}

.gallery-item:hover {
  transform: scale(1.02);
}

.gallery-item img,
.gallery-item video {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  object-fit: cover;
}

/* Responsive Masonry */
@media (max-width: 1200px) {
  .gallery { column-count: 3; }
}
@media (max-width: 768px) {
  .gallery {
    column-count: 2;
    column-gap: 12px;
    padding: 12px;
  }
}
@media (max-width: 480px) {
  .gallery { column-count: 1; }
}

/* Preview Modal */
.preview {
  display: none;
  position: fixed;
  z-index: 999;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.9);
  overflow: hidden;
  text-align: center;
}

.preview-content {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  margin: 0;
}


.preview img,
.preview video {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 12px;
  transition: transform 0.2s ease;
}



.close {
  position: absolute;
  top: 20px; right: 35px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
}

.preview-controls {
  margin-top: 15px;
}

/* Controls (Next / Prev) */
.preview-controls {
  position: absolute;
  bottom: 30px;    /* move inside the modal */
  left: 50%;
  transform: translateX(-50%);
  z-index: 1001;
  display: flex;
  justify-content: center;
}

.preview-controls button {
  background: rgba(255,255,255,0.2);
  border: none;
  padding: 12px 20px;
  margin: 0 10px;
  color: #fff;
  font-size: 20px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s;
}

.preview-controls button:hover {
  background: rgba(255,255,255,0.4);
}


.myWhatsAppButton {
    z-index: 999;
}