/* Cotação em tela cheia, uma pergunta por vez. Mesma gramática da cotação que já roda:
   campo na cor da operadora, opção em cartão branco, campo de texto com fio embaixo.
   A operadora manda na cor; a R Fontes assina no topo e no pé.
   Cada página define os tokens de --campo até --fonte no seu próprio <style>. */
:root {
  --suave: rgba(255, 255, 255, .8);
  --fio: rgba(255, 255, 255, .45);
  --erro-claro: #ffe0a8;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0; background: var(--campo); color: #fff;
  font-family: var(--fonte); font-size: 16px; line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
img { display: block; max-width: 100%; height: auto; }
p { margin: 0; }

/* campo cheio com um brilho no alto, pra cor não ficar chapada */
.app {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: 100dvh; display: flex; flex-direction: column;
  background:
    radial-gradient(120% 70% at 85% -10%, rgba(255, 255, 255, .16) 0%, rgba(255, 255, 255, 0) 60%),
    var(--campo-2, var(--campo));
}

/* topo: faixa branca atravessando a largura, com a base recortada.
   Diagonal na Santa Saúde (o painel inclinado dela) e na Blue Med; canto
   arredondado na Trasmontano, que é a caixa do logo dela.
   Cada página define --corte-* no seu <style>. */
.faixa { background: #fff; padding-bottom: var(--corte-folga, 26px); margin-bottom: 20px; }
.faixa-dentro {
  max-width: 640px; margin: 0 auto; padding: 16px 20px 4px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.faixa .op-logo { height: var(--logo-h, 34px); width: auto; flex-shrink: 0; }
/* a corretora assina em navy dentro da faixa, não em branco ao lado do logo:
   é o que tira a cara de co-branding de agência */
.assina-navy { display: flex; align-items: center; gap: 9px; color: #35445B; text-align: right; min-width: 0; }
.assina-navy i {
  order: 2; flex-shrink: 0; width: 30px; height: 22px; background: #E78A9B;
  -webkit-mask: url("img/simbolo.png") center / contain no-repeat;
  mask: url("img/simbolo.png") center / contain no-repeat;
}
.assina-navy > span { font-size: 11px; font-weight: 600; line-height: 1.3; color: #7D8A9C; }
.assina-navy b {
  display: block; margin-top: 2px; letter-spacing: 0; color: #35445B;
  font-family: "Times New Roman", Georgia, serif; font-weight: 400; font-size: 18px;
}

/* cotação da própria corretora: a marca ocupa o lugar do logo da operadora,
   desenhada e não em PNG, igual ao institucional, pra não perder nitidez */
.marca-rf { display: flex; align-items: center; gap: 11px; color: #35445B; }
.marca-rf i {
  flex-shrink: 0; width: 44px; height: 32px; background: #E78A9B;
  -webkit-mask: url("img/simbolo.png") center / contain no-repeat;
  mask: url("img/simbolo.png") center / contain no-repeat;
}
.marca-rf > span {
  font-family: "Times New Roman", Georgia, serif; font-size: 29px; line-height: 1;
}
.marca-rf small {
  display: block; font-family: "Montserrat", sans-serif; font-size: 9px;
  font-weight: 600; letter-spacing: .26em; margin-top: 4px; color: #7D8A9C;
}

.barra { height: 3px; max-width: 600px; margin: 0 auto; background: rgba(255, 255, 255, .26); border-radius: 999px; overflow: hidden; }
.barra span { display: block; height: 100%; width: 0; background: #fff; border-radius: 999px; transition: width .45s cubic-bezier(.16, 1, .3, 1); }
@media (max-width: 640px) { .barra { margin: 0 20px; } }

main { flex: 1; display: flex; }
form { flex: 1; width: 100%; max-width: 640px; margin: 0 auto; padding: 28px 20px calc(28px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; }
.passo { display: none; flex-direction: column; gap: 14px; }
.passo.atual { display: flex; }
@media (prefers-reduced-motion: no-preference) {
  .passo.atual { animation: entra .32s cubic-bezier(.16, 1, .3, 1); }
  @keyframes entra { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
}
.intro { font-size: 14.5px; font-weight: 500; color: var(--suave); }
.pergunta { margin: 0; font-size: 26px; line-height: 1.22; font-weight: 700; color: #fff; letter-spacing: -.015em; text-wrap: balance; outline: none; }
.ajuda { font-size: 14.5px; font-weight: 500; color: var(--suave); margin-top: -6px; }

.opcoes { display: grid; grid-template-columns: 1fr; gap: 10px; margin-top: 8px; }
.opcoes.duas { grid-template-columns: 1fr 1fr; }
.opc {
  appearance: none; font: inherit; text-align: left; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  width: 100%; min-height: 56px; padding: 10px 14px 10px 18px;
  border: 0; border-radius: 14px; background: #fff; color: var(--tinta);
  font-size: 16.5px; font-weight: 700; line-height: 1.25;
  box-shadow: 0 8px 22px var(--sombra); transition: background .15s, transform .1s;
  -webkit-tap-highlight-color: transparent;
}
.opc::after {
  content: ""; flex-shrink: 0; width: 28px; height: 28px; border-radius: 999px;
  background: var(--tinta-0) var(--seta) center / 16px no-repeat;
}
.duas .opc { padding: 10px 12px 10px 14px; font-size: 15.5px; }
.duas .opc::after { display: none; }
.opc:hover { background: var(--tinta-0); }
.opc:active { transform: scale(.985); }
.opc:focus-visible { outline: 3px solid rgba(255, 255, 255, .7); outline-offset: 3px; }
.opc[aria-pressed="true"] { background: var(--tinta-1); box-shadow: 0 0 0 3px #fff; }

.campo {
  font: inherit; font-size: 20px; font-weight: 600; color: #fff; caret-color: #fff;
  width: 100%; border: 0; border-bottom: 2px solid var(--fio); border-radius: 0;
  background: transparent; padding: 10px 2px; margin-top: 6px; outline: none;
  transition: border-color .15s;
}
.campo:focus { border-bottom-color: #fff; }
.campo::placeholder { color: rgba(255, 255, 255, .55); font-weight: 500; }
.campo.erro { border-bottom-color: var(--erro-claro); }

.ok {
  appearance: none; font: inherit; cursor: pointer; align-self: flex-start;
  display: inline-flex; align-items: center; gap: 8px; min-height: 52px; padding: 0 26px;
  margin-top: 8px; border: 0; border-radius: 999px; background: #fff; color: var(--tinta);
  font-size: 16.5px; font-weight: 700; box-shadow: 0 8px 22px var(--sombra);
  transition: background .15s, transform .1s;
}
.ok:hover { background: var(--tinta-0); }
.ok:active { transform: scale(.98); }
.ok:focus-visible { outline: 3px solid rgba(255, 255, 255, .7); outline-offset: 3px; }
.ok[disabled] { opacity: .7; cursor: default; }
.ok.cheio { align-self: stretch; justify-content: center; }
.msg { min-height: 1.4em; font-size: 14.5px; font-weight: 600; color: var(--erro-claro); }
.msg a { color: #fff; font-weight: 700; }

.rodape { margin-top: auto; padding-top: 28px; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.voltar {
  appearance: none; font: inherit; cursor: pointer; background: none; border: 0;
  padding: 12px 4px; min-height: 44px; color: #fff; font-size: 15px; font-weight: 600;
  text-decoration: underline; text-underline-offset: 3px;
}
.voltar[hidden] { display: none; }
/* a linha que separa a corretora da operadora: é o que evita a conta ser suspensa por
   parecer o site oficial, e por isso ela fica na tela, não escondida */
.nota { font-size: 12px; font-weight: 500; color: var(--suave); max-width: 46ch; line-height: 1.55; text-wrap: pretty; }
.nota a { position: relative; color: #fff; }
.nota a::after { content: ""; position: absolute; inset: -15px -10px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

@media (min-width: 700px) {
  form { padding-top: 56px; }
  .pergunta { font-size: 30px; }
}
@media (max-width: 430px) {
  .faixa-dentro { gap: 12px; padding-left: 16px; padding-right: 16px; }
  .faixa .op-logo { height: calc(var(--logo-h, 34px) - 6px); }
  .assina-navy > span { font-size: 0; }
  .assina-navy b { font-size: 16px; margin-top: 0; }
  .assina-navy i { width: 26px; height: 19px; }
  .marca-rf > span { font-size: 25px; }
  .marca-rf i { width: 38px; height: 28px; }
}
