/* ============================================================
   Quick Apply — standalone lead-capture form widget
   One box · no page chrome · fitted to a phone screen
   ============================================================ */
:root {
  --qa-ink: #1d161c;
  --qa-body: #4a3a2a;
  --qa-muted: #6b5b4a;
  --qa-cream: #fcf7ea;
  --qa-gold: #e2b15d;
  --qa-bronze: #6e5327;
  --qa-burg: #7b2d26;
  --qa-green: #2c6a47;
  --qa-red: #b4322a;
  --qa-line: rgba(110, 83, 39, 0.3);
}
* {
  box-sizing: border-box;
}
.af2-standalone {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 14px;
  font-family: "Inter", "Inter Fallback", system-ui, sans-serif;
  /* The card ground is #2A1A1E -> #120C10. The old page gradient
     (#1D161C -> #4A231E) measured 1.03:1 against it, so the card had no
     edge — it dissolved into the page. This is deliberately deeper and
     cooler than the card, giving the gold frame something to sit against. */
  background:
    radial-gradient(
      120% 80% at 50% -10%,
      rgba(226, 177, 93, 0.2),
      transparent 58%
    ),
    radial-gradient(
      80% 55% at 12% 108%,
      rgba(123, 45, 38, 0.34),
      transparent 62%
    ),
    radial-gradient(
      70% 50% at 92% 96%,
      rgba(44, 106, 71, 0.16),
      transparent 60%
    ),
    linear-gradient(168deg, #0b0709 0%, #120c10 44%, #1a1014 100%);
  background-attachment: fixed;
  position: relative;
  overflow-x: hidden;
}

/* ── the box ── */
.af2-box {
  width: min(430px, 100%);
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(180deg, #fffdf6, #f8f1de);
  border: 1.5px solid #d9a64c;
  box-shadow:
    0 2px 0 rgba(255, 255, 255, 0.35) inset,
    0 44px 80px -34px rgba(0, 0, 0, 0.72),
    0 0 0 6px rgba(226, 177, 93, 0.1);
}

/* ── masthead — part of the form ── */
.af2-head {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  padding: 16px 18px 14px;
  background: linear-gradient(102deg, #241a1e 0%, #33211f 55%, #4a231e 100%);
  border-bottom: 2px solid var(--qa-gold);
}
.af2-headcoin {
  display: grid;
  place-items: center;
  flex: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #f3da9a, #ecce77 52%, #c9a44e);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.55),
    inset 0 -3px 4px rgba(0, 0, 0, 0.28),
    0 10px 18px -8px rgba(0, 0, 0, 0.6);
}
.af2-headcoin img {
  width: 22px;
  height: 22px;
}
.af2-title {
  margin: 0;
  font:
    800 17.5px/1.2 "Sora",
    "Sora Fallback",
    system-ui;
  color: var(--qa-cream);
  letter-spacing: -0.01em;
}
.af2-tag {
  margin: 3px 0 0;
  font:
    600 10.6px/1.3 "Inter",
    "Inter Fallback",
    system-ui;
  color: #f3d58c;
  letter-spacing: 0.03em;
}
.af2-ribbon {
  position: absolute;
  top: 0;
  right: 16px;
  padding: 5px 9px 7px;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 78%, 0 100%);
  background: linear-gradient(180deg, #8c3b32, #7b2d26);
  font: 800 8.6px/1 "Inter";
  letter-spacing: 0.12em;
  color: var(--qa-cream);
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.4);
}
.af2-progress {
  height: 4px;
  background: rgba(110, 83, 39, 0.16);
}
.af2-progress span {
  display: block;
  height: 100%;
  width: 0;
  transition: width 0.3s ease;
  background: linear-gradient(90deg, var(--qa-gold), var(--qa-burg));
}

/* ── body ── */
.af2-body {
  padding: 14px 16px 16px;
}
.af2-field {
  margin-bottom: 10px;
  min-width: 0;
}
.af2-duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.af2-field label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 5px;
  font: 700 11.6px/1.2 "Inter";
  color: var(--qa-ink);
  letter-spacing: 0.01em;
}
.af2-field label b {
  color: var(--qa-burg);
}
.af2-cap {
  padding: 2px 6px;
  border-radius: 5px;
  background: rgba(226, 177, 93, 0.28);
  font: 800 8.4px/1 "Inter";
  letter-spacing: 0.1em;
  color: #6e5327;
}
.af2-field input,
.af2-field select {
  width: 100%;
  height: 46px;
  padding: 0 13px;
  border-radius: 11px;
  border: 1.5px solid var(--qa-line);
  background: #fffef9;
  font: 500 16px/1 "Inter";
  color: var(--qa-ink); /* 16px stops iOS zoom */
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}
.af2-field select {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236E5327' stroke-width='2.2' stroke-linecap='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 11px center;
  background-size: 15px;
  padding-right: 34px;
}
.af2-field input:focus,
.af2-field select:focus {
  outline: none;
  border-color: #b08542;
  box-shadow: 0 0 0 3.5px rgba(226, 177, 93, 0.32);
}
.af2-field input.is-bad,
.af2-field select.is-bad {
  border-color: var(--qa-red);
  background: #fff7f5;
}
.af2-field input::placeholder {
  color: #a2917c;
  font-size: 13.6px;
}

.af2-phone {
  display: flex;
}
.af2-cc {
  display: grid;
  place-items: center;
  padding: 0 11px;
  border-radius: 11px 0 0 11px;
  border: 1.5px solid var(--qa-line);
  border-right: 0;
  background: #f3e9d2;
  font: 700 13.4px/1 "Inter";
  color: var(--qa-bronze);
}
.af2-phone input {
  border-radius: 0 11px 11px 0;
}
.af2-dob {
  display: grid;
  grid-template-columns: 1fr 1.35fr 1.1fr;
  gap: 8px;
}

.af2-err {
  margin: 4px 0 0;
  font: 600 11.6px/1.45 "Inter";
  color: var(--qa-red);
  display: none;
}
.af2-err.on {
  display: block;
}

.af2-rule {
  margin: 2px 0 10px;
  padding: 10px 13px;
  border-radius: 11px;
  background: #fbf3e0;
  border: 1px solid rgba(226, 177, 93, 0.55);
  border-left: 4px solid var(--qa-bronze);
}
.af2-rule p {
  margin: 0;
  font: 600 12.4px/1.55 "Inter";
  color: var(--qa-ink);
}

.af2-age {
  margin-top: 8px;
  padding: 10px 13px;
  border-radius: 11px;
  font: 600 12.4px/1.55 "Inter";
}
.af2-age.is-ok {
  background: #e8f3ec;
  border: 1px solid var(--qa-green);
  color: #1d4e33;
}
.af2-age.is-bad {
  background: #fbedea;
  border: 1px solid var(--qa-red);
  color: #8a2119;
}
.af2-age.is-info {
  background: #fbf3e0;
  border: 1px solid rgba(226, 177, 93, 0.6);
  color: #5a4620;
}

.af2-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 2px 0 0;
  padding: 11px 13px;
  border-radius: 11px;
  background: #fbf3e0;
  border: 1px solid rgba(226, 177, 93, 0.5);
  cursor: pointer;
}
.af2-check input {
  width: 19px;
  height: 19px;
  flex: none;
  margin-top: 1px;
  accent-color: var(--qa-burg);
}
.af2-check span {
  font: 400 11.9px/1.55 "Inter";
  color: var(--qa-body);
}

