/* Identidade Predestinadas · Maria Giullia */
:root {
  --off: #f2f0ef;
  --branco: #ffffff;
  --rosa: #ff66c4;
  --rosa-escuro: #e14fa9;
  --rosa-claro: #ffd6ee;
  --vinho: #4a2124;
  --vinho-claro: #6b3a3e;
  --azul: #3e6e8e;
  --ceu: #5ba3d0;
  --salvia: #e6efe8;
  --salvia-texto: #3f6b4e;
  --nevoa: #e7eef4;
  --suave: #8a6f70;
  --linha: rgba(74, 33, 36, 0.12);
  --raio: 22px;
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --script: "Pinyon Script", "Snell Roundhand", cursive;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--off);
  color: var(--vinho);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.55;
  min-height: 100vh;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
button, input, select { font: inherit; color: inherit; }

.script { font-family: var(--script); color: var(--rosa); font-weight: 400; letter-spacing: 0; }
.rotulo {
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--rosa);
  font-weight: 500;
  margin: 0 0 14px;
}
.assinatura { font-family: var(--script); font-size: 26px; color: var(--vinho); margin-top: 28px; }

/* Fitas decorativas */
.fita { position: fixed; pointer-events: none; z-index: 0; opacity: 0.95; }
.fita--topo { top: -40px; right: -60px; width: 220px; }
.fita--base { bottom: -50px; left: -70px; width: 220px; transform: rotate(160deg); }
body.em-pergunta .fita--topo { display: none; }
.estrela { position: fixed; right: 26px; bottom: 120px; width: 26px; z-index: 0; pointer-events: none; }
@media (max-width: 520px) {
  .fita--topo { width: 150px; right: -50px; top: -30px; }
  .fita--base { width: 150px; left: -60px; }
  .estrela { display: none; }
}

/* Layout do questionário */
.tela {
  position: relative;
  z-index: 1;
  max-width: 560px;
  margin: 0 auto;
  padding: 40px 20px 32px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.tela--centro { justify-content: center; }
.titulo {
  font-weight: 300;
  font-size: clamp(30px, 7vw, 44px);
  line-height: 1.12;
  margin: 0 0 16px;
  letter-spacing: -0.01em;
}
.titulo .script { font-size: 1.35em; line-height: 0.8; }
.subtitulo { font-size: 17px; color: var(--vinho-claro); margin: 0 0 28px; font-weight: 300; }
.pergunta { font-weight: 400; font-size: clamp(24px, 5.6vw, 30px); line-height: 1.2; margin: 0 0 8px; }
.apoio { color: var(--suave); margin: 0 0 24px; font-size: 15px; }

.progresso { display: flex; align-items: center; gap: 12px; margin-bottom: 40px; }
.progresso__barra { flex: 1; height: 4px; background: rgba(74, 33, 36, 0.1); border-radius: 99px; overflow: hidden; }
.progresso__cheio { height: 100%; background: var(--rosa); border-radius: 99px; transition: width 0.4s ease; }
.progresso__texto { font-size: 12px; letter-spacing: 0.12em; color: var(--suave); white-space: nowrap; }

.campo {
  width: 100%;
  border: 1px solid var(--linha);
  background: var(--branco);
  border-radius: 16px;
  padding: 16px 18px;
  font-size: 17px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.campo:focus { border-color: var(--rosa); box-shadow: 0 0 0 4px rgba(255, 102, 196, 0.18); }
.campo-arroba { position: relative; }
.campo-arroba .campo { padding-left: 42px; }
.campo-arroba::before {
  content: "@";
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--rosa);
  font-weight: 500;
}

.botao {
  appearance: none;
  border: 0;
  cursor: pointer;
  width: 100%;
  border-radius: 999px;
  padding: 17px 24px;
  font-size: 16px;
  font-weight: 500;
  background: var(--vinho);
  color: var(--off);
  transition: transform 0.15s, background 0.2s, opacity 0.2s;
  margin-top: 16px;
}
.botao:hover { background: var(--vinho-claro); }
.botao:active { transform: scale(0.98); }
.botao:disabled { opacity: 0.45; cursor: default; }
.botao--rosa { background: var(--rosa); color: var(--vinho); }
.botao--rosa:hover { background: var(--rosa-escuro); }
.botao--linha { background: transparent; color: var(--vinho); border: 1px solid var(--linha); }
.botao--linha:hover { background: var(--branco); }
.link {
  background: none;
  border: 0;
  color: var(--suave);
  font-size: 14px;
  cursor: pointer;
  padding: 12px 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.opcoes { display: grid; gap: 10px; }
.opcao {
  appearance: none;
  text-align: left;
  background: var(--branco);
  border: 1px solid var(--linha);
  border-radius: 16px;
  padding: 16px 18px;
  font-size: 16px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, transform 0.1s;
}
.opcao:hover { border-color: var(--rosa); }
.opcao:active { transform: scale(0.99); }
.opcao--marcada { background: var(--rosa); border-color: var(--rosa); color: var(--vinho); font-weight: 500; }

/* Transição suave entre telas */
.entrar { animation: entrar 0.38s ease both; }
@keyframes entrar {
  from { opacity: 0; transform: translateX(24px); }
  to { opacity: 1; transform: none; }
}
.opcao strong { display: block; font-weight: 500; }
.opcao__desc { display: block; font-size: 14px; color: var(--vinho-claro); margin-top: 4px; line-height: 1.4; }
.opcao--marcada .opcao__desc { color: var(--vinho); }
.opcao--outro { text-align: center; color: var(--suave); border-style: dashed; }
.grupo-titulo { font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--rosa); font-weight: 500; margin: 18px 0 8px; }
.legenda { display: block; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--suave); margin: 6px 0 6px; }
.cartao-escolha { background: var(--vinho); color: var(--off); border-radius: var(--raio); padding: 22px; margin: 8px 0 6px; }
.cartao-escolha p { margin: 0 0 12px; }
.cartao-escolha p:last-child { margin: 0; }
.cartao-escolha .legenda { color: var(--rosa); margin: 0 0 2px; }
.cartao-escolha strong { font-size: 22px; font-weight: 400; }

