/*! RLT */
/* Appearance controls are shared by signed-in and public pages. Dark remains the default. */
html .theme-toggle,html body.application-shell .theme-toggle{
  display:inline-flex;align-items:center;justify-content:center;gap:9px;flex:0 0 auto;
  min-height:44px;padding:9px 12px;border:1px solid #627c93;border-radius:999px;
  background:#172d46;color:#eef5ff;font:600 .8125rem/1.4 ui-sans-serif,system-ui,sans-serif;
  cursor:pointer;white-space:nowrap;box-shadow:none;
}
html .theme-toggle[hidden]{display:none}
html .theme-toggle:hover,html body.application-shell .theme-toggle:hover{background:#213e5d;color:#fff;border-color:#77d5ff}
html .theme-toggle:focus-visible,html body.application-shell .theme-toggle:focus-visible{outline:3px solid #77d5ff;outline-offset:3px}
.theme-toggle-track{display:inline-block;position:relative;flex:0 0 30px;width:30px;height:18px;background:#61788f;border-radius:999px}
.theme-toggle-track::after{content:"";position:absolute;top:3px;left:3px;width:12px;height:12px;background:#fff;border-radius:50%}
.theme-toggle[aria-checked=true] .theme-toggle-track{background:#1468d4}
.theme-toggle[aria-checked=true] .theme-toggle-track::after{left:15px}
body.application-shell .accountbar{flex-wrap:wrap;gap:12px}
body.application-shell .account-identity{min-width:0}

/* Light palette. Scope every override so existing dark screens retain their styling. */
html[data-theme=light],html[data-theme=light] body.application-shell,html[data-theme=light] body.application-shell:not(.public-layout){
  color-scheme:light;--ink:#17263d;--muted:#4e6278;--paper:#f3f6fb;--dark:#e9f0f8;
  --surface:#ffffff;--surface-raised:#eaf1f9;--line:#c6d3e2;--accent:#07649c;
  --green:#087457;--brand-link:#075d94;--brand-brass:#1468d4;
  --gauge-blue:#087bad;--gauge-green:#087457;--gauge-amber:#956008;
  --navy:#eaf1f9;--teal:#087457;--gold:#80590f;
  background:var(--paper);color:var(--ink);
}
html[data-theme=light] body.application-shell a{color:var(--brand-link)}
html[data-theme=light] body.application-shell :is(.kicker,.eyeline,label,legend,summary){color:#37536e}
html[data-theme=light] body.application-shell :is(a,button,input,select,textarea,summary):focus-visible{outline-color:#1266ae}
html[data-theme=light] body.application-shell :is(button,.button){background:#eaf1f9;color:#223e5b;border-color:#9db2c8}
html[data-theme=light] body.application-shell :is(button,.button):hover{background:#dce9f6;color:#102d49;border-color:#357bb5}
html[data-theme=light] body.application-shell :is(button,.button).primary{background:#1468d4;color:#fff;border-color:#1468d4}
html[data-theme=light] body.application-shell :is(button,.button).primary:hover{background:#1056b2}
html[data-theme=light] body.application-shell :is(input,select,textarea){background:#fff;color:var(--ink);border-color:#9db2c8}
html[data-theme=light] body.application-shell :is(input,textarea)::placeholder{color:#5b6f84;opacity:1}
html[data-theme=light] body.application-shell :is(input[type=checkbox],input[type=radio],progress){accent-color:#1468d4}
html[data-theme=light] body.application-shell :is(.rail,.rail nav){background:#fff;border-color:var(--line)}
html[data-theme=light] body.application-shell .brand-wordmark{color:var(--ink)}
html[data-theme=light] body.application-shell :is(.brand-tagline,.account-identity small){color:var(--muted)}
html[data-theme=light] body.application-shell :is(.rail nav a,.nav-group summary){color:#37536e}
html[data-theme=light] body.application-shell :is(.rail nav a[aria-current=page],.nav-group[data-current=true]>summary){color:#084f88;background:#e3effc;box-shadow:inset 0 -2px #1468d4}
html[data-theme=light] body.application-shell :is(.rail nav a:hover,.nav-group summary:hover,.nav-group[open]>summary){background:#eaf1f9;color:#17263d}
html[data-theme=light] body.application-shell .nav-dropdown{background:#fff;border-color:var(--line);box-shadow:0 14px 32px #17263d22}
html[data-theme=light] body.application-shell .rail .nav-dropdown a{color:#223e5b}
html[data-theme=light] body.application-shell .rail .nav-dropdown a:hover{background:#e3effc}
html[data-theme=light] body.application-shell #account-actions .header-profile{color:#223e5b;border-color:#9db2c8}
html[data-theme=light] body.application-shell #account-actions .header-profile:hover{background:#e3effc}
html[data-theme=light] body.application-shell #account-actions :is(button,.button:not(.primary)){background:transparent;color:#223e5b;border-color:#9db2c8}
html[data-theme=light] body.application-shell #account-actions :is(button,.button:not(.primary)):hover{background:#dce9f6}
html[data-theme=light] .theme-toggle,html[data-theme=light] body.application-shell .theme-toggle{color:#223e5b;background:#eaf1f9;border-color:#9db2c8}
html[data-theme=light] .theme-toggle:hover,html[data-theme=light] body.application-shell .theme-toggle:hover{color:#102d49;background:#dce9f6;border-color:#357bb5}
html[data-theme=light] .theme-toggle:focus-visible{outline-color:#1266ae}

/* Shared surfaces: dashboards, Academy, work orders, financials and forms. */
html[data-theme=light] body.application-shell :is(.empty,.home-empty,details,.callout,.home-action,.dispatch-pulse,.assignment-row,.deliverable,.attendance-panel,.candidate,.region-row,.project-health-card,.gauge-card,.cost-stats article,.finance-card,.candidate-finance,.lesson-body,.lesson-content,.lesson-card,.exam-question,.question,.module-card,.module,.stat,.chapter,.lesson-nav,.scorecard,.choice,.task button,.alert-row button,.verify-item button,.search){background:var(--surface);color:var(--ink);border-color:var(--line)}
html[data-theme=light] body.application-shell .callout{border-left-color:#1468d4}
html[data-theme=light] body.application-shell :is(.study-section,.pricing-faq,.pricing-note){background:var(--surface);color:var(--ink);border-color:var(--line)}
html[data-theme=light] body.application-shell .learning{background:var(--paper);border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.metrics .metric strong,.cost-metric strong){color:var(--ink)}
html[data-theme=light] body.application-shell .cost-alert{background:#fff3d9;color:#76500d;border-color:#d4b57c}
html[data-theme=light] body.application-shell :is(.team-share,.team-incoming,.free-plan,.price-card.featured,.attendance-exception-form,.quiz,.quiz button.correct,.quiz button.wrong){background:#eaf1f9!important;color:var(--ink)!important;border-color:var(--line)!important}
html[data-theme=light] body.application-shell :is(.cost-metric,.candidate-evidence,.team-share,.free-plan,.free-plan p,.price-card>p,.price,.price-unit,.price-card ul,.pricing-note,.pricing-faq p,.workshop-facts p,.workshop-registrations span,.lesson-list){color:var(--ink)}
html[data-theme=light] body.application-shell :is(.rubric th,.status-key span,.chips span,.packet){background:#eaf1f9;color:#223e5b}
html[data-theme=light] body.application-shell :is(.status-badge,.pill,.status-chip,.attendance-state){color:#164f79;background:#e8f3fc;border-color:#a6c5df}
html[data-theme=light] body.application-shell :is(.status-chip.success,.attendance-state.is-in){color:#146043;background:#e6f5ed;border-color:#8cbea6}
html[data-theme=light] body.application-shell .status-chip.warning{color:#76500d;background:#fff3d9;border-color:#d4b57c}
html[data-theme=light] body.application-shell .status-chip.danger{color:#9a2d3b;background:#fcebf0;border-color:#d7a0ab}
html[data-theme=light] body.application-shell .error{color:#ac2438}
html[data-theme=light] body.application-shell table{background:#fff;color:var(--ink)}
html[data-theme=light] body.application-shell th{background:#eaf1f9;color:#223e5b}
html[data-theme=light] body.application-shell :is(td,th,.home-list li,.attendance-visit-heading,.attendance-points){border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.home-controls label,.home-controls select,.metric-caption,.metric-note,.home-list li span,.attendance-panel p,.home-action>span,.current-work ul){color:var(--muted)}
html[data-theme=light] body.application-shell .professional-dashboard #dashboard-refresh{color:#164f79;background:#eaf1f9}
html[data-theme=light] body.application-shell :is(.home-metric:nth-child(n),.metric-card){background:#fff;color:var(--ink);border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.home-metric:hover,.metric-card:hover,.gauge-card:hover){background:#f5f9ff;border-color:#357bb5}
html[data-theme=light] body.application-shell .home-metric .metric-caption{color:var(--muted)}
html[data-theme=light] body.application-shell .home-metric strong{color:var(--ink)}
html[data-theme=light] body.application-shell .metric-arrow{color:#1266ae}
html[data-theme=light] body.application-shell .metric-card.is-warning{background:#fff8e9;border-color:#d4b57c;box-shadow:inset 3px 0 #b98222}
html[data-theme=light] body.application-shell .metric-card.is-warning .metric-value{color:#76500d}
html[data-theme=light] body.application-shell .metric-card.is-success .metric-value{color:#146043}
html[data-theme=light] body.application-shell .attention-panel{background:#fff8e9;border-color:#d4b57c}
html[data-theme=light] body.application-shell :is(.attention-count,.attention-icon,.attendance-exception,.candidate ul){color:#76500d}
html[data-theme=light] body.application-shell .attention-panel li+li{border-color:#e3d1af}
html[data-theme=light] body.application-shell .attention-panel.is-clear{background:#e6f5ed;border-color:#8cbea6}
html[data-theme=light] body.application-shell .attention-panel.is-clear .attention-count{color:#146043}
html[data-theme=light] body.application-shell .gauge-track{stroke:#dce5ef}
html[data-theme=light] body.application-shell .home-action strong{color:var(--brand-link)}
html[data-theme=light] body.application-shell :is(.coverage-meter span,.coverage-meter strong small){color:var(--muted)}
html[data-theme=light] body.application-shell .dispatch-pulse .button{color:#223e5b!important;border-color:#9db2c8!important;background:#eaf1f9}
html[data-theme=light] body.application-shell .dispatch-pulse .button:hover{background:#dce9f6}
html[data-theme=light] body.application-shell .lesson-nav a.active{background:#e3effc;color:#084f88;border-color:#9cbcdf}
html[data-theme=light] body.application-shell .home-controls .role-preview-control{border-color:var(--line)}
html[data-theme=light] body.application-shell .current-work{background:linear-gradient(110deg,#e7f2fc,#fff);border-color:#a6c5df}
/* The Academy statistics wrapper stays transparent in both modes. */
html[data-theme=light] body.application-shell .academy-stats{background:transparent}

/* Dispatch calendar and map. Keep source map colors in light mode. */
html[data-theme=light] body.application-shell :is(.schedule-board,.schedule-day){background:#fff;border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.board-title,.schedule-day>header,.status-legend){background:#eaf1f9;color:#37536e;border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.board-date,.schedule-vacant,.schedule-job .schedule-time){color:var(--muted)}
html[data-theme=light] body.application-shell :is(.schedule-day>header strong,.schedule-job strong){color:var(--ink)}
html[data-theme=light] body.application-shell .schedule-job{background:#e8f3fc;color:#164f79;border-color:#a6c5df;border-left-color:#1676ba}
html[data-theme=light] body.application-shell .schedule-job.tone-amber{background:#fff3d9;color:#76500d;border-color:#d4b57c;border-left-color:#b98222}
html[data-theme=light] body.application-shell .schedule-job.tone-purple{background:#f0edff;color:#564188;border-color:#b7acd8;border-left-color:#7556b5}
html[data-theme=light] body.application-shell .schedule-job.tone-green{background:#e6f5ed;color:#146043;border-color:#8cbea6;border-left-color:#188258}
html[data-theme=light] body.application-shell :is(.schedule-job>span,.status-legend span){color:var(--muted)}
html[data-theme=light] body.application-shell .schedule-job .schedule-status{color:#164f79}
html[data-theme=light] body.application-shell .schedule-job.tone-amber .schedule-status{color:#76500d}
html[data-theme=light] body.application-shell .schedule-job.tone-green .schedule-status{color:#146043}
html[data-theme=light] body.application-shell .candidate>.status-chip.warning{color:#76500d;background:#fff3d9;border-color:#d4b57c}
html[data-theme=light] body.application-shell .candidate>.status-chip.success{color:#146043;background:#e6f5ed;border-color:#8cbea6}
html[data-theme=light] body.application-shell .dispatch-tabs{background:#eaf1f9;border-color:var(--line)}
html[data-theme=light] body.application-shell .dispatch-tabs label{color:var(--muted)}
html[data-theme=light] body.application-shell .dispatch-tabs button{background:transparent;color:#37536e}
html[data-theme=light] body.application-shell .dispatch-tabs button.primary{background:#e3effc;color:#084f88;border-color:#9cbcdf;box-shadow:inset 0 -2px #1468d4}
html[data-theme=light] body.application-shell #dispatch-map{background:#eaf1f9;border-color:#a6c5df}
html[data-theme=light] #dispatch-map .leaflet-tile-pane{filter:none}
html[data-theme=light] #dispatch-map :is(.leaflet-bar a,.leaflet-popup-content-wrapper,.leaflet-popup-tip,.leaflet-control-attribution){background:#fff;color:var(--ink);border-color:var(--line)}
html[data-theme=light] body.application-shell .operations-workspace .dispatch-card .status-badge{color:#164f79;background:#e8f3fc;border-color:#a6c5df}
html[data-theme=light] body.application-shell .operations-workspace .dispatch-card.tone-amber .status-badge{color:#76500d;background:#fff3d9;border-color:#d4b57c}
html[data-theme=light] body.application-shell .operations-workspace .dispatch-card.tone-green .status-badge{color:#146043;background:#e6f5ed;border-color:#8cbea6}

/* Technician portfolios and the work order hub use the same shared palette. */
html[data-theme=light] body.application-shell :is(.profile-head,.technician-profile .profile-head,.project-hub .hub-head){background:linear-gradient(115deg,#e3effc,#fff);border-color:#a6c5df;box-shadow:0 10px 28px #17263d0c}
html[data-theme=light] body.application-shell :is(.profile-head>.card,.technician-profile .profile-contact,.technician-profile .profile-sidebar .card,.technician-profile .proof-card){background:#fff!important;color:var(--ink);border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.technician-profile .profile-panel,.technician-profile .profile-credential,.technician-profile .profile-stats .metric-card,.project-hub .hub-panel,.project-hub .hub-record,.project-hub .hub-plan-panel){background:#fff;color:var(--ink);border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.technician-profile .profile-nav,.project-hub .hub-tabs,.project-hub .hub-summary,.technician-profile .proof-photos figure,.technician-profile .proof-photos img){background:#eaf1f9;border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.technician-profile .profile-nav button,.project-hub .hub-tabs button){background:transparent;color:#223e5b}
html[data-theme=light] body.application-shell :is(.technician-profile .profile-nav button:hover,.technician-profile .profile-nav button:focus-visible,.project-hub .hub-tabs button:hover,.project-hub .hub-tabs button[aria-current=page]){background:#dce9f6;color:#084f88}
html[data-theme=light] body.application-shell :is(.technician-profile>a:first-child,.technician-profile .profile-copy .kicker,.technician-profile .proof-card .kicker,.technician-profile .portrait-settings summary,.project-hub .hub-panel summary,.project-hub .hub-summary strong){color:var(--brand-link)}
html[data-theme=light] body.application-shell :is(.technician-profile .profile-copy .intro,.technician-profile .profile-panel>h2,.project-hub .hub-facts){color:var(--ink)}
html[data-theme=light] body.application-shell :is(.technician-profile .profile-copy p,.technician-profile .profile-panel>p,.technician-profile .profile-sidebar .card p,.technician-profile .profile-credential p,.technician-profile .profile-credential small,.technician-profile .proof-card>p.preserve-lines,.technician-profile .proof-photos figcaption,.technician-profile .history-entry span,.project-hub .hub-head p,.project-hub .hub-summary span,.project-hub .hub-record small){color:var(--muted);border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.technician-profile .profile-contact>strong,.technician-profile #profile-credentials .status-badge,.technician-profile .proof-card .status-badge){background:#e8f3fc;color:#164f79;border-color:#a6c5df}
html[data-theme=light] body.application-shell :is(.profile-nav,.technician-profile .portrait-settings,.technician-profile .history-entry){border-color:var(--line)}
html[data-theme=light] body.application-shell .hub-attention{background:#fff8e9;border-color:#d4b57c}
html[data-theme=light] body.application-shell .hub-attention-list a{background:#fff3d9;color:#76500d;border-color:#d4b57c}
html[data-theme=light] body.application-shell .hub-attention-list a:hover{background:#ffebbc}
html[data-theme=light] body.application-shell .hub-attention-list span{color:#76500d}
html[data-theme=light] body.application-shell :is(.pm-metrics>div,.pm-job-context){background:#fff;border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.pm-metrics span,.pm-definition){color:var(--muted)}
html[data-theme=light] body.application-shell :is(.pm-stars,.pm-star-choice label,.pm-metrics strong span){color:#80590f}
html[data-theme=light] body.application-shell .pm-star-choice label:has(input:checked){background:#e6f5ed;border-color:#188258}
html[data-theme=light] body.application-shell :is(.insurance-section,.insurance-card,.insurance-review,.insurance-limits>div,.region-picker,.help-search,.help-role-card,.help-guide-card,.help-steps,.help-side,.help-boundary){background:#fff;border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.region-picker legend,.region-heading,.region-picker strong){color:#37536e}
/* Gold support actions retain a dark foreground and a readable gold fill. */
html[data-theme=light] body.application-shell :is(.context-help,.help-steps>ol>li>span){background:#edc576;color:#07101d}

/* Public pages. Artwork and video content are not recolored. */
html[data-theme=light] body.application-shell :is(.public-hero,.public-footer,.public-start,.workshop-promo){background:#eaf1f9;border-color:var(--line)}
html[data-theme=light] body.application-shell :is(.public-hero,.public-footer,.workshop-promo){color:var(--ink)}
html[data-theme=light] body.application-shell .public-copy .public-intro{color:var(--muted)}
html[data-theme=light] body.application-shell :is(.public-hero .kicker,.workshop-promo .kicker){color:#075d94!important}
html[data-theme=light] body.application-shell .workshop-promo-art:after{background:linear-gradient(90deg,#eaf1f9,transparent 80%)}
html[data-theme=light] body.application-shell .public-values article{border-color:var(--line)}
html[data-theme=light] body.application-shell .public-video-promo .video-caption{color:var(--muted)}
html[data-theme=light] body.application-shell a.button.video-cta{background:#edc576;color:#081725;border-color:#cba257}
html[data-theme=light] body.application-shell a.button.video-cta:hover{background:#f5d79d}
html[data-theme=light] .overview-page{background:var(--paper);color:var(--ink);color-scheme:light}
html[data-theme=light] .overview-page a{color:#075d94}
html[data-theme=light] .overview-brand{color:var(--ink)!important}
html[data-theme=light] .overview-header{border-color:var(--line)}
html[data-theme=light] :is(.overview-intro,.overview-details){color:var(--muted)}
html[data-theme=light] .overview-kicker{color:#087457}
html[data-theme=light] .overview-page a:focus-visible{outline-color:#1266ae}

@media(max-width:760px){
  body.application-shell .nav-masthead{flex-wrap:wrap;gap:12px}
  body.application-shell .accountbar{width:100%;margin-left:0;justify-content:space-between;gap:8px}
  body.application-shell .accountbar #account-actions{margin-left:auto;flex-wrap:wrap}
}
@media print{.theme-toggle{display:none!important}}

/* Keep appearance independent of account controls on every role and viewport. */
body.application-shell .nav-masthead{flex-wrap:wrap}
body.application-shell .header-appearance{display:flex;align-items:center;margin-left:auto;flex:0 0 auto}
body.application-shell .accountbar{min-width:0}
body.application-shell .badge{color:var(--ink)}
html[data-theme=dark] body.application-shell :is(.intro,.card p,.premium-lesson p){color:#c5d6e8}
@media(max-width:760px){body.application-shell .header-appearance{margin-left:0}body.application-shell .accountbar{width:auto;flex:1 1 auto}}