.af2-summary {
  margin: 10px 0 0;
  padding: 11px 14px;
  border-radius: 11px;
  background: #fbedea;
  border: 1.5px solid var(--qa-red);
}
.af2-summary ul {
  margin: 0;
  padding-left: 17px;
}
.af2-summary li {
  font: 500 12px/1.6 "Inter";
  color: #8a2119;
}

/* ── submit: the burgundy 3D plate ── */
.af2-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 52px;
  margin-top: 12px;
  border: 0;
  border-radius: 13px;
  cursor: pointer;
  font:
    800 15px/1 "Sora",
    "Sora Fallback",
    "Inter",
    "Inter Fallback",
    system-ui;
  letter-spacing: 0.01em;
  color: var(--qa-cream);
  background: linear-gradient(180deg, #8c3b32 0%, #7b2d26 58%, #5a1f1a 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    inset 0 -3px 0 rgba(0, 0, 0, 0.32),
    0 14px 26px -12px rgba(90, 31, 26, 0.8);
  transition:
    transform 0.15s,
    filter 0.15s;
}
.af2-submit:hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
}
.af2-submit:active {
  transform: translateY(2px);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.35);
}
.af2-submit:disabled {
  opacity: 0.55;
  transform: none;
  cursor: wait;
}
.af2-submit:focus-visible {
  outline: 3px solid var(--qa-gold);
  outline-offset: 3px;
}
.af2-subcoin {
  display: grid;
  place-items: center;
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.34));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.26);
}
.af2-subcoin img {
  width: 15px;
  height: 15px;
  filter: brightness(0) invert(1);
}

