@font-face {
  font-family: "UnimedBrush";
  src: url("UnimedBrush-Regular.otf") format("opentype");
  font-weight: 400;
  font-display: swap;
}

:root {
  --verde: #00995D;
  --verde-escuro: #007a4a;
  --verde-claro: #8CC63F;
  --lima-escuro: #4F8A10; /* versão do lime com contraste acessível */
  --teal: #00A9A7;
  --teal-escuro: #00807E;
  --teal-claro: #B7E6E5;
  --azul-bg: #E4F5F5;
  --texto: #1f3d38;
  --texto-suave: #5a726d;
  --branco: #fff;
  --borda: #dbe8e6;
  --shadow: 0 12px 32px rgba(0, 87, 66, .12);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "Nunito", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--texto);
  background: var(--branco);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

.container { width: min(1180px, 100% - 40px); margin-inline: auto; }

.brush {
  font-family: "UnimedBrush", "Nunito", cursive;
  font-weight: 400;
  color: var(--verde-claro);
  font-size: 1.25em;
  line-height: 1;
}

/* ---------- Palco: tudo em uma dobra ---------- */
.stage {
  min-height: 100vh;
  min-height: 100svh; /* evita o salto da barra do navegador no mobile */
  display: flex;
  flex-direction: column;
}

/* ---------- Botões ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: inherit;
  font-weight: 800;
  font-size: 1rem;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 14px 30px;
  cursor: pointer;
  text-decoration: none;
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }

.btn--primary {
  background: var(--verde);
  color: var(--branco);
  box-shadow: 0 8px 20px rgba(0, 153, 93, .3);
}
.btn--primary:hover { background: var(--verde-escuro); }

.btn--outline { background: transparent; border-color: var(--verde); color: var(--verde); }
.btn--outline:hover { background: var(--verde); color: var(--branco); }

.btn--ghost {
  background: transparent;
  color: var(--texto-suave);
  font-weight: 700;
  padding: 14px 18px;
}
.btn--ghost:hover { color: var(--verde); background: #f2f8f7; }

.btn[disabled] { opacity: .65; cursor: not-allowed; transform: none; }
/* display: inline-flex anularia o atributo hidden do botão "Voltar" */
.btn[hidden] { display: none; }

.btn__loader {
  width: 18px; height: 18px;
  border: 3px solid rgba(255,255,255,.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Topbar ---------- */
.topbar { background: var(--branco); border-bottom: 1px solid var(--borda); flex: none; }
.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
}
.topbar__logo img { height: 36px; width: auto; }
.topbar__tag {
  background: var(--verde);
  color: var(--branco);
  font-weight: 800;
  font-size: .75rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  background-image: url("bg-hero.webp");
  background-size: cover;
  background-position: center right; /* mantém a foto na direita, livre */
  background-repeat: no-repeat;
  isolation: isolate;
  padding: 28px 0;
}
/* véu somente à esquerda; a metade direita fica limpa para a foto */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, .92) 0%,
    rgba(255, 255, 255, .88) 30%,
    rgba(255, 255, 255, .55) 45%,
    rgba(255, 255, 255, 0) 60%
  );
}

.hero__inner { width: min(1180px, 100% - 40px); }
/* todo o conteúdo ocupa só a metade esquerda */
.hero__content { max-width: 480px; }

/* foto do mobile em fluxo — só aparece abaixo de 900px */
.hero__photo { display: none; }

.hero h1 {
  font-size: clamp(1.875rem, 3vw, 2.75rem);
  font-weight: 900;
  line-height: 1.12;
  color: var(--verde-escuro);
  margin-bottom: 14px;
}
/* a brush tem corpo maior; o padding evita corte de acentos e descidas */
.hero h1 .brush {
  color: var(--lima-escuro);
  display: inline-block;
  line-height: 1.15;
  padding-bottom: .08em;
}

.hero__text {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.55;
  color: var(--texto);
  margin-bottom: 20px;
}
.hero__text strong { color: var(--verde-escuro); font-weight: 800; }

.hero__note { margin-top: 14px; font-size: .8125rem; font-weight: 800; color: #4a625d; }

/* regras da campanha, logo abaixo da linha de vigência */
.rules { list-style: none; margin-top: 8px; display: grid; gap: 5px; }
.rules li {
  position: relative;
  padding-left: 14px;
  font-size: .75rem;
  line-height: 1.45;
  color: #5a726d;
}
.rules li::before {
  content: "*";
  position: absolute;
  left: 0;
  top: 1px;
  color: var(--lima-escuro);
  font-weight: 900;
}

/* ---------- Card do formulário (uma pergunta por vez) ---------- */
/* card + selo ANS lado a lado */
.form-row { display: flex; align-items: center; gap: 16px; }
.form-card { flex: 1; min-width: 0; }
/* selo ANS ao lado do formulário — vertical, na orientação original */
.form-ans {
  flex: none;
  width: 34px;
  height: auto;        /* altura vem da proporção da imagem, nunca do container */
  max-height: 220px;
  align-self: center;
  border-radius: 5px;
}

.form-card {
  background: var(--branco);
  border-radius: 18px;
  padding: 22px 24px 18px;
  box-shadow: 0 18px 44px rgba(0, 87, 66, .18);
}

.form-card__head { margin-bottom: 16px; }
.form-card__step {
  display: block;
  font-size: .75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--texto-suave);
  margin-bottom: 8px;
}
.form-card__step strong { color: var(--verde); }

