/* Estilo das telas do app "transformar um cômodo" da Brilha Decor.
   Público: mulheres de 35 a 60+, no celular. Regras: corpo 18 px (nada abaixo de 17 px), nunca peso abaixo
   de 400, botões grandes com texto, contraste alto, cores quentes e claras da marca. */

:root {
  --creme: #FBF6EE;
  --areia: #F1E6D4;
  --areia-forte: #E4D3B9;
  --borda: #D9C7AC;
  --terracota: #A44E32;          /* contraste 5,6:1 com branco */
  --terracota-escura: #8A3F27;
  --terracota-clara: #F6E3D8;
  --texto: #3B2A20;              /* contraste 13:1 com o creme */
  --texto-suave: #6B5546;        /* contraste 6,5:1 com o creme */
  --branco: #FFFFFF;
  --erro: #9B2C1F;
  --erro-fundo: #FBE9E5;
  --raio: 16px;
  --check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  color-scheme: light;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--creme);
  color: var(--texto);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.55;
}

img { max-width: 100%; }

[hidden] { display: none !important; }

.visualmente-oculto {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

:focus-visible { outline: 3px solid var(--texto); outline-offset: 3px; }

/* ---------- cabeçalho ---------- */
.topo {
  position: sticky; top: 0; z-index: 20;
  background: var(--areia);
  border-bottom: 1px solid var(--borda);
  padding: 12px 16px;
  text-align: center;
}
.marca {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: .5px;
  color: var(--terracota-escura);
  text-decoration: none;
}

.conteudo { max-width: 560px; margin: 0 auto; padding: 20px 16px 56px; }

h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 30px; line-height: 1.2; font-weight: 700;
  margin: 6px 0 12px;
}
h2 {
  display: flex; align-items: center; gap: 12px;
  font-size: 22px; line-height: 1.3; font-weight: 700;
  margin: 0 0 12px;
}
p { margin: 0 0 12px; }

.texto-suave { color: var(--texto-suave); }

.passo {
  flex: none;
  width: 36px; height: 36px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--terracota); color: var(--branco);
  font-size: 18px; font-weight: 700;
}

/* ---------- blocos ---------- */
.bloco {
  background: var(--branco);
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  padding: 20px 16px;
  margin: 0 0 18px;
  box-shadow: 0 1px 3px rgba(59, 42, 32, .06);
  scroll-margin-top: 84px;
}
.bloco.com-erro { border: 2px solid var(--erro); }
.explica { color: var(--texto-suave); margin-bottom: 14px; }

.erro-campo {
  margin: 12px 0 0;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--erro-fundo);
  color: var(--erro);
  font-weight: 600;
}

/* ---------- campos ---------- */
.rotulo { display: block; margin-bottom: 8px; font-weight: 500; }
.campo {
  width: 100%;
  min-height: 58px;
  padding: 14px 16px;
  border: 2px solid var(--borda);
  border-radius: 12px;
  background: var(--creme);
  color: var(--texto);
  font: inherit; font-size: 20px; font-weight: 500;
}
.campo:focus { outline: 3px solid var(--texto); outline-offset: 2px; border-color: var(--terracota); }

