/**
 * Text Contrast Fixes
 * Ensures all text is readable on light backgrounds
 * Fixes white text on light backgrounds across all interfaces
 */

/* ========================================
   MODAL & POP-UP FIXES
   ======================================== */

/* All modals and pop-ups */
.modal,
.popup,
.dialog,
.alert,
.notification,
.toast,
.message-box {
  color: #333 !important;
}

.modal-content,
.popup-content,
.dialog-content {
  color: #333 !important;
}

.modal-title,
.popup-title,
.dialog-title {
  color: #212121 !important;
}

.modal-body,
.popup-body,
.dialog-body {
  color: #424242 !important;
}

/* Modal text elements */
.modal p,
.modal span,
.modal label,
.popup p,
.popup span,
.popup label {
  color: #333 !important;
}

/* ========================================
   FORM ELEMENTS ON LIGHT BACKGROUNDS
   ======================================== */

/* Form labels on light backgrounds */
.form-group label,
.input-label,
form label {
  color: #333 !important;
}

/* Input placeholders */
input::placeholder,
textarea::placeholder,
select::placeholder {
  color: #757575 !important;
}

/* Form helper text */
.form-help,
.help-text,
.form-hint {
  color: #616161 !important;
}

/* ========================================
   CARD & PANEL TEXT
   ======================================== */

/* Cards with light backgrounds */
.card:not([class*="gradient"]):not([class*="primary"]):not([class*="accent"]) {
  color: #333 !important;
}

.card-body,
.card-content {
  color: #424242 !important;
}

.card-title:not(.dashboard-welcome .card-title) {
  color: #212121 !important;
}

.card-text {
  color: #616161 !important;
}

/* ========================================
   TABLE FIXES
   ======================================== */

/* Table body text */
table tbody td {
  color: #333 !important;
}

/* Table headers - dark text for light backgrounds */
table thead th {
  color: #333 !important;
}

/* ========================================
   BUTTON TEXT FIXES
   ======================================== */

/* Secondary and outline buttons */
.btn-secondary,
.btn-outline,
.btn-light {
  color: #333 !important;
}

.btn-secondary:hover,
.btn-outline:hover {
  color: #fff !important;
}

/* ========================================
   SPECIFIC INTERFACE FIXES
   ======================================== */

/* Admin Interface */
.admin-interface .card:not([class*="gradient"]) .card-title {
  color: #212121 !important;
}

.admin-interface .form-label {
  color: #333 !important;
}

.admin-interface .input-group-text {
  color: #333 !important;
}

/* Settings panels */
.settings-panel,
.profile-panel {
  color: #333 !important;
}

.settings-panel label,
.profile-panel label {
  color: #333 !important;
}

/* System tab */
.system-settings,
.system-config {
  color: #333 !important;
}

.system-settings label,
.system-config label {
  color: #333 !important;
}

/* ========================================
   DROPDOWN & SELECT FIXES
   ======================================== */

/* Dropdown menus */
.dropdown-menu {
  color: #333 !important;
}

.dropdown-item {
  color: #333 !important;
}

