/* ============================================================
   360 Her Yerde — Tam ekran tur sayfası (tur.html)
   sections.css'ten sonra yüklenir (token'lar + viewer__card/lightbox
   ve viewer__spinner stillerini oradan alır).
   ============================================================ */

html, body { height: 100%; }
body.tour-page {
  margin: 0;
  background: #000;
  overflow: hidden;
  overscroll-behavior: none;
}

/* Tam ekran tuval kapsayıcısı */
.tour {
  position: fixed;
  inset: 0;
  background: #060605;
  user-select: none;
}
.tour__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
  cursor: grab;
  filter: contrast(1.04) saturate(1.06) brightness(1.02);
}
.tour.is-dragging .tour__canvas { cursor: grabbing; }

/* Hotspot / ok katmanı */
.tour__hotspots {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}

/* ---- Zemin halkaları (Matterport tarzı, yere basan elips) ---- */
.tour__arrow {
  position: absolute;
  z-index: 5;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  border-radius: 50%;
  cursor: pointer;
  pointer-events: auto;
  color: rgba(242, 240, 232, 0.95);
  background: rgba(242, 240, 232, 0.14);
  border: 3px solid rgba(242, 240, 232, 0.85);
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
  opacity: 0;
  transition: opacity 0.3s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease), transform 0.12s var(--ease);
}
.tour__arrow.is-shown { opacity: 1; }
.tour__arrow svg {
  width: 22px; height: 22px;
  fill: none; stroke: currentColor; stroke-width: 2.6;
  stroke-linecap: round; stroke-linejoin: round;
}
.tour__arrow.is-fwd { width: 92px; height: 42px; }
.tour__arrow.is-back { width: 62px; height: 30px; border-width: 2px; opacity: 0; background: rgba(242, 240, 232, 0.10); border-color: rgba(242, 240, 232, 0.6); }
.tour__arrow.is-back.is-shown { opacity: 0.85; }
.tour__arrow.is-back svg { width: 17px; height: 17px; }
.tour__arrow:hover {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--on-orange);
}
.tour__arrow.is-fwd.is-shown { animation: tourPulse 2.6s ease-out infinite; }
.tour__arrow:hover { animation: none; }
@keyframes tourPulse {
  0% { box-shadow: 0 0 0 0 rgba(225, 102, 58, 0.45); }
  70% { box-shadow: 0 0 0 18px rgba(225, 102, 58, 0); }
  100% { box-shadow: 0 0 0 0 rgba(225, 102, 58, 0); }
}

/* Bilgi pill (mekân/sahne adı) */
.tour__arrow.is-info {
  width: auto; height: auto;
  padding: 8px 16px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ivory);
  background: rgba(10, 10, 8, 0.6);
}
.tour__arrow.is-info:hover { color: var(--on-orange); }

/* Zemin yön okunun altındaki oda/hedef etiketi */
.tour__arrow-label {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  margin-top: 5px;
  background: rgba(20, 22, 26, 0.92);
  color: #f2f0e8;
  font-family: Archivo, system-ui, sans-serif;
  font-size: 0.70rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
  pointer-events: none;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.12);
  letter-spacing: 0.02em;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.tour__arrow:hover .tour__arrow-label {
  background: var(--orange);
  color: #fff;
  border-color: var(--orange);
  transform: translateX(-50%) translateY(2px);
}

/* ---- Üst bar ---- */
.tour__bar {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  pointer-events: none;
}
.tour__bar > * { pointer-events: auto; }
.tour__back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ivory);
  background: rgba(10, 10, 8, 0.55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(242, 240, 232, 0.22);
  border-radius: 999px;
  text-decoration: none;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease);
}
.tour__back:hover { border-color: var(--orange); color: var(--orange); }
.tour__title {
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ivory);
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.6);
}
.tour__spacer { flex: 1; }
.tour__tool {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  color: var(--ivory);
  background: rgba(10, 10, 8, 0.55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(242, 240, 232, 0.22);
  border-radius: 50%;
  cursor: pointer;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease), background 0.3s var(--ease);
}
.tour__tool:hover, .tour__tool[aria-expanded="true"], .tour__tool[aria-pressed="true"] {
  border-color: var(--orange);
  color: var(--orange);
}
.tour__tool svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Alt araç çubuğu (sol alt) — Matterport tarzı yuvarlak butonlar */
.tour__tools {
  position: absolute;
  left: 20px;
  bottom: 24px;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 10px;
}
/* Sağ alt bilgi butonu */
.tour__info {
  position: absolute;
  right: 20px;
  bottom: 24px;
  z-index: 6;
}
.tour__info svg { width: 17px; height: 17px; }

