/* ========================================================================== */
/*  HOTFIX | SETTINGS DARK SURFACES                                           */
/* ========================================================================== */

body[data-theme-mode="dark"] .content #app #pg-settings .s-color-box,
body[data-theme-mode="dark"] .content #app #pg-settings .s-switch-box { background: linear-gradient(180deg, rgba(10, 15, 24, .98) 0%, rgba(15, 23, 42, .98) 100%) !important; background-image: none !important; border-color: rgba(51, 65, 85, .92) !important; box-shadow: none !important; color: #e5e7eb !important; }

body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-color-box, .s-switch-box) * { background: transparent !important; }

body[data-theme-mode="dark"] .content #app #pg-settings .s-logo-zone { background: linear-gradient(180deg, rgba(10, 15, 24, .98) 0%, rgba(15, 23, 42, .98) 100%) !important; background-image: none !important; border-color: rgba(100, 116, 139, .48) !important; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .03) !important; }
body[data-theme-mode="dark"] .content #app #pg-settings .s-logo-zone:hover { background: linear-gradient(180deg, rgba(12, 18, 30, .98) 0%, rgba(17, 24, 39, .98) 100%) !important; border-color: color-mix(in srgb, var(--primary) 44%, rgba(100, 116, 139, .60) 56%) !important; }
body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-logo-zone-copy, #dropZoneContent, #faviconDropZoneContent, #mailAvatarDropZoneContent) { background: transparent !important; color: #e5e7eb !important; }
body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-logo-zone-title, .s-logo-zone-note, .s-logo-zone-icon) { color: #cbd5e1 !important; }
body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-logo-preview, .s-logo-preview-favicon, .s-logo-preview-avatar) { background: rgba(15, 23, 42, .72) !important; box-shadow: 0 8px 18px rgba(0, 0, 0, .32) !important; }
body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-input, .s-input.ui-field-soft, .s-input-icon input, input.ui-field-soft, textarea.ui-field-soft, select.ui-field-soft) { background: #0b1220 !important; background-image: none !important; border-color: rgba(100, 116, 139, .35) !important; color: #e5e7eb !important; box-shadow: none !important; }

body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-input, .s-input.ui-field-soft, .s-input-icon input, input.ui-field-soft, textarea.ui-field-soft, select.ui-field-soft)::placeholder { color: #94a3b8 !important; }

body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-input, .s-input.ui-field-soft, .s-input-icon input, input.ui-field-soft, textarea.ui-field-soft, select.ui-field-soft):focus { background: #0b1220 !important; border-color: color-mix(in srgb, var(--primary) 48%, #475569 52%) !important; box-shadow: 0 0 0 3px rgba(51, 65, 85, .32) !important; }

body[data-theme-mode="dark"] .content #app #pg-settings .ios-switch .slider { background: linear-gradient(180deg, #182232 0%, #111827 100%) !important; border-color: var(--gsw-dark-border) !important; box-shadow: inset 0 1px 2px rgba(2, 6, 23, .55) !important; }
body[data-theme-mode="dark"] .content #app #pg-settings .ios-switch .slider::before { background: #f8fafc !important; }
body[data-theme-mode="dark"] .content #app #pg-settings .ios-switch > input:checked + .slider { background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 84%, #67e8f9 16%) 0%, var(--primary) 100%) !important; border-color: color-mix(in srgb, var(--primary) 60%, #dbeafe 40%) !important; }

/* FINAL | UNIFIED BLACK DARK SURFACES */
body[data-theme-mode="dark"] {
    --gsw-dark-surface: #000000;
    --gsw-dark-surface-soft: #000000;
    --gsw-dark-surface-strong: #000000;
    --gsw-dark-bg: #000000;
}

body[data-theme-mode="dark"] :is(
    .ui-card,
    .card-panel,
    .u-table-container,
    .modal-content,
    .modal-shell,
    .confirm-modal .modal-content,
    .app-update-overlay .upd-card,
    #panelTutorial .pt-tooltip,
    #panelTutorial .pt-body,
    #panelTutorial .pt-actions,
    #missingProfileModal .mpm-card,
    #missingProfileModal .mpm-body,
    #missingProfileModal .mpm-actions,
    
    
    
    
    .gsw-delete-card,
    .content #app :is(
        .stat-card-modern,
        .ue-card,
        .ue-head,
        .us-card,
        .us-panel,
        .up-card,
        .et-head,
        .q-card,
        .et-actions,
        .u-table-card,
        .d-panel,
        .rp-panel,
        .s-card,
        .e-card,
        .t-card,
        .panel-card,
        .sticky,
        .e-stats,
        .u-pagination-wrap,
        .u-page-size-wrap,
        .t-ms-container,
        .t-ms-drop,
        .t-ms-selected,
        .t-section-item,
        .s-color-box,
        .s-switch-box,
        .s-logo-zone,
        .s-logo-size-wrap,
        .us-row,
        .us-panel-body,
        .us-chip,
        .ue-empty,
        .ue-note.limit,
        .rp-compare,
        .rp-cmp-item,
        .rp-user-card,
        .rp-chip,
        .rp-loading-card,
        .rp-chart-empty,
        .rp-chart-tooltip,
        .rp-user-modal-card,
        .rp-user-meta-item
    ),

body[data-theme-mode="dark"] :is(
    .content :is(
        input[type="text"],
        input[type="email"],
        input[type="password"],
        input[type="number"],
        input[type="tel"],
        input[type="url"],
        input[type="search"],
        input[type="date"],
        input[type="time"],
        input[type="datetime-local"],
        input[type="month"],
        input[type="week"],
        input[type="file"],
        select,
        textarea
    ),
    .admin-banner-actions :is(.u-search-input, .u-page-size-wrap, .u-page-size-input, .rp-filter .glass-input),
    .ui-select-trigger,
#missingProfileModal .mpm-field input,
    #missingProfileModal .mpm-field select,
    #pg-settings :is(.s-input, .s-input.ui-field-soft, .s-input-icon input, .s-color-box, .s-switch-box, .s-logo-zone),
    #pg-reports .rp-filter .ui-filter-control,
    #pg-user-statistics .us-track
):is(:hover, :focus, :focus-visible, :active),
body[data-theme-mode="dark"] .ui-select-picker.open .ui-select-trigger {
    background: #060606 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border-strong) !important;
    box-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

body[data-theme-mode="dark"] .modal-shell-kicker {
    background: #000000 !important;
    border-color: var(--gsw-dark-border) !important;
    color: #e5e7eb !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-color-box, .s-switch-box, .s-logo-zone) * {
    background: transparent !important;
}


body[data-theme-mode="dark"] :is(.modal-shell, .confirm-modal .modal-content, .gsw-delete-card) {
    background: #000000 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border) !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] :is(.admin-banner, #adminSectionBanner, #pg-dashboard .d-license-info, .admin-banner-stat, #pg-dashboard .d-license-icon) {
    background: #000000 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border) !important;
    box-shadow: none !important;
}

/* FINAL HOTFIX | SETTINGS ALL BLACK SURFACES */
body[data-theme-mode="dark"] #pg-settings :is(
    .panel-card,
    .settings-layout-card,
    .settings-screen-grid,
    .editor-form,
    .s-grid,
    .s-form-grid,
    .s-media-grid,
    .s-media-item,
    .smtp-header,
    .smtp-actions,
    .s-card-heading,
    .s-color-box,
    .s-switch-box,
    .s-logo-zone,
    .s-logo-size-wrap
) {
    background: #000000 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border) !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] #pg-settings :is(
    .s-input,
    .s-input.ui-field-soft,
    .s-input-icon input,
    input.ui-field-soft,
    textarea.ui-field-soft,
    select.ui-field-soft,
    .s-logo-preview,
    .s-logo-preview-favicon,
    .s-logo-preview-avatar,
    .s-logo-size-head strong,
    .s-logo-size-range,
    .ios-switch .slider
) {
    background: #000000 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border) !important;
    color: #e5e7eb !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] #pg-settings :is(
    .s-input,
    .s-input.ui-field-soft,
    .s-input-icon input,
    input.ui-field-soft,
    textarea.ui-field-soft,
    select.ui-field-soft,
    .s-logo-zone,
    .s-color-box,
    .s-switch-box
):is(:hover, :focus, :focus-visible, :active) {
    background: #050505 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border-strong) !important;
    box-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

body[data-theme-mode="dark"] #pg-settings :is(
    .s-color-box,
    .s-switch-box,
    .s-logo-zone,
    .s-logo-size-wrap
) * {
    background: transparent !important;
}

body[data-theme-mode="dark"] #pg-settings .s-logo-zone:hover {
    background: #050505 !important;
    background-image: none !important;
}