.dropdown-item:hover {
  color: #fff !important;
  background-color: var(--primary-color, #673AB7);
}

/* Select elements */
select option {
  color: #333 !important;
  background: white !important;
}

/* ========================================
   LIST & MENU FIXES
   ======================================== */

/* List items on light backgrounds */
.list-group-item {
  color: #333 !important;
}

.list-item {
  color: #333 !important;
}

/* Menu items */
.menu-item:not(.active) {
  color: #333 !important;
}

/* ========================================
   NOTIFICATION & ALERT FIXES
   ======================================== */

/* Success alerts */
.alert-success {
  color: #1B5E20 !important;
  background-color: #E8F5E9 !important;
}

/* Info alerts */
.alert-info {
  color: #01579B !important;
  background-color: #E1F5FE !important;
}

/* Warning alerts */
.alert-warning {
  color: #E65100 !important;
  background-color: #FFF3E0 !important;
}

/* Error alerts */
.alert-error,
.alert-danger {
  color: #B71C1C !important;
  background-color: #FFEBEE !important;
}

/* Toast notifications */
.toast {
  color: #333 !important;
}

.toast-success {
  color: #1B5E20 !important;
  background-color: #E8F5E9 !important;
}

.toast-error {
  color: #B71C1C !important;
  background-color: #FFEBEE !important;
}

/* ========================================
   BADGE & TAG FIXES
   ======================================== */

/* Badges on light backgrounds */
.badge-light,
.badge-secondary {
  color: #333 !important;
  background-color: #E0E0E0 !important;
}

/* Tags */
.tag:not([class*="primary"]):not([class*="accent"]) {
  color: #333 !important;
}

/* ========================================
   TAB & NAVIGATION FIXES
   ======================================== */

/* Tabs */
.tab:not(.active) {
  color: #333 !important;
}

.tab-content {
  color: #333 !important;
}

/* Breadcrumbs */
.breadcrumb-item:not(.active) {
  color: #616161 !important;
}

/* ========================================
   SPECIFIC COMPONENT FIXES
   ======================================== */

/* User profile sections */
.profile-info,
.user-details {
  color: #333 !important;
}

.profile-info label,
.user-details label {
  color: #616161 !important;
}

/* Settings sections */
.setting-item {
  color: #333 !important;
}

.setting-item label {
  color: #333 !important;
}

.setting-description {
  color: #757575 !important;
}

/* Dashboard stats on light backgrounds */
.stat-card:not([class*="gradient"]) {
  color: #333 !important;
}

.stat-card:not([class*="gradient"]) h4,
.stat-card:not([class*="gradient"]) .stat-title {
  color: #333 !important;
}

.stat-value {
  color: #212121 !important;
}

.stat-label {
  color: #616161 !important;
}

/* Fix stat-change and stat-trend text visibility */
.stat-change,
.stat-trend {
  color: #4CAF50 !important; /* Green for positive */
  font-weight: 500 !important;
}

.stat-change.negative {
  color: #F44336 !important; /* Red for negative */
}

/* Fix light text in stat cards */
.stat-card .stat-content p:not(.stat-value) {
  color: #616161 !important;
}

/* ========================================
   OWNER INTERFACE SPECIFIC
   ======================================== */

/* Add user/restaurant forms */
.add-user-form,
.add-restaurant-form {
  color: #333 !important;
}

.add-user-form label,
.add-restaurant-form label {
  color: #333 !important;
}

/* Staff management */
.staff-list,
.staff-item {
  color: #333 !important;
}

.staff-card {
  color: #333 !important;
}

.staff-card .staff-name {
  color: #212121 !important;
}

.staff-card .staff-role,
.staff-card .staff-status,
.staff-card .staff-info {
  color: #616161 !important;
}

/* Staff card text overflow fix */
.staff-card {
  overflow: hidden;
}

.staff-card .staff-name,
.staff-card .staff-email {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* ========================================
   MANAGER INTERFACE SPECIFIC
   ======================================== */

/* Schedule view */
.schedule-grid:not(.header) {
  color: #333 !important;
}

.schedule-cell:not(.header) {
  color: #333 !important;
}

/* Operations section text fixes */
.operations-content,
.operations-stats {
  color: #333 !important;
}

.operations-content label,
.operations-stats label {
  color: #333 !important;
}

/* Alert and notification text in manager dashboard */
.manager-interface .alert-item,
.manager-interface .notification-item {
  color: #333 !important;
}

/* Task list */
.task-item {
  color: #333 !important;
}

.task-description {
  color: #616161 !important;
}

/* ========================================
   CUSTOMER INTERFACE SPECIFIC
   ======================================== */

/* Restaurant cards */
.restaurant-card {
  color: #333 !important;
}

.restaurant-name {
  color: #212121 !important;
}

.restaurant-info {
  color: #616161 !important;
}

/* Review forms */
.review-form {
  color: #333 !important;
}

.review-form label {
  color: #333 !important;
}

/* ========================================
   WAITER INTERFACE SPECIFIC
   ======================================== */

/* Table status */
.table-status:not(.occupied):not(.reserved) {
  color: #333 !important;
}

/* Order items */
.order-item {
  color: #333 !important;
}

.order-details {
  color: #616161 !important;
}

/* ========================================
   ACCESSIBILITY IMPROVEMENTS
   ======================================== */

/* Ensure minimum contrast ratio (WCAG AA) */
.text-muted {
  color: #616161 !important;
}

.text-secondary {
  color: #757575 !important;
}

/* Fix specific dashboard text contrast issues */
.dashboard-content p,
.dashboard-content span:not(.badge):not(.stat-value) {
  color: #424242 !important;
}

/* Fix header actions text */
.header-actions .quick-actions button {
  color: #333 !important;
}

.header-actions .quick-actions button:hover {
  color: #212121 !important;
}

/* Fix empty state text */
.empty-state p {
  color: #616161 !important;
}

/* Fix hint text visibility */
.hint-text,
.help-text {
  color: #757575 !important;
}

/* Focus states */
*:focus {
  outline: 2px solid #673AB7 !important;
  outline-offset: 2px !important;
}

/* ========================================
   PRINT STYLES
   ======================================== */

@media print {
  * {
    color: #000 !important;
    background: white !important;
  }
}

/* ========================================
   DARK MODE EXCEPTIONS
   ======================================== */

@media (prefers-color-scheme: dark) {
  /* Revert fixes for dark mode */
  body.dark-mode .modal,
  body.dark-mode .popup,
  body.dark-mode .card {
    color: #E0E0E0 !important;
  }
}

/* ========================================
   ADDITIONAL TEXT CONTRAST FIXES (2025-11-26)
   ======================================== */

/* Main content text - ensure dark text */
.main-content,
.dashboard-content,
.content-area,
.tab-content,
main {
  color: #333 !important;
}

/* All paragraph text */
p:not([class*="white"]):not([style*="color: white"]):not([style*="color:#fff"]) {
  color: #424242 !important;
}

/* All span text except badges and status indicators */
span:not(.badge):not(.status):not(.tag):not([class*="white"]):not([style*="color: white"]) {
  color: #424242 !important;
}

/* Input text */
input:not([type="button"]):not([type="submit"]),
textarea,
select {
  color: #333 !important;
}

/* Section headers */
.section-header h2,
.section-header p,
.section-title,
.section-description {
  color: #333 !important;
}

/* Overview sections */
.overview-stats,
.stats-overview,
.quick-stats {
  color: #333 !important;
}

/* Filter groups */
.filter-group label,
.filter-item label,
.filter-controls label {
  color: #333 !important;
}

/* Report and analytics text */
.report-item,
.report-info,
.report-stats,
.analytics-card {
  color: #333 !important;
}

/* Shift and schedule displays */
.shift-status-banner,
.shift-info,
.schedule-info,
#shift-time-display {
  color: #333 !important;
}

/* Notification dropdowns */
.notifications-dropdown .dropdown-content,
.notifications-list,
.notification-message,
.notification-title {
  color: #333 !important;
}

/* User management */
.user-table td,
.user-info,
.user-details p,
.user-email {
  color: #333 !important;
}

/* Restaurant cards and info */
.restaurant-card p,
.restaurant-info p,
.restaurant-details {
  color: #424242 !important;
}

/* Fix any inline white text on cards with light backgrounds */
.card:not([style*="gradient"]):not([style*="background: #"]):not([style*="background:#"]) p,
.card:not([style*="gradient"]):not([style*="background: #"]):not([style*="background:#"]) span:not(.badge) {
  color: #424242 !important;
}

/* Fix stat cards specifically */
.stat-card .stat-content,
.stat-card .stat-label,
.stat-card p {
  color: #616161 !important;
}

.stat-card .stat-value,
.stat-card h3,
.stat-card h4 {
  color: #212121 !important;
}

/* Fix dashboard section titles */
h2, h3, h4, h5 {
  color: #212121 !important;
}

/* Fix light gray text that's hard to read */
[style*="color: #999"],
[style*="color:#999"],
[style*="color: #aaa"],
[style*="color:#aaa"],
[style*="color: #bbb"],
[style*="color:#bbb"],
[style*="color: #ccc"],
[style*="color:#ccc"] {
  color: #616161 !important;
}

/* Fix secondary text that might be too light */
.text-muted,
.text-secondary,
.text-gray,
.text-light {
  color: #616161 !important;
}

/* Performance metrics */
.performance-stats p,
.performance-card p {
  color: #424242 !important;
}

/* Task items */
.task-item p,
.task-card p,
.task-details {
  color: #424242 !important;
}

/* Schedule cells */
.schedule-cell p,
.schedule-item p {
  color: #333 !important;
}

/* Table cells - ensure readable */
td {
  color: #333 !important;
}

/* Fix overview card descriptions */
.overview-stats .stat-card p,
.overview-stats .stat-label {
  color: #616161 !important;
}

/* ========================================
   IMPORTANT OVERRIDES
   ======================================== */

/* Ensure these take precedence */
.light-bg,
.white-bg,
.bg-light,
.bg-white {
  color: #333 !important;
}

.light-bg *:not(.btn):not(.badge),
.white-bg *:not(.btn):not(.badge),
.bg-light *:not(.btn):not(.badge),
.bg-white *:not(.btn):not(.badge) {
  color: #333 !important;
}

/* Preserve gradient text colors */
[class*="gradient"] h1,
[class*="gradient"] h2,
[class*="gradient"] h3,
[class*="gradient"] .card-title {
  color: white !important;
}

/* Preserve primary button colors */
.btn-primary,
.btn-accent,
[class*="primary-btn"],
[class*="accent-btn"] {
  color: white !important;
}

/* Preserve navigation colors - EXPLICIT WHITE TEXT */
.sidebar,
.nav-sidebar,
.sidebar *,
.nav-sidebar *,
.sidebar .nav-link,
.sidebar .nav-link span,
.sidebar .material-icons {
  color: white !important;
}

/* Preserve colored card text */
[style*="background: linear-gradient"] *,
[style*="background:linear-gradient"] *,
[style*="background-image: linear-gradient"] *,
[style*="background-image:linear-gradient"] *,
[style*="background: #673AB7"] *,
[style*="background:#673AB7"] *,
[style*="background: #9C27B0"] *,
[style*="background:#9C27B0"] *,
[style*="background: #4CAF50"] *,
[style*="background:#4CAF50"] *,
[style*="background: #FF9800"] *,
[style*="background:#FF9800"] *,
[style*="background: #2196F3"] *,
[style*="background:#2196F3"] * {
  color: white !important;
}

.promo-card,
.promo-card *,
.validation-success,
.validation-success *,
.validation-error,
.validation-error *,
.btn-primary,
.btn-primary *,
.btn-waiter,
.btn-waiter *,
.btn-admin,
.btn-admin *,
.btn-owner,
.btn-owner *,
.btn-manager,
.btn-manager * {
  color: white !important;
}

.modal-content,
.modal-content p,
.modal-content span:not(.badge):not(.promo-type):not(.status-badge),
.modal-content label,
.modal-content h2,
.modal-content h3,
.modal-content h4 {
  color: #212121 !important;
}

.modal-content .btn-primary,
.modal-content .btn-primary *,
.modal-content .btn-waiter,
.modal-content .btn-waiter *,
.modal-content [style*="background: #4285F4"],
.modal-content [style*="background: #4285F4"] *,
.modal-content [style*="background: #34A853"],
.modal-content [style*="background: #34A853"] * {
  color: white !important;
}

/* Preserve badge text on colored backgrounds */
.badge[style*="background"],
.status-badge[style*="background"],
.tag[style*="background"] {
  color: white !important;
}

/* Preserve rating display text */
[style*="background: #4CAF50"][style*="color: white"],
[style*="background:#4CAF50"][style*="color: white"] {
  color: white !important;
}

/* Preserve claim code section white text */
#claim-code-section,
#claim-code-section * {
  color: white !important;
}