/* Sahne adı rozeti (alt orta) */
.tour__scene {
  position: absolute;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 18px;
  background: rgba(10, 10, 8, 0.6);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(242, 240, 232, 0.18);
  border-radius: 999px;
  pointer-events: none;
  white-space: nowrap;
}
.tour__scene b { font-size: 0.88rem; font-weight: 600; color: var(--ivory); letter-spacing: 0.04em; }
.tour__scene span { font-size: 0.72rem; color: var(--muted); letter-spacing: 0.1em; }

/* Sahne rozeti + önceki/sonraki okları (alt orta) */
.tour__navwrap {
  position: absolute;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 8px;
}
.tour__navwrap .tour__scene {
  position: static;
  left: auto;
  bottom: auto;
  transform: none;
}
.tour__navbtn {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  color: var(--ivory);
  background: rgba(10, 10, 8, 0.6);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(242, 240, 232, 0.22);
  border-radius: 50%;
  cursor: pointer;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease), opacity 0.3s var(--ease);
}
.tour__navbtn svg {
  width: 17px; height: 17px;
  fill: none; stroke: currentColor; stroke-width: 2;
  stroke-linecap: round; stroke-linejoin: round;
}
.tour__navbtn:hover { border-color: var(--orange); color: var(--orange); }
.tour__navbtn:disabled { opacity: 0.28; cursor: default; border-color: rgba(242, 240, 232, 0.14); color: var(--muted); }

