/* ==========================================================================
   SKYOCEANENTERPRISES — DEDICATED GALLERY PAGE STYLESHEET
   File: assets/css/gallery-page.css
   WordPress: will become page-gallery.php styles / template-parts
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. SECTION 1 — GALLERY HERO (Deep Navy #0D1B2A)
   -------------------------------------------------------------------------- */
.gallery-hero-section {
  position: relative;
  min-height: 48vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 140px 24px 85px;
  background-color: #0D1B2A !important;
  background: linear-gradient(135deg, #091320 0%, #0D1B2A 70%, #102438 100%) !important;
  color: #FFFFFF !important;
  overflow: hidden;
}

/* Subtle background illumination & texture */
.gallery-hero-section::before {
  content: '';
  position: absolute;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 500px;
  background: radial-gradient(ellipse at center, rgba(22, 138, 173, 0.22) 0%, rgba(13, 27, 42, 0) 70%);
  pointer-events: none;
}

.gallery-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 820px;
  margin: 0 auto;
  opacity: 1 !important;
  transform: none !important;
}

.gallery-hero-label {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-brand);
  font-size: 12px;
  letter-spacing: 0.26em;
  color: var(--color-gold);
  text-transform: uppercase;
  margin-bottom: 18px;
}

.gallery-hero-label::before,
.gallery-hero-label::after {
  content: '';
  display: block;
  width: 28px;
  height: 2px;
  background: var(--color-gold);
  border-radius: 2px;
}

.gallery-hero-title {
  font-family: var(--font-brand);
  font-size: clamp(2.4rem, 5.5vw, 4rem);
  font-weight: 800;
  color: var(--color-white);
  line-height: 1.15;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: 22px;
}

.gallery-hero-desc {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.88);
  max-width: 680px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   2. SECTION 2 — GALLERY INTRODUCTION (Off-White #F8F7F2)
   -------------------------------------------------------------------------- */
.gallery-intro-section {
  background-color: var(--color-offwhite);
  padding: 85px 24px;
  text-align: center;
  position: relative;
}

.gallery-intro-inner {
  max-width: 780px;
  margin: 0 auto;
}

.gallery-intro-heading {
  font-family: var(--font-brand);
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 800;
  color: var(--color-navy);
  line-height: 1.25;
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.gallery-intro-rule {
  display: block;
  width: 56px;
  height: 3px;
  background: var(--color-ocean);
  margin: 0 auto 22px;
  border-radius: 2px;
}

.gallery-intro-text {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  line-height: 1.75;
  color: #3d4a58;
  margin: 0;
}

/* --------------------------------------------------------------------------
   3. SECTION 3 & 4 — CATEGORY FILTERS & MAIN GALLERY (Deep Navy #0D1B2A)
   -------------------------------------------------------------------------- */
.gallery-main-section {
  background-color: var(--color-navy);
  padding: 95px 24px 115px;
  position: relative;
  overflow: hidden;
}

.gallery-main-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(22, 138, 173, 0.4) 50%, transparent 100%);
}

.gallery-container {
  max-width: 1280px;
  margin: 0 auto;
}

/* Filter Controls */
.gallery-filter-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 50px;
}

.gallery-filter-pill {
  font-family: var(--font-heading);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 10px 22px;
  border-radius: 30px;
  cursor: pointer;
  transition: all var(--transition-fast);
  outline: none;
}

.gallery-filter-pill:hover {
  color: var(--color-white);
  background: rgba(22, 138, 173, 0.25);
  border-color: var(--color-ocean);
  transform: translateY(-2px);
}

.gallery-filter-pill.active {
  color: var(--color-white);
  background: var(--color-ocean);
  border-color: var(--color-ocean);
  box-shadow: 0 4px 16px rgba(22, 138, 173, 0.45);
}

.gallery-filter-pill:focus-visible {
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.6);
}

/* Mixed-Size Editorial Grid (18 Items) */
.gallery-editorial-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}

/* Gallery Item Card */
.gallery-card {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  cursor: pointer;
  background-color: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.32s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.28s ease,
              opacity 0.40s ease;
  outline: none;
}

/* ==========================================================================
   PPT PRESENTATION-STYLE GALLERY ENTRANCE ANIMATION
   Smooth, elegant upward glide with crisp presentation timing ("pyar pyar se + thora fast")
   ========================================================================== */

