
/* ===================== PAGE CONTENT ===================== */
.page-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 24px 80px;
}

/* ===================== GRID & CARDS ===================== */
.obras-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-bottom: 56px;
}

.obra-card {
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--cinza-borda);
  overflow: hidden;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.03);
  display: flex;
  flex-direction: column;
  transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.4s ease;
  opacity: 0; /* Controlado pela animação staggered via JS */
  transform: translateY(15px) scale(0.98);
}

.obra-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 36px rgba(30, 58, 110, 0.12);
}

.obra-card-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4/3;
  overflow: hidden;
  background: #111a2e;
}

.obra-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.obra-card:hover .obra-card-img-wrap img {
  transform: scale(1.08);
}

.obra-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(26, 43, 74, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.obra-card:hover .obra-card-overlay {
  opacity: 1;
}

.zoom-icon {
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 10px 20px;
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  transform: translateY(12px);
  transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
  display: flex;
  align-items: center;
  gap: 6px;
}

.zoom-icon i {
  font-size: 0.85rem;
}

.obra-card:hover .zoom-icon {
  transform: translateY(0);
  border-color: #fff;
  background: rgba(255, 255, 255, 0.2);
}

@keyframes cardFadeIn {
  from {
    opacity: 0;
    transform: translateY(15px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ===================== BTN VER MAIS ===================== */
.ver-mais-wrap {
  text-align: center;
  padding: 12px 24px 20px;
  position: relative;
}

/* ===================== LIGHTBOX MELHORADO ===================== */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(10, 16, 28, 0.96);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
}

.lightbox.open {
  display: flex;
}

.lightbox-content-wrapper {
  position: relative;
  width: 100%;
  max-width: 820px;
  margin: 0 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: lightboxZoomIn 0.3s ease-out;
}

@keyframes lightboxZoomIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.lightbox img {
  width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  display: block;
  transition: transform 0.25s ease;
  cursor: zoom-in;
  background: #111a2e;
}

.lightbox img.zoomed {
  transform: scale(1.8);
  cursor: zoom-out;
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 28px;
  font-size: 2.5rem;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  background: none;
  border: none;
  line-height: 1;
  transition: all 0.2s;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-close:hover {
  color: #fff;
  transform: scale(1.1) rotate(90deg);
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 1.5rem;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  backdrop-filter: blur(4px);
  z-index: 100;
}

.lightbox-prev {
  left: 28px;
}

.lightbox-next {
  right: 28px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: var(--laranja);
  border-color: var(--laranja);
  transform: translateY(-50%) scale(1.08);
  box-shadow: 0 0 20px rgba(212, 105, 30, 0.5);
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 1024px) {
  .obras-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
  
  .lightbox-content-wrapper {
    margin: 0 80px;
  }
}

@media (max-width: 768px) {
  .page-content {
    padding: 40px 16px 60px;
  }

  .obras-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 40px;
  }

  .lightbox-content-wrapper {
    margin: 0 16px;
  }

  .lightbox img {
    max-height: 65vh;
  }

  .lightbox-prev,
  .lightbox-next {
    width: 44px;
    height: 44px;
    font-size: 1.2rem;
  }

  .lightbox-prev {
    left: 12px;
  }

  .lightbox-next {
    right: 12px;
  }
}

@media (max-width: 480px) {
  .lightbox-prev,
  .lightbox-next {
    display: none;
  }
}
