/* popup.css — Email capture modal styles for RouteVault lead magnet popup */

/* ── MODAL OVERLAY ── */
.rv-popup-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(10, 15, 26, 0.75);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: rv-popup-fade-in 0.25s ease;
}

.rv-popup-overlay.rv-popup-visible {
  display: flex;
}

/* ── MODAL CARD ── */
.rv-popup-card {
  background: #0a0f1a;
  border: 1px solid rgba(232, 93, 42, 0.3);
  border-radius: 20px;
  padding: 40px;
  max-width: 480px;
  width: 100%;
  position: relative;
  animation: rv-popup-slide-up 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 24px 80px rgba(0,0,0,0.5), 0 0 0 1px rgba(232,93,42,0.1);
}

@keyframes rv-popup-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes rv-popup-slide-up {
  from { transform: translateY(24px) scale(0.97); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

/* ── CLOSE BUTTON ── */
.rv-popup-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s;
  color: #9ca3af;
  font-size: 16px;
  line-height: 1;
  padding: 0;
}
.rv-popup-close:hover {
  background: rgba(255,255,255,0.12);
  color: #f8f6f1;
}

/* ── BADGE ── */
.rv-popup-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(232, 93, 42, 0.12);
  border: 1px solid rgba(232, 93, 42, 0.3);
  color: #e85d2a;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 20px;
  margin-bottom: 20px;
}

/* ── HEADLINE ── */
.rv-popup-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 26px;
  font-weight: 700;
  color: #f8f6f1;
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin-bottom: 10px;
}
.rv-popup-title em {
  font-style: normal;
  color: #e85d2a;
}

/* ── SUBTEXT ── */
.rv-popup-sub {
  color: #9ca3af;
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 28px;
}

/* ── FORM ── */
.rv-popup-form { display: flex; flex-direction: column; gap: 12px; }

.rv-popup-email {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  color: #f8f6f1;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}
.rv-popup-email::placeholder { color: #6b7280; }
.rv-popup-email:focus {
  border-color: rgba(232, 93, 42, 0.6);
  background: rgba(255,255,255,0.08);
}

.rv-popup-cta {
  width: 100%;
  padding: 15px;
  background: #e85d2a;
  color: white;
  border: none;
  border-radius: 12px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  letter-spacing: -0.01em;
}
.rv-popup-cta:hover { background: #ff7a45; transform: translateY(-1px); }
.rv-popup-cta:active { transform: translateY(0); }
.rv-popup-cta:disabled { background: #6b7280; cursor: not-allowed; transform: none; }

.rv-popup-privacy {
  text-align: center;
  font-size: 11px;
  color: #6b7280;
}

/* ── LOADING STATE ── */
.rv-popup-loading { display: none; gap: 8px; align-items: center; justify-content: center; }
.rv-popup-loading.rv-popup-active { display: flex; }
.rv-popup-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: rv-popup-spin 0.7s linear infinite;
}
@keyframes rv-popup-spin {
  to { transform: rotate(360deg); }
}

/* ── SUCCESS STATE ── */
.rv-popup-success {
  display: none;
  text-align: center;
  padding: 8px 0;
}
.rv-popup-success.rv-popup-active { display: block; }
.rv-popup-success-icon {
  width: 56px;
  height: 56px;
  background: rgba(5, 150, 105, 0.12);
  border: 1px solid rgba(5, 150, 105, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 24px;
}
.rv-popup-success-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: #f8f6f1;
  letter-spacing: -0.03em;
  margin-bottom: 8px;
}
.rv-popup-success-sub {
  color: #9ca3af;
  font-size: 14px;
  line-height: 1.6;
}

/* ── TOOL PREVIEW ── */
.rv-popup-tools {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 20px;
}
.rv-popup-tool-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 11px;
  color: #9ca3af;
}

/* ── ERROR ── */
.rv-popup-error {
  display: none;
  color: #ef4444;
  font-size: 12px;
  text-align: center;
  margin-top: -4px;
}
.rv-popup-error.rv-popup-active { display: block; }

/* ── RESPONSIVE ── */
@media (max-width: 540px) {
  .rv-popup-card { padding: 28px 24px; }
  .rv-popup-title { font-size: 22px; }
}

/* Hide form when success shown */
.rv-popup-form.rv-popup-hidden { display: none; }