body[data-theme-mode="dark"] #pg-settings .s-logo-size-range::-webkit-slider-thumb {
    background: #000000 !important;
    border-color: var(--primary) !important;
}

body[data-theme-mode="dark"] #pg-settings .s-logo-size-range::-moz-range-thumb {
    background: #000000 !important;
    border-color: var(--primary) !important;
}

body[data-theme-mode="dark"] #pg-settings :is(
    input:-webkit-autofill,
    input:-webkit-autofill:hover,
    input:-webkit-autofill:focus,
    textarea:-webkit-autofill,
    textarea:-webkit-autofill:hover,
    textarea:-webkit-autofill:focus,
    select:-webkit-autofill,
    select:-webkit-autofill:hover,
    select:-webkit-autofill:focus
) {
    -webkit-text-fill-color: #e5e7eb !important;
    -webkit-box-shadow: 0 0 0 1000px #000000 inset !important;
    box-shadow: 0 0 0 1000px #000000 inset !important;
    border-color: var(--gsw-dark-border) !important;
    caret-color: #e5e7eb !important;
}

body[data-theme-mode="dark"] #pg-settings .s-input-icon {
    background: #000000 !important;
    background-image: none !important;
    border: 1px solid var(--gsw-dark-border) !important;
    border-radius: 14px !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] #pg-settings .s-input-icon:focus-within {
    background: #050505 !important;
    border-color: var(--gsw-dark-border-strong) !important;
    box-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

