/* Shared mounting and component boundaries. All theme-specific colours are screen-only. */
html[data-ta-theme-pilot="1"] :is(.rs-home,.rs-curated) .ta-appearance-control{order:0;flex:0 0 40px}
html[data-ta-theme-pilot="1"] :is(.rs-home,.rs-curated) .ta-appearance-panel{position:fixed;top:var(--ta-appearance-top,82px);right:18px;z-index:10050}
html[data-ta-theme-pilot="1"] .ta-appearance-panel{max-height:calc(100dvh - var(--ta-appearance-top,82px) - 20px);overflow:auto}
@media(max-width:1200px){html[data-ta-theme-pilot="1"] .ta-appearance-panel{top:var(--ta-appearance-top,82px)}}
@media(max-width:600px){
 html[data-ta-theme-pilot="1"] :is(.rs-home .nav-row,.rs-curated .nav){gap:8px!important}
 html[data-ta-theme-pilot="1"] :is(.rs-home .nav-actions,.rs-curated header .account){gap:4px!important}
 html[data-ta-theme-pilot="1"] :is(.rs-home .site-header,.rs-curated header) .brand{width:140px!important;min-width:0!important;flex:0 1 140px!important}
 html[data-ta-theme-pilot="1"] :is(.rs-home,.rs-curated) .ta-appearance-control{flex-basis:36px;width:36px}
 html[data-ta-theme-pilot="1"] :is(.rs-home,.rs-curated) .ta-appearance-toggle{width:36px;border:0!important}
}
@media(max-width:380px){html[data-ta-theme-pilot="1"] :is(.rs-home .site-header,.rs-curated header) .brand{width:120px!important;flex-basis:120px!important}}
@media screen{
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .page-wrapper,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .container.content-page{background:#0b141b!important;color:#e9f0f3!important;color-scheme:dark}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(#ta-country-home,#ta-gear-hub,#ta-calculators-hub,.rs-home,.rs-curated){background:#0b141b!important;color:#e9f0f3!important;color-scheme:dark}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :where(h1,h2,h3,h4,h5,h6,label,legend){color:#e9f0f3}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :where(input:not([type=button],[type=submit],[type=radio],[type=checkbox],[type=range],[type=color]),select,textarea){color:#e9f0f3;background-color:#13212b;border-color:#536d7c;color-scheme:dark}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :where(input,textarea)::placeholder{color:#a9bec9;opacity:1}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :where(input[type=checkbox],input[type=radio],input[type=range]){accent-color:#34d3e6}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :where(table,th,td){border-color:#304653}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :where(hr){background-color:#304653;border-color:#304653}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(.woocommerce-MyAccount-content,.woocommerce-MyAccount-navigation,.woocommerce-form-login,.woocommerce-form-register,.woocommerce-ResetPassword,.woocommerce-info,.woocommerce-message){background:#13212b!important;color:#e9f0f3!important;border-color:#304653!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(.woocommerce-MyAccount-content,.woocommerce-MyAccount-navigation) a{color:#73dce9!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(.woocommerce-form-login,.woocommerce-form-register,.woocommerce-ResetPassword) :is(label,p){color:#e9f0f3!important}
 /* Preserve existing branded imagery; RouteSmart's approved full-colour mark has a light plate. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(.rs-home,.rs-curated) .brand,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .rs-network .rs-brand,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] #ta-country-home .route-logo{background:#fff!important;border-radius:7px;padding:5px 8px;box-sizing:border-box}
 /* Native canvases keep a readable plot surface without touching Chart data or options. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(.ta-chart-wrap,.ta-us-chart-wrap,.roi-chart-plot,.ta-ev-box,.ta-us-ev-box,.ta-gap-calc,.ta-gap-calc-ca,.ta-ca-charge,.ta-us-charge) canvas{background:#f8fafc!important;border-radius:8px;color-scheme:light}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(.ta-score-gauge,.ta-mobile-stop-score__gauge){background:#f8fafc!important;border-radius:8px;color-scheme:light}
 /* Map controls retain the vendor icon palette. Basemap/camera are untouched. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-ctrl-group,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-ctrl-group button,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-ctrl-attrib{background-color:#fff!important;color:#102a3a!important;color-scheme:light}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-ctrl-group button:hover{background-color:#edf5f6!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-ctrl-attrib a{color:#102a3a!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-popup-content{background:#13212b!important;color:#e9f0f3!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-popup-close-button{color:#e9f0f3!important;background:#13212b!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-popup-anchor-top .mapboxgl-popup-tip{border-bottom-color:#13212b!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-popup-anchor-bottom .mapboxgl-popup-tip{border-top-color:#13212b!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-popup-anchor-left .mapboxgl-popup-tip{border-right-color:#13212b!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .mapboxgl-popup-anchor-right .mapboxgl-popup-tip{border-left-color:#13212b!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is(.ta-score-box,.ta-mobile-stop-score) :is(strong,p){color:#e9f0f3!important}
 /* Cross-origin forms remain under the provider's control. Keep the boundary clear. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] :is([data-reach-form],.ta-partner-signup-form) iframe{background:#fff!important;border-radius:8px;color-scheme:light}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .ta-shell-mobile-search form{background:#13212b!important;border-color:#304653!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .ta-shell-mobile-nav nav a:hover{background:#1d3540!important;color:#8ae7ef!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .ta-market-dd-menu a:hover{background:#1d3540!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] .ta-appearance-options input{accent-color:#65dbe8!important}
}

/* Dark-mode acceptance corrections: semantic text and original image colours. */
@media screen {
 /* Legacy XStore articles and the shared editorial layout both need explicit prose colours.
    Do not inherit the light theme's global paragraph colour or the generated link palette. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post :is(.content-article.entry-content,.tar-article .entry-content) {
  color:#d4e0e5!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post :is(article.post-single,.tar-article) .entry-content :is(p,ul,ol,li,blockquote),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .tar-article .entry-content>p:first-of-type,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .entry-content .elementor-widget-text-editor,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .entry-content .elementor-widget-text-editor :is(p,ul,ol,li,blockquote) {
  color:#d4e0e5!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post :is(article.post-single,.tar-article) .entry-content :is(p,li,blockquote) :is(strong,em,b,i),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .entry-content .elementor-widget-text-editor :is(strong,em,b,i) {
  color:inherit!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post :is(.post-heading,.post-header,.content-article,.tar-article) :is(h1,h2,h3,h4,h5,h6),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .tar-article .entry-content .elementor-widget-heading .elementor-heading-title,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .tar-article .entry-content>.tar-text-heading {
  color:#e9f0f3!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post :is(article.post-single,.tar-article) .entry-content :is(p,li,blockquote) a:not(.button,.btn,.wp-element-button,.elementor-button),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .meta-post a {
  color:#73dce9!important;text-decoration-color:#50818c!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post :is(.meta-post,.meta-post time,.meta-post span,.share-post .share-title),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .tar-article .entry-content .tar-disclosure {
  color:#a9bec9!important;
 }
 /* Global theme paragraph rules must not override the consent panel or its status line. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-tc,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-tc :is(p,.ta-tc-summary,.ta-tc-summary span) {
  color:#c4d4dd!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-tc strong {color:#e9f0f3!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-tc a {color:#73dce9!important}
 /* The XStore panel contains a second independently coloured container. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.ta-shell-pilot .et-mobile-panel {
  background:#13212b!important;border-color:#405966!important;color:#a7e9f0!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.ta-shell-pilot .et-mobile-panel :is(.et-row-container.et-container,.et-wrap-columns,.et_column,a) {
  background:transparent!important;background-image:none!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.ta-shell-pilot .et-mobile-panel a,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.ta-shell-pilot .et-mobile-panel a :is(span,.et_b-icon) {
  color:#a7e9f0!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.ta-shell-pilot .et-mobile-panel a:is(:hover,:focus-visible),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.ta-shell-pilot .et-mobile-panel a:is(:hover,:focus-visible) span {
  color:#ffffff!important;
 }
 /* Multiply was intended to remove white product backgrounds on a light canvas.
    A neutral light image well preserves black products and transparent cutouts. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] #ta-gear-hub .ge-productimg,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] #ta-calc-hub .productimg {
  background:#f5f7f7!important;color-scheme:light;isolation:isolate;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] #ta-gear-hub .ge-productimg img,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] #ta-calc-hub .productimg img {
  mix-blend-mode:normal!important;filter:none!important;opacity:1!important;
 }
 /* The map logo uses the same light-only blending technique. Keep its original artwork. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.ta-ev-app-mode.ta-ev-results-page .ta-map-wrap > .ta-routesmart-brand-header {
  mix-blend-mode:normal!important;background:#ffffff!important;
 }
}

/* Reusable legacy shortcodes use inline colours; pair their surfaces and text explicitly. */
@media screen {
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout {
  background:linear-gradient(135deg,#24202d 0%,#142e36 100%)!important;
  color:#d4e0e5!important;border-color:#405966!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout :is(div,p,li,span) {color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout :is(h1,h2,h3,h4,h5,h6,strong,b),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout > div[style*="font-weight:700"] {color:#e9f0f3!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout > div[style*="text-transform:uppercase"] {color:#a9bec9!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout a {color:#73dce9!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout[data-ta-callout] a.tesladdict-track-click[data-cta-name] {
  background:linear-gradient(135deg,#b41442 0%,#0b6476 100%)!important;color:#ffffff!important;text-decoration:none!important;
 }
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-appearance-callout[data-ta-callout] a.tesladdict-track-click[data-cta-name]:is(:hover,:focus-visible) {
  background:#922044!important;color:#ffffff!important;outline:2px solid #73dce9;outline-offset:3px;
 }
 /* Dock to the web viewport edge. The safe area is part of the painted panel,
    not an external bottom offset; Safari's own toolbar remains browser-controlled. */
 html[data-ta-theme-pilot="1"] body.ta-shell-pilot .et-mobile-panel-wrapper {
  bottom:0!important;left:0!important;right:0!important;width:100%!important;margin:0!important;
 }
 html[data-ta-theme-pilot="1"] body.ta-shell-pilot .et-mobile-panel {
  margin:0!important;border-radius:14px 14px 0 0!important;border-bottom:0!important;
  padding-bottom:calc(5px + env(safe-area-inset-bottom,0px))!important;
 }
}

/* Dialog lists inherit explicit text colours independently of article/theme list rules. */
@media screen {
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body dialog.ta-ev-pwa-guide {color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body dialog.ta-ev-pwa-guide :is(ol,ul,li),
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body dialog.ta-ev-pwa-guide :is(ol,ul,li) :is(span,strong,em) {color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body dialog.ta-ev-pwa-guide li::marker {color:#ff8ba7!important}
}

/* Dark visibility audit: colours only, scoped to the affected shared components. */
@media screen {
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :is(.tl-report-context,.tar-ota-context) :is(p,span,strong){color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .rs-home footer a,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .rs-curated footer a{color:#b9cdd6!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :is(.rs-home,.rs-curated) :is(.mini-origin,.route-start>i,.choice-dot.origin){background:#087643!important;color:#fff!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .rs-curated.rs-curated :is(.mini-destination,.choice-dot.destination){color:#102a35!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .rs-network strong{color:#e9f0f3!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .entry-content>div[style*="clear: both"][style*="font-size: 13px"],
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .entry-content>div[style*="clear: both"][style*="font-size: 13px"]>span{color:#b9cdd6!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post :is(.post-details .post-title,.etheme-advanced-headline){color:#e9f0f3!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body #tesladdict-ev-calculator :is(div,label,span)[style*="color"],
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body #tesladdict-rate-badge,
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .tesladdict-pion-picker>div[style*="color"]{color:#d4e0e5!important}
 /* Deepen bright CTA fills sufficiently for small white labels. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body :is(.ge-primary,#ta-calc-hub .primary,.ta-gc-btn,.ta-gc-mid-cta>a,.ta-charge-hero-cta,.ta-ca-primary,.ta-us-primary,.ta-ps-button,.ta-account-button,.rs-curated .primary.continue,.ta-about-wrap .ta-btn.pink){background:#c70e45!important;color:#fff!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body #ta-global-home .tg-journey .tg-primary{background:#c70e45!important;color:#fff!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-partners-wrap :is(.ta-btn,.ta-email-btn){background:#c70e45!important;color:#fff!important}
 /* About-page surfaces were still white under the shared light headings. */
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap{background:#0b141b!important;color:#e9f0f3!important;--muted:#b9cdd6;--pink:#ff8ba7;--cyan:#73dce9}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap :is(.ta-section,.ta-global){background-color:transparent!important;color:#e9f0f3!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap :is(.ta-global p,.ta-global strong){color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-contact{background:#152b34!important;border-color:#304653!important;color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-contact p{color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-btn.blue{background:#08788a!important;color:#fff!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-btn.outline{background:transparent!important;color:#8ae7ef!important;border-color:#73dce9!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-card.pink a{color:#ff8ba7!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-card.purple a{color:#c4a8ff!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-mission span{color:#d4e0e5!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .posts-navigation .post-info{background:#15242e!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-map{background-color:#fff!important;border-radius:16px}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .ta-about-wrap .ta-pin span{color:#102a35!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body.single-post .elementor-widget-text-editor span[style*="color: #777777"]{color:#b9cdd6!important}
 html[data-ta-theme-pilot="1"][data-ta-theme="dark"] body .rs-home.rs-home .mini-destination{color:#102a35!important}
}
