/* ============================================================
   BUDAPEST FREE TOUR — TRUST, GUIDES, GALLERY & PROMO VIDEO
   Seamless CRO & Editorial Layer (Desktop + Mobile)
   ============================================================ */

/* --- 1. ABOUT OUR LOCAL GUIDES (#about-guides) --- */
#about-guides.bft-guides-section {
  position: relative;
  background: var(--bft-black, #090909) !important;
  color: #ffffff !important;
  padding: clamp(82px, 8.5vw, 138px) 0 !important;
  overflow: clip;
  isolation: isolate;
}

#about-guides.bft-guides-section::before {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(206, 41, 57, 0.12) 0%, rgba(206, 41, 57, 0) 70%);
  left: -180px;
  bottom: -180px;
  pointer-events: none;
  z-index: 0;
}

#about-guides .bft-guides-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: clamp(34px, 5vw, 76px);
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
}

/* White-outlined square/editorial frame requested by user */
#about-guides .bft-guides-box {
  position: relative;
  border: 1.5px solid rgba(255, 255, 255, 0.88);
  border-radius: 22px;
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
  padding: clamp(28px, 4.2vw, 56px);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.48);
}

#about-guides .bft-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
  margin-bottom: 18px;
}

#about-guides .bft-eyebrow::before {
  content: "";
  display: inline-block;
  width: 28px;
  height: 2px;
  background: var(--bft-red, #CE2939);
}

#about-guides .bft-guides-box h2 {
  color: #ffffff !important;
  font-size: clamp(28px, 3.3vw, 46px) !important;
  line-height: 1.08 !important;
  letter-spacing: -0.025em !important;
  margin: 0 0 22px !important;
  text-wrap: balance;
}

#about-guides .bft-guides-copy p {
  color: rgba(255, 255, 255, 0.82) !important;
  font-size: clamp(16px, 1.15vw, 18.5px);
  line-height: 1.72;
  margin: 0 0 16px;
}

#about-guides .bft-guides-copy p.bft-guides-highlight {
  color: #ffffff !important;
  font-weight: 600;
  font-size: clamp(17px, 1.2vw, 19.5px);
  margin-top: 20px;
  margin-bottom: 0;
  padding-left: 16px;
  border-left: 3px solid var(--bft-red, #CE2939);
}

#about-guides .bft-guides-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

#about-guides .bft-guides-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
}

#about-guides .bft-guides-pill svg {
  width: 15px;
  height: 15px;
  stroke: var(--bft-red, #CE2939);
  fill: none;
  stroke-width: 2.2;
  flex-shrink: 0;
}

#about-guides .bft-guides-media {
  position: relative;
  margin: 0;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  background: #141414;
}

#about-guides .bft-guides-media img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center 22%;
  display: block;
  transition: transform 0.7s var(--bft-ease, ease);
}

#about-guides .bft-guides-media:hover img {
  transform: scale(1.025);
}

#about-guides .bft-guides-caption {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(9, 9, 9, 0.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.4;
  display: flex;
  align-items: center;
  gap: 10px;
}

#about-guides .bft-guides-caption-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--bft-red, #CE2939);
  flex-shrink: 0;
}


/* --- 2. TOUR & TRAVELERS GALLERY (#tour-moments) --- */
#tour-moments.bft-moments-section {
  background: #ffffff !important;
  color: var(--bft-ink, #121212) !important;
  padding: clamp(80px, 8vw, 136px) 0 !important;
  border-top: 1px solid rgba(18, 18, 18, 0.08);
  border-bottom: 1px solid rgba(18, 18, 18, 0.08);
}

#tour-moments .bft-moments-header {
  max-width: 860px;
  margin: 0 auto clamp(42px, 5vw, 64px);
  text-align: center;
}

#tour-moments .bft-moments-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--bft-red, #CE2939);
  margin-bottom: 14px;
}

#tour-moments .bft-moments-header h2 {
  color: var(--bft-ink, #121212) !important;
  font-size: clamp(32px, 4.4vw, 62px) !important;
  line-height: 1.04 !important;
  letter-spacing: -0.025em !important;
  margin: 0 0 20px !important;
  text-wrap: balance;
}

#tour-moments .bft-moments-header p {
  color: #4b4946 !important;
  font-size: clamp(16.5px, 1.25vw, 20px);
  line-height: 1.65;
  margin: 0 auto;
  max-width: 780px;
}

#tour-moments .bft-moments-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 1.8vw, 22px);
  max-width: 1320px;
  margin: 0 auto;
}

#tour-moments .bft-moment-card {
  position: relative;
  margin: 0;
  border-radius: 18px;
  overflow: hidden;
  background: #f0ede8;
  aspect-ratio: 4 / 3;
  cursor: zoom-in;
  box-shadow: 0 12px 32px rgba(12, 10, 8, 0.07);
  border: 1px solid rgba(18, 18, 18, 0.07);
}

#tour-moments .bft-moment-card picture,
#tour-moments .bft-moment-card img {
  width: 100%;
  height: 100%;
  display: block;
}

#tour-moments .bft-moment-card img {
  object-fit: cover;
  object-position: var(--focus, center 28%);
  transition: transform 0.65s var(--bft-ease, ease), filter 0.4s ease;
}

#tour-moments .bft-moment-card:hover img {
  transform: scale(1.05);
}

