.theme-toggle{width:34px;height:34px;flex-shrink:0;display:inline-grid;place-items:center;border:1px solid #e5dfee;border-radius:50%;background:#f8f6fc;color:#6a587d;cursor:pointer;padding:7px}
.theme-toggle svg{width:19px;height:19px}.theme-toggle:hover{background:#eae3f4}.theme-toggle:focus-visible{outline:2px solid #9679b1;outline-offset:3px}.theme-sun{display:none}
html[data-theme=dark]{color-scheme:dark;--bg:#0e1219;--card:#171c26;--text:#e8ebf3;--muted:#a4aebe;--border:#303746;--blue:#62b1ff;--green:#36d9b5;--red:#f08b96;background:#0e1219;color:#e8ebf3}
html[data-theme=dark] body{background:#0e1219;color:#e8ebf3}
html[data-theme=dark] .theme-toggle{border-color:#35404f;background:#1b2230;color:#d9e3f1}html[data-theme=dark] .theme-toggle:hover{background:#2c3748}html[data-theme=dark] .theme-sun{display:block}html[data-theme=dark] .theme-moon{display:none}
html[data-theme=dark] :is(.global-header,.topbar,.editor-header){background:#10151eea;border-color:#2c3341;color:#dce2ed;backdrop-filter:blur(16px)}
html[data-theme=dark] .nota-brand{filter:invert(1);mix-blend-mode:screen}
html[data-theme=dark] :is(.global-nav,.global-nav a,.global-nav summary,.header-inner,.topbar-right,.profile-menu,.user-slot){color:#d9e3f1}
html[data-theme=dark] .global-nav [aria-current=page]{color:#4ae1bd;border-color:#4ae1bd}
html[data-theme=dark] :is(.menu-list,.research-menu nav,.notification-preview,.menu-popover){background:#1a202c;color:#dfe6f2;border-color:#303a4b;box-shadow:0 14px 40px #0005}
html[data-theme=dark] :is(.menu-list a,.research-menu nav a,.menu-list button){color:#dfe6f2}
html[data-theme=dark] :is(.login-entry,.avatar-toggle,.user-avatar,.small-badge){background:#202836;color:#c3d2e7;border-color:#364154}
html[data-theme=dark] :is(.home-module,.home-intro,.home-practice-copy,.usage-heading,.page-heading,.legal-document,.messages-main){color:#e8edf6}
html[data-theme=dark] :is(.home-title,.home-lead,.home-practice-copy h3,.usage-heading h1,.page-heading h1,.section-heading h2,.legal-document h1,.legal-document h2):not(:where(.home-hero *,.home-feature-card *,.home-practice-card *)){color:#eef2fa}
html[data-theme=dark] :is(.home-body,.home-caption,.home-eyebrow,.home-english,.usage-card-summary,.usage-dialog-intro,.usage-step p,.usage-followup p,.legal-document p,.legal-meta,.muted,.footer,.home-scroll-link):not(:where(.home-hero *,.home-feature-card *,.home-practice-card *)){color:#b7c3d6}
/* Media keeps its original palette, overlay and text contrast in both themes. */
html[data-theme=dark] :is(.home-hero,.home-feature-card,.home-practice-card){color:#141416}
html[data-theme=dark] .home-feature-dark{color:white}
html[data-theme=dark] .home-action{background:#253e44;border:1px solid #3e5f65;color:#e5fff6}html[data-theme=dark] .home-action:hover{background:#31605c}
html[data-theme=dark] :is(.card,.panel,.author-card,.monitor-panel,.push-toolbar,.auth-card,.usage-card,.usage-future,.usage-demo,.account-card,.feedback-card,.suggestion-card,.legal-document,.messages-list,.message-notice,.research-card,.research-entry,.research-panel,.research-post,.research-filter,.research-composer,.research-empty,.market-card,.market-comment,.author-directory,.notification-card){background:#171d28;color:#e0e6f0;border-color:#303a4b;box-shadow:none}
html[data-theme=dark] :is(.usage-card-title,.usage-step strong,.usage-followup h3,.usage-dialog h2,.usage-card-bottom){color:#d9e3f6}html[data-theme=dark] .usage-card:hover{background:#222b3c;border-color:#526279}
html[data-theme=dark] :is(dialog,.modal,.usage-dialog,.ai-dialog,.ai-table-dialog){background:#181f2b;color:#e8edf6;border-color:#384456;box-shadow:0 24px 90px #0008}html[data-theme=dark] dialog::backdrop{background:#02050bbc}
html[data-theme=dark] :is(input:not([type=checkbox]),textarea,select){background:#111722;color:#e4ebf6;border-color:#354154}html[data-theme=dark] :is(input,textarea)::placeholder{color:#8692a7}
html[data-theme=dark] :is(.secondary,.ai-subtle,.ai-icon,.close-button){background:#252e3d;color:#b9c7dc;border-color:#354154}
html[data-theme=dark] :is(.stock-chip,.author-row,.empty-icon,.empty-state,.monitor-symbol,.research-toolbar,.research-search,.research-year,.research-tabs,.research-comment,.research-attachment,.research-comment-compose,.source-box){background:#1d2635;color:#d4dfed;border-color:#344155}
html[data-theme=dark] table{color:#d5dfec}html[data-theme=dark] th{background:#242f40;color:#dde7f4;border-color:#3a4659}html[data-theme=dark] td{border-color:#303b4e}html[data-theme=dark] tbody tr:nth-child(even){background:#1b2433}
html[data-theme=dark] :is(.home-steps,.usage-step,.form-divider,.form-rule,.menu-rule,.section-rule){border-color:#333e50}html[data-theme=dark] .auth-screen{background:radial-gradient(ellipse at 50% 30%,#202b40,#0f141d 70%)}
html[data-theme=dark] :is(.site-editor,.editor-sidebar,.editor-panel,.editor-toolbar,.editor-actions,.editor-footer){background:#161d29;color:#d8e2f0;border-color:#344155}
@media(max-width:760px){.theme-toggle{width:31px;height:31px;padding:6px}}
.user-slot{width:196px;min-width:196px;justify-content:flex-end;gap:8px}
.user-slot .notification-slot{margin-right:0}
@media(max-width:760px){.user-slot{width:196px;min-width:196px;gap:8px}}
html[data-theme=dark] :is(.community-tools,.post-card,.compose-panel,.moderation-actions,.research-subnav){background:#171e2a;color:#dbe5f2;border-color:#303d50}
html[data-theme=dark] .community-page :is(.community-main,.compose-panel,.community-tools,.post-card){background:#151c27;color:#dce5f2;border-color:#303c4e}
html[data-theme=dark] .community-page .post-card :is(.content-text,.post-title,.topic-author .nickname){color:#dbe6f3}
html[data-theme=dark] .community-page .post-card .topic-author .nickname-admin{color:#fda956}
html[data-theme=dark] :is(.topic-body .content-text,.topic-body .post-title,.research-row,.commentary-panel p,.notification-item,.notification-line strong){color:#d1ddec}
html[data-theme=dark] :is(.market-card-value,.market-card>h3){color:#bcd5f7}
html[data-theme=dark] :is(.notification-item:hover,.notification-item:focus-visible){background:#263247}
html[data-theme=dark] :is(.notification-copy p,.notification-line span,.notification-line time,.legal-document section p,.legal-footer a){color:#abb8cc}
html[data-theme=dark] .market-card-value.hot{color:#ff8e89}html[data-theme=dark] .market-card-value.cold{color:#83b2ff}
html[data-theme=dark] .global-nav a[aria-current=page]::after{background:#4ae1bd}
/* Research follows the shared shell in both themes, including wide screens. */
html .research-main,html .community-page .community-main{max-width:1140px;padding-left:40px;padding-right:40px}
html .community-page .community-layout{grid-template-columns:minmax(0,1fr) 80px}
@media(min-width:1500px){html .research-main,html .community-page .community-main{max-width:1220px}}
@media(max-width:760px){html .research-main,html .community-page .community-main{padding-left:20px;padding-right:20px}html .community-page .community-layout{grid-template-columns:minmax(0,1fr)}}
html[data-theme=dark] .research-menu.current summary,html[data-theme=dark] .research-subnav a[aria-current]{color:#4ae1bd;border-color:#4ae1bd}
html[data-theme=dark] :is(.research-subnav a,.research-meta,.research-note,.heatmap-footnote,.market-card-label,.market-card-note,.market-card-source,.community-time,.community-time button,.topic-author time,.discussion-author time,.topic-actions button,.topic-actions a,.compose-trigger,.compose-toolbar button,.attachment-picker>span,.attachment-picker>label){color:#b7c3d6}
html[data-theme=dark] :is(.research-menu>nav a:hover,.menu-list a:hover,.menu-list button:hover){background:#293448;color:#eef2fa}
html[data-theme=dark] .community-page .topic-actions :is(button,a),html[data-theme=dark] .community-page .topic-author time{color:#b7c3d6}
html[data-theme=dark] .community-page .community-tools button[aria-pressed=true]{color:#4ae1bd}
html[data-theme=dark] .research-main :is(#reply-form,.composer-writing){background:#171d28;color:#e4ebf6}
html[data-theme=dark] .research-main :is(#reply-body,#post-body){background:#111722;color:#e4ebf6;border:1px solid #354154;font-family:inherit;border-radius:8px;padding:10px 12px}
html[data-theme=dark] .research-main textarea::placeholder{color:#a8b6cc}
html[data-theme=dark] :is(.market-card-row,.discussion-row,.composer-bottom){border-color:#354154}
html[data-theme=dark] :is(.market-card-row p,.market-card-line+.research-meta,.research-back,.topic-expand,.topic-content .topic-expand,.content-detail .topic-author .nickname){color:#b7c3d6}
html[data-theme=dark] .content-detail :is(.content-text,.post-title){color:#dbe6f3}
html[data-theme=dark] .community-page .community-tools [data-stance]{background:#263247;color:#d9e3f1}
html[data-theme=dark] .community-page .community-tools [aria-pressed=true]{background:#304456;color:#4ae1bd}
html[data-theme=dark] .community-page .community-time button{color:#b7c3d6}
html[data-theme=dark] .community-page .community-time button[aria-pressed=true]{background:#304456;color:#4ae1bd}

/* Pair text, borders and surfaces; never recolor original images or video. */
html[data-theme=light]{color-scheme:light;--theme-surface:#fff;--theme-inset:#f2f6fc;--theme-line:#dce3ef;--theme-ink:#27364d;--theme-muted:#5c6b80;--theme-link:#355b99;--theme-profit:#c72c4c;--theme-avatar:#edf3fc;--theme-avatar-ink:#415f86;--muted:#5c6b80}
html[data-theme=dark]{--panel:#171d28;--theme-surface:#171d28;--theme-inset:#1d2a3c;--theme-line:#35445b;--theme-ink:#dce8f8;--theme-muted:#b7c3d6;--theme-link:#9bcaff;--theme-profit:#ff6c87;--theme-avatar:#26364a;--theme-avatar-ink:#d1e4ff}
html[data-theme] :is(.access-notice,.notice-box,.feedback-notice,.comment-reply-target){background:var(--theme-inset);color:var(--theme-ink);border-color:var(--theme-line)}
html[data-theme] .messages-panel{background:var(--theme-surface);color:var(--theme-ink);border-color:var(--theme-line)}
html[data-theme] .messages-panel-heading{background:var(--theme-inset);color:var(--theme-ink);border-color:var(--theme-line)}
html[data-theme] :is(.access-notice p,.notice-box p,.notification-note,.messages-heading p,.messages-heading>span,.messages-back,.comment-reply-context){color:var(--theme-muted)}
html[data-theme] :is(.feedback-notice,.notification-note a,.comment-reply-target button){color:var(--theme-link)}
html[data-theme] .author-directory :is(thead th,tbody th){color:var(--theme-ink)}
html[data-theme] .author-directory :is(th,td){border-color:var(--theme-line)}
html[data-theme] .author-directory thead th{background:var(--theme-inset)}
html[data-theme] .author-directory .author-stat-navy{color:var(--theme-ink)}
html[data-theme] .author-directory .author-stat-pink{color:var(--theme-profit)}
html[data-theme] .author-directory .author-stat-time{color:var(--theme-muted)}
html[data-theme] .author-avatar{background:var(--theme-avatar);color:var(--theme-avatar-ink)}
html[data-theme] :is(.community-page .post-card,.topic-author,.composer-writing) .discussion-initial{background:var(--theme-avatar);color:var(--theme-avatar-ink)}
html[data-theme=light] :is(.field-hint,.entry-note,.baseline-note,.feedback-count,.feedback-footnote,.author-directory-heading h2 span,.author-directory-heading>.muted,.back-link,.legal-meta,.legal-footer a,.pro-service-note,.site-footer a,.site-footer span){color:var(--theme-muted)}
html[data-theme=light] .global-nav>a:not([aria-current]),html[data-theme=light] .research-menu:not(.current)>summary{color:#626d80}
html[data-theme=light] .feedback-heading .muted{color:var(--theme-muted)}
html[data-theme] .profile-card #profile-fields{border:0;padding:0;margin:0;min-width:0}
html[data-theme=light] :is(input:not([type=checkbox]),textarea,select,dialog,.modal){border-color:var(--theme-line)}
html[data-theme=light] :is(input:not([type=checkbox]),select):focus-visible{outline:2px solid #9b86bd;outline-offset:2px}
html[data-theme=light] .ai-page :is(.ai-layout,.ai-composer,.ai-table-block,.ai-table-dialog,.ai-dialog,.ai-row-actions,.ai-add-menu){border-color:var(--theme-line)}
html[data-theme] .ai-page :is(.ai-access-note,.ai-status,.ai-disclaimer,.ai-modal-description){color:var(--theme-muted)}
html[data-theme] .ai-page .ai-access-note a{color:var(--theme-link)}
html[data-theme=dark] .primary{background:#2365a5;color:#fff;border-color:#427bb3}
html[data-theme=dark] .primary:hover:not(:disabled){background:#2b74ba}
html[data-theme=dark] .research-main .topic-composer .composer-publish .primary{background:#14775f;border-color:#287e69;color:#fff}
html[data-theme=dark] :is(.notification-item.is-unread,.discussion-row.notification-focus){background:#1d2a3c;color:var(--theme-ink);border-color:var(--theme-line)}
html[data-theme=dark] .notification-item{border-color:var(--theme-line)}
html[data-theme=dark] .notification-item:hover,html[data-theme=dark] .notification-item:focus-visible{background:#263247}
html[data-theme=dark] .error-panel{background:#34222b;color:#ffd6dc;border-color:#633849}
html[data-theme=dark] .ai-page :is(.ai-message-content pre,.ai-message-content code){background:#202c3d;color:#d8e4f3;border-color:var(--theme-line)}
html[data-theme=dark] .ai-page .ai-message-content pre code{background:transparent}
html[data-theme=dark] .ai-page :is(.ai-template-card,.ai-template-add,.ai-file-card){background:var(--ai-card);color:var(--ai-text);border-color:var(--ai-line)}
/* The original read-only field declares an important light background. */
html[data-theme=dark] .phone-display input{background:#111722!important;color:#e4ebf6}
html[data-theme=dark] .compact-button{background:#26364a;color:var(--theme-link)}
html[data-theme=light] .compact-button{color:var(--theme-link)}
html[data-theme=dark] .compact-button:hover{background:#31465f}
html[data-theme=dark] :is(.legal-footer,.ai-page .ai-message-content th){border-color:var(--theme-line)}
html[data-theme] .ai-page :is(.ai-copy,.ai-table-toolbar button,.ai-prompts .ai-template-use){color:var(--theme-muted)}
/* Community actions follow both palettes, including hovered moderation items. */
html[data-theme] .moderation-actions{background:var(--theme-surface);color:var(--theme-ink);border-color:var(--theme-line)}
html[data-theme] .moderation-actions button{color:var(--theme-ink)}
html[data-theme] .moderation-actions button:hover,html[data-theme] .moderation-actions button:focus-visible{background:var(--theme-inset)}
html[data-theme=light] .moderation-actions .danger{color:#b83a42}
html[data-theme=dark] .moderation-actions .danger{color:#ffaaa6}
html[data-theme] .community-page .post-card :is(.topic-detail-link,.topic-author time,.topic-expand){color:var(--theme-muted)}
html[data-theme] .community-page .compose-trigger{background:var(--theme-inset);color:var(--theme-muted)}
html[data-theme] #topic-edit-dialog{width:640px;max-width:calc(100vw - 32px)}
#topic-edit-dialog textarea{width:100%;resize:vertical;max-height:50dvh;font-family:inherit;line-height:1.8}
html[data-theme] .ai-page .ai-table-dialog-heading{background:var(--theme-inset);color:var(--theme-ink);border-color:var(--theme-line)}
html[data-theme=dark] .ai-page .ai-table-toolbar button:hover{background:#26364a;color:#eef4ff}
html[data-theme=dark] .ai-page .ai-template-card:hover{background:var(--ai-hover);border-color:var(--ai-line)}
html[data-theme=dark] .notification-link{color:#b7c3d6}
html[data-theme=dark] .notification-link:hover,html[data-theme=dark] .notification-link:focus-visible{background:#263247;color:#eef4ff}