/* ---------- botões ---------- */
.botao {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%;
  min-height: 60px;
  padding: 14px 20px;
  border: 2px solid transparent;
  border-radius: 14px;
  font: inherit; font-size: 19px; font-weight: 600; line-height: 1.3;
  text-align: center; text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.botao svg { flex: none; width: 26px; height: 26px; }
.botao-principal { background: var(--terracota); color: var(--branco); }
.botao-principal:hover { background: var(--terracota-escura); }
.botao-secundario { background: var(--branco); color: var(--terracota-escura); border-color: var(--terracota); }
.botao-secundario:hover { background: var(--terracota-clara); }
.botao-grande { min-height: 70px; font-size: 21px; font-weight: 700; }
.botao[disabled] { opacity: .75; cursor: wait; }
.botao + .botao { margin-top: 12px; }
.label-botao:has(input:focus-visible) { outline: 3px solid var(--texto); outline-offset: 3px; }

.girando {
  width: 22px; height: 22px; flex: none;
  border: 3px solid rgba(255, 255, 255, .45);
  border-top-color: var(--branco);
  border-radius: 50%;
  animation: girar .9s linear infinite;
}
@keyframes girar { to { transform: rotate(360deg); } }

/* ---------- abertura e aviso de pedido anterior ---------- */
.abertura p { font-size: 19px; }
.aviso-ultimo {
  background: var(--areia);
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  padding: 16px;
  margin: 0 0 18px;
}

/* ---------- cartões de escolha (cômodo e estilo) ---------- */
.opcoes { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.opcoes-lista { display: grid; grid-template-columns: 1fr; gap: 12px; }

.cartao {
  position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  min-height: 140px;
  padding: 16px 10px;
  border: 2px solid var(--borda);
  border-radius: 14px;
  background: var(--creme);
  text-align: center;
  font-size: 19px; font-weight: 600; line-height: 1.25;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.cartao input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.cartao svg { width: 56px; height: 56px; color: var(--terracota); }
.cartao:has(input:focus-visible) { outline: 3px solid var(--texto); outline-offset: 2px; }
.cartao.selecionado {
  border-color: var(--terracota);
  background: var(--terracota-clara);
  box-shadow: inset 0 0 0 2px var(--terracota);
}
.cartao.selecionado::after {
  content: "";
  position: absolute; top: 10px; right: 10px;
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--terracota) var(--check) center / 18px no-repeat;
}

/* estilo: cartão deitado, bloco de cor à esquerda e texto à direita */
.cartao-estilo {
  flex-direction: row; align-items: stretch; justify-content: flex-start; gap: 0;
  min-height: 108px;
  padding: 0;
  overflow: hidden;
  text-align: left;
}
.estilo-visual { flex: none; width: 112px; position: relative; }
.estilo-visual img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
.estilo-texto { display: flex; flex-direction: column; justify-content: center; padding: 12px 48px 12px 14px; }
.estilo-nome { font-size: 20px; font-weight: 700; }
.estilo-desc { font-size: 18px; font-weight: 400; color: var(--texto-suave); }

/* blocos de cor provisórios (trocar pela foto própria de cada estilo) */
.estilo-contemporaneo { background: linear-gradient(180deg, #D9D4CC 0 52%, #8C857C 52% 78%, #2E2B28 78%); }
.estilo-escandinavo   { background: linear-gradient(180deg, #F4F1EA 0 50%, #D8C3A0 50% 78%, #A9B8A6 78%); }
.estilo-classico      { background: linear-gradient(180deg, #EADFC8 0 50%, #C9A96A 50% 76%, #7A5C3E 76%); }
.estilo-boho          { background: linear-gradient(180deg, #E8C9A6 0 48%, #B5683F 48% 74%, #6E7F4F 74%); }

/* ---------- foto ---------- */
.dicas { list-style: none; margin: 0 0 16px; padding: 0; }
.dicas li {
  position: relative;
  padding: 8px 0 8px 40px;
  border-bottom: 1px solid var(--areia);
}
.dicas li:last-child { border-bottom: 0; }
.dicas li::before {
  content: "";
  position: absolute; left: 0; top: 10px;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--terracota) var(--check) center / 16px no-repeat;
}
.previa { margin: 0 0 16px; }
.previa img {
  display: block; width: 100%; max-height: 320px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--borda);
  background: var(--areia);
}
.previa-ok { margin: 10px 0 0; font-weight: 600; color: var(--terracota-escura); }
.aviso-suave {
  margin: 10px 0 0;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--areia);
}

/* ---------- o que fica ---------- */
.toques { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: 10px; }
.toque {
  position: relative;
  display: flex; align-items: center; gap: 12px;
  min-height: 60px;
  padding: 12px 14px;
  border: 2px solid var(--borda);
  border-radius: 12px;
  background: var(--creme);
  font-size: 19px; font-weight: 500;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.toque input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.toque:has(input:focus-visible) { outline: 3px solid var(--texto); outline-offset: 2px; }
.caixa {
  flex: none;
  width: 28px; height: 28px;
  border: 2px solid var(--texto-suave);
  border-radius: 7px;
  background: var(--branco);
}
.toque.selecionado { border-color: var(--terracota); background: var(--terracota-clara); font-weight: 600; }
.toque.selecionado .caixa { border-color: var(--terracota); background: var(--terracota) var(--check) center / 18px no-repeat; }

/* ---------- envio ---------- */
.envio { margin-top: 8px; }
.envio .nota { margin: 12px 0 0; text-align: center; color: var(--texto-suave); }
.erro-geral {
  margin: 0 0 14px;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--erro-fundo);
  border: 2px solid var(--erro);
  color: var(--erro);
  font-weight: 600;
}

/* ---------- acompanhamento ---------- */
.linha-tempo { list-style: none; margin: 0; padding: 0; }
.etapa { position: relative; display: flex; gap: 14px; padding: 0 0 22px; }
.etapa:last-child { padding-bottom: 0; }
.etapa::before {
  content: "";
  position: absolute; left: 18px; top: 40px; bottom: 2px;
  width: 3px; margin-left: -1px;
  background: var(--borda);
}
.etapa:last-child::before { display: none; }
.etapa.feita::before { background: var(--terracota); }
.marcador {
  flex: none; position: relative; z-index: 1;
  width: 38px; height: 38px; border-radius: 50%;
  border: 3px solid var(--borda);
  background: var(--branco);
}
.etapa.feita .marcador { border-color: var(--terracota); background: var(--terracota) var(--check) center / 20px no-repeat; }
.etapa.atual .marcador { border-color: var(--terracota); animation: pulsar 1.8s ease-in-out infinite; }
.etapa.atual .marcador::after {
  content: "";
  position: absolute; top: 7px; left: 7px; right: 7px; bottom: 7px;
  border-radius: 50%;
  background: var(--terracota);
}
.etapa-nome { margin: 5px 0 0; font-size: 19px; font-weight: 500; color: var(--texto-suave); }
.etapa.feita .etapa-nome { color: var(--texto); }
.etapa.atual .etapa-nome { color: var(--texto); font-weight: 700; }
.etapa-detalhe { margin: 4px 0 0; font-size: 18px; color: var(--texto-suave); }
@keyframes pulsar {
  0%, 100% { box-shadow: 0 0 0 0 rgba(164, 78, 50, .35); }
  50% { box-shadow: 0 0 0 9px rgba(164, 78, 50, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .etapa.atual .marcador, .girando { animation: none; }
}

.miniatura {
  display: block; width: 100%; max-height: 280px;
  object-fit: cover;
  border-radius: 12px;
  background: var(--areia);
}
.link-copiavel { margin-top: 12px; font-size: 18px; }
.aviso {
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--areia);
  border: 1px solid var(--borda);
}

/* ---------- antes e depois ---------- */
.comparar {
  --pos: 50%;
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--raio);
  overflow: hidden;
  background: var(--areia);
  touch-action: pan-y;
  -webkit-user-select: none; user-select: none;
  cursor: ew-resize;
  -webkit-tap-highlight-color: transparent;
}
@supports not (aspect-ratio: 1 / 1) {
  .comparar { height: 72vw; max-height: 420px; }
}
.comparar img {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%;
  /* contain: a foto aparece inteira (o quadro já segue o formato da imagem final; a foto de antes nunca é cortada) */
  object-fit: contain;
  pointer-events: none;
  -webkit-user-drag: none;
}
.comparar .img-antes {
  -webkit-clip-path: inset(0 calc(100% - var(--pos)) 0 0);
  clip-path: inset(0 calc(100% - var(--pos)) 0 0);
}
.comparar-linha {
  position: absolute; top: 0; bottom: 0; left: var(--pos);
  width: 4px; margin-left: -2px;
  background: var(--branco);
  box-shadow: 0 0 6px rgba(0, 0, 0, .35);
  pointer-events: none;
}
.comparar-alca {
  position: absolute; top: 50%; left: 50%;
  width: 54px; height: 54px; margin: -27px 0 0 -27px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--branco);
  color: var(--terracota);
  box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
}
.comparar-alca svg { width: 32px; height: 32px; }
.etiqueta {
  position: absolute; top: 12px; z-index: 2;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(59, 42, 32, .82);
  color: var(--branco);
  font-size: 18px; font-weight: 600;
  pointer-events: none;
}
.etiqueta-antes { left: 12px; }
.etiqueta-depois { right: 12px; }
.selo-ia {
  position: absolute; right: 12px; bottom: 12px; z-index: 3;
  padding: 3px 12px;
  border-radius: 8px;
  background: var(--branco);
  color: var(--terracota-escura);
  border: 2px solid var(--terracota);
  font-size: 18px; font-weight: 700; letter-spacing: .5px;
  pointer-events: none;
}
.aviso-ilustrativo {
  margin: 10px 0 6px;
  font-size: 18px;
  color: var(--texto-suave);
}
.dica-arrastar { margin: 0 0 24px; font-weight: 500; }

/* ---------- peças ---------- */
.lista-pecas { list-style: none; margin: 0 0 24px; padding: 0; }
/* foto à esquerda com loja e preço ao lado; nome, medidas e botão na largura toda */
.peca {
  display: grid;
  grid-template-columns: 112px 1fr;
  column-gap: 14px;
  row-gap: 8px;
  background: var(--branco);
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  padding: 16px;
  margin: 0 0 16px;
}
.peca-foto {
  width: 112px; height: 112px;
  border-radius: 10px;
  border: 1px solid var(--areia-forte);
  background: var(--branco);
  overflow: hidden;
}
.peca-foto img { display: block; width: 100%; height: 100%; object-fit: contain; }
.peca-info { display: contents; }
.peca-foto { grid-column: 1; grid-row: 1 / span 2; }
.peca-loja { grid-column: 2; grid-row: 1; align-self: end; margin: 0; font-size: 18px; font-weight: 600; color: var(--terracota-escura); }
.peca-preco { grid-column: 2; grid-row: 2; align-self: start; margin: 0; }
.peca-preco strong { font-size: 21px; font-weight: 700; white-space: nowrap; }
.peca-cabeca { grid-column: 1 / -1; grid-row: 3; margin-top: 4px; }
.peca-nome { margin: 0; font-size: 19px; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.peca-detalhes { grid-column: 1 / -1; grid-row: 4; }
.peca-linha { margin: 0 0 6px; color: var(--texto); }
.peca-linha:last-child { margin-bottom: 0; }
.peca-linha strong { font-weight: 600; color: var(--texto-suave); }
.peca-termo { padding: 10px 12px; border-radius: 10px; background: var(--areia); }
.peca .botao { grid-column: 1 / -1; grid-row: 5; margin-top: 6px; }
.peca-sugestao { border-style: dashed; border-width: 2px; }
.selo-sugestao {
  display: inline-block;
  margin: 0 0 8px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--areia);
  border: 1px solid var(--borda);
  color: var(--terracota-escura);
  font-size: 17px; font-weight: 600;
}

/* ---------- perguntas novas do formulário ---------- */
.toque-redondo .caixa { border-radius: 50%; }
.toque-redondo.selecionado .caixa { background: var(--terracota) var(--check) center / 16px no-repeat; }
.toques-curtos { grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); }
.toques-coluna { grid-template-columns: 1fr; }
.rotulo-espacado { margin-top: 18px; }
.campo-texto { font-size: 19px; font-weight: 400; }
.campo-texto::placeholder { color: var(--texto-suave); opacity: 1; }
.contador { margin: 6px 0 0; font-size: 17px; color: var(--texto-suave); text-align: right; }
.subpergunta {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--areia-forte);
}
.subpergunta-titulo { font-size: 20px; font-weight: 700; margin-bottom: 12px; }

/* ---------- revisão ---------- */
.aviso-revisao {
  background: var(--terracota-clara);
  border: 2px solid var(--terracota);
  font-weight: 600;
  margin-bottom: 18px;
}
.etapa.em-revisao .marcador { animation: none; }

/* ---------- seções do resultado ---------- */
.secao-resultado { margin: 0 0 28px; }
.secao-resultado > h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 25px;
  color: var(--terracota-escura);
  margin-bottom: 10px;
}
.explicacao {
  background: var(--branco);
  border: 1px solid var(--borda);
  border-left: 5px solid var(--terracota);
  border-radius: var(--raio);
  padding: 18px 16px 6px;
}
.explicacao p { font-size: 19px; }

.grupo-aproveite { margin: 0 0 20px; }
.grupo-aproveite-titulo {
  margin: 0 0 10px;
  font-size: 21px; font-weight: 700;
  color: var(--texto);
}
.lista-aproveite { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.card-aproveite {
  background: var(--branco);
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  padding: 12px;
}
/* com foto: recorte à esquerda (até 3, um embaixo do outro) e a frase à direita */
.card-aproveite.com-foto { display: grid; grid-template-columns: 120px 1fr; column-gap: 14px; align-items: center; }
.recortes { display: flex; flex-direction: column; gap: 6px; }
.recortes img {
  display: block;
  width: 120px; height: 100px;
  object-fit: cover;
  border-radius: 10px;
  background: var(--areia);
}
.card-aproveite-texto { margin: 0; }
.grupo-sai .card-aproveite { background: var(--creme); }

.lista-proxima { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.proxima-item {
  background: var(--branco);
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  padding: 16px;
}
.proxima-nome { margin: 0 0 6px; font-size: 19px; font-weight: 600; line-height: 1.3; }
.proxima-texto { margin: 0 0 8px; }
.proxima-termo { margin: 0; padding: 10px 12px; border-radius: 10px; background: var(--areia); }
.proxima-termo strong { font-weight: 600; }

.avisos-finais {
  list-style: none;
  margin: 0 0 24px; padding: 14px 16px;
  border-radius: 12px;
  background: var(--areia);
  color: var(--texto-suave);
}
.avisos-finais li { margin: 0 0 6px; }
.avisos-finais li:last-child { margin-bottom: 0; }

@media (max-width: 360px) {
  .peca { grid-template-columns: 88px 1fr; }
  .peca-foto { width: 88px; height: 88px; }
  h1 { font-size: 27px; }
}
.peca-foto:empty { background: var(--areia); }