/* Keyframe for presentation slide entrance */
@keyframes pptGalleryEntrance {
  0% {
    opacity: 0;
    transform: translateY(22px) scale(0.975);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Base scroll reveal state */
.gallery-card.gal-item-reveal {
  opacity: 0;
  transform: translateY(24px) scale(0.975);
  will-change: transform, opacity;
  transition: opacity 0.44s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.44s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.30s ease,
              border-color 0.30s ease;
}

/* Activated on scroll / viewport entry */
.gallery-card.gal-item-reveal.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Stagger delays across rows so cards cascade in like PowerPoint presentation slides */
.gallery-card.gal-item-reveal:nth-child(4n + 1) { transition-delay: 0.04s; }
.gallery-card.gal-item-reveal:nth-child(4n + 2) { transition-delay: 0.09s; }
.gallery-card.gal-item-reveal:nth-child(4n + 3) { transition-delay: 0.14s; }
.gallery-card.gal-item-reveal:nth-child(4n + 4) { transition-delay: 0.19s; }

/* Filter switching slide-in animation */
.gallery-card.ppt-slide-in {
  animation: pptGalleryEntrance 0.42s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Editorial Sizing Accents (Mixed-size creative grid) */
.gallery-card.tall {
  grid-row: span 2;
  aspect-ratio: auto;
  height: 100%;
}

.gallery-card.wide {
  grid-column: span 2;
  aspect-ratio: auto;
  height: 100%;
}

.gallery-card.is-hidden {
  display: none !important;
}

.gallery-card:hover {
  transform: translateY(-6px) scale(1.012);
  border-color: rgba(212, 175, 55, 0.65);
  box-shadow: 0 20px 42px rgba(0, 0, 0, 0.55), 0 0 24px rgba(22, 138, 173, 0.28);
  z-index: 2;
}

.gallery-card:focus-visible {
  box-shadow: 0 0 0 3px var(--color-gold);
}

/* Image */
.gallery-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-card:hover .gallery-card-img {
  transform: scale(1.07);
}

/* Card Dark Overlay */
.gallery-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(13, 27, 42, 0.05) 0%,
    rgba(13, 27, 42, 0.45) 55%,
    rgba(13, 27, 42, 0.94) 100%
  );
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  pointer-events: none;
  transition: background 0.35s ease;
}

.gallery-card:hover .gallery-card-overlay {
  background: linear-gradient(
    180deg,
    rgba(13, 27, 42, 0.1) 0%,
    rgba(22, 138, 173, 0.35) 45%,
    rgba(13, 27, 42, 0.96) 100%
  );
}

.gallery-card-tag {
  display: inline-block;
  font-family: var(--font-brand);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--color-gold);
  text-transform: uppercase;
  margin-bottom: 6px;
}

.gallery-card-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-white);
  line-height: 1.35;
  margin: 0;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

/* Zoom / Expand Icon Badge */
.gallery-card-badge {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(13, 27, 42, 0.7);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.85);
  transition: all var(--transition-fast);
  pointer-events: none;
}

.gallery-card-badge svg {
  width: 18px;
  height: 18px;
  stroke: var(--color-white);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.gallery-card:hover .gallery-card-badge {
  opacity: 1;
  transform: scale(1);
  background: var(--color-ocean);
  border-color: var(--color-gold);
}

/* --------------------------------------------------------------------------
   4. SECTION 5 — FULLSCREEN IMAGE VIEWER / LIGHTBOX
   -------------------------------------------------------------------------- */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background-color: rgba(13, 27, 42, 0.95);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 30px 20px;
}

