/*
 * Camada visual da aplicação.
 * Mantém os seletores históricos usados pelos JavaScript, alterando apenas a
 * apresentação. Carregada depois de style.css e dos estilos de produto.
 */

:root {
  --ft-orange: #ff6600;
  --ft-navy: #021f5f;
  --ft-ink: #17213a;
  --ft-muted: #64748b;
  --ft-surface: #ffffff;
  --ft-canvas: #f3f7fd;
  --ft-line: #d9e3f0;
  --ft-danger: #c62828;
  --ft-radius-sm: 10px;
  --ft-radius: 16px;
  --ft-radius-lg: 24px;
  --ft-shadow-sm: 0 8px 24px rgba(2, 31, 95, 0.08);
  --ft-shadow: 0 24px 70px rgba(2, 31, 95, 0.14);
}

html {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  scroll-behavior: smooth;
  background: var(--ft-canvas);
}

body.app-shell {
  width: 100%;
  max-width: 100%;
  min-width: 280px;
  margin: 0;
  overflow-x: hidden;
  color: var(--ft-ink);
  background: var(--ft-canvas);
  font-family: "Montserrat", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.app-shell *,
body.app-shell *::before,
body.app-shell *::after {
  box-sizing: border-box;
}

body.app-shell img {
  max-width: 100%;
}

body.app-shell a,
body.app-shell button,
body.app-shell input,
body.app-shell select,
body.app-shell textarea {
  transition: border-color 180ms ease, box-shadow 180ms ease, color 180ms ease, background-color 180ms ease, transform 180ms ease;
}

/* Botões de escolha e comandos auxiliares usam peso normal. */
body.app-shell button,
body.app-shell .btn,
body.app-shell input[type="button"],
body.app-shell input[type="reset"] {
  font-weight: 400 !important;
}

/* O negrito fica reservado às ações principais de conversão e envio. */
body.app-shell .bg-next,
body.app-shell .bg-enviar-proposta,
body.app-shell .bg-resultado,
body.app-shell .bg-resultado2,
body.app-shell button[type="submit"],
body.app-shell input[type="submit"] {
  font-weight: 700 !important;
}

body.app-shell :focus-visible {
  outline: 3px solid color-mix(in srgb, var(--primary-color) 35%, white);
  outline-offset: 3px;
}

#conteudo-principal {
  min-height: 48vh;
}

body.app-shell[data-stage="obrigado"]:not(.route-emprestimo-condominios) #conteudo-principal {
  padding-top: clamp(24px, 4vw, 44px);
}

