/* Color-only layer, deliberately loaded after all light/mobile styles.
   Important palette declarations override the light-only inline monthly/tweak
   variables on these two owners. Removing the class restores them unchanged. */
.cpsa-color-toggle { display:inline-flex; align-items:center; justify-content:center; min-height:44px; padding:8px 12px; border:1px solid var(--ink); border-radius:999px; background:var(--paper-2); color:var(--ink); font:700 12px/1.4 var(--font-body); cursor:pointer; white-space:nowrap; }
.cpsa-color-toggle:focus-visible { outline:3px solid currentColor; outline-offset:3px; }
html.dark-mobile, html.dark-mobile .phone-stage {
  --paper:#101b18!important; --paper-2:#1b2b25!important; --paper-3:#23372f!important;
  --ink:#f0f5ed!important; --ink-soft:#c1d0c5!important; --ink-faint:#adbdaf!important;
  --rule:#688274!important; --rule-strong:#8ba594!important;
  --hot:#f3bd94!important;
  --brand-ink:#f0f5ed; --shadow:0 4px 0 #0005;
}
/* Gold stays seasonal; hot accents retain their hue with enough lightness for dark surfaces. */
html.dark-mobile body, html.dark-mobile .phone-stage { background:var(--paper); color:var(--ink); }
html.dark-mobile .cpsa-refined-home { --home-cream:var(--paper-2); }
html.dark-mobile .cpsa-home-hero h1 { color:#a7dfba; }
html.dark-mobile :is(.cpsa-site-header,.cpsa-site-footer,.app-header,.tabbar) { background:var(--paper); color:var(--ink); border-color:var(--rule); }
html.dark-mobile :is(.cpsa-protection-paths > a,.cpsa-home-article,.cpsa-home-article-bottom,.cpsa-footer-note) { border-color:var(--rule); }
html.dark-mobile :is(.cpsa-protect-icon,.cpsa-article-kicker), html.dark-mobile .cpsa-article-steps li p::first-letter { color:#a7dfba; }
html.dark-mobile :is(.cpsa-home-category,.cpsa-home-read) { background:#304b3b; color:var(--ink); }
html.dark-mobile :is(.cpsa-home-credit,.cpsa-news-summary,.cpsa-discovery-heading p,.cpsa-discovery-category,.cpsa-discovery-footer p) { color:var(--ink-soft); }
html.dark-mobile :is(.cpsa-news-spotlight,.cpsa-discovery,.cpsa-discovery-card,.cpsa-discovery-window,.cpsa-article-takeaway,.cpsa-article-steps li,.cpsa-article-prompt,.cpsa-play-feature,.cpsa-play-card,.cpsa-play-move,.cpsa-playbook-home,.cpsa-play-filters a) { background:var(--paper-2); color:var(--ink); border-color:var(--rule); box-shadow:none; }
html.dark-mobile :is(.cpsa-news-label,.cpsa-discovery-heading h2,.cpsa-discovery-card h3,.cpsa-discovery-footer a,.cpsa-article-takeaway p) { color:var(--ink); }
html.dark-mobile .cpsa-news-kicker { color:#f3c97c; }
html.dark-mobile .cpsa-news-icon { border-color:#f3c97c; }
html.dark-mobile .cpsa-news-icon::before { background:#f3c97c; }
html.dark-mobile .cpsa-news-icon::after { background:#f3c97c; box-shadow:0 4px 0 #f3c97c,-6px 8px 0 #f3c97c,0 8px 0 #f3c97c; }
html.dark-mobile :is(.cpsa-news-read,.cpsa-prompt-copy,.cpsa-pill-button.dark) { border:1px solid #8ba594; }
html.dark-mobile .cpsa-news-read:focus-visible { outline-color:#f3c97c; }
html.dark-mobile :is(input,textarea,select) { color:var(--ink); background:var(--paper-2); border-color:var(--rule-strong); }
html.dark-mobile :is(input,textarea)::placeholder { color:var(--ink-faint); opacity:1; }
html.dark-mobile button:not([class]):not([style*="color"]) { color:var(--ink); }
html.dark-mobile .cpsa-prompt-manual textarea { color:var(--ink); background:var(--paper-2); }
html.dark-mobile .tabbar :is(button,.cpsa-search-tab) { color:var(--ink-soft); }
html.dark-mobile .tabbar :is(button,.cpsa-search-tab).active { color:var(--ink); }
html.dark-mobile .cpsa-site-header nav[aria-label="Main navigation"] a { border-color:var(--rule); }
html.dark-mobile :is(.cpsa-topic-nav,.cpsa-monthly-icon,.cpsa-monthly-intro a,.btn.acid,.tag.acid,.btn-soft.acid,.cpsa-quiz-options button[aria-pressed="true"],.cpsa-play-filters a[aria-current="page"]) { color:#15241b; }
html.dark-mobile .cpsa-topic-nav a { color:inherit; }
html.dark-mobile .cpsa-play-filters a[aria-current="page"] { background:var(--acid); }
/* Content art and bright badges keep dark lettering; they are intentional accent islands. */
html.dark-mobile :is(.sticker,.placeholder) { --ink:#15241b; color:#15241b; }
html.dark-mobile :is(.btn.hot,.tag.hot) { color:#15241b; }
html.dark-mobile .cpsa-newsletter { background:var(--paper-2)!important; color:var(--ink); }
html.dark-mobile .cpsa-tip-link.card { background:var(--paper-2)!important; color:var(--ink); }
html.dark-mobile .cpsa-about-stat { background:var(--paper-2)!important; color:var(--ink)!important; }
html.dark-mobile .cpsa-home-video-art, html.dark-mobile .cpsa-video-still { background:#304b3b; }
html.dark-mobile .cpsa-hero-art-fallback { background:linear-gradient(140deg,#304b3b,var(--paper)); color:#a7dfba; }
html.dark-mobile :is(a,button,input,textarea,select,summary):focus-visible { outline:3px solid #f3c97c; outline-offset:3px; }

html.dark-mobile :is(.tip-item,.tip-item-h,.video-card,.chip,.tod-card) { background:var(--paper-2); border-color:var(--rule); }
html.dark-mobile .chip.active { background:var(--ink); color:var(--paper); }
html.dark-mobile .streak { background:#224e3d; color:#f0f5ed; }
html.dark-mobile .streak::before { opacity:.25; }
html.dark-mobile .cpsa-profile-avatar { color:#15241b!important; }
html.dark-mobile .cpsa-recommendation { background:var(--paper-3)!important; color:var(--ink)!important; }
html.dark-mobile .cpsa-tool-feedback { color:#15241b!important; }
html.dark-mobile .cpsa-tool-feedback button { color:#15241b; }

.phone-stage .cpsa-header-row > .cpsa-color-toggle { display:none; }
@media(max-width:767px) { .cpsa-header-row > .cpsa-color-toggle { display:none; } }
/* Focus needs a dark ring on the intentionally bright accent surfaces. */
html.dark-mobile :is(.cpsa-topic-nav,.cpsa-home-quiz,.cpsa-awareness-strip) :is(a,button):focus-visible,
html.dark-mobile :is(.btn.acid,.btn.hot,.cpsa-monthly-intro a,.cpsa-pill-button:not(.dark)):focus-visible { outline-color:#15241b; box-shadow:0 0 0 6px #f0f5ed; }

@supports (color:color-mix(in srgb,black,white)) {
  html.dark-mobile, html.dark-mobile .phone-stage { --hot:color-mix(in srgb,var(--theme-hot,#99502a) 45%,white)!important; }
}
html.dark-mobile .card { background:var(--paper-2); color:var(--ink); }
html.dark-mobile :is(input[type="text"],input[type="email"],input[type="password"]):focus { background:var(--paper-2); color:var(--ink); }
html.dark-mobile :is(.tag-pill.acid,.tag-pill.hot,.tag-pill.blue,.tag-pill.mint,.btn-soft.hot,.q-opt.wrong,.q-opt.correct) { color:#15241b; }
html.dark-mobile .cpsa-newsletter-signup p a { color:#a7dfba; }
html.dark-mobile .placeholder { --paper-2:#d3ead9; }
html.dark-mobile :is(.cpsa-article-body,.cpsa-tool-card,.cpsa-newsletter-signup) p a:not([class]) { color:#a7dfba; }