.rodape-nav { margin-top: auto; padding-top: 28px; display: flex; justify-content: space-between; align-items: center; }

.aceite { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--vinho-claro); margin-top: 16px; }
.aceite input { width: 20px; height: 20px; accent-color: var(--rosa); margin-top: 2px; flex: none; }
.aceite a { color: var(--rosa-escuro); }

.erro { color: #b3261e; font-size: 14px; margin-top: 12px; min-height: 1em; }

/* Cartão do perfil */
.perfil-card {
  display: flex;
  gap: 16px;
  align-items: center;
  background: var(--vinho);
  color: var(--off);
  border-radius: var(--raio);
  padding: 20px;
}
.perfil-card img, .avatar-vazio {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--rosa);
  flex: none;
  background: var(--vinho-claro);
}
.perfil-card strong { display: block; font-size: 18px; font-weight: 500; }
.perfil-card span { color: rgba(242, 240, 239, 0.75); font-size: 14px; }

.grade-posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.grade-posts button {
  padding: 0;
  border: 3px solid transparent;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 1;
  cursor: pointer;
  background: var(--rosa-claro);
}
.grade-posts img { width: 100%; height: 100%; object-fit: cover; }
.grade-posts button.marcado { border-color: var(--rosa); }

/* Espera */
.espera { text-align: center; }
.espera__mensagem { font-size: 18px; min-height: 1.6em; margin: 24px 0 36px; transition: opacity 0.3s; }
.pulso {
  width: 64px;
  height: 64px;
  margin: 0 auto;
  border-radius: 50%;
  background: var(--rosa);
  animation: pulso 1.6s ease-in-out infinite;
}
@keyframes pulso {
  0%, 100% { transform: scale(0.85); opacity: 0.6; }
  50% { transform: scale(1); opacity: 1; }
}
.fases { display: grid; gap: 10px; text-align: left; }
.fase {
  background: var(--branco);
  border-radius: 16px;
  padding: 14px 16px;
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 12px;
  align-items: start;
}
.fase b {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--rosa-claro);
  color: var(--vinho);
  display: grid;
  place-items: center;
  font-weight: 500;
}
.fase strong { display: block; font-weight: 500; }
.fase span { font-size: 14px; color: var(--suave); }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
