/* ═══════════════════════════════════════════════════════════════
   THE ULTIMATE BEAUTY — JOTFORM LIGHTBOX
   Elegáns felugró ablak a JotForm űrlapokhoz
   ═══════════════════════════════════════════════════════════════ */

/* ─── OVERLAY ──────────────────────────────────────────────── */
.jf-lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(15, 12, 8, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
  padding: 20px;
}

.jf-lightbox-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ─── MODAL BOX ────────────────────────────────────────────── */
.jf-lightbox-box {
  position: relative;
  width: 100%;
  max-width: 620px;
  max-height: 90vh;
  background: #FDFAF6;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,0.4), 0 0 0 1px rgba(184, 150, 90, 0.15);
  transform: translateY(30px) scale(0.97);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.jf-lightbox-overlay.active .jf-lightbox-box {
  transform: translateY(0) scale(1);
}

/* ─── HEADER ───────────────────────────────────────────────── */
.jf-lightbox-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 16px;
  border-bottom: 1px solid rgba(184, 150, 90, 0.15);
  flex-shrink: 0;
}

.jf-lightbox-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 500;
  color: #2C2824;
  margin: 0;
  letter-spacing: 0.01em;
}

.jf-lightbox-close {
  width: 36px;
  height: 36px;
  border: none;
  background: rgba(44, 40, 36, 0.06);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.2s;
  flex-shrink: 0;
}

.jf-lightbox-close:hover {
  background: rgba(44, 40, 36, 0.12);
  transform: scale(1.1);
}

.jf-lightbox-close svg {
  width: 18px;
  height: 18px;
  stroke: #2C2824;
  stroke-width: 2;
}

/* ─── IFRAME CONTAINER ─────────────────────────────────────── */
.jf-lightbox-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  min-height: 400px;
  max-height: calc(90vh - 72px);
}

.jf-lightbox-body iframe {
  width: 100%;
  min-height: 700px;
  border: none;
  display: block;
}

/* ─── LOADING STATE ────────────────────────────────────────── */
.jf-lightbox-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 300px;
  color: #B8965A;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.jf-lightbox-loading::after {
  content: '';
  width: 20px;
  height: 20px;
  border: 2px solid rgba(184, 150, 90, 0.2);
  border-top-color: #B8965A;
  border-radius: 50%;
  animation: jf-spin 0.8s linear infinite;
  margin-left: 12px;
}

@keyframes jf-spin {
  to { transform: rotate(360deg); }
}

/* ─── CTA TRIGGER BUTTONS ──────────────────────────────────── */
.jf-trigger-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 32px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-decoration: none;
  color: #FDFAF6;
  background: #B8965A;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
}

.jf-trigger-btn:hover {
  background: #a3834d;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(184, 150, 90, 0.3);
}

.jf-trigger-btn--outline {
  background: transparent;
  color: #B8965A;
  border: 1.5px solid rgba(184, 150, 90, 0.4);
}

.jf-trigger-btn--outline:hover {
  background: rgba(184, 150, 90, 0.08);
  border-color: #B8965A;
}

.jf-trigger-btn--large {
  padding: 18px 40px;
  font-size: 0.9rem;
}

/* On dark backgrounds */
.jf-trigger-btn--light {
  color: #B8965A;
  background: #FDFAF6;
}

.jf-trigger-btn--light:hover {
  background: #F5F0E8;
}

/* ─── RESPONSIVE ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .jf-lightbox-overlay {
    padding: 10px;
    align-items: flex-end;
  }

  .jf-lightbox-box {
    max-height: 95vh;
    max-width: 100%;
    border-radius: 16px 16px 0 0;
    transform: translateY(100%);
  }

  .jf-lightbox-overlay.active .jf-lightbox-box {
    transform: translateY(0);
  }

  .jf-lightbox-body {
    max-height: calc(95vh - 72px);
  }

  .jf-lightbox-body iframe {
    min-height: 600px;
  }

  .jf-trigger-btn {
    padding: 14px 24px;
    font-size: 0.8rem;
    width: 100%;
    justify-content: center;
  }
}
