/* ===== full-theme-contrast-audit-20261004 =====
   Final presentation-only contrast authority. This file is intentionally
   loaded after every portal/business stylesheet so legacy dark-first rules
   cannot leak pale/white text onto light surfaces. It does not change auth,
   payment, crop, storage, document rendering, or network behaviour. */

body.op-light{
  color-scheme:light;
  --text-main:#172033;
  --text-muted:#52627a;
  --text:#172033;
  --panel:#ffffff;
  --panel-2:#f8fafc;
  --input-bg:#ffffff;
  --border-color:#cbd5e1;
}
html.op-theme-dark body{
  color-scheme:dark;
  --text-main:#f8fafc;
  --text-muted:#cbd5e1;
  --text:#f8fafc;
  --panel:#111b2b;
  --panel-2:#172337;
  --input-bg:#0b1321;
  --border-color:#475569;
}

/* ---------- public landing ---------- */
body.op-light #loginScreen.front-home :is(
  .front-hero,.front-auth-panel,.front-tool-catalog,.landing-audience-section,
  .landing-policy-strip,.landing-metrics-section,.landing-privacy-section,
  #landingArticles,.op-footer
){
  background:#fff!important;
  color:#172033!important;
  border-color:#cbd5e1!important;
}
body.op-light #loginScreen.front-home :is(
  .front-hero,.front-auth-panel,.front-tool-catalog,.landing-audience-section,
  .landing-policy-strip,.landing-metrics-section,.landing-privacy-section,
  #landingArticles,.op-footer
) :is(h1,h2,h3,h4,h5,h6,strong,b,summary,legend){
  color:#172033!important;
  -webkit-text-fill-color:initial!important;
  text-shadow:none!important;
}
body.op-light #loginScreen.front-home :is(
  .front-hero,.front-auth-panel,.front-tool-catalog,.landing-audience-section,
  .landing-policy-strip,.landing-metrics-section,.landing-privacy-section,
  #landingArticles,.op-footer
) :is(p,label,small,li,figcaption){
  color:#475569!important;
}
body.op-light #loginScreen.front-home .landing-audience-badges span{
  background:#eff6ff!important;color:#1e3a8a!important;border-color:#bfdbfe!important;
}
body.op-light #loginScreen.front-home .landing-service-search label,
body.op-light #loginScreen.front-home .landing-audience-kicker,
body.op-light #loginScreen.front-home .landing-policy-kicker,
body.op-light #loginScreen.front-home .landing-privacy-kicker{color:#075985!important}
body.op-light #loginScreen.front-home :is(.landing-service-search,.landing-contact-card) :is(input,select,textarea){
  background:#fff!important;color:#172033!important;border-color:#94a3b8!important;
}
body.op-light #loginScreen.front-home :is(.landing-service-search,.landing-contact-card) :is(input,textarea)::placeholder{color:#64748b!important}
body.op-light #loginScreen.front-home :is(.landing-faq-card,.landing-contact-card,.landing-privacy-grid article){
  background:#f8fafc!important;border-color:#d7e2eb!important;color:#172033!important;
}
body.op-light #loginScreen.front-home .landing-faq-card summary,
body.op-light #loginScreen.front-home .landing-contact-card .contact-detail,
body.op-light #loginScreen.front-home #landingPolicyTitle,
body.op-light #loginScreen.front-home .landing-metrics-heading,
body.op-light #loginScreen.front-home .landing-metric-card strong,
body.op-light #loginScreen.front-home .landing-privacy-grid strong{color:#172033!important}
body.op-light #loginScreen.front-home :is(.landing-policy-links a,.op-footer a,.op-footer-link-button){color:#1d4ed8!important}
body.op-light #loginScreen.front-home .landing-metric-card{border-color:#cbd5e1!important}
body.op-light #loginScreen.front-home .landing-metric-card span,
body.op-light #loginScreen.front-home .landing-metrics-subtitle,
body.op-light #loginScreen.front-home .landing-metrics-status{color:#52627a!important}
/* The light landing nav intentionally remains navy; keep its foreground white. */
body.op-light #loginScreen.front-home .front-nav,
body.op-light #loginScreen.front-home .front-nav :is(strong,span,small,label,button){color:#fff!important}
body.op-light #loginScreen.front-home .front-nav select{background:#fff!important;color:#172033!important;border-color:#cbd5e1!important}

