/* ==========================================================================
   Portal Hora10 — Design System compartilhado (módulos redesenhados)
   Referência: mockups aprovados (Solicitações/Avarias/Contagem), 18/jul/2026.
   Escopo: aplica-se dentro de .h10-module (não vaza estilo para o resto do portal).
   ========================================================================== */

/* Tokens V3 (19/set/2026) — ficam em :root para o shell (sidebar/topbar do base.html) e o
   .h10-module beberem da mesma fonte. Paleta do kit migration_kit/h10-v3.css. */
:root, .h10-module {
  --h10-bg-page: #f6f9fe;
  --h10-surface: #ffffff;
  --h10-surface-soft: #f8fbff;
  --h10-border: #dfe7f2;
  --h10-border-strong: #d3ddea;
  --h10-navy: #081f3b;

  --h10-text: #0f1f47;
  --h10-text-secondary: #536987;
  --h10-text-muted: #8da0b9;

  --h10-primary: #146cf6;
  --h10-primary-hover: #0b5ee8;
  --h10-primary-soft: #eaf3ff;
  --h10-success: #13b77a;
  --h10-success-soft: #e8f8f2;
  --h10-warning: #f6a917;
  --h10-warning-soft: #fff6df;
  --h10-danger: #ff4057;
  --h10-danger-soft: #fff0f2;
  --h10-purple: #7c56e8;
  --h10-purple-soft: #f2edff;
  --h10-cyan: #0891b2;
  --h10-cyan-soft: #ecfeff;

  --h10-radius-sm: 10px;
  --h10-radius-md: 14px;
  --h10-radius-lg: 18px;
  --h10-shadow-card: 0 8px 26px rgba(26, 61, 107, .06);
  --h10-shadow-hover: 0 14px 34px rgba(26, 61, 107, .10);
}
.h10-module {
  font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--h10-text);
  background: var(--h10-bg-page);
  margin: -1.25rem;           /* neutraliza o padding do .main-content (1.25rem) — evita overflow horizontal de ~4px */
  padding: 22px 26px 34px;
  min-height: calc(100vh - 60px);
}

.h10-module * { box-sizing: border-box; }

