/* Quiz de estilo (inc/quiz.php). Mesmas cores e fontes da home Luxo, pensado primeiro para o celular. */
:root {
  --marfim: #f9f5ed;
  --papel: #fffdf8;
  --tinta: #151412;
  --suave: #6b655e;
  --ouro: #ad7a36;
  --ouro-claro: #d9b77c;
  --linha: #e4d8c5;
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Montserrat", Arial, sans-serif;
  --lux: cubic-bezier(.22, 1, .36, 1);
  --lado: 20px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; min-height: 100dvh; background: var(--marfim); color: var(--tinta); font: 400 15px/1.6 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { display: block; max-width: 100%; }
button, input { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; margin: 0; }
em { font-style: italic; color: var(--ouro); }

/* Topo */
.qz-topo { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: center; height: 56px; padding: 0 var(--lado); background: rgba(249, 245, 237, .92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--linha); }
.qz-marca { font: 500 19px/1 var(--serif); letter-spacing: .32em; color: var(--tinta); text-decoration: none; padding-left: .32em; }
.qz-voltar { position: absolute; left: 8px; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border: 0; background: none; font-size: 20px; color: var(--suave); cursor: pointer; }
.qz-progresso { position: sticky; top: 56px; z-index: 5; height: 2px; background: var(--linha); }
.qz-progresso span { display: block; height: 100%; width: 0; background: var(--ouro); transition: width .5s var(--lux); }

.qz { max-width: 560px; margin: 0 auto; padding: 0 var(--lado) 48px; }
.qz-tela { animation: qz-entra .55s var(--lux) both; }
@keyframes qz-entra { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .qz-tela { animation: none; } .qz-progresso span { transition: none; } }

.qz-selo { margin: 0 0 12px; font: 500 10.5px/1 var(--sans); letter-spacing: .3em; text-transform: uppercase; color: var(--ouro); }

/* Botões */
.qz-botao { display: inline-flex; align-items: center; justify-content: center; gap: .7rem; min-height: 52px; padding: 0 30px; border: 1px solid var(--tinta); background: var(--tinta); color: #fff; font: 500 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: background .3s, border-color .3s; }
.qz-botao:hover, .qz-botao:focus-visible { background: var(--ouro); border-color: var(--ouro); }
.qz-botao--claro { background: transparent; color: var(--tinta); }
.qz-botao--claro:hover, .qz-botao--claro:focus-visible { background: var(--tinta); color: #fff; border-color: var(--tinta); }
.qz-botao[disabled] { opacity: .55; cursor: wait; }
.qz-link { background: none; border: 0; padding: 8px 0; color: var(--suave); font-size: 13px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* Abertura */
/* A abertura cabe inteira na tela do celular: a foto encolhe para o botão "Começar" ficar sempre visível. */
.qz:has(.qz-intro), .qz:has(.qz-resultado) { padding-bottom: 0; }
.qz-intro { display: flex; flex-direction: column; height: calc(100vh - 56px); height: calc(100dvh - 56px); min-height: 480px; margin: 0 calc(-1 * var(--lado)); }
.qz-intro__foto { flex: 1 1 auto; min-height: 140px; margin: 0; overflow: hidden; }
.qz-intro__foto img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; }
.qz-intro__texto { flex: none; padding: 22px var(--lado) calc(18px + env(safe-area-inset-bottom)); text-align: center; }
.qz-intro .qz-selo { margin-bottom: 10px; }
.qz-intro h1 { font-size: clamp(28px, 8vw, 44px); line-height: 1.08; }
.qz-intro p:not(.qz-selo) { margin: 10px auto 18px; max-width: 34ch; color: var(--suave); font-size: 14px; line-height: 1.5; }
.qz-intro small { display: block; margin-top: 10px; font-size: 12px; color: var(--suave); letter-spacing: .04em; }
.qz-intro .qz-botao { width: 100%; max-width: 320px; }

/* Pergunta */
.qz-pergunta { padding-top: 34px; }
.qz-pergunta h2 { font-size: clamp(27px, 7.4vw, 36px); line-height: 1.15; margin-bottom: 26px; }
.qz-opcoes { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.qz-opcao { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 64px; padding: 14px 18px; border: 1px solid var(--linha); background: var(--papel); text-align: left; font: 400 15.5px/1.4 var(--sans); cursor: pointer; transition: border-color .25s, background .25s, transform .25s var(--lux); }
.qz-opcao:hover { border-color: var(--ouro-claro); }
.qz-opcao:focus-visible { outline: 2px solid var(--ouro); outline-offset: 2px; }
.qz-opcao:active { transform: scale(.985); }
.qz-opcao.is-escolhida { border-color: var(--ouro); background: #f6ecdb; }
.qz-opcao__letra { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid var(--linha); border-radius: 50%; font: 500 15px/1 var(--serif); color: var(--ouro); }
.qz-opcao.is-escolhida .qz-opcao__letra { background: var(--ouro); border-color: var(--ouro); color: #fff; }
.qz-cores { display: flex; margin-left: auto; flex: none; }
.qz-cores i { width: 20px; height: 20px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .12); margin-left: -6px; box-shadow: 0 0 0 2px var(--papel); }

/* Resultado: cabe numa tela do celular (perfil, peças e as duas saídas sem rolar). */
.qz-resultado { display: flex; flex-direction: column; min-height: calc(100vh - 58px); min-height: calc(100dvh - 58px); padding: 18px 0 calc(10px + env(safe-area-inset-bottom)); text-align: center; }
.qz-resultado .qz-selo { margin-bottom: 6px; }
.qz-resultado h2 { font-size: clamp(30px, 8.6vw, 46px); line-height: 1.05; }
.qz-resultado__texto { margin: 8px auto 0; max-width: 42ch; color: var(--suave); font-size: 13.5px; line-height: 1.5; }
.qz-pecas { flex: 1 1 0; display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: minmax(0, 1fr); gap: 8px; min-height: 110px; max-height: 44vh; max-height: 44dvh; margin: 14px 0 0; }
.qz-peca { display: flex; flex-direction: column; min-height: 0; margin: 0; }
.qz-peca img { flex: 1 1 0; width: 100%; height: 0; min-height: 0; object-fit: cover; object-position: center 25%; background: var(--linha); }
.qz-peca figcaption { flex: none; padding-top: 6px; font: 500 14px/1.2 var(--serif); }
.qz-acoes { flex: none; display: grid; gap: 8px; margin: 14px 0 0; }
.qz-acoes .qz-botao { width: 100%; min-height: 48px; padding: 0 16px; letter-spacing: .12em; }

/* Cadastro no Clube VIP (tela própria) */
.qz-vip { padding: 22px 0 calc(24px + env(safe-area-inset-bottom)); }
.qz-vip h2 { font-size: clamp(26px, 7.4vw, 36px); line-height: 1.12; }
.qz-vip form > p:not(.qz-selo):not(.qz-vip__msg), .qz-vip__ok > p:not(.qz-selo) { margin: 8px 0 18px; font-size: 14px; color: var(--suave); }
.qz-vip label:not(.qz-aceite) { display: block; margin-bottom: 10px; }
.qz-vip label:not(.qz-aceite) span { display: block; margin-bottom: 5px; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--suave); }
.qz-vip input[type=text], .qz-vip input[type=email], .qz-vip input[type=tel] { width: 100%; height: 48px; padding: 0 14px; border: 1px solid var(--linha); background: var(--papel); font-size: 16px; }
.qz-vip input:focus { outline: none; border-color: var(--ouro); }
.qz-aceite { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 16px; font-size: 12.5px; line-height: 1.45; color: var(--suave); }
.qz-aceite input { flex: none; width: 18px; height: 18px; margin-top: 1px; accent-color: var(--ouro); }
.qz-vip .qz-botao { width: 100%; }
.qz-vip__msg { min-height: 1.4em; margin: 10px 0 0; font-size: 13px; color: var(--ouro); }
.qz-vip__msg.is-erro { color: #b32d2e; }
.qz-hp { position: absolute; left: -9999px; }

.qz-fim { flex: none; margin-top: 4px; display: flex; justify-content: center; gap: 22px; }
.qz-aviso { padding: 40px 0; text-align: center; color: var(--suave); }

@media (min-width: 720px) {
  .qz-intro { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 40px; height: auto; min-height: 0; margin: 40px 0 0; }
  .qz-intro__foto { aspect-ratio: 4 / 5; }
  .qz-intro__texto { padding: 0; text-align: left; }
  .qz-intro p:not(.qz-selo) { margin-left: 0; }
  .qz { max-width: 640px; }
  .qz-intro { max-width: none; }
  main.qz:has(.qz-intro) { max-width: 960px; }
}

/* Celulares bem baixos: aperta o resultado para os botões e links caberem sem rolar. */
@media (max-height: 620px) {
  .qz-resultado { padding-top: 10px; }
  .qz-resultado__texto { font-size: 12.5px; line-height: 1.45; }
  .qz-pecas { margin-top: 10px; min-height: 96px; }
  .qz-acoes { margin-top: 10px; }
  .qz-acoes .qz-botao { min-height: 44px; }
  .qz-fim { margin-top: 0; }
  .qz-fim .qz-link { padding: 4px 0; }
  .qz-vip { padding-top: 12px; }
  .qz-vip form > p:not(.qz-selo):not(.qz-vip__msg) { display: none; }
  .qz-vip h2 { margin-bottom: 12px; }
  .qz-vip input[type=text], .qz-vip input[type=email], .qz-vip input[type=tel] { height: 44px; }
}