/* Preserve connoisseur card white text (customer dashboard) */
.card[style*="gradient"] h3,
.card[style*="gradient"] p,
.card[style*="gradient"] span {
  color: white !important;
}

/* ========================================
   DASHBOARD HEADER FIXES
   ======================================== */

/* Dashboard header text - ensure dark readable text */
.dashboard-header,
.dashboard-header h1,
.dashboard-header h2,
.dashboard-header h3,
.dashboard-header .page-title,
.dashboard-header #page-title,
.header-title,
.page-header,
.page-header h1,
.page-header h2 {
  color: #212121 !important;
}

/* Header breadcrumb */
.breadcrumb,
.breadcrumb span,
#breadcrumb,
#breadcrumb span {
  color: #666 !important;
}

/* User name in header */
.user-name,
#user-name,
.header-user-name {
  color: #333 !important;
}

/* Welcome text */
.welcome-text,
.welcome-message,
#welcome-name {
  color: #333 !important;
}

/* Header actions icons - dark for visibility */
.header-actions .material-icons,
.dashboard-header .material-icons:not(.sidebar .material-icons) {
  color: #333 !important;
}

/* Waiter dashboard specific header fixes */
body.waiter-dashboard .dashboard-header,
body.waiter-dashboard .page-title,
body.waiter-dashboard .header-title {
  color: #212121 !important;
}