/* Sağ alt: Google Maps tarzı zoom butonları */
.tour__zoom {
  position: absolute;
  right: 20px;
  bottom: 76px;
  z-index: 6;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.tour__zoom-btn { width: 40px; height: 40px; }

/* Sahne menüsü (sol alt çubuğun üstünde açılır) */
.tour__menu {
  position: absolute;
  left: 20px;
  bottom: 78px;
  z-index: 7;
  width: 230px;
  max-height: calc(100% - 210px);
  overflow-y: auto;
  padding: 8px;
  background: rgba(10, 10, 8, 0.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line);
  border-radius: 14px;
}
.tour__menu[hidden] { display: none; }
.tour__menu-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 9px 12px;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(242, 240, 232, 0.82);
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.tour__menu-item:hover { background: rgba(242, 240, 232, 0.08); color: var(--ivory); }
.tour__menu-item.is-active { background: var(--orange); color: var(--on-orange); }

/* İpucu (alt çubuğun üstünde) */
.tour__hint {
  position: absolute;
  left: 20px;
  bottom: 78px;
  z-index: 5;
  padding: 8px 15px;
  background: rgba(10, 10, 8, 0.55);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(242, 240, 232, 0.16);
  border-radius: 999px;
  font-size: 0.76rem;
  color: rgba(242, 240, 232, 0.82);
  pointer-events: none;
  transition: opacity 0.5s var(--ease), visibility 0.5s var(--ease);
}
.tour__hint.is-hidden { opacity: 0; visibility: hidden; }

/* Proje Açılış Yükleyicisi — Süreç ve İlerleme Göstergeli */
#tour-loader {
  position: absolute;
  inset: 0;
  z-index: 25;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #15171a;
  color: #f2f0e8;
  transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.65s ease;
}
#tour-loader.is-done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.viewer__loader-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 320px;
  width: 86%;
  gap: 12px;
}
.viewer__loader-brand {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--orange);
  text-transform: uppercase;
}
#tour-loader .viewer__spinner {
  width: 36px;
  height: 36px;
  border-width: 3px;
  border-color: rgba(225, 102, 58, 0.22);
  border-top-color: var(--orange);
  margin: 4px 0;
}
.viewer__loader-title {
  font-size: 1.18rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
}
.viewer__loader-bar-wrap {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  overflow: hidden;
  margin: 4px 0 2px;
}
.viewer__loader-bar {
  width: 12%;
  height: 100%;
  background: linear-gradient(90deg, var(--orange), #ff9a6c);
  border-radius: 999px;
  transition: width 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}
.viewer__loader-step {
  font-size: 0.80rem;
  color: #9ba0a6;
  font-weight: 500;
  min-height: 1.4em;
  letter-spacing: 0.01em;
}

/* ---- 3B İMMOVİEWER BİNA & KAT PLANI GÖRÜNÜMÜ ---- */
.tour__doll {
  position: absolute;
  inset: 0;
  z-index: 9;
  background: #25272a;               /* İmmoviewer stüdyo koyu füme zemin */
  overflow: hidden;
  cursor: grab;
  opacity: 1;
  transition: opacity 0.24s ease;
}
.tour__doll.is-closing {
  opacity: 0;
  pointer-events: none;
}
.tour__doll.is-dragging { cursor: grabbing; }
.tour__doll[hidden] { display: none; }
.tour__doll-stage {
  position: absolute;
  inset: 0;
  touch-action: none;
}
.tour__doll-3d {
  position: absolute;
  inset: 0;
}
.tour__doll-3d canvas {
  width: 100%;
  height: 100%;
  display: block;
}
.tour__doll-pins {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* Sol Üst: İmmoviewer Rooms (Odalar) Paneli */
.tour__doll-rooms {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 6;
  width: 200px;
  background: rgba(24, 26, 30, 0.94);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  font-family: Archivo, system-ui, sans-serif;
  transition: max-height 0.3s ease;
}
.tour__doll-rooms-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  background: rgba(34, 37, 42, 0.9);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #e2e4e8;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.tour__doll-rooms-toggle {
  background: transparent;
  border: none;
  color: #9ba0a6;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  padding: 0 4px;
}
.tour__doll-search-wrap {
  position: relative;
  padding: 7px 9px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.tour__doll-search {
  width: 100%;
  background: #15171a;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  padding: 5px 8px 5px 25px;
  color: #fff;
  font-size: 0.74rem;
  font-family: inherit;
}
.tour__doll-search:focus { outline: none; border-color: #00b0ff; }
.tour__doll-search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  fill: none;
  stroke: #8a8f96;
  stroke-width: 2.2;
  pointer-events: none;
}
.tour__doll-room-list {
  list-style: none;
  margin: 0;
  padding: 4px;
  max-height: 230px;
  overflow-y: auto;
}
.tour__doll-room-item {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  text-align: left;
  padding: 6px 8px;
  border: none;
  background: transparent;
  color: #c4c7cc;
  border-radius: 6px;
  font-size: 0.76rem;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.tour__doll-room-item:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}
.tour__doll-room-item.is-active {
  background: rgba(225, 102, 58, 0.18);
  color: var(--orange-2);
  font-weight: 600;
}
.tour__doll-room-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--orange);
  flex-shrink: 0;
}

/* Üst Orta: [ 2D | 3D ] Mod Seçici (İmmoviewer Tarzı) */
.tour__doll-modes {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px 4px;
  background: rgba(24, 26, 30, 0.92);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}
.tour__doll-mode {
  padding: 5px 14px;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: #9ba0a6;
  font: 600 0.84rem Archivo, system-ui, sans-serif;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.2s ease;
}
.tour__doll-mode:hover { color: #ffffff; }
.tour__doll-mode.is-active {
  background: #17181c;
  color: var(--orange-2);           /* 360 Her Yerde turuncu vurgusu */
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

/* Sağ Üst Kapat Butonu */
.tour__doll-close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 6;
}

/* Sağ Alt Kontroller */
.tour__doll-controls {
  position: absolute;
  right: 18px;
  bottom: 24px;
  z-index: 6;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.tour__doll-ctrl {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: rgba(24, 26, 30, 0.88);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  color: #e2e4e8;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  transition: all 0.2s ease;
}
.tour__doll-ctrl svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.2; }
.tour__doll-ctrl:hover { border-color: #00b0ff; color: #00b0ff; }

/* Alt Açılış / Girişe İniş Bildirimi */
.tour__doll-intro-pill {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: rgba(20, 22, 26, 0.94);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(225, 102, 58, 0.4);
  border-radius: 999px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.55);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 500;
  pointer-events: auto;
  white-space: nowrap;
}
.tour__doll-intro-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--orange-2);
  box-shadow: 0 0 10px var(--orange);
  animation: dollIntroPulse 1.4s infinite;
}
@keyframes dollIntroPulse {
  0% { transform: scale(0.9); opacity: 0.8; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.8; }
}
.tour__doll-intro-dive {
  padding: 4px 12px;
  border-radius: 999px;
  border: none;
  background: var(--orange);
  color: #fff;
  font: 700 0.72rem Archivo, system-ui, sans-serif;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}