body[data-theme-mode="dark"] #pg-settings .s-input-icon > i {
    background: transparent !important;
    color: #cbd5e1 !important;
}

body[data-theme-mode="dark"] #pg-settings .s-input-icon > input.s-input.ui-field-soft,
body[data-theme-mode="dark"] #pg-settings .s-input-icon > input.s-input,
body[data-theme-mode="dark"] #pg-settings .s-smtp-grid > input.s-input.ui-field-soft,
body[data-theme-mode="dark"] #pg-settings .s-smtp-grid > input.s-input {
    background: transparent !important;
    background-image: none !important;
    border: 0 !important;
    box-shadow: none !important;
    color: #e5e7eb !important;
    appearance: none !important;
    -webkit-appearance: none !important;
}

body[data-theme-mode="dark"] #pg-settings .s-smtp-grid > input.s-input.ui-field-soft,
body[data-theme-mode="dark"] #pg-settings .s-smtp-grid > input.s-input {
    background: #000000 !important;
    border: 1px solid var(--gsw-dark-border) !important;
    border-radius: 14px !important;
}

body[data-theme-mode="dark"] #pg-settings .s-smtp-grid > input.s-input.ui-field-soft:is(:hover, :focus, :focus-visible),
body[data-theme-mode="dark"] #pg-settings .s-smtp-grid > input.s-input:is(:hover, :focus, :focus-visible) {
    background: #050505 !important;
    border-color: var(--gsw-dark-border-strong) !important;
    box-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings .ui-field-soft {
    --ui-field-bg: #000000 !important;
    --ui-field-border: var(--gsw-dark-border) !important;
    --ui-field-color: #e5e7eb !important;
    --ui-field-focus-border: var(--gsw-dark-border-strong) !important;
    --ui-field-focus-bg: #050505 !important;
    --ui-field-focus-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings .s-input-icon {
    background: #000000 !important;
    background-image: none !important;
    border: 1px solid var(--gsw-dark-border) !important;
    border-radius: 14px !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings .s-input-icon:focus-within {
    background: #050505 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border-strong) !important;
    box-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-input, .s-input.ui-field-soft, .s-input-icon input, input.ui-field-soft, textarea.ui-field-soft, select.ui-field-soft) {
    background: #000000 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border) !important;
    color: #e5e7eb !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings :is(.s-input, .s-input.ui-field-soft, .s-input-icon input, input.ui-field-soft, textarea.ui-field-soft, select.ui-field-soft):focus {
    background: #050505 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border-strong) !important;
    box-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings .s-input-icon > input.s-input.ui-field-soft,
body[data-theme-mode="dark"] .content #app #pg-settings .s-input-icon > input.s-input {
    background: transparent !important;
    background-image: none !important;
    border: 0 !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings .s-smtp-grid > input.s-input.ui-field-soft,
body[data-theme-mode="dark"] .content #app #pg-settings .s-smtp-grid > input.s-input {
    background: #000000 !important;
    background-image: none !important;
    border: 1px solid var(--gsw-dark-border) !important;
    color: #e5e7eb !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] .content #app #pg-settings .s-smtp-grid > input.s-input.ui-field-soft:is(:hover, :focus, :focus-visible),
body[data-theme-mode="dark"] .content #app #pg-settings .s-smtp-grid > input.s-input:is(:hover, :focus, :focus-visible) {
    background: #050505 !important;
    background-image: none !important;
    border-color: var(--gsw-dark-border-strong) !important;
    box-shadow: 0 0 0 3px rgba(55, 55, 55, .24) !important;
}

/* ========================================================================== */
/*  FINAL | PLAYER LIGHT PARITY                                               */
/* ========================================================================== */

body[data-theme-mode="dark"] .content #app #pg-player .stage-controls > .ui-badge,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-controls > .ui-badge {
    background: transparent !important;
    background-image: none !important;
    border: 0 !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    --gsw-badge-bg: transparent !important;
    --gsw-badge-border: transparent !important;
    --gsw-badge-text: #ffffff !important;
    font-family: var(--gsw-font-family) !important;
}

body[data-theme-mode="dark"] .content #app #pg-player .stage-controls .vol-btn,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-controls .vol-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 42px !important;
    min-width: 42px !important;
    height: 42px !important;
    border-radius: 12px !important;
    border: 1px solid #ffffff !important;
    background: #ffffff !important;
    background-image: none !important;
    color: #334155 !important;
    box-shadow: 0 10px 18px -16px rgba(15, 23, 42, .55) !important;
    filter: none !important;
    opacity: 1 !important;
}

