/* ==========================================================================
   Site-wide "Get Audit" popup lead form — mirrors the /lp modal pattern but
   uses the main site's own design tokens (--ink-900, --slate-*, --blue-500,
   --surface-*, --border-light) so it matches the rest of the site.
   Loaded after style.css / hero-v2.css / hero-carousel.css.
   ========================================================================== */

.site-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(12, 44, 85, 0.55);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.site-modal-overlay.is-open {
  display: flex;
}

.site-modal {
  position: relative;
  width: 100%;
  max-width: 34rem;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--white);
  border-radius: 1.25rem;
  box-shadow: 0 25px 60px rgba(12, 44, 85, 0.35);
  padding: 2.25rem 2rem;
  animation: site-modal-in 0.25s ease;
}

@keyframes site-modal-in {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.site-modal-close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  width: 2.25rem;
  height: 2.25rem;
  border: none;
  border-radius: 999px;
  background: var(--surface-100);
  color: var(--slate-600);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease;
}

.site-modal-close:hover {
  background: var(--border-light);
  color: var(--ink-900);
}

.site-modal-title {
  font-size: 1.45rem;
  line-height: 1.25;
  margin: 0.5rem 0 0.6rem;
  color: var(--ink-900);
}

.site-modal-sub {
  font-size: 0.95rem;
  color: var(--slate-600);
  margin-bottom: 1.5rem;
}

/* Selected-package summary strip shown at the top of the "Start Your Project" modal */
.project-modal-package-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  background: var(--surface-50);
  border: 1px solid var(--border-light);
  border-radius: 0.75rem;
  padding: 0.85rem 1.1rem;
  margin-bottom: 1.25rem;
}

.project-modal-package-label {
  font-weight: 700;
  color: var(--ink-900);
  font-size: 1rem;
}

.project-modal-package-price {
  font-weight: 800;
  color: var(--blue-500);
  font-size: 1.1rem;
}

.site-modal-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

.site-modal-form-row input,
.site-modal-form-row select,
.site-modal-form-row textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--border-light);
  border-radius: 0.65rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--ink-900);
  background: var(--white);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.site-modal-form-row input:focus,
.site-modal-form-row select:focus,
.site-modal-form-row textarea:focus {
  outline: none;
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px rgba(29, 113, 232, 0.14);
}

.site-modal-form-row > select,
.site-modal-form-row > textarea,
.site-modal-form-row > button {
  grid-column: 1 / -1;
}

.site-modal-form-row .btn-block {
  margin-top: 0.35rem;
  width: 100%;
}

/* honeypot field — hidden from real users, left in the tab order trap for bots */
.site-modal-hp {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.site-modal-status {
  min-height: 1.2em;
  margin-top: 0.75rem;
  font-size: 0.88rem;
}

.site-modal-status.is-error {
  color: #b91c1c;
}

.site-modal-status.is-loading {
  color: var(--slate-600);
}

.site-modal-success {
  text-align: center;
  padding: 1.5rem 0.5rem;
}

.site-modal-success-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 999px;
  background: #dcfce7;
  color: #16a34a;
  margin-bottom: 1rem;
}

.site-modal-success-badge svg {
  width: 1.9rem;
  height: 1.9rem;
}

@media (max-width: 640px) {
  .site-modal {
    padding: 1.75rem 1.25rem;
    border-radius: 1rem;
  }

  .site-modal-form-row {
    grid-template-columns: 1fr;
  }
}
