/* /contrast129.css?v=129 */
/* EPT V129: foreground-only fixes for existing surfaces. No sizes, layout, events or media changes.
   Repeated :root intentionally outranks legacy important light-theme text-fill rules. */

/* These headers retain a navy background in BOTH themes. Child colors must not inherit a light-page ink. */
html:root:root .overlay .dialog .contacts-head,
html:root:root .overlay .dialog .contacts-head :is(h1,h2,h3,strong,b,.contacts-kicker,.contacts-head-icon),
html:root:root #peerProfileModal .peer-profile-top,
html:root:root #peerProfileModal .peer-profile-top :is(strong,span,h2){
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;text-shadow:none!important;
}
html:root:root .overlay .dialog .contacts-head :is(p,small){
 color:#cce5f8!important;-webkit-text-fill-color:#cce5f8!important;opacity:1!important;text-shadow:none!important;
}
/* Contacts has an explicitly WHITE header in light mode; keep its text dark. */
html:root:root:is([data-theme="light"],.ept-light-active) #contactsModal .dialog .contacts-head,
html:root:root:is([data-theme="light"],.ept-light-active) #contactsModal .dialog .contacts-head :is(h1,h2,h3,strong,b,span){
 color:#173b57!important;-webkit-text-fill-color:#173b57!important;text-shadow:none!important;
}
html:root:root:is([data-theme="light"],.ept-light-active) #contactsModal .dialog .contacts-head :is(p,small){
 color:#40546b!important;-webkit-text-fill-color:#40546b!important;opacity:1!important;
}
/* Close is translucent on dark headers and pale in light mode. */
html:root:root .overlay .dialog .contacts-head .contacts-close-icon{
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;text-shadow:none!important;
}
html:root:root:is([data-theme="light"],.ept-light-active) .overlay .dialog .contacts-head .contacts-close-icon{
 color:#173b57!important;-webkit-text-fill-color:#173b57!important;
}
html:root:root .overlay .dialog .contacts-head .contacts-head-icon{
 color:#fff!important;-webkit-text-fill-color:#fff!important;
}

/* Forward picker: its body is navy in dark mode and pale in light mode. Search/preview stay pale. */
html:root:root #forwardModal .ept-forward-dialog{
 --ept129-ink:#f5fbff;--ept129-muted:#cce5f8;--ept129-hover:#153b60;
 color:var(--ept129-ink)!important;
}
html:root:root:is([data-theme="light"],.ept-light-active) #forwardModal .ept-forward-dialog{
 --ept129-ink:#173b57;--ept129-muted:#40546b;--ept129-hover:#e5f1fc;
}
html:root:root #forwardModal .ept-forward-dialog :is(.ept-forward-header h2,.ept-forward-person,.ept-forward-name strong,#closeForward){
 color:var(--ept129-ink)!important;-webkit-text-fill-color:var(--ept129-ink)!important;text-shadow:none!important;
}
html:root:root #forwardModal .ept-forward-dialog :is(.ept-forward-name small,.ept-forward-chevron,.ept-forward-section-title,.ept-forward-no-results,#forwardStatus){
 color:var(--ept129-muted)!important;-webkit-text-fill-color:var(--ept129-muted)!important;opacity:1!important;text-shadow:none!important;
}
html:root:root #forwardModal .ept-forward-person:is(:hover,:active,:focus-visible){
 background-color:var(--ept129-hover)!important;
}
html:root:root #forwardModal :is(.ept-forward-search,.ept-forward-search input,#forwardPreview,#forwardOpenById,.ept-forward-retry){
 color:#173b57!important;-webkit-text-fill-color:#173b57!important;text-shadow:none!important;
}
html:root:root #forwardModal .ept-forward-search input::placeholder{
 color:#40546b!important;-webkit-text-fill-color:#40546b!important;opacity:1!important;
}
html:root:root #forwardModal .ept-forward-avatar{
 color:#fff!important;-webkit-text-fill-color:#fff!important;
}
/* The small final confirmation stays white in the existing stylesheet, independently of theme. */
html:root:root #eptForwardConfirm :is(.ept-forward-confirm-title,.ept-forward-confirm-preview,#eptForwardCancel){
 color:#173b57!important;-webkit-text-fill-color:#173b57!important;text-shadow:none!important;
}
html:root:root #eptForwardConfirm #eptForwardSend{
 color:#fff!important;-webkit-text-fill-color:#fff!important;
}