.af2-foot {
  margin: 10px 0 0;
  text-align: center;
  font: 500 10.8px/1.5 "Inter";
  color: var(--qa-muted);
}

/* ── success state ── */
.af2-done {
  padding: 34px 22px;
  text-align: center;
}
.af2-done-seal {
  display: block;
  width: 64px;
  margin: 0 auto 14px;
}
.af2-done h2 {
  margin: 0 0 8px;
  font: 800 21px/1.2 "Sora";
  color: #1d4e33;
}
.af2-done p {
  margin: 0 auto;
  max-width: 40ch;
  font: 400 13.4px/1.7 "Inter";
  color: var(--qa-body);
}

/* ── small phones ── */
@media (max-width: 380px) {
  .af2-body {
    padding: 12px 12px 14px;
  }
  .af2-duo {
    gap: 8px;
  }
  .af2-title {
    font-size: 16px;
  }
}
/* ── short screens: tighten so the box needs less scrolling ── */
@media (max-height: 760px) {
  .af2-field {
    margin-bottom: 8px;
  }
  .af2-field input,
  .af2-field select {
    height: 44px;
  }
  .af2-head {
    padding: 13px 16px 11px;
  }
}

/* masthead logo (the real seal, as in the header) + consent links */
.af2-headlogo {
  display: grid;
  place-items: center;
  flex: none;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #fff6df, #f3da9a 60%, #c9a44e);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.6),
    inset 0 -3px 4px rgba(0, 0, 0, 0.24),
    0 10px 18px -8px rgba(0, 0, 0, 0.6);
}
.af2-headlogo img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: contain;
  image-rendering: auto;
}

/* ── embedded mode: the widget inside a normal page (apply / contact) ── */
.af2-embed {
  max-width: 560px;
  margin-inline: auto;
}
.af2-embed .af2-box {
  width: 100%;
  box-shadow:
    0 28px 60px -34px rgba(29, 22, 28, 0.5),
    inset 0 2px 0 rgba(255, 255, 255, 0.35);
}

/* Faint horizon rule + grain so the deep field reads as designed
   rather than as an empty black page. Purely decorative. */
.af2-standalone::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.014) 0 1px,
      transparent 1px 3px
    ),
    radial-gradient(
      1.4px 1.4px at 18% 22%,
      rgba(243, 213, 140, 0.42) 50%,
      transparent 51%
    ),
    radial-gradient(
      1.2px 1.2px at 76% 14%,
      rgba(243, 213, 140, 0.34) 50%,
      transparent 51%
    ),
    radial-gradient(
      1.1px 1.1px at 44% 84%,
      rgba(243, 213, 140, 0.28) 50%,
      transparent 51%
    ),
    radial-gradient(
      1.3px 1.3px at 88% 72%,
      rgba(243, 213, 140, 0.3) 50%,
      transparent 51%
    );
  opacity: 0.8;
}
.af2-standalone > * {
  position: relative;
  z-index: 1;
}
/* <main> was added for the H1/landmark. Without this it stretches full width
   and the card left-aligns inside it. */
.af2-standalone > main {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
/* Skip link must stay hidden until focused. The page has no other stylesheet
   defining it, so it was rendering inline at the top. */
.af2-standalone .hb-skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 60;
}
.af2-standalone .hb-skip:focus {
  left: 14px;
  top: 14px;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--hbc-gold, #f5c542);
  color: #20180b;
  font-weight: 800;
  text-decoration: none;
}
@media (prefers-reduced-motion: reduce) {
  .af2-standalone::before {
    background-image: none;
  }
}
