/* ============================================================
   Radar Rápido da Liderança — folha de estilo única
   HTML semântico + custom properties, sem framework/dependência.
   Paleta e fontes replicadas do hub da Imersão IA em Negócios
   pra manter a identidade visual da WonderFlow.
   ============================================================ */

@font-face {
  font-family: 'Bricolage Grotesque';
  src: url('../fonts/bricolage-grotesque-var.woff2') format('woff2');
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-var.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --tide: #3E8F98;
  --tide-light: #51A8B1;
  --ink: #1C2321;
  --ink-soft: #55605D;
  --paper: #F5F7F7;
  --paper-raised: #FFFFFF;
  --sand: #EDEAE3;
  --ember: #C1503F;
  --brass: #A8804F;
  --border: #DCDDD6;
  --radius: 14px;
  --radius-sm: 10px;

  --font-display: 'Bricolage Grotesque', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;

  --ease-reveal: cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #F2F1EE;
    --ink-soft: #C6CAC8;
    --paper: #14181A;
    --paper-raised: #1B2023;
    --sand: #21201B;
    --border: #33383A;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}

a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }
button { font-family: inherit; }

.wrap {
  max-width: 560px;
  margin: 0 auto;
  padding: 32px 20px 48px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.logo {
  width: 132px;
  margin: 0 auto 32px;
}

.screen { display: none; flex: 1; flex-direction: column; }
.screen.is-active { display: flex; }

/* Tela 1 — Convite */
.invite { text-align: center; justify-content: center; }
.invite h1 { font-size: 1.75rem; }
.invite p { color: var(--ink-soft); font-size: 1.05rem; }

/* Progresso */
.progress-label {
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin-bottom: 8px;
}
.progress-track {
  height: 6px;
  border-radius: 999px;
  background: var(--sand);
  overflow: hidden;
  margin-bottom: 28px;
}
.progress-fill {
  height: 100%;
  background: var(--tide);
  border-radius: 999px;
  transition: width 0.3s var(--ease-reveal);
}

.is-hidden { display: none !important; }

/* Tela 2 — Perguntas */
.question-instruction {
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin-bottom: 4px;
}
.question h2 { font-size: 1.3rem; margin-bottom: 24px; }
.options { display: flex; flex-direction: column; gap: 12px; }
.option-btn {
  text-align: left;
  padding: 16px 20px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: var(--paper-raised);
  color: var(--ink);
  font-size: 1rem;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.option-btn:hover,
.option-btn:focus-visible { border-color: var(--tide); }
.option-btn.is-selected {
  border-color: var(--tide);
  background: color-mix(in srgb, var(--tide) 12%, var(--paper-raised));
}

.nav-row {
  margin-top: 24px;
  display: flex;
  justify-content: space-between;
}

.btn-link {
  background: none;
  border: none;
  color: var(--ink-soft);
  font-size: 0.95rem;
  cursor: pointer;
  padding: 8px 0;
}
.btn-link:disabled { visibility: hidden; }

/* Tela 3 — Identificação */
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 6px;
}
.field input {
  width: 100%;
  padding: 13px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--paper-raised);
  color: var(--ink);
  font-size: 1rem;
  font-family: inherit;
}
.field input:focus { outline: 2px solid var(--tide); outline-offset: 1px; }
.field-optional-tag {
  font-weight: 400;
  color: var(--ink-soft);
  font-size: 0.8rem;
}

.consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin: 20px 0;
}
.consent input { margin-top: 3px; }

.privacy-notice {
  font-size: 0.78rem;
  color: var(--ink-soft);
  margin-bottom: 20px;
}

.error-text {
  color: var(--ember);
  font-size: 0.85rem;
  margin-top: -8px;
  margin-bottom: 16px;
  display: none;
}
.error-text.is-visible { display: block; }

/* Tela 4 — Resultado */
.result-block { margin-bottom: 20px; }
.result-block h3 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--tide);
  margin-bottom: 6px;
}
.result-block p { margin: 0 0 12px; }
.result-atencao-heading { font-size: 1.1rem; }
.result-block ul { padding-left: 20px; margin: 0 0 12px; }
.result-block li { margin-bottom: 6px; }
.result-tag {
  display: inline-block;
  font-size: 0.75rem;
  color: var(--ink-soft);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 12px;
  margin-bottom: 20px;
}
.disclaimer {
  font-size: 0.85rem;
  color: var(--ink-soft);
  border-top: 1px solid var(--border);
  padding-top: 16px;
  margin-top: 24px;
}

/* Botões primário/secundário, usados em várias telas */
.btn-primary,
.btn-secondary {
  display: block;
  width: 100%;
  text-align: center;
  padding: 16px 20px;
  border-radius: var(--radius);
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  text-decoration: none;
}
.btn-primary {
  background: var(--tide);
  color: #fff;
  margin-bottom: 12px;
}
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-secondary {
  background: var(--paper-raised);
  color: var(--ink);
  border: 1.5px solid var(--border);
}

.hint-banner {
  background: var(--sand);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.8rem;
  color: var(--ink-soft);
  margin-bottom: 20px;
}
