/* Hành chính — tab Tham số trong module Lương Nhân Sự (20/10/2026, giai đoạn 3 lương 70/30 + KPI).
   Nạp sau hanh-chinh-payroll.css và hanh-chinh-kpi.css; dùng lại .pr-table / .pr-in / .pr-wrap /
   .pr-toolbar / .pr-legend-v2. File này chỉ thêm phần riêng của bảng tham số. */

#payrollPaneThamSo .pr-toolbar { margin-bottom: 6px; }
#payrollPaneThamSo .pr-toolbar label { font-size: 12.5px; color: #5A4632; font-weight: 600; }
#thamSoLegend { margin-bottom: 10px; }
#thamSoLegend .thamso-lien-ket { color: #8B5A1E; font-weight: 700; text-decoration: none; border-bottom: 1px dotted #C27A34; }
#thamSoLegend .thamso-lien-ket:hover { color: #5A3A10; }

/* Ghi chú bản ghi + khung báo lỗi tổng. */
.thamso-note { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; max-width: 760px; }
.thamso-note label { font-size: 12.5px; font-weight: 600; color: #5A4632; white-space: nowrap; }
.thamso-note input { flex: 1; min-width: 0; border: 1px solid #E8DFD5; border-radius: 8px; padding: 6px 9px; font: inherit; font-size: 12.5px; background: #fff; }
.thamso-note input:focus { outline: 2px solid #C27A34; }
.thamso-note input[readonly] { background: #FAF6F0; color: #6B5B4B; }
.thamso-errors { margin: 0 0 10px; padding: 8px 12px; border: 1px solid #F3C7C2; border-radius: 8px; background: #FDF2F2; color: #B42318; font-size: 12.5px; font-weight: 600; line-height: 1.5; }
.thamso-trong { color: #8A7355; font-size: 12.5px; padding: 14px; }

/* Mỗi nhóm một khối. */
.thamso-sec { margin: 0 0 14px; }
.thamso-sec-head { display: flex; align-items: baseline; gap: 10px; padding: 6px 2px 5px; }
.thamso-sec-head strong { font-size: 12px; letter-spacing: .05em; color: #5A4632; text-transform: uppercase; }
.thamso-dem { font-size: 11.5px; font-weight: 700; color: #B45309; }
.pr-wrap.thamso-wrap, body.hc-module-payroll .pr-wrap.thamso-wrap { max-height: none; }
.thamso-table { width: 100%; white-space: normal; }
.thamso-table thead th { position: static; text-align: left; padding: 6px 10px; }
.thamso-table th:nth-child(2), .thamso-table th:nth-child(3) { text-align: right; }
.thamso-table th:nth-child(4) { text-align: center; }
.thamso-table td { padding: 5px 10px; vertical-align: middle; border-bottom: 1px solid #F0E8DD; }
.thamso-table tbody tr:last-child td { border-bottom: 0; }
.thamso-td-label { min-width: 260px; font-weight: 600; color: #3B3128; }
.thamso-td-in { width: 190px; min-width: 150px; }
.thamso-td-md { width: 150px; text-align: right; color: #8A7355; font-variant-numeric: tabular-nums; white-space: nowrap; }
.thamso-td-khac { width: 34px; text-align: center; color: #B45309; font-size: 11px; }
.thamso-td-hint { color: #6B5B4B; font-size: 11.5px; line-height: 1.45; min-width: 240px; }

/* Ô nhập: vàng, chữ xanh (quy ước ô nhập của bảng lương / Excel mẫu). */
.thamso-o { display: flex; align-items: center; gap: 4px; }
.thamso-table .thamso-in { background: #FFF6D6; color: #1D4ED8; font-weight: 700; text-align: right; border: 1px solid #F1E2A8; border-radius: 6px; padding: 4px 8px; font: inherit; font-weight: 700; font-variant-numeric: tabular-nums; width: 100%; box-sizing: border-box; }
.thamso-table select.thamso-in { text-align: left; cursor: pointer; }
.thamso-table .thamso-in:focus { outline: 2px solid #C27A34; background: #FFFBEA; }
.thamso-table .thamso-in[readonly], .thamso-table .thamso-in:disabled { background: #F6F2EC; color: #3B3128; border-color: #EDE5DA; cursor: default; opacity: 1; }
.thamso-table .thamso-in[readonly]:focus { outline: none; }
.thamso-table .thamso-in::placeholder { color: #8A7355; font-weight: 600; font-style: italic; }
.thamso-hau { color: #8A7355; font-size: 11.5px; min-width: 10px; }

/* Trạng thái dòng. */
.thamso-table tr.thamso-khac .thamso-td-label { box-shadow: inset 3px 0 0 #F59E0B; }
.thamso-table tr.thamso-khac .thamso-td-md { color: #B45309; }
.thamso-table tr.thamso-dan-xuat .thamso-td-label { color: #6B5B4B; font-weight: 500; }
.thamso-table tr.thamso-loi td { background: #FDF2F2; }
.thamso-table tr.thamso-loi .thamso-in { border-color: #F04438; color: #B42318; }
.thamso-table tr.thamso-loi .thamso-msg { display: block; color: #B42318; font-weight: 700; }
.thamso-msg:empty { display: none; }

@media (max-width: 720px) {
    .thamso-note { flex-direction: column; align-items: stretch; }
    .thamso-td-label { min-width: 150px; }
    .thamso-td-hint { min-width: 160px; }
    .thamso-td-in { min-width: 120px; width: 130px; }
    .pr-wrap.thamso-wrap { overflow-x: auto; }
}
