/* ==========================================================================
   PREVIEW MODE PAYMENT BANNER & QR MODAL (THEME MATCHED & CLEAN MINIMALIST)
   ========================================================================== */

/* 1. Floating Banner */
.im-preview-banner {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99990;
  width: min(380px, calc(100vw - 32px));
  background: rgba(255, 253, 248, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(201, 165, 93, 0.45);
  border-radius: 20px;
  box-shadow: 0 16px 40px -10px rgba(122, 42, 53, 0.3), 0 4px 16px rgba(0, 0, 0, 0.08);
  padding: 18px 20px 16px;
  box-sizing: border-box;
  font-family: 'Jost', sans-serif;
  color: #4a3832;
  transform: translateY(140%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.5s ease;
}

.im-preview-banner.is-visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.im-preview-banner__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.im-preview-banner__badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(184, 107, 119, 0.12);
  border: 1px solid rgba(184, 107, 119, 0.3);
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #a0344e;
}

.im-preview-banner__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #a0344e;
  box-shadow: 0 0 0 0 rgba(160, 52, 78, 0.7);
  animation: im-pulse-dot 1.8s infinite;
}

@keyframes im-pulse-dot {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(160, 52, 78, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(160, 52, 78, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(160, 52, 78, 0);
  }
}

.im-preview-banner__close {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px;
  margin: -4px -4px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #8c726a;
  border-radius: 50%;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.im-preview-banner__close:hover {
  color: #a0344e;
  background: rgba(184, 107, 119, 0.1);
  transform: scale(1.1);
}

.im-preview-banner__message {
  margin: 0 0 14px;
  font-size: 13.5px;
  line-height: 1.48;
  color: #5c4842;
  font-weight: 400;
}

.im-preview-banner__cta {
  width: 100%;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, #a0344e 0%, #b86b77 100%);
  color: #ffffff;
  padding: 11px 18px;
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 6px 16px -4px rgba(160, 52, 78, 0.45);
  transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
}

.im-preview-banner__cta:hover {
  transform: translateY(-1.5px);
  box-shadow: 0 10px 22px -4px rgba(160, 52, 78, 0.55);
  filter: brightness(1.05);
}

.im-preview-banner__cta:active {
  transform: translateY(0);
}

/* 2. QR Payment Modal */
.im-qr-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.im-qr-modal.is-active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.im-qr-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(35, 18, 22, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.im-qr-modal__dialog {
  position: relative;
  z-index: 1;
  width: min(390px, 94vw);
  background: #fffdf8;
  border: 1px solid rgba(201, 165, 93, 0.5);
  border-radius: 24px;
  box-shadow: 0 25px 60px -15px rgba(92, 14, 26, 0.45);
  padding: 24px 22px 20px;
  box-sizing: border-box;
  text-align: center;
  font-family: 'Jost', sans-serif;
  color: #4a3832;
  transform: scale(0.92) translateY(12px);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.im-qr-modal.is-active .im-qr-modal__dialog {
  transform: scale(1) translateY(0);
}

.im-qr-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(184, 107, 119, 0.08);
  border: none;
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #7a5a54;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.im-qr-modal__close:hover {
  background: rgba(160, 52, 78, 0.15);
  color: #a0344e;
  transform: scale(1.08);
}

.im-qr-modal__eyebrow {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #b8860b;
}

.im-qr-modal__title {
  margin: 0 0 16px;
  font-family: 'Cormorant Garamond', serif;
  font-size: 26px;
  font-weight: 600;
  color: #a0344e;
  line-height: 1.2;
}

/* Framed exact aspect ratio of QR.jpg (649 / 773 = ~0.8396) */
.im-qr-modal__qr-frame {
  margin: 0 auto 16px;
  width: min(270px, 72vw);
  aspect-ratio: 649 / 773;
  background: #ffffff;
  border: 1px solid rgba(201, 165, 93, 0.35);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 24px -6px rgba(122, 42, 53, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
}

.im-qr-modal__qr-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.im-qr-modal__whatsapp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 11px 18px;
  background: #25d366;
  color: #ffffff;
  text-decoration: none;
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 999px;
  box-sizing: border-box;
  box-shadow: 0 6px 18px -4px rgba(37, 211, 102, 0.45);
  transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
}

.im-qr-modal__whatsapp-btn:hover {
  transform: translateY(-1.5px);
  box-shadow: 0 10px 24px -4px rgba(37, 211, 102, 0.55);
  filter: brightness(1.04);
}

.im-qr-modal__note {
  margin: 12px 0 0;
  font-size: 12.5px;
  line-height: 1.48;
  color: #7a655f;
  font-weight: 400;
}

/* 3. Mobile Responsiveness */
@media (max-width: 600px) {
  .im-preview-banner {
    bottom: 16px;
    right: 16px;
    left: 16px;
    width: auto;
    padding: 16px 16px 14px;
    border-radius: 18px;
  }

  .im-preview-banner__message {
    font-size: 13px;
    margin-bottom: 12px;
  }

  .im-qr-modal__dialog {
    padding: 22px 18px 18px;
    border-radius: 20px;
  }

  .im-qr-modal__qr-frame {
    width: min(240px, 68vw);
  }
}