body[data-theme-mode="dark"] .content #app #pg-player .stage-controls .vol-btn:hover,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-controls .vol-btn:hover {
    background: #ffffff !important;
    background-image: none !important;
    border-color: #ffffff !important;
    color: #334155 !important;
    transform: translateY(-2px) scale(1.03) !important;
    box-shadow: 0 14px 24px -18px rgba(15, 23, 42, .45) !important;
    filter: none !important;
    opacity: 1 !important;
}

body[data-theme-mode="dark"] .content #app #pg-player .stage-controls .vol-btn :is(i, svg),
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-controls .vol-btn :is(i, svg) {
    color: #334155 !important;
    fill: currentColor !important;
    opacity: 1 !important;
}

body[data-theme-mode="dark"] .content #app #pg-player .stage-controls :is(.time-val, .time-sep, .volume-text),
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-controls :is(.time-val, .time-sep, .volume-text) {
    color: #ffffff !important;
    font-family: var(--gsw-font-family) !important;
    -webkit-text-fill-color: #ffffff !important;
    opacity: 1 !important;
}

body[data-theme-mode="dark"] .content #app #pg-player .stage-header .btn-back,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-header .btn-back {
    background: #ffffff !important;
    background-image: none !important;
    border: 1px solid #dbe5f2 !important;
    box-shadow: 0 10px 18px -16px rgba(15, 23, 42, .55) !important;
    color: #334155 !important;
    filter: none !important;
    opacity: 1 !important;
}

