/* GestorAppMI - PEDIDOS / ORÇAMENTOS e ORDEM DE SERVIÇO (11/10/2026): o que é só destas telas; o resto vem do app.css (lista em grade, ficha, cards). */
/* A JANELA É UM CARTÃO SÓ (como PRODUTOS / CLIENTES): barra → filtros e cards → pesquisa → lista, colados e brancos; a lista cresce até o fim */
.g-win.gpd { background: var(--p-bg, #e4ebf6) !important; }
.g-win.gpd > .gpd-topo { margin-top: -10px; padding: 12px 12px 4px; display: flex; flex-direction: column; gap: 10px; background: #fff;
  border-left: 1px solid var(--p-borda, #e3e9f3); border-right: 1px solid var(--p-borda, #e3e9f3); }
.g-win.gpd > .gpd-topo + .gk-pesq { margin-top: -10px !important; padding: 8px 12px 0 !important; background: #fff; border-left: 1px solid var(--p-borda, #e3e9f3); border-right: 1px solid var(--p-borda, #e3e9f3); }
.g-win.gpd > .gk-lista { flex: 1 0 auto !important; min-height: 220px; }
.gpd-filtros { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px 10px; }
.gpd-filtros > label { display: flex; flex-direction: column; gap: 3px; flex: 0 0 170px; }
.gpd-filtros > label > span { font-size: 11px; font-weight: 900; color: var(--p-texto, #16233d); }
.gpd-filtros input, .gpd-filtros select { height: 38px; width: 100%; border-radius: 10px !important; }
.gpd-atalhos { display: flex; gap: 6px; flex-wrap: wrap; }
.gpd-atalhos button { height: 38px; padding: 0 14px !important; border-radius: 999px !important; font-weight: 800 !important; font-size: 11.5px !important;
  background: var(--p-50, #eff6ff) !important; color: var(--p-600, #1461cf) !important; border: 1.5px solid var(--p-300, #9cc2f5) !important; box-shadow: none !important; }
.gpd-atalhos button:hover { background: var(--p-100, #dbeafe) !important; }
/* CARDS DO RESUMO E DAS ETAPAS: todos do mesmo tamanho, baixos, e a linha fecha de ponta a ponta */
.gpd-resumo { display: flex; flex-direction: column; gap: 8px; }
.gpd-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.gpd-card { display: flex !important; flex-direction: column; align-items: center; justify-content: center; gap: 1px; min-width: 0 !important; min-height: 0 !important; height: auto !important;
  padding: 6px 10px !important; border-radius: 12px !important; background: #fff !important; border: 1px solid var(--p-borda, #e3e9f3) !important;
  box-shadow: 0 1px 2px rgba(0,0,0,.05), 0 3px 10px rgba(0,0,0,.05) !important; color: var(--p-texto, #16233d) !important; text-align: center; }
.gpd-card i { font-style: normal; font-size: 18px; line-height: 1.1; }
.gpd-card b { font-size: 11px; font-weight: 900; letter-spacing: .3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.gpd-card span { font-size: 15px; font-weight: 900; color: #0f7b3d; } .gpd-card small { font-size: 10.5px; font-weight: 800; color: var(--p-texto2, #4d5d7a); }
.gpd-card-total span { font-size: 17px; }
.gpd-cards:not(.gpd-etapas-cards) { grid-template-columns: repeat(auto-fill, minmax(230px, 280px)); }
.gpd-etapas-cards { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.gpd-c-etapa { cursor: pointer; } .gpd-c-etapa span { color: var(--p-600, #1461cf) !important; font-size: 16px; }
.gpd-c-etapa b { font-size: 10.5px; white-space: normal; line-height: 1.15; }
.gpd-c-etapa.ativo { border: 2px solid var(--p-500, #1668e3) !important; background: var(--p-50, #eff6ff) !important; }
@media (max-width: 1100px) { .gpd-etapas-cards { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.gpd-sit, .gpd-selo, .gpd-etapa, .gpd-pri { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 11px; font-weight: 900; letter-spacing: .3px; }
.gpd-sit.s-ABERTO, .gpd-selo.s-ABERTO { background: #dcf5e6; color: #0f7b3d; }
.gpd-sit.s-FECHADO, .gpd-selo.s-FECHADO { background: var(--p-100, #dbeafe); color: var(--p-800, #0d2b5e); }
.gpd-sit.s-CANCELADO, .gpd-selo.s-CANCELADO { background: #fde2e6; color: #b4233f; }
.gpd-etapa { background: var(--p-50, #eff6ff); color: var(--p-700, var(--p-600, #1461cf)); border: 1px solid var(--p-300, #9cc2f5); }
.gpd-pri.p-ALTA { background: #ffe8d6; color: #a14b00; } .gpd-pri.p-URGENTE { background: #b4233f; color: #fff; } .gpd-pri.p-BAIXA { color: var(--p-texto2, #4d5d7a); }
.gpd-selo { margin-left: 10px; vertical-align: middle; }
.gv-tit .gpd-etapa { margin-left: 10px; vertical-align: middle; }
.gpd-origem { margin: 0; align-self: center; font-size: 12px; color: var(--p-texto2, #4d5d7a); }
.gpd-busca { position: relative; }
.gpd-busca .gpr-achados button small { font-weight: 600; color: var(--p-texto2, #4d5d7a); }
.gpd-cli { display: flex; flex-direction: column; justify-content: center; gap: 2px; min-height: 56px; padding: 8px 12px; border-radius: 12px; background: var(--p-50, #f6f9fd);
  border: 1px solid var(--p-borda, #e3e9f3); font-size: 12px; color: var(--p-texto, #16233d); }
.gpd-cli b { font-size: 13px; } .gpd-cli small { color: var(--p-texto2, #4d5d7a); font-weight: 700; }
.gpd-add { display: grid; grid-template-columns: minmax(0, 1fr) 100px 120px 90px 110px auto; gap: 8px; align-items: end; }
.gpd-add label { display: flex; flex-direction: column; gap: 3px; }
.gpd-add > button, .gpd-gerar button { height: 40px; border-radius: 999px !important; padding: 0 16px !important; font-weight: 900 !important; }
.gpd-gerar { display: flex; gap: 8px; align-items: end; flex-wrap: wrap; }
.gpd-info { margin: 0; font-size: 12px; color: var(--p-texto2, #4d5d7a); min-height: 16px; }
.gpd-ruim, .gpd-aviso { color: #b4233f !important; font-weight: 900; }
.gpd-aviso { display: block; margin: 4px 0 0; font-size: 12px; font-style: normal; }
.gpd-cinza { margin: 4px 0; font-size: 11.5px; color: var(--p-texto2, #4d5d7a); }
.gpd-itens table, .gpd-parc table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.gpd-itens th, .gpd-parc th { text-align: left; font-size: 11px; font-weight: 900; padding: 6px 8px; background: var(--p-50, #f6f9fd); border-bottom: 1.5px solid var(--p-borda, #e3e9f3); }
.gpd-itens td, .gpd-parc td { padding: 5px 8px; border-bottom: 1px solid var(--p-borda, #e3e9f3); }
.gpd-itens tbody tr { cursor: pointer; } .gpd-itens tbody tr:hover { background: var(--p-50, #f6f9fd); }
.gpd-itens .n { text-align: right; white-space: nowrap; }
.gpd-tira { width: 26px; height: 26px; min-width: 0 !important; padding: 0 !important; border-radius: 50% !important; font-size: 11px !important; }
.gpd-parc input { height: 34px; max-width: 170px; }
.gpd-tots { display: grid; grid-template-columns: 180px 200px minmax(0, 1fr); gap: 10px; align-items: end; }
.gpd-tots label { display: flex; flex-direction: column; gap: 3px; }
.gpd-somas { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px 16px; font-size: 12.5px; color: var(--p-texto2, #4d5d7a); font-weight: 700; }
.gpd-somas b { color: var(--p-texto, #16233d); } .gpd-total { font-size: 15px; } .gpd-total b { color: #0f7b3d !important; font-size: 18px; }
.gpd-fotos { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; } .gpd-fotos > div { display: contents; }
.gpd-foto { position: relative; display: inline-flex !important; align-items: center; justify-content: center; width: 86px; height: 64px; padding: 0 !important; border-radius: 12px !important;
  font-weight: 900 !important; overflow: visible; }
.gpd-foto img { width: 100%; height: 100%; object-fit: cover; border-radius: 11px; }
.gpd-foto i { position: absolute; top: -7px; right: -7px; width: 22px; height: 22px; border-radius: 50%; background: #b4233f; color: #fff; font-style: normal; font-size: 11px; line-height: 22px; text-align: center; }
.gpd-foto-nova { outline: 2px dashed var(--p-300, #9cc2f5); }
.gpd-foto-add { display: inline-flex; align-items: center; justify-content: center; height: 64px; padding: 0 18px; border-radius: 12px; cursor: pointer; font-weight: 900; font-size: 12px;
  border: 2px dashed var(--p-300, #9cc2f5); color: var(--p-600, #1461cf); background: var(--p-50, #f6f9fd); }
.gpd-foto-grande { max-width: min(calc(80 * var(--vw, 1vw)), 900px); max-height: calc(70 * var(--vh, 1vh)); border-radius: 10px; }
.gpd-receber { font-size: 12px; color: var(--p-texto2, #4d5d7a); }
.gpd-hist { display: flex; flex-direction: column; gap: 2px; max-height: 180px; overflow-y: auto; padding: 8px 12px; border-radius: 12px; background: var(--p-50, #f6f9fd); border: 1px solid var(--p-borda, #e3e9f3); font-size: 12px; }
.gpd-hist:empty { display: none; }
.gpd-hist > div { display: grid; grid-template-columns: 120px 170px minmax(0, 1fr) 110px; gap: 8px; padding: 3px 0; border-bottom: 1px dashed var(--p-borda, #e3e9f3); }
.gpd-hist time { font-weight: 800; } .gpd-hist em { font-style: normal; font-weight: 900; color: var(--p-600, #1461cf); } .gpd-hist small { text-align: right; color: var(--p-texto2, #4d5d7a); }
.gpd-os-aprov { align-self: center; font-size: 12px; }
.gpd-marca { display: flex !important; flex-direction: row !important; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 800; cursor: pointer; }
.gpd-marca input { width: 18px; height: 18px; accent-color: var(--p-500, #1668e3); }
.gpd-acoes { flex-wrap: wrap; } .gpd-acoes button { min-width: 0 !important; padding: 0 14px !important; }
/* [DLG-LARGURA-3010] as janelas gpd-dlg (pedidos, cobrança, condicionais) dizem a própria largura (style no .gpd-dlg-meio): o limite de
   820px da caixa do MaTIA (dialog.g-info) cortava as mais largas — o CONDICIONAL (900px) perdia o valor e as colunas da direita */
dialog.g-info.gpd-dlg { max-width: calc(96 * var(--vw, 1vw)); }
.gpd-dlg-meio { box-sizing: border-box; }
.gpd-dlg-meio { padding: 14px 18px; display: flex; flex-direction: column; gap: 10px; background: #fff; color: #10223f; text-align: left; }
.gpd-dlg-meio p { margin: 0; } .gpd-l { display: flex; flex-direction: column; gap: 3px; font-size: 12px; font-weight: 800; } .gpd-l input { height: 40px; }
.gpd-etapas { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; }
@media (max-width: 760px) {
  .gpd-filtros > label { flex: 1 1 calc(50% - 10px); } .gpd-etapas-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gpd-add { grid-template-columns: 1fr 1fr; } .gpd-add .gpd-busca { grid-column: 1 / -1; }
  .gpd-tots { grid-template-columns: 1fr 1fr; } .gpd-somas { grid-column: 1 / -1; justify-content: flex-start; }
  .gpd-hist > div { grid-template-columns: 1fr; }
  .gpd-acoes button { font-size: 0 !important; padding: 0 10px !important; } .gpd-acoes button::first-letter { font-size: 16px; }
  .gpd-ficha .g-g12 > * { grid-column: 1 / -1 !important; }
}

/* DEVOLUÇÃO DO CONDICIONAL: um card por item, centralizados */
.gpd-dev { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.gpd-dev-card { flex: 1 1 170px; max-width: 220px; display: flex; flex-direction: column; gap: 4px; padding: 8px; border: 1px solid #c9d3e3; border-radius: 10px; text-align: center; font-size: 12px; }
.gpd-dev-card input { height: 36px; text-align: center; }

/* ==== FICHA NOVA DO PEDIDO / OS (Nicholas, 12/10): no padrão da EMISSÃO DE NOTA — faixa do documento em cima, os passos à esquerda
   (cards numerados) e o RESUMO à direita (totais, retido / líquido e os botões). No celular, uma coluna só. ==== */
.gk-ficha.gpd-nova { grid-template-rows: auto auto minmax(0, 1fr) !important; background: var(--p-bg, #eef3fa) !important; }
.gpd-nova [hidden] { display: none !important; }
.gpd-nova label { display: flex; flex-direction: column; gap: 4px; min-width: 0; margin: 0; }
.gpd-nova label > span { font-size: 11px; font-weight: 900; letter-spacing: .3px; color: var(--p-texto2, #4d5d7a); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gpd-nova :is(input:not([type=checkbox]):not([type=file]), select) { width: 100%; height: 40px; box-sizing: border-box; }
.gpd-nova textarea { width: 100%; box-sizing: border-box; resize: vertical; }
/* (14/10, Mateus) CABEÇALHO NUMA LINHA SÓ, no alto da coluna da esquerda (a coluna da direita sobe até o topo) */
.gk-ficha.gpd-nova fieldset.gpd-cab { display: flex; flex-wrap: nowrap; align-items: flex-end; gap: 8px; margin: 0 !important; padding: 0 !important; border: 0 !important;
  background: none !important; overflow: visible !important; flex: none !important; min-width: 0; }
.gpd-cab > .gpd-c { flex: 1 1 130px; min-width: 0; } .gpd-cab > .gpd-c-tipo { flex: 1 1 150px; } .gpd-cab > .gpd-c-num { flex: 0 1 80px; }
.gpd-cab > .gpd-c-hora { flex: 0 1 95px; } .gpd-cab > .gpd-c-prev { flex: 1 1 140px; } .gpd-cab > .gpd-c-vend { flex: 2 1 180px; } .gpd-cab > .gpd-c-atd { flex: 1 1 120px; }
.gpd-cab #pd-numero, .gpd-cab #pd-atendente { background: var(--p-50, #f6f9fd) !important; font-weight: 900; }
.gpd-corpo { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 14px; align-items: start; min-height: 0; overflow-y: auto; padding: 14px 16px; }
.gk-ficha.gpd-nova fieldset.gpd-secoes { display: flex; flex-direction: column; gap: 12px; min-width: 0; margin: 0 !important; padding: 0 !important; border: 0 !important;
  background: none !important; overflow: visible !important; }
.gpd-sec { border: 1.5px solid var(--p-borda, #e3e9f3); border-radius: 16px; background: #fff; padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.gpd-sec > header { display: flex; align-items: center; gap: 10px; }
.gpd-sec > header i { width: 30px; height: 30px; flex: none; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 900; font-size: 15px;
  background: var(--p-500, #1668e3); color: #fff; }
.gpd-sec > header b { font-size: 14px; font-weight: 900; letter-spacing: .6px; color: var(--p-texto, #16233d); }
.gpd-sec > header em { margin-left: auto; font-style: normal; font-weight: 900; color: #0f9d58; font-size: 18px; }
.gpd-sec > header .gpd-etapa { margin-left: 4px; }
.gpd-nova .gpd-busca input { height: 48px; font-size: 16px; padding: 0 14px; text-align: left !important; }
.gpd-nova label > span, .gpd-nova label:has(> input[type="date"]) > span { text-align: left !important; align-self: stretch; }
.gpd-nova label:has(> input[type="date"]) { align-items: stretch !important; }
.gpd-nova .gpd-pg-v > span { flex: none; overflow: visible; }
.gpd-nova .gpd-cli { flex-direction: row; align-items: center; gap: 12px; min-height: 0; padding: 10px 12px; border: 1.5px solid var(--p-borda, #e3e9f3); }
.gpd-cli-d { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.gpd-cli-d b { font-size: 15px; font-weight: 900; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gpd-cli-d span { font-size: 12px; font-weight: 700; color: var(--p-texto2, #4d5d7a); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gpd-cli > button { height: 38px; padding: 0 16px; flex: none; }
.gpd-nova .gpd-add { grid-template-columns: minmax(0, 1fr) repeat(4, 120px) 44px; gap: 8px; align-items: end; }
/* [ITEM-LINHA-1311] (13/11, Mateus) tudo numa linha: o PRODUTOS E SERVIÇOS um pouco menor e QTD / % DESC / R$ DESC / CFOP do tamanho do PREÇO */
.gpd-nova .gpd-add:has(.gpd-c-cfop) { grid-template-columns: minmax(0, 1fr) repeat(5, 120px) 44px; }
.g-win .gpd-nova .gpd-add > button { width: 44px; height: 44px; padding: 0 !important; border-radius: 50% !important; font-size: 20px !important; }
.gpd-nova .gpd-add input { height: 44px; } .gpd-add #pd-qtd, .gpd-add #pd-preco, .gpd-add #pd-descp, .gpd-add #pd-descv { text-align: right; }
.gpd-nova .gpd-info { margin: -4px 0 0; } .gpd-nova .gpd-info:empty { display: none; }
.gpd-nova .gpd-itens { overflow-x: auto; }
.gpd-nova .gpd-itens table { font-size: 13px; }
.gpd-nova .gpd-itens th { background: none; font-size: 10.5px; letter-spacing: .4px; color: var(--p-texto2, #4d5d7a); white-space: nowrap; }
.gpd-nova .gpd-itens td { white-space: nowrap; padding: 6px 8px; }
.gpd-nova .gpd-itens td.gpd-desc { width: 100%; max-width: 0; overflow: hidden; text-overflow: ellipsis; }
.gpd-nova .gpd-itens .c { text-align: center; }
.gpd-vazio { margin: 2px 0; font-size: 12px; font-weight: 800; color: var(--p-texto2, #4d5d7a); text-align: center; }
.gpd-nova .gpd-dg { display: flex; justify-content: flex-end; gap: 10px; }
.gpd-nova .gpd-dg > label { flex: 0 0 190px; } .gpd-dg input { text-align: right; }
/* (14/10, Mateus) FORMAS DE PAGAMENTO EM LISTA SUSPENSA: escolhe → entra a linha com o que falta → a lista volta fechada */
.gpd-nova .gpd-forma-sel { width: 100%; height: 44px; font-size: 14px; font-weight: 900; border-radius: 12px; cursor: pointer; }
.gpd-nova .gpd-forma-sel[hidden] { display: none; }
.gpd-pgs { display: flex; flex-direction: column; gap: 8px; } .gpd-pgs:empty { display: none; }
.gpd-pg { border: 1.5px solid var(--p-borda, #e3e9f3); border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; background: var(--p-50, #f6f9fd); }
.gpd-pg-l { display: flex; align-items: center; gap: 10px; } .gpd-pg-l > b { flex: 1; font-size: 14px; font-weight: 900; color: var(--p-texto, #16233d); }
.gpd-nova label.gpd-pg-v { flex-direction: row !important; align-items: center !important; gap: 6px; } .gpd-pg-v > span { color: var(--p-texto, #16233d) !important; }
.gpd-nova .gpd-pg-v input { width: 130px; height: 38px; text-align: right; font-size: 15px; font-weight: 900; }
.gpd-parcs { display: flex; flex-wrap: wrap; gap: 4px; }
.gpd-parcs button { height: 38px; min-width: 46px; padding: 0 8px !important; font-weight: 900 !important; }
.gpd-parcs button.ativo, .gpd-os-qual button.ativo { background: var(--p-500, #1668e3) !important; color: #fff !important; border-color: var(--p-500, #1668e3) !important; }
.gpd-nova .gpd-pg-datas { display: flex; gap: 10px; } .gpd-pg-datas > label { flex: 0 0 170px; }
.gpd-parc-lista { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; font-weight: 700; color: var(--p-texto2, #4d5d7a); }
.gpd-falta:empty { display: none; } .gpd-falta b { color: #c8323f; font-size: 13px; }
/* (14/10, Mateus) OBSERVAÇÕES: uma caixa por linha, na largura toda da tela, 3 linhas de altura */
.gpd-nova .gpd-obs { display: grid; grid-template-columns: 1fr; gap: 10px; }
.gpd-nova .gpd-obs textarea { width: 100%; min-height: calc(3 * 1.45em + 16px); }
.gpd-g { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 10px; align-items: end; }
.gpd-g > .c2 { grid-column: span 2; } .gpd-g > .c3 { grid-column: span 3; } .gpd-g > .c4 { grid-column: span 4; } .gpd-g > .c6 { grid-column: span 6; } .gpd-g > .c12 { grid-column: 1 / -1; }
.gpd-nova .gpd-g > label.gpd-marca { flex-direction: row; align-self: center; }
.gpd-os-qual { display: flex; gap: 8px; }
.gpd-os-qual button { flex: 0 0 180px; height: 40px; border-radius: 12px !important; font-weight: 900 !important; }
.gpd-nova .gpd-hist > div { grid-template-columns: 130px 150px minmax(0, 1fr) 110px; }
.gpd-resumo-lado { position: sticky; top: 0; display: flex; flex-direction: column; gap: 12px; border: 1.5px solid var(--p-borda, #e3e9f3); border-radius: 16px; background: #fff; padding: 14px; }
.gpd-sit-lado { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.gpd-sit-lado .gpd-selo { margin: 0; font-size: 12px; padding: 4px 12px; }
.gpd-origem:empty { display: none; }
.gpd-somas { display: flex; flex-direction: column; gap: 6px; }
.gpd-nova .gpd-somas { flex-wrap: nowrap; justify-content: flex-start; }
.gpd-t { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.gpd-t span { font-size: 12px; font-weight: 800; letter-spacing: .3px; color: var(--p-texto2, #4d5d7a); }
.gpd-t b { font-size: 13.5px; font-weight: 900; color: var(--p-texto, #16233d); white-space: nowrap; }
.gpd-t-total { margin-top: 6px; padding-top: 10px; border-top: 2px solid var(--p-borda, #e3e9f3); }
.gpd-t-total span { font-size: 13px; color: var(--p-texto, #16233d); } .gpd-t-total b { font-size: 28px; color: var(--p-500, #1668e3); }
.gpd-t-ret b { color: #c8323f; }
.gpd-t-liq { padding-top: 8px; border-top: 1px dashed var(--p-borda, #e3e9f3); } .gpd-t-liq span { color: #0f7b3d; } .gpd-t-liq b { font-size: 22px; color: #0f7b3d; }
.gpd-nova .gpd-receber { display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-radius: 10px; background: var(--p-50, #f6f9fd); font-size: 11.5px; font-weight: 700; }
.gpd-nova .gpd-receber:empty { display: none; } .gpd-receber b { font-size: 10.5px; letter-spacing: .4px; }
.gpd-acoes-lado { display: flex; flex-direction: column; gap: 8px; }.g-win .gpd-nova .gpd-bt-grande { width: 100%; height: 56px; font-size: 18px !important; font-weight: 900 !important; border-radius: 14px !important; }
.g-win .gpd-nova .gpd-bt-acao { width: 100%; height: 44px; font-weight: 900 !important; border-radius: 12px !important; }
.gpd-icones { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); grid-auto-flow: column; gap: 6px; }
.g-win .gpd-nova .gpd-icones button { height: 54px; padding: 0 !important; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  font-size: 18px !important; border-radius: 12px !important; min-width: 0 !important; }
.gpd-icones button span { font-size: 9.5px; font-weight: 900; letter-spacing: .3px; }
.gpd-perigo { display: flex; gap: 6px; }
.g-win .gpd-nova .gpd-perigo button { flex: 1; min-width: 0 !important; height: 36px; padding: 0 6px !important; font-size: 11px !important; font-weight: 900 !important; border-radius: 10px !important;
  background: #fff !important; color: #b4233f !important; border: 1.5px solid #f3c4cc !important; box-shadow: none !important; }
.g-win .gpd-nova .gpd-perigo button[data-a="reabrir"] { color: var(--p-600, #1461cf) !important; border-color: var(--p-300, #9cc2f5) !important; }
.g-win .gpd-nova .gpd-bt-fechar { width: 100%; height: 40px; border-radius: 12px !important; font-weight: 900 !important; }
@media (max-width: 1000px) {
  .gpd-corpo { display: flex; flex-direction: column; align-items: stretch; } .gpd-corpo > * { flex: none !important; }
  .gpd-resumo-lado { position: static; }
}
@media (max-width: 600px) {
  .gk-ficha.gpd-nova fieldset.gpd-cab { flex-wrap: wrap; gap: 8px; }
  .gpd-cab > .gpd-c, .gpd-cab > .gpd-c-vend { flex: 1 1 calc(50% - 8px) !important; }
  .gpd-corpo { padding: 10px; gap: 10px; }
  .gpd-sec { padding: 10px; }
  .gpd-nova .gpd-add { grid-template-columns: repeat(4, minmax(0, 1fr)); } .gpd-nova .gpd-add > .gpd-busca { grid-column: 1 / -1; }
  .g-win .gpd-nova .gpd-add > button { grid-column: 1 / -1; width: 100%; border-radius: 12px !important; }
  .gpd-nova .gpd-dg > label { flex: 1 1 0; }
  .gpd-nova .gpd-obs { grid-template-columns: 1fr; }
  .gpd-g > :is(.c2, .c3, .c4) { grid-column: span 6; } .gpd-g > .c6 { grid-column: 1 / -1; }
  .gpd-g-txt > * { grid-column: 1 / -1 !important; }
  .gpd-os-qual button { flex: 1; }
  .gpd-nova .gpd-pg-datas > label { flex: 1 1 0; }
  .gpd-pg-l { flex-wrap: wrap; } .gpd-pg-l > b { flex: 1 1 0; min-width: 0; } .gpd-nova label.gpd-pg-v { order: 3; flex: 1 1 100%; } .gpd-nova .gpd-pg-v input { flex: 1; width: auto; }
  .gpd-nova .gpd-hist > div { grid-template-columns: 1fr; }
  .gpd-nova .gpd-itens table { font-size: 12px; } .gpd-nova .gpd-itens :is(th, td) { padding: 5px 4px; }
  .gpd-nova .gpd-itens :is(th, td):nth-child(2) { display: none; }
}
/* (15/10) filtro de situação com o NOME (ABERTAS · ENTREGUES · FATURADAS · FECHADAS · CANCELADAS · TODAS) */
.gk-filtros.gk-filtros-nome { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.gk-filtros.gk-filtros-nome button { width: auto; min-width: 0; padding: 0 12px; font-size: 12px; font-weight: 800; letter-spacing: .3px; }

/* (15/10) botão HISTÓRICO / ACOMPANHAMENTO da OS e a lista dele */
.gpd-bt-hist { width: 100%; margin: 6px 0; }
.gpd-hist-lista > div { display: grid; grid-template-columns: 130px 140px 1fr auto; gap: 8px; padding: 4px 0; border-bottom: 1px solid #e3e8f2; font-size: 13px; text-align: left; }
.gpd-hist-lista time { font-weight: 800; } .gpd-hist-lista em { font-style: normal; color: #1d5fd1; font-weight: 700; }

/* (15/10, Mateus) SITUAÇÃO DA OS (a classe repetida vence a regra geral dos campos, que é bem específica): seleção + ✓ na mesma linha, com a cor de cada situação (também na coluna SITUAÇÃO da lista) */
.gpd-sit-lado .gpd-sit-linha { display: flex; align-items: center; gap: 6px; width: 100%; }
html :is(#g-sistema, .g-win) .gpd-sit-lado .gpd-sit-linha select.gpd-sit-sel { flex: 1 1 auto; min-width: 0; height: 36px; padding: 0 10px; border-radius: 10px; font-size: 13px; font-weight: 900; letter-spacing: .3px; border: 2px solid currentColor !important; }
.g-win .gpd-sit-lado .gpd-sit-sel:disabled { opacity: 1; cursor: default; }
.g-win .gpd-sit-lado .gpd-sit-sel option { background: #fff; color: #16233d; }
html :is(#g-sistema, .g-win) .gpd-nova .gpd-sit-linha button.gpd-sit-ok.gpd-sit-ok.gpd-sit-ok.gpd-sit-ok { flex: 0 0 40px; width: 40px; height: 36px; padding: 0 !important; min-width: 0 !important; border-radius: 10px !important; font-size: 18px !important; font-weight: 900 !important; }
.gpd-sit-motivo { margin: 0; font-size: 11px; font-weight: 800; color: var(--p-texto2, #4d5d7a); }
.gpd-sit-motivo:empty { display: none; }
.gpd-sit.o-ABERTA { background: #dcf5e6; color: #0f7b3d; }
html :is(#g-sistema, .g-win) .gpd-sit-lado .gpd-sit-linha select.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.o-ABERTA { background: #dcf5e6 !important; color: #0f7b3d !important; border-color: currentColor !important; }
.gpd-sit.o-FATURADA { background: #0f7b3d; color: #fff; }
html :is(#g-sistema, .g-win) .gpd-sit-lado .gpd-sit-linha select.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.o-FATURADA { background: #0f7b3d !important; color: #fff !important; border-color: currentColor !important; }
.gpd-sit.o-FECHADA { background: #fde2e2; color: #c62828; }
html :is(#g-sistema, .g-win) .gpd-sit-lado .gpd-sit-linha select.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.o-FECHADA { background: #fde2e2 !important; color: #c62828 !important; border-color: currentColor !important; }
.gpd-sit.o-CANCELADA { background: #4b5563; color: #fff; }
html :is(#g-sistema, .g-win) .gpd-sit-lado .gpd-sit-linha select.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.o-CANCELADA { background: #4b5563 !important; color: #fff !important; border-color: currentColor !important; }
.gpd-sit.o-EXCLUIDA { background: #6b21a8; color: #fff; }
html :is(#g-sistema, .g-win) .gpd-sit-lado .gpd-sit-linha select.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.o-EXCLUIDA { background: #6b21a8 !important; color: #fff !important; border-color: currentColor !important; }
.gpd-sit.o-OUTRAS { background: #ffedd5; color: #c2410c; }
html :is(#g-sistema, .g-win) .gpd-sit-lado .gpd-sit-linha select.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.gpd-sit-sel.o-OUTRAS { background: #ffedd5 !important; color: #c2410c !important; border-color: currentColor !important; }

/* ===== [PEDCOMPRA-2110] COMPRAS > PEDIDO DE COMPRA no padrão de PEDIDOS / OS (Nicholas, 21/10) ===== */
.gpd-sit.s-ENVIADO, .gpd-selo.s-ENVIADO { background: var(--p-100, #dbeafe); color: var(--p-800, #0d2b5e); }
.gpd-sit.s-ATENDIDO, .gpd-selo.s-ATENDIDO { background: #dcf5e6; color: #0f7b3d; }
.gpd-sit.s-ABERTO.gpc-a, .gpc .gpd-sit.s-ABERTO, .gpc .gpd-selo.s-ABERTO { background: #fff3cd; color: #8a5a00; }
.gpc .gpc-resumo { flex-direction: row; flex-wrap: wrap; gap: 8px; }
.gpc .gpc-card { flex: 0 1 220px; cursor: pointer; padding: 6px 10px !important; border-radius: 12px !important; background: #fff !important; border: 1px solid var(--p-borda, #d6e0ef) !important; }
.gpc .gpc-card:hover { border-color: var(--p-400, #4d8ff0) !important; }
.gpc .gpc-card.s-ENVIADO span { color: var(--p-600, #1461cf); } .gpc .gpc-card.s-ABERTO span { color: #8a5a00; }
.gpc .gpd-cab > .gpd-c-num { flex: 0 1 100px; } .gpc .gpd-cab > .gpc-c-comp { flex: 2 1 180px; }
.gpc .gpd-cab #pc-numero { background: var(--p-50, #f6f9fd) !important; font-weight: 900; text-align: center; }
.gpc .gpd-nova .gpc-add { grid-template-columns: minmax(0, 1fr) 100px 140px 44px; }
.gpc .gpc-add #pc-qtd, .gpc .gpc-add #pc-custo { text-align: right; }
.gpc .gpd-nova .gpc-dg > label { flex: 0 0 170px; }
.gpc .gpc-pag { display: grid; grid-template-columns: minmax(0, 220px) minmax(0, 1fr); gap: 10px; }
.gpc .gpc-pag label { display: flex; flex-direction: column; gap: 3px; }
.gpc .gpc-pag select, .gpc .gpc-pag input { height: 44px; }
.gpc .gpc-conds { margin-top: 8px; }
.gpc .gpc-t-qtd { opacity: .75; font-size: 12px; }
@media (max-width: 600px) {
  .gpc .gpd-nova .gpc-add { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gpc .gpc-pag { grid-template-columns: 1fr; }
  .gpc .gpc-card { flex: 1 1 calc(50% - 8px); }
}
