/* SECTION */
.gallery-3d {
  padding: 80px 5%;
  background: #f8fafc;
  text-align: center;
}

.gallery-title {
  font-size: 2.5rem;
  font-weight: 900;
  margin-bottom: 40px;
  color: #0f172a;
}

/* GRID */
.gallery-3d-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 25px;
}

/* CARD */
.gallery-card {
  perspective: 1000px;
}

.card-inner {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  transform-style: preserve-3d;
  transition: transform 0.4s ease;
  box-shadow: 0 20px 50px rgba(0,0,0,0.1);
}

/* IMAGE */
.card-inner img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
}

/* OVERLAY */
.card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 14px;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
}

/* HOVER 3D LIFT */
.gallery-card:hover .card-inner {
  transform: rotateY(8deg) rotateX(6deg) scale(1.04);
}
/* SECTION */
.premium-gallery {
  padding: 80px 5%;
  background: #f9fafb;
  text-align: center;
}

/* TITLE */
.gallery-title {
  font-size: 2.8rem;
  font-weight: 900;
  margin-bottom: 40px;
  color: #1e293b;
  position: relative;
  display: inline-block;
}

/* GRID */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  position: relative;
}

/* ITEM */
.gallery-item {
  perspective: 1200px;
}

.card-inner {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  transform-style: preserve-3d;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  box-shadow: 0 20px 50px rgba(0,0,0,0.1);
}

/* IMAGE */
.card-inner img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  display: block;
  border-radius: 15px;
}

/* OVERLAY */
.overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  border-bottom-left-radius: 15px;
  border-bottom-right-radius: 15px;
}

/* HOVER EFFECT */
.gallery-item:hover .card-inner {
  transform: rotateY(8deg) rotateX(6deg) scale(1.05);
  box-shadow: 0 30px 70px rgba(0,0,0,0.15);
}

/* ANIMATED SHAPES */
.premium-gallery::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 200px;
  height: 200px;
  background: rgba(37, 99, 235, 0.1);
  border-radius: 50%;
  animation: float 10s infinite alternate;
}

@keyframes float {
  from { transform: translateY(0); }
  to { transform: translateY(-20px); }
}
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
}

.lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 3rem;
  color: #fff;
  cursor: pointer;
}