/* ==========================================================================
   ORCHID SOCIETY OF ASSAM - GALLERY PAGE STYLES
   ========================================================================== */

:root {
  --gallery-bg: #fbfdfc;
  --gallery-emerald: #0B7B68;
  --gallery-emerald-dark: #064e42;
  --gallery-emerald-light: #10B981;
  --gallery-mint-bg: #eaf4ee;
  --gallery-mint-border: #b8d6c2;
  --gallery-text-main: #142823;
  --gallery-text-muted: #4e6b63;
  --gallery-card-bg: #ffffff;
  --gallery-border-subtle: #e5ebe7;
  --gallery-radius-sm: 8px;
  --gallery-radius-md: 14px;
  --gallery-radius-lg: 20px;
  --gallery-radius-pill: 9999px;
  --gallery-shadow-sm: 0 4px 16px rgba(11, 123, 104, 0.06);
  --gallery-shadow-hover: 0 14px 32px rgba(11, 123, 104, 0.14);
}

.gallery-page-body {
  background-color: var(--gallery-bg);
  color: var(--gallery-text-main);
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  overflow-x: hidden;
}

/* --------------------------------------------------------------------------
   1. HERO SECTION
   -------------------------------------------------------------------------- */
.gallery-hero {
  position: relative;
  min-height: 480px;
  background: url('/assets/images/gallery-hero-bg.png') no-repeat right center / cover;
  background-color: #f7f9f7;
  padding: 130px 0 85px 0;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--gallery-border-subtle);
  overflow: hidden;
}

.gallery-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(251, 253, 252, 0.95) 0%, rgba(251, 253, 252, 0.82) 48%, rgba(251, 253, 252, 0.18) 80%, transparent 100%);
  pointer-events: none;
  z-index: 1;
}

.gallery-hero-container {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.gallery-hero-content {
  max-width: 580px;
}

.gallery-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gallery-emerald);
  margin-bottom: 10px;
}

.gallery-eyebrow i {
  font-size: 0.85rem;
}

.gallery-hero-title {
  font-family: Spectral, Cormorant Garamond, Georgia, serif;
  font-size: clamp(2.4rem, 4.5vw, 3.6rem);
  font-weight: 700;
  line-height: 1.08;
  color: #112822;
  margin: 0 0 14px 0;
  letter-spacing: -0.02em;
}

.gallery-title-italic {
  font-style: italic;
  color: var(--gallery-emerald);
  font-weight: 600;
  position: relative;
  display: inline-block;
}

.title-accent-bar {
  display: block;
  width: 54px;
  height: 3.5px;
  background: var(--gallery-emerald-light);
  border-radius: 4px;
  margin-top: 10px;
}

.gallery-hero-desc {
  font-size: 0.96rem;
  line-height: 1.6;
  color: var(--gallery-text-muted);
  margin: 0 0 22px 0;
  max-width: 480px;
}

.gallery-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  padding: 6px 16px;
  border-radius: var(--gallery-radius-pill);
  border: 1px solid rgba(11, 123, 104, 0.2);
  font-size: 0.8rem;
  color: var(--gallery-text-muted);
  box-shadow: var(--gallery-shadow-sm);
}

.gallery-breadcrumb a {
  color: var(--gallery-emerald);
  text-decoration: none;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: color 0.2s;
}

.gallery-breadcrumb a:hover {
  color: var(--gallery-emerald-dark);
}

.breadcrumb-sep {
  color: #9cb5ac;
  font-size: 0.85rem;
}

.breadcrumb-current {
  color: #1e3a32;
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   2. SHOWCASE & FILTER SECTION
   -------------------------------------------------------------------------- */
.gallery-showcase-section {
  position: relative;
  padding: 55px 0 70px 0;
  background: #ffffff;
}

.gallery-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
}

.gallery-watermark {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  font-family: Spectral, Georgia, serif;
  font-size: clamp(3rem, 7vw, 6rem);
  font-style: italic;
  color: rgba(11, 123, 104, 0.04);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

.showcase-header {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 640px;
  margin: 0 auto 32px auto;
}

.showcase-flower-icon {
  display: inline-block;
  font-size: 1.4rem;
  margin-bottom: 6px;
  animation: gentlePulse 3s ease-in-out infinite;
}

@keyframes gentlePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

.showcase-title {
  font-family: Spectral, Cormorant Garamond, Georgia, serif;
  font-size: clamp(1.8rem, 3.2vw, 2.5rem);
  font-weight: 700;
  color: #112822;
  margin: 0 0 10px 0;
  letter-spacing: -0.01em;
}

.showcase-subtitle {
  font-size: 0.92rem;
  color: var(--gallery-text-muted);
  line-height: 1.55;
  margin: 0;
}

/* Filter Bar Pills */
.gallery-filter-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 45px;
  position: relative;
  z-index: 2;
}

