html.theme-dark,
html.theme-dark body,
html.theme-dark #app,
html.theme-dark .app-theme-root {
  background-color: #020617;
  color: #e5e7eb;
}

html.theme-dark {
  --tauri-dark-bg: #020617;
  --tauri-dark-surface: #0f172a;
  --tauri-dark-surface-2: #111827;
  --tauri-dark-surface-3: #1e293b;
  --tauri-dark-border: rgba(148, 163, 184, 0.18);
  --tauri-dark-border-strong: rgba(148, 163, 184, 0.28);
  --tauri-dark-text: #e5e7eb;
  --tauri-dark-text-soft: #cbd5e1;
  --tauri-dark-text-muted: #94a3b8;
}

html.theme-dark .ant-modal-content,
html.theme-dark .ant-modal-header,
html.theme-dark .ant-modal-footer,
html.theme-dark .ant-drawer-content,
html.theme-dark .ant-drawer-header,
html.theme-dark .ant-drawer-body,
html.theme-dark .ant-popover-inner,
html.theme-dark .ant-dropdown-menu,
html.theme-dark .ant-select-dropdown,
html.theme-dark .ant-picker-panel-container,
html.theme-dark .ant-picker-dropdown .ant-picker-panel-container,
html.theme-dark .ant-menu-submenu-popup .ant-menu,
html.theme-dark .ant-notification-notice,
html.theme-dark .ant-message-notice-content {
  background: var(--tauri-dark-surface) !important;
  color: var(--tauri-dark-text) !important;
  border-color: var(--tauri-dark-border) !important;
}

html.theme-dark .ant-modal-content,
html.theme-dark .ant-drawer-content,
html.theme-dark .ant-popover-inner,
html.theme-dark .ant-dropdown-menu,
html.theme-dark .ant-select-dropdown,
html.theme-dark .ant-picker-panel-container,
html.theme-dark .ant-notification-notice,
html.theme-dark .ant-message-notice-content {
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.38) !important;
}

html.theme-dark .ant-modal-header,
html.theme-dark .ant-modal-footer,
html.theme-dark .ant-drawer-header,
html.theme-dark .ant-popover-title,
html.theme-dark .ant-dropdown-menu-item,
html.theme-dark .ant-dropdown-menu-submenu-title,
html.theme-dark .ant-menu-item,
html.theme-dark .ant-menu-submenu-title {
  border-color: var(--tauri-dark-border) !important;
}