body[data-theme-mode="dark"] .content #app #pg-player .stage-header .btn-back:hover,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-header .btn-back:hover {
    background: #ffffff !important;
    background-image: none !important;
    border-color: #dbe5f2 !important;
    color: #334155 !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 10px 18px -16px rgba(15, 23, 42, .55) !important;
    filter: brightness(.94) saturate(1.04) !important;
    opacity: 1 !important;
}

body[data-theme-mode="dark"] .content #app #pg-player .stage-header .btn-back :is(i, svg, .btn-back-label),
body.gsw-standalone[data-theme-mode="dark"] #pg-player .stage-header .btn-back :is(i, svg, .btn-back-label) {
    color: inherit !important;
    fill: currentColor !important;
    -webkit-text-fill-color: currentColor !important;
    opacity: 1 !important;
}


body[data-theme-mode="dark"] #pg-player .player-vol-btn,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .player-vol-btn {
    background: #ffffff !important;
    background-image: none !important;
    border: 1px solid #ffffff !important;
    color: #334155 !important;
    box-shadow: 0 10px 18px -16px rgba(15, 23, 42, .55) !important;
    opacity: 1 !important;
}

body[data-theme-mode="dark"] #pg-player .player-vol-btn:hover,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .player-vol-btn:hover {
    background: #ffffff !important;
    background-image: none !important;
    border-color: #ffffff !important;
    color: #334155 !important;
}

body[data-theme-mode="dark"] #pg-player .player-vol-btn :is(i, svg),
body.gsw-standalone[data-theme-mode="dark"] #pg-player .player-vol-btn :is(i, svg),
body[data-theme-mode="dark"] #currentTimeTxt,
body[data-theme-mode="dark"] #totalTimeTxt,
body[data-theme-mode="dark"] #volumeTxt,
body[data-theme-mode="dark"] #pg-player .time-sep,
body.gsw-standalone[data-theme-mode="dark"] #currentTimeTxt,
body.gsw-standalone[data-theme-mode="dark"] #totalTimeTxt,
body.gsw-standalone[data-theme-mode="dark"] #volumeTxt,
body.gsw-standalone[data-theme-mode="dark"] #pg-player .time-sep {
    color: #ffffff !important;
    fill: currentColor !important;
    -webkit-text-fill-color: currentColor !important;
    opacity: 1 !important;
}

/* GLOBAL ACCENT SYNC (DARK) | derive interface colors from --primary */
body[data-theme-mode="dark"] {
    --gsw-dark-accent-10: color-mix(in srgb, var(--primary) 10%, #050505 90%);
    --gsw-dark-accent-16: color-mix(in srgb, var(--primary) 16%, #050505 84%);
    --gsw-dark-accent-24: color-mix(in srgb, var(--primary) 24%, #1e293b 76%);
    --gsw-dark-accent-text: color-mix(in srgb, var(--primary) 72%, #f8fafc 28%);
}

body[data-theme-mode="dark"] .content #app :is(
    .ui-badge,
    .chip,
    .status,
    [class*='kicker']
) {
    border-color: transparent !important;
    background: var(--gsw-dark-accent-10) !important;
    color: var(--gsw-dark-accent-text) !important;
}

body[data-theme-mode="dark"] .content #app :is(
    .st-draft,
    .st-pending,
    .st-ok,
    .st-cancel
) {
    border-color: var(--gsw-dark-accent-24) !important;
    background: var(--gsw-dark-accent-10) !important;
    color: var(--gsw-dark-accent-text) !important;
}

/* Proposal status pills must keep semantic colors (not accent color) */
body[data-theme-mode="dark"] .content #app #pg-proposals .st-draft {
    border-color: #fdba74 !important;
    background: #fff7ed !important;
    color: #c2410c !important;
}

body[data-theme-mode="dark"] .content #app #pg-proposals .st-pending {
    border-color: #cbd5e1 !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
}