/* ---------- Cabeçalho da página ---------- */
.h10-page-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 20px;
}
.h10-page-heading { display: flex; gap: 14px; align-items: flex-start; }
.h10-page-icon {
  width: 44px; height: 44px; flex: 0 0 44px; border-radius: 12px;
  display: grid; place-items: center; font-size: 20px;
  background: var(--h10-primary-soft); color: var(--h10-primary);
}
.h10-breadcrumb {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--h10-text-muted); margin-bottom: 2px;
}
.h10-breadcrumb a { color: var(--h10-text-secondary); text-decoration: none; }
.h10-breadcrumb i { font-size: 10px; }
.h10-page-heading h1 { font-size: 30px; font-weight: 750; margin: 0; line-height: 1.05; letter-spacing: -.6px; color: #081947; }
.h10-page-heading p { font-size: 13.5px; color: #6680a3; margin: 5px 0 0; }
.h10-page-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* ---------- Botões ---------- */
.h10-btn-primary, .h10-btn-secondary, .h10-btn-danger {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 42px; padding: 0 16px; border-radius: 10px;
  font-size: 13px; font-weight: 650; cursor: pointer; text-decoration: none;
  transition: background .15s, box-shadow .15s, border-color .15s, transform .15s;
}
.h10-btn-primary { border: 1px solid #0d65ef; background: linear-gradient(180deg, #1875ff, #0d65ef); color: #fff;
  box-shadow: 0 7px 18px rgba(20, 108, 246, .22); }
.h10-btn-primary:hover { background: linear-gradient(180deg, #146cf6, #0b5ee8); color: #fff; transform: translateY(-1px); }
.h10-btn-secondary { background: #fff; border: 1px solid var(--h10-border-strong);
  color: var(--h10-text); }
.h10-btn-secondary:hover { background: var(--h10-surface-soft); color: var(--h10-text);
  box-shadow: 0 7px 18px rgba(26, 61, 107, .10); transform: translateY(-1px); }
/* Ação destrutiva. Discreta em repouso (contorno, não bloco vermelho): ficar gritando não
   protege ninguém, e um botão vermelho sólido ao lado do "Salvar" compete com ele. Só assume a
   cor cheia no hover, quando o clique já é intenção. Entrou em 24/07/2026, junto do .h10-btn-icon
   — as duas faltavam e a tela de Mídia em TV as usou achando que existiam. */
.h10-btn-danger { background: #fff; border: 1px solid var(--h10-danger);
  color: var(--h10-danger); }
.h10-btn-danger:hover { background: var(--h10-danger); color: #fff; }
/* Botão só de ícone, para ações em miniaturas e linhas de tabela. */
.h10-btn-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; padding: 0; border-radius: 7px; cursor: pointer;
  background: var(--h10-surface); border: 1px solid var(--h10-border-strong);
  color: var(--h10-text-secondary); font-size: 14px; line-height: 1;
  transition: background .15s, color .15s, border-color .15s;
}
.h10-btn-icon:hover { background: var(--h10-surface-soft); color: var(--h10-text); }
.h10-btn-icon.is-danger:hover { background: var(--h10-danger); border-color: var(--h10-danger);
  color: #fff; }

/* ---------- Abas do módulo ---------- */
.h10-tabs {
  display: flex; gap: 10px; margin-bottom: 16px; padding: 0 8px;
  background: var(--h10-surface); border: 1px solid var(--h10-border);
  border-radius: 12px; box-shadow: var(--h10-shadow-card);
  overflow-x: auto; overflow-y: hidden;
}
.h10-tab {
  display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
  padding: 15px 12px; font-size: 13px; font-weight: 600;
  color: var(--h10-text-secondary); text-decoration: none;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
}
.h10-tab:hover { color: var(--h10-text); }
.h10-tab.active { color: var(--h10-primary); font-weight: 650;
  border-bottom-color: var(--h10-primary); }

/* ---------- Sub-abas (2º nível dentro de uma aba) ---------- */
.h10-subtabs {
  display: flex; gap: 6px; flex-wrap: wrap;
  margin: -8px 0 18px;
}
.h10-subtab {
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  padding: 6px 14px; font-size: 12.5px; font-weight: 500;
  color: var(--h10-text-secondary); text-decoration: none;
  background: var(--h10-surface); border: 1px solid var(--h10-border);
  border-radius: 999px;
}
.h10-subtab:hover { color: var(--h10-text); border-color: var(--h10-primary); }
.h10-subtab.active {
  color: #fff; background: var(--h10-primary);
  border-color: var(--h10-primary); font-weight: 600;
}

/* ---------- KPIs ----------
   Anatomia V3 sem mexer no HTML dos 75 templates: o .h10-kpi vira grade de 2 colunas e o
   .h10-kpi-top "some" (display: contents) para o ícone e o rótulo virarem filhos da grade —
   ícone ocupa a 1ª coluna nas 3 linhas, rótulo/valor/rodapé empilham na 2ª. */
.h10-kpi-grid {
  display: grid; grid-template-columns: repeat(5, 1fr);
  gap: 10px; margin-bottom: 14px;
}
.h10-kpi {
  background: var(--h10-surface); border: 1px solid #ebf0f6;
  border-radius: 12px; padding: 13px 14px; min-height: 92px;
  box-shadow: 0 4px 16px rgba(24, 63, 115, .04); transition: box-shadow .15s, transform .15s;
  display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 11px;
  grid-template-rows: auto auto auto; align-content: start;
}
/* KPI que é link (<a class="h10-kpi">): telas antigas o forçam a display:block com uma classe
   local — a anatomia em grade tem que vencer, senão o ícone sobe para cima do rótulo. */
.h10-module .h10-kpi, .h10-module a.h10-kpi { display: grid; text-decoration: none; color: inherit; }
.h10-kpi:hover { box-shadow: var(--h10-shadow-hover); transform: translateY(-1px); }
.h10-kpi-top { display: contents; }
.h10-kpi-icon {
  width: 38px; height: 38px; border-radius: 11px; flex: 0 0 38px;
  display: grid; place-items: center; font-size: 17px;
  grid-column: 1; grid-row: 1 / span 3;
}
.h10-kpi-label { grid-column: 2; font-size: 11px; font-weight: 500; color: #6680a1; margin-bottom: 3px; }
.h10-kpi-value { grid-column: 2; font-size: 21px; font-weight: 760; line-height: 1.1; letter-spacing: -.35px; color: #0c204c; }
.h10-kpi-foot { grid-column: 2; font-size: 11px; color: #748aa7; margin-top: 5px; }
.h10-kpi-foot .up { color: var(--h10-success); font-weight: 600; }
.h10-kpi-foot .down { color: var(--h10-danger); font-weight: 600; }
/* KPI sem ícone: o valor ocupa a largura toda */
.h10-kpi:not(:has(.h10-kpi-icon)) { grid-template-columns: minmax(0, 1fr); }
.h10-kpi:not(:has(.h10-kpi-icon)) > * { grid-column: 1; }

/* tons de ícone */
.tone-blue   { background: var(--h10-primary-soft); color: var(--h10-primary); }
.tone-green  { background: var(--h10-success-soft); color: var(--h10-success); }
.tone-purple { background: var(--h10-purple-soft);  color: var(--h10-purple); }
.tone-orange { background: var(--h10-warning-soft); color: var(--h10-warning); }
.tone-red    { background: var(--h10-danger-soft);  color: var(--h10-danger); }
.tone-cyan   { background: var(--h10-cyan-soft);    color: var(--h10-cyan); }

/* ---------- Barra de filtros ---------- */
.h10-filter-bar {
  display: flex; gap: 8px; align-items: center; flex-wrap: wrap;
  padding: 10px; margin-bottom: 14px; background: rgba(255,255,255,.92);
  border: 1px solid var(--h10-border); border-radius: var(--h10-radius-md);
  box-shadow: var(--h10-shadow-card);
}
.h10-search { position: relative; flex: 1 1 200px; min-width: 130px; max-width: 460px; }
/* empurra o "Exportar" para a direita mantendo tudo na mesma linha */
.h10-filter-bar .h10-export { margin-left: auto; }
/* remove o "botão" spinner (pra cima/baixo) dos campos de data no filtro */
.h10-filter-bar input[type="date"]::-webkit-inner-spin-button { display: none; -webkit-appearance: none; margin: 0; }
.h10-filter-bar input[type="date"] { -moz-appearance: textfield; padding-left: 8px; padding-right: 4px; }
.h10-search i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  color: var(--h10-text-muted); font-size: 14px; }
.h10-input, .h10-select {
  width: 100%; height: 42px; padding: 0 12px; border-radius: 10px;
  border: 1px solid var(--h10-border); background: #fff;
  color: var(--h10-text); font-size: 13px; font-weight: 500;
}
.h10-search .h10-input { padding-left: 34px; }
.h10-select { min-width: 108px; width: auto; cursor: pointer;
  appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; padding-right: 30px; }
.h10-input:focus, .h10-select:focus { outline: none; border-color: var(--h10-primary);
  box-shadow: 0 0 0 3px rgba(20, 108, 246, .14); }
.h10-filter-spacer { flex: 1 1 auto; }
/* barra de filtros "apertada": segura todos os campos numa linha só em telas largas,
   deixando os selects encolherem em vez de quebrar a linha */
@media (min-width: 1100px) {
  .h10-filter-bar--tight { flex-wrap: nowrap; }
  .h10-filter-bar--tight .h10-select { flex: 1 1 0; min-width: 0; }
  .h10-filter-bar--tight .h10-btn-secondary,
  .h10-filter-bar--tight .h10-btn-primary { flex: 0 0 auto; white-space: nowrap; }
}

/* ---------- Cards de conteúdo ---------- */
.h10-card {
  background: var(--h10-surface); border: 1px solid var(--h10-border);
  border-radius: var(--h10-radius-md); box-shadow: var(--h10-shadow-card);
}
.h10-card-head { display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 14px 16px 12px; border-bottom: 1px solid #ebf0f6; }
.h10-card-title { font-size: 15px; font-weight: 750; margin: 0; color: #102653; }
.h10-card-subtitle { font-size: 11.5px; color: #7890ae; margin: 3px 0 0; font-weight: 400; }
.h10-card-body { padding: 4px 4px 8px; }

/* ---------- Tabela ---------- */
.h10-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.h10-table thead th {
  text-align: left; padding: 10px 12px; font-size: 10.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .03em; color: #6680a2;
  background: #f6f9fd; border-bottom: 1px solid #ebf0f6;
  white-space: nowrap;
}
.h10-table tbody td { padding: 10px 12px; border-bottom: 1px solid #edf2f8;
  color: #253a5d; vertical-align: middle; }
.h10-table tbody tr:hover { background: #fafdff; }
.h10-table tbody tr:last-child td { border-bottom: 0; }
.h10-num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
/* O cabeçalho numérico PRECISA desta regra: `.h10-table thead th` (0,1,1) vence `.h10-num`
   (0,1,0) por especificidade, então o th ficava alinhado à esquerda enquanto os valores
   iam para a direita — coluna visualmente quebrada em toda tabela de dinheiro do portal
   (C.C. Fornecedores, PIN, Solicitações: 9 templates, 41 cabeçalhos). */
.h10-table thead th.h10-num { text-align: right; }
.h10-strong { font-weight: 700; }

/* ---------- Badges ---------- */
.h10-badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 0 9px; height: 23px;
  border-radius: 7px; font-size: 10.5px; font-weight: 650; white-space: nowrap;
}
.h10-badge.is-success { background: #e7f8f1; color: #099767; }
.h10-badge.is-warning { background: #fff2d2; color: #cb8500; }
.h10-badge.is-danger  { background: #ffe9ed; color: #ee3049; }
.h10-badge.is-neutral { background: #edf2f7; color: #657a95; }
.h10-badge.is-info    { background: #e9f3ff; color: #0f64eb; }
.h10-badge.is-purple  { background: var(--h10-purple-soft); color: var(--h10-purple); }

/* ---------- Barra de progresso (orçamento) ---------- */
.h10-progress { height: 6px; border-radius: 999px; background: #eef2f7; overflow: hidden; margin-top: 4px; }
.h10-progress > span { display: block; height: 100%; border-radius: 999px; background: var(--h10-success); }
.h10-progress.is-warning > span { background: var(--h10-warning); }
.h10-progress.is-danger  > span { background: var(--h10-danger); }

/* ---------- Ações de linha ---------- */
.h10-row-actions { display: inline-flex; gap: 4px; }
.h10-icon-btn {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--h10-border);
  background: #fff; color: var(--h10-text-secondary); display: inline-grid;
  place-items: center; cursor: pointer; font-size: 13px; text-decoration: none;
}
.h10-icon-btn:hover { background: var(--h10-surface-soft); color: var(--h10-text); }
.h10-icon-btn.is-success:hover { background: var(--h10-success-soft); color: var(--h10-success); border-color: var(--h10-success); }
.h10-icon-btn.is-danger:hover  { background: var(--h10-danger-soft);  color: var(--h10-danger);  border-color: var(--h10-danger); }

/* ---------- Paginação ---------- */
.h10-tablefoot { display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; padding: 14px 16px; border-top: 1px solid var(--h10-border);
  font-size: 12.5px; color: var(--h10-text-secondary); }

/* ---------- Estado vazio ---------- */
.h10-empty { text-align: center; padding: 48px 16px; color: var(--h10-text-secondary); }
.h10-empty i { font-size: 34px; color: var(--h10-text-muted); display: block; margin-bottom: 10px; }
.h10-empty h3 { font-size: 15px; font-weight: 600; margin: 0 0 4px; color: var(--h10-text); }
.h10-empty p { font-size: 13px; margin: 0; }

/* ---------- Layout de grades ---------- */
.h10-grid-charts { display: grid; grid-template-columns: 5fr 3fr 4fr; gap: 12px; margin-bottom: 12px; }
.h10-grid-bottom { display: grid; grid-template-columns: 2fr 1fr; gap: 12px; }
.h10-chart-box { position: relative; height: 260px; padding: 8px 12px 12px; }

/* ---------- Responsivo ---------- */
@media (max-width: 1199px) {
  .h10-kpi-grid { grid-template-columns: repeat(3, 1fr); }
  .h10-grid-charts { grid-template-columns: 1fr 1fr; }
  .h10-grid-bottom { grid-template-columns: 1fr; }
}
@media (max-width: 767px) {
  .h10-module { margin: -1.25rem; padding: 14px; }
  .h10-kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .h10-grid-charts { grid-template-columns: 1fr; }
  .h10-page-actions { width: 100%; }
}
@media (max-width: 575px) {
  .h10-kpi-grid { grid-template-columns: 1fr; }
}

/* ============================================================================
   Aviso (banner) e formulário de cadastro — acrescentados em 23/07/2026 para as
   abas Fornecedores e Ajustes de NF do PIN. Até aqui o design system não tinha
   nenhum dos dois: quem precisava de aviso criava um estilo local no template
   (ver .ec-alerta em estoque_cobertura.html), e formulário se virava com a
   .h10-filter-bar, que é de FILTRO e não de cadastro.
   Só classes NOVAS — nada acima foi alterado.
   ========================================================================== */
.h10-alert {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 14px 16px; margin-bottom: 16px;
  border: 1px solid var(--h10-border);
  border-left-width: 4px;
  border-radius: var(--h10-radius-md);
  background: var(--h10-surface);
  font-size: 14px; line-height: 1.5;
  box-shadow: var(--h10-shadow-card);
}
.h10-alert > i { font-size: 18px; line-height: 1.3; flex-shrink: 0; }
.h10-alert code {
  background: var(--h10-surface-soft); border: 1px solid var(--h10-border);
  border-radius: var(--h10-radius-sm); padding: 1px 5px; font-size: 13px;
}
.h10-alert.is-info    { border-left-color: var(--h10-primary); background: var(--h10-primary-soft); }
.h10-alert.is-info > i    { color: var(--h10-primary); }
.h10-alert.is-warning { border-left-color: var(--h10-warning); background: var(--h10-warning-soft); }
.h10-alert.is-warning > i { color: var(--h10-warning); }
.h10-alert.is-danger  { border-left-color: var(--h10-danger);  background: var(--h10-danger-soft); }
.h10-alert.is-danger > i  { color: var(--h10-danger); }
.h10-alert.is-success { border-left-color: var(--h10-success); background: var(--h10-success-soft); }
.h10-alert.is-success > i { color: var(--h10-success); }

/* Grade de cadastro: colunas que se acomodam sozinhas, sem media query por tela. */
.h10-form-grid {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  align-items: end;
}
.h10-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.h10-label {
  font-size: 12px; font-weight: 600; color: var(--h10-text-secondary);
  text-transform: uppercase; letter-spacing: .02em;
}
.h10-field .h10-input, .h10-field .h10-select { width: 100%; }
.h10-field-actions { justify-content: flex-end; }
@media (max-width: 575px) {
  .h10-form-grid { grid-template-columns: 1fr; }
}

/* ============================================================================
   V3 (19/set/2026) — componentes que o kit de migração pede e o design system não tinha.
   Só classes NOVAS. Kit: /root/incoming/v03_extraido/portalh10_v3_package/migration_kit.
   ========================================================================== */

/* Filtro V3: ícone + rótulo pequeno + controle, dentro de uma pílula de 54px.
   Uso: <label class="h10-filter-field"><span class="ico"><i class="bi bi-calendar3"></i></span>
          <span class="txt"><span class="lbl">Período</span><select class="h10-select">…</select></span></label>
   O controle continua sendo o mesmo <select>/<input> (name/id intactos) — só ganha a moldura. */
.h10-filter-field {
  display: flex; align-items: center; gap: 10px; min-width: 0;
  height: 54px; padding: 6px 10px 6px 8px; margin: 0;
  border: 1px solid var(--h10-border); border-radius: 10px; background: #fff;
  flex: 1 1 160px; max-width: 440px; cursor: pointer;
}
.h10-filter-field:focus-within { border-color: var(--h10-primary); box-shadow: 0 0 0 3px rgba(20, 108, 246, .14); }
.h10-filter-field.is-wide { flex: 2 1 220px; max-width: 640px; }
.h10-filter-field.is-narrow { flex: 0 1 150px; }
.h10-filter-field > .ico {
  width: 30px; height: 30px; border-radius: 8px; flex: 0 0 30px;
  display: grid; place-items: center; background: var(--h10-primary-soft); color: var(--h10-primary); font-size: 14px;
}
.h10-filter-field > .txt { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.h10-filter-field .lbl { font-size: 10px; color: #7290b5; line-height: 1.2; margin-bottom: 1px; font-weight: 500;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h10-filter-field .h10-input, .h10-filter-field .h10-select,
.h10-filter-field input, .h10-filter-field select {
  height: 22px; padding: 0 22px 0 0; border: 0; border-radius: 0; background-color: transparent;
  font-size: 13px; font-weight: 650; color: #14264c; width: 100%; min-width: 0; box-shadow: none !important;
  background-position: right 2px center;
}
.h10-filter-field input[type="date"] { padding-right: 0; }
.h10-filter-field input::placeholder { color: #a5b4c8; font-weight: 500; }
.h10-filter-field .h10-input:focus, .h10-filter-field .h10-select:focus,
.h10-filter-field input:focus, .h10-filter-field select:focus { outline: none; }
/* par "de → até" numa pílula só: a data precisa dos seus ~112px, senão o navegador corta "09/04/20" */
.h10-filter-field .range { display: flex; align-items: center; gap: 4px; white-space: nowrap; }
.h10-filter-field .range input[type="date"] { width: 112px; flex: 0 0 auto; }
.h10-filter-field:has(.range input[type="date"]) { flex: 0 0 auto; }
.h10-filter-field .range i { color: #a5b4c8; font-size: 11px; flex: 0 0 auto; }
/* ações da barra: atualizar (ícone) + Aplicar (único sólido) */
.h10-filter-actions { display: flex; gap: 8px; align-items: stretch; margin-left: auto; flex: 0 0 auto; }
.h10-filter-actions .h10-btn-primary, .h10-filter-actions .h10-btn-secondary { min-height: 54px; }
.h10-btn-iconsq {
  width: 54px; height: 54px; border-radius: 10px; border: 1px solid var(--h10-border); background: #fff;
  color: var(--h10-primary); display: inline-grid; place-items: center; font-size: 16px; cursor: pointer; text-decoration: none;
  transition: background .15s, box-shadow .15s;
}
.h10-btn-iconsq:hover { background: var(--h10-primary-soft); color: var(--h10-primary); }
.h10-filter-bar .h10-more { position: relative; }
.h10-filter-bar .h10-more-count {
  position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; border-radius: 999px;
  background: var(--h10-primary); color: #fff; font-size: 10px; font-weight: 700; display: grid; place-items: center; padding: 0 5px;
}
/* gaveta "Mais filtros" (abre/fecha por classe .is-open, JS em h10-v3.js) */
.h10-more-filters { display: none; flex-basis: 100%; gap: 8px; flex-wrap: wrap; padding-top: 8px;
  border-top: 1px dashed var(--h10-border); margin-top: 2px; }
.h10-more-filters.is-open { display: flex; }

/* Toolbar da tabela: busca → exportar → colunas, na cabeceira do card */
.h10-table-tools { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.h10-table-tools .h10-search { flex: 1 1 200px; max-width: 320px; }
.h10-table-tools .h10-btn-secondary { min-height: 38px; padding: 0 12px; font-size: 12.5px; }
.h10-table-tools .h10-input { height: 38px; }

/* Menu "…" de ações da linha */
.h10-row-menu { position: relative; display: inline-block; }
.h10-row-menu > summary { list-style: none; width: 28px; height: 28px; border-radius: 7px; border: 1px solid var(--h10-border);
  display: grid; place-items: center; cursor: pointer; color: var(--h10-text-secondary); background: #fff; }
.h10-row-menu > summary::-webkit-details-marker { display: none; }
.h10-row-menu[open] > summary { background: var(--h10-primary-soft); color: var(--h10-primary); }
.h10-row-menu > .menu { position: absolute; right: 0; top: 32px; z-index: 30; min-width: 180px; padding: 6px;
  background: #fff; border: 1px solid var(--h10-border); border-radius: 10px; box-shadow: var(--h10-shadow-hover); }
.h10-row-menu > .menu a, .h10-row-menu > .menu button { display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 7px 10px; border: 0; background: none; border-radius: 7px; font-size: 12.5px; color: var(--h10-text);
  text-decoration: none; text-align: left; cursor: pointer; }
.h10-row-menu > .menu a:hover, .h10-row-menu > .menu button:hover { background: var(--h10-surface-soft); }
.h10-row-menu > .menu .is-danger { color: var(--h10-danger); }

/* Paginação padronizada */
.h10-pagination { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.h10-pagination a, .h10-pagination button, .h10-pagination span.pg {
  min-width: 30px; height: 30px; padding: 0 8px; border-radius: 8px; border: 1px solid var(--h10-border);
  background: #fff; color: var(--h10-text-secondary); font-size: 12px; font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center; text-decoration: none; cursor: pointer;
}
.h10-pagination .active { background: var(--h10-primary); border-color: var(--h10-primary); color: #fff; }
.h10-pagination .disabled { opacity: .45; pointer-events: none; }
.h10-pagination .dots { border: 0; background: none; }

/* Faixa "Insights do período" (base dos dashboards) — só com dados REAIS calculados na rota/template */
.h10-insights {
  display: flex; align-items: stretch;
  background: linear-gradient(180deg, #fff, #f8fbff); border: 1px solid #d8e7fb; border-radius: 14px; overflow: hidden;
  box-shadow: var(--h10-shadow-card); margin-top: 12px;
}
.h10-insight-lead { display: flex; gap: 12px; align-items: center; padding: 14px 16px; min-height: 76px; flex: 0 1 300px; min-width: 0; }
.h10-insight-lead .ico { width: 42px; height: 42px; border-radius: 12px; flex: 0 0 42px; display: grid; place-items: center;
  background: var(--h10-primary-soft); color: var(--h10-primary); font-size: 20px; }
.h10-insight-lead > span { display: flex; flex-direction: column; min-width: 0; }
.h10-insight-lead b { font-size: 14px; color: #102653; }
.h10-insight-lead span span { font-size: 11.5px; color: #6e85a5; }
.h10-insight { display: flex; gap: 10px; align-items: center; padding: 14px 16px; border-left: 1px solid #e5edf7; min-height: 76px;
  min-width: 0; flex: 1 1 0; color: inherit; }
.h10-insight .ico { width: 34px; height: 34px; border-radius: 9px; flex: 0 0 34px; display: grid; place-items: center; font-size: 15px; }
.h10-insight > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.h10-insight .val { font-size: 15px; font-weight: 750; color: #0c204c; line-height: 1.15; }
.h10-insight .lbl { font-size: 11px; color: #6e85a5; line-height: 1.3; }
a.h10-insight:hover { background: #f3f8ff; }
.h10-insight-action { display: flex; align-items: center; justify-content: center; padding: 14px 16px; border-left: 1px solid #e5edf7; flex: 0 0 auto; }

/* Cabeçalho da página: metadado de atualização no canto direito */
.h10-page-meta { font-size: 12px; color: #6e83a0; text-align: right; line-height: 1.5; }
.h10-page-meta i { color: var(--h10-primary); margin-right: 4px; }

/* Card hero (um único indicador principal inequívoco) */
.h10-card.is-hero { background: linear-gradient(135deg, #082c62, #0755ad 55%, #0b73da); color: #fff; border: 0; }
.h10-card.is-hero .h10-card-head { border-bottom-color: rgba(255,255,255,.14); }
.h10-card.is-hero .h10-card-title, .h10-card.is-hero .h10-card-subtitle { color: #fff; }

/* Ponto de status (linha crítica ganha um ponto, não a linha inteira pintada) */
.h10-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #c7d2e0; margin-right: 6px; vertical-align: middle; }
.h10-dot.is-success { background: var(--h10-success); } .h10-dot.is-danger { background: var(--h10-danger); }
.h10-dot.is-warning { background: var(--h10-warning); } .h10-dot.is-info { background: var(--h10-primary); }

@media (max-width: 1300px) {
  .h10-insights { flex-wrap: wrap; }
  .h10-insight-lead { flex: 1 1 100%; border-bottom: 1px solid #e5edf7; }
  .h10-insight { flex: 1 1 45%; }
  .h10-insight:nth-child(2) { border-left: 0; }
}
@media (max-width: 900px) {
  .h10-insights { display: block; }
  .h10-insight, .h10-insight-action { border-left: 0; border-top: 1px solid #e5edf7; }
  .h10-filter-actions { margin-left: 0; width: 100%; }
  .h10-filter-actions .h10-btn-primary { flex: 1 1 auto; justify-content: center; }
}
@keyframes h10-spin { to { transform: rotate(360deg); } }
.h10-spin { display: inline-block; animation: h10-spin .9s linear infinite; }

/* Barra em modo "rail" (montada pelo h10-v3.js): botões e dropdowns na altura das pílulas */
.h10-filter-bar.is-rail > .h10-btn-primary, .h10-filter-bar.is-rail > .h10-btn-secondary,
.h10-filter-bar.is-rail > .h10-btn-danger, .h10-filter-bar.is-rail > .dropdown > .h10-btn-secondary,
.h10-filter-bar.is-rail > .dropdown > .h10-btn-primary, .h10-filter-bar.is-rail > form > .h10-btn-secondary { min-height: 54px; }
.h10-filter-bar.is-rail > .h10-filter-field .h10-search { position: static; flex: 1 1 auto; max-width: none; }
.h10-filter-bar.is-rail > .h10-filter-field .h10-search .h10-input { padding-left: 0; }
.h10-filter-bar.is-rail input[type="checkbox"] { width: 16px; height: 16px; }
.h10-filter-bar.is-rail > label:not(.h10-filter-field) { font-size: 12.5px; font-weight: 600; color: var(--h10-text-secondary);
  display: inline-flex; align-items: center; gap: 6px; padding: 0 6px; }

/* ============================================================================
   V3 (20/set/2026) — lista de opções própria dos selects de filtro (.h10-dd, montada pelo
   h10-v3.js no <body>) e barra de filtros recolhível (chips dos filtros em vigor).
   ========================================================================== */
.h10-dd {
  position: fixed; z-index: 1080; display: flex; flex-direction: column; padding: 6px;
  background: #fff; border: 1px solid var(--h10-border); border-radius: 12px;
  box-shadow: 0 14px 36px rgba(8, 31, 59, .16), 0 2px 6px rgba(8, 31, 59, .06);
  font-family: inherit; outline: none; animation: h10-dd-in .12s ease-out;
}
@keyframes h10-dd-in { from { transform: translateY(-4px); } to { transform: none; } }
.h10-dd-search { position: relative; margin: 2px 2px 6px; }
.h10-dd-search i { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: #8da0b9; font-size: 13px; }
.h10-dd-search input {
  width: 100%; height: 36px; padding: 0 10px 0 32px; border: 1px solid var(--h10-border); border-radius: 8px;
  font-size: 13px; font-weight: 500; color: #14264c; background: #f8fafd;
}
.h10-dd-search input:focus { outline: none; border-color: var(--h10-primary); background: #fff; box-shadow: 0 0 0 3px rgba(20, 108, 246, .14); }
.h10-dd-list { overflow: auto; max-height: min(340px, 60vh); overscroll-behavior: contain; scrollbar-width: thin; }
.h10-dd-opt {
  display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 6px 10px; border-radius: 8px;
  font-size: 13px; font-weight: 500; color: #14264c; cursor: pointer; line-height: 1.25;
}
.h10-dd-opt .t { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h10-dd-opt .chk { flex: 0 0 auto; font-size: 14px; color: var(--h10-primary); opacity: 0; }
.h10-dd-opt.is-active { background: var(--h10-primary-soft); }
.h10-dd-opt.is-selected { color: var(--h10-primary); font-weight: 650; }
.h10-dd-opt.is-selected .chk { opacity: 1; }
.h10-dd-opt.is-disabled { color: #a5b4c8; cursor: default; }
.h10-dd-group { padding: 8px 10px 4px; font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #7290b5; }
.h10-dd-empty { padding: 14px 10px; font-size: 12.5px; color: #7290b5; text-align: center; }
.h10-dd-count { padding: 6px 10px 2px; margin-top: 4px; border-top: 1px solid #edf2f8; font-size: 10.5px; color: #8da0b9; }

/* Barra recolhida: pílulas, Aplicar, Atualizar e "Mais filtros" somem; ficam os chips + botões de ação da tela */
.h10-filter-chips { display: none; flex: 1 1 auto; min-width: 0; flex-wrap: wrap; align-items: center; gap: 6px; margin-right: auto; }
.h10-filter-chips .lead {
  display: inline-flex; align-items: center; gap: 6px; padding: 0 6px 0 2px;
  font-size: 10.5px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: #7290b5;
}
.h10-filter-chips .lead i { font-size: 13px; }
.h10-filter-chip {
  display: inline-flex; align-items: center; gap: 8px; height: 40px; max-width: 280px; padding: 0 12px 0 7px;
  border: 1px solid var(--h10-border); border-radius: 10px; background: #fff; cursor: pointer;
  font: inherit; text-align: left; color: inherit; transition: border-color .15s, box-shadow .15s, background .15s;
}
.h10-filter-chip:hover { border-color: var(--h10-primary); box-shadow: 0 0 0 3px rgba(20, 108, 246, .10); }
.h10-filter-chip:focus-visible { outline: none; border-color: var(--h10-primary); box-shadow: 0 0 0 3px rgba(20, 108, 246, .18); }
.h10-filter-chip .ico {
  width: 26px; height: 26px; flex: 0 0 26px; border-radius: 7px; display: grid; place-items: center;
  background: #f1f5fb; color: #7290b5; font-size: 12.5px;
}
.h10-filter-chip .txt { display: flex; flex-direction: column; min-width: 0; }
.h10-filter-chip .k { font-size: 10px; font-weight: 500; color: #7290b5; line-height: 1.15; white-space: nowrap; }
.h10-filter-chip .v { font-size: 12.5px; font-weight: 650; color: #14264c; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h10-filter-chip.is-on { border-color: #c5dbfb; background: #eef5ff; }
.h10-filter-chip.is-on .ico { background: var(--h10-primary); color: #fff; }
.h10-filter-chip.is-on .v { color: #0d4fc0; }
.h10-filter-chip.is-muted .v { color: #8da0b9; font-weight: 500; }
.h10-filter-toggle { display: inline-flex; align-items: center; gap: 6px; flex: 0 0 auto; white-space: nowrap; }
.h10-filter-toggle i { font-size: 14px; }
.h10-filter-bar.is-collapsed { padding: 8px 10px; }
.h10-filter-bar.is-collapsed > .h10-filter-chips { display: flex; }
.h10-filter-bar.is-collapsed > .h10-filter-field, .h10-filter-bar.is-collapsed > .h10-filter-actions,
.h10-filter-bar.is-collapsed > button[type="submit"], .h10-filter-bar.is-collapsed > .h10-btn-primary,
.h10-filter-bar.is-collapsed > .h10-more, .h10-filter-bar.is-collapsed > [data-h10-more],
.h10-filter-bar.is-collapsed > .h10-more-filters, .h10-filter-bar.is-collapsed > .h10-filter-spacer,
.h10-filter-bar.is-collapsed > .h10-btn-iconsq { display: none; }
/* botões que ficam (Exportar, Sincronizar…) descem para a altura dos chips */
.h10-filter-bar.is-collapsed > .h10-btn-secondary, .h10-filter-bar.is-collapsed > .h10-btn-danger,
.h10-filter-bar.is-collapsed > .dropdown > .h10-btn-secondary, .h10-filter-bar.is-collapsed > .dropdown > .h10-btn-primary,
.h10-filter-bar.is-collapsed > form > .h10-btn-secondary, .h10-filter-bar.is-collapsed > .h10-filter-toggle { min-height: 40px; }
.h10-filter-bar.is-rail:not(.is-collapsed) > .h10-filter-toggle { min-height: 54px; }
@media (min-width: 1100px) { .h10-filter-bar--tight.is-collapsed { flex-wrap: wrap; } }
@media (max-width: 900px) {
  .h10-filter-chips .lead { display: none; }
  .h10-filter-chip { max-width: 100%; }
  .h10-filter-bar.is-collapsed > .h10-filter-toggle { width: auto; }
}
