/* ─────────────────────────────────────────────────────────────────────────────────────────────
   Website Lead Form — styles cloned from the source funnel's computed styles.

   Source facts (measured 2026-09-03 on offer.virginiahomebuyers.org):
     page canvas 629px wide, white; body font Roboto 400
     form column 340px; labels Roboto 18/400 #000, 46px tall row
     inputs 63px tall, bg #e6e8ec, 1px transparent border, radius 3px, Roboto 18px, padding 8 10 9
     textarea 63px tall, same surface
     button 340×64, bg #b5151f, white, Roboto 20/700, radius 6px, label "GET YOUR OFFER"
     opt-in copy Roboto 18px #000
     footer: logo 100×67, phone Verdana 22/700 #002661 underlined, copyright Roboto 14/300 #0a0a0a
     thank-you: video 400×242, message Roboto 18/500 #0a0a0a centered
   ───────────────────────────────────────────────────────────────────────────────────────────── */
:root {
  --canvas: 629px;
  --column: 340px;
  --ink: #000;
  --ink-soft: #0a0a0a;
  --field: #e6e8ec;
  --field-focus: #d9dce3;
  --cta: #b5151f;
  --cta-hover: #9e121b;
  --navy: #002661;
  --error: #d0021b;
  --error-bg: #fdecee;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: #fff;
  color: var(--ink);
  font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }

.page {
  width: 100%;
  max-width: var(--canvas);
  margin: 0 auto;
  padding: 0 16px;
}
.section { display: flex; flex-direction: column; align-items: center; }

/* Header */
.header { padding: 32px 0 20px; }
.header__logo { width: 174px; height: 116px; object-fit: contain; }
.thank-you .header { padding: 26px 0 26px; }
.thank-you .header__logo { width: 152px; height: 101px; }

/* Offer form */
.form { width: 100%; max-width: var(--column); margin: 0 auto; }
.headline {
  margin: 0 0 18px;
  text-align: center;
  font-size: 24px;
  line-height: 1.4;
  font-weight: 500;
  color: var(--ink-soft);
}
.headline:empty { display: none; }
.field { margin-bottom: 12px; }
.field__label {
  display: block;
  min-height: 46px;
  padding: 12px 0 8px;
  font-size: 18px;
  line-height: 26px;
  font-weight: 400;
  color: var(--ink);
}
.field__input,
.field__textarea {
  display: block;
  width: 100%;
  height: 63px;
  padding: 8px 10px 9px;
  background: var(--field);
  border: 1px solid transparent;
  border-radius: 3px;
  color: var(--ink);
  font: inherit;
  font-size: 18px;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}
.field__textarea { resize: vertical; min-height: 63px; line-height: 1.35; }
.field__input::placeholder, .field__textarea::placeholder { color: #75797f; opacity: 1; }
.field__input:focus, .field__textarea:focus { background: var(--field-focus); border-color: #b8bdc7; }
.field.is-invalid .field__input,
.field.is-invalid .field__textarea,
.field.is-invalid .phone { border-color: var(--error); box-shadow: inset 0 0 0 1px var(--error); }
.field__error {
  display: none;
  margin-top: 6px;
  color: var(--error);
  font-size: 14px;
  line-height: 1.3;
}
.field.is-invalid .field__error { display: block; }

/* Phone: country prefix + number, mirroring the source's intl-tel-input widget */
.phone {
  display: flex;
  align-items: stretch;
  height: 63px;
  background: var(--field);
  border: 1px solid transparent;
  border-radius: 3px;
}
.phone:focus-within { background: var(--field-focus); border-color: #b8bdc7; }
.phone__country {
  flex: 0 0 auto;
  width: 96px;
  height: 100%;
  padding: 0 4px 0 10px;
  border: 0;
  border-right: 1px solid #cfd3da;
  border-radius: 3px 0 0 3px;
  background: transparent;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  cursor: pointer;
  outline: none;
}
.phone__number {
  flex: 1 1 auto;
  height: 100%;
  padding: 8px 10px 9px;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 18px;
  color: var(--ink);
  outline: none;
  min-width: 0;
}

/* Opt-in */
.optin { margin-top: 4px; }
.optin__row { display: flex; align-items: flex-start; gap: 10px; }
.optin__check {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  margin: 3px 0 0;
  accent-color: var(--cta);
  cursor: pointer;
}
.optin__text { font-size: 18px; line-height: 1.5; color: var(--ink); cursor: pointer; }
.optin__text a { color: var(--ink); }

/* CTA */
.btn {
  display: block;
  width: 100%;
  height: 64px;
  margin: 26px 0 0;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: var(--cta);
  color: #fff;
  font: inherit;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: normal;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn:hover { background: var(--cta-hover); }
.btn[disabled] { opacity: 0.7; cursor: progress; }

/* Form-level message box (source: .form-messagebox, hidden until validation fails) */
.messagebox {
  display: none;
  margin: 14px 0 0;
  padding: 10px 12px;
  border-radius: 3px;
  background: var(--error-bg);
  color: var(--error);
  font-size: 15px;
  line-height: 1.4;
}
.messagebox.is-visible { display: block; }

/* "Thank You!" overlay (source: .lightbox-dim > .notification-text, shown for 1000 ms) */
.lightbox-dim {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1000;
}
.lightbox-dim.is-visible { display: flex; }
.notification-text {
  padding: 28px 44px;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 28px;
  font-weight: 500;
}

/* Thank-you page */
.video {
  position: relative;
  width: 100%;
  max-width: 400px;
  aspect-ratio: 400 / 242;
  margin: 0 auto;
  background: #000;
}
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.message {
  margin: 24px 0 0;
  text-align: center;
  font-size: 18px;
  line-height: 25px;
  font-weight: 500;
  color: var(--ink-soft);
}

/* Footer */
.footer { padding: 64px 0 40px; }
.thank-you .footer { padding: 72px 0 40px; }
.footer__logo { width: 100px; height: 67px; object-fit: contain; }
.footer__phone {
  margin: 22px 0 0;
  font-family: Verdana, Geneva, sans-serif;
  font-size: 22px;
  line-height: 1.4;
  font-weight: 700;
  text-align: center;
}
.footer__phone a { color: var(--navy); text-decoration: underline; }
.footer__copy {
  margin: 22px 0 0;
  font-size: 14px;
  line-height: 22.4px;
  font-weight: 300;
  color: var(--ink-soft);
  text-align: center;
}

@media (max-width: 420px) {
  .field__label, .field__input, .field__textarea, .phone__number, .optin__text { font-size: 17px; }
  .header__logo { width: 150px; height: 100px; }
}