body[data-theme-mode="dark"] .content #app #pg-proposals .st-ok {
    border-color: #bbf7d0 !important;
    background: #ecfdf3 !important;
    color: #15803d !important;
}

body[data-theme-mode="dark"] .content #app #pg-proposals .st-cancel {
    border-color: #fecaca !important;
    background: #fef2f2 !important;
    color: #b91c1c !important;
}

body[data-theme-mode="dark"] .content #app :is(
    table thead th,
    .gsw-table-head,
    .gsw-table-head > th
) {
    background: #111827 !important;
    border-color: #22314a !important;
    color: #cbd5e1 !important;
}

body[data-theme-mode="dark"] .content #app :is(
    .ui-button.ui-button-plain,
    .ui-button.ui-button-plain,
    .ui-action-menu-panel > .ui-button,
    .ui-action-menu-panel > a.ui-button
) {
    border-color: var(--gsw-dark-accent-24) !important;
    background: #000000 !important;
    color: var(--gsw-dark-accent-text) !important;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel,
body[data-theme-mode="dark"] .ui-action-menu-panel,
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 2600;
    min-width: 236px;
    max-height: min(320px, 60vh);
    padding: 8px;
    border-radius: 18px;
    border: 1px solid var(--gsw-dark-border);
    background: #000000;
    box-shadow: none;
    display: grid;
    gap: 2px;
    overflow: auto;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel[hidden],
body[data-theme-mode="dark"] .ui-action-menu-panel[hidden],
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel[hidden] {
    display: none !important;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel > :is(.ui-button, a.ui-button),
body[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button),
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button) {
    width: 100% !important;
    min-height: 38px !important;
    margin: 0 !important;
    padding: 0 12px !important;
    display: flex !important;
    align-items: center;
    gap: 10px;
    justify-content: flex-start !important;
    text-align: left !important;
    border: 0 !important;
    border-radius: 12px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #e5e7eb !important;
    font-size: .84rem !important;
    font-weight: 700 !important;
    line-height: 1.25 !important;
    transform: none !important;
    text-decoration: none !important;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel > :is(.ui-button, a.ui-button):is(:hover, :focus-visible),
body[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button):is(:hover, :focus-visible),
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button):is(:hover, :focus-visible) {
    background: #111827 !important;
    color: #ffffff !important;
    outline: none !important;
    transform: none !important;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel > :is(.ui-button, a.ui-button):disabled,
body[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button):disabled,
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button):disabled {
    opacity: .5;
    cursor: not-allowed;
    background: transparent !important;
    color: #64748b !important;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel > :is(.ui-button, a.ui-button) :is(i, svg),
body[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button) :is(i, svg),
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button) :is(i, svg) {
    min-width: 16px;
    color: inherit;
    fill: currentColor;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel > :is(.ui-button, a.ui-button).ui-button-danger,
body[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button).ui-button-danger,
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button).ui-button-danger {
    color: #f87171 !important;
}

body[data-theme-mode="dark"] .content #app .ui-action-menu-panel > :is(.ui-button, a.ui-button).ui-button-danger:is(:hover, :focus-visible),
body[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button).ui-button-danger:is(:hover, :focus-visible),
body.gsw-standalone[data-theme-mode="dark"] .ui-action-menu-panel > :is(.ui-button, a.ui-button).ui-button-danger:is(:hover, :focus-visible) {
    background: #351515 !important;
    color: #fecaca !important;
}

/* Unified button variants: only primary + plain */
body[data-theme-mode="dark"] .content #app .ui-button.ui-button-primary,
body.gsw-standalone[data-theme-mode="dark"] .ui-button.ui-button-primary {
    background: var(--btn-gradient) !important;
    border-color: var(--primary) !important;
    color: #ffffff !important;
}

body[data-theme-mode="dark"] .content #app .ui-button.ui-button-plain,
body.gsw-standalone[data-theme-mode="dark"] .ui-button.ui-button-plain {
    background: #000000 !important;
    border-color: var(--gsw-dark-border) !important;
    color: #e5e7eb !important;
}

body[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero,.ops-focus,.ops-board,.ops-panel),
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero,.ops-focus,.ops-board,.ops-panel) {
    border-color: var(--gsw-dark-border) !important;
    background: linear-gradient(180deg, #050505 0%, #0a0a0a 100%) !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-hero {
    background:
        radial-gradient(circle at 88% 8%, color-mix(in srgb, var(--primary) 16%, transparent 84%) 0%, transparent 34%),
        linear-gradient(180deg, #050505 0%, #0a0a0a 100%) !important;
}

body[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero-copy h2,.ops-focus-head h3,.ops-board-copy h3,.ops-panel-copy h3,.ops-hero-metric strong,.ops-focus-item-head strong,.ops-stat-copy strong,.ops-item-main strong),
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero-copy h2,.ops-focus-head h3,.ops-board-copy h3,.ops-panel-copy h3,.ops-hero-metric strong,.ops-focus-item-head strong,.ops-stat-copy strong,.ops-item-main strong) {
    color: #f8fafc !important;
}

body[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero-copy p,.ops-focus-head p,.ops-board-copy p,.ops-panel-copy p,.ops-hero-metric small,.ops-stat-copy span,.ops-stat-copy small,.ops-focus-item p,.ops-item-main span,.ops-empty),
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero-copy p,.ops-focus-head p,.ops-board-copy p,.ops-panel-copy p,.ops-hero-metric small,.ops-stat-copy span,.ops-stat-copy small,.ops-focus-item p,.ops-item-main span,.ops-empty) {
    color: #94a3b8 !important;
}

