/* Geeks Ghostwriting — scroll replica of #popupform
   Existing click popup (#popupform) is NOT changed.
   Link this file AFTER style-web.css */

.ggw-scroll-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
  background: rgba(8, 12, 28, 0.72);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

.ggw-scroll-overlay.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.ggw-scroll-overlay .popupform.ggw-scroll-card {
  display: block !important;
  position: relative;
  margin: 0 auto;
  transform: translateY(48px) scale(0.92);
  opacity: 0;
  transition:
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.45s ease;
}

.ggw-scroll-overlay.is-open .popupform.ggw-scroll-card {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.ggw-scroll-close {
  position: absolute;
  top: -12px;
  right: 16px;
  z-index: 5;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: #e10600;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(225, 6, 0, 0.35);
}

.ggw-scroll-close::before,
.ggw-scroll-close::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 2px;
  background: #fff;
}

.ggw-scroll-close::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.ggw-scroll-close::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.ggw-scroll-close:hover {
  background: #c10500;
}

body.ggw-scroll-lock {
  overflow: hidden;
}

@media (max-width: 900px) {
  .ggw-scroll-overlay .popupform.ggw-scroll-card {
    width: 100% !important;
    max-width: 420px;
    height: auto !important;
    background: #5e84ff !important;
    background-image: none !important;
    border-radius: 16px;
  }

  .ggw-scroll-overlay .popupform .popup-content {
    float: none;
    width: 100%;
    margin: 0;
  }

  .ggw-scroll-close {
    top: 8px;
    right: 8px;
  }
}
