/* Popup do formulário de aplicação — mesma linguagem visual da página (verde profundo + creme + dourado) */

.lead { width: min(680px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); margin: auto; padding: 0; border: 1px solid #2a3a26; border-radius: 21px; background: linear-gradient(150deg, #0a2b1a 0%, #04140b 100%); color: var(--cream); box-shadow: 0 40px 120px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(223, 207, 162, 0.06) inset; overflow: hidden; }
.lead::backdrop { background: rgba(3, 12, 7, 0.72); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.lead[open] { display: flex; flex-direction: column; }
.lead__scroll { overflow-y: auto; overscroll-behavior: contain; padding: 52px 52px 44px; }
.lead__close { position: absolute; top: 18px; right: 18px; z-index: 2; display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 245, 220, 0.06); color: var(--cream); transition: background-color 0.3s, transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1); }
.lead__close:hover { background: rgba(255, 245, 220, 0.14); transform: rotate(90deg); }
.lead__close:focus-visible { outline: 2px solid #dfcfa2; outline-offset: 2px; }
.lead__close svg { width: 16px; height: 16px; }

.lead__title { font-family: var(--f-display); font-weight: 500; font-size: 40px; line-height: 46px; color: var(--cream); padding-right: 40px; text-box: normal; }
.lead__title .s { font-size: 46px; }
.lead__form { display: flex; flex-direction: column; gap: 30px; margin-top: 34px; }

.q { border: 0; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.q__label { display: flex; align-items: baseline; gap: 12px; padding: 0; font-size: 18px; line-height: 24px; color: #f3ead2; text-box: normal; }
.q__n { flex: none; font-family: var(--f-display); font-weight: 500; font-size: 15px; background-image: linear-gradient(160deg, #fff5dc, #98885f); -webkit-background-clip: text; background-clip: text; color: transparent; }
.q__hint { font-size: 14px; color: rgba(255, 245, 220, 0.5); }

.field { width: 100%; height: 56px; padding: 0 18px; border: 1px solid rgba(208, 192, 151, 0.2); border-radius: 12px; background: rgba(4, 20, 11, 0.6); color: var(--cream); font: inherit; font-size: 17px; transition: border-color 0.3s, box-shadow 0.3s, background-color 0.3s; }
.field::placeholder { color: rgba(255, 245, 220, 0.35); }
.field:hover { border-color: rgba(208, 192, 151, 0.38); }
.field:focus { outline: none; border-color: #d0c097; background: rgba(4, 20, 11, 0.85); box-shadow: 0 0 0 4px rgba(208, 192, 151, 0.14); }
.field--other { margin-top: 2px; }
.field[hidden] { display: none; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { position: relative; }
.chip input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.chip span { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 10px 18px; border: 1px solid rgba(255, 245, 220, 0.18); border-radius: 100px; font-size: 15px; line-height: 20px; color: #ece3cb; transition: background-color 0.3s, border-color 0.3s, color 0.3s, transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }
.chip span::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; border: 1px solid rgba(255, 245, 220, 0.4); transition: background-color 0.3s, border-color 0.3s; }
.chip input:hover + span { border-color: rgba(208, 192, 151, 0.55); }
.chip input:checked + span { background: linear-gradient(96deg, #fff5dc 30%, #cbb680 140%); border-color: transparent; color: #0e1311; }
.chip input:checked + span::before { background: #0e1311; border-color: #0e1311; }
.chip input:active + span { transform: scale(0.96); }
.chip input:focus-visible + span { outline: 2px solid #dfcfa2; outline-offset: 3px; }

.q.is-invalid .field, .q.is-invalid .chip span { border-color: rgba(215, 103, 103, 0.75); }
.q__error { font-size: 14px; color: #e08a8a; text-box: normal; }
.q__error:empty { display: none; }

.lead__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.lead__submit { display: flex; align-items: center; gap: 8px; width: 100%; margin-top: 6px; }
.lead__submit .cta__pill { flex: 1; height: 72px; padding: 0 24px; font-size: 18px; letter-spacing: 0.04em; font-weight: 500; }
.lead__submit .cta__dot { width: 72px; height: 72px; }
.lead__submit[disabled] { opacity: 0.65; pointer-events: none; }
.lead__status { min-height: 20px; font-size: 15px; text-align: center; color: rgba(255, 245, 220, 0.7); text-box: normal; }
.lead__status.is-error { color: #e08a8a; }

.lead__done { display: none; flex-direction: column; align-items: center; gap: 18px; padding: 24px 0 8px; text-align: center; }
.lead.is-done .lead__form, .lead.is-done .lead__title { display: none; }
.lead.is-done .lead__done { display: flex; }
.lead__done-icon { width: 76px; height: 76px; border-radius: 50%; background: linear-gradient(180deg, #f8da94, #9b8654); display: flex; align-items: center; justify-content: center; }
.lead__done-icon svg { width: 34px; height: 34px; }
.lead__done h2 { font-family: var(--f-display); font-weight: 500; font-size: 36px; line-height: 42px; text-box: normal; }
.lead__done p { max-width: 420px; font-size: 18px; line-height: 27px; color: rgba(255, 245, 220, 0.8); text-box: normal; }

body.has-modal { overflow: hidden; }

@media (prefers-reduced-motion: no-preference) {
  .lead[open] { animation: lead-in 0.55s cubic-bezier(0.22, 1, 0.36, 1); }
  .lead[open]::backdrop { animation: lead-fade 0.4s ease-out; }
  .lead[open] .q { animation: lead-q 0.6s cubic-bezier(0.22, 1, 0.36, 1) both; }
  .lead[open] .q:nth-of-type(2) { animation-delay: 0.05s; }
  .lead[open] .q:nth-of-type(3) { animation-delay: 0.1s; }
  .lead[open] .q:nth-of-type(4) { animation-delay: 0.15s; }
  .lead[open] .q:nth-of-type(5) { animation-delay: 0.2s; }
  .lead.is-done .lead__done { animation: lead-q 0.6s cubic-bezier(0.22, 1, 0.36, 1) both; }
  @keyframes lead-in { from { opacity: 0; transform: translateY(28px) scale(0.97); } }
  @keyframes lead-fade { from { opacity: 0; } }
  @keyframes lead-q { from { opacity: 0; transform: translateY(14px); } }
}

@media (max-width: 640px) {
  .lead { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; border-radius: 0; border: 0; }
  .lead__scroll { padding: 64px 24px 32px; }
  .lead__title { font-size: 30px; line-height: 36px; }
  .lead__title .s { font-size: 36px; }
  .lead__form { gap: 26px; margin-top: 26px; }
  .lead__submit .cta__pill { height: 64px; font-size: 15px; padding: 0 14px; }
  .lead__submit .cta__dot { width: 64px; height: 64px; }
  .chip span { font-size: 14px; padding: 9px 14px; }
}

.lead.is-done .lead__scroll { display: flex; flex-direction: column; justify-content: center; min-height: 100%; }