.gallery-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 18px;
  border-radius: var(--gallery-radius-pill);
  border: 1px solid var(--gallery-border-subtle);
  background: #ffffff;
  color: var(--gallery-text-muted);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.gallery-filter-btn i {
  font-size: 0.85rem;
  color: var(--gallery-emerald);
  transition: color 0.25s;
}

.gallery-filter-btn:hover {
  border-color: var(--gallery-emerald-light);
  color: var(--gallery-emerald-dark);
  transform: translateY(-2px);
  box-shadow: var(--gallery-shadow-sm);
}

.gallery-filter-btn.is-active {
  background: var(--gallery-emerald);
  border-color: var(--gallery-emerald);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(11, 123, 104, 0.25);
}

.gallery-filter-btn.is-active i {
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   3. CATEGORY BLOCKS & 5-COLUMN PHOTO GRIDS
   -------------------------------------------------------------------------- */
.gallery-category-block {
  margin-bottom: 48px;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.gallery-category-block.is-hidden {
  display: none;
}

.category-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 14px;
}

.category-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

.category-icon {
  font-size: 1.15rem;
  color: var(--gallery-emerald);
}

.category-heading {
  font-family: Spectral, Georgia, serif;
  font-size: 1.28rem;
  font-weight: 700;
  color: #142823;
  margin: 0;
  white-space: nowrap;
}

.category-divider-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, #d8e5df 0%, rgba(216, 229, 223, 0.2) 100%);
  margin-left: 8px;
}

.category-view-all-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: none;
  color: var(--gallery-emerald);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.category-view-all-btn .arrow {
  transition: transform 0.2s ease;
}

.category-view-all-btn:hover {
  color: var(--gallery-emerald-dark);
}

.category-view-all-btn:hover .arrow {
  transform: translateX(3px);
}

/* 5-Column Grid */
.gallery-grid-5 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 16px;
}

.gallery-card {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: var(--gallery-radius-md);
  overflow: hidden;
  background: #0d2821;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  cursor: pointer;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.3s ease;
  border: 1px solid rgba(11, 123, 104, 0.12);
  display: flex;
  flex-direction: column;
}

/* Portrait Card: Taller aspect ratio with elegant framing */
.gallery-card.is-portrait {
  aspect-ratio: 3 / 4;
}

/* Landscape Card: Standard wide framing */
.gallery-card.is-landscape {
  aspect-ratio: 4 / 3;
}

.gallery-card.is-square {
  aspect-ratio: 1 / 1;
}

.gallery-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: var(--gallery-shadow-hover);
  border-color: rgba(16, 185, 129, 0.5);
}

.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

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

.gallery-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11, 123, 104, 0) 30%, rgba(6, 78, 66, 0.88) 100%);
  opacity: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 14px;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

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

.gallery-card-title {
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 700;
  margin: 0;
  line-height: 1.25;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

.gallery-card-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(3, 33, 27, 0.65);
  backdrop-filter: blur(6px);
  color: #a7f3d0;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(16, 185, 129, 0.3);
  z-index: 2;
  transition: opacity 0.2s ease;
}

.gallery-card-zoom-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--gallery-emerald-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.25s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  z-index: 2;
}

.gallery-card:hover .gallery-card-zoom-icon {
  opacity: 1;
  transform: scale(1);
}

/* --------------------------------------------------------------------------
   4. CALL TO ACTION CARD
   -------------------------------------------------------------------------- */
.gallery-cta-container {
  margin-top: 35px;
}

.gallery-cta-card {
  position: relative;
  background: linear-gradient(135deg, #faf7f0 0%, #edf7f2 60%, #e2f2ea 100%);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: var(--gallery-radius-lg);
  padding: 24px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(11, 123, 104, 0.06);
}

.gallery-cta-left {
  display: flex;
  align-items: center;
  gap: 20px;
  position: relative;
  z-index: 2;
}

.cta-sketch-img {
  width: 52px;
  height: auto;
  opacity: 0.85;
  flex-shrink: 0;
}

.cta-camera-circle {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--gallery-emerald);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  box-shadow: 0 4px 14px rgba(11, 123, 104, 0.28);
  flex-shrink: 0;
}

.cta-text-block h3 {
  font-family: Spectral, Georgia, serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #112822;
  margin: 0 0 4px 0;
}