/* Waiter dashboard header h1 fix - ensure dark readable text */
.waiter-interface .header h1,
.waiter-interface .header #page-title,
.waiter-interface #page-title,
body.waiter-dashboard .header h1,
body.waiter-dashboard #page-title {
  color: #212121 !important;
}

/* Manager dashboard specific header fixes */
body.manager-dashboard .dashboard-header,
body.manager-dashboard .page-title,
body.manager-dashboard .header-title {
  color: #212121 !important;
}

/* Owner dashboard specific header fixes */
body.owner-dashboard .dashboard-header,
body.owner-dashboard .page-title,
body.owner-dashboard .header-title {
  color: #212121 !important;
}

/* ========================================
   DARK THEME SUPPORT
   ======================================== */

/* Dark theme base styles */
body.dark-theme {
  background-color: #1a1a2e !important;
  color: #e0e0e0 !important;
}

body.dark-theme .main-content {
  background-color: #1a1a2e !important;
}

body.dark-theme .dashboard-container {
  background-color: #1a1a2e !important;
}

/* Dark theme header - ensure readable text */
body.dark-theme .dashboard-header,
body.dark-theme .dashboard-header h1,
body.dark-theme .dashboard-header h2,
body.dark-theme .dashboard-header h3,
body.dark-theme .page-title,
body.dark-theme #page-title,
body.dark-theme .header-title {
  color: #ffffff !important;
}

