/* ==========================================================================
   IŞIK KUTUSU (lightbox) — ORTAK
   Hem site hem panel yükler. Pencerenin HTML'i isik-kutusu.js'ten üretilir.
   Panelde site değişkenleri (--bo-*, --yazi-*) olmadığı için bu dosyada
   sabit ölçüler kullanılıyor.
   ========================================================================== */

.isik-kutusu {
  position: fixed; inset: 0;
  background: rgba(14, 16, 19, .94);
  z-index: 200;                       /* panel üst çubuğu ve pencerelerin üstünde */
  display: flex; align-items: center; justify-content: center;
  padding: 40px 56px;
  /* Sürüklenirken metin seçilmesin */
  user-select: none; -webkit-user-select: none;
  touch-action: pan-y;
  cursor: grab;
}
.isik-kutusu[hidden] { display: none; }
.isik-kutusu.surukleniyor { cursor: grabbing; }

/* Pencere açıkken arka plan kaymasın */
html.isik-acik { overflow: hidden; }

.ik-govde {
  margin: 0;
  width: 100%; max-width: 100%; max-height: 100%;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}

/* --- Akışkan şerit (20 Ağu) ------------------------------------------------
   Fotoğraflar arasında ani geçiş yerine kayarak geçiş. Şerit üç kareden
   oluşur (önceki · şu anki · sonraki) ve normalde -100%'de durur, yani
   ortadaki kare görünür. Parmak/fare sürüklerken şerit anlık takip eder;
   bırakıldığında ya sonraki kareye kayar ya yerine döner.                 */

.ik-pencere {
  width: 100%;
  overflow: hidden;
}

.ik-serit {
  display: flex;
  will-change: transform;
  transform: translate3d(-100%, 0, 0);
}
.ik-serit.akiyor {
  transition: transform .32s cubic-bezier(.22, .61, .36, 1);
}

.ik-kare {
  flex: 0 0 100%;
  display: flex; align-items: center; justify-content: center;
  min-width: 0;
}

.ik-govde img {
  max-width: 100%;
  max-height: 78vh;
  width: auto; height: auto;
  border-radius: 4px;
  object-fit: contain;
  background: rgba(255, 255, 255, .04);
}

/* Hareketi azalt tercihi: kayma olmasın, geçiş anında olsun */
@media (prefers-reduced-motion: reduce) {
  .ik-serit.akiyor { transition: none; }
}
/* Fotoğraf kodu — sayaçtan önce, beyaz ve belirgin (20 Ağu) */
.ik-kod { color: #F6F3EE; font-weight: 700; letter-spacing: .06em; }

.ik-govde figcaption {
  text-align: center;
  font: 500 13px/1.4 ui-monospace, Menlo, Consolas, monospace;
  color: rgba(246, 243, 238, .6);
}

.ik-kapat, .ik-ok {
  position: absolute;
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  border: 0;
  border-radius: 50%;
  background: rgba(246, 243, 238, .12);
  color: #F6F3EE;
  font: 400 26px/1 system-ui, sans-serif;
  cursor: pointer;
  transition: background .18s ease, color .18s ease;
}
.ik-kapat:hover, .ik-ok:hover { background: #E8621B; color: #fff; }
.ik-kapat:focus-visible, .ik-ok:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.ik-ok[hidden] { display: none; }

.ik-kapat { top: 18px; right: 18px; font-size: 30px; }
.ik-geri  { left: 18px;  top: 50%; transform: translateY(-50%); }
.ik-ileri { right: 18px; top: 50%; transform: translateY(-50%); }

@media (max-width: 700px) {
  .isik-kutusu { padding: 28px 12px; }
  .ik-kapat, .ik-ok { width: 44px; height: 44px; font-size: 20px; }
  .ik-kapat { font-size: 24px; top: 12px; right: 12px; }
  .ik-geri  { left: 8px; }
  .ik-ileri { right: 8px; }
  .ik-govde img { max-height: 70vh; }
}

/* Işık kutusu açılabilen fotoğraflar tıklanabilir görünsün */
[data-isik-grup] a[href] { cursor: zoom-in; }


/* --- Büyük video oynatıcı -------------------------------------------------
   Video kartına basınca aynı karanlık pencerede, ekranı kaplayacak kadar
   büyük açılır. 16:9 oranı korunur; hem geniş hem uzun ekranda sığar.    */

.isik-kutusu.ik-video { cursor: default; }

.ik-video-kutu {
  width: min(92vw, calc((88vh - 40px) * 16 / 9));
  aspect-ratio: 16 / 9;
  max-height: 88vh;
  background: #000;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 30px 90px rgba(0, 0, 0, .5);
}
.ik-video-kutu iframe { width: 100%; height: 100%; border: 0; display: block; }

/* Dikey video (Reels/Shorts): oynatıcı da dikey olsun, yoksa 16:9 çerçevede
   yanları kocaman siyah bant kalıyordu (20 Ağu). */
.ik-video-kutu.dikey {
  aspect-ratio: 9 / 16;
  width: min(92vw, calc((88vh - 40px) * 9 / 16));
}

@media (max-width: 700px) {
  .ik-video-kutu { width: 96vw; border-radius: 0; }
}