.tour__doll-intro-dive:hover {
  background: var(--orange-2);
  transform: scale(1.04);
}

/* Sahne pinleri (site turuncusu) */
.tour__doll-pin {
  position: absolute;
  width: 14px;
  height: 14px;
  padding: 0;
  border-radius: 50%;
  border: 2px solid #ffffff;
  background: var(--orange);           /* 360 Her Yerde turuncusu */
  cursor: pointer;
  pointer-events: auto;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 3px rgba(225, 102, 58, 0.40), 0 2px 6px rgba(0, 0, 0, 0.6);
  transition: transform 0.18s var(--ease), background 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.tour__doll-pin i { display: none; } /* Numarayı gizle, saf turuncu nokta yap */
.tour__doll-pin:hover {
  background: #ffffff;
  border-color: var(--orange);
  transform: translate(-50%, -50%) scale(1.6);
  box-shadow: 0 0 0 5px rgba(225, 102, 58, 0.55), 0 3px 10px rgba(0, 0, 0, 0.7);
  z-index: 20;
}
.tour__doll-pin.is-active {
  background: var(--orange-2);
  border-color: #ffffff;
  transform: translate(-50%, -50%) scale(1.4);
  box-shadow: 0 0 0 6px rgba(240, 122, 77, 0.45), 0 2px 8px rgba(0, 0, 0, 0.6);
  z-index: 15;
}
.tour__doll-pin span {
  position: absolute;
  bottom: calc(100% + 7px);
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(18, 20, 24, 0.94);
  border: 1px solid rgba(225, 102, 58, 0.5);
  color: #fff;
  font: 600 11px Archivo, system-ui, sans-serif;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  transition: opacity 0.15s ease;
}
.tour__doll-pin:hover span,
.tour__doll-pin.is-active span {
  opacity: 1;
}

/* Küçük ekran */
@media (max-width: 640px) {
  .tour__bar { padding: 12px 14px; gap: 10px; }
  .tour__title { font-size: 0.86rem; }
  .tour__arrow.is-fwd { width: 80px; height: 37px; }
  .tour__arrow.is-back { width: 54px; height: 26px; }
  .tour__arrow svg { width: 19px; height: 19px; }
  .tour__hint { left: 14px; right: 14px; bottom: 66px; text-align: center; }
  .tour__navwrap { top: 62px; bottom: auto; gap: 6px; }
  .tour__navbtn { width: 34px; height: 34px; }
  .tour__zoom { right: 14px; bottom: 108px; gap: 6px; }
  .tour__zoom-btn { width: 36px; height: 36px; }
  .tour__menu { left: 12px; right: 12px; bottom: 66px; width: auto; max-height: calc(100% - 200px); }
  .tour__tools { left: 14px; bottom: 14px; gap: 8px; }
  .tour__tools .tour__tool { width: 38px; height: 38px; }
  .tour__info { right: 14px; bottom: 14px; width: 38px; height: 38px; }
  .tour__doll-pin { width: 28px; height: 28px; font-size: 11px; }
  .tour__doll-header { top: 10px; left: 12px; right: 12px; flex-wrap: wrap; gap: 8px; }
  .tour__doll-brand { order: 1; }
  .tour__doll-close { order: 2; width: 34px; height: 34px; }
  .tour__doll-modes { order: 3; width: 100%; justify-content: center; padding: 2px; }
  .tour__doll-mode { padding: 5px 12px; font-size: 0.72rem; }
  .tour__doll-controls { right: 12px; bottom: 16px; gap: 6px; }
  .tour__doll-ctrl { width: 34px; height: 34px; }
  .tour__doll-note { bottom: 14px; left: 12px; transform: none; font-size: 0.68rem; padding: 6px 12px; max-width: calc(100% - 65px); white-space: normal; }
}