.ft-home-intro {
  min-height: 54vh;
  padding: clamp(52px, 9vw, 108px) 18px;
  background:
    radial-gradient(circle at 12% 18%, rgba(43, 114, 238, 0.16), transparent 33%),
    radial-gradient(circle at 88% 16%, rgba(255, 102, 0, 0.12), transparent 28%),
    linear-gradient(180deg, #f8fbff 0%, #edf4fd 100%);
}

.ft-home-card {
  max-width: 820px;
  margin: 0 auto;
  padding: clamp(30px, 6vw, 58px);
  border: 1px solid rgba(43, 114, 238, 0.15);
  border-radius: var(--ft-radius-lg);
  background: #fff;
  box-shadow: var(--ft-shadow);
  text-align: center;
}

.ft-home-eyebrow,
.ft-form-kicker {
  margin: 0 0 8px;
  color: var(--ft-orange);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ft-home-card h1 {
  margin: 0 0 18px;
  color: var(--ft-navy);
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 800;
  line-height: 1.12;
}

.ft-home-card > p:not(.ft-home-eyebrow) {
  max-width: 650px;
  margin: 0 auto;
  color: var(--ft-muted);
  font-size: 1rem;
}

.ft-home-cta {
  max-width: 330px;
  margin: 30px auto 0;
  text-decoration: none;
}

.ft-insurance-page .form-simulador {
  max-width: 680px;
}

.ft-insurance-header {
  justify-content: flex-start;
}

.ft-insurance-header .container-header-textos {
  max-width: 100%;
}

.ft-insurance-header .ft-form-kicker {
  text-align: left;
}

.ft-insurance-page .ft-insurance-choices {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.ft-insurance-page .ft-insurance-choices > .bg-modelo {
  width: 100% !important;
}

@media (max-width: 540px) {
  .ft-insurance-page .ft-insurance-choices {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.ft-optional {
  color: var(--ft-muted);
  font-size: 0.8rem;
  font-weight: 500;
}

.ft-form-response {
  margin: 8px 0 14px;
  padding: 14px 16px;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 600;
}

.ft-form-response.is-error {
  border: 1px solid #ef9a9a;
  color: #991b1b;
  background: #fff1f2;
}

.ft-form-response.is-success {
  border: 1px solid #86efac;
  color: #166534;
  background: #f0fdf4;
}

.ft-success-card {
  text-align: center;
}

.ft-success-card .ft-success-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  margin-bottom: 18px;
  border-radius: 50%;
  color: #fff;
  background: #16a34a;
  font-size: 2rem;
  font-weight: 800;
}

.ft-success-card > p:not(.ft-form-kicker) {
  color: var(--ft-muted);
}

/* A confirmação intermediária começa oculta; ao aparecer, sua mensagem deve
 * permanecer legível e o link deve funcionar mesmo se o script não carregar. */
body.app-shell.route-garantia-de-imoveis .processando_continua {
  opacity: 1 !important;
  transform: none !important;
}

body.app-shell.route-garantia-de-imoveis .processando_continua .msg_aguarde {
  width: min(100%, 680px);
  margin: 0 auto 24px;
  padding: 24px;
  border: 1px solid rgba(43, 114, 238, 0.18);
  border-radius: var(--ft-radius);
  color: var(--ft-navy);
  background: #fff;
}

body.app-shell.route-garantia-de-imoveis .processando_continua .msg_aguarde h1 {
  color: var(--primary-color);
}

body.app-shell.route-garantia-de-imoveis .processando_continua .msg_aguarde p {
  color: var(--ft-muted);
}

.ft-success-card .bg-next {
  max-width: 330px;
  margin-right: auto;
  margin-left: auto;
  text-decoration: none;
}

/* As confirmações antigas conservam seu conteúdo e ações, mas usam o cartão
 * visual da confirmação de seguros. Os seletores só valem na rota /obrigado. */
body.app-shell[data-stage="obrigado"] .progresso-inicio,
body.app-shell[data-stage="obrigado"] .progresso-imoveis,
body.app-shell[data-stage="obrigado"] .progresso-giro,
body.app-shell[data-stage="obrigado"] .progresso-resposivo,
body.app-shell[data-stage="obrigado"] .progresso-resposivo-imoveis,
body.app-shell[data-stage="obrigado"] .progresso-resposivo-giro,
body.app-shell[data-stage="obrigado"] .bg-simulador .texto-lateral,
body.app-shell[data-stage="obrigado"] .form-simulador form > .conteudo {
  display: none !important;
}

body.app-shell[data-stage="obrigado"] .resultado_espaco {
  width: min(100%, 760px);
  min-height: 0 !important;
  margin: 0 auto !important;
  padding: 0 18px;
  background: transparent !important;
}

body.app-shell[data-stage="obrigado"] .msg_aguarde:has(> .processando_final) {
  width: 100%;
  padding: 0 18px;
  background: transparent !important;
}

body.app-shell[data-stage="obrigado"] .form-simulador:has(.processando_final) {
  width: min(100%, 760px);
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

body.app-shell[data-stage="obrigado"] .processando_final,
body.app-shell[data-stage="obrigado"] .energia-assinatura-page .energia-obrigado-box {
  width: min(100%, 680px) !important;
  max-width: 680px !important;
  min-height: 0;
  margin: 0 auto !important;
  padding: clamp(32px, 6vw, 48px) !important;
  border: 1px solid rgba(43, 114, 238, 0.13) !important;
  border-radius: var(--ft-radius-lg) !important;
  color: var(--ft-muted) !important;
  background: #fff !important;
  box-shadow: var(--ft-shadow) !important;
  text-align: center;
  opacity: 1 !important;
  transform: none !important;
}

body.app-shell[data-stage="obrigado"] .processando_final::before,
body.app-shell[data-stage="obrigado"] .energia-obrigado-box::before {
  content: "✓";
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  border-radius: 50%;
  color: #fff;
  background: #16a34a;
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
}

body.app-shell[data-stage="obrigado"] .processando_final .msg_aguarde {
  width: 100%;
  margin: 0 !important;
  padding: 0 !important;
  color: inherit;
  background: transparent !important;
}

body.app-shell[data-stage="obrigado"] .processando_final h1,
body.app-shell[data-stage="obrigado"] .energia-obrigado-box h1 {
  margin: 0 0 24px !important;
  padding: 0 !important;
  color: var(--primary-color-fade) !important;
  font-family: inherit;
  font-size: clamp(1.8rem, 4vw, 2.35rem) !important;
  font-weight: 800 !important;
  line-height: 1.18 !important;
}

body.app-shell[data-stage="obrigado"] .processando_final h1::before,
body.app-shell[data-stage="obrigado"] .energia-obrigado-box h1::before {
  content: "Solicitação recebida";
  display: block;
  margin-bottom: 8px;
  color: var(--ft-orange);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
}

body.app-shell[data-stage="obrigado"] .processando_final p,
body.app-shell[data-stage="obrigado"] .energia-obrigado-box p {
  max-width: 580px;
  margin: 0 auto 14px !important;
  padding: 0 !important;
  color: var(--ft-muted) !important;
  font-size: 1rem !important;
  line-height: 1.65 !important;
}

body.app-shell[data-stage="obrigado"] .processando_final h2 {
  margin: 22px 0 0 !important;
  color: var(--primary-color-fade);
  font-size: 1.2rem;
}

body.app-shell[data-stage="obrigado"] .imagem-obrigado-parceiros {
  display: block;
  width: min(220px, 60%);
  margin: 18px auto;
}

body.app-shell[data-stage="obrigado"] .texto-destaque-obrigado-parceiros {
  text-decoration-color: currentColor;
}

body.app-shell[data-stage="obrigado"] .energia-assinatura-page {
  background:
    radial-gradient(circle at 12% 12%, color-mix(in srgb, var(--primary-color) 14%, transparent) 0, transparent 34%),
    linear-gradient(180deg, #f8fbff 0%, #edf4fd 100%) !important;
}

body.app-shell[data-stage="obrigado"] .energia-obrigado-wrap {
  padding: 0 18px 50px;
}

body.app-shell[data-stage="obrigado"] .energia-assinatura-page .energia-obrigado-box {
  margin: 0 auto !important;
}

body.app-shell[data-stage="obrigado"].route-afiliados .form-simulador,
body.app-shell[data-stage="obrigado"].route-parceiros .form-simulador {
  max-width: 680px;
}

body.app-shell[data-stage="obrigado"].route-afiliados #parcelas,
body.app-shell[data-stage="obrigado"].route-parceiros #parcelas,
body.app-shell[data-stage="obrigado"].route-consignado-empresas #parcelas {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent !important;
}

body.app-shell[data-stage="obrigado"].route-afiliados #parcelas::before,
body.app-shell[data-stage="obrigado"].route-parceiros #parcelas::before {
  content: "✓";
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  border-radius: 50%;
  color: #fff;
  background: #16a34a;
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
}

body.app-shell[data-stage="obrigado"].route-afiliados #parcelas h1,
body.app-shell[data-stage="obrigado"].route-parceiros #parcelas h1 {
  margin: 0 0 24px;
  color: var(--primary-color-fade);
  font-size: clamp(1.8rem, 4vw, 2.35rem);
  font-weight: 800;
  line-height: 1.18;
}

body.app-shell[data-stage="obrigado"].route-afiliados #parcelas h1::before,
body.app-shell[data-stage="obrigado"].route-parceiros #parcelas h1::before {
  content: "Solicitação recebida";
  display: block;
  margin-bottom: 8px;
  color: var(--ft-orange);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body.app-shell[data-stage="obrigado"].route-afiliados #parcelas p,
body.app-shell[data-stage="obrigado"].route-parceiros #parcelas p {
  margin: 0 auto 14px;
  color: var(--ft-muted);
  font-size: 1rem;
  line-height: 1.65;
}

.site-header {
  position: relative;
  z-index: 50;
  box-shadow: 0 8px 30px rgba(2, 31, 95, 0.14);
}

.site-header .topo {
  display: flex !important;
  min-height: 92px;
  height: auto;
  padding: 12px 0;
  background: linear-gradient(120deg, var(--primary-color) 0%, color-mix(in srgb, var(--primary-color) 84%, var(--ft-navy)) 100%);
}

.container-header-logo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 68px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 0;
}

.brand-link img {
  display: block;
  max-width: min(282px, 62vw);
  object-fit: contain;
}

#logo-responsivo {
  display: none;
}