body.dark-theme .breadcrumb,
body.dark-theme .breadcrumb span,
body.dark-theme #breadcrumb,
body.dark-theme #breadcrumb span {
  color: #b0b0b0 !important;
}

body.dark-theme .user-name,
body.dark-theme #user-name,
body.dark-theme .header-user-name {
  color: #e0e0e0 !important;
}

/* Dark theme cards */
body.dark-theme .card {
  background-color: #16213e !important;
  border-color: #0f3460 !important;
  color: #e0e0e0 !important;
}

body.dark-theme .card-title,
body.dark-theme .card-title h3 {
  color: #ffffff !important;
}

body.dark-theme .card-content,
body.dark-theme .card-body {
  color: #c0c0c0 !important;
}

/* Dark theme forms */
body.dark-theme input,
body.dark-theme select,
body.dark-theme textarea {
  background-color: #0f3460 !important;
  border-color: #1a1a2e !important;
  color: #e0e0e0 !important;
}

body.dark-theme input::placeholder,
body.dark-theme textarea::placeholder {
  color: #808080 !important;
}

body.dark-theme label {
  color: #c0c0c0 !important;
}

/* Dark theme tables */
body.dark-theme table {
  background-color: #16213e !important;
}

body.dark-theme th {
  background-color: #0f3460 !important;
  color: #ffffff !important;
}

