/* ===================================================
   Lead Capture Popup — NaviGo Tech Solutions
   Brand: #1E90FF (blue) | #0D1117 (dark) | #10B981 (green)
   Fonts: Montserrat (headings) | Inter (body)
=================================================== */

.lead-popup-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(13, 17, 23, 0.80);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

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

/* Card */
.lead-popup-card {
  position: relative;
  background: #ffffff;
  border-radius: 20px;
  width: 100%;
  max-width: 460px;
  box-shadow: 0 32px 80px rgba(0,0,0,0.4), 0 0 0 1px rgba(30,144,255,0.12);
  overflow: hidden;
  transform: translateY(40px) scale(0.96);
  opacity: 0;
  transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.4s ease;
}

.lead-popup-overlay.is-visible .lead-popup-card {
  transform: translateY(0) scale(1);
  opacity: 1;
}

/* Pulse on appear */
@keyframes lead-pulse {
  0%   { box-shadow: 0 32px 80px rgba(0,0,0,.4), 0 0 0 0 rgba(30,144,255,0.4); }
  60%  { box-shadow: 0 32px 80px rgba(0,0,0,.4), 0 0 0 14px rgba(30,144,255,0); }
  100% { box-shadow: 0 32px 80px rgba(0,0,0,.4), 0 0 0 0 rgba(30,144,255,0); }
}

.lead-popup-overlay.is-visible .lead-popup-card {
  animation: lead-pulse 1.4s ease 0.5s 1;
}

/* Close Button */
.lead-popup-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 10;
  width: 32px;
  height: 32px;
  border: none;
  background: rgba(255,255,255,0.15);
  border-radius: 50%;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.2s;
  padding: 0;
}

.lead-popup-close:hover {
  background: rgba(255,255,255,0.28);
  transform: scale(1.1);
}

/* Header */
.lead-popup-header {
  background: linear-gradient(135deg, #0D1117 0%, #0a2540 50%, #004fa3 100%);
  padding: 32px 28px 26px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* Decorative circles */
.lead-popup-header::before {
  content: '';
  position: absolute;
  top: -50px; right: -30px;
  width: 160px; height: 160px;
  border-radius: 50%;
  background: rgba(30,144,255,0.08);
}

.lead-popup-header::after {
  content: '';
  position: absolute;
  bottom: -60px; left: -30px;
  width: 120px; height: 120px;
  border-radius: 50%;
  background: rgba(16,185,129,0.07);
}

/* Animated glow dot */
.lead-popup-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(16,185,129,0.15);
  border: 1px solid rgba(16,185,129,0.3);
  color: #10B981;
  font-family: 'Inter', sans-serif;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.lead-popup-live::before {
  content: '';
  width: 7px; height: 7px;
  background: #10B981;
  border-radius: 50%;
  animation: live-blink 1.2s ease-in-out infinite;
}

@keyframes live-blink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.4; transform: scale(0.7); }
}

.lead-popup-header h2 {
  font-family: 'Montserrat', sans-serif;
  color: #ffffff;
  font-size: 1.55rem;
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 8px;
  letter-spacing: -0.02em;
}

.lead-popup-header h2 span {
  background: linear-gradient(90deg, #1E90FF, #10B981);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.lead-popup-header p {
  color: rgba(255,255,255,0.78);
  font-size: 0.87rem;
  margin: 0;
  font-family: 'Inter', sans-serif;
  line-height: 1.5;
}

/* Trust pills */
.lead-popup-trust {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.lead-popup-trust span {
  background: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.88);
  font-size: 0.7rem;
  font-family: 'Inter', sans-serif;
  padding: 3px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.15);
}

/* Body */
.lead-popup-body {
  padding: 22px 28px 26px;
}

.lead-form-group {
  margin-bottom: 13px;
}

.lead-form-group label {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 0.76rem;
  font-weight: 600;
  color: #111827;
  margin-bottom: 5px;
  letter-spacing: 0.01em;
}

.lead-form-group input,
.lead-form-group select {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid #E5E7EB;
  border-radius: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  color: #111827;
  background: #F9FAFB;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.lead-form-group select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%230D1117' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
  cursor: pointer;
}

.lead-form-group input:focus,
.lead-form-group select:focus {
  border-color: #1E90FF;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(30,144,255,0.12);
}

.lead-form-group input::placeholder {
  color: #9CA3AF;
}

.lead-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Submit */
.lead-popup-submit {
  width: 100%;
  padding: 13px 20px;
  background: linear-gradient(135deg, #1E90FF 0%, #0066CC 100%);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  margin-top: 4px;
  position: relative;
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 18px rgba(30,144,255,0.38);
}

.lead-popup-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(30,144,255,0.50);
}

.lead-popup-submit:active { transform: translateY(0); }

.lead-popup-submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.lead-popup-submit .btn-spinner {
  display: none;
  width: 15px; height: 15px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: lead-spin 0.7s linear infinite;
  margin-right: 8px;
  vertical-align: middle;
}

.lead-popup-submit.is-loading .btn-spinner { display: inline-block; }

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

/* Privacy + Skip */
.lead-popup-privacy {
  text-align: center;
  font-size: 0.72rem;
  color: #9CA3AF;
  margin: 10px 0 0;
  font-family: 'Inter', sans-serif;
}

.lead-popup-skip {
  display: block;
  text-align: center;
  margin-top: 8px;
  font-size: 0.74rem;
  color: #9CA3AF;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s;
  width: 100%;
}

.lead-popup-skip:hover { color: #374151; }

/* Success */
.lead-popup-success {
  text-align: center;
  padding: 8px 0 4px;
}

.lead-popup-success .success-icon {
  width: 68px; height: 68px;
  background: linear-gradient(135deg, #1E90FF, #10B981);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 30px;
  color: #fff;
  animation: lead-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes lead-pop {
  from { transform: scale(0); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.lead-popup-success h3 {
  font-family: 'Montserrat', sans-serif;
  color: #111827;
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.lead-popup-success p {
  color: #6B7280;
  font-size: 0.88rem;
  font-family: 'Inter', sans-serif;
  margin-bottom: 20px;
}

/* Mobile */
@media (max-width: 500px) {
  .lead-popup-card {
    border-radius: 16px;
    max-height: 92vh;
    overflow-y: auto;
  }
  .lead-popup-header { padding: 24px 20px 20px; }
  .lead-popup-body   { padding: 18px 20px 22px; }
  .lead-popup-header h2 { font-size: 1.3rem; }
  .lead-form-row { grid-template-columns: 1fr; gap: 0; }
}