html.theme-dark .ant-modal-title,
html.theme-dark .ant-drawer-title,
html.theme-dark .ant-popover-title,
html.theme-dark .ant-select-item,
html.theme-dark .ant-dropdown-menu-title-content,
html.theme-dark .ant-dropdown-menu-item,
html.theme-dark .ant-empty-description,
html.theme-dark .ant-form-item-label > label,
html.theme-dark .ant-descriptions-item-label,
html.theme-dark .ant-descriptions-item-content,
html.theme-dark .ant-picker-header,
html.theme-dark .ant-picker-content th,
html.theme-dark .ant-picker-cell,
html.theme-dark .ant-message-custom-content,
html.theme-dark .ant-notification-notice-message,
html.theme-dark .ant-notification-notice-description {
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-modal-confirm .ant-modal-content,
html.theme-dark .ant-modal-confirm .ant-modal-confirm-body,
html.theme-dark .ant-modal-confirm .ant-modal-confirm-paragraph {
  background: var(--tauri-dark-surface) !important;
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-modal-confirm .ant-modal-confirm-title,
html.theme-dark .ant-modal-confirm .ant-modal-confirm-content,
html.theme-dark .ant-modal-confirm .ant-modal-confirm-content *,
html.theme-dark .ant-modal-confirm .ant-modal-confirm-body .ant-modal-confirm-title + div {
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-modal-confirm .ant-modal-confirm-btns {
  border-top: 1px solid var(--tauri-dark-border) !important;
}

html.theme-dark .ant-input,
html.theme-dark .ant-input-affix-wrapper,
html.theme-dark .ant-input-number,
html.theme-dark .ant-input-number-group-addon,
html.theme-dark .ant-select-selector,
html.theme-dark .ant-picker,
html.theme-dark .ant-mentions,
html.theme-dark .ant-mentions > textarea,
html.theme-dark .ant-input-group-addon,
html.theme-dark textarea.ant-input {
  background: var(--tauri-dark-surface) !important;
  border-color: var(--tauri-dark-border) !important;
  color: var(--tauri-dark-text) !important;
  box-shadow: none !important;
}

html.theme-dark .ant-input:hover,
html.theme-dark .ant-input:focus,
html.theme-dark .ant-input-affix-wrapper:hover,
html.theme-dark .ant-input-affix-wrapper-focused,
html.theme-dark .ant-input-number:hover,
html.theme-dark .ant-input-number-focused,
html.theme-dark .ant-select-focused .ant-select-selector,
html.theme-dark .ant-picker:hover,
html.theme-dark .ant-picker-focused {
  border-color: var(--tauri-dark-border-strong) !important;
}

html.theme-dark .ant-input::placeholder,
html.theme-dark .ant-input-password input::placeholder,
html.theme-dark .ant-select-selection-placeholder,
html.theme-dark .ant-picker-input > input::placeholder,
html.theme-dark .ant-mentions > textarea::placeholder {
  color: var(--tauri-dark-text-muted) !important;
}

html.theme-dark .ant-input-number-input,
html.theme-dark .ant-input-password input,
html.theme-dark .ant-picker-input > input,
html.theme-dark .ant-select-selection-item,
html.theme-dark .ant-select-arrow,
html.theme-dark .ant-picker-suffix,
html.theme-dark .ant-picker-clear,
html.theme-dark .ant-input-prefix,
html.theme-dark .ant-input-suffix,
html.theme-dark .ant-input-password-icon,
html.theme-dark .ant-input-password-icon .anticon,
html.theme-dark .anticon-eye,
html.theme-dark .anticon-eye-invisible {
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-btn-default,
html.theme-dark .ant-input-search-button {
  background: var(--tauri-dark-surface-3) !important;
  border-color: var(--tauri-dark-border) !important;
  color: #ffffff !important;
}

html.theme-dark .ant-btn-default:hover,
html.theme-dark .ant-btn-default:focus,
html.theme-dark .ant-input-search-button:hover,
html.theme-dark .ant-input-search-button:focus {
  background: #334155 !important;
  border-color: var(--tauri-dark-border-strong) !important;
  color: #ffffff !important;
}

html.theme-dark .ant-btn-default span,
html.theme-dark .ant-btn-default .anticon,
html.theme-dark .ant-input-search-button span,
html.theme-dark .ant-input-search-button .anticon {
  color: inherit !important;
}

html.theme-dark .ant-checkbox-wrapper,
html.theme-dark .ant-radio-wrapper,
html.theme-dark .ant-switch,
html.theme-dark .ant-tag,
html.theme-dark .ant-badge-status-text,
html.theme-dark .ant-typography,
html.theme-dark .ant-list-item,
html.theme-dark .ant-collapse,
html.theme-dark .ant-collapse > .ant-collapse-item > .ant-collapse-header {
  color: var(--tauri-dark-text-soft) !important;
}

html.theme-dark .ant-checkbox-inner,
html.theme-dark .ant-radio-inner {
  background: var(--tauri-dark-surface) !important;
  border-color: var(--tauri-dark-border-strong) !important;
}

html.theme-dark .ant-select-item-option-active:not(.ant-select-item-option-disabled),
html.theme-dark .ant-select-item-option-selected:not(.ant-select-item-option-disabled),
html.theme-dark .ant-dropdown-menu-item:hover,
html.theme-dark .ant-dropdown-menu-submenu-title:hover,
html.theme-dark .ant-menu-item:hover,
html.theme-dark .ant-menu-submenu-title:hover,
html.theme-dark .ant-picker-cell-in-view.ant-picker-cell-selected .ant-picker-cell-inner,
html.theme-dark .ant-picker-cell-in-view.ant-picker-cell-range-start .ant-picker-cell-inner,
html.theme-dark .ant-picker-cell-in-view.ant-picker-cell-range-end .ant-picker-cell-inner {
  background: var(--tauri-dark-surface-3) !important;
}

html.theme-dark .ant-tabs-nav::before,
html.theme-dark .ant-tabs-top > .ant-tabs-nav::before,
html.theme-dark .ant-tabs-bottom > .ant-tabs-nav::before,
html.theme-dark .ant-tabs-left > .ant-tabs-nav::before,
html.theme-dark .ant-tabs-right > .ant-tabs-nav::before {
  border-color: var(--tauri-dark-border) !important;
}

html.theme-dark .ant-tabs-tab {
  background: var(--tauri-dark-surface-3) !important;
  border-color: var(--tauri-dark-border) !important;
  color: var(--tauri-dark-text-soft) !important;
}

html.theme-dark .ant-tabs-tab:hover,
html.theme-dark .ant-tabs-tab-active,
html.theme-dark .ant-tabs-tab-active .ant-tabs-tab-btn,
html.theme-dark .ant-tabs-tab-btn,
html.theme-dark .ant-tabs-tab-remove {
  color: #ffffff !important;
}

html.theme-dark .ant-tabs-card > .ant-tabs-nav .ant-tabs-tab-active {
  background: var(--tauri-dark-surface-2) !important;
  border-bottom-color: var(--tauri-dark-surface-2) !important;
}

html.theme-dark .ant-menu,
html.theme-dark .ant-menu-sub,
html.theme-dark .ant-menu-item,
html.theme-dark .ant-menu-submenu-title,
html.theme-dark .ant-dropdown-menu {
  background: var(--tauri-dark-surface) !important;
  color: var(--tauri-dark-text-soft) !important;
}

html.theme-dark .ant-menu-item-selected,
html.theme-dark .ant-menu-submenu-selected > .ant-menu-submenu-title {
  color: #ffffff !important;
}

html.theme-dark .ant-card,
html.theme-dark .ant-card-head,
html.theme-dark .ant-card-body,
html.theme-dark .ant-card-small > .ant-card-head {
  background: var(--tauri-dark-surface-2) !important;
  border-color: var(--tauri-dark-border) !important;
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-card-head-title,
html.theme-dark .ant-card-extra,
html.theme-dark .ant-card-meta-title,
html.theme-dark .ant-card-meta-description {
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-radio-button-wrapper {
  background: var(--tauri-dark-surface-2) !important;
  border-color: var(--tauri-dark-border) !important;
  color: var(--tauri-dark-text-soft) !important;
}

html.theme-dark .ant-radio-group-solid .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled) {
  background: var(--home-primary, #4c8dff) !important;
  border-color: var(--home-primary, #4c8dff) !important;
  color: #ffffff !important;
}

html.theme-dark .field-config-popover .ant-popover-inner {
  background: var(--tauri-dark-surface) !important;
  border: 1px solid var(--tauri-dark-border) !important;
}

html.theme-dark .field-config-popover .ant-popover-title {
  color: var(--tauri-dark-text) !important;
  border-bottom-color: var(--tauri-dark-border) !important;
}

html.theme-dark .field-config-popover__content,
html.theme-dark .field-config-popover__content * {
  color: var(--tauri-dark-text-soft);
}

html.theme-dark .field-config-popover__content .ant-slider-rail {
  background: rgba(148, 163, 184, 0.18) !important;
}

html.theme-dark .field-config-popover__content .ant-slider-track {
  background: var(--home-primary, #4c8dff) !important;
}

html.theme-dark .field-config-popover__content .ant-slider-handle::after {
  box-shadow: 0 0 0 2px var(--home-primary, #4c8dff) !important;
}

html.theme-dark .home-popconfirm .ant-popover-inner,
html.theme-dark .home-popconfirm .ant-popover-inner-content {
  background: linear-gradient(180deg, #111827 0%, #0f172a 100%) !important;
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .home-popconfirm .ant-popover-inner {
  border: 1px solid var(--tauri-dark-border) !important;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.45) !important;
}

html.theme-dark .home-popconfirm .ant-popover-message-title,
html.theme-dark .home-popconfirm .ant-popover-message-description,
html.theme-dark .home-popconfirm .ant-popover-buttons {
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .home-popconfirm .ant-popover-message .anticon {
  color: #f59e0b !important;
}

html.theme-dark .home-modal .ant-modal-body,
html.theme-dark .web .ant-modal-body,
html.theme-dark .home-modal .ant-modal-footer {
  background: var(--tauri-dark-surface) !important;
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .home-modal .ant-modal-close-x,
html.theme-dark .home-modal .ant-modal-close-icon,
html.theme-dark .home-modal .ant-modal-close .anticon {
  color: var(--tauri-dark-text-soft) !important;
}

html.theme-dark .home-modal .ant-input,
html.theme-dark .home-modal .ant-input-affix-wrapper,
html.theme-dark .home-modal .ant-select-selector,
html.theme-dark .home-modal .ant-picker,
html.theme-dark .home-modal .ant-radio-button-wrapper,
html.theme-dark .home-modal .ant-card,
html.theme-dark .home-modal .ant-card-head,
html.theme-dark .home-modal .ant-card-body {
  background: var(--tauri-dark-surface-2) !important;
  border-color: var(--tauri-dark-border) !important;
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .home-modal .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled) {
  background: var(--home-primary, #4c8dff) !important;
  border-color: var(--home-primary, #4c8dff) !important;
  color: #ffffff !important;
}

html.theme-dark .home-modal .ant-tabs-tab-btn,
html.theme-dark .home-modal .ant-tabs-tab,
html.theme-dark .home-modal .ant-card-head-title,
html.theme-dark .home-modal .ant-card-extra,
html.theme-dark .home-modal .ant-form-item-label > label,
html.theme-dark .home-modal .ant-checkbox-wrapper,
html.theme-dark .home-modal .ant-checkbox + span,
html.theme-dark .home-modal .ant-progress-text {
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-popconfirm .ant-popover-inner,
html.theme-dark .ant-popconfirm .ant-popover-inner-content {
  background: linear-gradient(180deg, #111827 0%, #0f172a 100%) !important;
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-popconfirm .ant-popover-inner {
  border: 1px solid var(--tauri-dark-border) !important;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.45) !important;
}

html.theme-dark .ant-popconfirm .ant-popover-message-title,
html.theme-dark .ant-popconfirm .ant-popover-message-title-only,
html.theme-dark .ant-popconfirm .ant-popover-message-description,
html.theme-dark .ant-popconfirm .ant-popover-buttons,
html.theme-dark .ant-popconfirm .ant-popover-buttons .ant-btn,
html.theme-dark .ant-popconfirm .ant-popover-buttons .ant-btn span,
html.theme-dark .ant-popconfirm .ant-popover-buttons .ant-btn .anticon {
  color: var(--tauri-dark-text) !important;
}

html.theme-dark .ant-popconfirm .ant-popover-message .anticon {
  color: #f59e0b !important;
}

html.theme-dark .ant-popconfirm .ant-popover-buttons .ant-btn-default {
  background: var(--tauri-dark-surface-3) !important;
  border-color: var(--tauri-dark-border) !important;
}

html.theme-dark .ant-popconfirm .ant-popover-buttons .ant-btn-primary {
  color: #ffffff !important;
}

html.theme-dark .cloud-sync-popover .ant-popover-inner,
html.theme-dark .cloud-sync-popover .ant-popover-inner-content {
  background: var(--tauri-dark-surface-2) !important;
  color: var(--tauri-dark-text) !important;
}