body.dark-theme td {
  color: #e0e0e0 !important;
  border-color: #1a1a2e !important;
}

body.dark-theme tr:hover {
  background-color: #0f3460 !important;
}

/* Dark theme modals */
body.dark-theme .modal-content {
  background-color: #16213e !important;
  color: #e0e0e0 !important;
}

body.dark-theme .modal-header {
  border-color: #0f3460 !important;
}

body.dark-theme .modal-title {
  color: #ffffff !important;
}

body.dark-theme .modal-body {
  color: #c0c0c0 !important;
}

/* Dark theme icons in header */
body.dark-theme .header-actions .material-icons,
body.dark-theme .dashboard-header .material-icons:not(.sidebar .material-icons) {
  color: #e0e0e0 !important;
}

/* Dark theme sidebar - keep original colors */
body.dark-theme .sidebar {
  background-color: #0f3460 !important;
}

body.dark-theme .sidebar .nav-link {
  color: #ffffff !important;
}

/* Dark theme stats and metrics */
body.dark-theme .stat-value,
body.dark-theme .metric-value {
  color: #ffffff !important;
}

body.dark-theme .stat-label,
body.dark-theme .metric-label {
  color: #b0b0b0 !important;
}

/* Light theme explicit styles */
body.light-theme {
  background-color: #f5f5f5 !important;
  color: #333333 !important;
}

body.light-theme .main-content {
  background-color: #f5f5f5 !important;
}

body.light-theme .card {
  background-color: #ffffff !important;
  color: #333333 !important;
}

.settings-section,
.settings-section *,
.settings-content,
.settings-content *,
.settings-container,
.settings-container *,
#settings-content,
#settings-content *,
#settings-tab,
#settings-tab *,
[data-tab-content="settings"],
[data-tab-content="settings"] *,
.dunamis-settings-enhanced,
.dunamis-settings-enhanced ~ *,
.password-section,
.password-section *,
.setting-info,
.setting-info *,
.setting-label,
.setting-description {
  color: #212121 !important;
}

.settings-section,
.setting-item,
.password-section,
.profile-form,
.settings-panel,
.profile-panel {
  background-color: #ffffff;
}

.settings-section h1,
.settings-section h2,
.settings-section h3,
.settings-section h4,
.settings-content h1,
.settings-content h2,
.settings-content h3,
.settings-content h4,
#settings-content h1,
#settings-content h2,
#settings-content h3,
#settings-content h4,
[data-tab-content="settings"] h1,
[data-tab-content="settings"] h2,
[data-tab-content="settings"] h3,
[data-tab-content="settings"] h4 {
  color: #111827 !important;
}

.settings-section p,
.settings-section span:not(.toggle-slider):not(.badge):not(.status-badge),
.settings-section label,
.settings-content p,
.settings-content span:not(.toggle-slider):not(.badge):not(.status-badge),
.settings-content label,
#settings-content p,
#settings-content span:not(.toggle-slider):not(.badge):not(.status-badge),
#settings-content label,
[data-tab-content="settings"] p,
[data-tab-content="settings"] span:not(.toggle-slider):not(.badge):not(.status-badge),
[data-tab-content="settings"] label {
  color: #374151 !important;
}