.header-product {
  max-width: 360px;
  padding: 9px 14px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.35;
  text-align: right;
  backdrop-filter: blur(8px);
}

#preloader {
  background: rgba(255, 255, 255, 0.96);
}

.preloader-img {
  width: min(260px, 70vw);
}

.bg-simulador {
  position: relative;
  min-height: 620px !important;
  margin-top: 0;
  padding: clamp(34px, 6vw, 78px) 18px clamp(52px, 8vw, 96px);
  background:
    radial-gradient(circle at 12% 12%, color-mix(in srgb, var(--primary-color) 14%, transparent) 0, transparent 34%),
    radial-gradient(circle at 90% 18%, rgba(255, 102, 0, 0.10) 0, transparent 27%),
    linear-gradient(180deg, #f8fbff 0%, #edf4fd 100%);
}

.form-simulador,
#msg-aviso-inicio {
  position: relative;
  left: auto;
  right: auto;
  width: min(100%, 760px);
  min-height: 0;
  margin: 0 auto;
  padding: clamp(24px, 5vw, 48px);
  border: 1px solid rgba(43, 114, 238, 0.13);
  border-radius: var(--ft-radius-lg);
  background: var(--ft-surface);
  box-shadow: var(--ft-shadow);
}

.form-simulador form {
  margin-top: 0;
}

.form-simulador h1,
.form-simulador h2,
.form-simulador h3 {
  color: var(--primary-color-fade);
  font-family: inherit;
}

.form-simulador h1 {
  margin-bottom: 28px;
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 750;
  line-height: 1.18;
}

.form-simulador h2 {
  margin-bottom: 12px;
  font-size: clamp(1.25rem, 3vw, 1.55rem);
  font-weight: 650;
  line-height: 1.3;
}

.form-simulador h3 {
  margin: 0 0 24px;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.55;
}