body[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero-metric,.ops-focus-item,.ops-stat,.ops-item),
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard :is(.ops-hero-metric,.ops-focus-item,.ops-stat,.ops-item) {
    border-color: var(--gsw-dark-border) !important;
    background: #000000 !important;
    box-shadow: none !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-panel-count,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-panel-count {
    border-color: var(--gsw-dark-border) !important;
    background: #000000 !important;
    color: #94a3b8 !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-empty-icon,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-empty-icon {
    border-color: var(--gsw-dark-border) !important;
    background: #050505 !important;
    color: #64748b !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-empty strong,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-empty strong {
    color: #e5e7eb !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-state.is-renewal,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-state.is-renewal {
    background: #10213f !important;
    color: #93c5fd !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-state.is-soon,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-state.is-soon {
    background: #2b1808 !important;
    color: #fdba74 !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-state.is-critical,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-state.is-critical {
    background: #351515 !important;
    color: #fca5a5 !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-state.is-finance,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-state.is-finance {
    background: #0f2418 !important;
    color: #86efac !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-state.is-task,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-state.is-task {
    background: #1f1637 !important;
    color: #c4b5fd !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-state.is-document,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-state.is-document {
    background: #182247 !important;
    color: #a5b4fc !important;
}

body[data-theme-mode="dark"] #pg-dashboard .ops-empty,
body.gsw-standalone[data-theme-mode="dark"] #pg-dashboard .ops-empty {
    border-color: var(--gsw-dark-border) !important;
    background: #000000 !important;
}

body[data-theme-mode="dark"] .gsw-switch-row,
body.gsw-standalone[data-theme-mode="dark"] .gsw-switch-row {
    border-color: var(--gsw-dark-border) !important;
    background: #000000 !important;
}

body[data-theme-mode="dark"] .gsw-switch-copy strong,
body.gsw-standalone[data-theme-mode="dark"] .gsw-switch-copy strong {
    color: #f8fafc !important;
}

body[data-theme-mode="dark"] .gsw-switch-copy small,
body.gsw-standalone[data-theme-mode="dark"] .gsw-switch-copy small {
    color: #94a3b8 !important;
}