.settings-section input,
.settings-section select,
.settings-section textarea,
.settings-content input,
.settings-content select,
.settings-content textarea,
#settings-content input,
#settings-content select,
#settings-content textarea,
[data-tab-content="settings"] input,
[data-tab-content="settings"] select,
[data-tab-content="settings"] textarea {
  color: #111827 !important;
  background-color: #ffffff !important;
}

.settings-section .save-btn,
.settings-section .save-btn *,
.settings-section .danger-btn,
.settings-section .danger-btn *,
.settings-section .toggle-switch,
.settings-section .toggle-switch *,
.settings-content .save-btn,
.settings-content .save-btn *,
.settings-content .danger-btn,
.settings-content .danger-btn *,
.settings-content .toggle-switch,
.settings-content .toggle-switch * {
  color: inherit;
}

.settings-section .save-btn,
.settings-section .save-btn *,
.settings-section .danger-btn,
.settings-section .danger-btn *,
.settings-content .save-btn,
.settings-content .save-btn *,
.settings-content .danger-btn,
.settings-content .danger-btn * {
  color: #ffffff !important;
}

body.dark-theme .settings-section,
body.dark-theme .setting-item,
body.dark-theme .password-section,
body.dark-theme .profile-form,
body.dark-theme .settings-panel,
body.dark-theme .profile-panel {
  background-color: #16213e !important;
}

body.dark-theme .settings-section,
body.dark-theme .settings-section *,
body.dark-theme .settings-content,
body.dark-theme .settings-content *,
body.dark-theme #settings-content,
body.dark-theme #settings-content *,
body.dark-theme [data-tab-content="settings"],
body.dark-theme [data-tab-content="settings"] * {
  color: #e5e7eb !important;
}

.modal-overlay .modal-content,
.modal-overlay .modal-content *,
.modal .modal-content,
.modal .modal-content *,
.dunamis-modal .modal-content,
.dunamis-modal .modal-content *,
.popup .popup-content,
.popup .popup-content *,
.dialog .dialog-content,
.dialog .dialog-content *,
[style*="background: white"].modal-content,
[style*="background:white"].modal-content,
[style*="background: #fff"].modal-content,
[style*="background:#fff"].modal-content,
[style*="background: #ffffff"].modal-content,
[style*="background:#ffffff"].modal-content,
[style*="background: white"].modal-content *,
[style*="background:white"].modal-content *,
[style*="background: #fff"].modal-content *,
[style*="background:#fff"].modal-content *,
[style*="background: #ffffff"].modal-content *,
[style*="background:#ffffff"].modal-content * {
  color: #111827 !important;
}

.modal-overlay .modal-header:not([style*="linear-gradient"]):not([style*="background: #"]):not([style*="background:#"]),
.modal .modal-header:not([style*="linear-gradient"]):not([style*="background: #"]):not([style*="background:#"]),
.dunamis-modal .modal-header:not([style*="linear-gradient"]):not([style*="background: #"]):not([style*="background:#"]),
.modal-overlay .modal-body,
.modal .modal-body,
.dunamis-modal .modal-body,
.modal-overlay .modal-footer,
.modal .modal-footer,
.dunamis-modal .modal-footer {
  color: #111827 !important;
}

.modal-overlay .modal-content p,
.modal-overlay .modal-content label,
.modal-overlay .modal-content li,
.modal-overlay .modal-content td,
.modal-overlay .modal-content th,
.modal .modal-content p,
.modal .modal-content label,
.modal .modal-content li,
.modal .modal-content td,
.modal .modal-content th,
.dunamis-modal .modal-content p,
.dunamis-modal .modal-content label,
.dunamis-modal .modal-content li,
.dunamis-modal .modal-content td,
.dunamis-modal .modal-content th {
  color: #111827 !important;
}