html.op-theme-dark #loginScreen.front-home :is(
  .front-hero,.front-auth-panel,.front-tool-catalog,.landing-audience-section,
  .landing-policy-strip,.landing-metrics-section,.landing-privacy-section,
  #landingArticles,.op-footer
){color:#f1f5f9!important}
html.op-theme-dark #loginScreen.front-home :is(
  .front-hero,.front-auth-panel,.front-tool-catalog,.landing-audience-section,
  .landing-policy-strip,.landing-metrics-section,.landing-privacy-section,
  #landingArticles,.op-footer
) :is(h1,h2,h3,h4,h5,h6,strong,b,summary,legend){color:#f8fafc!important;-webkit-text-fill-color:initial!important}
html.op-theme-dark #loginScreen.front-home :is(
  .front-hero,.front-auth-panel,.front-tool-catalog,.landing-audience-section,
  .landing-policy-strip,.landing-metrics-section,.landing-privacy-section,
  #landingArticles,.op-footer
) :is(p,label,small,li,figcaption){color:#cbd5e1!important}
html.op-theme-dark #loginScreen.front-home :is(.landing-service-search,.landing-contact-card) :is(input,select,textarea){
  background:#07152f!important;color:#f8fafc!important;border-color:#52657d!important;
}

/* ---------- auth, registration, renewal and payment ---------- */
body.op-light #portalAuthPage .portal-auth-card,
body.op-light :is(#signUpScreen,#renewalScreen,#trialUpgradeDialog){
  background:#fff!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light #portalAuthPage :is(h1,h2,h3,h4,strong,label,span,small,p),
body.op-light :is(#signUpScreen,#renewalScreen,#trialUpgradeDialog) :is(h1,h2,h3,h4,strong,label,span,p){
  color:#334155!important;
  -webkit-text-fill-color:initial!important;
}
body.op-light #portalAuthPage :is(p,small),
body.op-light :is(#signUpScreen,#renewalScreen,#trialUpgradeDialog) :is(p,small){color:#52627a!important}
body.op-light :is(#registrationOtpGate,#registrationPaymentSection,#razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,.direct-purchase-agreement,.autopay-agreement-note){
  background:#f8fafc!important;color:#334155!important;border-color:#b8c7dc!important;
}
body.op-light :is(#registrationOtpGate,#registrationPaymentSection,#razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,.direct-purchase-agreement,.autopay-agreement-note) :is(h3,h4,strong,p,label,span,small,div){
  color:#334155!important;
}
body.op-light .payment-plan-choice{
  background:#fff!important;color:#172033!important;border-color:#94a3b8!important;box-shadow:none!important;
}
body.op-light .payment-plan-choice strong{color:#172033!important}
body.op-light .payment-plan-choice small{color:#52627a!important}
body.op-light .payment-plan-choice[aria-pressed="true"]{
  background:linear-gradient(135deg,#2563eb,#0e7490)!important;color:#fff!important;border-color:#1d4ed8!important;
}
body.op-light .payment-plan-choice[aria-pressed="true"] :is(strong,small,span){color:#fff!important}
body.op-light :is(
  #paymentCheckoutStatus,#registrationOtpStatus,#registrationLocationStatus,#signUpStatusMsg,
  #signupPlanDiscountNote,#razorpayPlanSummary,#referralAppliedLabel,
  #trialUpgradeStatus,#renewalStatusMsg,#renewalReferralYearRewardStatus,
  #referralActivationStatus,#walletStatus,#purchaseHistoryStatus,#bookmarkEditorStatus
){color:#475569!important}
body.op-light :is(#signUpScreen,#renewalScreen,#trialUpgradeDialog) a{color:#1d4ed8!important}

html.op-theme-dark #portalAuthPage .portal-auth-card,
html.op-theme-dark :is(#signUpScreen,#renewalScreen,#trialUpgradeDialog){
  background:#111b2b!important;color:#f1f5f9!important;border-color:#475569!important;
}
html.op-theme-dark #portalAuthPage .portal-auth-header{background:#172337!important;color:#f8fafc!important;border-color:#475569!important}
html.op-theme-dark #portalAuthPage :is(h1,h2,h3,h4,strong,label,span,p,small),
html.op-theme-dark :is(#signUpScreen,#renewalScreen,#trialUpgradeDialog) :is(h1,h2,h3,h4,strong,label,span,p,small){color:#e5e7eb!important;-webkit-text-fill-color:initial!important}
html.op-theme-dark #portalAuthPage :is(input,select,textarea),
html.op-theme-dark :is(#signUpScreen,#renewalScreen,#trialUpgradeDialog) :is(input,select,textarea){
  background:#0b1321!important;color:#f8fafc!important;border-color:#52657d!important;
}
html.op-theme-dark :is(#registrationOtpGate,#registrationPaymentSection,#razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,.direct-purchase-agreement,.autopay-agreement-note){
  background:#0f1b2d!important;color:#e2e8f0!important;border-color:#4b6b8d!important;
}
html.op-theme-dark :is(#registrationOtpGate,#registrationPaymentSection,#razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,.direct-purchase-agreement,.autopay-agreement-note) :is(h3,h4,strong,p,label,span,small,div){color:#e2e8f0!important}
html.op-theme-dark :is(
  #paymentCheckoutStatus,#registrationOtpStatus,#registrationLocationStatus,#signUpStatusMsg,
  #signupPlanDiscountNote,#razorpayPlanSummary,#referralAppliedLabel,
  #trialUpgradeStatus,#renewalStatusMsg,#renewalReferralYearRewardStatus,
  #referralActivationStatus,#walletStatus,#purchaseHistoryStatus,#bookmarkEditorStatus
){color:#bfdbfe!important}

/* ---------- workspace-wide readable ink ---------- */
body.op-light #mainApp{
  color:#172033!important;
  --ws-text:#172033;--ws-muted:#52627a;--ws-line:#cbd5e1;--ws-input:#fff;
}
body.op-light #mainApp :is(
  .container,.tab-content,.control-panel,.upload-box,.preview-box,.preview-container,
  .history-table-container,.business-maker-panel,.business-preview-panel,
  .bulk-auto-launch-card,.bulk-auto-review-row,.bulk-auto-add-more-card,
  .bulk-auto-manual-card,.pp-five-a4,.pp-five-slot,.customize-tools-panel,
  #resumeTemplatePicker,#pdf-premium-card
){color:#172033!important}
body.op-light #mainApp .tab-content :is(h1,h2,h3,h4,h5,h6,strong,b,legend,summary,td,th,output){
  color:#172033!important;-webkit-text-fill-color:initial!important;text-shadow:none!important;
}
body.op-light #mainApp .tab-content :is(p,label,small,figcaption){color:#475569!important}
body.op-light #mainApp :is(.control-panel,.upload-box,.preview-box,.preview-container,.business-maker-panel,.business-preview-panel,.bulk-auto-review-row,.bulk-auto-add-more-card,.bulk-auto-manual-card) :is(span,strong,b){color:#334155!important}
body.op-light #mainApp :is(input:not([type="color"]),select,textarea,[contenteditable="true"]){
  background:#fff!important;color:#172033!important;border-color:#94a3b8!important;caret-color:#172033!important;
}
body.op-light #mainApp :is(input,textarea)::placeholder{color:#64748b!important;opacity:1!important}
body.op-light #mainApp select option{background:#fff!important;color:#172033!important}
body.op-light #mainApp :is(.universal-export-panel,.added-card-row,.portal-preview-zoom-toolbar,.customize-tools-dialog){
  background:#f8fafc!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light #mainApp .dashboard-group-title{color:#172033!important;border-color:#cbd5e1!important}
body.op-light #mainApp .dashboard-card{background:#fff!important;color:#243b69!important}
body.op-light #mainApp .dashboard-card:after{color:#52627a!important}
body.op-light #mainApp .portal-bookmark-slot{color:#475569!important}
body.op-light #mainApp .portal-bookmark-slot:hover,
body.op-light #mainApp .portal-bookmark-slot:focus-visible{color:#172033!important}

/* Primary/coloured actions keep a white foreground in light mode. */

body.op-light #mainApp .tab-btn.active,
body.op-light #mainApp .tab-btn.active :is(span,strong,b,small){color:#fff!important}

/* Editors and tool chrome follow the selected theme; generated pages/canvases
   remain document-white and are deliberately not recoloured. */
body.op-light #mainApp :is(.pro-pdf-editor,.premium-card-editor,.resume-voice-editor){
  background:#fff!important;color:#172033!important;border-color:#cbd5e1!important;box-shadow:0 10px 26px #17203314!important;
}
body.op-light #mainApp .pro-pdf-editor :is(.pro-pdf-head,.pro-pdf-filebar,.pro-pdf-toolbar,.pro-pdf-sidebar,.pro-pdf-selection-info,.pro-pdf-stage,.pro-pdf-preview),
body.op-light #mainApp .premium-card-editor :is(.premium-card-editor-head,.premium-card-editor-toolbar),
body.op-light #mainApp .resume-voice-editor{
  background:#f8fafc!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light #mainApp :is(.pro-pdf-editor,.premium-card-editor,.resume-voice-editor) :is(h2,h3,h4,p,label,span,strong,small){color:#334155!important}
body.op-light #mainApp :is(.pro-pdf-editor,.premium-card-editor,.resume-voice-editor) :is(input,select,textarea){
  background:#fff!important;color:#172033!important;border-color:#94a3b8!important;
}
body.op-light #mainApp .resume-chat-log{background:#f8fafc!important;border-color:#cbd5e1!important}
body.op-light #mainApp .resume-chat-message.assistant{background:#e0f2fe!important;color:#164e63!important}
body.op-light #mainApp .resume-chat-message.user{background:#dbeafe!important;color:#1e3a8a!important}
body.op-light #mainApp :is(.pdf-unlock-shell,.pdf-office-shell) :is(h1,h2,h3,h4,strong,p,label,span,small){color:#334155!important}
body.op-light #mainApp :is(.pdf-unlock-shell,.pdf-office-shell) :is(input,select,textarea){background:#fff!important;color:#172033!important}

/* ---------- My Account, history and admin ---------- */
body.op-light #mainApp #tab-my-account :is(#referralPanel,.account-support-actions,.referral-stat-card){
  background:#f8fafc!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light #mainApp #tab-my-account :is(#referralPanel,.account-support-actions,.referral-stat-card) :is(h2,h3,h4,strong,label,span){color:#172033!important}
body.op-light #mainApp #tab-my-account :is(#referralPanel,.account-support-actions,.referral-stat-card) :is(p,small){color:#52627a!important}
body.op-light #mainApp :is(.history-table-container,.history-table){background:#fff!important;color:#172033!important;border-color:#cbd5e1!important}
body.op-light #mainApp .history-table th{background:#eef4ff!important;color:#172033!important;border-color:#cbd5e1!important}
body.op-light #mainApp .history-table td{background:#fff!important;color:#172033!important;border-color:#dbe3ed!important}




/* ---------- business tools / UDID / billing ---------- */
body.op-light #mainApp :is(.business-maker-panel,.business-preview-panel,.billing-brand-box,.vc-extra-text-editor,.udid-qr-history-row){
  background:#fff!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light #mainApp :is(.business-maker-panel,.business-preview-panel,.billing-brand-box,.vc-extra-text-editor,.udid-qr-history-row) :is(h3,h4,strong,label,span){color:#172033!important}
body.op-light #mainApp :is(.business-maker-panel,.business-preview-panel,.billing-brand-box,.vc-extra-text-editor,.udid-qr-history-row) :is(p,small){color:#52627a!important}
body.op-light #mainApp :is(.business-maker-grid,.udid-qr-signature) :is(input,select,textarea){background:#fff!important;color:#172033!important;border-color:#94a3b8!important}
body.op-light #mainApp :is(.business-mode-switch button,.business-template-chip,.billing-design-toggle,.billing-mini-stepper){
  background:#f8fafc!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light #mainApp :is(.business-mode-switch button.active,.business-template-chip.active,.billing-design-toggle.is-active){
  color:#075985!important;border-color:#38bdf8!important;
}
body.op-light #mainApp :is(.udid-qr-legal,.udid-qr-consent,.udid-qr-charge-note){color:inherit!important}

/* ---------- top-layer dialogs that sit outside normal tab surfaces ---------- */
body.op-light :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog,.info-modal-card
){
  background:#fff!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog,.info-modal-card
) :is(h1,h2,h3,h4,strong,b,legend,summary,span){
  color:#172033!important;-webkit-text-fill-color:initial!important;
}
body.op-light :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog,.info-modal-card
) :is(p,label,small,li,figcaption){color:#475569!important}
body.op-light :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog
) :is(input,select,textarea){
  background:#fff!important;color:#172033!important;border-color:#94a3b8!important;
}
body.op-light :is(#purchaseHistoryClose,#accountDeleteRequestClose,.wallet-dialog-close,.info-modal-close){color:#334155!important}
body.op-light #purchaseHistoryDialog :is(.purchase-history-card,.purchase-history-field,.purchase-history-empty){
  background:#f8fafc!important;color:#172033!important;border-color:#cbd5e1!important;
}
body.op-light #purchaseHistoryDialog :is(.purchase-history-plan-title,.purchase-history-value){color:#172033!important}
body.op-light #purchaseHistoryDialog :is(.purchase-history-key,.purchase-history-meta,.purchase-history-empty){color:#52627a!important}
body.op-light #purchaseHistoryDialog .purchase-history-amount{color:#047857!important}
body.op-light #accountLocationDialogStatus{background:#f8fafc!important;color:#475569!important;border-color:#cbd5e1!important}
body.op-light :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog
) :is(.action-btn,.login-btn,[type="submit"],.utility-primary-btn,.btn-add,.btn-download),
body.op-light :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog
) :is(.action-btn,.login-btn,[type="submit"],.utility-primary-btn,.btn-add,.btn-download) :is(span,strong,b,small){
  color:#fff!important;
}

/* Dark dialog/workspace safety: business-tools.css loads late, so repeat the
   dark authority here after it. */
html.op-theme-dark #mainApp{color:#f1f5f9!important}
html.op-theme-dark #mainApp .tab-content :is(h1,h2,h3,h4,h5,h6,strong,b,legend,summary,td,th,output){color:#f1f5f9!important;-webkit-text-fill-color:initial!important}
html.op-theme-dark #mainApp .tab-content :is(p,label,small,figcaption){color:#cbd5e1!important}
html.op-theme-dark #mainApp :is(input:not([type="color"]),select,textarea,[contenteditable="true"]){
  background:#0b1321!important;color:#f8fafc!important;border-color:#52657d!important;caret-color:#fff!important;
}
html.op-theme-dark #mainApp :is(input,textarea)::placeholder{color:#94a3b8!important;opacity:1!important}
html.op-theme-dark #mainApp select option{background:#111827!important;color:#f8fafc!important}
html.op-theme-dark #mainApp :is(.business-maker-panel,.business-preview-panel,.billing-brand-box,.vc-extra-text-editor,.udid-qr-history-row,.business-mode-switch button,.business-template-chip,.billing-design-toggle,.billing-mini-stepper){
  background:#172337!important;color:#f1f5f9!important;border-color:#475569!important;
}
html.op-theme-dark #mainApp :is(.business-maker-panel,.business-preview-panel,.billing-brand-box,.vc-extra-text-editor,.udid-qr-history-row) :is(h3,h4,strong,label,span){color:#f1f5f9!important}
html.op-theme-dark #mainApp :is(.business-maker-panel,.business-preview-panel,.billing-brand-box,.vc-extra-text-editor,.udid-qr-history-row) :is(p,small){color:#cbd5e1!important}
html.op-theme-dark :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog,.info-modal-card
){
  background:#111b2b!important;color:#f1f5f9!important;border-color:#475569!important;
}
html.op-theme-dark :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog,.info-modal-card
) :is(h1,h2,h3,h4,strong,b,legend,summary,span){color:#f1f5f9!important;-webkit-text-fill-color:initial!important}
html.op-theme-dark :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog,.info-modal-card
) :is(p,label,small,li,figcaption){color:#cbd5e1!important}
html.op-theme-dark :is(
  #accountLocationVerificationDialog,#accountRecoveryDialog,#adminTwoFactorDialog,
  #landingWhatsAppDialog,#landingFeedbackDialog,#quickCalculatorDialog,#quickCashTallyDialog,
  #bookmarkEditorDialog,#customizeToolsDialog,#bulkAutoManualCropDialog,#bulkAutoAddMoreDialog,
  #np-password-dialog,#walletDialog,#udidQrUnlockDialog,#udidQrConfirmDialog,
  #referralActivationDialog,#accountChatDialog,#refundRequestDialog,
  #purchaseHistoryDialog,#accountDeleteRequestDialog,#trialUpgradeDialog
) :is(input,select,textarea){background:#0b1321!important;color:#f8fafc!important;border-color:#52657d!important}
html.op-theme-dark #purchaseHistoryDialog :is(.purchase-history-card,.purchase-history-field,.purchase-history-empty){
  background:#172337!important;color:#f1f5f9!important;border-color:#475569!important;
}
html.op-theme-dark #purchaseHistoryDialog :is(.purchase-history-plan-title,.purchase-history-value){color:#f8fafc!important}
html.op-theme-dark #purchaseHistoryDialog :is(.purchase-history-key,.purchase-history-meta,.purchase-history-empty){color:#cbd5e1!important}
html.op-theme-dark #purchaseHistoryDialog .purchase-history-amount{color:#86efac!important}
html.op-theme-dark #accountLocationDialogStatus{background:#172337!important;color:#cbd5e1!important;border-color:#475569!important}

/* Preserve semantic feedback colours after the broad theme rules. */
body.op-light :is([data-error="true"],.error-msg,.field-error,.status-error){color:#b91c1c!important}
html.op-theme-dark :is([data-error="true"],.error-msg,.field-error,.status-error){color:#fecaca!important}
body.op-light :is(.success-msg,[data-success="true"],.status-success){color:#047857!important}
html.op-theme-dark :is(.success-msg,[data-success="true"],.status-success){color:#86efac!important}

/* Disabled text remains readable rather than disappearing. */
body.op-light :is(button,input,select,textarea):disabled{opacity:.64}
html.op-theme-dark :is(button,input,select,textarea):disabled{opacity:.68}

/* Dark auth navigation must stay readable on the #111b2b authentication card. */
html.op-theme-dark .portal-auth-card .auth-link{color:#93c5fd!important;}


/* ===== public-landing-browser-consistency-20261005 =====
   The public landing is intentionally a light/readable marketing surface.
   A saved workspace dark-theme preference must never turn its copy white on
   white panels. This final layer is deliberately scoped to the public landing
   and does not change authenticated workspace, payment, tool or admin UI. */
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > .front-hero,
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > #landingArticles{
  opacity:1!important;
  filter:none!important;
  color:#172033!important;
}
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > .front-hero h1,
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > #landingArticles h2{
  color:#172033!important;
  -webkit-text-fill-color:#172033!important;
  opacity:1!important;
  text-shadow:none!important;
}
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > .front-hero p,
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > #landingArticles p{
  color:#475569!important;
  -webkit-text-fill-color:#475569!important;
  opacity:1!important;
  text-shadow:none!important;
}
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > #landingArticles .landing-articles-heading>span{
  color:#087d8a!important;
  -webkit-text-fill-color:#087d8a!important;
  opacity:1!important;
}
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home > #landingArticles .landing-articles-link{
  color:#1f6cc4!important;
  -webkit-text-fill-color:#1f6cc4!important;
  opacity:1!important;
}
/* The SI mark always sits on a pale badge; force a dark glyph even when
   broader nav/theme selectors make all nav spans white. */
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home .front-nav .skillo-logo-box{
  background:linear-gradient(145deg,#fff,#c9eef0)!important;
  border-color:rgba(255,255,255,.82)!important;
}
html:not(.workspace-route) body.public-landing-active #loginScreen.front-home .front-nav .skillo-logo-box .skillo-logo-fallback{
  color:#10213a!important;
  -webkit-text-fill-color:#10213a!important;
  opacity:1!important;
  text-shadow:none!important;
}


/* ===== referral-counter-visibility-20261005 =====
   Counter numerals must remain readable even when older component rules or
   browser text-fill state are present. Presentation only. */
body.op-light #mainApp #tab-my-account .referral-stat-card :is(
  #referralQualifiedCount,#referralTokenCount,#referralGiftTokenCount,#referralLevelTokenCount,#referralActivationGiftCount
){
  color:#0f172a!important;
  -webkit-text-fill-color:#0f172a!important;
  opacity:1!important;
  text-shadow:none!important;
}
html.op-theme-dark #mainApp #tab-my-account .referral-stat-card :is(
  #referralQualifiedCount,#referralTokenCount,#referralGiftTokenCount,#referralLevelTokenCount,#referralActivationGiftCount
){
  color:#f8fafc!important;
  -webkit-text-fill-color:#f8fafc!important;
  opacity:1!important;
  text-shadow:none!important;
}


