/* =============================================================================
   Theme Overrides
   Light theme component style overrides
   ============================================================================= */

[data-theme="light"] body {
    background: var(--bg-primary);
}

[data-theme="light"] .solar-metric,
[data-theme="light"] .weather-metric,
[data-theme="light"] .device-card,
[data-theme="light"] .power-device,
[data-theme="light"] .saltwater-device,
[data-theme="light"] .saltwater-metric,
[data-theme="light"] .power-metric,
[data-theme="light"] .alert,
[data-theme="light"] .weather-station,
[data-theme="light"] .floor-plan,
[data-theme="light"] .isp-stat {
    background: var(--bg-hover);
}

[data-theme="light"] .solar-metric:hover,
[data-theme="light"] .weather-metric:hover,
[data-theme="light"] .device-card:hover,
[data-theme="light"] .isp-stat:hover {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .solar-metric.primary {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
}

[data-theme="light"] .weather-metric.primary {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: #fff;
}

[data-theme="light"] .power-device-switch.switch-on {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.2) 0%, rgba(76, 175, 80, 0.1) 100%);
    border-color: rgba(76, 175, 80, 0.4);
}

[data-theme="light"] .power-device-switch.switch-off {
    background: var(--bg-hover);
    border-color: var(--border-muted);
}

[data-theme="light"] .device-card.switch-on,
[data-theme="light"] .power-device.has-switch.switch-on {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.18) 0%, rgba(76, 175, 80, 0.08) 100%);
}

[data-theme="light"] .garage-image-wrapper {
    border-color: var(--border-muted);
}

