:root {
  color-scheme: light;
  --page: #f6f6f2;
  --surface: #ffffff;
  --surface-2: #f2f1ec;
  --ink: #0b0b0b;
  --ink-2: #52514e;
  --muted: #898781;
  --line: #e4e3dc;
  --line-2: #cfcec5;
  --side: #0f1a11;
  --side-2: #182619;
  --brand: #8cc152;
  --brand-ink: #10200a;
  --brand-dark: #1f3d25;
  --series-1: #2a78d6;
  --series-2: #eb6834;
  --series-prev: #c3c2b7;
  --good: #0ca30c;
  --good-text: #006300;
  --warning: #fab219;
  --serious: #ec835a;
  --critical: #d03b3b;
  --display: 'Rajdhani', 'Arial Narrow', sans-serif;
  --body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --r: 10px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body { background: var(--page); color: var(--ink); font: 400 14px/1.5 var(--body); -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--series-1); outline-offset: 2px; }
.num, td.n, th.n { font-variant-numeric: tabular-nums; text-align: right; }

.tela-carregando { height: 100vh; display: grid; place-items: center; background: var(--side); }
.tela-carregando img { animation: piscar 1.2s infinite; }
@keyframes piscar { 50% { opacity: .4; } }

/* ---------- login ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 16px; background: radial-gradient(circle at 70% 20%, #1f3d25, var(--side) 60%); }
.login form { width: min(400px, 100%); background: var(--surface); border-radius: 16px; padding: 32px; display: flex; flex-direction: column; gap: 14px; box-shadow: 0 30px 80px rgba(0, 0, 0, .35); }
.login img { height: 44px; width: auto; filter: brightness(0); margin-bottom: 8px; align-self: flex-start; }
.login h1 { font-family: var(--display); font-size: 28px; text-transform: uppercase; letter-spacing: .03em; line-height: 1; }
.login p { color: var(--ink-2); }

/* ---------- estrutura ---------- */
.app { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
.lateral { position: sticky; top: 0; height: 100vh; background: var(--side); color: #dfe5d8; display: flex; flex-direction: column; padding: 18px 12px; overflow-y: auto; }
.lateral .logo { display: flex; align-items: center; gap: 10px; padding: 4px 10px 22px; }
.lateral .logo img { height: 30px; width: auto; }
.lateral nav { display: flex; flex-direction: column; gap: 2px; }
.lateral nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; text-decoration: none; font-weight: 500; color: #c4ccbc; transition: background .2s, color .2s; }
.lateral nav a:hover { background: var(--side-2); color: #fff; }
.lateral nav a.on { background: var(--brand); color: var(--brand-ink); }
.lateral nav a .badge { margin-left: auto; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--serious); color: #fff; font-size: 12px; font-weight: 700; display: grid; place-items: center; }
.lateral nav a.on .badge { background: var(--brand-ink); color: var(--brand); }
.lateral .sep { height: 1px; background: rgba(255, 255, 255, .08); margin: 12px 8px; }
.lateral .usuario { margin-top: auto; padding: 14px 12px 4px; border-top: 1px solid rgba(255, 255, 255, .08); display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.lateral .usuario small { color: #8f9a87; text-transform: capitalize; }
.lateral .usuario button { margin-top: 8px; align-self: flex-start; color: #c4ccbc; text-decoration: underline; text-underline-offset: 3px; font-size: 13px; }
.status-rede { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #8f9a87; margin-top: 6px; }
.status-rede i { width: 8px; height: 8px; border-radius: 50%; background: var(--good); }
.status-rede.off i { background: var(--critical); }

.conteudo { min-width: 0; padding: 24px clamp(16px, 3vw, 36px) 64px; }
.cab { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-bottom: 20px; }
.cab h1 { font-family: var(--display); font-size: 30px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; line-height: 1; }
.cab .sub { color: var(--muted); font-size: 13px; }
.cab .acoes { margin-left: auto; display: flex; flex-wrap: wrap; gap: 8px; }
.topo-movel { display: none; }

.abas { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; scrollbar-width: none; }
.abas button { padding: 10px 14px; font-weight: 500; color: var(--ink-2); border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.abas button:hover { color: var(--ink); }
.abas button.on { color: var(--ink); border-color: var(--ink); }

/* ---------- componentes ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 8px; font-weight: 600; font-size: 14px; white-space: nowrap; border: 1px solid transparent; transition: background .2s, border-color .2s, opacity .2s; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-p { background: var(--brand-dark); color: #fff; }
.btn-p:hover { background: #2a5232; }
.btn-v { background: var(--brand); color: var(--brand-ink); }
.btn-v:hover { background: #9dcc68; }
.btn-s { background: var(--surface); border-color: var(--line-2); }
.btn-s:hover { border-color: var(--ink-2); }
.btn-g { color: var(--ink-2); }
.btn-g:hover { background: var(--surface-2); color: var(--ink); }
.btn-d { color: var(--critical); border-color: #f1c9c9; background: #fff; }
.btn-d:hover { background: #fdf1f1; }
.btn-xl { height: 54px; font-size: 16px; padding: 0 22px; border-radius: 10px; }
.btn-sm { height: 30px; padding: 0 10px; font-size: 13px; border-radius: 6px; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; min-width: 0; }
.card h2, .card h3 { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.card h2 .mais, .card h3 .mais { margin-left: auto; text-transform: none; letter-spacing: 0; font-weight: 500; color: var(--series-1); font-size: 13px; text-decoration: none; }
.grade { display: grid; gap: 14px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-2-1 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.mb { margin-bottom: 14px; }

.kpi { display: flex; flex-direction: column; gap: 4px; }
.kpi .rot { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); }
.kpi .val { font-size: 28px; font-weight: 600; letter-spacing: -.01em; line-height: 1.15; }
.kpi .cmp { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.delta { font-weight: 600; display: inline-flex; align-items: center; gap: 2px; }
.delta.up { color: var(--good-text); }
.delta.down { color: var(--critical); }
.meta-barra { height: 6px; border-radius: 3px; background: var(--surface-2); margin-top: 8px; overflow: hidden; }
.meta-barra i { display: block; height: 100%; background: var(--series-1); border-radius: 3px; }

.alerta { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.alerta:last-child { border-bottom: 0; }
.alerta .ico { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 12px; font-weight: 700; }
.ico.crit { background: var(--critical); } .ico.warn { background: var(--warning); color: #3a2a00; } .ico.ok { background: var(--good); } .ico.ser { background: var(--serious); }
.alerta b { font-weight: 600; }
.alerta small { color: var(--muted); display: block; }
.vazio { color: var(--muted); font-size: 13px; padding: 12px 0; }

.tabela-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { text-align: left; font-weight: 600; font-size: 12px; color: var(--ink-2); text-transform: uppercase; letter-spacing: .04em; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--surface-2); white-space: nowrap; position: sticky; top: 0; }
td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #fafaf7; }
tr.clicavel { cursor: pointer; }
tfoot td { font-weight: 600; background: var(--surface-2); border-top: 1px solid var(--line-2); }
td.acoes { white-space: nowrap; text-align: right; }
.thumb { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; background: var(--surface-2); }

.tag { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 11px; font-size: 12px; font-weight: 600; background: var(--surface-2); color: var(--ink-2); white-space: nowrap; }
.tag::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.tag.novo { background: #fff4dc; color: #8a5a00; }
.tag.separando { background: #e7f0fb; color: #1c5cab; }
.tag.saiu { background: #efeafb; color: #4a3aa7; }
.tag.entregue, .tag.concluida, .tag.recebida, .tag.pago { background: #e5f5e5; color: var(--good-text); }
.tag.cancelada, .tag.vencido { background: #fbe9e9; color: #a32626; }
.tag.aberta, .tag.aberto { background: #fff4dc; color: #8a5a00; }
.tag.semponto::before { display: none; }

.filtros { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 14px; }
.filtros .campo { margin: 0; }
.periodo { display: inline-flex; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; background: var(--surface); }
.periodo button { height: 36px; padding: 0 12px; font-size: 13px; font-weight: 500; color: var(--ink-2); border-right: 1px solid var(--line); }
.periodo button:last-child { border-right: 0; }
.periodo button.on { background: var(--ink); color: #fff; }

.campo { display: flex; flex-direction: column; gap: 5px; margin-bottom: 12px; min-width: 0; }
.campo > span { font-size: 12px; font-weight: 600; color: var(--ink-2); }
.campo > small { color: var(--muted); font-size: 12px; }
.campo input:not([type=checkbox]):not([type=radio]), .campo select, .campo textarea, .inp {
  height: 38px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface); outline: none; width: 100%; transition: border-color .2s, box-shadow .2s;
}
.campo textarea { height: auto; padding: 8px 12px; resize: vertical; }
.campo input:focus, .campo select:focus, .campo textarea:focus, .inp:focus { border-color: var(--series-1); box-shadow: 0 0 0 3px rgba(42, 120, 214, .15); }
.inp-busca { width: 260px; max-width: 100%; }
.check { display: flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; margin-bottom: 10px; }
.check input { width: 18px; height: 18px; accent-color: var(--brand-dark); }
.form-g { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 0 14px; }
.form-g .full { grid-column: 1 / -1; }
.preco-inp { width: 96px; height: 34px; padding: 0 8px; border-radius: 6px; border: 1px solid var(--line-2); text-align: right; font-variant-numeric: tabular-nums; }
.preco-inp.mudou { border-color: var(--series-1); background: #eef5fd; }

/* ---------- modal ---------- */
.modal-fundo { position: fixed; inset: 0; z-index: 100; background: rgba(15, 26, 17, .55); display: grid; place-items: center; padding: 16px; animation: aparecer .2s; }
@keyframes aparecer { from { opacity: 0; } }
.modal { background: var(--surface); border-radius: 14px; width: min(560px, 100%); max-height: calc(100vh - 32px); display: flex; flex-direction: column; box-shadow: 0 30px 80px rgba(0, 0, 0, .3); animation: subir .25s var(--ease); }
.modal.largo { width: min(920px, 100%); }
@keyframes subir { from { transform: translateY(16px); } }
.modal header { display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal header h2 { font-size: 17px; font-weight: 600; }
.modal header button { margin-left: auto; width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); }
.modal header button:hover { background: var(--surface-2); }
.modal .corpo { padding: 18px 20px; overflow-y: auto; }
.modal footer { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 20px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.erro-form { color: var(--critical); font-size: 13px; margin-top: 4px; }
.erro-form:empty { display: none; }

#avisos { position: fixed; right: 16px; bottom: 16px; z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: flex-end; }
.aviso { padding: 12px 16px; border-radius: 10px; background: var(--ink); color: #fff; font-size: 14px; box-shadow: 0 10px 30px rgba(0, 0, 0, .2); animation: subir .25s var(--ease); max-width: 360px; }
.aviso.erro { background: var(--critical); }
.aviso.ok { background: var(--brand-dark); }

/* ---------- gráficos ---------- */
.graf { position: relative; width: 100%; }
.graf svg { display: block; width: 100%; height: auto; overflow: visible; }
.graf .eixo text { fill: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.graf .grid line { stroke: #ecebe5; stroke-width: 1; }
.graf .base { stroke: var(--line-2); stroke-width: 1; }
.graf .alvo { fill: transparent; cursor: crosshair; }
.graf .mira { stroke: var(--ink-2); stroke-width: 1; stroke-dasharray: 3 3; pointer-events: none; }
.graf .rot-dir { fill: var(--ink-2); font-size: 11px; font-weight: 600; }
.dica { position: absolute; z-index: 5; pointer-events: none; background: var(--ink); color: #fff; padding: 8px 10px; border-radius: 8px; font-size: 12px; line-height: 1.45; white-space: nowrap; transform: translate(-50%, calc(-100% - 10px)); box-shadow: 0 6px 20px rgba(0, 0, 0, .2); }
.dica b { font-weight: 600; }
.dica i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }
.legenda { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12px; color: var(--ink-2); margin-bottom: 8px; }
.legenda span { display: inline-flex; align-items: center; gap: 6px; }
.legenda i { width: 12px; height: 4px; border-radius: 2px; }
.hbar { display: grid; grid-template-columns: minmax(90px, 38%) 1fr auto; align-items: center; gap: 10px; padding: 5px 0; font-size: 13px; }
.hbar .n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); }
.hbar .t { height: 10px; background: var(--surface-2); border-radius: 0 4px 4px 0; position: relative; }
.hbar .t i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--series-1); border-radius: 0 4px 4px 0; }
.hbar .v { font-variant-numeric: tabular-nums; font-weight: 500; min-width: 80px; text-align: right; }

/* ---------- pedidos (quadro) ---------- */
.quadro { display: grid; grid-template-columns: repeat(3, minmax(260px, 1fr)); gap: 14px; align-items: start; }
.coluna { background: var(--surface-2); border-radius: var(--r); padding: 10px; min-height: 120px; }
.coluna > h3 { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; padding: 4px 6px 10px; color: var(--ink-2); }
.coluna > h3 b { margin-left: auto; background: var(--surface); border-radius: 10px; padding: 0 8px; font-size: 12px; }
.ped { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px; margin-bottom: 8px; display: flex; flex-direction: column; gap: 6px; }
.ped .l1 { display: flex; align-items: center; gap: 8px; }
.ped .cod { font-family: var(--display); font-weight: 700; font-size: 18px; letter-spacing: .08em; }
.ped .tempo { margin-left: auto; font-size: 12px; color: var(--muted); }
.ped .tempo.atraso { color: var(--critical); font-weight: 600; }
.ped .cli { font-weight: 600; }
.ped .end { color: var(--ink-2); font-size: 13px; }
.ped .meta { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12px; }
.ped .acoes { display: flex; gap: 6px; margin-top: 4px; }
.ped .acoes .btn { flex: 1; }
.base-tag { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: 11px; font-size: 12px; font-weight: 600; background: #e7f0fb; color: #1c5cab; }

/* ---------- PDV ---------- */
.pdv { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 16px; align-items: start; }
.pdv-busca { position: relative; margin-bottom: 12px; }
.pdv-busca input { height: 52px; font-size: 17px; padding-left: 46px; border-radius: 12px; border: 2px solid var(--line-2); width: 100%; outline: none; background: var(--surface); }
.pdv-busca input:focus { border-color: var(--brand-dark); }
.pdv-busca svg { position: absolute; left: 15px; top: 16px; color: var(--muted); }
.pdv-sugestoes { position: absolute; left: 0; right: 0; top: 56px; z-index: 20; background: var(--surface); border: 1px solid var(--line-2); border-radius: 12px; box-shadow: 0 16px 40px rgba(0, 0, 0, .12); max-height: 360px; overflow-y: auto; }
.pdv-sugestoes button { display: flex; width: 100%; align-items: center; gap: 12px; padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--line); }
.pdv-sugestoes button:hover, .pdv-sugestoes button.sel { background: #eef5fd; }
.pdv-sugestoes img { width: 36px; height: 36px; border-radius: 6px; object-fit: cover; }
.pdv-sugestoes span { flex: 1; }
.atalhos { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.atalho { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; text-align: left; transition: border-color .2s, transform .1s; }
.atalho:hover { border-color: var(--brand-dark); }
.atalho:active { transform: scale(.97); }
.atalho img { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; background: var(--surface-2); }
.atalho span { padding: 8px 10px 2px; font-weight: 600; font-size: 13px; line-height: 1.25; }
.atalho small { padding: 0 10px 8px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.cupom-pdv { position: sticky; top: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; display: flex; flex-direction: column; max-height: calc(100vh - 32px); }
.cupom-pdv header { padding: 14px 16px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.cupom-pdv .linhas { flex: 1; overflow-y: auto; min-height: 120px; }
.lpdv { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 10px 16px; border-bottom: 1px solid var(--line); }
.lpdv .nm { font-weight: 600; }
.lpdv .qt { display: flex; align-items: center; gap: 6px; color: var(--ink-2); font-size: 13px; }
.lpdv .qt input { width: 76px; height: 30px; border: 1px solid var(--line-2); border-radius: 6px; padding: 0 8px; text-align: right; }
.lpdv .tt { font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.lpdv .rm { color: var(--muted); font-size: 12px; text-align: right; }
.lpdv .rm:hover { color: var(--critical); }
.cupom-pdv footer { border-top: 1px solid var(--line); padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.tot-pdv { display: flex; justify-content: space-between; align-items: baseline; }
.tot-pdv b { font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; }
.linha-res { display: flex; justify-content: space-between; font-size: 13px; color: var(--ink-2); }
.cx-status { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.pend-sync { background: #fff4dc; color: #8a5a00; border-radius: 8px; padding: 8px 12px; font-size: 13px; margin-bottom: 12px; display: flex; align-items: center; gap: 10px; }
.pags { display: flex; flex-direction: column; gap: 8px; }
.pag-linha { display: grid; grid-template-columns: 1fr 140px 32px; gap: 8px; align-items: center; }
.formas { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 12px; }
.formas button { height: 56px; border-radius: 10px; border: 1px solid var(--line-2); font-weight: 600; font-size: 13px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.formas button:hover { border-color: var(--brand-dark); background: #f3f8ee; }
.resumo-pag { background: var(--surface-2); border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; margin-top: 10px; }
.resumo-pag div { display: flex; justify-content: space-between; }
.resumo-pag .grande { font-size: 20px; font-weight: 700; }

/* ---------- produtos ---------- */
.foto-up { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.foto-up img { width: 96px; height: 96px; border-radius: 12px; object-fit: cover; background: var(--surface-2); border: 1px solid var(--line); }
.drop { border: 2px dashed var(--line-2); border-radius: 12px; padding: 14px; text-align: center; color: var(--ink-2); font-size: 13px; cursor: pointer; flex: 1; transition: border-color .2s, background .2s; }
.drop:hover, .drop.arrastando { border-color: var(--series-1); background: #eef5fd; }

/* ---------- DRE ---------- */
.dre td:first-child { padding-left: 12px; }
.dre tr.sub td { font-weight: 600; background: #fafaf7; }
.dre tr.res td { font-weight: 700; background: var(--surface-2); font-size: 14px; }
.dre td.ind { padding-left: 28px; color: var(--ink-2); }
.neg { color: var(--critical); }

/* ---------- impressão (cupom 80 mm) ---------- */
#impressao { display: none; }
@media print {
  @page { margin: 4mm; }
  body > *:not(#impressao) { display: none !important; }
  #impressao { display: block !important; font: 12px/1.35 'Courier New', monospace; color: #000; width: 72mm; }
  #impressao.a4 { width: auto; font: 12px/1.4 var(--body); }
  #impressao h1 { font-size: 15px; text-align: center; }
  #impressao .c { text-align: center; }
  #impressao hr { border: 0; border-top: 1px dashed #000; margin: 6px 0; }
  #impressao table { font-size: 12px; }
  #impressao td, #impressao th { padding: 2px 0; border: 0; background: none; }
}

/* ---------- responsivo ---------- */
@media (max-width: 1200px) {
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pdv { grid-template-columns: minmax(0, 1fr) 340px; }
}
@media (max-width: 980px) {
  .app { grid-template-columns: 1fr; }
  .lateral { position: fixed; z-index: 90; left: 0; width: 260px; transform: translateX(-100%); transition: transform .3s var(--ease); }
  .lateral.aberta { transform: none; box-shadow: 20px 0 60px rgba(0, 0, 0, .35); }
  .topo-movel { display: flex; align-items: center; gap: 12px; position: sticky; top: 0; z-index: 50; background: var(--side); color: #fff; padding: 10px 16px; }
  .topo-movel img { height: 26px; width: auto; }
  .topo-movel button { width: 40px; height: 40px; border-radius: 8px; display: grid; place-items: center; }
  .g3, .g-2-1 { grid-template-columns: 1fr; }
  .quadro { grid-template-columns: 1fr; }
  .pdv { grid-template-columns: 1fr; }
  .cupom-pdv { position: static; max-height: none; }
}
@media (max-width: 640px) {
  .g2, .g4 { grid-template-columns: 1fr; }
  .conteudo { padding: 16px 16px 64px; }
  .cab h1 { font-size: 26px; }
  .cab .acoes { margin-left: 0; width: 100%; }
  .inp-busca { width: 100%; }
  .formas { grid-template-columns: repeat(3, 1fr); }
  .modal .corpo { padding: 16px; }
}
