/* ===== Portal do RH por cliente e importador (prefixo rh-). Dono: G-MDS-B. A cor do cliente entra por --rh-cor na casca. ===== */
.rh-shell { --rh-cor: var(--mds-serie-1); --rh-cor-forte: color-mix(in srgb, var(--rh-cor) 78%, black); --rh-cor-suave: color-mix(in srgb, var(--rh-cor) 10%, var(--mds-sobre-cor)); display: block; max-width: 1180px; margin: 0 auto; min-width: 0; }
.rh-topo { display: flex; align-items: center; gap: 12px; background: var(--rh-cor); color: var(--mds-sobre-cor); padding: 12px 16px; border-radius: var(--mds-raio) var(--mds-raio) 0 0; flex-wrap: wrap; }
.rh-logo { width: 40px; height: 40px; border-radius: 10px; background: var(--mds-superficie); color: var(--rh-cor-forte); display: inline-grid; place-items: center; font-weight: 800; font-size: 16px; letter-spacing: .5px; flex: none; }
.rh-marca { display: flex; flex-direction: column; min-width: 0; flex: 1 1 200px; }
.rh-marca b { font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rh-marca small { font-size: 11px; opacity: .8; letter-spacing: .2px; }
.rh-quem { font-size: 13px; background: color-mix(in srgb, var(--mds-sobre-cor) 16%, transparent); padding: 4px 10px; border-radius: 99px; white-space: nowrap; }
.rh-volta { color: var(--mds-sobre-cor); font-size: 13px; text-decoration: underline; white-space: nowrap; }
.rh-nav { display: flex; gap: 2px; background: var(--mds-superficie); border: 1px solid var(--mds-borda); border-top: 0; padding: 0 8px; overflow-x: auto; margin-bottom: 18px; border-radius: 0 0 var(--mds-raio) var(--mds-raio); -webkit-overflow-scrolling: touch; }
.rh-nav-item { display: inline-flex; align-items: center; gap: 6px; padding: 11px 12px; color: var(--mds-apoio); text-decoration: none; font-size: 13px; font-weight: 600; white-space: nowrap; border-bottom: 3px solid transparent; }
.rh-nav-item:hover { color: var(--rh-cor-forte); background: var(--rh-cor-suave); }
.rh-nav-item[aria-current="page"] { color: var(--rh-cor-forte); border-bottom-color: var(--rh-cor); }
.rh-nav-n { background: var(--rh-cor); color: var(--mds-sobre-cor); font-size: 11px; border-radius: 99px; padding: 0 6px; min-width: 18px; text-align: center; line-height: 18px; }
.rh-cab .mds-cab { margin-top: 0; }
.rh-corpo { min-width: 0; }
.rh-shell .mds-btn { background: var(--rh-cor); border-color: var(--rh-cor); }
.rh-shell .mds-btn:hover { background: var(--rh-cor-forte); }
.rh-shell .mds-btn-sec, .rh-modal-sec { background: var(--mds-superficie); color: var(--rh-cor-forte); border-color: var(--rh-cor); }
.rh-shell .mds-btn-sec:hover { background: var(--rh-cor-suave); }
.rh-shell .mds-btn-perigo { background: var(--mds-erro); border-color: var(--mds-erro); }
.rh-shell a { color: var(--rh-cor-forte); }
.rh-shell a.mds-btn, .rh-shell a.mds-btn:hover { color: var(--mds-sobre-cor); text-decoration: none; }
.rh-shell a.mds-btn-sec, .rh-shell a.mds-btn-sec:hover { color: var(--rh-cor-forte); }
.rh-shell .rh-topo a.rh-volta { color: var(--mds-sobre-cor); }
.rh-shell .mds-aba[aria-selected="true"] { color: var(--rh-cor-forte); border-bottom-color: var(--rh-cor); }
.rh-shell .mds-kpi { border-top: 3px solid var(--rh-cor-suave); }
.rh-shell .mds-kpi-aviso, .rh-shell .mds-kpi-erro, .rh-shell .mds-kpi-ok { border-top-width: 1px; }
.rh-kpis { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.rh-kpis .mds-kpi strong { white-space: nowrap; font-size: 21px; }
.rh-grade { align-items: start; margin-bottom: 14px; }
.rh-bloco { margin-bottom: 14px; }
.rh-bloco h2, .rh-grade .mds-cartao h2 { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.rh-ver { font-size: 12px; font-weight: 600; text-decoration: none; }
.rh-ver:hover { text-decoration: underline; }
.rh-h3 { font-size: 13px; margin: 14px 0 6px; font-family: var(--mds-fonte-titulo, inherit); }

/* listas de itens */
.rh-lista-itens { list-style: none; margin: 0; padding: 0; }
.rh-lista-itens li + li { border-top: 1px solid var(--mds-borda); }
.rh-lista-itens a, .rh-lista-itens li > .rh-item-txt:first-child { display: flex; align-items: center; gap: 10px; padding: 9px 0; color: inherit; text-decoration: none; }
.rh-lista-itens li > .rh-item-txt:first-child { display: flex; flex-direction: column; align-items: flex-start; gap: 0; }
.rh-lista-itens a:hover .rh-item-txt b { color: var(--rh-cor-forte); }
.rh-item-txt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.rh-item-txt b { font-size: 13px; overflow-wrap: anywhere; }
.rh-item-txt small { color: var(--mds-apoio); font-size: 12px; overflow-wrap: anywhere; }
.rh-item-dir { white-space: nowrap; font-size: 13px; font-weight: 600; }
.rh-pt { width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--mds-info); }
.rh-pt-erro { background: var(--mds-erro); } .rh-pt-aviso { background: var(--mds-aviso); } .rh-pt-ok { background: var(--mds-ok); } .rh-pt-neutro { background: var(--mds-apoio); }
.rh-txt-erro { color: var(--mds-erro); }

/* vidas */
.rh-filtros .mds-campo { min-width: 140px; }
.rh-busca { flex: 1 1 240px; }
.rh-contagem-v { margin: 0 0 8px; font-size: 13px; }
.rh-mais { display: flex; justify-content: center; padding: 12px 0 2px; }
.rh-form { display: grid; gap: 12px; }
.rh-duas { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.rh-form .mds-campo small { font-size: 12px; color: var(--mds-apoio); }
.rh-form .mds-campo small[hidden], .mds-campo[hidden] { display: none; }
.rh-form .mds-campo-erro small { color: var(--mds-erro); font-weight: 600; }
.rh-dl { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; margin: 0 0 6px; }
.rh-dl div { display: flex; flex-direction: column; min-width: 0; }
.rh-dl dt { font-size: 11px; color: var(--mds-apoio); }
.rh-dl dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }

/* movimentação: andamento do lote */
.rh-lote-topo { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.rh-tempo { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.rh-tempo li { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; position: relative; padding-top: 4px; color: var(--mds-apoio); }
.rh-tempo li::before { content: ''; position: absolute; top: 15px; left: 24px; right: -8px; height: 2px; background: var(--mds-borda); }
.rh-tempo li:last-child::before { display: none; }
.rh-t-bola { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--mds-borda); background: var(--mds-superficie); display: inline-grid; place-items: center; position: relative; z-index: 1; color: var(--mds-sobre-cor); }
.rh-tempo b { font-size: 13px; color: var(--mds-texto); } .rh-tempo small { font-size: 12px; }
.rh-t-feito .rh-t-bola, .rh-t-atual .rh-t-bola { background: var(--rh-cor); border-color: var(--rh-cor); }
.rh-t-feito::before { background: var(--rh-cor); }
.rh-t-atual .rh-t-bola { box-shadow: 0 0 0 4px var(--rh-cor-suave); }
.rh-t-erro .rh-t-bola { background: var(--mds-erro); border-color: var(--mds-erro); }

/* gráficos */
.rh-graf-cartao h2 { display: block; margin-bottom: 2px; }
.rh-graf-cartao .mds-sub { margin: 0 0 8px; font-size: 12px; }
.rh-graf { position: relative; height: 240px; }

/* chamados */
.rh-cha-topo { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.rh-msgs { list-style: none; margin: 10px 0 14px; padding: 0; display: grid; gap: 8px; }
.rh-msg { border: 1px solid var(--mds-borda); border-radius: 10px; padding: 8px 12px; background: var(--mds-fundo); }
.rh-msg-equipe { background: var(--mds-info-suave); border-color: transparent; }
.rh-msg-topo { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-size: 13px; }
.rh-msg-topo small { color: var(--mds-apoio); }
.rh-msg p { margin: 4px 0 0; overflow-wrap: anywhere; }
.rh-peq { padding: 4px 10px; font-size: 12px; }

/* importador */
.rh-imp { min-width: 0; }
.rh-passos { list-style: none; margin: 0 0 16px; padding: 0; display: flex; gap: 8px; flex-wrap: wrap; }
.rh-passos li { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 99px; background: var(--mds-fundo); color: var(--mds-apoio); font-size: 13px; font-weight: 600; border: 1px solid var(--mds-borda); }
.rh-passos li > span { width: 20px; height: 20px; border-radius: 50%; background: var(--mds-borda); color: var(--mds-apoio); display: inline-grid; place-items: center; font-size: 11px; }
.rh-passos .rh-passo-ativo { background: var(--rh-cor-suave); border-color: var(--rh-cor); color: var(--rh-cor-forte); }
.rh-passos .rh-passo-ativo > span, .rh-passos .rh-passo-feito > span { background: var(--rh-cor); color: var(--mds-sobre-cor); }
.rh-passos .rh-passo-feito { color: var(--rh-cor-forte); }
.rh-imp-grade { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 14px; align-items: start; }
.rh-imp-main, .rh-imp-lado { min-width: 0; }
.rh-imp-lado { position: sticky; top: 12px; }
.rh-drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; border: 2px dashed var(--mds-borda); border-radius: var(--mds-raio); padding: 28px 16px; background: var(--mds-superficie); cursor: pointer; transition: border-color .15s, background .15s; }
.rh-drop:hover, .rh-drop:focus-within, .rh-drop-sobre { border-color: var(--rh-cor); background: var(--rh-cor-suave); }
.rh-drop-ic { color: var(--rh-cor); }
.rh-drop b { font-size: 15px; } .rh-drop small { color: var(--mds-apoio); }
.rh-so-leitor { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); border: 0; white-space: nowrap; }
.rh-mt { margin-top: 12px; }
.rh-acoes { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
.rh-lista { margin: 6px 0 0; padding-left: 18px; font-size: 13px; } .rh-lista li { margin: 3px 0; }
.rh-lista-ok { list-style: none; padding-left: 0; } .rh-lista-ok li { position: relative; padding-left: 18px; color: var(--mds-ok); }
.rh-lista-ok li::before { content: '✓'; position: absolute; left: 0; font-weight: 700; }
.rh-lado-erro { color: var(--mds-erro); }
.rh-contagem { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; margin: 10px 0; }
.rh-cont { border: 1px solid var(--mds-borda); border-radius: 10px; padding: 8px 10px; background: var(--mds-superficie); display: flex; flex-direction: column; }
.rh-cont b { font-size: 20px; } .rh-cont small, .rh-cont span { color: var(--mds-apoio); font-size: 12px; }
.rh-cont-ok { border-left: 4px solid var(--mds-ok); } .rh-cont-erro { border-left: 4px solid var(--mds-erro); } .rh-cont-aviso { border-left: 4px solid var(--mds-aviso); }
.rh-tab-map, .rh-tab-prev { width: 100%; border-collapse: collapse; font-size: 13px; }
.rh-tab-map th, .rh-tab-prev th { text-align: left; font-size: 12px; color: var(--mds-apoio); padding: 6px 8px; border-bottom: 1px solid var(--mds-borda); background: var(--mds-fundo); white-space: nowrap; }
.rh-tab-map td, .rh-tab-prev td { padding: 6px 8px; border-bottom: 1px solid var(--mds-borda); vertical-align: middle; }
.rh-imp select, .rh-imp input:not([type=file]) { max-width: 100%; }
.rh-imp .mds-campo select { width: 100%; }
.rh-tab-prev input { min-width: 110px; }
.rh-cel { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rh-cel-erro { background: var(--mds-erro-suave); color: var(--mds-erro); font-weight: 600; }
.rh-cel-aviso { background: var(--mds-aviso-suave); color: var(--mds-aviso); }
.rh-cel-vazia { color: var(--mds-apoio); }
.rh-lin-ok td:first-child { box-shadow: inset 3px 0 0 var(--mds-ok); } .rh-lin-aviso td:first-child { box-shadow: inset 3px 0 0 var(--mds-aviso); } .rh-lin-erro td:first-child { box-shadow: inset 3px 0 0 var(--mds-erro); }
.rh-kpi-txt { font-size: 13px; color: var(--mds-apoio); }
.rh-prazos { font-size: 12px; color: var(--mds-apoio); margin: 6px 0 0; }
.rh-importar { min-width: 0; }

@media (max-width: 1000px) { .rh-imp-grade { grid-template-columns: 1fr; } .rh-imp-lado { position: static; } }
@media (max-width: 900px) {
  .rh-topo { padding: 10px 12px; } .rh-marca { flex-basis: 140px; }
  .rh-nav { padding: 0 4px; margin-bottom: 14px; flex-wrap: wrap; overflow-x: visible; }
  .rh-nav-item { padding: 9px 10px; }
  .rh-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rh-kpis .mds-kpi strong { font-size: 18px; white-space: normal; overflow-wrap: anywhere; }
  .rh-duas, .rh-dl { grid-template-columns: 1fr; }
  .rh-tempo { grid-template-columns: 1fr 1fr; row-gap: 14px; } .rh-tempo li::before { display: none; }
  .rh-graf { height: 220px; }
  .rh-tab-prev { display: table; width: max-content; min-width: 100%; }
  .rh-tab-prev thead { display: table-header-group; } .rh-tab-prev tbody { display: table-row-group; }
  .rh-tab-prev tr { display: table-row; padding: 0; border: 0; } .rh-tab-prev td { display: table-cell; width: auto; padding: 6px 8px; border-bottom: 1px solid var(--mds-borda); }
  .rh-tab-prev td::before { content: none; }
  .rh-imp .mds-tabela-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .rh-cel { max-width: 150px; }
  .rh-shell .mds-cab { flex-direction: column; align-items: stretch; }
  .rh-shell .mds-cab-acoes { width: 100%; } .rh-shell .mds-cab-acoes .mds-btn { flex: 1 1 auto; justify-content: center; }
  .mds-modal-fundo .mds-modal { max-height: 94vh; }
  .rh-filtros .mds-campo { flex: 1 1 130px; }
}
@media (max-width: 480px) { .rh-kpis { grid-template-columns: 1fr 1fr; } .rh-topo .rh-quem { display: none; } }
