/* ========================================
   DARK THEME - Comprehensive Variable Overrides
   Uses [data-theme="dark"] selector to override light theme
   ======================================== */

/* ========================================
   BASE.CSS VARIABLE OVERRIDES
   ======================================== */

[data-theme="dark"] {
    /* Primary Colors - Keep same for brand consistency */
    --primary-color: #16a085;
    --primary-hover: #14b8a6;
    --secondary-color: #3498db;
    --success-color: #27ae60;
    --danger-color: #e74c3c;
    --warning-color: #e67e22;
    --info-color: #3498db;
    --light-color: #2c3e50;
    --dark-color: #ecf0f1; /* Inverted: light text on dark bg */
    
    /* Gray Scale - Inverted for dark theme */
    --gray-100: #1a2332;
    --gray-200: #2c3e50;
    --gray-300: #34495e;
    --gray-400: #7f8c8d;
    --gray-500: #95a5a6;
    --gray-600: #bdc3c7;
    --gray-700: #ecf0f1;
    --gray-800: #f5f6fa;
    --gray-900: #ffffff;
}

/* Body background – use variable; stay transparent when using common site-background layer */
[data-theme="dark"] body {
    color: var(--theme-text-primary);
}

[data-theme="dark"] body:not(.site-background) {
    background-color: var(--theme-bg-primary);
}

/* ========================================
   CLASSIC-HOME-THEME.CSS VARIABLE OVERRIDES
   ======================================== */

[data-theme="dark"] {
    /* Primary Colors - Keep brand colors */
    --theme-primary: #16a085;
    --theme-primary-dark: #138d75;
    --theme-primary-light: #1abc9c;
    --theme-primary-hover: #14b8a6;
    
    /* Secondary Colors - Keep brand colors */
    --theme-secondary: #3498db;
    --theme-secondary-dark: #2980b9;
    --theme-secondary-light: #5dade2;
    --theme-secondary-hover: #3da5e0;
    
    /* Accent Colors - Keep brand colors */
    --theme-accent: #f39c12;
    --theme-accent-dark: #e67e22;
    --theme-accent-light: #f1c40f;
    --theme-accent-hover: #f4a261;
    
    /* Success, Warning, Danger, Info - Keep brand colors */
    --theme-success: #27ae60;
    --theme-success-dark: #229954;
    --theme-success-light: #2ecc71;
    --theme-success-hover: #2dd573;
    
    --theme-warning: #e67e22;
    --theme-warning-dark: #d35400;
    --theme-warning-light: #f39c12;
    --theme-warning-hover: #ea8a3a;
    
    --theme-danger: #e74c3c;
    --theme-danger-dark: #c0392b;
    --theme-danger-light: #ec7063;
    --theme-danger-hover: #eb5a4a;
    
    --theme-info: #3498db;
    --theme-info-dark: #2980b9;
    --theme-info-light: #5dade2;
    --theme-info-hover: #3da5e0;
    
    /* Neutral Colors - Inverted for dark theme */
    --theme-dark: #ecf0f1; /* Light text on dark bg */
    --theme-dark-light: #bdc3c7;
    --theme-dark-lighter: #95a5a6;
    
    /* Background Colors - Dark theme */
    --theme-bg-primary: #1a2332;        /* Main dark background */
    --theme-bg-secondary: #2c3e50;      /* Secondary dark background */
    --theme-bg-tertiary: #34495e;       /* Tertiary dark background */
    --theme-bg-dark: #0f1419;           /* Very dark background */
    
    /* Text Colors - Light text for dark background */
    --theme-text-primary: #ecf0f1;      /* Primary text (light) */
    --theme-text-secondary: #bdc3c7;    /* Secondary text (medium light) */
    --theme-text-muted: #95a5a6;        /* Muted text */
    --theme-text-light: #ecf0f1;        /* Light text */
    --theme-text-white: #ffffff;        /* White text */
    
    /* Border Colors - Dark theme borders */
    --theme-border: #34495e;            /* Standard border */
    --theme-border-light: #2c3e50;      /* Light border */
    --theme-border-dark: #95a5a6;       /* Dark border (inverted) */
    --theme-border-primary: #16a085;    /* Primary border (keep brand) */
    
    /* Shadow Colors - Adjusted for dark theme */
    --theme-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.4);
    --theme-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    --theme-shadow-md: 0 6px 20px rgba(0, 0, 0, 0.6);
    --theme-shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.7);
    --theme-shadow-xl: 0 15px 40px rgba(0, 0, 0, 0.8);
    
    /* Glow Effects - Adjusted for dark theme */
    --theme-glow-primary: 0 0 20px rgba(22, 160, 133, 0.6);
    --theme-glow-secondary: 0 0 20px rgba(52, 152, 219, 0.6);
    --theme-glow-accent: 0 0 20px rgba(243, 156, 18, 0.6);
}

/* ========================================
   CARDS & COMPONENTS - Dark Theme Overrides
   ======================================== */

/* Cards - Dark background with contrast */
/* Note: Using !important only for base card classes that may have inline styles or very high specificity from other CSS files */
[data-theme="dark"] .card,
[data-theme="dark"] .dashboard-card,
[data-theme="dark"] .client-card-classified,
[data-theme="dark"] .booking-item {
    background: #2c3e50 !important; /* Needed to override classic-home-theme.css which uses !important */
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

/* Card Header - Dark theme */
[data-theme="dark"] .card-header,
[data-theme="dark"] .dashboard-card .card-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important; /* Override classic-home-theme.css */
}