/* Account/settings: these two approved cards keep their BLUE backgrounds in both themes. */
html:root:root.ept-v2-layout #settingsPage .ept-r44-profile,
html:root:root.ept-v2-layout #settingsPage .ept-r44-profile :is(strong,b,span),
html:root:root #settingsPage .ept-r44-card-link,
html:root:root #settingsPage .ept-r44-card-link :is(b,strong,span){
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;text-shadow:none!important;
}
html:root:root.ept-v2-layout #settingsPage .ept-r44-profile small,
html:root:root #settingsPage .ept-r44-card-link small{
 color:#cce5f8!important;-webkit-text-fill-color:#cce5f8!important;opacity:1!important;text-shadow:none!important;
}
/* Profile ID card is pale in light mode, navy otherwise. */
html:root:root #profileModal .dialog .profile-identity :is(span,strong,#profileEptId){
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;text-shadow:none!important;
}
html:root:root:is([data-theme="light"],.ept-light-active) #profileModal .dialog .profile-identity :is(span,strong,#profileEptId){
 color:#173b57!important;-webkit-text-fill-color:#173b57!important;
}
/* Copy-ID is blue in dark mode and pale in light mode. */
html:root:root #profileModal .profile-identity .small-action{
 color:#fff!important;-webkit-text-fill-color:#fff!important;
}
html:root:root:is([data-theme="light"],.ept-light-active) #profileModal .profile-identity .small-action{
 color:#173b57!important;-webkit-text-fill-color:#173b57!important;
}
/* Settings title follows the existing header: pale in light subpages, blue on settings home. */
html:root:root #settingsPage .settings-top :is(h1,small){
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;text-shadow:none!important;
}
html:root:root:is([data-theme="light"],.ept-light-active) #settingsPage:not(.ept-r44-home-view) .settings-top :is(h1,small){
 color:#173b57!important;-webkit-text-fill-color:#173b57!important;
}

/* Security dialogs keep a navy box even when the main application uses light mode. */
html:root:root .ept73-overlay .ept73-box :is(h2,h3,p,label,small,strong,code){
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;text-shadow:none!important;
}
html:root:root .ept73-overlay .ept73-box :is(input,textarea){
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;caret-color:#f5fbff!important;
}
html:root:root .ept73-overlay .ept73-box :is(input,textarea)::placeholder{
 color:#cce5f8!important;-webkit-text-fill-color:#cce5f8!important;opacity:1!important;
}
/* Existing media/gallery toolbars and call heading are always BLUE, never pale page surfaces. */
html:root:root.ept-v2-layout :is(#fileViewer,#chatMediaGallery)>header,
html:root:root.ept-v2-layout :is(#fileViewer,#chatMediaGallery)>header :is(strong,small,span,button),
html:root:root #callModal .call-head :is(strong,small){
 color:#f5fbff!important;-webkit-text-fill-color:#f5fbff!important;text-shadow:none!important;
}
/* Primary actions on known dark blue/teal buttons. Do not blanket-recolor other buttons or icon art. */
html:root:root .overlay .dialog button.primary,
html:root:root .overlay .dialog button.primary :is(span,strong,small),
html:root:root .ept73-box button,
html:root:root #settingsPage .ept73-panel button,
html:root:root #assistant97 button,
html:root:root #chatView #bulkToolbar :is(#bulkForward,#assistant97Button){
 color:#fff!important;-webkit-text-fill-color:#fff!important;text-shadow:none!important;
}
/* Portalled message menus: preserve the semantic delete color and existing light/dark backgrounds. */
html:root:root .ept-r43-menu{--ept129-menu:#f5fbff;--ept129-delete:#ffb8c7}
html:root:root:is([data-theme="light"],.ept-light-active) .ept-r43-menu{--ept129-menu:#173b57;--ept129-delete:#a51e43}
html:root:root .ept-r43-menu .ept-r43-menu-content>button{
 color:var(--ept129-menu)!important;-webkit-text-fill-color:var(--ept129-menu)!important;text-shadow:none!important;
}
html:root:root .ept-r43-menu .ept-r43-menu-content>button:is([data-action^="delete"],[data-viewer-action="delete"]){
 color:var(--ept129-delete)!important;-webkit-text-fill-color:var(--ept129-delete)!important;
}
/* Pair foreground/background on the existing pale forward search, regardless of generic input rules. */
html:root:root #forwardModal .ept-forward-search{
 background-color:#f5f7fb!important;background-image:none!important;
}
html:root:root #forwardModal .ept-forward-search input{
 background-color:transparent!important;background-image:none!important;
}
/* The security PIN field belongs to its navy dialog, independently of the page theme. */
html:root:root .ept73-overlay .ept73-box :is(input,textarea){
 background-color:#092846!important;background-image:none!important;
}
html:root:root .ept-r43-menu .ept-r43-menu-content>button :is(span,strong,small){
 color:inherit!important;-webkit-text-fill-color:inherit!important;text-shadow:none!important;
}

