/* Dark-theme surface/foreground contract. Loaded after page styles.
   Text must never inherit the dark palette while retaining a light surface. */
:root{
  --ct-canvas:#07111f;--ct-surface:#142236;--ct-input:#0c1b2d;
  --ct-text:#f7fafc;--ct-muted:#c0cbd8;--ct-accent:#63d0ff;--ct-line:#52657b;
  --paper:#0c1b2d;--mist:#142236;--mist-2:#21354c;
  --ink:#f7fafc;--ink-2:#c0cbd8;--ink-3:#b3c2d5;
  --line:#52657b;--line-warm:#52657b;
  --accent:#38bdf8;--accent-hover:#7dd3fc;--accent-deep:#7dd3fc;--accent-soft:#12334c;
  --pine:#14364e;--pine-deep:#07111f;--pine-soft:#19374d;
  --cream-on-clay:#07111f;--footer-fg:#c0cbd8;
  --good:#8ee3af;--bad:#ffb4ab;
}
html{color-scheme:dark}
/* Opaque reading surfaces also protect text from the site-wide photo backdrop. */
body #main:not(.calm){background:#0b1627!important}
body .site-header :is(.wordmark-light,.nav-search-row,.nav-search-row span,.contact-link-label),
body .slim-bar :is(.wordmark-light,.slim-search,.slim-search span,.contact-link-label){color:var(--ct-muted)!important}
body .site-header .wordmark,body .slim-wordmark{color:var(--ct-text)!important}
body :is(.nav-menu,.site-search,.site-search-box){background:var(--ct-surface)!important;color:var(--ct-text)!important}
body .nav-menu :is(a,.nav-learn-title),body .site-search :is(label,.site-search-title){color:var(--ct-text)!important}
body .nav-menu :is(.nav-learn-desc,.nav-learn-heading),body .site-search :is(p,.site-search-desc){color:var(--ct-muted)!important}
body .nav-menu a:hover,body .site-search :is(.is-active,[aria-selected=true]){background:#213b53!important}
body :is(input[type=text],input[type=number],input[type=email],input[type=tel],input[type=search],input:not([type]),textarea,select){
  background:var(--ct-input)!important;color:var(--ct-text)!important;
  -webkit-text-fill-color:var(--ct-text)!important;border-color:var(--ct-line)!important;
}
body :is(input,textarea)::placeholder{color:#b3c2d5!important;-webkit-text-fill-color:#b3c2d5!important;opacity:1!important}
body input:autofill{box-shadow:0 0 0 1000px var(--ct-input) inset!important;-webkit-text-fill-color:var(--ct-text)!important}
body :is(.v2h-input,.pv-money,.rf-input-wrap){background:var(--ct-input)!important;border-color:var(--ct-line)!important;color:var(--ct-text)!important}
body #main :is(.v2h-field label,.pv-fieldlabel,.rf-fields label,.clm-ctl label,.enquiry label){color:var(--ct-text)!important}
body #main :is(.v2h-input>span,.pv-money>span,.rf-input-wrap>span,.v2h-help,.v2h-rate-note,.pv-basis,.rf-fields p){color:var(--ct-muted)!important}
body #main :is(.v2h-calc-result,.pv-output,.pv-controls,.clm-doc-head,.pacific-contact,.pacific-contact-band){background:var(--ct-surface)!important;color:var(--ct-text)!important;border-color:var(--ct-line)!important}
body #main .v2h-calc-result :is(p,span,strong,small,li,dt,dd,output){color:var(--ct-text)!important}
body #main .v2h-calc-result a{color:var(--ct-accent)!important}
body #main :is(.v2h-calc-result,.pv-output) :is(p,small,dt){color:var(--ct-muted)!important}
body #main :is(.v2h-calc-result,.pv-output) :is(strong,output){color:var(--ct-text)!important}
body #main .rf-page{color:var(--ct-text)}
body #main .rf-page :is(h1,h2,h3,.rf-result-value){color:var(--ct-text)!important}
body #main .rf-page :is(p,li,.rf-breadcrumb,.rf-meta,.rf-result-label){color:var(--ct-muted)!important}
body #main .rf-page :is(.rf-summary,.rf-goal,.rf-calc-card,.rf-checklist,.rf-reach){background:var(--ct-surface)!important;border-color:var(--ct-line)!important;color:var(--ct-text)!important}
body #main .rf-page :is(a,.rf-eyebrow,.rf-formula),body #main .rf-page h1 em{color:var(--ct-accent)!important}
/* Cyan actions require dark text, including their icon and label children. */
body :is(.nav-cta,.slim-cta,.pc-contact-options>a:first-child,.rf-button,.rf-button-light){background:#38bdf8!important;color:#07111f!important;border-color:#38bdf8!important}
body :is(.nav-cta,.slim-cta,.pc-contact-options>a:first-child,.rf-button,.rf-button-light) :is(span,b,strong,small){color:#07111f!important}
body #main .rf-page a.rf-button{color:#07111f!important}
body :is(.nav-cta,.slim-cta,.pc-contact-options>a:first-child,.rf-button):hover{background:#7dd3fc!important;color:#07111f!important}
body .pc-contact-options>a:not(:first-child):not(.pc-email){background:var(--ct-surface)!important;color:var(--ct-text)!important;border-color:var(--ct-line)!important}
body .pc-contact-options>a:not(:first-child):not(.pc-email) :is(span,b){color:var(--ct-text)!important}
body :is(.enquiry-error,.vm-error,#rf-error){color:#ffb4ab!important}
body #main .rf-page #rf-error{background:#381b27!important;color:#ffcdc5!important;border-color:#ffb4ab!important}
body :focus-visible{outline:3px solid #63d0ff!important;outline-offset:3px!important}
body .nav-group-btn:hover,body .nav-group-btn[aria-expanded=true]{background:#213b53!important;color:var(--ct-text)!important}
body .calc-handoff-btn,body #vm-launch{background:#38bdf8!important;color:#07111f!important;border-color:#38bdf8!important}
body .calc-handoff-btn :is(span,strong,b){color:#07111f!important}
body #main :is(.sh-btn,.guide-cta-btn):not(.sh-btn--ghost):not(.sh-btn--ghost-light){background:#38bdf8!important;color:#07111f!important;border-color:#38bdf8!important}
body #main :is(.sh-finale-card,.pl-wholepath){background:var(--ct-surface)!important;color:var(--ct-text)!important}
body #main :is(.sh-finale-card,.pl-wholepath) :is(h2,h3,p,li,strong,span){color:var(--ct-text)!important}
body #main :is(.sh-finale-card,.pl-wholepath) a{color:var(--ct-accent)!important}
body #main .sh-recap{color:#8ee3af!important}
body #main :is(.pl-badge,.pl-stack-seg--p,.pl-stack-seg--i){color:#07111f!important}
body #main :is(button[aria-pressed=true],button[role=tab][aria-selected=true],.guide-new,.vm-cc-actions>a){background:#38bdf8!important;color:#07111f!important;border-color:#38bdf8!important}
body #main :is(button[aria-pressed=true],button[role=tab][aria-selected=true],.vm-cc-actions>a) :is(span,b,strong){color:#07111f!important}
body #main :is(.pl-contact-band,.pl-wholepath-note,.bucket-head>th){background:var(--ct-surface)!important;color:var(--ct-text)!important}
body #main .pl-contact-band :is(h2,h3,p,li,strong){color:var(--ct-text)!important}
body #main .pl-contact-band a{color:var(--ct-accent)!important}
body .area-mobile-ask{background:#38bdf8!important;color:#07111f!important;border-color:#38bdf8!important}
body #main .rf-summary>span{color:var(--ct-muted)!important}
body #main .rf-goal>span{color:var(--ct-accent)!important}
body #main .pl-verdict--not{background:#3e1f2a!important;color:#ffcdc5!important}
body :is(.form-status--error,.enquiry-alert){background:#3e1f2a!important;color:#ffcdc5!important}
body :is(.form-status--error,.enquiry-alert) :is(p,span,li,strong){color:#ffcdc5!important}
body :is(.form-status--ok,.enquiry-success){background:#12372c!important;color:#c8f7dd!important}
body :is(.form-status--ok,.enquiry-success) :is(p,span,li,strong){color:#c8f7dd!important}
body input[aria-invalid=true],body textarea[aria-invalid=true]{border-color:#ffb4ab!important}
body #main .clm-hero-note{color:var(--ct-muted)!important}
body .skip-link{background:#38bdf8!important;color:#07111f!important}
body #vm-panel,body #vm-panel .vm-head{background:var(--ct-surface)!important;color:var(--ct-text)!important}
body #vm-panel :is(.vm-head strong,.vm-head small,#vm-close){color:var(--ct-text)!important}
body #vm-panel #vm-close{background:var(--ct-input)!important;border-color:var(--ct-line)!important}
body #vm-panel :is(.vm-modes button,.vm-prompts button){background:#213b53!important;color:var(--ct-text)!important;border-color:var(--ct-line)!important}
body #vm-panel :is(.vm-modes button[aria-pressed=true],button[type=submit],.vm-wa){background:#38bdf8!important;color:#07111f!important;border-color:#38bdf8!important}
body #vm-panel :is(.vm-visitor,.vm-assistant){background:#142c43!important;color:var(--ct-text)!important}
body #vm-panel .vm-bubble :is(p,strong){color:var(--ct-text)!important}
body #main :is(.chip,.guide-chip,.pill,.guide-num,.site-search-tag){background:#213b53!important;color:var(--ct-text)!important}
body #main :is(.guide-contents,.guide-contents details,.prevnext-link,.guide-prevnext,.keep-learning,.section-summary){background:var(--ct-surface)!important;color:var(--ct-text)!important}
body #main :is(.guide-contents,.prevnext-link,.guide-prevnext,.keep-learning) :is(a,span,b,strong,small,h2,h3){color:var(--ct-text)!important}
body #main :is(.clm-terms,.clm-doc,.clm-anatomy-grid) :is(h2,h3,.clm-doc-head,.clm-doc-head span){color:var(--ct-text)!important}
body #main :is(.clm-doc-tabs button.on,.clm-doc-tabs button[aria-selected=true],.pv-term button[aria-pressed=true],.pv-year.is-active){background:#38bdf8!important;color:#07111f!important}
body #main .clm-doc-tabs button{background:var(--ct-input)!important;color:var(--ct-text)!important}
body #main .clm-doc-tabs button[aria-selected=true]{background:#38bdf8!important;color:#07111f!important}
@media(max-width:899px){body .site-header:has(.site-nav.open){display:block!important;position:fixed!important;top:64px!important;left:0;right:0;z-index:74;background:var(--ct-canvas)!important}body .site-header:has(.site-nav.open) .brand,body .site-header:has(.site-nav.open)>.wrap>.nav-toggle{display:none!important}body .site-header .site-nav.open{max-height:calc(100dvh - 148px);overflow-y:auto}}
@media print{html{color-scheme:light}body #main:not(.calm){background:white!important;color:black!important}}