.container-header-form {
  align-items: center;
  justify-content: center;
  gap: clamp(18px, 4vw, 38px);
  margin: calc(clamp(24px, 5vw, 48px) * -1) calc(clamp(24px, 5vw, 48px) * -1) 36px;
  padding: clamp(24px, 5vw, 40px);
  overflow: hidden;
  border-bottom: 1px solid rgba(43, 114, 238, 0.12);
  border-radius: var(--ft-radius-lg) var(--ft-radius-lg) 0 0;
  background: linear-gradient(135deg, color-mix(in srgb, var(--primary-color) 8%, white), #fff 62%);
}

.container-header-form-img {
  width: auto;
  max-width: 180px;
  height: 126px;
  object-fit: contain;
}

.container-header-textos {
  align-items: flex-start;
  max-width: 410px;
}

.container-header-textos > h1,
.container-header-textos > h2,
.container-header-textos > h3 {
  text-align: left;
}

.container-header-textos > h1 {
  margin: 0 0 12px;
  font-size: clamp(1.65rem, 4vw, 2.15rem);
  font-weight: 750;
  line-height: 1.2;
}

.container-header-textos > h3,
.container-header-textos > h3:nth-child(3) {
  margin: 4px 0;
  font-size: 0.96rem;
  line-height: 1.45;
}

.texto-lateral {
  display: none;
}

.form-group {
  margin-bottom: 1.35rem;
}

.form-group label,
.form-label {
  display: block;
  margin-bottom: 9px;
  color: #334155;
  font-size: 0.95rem;
  font-weight: 650;
  line-height: 1.45;
}

.form-control,
.nice-select,
body.app-shell select.form-control,
body.app-shell textarea.form-control {
  width: 100%;
  min-height: 52px;
  padding: 12px 15px;
  border: 1px solid var(--ft-line);
  border-radius: var(--ft-radius-sm);
  color: var(--ft-ink) !important;
  background: #fff !important;
  font-size: 1rem;
  line-height: 1.45;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
}

textarea.form-control {
  min-height: 120px;
}

.form-control:hover,
.nice-select:hover {
  border-color: color-mix(in srgb, var(--primary-color) 45%, var(--ft-line));
}

.form-control:focus,
.nice-select.open,
.nice-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary-color) 13%, transparent);
}

body.app-shell input[type="email"],
body.app-shell input[type="url"] {
  text-transform: none;
}

.nice-select {
  height: 52px;
  margin-bottom: 12px;
  line-height: 27px;
}

.nice-select .list {
  padding-top: 54px;
  border: 1px solid var(--ft-line);
  border-radius: 12px;
  box-shadow: var(--ft-shadow-sm);
}

/* Mantém os selects pesquisáveis acima dos botões das perguntas seguintes. */
.ft-wizard-active .nice-select.open {
  z-index: 1100;
}

.ft-wizard-active .nice-select.open .list {
  z-index: 1101;
}

.ft-wizard-active .nice-select.open .nice-select-search-box {
  z-index: 1102;
  opacity: 1 !important;
  pointer-events: auto !important;
  transform: scale(1) translateY(0) !important;
}

.campo-obrigatorio {
  float: none;
  margin: 6px 0 0;
  color: var(--ft-danger);
  font-size: 0.82rem;
  font-weight: 600;
}

.campo-obrigatorio-2 {
  float: none;
  margin-left: 4px;
  color: var(--ft-danger) !important;
}

/* A faixa legada escondia o campo com problema, principalmente no celular.
 * As regras dos formulários continuam acionando os mesmos marcadores; a camada
 * comum os apresenta perto do botão que iniciou a validação. */
.msg_informacao_obrigatorio {
  display: none !important;
}

.ft-validation-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  width: 100%;
  margin: 10px 0 14px;
  padding: 16px 18px;
  border: 1px solid #ef9a9a;
  border-left: 5px solid var(--ft-danger);
  border-radius: 12px;
  color: #7f1d1d;
  background: #fff1f2;
  box-shadow: 0 8px 22px rgba(127, 29, 29, 0.09);
}

.ft-validation-summary-copy {
  min-width: 0;
}

.ft-validation-summary strong {
  display: block;
  margin-bottom: 2px;
  font-size: 0.96rem;
  line-height: 1.4;
}

.ft-validation-summary p {
  margin: 0;
  color: #991b1b;
  font-size: 0.86rem;
  line-height: 1.45;
}

.ft-validation-jump {
  flex: 0 0 auto;
  min-height: 42px;
  padding: 9px 13px;
  border: 1px solid #b91c1c;
  border-radius: 9px;
  color: #fff;
  background: #b91c1c;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
}

.ft-validation-jump:hover {
  color: #fff;
  background: #991b1b;
}

.ft-validation-target {
  border-color: var(--ft-danger) !important;
  box-shadow: 0 0 0 4px rgba(198, 40, 40, 0.13) !important;
}

.form-simulador .form-group > div[class^="btn-"],
.form-simulador .form-group > div[class*=" btn-"],
.form-simulador .estado-civil,
.form-simulador .tempo-servico,
.form-simulador .objetivo,
.form-simulador .prazo {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  width: 100%;
}

/* As classes históricas já indicam a proporção esperada de cada grupo.
 * Grid mantém todas as opções com a mesma largura, inclusive a última linha. */
.form-simulador .btn-50,
.form-simulador .btn-30,
.form-simulador .btn-25 {
  display: grid !important;
  align-items: stretch;
}

.form-simulador .btn-50 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-simulador .btn-30 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.form-simulador .btn-25 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

/* Os dois prazos coexistem no HTML legado; exibe só o da operação atual. */
.route-financiamento-de-imoveis .form-simulador #prazo-refi-imovel,
.route-garantia-de-imoveis .form-simulador #prazo-fina-imovel {
  display: none !important;
}

.route-financiamento-de-imoveis .form-simulador #prazo-fina-imovel {
  display: grid !important;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.route-financiamento-de-imoveis .form-simulador #prazo-fina-imovel > button {
  width: 100% !important;
  min-width: 0;
  margin: 0 !important;
}

.route-financiamento-de-imoveis .ft-finance-range {
  margin-top: 20px;
}

