/* Página do pedido: celular primeiro, duas colunas no computador */
.layout-pedido { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
.pilha-itens { display: flex; flex-direction: column; gap: 10px; }
.pilha-linhas { display: flex; flex-direction: column; gap: 8px; }
.item {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px;
  background: #fff; border: 1px solid var(--borda); border-radius: var(--raio);
}
.item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.item-nome { font-weight: 700; }
.item-preco { font-size: 14px; color: var(--tinta-3); }
.contador { display: flex; align-items: center; gap: 4px; }
.contador button {
  width: 44px; height: 44px; border-radius: 22px; font-size: 20px; font-weight: 700; cursor: pointer;
  border: 1px solid var(--borda-campo); background: var(--fundo);
}
.contador button.mais { border-color: var(--acento); background: var(--acento-claro); color: var(--acento-escuro); }
.contador output { min-width: 30px; text-align: center; font-size: 18px; font-weight: 800; }

.opcoes-pagamento { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.opcao {
  position: relative; display: flex; flex-direction: column; gap: 2px; padding: 14px 16px;
  border: 1px solid var(--borda-campo); border-radius: var(--raio); background: #fff; cursor: pointer;
}
.opcao input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.opcao:has(input:checked) { border: 2px solid var(--acento); background: var(--acento-claro); padding: 13px 15px; }
.opcao:has(input:focus-visible) { outline: 2px solid var(--acento); outline-offset: 2px; }
.opcao-titulo { font-weight: 800; }
.opcao-desc { font-size: 14px; color: var(--tinta-2); }
.privacidade { margin-top: -8px; }

/* No celular, o total e o botão ficam presos embaixo */
.resumo-lateral {
  position: sticky; bottom: 0; z-index: 2; margin: 0 -20px -48px;
  display: flex; flex-direction: column; gap: 10px; padding: 14px 20px 20px;
  background: #fff; border-top: 1px solid var(--borda); box-shadow: 0 -6px 16px rgba(31, 36, 48, .06);
}
.so-computador { display: none; }
.titulo-tela, .titulo-aviso { font-size: 26px; font-weight: 800; }
.dados-resumo { gap: 14px; }

@media (min-width: 900px) {
  .layout-pedido { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; }
  .opcoes-pagamento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .resumo-lateral {
    position: sticky; top: 24px; bottom: auto; margin: 0; padding: 22px;
    border: 1px solid var(--borda); border-radius: 18px; box-shadow: none;
  }
  .resumo-lateral h2 { font-size: 18px; font-weight: 800; }
  .so-computador { display: flex; }
  hr.so-computador { display: block; }
}

/* Comprovante e confirmação */
.confirmacao { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.comprovante { display: flex; flex-direction: column; gap: 14px; padding: 24px; }
.comprovante-topo { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.comprovante h2 { font-size: 20px; font-weight: 800; }
.qr-vazio {
  width: 200px; height: 200px; margin: 0 auto; border-radius: 12px; border: 2px dashed var(--borda-campo);
  display: flex; align-items: center; justify-content: center; color: var(--tinta-3);
}

@media print {
  @page { margin: 16mm; }
  body { background: #fff; }
  .topo, .nao-imprimir { display: none !important; }
  .conteudo { padding: 0; }
  .comprovante { border: 1px solid #999; }
}
