:root {
  --navy-950: #041235; --navy-900: #061a4a; --navy: #0b2a6f; --azul: #1e6fd9; --ceu: #3ba8f0;
  --limao: #b5d916; --verde: #3daa2e; --tinta: #10203f; --cinza: #5b6b85; --linha: #dfe6f1; --suave: #f2f6fc;
  --erro: #d6453d;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: #041235; }
body {
  margin: 0; min-height: 100vh; font-family: 'Inter', system-ui, sans-serif; color: var(--tinta);
  background: radial-gradient(circle at 80% 0%, #1c4fae 0%, var(--navy) 35%, var(--navy-950) 100%) fixed var(--navy-950);
  overflow-x: hidden;
}
.fundo-arcos { position: fixed; width: 1100px; max-width: none; right: -820px; top: 160px; opacity: 0.35; pointer-events: none; z-index: 0; }
.tela { position: relative; z-index: 1; max-width: 560px; margin: 0 auto; padding: 28px 16px 40px; }
[hidden] { display: none !important; }

.hero { text-align: center; color: #fff; margin-bottom: 22px; }
.hero-logo { width: 132px; height: 132px; border-radius: 50%; box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4); }
.hero h1 { font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: clamp(24px, 6.4vw, 32px); line-height: 1.15; margin: 18px 0 10px; }
.hero h1 em, .resultado h1 em { font-style: normal; color: var(--limao); }
.hero p { color: #c8d5ee; margin: 0; font-size: 15px; }

.cartao { background: #fff; border-radius: 22px; padding: 22px 20px; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35); }
.progresso { height: 6px; background: var(--suave); border-radius: 3px; overflow: hidden; }
#barra-progresso { height: 100%; width: 25%; background: linear-gradient(90deg, var(--limao), var(--verde)); transition: width 0.3s; }
.contador { font-size: 12px; color: var(--cinza); margin: 8px 0 4px; font-weight: 600; }

.passo { border: 0; margin: 0; padding: 0; display: none; }
.passo.ativo { display: block; animation: entra 0.25s ease; }
@keyframes entra { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
legend { font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 20px; color: var(--navy); padding: 0; margin-bottom: 4px; }
.ajuda { color: var(--cinza); font-size: 14px; margin: 4px 0 12px; }
.ajuda small { font-size: 12px; }

.campo { display: block; margin-bottom: 14px; }
.campo > span { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.campo small { color: var(--cinza); font-weight: 400; }
.campo.oculto { display: none; }
input:not([type=radio]):not([type=checkbox]), select {
  width: 100%; height: 50px; border: 1.5px solid var(--linha); border-radius: 12px; padding: 0 14px;
  font: inherit; font-size: 16px; color: var(--tinta); background: #fff; outline: none; transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus, select:focus { border-color: var(--azul); box-shadow: 0 0 0 4px rgba(30, 111, 217, 0.14); }
.com-prefixo { display: flex; align-items: center; border: 1.5px solid var(--linha); border-radius: 12px; overflow: hidden; }
.com-prefixo:focus-within { border-color: var(--azul); box-shadow: 0 0 0 4px rgba(30, 111, 217, 0.14); }
.com-prefixo i { font-style: normal; font-weight: 700; color: var(--cinza); padding: 0 0 0 14px; }
.com-prefixo.sufixo i { padding: 0 14px 0 0; }
.com-prefixo input { border: 0 !important; box-shadow: none !important; font-size: 20px !important; font-weight: 700; }
.linha { display: flex; gap: 10px; }
.linha .uf { flex: 0 0 96px; }
.linha .campo:last-child { flex: 1; }

.alternar { display: flex; background: var(--suave); border-radius: 12px; padding: 4px; margin-bottom: 14px; }
.alternar label { flex: 1; }
.alternar input, .opcoes input { position: absolute; opacity: 0; pointer-events: none; }
.alternar span { display: block; text-align: center; padding: 10px; border-radius: 9px; font-weight: 600; font-size: 14px; color: var(--cinza); cursor: pointer; }
.alternar input:checked + span { background: #fff; color: var(--navy); box-shadow: 0 2px 8px rgba(11, 42, 111, 0.12); }
.alternar input:focus-visible + span, .opcoes input:focus-visible + span { outline: 2px solid var(--azul); outline-offset: 2px; }

.opcoes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 16px; }
.opcoes.tres { grid-template-columns: repeat(3, 1fr); }
.opcoes label { position: relative; }
.opcoes span { display: flex; flex-direction: column; justify-content: center; min-height: 54px; height: 100%; padding: 10px 12px; border: 1.5px solid var(--linha); border-radius: 12px; cursor: pointer; transition: all 0.15s; }
.opcoes b { font-size: 14px; color: var(--tinta); }
.opcoes small { font-size: 11.5px; color: var(--cinza); }
.opcoes input:checked + span { border-color: var(--verde); background: #f3fae6; box-shadow: inset 0 0 0 1px var(--verde); }

.campo-mel { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.aceite { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--cinza); margin-top: 6px; cursor: pointer; }
.aceite input { width: 20px; height: 20px; margin: 0; flex: none; accent-color: var(--verde); }

.erro { color: var(--erro); font-size: 13.5px; font-weight: 600; min-height: 0; margin: 8px 0 0; }
.erro:empty { display: none; }
.acoes { display: flex; gap: 10px; margin-top: 18px; }
.acoes.coluna { flex-direction: column; }
.botao {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; min-height: 52px; border: 0; border-radius: 14px;
  font: inherit; font-weight: 700; font-size: 16px; cursor: pointer; text-decoration: none;
  background: linear-gradient(90deg, var(--limao), var(--verde)); color: var(--navy-950); transition: transform 0.1s, filter 0.15s;
}
.botao:hover { filter: brightness(1.05); }
.botao:active { transform: scale(0.98); }
.botao:disabled { opacity: 0.6; cursor: wait; }
.botao.secundario { flex: 0 0 auto; padding: 0 20px; background: var(--suave); color: var(--navy); }
.botao.whats { background: #25d366; color: #fff; }
.botao.link { background: none; color: var(--azul); min-height: 40px; font-size: 14px; }

.rodape-site { text-align: center; color: #8ea3cc; font-size: 12px; margin-top: 22px; }

/* resultado */
.resultado { text-align: center; }
.resultado-logo { width: 78px; height: 78px; margin-top: -60px; border-radius: 50%; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3); }
.tela#tela-resultado { padding-top: 64px; max-width: 880px; }
.tela#tela-resultado .cartao { max-width: 560px; margin: 0 auto; }
.resultado h1 { font-family: 'Montserrat', sans-serif; font-size: 22px; color: var(--navy); margin: 10px 0 16px; }
.resultado h1 em { color: var(--verde); }
.resumo { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.resumo div { background: var(--suave); border-radius: 12px; padding: 12px; }
.resumo small { display: block; font-size: 11.5px; color: var(--cinza); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }
.resumo b { font-family: 'Montserrat', sans-serif; font-size: 19px; color: var(--navy); }
.retorno { margin: 14px 0 0; color: var(--tinta); }
.retorno b { color: var(--verde); }
.pequeno { font-size: 12px; color: var(--cinza); margin: 10px 0 0; }
.titulo-preview { color: #fff; font-family: 'Montserrat', sans-serif; font-size: 16px; text-align: center; margin: 34px 0 14px; opacity: 0.85; }
.preview { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.preview .moldura { overflow: hidden; border-radius: 6px; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35); }
.preview .pg { transform-origin: top left; }

.render-pdf { position: absolute; left: -10000px; top: 0; width: 794px; }

.carregando { position: fixed; inset: 0; z-index: 10; background: rgba(4, 18, 53, 0.82); display: flex; flex-direction: column; align-items: center; justify-content: center; color: #fff; gap: 16px; font-weight: 600; }
.spinner { width: 48px; height: 48px; border-radius: 50%; border: 4px solid rgba(255, 255, 255, 0.2); border-top-color: var(--limao); animation: gira 0.8s linear infinite; }
@keyframes gira { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
.rodape-site a { color: #a9bbdd; text-decoration: none; }
.rodape-site a:hover { color: #fff; }