.modal-overlay .modal-content h1,
.modal-overlay .modal-content h2,
.modal-overlay .modal-content h3,
.modal-overlay .modal-content h4,
.modal-overlay .modal-content h5,
.modal-overlay .modal-content h6,
.modal .modal-content h1,
.modal .modal-content h2,
.modal .modal-content h3,
.modal .modal-content h4,
.modal .modal-content h5,
.modal .modal-content h6,
.dunamis-modal .modal-content h1,
.dunamis-modal .modal-content h2,
.dunamis-modal .modal-content h3,
.dunamis-modal .modal-content h4,
.dunamis-modal .modal-content h5,
.dunamis-modal .modal-content h6 {
  color: #0f172a !important;
}

.modal-overlay .modal-content input,
.modal-overlay .modal-content select,
.modal-overlay .modal-content textarea,
.modal .modal-content input,
.modal .modal-content select,
.modal .modal-content textarea,
.dunamis-modal .modal-content input,
.dunamis-modal .modal-content select,
.dunamis-modal .modal-content textarea {
  color: #111827 !important;
  background-color: #ffffff !important;
}

.modal-overlay .modal-content input::placeholder,
.modal-overlay .modal-content textarea::placeholder,
.modal .modal-content input::placeholder,
.modal .modal-content textarea::placeholder,
.dunamis-modal .modal-content input::placeholder,
.dunamis-modal .modal-content textarea::placeholder {
  color: #6b7280 !important;
}

.modal-overlay .modal-header[style*="linear-gradient"],
.modal-overlay .modal-header[style*="linear-gradient"] *,
.modal .modal-header[style*="linear-gradient"],
.modal .modal-header[style*="linear-gradient"] *,
.dunamis-modal .modal-header[style*="linear-gradient"],
.dunamis-modal .modal-header[style*="linear-gradient"] *,
.modal-overlay .modal-content .primary-button,
.modal-overlay .modal-content .primary-button *,
.modal-overlay .modal-content .btn-primary,
.modal-overlay .modal-content .btn-primary *,
.modal-overlay .modal-content button[type="submit"],
.modal-overlay .modal-content button[type="submit"] *,
.modal .modal-content .primary-button,
.modal .modal-content .primary-button *,
.modal .modal-content .btn-primary,
.modal .modal-content .btn-primary *,
.modal .modal-content button[type="submit"],
.modal .modal-content button[type="submit"] *,
.dunamis-modal .modal-content .primary-button,
.dunamis-modal .modal-content .primary-button *,
.dunamis-modal .modal-content .btn-primary,
.dunamis-modal .modal-content .btn-primary *,
.modal-overlay .modal-content .status-badge,
.modal-overlay .modal-content .status-badge *,
.modal-overlay .modal-content .badge,
.modal-overlay .modal-content .badge *,
.modal-overlay .modal-content [style*="color: white"],
.modal-overlay .modal-content [style*="color:white"],
.modal .modal-content [style*="color: white"],
.modal .modal-content [style*="color:white"],
.dunamis-modal .modal-content [style*="color: white"],
.dunamis-modal .modal-content [style*="color:white"] {
  color: #ffffff !important;
}

.modal-overlay .modal-content .secondary-button,
.modal-overlay .modal-content .btn-secondary,
.modal .modal-content .secondary-button,
.modal .modal-content .btn-secondary,
.dunamis-modal .modal-content .secondary-button,
.dunamis-modal .modal-content .btn-secondary {
  color: #111827 !important;
}

body.dark-theme .modal-overlay .modal-content,
body.dark-theme .modal-overlay .modal-content *,
body.dark-theme .modal .modal-content,
body.dark-theme .modal .modal-content *,
body.dark-theme .dunamis-modal .modal-content,
body.dark-theme .dunamis-modal .modal-content * {
  color: #e5e7eb !important;
}

/* Font size adjustments */
body[style*="font-size: 14px"] * {
  font-size: inherit;
}

body[style*="font-size: 18px"] * {
  font-size: inherit;
}
