/* ==========================================================================
   CVPro Theme - Popup / Modal Styles
   Version: 1.0.0
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Popup Overlay
   -------------------------------------------------------------------------- */

.cvpro-popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, var(--overlay-opacity, 0.6));
  z-index: var(--cvpro-z-modal, 400);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--cvpro-space-lg, 1.5rem);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.cvpro-popup-overlay.is-visible {
  opacity: 1;
  visibility: visible;
}

/* --------------------------------------------------------------------------
   2. Popup Container
   -------------------------------------------------------------------------- */

.cvpro-popup-container {
  background: var(--cvpro-bg-primary, #FFFFFF);
  border-radius: var(--cvpro-radius-xl, 16px);
  max-width: 480px;
  width: 100%;
  padding: var(--cvpro-space-2xl, 3rem);
  position: relative;
  box-shadow: var(--cvpro-shadow-xl, 0 20px 25px -5px rgba(0, 0, 0, 0.1));
  transform: translateY(20px) scale(0.98);
  transition: transform 0.3s ease;
  max-height: 90vh;
  overflow-y: auto;
}

.cvpro-popup-overlay.is-visible .cvpro-popup-container {
  transform: translateY(0) scale(1);
}

/* --------------------------------------------------------------------------
   3. Close Button
   -------------------------------------------------------------------------- */

.cvpro-popup-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--cvpro-bg-secondary, #F9FAFB);
  border: none;
  border-radius: var(--cvpro-radius-full, 9999px);
  cursor: pointer;
  color: var(--cvpro-text-secondary, #6B7280);
  transition: background 150ms ease, color 150ms ease;
  z-index: 2;
}

.cvpro-popup-close:hover {
  background: var(--cvpro-border, #E5E7EB);
  color: var(--cvpro-text-primary, #111928);
}

.cvpro-popup-close svg {
  width: 20px;
  height: 20px;
}

/* --------------------------------------------------------------------------
   4. Progress Dots
   -------------------------------------------------------------------------- */

.cvpro-popup-progress-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: var(--cvpro-space-xl, 2rem);
}

.cvpro-popup-dot {
  width: 10px;
  height: 10px;
  border-radius: var(--cvpro-radius-full, 9999px);
  background: var(--cvpro-border, #E5E7EB);
  transition: background 250ms ease, transform 250ms ease;
}

.cvpro-popup-dot.is-active {
  background: var(--cvpro-primary, #1A56DB);
  transform: scale(1.15);
}

.cvpro-popup-dot.is-completed {
  background: var(--cvpro-success, #0E9F6E);
}

/* --------------------------------------------------------------------------
   5. Popup Icon
   -------------------------------------------------------------------------- */

.cvpro-popup-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto var(--cvpro-space-lg, 1.5rem);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--cvpro-radius-full, 9999px);
  background: rgba(26, 86, 219, 0.08);
  color: var(--cvpro-primary, #1A56DB);
}

.cvpro-popup-icon svg {
  width: 36px;
  height: 36px;
}

/* Scanning Animation */
.cvpro-scanning-animation {
  width: 72px;
  height: 72px;
  margin: 0 auto var(--cvpro-space-lg, 1.5rem);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cvpro-scanning-animation::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--cvpro-radius-full, 9999px);
  border: 3px solid rgba(26, 86, 219, 0.15);
  animation: cvpro-scan-pulse 1.5s ease-in-out infinite;
}

.cvpro-scanning-animation::after {
  content: '';
  position: absolute;
  inset: 8px;
  border-radius: var(--cvpro-radius-full, 9999px);
  border: 3px solid transparent;
  border-top-color: var(--cvpro-primary, #1A56DB);
  animation: cvpro-scan-spin 1s linear infinite;
}

.cvpro-scanning-animation svg {
  width: 28px;
  height: 28px;
  color: var(--cvpro-primary, #1A56DB);
}

@keyframes cvpro-scan-pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.7;
  }
}

@keyframes cvpro-scan-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* --------------------------------------------------------------------------
   6. Popup Title & Subtitle
   -------------------------------------------------------------------------- */

.cvpro-popup-title {
  font-family: var(--cvpro-font-heading, 'Inter', sans-serif);
  font-size: 1.5rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: var(--cvpro-space-sm, 0.5rem);
  color: var(--cvpro-text-primary, #111928);
  line-height: 1.2;
}

.cvpro-popup-subtitle {
  font-size: 0.9375rem;
  text-align: center;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-bottom: var(--cvpro-space-xl, 2rem);
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   7. Google Button (in popup context)
   -------------------------------------------------------------------------- */

.cvpro-popup-container .cvpro-btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 0.75rem 1.25rem;
  background: var(--cvpro-bg-primary, #FFFFFF);
  border: 1px solid var(--cvpro-border, #E5E7EB);
  border-radius: var(--cvpro-radius-md, 8px);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--cvpro-text-primary, #111928);
  cursor: pointer;
  transition: background 150ms ease, box-shadow 150ms ease;
}

.cvpro-popup-container .cvpro-btn-google:hover {
  background: var(--cvpro-bg-secondary, #F9FAFB);
  box-shadow: var(--cvpro-shadow-sm, 0 1px 2px 0 rgba(0, 0, 0, 0.05));
}

.cvpro-popup-container .cvpro-btn-google svg,
.cvpro-popup-container .cvpro-btn-google img {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   8. Divider
   -------------------------------------------------------------------------- */

.cvpro-popup-divider {
  display: flex;
  align-items: center;
  gap: var(--cvpro-space-md, 1rem);
  margin: var(--cvpro-space-lg, 1.5rem) 0;
  color: var(--cvpro-text-secondary, #6B7280);
  font-size: 0.8125rem;
}

.cvpro-popup-divider::before,
.cvpro-popup-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--cvpro-border, #E5E7EB);
}

/* --------------------------------------------------------------------------
   9. Form Group
   -------------------------------------------------------------------------- */

.cvpro-form-group {
  margin-bottom: var(--cvpro-space-md, 1rem);
}

.cvpro-form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--cvpro-text-primary, #111928);
  margin-bottom: var(--cvpro-space-xs, 0.25rem);
}

.cvpro-form-group input {
  width: 100%;
  padding: 0.75rem 0.875rem;
  border: 1px solid var(--cvpro-border, #E5E7EB);
  border-radius: var(--cvpro-radius-md, 8px);
  font-size: 0.9375rem;
  color: var(--cvpro-text-primary, #111928);
  background: var(--cvpro-bg-primary, #FFFFFF);
  transition: border-color 150ms ease, box-shadow 150ms ease;
  outline: none;
}

.cvpro-form-group input::placeholder {
  color: var(--cvpro-text-secondary, #6B7280);
  opacity: 0.6;
}

.cvpro-form-group input:focus {
  border-color: var(--cvpro-primary, #1A56DB);
  box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.12);
}

.cvpro-form-group input.is-error {
  border-color: var(--cvpro-error, #E02424);
  box-shadow: 0 0 0 3px rgba(224, 36, 36, 0.12);
}

.cvpro-form-error {
  font-size: 0.8125rem;
  color: var(--cvpro-error, #E02424);
  margin-top: var(--cvpro-space-xs, 0.25rem);
  display: none;
}

.cvpro-form-group.has-error .cvpro-form-error {
  display: block;
}

/* --------------------------------------------------------------------------
   10. Password Strength
   -------------------------------------------------------------------------- */

.cvpro-password-strength {
  height: 4px;
  border-radius: var(--cvpro-radius-full, 9999px);
  background: var(--cvpro-border, #E5E7EB);
  margin-top: var(--cvpro-space-sm, 0.5rem);
  overflow: hidden;
}

.cvpro-password-strength-fill {
  height: 100%;
  width: 0;
  border-radius: var(--cvpro-radius-full, 9999px);
  transition: width 300ms ease, background 300ms ease;
}

.cvpro-password-strength-fill.strength-weak {
  width: 33%;
  background: var(--cvpro-error, #E02424);
}

.cvpro-password-strength-fill.strength-medium {
  width: 66%;
  background: #F59E0B;
}

.cvpro-password-strength-fill.strength-strong {
  width: 100%;
  background: var(--cvpro-success, #0E9F6E);
}

.cvpro-password-strength-text {
  font-size: 0.75rem;
  margin-top: 4px;
  color: var(--cvpro-text-secondary, #6B7280);
}

/* --------------------------------------------------------------------------
   11. Privacy Note & Sign-in Link
   -------------------------------------------------------------------------- */

.cvpro-popup-privacy-note {
  font-size: 0.75rem;
  text-align: center;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-top: var(--cvpro-space-lg, 1.5rem);
  line-height: 1.5;
}

.cvpro-popup-privacy-note a {
  color: var(--cvpro-primary, #1A56DB);
  text-decoration: underline;
}

.cvpro-popup-signin {
  font-size: 0.875rem;
  text-align: center;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-top: var(--cvpro-space-md, 1rem);
}

.cvpro-popup-signin a {
  color: var(--cvpro-primary, #1A56DB);
  font-weight: 600;
  text-decoration: none;
}

.cvpro-popup-signin a:hover {
  text-decoration: underline;
}

/* --------------------------------------------------------------------------
   12. Success State (Step 2)
   -------------------------------------------------------------------------- */

.cvpro-popup-success-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--cvpro-space-lg, 1.5rem);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(14, 159, 110, 0.1);
  border-radius: var(--cvpro-radius-full, 9999px);
  color: var(--cvpro-success, #0E9F6E);
  animation: cvpro-success-pop 0.5s ease forwards;
}

.cvpro-popup-success-icon svg {
  width: 40px;
  height: 40px;
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  animation: cvpro-checkmark-draw 0.6s 0.3s ease forwards;
}

@keyframes cvpro-success-pop {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  70% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes cvpro-checkmark-draw {
  to {
    stroke-dashoffset: 0;
  }
}

/* Popup step visibility */
.cvpro-popup-step {
  display: block;
}

.cvpro-popup-step[hidden] {
  display: none;
}

/* --------------------------------------------------------------------------
   13. Popup Animations
   -------------------------------------------------------------------------- */

/* Slide Up */
@keyframes cvpro-slide-up {
  from {
    transform: translateY(40px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.cvpro-popup-container--slide-up {
  animation: cvpro-slide-up 0.35s ease forwards;
}

/* Fade */
@keyframes cvpro-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.cvpro-popup-container--fade {
  animation: cvpro-fade-in 0.3s ease forwards;
}

/* Scale */
@keyframes cvpro-scale-in {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.cvpro-popup-container--scale {
  animation: cvpro-scale-in 0.3s ease forwards;
}

/* --------------------------------------------------------------------------
   14. Exit Intent Overlay
   -------------------------------------------------------------------------- */

.cvpro-exit-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: var(--cvpro-z-modal, 400);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--cvpro-space-lg, 1.5rem);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.cvpro-exit-overlay.is-visible {
  opacity: 1;
  visibility: visible;
}

.cvpro-exit-container {
  background: var(--cvpro-bg-primary, #FFFFFF);
  border-radius: var(--cvpro-radius-xl, 16px);
  max-width: 440px;
  width: 100%;
  padding: var(--cvpro-space-3xl, 4rem) var(--cvpro-space-2xl, 3rem);
  text-align: center;
  position: relative;
  box-shadow: var(--cvpro-shadow-xl);
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.cvpro-exit-overlay.is-visible .cvpro-exit-container {
  transform: scale(1);
}

.cvpro-exit-icon {
  font-size: 3.5rem;
  margin-bottom: var(--cvpro-space-lg, 1.5rem);
  line-height: 1;
}

.cvpro-exit-container h2 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: var(--cvpro-space-sm, 0.5rem);
  color: var(--cvpro-text-primary, #111928);
}

.cvpro-exit-container p {
  font-size: 0.9375rem;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-bottom: var(--cvpro-space-xl, 2rem);
  line-height: 1.6;
}

.cvpro-exit-container .cvpro-btn {
  margin-bottom: var(--cvpro-space-md, 1rem);
}

.cvpro-exit-dismiss {
  display: inline-block;
  background: none;
  border: none;
  color: var(--cvpro-text-secondary, #6B7280);
  font-size: 0.875rem;
  cursor: pointer;
  padding: var(--cvpro-space-sm, 0.5rem);
  transition: color 150ms ease;
}

.cvpro-exit-dismiss:hover {
  color: var(--cvpro-text-primary, #111928);
}

.cvpro-exit-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--cvpro-bg-secondary, #F9FAFB);
  border: none;
  border-radius: var(--cvpro-radius-full, 9999px);
  cursor: pointer;
  color: var(--cvpro-text-secondary, #6B7280);
  transition: background 150ms ease, color 150ms ease;
}

.cvpro-exit-close:hover {
  background: var(--cvpro-border, #E5E7EB);
  color: var(--cvpro-text-primary, #111928);
}

.cvpro-exit-close svg {
  width: 18px;
  height: 18px;
}

/* --------------------------------------------------------------------------
   15. Responsive - Mobile Popup
   -------------------------------------------------------------------------- */

@media (max-width: 640px) {
  .cvpro-popup-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .cvpro-popup-container {
    max-width: 100%;
    border-radius: var(--cvpro-radius-xl, 16px) var(--cvpro-radius-xl, 16px) 0 0;
    padding: var(--cvpro-space-xl, 2rem) var(--cvpro-space-lg, 1.5rem) calc(var(--cvpro-space-2xl, 3rem) + env(safe-area-inset-bottom, 0px));
    max-height: 92vh;
    max-height: 92dvh;
    transform: translateY(100%);
  }

  .cvpro-popup-close {
    width: 44px;
    height: 44px;
  }

  .cvpro-popup-overlay.is-visible .cvpro-popup-container {
    transform: translateY(0);
  }

  /* Bottom sheet handle */
  .cvpro-popup-container::before {
    content: '';
    display: block;
    width: 40px;
    height: 4px;
    background: var(--cvpro-border, #E5E7EB);
    border-radius: var(--cvpro-radius-full, 9999px);
    margin: 0 auto var(--cvpro-space-lg, 1.5rem);
  }

  .cvpro-exit-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .cvpro-exit-container {
    max-width: 100%;
    border-radius: var(--cvpro-radius-xl, 16px) var(--cvpro-radius-xl, 16px) 0 0;
    padding: var(--cvpro-space-xl, 2rem) var(--cvpro-space-lg, 1.5rem) var(--cvpro-space-2xl, 3rem);
    transform: translateY(100%);
  }

  .cvpro-exit-overlay.is-visible .cvpro-exit-container {
    transform: translateY(0);
  }

  .cvpro-exit-container::before {
    content: '';
    display: block;
    width: 40px;
    height: 4px;
    background: var(--cvpro-border, #E5E7EB);
    border-radius: var(--cvpro-radius-full, 9999px);
    margin: 0 auto var(--cvpro-space-lg, 1.5rem);
  }
}

/* ==========================================================================
   BEM COMPATIBILITY LAYER - Popup Classes
   Maps BEM class names (used in PHP templates) to existing flat-named styles.
   ========================================================================== */

/* --------------------------------------------------------------------------
   BEM: Popup Close (generic)
   -------------------------------------------------------------------------- */

.cvpro-popup__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--cvpro-bg-secondary, #F9FAFB);
  border: none;
  border-radius: var(--cvpro-radius-full, 9999px);
  cursor: pointer;
  color: var(--cvpro-text-secondary, #6B7280);
  transition: background 150ms ease, color 150ms ease;
  z-index: 2;
}

.cvpro-popup__close:hover {
  background: var(--cvpro-border, #E5E7EB);
  color: var(--cvpro-text-primary, #111928);
}

.cvpro-popup__close svg {
  width: 20px;
  height: 20px;
}

/* --------------------------------------------------------------------------
   BEM: Register Popup
   -------------------------------------------------------------------------- */

.cvpro-register-popup__step {
  display: block;
}

.cvpro-register-popup__step--hidden,
.cvpro-register-popup__step[hidden] {
  display: none;
}

.cvpro-register-popup__progress {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: var(--cvpro-space-xl, 2rem);
}

.cvpro-register-popup__dot {
  width: 10px;
  height: 10px;
  border-radius: var(--cvpro-radius-full, 9999px);
  background: var(--cvpro-border, #E5E7EB);
  transition: background 250ms ease, transform 250ms ease;
}

.cvpro-register-popup__dot.is-active {
  background: var(--cvpro-primary, #1A56DB);
  transform: scale(1.15);
}

.cvpro-register-popup__dot.is-completed {
  background: var(--cvpro-success, #0E9F6E);
}

.cvpro-register-popup__icon {
  width: 72px;
  height: 72px;
  margin: 0 auto var(--cvpro-space-lg, 1.5rem);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--cvpro-radius-full, 9999px);
  background: rgba(26, 86, 219, 0.08);
  color: var(--cvpro-primary, #1A56DB);
}

.cvpro-register-popup__icon svg {
  width: 36px;
  height: 36px;
}

.cvpro-register-popup__title {
  font-family: var(--cvpro-font-heading, 'Inter', sans-serif);
  font-size: 1.5rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: var(--cvpro-space-sm, 0.5rem);
  color: var(--cvpro-text-primary, #111928);
  line-height: 1.2;
}

.cvpro-register-popup__subtext {
  font-size: 0.9375rem;
  text-align: center;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-bottom: var(--cvpro-space-xl, 2rem);
  line-height: 1.6;
}

.cvpro-register-popup__google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 0.75rem 1.25rem;
  background: var(--cvpro-bg-primary, #FFFFFF);
  border: 1px solid var(--cvpro-border, #E5E7EB);
  border-radius: var(--cvpro-radius-md, 8px);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--cvpro-text-primary, #111928);
  cursor: pointer;
  transition: background 150ms ease, box-shadow 150ms ease;
}

.cvpro-register-popup__google:hover {
  background: var(--cvpro-bg-secondary, #F9FAFB);
  box-shadow: var(--cvpro-shadow-sm, 0 1px 2px 0 rgba(0, 0, 0, 0.05));
}

.cvpro-register-popup__google svg,
.cvpro-register-popup__google img {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.cvpro-register-popup__divider {
  display: flex;
  align-items: center;
  gap: var(--cvpro-space-md, 1rem);
  margin: var(--cvpro-space-lg, 1.5rem) 0;
  color: var(--cvpro-text-secondary, #6B7280);
  font-size: 0.8125rem;
}

.cvpro-register-popup__divider::before,
.cvpro-register-popup__divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--cvpro-border, #E5E7EB);
}

.cvpro-register-popup__form {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.cvpro-register-popup__privacy {
  font-size: 0.75rem;
  text-align: center;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-top: var(--cvpro-space-lg, 1.5rem);
  line-height: 1.5;
}

.cvpro-register-popup__privacy a {
  color: var(--cvpro-primary, #1A56DB);
  text-decoration: underline;
}

.cvpro-register-popup__signin {
  font-size: 0.875rem;
  text-align: center;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-top: var(--cvpro-space-md, 1rem);
}

.cvpro-register-popup__signin a {
  color: var(--cvpro-primary, #1A56DB);
  font-weight: 600;
  text-decoration: none;
}

.cvpro-register-popup__signin a:hover {
  text-decoration: underline;
}

.cvpro-register-popup__submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--cvpro-space-sm, 0.5rem);
  width: 100%;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1.2;
  border-radius: var(--cvpro-radius-md, 8px);
  border: 2px solid transparent;
  transition: all 150ms ease;
  text-decoration: none;
  cursor: pointer;
  background-color: var(--cvpro-primary, #1A56DB);
  color: #FFFFFF;
  border-color: var(--cvpro-primary, #1A56DB);
  box-sizing: border-box;
}

.cvpro-register-popup__submit:hover {
  background-color: var(--cvpro-primary-dark, #1E429F);
  border-color: var(--cvpro-primary-dark, #1E429F);
  color: #FFFFFF;
}

.cvpro-register-popup__submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.cvpro-register-popup__success-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--cvpro-space-lg, 1.5rem);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(14, 159, 110, 0.1);
  border-radius: var(--cvpro-radius-full, 9999px);
  color: var(--cvpro-success, #0E9F6E);
  animation: cvpro-success-pop 0.5s ease forwards;
}

.cvpro-register-popup__success-icon svg {
  width: 40px;
  height: 40px;
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  animation: cvpro-checkmark-draw 0.6s 0.3s ease forwards;
}

/* --------------------------------------------------------------------------
   BEM: Exit Intent Popup
   -------------------------------------------------------------------------- */

.cvpro-exit-popup__icon {
  font-size: 3.5rem;
  margin-bottom: var(--cvpro-space-lg, 1.5rem);
  line-height: 1;
  text-align: center;
}

.cvpro-exit-popup__title {
  font-family: var(--cvpro-font-heading, 'Inter', sans-serif);
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: var(--cvpro-space-sm, 0.5rem);
  color: var(--cvpro-text-primary, #111928);
  text-align: center;
}

.cvpro-exit-popup__subtext {
  font-size: 0.9375rem;
  color: var(--cvpro-text-secondary, #6B7280);
  margin-bottom: var(--cvpro-space-xl, 2rem);
  line-height: 1.6;
  text-align: center;
}

.cvpro-exit-popup__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--cvpro-space-sm, 0.5rem);
  width: 100%;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1;
  border-radius: var(--cvpro-radius-md, 8px);
  border: 2px solid transparent;
  transition: all 150ms ease;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  background-color: var(--cvpro-primary, #1A56DB);
  color: #FFFFFF;
  border-color: var(--cvpro-primary, #1A56DB);
  margin-bottom: var(--cvpro-space-md, 1rem);
}

.cvpro-exit-popup__cta:hover {
  background-color: var(--cvpro-primary-dark, #1E429F);
  border-color: var(--cvpro-primary-dark, #1E429F);
  color: #FFFFFF;
}

.cvpro-exit-popup__dismiss {
  display: inline-block;
  background: none;
  border: none;
  color: var(--cvpro-text-secondary, #6B7280);
  font-size: 0.875rem;
  cursor: pointer;
  padding: var(--cvpro-space-sm, 0.5rem);
  transition: color 150ms ease;
  text-align: center;
  width: 100%;
}

.cvpro-exit-popup__dismiss:hover {
  color: var(--cvpro-text-primary, #111928);
}

/* --------------------------------------------------------------------------
   BEM: Form Fields
   -------------------------------------------------------------------------- */

.cvpro-form__field {
  margin-bottom: var(--cvpro-space-md, 1rem);
}

.cvpro-form__label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--cvpro-text-primary, #111928);
  margin-bottom: var(--cvpro-space-xs, 0.25rem);
}

.cvpro-form__input {
  width: 100%;
  padding: 0.75rem 0.875rem;
  border: 1px solid var(--cvpro-border, #E5E7EB);
  border-radius: var(--cvpro-radius-md, 8px);
  font-size: 0.9375rem;
  color: var(--cvpro-text-primary, #111928);
  background: var(--cvpro-bg-primary, #FFFFFF);
  transition: border-color 150ms ease, box-shadow 150ms ease;
  outline: none;
  font-family: var(--cvpro-font-body, 'Inter', sans-serif);
  box-sizing: border-box;
}

.cvpro-form__input::placeholder {
  color: var(--cvpro-text-secondary, #6B7280);
  opacity: 0.6;
}

.cvpro-form__input:focus {
  border-color: var(--cvpro-primary, #1A56DB);
  box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.12);
}

.cvpro-form__input.is-error {
  border-color: var(--cvpro-error, #E02424);
  box-shadow: 0 0 0 3px rgba(224, 36, 36, 0.12);
}

.cvpro-form__password-wrapper {
  position: relative;
}

.cvpro-form__password-wrapper .cvpro-form__input {
  padding-right: 3rem;
}

.cvpro-form__password-toggle {
  position: absolute;
  top: 50%;
  right: 0.75rem;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cvpro-text-secondary, #6B7280);
  transition: color 150ms ease;
  padding: 0;
}

.cvpro-form__password-toggle:hover {
  color: var(--cvpro-text-primary, #111928);
}

.cvpro-form__password-toggle svg {
  width: 18px;
  height: 18px;
}

.cvpro-form__password-strength {
  height: 4px;
  border-radius: var(--cvpro-radius-full, 9999px);
  background: var(--cvpro-border, #E5E7EB);
  margin-top: var(--cvpro-space-sm, 0.5rem);
  overflow: hidden;
}

.cvpro-form__strength-bar {
  height: 4px;
  border-radius: var(--cvpro-radius-full, 9999px);
  background: var(--cvpro-border, #E5E7EB);
  margin-top: var(--cvpro-space-sm, 0.5rem);
  overflow: hidden;
}

.cvpro-form__strength-fill {
  height: 100%;
  width: 0;
  border-radius: var(--cvpro-radius-full, 9999px);
  transition: width 300ms ease, background 300ms ease;
}

.cvpro-form__strength-fill.strength-weak {
  width: 33%;
  background: var(--cvpro-error, #E02424);
}

.cvpro-form__strength-fill.strength-medium {
  width: 66%;
  background: #F59E0B;
}

.cvpro-form__strength-fill.strength-strong {
  width: 100%;
  background: var(--cvpro-success, #0E9F6E);
}

.cvpro-form__strength-text {
  font-size: 0.75rem;
  margin-top: 4px;
  color: var(--cvpro-text-secondary, #6B7280);
}

.cvpro-form__captcha {
  margin-top: var(--cvpro-space-md, 1rem);
  margin-bottom: var(--cvpro-space-md, 1rem);
  display: flex;
  justify-content: center;
}

.cvpro-form__error {
  display: none;
  font-size: 0.8125rem;
  color: var(--cvpro-error, #E02424);
  margin-top: var(--cvpro-space-xs, 0.25rem);
}

.cvpro-form__field.has-error .cvpro-form__error {
  display: block;
}

/* --------------------------------------------------------------------------
   BEM Popup: Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 640px) {
  .cvpro-register-popup__title {
    font-size: 1.25rem;
  }

  .cvpro-register-popup__subtext {
    font-size: 0.875rem;
  }

  .cvpro-exit-popup__title {
    font-size: 1.25rem;
  }

  .cvpro-exit-popup__subtext {
    font-size: 0.875rem;
  }
}

/* ==========================================================================
   POPUP OVERLAY & CARD OVERRIDES
   Proper dark overlay with centered white card
   ========================================================================== */

.cvpro-popup-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--cvpro-z-modal, 400);
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.cvpro-popup-overlay.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.cvpro-popup {
  background: #fff;
  border-radius: 1rem;
  max-width: 440px;
  width: 100%;
  padding: 2rem;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
  transform: translateY(20px);
  transition: transform 0.3s ease;
}

.cvpro-popup-overlay.is-visible .cvpro-popup {
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   Popup Close Button (BEM .cvpro-popup__close override)
   -------------------------------------------------------------------------- */

.cvpro-popup__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 9999px;
  cursor: pointer;
  color: #9ca3af;
  transition: color 150ms ease, background 150ms ease;
  z-index: 2;
  padding: 0;
  line-height: 1;
}

.cvpro-popup__close:hover {
  color: #111928;
  background: rgba(0, 0, 0, 0.05);
}

.cvpro-popup__close svg {
  width: 20px;
  height: 20px;
}

/* --------------------------------------------------------------------------
   Trust Row
   -------------------------------------------------------------------------- */

.cvpro-popup__trust-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 1rem;
}

.cvpro-popup__trust-row span {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.cvpro-popup__trust-row svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   Social Proof
   -------------------------------------------------------------------------- */

.cvpro-popup__social-proof {
  text-align: center;
  font-size: 0.8125rem;
  color: #6b7280;
  margin-top: 1rem;
  line-height: 1.5;
}

/* --------------------------------------------------------------------------
   Activity Indicator
   -------------------------------------------------------------------------- */

.cvpro-popup__activity {
  text-align: center;
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 0.5rem;
  line-height: 1.4;
}

/* --------------------------------------------------------------------------
   Love Text
   -------------------------------------------------------------------------- */

.cvpro-popup__love-text {
  text-align: center;
  font-size: 0.8125rem;
  margin-top: 1rem;
  color: #6b7280;
  line-height: 1.5;
}