.progress { height: 5px; background: var(--borda); border-radius: 999px; overflow: hidden; }
.progress__bar {
  display: block;
  height: 100%;
  width: 20%;
  background: var(--verde);
  border-radius: 999px;
  transition: width .3s ease;
}

/* cada passo é uma pergunta; só o ativo aparece */
.step { display: none; }
.step.is-active { display: block; animation: step-in .25s ease; }
@keyframes step-in {
  from { opacity: 0; transform: translateX(8px); }
  to   { opacity: 1; transform: none; }
}

.step label {
  display: block;
  font-weight: 800;
  font-size: 1.0625rem;
  color: var(--texto);
  margin-bottom: 10px;
}
.step input,
.step select {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  color: var(--texto);
  padding: 13px 16px;
  border: 2px solid var(--borda);
  border-radius: 12px;
  background: var(--branco);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.step select { cursor: pointer; }
.step input:focus,
.step select:focus {
  outline: none;
  border-color: var(--verde);
  box-shadow: 0 0 0 4px rgba(0, 153, 93, .12);
}
.step input::placeholder { color: #a9bcb8; }

.step.is-invalid input,
.step.is-invalid select { border-color: #d64545; }
.error { display: none; color: #d64545; font-size: .8125rem; font-weight: 700; margin-top: 6px; }
.step.is-invalid .error { display: block; }

.hp { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; }

.form-nav { display: flex; align-items: center; gap: 8px; margin-top: 16px; }
.form-nav .btn--primary { flex: 1; }

.form-card__privacy {
  font-size: .6875rem;
  color: var(--texto-suave);
  text-align: center;
  margin-top: 10px;
  line-height: 1.45;
}
.form-error {
  margin-top: 10px;
  padding: 10px 12px;
  background: #fdecec;
  border-radius: 10px;
  color: #b53232;
  font-size: .8125rem;
  font-weight: 700;
  text-align: center;
}

/* ---------- Rodapé legal ---------- */
.legal { background: #fff; color: var(--texto-suave); flex: none; padding: 16px 0; border-top: 1px solid var(--borda); }
.legal__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  text-align: left;
}
.legal__logo { height: 34px; width: auto; flex: none; }
.legal p { font-size: .75rem; line-height: 1.55; max-width: 620px; }
/* selo ANS: barra vertical estreita, mantida na orientação original */
.legal__ans { height: 52px; width: auto; flex: none; border-radius: 3px; }

/* badge de abrangência (usado só na página de Unaí) */
.hero__local {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--verde);
  color: #fff;
  font-weight: 800;
  font-size: .8125rem;
  letter-spacing: .02em;
  padding: 6px 15px;
  border-radius: 999px;
  margin-bottom: 14px;
}

/* ---------- Responsivo ---------- */

/* telas baixas: solta a trava de altura para nada ficar cortado */
@media (max-height: 680px) and (min-width: 901px) {
  .stage { min-height: 0; }
  .hero { padding: 40px 0; }
}

@media (max-width: 900px) {
  /* a foto vira elemento em fluxo: o texto nunca invade a imagem */
  .stage { min-height: 0; }
  .hero {
    display: block;
    /* o fundo clareia até o tom do topo da foto, para não haver emenda */
    background-image: linear-gradient(to bottom, #94DADD 0%, #A6E1E3 52%, #D4F5F6 100%);
    background-color: #94DADD;
    padding: 22px 0 0;
  }
  .hero::before { background: none; }
  .hero__content { max-width: 520px; margin-inline: auto; text-align: center; }
  .hero h1 { font-size: clamp(1.625rem, 6.5vw, 2rem); margin-bottom: 10px; }
  .hero__text { font-size: .9375rem; margin-bottom: 16px; }
  .hero__note { color: #2c453f; margin-top: 12px; } /* fundo teal exige texto mais fechado */
  .rules { justify-items: center; }
  .rules li { text-align: left; color: #33514b; }
  .step label { font-size: 1rem; }
  .form-row { gap: 10px; }
  .form-ans { width: 28px; }
  .form-card { padding: 18px 20px 16px; }
  .form-card__head { margin-bottom: 12px; }
  .hero__photo {
    display: block;
    width: 100%;
    /* recorte justo na foto: sem o vazio de céu acima das pessoas */
    aspect-ratio: 400 / 360;
    object-fit: cover;
    object-position: bottom center;
    margin-top: 16px;
    /* dissolve o topo da imagem no fundo, eliminando o corte seco */
    -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 22%);
    mask-image: linear-gradient(to bottom, transparent 0, #000 22%);
  }
  .legal__inner { flex-direction: column; text-align: center; }
  .legal { padding: 12px 0; }
}

@media (max-width: 480px) {
  .form-card { padding: 20px 18px 16px; }
  .topbar__tag { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
}

/* ---------- Página de obrigado ---------- */
.thanks {
  flex: 1;
  display: grid;
  place-items: center;
  background: var(--azul-bg);
  padding: 60px 0;
  text-align: center;
}
.thanks__box {
  background: var(--branco);
  border-radius: 24px;
  padding: 56px 40px;
  box-shadow: var(--shadow);
  max-width: 620px;
  margin-inline: auto;
}
.thanks__check {
  width: 84px; height: 84px;
  margin: 0 auto 24px;
  border-radius: 50%;
  background: var(--verde);
  color: var(--branco);
  display: grid;
  place-items: center;
  font-size: 2.5rem;
  font-weight: 900;
}
.thanks__box h1 {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 900;
  color: var(--verde);
  margin-bottom: 14px;
  line-height: 1.15;
}
.thanks__box > p { color: var(--texto); margin-bottom: 28px; font-size: 1.0625rem; }
.thanks__actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
