/* Balcão — estilos do aplicativo */

:root {
  --tinta: #1d2b53;
  --tinta-clara: #34457c;
  --papel: #eef1f5;
  --fundo-externo: #dfe4ec;
  --superficie: #ffffff;
  --linha: #d9dee7;
  --texto: #18203a;
  --suave: #566078;
  --etiqueta: #ffc933;
  --etiqueta-escura: #e0ad13;
  --ok: #157347;
  --ok-fundo: #e2f3ea;
  --erro: #b3261e;
  --erro-fundo: #fbe7e5;
  --fonte-titulo: "Bricolage Grotesque", "Trebuchet MS", system-ui, sans-serif;
  --fonte: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --topo-h: 56px;
  --abas-h: 64px;
  --seguro-topo: env(safe-area-inset-top, 0px);
  --seguro-base: env(safe-area-inset-bottom, 0px);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--fundo-externo);
  color: var(--texto);
  font: 400 16px/1.45 var(--fonte);
  -webkit-font-smoothing: antialiased;
}

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
img { max-width: 100%; }

:focus-visible { outline: 3px solid var(--tinta); outline-offset: 2px; }
.topo :focus-visible, .btn.principal:focus-visible, .abas :focus-visible { outline-color: #fff; }
.abas :focus-visible { outline-color: var(--tinta); }

.conteudo:focus { outline: none; }
.oculto { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Estrutura ---------- */

.app {
  position: relative;
  max-width: 560px;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--papel);
  box-shadow: 0 0 0 1px rgba(29, 43, 83, 0.06);
}

.topo {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: calc(var(--topo-h) + var(--seguro-topo));
  padding: var(--seguro-topo) 16px 0;
  background: var(--tinta);
  color: #fff;
}
.topo h1 {
  margin: 0;
  flex: 1;
  min-width: 0;
  font: 600 20px/1.2 var(--fonte-titulo);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.topo .logo-mini {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #fff;
  object-fit: contain;
  flex: none;
}
.topo .voltar {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-left: -8px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #fff;
  text-decoration: none;
}
.topo .voltar:active { background: rgba(255, 255, 255, 0.14); }

.conteudo {
  padding: 16px 16px calc(var(--abas-h) + var(--seguro-base) + 96px);
}

.aviso-offline {
  position: sticky;
  top: calc(var(--topo-h) + var(--seguro-topo));
  z-index: 19;
  padding: 8px 16px;
  background: var(--etiqueta);
  color: var(--tinta);
  font-size: 14px;
  font-weight: 600;
}

/* ---------- Navegação inferior ---------- */

.abas {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  max-width: 560px;
  margin: 0 auto;
  padding-bottom: var(--seguro-base);
  background: var(--superficie);
  border-top: 1px solid var(--linha);
}
.abas a {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-height: var(--abas-h);
  padding: 0 2px;
  color: var(--suave);
  font-size: 11px;
  font-weight: 500;
  text-decoration: none;
  text-align: center;
}
.abas a svg { width: 24px; height: 24px; }
.abas a[aria-current="page"] { color: var(--tinta); font-weight: 700; }
.abas a[aria-current="page"]::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 22%;
  right: 22%;
  height: 4px;
  border-radius: 0 0 4px 4px;
  background: var(--etiqueta);
}

.area-fab {
  position: fixed;
  left: 0;
  right: 0;
  bottom: calc(var(--abas-h) + var(--seguro-base) + 14px);
  z-index: 25;
  display: flex;
  justify-content: flex-end;
  max-width: 560px;
  margin: 0 auto;
  padding: 0 16px;
  pointer-events: none;
}
.fab {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 52px;
  padding: 0 20px 0 16px;
  border: 0;
  border-radius: 26px;
  background: var(--etiqueta);
  color: var(--tinta);
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(29, 43, 83, 0.28);
}
.fab svg { width: 22px; height: 22px; }
.fab:active { background: var(--etiqueta-escura); }

/* ---------- Textos ---------- */

h2 {
  margin: 0 0 12px;
  font: 600 22px/1.2 var(--fonte-titulo);
  letter-spacing: -0.01em;
}
h3 {
  margin: 0 0 8px;
  font: 600 17px/1.3 var(--fonte-titulo);
}
p { margin: 0 0 12px; }
.suave { color: var(--suave); }
.pequeno { font-size: 14px; }
.num { font-variant-numeric: tabular-nums; }
.valor {
  font: 600 17px/1.2 var(--fonte-titulo);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* ---------- Busca ---------- */

.busca { position: relative; margin-bottom: 4px; }
.busca svg {
  position: absolute;
  left: 13px;
  top: 50%;
  width: 20px;
  height: 20px;
  transform: translateY(-50%);
  color: var(--suave);
  pointer-events: none;
}
.busca input {
  width: 100%;
  height: 46px;
  padding: 0 14px 0 42px;
  border: 1.5px solid var(--linha);
  border-radius: 23px;
  background: var(--superficie);
}

/* ---------- Listas ---------- */

.lista { margin: 8px 0 0; padding: 0; list-style: none; }
.linha {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--linha);
  color: inherit;
  text-decoration: none;
}
.linha:active { background: rgba(29, 43, 83, 0.05); }
.linha .principal { flex: 1; min-width: 0; }
.linha .titulo {
  display: block;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.linha .sec { display: block; font-size: 14px; color: var(--suave); }
.linha .direita { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: none; }
.miniatura {
  flex: none;
  width: 54px;
  height: 54px;
  border-radius: 10px;
  background: #dfe4ec;
  object-fit: cover;
  display: grid;
  place-items: center;
  color: var(--suave);
  font: 600 20px var(--fonte-titulo);
  overflow: hidden;
}
.miniatura img { width: 100%; height: 100%; object-fit: cover; }

.chip {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 12px;
  background: #e6e9f0;
  color: var(--suave);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.chip.ok { background: var(--ok-fundo); color: var(--ok); }
.chip.erro { background: var(--erro-fundo); color: var(--erro); }

.cancelado .titulo, .cancelado .valor { text-decoration: line-through; color: var(--suave); }

.vazio {
  padding: 40px 12px;
  text-align: center;
  color: var(--suave);
}
.vazio strong { display: block; margin-bottom: 4px; color: var(--texto); font: 600 18px var(--fonte-titulo); }

.carregando { padding: 40px 0; text-align: center; color: var(--suave); }

/* ---------- Formulários ---------- */

.form { display: block; }
.campo { display: block; margin-bottom: 16px; }
.campo > span:first-child, .campo > .rotulo { display: block; margin-bottom: 6px; font-size: 15px; font-weight: 600; }
.campo small { display: block; margin-top: 5px; color: var(--suave); font-size: 13.5px; }
.campo input, .campo select, .campo textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 1.5px solid var(--linha);
  border-radius: 10px;
  background: var(--superficie);
}
.campo textarea { min-height: 84px; resize: vertical; }
.campo input:focus, .campo textarea:focus, .campo select:focus, .busca input:focus {
  outline: 3px solid rgba(29, 43, 83, 0.28);
  outline-offset: 0;
  border-color: var(--tinta);
}
.pares { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.prefixo { position: relative; display: block; }
.prefixo::before {
  content: "R$";
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--suave);
  font-weight: 600;
  pointer-events: none;
}
.prefixo input { padding-left: 42px; }

.msg-erro {
  margin: 0 0 16px;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--erro-fundo);
  color: var(--erro);
  font-weight: 500;
}
.msg-ok {
  margin: 0 0 16px;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--ok-fundo);
  color: var(--ok);
  font-weight: 500;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 20px;
  border: 1.5px solid var(--tinta);
  border-radius: 12px;
  background: transparent;
  color: var(--tinta);
  font-weight: 600;
  text-decoration: none;
}
.btn.principal { background: var(--tinta); color: #fff; }
.btn.principal:active { background: var(--tinta-clara); }
.btn.perigo { border-color: transparent; color: var(--erro); }
.btn.confirma-perigo { border-color: var(--erro); background: var(--erro); color: #fff; }
.btn.bloco { display: flex; width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.45; cursor: not-allowed; }
.btn svg { width: 20px; height: 20px; }
.acoes { display: grid; gap: 10px; margin-top: 8px; }

.chave {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  padding: 12px 0;
  border-top: 1px solid var(--linha);
  border-bottom: 1px solid var(--linha);
}
.chave .rotulo { font-weight: 600; }
.chave small { display: block; color: var(--suave); font-size: 13.5px; }
.chave input {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  flex: none;
  width: 52px;
  height: 30px;
  margin: 0;
  border-radius: 15px;
  background: #b9c0cf;
  cursor: pointer;
  transition: background 0.15s;
}
.chave input::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.15s;
}
.chave input:checked { background: var(--ok); }
.chave input:checked::after { transform: translateX(22px); }

/* Foto do produto / logo */
.foto-campo { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.foto-previa {
  flex: none;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  border: 1.5px dashed #aab2c4;
  border-radius: 14px;
  background: var(--superficie);
  overflow: hidden;
  color: var(--suave);
}
.foto-previa img { width: 100%; height: 100%; object-fit: contain; }
.foto-previa svg { width: 30px; height: 30px; }
.foto-botoes { display: flex; flex-wrap: wrap; gap: 8px; }
.foto-botoes .btn { min-height: 42px; padding: 0 14px; font-size: 15px; }

/* ---------- Talão (resumo do pedido) ---------- */

.talao {
  position: relative;
  margin-bottom: 22px;
  padding: 18px 18px 14px;
  background: var(--superficie);
  filter: drop-shadow(0 1px 1px rgba(29, 43, 83, 0.14));
}
.talao::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 8px;
  background: conic-gradient(from 135deg at top, transparent 90deg, var(--superficie) 0) 0 0 / 16px 8px repeat-x;
}
.talao .cabeca { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.talao .cabeca h2 { margin: 0; font-size: 21px; }
.talao .loja { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.talao .loja img { width: 40px; height: 40px; object-fit: contain; border-radius: 6px; }
.talao .loja strong { font: 600 16px var(--fonte-titulo); }
.talao .meta { margin: 0 0 12px; color: var(--suave); font-size: 14px; }
.talao .cliente { padding: 10px 0; border-top: 1px dashed #b9c0cf; border-bottom: 1px dashed #b9c0cf; margin-bottom: 4px; }
.talao .cliente strong { display: block; }

.item-talao { padding: 10px 0; border-bottom: 1px dashed #d3d8e2; }
.item-talao:last-of-type { border-bottom: 0; }
.item-talao .linha-1 { display: flex; justify-content: space-between; gap: 12px; }
.item-talao .nome { font-weight: 600; overflow-wrap: anywhere; }
.item-talao .conta { color: var(--suave); font-size: 14px; }

.qtd { display: inline-flex; align-items: center; margin-top: 6px; border: 1.5px solid var(--linha); border-radius: 10px; overflow: hidden; }
.qtd button {
  width: 40px;
  height: 38px;
  border: 0;
  background: #f3f5f9;
  font-size: 20px;
  line-height: 1;
}
.qtd button:active { background: #e3e7ef; }
.qtd input {
  width: 54px;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: #fff;
  text-align: center;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
}
.qtd input::-webkit-outer-spin-button, .qtd input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.item-talao .remover { border: 0; background: none; color: var(--erro); font-size: 14px; font-weight: 600; padding: 8px 0 8px 12px; }

.somas { padding-top: 8px; border-top: 2px solid var(--texto); margin-top: 6px; }
.somas .soma { display: flex; justify-content: space-between; padding: 3px 0; }
.somas .total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 8px -18px 0;
  padding: 10px 18px;
  background: var(--etiqueta);
  color: var(--tinta);
}
.somas .total span { font-weight: 700; }
.somas .total strong { font: 700 28px/1.1 var(--fonte-titulo); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }

.selo-cancelado {
  display: inline-block;
  padding: 3px 10px;
  border: 2px solid var(--erro);
  border-radius: 6px;
  color: var(--erro);
  font: 700 14px var(--fonte-titulo);
  transform: rotate(-3deg);
}

.bloco-cliente {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  padding: 12px 14px;
  border: 1.5px solid var(--linha);
  border-radius: 12px;
  background: var(--superficie);
}
.bloco-cliente strong { display: block; }
.bloco-cliente.vazio-sel { border-style: dashed; border-color: #aab2c4; width: 100%; color: var(--tinta); font-weight: 600; text-align: left; }

/* ---------- Folha inferior (sheet) ---------- */

.sheet-fundo {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: rgba(24, 32, 58, 0.5);
}
.sheet {
  width: 100%;
  max-width: 560px;
  max-height: 88vh;
  max-height: 88dvh;
  display: flex;
  flex-direction: column;
  border-radius: 20px 20px 0 0;
  background: var(--superficie);
  animation: subir 0.18s ease-out;
}
@keyframes subir { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
.sheet header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 8px;
}
.sheet header h2 { margin: 0; font-size: 20px; }
.sheet .fechar { border: 0; background: #eef1f5; width: 38px; height: 38px; border-radius: 50%; font-size: 20px; line-height: 1; }
.sheet .corpo { overflow-y: auto; padding: 8px 16px calc(20px + var(--seguro-base)); -webkit-overflow-scrolling: touch; }
.sheet footer { padding: 12px 16px calc(12px + var(--seguro-base)); border-top: 1px solid var(--linha); }
.sheet .linha { width: 100%; background: none; border-left: 0; border-right: 0; border-top: 0; text-align: left; }
.sheet .linha[disabled] { opacity: 0.5; cursor: not-allowed; }

/* ---------- Aviso rápido ---------- */

#toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--abas-h) + var(--seguro-base) + 84px);
  z-index: 80;
  max-width: min(92vw, 520px);
  padding: 11px 18px;
  border-radius: 12px;
  background: var(--texto);
  color: #fff;
  font-weight: 500;
  transform: translateX(-50%);
  pointer-events: none;
}
#toast.erro { background: var(--erro); }

/* ---------- Entrada (login) ---------- */

.entrada { padding: calc(40px + var(--seguro-topo)) 20px 40px; }
.entrada .marca { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.entrada .marca img { width: 52px; height: 52px; border-radius: 12px; }
.entrada .marca span { font: 700 40px/1 var(--fonte-titulo); letter-spacing: -0.03em; color: var(--tinta); }
.entrada .chamada { margin: 0 0 28px; color: var(--suave); font-size: 17px; }
.abas-login { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 20px; border-bottom: 2px solid var(--linha); }
.abas-login button {
  padding: 12px 0;
  border: 0;
  border-bottom: 4px solid transparent;
  margin-bottom: -2px;
  background: none;
  color: var(--suave);
  font-weight: 600;
}
.abas-login button[aria-selected="true"] { color: var(--tinta); border-bottom-color: var(--etiqueta); }

/* ---------- Cartão de informação (Loja) ---------- */

.secao { margin-bottom: 28px; }
.link-catalogo {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 10px 12px;
  border: 1.5px solid var(--linha);
  border-radius: 10px;
  background: var(--superficie);
  font-size: 14.5px;
  overflow-wrap: anywhere;
}
.instalar {
  padding: 14px;
  border-left: 5px solid var(--etiqueta);
  background: var(--superficie);
  border-radius: 0 10px 10px 0;
}
.instalar p:last-child { margin-bottom: 0; }

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

/* ---------- Lote 1: selo de pendentes, filtros e "ver mais" ---------- */
.selo-aba {
  position: absolute;
  top: 6px;
  left: calc(50% + 6px);
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--erro);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
}
.filtros { display: flex; gap: 8px; margin: 10px 0 2px; }
.filtro {
  min-height: 36px;
  padding: 0 14px;
  border: 1.5px solid var(--linha);
  border-radius: 18px;
  background: var(--superficie);
  color: var(--suave);
  font-size: 14px;
  font-weight: 600;
}
.filtro[aria-pressed="true"] { border-color: var(--tinta); background: var(--tinta); color: #fff; }
.mais-area { padding: 14px 0 6px; text-align: center; list-style: none; }
.mais-area .btn { min-width: 200px; }

/* ---------- Lote 2: botões de WhatsApp ---------- */
.btn-zap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  margin-top: 10px;
  padding: 0 18px;
  border-radius: 12px;
  background: #0f7a3d;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}
.btn-zap svg { width: 20px; height: 20px; }
.btn-zap.claro { display: flex; background: #fff; color: #0f7a3d; border: 1.5px solid #0f7a3d; }
.talao .cliente .btn-zap { display: flex; }

/* ---------- Lote 3: relatórios na tela ---------- */
.rel-topo { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.rel-acoes { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.rel-opcao { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.rel-opcao input { width: 20px; height: 20px; }
.rel-resumo { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 16px; }
.rel-resumo > div { display: flex; flex-direction: column; padding: 10px 14px; border-radius: 12px; background: var(--etiqueta); color: var(--tinta); }
.rel-resumo strong { font: 700 20px/1.3 var(--fonte-titulo); }
.tabela-rel { width: 100%; border-collapse: collapse; background: var(--superficie); }
.tabela-rel tr[hidden] { display: none !important; }
.tabela-rel .dir { text-align: right; }
.produtos-cliente { margin: 0; padding: 0; list-style: none; }
.produtos-cliente li { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px dashed #d3d8e2; }
.produtos-cliente li:last-child { border-bottom: 0; }
.zap-texto { display: inline-flex; align-items: center; gap: 6px; color: #0f7a3d; font-weight: 600; text-decoration: none; white-space: nowrap; }
.zap-texto svg { width: 16px; height: 16px; flex: none; }
.zap-icone { flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: #0f7a3d; color: #fff; }
.zap-icone svg { width: 22px; height: 22px; }
.item-cliente { display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--linha); }
.item-cliente .linha { flex: 1; min-width: 0; border-bottom: 0; }
.btn.mini { min-height: 36px; padding: 0 12px; font-size: 14px; border-radius: 10px; }
.marca-lateral { display: none; }
.cab-lista { display: none; }
.coluna-estreita { max-width: 640px; }

@media (max-width: 899px) {
  .tabela-rel thead { display: none; }
  .tabela-rel, .tabela-rel tbody, .tabela-rel tr, .tabela-rel td { display: block; }
  .tabela-rel { background: transparent; }
  .tabela-rel tr { margin-bottom: 10px; padding: 10px 14px; border: 1px solid var(--linha); border-radius: 12px; background: var(--superficie); }
  .tabela-rel tr.detalhe { margin: -6px 0 10px; border-top: 0; border-radius: 0 0 12px 12px; background: #f6f8fb; }
  .tabela-rel td { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
  .tabela-rel td::before { content: attr(data-rotulo); color: var(--suave); font-size: 14px; }
  .tabela-rel td.destaque { display: block; font-size: 17px; font-weight: 700; }
  .tabela-rel td.destaque::before, .tabela-rel td.acoes-linha::before, .tabela-rel tr.detalhe td::before { display: none; }
  .tabela-rel td.acoes-linha { justify-content: flex-start; gap: 8px; padding-top: 8px; }
  .tabela-rel tr.detalhe td { display: block; padding: 0; }
}

/* ---------- Lote 3: versão para computador ---------- */
@media (min-width: 900px) {
  body { background: var(--papel); }
  .app.com-menu { max-width: none; margin: 0; padding-left: 232px; box-shadow: none; }
  .marca-lateral {
    position: fixed; left: 0; top: 0; z-index: 36; width: 232px; height: var(--topo-h);
    display: flex; align-items: center; gap: 10px; padding: 0 16px;
    background: var(--tinta); color: #fff; font: 600 16px var(--fonte-titulo); overflow: hidden;
  }
  .marca-lateral img { width: 30px; height: 30px; border-radius: 7px; background: #fff; object-fit: contain; flex: none; }
  .marca-lateral strong { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .app.com-menu .topo { padding-left: 32px; padding-right: 32px; }
  .app.com-menu .topo .logo-mini { display: none; }

  .abas {
    top: var(--topo-h); bottom: 0; left: 0; right: auto; width: 232px; max-width: none; margin: 0;
    display: flex; flex-direction: column; justify-content: flex-start; gap: 4px; padding: 16px 12px;
    border-top: 0; border-right: 1px solid var(--linha); z-index: 35;
  }
  .abas a { flex-direction: row; justify-content: flex-start; gap: 12px; min-height: 46px; padding: 0 14px; border-radius: 10px; font-size: 15px; font-weight: 600; }
  .abas a:hover { background: rgba(29, 43, 83, 0.06); }
  .abas a[aria-current="page"] { background: var(--tinta); color: #fff; }
  .abas a[aria-current="page"]::before { display: none; }
  .abas a[aria-current="page"] :focus-visible { outline-color: #fff; }
  .selo-aba { position: static; margin-left: auto; }

  .conteudo { max-width: 1120px; margin: 0 auto; padding: 28px 32px 64px; }
  .aviso-offline { padding-left: 32px; }
  .area-fab { left: auto; right: 32px; bottom: 28px; max-width: none; margin: 0; padding: 0; }
  #toast { bottom: 28px; }

  .sheet-fundo { align-items: center; }
  .sheet { max-width: 600px; max-height: 86vh; border-radius: 20px; }

  .lista { border: 1px solid var(--linha); border-radius: 14px; padding: 0 20px; background: var(--superficie); }
  .lista li:last-child > .linha, .lista li:last-child.item-cliente { border-bottom: 0; }
  .lista .linha:hover { background: rgba(29, 43, 83, 0.04); }
  .sheet .lista { border: 0; padding: 0; }
  .tabela-clientes { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; }
  .tabela-clientes .item-cliente:nth-last-child(2):nth-child(odd), .tabela-clientes .item-cliente:last-child { border-bottom: 0; }

  .cab-lista {
    display: grid; gap: 16px; margin-top: 16px; padding: 0 21px 6px;
    color: var(--suave); font-size: 12.5px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase;
  }
  .cab-pedidos { grid-template-columns: minmax(0, 1fr) 150px 130px; }
  .cab-produtos { grid-template-columns: 54px minmax(0, 1fr) 150px 150px; }
  .cab-pedidos span:nth-child(2), .cab-produtos span:nth-child(3) { text-align: right; }
  .tabela-pedidos .linha { display: grid; grid-template-columns: minmax(0, 1fr) 150px 130px; gap: 16px; }
  .tabela-produtos .linha { display: grid; grid-template-columns: 54px minmax(0, 1fr) 150px 150px; gap: 16px; }
  .tabela-pedidos .direita, .tabela-produtos .direita { display: contents; }
  .tabela-pedidos .valor, .tabela-produtos .valor { text-align: right; }
  .tabela-pedidos .chip, .tabela-produtos .chip { justify-self: start; }
  .busca { max-width: 520px; }

  .form { max-width: 720px; }
  .form.duas { max-width: none; display: grid; grid-template-columns: 1fr 1fr; column-gap: 32px; align-items: start; }
  .form.duas > .inteira { grid-column: 1 / -1; }
  .duas-secoes { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start; }

  .tabela-rel-caixa { overflow: hidden; border: 1px solid var(--linha); border-radius: 14px; background: var(--superficie); }
  .tabela-rel th { padding: 11px 14px; border-bottom: 2px solid var(--linha); color: var(--suave); font-size: 12.5px; letter-spacing: 0.05em; text-align: left; text-transform: uppercase; }
  .tabela-rel th.dir { text-align: right; }
  .tabela-rel td { padding: 12px 14px; border-bottom: 1px solid var(--linha); font-variant-numeric: tabular-nums; vertical-align: middle; }
  .tabela-rel td.destaque { font-weight: 600; }
  .tabela-rel td.acoes-linha { white-space: nowrap; text-align: right; }
  .tabela-rel td.acoes-linha .btn { margin-left: 6px; }
  .tabela-rel tbody tr:hover:not(.detalhe) { background: rgba(29, 43, 83, 0.03); }
  .tabela-rel tr.detalhe td { padding: 4px 14px 14px 32px; background: #f6f8fb; }

  .app.admin-largo { max-width: 1000px; }
}

/* Lote 3: painel admin no computador */
@media (min-width: 900px) {
  .app.admin-largo { max-width: 1180px; }
  .admin-largo .acoes { display: flex; gap: 12px; justify-content: flex-start; }
  .admin-largo .acoes .btn.bloco { width: auto; min-width: 200px; padding: 0 22px; }
  .admin-largo .linha .direita { flex-direction: row !important; align-items: center !important; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
  .admin-largo .linha .direita .btn { white-space: nowrap; }
  .admin-largo .linha .principal { min-width: 0; flex: 1; }
}

/* Lote 4: galeria de fotos do produto */
.rotulo-galeria { display: block; margin-bottom: 8px; font-weight: 600; font-size: 14px; }
.rotulo-galeria small, .campo small.suave { font-weight: 400; color: var(--suave); }
.galeria { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; }
.foto-item, .foto-add { position: relative; aspect-ratio: 1/1; border-radius: 12px; overflow: hidden; background: #dfe4ec; }
.foto-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.foto-item .capa { position: absolute; left: 6px; top: 6px; padding: 2px 8px; border-radius: 8px; background: var(--etiqueta, #ffc933); color: var(--tinta, #1d2b53); font-size: 11px; font-weight: 700; }
.foto-acoes { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-between; padding: 4px; background: linear-gradient(transparent, rgba(0,0,0,.55)); }
.foto-acoes button { width: 32px; height: 32px; border: 0; border-radius: 50%; background: rgba(255,255,255,.92); color: #18203a; font-size: 13px; }
.foto-add { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 1.5px dashed var(--linha, #c7cedb); background: #fff; color: var(--tinta, #1d2b53); font-size: 12px; font-weight: 600; }
.foto-add svg { width: 24px; height: 24px; }
.galeria-campo { margin-bottom: 14px; }

/* Lote 5: variações no formulário de produto */
.bloco-variacoes { padding: 14px; border: 1.5px solid var(--linha, #d9dee7); border-radius: 12px; background: #fff; margin-bottom: 14px; }
.bloco-variacoes[hidden], #campo-estoque[hidden] { display: none; }
.duas-colunas-var { display: grid; grid-template-columns: 1fr; gap: 0 14px; }
@media (min-width: 640px) { .duas-colunas-var { grid-template-columns: 1fr 1.6fr; } }
.tabela-combos { border: 1px solid var(--linha, #d9dee7); border-radius: 10px; overflow: hidden; }
.cab-combos, .linha-combo, .total-combos { display: grid; grid-template-columns: 1fr 110px; align-items: center; gap: 10px; padding: 8px 12px; }
.cab-combos { background: #f3f5f9; font-size: 13px; font-weight: 600; color: var(--suave); }
.linha-combo { border-top: 1px solid var(--linha, #d9dee7); }
.linha-combo input { width: 100%; min-height: 38px; padding: 0 10px; border: 1.5px solid var(--linha, #d9dee7); border-radius: 8px; font: inherit; }
.total-combos { border-top: 1px solid var(--linha, #d9dee7); background: #f8f9fc; font-size: 13px; color: var(--suave); }
.total-combos span:last-child { text-align: right; font-weight: 600; }

/* Lote 5.1: contadores no seletor de produtos do pedido */
.qtd-n { min-width: 34px; padding: 0 4px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.qtd.qtd-linha { margin-top: 4px; }
.btn.pequeno { min-height: 36px; padding: 0 14px; font-size: 14px; margin-top: 4px; }
.lista .linha[data-id], .lista .linha[data-vid] { cursor: default; }

/* Lote 5.1: no celular, não mostra linhas em branco nos cartões dos relatórios */
@media (max-width: 899px) {
  .tabela-rel td:empty { display: none; }
}
