/* Estilos específicos do grupo de módulos: acidentes e almoxarifado (prefixo .ac-) */
.ac-body { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.ac-body > .ph h1, .ac-sec-h h1 { font-size: 16px; letter-spacing: -.01em; }
.ac-body > .ph .ph-sub, .ac-sec-h .ph-sub { font-size: 12.5px; }
.ac-painel { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.ac-s { font-size: 11.5px; }
.ac-lbl { font-size: 10.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--mut); margin: 2px 0 2px; }
.ac-chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.ac-desc { margin-top: 10px; color: var(--ink-2); }

/* variação ano × ano: verde = melhor, vermelho = pior (sempre com seta e texto) */
.ac-var { font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ac-var.melhor { color: var(--good-tx); }
.ac-var.pior { color: var(--crit-tx); }

/* "Como é calculado" */
.ac-calc { background: var(--sf); border: 1px solid var(--ln); border-radius: var(--r-lg); padding: 10px 14px; font-size: 12.5px; color: var(--ink-2); }
.ac-calc summary { cursor: pointer; font-weight: 600; color: var(--acc-tx); list-style: none; display: flex; align-items: center; gap: 6px; }
.ac-calc summary::-webkit-details-marker { display: none; }
.ac-calc > div { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }

/* anotações do mês */
.ac-anot { border-top: 1px solid var(--ln-2); margin-top: 8px; padding-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.ac-anot-h { display: flex; justify-content: space-between; align-items: center; font-size: 11.5px; font-weight: 600; color: var(--ink-2); }
.ac-anot-h > span { display: inline-flex; gap: 6px; align-items: center; }
.ac-anot-l { display: flex; flex-direction: column; gap: 4px; }
.ac-anot-i { display: flex; gap: 10px; align-items: center; font-size: 12.5px; padding: 4px 8px; background: var(--sf-2); border-radius: var(--r-sm); }
.ac-anot-i b { min-width: 76px; color: var(--acc-tx); font-weight: 600; }
.ac-anot-i > span:not(.ac-anot-x) { flex: 1; min-width: 0; }
.ac-anot-x { display: inline-flex; gap: 2px; }

/* tabelas compactas */
.ac-cmp td, .ac-cmp th { padding: 6px 8px; }
.ac-pareto { max-height: 360px; }
.ac-pareto tr.ac-a80 td { background: var(--acc-soft); }
.ac-grav { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 4px; font-size: 11px; font-weight: 700; color: #fff; background: #4f86b8; margin-right: 4px; }
.ac-grav.g0 { background: #c4d6e8; color: var(--ink); } .ac-grav.g1 { background: #8fb3d4; color: var(--ink); } .ac-grav.g2 { background: #4f86b8; }
.ac-grav.g3 { background: #1f5f99; } .ac-grav.g4 { background: #12395f; } .ac-grav.g5, .ac-grav.g6 { background: #0f1b2a; }

/* detalhe / formulário */
.ac-det { display: flex; flex-direction: column; gap: 12px; }
.ac-sub { background: var(--sf-2); }
.ac-click { cursor: pointer; }
.ac-click:hover .r-t { color: var(--acc-tx); }
.ac-form { display: flex; flex-direction: column; gap: 14px; }
.ac-form .form-grid [data-k="partes"] > div { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 6px 12px !important; padding: 10px 12px; background: var(--sf-2); border: 1px solid var(--ln); border-radius: var(--r); }
.ac-pick { position: relative; display: flex; gap: 6px; align-items: center; }
.ac-dd { position: absolute; top: calc(100% + 4px); left: 0; right: 0; z-index: 5; background: var(--sf); border: 1px solid var(--ln-strong); border-radius: var(--r); box-shadow: var(--sh-lg); max-height: 280px; overflow-y: auto; }
.ac-dd button { display: flex; flex-direction: column; align-items: flex-start; width: 100%; border: 0; background: none; padding: 8px 12px; cursor: pointer; text-align: left; border-bottom: 1px solid var(--ln-2); }
.ac-dd button:hover { background: var(--acc-soft); }
.ac-dd button span { font-size: 11.5px; color: var(--mut); }
.ac-dd-vazio { padding: 10px 12px; font-size: 12px; }
.ac-anexos .rows { margin: 8px 0; }
.ac-anx-add { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ac-anx-add select { width: 160px; }

/* horas trabalhadas */
.ac-hh td, .ac-hh th { padding: 6px 4px; }
.ac-hh td:first-child { white-space: nowrap; padding-left: 14px; }
.ac-hh-in { height: 30px; width: 100%; min-width: 66px; font-size: 12.5px; text-align: right; padding: 0 6px; font-variant-numeric: tabular-nums; }
.ac-hh-in.ac-dirty { border-color: var(--warn); background: var(--warn-bg); }
.ac-hh tfoot td { border-top: 1px solid var(--ln); background: var(--sf-2); }

/* RCA */
.ac-alerta { border-color: var(--warn-ln); }
.ac-alerta .card-t { display: inline-flex; gap: 6px; align-items: center; color: var(--warn-tx); }
.ac-pq { display: flex; flex-direction: column; gap: 8px; }
.ac-pq-row { display: grid; grid-template-columns: 80px minmax(0, 1fr) 190px; gap: 10px; align-items: center; }
.ac-pq-n { font-size: 11px; font-weight: 700; color: var(--acc-tx); text-transform: uppercase; letter-spacing: .05em; }
.ac-ish-box { overflow-x: auto; }
.ac-ish { width: 100%; min-width: 760px; height: auto; display: block; }
.ac-ish-spine { stroke: var(--acc); stroke-width: 3; }
.ac-ish-arrow { fill: var(--acc); }
.ac-ish-head { fill: var(--acc); }
.ac-ish-headtx { fill: #fff; font-size: 12.5px; font-weight: 600; }
.ac-ish-bone { stroke: var(--s1); stroke-width: 2; }
.ac-ish-cat { fill: var(--acc-soft); stroke: var(--s1); stroke-width: 1; }
.ac-ish-cattx { fill: var(--acc); font-size: 12px; font-weight: 700; }
.ac-ish-twig { stroke: var(--mut-2); stroke-width: 1; }
.ac-ish-tx { fill: var(--ink); font-size: 11px; }
.ac-ish-mais { fill: var(--mut); font-size: 10.5px; font-weight: 600; }
.ac-ish-vazio { fill: var(--mut-2); font-size: 10.5px; font-style: italic; }
.ac-6m { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.ac-6m-col { background: var(--sf-2); border: 1px solid var(--ln); border-radius: var(--r); padding: 8px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ac-6m-h { font-size: 11px; font-weight: 700; color: var(--acc-tx); text-transform: uppercase; letter-spacing: .05em; display: flex; justify-content: space-between; }
.ac-6m-it { display: flex; gap: 2px; align-items: center; }
.ac-6m-it .in { height: 30px; font-size: 12px; padding: 0 6px; }
.ac-val { display: flex; flex-direction: column; gap: 8px; }
.ac-val .check { align-items: flex-start; font-size: 12.5px; }

/* almoxarifado */
.ac-imp-drop { border: 1.5px dashed var(--ln-strong); border-radius: var(--r-lg); padding: 22px; text-align: center; color: var(--mut); background: var(--sf-2); display: flex; flex-direction: column; gap: 8px; align-items: center; }
.ac-imp-map { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 14px; }
.ac-imp-modos { display: flex; flex-direction: column; gap: 8px; }
.ac-imp-modos .check { align-items: flex-start; }
.ac-prog { height: 8px; background: var(--ln-2); border-radius: 4px; overflow: hidden; }
.ac-prog > i { display: block; height: 100%; width: 0; background: var(--acc); transition: width .2s; }
.ac-prev td, .ac-prev th { padding: 5px 8px; font-size: 12px; }

/* responsivo */
@media (max-width: 1100px) { .ac-6m { grid-template-columns: repeat(3, minmax(0, 1fr)); } .ac-imp-map { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 860px) { .ac-pq-row { grid-template-columns: 1fr; gap: 4px; } .ac-6m { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------------- impressão (Ficha / RCA em PDF) ---------------- */
.ac-print { display: none; }
@media print {
  body.ac-printing > *:not(.ac-print) { display: none !important; }
  body.ac-printing .ac-print { display: block; }
  @page { margin: 1.4cm; }
}
.ac-pr { font-size: 11.5px; color: #111; }
.ac-pr-h { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 10px; margin-bottom: 12px; border-bottom: 3px solid #12395f; }
.ac-pr-h img { height: 34px; }
.ac-pr-h > div:nth-child(2) { text-align: center; display: flex; flex-direction: column; }
.ac-pr-h b { font-size: 15px; color: #12395f; letter-spacing: .02em; }
.ac-pr-h span { font-size: 10.5px; color: #555; }
.ac-pr-dt { font-size: 10.5px; color: #444; text-align: right; }
.ac-pr-tag { text-align: center; font-weight: 700; font-size: 12px; margin-bottom: 10px; padding: 5px; border: 1px solid #12395f; color: #12395f; }
.ac-pr-t { width: 100%; border-collapse: collapse; margin-bottom: 10px; break-inside: auto; }
.ac-pr-t th, .ac-pr-t td { border: 1px solid #ccc; padding: 5px 8px; vertical-align: top; text-align: left; }
.ac-pr-t th { background: #f3f4f6; width: 30%; font-weight: 600; color: #333; }
.ac-pr-acoes th { width: auto; }
.ac-pr-sec td { background: #12395f; color: #fff; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; font-size: 10.5px; }
.ac-pr-sec2 { background: #12395f; color: #fff; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; font-size: 10.5px; padding: 5px 8px; }
.ac-pr-txt { line-height: 1.55; white-space: pre-wrap; }
.ac-pr-ish { border: 1px solid #ccc; margin-bottom: 10px; break-inside: avoid; }
.ac-pr-ish .ac-ish { min-width: 0; }
.ac-pr-foot { font-size: 10px; color: #666; margin-top: 4px; }
.ac-pr-ass { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 44px; }
.ac-pr-ass div { border-top: 1px solid #333; padding-top: 6px; text-align: center; font-size: 10.5px; color: #444; }
.ac-hh-in { padding: 0 5px; -moz-appearance: textfield; appearance: textfield; }
.ac-hh-in::-webkit-outer-spin-button, .ac-hh-in::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.ac-kv-sm { font-size: 16px !important; }
.ac-rank td { padding: 4px 4px 0; border-bottom: 0; font-size: 12px; }
.ac-rank tr:hover td { background: none; }
.ac-rank-l { max-width: 0; width: 60%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ac-rank-b td { padding: 2px 4px 6px; border-bottom: 1px solid var(--ln-2); }
.ac-tabs { overflow-x: auto; scrollbar-width: thin; }
.ac-tabs .tab { white-space: nowrap; }