/* ===== fixed-white-auth-popup-20261005 =====
   Login and signup stay white/readable regardless of any saved or manually
   selected workspace theme. This is the final contrast authority for auth. */
#portalAuthPage .portal-auth-card,
html.op-theme-dark #portalAuthPage .portal-auth-card,
body.op-light #portalAuthPage .portal-auth-card{
  background:#ffffff!important;
  color:#172033!important;
  border-color:#cbd5e1!important;
  color-scheme:light!important;
}
#portalAuthPage .portal-auth-header,
html.op-theme-dark #portalAuthPage .portal-auth-header{
  background:#f8fafc!important;
  color:#172554!important;
  border-color:#dbe3ed!important;
}
#portalAuthPage .portal-auth-content,
#portalAuthPage .front-auth-panel,
#portalAuthPage #signUpScreen.auth-box,
html.op-theme-dark #portalAuthPage .portal-auth-content,
html.op-theme-dark #portalAuthPage .front-auth-panel,
html.op-theme-dark #portalAuthPage #signUpScreen.auth-box{
  background:#ffffff!important;
  color:#172033!important;
}
#portalAuthPage :is(h1,h2,h3,h4,h5,h6,strong,b,label,legend,summary),
html.op-theme-dark #portalAuthPage :is(h1,h2,h3,h4,h5,h6,strong,b,label,legend,summary){
  color:#172033!important;
  -webkit-text-fill-color:#172033!important;
  text-shadow:none!important;
}
#portalAuthPage :is(p,small,span,li,figcaption),
html.op-theme-dark #portalAuthPage :is(p,small,span,li,figcaption){
  color:#475569!important;
  -webkit-text-fill-color:#475569!important;
  text-shadow:none!important;
}
#portalAuthPage :is(input:not([type="checkbox"]):not([type="radio"]):not([type="color"]),select,textarea),
html.op-theme-dark #portalAuthPage :is(input:not([type="checkbox"]):not([type="radio"]):not([type="color"]),select,textarea){
  background:#ffffff!important;
  color:#172033!important;
  -webkit-text-fill-color:#172033!important;
  border-color:#94a3b8!important;
  caret-color:#172033!important;
  color-scheme:light!important;
}
#portalAuthPage :is(input,textarea)::placeholder,
html.op-theme-dark #portalAuthPage :is(input,textarea)::placeholder{
  color:#64748b!important;
  -webkit-text-fill-color:#64748b!important;
  opacity:1!important;
}
#portalAuthPage :is(
  .human-verification-shell,#registrationLocationBox,#registrationOtpGate,#registrationPaymentSection,
  #razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,
  .direct-purchase-agreement,.autopay-agreement-note
),
html.op-theme-dark #portalAuthPage :is(
  .human-verification-shell,#registrationLocationBox,#registrationOtpGate,#registrationPaymentSection,
  #razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,
  .direct-purchase-agreement,.autopay-agreement-note
){
  background:#f8fafc!important;
  color:#334155!important;
  border-color:#cbd5e1!important;
}
#portalAuthPage :is(
  .human-verification-shell,#registrationLocationBox,#registrationOtpGate,#registrationPaymentSection,
  #razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,
  .direct-purchase-agreement,.autopay-agreement-note
) :is(h1,h2,h3,h4,strong,b,label,span,p,small,div),
html.op-theme-dark #portalAuthPage :is(
  .human-verification-shell,#registrationLocationBox,#registrationOtpGate,#registrationPaymentSection,
  #razorpaySignupPanel,#trialRegistrationPanel,.refund-agreement-surface,.signup-policy-consent,
  .direct-purchase-agreement,.autopay-agreement-note
) :is(h1,h2,h3,h4,strong,b,label,span,p,small,div){
  color:#334155!important;
  -webkit-text-fill-color:#334155!important;
}
#portalAuthPage .portal-auth-brand{
  color:#172554!important;
  -webkit-text-fill-color:#172554!important;
}
#portalAuthPage :is(.portal-auth-home-link,.auth-link,a:not(.login-btn)){
  color:#1d4ed8!important;
  -webkit-text-fill-color:#1d4ed8!important;
}
#portalAuthPage .login-btn,
html.op-theme-dark #portalAuthPage .login-btn{
  background:#2563eb!important;
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
}
#portalAuthPage .login-btn :is(span,strong,b,small),
html.op-theme-dark #portalAuthPage .login-btn :is(span,strong,b,small){
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
}
#portalAuthPage .payment-plan-choice,
html.op-theme-dark #portalAuthPage .payment-plan-choice{
  background:#ffffff!important;
  color:#172033!important;
  border-color:#94a3b8!important;
}
#portalAuthPage .payment-plan-choice :is(strong,small,span),
html.op-theme-dark #portalAuthPage .payment-plan-choice :is(strong,small,span){
  color:#172033!important;
  -webkit-text-fill-color:#172033!important;
}
#portalAuthPage .payment-plan-choice[aria-pressed="true"],
html.op-theme-dark #portalAuthPage .payment-plan-choice[aria-pressed="true"]{
  background:linear-gradient(135deg,#2563eb,#0e7490)!important;
  color:#ffffff!important;
  border-color:#1d4ed8!important;
}
#portalAuthPage .payment-plan-choice[aria-pressed="true"] :is(strong,small,span),
html.op-theme-dark #portalAuthPage .payment-plan-choice[aria-pressed="true"] :is(strong,small,span){
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
}
#portalAuthPage #errorMsg{
  color:#b91c1c!important;
  -webkit-text-fill-color:#b91c1c!important;
}
