#sg-gallery-grid {

  min-height: 75vh;
}

.sg-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin: 40px 0;
}

.sg-card {
  cursor: pointer;
  background: #fff;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  transition: .3s ease;
}

.sg-card:hover {
  transform: translateY(-5px);
}

.sg-card-image {
  height: 220px;
  background-size: cover;
  background-position: center;
}

.sg-card-body {
  padding: 15px;
  text-align: center;
}

.sg-card-body h3 {
  font-family: 'Garet', sans-serif;
}



@media (max-width:1024px) {
  .sg-gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width:600px) {
  .sg-gallery-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================
   MODAL
========================= */

.sg-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 0;
  transition: opacity .25s ease;
}

.sg-modal.show {
  display: flex;
  opacity: 1;
}

.sg-modal-content {
  background: #ffffff;
  padding: 40px;
  width: 90%;
  max-width: 420px;
  border-radius: 12px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.2);
  position: relative;
  transform: translateY(20px);
  transition: transform .25s ease;
}

.sg-modal.show .sg-modal-content {
  transform: translateY(0);
}

.sg-modal-content h2 {
  font-size: 28px;
  margin-bottom: 25px;
  font-weight: 600;
  color: #333;
}

.sg-close {
  position: absolute;
  right: 18px;
  top: 15px;
  cursor: pointer;
  font-size: 18px;
  color: #999;
  transition: .2s;
}

.sg-close:hover {
  color: #000;
}

#sg-access-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

#sg-access-code {
  padding: 14px;
  font-size: 16px;
  border: 1px solid #ddd;
  border-radius: 6px;
  outline: none;
  transition: .2s;
}

#sg-access-code:focus {
  border-color: #c9a96e;
  box-shadow: 0 0 0 2px rgba(201, 169, 110, 0.15);
}

#sg-access-form button {
  padding: 14px;
  font-size: 14px;
  letter-spacing: 1px;
  text-transform: uppercase;
  border: none;
  border-radius: 6px;
  background: #c9a96e;
  color: white;
  cursor: pointer;
  transition: .2s;
}

#sg-access-form button:hover {
  background: #b8945b;
}

#sg-gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
}

@media (max-width: 1200px) {
  #sg-gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  #sg-gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  #sg-gallery-grid {
    grid-template-columns: 1fr;
  }
}

.sg-photo {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  cursor: pointer;
}

.sg-photo img {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  display: block;
  transition: transform .3s ease;
}

.sg-photo:hover img {
  transform: scale(1.05);
}

.sg-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  justify-content: center;
  align-items: center;
  z-index: 99999;
}

.sg-lightbox img {
  max-width: 90%;
  max-height: 90%;
}

.sg-lightbox button {
  position: absolute;
  background: none;
  border: none;
  color: white;
  font-size: 40px;
  cursor: pointer;
}

#sg-prev {
  left: 40px;
}

#sg-next {
  right: 40px;
}

.sg-lightbox-close {
  position: absolute;
  top: 30px;
  right: 40px;
  font-size: 40px;
  color: white;
  cursor: pointer;
}

.sg-download {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0, 0, 0, 0.6);
  color: white;
  padding: 6px 8px;
  border-radius: 4px;
  font-size: 14px;
  text-decoration: none;
}