.route-financiamento-de-imoveis #valor_precisa_imovel + .valor-imovel {
  margin-top: 16px;
}

.route-financiamento-de-imoveis .ft-finance-range[hidden] {
  display: none !important;
}

.route-financiamento-de-imoveis .ft-finance-range > label {
  display: block;
  margin-bottom: 10px;
  color: #35445b;
  font-weight: 600;
}

.route-financiamento-de-imoveis .ft-finance-range > input[type="range"] {
  display: block;
  width: 100%;
  margin: 0;
  accent-color: #2b72ee;
  cursor: pointer;
}

.route-financiamento-de-imoveis .ft-finance-range-limits {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
  color: #52627a;
  font-size: 0.84rem;
}

@media (max-width: 768px) {
  .route-financiamento-de-imoveis .form-simulador #prazo-fina-imovel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.form-simulador .btn-50 > .row,
.form-simulador .btn-30 > .row,
.form-simulador .btn-25 > .row {
  display: none;
}

.form-simulador .btn-50 > .bg-modelo,
.form-simulador .btn-30 > .bg-modelo,
.form-simulador .btn-25 > .bg-modelo {
  width: 100% !important;
}

.form-simulador.ft-step-enter {
  animation: ft-step-enter 220ms ease-out both;
}

@keyframes ft-step-enter {
  from {
    opacity: 0.55;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.ft-submit-feedback {
  width: 100%;
  margin: 10px 0 14px;
  padding: 14px 16px;
  border: 1px solid #ef9a9a;
  border-left: 5px solid var(--ft-danger);
  border-radius: 12px;
  color: #7f1d1d;
  background: #fff1f2;
  font-size: 0.9rem;
  line-height: 1.5;
}

.ft-important-note {
  width: 100%;
  padding: 22px clamp(18px, 4vw, 34px);
  border: 1px solid #f27b63;
  border-radius: var(--ft-radius);
  color: #ffffff;
  background: linear-gradient(135deg, #ef775f 0%, #f18d78 100%);
  box-shadow: 0 12px 28px rgba(198, 40, 40, 0.14);
  text-align: center;
}

.ft-important-note strong {
  display: block;
  margin-bottom: 12px;
  font-size: clamp(1.1rem, 2.5vw, 1.35rem);
  line-height: 1.35;
}

.ft-important-note strong span {
  display: inline-grid;
  width: 1.35em;
  height: 1.35em;
  margin-left: 4px;
  place-items: center;
  border-radius: 50%;
  color: #ef775f;
  background: #ffffff;
  font-size: 0.75em;
}

.ft-important-note p {
  margin: 0;
  color: inherit;
  font-size: 1rem;
  line-height: 1.6;
}

.ft-question-help {
  margin: 4px 0 12px;
  color: #64748b;
  font-size: 0.92rem;
  line-height: 1.45;
}

.ft-other-purpose[hidden] {
  display: none !important;
}

.form-simulador .bg-modelo {
  flex: 1 1 132px;
  min-width: 0;
  min-height: 48px;
  margin: 0 !important;
  padding: 10px 13px;
  border: 1px solid var(--ft-line);
  border-radius: 12px;
  color: #475569;
  background: #fff;
  font-size: 0.92rem;
  font-weight: 400;
  white-space: normal;
  box-shadow: none;
}

@media (min-width: 769px) {
  .route-emprestimo-condominios .form-simulador #como_se_identifica {
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
  }

  .route-emprestimo-condominios .form-simulador #como_se_identifica > .bg-modelo {
    width: 100% !important;
    min-width: 0;
    padding: 8px 5px;
    font-size: 0.82rem;
    line-height: 1.2;
  }
}

:is(.route-garantia-de-veiculos, .route-financiamento-de-veiculos) .form-simulador .btn-tipo-veiculo {
  display: grid !important;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: stretch;
  gap: 8px !important;
}

:is(.route-garantia-de-veiculos, .route-financiamento-de-veiculos) .form-simulador .btn-tipo-veiculo > button {
  width: 100% !important;
  min-width: 0;
  min-height: 48px;
  padding: 8px 4px !important;
  font-size: 0.78rem;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

@media (max-width: 540px) {
  :is(.route-garantia-de-veiculos, .route-financiamento-de-veiculos) .form-simulador .btn-tipo-veiculo {
    gap: 5px !important;
  }

  :is(.route-garantia-de-veiculos, .route-financiamento-de-veiculos) .form-simulador .btn-tipo-veiculo > button {
    padding: 8px 2px !important;
    font-size: 0.68rem;
  }
}

.form-simulador .bg-modelo:hover {
  border-color: var(--primary-color-fade);
  color: var(--primary-color-fade);
  transform: translateY(-1px);
}

.form-simulador .bg-modelo.active,
.form-simulador .bg-modelo.active:hover {
  border-color: var(--primary-color-fade);
  color: #fff;
  background: var(--primary-color-fade);
  box-shadow: 0 8px 18px color-mix(in srgb, var(--primary-color) 24%, transparent);
}

.bg-next,
.bg-enviar-proposta,
.bg-resultado,
.bg-resultado2 {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 54px;
  margin: 24px 0 8px;
  padding: 13px 20px;
  border: 0;
  border-radius: 13px;
  color: #fff;
  background: linear-gradient(135deg, var(--secondary-color), color-mix(in srgb, var(--secondary-color) 78%, var(--primary-color)));
  font-size: 1rem;
  font-weight: 750;
  line-height: 1.25;
  text-transform: none;
  box-shadow: 0 12px 24px color-mix(in srgb, var(--secondary-color) 25%, transparent);
}

.bg-next:hover,
.bg-enviar-proposta:hover,
.bg-resultado:hover,
.bg-resultado2:hover {
  color: #fff;
  background: var(--secondary-color);
  box-shadow: 0 8px 18px color-mix(in srgb, var(--secondary-color) 22%, transparent);
  transform: translateY(-1px);
}

.bg-next:disabled,
.bg-next[disabled],
#btn-enviar-proposta:disabled,
#btn-enviar-proposta[disabled] {
  border: 1px solid #cbd5e1;
  color: #64748b;
  background: #e2e8f0;
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

.progresso-inicio ul,
.progresso ul,
.progresso-imoveis ul,
.progresso-giro ul,
.progresso-resposivo ul,
.progresso-resposivo-imoveis ul,
.progresso-resposivo-giro ul {
  margin-bottom: 0;
  background-color: #dbe5f2;
}

.resultado_espaco > div,
.msg-restricao-cpf,
.msg-restricao-cidade,
.msg-simulacao-preenchida,
.msg-boas-vindas {
  border-radius: var(--ft-radius);
}

.new_duvidas {
  padding: clamp(48px, 7vw, 88px) 18px;
  background: #fff;
}

.new_duvidas .container {
  max-width: 900px;
}

.new_duvidas h1 {
  margin-bottom: 30px;
  color: var(--ft-navy);
  font-size: clamp(1.65rem, 4vw, 2.15rem);
}

.new_duvidas p.app-duvidas-titulo {
  margin: 12px 0 0;
  padding: 17px 20px;
  border: 1px solid var(--ft-line);
  border-radius: 12px;
  background: #fff;
  font-size: 1rem;
  font-weight: 650;
  box-shadow: 0 4px 14px rgba(2, 31, 95, 0.05);
}

.new_duvidas p.app-duvidas-titulo:hover {
  border-color: color-mix(in srgb, var(--primary-color) 45%, var(--ft-line));
  box-shadow: var(--ft-shadow-sm);
}

.new_duvidas p.app-duvidas-titulo + span {
  padding: 16px 20px 4px;
  color: #526077;
  font-size: 0.96rem;
  line-height: 1.7;
}

.back-top-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--ft-orange);
  box-shadow: 0 8px 22px rgba(255, 102, 0, 0.3);
}

.site-footer.rodape {
  height: auto;
  padding: 52px 18px 26px !important;
  color: #fff;
  background: linear-gradient(145deg, var(--rodape-color), color-mix(in srgb, var(--rodape-color) 82%, #000)) !important;
  font-family: inherit;
}

.site-footer .container-geral {
  max-width: 1180px;
}

.site-footer .contatos-rodape {
  gap: 28px;
  margin-bottom: 34px;
  padding-bottom: 34px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.site-footer .img-container-rodape {
  display: inline-flex;
}

.site-footer .img-container-rodape img {
  width: min(242px, 64vw);
}

.site-footer .redes-sociais-container-rodape {
  gap: 12px;
}

.site-footer .redes-sociais-container-rodape > .fa-brands {
  width: 48px;
  height: 48px;
  margin: 0;
  color: var(--primary-color);
  font-size: 1.25rem;
}

.site-footer .selos-rodape {
  gap: 20px;
}

.site-footer .selo-google {
  width: 142px;
  height: auto;
}

.site-footer .informacoes-legais-rodape {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 34px;
}

.site-footer .informacoes-legais-rodape > p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.84rem;
  line-height: 1.75;
  text-align: left;
}

.site-footer .informacoes-legais-rodape > p:nth-child(3),
.site-footer .informacoes-legais-rodape > p:nth-child(4),
.site-footer .informacoes-legais-rodape > p:nth-child(5) {
  grid-column: 1 / -1;
}

.site-footer .informacoes-legais-rodape a {
  color: #fff;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.security-notice {
  position: relative;
  z-index: 60;
  border-bottom: 1px solid #e45100;
  color: #fff;
  background: linear-gradient(105deg, #e45100 0%, var(--ft-orange) 52%, #f47a24 100%);
  box-shadow: 0 5px 18px rgba(99, 36, 0, 0.18);
}

.security-notice[hidden] {
  display: none !important;
}

.security-notice-inner {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 42px;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.security-notice-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 50%;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1;
}

.security-notice p {
  margin: 0;
  color: #fff;
  font-size: 0.86rem;
  line-height: 1.45;
  text-align: center;
}

.security-notice p strong {
  font-weight: 800;
}

#close-security-notice {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  margin-left: auto;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 10px;
  color: #fff;
  background: rgba(2, 31, 95, 0.28);
  font: inherit;
  font-size: 1.65rem;
  line-height: 1;
  cursor: pointer;
}

#close-security-notice:hover {
  border-color: #fff;
  background: rgba(2, 31, 95, 0.5);
}

#close-security-notice:focus-visible {
  outline-color: #fff;
}

#cookie {
  position: fixed;
  right: 20px;
  bottom: 20px;
  left: auto;
  display: none;
  align-items: center;
  gap: 18px;
  width: min(640px, calc(100vw - 40px));
  margin: 0;
  padding: 18px;
  border: 1px solid var(--ft-line);
  border-radius: 16px;
  color: var(--ft-ink);
  background: #fff;
  box-shadow: 0 22px 60px rgba(2, 31, 95, 0.24);
  z-index: 9999;
}

