.gallery_section {
  padding: 90px 0;
  background-color: #f8f9fa;
}

.gallery-masonry {
  margin: 30px 0;
}

.gallery-item {
  width: 100%;
  margin-bottom: 20px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: opacity 0.3s ease;
}

.gallery-item:hover {
  opacity: 0.9;
}

.gallery-item img,
.gallery-item video {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
}

.play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.play-button::after {
  content: '';
  border-style: solid;
  border-width: 15px 0 15px 25px;
  border-color: transparent transparent transparent #000;
}

/* Bootstrap Modal Overrides */
.modal-dialog.modal-xl {
  max-width: 90vw;
}

.modal-content {
  background-color: rgba(0,0,0,0.9);
}

.modal-header {
  border: none;
  padding: 1rem;
  position: absolute;
  right: 0;
  z-index: 1;
}

.modal-header .close {
  color: white;
  opacity: 1;
  text-shadow: none;
  font-size: 2rem;
}

.modal-body {
  text-align: center;
  padding: 0;
}

.modal-body img,
.modal-body video {
  max-height: 90vh;
  width: 100%;
  object-fit: contain;
}

/* Responsive Styles */
@media (max-width: 991px) {
  .gallery-item {
    width: calc(50% - 20px);
  }
}

@media (max-width: 576px) {
  .gallery-item {
    width: 100%;
  }
  
  .modal-header .close {
    right: 10px;
    top: -40px;
  }
}