/* ============================================
   FORMS & LEAD FORM
   ============================================ */

.form-card {
  background: var(--white);
  border: 1px solid var(--border-gray);
  border-radius: 14px;
  padding: 38px;
  box-shadow: var(--shadow-md);
}

.form-card h2,
.form-card h3 {
  font-size: 1.5rem;
  margin-bottom: 6px;
}

.form-card .form-sub {
  color: var(--text-gray);
  font-size: 0.95rem;
  margin-bottom: 26px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.form-group { display: flex; flex-direction: column; gap: 7px; }
.form-group.full { grid-column: 1 / -1; }

.form-group label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--charcoal);
}

.form-group label .req { color: var(--fire-red); margin-left: 2px; }

.form-control {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--border-gray);
  border-radius: 8px;
  background: var(--white);
  color: var(--charcoal);
  font-size: 0.96rem;
  transition: border-color .2s ease, box-shadow .2s ease;
  min-height: 46px;
}

.form-control::placeholder { color: #9a9a9a; }

.form-control:hover { border-color: #c9c9c9; }

.form-control:focus {
  outline: none;
  border-color: var(--fire-red);
  box-shadow: 0 0 0 3px rgba(229,35,41,.14);
}

textarea.form-control { min-height: 128px; resize: vertical; }

select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23555' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}

/* Invalid state */
.form-group.invalid .form-control {
  border-color: var(--fire-red);
  background: #FFF5F5;
}

.field-error {
  color: var(--fire-red);
  font-size: 0.82rem;
  min-height: 1em;
}

/* Checkbox / radio */
.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-gray);
  line-height: 1.55;
}

.checkbox-group input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 3px;
  accent-color: var(--fire-red);
  flex: 0 0 auto;
}

/* Honeypot */
.hp-field {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Submit button + states */
.btn-submit { width: 100%; position: relative; }

.btn-submit[disabled] {
  opacity: .7;
  cursor: not-allowed;
}

.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255,255,255,.4);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin .7s linear infinite;
  display: none;
}

.btn-submit.loading .spinner { display: inline-block; }
.btn-submit.loading .btn-label { opacity: .8; }

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

/* Form status messages */
.form-status {
  display: none;
  padding: 14px 18px;
  border-radius: 8px;
  font-size: 0.94rem;
  margin-top: 18px;
}

.form-status.success {
  display: block;
  background: #E9F7EF;
  border: 1px solid #9CD9B4;
  color: #17603A;
}

.form-status.error {
  display: block;
  background: #FFF0F0;
  border: 1px solid #F1A9AC;
  color: #8E1418;
}

/* Rate-limit note */
.form-note {
  font-size: 0.83rem;
  color: #8a8a8a;
  margin-top: 14px;
  text-align: center;
}

@media (max-width: 700px) {
  .form-grid { grid-template-columns: 1fr; }
  .form-card { padding: 26px 20px; }
}

/* ---------- Contact layout ---------- */
.contact-layout {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 48px;
  align-items: start;
}

@media (max-width: 991px) {
  .contact-layout { grid-template-columns: 1fr; }
}

.map-embed {
  margin-top: 32px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-gray);
  box-shadow: var(--shadow-sm);
}

.map-embed iframe {
  width: 100%;
  height: 320px;
  border: 0;
  display: block;
}