.cta-text-block p {
  font-size: 0.84rem;
  color: var(--gallery-text-muted);
  margin: 0;
  line-height: 1.45;
}

.gallery-cta-btn {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--gallery-emerald);
  color: #ffffff;
  font-family: inherit;
  font-size: 0.84rem;
  font-weight: 700;
  padding: 10px 22px;
  border-radius: var(--gallery-radius-pill);
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.25s ease;
  box-shadow: 0 4px 14px rgba(11, 123, 104, 0.22);
}

.gallery-cta-btn:hover {
  background: var(--gallery-emerald-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(11, 123, 104, 0.32);
  color: #ffffff;
}

.gallery-cta-btn i {
  font-size: 0.9rem;
}

/* --------------------------------------------------------------------------
   5. LIGHTBOX MODAL - FULL IMMERSIVE PHOTO VIEWER
   -------------------------------------------------------------------------- */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(2, 14, 11, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

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

.lightbox-dialog {
  position: relative;
  width: 100%;
  max-width: 1200px;
  height: 92vh;
  max-height: 92vh;
  background: #051a14;
  border: 1px solid rgba(52, 211, 153, 0.35);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(16, 185, 129, 0.2);
  display: flex;
  flex-direction: column;
}

.lightbox-close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 30;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.7);
  border: 1.5px solid rgba(255, 255, 255, 0.35);
  color: #ffffff;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.lightbox-close-btn:hover {
  background: #ef4444;
  border-color: #ef4444;
  transform: scale(1.1);
}

.lightbox-image-frame {
  position: relative;
  flex: 1;
  width: 100%;
  min-height: 0; /* Allow flex item to shrink properly */
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, #07221a 0%, #020b08 100%);
  padding: 16px 20px;
  overflow: hidden;
}

/* FULL PHOTO DISPLAY - FILLS THE ENTIRE STAGE UNTRUNCATED FOR BOTH PORTRAIT AND LANDSCAPE */
.lightbox-image-frame img {
  max-width: 100% !important;
  max-height: 100% !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
  object-position: center !important;
  display: block !important;
  border-radius: 8px !important;
  filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.75)) !important;
  transition: transform 0.25s ease;
}

.lightbox-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(11, 123, 104, 0.9);
  border: 1.5px solid rgba(255, 255, 255, 0.45);
  color: #ffffff;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 20;
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.lightbox-nav-btn:hover {
  background: #10b981;
  transform: translateY(-50%) scale(1.12);
  box-shadow: 0 6px 24px rgba(16, 185, 129, 0.5);
}

.lightbox-prev { left: 18px; }
.lightbox-next { right: 18px; }

.lightbox-caption-bar {
  padding: 14px 24px;
  background: #061914;
  border-top: 1px solid rgba(52, 211, 153, 0.2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  z-index: 10;
}

.lightbox-caption-left {
  flex: 1;
  min-width: 200px;
}

.lightbox-caption-left h4 {
  font-family: Spectral, Georgia, serif;
  font-size: 1.2rem;
  color: #ffffff;
  margin: 0 0 4px 0;
}

.lightbox-caption-left p {
  font-size: 0.84rem;
  color: #a7dcc2;
  margin: 0;
  line-height: 1.4;
}

.lightbox-meta-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lightbox-counter {
  font-size: 0.78rem;
  color: #6ee7b7;
  font-weight: 700;
  background: rgba(16, 185, 129, 0.15);
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.lightbox-tag {
  background: rgba(16, 185, 129, 0.25);
  border: 1px solid rgba(16, 185, 129, 0.5);
  color: #34d399;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: var(--gallery-radius-pill);
}

/* --------------------------------------------------------------------------
   6. RESPONSIVE BREAKPOINTS
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .gallery-grid-5 {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 768px) {
  .gallery-hero {
    min-height: 380px;
    padding: 105px 0 60px 0;
    background-position: center right;
  }

  .gallery-hero-title {
    font-size: 2.2rem;
  }

  .gallery-grid-5 {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  .gallery-cta-card {
    flex-direction: column;
    align-items: stretch;
    padding: 20px;
    text-align: center;
  }

  .gallery-cta-left {
    flex-direction: column;
  }

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

@media (max-width: 520px) {
  .gallery-grid-5 {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  .gallery-filter-bar {
    gap: 6px;
  }

  .gallery-filter-btn {
    padding: 6px 12px;
    font-size: 0.75rem;
  }

  .category-heading {
    font-size: 1.1rem;
  }
}
