/* ═══════════════════════════════════════════════════════════
   gallery.css — Cinematic slider · Ken Burns · Film strip
   Manish & Arjoo  ·  26 April 2026
═══════════════════════════════════════════════════════════ */

/* ── Section ── */
.gallery-section {
  padding: 100px 0 0;
  background: linear-gradient(160deg, #FEF8EE 0%, #FFFAF3 60%, #FEF6E8 100%);
  overflow: hidden;
}
.gallery-section .container { max-width: 1200px; }

/* ── Slider wrapper ── */
.g-slider { position: relative; user-select: none; }

/* ══════════════════════════════════════
   MAIN STAGE
══════════════════════════════════════ */
.g-stage {
  position: relative;
  height: 56vh;
  min-height: 380px;
  max-height: 600px;
  overflow: hidden;
  border-radius: 16px;
  box-shadow:
    0 30px 80px rgba(42,8,69,.22),
    0 0 0 1px rgba(201,164,71,.3);
  background: #1a0030;
}

/* slides stack */
.g-slides { position: absolute; inset: 0; }

.g-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1.1s cubic-bezier(.4,0,.2,1);
  z-index: 1;
}
.g-slide.active  { opacity: 1; z-index: 2; }
.g-slide.leaving { opacity: 0; z-index: 1; }

/* ── Ken Burns on the image ── */
.g-img {
  width: 100%; height: 100%;
  object-fit: contain;        /* show full portrait photo — no cropping */
  object-position: center;
  display: block;
  transform-origin: center;
  will-change: transform;
}
/* 4 KB variants cycle round-robin */
.g-slide.active .g-img.kb-1 { animation: kb1 9s ease-in-out forwards; }
.g-slide.active .g-img.kb-2 { animation: kb2 9s ease-in-out forwards; }
.g-slide.active .g-img.kb-3 { animation: kb3 9s ease-in-out forwards; }
.g-slide.active .g-img.kb-4 { animation: kb4 9s ease-in-out forwards; }

@keyframes kb1 {
  0%   { transform: scale(1)    translate(0,    0); }
  100% { transform: scale(1.12) translate(-2%,  -1.5%); }
}
@keyframes kb2 {
  0%   { transform: scale(1.1)  translate(2%,   1%); }
  100% { transform: scale(1)    translate(-1%, -0.5%); }
}
@keyframes kb3 {
  0%   { transform: scale(1.06) translate(-3%,  0); }
  100% { transform: scale(1.1)  translate(2%,  -1%); }
}
@keyframes kb4 {
  0%   { transform: scale(1.08) translate(2%,  -1%); }
  100% { transform: scale(1)    translate(-2%,  1%); }
}

/* ── Dark gradient overlay (bottom) ── */
.g-stage::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgba(20,0,40,.7) 0%, transparent 45%),
    linear-gradient(to bottom, rgba(20,0,40,.25) 0%, transparent 35%);
  pointer-events: none;
  z-index: 3;
}

/* ── Gold corner ornaments ── */
.g-corners { position: absolute; inset: 18px; pointer-events: none; z-index: 5; }
.gc {
  position: absolute;
  color: var(--gold);
  font-size: 1.3rem;
  opacity: .7;
  line-height: 1;
}
.gc.tl { top: 0;  left: 0;  }
.gc.tr { top: 0;  right: 0; }
.gc.bl { bottom: 0; left: 0; }
.gc.br { bottom: 0; right: 0; }

/* ── Photo counter ── */
.g-counter {
  position: absolute;
  bottom: 22px;
  right: 26px;
  z-index: 6;
  display: flex;
  align-items: baseline;
  gap: 4px;
  font-family: var(--ff-disp);
  letter-spacing: .12em;
}
.g-curr { font-size: 2rem; color: var(--gold-lt); font-weight: 700; line-height: 1; }
.g-sep  { font-size: .9rem; color: rgba(255,255,255,.4); }
.g-total{ font-size: .9rem; color: rgba(255,255,255,.5); }