.gallery-lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-content {
  position: relative;
  max-width: 1040px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.lightbox-img-wrap {
  position: relative;
  max-width: 90vw;
  max-height: 76vh;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 30px rgba(22, 138, 173, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background-color: #060e17;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 76vh;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

/* Lightbox Controls */
.lightbox-btn {
  position: absolute;
  background: rgba(13, 27, 42, 0.75);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--color-white);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  z-index: 10;
  outline: none;
}

.lightbox-btn svg {
  width: 22px;
  height: 22px;
  stroke: var(--color-white);
  fill: none;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.lightbox-btn:hover {
  background: var(--color-ocean);
  border-color: var(--color-gold);
  transform: scale(1.08);
}

.lightbox-btn:focus-visible {
  box-shadow: 0 0 0 3px var(--color-gold);
}

.lightbox-close {
  top: -55px;
  right: 0;
}

.lightbox-prev {
  left: -65px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-prev:hover {
  transform: translateY(-50%) scale(1.08);
}

.lightbox-next {
  right: -65px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next:hover {
  transform: translateY(-50%) scale(1.08);
}

/* Lightbox Caption */
.lightbox-caption {
  margin-top: 18px;
  text-align: center;
  max-width: 700px;
}

.lightbox-tag {
  display: inline-block;
  font-family: var(--font-brand);
  font-size: 11px;
  letter-spacing: 0.22em;
  color: var(--color-gold);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.lightbox-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-white);
  margin: 0 0 8px;
}

.lightbox-counter {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.08);
  padding: 4px 14px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* --------------------------------------------------------------------------
   5. SECTION 6 — FINAL CTA SECTION (Ocean Blue #168AAD)
   -------------------------------------------------------------------------- */
.gallery-cta-section {
  background-color: var(--color-ocean);
  color: var(--color-white);
  padding: 95px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.gallery-cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.12) 0%, transparent 65%);
  pointer-events: none;
}

.gallery-cta-inner {
  position: relative;
  z-index: 2;
  max-width: 780px;
  margin: 0 auto;
}

.gallery-cta-title {
  font-family: var(--font-brand);
  font-size: clamp(2rem, 4.2vw, 3rem);
  font-weight: 800;
  line-height: 1.2;
  color: var(--color-white);
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.gallery-cta-desc {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.92);
  margin: 0 auto 36px;
  max-width: 650px;
}

.btn-gallery-contact {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background-color: var(--color-navy);
  color: var(--color-white);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  padding: 18px 42px;
  border-radius: 6px;
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(13, 27, 42, 0.35);
  transition: all var(--transition-fast);
}

.btn-gallery-contact svg {
  width: 18px;
  height: 18px;
  stroke: var(--color-gold);
  fill: none;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform var(--transition-fast);
}

.btn-gallery-contact:hover {
  background-color: #07111b;
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(13, 27, 42, 0.45);
}

.btn-gallery-contact:hover svg {
  transform: translateX(4px);
}

/* --------------------------------------------------------------------------
   6. SECTION 7 — SHARED FOOTER OVERRIDES (Deep Navy #0D1B2A)
   -------------------------------------------------------------------------- */
.site-footer.footer-navy,
body.gallery-page .site-footer {
  background-color: var(--color-navy);
}

/* --------------------------------------------------------------------------
   7. RESPONSIVE BREAKPOINTS
   -------------------------------------------------------------------------- */
@media (max-width: 1180px) {
  .gallery-editorial-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .lightbox-prev {
    left: -20px;
  }

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

@media (max-width: 860px) {
  .gallery-editorial-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .gallery-card.tall,
  .gallery-card.wide {
    grid-row: auto;
    grid-column: auto;
    aspect-ratio: 4 / 3;
  }

  .lightbox-prev,
  .lightbox-next {
    position: static;
    transform: none;
    margin: 0 8px;
  }

  .lightbox-prev:hover,
  .lightbox-next:hover {
    transform: scale(1.08);
  }

  .lightbox-nav-row {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 14px;
  }

  .lightbox-close {
    top: -46px;
    right: 0;
  }
}

@media (max-width: 560px) {
  .gallery-hero-section {
    min-height: auto;
    padding: 105px 20px 65px;
  }

  .gallery-intro-section,
  .gallery-main-section,
  .gallery-cta-section {
    padding: 68px 20px;
  }

  .gallery-filter-bar {
    gap: 8px;
    margin-bottom: 34px;
  }

  .gallery-filter-pill {
    font-size: 0.82rem;
    padding: 8px 16px;
  }

  .gallery-editorial-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .btn-gallery-contact {
    width: 100%;
    justify-content: center;
  }

  .lightbox-img-wrap {
    max-height: 60vh;
  }
}

@media (max-width: 480px) {
  .gallery-hero-section h1 {
    font-size: 2rem;
  }
  .gallery-editorial-grid {
    grid-template-columns: 1fr;
  }
  .gallery-filter-bar {
    gap: 8px;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 8px;
  }
}

@media (max-width: 375px) {
  .gallery-hero-section h1 {
    font-size: 1.75rem;
  }
  .gallery-card-content {
    padding: 16px 12px;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .gallery-card,
  .gallery-card.gal-item-reveal,
  .gallery-card.ppt-slide-in,
  .gallery-card-img,
  .gallery-card-badge,
  .gallery-filter-pill,
  .btn-gallery-contact,
  .lightbox-btn {
    transform: none !important;
    transition: none !important;
    animation: none !important;
    opacity: 1 !important;
  }
}

