/* Dark mode overrides the same components; no filters are applied to the application. */
html[data-webin-theme=dark] { --webin-purple: #c5a1e1; --webin-deep: #dbbdf0; --webin-accent: #b287d2; --webin-ink: #eeeaf3; --webin-muted: #b8b0c3; --webin-border: #3c3448; --webin-surface: #19161f; --webin-soft: #34283f; --webin-red: #bf455a; --webin-green: #82d3a7; }
[data-webin-theme=dark] .webin-desktop-header,
[data-webin-theme=dark] .webin-sidebar, [data-webin-theme=dark] .webin-sidebar .x-panel-body,
[data-webin-theme=dark] .webin-sidebar .x-panel-header,
[data-webin-theme=dark] .webin-navigation .x-grid-view,
[data-webin-theme=dark] .webin-navigation .x-grid-item,
[data-webin-theme=dark] .webin-work-view .x-toolbar-default,
[data-webin-theme=dark] .webin-work-view .x-grid,
[data-webin-theme=dark] .webin-work-view .x-grid .x-panel-body,
[data-webin-theme=dark] .x-panel-body-default,
[data-webin-theme=dark] .x-window-default,
[data-webin-theme=dark] .x-window-header-default,
[data-webin-theme=dark] .x-menu-body-default,
[data-webin-theme=dark] .x-menu-default,
[data-webin-theme=dark] .webin-card .x-panel-body,
[data-webin-theme=dark] .webin-card .x-toolbar-footer,
[data-webin-theme=dark] .webin-finance-summary > div,
[data-webin-theme=dark] .webin-cash-summary > div,
[data-webin-theme=dark] .webin-summary > div,
[data-webin-theme=dark] .webin-empty-state,
[data-webin-theme=dark] .webin-organization-menu,
[data-webin-theme=dark] .webin-organization-menu .x-menu-body,
[data-webin-theme=dark] .webin-organization-list .x-grid-view,
[data-webin-theme=dark] .webin-organization-list .x-grid-item { background: #231e2b; color: var(--webin-ink); }
[data-webin-theme=dark] .webin-work-view .x-grid-item { background: #231e2b; border-color: #342d3e; }
[data-webin-theme=dark] .webin-work-view .x-grid-item-over,
[data-webin-theme=dark] .webin-navigation .x-grid-item-over { background: #2e2638; }
[data-webin-theme=dark] .webin-work-view .x-grid-item-selected,
[data-webin-theme=dark] .webin-navigation .x-grid-item-selected { background: var(--webin-soft); }
[data-webin-theme=dark] .webin-work-view .x-column-header,
[data-webin-theme=dark] .webin-work-view .x-grid-header-ct,
[data-webin-theme=dark] .webin-work-view .x-grid-row-summary .x-grid-cell,
[data-webin-theme=dark] .x-window .x-toolbar-footer,
[data-webin-theme=dark] .webin-login-footer { background: #292330; border-color: var(--webin-border); color: var(--webin-muted); }
[data-webin-theme=dark] .webin-work-tabs > .x-tab-bar,
[data-webin-theme=dark] .webin-work-tabs > .x-panel-bodyWrap > .x-tab-bar,
[data-webin-theme=dark] .webin-cash-tabs > .x-tab-bar,
[data-webin-theme=dark] .webin-cash-tabs > .x-panel-bodyWrap > .x-tab-bar,
[data-webin-theme=dark] .webin-cash-tabs .x-tab-default-top { background: #211b29; }
[data-webin-theme=dark] .webin-work-tabs .x-tab-active.x-tab-default-top { background: var(--webin-surface); }
[data-webin-theme=dark] .webin-cash-tabs .x-tab-active.x-tab-default-top { background: #231e2b; }
[data-webin-theme=dark] .webin-work-view .x-btn-default-toolbar-small,
[data-webin-theme=dark] .webin-work-view .x-btn-default-small,
[data-webin-theme=dark] .x-window .x-btn-default-small,
[data-webin-theme=dark] .webin-login-card .webin-secondary.x-btn { background: #2b2434; border-color: #51455e; }
[data-webin-theme=dark] .webin-work-view .x-btn-over,
[data-webin-theme=dark] .x-window .x-btn-over { background: #392d44; }
[data-webin-theme=dark] body .webin-primary.x-btn,
[data-webin-theme=dark] body .webin-login-card .webin-login-submit.x-btn-default-medium { background: #774c97 !important; border-color: #9f76ba !important; }
[data-webin-theme=dark] body .webin-primary.x-btn-over { background: #8658a8 !important; }
[data-webin-theme=dark] .x-form-text-default,
[data-webin-theme=dark] .x-form-trigger-wrap-default,
[data-webin-theme=dark] .webin-sidebar .x-form-text-default,
[data-webin-theme=dark] .webin-login-field .x-form-trigger-wrap-default,
[data-webin-theme=dark] .webin-organization-menu .x-form-trigger-wrap { background: #201b28; color: var(--webin-ink); border-color: #51455e; }
[data-webin-theme=dark] .x-form-trigger-default { background: #201b28; color: var(--webin-muted); }
[data-webin-theme=dark] input::placeholder { color: #b1a5bd; }
[data-webin-theme=dark] .x-form-empty-field-default { color: #b1a5bd; }
[data-webin-theme=dark] .x-form-trigger-wrap-focus { border-color: #bc91db; box-shadow: 0 0 0 2px #bc91db25; }
[data-webin-theme=dark] .x-form-trigger-wrap-invalid { border-color: #ef92a2; }
[data-webin-theme=dark] .x-grid-empty { color: var(--webin-muted); }
[data-webin-theme=dark] .x-menu-item-text-default { color: var(--webin-ink); }
[data-webin-theme=dark] .x-menu-item-active { background: #392d44; }
[data-webin-theme=dark] .x-menu-item-icon-default,
[data-webin-theme=dark] .x-menu-item-arrow-default,
[data-webin-theme=dark] .x-menu-item-checkbox-default { color: var(--webin-purple); }
[data-webin-theme=dark] .x-menu-item-separator { border-color: var(--webin-border); }
[data-webin-theme=dark] .webin-badge-positive { background: #203d31; color: #a5e4c2; }
[data-webin-theme=dark] .webin-badge-negative { background: #472832; color: #ffb5c1; }
[data-webin-theme=dark] .webin-badge-pending { background: #44391f; color: #f2d58c; }
[data-webin-theme=dark] .webin-notice { background: #203d31; border-color: #375b48; color: #bce8ce; }
[data-webin-theme=dark] .webin-error { background: #472832; border-color: #794550; color: #ffbec8; }
[data-webin-theme=dark] .webin-required-indicator { color: #ff9fb1; }
[data-webin-theme=dark] .webin-organization-menu::before { background: #231e2b; }
[data-webin-theme=dark] .webin-organization-option { background: #2b2434; color: var(--webin-ink); }
[data-webin-theme=dark] .webin-organization-list .x-grid-item-over .webin-organization-option { background: #392d44; }
[data-webin-theme=dark] .webin-organization-current { background: #50385f; color: #e8c9ff; }
[data-webin-theme=dark] .webin-login-split,
[data-webin-theme=dark] .webin-login-split .webin-content,
[data-webin-theme=dark] .webin-login-split .webin-login-card,
[data-webin-theme=dark] .webin-login-split .webin-login-footer { background: #19161f; }
[data-webin-theme=dark] .webin-login-intro { background: #2a2035; }
[data-webin-theme=dark] .webin-login-intro::after { border-color: #b990d929; }

[data-webin-theme=dark] .webin-code-slot { background: #201b28; border-color: #51455e; color: var(--webin-ink); }
[data-webin-theme=dark] .webin-code-slot-active { border-color: #bc91db; }
[data-webin-theme=dark] .webin-permission-tree .x-tree-node-text { color: var(--webin-ink); }
[data-webin-theme=dark] .webin-permission-tree .webin-permission-unavailable .x-tree-node-text { color: #a194ad; }
[data-webin-theme=dark] .x-datepicker, [data-webin-theme=dark] .x-datepicker-inner { background: #231e2b; border-color: var(--webin-border); }
[data-webin-theme=dark] .x-datepicker-date { color: var(--webin-ink); }
[data-webin-theme=dark] .x-datepicker-column-header, [data-webin-theme=dark] .x-datepicker-footer { background: #292330; }
[data-webin-theme=dark] .x-datepicker-column-header-inner { color: var(--webin-muted); }
[data-webin-theme=dark] .x-datepicker-prevday .x-datepicker-date, [data-webin-theme=dark] .x-datepicker-nextday .x-datepicker-date { color: #998ca5; }
[data-webin-theme=dark] .x-datepicker-cell:hover .x-datepicker-date { background: #392d44; }
[data-webin-theme=dark] .x-datepicker-selected .x-datepicker-date { background: #774c97; color: #fff; }
[data-webin-theme=dark] .x-boundlist { background: #231e2b; border-color: #51455e; }
[data-webin-theme=dark] .x-boundlist-item { color: var(--webin-ink); }
[data-webin-theme=dark] .x-boundlist-item-over, [data-webin-theme=dark] .x-boundlist-selected { background: #392d44; border-color: #774c97; }
[data-webin-theme=dark] .x-splitter { background: #292330; }
[data-webin-theme=dark] .x-mask { background: #0c0911; opacity: .55; }
[data-webin-theme=dark] .x-mask-msg { background: #2b2434; border-color: var(--webin-border); }
[data-webin-theme=dark] .x-mask-msg-text { color: var(--webin-ink); }
[data-webin-theme=dark] .startup { color: var(--webin-ink); }
[data-webin-theme=dark] .webin-desktop-header .x-btn { background: transparent; border-color: transparent; }
[data-webin-theme=dark] .webin-desktop-header .x-btn-over,
[data-webin-theme=dark] .webin-desktop-header .x-btn-focus,
[data-webin-theme=dark] .webin-desktop-header .x-btn-menu-active { background: #34283f; border-color: #665074; }
[data-webin-theme=dark] .x-collapse-el { background-color: #3c3448; color: var(--webin-muted); }
[data-webin-theme=dark] .x-form-display-field-default { color: var(--webin-ink); }
[data-webin-theme=dark] .x-splitter-collapse-el { background-color: #3c3448; color: var(--webin-muted); }
/* Floating editors and permission trees share the same dark surfaces as workspace grids. */
html[data-webin-theme=dark] { --webin-panel: #231e2b; --webin-hover: #2e2638; }
[data-webin-theme=dark] .x-grid-view, [data-webin-theme=dark] .x-grid-item { background-color: var(--webin-panel); color: var(--webin-ink); }
[data-webin-theme=dark] .x-grid-item-over { background: var(--webin-hover); }
[data-webin-theme=dark] .x-grid-item-selected { background: var(--webin-soft); }
[data-webin-theme=dark] .x-toolbar-default { background: var(--webin-panel); border-color: var(--webin-border); }
[data-webin-theme=dark] .x-btn-default-toolbar-small { background: #2b2434; border-color: #51455e; border-radius: 5px; }
[data-webin-theme=dark] .x-btn-inner, [data-webin-theme=dark] .x-btn-icon-el { color: var(--webin-ink); }
[data-webin-theme=dark] .x-keyboard-mode .x-btn.x-btn-focus,
[data-webin-theme=dark] .x-btn.x-btn-pressed, [data-webin-theme=dark] .x-btn.x-btn-menu-active { background: var(--webin-soft); border-color: var(--webin-accent); box-shadow: none; }
[data-webin-theme=dark] .webin-dashboard-button.x-btn { background: transparent; }
[data-webin-theme=dark] .webin-dashboard-button.x-btn-over, [data-webin-theme=dark] .webin-dashboard-button.x-btn-focus,
[data-webin-theme=dark] .webin-dashboard-active.x-btn { background: var(--webin-soft); }
[data-webin-theme=dark] .webin-permission-tree .x-grid-view, [data-webin-theme=dark] .webin-permission-tree .x-grid-item { background: var(--webin-panel); }
[data-webin-theme=dark] .webin-permission-tree .x-grid-item-over { background: var(--webin-hover); }
[data-webin-theme=dark] .webin-permission-tree .x-grid-item-selected { background: var(--webin-soft); }
[data-webin-theme=dark] .x-menu-item-default.x-menu-item-focus,
[data-webin-theme=dark] .x-menu-item-default.x-menu-item-active { background: var(--webin-soft); }
[data-webin-theme=dark] .webin-signout-item .x-menu-item-text-default,
[data-webin-theme=dark] .webin-signout-item .x-menu-item-icon-default { color: #ffb5c1; }
html[data-webin-theme=dark] { --webin-incoming-bg: #1e3029; --webin-incoming: #a5e4c2; --webin-outgoing-bg: #36232c; --webin-outgoing: #ffb5c1; --webin-balance-bg: #2d2339; --webin-balance: #d6b4ef; --webin-projected-bg: #29263b; --webin-projected: #c9b9ec; }
[data-webin-theme=dark] .webin-work-view .x-grid-row-summary .x-grid-cell,
[data-webin-theme=dark] .x-grid-row-summary .x-grid-cell-rowbody,
[data-webin-theme=dark] .x-grid-row-summary .x-grid-rowwrap { background-color: #292330 !important; color: var(--webin-ink); border-color: var(--webin-border); }
[data-webin-theme=dark] .x-docked-summary, [data-webin-theme=dark] .x-docked-summary .x-grid-item { background: #292330; }
[data-webin-theme=dark] .x-grid-empty { background-color: var(--webin-panel); color: var(--webin-muted); }
[data-webin-theme=dark] .x-form-spinner-default { background-color: #201b28; color: var(--webin-muted); }
[data-webin-theme=dark] .webin-cash-summary > .webin-metric-incoming, [data-webin-theme=dark] .webin-finance-summary > .webin-metric-incoming { background: var(--webin-incoming-bg); }
[data-webin-theme=dark] .webin-cash-summary > .webin-metric-outgoing, [data-webin-theme=dark] .webin-cash-summary > .webin-metric-negative, [data-webin-theme=dark] .webin-finance-summary > .webin-metric-outgoing { background: var(--webin-outgoing-bg); }
[data-webin-theme=dark] .webin-cash-summary > .webin-metric-balance { background: var(--webin-balance-bg); }
[data-webin-theme=dark] .webin-cash-summary > .webin-metric-projected { background: var(--webin-projected-bg); }
[data-webin-theme=dark] .x-docked-summary, [data-webin-theme=dark] .x-docked-summary > :first-child { background-color: #292330 !important; }
[data-webin-theme=dark] .x-grid-inner-locked { border-right-color: var(--webin-border); }
[data-webin-theme=dark] .webin-dashboard-tools.x-toolbar { background: transparent; }
[data-webin-theme=dark] .webin-dashboard-tools .x-btn { background: transparent; border-color: transparent; }
[data-webin-theme=dark] .webin-dashboard-due-tabs > .x-tab-bar,
[data-webin-theme=dark] .webin-dashboard-due-tabs > .x-panel-bodyWrap > .x-tab-bar { background: transparent; }
[data-webin-theme=dark] .x-column-header-over,
[data-webin-theme=dark] .x-column-header-open,
[data-webin-theme=dark] .x-column-header-sort-ASC,
[data-webin-theme=dark] .x-column-header-sort-DESC,
[data-webin-theme=dark] .webin-work-view .x-column-header-over,
[data-webin-theme=dark] .webin-work-view .x-column-header-open { background: #34283f; color: var(--webin-ink); }
[data-webin-theme=dark] .x-column-header-trigger,
[data-webin-theme=dark] .x-column-header-trigger-over,
[data-webin-theme=dark] .x-column-header-trigger-pressed { background: #34283f; color: var(--webin-purple); border-left-color: var(--webin-border); }

[data-webin-theme=dark] .x-window-body-default { background: var(--webin-panel); color: var(--webin-ink); }
[data-webin-theme=dark] .x-window .x-column-header,
[data-webin-theme=dark] .x-window .x-grid-header-ct { background: #292330; color: var(--webin-muted); border-color: var(--webin-border); }
[data-webin-theme=dark] .x-window .x-tab-bar-default { background: #211b29; }
[data-webin-theme=dark] .x-window .x-tab-active.x-tab-default-top { background: var(--webin-panel); }
[data-webin-theme=dark] .x-window .x-btn-default-toolbar-small { background: #2b2434; border-color: #51455e; }
[data-webin-theme=dark] .x-window .x-btn-default-toolbar-small.x-btn-over { background: #392d44; }
[data-webin-theme=dark] .x-window .x-column-header-over,
[data-webin-theme=dark] .x-window .x-column-header-open { background: #34283f; color: var(--webin-ink); }
[data-webin-theme=dark] .webin-login-card > .x-panel-bodyWrap > .x-panel-body { background: var(--webin-panel); color: var(--webin-ink); }
[data-webin-theme=dark] .webin-login-split .webin-login-card > .x-panel-bodyWrap > .x-panel-body { background: #19161f; }
