/* THRS V9 — System-Wide Dark & Light Contrast / 2026-11-05
 * Production-safe presentation-only layer.
 * Restores readable inline neutral colors in HR operational screens.
 * Preserves role rules, data, layouts, state colors, and chart series.
 */
html[data-theme="light"] .thrs-main-shell .thrs-page{
  --v9-text:#102a49;
  --v9-muted:#52667e;
  --v9-surface:#fff;
  --v9-raised:#f6f9fd;
  --v9-outline:#ccd8e6;
  --v9-focus:#946a18;
}
html[data-theme="dark"] .thrs-main-shell .thrs-page{
  --v9-text:#edf5ff;
  --v9-muted:#c1d2e5;
  --v9-surface:#15315b;
  --v9-raised:#102944;
  --v9-outline:#6686a8;
  --v9-focus:#f1cf81;
}
/* Dark-mode selectors for real neutral inline foreground and surfaces follow. */

/* Scoped neutral inline styles generated from audited HR pages. */
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(
  [style^="color: rgb(15, 23, 42)"],
  [style*="; color: rgb(15, 23, 42)"],
  [style^="color: #0f172a"],
  [style*="; color: #0f172a"],
  [style^="color: rgb(17, 24, 39)"],
  [style*="; color: rgb(17, 24, 39)"],
  [style^="color: #111827"],
  [style*="; color: #111827"],
  [style^="color: rgb(30, 41, 59)"],
  [style*="; color: rgb(30, 41, 59)"],
  [style^="color: #1e293b"],
  [style*="; color: #1e293b"],
  [style^="color: rgb(31, 41, 55)"],
  [style*="; color: rgb(31, 41, 55)"],
  [style^="color: #1f2937"],
  [style*="; color: #1f2937"],
  [style^="color: rgb(51, 65, 85)"],
  [style*="; color: rgb(51, 65, 85)"],
  [style^="color: #334155"],
  [style*="; color: #334155"],
  [style^="color: rgb(55, 65, 81)"],
  [style*="; color: rgb(55, 65, 81)"],
  [style^="color: #374151"],
  [style*="; color: #374151"],
  [style^="color: rgb(71, 85, 105)"],
  [style*="; color: rgb(71, 85, 105)"],
  [style^="color: #475569"],
  [style*="; color: #475569"],
  [style^="color: rgb(10, 31, 61)"],
  [style*="; color: rgb(10, 31, 61)"],
  [style^="color: #0a1f3d"],
  [style*="; color: #0a1f3d"],
  [style^="color: rgb(15, 39, 71)"],
  [style*="; color: rgb(15, 39, 71)"],
  [style^="color: #0f2747"],
  [style*="; color: #0f2747"],
  [style^="color: rgb(26, 54, 93)"],
  [style*="; color: rgb(26, 54, 93)"],
  [style^="color: #1a365d"],
  [style*="; color: #1a365d"],
  [style^="color: rgb(26, 58, 92)"],
  [style*="; color: rgb(26, 58, 92)"],
  [style^="color: #1a3a5c"],
  [style*="; color: #1a3a5c"]
){color:var(--v9-text)!important;}
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(
  [style^="color: rgb(100, 116, 139)"],
  [style*="; color: rgb(100, 116, 139)"],
  [style^="color: #64748b"],
  [style*="; color: #64748b"],
  [style^="color: rgb(107, 114, 128)"],
  [style*="; color: rgb(107, 114, 128)"],
  [style^="color: #6b7280"],
  [style*="; color: #6b7280"],
  [style^="color: rgb(113, 128, 150)"],
  [style*="; color: rgb(113, 128, 150)"],
  [style^="color: #718096"],
  [style*="; color: #718096"],
  [style^="color: rgb(148, 163, 184)"],
  [style*="; color: rgb(148, 163, 184)"],
  [style^="color: #94a3b8"],
  [style*="; color: #94a3b8"],
  [style^="color: rgb(156, 163, 175)"],
  [style*="; color: rgb(156, 163, 175)"],
  [style^="color: #9ca3af"],
  [style*="; color: #9ca3af"]
){color:var(--v9-muted)!important;}
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(
  [style*="background: rgb(255, 255, 255)"],
  [style*="background-color: rgb(255, 255, 255)"],
  [style*="background: #ffffff"],
  [style*="background-color: #ffffff"],
  [style*="background: rgb(255, 255, 255)"],
  [style*="background-color: rgb(255, 255, 255)"],
  [style*="background: rgb(248, 250, 252)"],
  [style*="background-color: rgb(248, 250, 252)"],
  [style*="background: #f8fafc"],
  [style*="background-color: #f8fafc"],
  [style*="background: rgb(249, 250, 251)"],
  [style*="background-color: rgb(249, 250, 251)"],
  [style*="background: #f9fafb"],
  [style*="background-color: #f9fafb"],
  [style*="background: rgb(243, 244, 246)"],
  [style*="background-color: rgb(243, 244, 246)"],
  [style*="background: #f3f4f6"],
  [style*="background-color: #f3f4f6"],
  [style*="background: rgb(241, 245, 249)"],
  [style*="background-color: rgb(241, 245, 249)"],
  [style*="background: #f1f5f9"],
  [style*="background-color: #f1f5f9"]
){background:var(--v9-surface)!important;}
html[data-theme="light"] .thrs-main-shell .thrs-page :is(td,th,small,span,label,p):is([style^="color: rgb(148, 163, 184)"],[style*="; color: rgb(148, 163, 184)"],[style^="color: #94a3b8"],[style*="; color: #94a3b8"],[style^="color: rgb(156, 163, 175)"],[style*="; color: rgb(156, 163, 175)"],[style^="color: #9ca3af"],[style*="; color: #9ca3af"]){color:#52667e!important;}
html[data-theme="light"] .thrs-main-shell :is(.thrs-page-payroll,.thrs-page-team-reports) :is(span,strong,b,small)[style*="color: rgb(16, 185, 129)"]{color:#047857!important;}
html[data-theme="light"] .thrs-main-shell :is(.thrs-page-payroll,.thrs-page-team-reports) :is(span,strong,b,small)[style*="color: rgb(245, 158, 11)"]{color:#92400e!important;}
html[data-theme="light"] .thrs-main-shell :is(.thrs-page-payroll,.thrs-page-team-reports) :is(span,strong,b,small)[style*="color: rgb(239, 68, 68)"]{color:#b91c1c!important;}

/* The active employee/report hero gradients and semantic chart hues are excluded. */
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(
 .form-label,.form-group label,.thrs-rec-candidate-contact,.ws-employee-meta,
 .thrs-payroll-flow-step,.thrs-payroll-flow-step small
){
 color:var(--v9-text)!important;
}
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(.thrs-btn-secondary,.thrs-btn-outline){
 --thrs-btn-color:var(--v9-text);
 --thrs-btn-border:var(--v9-outline);
}
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(
 .thrs-payroll-flow-step,.thrs-recruitment-filter-card,
 .thrs-rec-v5-table-card,.thrs-attendance-chart-panel
){
 border-color:var(--v9-outline)!important;
}
/* Fix the explicitly light-only Performance tabs separator. */
html[data-theme="dark"] .thrs-page-performance > div[style*="border-bottom"]{
 border-bottom-color:var(--v9-outline)!important;
}
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(
 input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="file"]),
 select,textarea
){
 color-scheme:dark;
}
html[data-theme="light"] .thrs-main-shell .thrs-page :is(
 input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="file"]),
 select,textarea
){
 color-scheme:light;
}
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(input,textarea)::placeholder{
 color:#b8cbe1!important;
 opacity:1!important;
}
html[data-theme="light"] .thrs-main-shell .thrs-page :is(input,textarea)::placeholder{
 color:#596b84!important;
 opacity:1!important;
}
/* Muted text should not become washed-out in disabled and empty states. */
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(.empty-state,.pagination-info,.emp-stat-label){
 color:var(--v9-muted)!important;
}
html[data-theme="light"] .thrs-main-shell .thrs-page :is(.pagination-info,.emp-stat-label){
 color:#52667e!important;
}
/* Focus is high visibility without changing hit areas or interactive behavior. */
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(
 button,a,input,select,textarea,[role="tab"],[role="button"],[role="option"]
):focus-visible{
 outline:2px solid var(--v9-focus)!important;
 outline-offset:2px!important;
}
html[data-theme="light"] .thrs-main-shell .thrs-page :is(
 button,a,input,select,textarea,[role="tab"],[role="button"],[role="option"]
):focus-visible{
 outline:2px solid var(--v9-focus)!important;
 outline-offset:2px!important;
}
html[data-theme="dark"] .thrs-main-shell .thrs-page :is(.thrs-btn,.action-btn):disabled{
 opacity:.65;
}
/* Respect the screen reader's and OS's forced-color handling. */
@media(forced-colors:active){
 :is(html[data-theme="dark"],html[data-theme="light"]) .thrs-main-shell .thrs-page :is(button,a,input,select,textarea):focus-visible{
  outline-color:Highlight!important;
 }
}
