/* Light is the default; explicit dark preferences and original artwork are preserved. */
:root{color-scheme:light}:root[data-theme=dark]{color-scheme:dark}
.theme-toggle{position:relative;display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;min-width:36px;padding:0;border:1px solid transparent;border-radius:9px;background:transparent;color:var(--muted,#8a8a95);cursor:pointer;flex-shrink:0;transition:color .18s,background-color .18s,border-color .18s}
.theme-toggle:hover{color:var(--accent,#b3adea);background:var(--accent-wash,#6f61cc19);border-color:var(--accent-edge,#6f61cc33)}
.theme-toggle:focus-visible{outline:2px solid var(--violet,#6f61cc);outline-offset:3px}
.theme-toggle svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.theme-toggle .theme-moon{display:none}
.theme-toggle-mobile{display:none}
.theme-toggle-legacy{margin-left:auto;color:var(--muted,#8a8a95)}
.theme-changing .theme-toggle svg{animation:theme-icon-in .2s ease-out}
@keyframes theme-icon-in{from{transform:rotate(-35deg) scale(.75);opacity:.4}to{transform:none;opacity:1}}
:root[data-theme=light]{color-scheme:light;--bg:#f5f5fa;--surface:#ffffff;--surface-hi:#efeff7;--line:#dfdfeb;--text:#252435;--muted:#6b687e;--secondary:#565267;--faint:#777286;--accent:#6552b5;--violet:#6f61cc;--blue:#6552b5;--green:#168255;--gold:#99732b;--accent-wash:#eeebfa;--accent-edge:#d2c9ee;--accent-hover:#5e4ead;--theme-shadow:0 14px 42px #3e315017;--theme-edge:#dfdfeb}
:root[data-theme=light] .theme-toggle .theme-sun{display:none}
:root[data-theme=light] .theme-toggle .theme-moon{display:block}
:root[data-theme=light] body{background:var(--bg)!important;color:var(--text)!important}
:root[data-theme=light] .space-grain{background:radial-gradient(ellipse at 47% -15%,#e9e3fb88,transparent 55%)!important}
:root[data-theme=light] :is(.topbar,.rail,.main-nav,.chat-dock){background:#ffffffed!important;border-color:var(--line)!important;color:var(--text)!important}
:root[data-theme=light] :is(.topbar,.rail){box-shadow:0 2px 20px #50416e05!important}
:root[data-theme=light] :is(.rail-brand,.rail-social,.rail-locale,.restore-chat){background-color:var(--surface)!important;border-color:var(--line)!important;color:var(--secondary)!important}
:root[data-theme=light] :is(.rail-divider,.wordmark-line){background:var(--line)!important}
:root[data-theme=light] .rail-item{color:var(--muted)!important}
:root[data-theme=light] .rail-item:is(:hover,.is-active){background:var(--accent-wash)!important;color:var(--accent)!important;box-shadow:none!important}
:root[data-theme=light] .quick-rail .rail-item.is-active .rail-icon{background:var(--accent-edge)!important;color:var(--accent)!important;border-color:#bdb0e5!important;box-shadow:inset 0 1px 0 #ffffff9c!important}
:root[data-theme=light] .quick-rail .rail-item:hover .rail-icon{color:var(--accent)!important}
:root[data-theme=light] :is(.top-online b,.rail-presence-number b,.wordmark b){color:var(--text)!important}
:root[data-theme=light] :is(.account-popover,.mega-menu,.emoji-popover,.chat-members-popover,.chat-sound-popover,.locale-popover,.smart-search-dialog,.modal,.modal-content,.shop-preview-sheet,.cab-dialog,.forum-editor-modal,.site-reaction-dialog){background-color:var(--surface)!important;color:var(--text)!important;border-color:var(--theme-edge)!important;box-shadow:var(--theme-shadow)!important}
:root[data-theme=light] :is(.modal,.smart-search-dialog,.shop-preview-sheet,.cab-dialog,.forum-editor-modal,.site-reaction-dialog)::backdrop{background:#30284060!important;backdrop-filter:blur(5px)}
:root[data-theme=light] :is(.menu-backdrop,.modal-backdrop){background:#30284060!important}
:root[data-theme=light] :is(.account-pop-head,.account-popover .logout,.chat-header,.chat-input-area,.chat-members-head,.emoji-head,.locale-head){border-color:var(--line)!important}
:root[data-theme=light] :is(.account-popover a,.account-popover button,.mega-menu a,.mega-menu button,.chat-member-row,.chat-heading,.chat-title b,.chat-person,.chat-person>b,.chat-text,.chat-message-content){color:var(--text)!important}
:root[data-theme=light] :is(.account-popover a,.account-popover button,.mega-menu a,.mega-menu button,.chat-member-row):hover{background:var(--accent-wash)!important;color:var(--accent)!important}
:root[data-theme=light] :is(.home-panel,.panel,.server-hub,.server-list,.server-mascot,.server-hub-footer,.stat,.poll-card,.rank-feature,.rank-line,.home-v9 .community-grid .home-panel){background-color:var(--surface)!important;border-color:var(--line)!important;color:var(--text)!important}
:root[data-theme=light] :is(.server-row,.hub-stat,.panel-head,.section-heading,.discussion-row,.timeline-row,.rank-line,.poll-card footer,.footer,.footer-inner){border-color:var(--line)!important}
:root[data-theme=light] :is(.server-row h3,.section-heading h1,.section-heading h2,.panel-head h2,.panel-head h3,.home-panel h2,.home-panel h3,.poll-question,.hub-stat b,.stat b,.stat strong,.server-name){color:var(--text)!important}
:root[data-theme=light] :is(.server-map,.panel-subtitle,.footer,.footer-note,.hub-stat small,.quiet-label,.eyebrow){color:var(--muted)!important}
:root[data-theme=light] :is(.occupancy-track,.poll-track,.poll-bar,.poll-option-track){background:#e9e6f1!important}
:root[data-theme=light] :is(.poll-option,.poll-choice,.rank-line):hover{background:var(--accent-wash)!important}
:root[data-theme=light] :is(.chat-header,.chat-input-area,.chat-sound-popover,.chat-members-popover,.chat-sound-popover button){background-color:var(--surface)!important;color:var(--text)!important}
:root[data-theme=light] :is(.chat-message):hover{background:#6f61cc05!important}
:root[data-theme=light] :is(.chat-text,.chat-message-content){color:var(--text)!important}
:root[data-theme=light] :is(.chat-time,.chat-date,.chat-message time,.chat-online-label,.chat-char-count){color:var(--muted)!important}
:root[data-theme=light] :is(.reply-preview,.chat-reply,.chat-unread,.chat-pin,.chat-login){background:var(--accent-wash)!important;color:var(--accent)!important;border-color:var(--accent-edge)!important}
:root[data-theme=light] :is(#chat-form,.chat-form,.chat-form-wrap,.chat-input-wrap,.composer){background-color:var(--surface-hi)!important;border-color:var(--line)!important}
:root[data-theme=light] :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]):not([type=submit]),textarea,select){background-color:var(--surface-hi)!important;color:var(--text)!important;border-color:var(--line)!important;caret-color:var(--accent)}
:root[data-theme=light] :is(input,textarea)::placeholder{color:#777286!important;opacity:1}
:root[data-theme=light] select option{background-color:var(--surface)!important;color:var(--text)!important}
:root[data-theme=light] :is(input,textarea,select):focus-visible{outline:2px solid #8171d14d;outline-offset:2px}
:root[data-theme=light] :is(.public-auth h2,.public-auth label,.public-auth-links button,.public-auth-links a){color:var(--text)!important}
:root[data-theme=light] .public-auth p{color:var(--muted)!important}
:root[data-theme=light] .public-form-error.is-success{color:#137549!important}
:root[data-theme=light] :is(.text-danger,.public-form-error:not(.is-success)){color:#b63d53!important}
:root[data-theme=light] :is(.button.ghost,.button.secondary,.icon-button,.top-sign-in,.chat-header-actions button,.shop-account-links a){border-color:var(--line)!important;color:var(--secondary)!important;background:var(--surface-hi)!important}
:root[data-theme=light] .theme-toggle{background:transparent!important;border-color:transparent!important}
:root[data-theme=light] .theme-toggle:hover{background:var(--accent-wash)!important;border-color:var(--accent-edge)!important;color:var(--accent)!important}
:root[data-theme=light] :is(.button.ghost,.button.secondary,.icon-button,.top-sign-in):hover{background:var(--accent-wash)!important;border-color:var(--accent-edge)!important;color:var(--accent)!important}
:root[data-theme=light] :is(.rules-section,.rules-card,.rules-item,.rules-intro,.rules-navigation,.rules-sidebar,.rules-toolbar,.rules-reader-tools,.rules-reader-card,.rules-section-list){background-color:var(--surface)!important;border-color:var(--line)!important;color:var(--text)!important}
/* Match the reader's ID specificity, including its important dark gradients. */
:root[data-theme=light] #rules-view .rules-rich-text .rules-topic-penalty{--callout-text:#843d50;background:#fff1f3!important;border-color:#d58b9e!important;color:var(--callout-text)!important}
:root[data-theme=light] #rules-view .rules-rich-text .rules-topic-exception{--callout-text:#765c20;background:#fff8e8!important;border-color:#c4a256!important;color:var(--callout-text)!important}
:root[data-theme=light] #rules-view .rules-rich-text .rules-topic-example{--callout-text:#315c85;background:#edf5fd!important;border-color:#81a8ce!important;color:var(--callout-text)!important}
:root[data-theme=light] #rules-view .rules-rich-text :is(.rules-topic-condition,.rules-topic-note){--callout-text:#584486;background:var(--accent-wash)!important;border-color:#afa0d5!important;color:var(--callout-text)!important}
:root[data-theme=light] #rules-view .rules-rich-text :is(.rules-topic-penalty,.rules-topic-exception,.rules-topic-example,.rules-topic-condition,.rules-topic-note) :is(p,span,div,strong,b,font){color:var(--callout-text)!important}
:root[data-theme=light] #rules-view .rules-rich-text blockquote .rules-chain-arrow{color:var(--accent)!important}
:root[data-theme=light] :is(.shop-page,.stats-page,.clans-page,.forum-space){color:var(--text)!important}
:root[data-theme=light] :is(.shop-product,.shop-product-card,.shop-categories a,.shop-category,.shop-toolbar,.shop-collection,.shop-server-menu,.shop-order,.shop-checkout,.shop-preview-details,.shop-preview-info,.stats-card,.stats-summary-card,.stats-table-wrap,.stats-filter-panel,.stats-player-detail,.clan-card,.clan-panel,.clans-table-wrap,.clan-detail-panel,.forum-board,.forum-section,.forum-topic-card,.forum-message,.forum-composer,.forum-editor-modal){background-color:var(--surface)!important;border-color:var(--line)!important;color:var(--text)!important}
:root[data-theme=light] :is(.shop-page,.stats-page,.clans-page,.forum-space) :is(table,thead,tbody,tr,td,th){border-color:var(--line)!important}
:root[data-theme=light] :is(.shop-page,.stats-page,.clans-page) :is(h1,h2,h3,label){color:var(--text)!important}
:root[data-theme=light] :is(.shop-page,.stats-page,.clans-page) :is(.is-selected,.is-active,[aria-selected=true]){border-color:var(--accent-edge)!important}
:root[data-theme=light] :is(.forum-toolbar,.forum-search,.forum-breadcrumbs,.forum-post-toolbar,.forum-editor-toolbar,.forum-spoiler,.spoiler-content,.forum-code-block,.site-color-picker){background-color:var(--surface-hi)!important;border-color:var(--line)!important;color:var(--text)!important}
:root[data-theme=light] :is(.forum-editor,.forum-editor-body,.forum-message-content){color:var(--text)!important}
:root[data-theme=light] :is(.forum-editor,.forum-editor-body,.tox .tox-edit-area__iframe){background-color:var(--surface)!important}
:root[data-theme=light] .cabinet{--cab-panel:#fff;--cab-raised:#efeff7;--cab-edge:#dfdfeb;--cab-muted:#6b687e;--cab-accent:#6552b5;color:var(--text)!important}
:root[data-theme=light] :is(.cab-stat-grid,.cab-sidebar nav>a,.cab-slot,.cab-choice,.cab-search-results,.cab-search>label,.cab-dialog){background-color:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important}
:root[data-theme=light] .cab-identity{background:linear-gradient(120deg,#eeebfa,#fff 75%)!important;color:var(--text)!important;border-color:var(--accent-edge)!important}
:root[data-theme=light] :is(.cab-field label,.cab-heading h1,.cab-heading h2,.cab-card h2,.cab-stat-grid strong,.cab-stat-grid b){color:var(--text)!important}
:root[data-theme=light] .mini-profile{--mp-text:#252435;--mp-muted:#6b687e;--mp-accent:#6552b5;background:transparent!important}
:root[data-theme=light] .mini-profile-body{background-color:var(--surface)!important;border-color:var(--line)!important;box-shadow:var(--theme-shadow)!important}
:root[data-theme=light] .mini-profile-avatar{box-shadow:0 0 0 5px var(--surface),0 5px 16px #3e315015!important}
:root[data-theme=light] :is(.mini-profile-age,.mini-profile-metric){border-color:var(--line)!important}
:root[data-theme=light] .mini-profile-metric{background:var(--surface-hi)!important}
:root[data-theme=light] .mini-profile-presence{background-color:var(--surface-hi)!important;color:var(--muted)!important;border-color:var(--line)!important}
:root[data-theme=light] .mini-profile-presence.is-online{background:#e9f5ef!important;color:#137549!important;border-color:#c7e6d4!important}
:root[data-theme=light] :is(.detail-tooltip,.public-tooltip,.ui-tooltip){background:#302b43!important;color:#fff!important;border-color:#64558433!important;box-shadow:0 4px 18px #30284022!important}
/* Legacy public pages share the selected palette when opened from the new shell. */
:root[data-theme=light] :is(.wapper,.wapper>.content,.newprofile-page){background-color:var(--bg)!important;color:var(--text)!important}
:root[data-theme=light] :is(.wapper .block,.wapper .shopscontainer,.wapper .card,.wapper .modal-content,.wapper .dropdown-menu,.wapper .tab-content,.wapper .mobile-menu-bottom){background-color:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important}
:root[data-theme=light] :is(.wapper .header,.wapper .header_content,.wapper .table,.wapper .table td,.wapper .table th){background-color:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important}
:root[data-theme=light] :is(.project-pulse,.project-pulse>span,.store-category){background-color:var(--surface)!important;border-color:var(--line)!important}
:root[data-theme=light] .store-category::after{background:none!important}
:root[data-theme=light] .store-category:hover{background-color:var(--accent-wash)!important;border-color:var(--accent-edge)!important}
:root[data-theme=light] :is(.store-category .category-copy strong,.store-category .category-copy b,.store-category .category-arrow){color:var(--text)!important}
:root[data-theme=light] :is(.store-category .category-copy small,.store-category .category-tag,.project-pulse>span>small,.server-occupancy small,.section-caption,.section-presence,.rail-item span,.rail-locale span,.footer-links a){color:var(--muted)!important}
:root[data-theme=light] :is(.project-pulse b,.server-description .server-name,.giveaway-copy h3 button,.poll-widget h3 button,.poll-result-label>span){color:var(--text)!important}
:root[data-theme=light] :is(.poll-card,.poll-widget) h3 button{color:var(--text)!important}
:root[data-theme=light] .rank-switch button{color:var(--muted)!important}
:root[data-theme=light] .rank-switch button:is(.is-active,[aria-selected=true]){background-color:var(--violet)!important;color:#fff!important}
:root[data-theme=light] :is(.mascot-label,.footer-brand){color:var(--text)!important;text-shadow:none}
:root[data-theme=light] :is(.mascot-label,.footer-brand,.rail-brand) img{filter:brightness(.22)}
:root[data-theme=light] .rank-feature.has-profile-cover{--text:#fff;--muted:#d9d5e6;--secondary:#e7e2f0;color:#fff!important}
:root[data-theme=light] .home-poll h3 button{color:var(--text)!important}
:root[data-theme=light] .project-pulse em{color:var(--green)!important}
:root[data-theme=light] .category-tag{background-color:var(--accent-wash)!important;color:var(--accent)!important;border-color:var(--accent-edge)!important}
:root[data-theme=light] .stats-picker-trigger{background:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important}
:root[data-theme=light] .stats-leader:has(.stats-profile-cover){--text:#fff;--muted:#d9d5e6;--secondary:#e7e2f0;--accent:#c3b5ff;color:#fff!important}
:root[data-theme=light] .stats-periods button[aria-pressed=true]{background:var(--violet)!important;color:#fff!important}
:root[data-theme=light] .cab-sidebar nav>a[aria-current=page]{background:var(--accent-wash)!important;color:var(--accent)!important}
:root[data-theme=light] :is(.cab-search input,.cab-search-results>button,.cab-switch-row b,.cab-select-row b,.cab-secondary){color:var(--text)!important}
:root[data-theme=light] .cab-choice>button[aria-checked=true]{background:var(--accent-wash)!important;color:var(--accent)!important}
:root[data-theme=light] .cab-quick-grid>a{background:linear-gradient(135deg,#eeebfa,#fff)!important;border-color:var(--line)!important;color:var(--text)!important}
:root[data-theme=light] .cab-identity:has(.cab-cover){--text:#fff;--secondary:#eee9f5;--muted:#ded8ea;--cab-muted:#ded8ea;--cab-accent:#d8cbff;color:#fff!important}
:root[data-theme=light] .cab-quick-grid>a:hover{background:var(--accent-wash)!important}
/* Nickname artwork and role gradients keep their original colors. */
:root[data-theme=light] #rules-view :is(.rules-content-description.is-notice,.rules-penalty>span){color:var(--accent)!important}
:root[data-theme=light] :is(.rules-rich-text,.forum-message-content) :is([style*="#f4f4f6"],[style*="#eeeeee"],[style*="#ffffff"],[color="#ffffff"],[color="#FFFFFF"]){color:var(--text)!important}
/* Secondary cards must use the same palette as the first screen. */
:root[data-theme=light] :is(.home-update,.news-lead,.news-item,.home-product){background:var(--surface)!important;border-color:var(--line)!important}
:root[data-theme=light] :is(.home-update,.news-lead,.news-item,.home-product):hover{background:var(--surface)!important;border-color:var(--accent-edge)!important;box-shadow:0 5px 20px #4e3a7810!important}
:root[data-theme=light] :is(.news-lead-copy>strong,.news-item-copy>strong,.mega-group b,.mega-group h3){color:var(--text)!important}
:root[data-theme=light] :is(.news-summary,.news-lead-copy>span){color:var(--secondary)!important}
:root[data-theme=light] :is(.home-update-meta,.news-item time,.news-lead time){color:var(--muted)!important}
:root[data-theme=light] :is(.home-update-art,.news-lead-image,.news-item-image){background-color:var(--surface-hi)!important}
:root[data-theme=light] .news-item-meta>span{background:var(--accent-wash)!important;color:var(--accent)!important}
:root[data-theme=light] :is(.server-connect:disabled,.is-quiet .server-connect){background:var(--surface-hi)!important;color:var(--secondary)!important;border-color:var(--line)!important;box-shadow:none!important}
:root[data-theme=light] .is-quiet .server-connect:is(:hover,:focus-visible){background:var(--accent-wash)!important;color:var(--accent)!important;border-color:var(--accent-edge)!important}
:root[data-theme=light] ::selection{background:#d9d0f4;color:#302448}
:root[data-theme=light] :is(input[type=checkbox],input[type=radio],input[type=range]){accent-color:var(--violet)}
:root[data-theme=light] :is(.chat-sound-popover [aria-checked=true]>i,.cab-switch input:checked+span)::after{background:#fff!important}
/* A purchased nameplate is dark artwork; its labels need their own contrast. */
:root[data-theme=light] :is(.site-message-plate .chat-person,.forum-message-header.site-message-plate){--text:#f4f4f6;--secondary:#e0dbe9;--muted:#d6cedf;--accent:#c9bcff;color:var(--text)!important}
:root[data-theme=light] :is(.site-message-plate .chat-person,.forum-message-header.site-message-plate) .member-name{filter:none!important;text-shadow:0 1px 3px #000b}
:root[data-theme=light] .site-message-plate .chat-person :is(time,.chat-time){color:var(--muted)!important;text-shadow:0 1px 2px #000a}
/* Profile neutrals are independent of a member's selected accent and cover. */
:root[data-theme=light] :is(.np,.np_gate,.np_modal,.np_player){--np-bg:#f5f5fa!important;--np-deep:#efeff7!important;--np-deep-rgb:239,239,247!important;--np-surface:#fff!important;--np-surface2:#f2f1f8!important;--np-surface3:#e9e6f3!important;--np-line:#dfdfeb!important;--np-line-soft:#e8e5f0!important;--np-text:#252435!important;--np-muted:#6b687e!important;--np-dim:#777286!important;--np-on-accent:#fff!important;--np-live:#168255!important;--np-gold:#99732b!important;--np-danger:#b63d53!important;--np-blue:#386ea5!important;--np-shadow:0 8px 25px #3e315012!important;--np-glass-bg:#ffffffed!important;--np-glass-bg2:#f2f1f8ed!important;color:var(--np-text)!important}
:root[data-theme=light] :is(.np_gate,.np_modal){background:#f5f5faed!important;color:var(--text)!important}
:root[data-theme=light] :is(.np .np_hint,.np .np_socrow,.np .empty-element,.np .date){background:var(--surface-hi)!important;color:var(--secondary)!important;border-color:var(--line)!important}
:root[data-theme=light] .np :is(.np_more_btn,.np_btn_ghost){background:var(--surface)!important;color:var(--secondary)!important;border-color:var(--line)!important}
:root[data-theme=light] .np .np_hero_main{color:var(--text)!important}
:root[data-theme=light] .np .np_hero_main :is(.np_status,.np_bio){color:var(--secondary)!important}
:root[data-theme=light] .np .np_btn_live{color:var(--np-live)!important}
:root[data-theme=light] .np :is(.np_acc,.np_srv_time){color:color-mix(in srgb,var(--np-accent) 65%,#252435)!important}
:root[data-theme=light] .np .np_hero_main .np_btn_main{color:#fff!important}
:root[data-theme=light] .np .np_tabbar button[aria-selected=true]{color:#fff!important}
:root[data-theme=light] .np :is(.np_btn_main,.np_tabbar button[aria-selected=true]){background:var(--violet)!important;border-color:var(--violet)!important}
:root[data-theme=light] .np :is(.np_k,.np_tabbar button:not([aria-selected=true])){color:var(--muted)!important}
:root[data-theme=light] .np :is(.np_tabbar button[aria-selected=true] .np_n){background:#ffffff26!important;color:#fff!important}
:root[data-theme=light] :is(.gcms_reaction_btn,.gcms_reaction_btn.has_count){background:var(--surface-hi)!important;color:var(--secondary)!important;border-color:var(--line)!important}
:root[data-theme=light] .gcms_reaction_btn:is(:hover,.active){background:var(--accent-wash)!important;border-color:var(--accent-edge)!important;color:var(--accent)!important}
:root[data-theme=light] .gcms_reaction_tip{background:#302b43!important;color:#fff!important}
:root[data-theme=light] .header_tabs .collapsible-menu a{background:var(--surface-hi)!important;color:var(--secondary)!important;border-color:var(--line)!important}
:root[data-theme=light] .header_tabs .collapsible-menu a:hover{background:var(--accent-wash)!important;color:var(--accent)!important}
:root[data-theme=light] .header_tabs .collapsible-menu>li>ul{background:var(--surface)!important;border-color:var(--line)!important;box-shadow:var(--theme-shadow)!important}
:root[data-theme=light] :is(.footer_navs,.footer_links,.footer .bottom_line){background:var(--surface)!important;color:var(--secondary)!important;border-color:var(--line)!important}
:root[data-theme=light] .footer_navs :is(a,span,p){color:var(--secondary)!important}
:root[data-theme=light] :is(.forum-image-viewer,.fe-popover,.site-color-picker){background:var(--surface)!important;border-color:var(--line)!important;color:var(--text)!important;box-shadow:var(--theme-shadow)!important}
:root[data-theme=light] .forum-image-viewer::backdrop{background:#302840a6!important}
:root[data-theme=light] :is(.fe-select,.fe-status,.fe-file-drop,.fe-color-grid button,.fe-color-recent button,.fe-color-saved button){background:var(--surface-hi)!important;color:var(--secondary)!important;border-color:var(--line)!important}
:root[data-theme=light] .fe-file-drop{background-image:none!important}
:root[data-theme=light] :is(.forum-editor-modal,.fe-popover) :is(h2,h3,label,button){color:var(--text)}
:root[data-theme=light] :is(.forum-editor-modal,.fe-popover) .forum-primary{color:#fff!important}
@media(max-width:760px){
 .theme-toggle-desktop{display:none}
 .topbar .theme-toggle-mobile{display:inline-flex;position:absolute;left:0;top:0;z-index:2;width:32px;min-width:32px;height:36px}
 .topbar-inner:has(.notification-button:not([hidden])) .theme-toggle-mobile{left:40px}
}
@media(prefers-reduced-motion:reduce){.theme-toggle{transition:none}.theme-changing .theme-toggle svg{animation:none}}