#cookie p {
  flex: 1 1 auto;
  margin: 0;
  font-size: 0.86rem;
  line-height: 1.55;
}

#cookie a {
  color: var(--primary-color);
}

#cookie button {
  flex: 0 0 auto;
  width: auto;
  padding: 10px 14px;
  border: 0;
  border-radius: 10px;
  color: #fff;
  background: var(--primary-color);
  font-size: 0.86rem;
  font-weight: 700;
}

.partner-footer {
  padding: 34px 18px;
}

.partner-footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.partner-footer img {
  width: auto;
  max-width: min(250px, 60vw);
  max-height: 86px;
  object-fit: contain;
}

.not-found {
  max-width: 720px;
  padding: 100px 18px;
  text-align: center;
}

.not-found-code {
  display: block;
  color: var(--primary-color);
  font-size: clamp(4rem, 15vw, 8rem);
  font-weight: 800;
  line-height: 1;
  opacity: 0.15;
}

.not-found h1 {
  margin-top: -20px;
  color: var(--ft-navy);
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  font-weight: 750;
}

.not-found p {
  color: var(--ft-muted);
}

.not-found .bg-next {
  max-width: 320px;
  text-decoration: none;
}

.ft-wizard-progress {
  width: min(100%, 760px);
  margin: 0 auto 24px;
  padding: 0 2px;
}