/* Card Header with Bootstrap bg classes - Override bg-light, bg-success, etc. */
[data-theme="dark"] .card-header.bg-light {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .card-header.bg-success {
    background: linear-gradient(135deg, var(--theme-success) 0%, #1e8449 100%) !important;
    color: white !important;
}

[data-theme="dark"] .card-header.bg-info {
    background: linear-gradient(135deg, var(--theme-info) 0%, #2874a6 100%) !important;
    color: white !important;
}

[data-theme="dark"] .card-header.bg-primary {
    background: linear-gradient(135deg, var(--theme-primary) 0%, #0e7d6d 100%) !important;
    color: white !important;
    border-bottom-color: #34495e !important;
    color: #ecf0f1 !important;
}

/* Card Body - Dark theme */
[data-theme="dark"] .card-body,
[data-theme="dark"] .dashboard-card .card-body,
[data-theme="dark"] .property-details,
[data-theme="dark"] .client-card-classified .client-card-body {
    background: #2c3e50 !important; /* Override classic-home-theme.css */
    color: #ecf0f1 !important;
}

/* Card Footer - Dark theme */
[data-theme="dark"] .card-footer {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important; /* Override classic-home-theme.css */
    border-top-color: #34495e !important;
}

/* Stat Cards - Dark theme */
[data-theme="dark"] .stat-card,
[data-theme="dark"] .summary-card {
    background: #2c3e50 !important; /* Override classic-home-theme.css */
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

/* ========================================
   FORMS - Dark Theme Overrides
   ======================================== */

/* Form Controls */
[data-theme="dark"] .form-control {
    background-color: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .form-control:focus {
    background-color: #2c3e50;
    border-color: var(--theme-primary);
    color: #ecf0f1;
}

[data-theme="dark"] .form-control::placeholder {
    color: #95a5a6;
}

[data-theme="dark"] .form-control:disabled {
    background-color: #1a2332;
    opacity: 0.6;
}

/* Form Labels */
[data-theme="dark"] .form-label {
    color: #ecf0f1;
}

/* Form Select */
[data-theme="dark"] .form-select {
    background-color: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2316a085' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
}

[data-theme="dark"] .form-select:focus {
    background-color: #2c3e50;
    border-color: var(--theme-primary);
    color: #ecf0f1;
}

/* Form Check */
[data-theme="dark"] .form-check-input {
    background-color: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .form-check-input:checked {
    background-color: var(--theme-primary);
    border-color: var(--theme-primary);
}

[data-theme="dark"] .form-check-label {
    color: #ecf0f1;
}

/* ========================================
   TABLES - Dark Theme Overrides
   Comprehensive table styling for all tables across the site
   ======================================== */

/* Base Table Styles - Using !important to override Bootstrap and other CSS */
[data-theme="dark"] .table {
    color: #ecf0f1 !important;
    background-color: transparent !important;
}

/* Table Headers */
[data-theme="dark"] .table thead,
[data-theme="dark"] .table thead tr,
[data-theme="dark"] .table thead th {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
    border-bottom-color: var(--theme-primary) !important;
}

/* Bootstrap table-light class override */
[data-theme="dark"] .table-light,
[data-theme="dark"] .table thead.table-light,
[data-theme="dark"] .table thead.table-light th {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
}

/* Table Body */
[data-theme="dark"] .table tbody,
[data-theme="dark"] .table tbody tr {
    background-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .table tbody td,
[data-theme="dark"] .table tbody th {
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

/* Table Hover - Bootstrap .table-hover class */
[data-theme="dark"] .table-hover tbody tr:hover,
[data-theme="dark"] .table tbody tr:hover {
    background-color: #34495e !important;
    color: #ecf0f1 !important;
}

/* Table Striped - Bootstrap .table-striped class */
[data-theme="dark"] .table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(22, 160, 133, 0.1) !important;
}

[data-theme="dark"] .table-striped tbody tr:nth-of-type(even) {
    background-color: #2c3e50 !important;
}

/* Table Striped + Hover combination */
[data-theme="dark"] .table-striped.table-hover tbody tr:hover {
    background-color: #34495e !important;
}

/* Table Bordered */
[data-theme="dark"] .table-bordered,
[data-theme="dark"] .table-bordered th,
[data-theme="dark"] .table-bordered td {
    border-color: #34495e !important;
}

/* Table Responsive Container */
[data-theme="dark"] .table-responsive {
    background-color: transparent !important;
}

/* Table Footer */
[data-theme="dark"] .table tfoot,
[data-theme="dark"] .table tfoot th,
[data-theme="dark"] .table tfoot td {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
    border-top-color: var(--theme-primary) !important;
}

/* Bootstrap Table Variants (when used on rows/rows) */
[data-theme="dark"] .table-primary,
[data-theme="dark"] .table-primary > th,
[data-theme="dark"] .table-primary > td {
    background-color: rgba(22, 160, 133, 0.2) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .table-success,
[data-theme="dark"] .table-success > th,
[data-theme="dark"] .table-success > td {
    background-color: rgba(46, 213, 115, 0.2) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .table-danger,
[data-theme="dark"] .table-danger > th,
[data-theme="dark"] .table-danger > td {
    background-color: rgba(231, 76, 60, 0.2) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .table-warning,
[data-theme="dark"] .table-warning > th,
[data-theme="dark"] .table-warning > td {
    background-color: rgba(241, 196, 15, 0.2) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .table-info,
[data-theme="dark"] .table-info > th,
[data-theme="dark"] .table-info > td {
    background-color: rgba(52, 152, 219, 0.2) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .table-dark,
[data-theme="dark"] .table-dark > th,
[data-theme="dark"] .table-dark > td {
    background-color: #1a1a1a !important;
    color: #ecf0f1 !important;
}

/* Table Small (Bootstrap .table-sm) */
[data-theme="dark"] .table-sm th,
[data-theme="dark"] .table-sm td {
    color: #ecf0f1 !important;
}

/* Table Borderless */
[data-theme="dark"] .table-borderless th,
[data-theme="dark"] .table-borderless td {
    border-color: transparent !important;
}

/* ========================================
   MODALS - Dark Theme Overrides
   ======================================== */

/* Modal - Using !important because Bootstrap modals have high specificity */
[data-theme="dark"] .modal-content {
    background-color: #2c3e50 !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .modal-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-bottom-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .modal-title {
    color: #ecf0f1;
}

[data-theme="dark"] .modal-body {
    color: #ecf0f1;
}

[data-theme="dark"] .modal-footer {
    background: #34495e;
    border-top-color: #34495e;
}

/* Modal Backdrop - Using !important because Bootstrap backdrop has high specificity */
[data-theme="dark"] .modal-backdrop {
    background-color: rgba(0, 0, 0, 0.7) !important;
}

/* ========================================
   ALERTS - Dark Theme Overrides
   ======================================== */

[data-theme="dark"] .alert-primary {
    color: #b8e6d9;
    background-color: rgba(22, 160, 133, 0.2);
    border-color: rgba(22, 160, 133, 0.4);
}

[data-theme="dark"] .alert-secondary {
    color: #b3d9f2;
    background-color: rgba(52, 152, 219, 0.2);
    border-color: rgba(52, 152, 219, 0.4);
}

[data-theme="dark"] .alert-success {
    color: #a8e6c4;
    background-color: rgba(39, 174, 96, 0.2);
    border-color: rgba(39, 174, 96, 0.4);
}

[data-theme="dark"] .alert-danger {
    color: #f5b7b1;
    background-color: rgba(231, 76, 60, 0.2);
    border-color: rgba(231, 76, 60, 0.4);
}

[data-theme="dark"] .alert-warning {
    color: #fad7a0;
    background-color: rgba(230, 126, 34, 0.2);
    border-color: rgba(230, 126, 34, 0.4);
}

[data-theme="dark"] .alert-info {
    color: #b3d9f2;
    background-color: rgba(52, 152, 219, 0.2);
    border-color: rgba(52, 152, 219, 0.4);
}

/* ========================================
   DROPDOWNS - Dark Theme Overrides
   ======================================== */

[data-theme="dark"] .dropdown-menu {
    background-color: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .dropdown-item {
    color: #ecf0f1;
}

[data-theme="dark"] .dropdown-item:hover {
    background-color: rgba(22, 160, 133, 0.2);
    color: var(--theme-primary);
}

[data-theme="dark"] .dropdown-item.active {
    background-color: var(--theme-primary);
    color: #ffffff;
}

[data-theme="dark"] .dropdown-divider {
    background-color: #34495e;
}

/* ========================================
   NAVIGATION & PAGINATION - Dark Theme
   ======================================== */

[data-theme="dark"] .nav-link {
    color: #ecf0f1;
}

[data-theme="dark"] .nav-link:hover {
    color: var(--theme-primary);
    background-color: rgba(22, 160, 133, 0.2);
}

[data-theme="dark"] .nav-link.active {
    color: var(--theme-primary);
    background-color: rgba(22, 160, 133, 0.3);
}

/* Pagination */
[data-theme="dark"] .page-link {
    background-color: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .page-link:hover {
    background-color: rgba(22, 160, 133, 0.2);
    border-color: var(--theme-primary);
    color: var(--theme-primary);
}

[data-theme="dark"] .page-item.active .page-link {
    background-color: var(--theme-primary);
    border-color: var(--theme-primary);
    color: #ffffff;
}

[data-theme="dark"] .page-item.disabled .page-link {
    background-color: #1a2332;
    border-color: #34495e;
    color: #95a5a6;
}

/* ========================================
   LIST GROUPS - Dark Theme
   ======================================== */

[data-theme="dark"] .list-group-item {
    background-color: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .list-group-item:hover {
    background-color: #34495e;
    border-color: var(--theme-primary);
    color: #ecf0f1;
}

[data-theme="dark"] .list-group-item.active {
    background-color: var(--theme-primary);
    border-color: var(--theme-primary);
    color: #ffffff;
}

/* ========================================
   CLIENT LAYOUT - Dark Theme Overrides
   ======================================== */

[data-theme="dark"] .main-content {
    background-color: var(--theme-bg-primary);
}

[data-theme="dark"] .site-background .main-content {
    background-color: transparent !important;
}

[data-theme="dark"] .client-navbar {
    background-color: #2c3e50;
}

[data-theme="dark"] .client-navbar .navbar-brand {
    color: var(--theme-primary);
}

[data-theme="dark"] .client-navbar .nav-link {
    color: #ecf0f1;
}

[data-theme="dark"] .client-navbar .nav-link:hover {
    background-color: rgba(22, 160, 133, 0.2);
    color: var(--theme-primary);
}

[data-theme="dark"] .client-footer {
    background-color: #1a2332;
    color: #95a5a6;
}

[data-theme="dark"] .client-footer h5 {
    color: #ecf0f1;
}

[data-theme="dark"] .client-footer a {
    color: #95a5a6;
}

[data-theme="dark"] .client-footer a:hover {
    color: #ecf0f1;
}

[data-theme="dark"] .page-header {
    background-color: #2c3e50;
    border-bottom-color: #34495e;
}

[data-theme="dark"] .content-card {
    background-color: #2c3e50;
    color: #ecf0f1;
}

/* ========================================
   ADMIN LAYOUT - Dark Theme Overrides
   ======================================== */

/* Admin sidebar — theme tokens in admin-sidebar.css */
[data-theme="dark"] .admin-main {
    background-color: #1a2332;
}

[data-theme="dark"] .admin-topbar {
    background-color: #2c3e50;
    border-bottom-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .admin-topbar .sidebar-toggle {
    color: #ecf0f1;
}

[data-theme="dark"] .admin-topbar .sidebar-toggle:hover {
    background-color: #34495e;
}

[data-theme="dark"] .admin-topbar .topbar-link {
    color: #ecf0f1;
}

[data-theme="dark"] .admin-topbar .topbar-link:hover {
    background-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .admin-content {
    background-color: #1a2332;
    color: #ecf0f1;
}

[data-theme="dark"] .admin-footer {
    background-color: #2c3e50;
    border-top-color: #34495e;
    color: #95a5a6;
}

[data-theme="dark"] .stat-card {
    background-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .stat-card-label {
    color: #95a5a6;
}

/* ========================================
   HOUSE LAYOUT V2 - Dark Theme Overrides
   ======================================== */

/* House layout already uses dark sky - adjust for better contrast */
[data-theme="dark"] body.theme-layout {
    background: linear-gradient(to bottom, 
        #0a0e1a 0%, 
        #0f1419 15%, 
        #1a2332 40%, 
        #2c3e50 100%
    );
}

/* Main content - Dark theme; transparent when using common site-background layer */
[data-theme="dark"] .client-main {
    background: var(--theme-bg-primary);
}

[data-theme="dark"] .site-background .client-main {
    background: transparent !important;
}

/* Window panels - Dark theme */
[data-theme="dark"] .window-panel {
    background: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .window-content {
    background: rgba(44, 62, 80, 0.9);
    color: #ecf0f1;
}

/* Roof - Keep dark but ensure visibility */
[data-theme="dark"] .roof-nav {
    background: rgba(26, 35, 50, 0.95);
}

[data-theme="dark"] .roof-nav .brand,
[data-theme="dark"] .roof-nav .nav-links a {
    color: #ecf0f1;
}

[data-theme="dark"] .roof-nav .nav-links a:hover {
    color: var(--theme-primary);
    background: rgba(22, 160, 133, 0.2);
}

/* Door footer - Keep grass green (nature color, works in dark theme) */
/* Grass stays green - it's a natural element that works in both themes */

/* ========================================
   UTILITY CLASSES - Dark Theme
   ======================================== */

/* Utility classes - Using !important because utility classes often have !important in frameworks */
[data-theme="dark"] .text-muted {
    color: #95a5a6 !important;
}

[data-theme="dark"] .bg-light {
    background-color: #2c3e50 !important;
}

[data-theme="dark"] .bg-dark {
    background-color: #ecf0f1 !important; /* Inverted */
    color: #1a2332 !important;
}

/* ========================================
   PROGRESS BARS - Dark Theme
   ======================================== */

[data-theme="dark"] .progress {
    background-color: #1a2332;
}

/* Progress bars keep their brand colors - no change needed */

/* ========================================
   TOOLTIPS - Dark Theme
   ======================================== */

[data-theme="dark"] .tooltip-inner {
    background-color: #2c3e50;
    color: #ecf0f1;
}

/* ========================================
   PAGE HERO - Dark Theme Overrides
   ======================================== */

/* Page hero already uses dark gradient - adjust if needed */
[data-theme="dark"] .page-hero,
[data-theme="dark"] .dashboard-header {
    background: linear-gradient(135deg, #1a2332 0%, #2c3e50 50%, #34495e 100%);
}

/* ========================================
   DASHBOARD SPECIFIC - Dark Theme
   ======================================== */

/* Dashboard CSS Variables Override (--home-*) */
[data-theme="dark"] {
    /* Warm Earth Tones - Dark Theme */
    --home-cream: #2c3e50;
    --home-warm-white: #34495e;
    --home-sand: #2c3e50;
    --home-beige: #34495e;
    
    /* Natural Wood Tones - Slightly lighter for visibility */
    --home-wood-light: #7f8c8d;
    --home-wood: #95a5a6;
    --home-wood-dark: #bdc3c7;
    --home-mahogany: #7f8c8d;
    
    /* Cozy Accent Colors - Keep but adjust for dark bg */
    --home-terracotta: #e67e22;
    --home-sage: #27ae60;
    --home-sage-dark: #229954;
    --home-forest: #1e8449;
    --home-ocean: #3498db;
    --home-ocean-dark: #2980b9;
    --home-sunset: #e67e22;
    --home-gold: #f39c12;
    --home-rust: #c0392b;
    
    /* Text Colors - Inverted for dark theme */
    --home-text-dark: #ecf0f1;
    --home-text-medium: #bdc3c7;
    --home-text-light: #95a5a6;
    --home-text-muted: #7f8c8d;
    
    /* Shadows - Darker for dark theme */
    --shadow-warm-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-warm-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-warm-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-warm-glow: 0 0 20px rgba(52, 152, 219, 0.2);
}

/* Dashboard Modern - Dark theme */
[data-theme="dark"] .dashboard-modern {
    background: linear-gradient(180deg, #1a2332 0%, #2c3e50 100%);
}

[data-theme="dark"] .dashboard-header-modern {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    border-color: #34495e;
}

[data-theme="dark"] .dashboard-window-modern {
    background: #2c3e50 !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .window-header-modern {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .window-body-modern {
    background: linear-gradient(180deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .window-title-modern {
    color: #ecf0f1;
}

[data-theme="dark"] .stat-card-modern {
    background: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .stat-value-modern {
    color: #ecf0f1;
}

[data-theme="dark"] .stat-label-modern {
    color: #bdc3c7;
}

[data-theme="dark"] .client-card,
[data-theme="dark"] .client-card-compact {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .client-name {
    color: #ecf0f1;
}

[data-theme="dark"] .client-email,
[data-theme="dark"] .client-date {
    color: #bdc3c7;
}

[data-theme="dark"] .btn-change-class {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .btn-change-class:hover {
    background: linear-gradient(135deg, #27ae60 0%, #229954 100%);
    border-color: #27ae60;
    color: white;
}

[data-theme="dark"] .dashboard-title-modern {
    color: #ecf0f1;
}

[data-theme="dark"] .dashboard-subtitle-modern {
    color: #bdc3c7;
}

[data-theme="dark"] .quick-action-window-btn {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-color: #2c3e50;
}

[data-theme="dark"] .action-label {
    color: #ecf0f1;
}

[data-theme="dark"] .activity-item {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-color: #2c3e50;
}

[data-theme="dark"] .activity-text {
    color: #ecf0f1;
}

[data-theme="dark"] .activity-time {
    color: #bdc3c7;
}

[data-theme="dark"] .empty-state-modern p {
    color: #bdc3c7;
}

[data-theme="dark"] .property-management-card {
    background: #34495e;
    border-color: #2c3e50;
}

/* ========================================
   BREADCRUMBS - Dark Theme
   ======================================== */

[data-theme="dark"] .breadcrumb {
    background-color: transparent;
}

[data-theme="dark"] .breadcrumb-item + .breadcrumb-item::before {
    color: #95a5a6;
}

[data-theme="dark"] .breadcrumb-item a {
    color: #ecf0f1;
}

[data-theme="dark"] .breadcrumb-item.active {
    color: #95a5a6;
}

/* ========================================
   ADDITIONAL COMPONENT OVERRIDES
   ======================================== */

/* Links – use theme link variables (global text color law) */
[data-theme="dark"] a {
    color: var(--theme-link-color);
}

[data-theme="dark"] a:hover {
    color: var(--theme-link-hover-color);
}

/* Headings – same law as header: use --theme-heading-color */
[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] h4,
[data-theme="dark"] h5,
[data-theme="dark"] h6 {
    color: var(--theme-heading-color);
}

/* Paragraphs – use theme variable (global text color law) */
[data-theme="dark"] p {
    color: var(--theme-text-primary);
}

/* Horizontal Rules */
[data-theme="dark"] hr {
    border-color: #34495e;
}

/* Code/Pre elements – use theme variable (global text color law) */
[data-theme="dark"] code,
[data-theme="dark"] pre {
    background-color: #1a2332;
    color: var(--theme-text-primary);
    border-color: #34495e;
}

/* Blockquotes – use theme variable (global text color law) */
[data-theme="dark"] blockquote {
    border-left-color: var(--theme-primary);
    color: var(--theme-text-secondary);
}

/* ========================================
   FILTER PANELS & SECTIONS - Dark Theme
   ======================================== */

[data-theme="dark"] .filter-panel,
[data-theme="dark"] .filters-section,
[data-theme="dark"] .filters-panel {
    background: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .filter-row {
    color: #ecf0f1;
}

[data-theme="dark"] .filter-group label {
    color: #bdc3c7;
}

[data-theme="dark"] .filter-input,
[data-theme="dark"] .filter-select {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .filter-input:focus,
[data-theme="dark"] .filter-select:focus {
    background-color: #34495e;
    border-color: var(--theme-primary);
    color: #ecf0f1;
}

[data-theme="dark"] .filter-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%2316a085' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
}

/* ========================================
   SUMMARY CARDS & CHART CARDS - Dark Theme
   ======================================== */

[data-theme="dark"] .summary-card {
    background: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .summary-card:hover {
    background: #34495e;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
}

[data-theme="dark"] .card-value,
[data-theme="dark"] .stat-value {
    color: #ecf0f1;
}

[data-theme="dark"] .card-label,
[data-theme="dark"] .stat-label {
    color: #bdc3c7;
}

[data-theme="dark"] .card-trend.positive {
    color: #2ecc71;
    background: rgba(46, 204, 113, 0.2);
}

[data-theme="dark"] .card-trend.negative {
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.2);
}

/* Chart Cards */
[data-theme="dark"] .chart-card {
    background: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .chart-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-bottom-color: #34495e;
}

[data-theme="dark"] .chart-header h3 {
    color: #ecf0f1;
}

[data-theme="dark"] .chart-body {
    background: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .chart-legend {
    color: #ecf0f1;
}

[data-theme="dark"] .legend-item {
    color: #ecf0f1;
}

[data-theme="dark"] .legend-label {
    color: #bdc3c7;
}

[data-theme="dark"] .legend-value {
    color: #ecf0f1;
}

[data-theme="dark"] .btn-chart-action {
    background: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .btn-chart-action:hover {
    background: #3d566e;
    border-color: var(--theme-primary);
}

[data-theme="dark"] .btn-chart-action.active {
    background: var(--theme-primary);
    border-color: var(--theme-primary);
    color: #ffffff;
}

/* ========================================
   CONFIG SECTIONS & ITEMS - Dark Theme
   ======================================== */

[data-theme="dark"] .config-section {
    background: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .config-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-bottom-color: #34495e;
}

[data-theme="dark"] .config-header h3 {
    color: #ecf0f1;
}

[data-theme="dark"] .section-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-bottom-color: #34495e;
}

[data-theme="dark"] .section-title h2 {
    color: #ecf0f1;
}

[data-theme="dark"] .section-title p {
    color: #bdc3c7;
}

[data-theme="dark"] .section-body {
    background: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .config-item {
    background: #34495e;
    border-color: #2c3e50;
}

[data-theme="dark"] .config-item:hover {
    background: #3d566e;
}

[data-theme="dark"] .config-info-card {
    background: rgba(52, 152, 219, 0.1);
    border-color: rgba(52, 152, 219, 0.2);
}

[data-theme="dark"] .config-info-card.highlight {
    background: rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.2);
}

[data-theme="dark"] .info-content {
    color: #bdc3c7;
}

[data-theme="dark"] .info-content strong {
    color: #ecf0f1;
}

/* ========================================
   TABLE CONTAINERS - Dark Theme
   ======================================== */

[data-theme="dark"] .table-container {
    background: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .properties-table,
[data-theme="dark"] .data-table {
    color: #ecf0f1;
}

[data-theme="dark"] .properties-table thead,
[data-theme="dark"] .data-table thead {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
}

[data-theme="dark"] .properties-table th,
[data-theme="dark"] .data-table th {
    color: #ecf0f1;
    border-bottom-color: #34495e;
}

[data-theme="dark"] .properties-table th.sortable:hover,
[data-theme="dark"] .data-table th.sortable:hover {
    background: #3d566e;
}

[data-theme="dark"] .properties-table tbody tr,
[data-theme="dark"] .data-table tbody tr {
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .properties-table tbody tr:hover,
[data-theme="dark"] .data-table tbody tr:hover {
    background: #34495e;
}

[data-theme="dark"] .properties-table td,
[data-theme="dark"] .data-table td {
    color: #ecf0f1;
}

[data-theme="dark"] .table-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-bottom-color: #34495e;
}

[data-theme="dark"] .table-header h4 {
    color: #ecf0f1;
}

/* ========================================
   BUTTON VARIANTS - Dark Theme
   ======================================== */

[data-theme="dark"] .btn-refresh,
[data-theme="dark"] .btn-export,
[data-theme="dark"] .btn-export-table {
    background: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .btn-refresh:hover,
[data-theme="dark"] .btn-export:hover,
[data-theme="dark"] .btn-export-table:hover {
    background: #3d566e;
    border-color: var(--theme-primary);
    color: var(--theme-primary);
}

[data-theme="dark"] .btn-apply-filter {
    background: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .btn-apply-filter:hover {
    background: #3d566e;
    border-color: var(--theme-primary);
}

[data-theme="dark"] .btn-reset {
    background: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .btn-reset:hover {
    background: #3d566e;
    border-color: var(--theme-primary);
}

/* ========================================
   SEARCH BOXES - Dark Theme
   ======================================== */

[data-theme="dark"] .search-box input {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .search-box input:focus {
    background-color: #34495e;
    border-color: var(--theme-primary);
    color: #ecf0f1;
}

[data-theme="dark"] .search-box i {
    color: #95a5a6;
}

/* ========================================
   REPORTS SECTIONS - Dark Theme
   ======================================== */

[data-theme="dark"] .reports-section {
    background: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .reports-tabs {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-color: #34495e;
}

[data-theme="dark"] .tab-btn {
    background: transparent;
    border-color: transparent;
    color: #bdc3c7;
}

[data-theme="dark"] .tab-btn:hover {
    background: rgba(22, 160, 133, 0.2);
    color: var(--theme-primary);
}

[data-theme="dark"] .tab-btn.active {
    background: rgba(22, 160, 133, 0.3);
    border-color: var(--theme-primary);
    color: var(--theme-primary);
}

[data-theme="dark"] .tab-content {
    background: #2c3e50;
    color: #ecf0f1;
}

/* ========================================
   STAT CARD VARIANTS - Dark Theme
   ======================================== */

[data-theme="dark"] .stat-card.total .stat-icon,
[data-theme="dark"] .stat-card.pending .stat-icon,
[data-theme="dark"] .stat-card.confirmed .stat-icon,
[data-theme="dark"] .stat-card.completed .stat-icon,
[data-theme="dark"] .stat-card.cancelled .stat-icon {
    background: rgba(22, 160, 133, 0.2);
    color: var(--theme-primary);
}

[data-theme="dark"] .stat-icon.deposit,
[data-theme="dark"] .stat-icon.ending-soon,
[data-theme="dark"] .stat-icon.this-month,
[data-theme="dark"] .stat-icon.commissions,
[data-theme="dark"] .stat-icon.by-customer,
[data-theme="dark"] .stat-icon.by-admin {
    background: rgba(22, 160, 133, 0.2);
    color: var(--theme-primary);
}

/* ========================================
   RANK BADGES - Dark Theme
   ======================================== */

[data-theme="dark"] .rank-badge {
    background: #34495e;
    color: #ecf0f1;
}

/* Rank badges rank-1, rank-2, rank-3 and performer-rank keep their gradient colors - they work well in dark theme */

/* ========================================
   CONFIG ICONS - Dark Theme
   ======================================== */

[data-theme="dark"] .config-icon.total {
    background: var(--theme-primary);
    color: white;
}

/* ========================================
   LOGIN & REGISTER PAGES - Dark Theme
   ======================================== */

[data-theme="dark"] .login-page {
    background: linear-gradient(135deg, #1a2332 0%, #2c3e50 100%);
}

[data-theme="dark"] .login-form-section {
    background-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .login-form-wrapper {
    color: #ecf0f1;
}

[data-theme="dark"] .login-title {
    color: #ecf0f1;
}

[data-theme="dark"] .login-subtitle {
    color: #bdc3c7;
}

[data-theme="dark"] .divider span {
    background-color: #2c3e50;
    color: #bdc3c7;
}

[data-theme="dark"] .divider::before {
    background-color: #34495e;
}

[data-theme="dark"] .social-login .btn {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .social-login .btn:hover {
    background-color: #3d566e;
    border-color: var(--theme-primary);
}

/* Register Page */
[data-theme="dark"] .register-page {
    background: linear-gradient(135deg, #1a2332 0%, #2c3e50 100%);
}

[data-theme="dark"] .register-card {
    background-color: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
}

[data-theme="dark"] .register-title {
    color: #ecf0f1;
}

[data-theme="dark"] .register-subtitle {
    color: #bdc3c7;
}

[data-theme="dark"] .role-card {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .role-card:hover {
    border-color: var(--theme-primary);
    background-color: #3d566e;
}

[data-theme="dark"] .role-card h5 {
    color: #ecf0f1;
}

[data-theme="dark"] .role-card p {
    color: #bdc3c7;
}

[data-theme="dark"] .role-card:has(input[type="radio"]:checked) {
    background-color: var(--theme-primary);
    border-color: var(--theme-primary);
}

[data-theme="dark"] .consultant-search-wrapper .input-group-text {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .consultant-search-results {
    background: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .consultant-search-item {
    border-bottom-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .consultant-search-item:hover,
[data-theme="dark"] .consultant-search-item.active {
    background-color: var(--theme-primary);
    color: #ffffff;
}

[data-theme="dark"] .consultant-item-details {
    color: #bdc3c7;
}

[data-theme="dark"] .consultant-search-no-results {
    color: #bdc3c7;
}

/* ========================================
   PROPERTIES PAGE - Dark Theme
   ======================================== */

[data-theme="dark"] .search-header {
    background: linear-gradient(135deg, #1a2332 0%, #2c3e50 100%);
}

[data-theme="dark"] .search-bar {
    background: #2c3e50 !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .search-input input,
[data-theme="dark"] .date-input input,
[data-theme="dark"] .search-guests input {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .search-input i,
[data-theme="dark"] .date-input i,
[data-theme="dark"] .search-guests i {
    color: #95a5a6;
}

[data-theme="dark"] .filters-sidebar {
    background: #2c3e50 !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .filters-header {
    border-bottom-color: #34495e;
}

[data-theme="dark"] .filters-header h5 {
    color: #ecf0f1;
}

[data-theme="dark"] .filter-section {
    border-bottom-color: #34495e;
}

[data-theme="dark"] .filter-section h6 {
    color: #ecf0f1;
}

[data-theme="dark"] .price-inputs input {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

[data-theme="dark"] .price-inputs span {
    color: #bdc3c7;
}

[data-theme="dark"] .results-header {
    background: #2c3e50;
    border-color: #34495e;
}

[data-theme="dark"] .results-info h5 {
    color: #ecf0f1;
}

/* Property cards - Using !important to override classic-home-theme.css and properties.css */
[data-theme="dark"] .property-card {
    background: #2c3e50 !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .property-card:hover {
    background: #34495e !important;
    border-color: var(--theme-primary) !important;
}

[data-theme="dark"] .property-info {
    background: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .property-title {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .property-location {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .property-features {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .property-footer {
    border-top-color: #34495e !important;
}

[data-theme="dark"] .property-favorite {
    background: rgba(44, 62, 80, 0.9) !important;
}

[data-theme="dark"] .property-favorite:hover {
    background: rgba(52, 73, 94, 0.95) !important;
}

[data-theme="dark"] .property-price-all-classes .price-row {
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .property-price-all-classes .price-label-small {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .property-price-all-classes .price-value {
    color: var(--theme-primary) !important;
}

[data-theme="dark"] .property-rating {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .property-price {
    color: var(--theme-primary) !important;
}

[data-theme="dark"] .property-price span {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .price-label.price-a {
    background-color: rgba(230, 126, 34, 0.2);
    color: #f39c12;
    border-color: rgba(230, 126, 34, 0.4);
}

[data-theme="dark"] .price-label.price-b {
    background-color: rgba(52, 152, 219, 0.2);
    color: #5dade2;
    border-color: rgba(52, 152, 219, 0.4);
}

[data-theme="dark"] .price-label.price-c {
    background-color: rgba(149, 165, 166, 0.2);
    color: #bdc3c7;
    border-color: rgba(149, 165, 166, 0.4);
}

[data-theme="dark"] .empty-state {
    color: #95a5a6;
}

[data-theme="dark"] .empty-state h5 {
    color: #bdc3c7;
}

[data-theme="dark"] .property-thumbnail {
    border-color: #34495e;
}

[data-theme="dark"] .property-info-text {
    color: #ecf0f1;
}

/* ========================================
   BOOKING PAGES - Dark Theme
   ======================================== */

/* Booking Cards */
[data-theme="dark"] .booking-card,
[data-theme="dark"] .payment-card {
    background: #2c3e50 !important;
    border-color: #34495e !important;
}

/* Booking Table Rows - Consultant Bookings */
[data-theme="dark"] .booking-row,
[data-theme="dark"] table tbody tr.booking-row,
[data-theme="dark"] .table tbody tr.booking-row {
    background: #2c3e50 !important;
    background-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .booking-row:hover,
[data-theme="dark"] table tbody tr.booking-row:hover,
[data-theme="dark"] .table tbody tr.booking-row:hover {
    background: #34495e !important;
    background-color: #34495e !important;
}

[data-theme="dark"] .booking-row td,
[data-theme="dark"] table tbody tr.booking-row td,
[data-theme="dark"] .table tbody tr.booking-row td {
    background: transparent !important;
    background-color: transparent !important;
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

/* All table rows in booking tables */
[data-theme="dark"] .table tbody tr,
[data-theme="dark"] table tbody tr,
[data-theme="dark"] .table tbody tr:not(.booking-row) {
    background: #2c3e50 !important;
    background-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .table tbody tr td,
[data-theme="dark"] table tbody tr td {
    background: transparent !important;
    background-color: transparent !important;
    color: #ecf0f1 !important;
}

/* Bookings Table - Admin/General */
[data-theme="dark"] .bookings-table tbody tr {
    background: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .bookings-table tbody tr:hover {
    background: #34495e !important;
}

[data-theme="dark"] .bookings-table tbody td {
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .bookings-table thead th {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .bookings-table thead th.sortable:hover {
    background: #3d566e !important;
}

/* Booking Table Cell Styles */
[data-theme="dark"] .booking-id-link {
    color: var(--theme-primary) !important;
}

[data-theme="dark"] .booking-id-link:hover {
    color: var(--theme-primary-hover) !important;
}

[data-theme="dark"] .property-cell .property-title {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .customer-cell .customer-name {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .period-dates {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .period-type {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .amount-value {
    color: var(--theme-success) !important;
}

/* Filter Card */
[data-theme="dark"] .filter-card {
    background: #2c3e50 !important;
    border-color: #34495e !important;
    border-left-color: var(--theme-primary) !important;
}

[data-theme="dark"] .filter-card input,
[data-theme="dark"] .filter-card select {
    background-color: #34495e !important;
    border-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .filter-card input:focus,
[data-theme="dark"] .filter-card select:focus {
    background-color: #34495e !important;
    border-color: var(--theme-primary) !important;
    color: #ecf0f1 !important;
}

/* Commission Breakdown */
[data-theme="dark"] .commission-breakdown {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-left-color: var(--theme-success) !important;
}

[data-theme="dark"] .commission-row {
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .commission-row .label {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .commission-row .amount {
    color: var(--theme-success) !important;
}

/* Details Card */
[data-theme="dark"] .details-card {
    background: #2c3e50 !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .details-card:hover {
    background: #34495e !important;
    border-color: var(--theme-primary) !important;
}

/* Info Item */
[data-theme="dark"] .info-item {
    background: #34495e !important;
    border-left-color: var(--theme-primary) !important;
}

[data-theme="dark"] .info-item .label {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .info-item .value {
    color: #ecf0f1 !important;
}

/* Timeline */
[data-theme="dark"] .timeline-marker {
    background: #2c3e50 !important;
    border-color: var(--theme-primary) !important;
}

[data-theme="dark"] .timeline-item:not(:last-child)::before {
    background: #34495e !important;
}

/* Payment Status */
[data-theme="dark"] .payment-status.paid {
    color: var(--theme-success) !important;
}

[data-theme="dark"] .payment-status.pending {
    color: var(--theme-warning) !important;
}

[data-theme="dark"] .payment-status.failed {
    color: var(--theme-danger) !important;
}

/* Commission Badge */
[data-theme="dark"] .commission-badge {
    background: linear-gradient(135deg, var(--theme-success) 0%, #1e8449 100%) !important;
    color: white !important;
}

/* Badge Warning */
[data-theme="dark"] .badge.bg-warning {
    color: #1a1a1a !important;
}

/* Booking Info Grid */
[data-theme="dark"] .booking-info-grid {
    background: transparent;
}

/* Commission Breakdown Boxes - Booking Details Page */
/* Override inline styles with !important - Using multiple attribute selector patterns */
[data-theme="dark"] .card.border-success .card-body > div.d-flex[style*="background-color"] {
    background-color: #34495e !important;
    background: #34495e !important;
}

/* Profit box (light grey background) */
[data-theme="dark"] .card.border-success .card-body > div.d-flex[style*="#f9f9f9"],
[data-theme="dark"] .card.border-success .card-body > div.d-flex:has(#profitAmount) {
    background-color: #34495e !important;
    background: #34495e !important;
}

/* Your Commission box (light green background) */
[data-theme="dark"] .card.border-success .card-body > div.d-flex[style*="#e8f5e9"],
[data-theme="dark"] .card.border-success .card-body > div.d-flex:has(#yourCommission) {
    background-color: rgba(22, 160, 133, 0.15) !important;
    background: rgba(22, 160, 133, 0.15) !important;
}

/* MLM Commission box (light orange background) */
[data-theme="dark"] .card.border-success .card-body > div.d-flex[style*="#fff3e0"],
[data-theme="dark"] .card.border-success .card-body > div.d-flex:has(#mlmCommission) {
    background-color: rgba(52, 152, 219, 0.15) !important;
    background: rgba(52, 152, 219, 0.15) !important;
}

/* Admin Fee box (light purple background) */
[data-theme="dark"] .card.border-success .card-body > div.d-flex[style*="#f3e5f5"],
[data-theme="dark"] .card.border-success .card-body > div.d-flex:has(#adminFee) {
    background-color: rgba(155, 89, 182, 0.15) !important;
    background: rgba(155, 89, 182, 0.15) !important;
}

/* Text colors in commission breakdown boxes */
[data-theme="dark"] .card.border-success .card-body > div.d-flex .text-muted,
[data-theme="dark"] .card.border-success .card-body > div.d-flex small.text-muted {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .card.border-success .card-body > div.d-flex strong {
    color: #ecf0f1 !important;
}

/* Profit amount color override */
[data-theme="dark"] #profitAmount {
    color: #f39c12 !important;
}

/* ========================================
   CONSULTANT DASHBOARD - Dark Theme
   ======================================== */

/* Commission Row Cards */
[data-theme="dark"] .commission-row {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .commission-row:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
}

/* Commission Rates */
[data-theme="dark"] .commission-rates {
    background: linear-gradient(135deg, rgba(22, 160, 133, 0.15) 0%, rgba(22, 160, 133, 0.08) 100%) !important;
    border-color: rgba(22, 160, 133, 0.3) !important;
}

[data-theme="dark"] .commission-rates-title {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .commission-rate-item {
    background: #34495e !important;
    border-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

/* Network Statistics */
[data-theme="dark"] .network-stat {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #2c3e50 !important;
}

[data-theme="dark"] .network-stat:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
}

[data-theme="dark"] .network-stat-value {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .network-stat-label {
    color: #bdc3c7 !important;
}

/* Performance Metrics */
[data-theme="dark"] .performance-metric {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #2c3e50 !important;
}

[data-theme="dark"] .performance-metric:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
}

/* Network Level Tabs */
[data-theme="dark"] .network-level-tabs {
    background: #2c3e50 !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .network-level-tab {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .network-level-tab:hover {
    background: rgba(52, 73, 94, 0.5) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .network-level-tab.active {
    background: linear-gradient(135deg, var(--theme-primary) 0%, var(--theme-primary-dark) 100%) !important;
    color: white !important;
}

/* Hierarchy Items */
[data-theme="dark"] .hierarchy-item-compact {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #2c3e50 !important;
}

[data-theme="dark"] .label-compact {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .value-compact {
    color: #ecf0f1 !important;
}

/* Commission Summary Card */
[data-theme="dark"] .commission-summary-card {
    background: linear-gradient(135deg, var(--theme-primary-dark) 0%, var(--theme-primary) 100%) !important;
    color: white !important;
}

[data-theme="dark"] .commission-summary-title {
    color: rgba(255, 255, 255, 0.85) !important;
}

[data-theme="dark"] .commission-summary-value {
    color: white !important;
}

[data-theme="dark"] .commission-summary-change {
    background: rgba(255, 255, 255, 0.2) !important;
}

/* Top Performers */
[data-theme="dark"] .top-performer-item {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #2c3e50 !important;
}

[data-theme="dark"] .top-performer-item:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
}

/* Achievement Counter */
[data-theme="dark"] #achievementCounter .achievement-count {
    color: #ecf0f1 !important;
}

[data-theme="dark"] #achievementCounter .achievement-label {
    color: #bdc3c7 !important;
}

[data-theme="dark"] #achievementCounter .achievement-icon {
    color: var(--theme-accent) !important;
}

/* Commission Breakdown Sidebar - Level Boxes (Direct, L1, L2, L3) */
[data-theme="dark"] .breakdown-item-sidebar {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .breakdown-item-sidebar:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
}

[data-theme="dark"] .label-sidebar {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .value-sidebar {
    color: #ecf0f1 !important;
}

/* Commission Summary Items */
[data-theme="dark"] .commission-summary-item {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .commission-summary-item .summary-label {
    color: #bdc3c7 !important;
}

[data-theme="dark"] .commission-summary-item .summary-value {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .commission-summary-item .summary-count {
    color: #95a5a6 !important;
}

/* Chart Container */
[data-theme="dark"] .chart-container {
    background: #2c3e50 !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .chart-center-value {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .chart-center-label {
    color: #bdc3c7 !important;
}

/* Commission Sources Sidebar */
[data-theme="dark"] .commission-sources-sidebar .window-body-modern {
    background: #2c3e50 !important;
    color: #ecf0f1 !important;
}

/* Breakdown Items */
[data-theme="dark"] .breakdown-item {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .breakdown-item:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
}

[data-theme="dark"] .breakdown-label {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .breakdown-value {
    color: #ecf0f1 !important;
}

/* Quick Action Buttons - Compact */
[data-theme="dark"] .quick-action-btn-compact {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .quick-action-btn-compact:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .quick-action-btn-compact i {
    color: var(--theme-primary) !important;
}

[data-theme="dark"] .quick-action-btn-compact:hover i {
    color: var(--theme-primary) !important;
}

/* Quick Action Window Buttons */
[data-theme="dark"] .quick-action-window-btn {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .quick-action-window-btn:hover {
    border-color: var(--theme-primary) !important;
}

[data-theme="dark"] .action-icon-wrapper {
    background: rgba(22, 160, 133, 0.2) !important;
    border-color: rgba(22, 160, 133, 0.3) !important;
    color: var(--theme-primary) !important;
}

[data-theme="dark"] .quick-action-window-btn:hover .action-icon-wrapper {
    background: rgba(22, 160, 133, 0.3) !important;
    border-color: var(--theme-primary) !important;
    color: white !important;
}

[data-theme="dark"] .action-label {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .quick-action-window-btn:hover .action-label {
    color: white !important;
}

/* Quick Actions Compact Container */
[data-theme="dark"] .quick-actions-compact {
    background: transparent;
}

/* Detailed Commissions Container - Table Rows */
[data-theme="dark"] #detailedCommissionsContainer .table tbody tr {
    background: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table tbody tr:hover {
    background: #34495e !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table tbody td {
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table thead th {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table thead th.sortable:hover {
    background: #3d566e !important;
}

[data-theme="dark"] #detailedCommissionsContainer .detailed-commissions .card {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%) !important;
    border-color: #34495e !important;
}

[data-theme="dark"] #detailedCommissionsContainer .detailed-commissions .card h4 {
    color: #ecf0f1 !important;
}

[data-theme="dark"] #detailedCommissionsContainer .detailed-commissions .card h6 {
    color: #bdc3c7 !important;
}

[data-theme="dark"] #detailedCommissionsContainer .detailed-commissions .card small {
    color: #bdc3c7 !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table-responsive {
    border-color: #34495e !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table-primary {
    background: linear-gradient(135deg, rgba(22, 160, 133, 0.2) 0%, rgba(22, 160, 133, 0.1) 100%) !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table-success {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.2) 0%, rgba(52, 152, 219, 0.1) 100%) !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table-warning {
    background: linear-gradient(135deg, rgba(230, 126, 34, 0.2) 0%, rgba(230, 126, 34, 0.1) 100%) !important;
}

[data-theme="dark"] #detailedCommissionsContainer .table-info {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.2) 0%, rgba(243, 156, 18, 0.1) 100%) !important;
}

/* Commission Table */
[data-theme="dark"] .commission-table tbody tr {
    background: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] .commission-table tbody tr:hover {
    background: #34495e !important;
}

[data-theme="dark"] .commission-table tbody td {
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .commission-table thead th {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ecf0f1 !important;
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] .commission-table .status-badge.pending {
    background: rgba(230, 126, 34, 0.2) !important;
    color: #f39c12 !important;
}

[data-theme="dark"] .commission-table .status-badge.paid {
    background: rgba(39, 174, 96, 0.2) !important;
    color: #2ecc71 !important;
}

/* Commission Group Header */
[data-theme="dark"] .commission-group-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #34495e !important;
}

[data-theme="dark"] .commission-group-title {
    color: #ecf0f1 !important;
}

[data-theme="dark"] .commission-group-total {
    color: #ecf0f1 !important;
}

/* Load More Button */
[data-theme="dark"] #loadMoreCommissionsBtn {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] #loadMoreCommissionsBtn:hover {
    background: linear-gradient(135deg, #3d566e 0%, #34495e 100%) !important;
    border-color: var(--theme-primary) !important;
}

[data-theme="dark"] #loadMoreCommissionsContainer {
    border-top-color: #34495e !important;
}
  
/* Commission pages */
[data-theme="dark"] .commission-details-card {
    background: #2c3e50 !important;
    border-color: #34495e !important;
}

/* Network tree */
[data-theme="dark"] .org-chart-container {
    background: #2c3e50 !important;
}

[data-theme="dark"] .node-card {
    background: #34495e !important;
    border-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

/* MLM Overview specific */
[data-theme="dark"] .mlm-overview-page .page-header,
[data-theme="dark"] .mlm-dashboard .page-header-modern {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-color: #34495e;
}

[data-theme="dark"] .mlm-overview-page .page-title,
[data-theme="dark"] .mlm-dashboard .page-title {
    color: #ecf0f1;
}

[data-theme="dark"] .mlm-network-tree-page .tree-node .node-content,
[data-theme="dark"] .node-card {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .mlm-consultants-page .consultants-table,
[data-theme="dark"] .mlm-reports-page .report-table {
    color: #e2e8f0;
}

[data-theme="dark"] .page-header-modern .btn-primary {
    background: var(--theme-primary);
    color: white;
}

[data-theme="dark"] .page-header-modern .btn-outline-primary {
    border-color: var(--theme-primary);
    color: var(--theme-primary);
}

[data-theme="dark"] .page-header-modern .btn-outline-primary:hover {
    background: var(--theme-primary);
    color: white;
}

/* ========================================
   PROPERTY DETAILS PAGE - Dark Theme (legacy layout only)
   Obsidian property details (.prop-obsidian-ui) uses property-details-obsidian.css
   ======================================== */

/* Property Section Cards */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .property-section {
    background: #2c3e50 !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .section-title {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .property-description {
    color: #bdc3c7 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .read-more {
    color: var(--theme-primary) !important;
}

/* Feature Items */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .feature-item {
    background: #34495e !important;
    border-color: #2c3e50 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .feature-text h6 {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .feature-value {
    color: #ecf0f1 !important;
}

/* Amenities */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .amenity-item {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .amenity-item i {
    color: var(--theme-success) !important;
}

/* Owner Card */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .owner-card {
    background: #34495e !important;
    border-color: #2c3e50 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .owner-info h6 {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .owner-verified {
    color: var(--theme-success) !important;
}

/* Reviews Summary */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .reviews-summary {
    background: #34495e !important;
    border-color: #2c3e50 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .overall-rating-value {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .overall-rating-count {
    color: #bdc3c7 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .rating-label {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .rating-bar {
    background: #2c3e50 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .rating-percent {
    color: #bdc3c7 !important;
}

/* Review Items */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .review-item {
    border-bottom-color: #34495e !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .reviewer-avatar {
    background: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .reviewer-name {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .review-date {
    color: #95a5a6 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .review-text {
    color: #bdc3c7 !important;
}

/* Booking Card (Sidebar) */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .booking-card {
    background: #2c3e50 !important;
    border-color: #34495e !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .price-amount {
    color: var(--theme-primary) !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .price-unit {
    color: #bdc3c7 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .price-row {
    border-bottom-color: #34495e !important;
}

/* Gallery Book Design */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .gallery-book {
    background: #34495e !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 
                0 0 0 1px rgba(255, 255, 255, 0.05) !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .gallery-left-page {
    background: #2c3e50 !important;
    box-shadow: inset -2px 0 10px rgba(0, 0, 0, 0.2),
                2px 0 20px rgba(0, 0, 0, 0.3) !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .gallery-right-page {
    background: #2c3e50 !important;
    box-shadow: inset 2px 0 10px rgba(0, 0, 0, 0.2),
                -2px 0 20px rgba(0, 0, 0, 0.3) !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .gallery-item {
    background: #34495e !important;
}

/* Action Buttons */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .action-btn {
    background: #34495e !important;
    border-color: #2c3e50 !important;
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .action-btn:hover {
    background: #3d566e !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .action-btn.favorite.active {
    color: var(--theme-danger) !important;
    border-color: var(--theme-danger) !important;
}

/* Property Meta */
[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .property-meta {
    color: #bdc3c7 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .property-header h1 {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .rating-value {
    color: #ecf0f1 !important;
}

[data-theme="dark"] body:not(:has(.prop-obsidian-ui)) .rating-count {
    color: #bdc3c7 !important;
}

/* ========================================
   UTILITY OVERRIDES - Dark Theme
   ======================================== */

/* Ensure white backgrounds are overridden */
[data-theme="dark"] [style*="background: white"],
[data-theme="dark"] [style*="background: #fff"],
[data-theme="dark"] [style*="background: #ffffff"],
[data-theme="dark"] [style*="background-color: white"],
[data-theme="dark"] [style*="background-color: #fff"],
[data-theme="dark"] [style*="background-color: #ffffff"] {
    background: #2c3e50 !important;
    background-color: #2c3e50 !important;
}

