/* Tema do SaaS = tema do sistema Doce Morena: Bootstrap 3.3.2 + base.css do Doce Morena (barra inverse escura, jumbotron cinza,
   trilha de navegacao, .well, .btn, .table, .alert, .label, paginacao) + estes ajustes para o CELULAR em pe, uma mao, galpao com luz ruim:
   alvos grandes, contraste alto e feedback grande. Carregado depois de ../assets/css/bootstrap.min.css e base-doce-morena.css. */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { padding-top: 50px; background: #fff; color: #333; font-size: 14px; padding-bottom: env(safe-area-inset-bottom); }
a { color: #337ab7; }

/* moldura: navbar-inverse fixa + jumbotron compacto (aproveita a tela) + trilha */
.navbar-brand { font-weight: 700; }
.navbar-inverse .navbar-text { color: #9d9d9d; }
.navbar-form.quem { margin: 8px 15px; padding: 0; border: 0; box-shadow: none; }
.navbar-nav > li > a { padding-top: 15px; padding-bottom: 15px; }
.jumbotron { padding: 14px 0 10px; margin: 0 0 12px; border-bottom: 1px solid #e3e3e3; }
.jumbotron h1 { font-size: 26px; margin: 0; font-weight: 600; }
.jumbotron p { margin: 3px 0 0; font-size: 14px; color: #777; }
.container-fluid.corpo { padding-left: 15px; padding-right: 15px; }
.breadcrumb { margin-bottom: 12px; padding: 7px 12px; }
.toolbar { margin: 0 0 12px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
main { padding-bottom: 24px; }

/* titulos */
h1 { font-size: 26px; margin: 4px 0 12px; } h2 { font-size: 18px; margin: 18px 0 8px; color: #555; }
.msg { color: #777; margin: 8px 0; } .msg.erro { color: #a94442; font-weight: 600; }

/* campos (equivalente a .form-control, maiores para toque) */
label { display: block; margin: 10px 0 0; font-weight: 700; color: #333; font-size: 14px; }
input, select, textarea { display: block; width: 100%; margin-top: 4px; padding: 6px 12px; height: 34px; font-size: 14px; line-height: 1.42857143; color: #555; background: #fff; border: 1px solid #ccc; border-radius: 4px; box-shadow: inset 0 1px 1px rgba(0,0,0,.075); }
input[type=checkbox], input[type=radio], input[type=hidden] { display: inline; width: auto; height: auto; }
textarea { height: auto; }
input:focus, select:focus, textarea:focus { outline: 0; border-color: #66afe9; box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102,175,233,.6); }
input[type=file] { height: auto; padding: 8px; }
input::placeholder { color: #aaa; }

/* botoes: <button> e a.botao seguem o .btn-default; .grande e o .btn-primary .btn-lg .btn-block */
button, .botao { display: inline-block; padding: 6px 12px; font-size: 14px; font-weight: 400; line-height: 1.42857143; color: #333; background: #fff; border: 1px solid #ccc; border-radius: 4px; cursor: pointer; text-align: center; text-decoration: none; touch-action: manipulation; }
button:hover, .botao:hover { background: #e6e6e6; border-color: #adadad; color: #333; text-decoration: none; }
button:disabled { opacity: .55; cursor: not-allowed; }
button.grande, .botao.grande { display: block; width: 100%; min-height: 46px; margin: 12px 0; padding: 10px 16px; font-size: 18px; line-height: 1.3333333; border-radius: 6px; font-weight: 600; color: #fff; background: #337ab7; border-color: #2e6da4; }
button.grande:hover, .botao.grande:hover { background: #286090; border-color: #204d74; color: #fff; }
button.grande:disabled { background: #337ab7; }
.navbar .btn, .toolbar .btn { font-size: 14px; }

/* paineis (.well / .panel) */
.cartao { background: #f5f5f5; border: 1px solid #e3e3e3; border-radius: 4px; padding: 15px; margin: 0 0 15px; box-shadow: inset 0 1px 1px rgba(0,0,0,.05); }
.cartao h2 { margin-top: 0; }
figure.cartao { margin: 0 0 15px; }
/* S1: etiqueta de status do fornecedor (Minhas postagens). Paleta do sistema; contraste >= 4,5:1 (letra escura no amarelo). */
.status { display: inline-block; margin-top: 6px; padding: 5px 12px; border-radius: 14px; font-size: 15px; font-weight: 700; line-height: 1.3; }
.status-pendente { background: #555555; color: #ffffff; }
.status-transportadora { background: #f0ad4e; color: #222222; }
.status-entregue { background: #3c763d; color: #ffffff; }
.status-cancelada { background: #a94442; color: #ffffff; }
.armadilha { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }   /* campo-armadilha do cadastro rapido do portal */
.fotos-grade { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.fotos-grade figure.cartao { margin: 0; padding: 8px; }
.fotos-grade img { display: block; width: 100%; height: 160px; object-fit: cover; border-radius: 8px; }

/* resposta GRANDE da leitura (cores do Bootstrap: success / danger / warning / info) */
.feedback { border-radius: 4px; padding: 20px 14px; margin: 0 0 12px; text-align: center; font-size: 26px; font-weight: 700; min-height: 88px; display: flex; align-items: center; justify-content: center; }
.feedback.neutro { background: #d9edf7; color: #31708f; border: 1px solid #bce8f1; font-size: 18px; font-weight: 400; }
.feedback.ok { background: #5cb85c; color: #fff; border: 1px solid #4cae4c; }
.feedback.erro { background: #d9534f; color: #fff; border: 1px solid #d43f3a; }
.feedback.aviso { background: #f0ad4e; color: #fff; border: 1px solid #eea236; }

/* contadores (quadros do painel) */
.grade { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 0 0 12px; }
.grade div { background: #fff; border: 1px solid #ddd; border-top: 3px solid #337ab7; border-radius: 4px; padding: 10px 6px; text-align: center; }
.grade b { display: block; font-size: 30px; color: #333; line-height: 1.1; } .grade small { color: #777; font-size: 13px; }
.grade.pequeno b { font-size: 22px; }

/* abas (QR / Protocolo / Sem pre) */
.abas { display: flex; gap: 0; margin: 0 0 12px; } .abas button { flex: 1; border-radius: 0; margin-left: -1px; }
.abas button:first-child { border-radius: 4px 0 0 4px; margin-left: 0; } .abas button:last-child { border-radius: 0 4px 4px 0; }
.abas button.ativa { background: #337ab7; border-color: #2e6da4; color: #fff; font-weight: 600; }
.linha { display: flex; gap: 10px; align-items: center; margin: 10px 0; }
video { width: 100%; border-radius: 4px; background: #000; max-height: 46vh; object-fit: cover; }

/* listas (.list-group) e historico */
.lista, .historico { list-style: none; padding: 0; margin: 0 0 15px; }
.lista li, .historico li { background: #fff; border: 1px solid #ddd; margin-bottom: -1px; padding: 10px 15px; display: flex; justify-content: space-between; gap: 8px; align-items: center; font-size: 15px; }
.lista li:first-child, .historico li:first-child { border-radius: 4px 4px 0 0; } .lista li:last-child, .historico li:last-child { border-radius: 0 0 4px 4px; margin-bottom: 0; }
.lista li button, .lista li .botao { padding: 6px 12px; font-size: 14px; } .lista li form { margin: 0; }
.historico li.ok { border-left: 5px solid #5cb85c; } .historico li.erro { border-left: 5px solid #d9534f; } .historico li.aviso { border-left: 5px solid #f0ad4e; }
.historico li small { color: #999; white-space: nowrap; }

/* menu da pagina inicial (atalhos grandes) */
.menu { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.menu .botao.grande { margin: 0; }

/* situacao (equivale ao .label do Bootstrap) */
.chip { display: inline-block; padding: .25em .7em; font-size: 12px; font-weight: 700; line-height: 1; color: #fff; background: #777; border-radius: .25em; }
.chip.ativo, .chip.paga { background: #5cb85c; } .chip.teste { background: #5bc0de; } .chip.suspenso { background: #f0ad4e; } .chip.bloqueado, .chip.cancelado, .chip.vencida { background: #d9534f; }
.tabela { margin-bottom: 15px; }
.paginacao { margin: 0 0 15px; } .pagination { margin: 4px 0 0; }
.qr { width: 220px; height: 220px; margin: 0 auto; background: #fff; padding: 8px; border: 1px solid #ddd; border-radius: 4px; } .qr svg { width: 100%; height: 100%; }

.login { max-width: 440px; margin: 20px auto; }

/* telas largas: usa o espaco (duas colunas nos formularios curtos) */
@media (min-width: 992px) {
  .grade { grid-template-columns: repeat(6, 1fr); } .grade.pequeno { grid-template-columns: repeat(3, 1fr); }
  .duas-colunas { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; align-items: start; }
}
@media (max-width: 767px) { .navbar-form.quem { margin: 6px 15px; } .jumbotron h1 { font-size: 22px; } }

/* etiquetas (termica 100 x 150 mm) */
.etiqueta { width: 100mm; height: 150mm; background: #fff; color: #000; margin: 12px auto; padding: 5mm; display: flex; flex-direction: column; justify-content: space-between; page-break-after: always; font-family: Arial, Helvetica, sans-serif; border: 1px dashed #888; }
.etiqueta .et-topo { display: flex; justify-content: space-between; font-size: 11pt; border-bottom: 1px solid #000; padding-bottom: 2mm; }
.etiqueta .et-dest strong { display: block; font-size: 20pt; line-height: 1.1; } .etiqueta .et-dest small, .etiqueta .et-rem small { font-size: 8pt; color: #444; display: block; }
.etiqueta .et-dest span { font-size: 13pt; } .etiqueta .et-rem { font-size: 11pt; }
.etiqueta .et-qr { align-self: center; width: 60mm; height: 60mm; display: flex; align-items: center; justify-content: center; font-size: 7pt; word-break: break-all; text-align: center; }
.etiqueta .et-qr canvas, .etiqueta .et-qr img, .etiqueta .et-qr svg { width: 60mm; height: 60mm; }
.etiqueta .et-base { display: flex; justify-content: space-between; align-items: flex-end; font-size: 12pt; }
.etiqueta .et-prot { font: 700 22pt "Courier New", monospace; letter-spacing: 1px; } .etiqueta .et-vol { font-weight: 700; font-size: 14pt; } .etiqueta .et-peso { font-size: 10pt; }
@media screen { .etiqueta { width: min(100mm, 100%); height: auto; min-height: 150mm; gap: 3mm; } .etiqueta .et-base { flex-wrap: wrap; gap: 4px 10px; } .etiqueta .et-qr { width: min(60mm, 70%); height: auto; aspect-ratio: 1; } .etiqueta .et-qr svg { width: 100%; height: 100%; } }
@page { size: 100mm 150mm; margin: 0; }
@media print { body { padding: 0; background: #fff; } .navbar, .jumbotron, .breadcrumb, .toolbar, .nao-imprimir { display: none !important; } main, .container-fluid { padding: 0 !important; max-width: none; } .etiqueta { margin: 0; border: 0; } }
/* balcao: tipos de volume e pagamento em botoes grandes (um toque), quantidade com + e -, total sempre visivel */
.tipos { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.tipos .tipo { flex: 1 1 28%; min-height: 46px; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 14px; }
.tipos .tipo span { font-size: 12px; color: #555; }
.tipos .tipo.ativo { background: #337ab7; border-color: #2e6da4; color: #fff; } .tipos .tipo.ativo span { color: #fff; }
.linha.qtd { justify-content: center; } .linha.qtd button { min-width: 46px; min-height: 34px; font-size: 18px; } .linha.qtd input { width: 80px; text-align: center; font-size: 14px; min-height: 34px; }
.total { font-size: 22px; font-weight: 700; text-align: center; margin: 8px 0 14px; }
.linha .cidade { flex: 1 1 auto; } .linha .uf { flex: 0 0 90px; }
/* portal: lote de pre-postagens (tabela em telas largas; cada linha vira um cartao no celular) */
table.lote { width: 100%; border-collapse: collapse; margin: 10px 0; } table.lote th { text-align: left; font-size: 13px; color: #555; padding: 4px 6px; }
table.lote td { padding: 4px 6px; vertical-align: top; } table.lote input, table.lote select { width: 100%; min-height: 34px; padding: 6px 12px; font-size: 14px; }
table.lote td.lote-valor { white-space: nowrap; font-weight: 600; padding-top: 10px; } table.lote tr.erro td { background: #fdf0f0; }
.lote-total { font-size: 14px; margin: 8px 0 14px; }
@media (max-width: 767px) { table.lote thead { display: none; } table.lote tr { display: block; border: 1px solid #ddd; border-radius: 6px; padding: 8px; margin-bottom: 10px; } table.lote td { display: block; padding: 3px 0; } table.lote td::before { content: attr(data-rotulo); display: block; font-size: 12px; color: #666; } }
/* recibo de postagem: 80 mm (impressora termica) e tela do celular */
.recibo { max-width: 80mm; margin: 0 auto 20px; padding: 10px 12px; background: #fff; border: 1px dashed #bbb; font-size: 14px; line-height: 1.35; color: #000; page: recibo; }
.recibo header { text-align: center; margin-bottom: 6px; } .recibo header strong { display: block; font-size: 20px; } .recibo header span { display: block; font-size: 12px; }
.recibo hr { border: 0; border-top: 1px dashed #000; margin: 8px 0; }
.recibo .rc-num { text-align: center; font-size: 18px; font-weight: 700; margin: 6px 0; }
.recibo .rc-linha { display: flex; justify-content: space-between; gap: 8px; margin: 2px 0; } .recibo .rc-cod { font-size: 18px; letter-spacing: 1px; }
.recibo .rc-total { font-size: 17px; } .recibo .rc-situacao { text-align: center; font-weight: 700; font-size: 16px; border: 2px solid #000; margin: 6px 0; padding: 3px; } .recibo .rc-situacao.receber { background: #000; color: #fff; }
.recibo .rc-bloco { margin: 6px 0; } .recibo .rc-bloco small { display: block; font-size: 11px; letter-spacing: 1px; } .recibo .rc-bloco strong, .recibo .rc-bloco span { display: block; }
.recibo .rc-qr { width: 120px; height: 120px; margin: 8px auto; } .recibo .rc-qr svg { width: 100%; height: 100%; }
.recibo .rc-nota { font-size: 11px; text-align: center; margin: 4px 0; } .recibo .rc-aviso { font-size: 11px; text-align: center; border-top: 1px dashed #000; padding-top: 4px; margin: 4px 0 0; }
@page recibo { size: 80mm auto; margin: 3mm; }
@media print { .recibo { border: 0; max-width: none; margin: 0; padding: 0; } }
/* logo da transportadora (recibo, etiquetas e acompanhamento) */
.recibo .rc-logo { display: block; max-width: 60mm; max-height: 22mm; margin: 0 auto 4px; }
.etiqueta .et-logo { max-height: 12mm; max-width: 38mm; margin-right: 6px; vertical-align: middle; }
.rastreio-logo { text-align: center; } .rastreio-logo img { max-width: 240px; max-height: 100px; }
/* camera: em tela larga (computador) o video nao ocupa a largura toda; no celular continua em largura total */
@media (min-width: 768px) { video { display: block; max-width: 480px; max-height: 360px; margin: 0 auto; } }
/* entrada do portal: quem somos e como funciona */
.quem .passos-portal { margin: 6px 0 10px; padding-left: 20px; } .quem .passos-portal li { margin: 3px 0; }