/* ── Caption slot (bottom-left) ── */
.g-caption {
  position: absolute;
  bottom: 22px;
  left: 26px;
  z-index: 6;
  font-family: var(--ff-disp);
  font-size: .62rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(255,255,255,.55);
}

/* ── Arrows ── */
.g-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 7;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(201,164,71,.4);
  backdrop-filter: blur(6px);
  color: var(--gold-lt);
  font-size: 1.8rem;
  width: 52px; height: 52px;
  border-radius: 50%;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all .3s;
  line-height: 1;
}
.g-arrow:hover {
  background: rgba(201,164,71,.22);
  border-color: var(--gold);
  transform: translateY(-50%) scale(1.08);
}
.g-prev { left: 18px; }
.g-next { right: 18px; }
.g-arrow:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

/* ── Expand / fullscreen ── */
.g-expand {
  position: absolute;
  top: 18px;
  right: 22px;
  z-index: 7;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(201,164,71,.35);
  backdrop-filter: blur(6px);
  color: var(--gold-lt);
  font-size: 1rem;
  width: 38px; height: 38px;
  border-radius: 8px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all .3s;
}
.g-expand:hover { background: rgba(201,164,71,.22); border-color: var(--gold); }

/* ── Progress bar ── */
.g-progress {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  background: rgba(255,255,255,.12);
  z-index: 8;
}
.g-progress-bar {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--gold-dk), var(--gold), var(--gold-lt));
  transition: width linear;
}

/* ══════════════════════════════════════
   DOT NAVIGATION
══════════════════════════════════════ */
.g-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 18px 0 14px;
}
.g-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(74,20,114,.25);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: all .35s;
}
.g-dot.active {
  background: var(--gold);
  transform: scale(1.4);
  box-shadow: 0 0 8px rgba(201,164,71,.6);
}
.g-dot:hover:not(.active) { background: var(--lav); transform: scale(1.2); }

/* ══════════════════════════════════════
   FILM STRIP
══════════════════════════════════════ */
.g-strip-wrap {
  overflow: hidden;
  padding: 0 0 48px;
  position: relative;
}
.g-strip-wrap::before,
.g-strip-wrap::after {
  content: '';
  position: absolute;
  top: 0; bottom: 48px;
  width: 80px;
  z-index: 2;
  pointer-events: none;
}
.g-strip-wrap::before {
  left: 0;
  background: linear-gradient(to right, #FEF8EE, transparent);
}
.g-strip-wrap::after {
  right: 0;
  background: linear-gradient(to left, #FEF6E8, transparent);
}

.g-strip {
  display: flex;
  gap: 10px;
  padding: 4px 60px;
  transition: transform .5s cubic-bezier(.4,0,.2,1);
  will-change: transform;
}

.g-thumb {
  flex-shrink: 0;
  width: 90px;
  height: 68px;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all .35s;
  opacity: .55;
  position: relative;
}
.g-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s;
}
.g-thumb:hover { opacity: .85; transform: translateY(-3px); }
.g-thumb:hover img { transform: scale(1.08); }
.g-thumb.active {
  border-color: var(--gold);
  opacity: 1;
  transform: translateY(-4px);
  box-shadow: 0 6px 20px rgba(201,164,71,.4);
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .g-stage {
    height: auto;
    min-height: unset;
    max-height: unset;
    aspect-ratio: 4 / 3;
    border-radius: 10px;
  }
  .g-img { object-fit: contain; }
  .g-arrow { width: 40px; height: 40px; font-size: 1.4rem; }
  .g-curr { font-size: 1.5rem; }
  .g-thumb { width: 68px; height: 52px; }
}
@media (max-width: 480px) {
  .g-stage { aspect-ratio: 3 / 2; }
  .g-counter { bottom: 14px; right: 14px; }
  .g-caption { display: none; }
  .g-arrow { display: none; }
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  .g-slide { transition: opacity .3s; }
  .g-img   { animation: none !important; }
}
