/* Tenant appearance overrides loaded after feature stylesheets. */

/* Core page typography and actions */
.app-page-header h1,
.dashboard-card h2,
.dashboard-alert-card h2,
.dashboard-alert-counts strong,
.fxl-title,
.tile-name,
.back,
button.link,
.grid.order .code,
.tl-summary,
.login-brand,
.hist-date,
.fx-photo,
.ol-code,
.fx-hist .hd,
.fx-department-health-heading h3,
.fx-department-health-row strong,
.fx-health-explain summary,
.fx-health-factor > strong,
.vs-heading h3,
.vs-facts strong,
.oc-label,
.oc-branch-banner,
.oc-branch-banner strong,
.oc-line .oc-product strong,
.sc-progress,
.sc-suggested,
.sc-department,
.sc-facts strong,
.sc-count-grid label,
.sc-history-row strong,
.ch-type,
.ch-row strong,
.scr-metric strong,
.scr-table th {
    color: var(--nexus-primary, #1F3864) !important;
}

.app-eyebrow,
.dashboard-card-kicker,
.dashboard-card-action,
.dashboard-alert-kicker,
.panel h3,
a.card-link h3,
.card-go,
.fx-card h3,
.sc-heading h3,
.ch-section h3,
.oc-card h3,
.scr-section h2,
.scr-section h3 {
    color: var(--nexus-accent, #EE7326) !important;
}

/* Primary controls */
.app-button-primary,
button.primary,
.btn-primary,
.fx-btn.primary,
.oc-primary,
.sc-primary,
.vs-save,
.dashboard-alert-card > a,
.sc-review,
.order-cta a {
    background-color: var(--nexus-primary, #1F3864) !important;
    border-color: var(--nexus-primary, #1F3864) !important;
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

/* Field navigation and interactive selections */
.fx-head,
.fxl-filters button.on,
.fx-tabs button.on,
.fx-photo-button.camera {
    background-color: var(--nexus-primary, #1F3864) !important;
    border-color: var(--nexus-primary, #1F3864) !important;
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

.fxl-filters button,
.fx-tabs button,
.fx-order-department span,
.fx-order-department select,
.fx-photo-heading,
.fx-location-details summary,
.fx-location-summary strong,
.fx-evidence strong,
.fx-resolution-card > strong,
.fx-issue-classification label {
    color: var(--nexus-primary, #1F3864) !important;
}

/* Report heroes, table headings and export controls */
.scr-hero,
.scr-header,
.stock-count-report-header,
.report-hero {
    background-color: var(--nexus-primary, #1F3864) !important;
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

.scr-hero h1,
.scr-header h1,
.stock-count-report-header h1,
.report-hero h1 {
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

.scr-table thead,
.scr-table-header,
.stock-count-table thead {
    background-color: var(--nexus-primary, #1F3864) !important;
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

/* Grouped navigation */
.nav-children {
    border-left-color: var(--nexus-accent, #EE7326) !important;
}
.sidebar .nav-children a.active {
    background-color: var(--nexus-primary, #1F3864) !important;
    color: var(--nexus-primary-text, #FFFFFF) !important;
    box-shadow: inset 3px 0 0 var(--nexus-accent, #EE7326) !important;
}
.mobile-nav-bar {
    background-color: var(--nexus-sidebar, #1F3864) !important;
    color: var(--nexus-sidebar-text, #FFFFFF) !important;
}
.mobile-nav-bar span {
    color: var(--nexus-accent, #EE7326) !important;
}

/* Focus colour */
.oc-qty input[type="number"]:focus,
input:focus,
select:focus,
textarea:focus {
    border-color: var(--nexus-accent, #EE7326) !important;
}

/* Tenant appearance completion: shared CRM, lists, grids and workspaces */

/* Section labels and branded text links */
.app-eyebrow,
.app-page .app-eyebrow,
.accounts-page .app-eyebrow,
.stores-page .app-eyebrow,
.field-page .app-eyebrow,
.app-link,
.app-table a,
.app-grid a,
.grid a,
.accounts-page a:not(.app-button):not(.btn),
.account-open,
.open-link {
    color: var(--nexus-accent, #EE7326) !important;
}

/* Main titles and branded headings */
.app-page-header h1,
.accounts-page h1,
.stores-page h1,
.field-page h1,
.app-card h2,
.app-card h3,
.app-panel h2,
.app-panel h3 {
    color: var(--nexus-primary, #1F3864) !important;
}

/* Shared table and grid headers */
.app-table thead,
.app-table thead tr,
.app-table thead th,
.app-grid thead,
.app-grid thead tr,
.app-grid thead th,
.grid thead,
.grid thead tr,
.grid thead th,
.accounts-table thead,
.accounts-table thead tr,
.accounts-table thead th,
.table-header,
.table-head,
[role="table"] [role="rowheader"] {
    background-color: var(--nexus-primary, #1F3864) !important;
    border-color: var(--nexus-primary, #1F3864) !important;
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

/* Keep links inside themed header rows readable */
.app-table thead a,
.app-grid thead a,
.grid thead a,
.accounts-table thead a {
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

/* Common selected/active controls */
.app-tabs .active,
.app-tab.active,
.segmented-control .active,
.pagination .active,
.pager .active,
.app-chip.active,
.filter-chip.active {
    background-color: var(--nexus-primary, #1F3864) !important;
    border-color: var(--nexus-primary, #1F3864) !important;
    color: var(--nexus-primary-text, #FFFFFF) !important;
}

/* Branded badges only. Semantic success/warning/error badges remain untouched. */
.app-badge-primary,
.app-pill-primary,
.count-badge,
.total-badge {
    color: var(--nexus-primary, #1F3864) !important;
    background: color-mix(in srgb, var(--nexus-primary, #1F3864) 10%, white 90%) !important;
}

/* Search and form focus should use the tenant accent instead of legacy orange. */
.app-search input:focus,
.app-filter input:focus,
.app-filter select:focus,
.search-panel input:focus,
.search-panel select:focus {
    outline-color: color-mix(in srgb, var(--nexus-accent, #EE7326) 30%, transparent) !important;
    border-color: var(--nexus-accent, #EE7326) !important;
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--nexus-accent, #EE7326) 16%, transparent) !important;
}

/* Final legacy-orange cleanup */
.app-eyebrow,
.accounts-page .app-eyebrow,
.accounts-page [class*="eyebrow"],
.accounts-page [class*="kicker"],
.accounts-page [class*="open"],
.accounts-page tbody a,
.accounts-page table tbody a,
.accounts-page .app-table tbody a,
.accounts-page .grid tbody a {
  color: var(--nexus-accent, #EE7326) !important;
}
.accounts-page table thead,
.accounts-page table thead tr,
.accounts-page table thead th,
.accounts-page .app-table thead,
.accounts-page .app-table thead tr,
.accounts-page .app-table thead th,
.accounts-page .grid thead,
.accounts-page .grid thead tr,
.accounts-page .grid thead th {
  background: var(--nexus-primary, #1F3864) !important;
  border-color: var(--nexus-primary, #1F3864) !important;
  color: var(--nexus-primary-text, #FFFFFF) !important;
}
.accounts-page input:focus,
.accounts-page select:focus {
  border-color: var(--nexus-accent, #EE7326) !important;
  outline-color: var(--nexus-accent, #EE7326) !important;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--nexus-accent, #EE7326) 18%, transparent) !important;
}

