/* CPO-only Payscale Setup. Scoped to Recruitment Tracker theme. */
.pset { --pset-green:#166534; --pset-border:#dce5e0; --pset-muted:#64748b; display:grid;gap:16px;min-width:0 }
.pset * {box-sizing:border-box}
.pset :is(input,select,textarea){font:inherit}
.pset-top{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.pset-kpi{border:1px solid var(--pset-border);border-radius:12px;padding:15px 17px;background:white;min-width:0}
.pset-kpi span{display:block;font-size:11px;color:#67768a;font-weight:650;margin-bottom:8px}
.pset-kpi strong{font-size:21px;color:#204532;font-weight:750;display:block;overflow-wrap:anywhere}
.pset-kpi small{display:block;font-size:11px;color:#657581;margin-top:4px}
.pset-tabs{display:flex;flex-wrap:wrap;gap:5px;background:#edf3ef;border:1px solid #dce8e1;border-radius:11px;padding:5px;max-width:100%}
.pset-tabs button{border:0;border-radius:8px;padding:10px 14px;color:#4c6656;background:transparent;font-size:12px;font-weight:700;cursor:pointer}
.pset-tabs button[aria-selected=true]{background:white;color:var(--pset-green);box-shadow:0 1px 5px #18352418}
.pset-tabs button:focus-visible,.pset button:focus-visible{outline:3px solid #78b195;outline-offset:2px}
.pset-panel{background:white;border:1px solid var(--pset-border);border-radius:15px;min-width:0;overflow:hidden;box-shadow:0 2px 9px #0f172a06}
.pset-panel-head{background:linear-gradient(110deg,#eef6f1,#fff 84%);border-bottom:1px solid var(--pset-border);padding:17px 19px;display:flex;justify-content:space-between;gap:12px;align-items:start;flex-wrap:wrap}
.pset-panel-head h3{margin:0;color:#204a34;font-size:16px;font-weight:750}
.pset-panel-head p{margin:5px 0 0;color:#64748b;font-size:12px;line-height:1.55;max-width:750px}
.pset-panel-body{padding:19px;min-width:0}
.pset-section{border:1px solid #e2e9e5;border-radius:12px;margin-bottom:15px;background:#fff;overflow:hidden}
.pset-section h4{margin:0;background:#f2f8f4;border-bottom:1px solid #e1eae4;padding:12px 15px;color:#286449;font-size:13px;font-weight:700}
.pset-section-body{padding:15px}
.pset-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,190px),1fr));gap:12px}
.pset-grid label,.pset-editor label{display:grid;gap:6px;color:#475569;font-size:12px;font-weight:650;min-width:0;line-height:1.4}
.pset-grid :is(input,select,textarea),.pset-editor :is(input,select,textarea),.pset-filter input,.pset-filter select{width:100%;max-width:100%;min-width:0;border:1px solid #cdd6df;border-radius:9px;padding:9px 11px;min-height:40px;color:#172033;background:#fff}
.pset :is(input,select,textarea):focus-visible{outline:0;border-color:#619778;box-shadow:0 0 0 3px #52856a20}
.pset-controls{display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:11px;margin:15px 0}
.pset-controls .pset-filter{flex:1 1 210px;min-width:170px}
.pset-actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin-top:15px}
.pset-editor{padding:16px;border:1px solid #d5e7dd;background:#f7fbf8;border-radius:12px;margin:15px 0}
.pset-editor h4{margin:0 0 12px;font-size:14px;color:#225637}
.pset-editor .pset-grid{margin-bottom:12px}
.pset-note{font-size:12px;color:#617486;line-height:1.6;margin:9px 0}
.pset-warning{margin:0 0 12px;padding:11px 13px;border:1px solid #f0dba7;border-radius:10px;background:#fff9e9;color:#82551b;font-size:12px;line-height:1.6}
.pset-good{margin:0 0 12px;padding:11px 13px;border:1px solid #c9e8d6;border-radius:10px;background:#eef9f2;color:#166534;font-size:12px;line-height:1.6}
.pset-status{display:inline-flex;align-items:center;border-radius:99px;padding:4px 8px;font-size:11px;font-weight:700;background:#f1f5f9;color:#475569;white-space:nowrap}
.pset-status[data-s=active],.pset-status[data-s=approved]{background:#ecfdf5;color:#166534}
.pset-status[data-s=inactive],.pset-status[data-s=needs_review]{background:#fff4d6;color:#805100}
.pset-scroll{overflow:auto;max-width:100%}
.pset-table{width:100%;border-collapse:collapse;font-size:12px;line-height:1.45}
.pset-table th{background:#f8fafc;padding:11px 12px;border-bottom:1px solid #dce5e0;color:#617287;text-align:left;font-size:11px;font-weight:750;white-space:nowrap}
.pset-table td{border-bottom:1px solid #e9eef1;padding:10px 12px;color:#334155;vertical-align:middle}
.pset-table tbody tr:hover{background:#fcfdfc}
.pset-table tbody tr.pset-editing-row{background:#f4f8f6}
.pset-table tbody tr.pset-inline-editor-row:hover{background:#f8fafb}
.pset-table .pset-inline-editor-row>td{background:#f8fafb;padding:14px 16px 17px;border-bottom:1px solid #cedbd5}
.pset-table .pset-inline-editor-row .pset-editor{margin:0;border-color:#dce6e3;background:#fff;box-shadow:0 3px 12px rgba(15,23,42,.05)}
.pset-table .pset-inline-editor-row .pset-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
@media(max-width:720px){.pset-table .pset-inline-editor-row .pset-grid{grid-template-columns:1fr}}
.pset-table input{min-height:34px}
.pset-table--compact{max-width:100%}
.pset-table--compact td{min-width:82px}
.pset-table--compact :is(input,select){min-width:70px;width:100%;padding:7px 8px;min-height:36px}
.pset-table .pset-action-cell{white-space:nowrap}
.pset-table .pset-action-cell button{font-size:11px}
.pset-empty{text-align:center;color:#7b8795;padding:22px;font-size:12px}
.pset-feedback{min-height:20px;margin-bottom:2px;font-size:12px}
.pset-feedback[data-type=error]{padding:11px 13px;background:#fef2f2;border:1px solid #fecaca;color:#9a1e29;border-radius:9px}
.pset-feedback[data-type=success]{padding:11px 13px;background:#eef9f2;border:1px solid #c9e8d6;color:#166534;border-radius:9px}
.pset-formula{font-size:13px;line-height:1.7;color:#334155;background:#f8fafc;border:1px solid #e2e8f0;border-radius:10px;padding:13px 15px}
.pset-formula b{color:#21533a}
.pset-preview{padding:15px;border:1px solid #d5e6dc;border-radius:12px;background:#f2f8f4;font-size:13px;color:#205038;line-height:1.7}
.pset-preview strong{font-size:20px;font-variant-numeric:tabular-nums}
.pset-history{width:100%}
.pset-history details{border-bottom:1px solid #e2e9ef;padding:12px}
.pset-history summary{display:flex;flex-wrap:wrap;justify-content:space-between;gap:9px;cursor:pointer;color:#334155;font-size:12px}
.pset-history pre{background:#f8fafc;padding:11px;border-radius:9px;white-space:pre-wrap;overflow-wrap:anywhere;max-height:280px;overflow:auto;font-size:11px}
.pset :is(button,.btn):disabled{opacity:.53;cursor:not-allowed}
@media(max-width:920px){.pset-top{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:620px){.pset-top{grid-template-columns:1fr 1fr}.pset-panel-body{padding:12px}.pset-panel-head{padding:14px}.pset-tabs button{flex:1 1 42%;text-align:center}.pset-grid{grid-template-columns:1fr}.pset-section-body{padding:12px}.pset-controls{align-items:stretch}.pset-kpi{padding:12px}.pset-kpi strong{font-size:17px}}


/* CPO Payscale Setup — Excel review workflow */
.pset-excel-toolbar{display:flex;justify-content:space-between;gap:15px;align-items:center;flex-wrap:wrap;
 padding:14px 16px;margin:0 0 13px;border:1px solid #cfe3d6;background:linear-gradient(120deg,#f6fbf7,#eff7f1);
 border-radius:12px;color:#22523c}
.pset-excel-heading{display:grid;gap:4px;min-width:220px}
.pset-excel-heading b{font-size:13px;letter-spacing:.01em}
.pset-excel-heading small{font-size:11px;line-height:1.5;color:#5e796b}
.pset-excel-actions{display:flex;align-items:center;gap:9px;flex-wrap:wrap}
.pset-excel-actions .btn{margin:0;font-weight:650}
.pset-excel-upload{display:inline-flex;align-items:center;justify-content:center;cursor:pointer;position:relative;
 border-color:#2b6a4b!important;background:#206a43!important;color:white!important}
.pset-excel-upload input{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}
.pset-excel-upload:focus-within{outline:2px solid #459d69;outline-offset:2px}
.pset-import-preview{border:1px solid #d2e6da;background:#fff;border-radius:13px;padding:17px 18px;
 box-shadow:0 5px 21px #143c2110;margin:14px 0 20px}
.pset-import-top{display:flex;justify-content:space-between;gap:10px;align-items:flex-start}
.pset-import-top h3{font-size:14px;color:#1d533b;margin:0 0 5px}
.pset-import-top p{font-size:12px;line-height:1.55;color:#627b6c;margin:0}
.pset-import-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin:14px 0}
.pset-import-metrics>div{background:#f6faf7;border:1px solid #dfebe4;border-radius:10px;
 padding:12px 14px;display:grid;gap:4px}
.pset-import-metrics b{font-size:18px;color:#20583e;font-variant-numeric:tabular-nums}
.pset-import-metrics span{font-size:11px;color:#657d6d}
.pset-import-scroll{max-height:37vh;overflow:auto;margin:12px 0;border:1px solid #e4e9ed;border-radius:9px}
.pset-import-rejected{color:#ae2b35;font-weight:750}
.pset-import-changed{color:#94650b;font-weight:750}
.pset-import-added{color:#177043;font-weight:750}
.pset-import-confirm{display:flex;justify-content:space-between;gap:15px;align-items:end;flex-wrap:wrap;margin:14px 0 7px}
.pset-import-confirm label{display:grid;gap:6px;flex:1 1 310px;min-width:210px;font-size:12px;color:#435a50;font-weight:650}
.pset-import-confirm input{border:1px solid #cddbd2;border-radius:9px;height:39px;padding:9px 12px;width:100%}
.pset-import-confirm button{white-space:nowrap;min-height:39px}
.pset-import-error{background:#fff2f2;border:1px solid #f4b8b8;border-radius:9px;padding:11px 13px;color:#9d3131;font-size:12px}
@media(max-width:670px){.pset-excel-actions{width:100%}.pset-excel-actions>*{flex:1 1 45%}
 .pset-import-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}
 .pset-import-top{flex-direction:column}}

/* CPO catalog and benchmark editors: fixed, centered and keyboard-friendly. */
.pset-modal-backdrop{position:fixed;inset:0;z-index:180;display:flex;align-items:center;justify-content:center;background:rgba(15,23,42,.58);padding:20px;overflow:auto}
.pset-modal-card{width:min(750px,96vw);max-height:min(86vh,920px);overflow:auto;background:#fff;border:1px solid #dce6e0;border-radius:16px;box-shadow:0 22px 65px rgba(15,23,42,.25);padding:24px}
.pset-modal-card.pset-benchmark-modal{width:min(900px,96vw)}
.pset-modal-card .pset-editor{padding:0;border:0;background:transparent;margin:0;box-shadow:none}
.pset-modal-card .pset-dialog-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px}
.pset-modal-card .pset-dialog-title h4{font-size:17px;margin:0}
.pset-modal-card .pset-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
.pset-modal-card .pset-actions{justify-content:flex-end;flex-wrap:wrap}
.pset-modal-card .pset-editor>.pset-note{display:grid;gap:5px;font-size:12px;color:#475569}
.pset-modal-card [name=reason]{width:100%;margin-top:4px}
.pset-modal-card [data-pset="cancelEditor"]:first-of-type{min-width:34px}
.pset-modal-card #pset-editor-feedback:not(:empty){color:#b91c1c;padding:8px 0}
.pset .btn.danger{background:#fff1f2;border-color:#fecdd3;color:#9f1239}
.pset .btn.danger:hover{background:#ffe4e6}
@media(max-width:660px){.pset-modal-backdrop{align-items:flex-start;padding:10px}.pset-modal-card{padding:16px;max-height:94vh}.pset-modal-card .pset-grid{grid-template-columns:1fr}}


/* Sorting controls for CPO-owned catalogs; the underlying approval state is retained. */
.pset-controls .pset-sort-control{flex:0 1 240px;min-width:175px}
.pset-controls .pset-sort-control>label{display:grid;gap:4px;margin:0;font-size:11px;font-weight:700;color:#516876}
.pset-controls .pset-sort-control select{width:100%;max-width:100%;min-height:38px;padding:7px 10px;background:#fff}
.pset-table .pset-sort-heading{display:inline-flex;align-items:center;gap:6px;background:transparent;border:none;padding:0;margin:0;cursor:pointer;color:inherit;font:inherit;font-weight:750;white-space:nowrap}
.pset-table .pset-sort-heading:hover{color:#135c3d;text-decoration:underline}
.pset-table .pset-sort-heading:focus-visible{outline:2px solid #166534;outline-offset:3px;border-radius:3px}
.pset-table .pset-sort-heading span{font-size:12px;color:#537f69}
.pset-table .pset-archived-row{background:#fafafa;color:#64748b}
.pset-table .pset-archived-hint{display:block;color:#64748b;font-size:10px;font-weight:500;margin-top:3px}
@media(max-width:720px){
 .pset-controls .pset-sort-control{flex:1 1 160px}
 .pset-table .pset-sort-heading{gap:3px}
}
