/* Short demo form embedded in the final "Book a demo" band (Sept 30 2026).
   Mounted by /demo-form.js on <div class="edf" data-demo-form>.

   Every selector is namespaced .edf. The band's own page CSS is duplicated
   inline in 400+ sources, so nothing here may rely on, or redefine, a shared
   class. The whitepaper gate's card class in particular belongs to
   wp-form.css, which these pages do not load; a test asserts this file never
   names it.

   position:relative is load-bearing, not decoration. .cta-final::before is an
   absolutely positioned radial gradient and the band's own h2/p/.sub each set
   position:relative to sit above it; without it here the card renders UNDER
   the gradient. */
.edf {
  position: relative;
  max-width: 520px;
  margin: 0 auto;
  background: #fff;
  color: var(--ink);
  border-radius: 22px;
  padding: 26px 26px 24px;
  box-shadow: 0 24px 60px rgba(11, 36, 51, 0.22);
  text-align: left;
}
.edf-h {
  font-family: var(--display);
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin-bottom: 4px;
}
.edf-sub {
  font-size: 13.5px;
  color: #5A7280;
  line-height: 1.45;
  margin-bottom: 4px;
}
/* First/last name share a row on anything wider than a small phone and stack
   below it. gap on the grid, not margins, so the stacked order keeps the same
   rhythm as the single-column fields. */
.edf-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 12px;
}
.edf label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin: 14px 0 6px;
  color: var(--ink);
}
/* 16px is deliberate: iOS Safari zooms the viewport on focus for anything
   smaller, which on a phone throws the whole band off-screen mid-typing.
   min-height 44px is the Apple/WCAG touch target. */
.edf input {
  width: 100%;
  min-height: 44px;
  padding: 11px 14px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-family: var(--body);
  font-size: 16px;
  color: var(--ink);
  background: var(--paper);
}
.edf input:focus-visible {
  outline: 2px solid var(--qliq);
  outline-offset: 1px;
  border-color: var(--qliq);
}
.edf input[aria-invalid="true"] { border-color: var(--pulse); }
.edf-err {
  display: none;
  color: #B4472F;
  font-size: 12.5px;
  margin-top: 6px;
}
.edf-btn {
  width: 100%;
  min-height: 48px;
  margin-top: 18px;
  border: none;
  border-radius: 100px;
  background: var(--pulse);
  color: #fff;
  font-family: var(--body);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  touch-action: manipulation;
}
.edf-btn:disabled { opacity: .75; cursor: default; }
.edf-note {
  font-size: 11.5px;
  color: #8AA0AC;
  line-height: 1.5;
  margin-top: 12px;
  text-align: center;
}
.edf-note a { color: var(--qliq-deep); text-decoration: underline; }
/* Submit-time failure. Validation messages are per-field (.edf-err) so the
   visitor is pointed at the field, not at a banner. */
.edf-fail {
  display: none;
  margin-top: 14px;
  padding: 12px 14px;
  border: 1.5px solid var(--pulse);
  border-radius: 12px;
  font-size: 13.5px;
  line-height: 1.5;
}
.edf-fail a { color: var(--qliq-deep); font-weight: 700; }
.edf-ok { display: none; text-align: center; padding: 8px 0 4px; }
.edf-ok .edf-tick {
  font-size: 30px;
  line-height: 1;
  color: var(--sage-deep);
  margin-bottom: 10px;
}
.edf-ok h3 {
  font-family: var(--display);
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 6px;
}
.edf-ok p { font-size: 14px; color: #3E5563; }
/* The honeypot. Off-screen rather than display:none: some bots skip hidden
   inputs, and a field that is not rendered is not filled. aria-hidden and
   tabindex keep it away from assistive tech and the tab order. */
.edf-hp { position: absolute; left: -9999px; top: -9999px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 560px) {
  .edf { padding: 20px 18px 18px; border-radius: 18px; }
  .edf-row { grid-template-columns: 1fr; }
}
/* The band's secondary button survives the swap and now renders UNDER the
   card. Centring is stated explicitly rather than inherited: two pages define
   .cta-btns twice and the winning rule differs between them. */
.cta-final .edf + .cta-btns {
  justify-content: center;
  margin-top: 18px;
  position: relative;
}
/* The band pads 72px/56px on desktop and the card would otherwise touch the
   rounded corners on a narrow phone. */
@media (max-width: 700px) {
  .cta-final .edf { margin-left: 0; margin-right: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .edf-btn { transition: none; }
}