#tour-moments .bft-moment-caption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 28px 16px 14px;
  background: linear-gradient(to top, rgba(9, 9, 9, 0.82) 0%, rgba(9, 9, 9, 0.38) 62%, rgba(9, 9, 9, 0) 100%);
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.35;
  opacity: 0.94;
  transition: opacity 0.3s ease;
}

#tour-moments .bft-moments-cta {
  text-align: center;
  margin-top: clamp(34px, 4vw, 52px);
}

#tour-moments .bft-moments-cta .btn-primary {
  background: var(--bft-black, #090909) !important;
  color: #ffffff !important;
  border-radius: 999px !important;
  padding: 15px 34px !important;
  font-size: 16px !important;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.16);
}

#tour-moments .bft-moments-cta .btn-primary:hover {
  background: var(--bft-red, #CE2939) !important;
  transform: translateY(-2px);
}


/* --- 3. PROMO VIDEO SECTION ABOVE BOOKING (#tour-video — EN & ES ONLY) --- */
#tour-video.bft-video-section {
  background: var(--bft-black, #090909) !important;
  color: #ffffff !important;
  padding: clamp(36px, 4.5vh, 60px) 0 !important;
  overflow: hidden;
  max-height: 1200px;
  opacity: 1;
  transition: opacity 0.55s ease, max-height 0.65s cubic-bezier(0.4, 0, 0.2, 1), padding 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}

#tour-video.bft-video-section.is-closing {
  opacity: 0 !important;
  max-height: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  pointer-events: none;
}

#tour-video .bft-video-header {
  max-width: 760px;
  margin: 0 auto clamp(16px, 2.2vh, 26px);
  text-align: center;
}

#tour-video .bft-video-header h2 {
  color: #ffffff !important;
  font-size: clamp(24px, 2.7vw, 38px) !important;
  line-height: 1.08 !important;
  letter-spacing: -0.025em !important;
  margin: 0 0 8px !important;
}

#tour-video .bft-video-header p {
  color: rgba(255, 255, 255, 0.74) !important;
  font-size: clamp(14.5px, 1.05vw, 16.5px);
  line-height: 1.45;
  margin: 0 auto;
}

#tour-video .bft-video-stage {
  position: relative;
  width: clamp(320px, calc((100svh - 270px) * 16 / 9), 740px);
  max-width: 100%;
  margin: 0 auto;
  border-radius: 20px;
  overflow: hidden;
  background: #000000;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 24px 68px rgba(0, 0, 0, 0.6);
  aspect-ratio: 16 / 9;
  cursor: pointer;
  user-select: none;
}

#tour-video .bft-promo-video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  background: #000000;
}

#tour-video .bft-video-sound-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.88);
  background: rgba(9, 9, 9, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #ffffff;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease, opacity 0.2s ease;
}

#tour-video .bft-video-stage:hover .bft-video-sound-btn {
  background: var(--bft-red, #CE2939);
  border-color: var(--bft-red, #CE2939);
  transform: scale(1.04);
}

/* Hide sound button completely once playing with sound */
#tour-video .bft-video-stage.is-active-play .bft-video-sound-btn {
  display: none !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

#tour-video .bft-video-sound-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.2;
  flex-shrink: 0;
}

#tour-video .bft-video-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  background: rgba(255, 255, 255, 0.16);
  z-index: 4;
  opacity: 0;
  transition: opacity 0.25s ease;
}

#tour-video .bft-video-stage.is-active-play .bft-video-progress {
  opacity: 1;
}

#tour-video .bft-video-progress-bar {
  width: 0%;
  height: 100%;
  background: var(--bft-red, #CE2939);
  transition: width 0.15s linear;
}


/* --- LIGHTBOX MODAL FOR GALLERY PHOTOS --- */
.bft-lightbox {
  position: fixed;
  inset: 0;
  z-index: 10050;
  background: rgba(6, 6, 6, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

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

.bft-lightbox img {
  max-width: min(94vw, 1140px);
  max-height: 78vh;
  width: auto;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.65);
  object-fit: contain;
}

.bft-lightbox-caption {
  margin-top: 14px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 15px;
  text-align: center;
  max-width: 720px;
}

.bft-lightbox-close {
  position: absolute;
  top: 20px;
  right: 22px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bft-lightbox-close:hover {
  background: var(--bft-red, #CE2939);
  border-color: var(--bft-red, #CE2939);
}


/* --- RESPONSIVE BREAKPOINTS --- */
@media (max-width: 980px) {
  #about-guides .bft-guides-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  #about-guides .bft-guides-media {
    max-width: 540px;
    margin: 0 auto;
    width: 100%;
  }

  #tour-moments .bft-moments-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  #tour-video.bft-video-section {
    padding: 48px 0 !important;
  }

  #tour-video .bft-video-stage {
    width: 100%;
  }
}

@media (max-width: 600px) {
  #about-guides .bft-guides-box {
    padding: 24px 20px;
    border-radius: 18px;
  }

  #tour-moments .bft-moments-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  #tour-moments .bft-moment-card {
    aspect-ratio: 16 / 11;
  }

  #tour-video .bft-video-sound-btn {
    padding: 8px 13px;
    font-size: 12px;
    top: 10px;
    right: 10px;
    white-space: nowrap;
  }
}