.ft-wizard-progress-copy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 9px;
  color: #52627a;
  font-size: 0.86rem;
  line-height: 1.3;
}

.ft-wizard-counter {
  color: #23406d;
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
}

.ft-wizard-track {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #ffe8d8;
}

.ft-wizard-track > span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ff8a3d 0%, var(--ft-orange) 100%);
  transition: width 280ms ease;
}

.ft-wizard-active {
  position: relative;
}

/* Mantém os campos no formulário para preservar os seletores e eventos legados. */
.ft-wizard-active .ft-wizard-screen:not(.is-current) {
  position: absolute !important;
  top: 0 !important;
  left: -100000px !important;
  z-index: -1 !important;
  width: 1px !important;
  min-width: 0 !important;
  height: 1px !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.ft-wizard-active .ft-wizard-screen.is-current {
  position: relative;
  z-index: 3;
  animation: ft-wizard-enter 220ms ease both;
}

/* Colunas da mesma etapa têm contextos de empilhamento próprios no mobile.
 * O bloco com o select aberto precisa ficar acima das colunas seguintes. */
.ft-wizard-active .ft-wizard-screen.is-current:has(.nice-select.open) {
  z-index: 20;
}

.ft-wizard-active .ft-wizard-panel-current {
  display: block !important;
}

.ft-wizard-active .ft-wizard-original-action,
.ft-wizard-active .ft-wizard-original-action-group {
  display: none !important;
}

.ft-wizard-navigation {
  position: relative;
  z-index: 2;
  width: min(100%, 760px);
  margin: 26px auto 0;
}

.ft-wizard-error {
  margin-bottom: 14px;
  padding: 13px 16px;
  border: 1px solid #efb1b1;
  border-radius: 12px;
  background: #fff2f2;
  color: #a52222;
  font-size: 0.92rem;
  line-height: 1.45;
}

.ft-wizard-error[hidden] {
  display: none !important;
}

.route-garantia-de-veiculos .msg-veiculo-nome {
  width: 100%;
  margin-top: 22px;
  padding: 22px;
  border: 1px solid #bfd0e9;
  border-radius: 16px;
  background: #f5f9ff;
  text-align: center;
}

.route-garantia-de-veiculos .msg-veiculo-nome p {
  margin: 0 0 18px;
  color: #24446e;
}

.route-garantia-de-veiculos .ft-vehicle-financing-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 360px);
  min-height: 56px;
  margin: 0 auto;
  padding: 12px 20px;
  border-radius: 999px;
  background: #2b72ee;
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 8px 20px rgba(43, 114, 238, 0.2);
}

.route-garantia-de-veiculos .ft-vehicle-financing-cta:hover,
.route-garantia-de-veiculos .ft-vehicle-financing-cta:focus-visible {
  background: #1f5fd1;
  color: #fff;
  text-decoration: none;
}

.ft-wizard-next[hidden] {
  display: none !important;
}

.ft-wizard-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

body.app-shell .ft-wizard-back,
body.app-shell .ft-wizard-next {
  min-width: 146px;
  min-height: 48px;
  padding: 11px 24px;
  border-radius: 999px;
  font-size: 0.96rem;
  font-weight: 400 !important;
  line-height: 1.2;
  cursor: pointer;
}

body.app-shell .ft-wizard-back {
  border: 1px solid #bfd0e9;
  background: #fff;
  color: #36516f;
}