[data-theme="light"] .status-badge.disconnected {
    background: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .tab-btn,
[data-theme="light"] .header-btn,
[data-theme="light"] .settings-link,
[data-theme="light"] .restart-btn {
    background: rgba(0, 0, 0, 0.05);
    border-color: var(--border-muted);
}

[data-theme="light"] .sensor-info-card {
    background: rgba(255, 255, 255, 0.95);
    border-color: var(--border-muted);
}

[data-theme="light"] .sensor-tooltip {
    background: var(--bg-card);
    border-color: var(--border-muted);
}

[data-theme="light"] .chart-legend {
    border-top-color: var(--border-subtle);
}

[data-theme="light"] .device-toggle,
[data-theme="light"] .tuya-toggle {
    background: rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .saltwater-level-btn,
[data-theme="light"] .saltwater-boost-btn {
    border-color: var(--border-muted);
    color: var(--text-secondary);
}

[data-theme="light"] .saltwater-status-badge.off {
    background: rgba(0, 0, 0, 0.1);
}

/* Light theme: fix white-on-white text in active/hover states */
[data-theme="light"] .tab-btn.active {
    background: var(--accent-blue);
    color: #fff;
}

[data-theme="light"] .header-btn:hover,
[data-theme="light"] .header-btn.active {
    background: rgba(0, 0, 0, 0.08);
    color: var(--text-primary);
}

[data-theme="light"] .saltwater-level-btn.active {
    color: #fff;
}

[data-theme="light"] .saltwater-alert.fault {
    color: var(--text-primary);
}

[data-theme="light"] .col-select-btn {
    background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .col-select-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .col-select-btn.active {
    color: #fff;
}

[data-theme="light"] .customize-toggle-slider {
    background: rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .customize-card-item:hover {
    background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .customize-close-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .card-dismiss {
    background: rgba(233, 69, 96, 0.1);
}

[data-theme="light"] .card-dismiss:hover {
    background: rgba(233, 69, 96, 0.3);
}

[data-theme="light"] .card-drag-handle:hover {
    background: rgba(0, 100, 255, 0.08);
}

[data-theme="light"] .card-ghost {
    background: rgba(0, 100, 255, 0.04) !important;
    border-color: var(--accent-blue) !important;
}

[data-theme="light"] .card-drag {
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.15), 0 0 0 2px var(--accent-blue);
}

[data-theme="light"] .card-chosen {
    box-shadow: 0 12px 40px rgba(0, 100, 255, 0.2), 0 0 0 2px var(--accent-blue);
}

[data-theme="light"] .card-toast {
    background: #fff;
    color: var(--text-primary);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border-color: var(--border-muted);
}

[data-theme="light"] .customize-card-order {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .customize-done-btn:hover {
    background: #1a8cff;
}

[data-theme="light"] .customize-drag-handle {
    color: rgba(0, 0, 0, 0.25);
}

[data-theme="light"] .customize-drag-handle:hover {
    color: var(--accent-blue);
    background: rgba(0, 100, 255, 0.08);
}

[data-theme="light"] .customize-card-ghost {
    background: rgba(0, 100, 255, 0.06) !important;
    border-color: var(--accent-blue) !important;
}

[data-theme="light"] .customize-card-hidden {
    background: rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .customize-restore-btn {
    background: rgba(0, 100, 255, 0.08);
    color: var(--accent-blue);
}

[data-theme="light"] .customize-restore-btn:hover {
    background: rgba(0, 100, 255, 0.15);
}

[data-theme="light"] .customize-drag-hint {
    color: var(--text-secondary);
}

[data-theme="light"] .customize-hidden-count {
    background: rgba(0, 0, 0, 0.06);
    color: var(--text-secondary);
}

[data-theme="light"] .customize-device-panel {
    border-top-color: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .customize-device-item:hover {
    background: rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .customize-device-drag {
    color: rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .customize-device-drag:hover {
    color: var(--accent-blue);
}

[data-theme="light"] .customize-group {
    border-color: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .customize-group-header {
    background: rgba(0, 0, 0, 0.02);
}

[data-theme="light"] .customize-group-drag {
    color: rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .customize-group-count {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .customize-add-group-btn:hover,
[data-theme="light"] .customize-import-rooms-btn:hover {
    background: rgba(0, 100, 255, 0.08);
}

[data-theme="light"] .customize-hidden-devices {
    border-top-color: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .customize-restore-device-btn {
    background: rgba(0, 100, 255, 0.08);
}

[data-theme="light"] .customize-restore-device-btn:hover {
    background: rgba(0, 100, 255, 0.15);
}

[data-theme="light"] .device-group-header:hover {
    background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .device-dismiss-btn {
    background: rgba(233, 69, 96, 0.15);
    color: var(--accent);
}

[data-theme="light"] .device-dismiss-btn:hover {
    background: rgba(233, 69, 96, 0.3);
}

[data-theme="light"] .alert {
    background: rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .alert:hover {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .alert-critical {
    border-color: rgba(233, 69, 96, 0.3);
}

[data-theme="light"] .alert-warning {
    border-color: rgba(217, 119, 6, 0.3);
}

[data-theme="light"] .notification {
    color: #fff;
}

[data-theme="light"] .search-result-type {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .search-footer kbd {
    background: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .user-switcher-dropdown {
    background: var(--bg-card);
    border-color: var(--border-muted);
}

[data-theme="light"] .user-option:hover {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .edit-mode-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .floor-plan {
    background: rgba(0, 0, 0, 0.02);
}

[data-theme="light"] .floor-plan-header {
    background: rgba(0, 0, 0, 0.04);
    border-bottom-color: var(--border-subtle);
}
/* Light theme overrides for snooze */
[data-theme="light"] .snooze-menu {
    border-color: rgba(0, 0, 0, 0.15);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .snooze-menu button:hover {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .alert-snooze-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .snoozed-indicator:hover {
    background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .alert-unsnooze-btn {
    background: rgba(0, 0, 0, 0.06);
    border-color: rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .alert-unsnooze-btn:hover {
    background: rgba(0, 0, 0, 0.12);
}
/* Light theme overrides for schedules */
[data-theme="light"] .schedule-item {
    background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .schedule-toggle-btn,
[data-theme="light"] .schedule-edit-btn,
[data-theme="light"] .schedule-delete-btn {
    background: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .schedules-add-btn {
    border-color: rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .schedules-sun-bar {
    background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .schedule-modal {
    background: #fff;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .schedule-modal select,
[data-theme="light"] .schedule-modal input[type="number"] {
    background: #f5f5f5;
    border-color: #ddd;
    color: #333;
}
[data-theme="light"] .user-switcher-dropdown {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

[data-theme="light"] .user-option:hover {
    background: rgba(0, 0, 0, 0.05);
}
[data-theme="light"] .customize-promote-toggle {
    border-color: rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .customize-promote-label {
    color: rgba(0, 0, 0, 0.5);
}

[data-theme="light"] .customize-promote-toggle:has(input:checked) .customize-promote-label {
    color: #4a90e2;
}