body.app-shell .ft-wizard-next {
  border: 1px solid #2b72ee;
  background: #2b72ee;
  color: #fff;
  box-shadow: 0 8px 20px rgba(43, 114, 238, 0.2);
}

body.app-shell .ft-wizard-next.is-final {
  font-weight: 700 !important;
}

body.app-shell .ft-wizard-back:hover,
body.app-shell .ft-wizard-back:focus-visible {
  border-color: #2b72ee;
  color: #1f5fd1;
}

body.app-shell .ft-wizard-next:hover,
body.app-shell .ft-wizard-next:focus-visible {
  border-color: #1f5fd1;
  background: #1f5fd1;
}

body.app-shell .ft-wizard-back:focus-visible,
body.app-shell .ft-wizard-next:focus-visible {
  outline: 3px solid rgba(43, 114, 238, 0.24);
  outline-offset: 3px;
}

@keyframes ft-wizard-enter {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .security-notice-inner {
    grid-template-columns: 26px minmax(0, 1fr) 38px;
    gap: 8px;
    min-height: 64px;
  }

  .security-notice-icon {
    width: 24px;
    height: 24px;
    font-size: 0.88rem;
  }

  .security-notice p {
    font-size: 0.72rem;
    line-height: 1.35;
  }

  #close-security-notice {
    width: 36px;
    height: 36px;
  }

  .site-header .topo {
    min-height: 78px;
    padding: 10px 0;
  }

  .container-header-logo {
    min-height: 58px;
    gap: 12px;
  }

  #logo {
    display: none;
  }

  #logo-responsivo {
    display: inline-flex;
  }

  .header-product {
    max-width: 46vw;
    padding: 7px 10px;
    font-size: 0.7rem;
  }

  .bg-simulador {
    padding-right: 12px;
    padding-left: 12px;
  }

  .bg-simulador > .container {
    width: 100%;
    max-width: 100%;
    padding-right: 0;
    padding-left: 0;
  }

  .form-simulador,
  #msg-aviso-inicio {
    left: auto !important;
    right: auto;
    width: 100%;
    max-width: 100%;
    margin-right: 0;
    margin-left: 0 !important;
    padding: 24px 18px;
    border-radius: 18px;
  }

  .container-header-form {
    flex-direction: column;
    align-items: center;
    margin: -24px -18px 18px;
    padding: 18px 16px;
    border-radius: 18px 18px 0 0;
    text-align: center;
  }

  .container-header-form-img {
    width: auto;
    max-width: min(170px, 65vw);
    height: 84px;
    scale: 1 !important;
  }

  .container-header-textos {
    align-items: center;
  }

  .container-header-textos > h1,
  .container-header-textos > h2,
  .container-header-textos > h3 {
    text-align: center;
  }

  .container-header-textos > h1,
  .container-header-textos > h2 {
    margin-bottom: 0;
  }

  .container-header-textos > h3,
  .container-header-textos > h4,
  .container-header-textos > p:not(.ft-form-kicker) {
    display: none !important;
  }

  .ft-insurance-header .ft-form-kicker {
    text-align: center;
  }

  .form-simulador .bg-modelo {
    flex-basis: calc(50% - 8px);
    width: auto !important;
  }

  .form-simulador .btn-30,
  .form-simulador .btn-25 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .form-simulador .btn-50 > .bg-modelo,
  .form-simulador .btn-30 > .bg-modelo,
  .form-simulador .btn-25 > .bg-modelo {
    width: 100% !important;
  }

  .site-footer .contatos-rodape,
  .partner-footer .container {
    flex-direction: column;
  }

  .site-footer .informacoes-legais-rodape {
    grid-template-columns: 1fr;
  }

  .site-footer .informacoes-legais-rodape > p {
    grid-column: auto;
  }

  #cookie {
    right: 12px;
    bottom: 12px;
    left: 12px;
    flex-direction: column;
    align-items: stretch;
    width: auto;
  }

  #cookie button {
    width: 100%;
  }

  .ft-validation-summary {
    flex-direction: column;
    align-items: stretch;
  }

  .ft-validation-jump {
    width: 100%;
  }

  .ft-wizard-progress {
    margin-bottom: 20px;
  }

  .ft-wizard-navigation {
    margin-top: 22px;
  }

  .ft-wizard-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
  }

  body.app-shell .ft-wizard-back,
  body.app-shell .ft-wizard-next {
    flex: 0 0 auto;
    width: auto;
    min-width: 96px;
    min-height: 36px;
    padding: 7px 13px;
    font-size: 0.8rem;
    box-shadow: none;
  }

  body.app-shell .ft-wizard-next:not(.is-final) {
    border-color: #bfd0e9;
    color: #36516f;
    background: #f8fafc;
  }

  body.app-shell .ft-wizard-next:not(.is-final):hover {
    color: #24446e;
    background: #eaf1fb;
  }

}

@media (max-width: 420px) {
  .header-product {
    display: none;
  }

  .container-header-logo {
    justify-content: center;
  }

  .form-simulador .bg-modelo {
    flex-basis: 100%;
  }

  .form-simulador .btn-50,
  .form-simulador .btn-30,
  .form-simulador .btn-25 {
    grid-template-columns: 1fr;
  }

  .form-simulador #profissao.btn-30 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  body.app-shell *,
  body.app-shell *::before,
  body.app-shell *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
