/* UI colors only; artwork, game boards and export pixels keep their original palette. */
:root{color-scheme:light;--dp-surface:#fff;--dp-ground:#f7f8fa;--dp-action:#19448e}
:root[data-theme=dark]{color-scheme:dark;--dp-ground:#101722;--dp-surface:#182231;--dp-blue:#a6c9ff;--dp-ink:#e8edf5;--dp-line:#3b4a5e;--dp-soft:#223248;--dp-muted:#acb9cb;--dp-action:#2b569a}
.dp-theme-control{display:flex;align-items:center;gap:12px;margin-top:22px;padding-top:18px;border-top:1px solid var(--dp-line);font-size:13px;line-height:1.5;color:var(--dp-ink)}
.dp-theme-control>span{flex:1;min-width:0;overflow-wrap:anywhere}.dp-theme-control select{font:inherit;max-width:70%;min-width:0;min-height:44px;padding:8px;border:1px solid var(--dp-line);border-radius:7px;color:var(--dp-ink);background:var(--dp-surface)}
.dp-header a.dp-brand{display:flex;align-items:center;justify-content:center;text-decoration:none;color:var(--dp-ink)}
.dp-header .dp-wordmark{display:block;flex:none;font-family:"Arial Rounded MT Bold","Trebuchet MS",Arial,sans-serif;font-size:33px;font-weight:700;letter-spacing:-1.6px;line-height:1;margin:0;padding:0}
@media(max-width:640px){.dp-header .dp-wordmark{font-size:28px;letter-spacing:-1.4px}}
html[data-theme=dark]{background:var(--dp-ground)}
html[data-theme=dark] .dp-site{color:var(--dp-ink);background:var(--dp-ground);--bg:var(--dp-ground);--card:var(--dp-surface);--text:var(--dp-ink);--sub:var(--dp-muted);--primary:var(--dp-action);--primary-dark:var(--dp-blue);--accent:#a6c9ff;--blue:#a6c9ff}
html[data-theme=dark] .dp-site .main,
html[data-theme=dark] .dp-site .dp-header,
html[data-theme=dark] .dp-site .dp-footer,
html[data-theme=dark] .dp-site dialog,
html[data-theme=dark] .dp-site .dp-dialog-head button,
html[data-theme=dark] .dp-site .dp-search,
html[data-theme=dark] .dp-site .dp-filter-trigger,
html[data-theme=dark] .dp-site .dp-filter-topics button,
html[data-theme=dark] .dp-site .dp-home-kinds button,
html[data-theme=dark] .dp-site .dp-next-categories a,
html[data-theme=dark] .dp-site .dp-more,
html[data-theme=dark] .dp-site .dp-random,
html[data-theme=dark] .dp-site .dp-page-jump button,
html[data-theme=dark] .dp-site .dp-secondary-button,
html[data-theme=dark] .dp-site .dp-policy button,
html[data-theme=dark] .dp-site .dp-work-card,
html[data-theme=dark] .dp-site .dp-about-links a,
html[data-theme=dark] .dp-site .dp-directory-kind,
html[data-theme=dark] .dp-site .dp-view-toggle,
html[data-theme=dark] .dp-site .dp-export-controls,
html[data-theme=dark] .dp-site .dp-skip{background:var(--dp-surface);border-color:var(--dp-line);color:var(--dp-ink)}
html[data-theme=dark] .dp-site input:not([type=range]):not([type=color]),
html[data-theme=dark] .dp-site textarea,
html[data-theme=dark] .dp-site select{color:var(--dp-ink);background-color:var(--dp-surface);border-color:var(--dp-line)}
html[data-theme=dark] .dp-site input::placeholder,
html[data-theme=dark] .dp-site textarea::placeholder{color:var(--dp-muted);opacity:1}
html[data-theme=dark] .dp-preview-bar{background:#0b1220;color:#d8e5f8}
html[data-theme=dark] .dp-site .dp-card figure,
html[data-theme=dark] .dp-site .dp-header-search,
html[data-theme=dark] .dp-site .dp-previous-result,
html[data-theme=dark] .dp-site .dp-drawer-secondary .dp-app-promotion,
html[data-theme=dark] .dp-site .dp-sort-tools button,
html[data-theme=dark] .dp-site .dp-ranking-toggle,
html[data-theme=dark] .dp-site .dp-export-controls button,
html[data-theme=dark] .dp-site .dp-personal-share,
html[data-theme=dark] .dp-site .dp-name-diagnosis #shindanretry{background:var(--dp-soft);border-color:var(--dp-line);color:var(--dp-ink)}
html[data-theme=dark] .dp-site .dp-order-tabs button[aria-pressed=true],
html[data-theme=dark] .dp-site .dp-filter-topics button[aria-pressed=true],
html[data-theme=dark] .dp-site .dp-library-status .dp-view-toggle[aria-pressed=true],
html[data-theme=dark] .dp-site .dp-quiz-series a:hover,
html[data-theme=dark] .dp-site .dp-work-card:hover,
html[data-theme=dark] .dp-site .dp-about-links a:hover,
html[data-theme=dark] .dp-site .dp-ranking-toggle:hover{background:#2a4161;color:var(--dp-blue);border-color:#7197c9}
html[data-theme=dark] .dp-site .dp-home-kinds button[aria-pressed=true],
html[data-theme=dark] .dp-site .dp-primary-button,
html[data-theme=dark] .dp-site .dp-search:not(.dp-header-search) button,
html[data-theme=dark] .dp-site .dp-pagination [aria-current],
html[data-theme=dark] .dp-site .dp-quiz-series [aria-current],
html[data-theme=dark] .dp-site #save-image-btn,
html[data-theme=dark] .dp-site .dp-export-save,
html[data-theme=dark] .dp-site .choose_box .return,
html[data-theme=dark] .dp-site .dp-name-diagnosis #shindancheck,
html[data-theme=dark] .dp-site .dp-personal-share button{background:var(--dp-action);border-color:#6088bf;color:#fff!important}
html[data-theme=dark] .dp-site .dp-directory-work .dp-title-link,
html[data-theme=dark] .dp-site .ranking-list li{border-color:var(--dp-line)}
html[data-theme=dark] .dp-site .dp-work-kind{background:#263e5d;color:#c0d9ff}
html[data-theme=dark] .dp-site .dp-work-kind[data-kind=quiz]{background:#1d443b;color:#a8e1ca}
html[data-theme=dark] .dp-site .dp-work-kind[data-kind=diagnosis],
html[data-theme=dark] .dp-site .dp-work-kind[data-kind=drawing]{background:#41334e;color:#dfc3f5}
html[data-theme=dark] .dp-site #battle-container,

html[data-theme=dark] .dp-site .dp-quiz,

html[data-theme=dark] .dp-site .dp-diagnosis-step,

html[data-theme=dark] .dp-site .choose_box .dp-question-panel,

html[data-theme=dark] .dp-site .shindan-wrapper,

html[data-theme=dark] .dp-site .dp-kanaupa-content .panel.dp-quiz{background:var(--dp-soft);color:var(--dp-ink);border-color:var(--dp-line)}
html[data-theme=dark] .dp-site #leftField,
html[data-theme=dark] .dp-site #rightField,
html[data-theme=dark] .dp-site .middleField,
html[data-theme=dark] .dp-site .dp-quiz-choice,
html[data-theme=dark] .dp-site .choose_box a.btn2,
html[data-theme=dark] .dp-site #results-container,
html[data-theme=dark] .dp-site .choose_box .result #ansRst,
html[data-theme=dark] .dp-site .choose_box .result #ansDisc,
html[data-theme=dark] .dp-site .dp-kanaupa-content .panel,
html[data-theme=dark] .dp-site .dp-kanaupa-content .choice-btn{background:var(--dp-surface);color:var(--dp-ink);border-color:#536982;box-shadow:0 2px 0 #0c1523}
html[data-theme=dark] .dp-site #leftField:hover,
html[data-theme=dark] .dp-site #rightField:hover,
html[data-theme=dark] .dp-site .dp-quiz-choice:hover,
html[data-theme=dark] .dp-site .choose_box a.btn2:hover,
html[data-theme=dark] .dp-site .dp-kanaupa-content .choice-btn:hover{background:#2a3e58;border-color:#8cb2e5}
html[data-theme=dark] .dp-site #both-like{background:#1e4636;color:#b9efcf;border-color:#67ac87;box-shadow:0 2px 0 #112d20}
html[data-theme=dark] .dp-site #both-dislike{background:#4a3520;color:#f6d1a1;border-color:#b39060;box-shadow:0 2px 0 #302417}
html[data-theme=dark] .dp-site #both-like:hover{background:#2a5b44}
html[data-theme=dark] .dp-site #both-dislike:hover{background:#5b4229}
html[data-theme=dark] .dp-site .choose_box .result,
html[data-theme=dark] .dp-site .dp-showing-result,
html[data-theme=dark] .dp-site .dp-kanaupa-content .panel.dp-showing-result,
html[data-theme=dark] .dp-site .dp-diagnosis-result{background:linear-gradient(145deg,#253a57,var(--dp-surface) 70%);border-color:#4c678b;color:var(--dp-ink)}
html[data-theme=dark] .dp-site .choose_box #ansP,
html[data-theme=dark] .dp-site .choose_box #ansH4,
html[data-theme=dark] .dp-site .dp-question,
html[data-theme=dark] .dp-site .character-name,
html[data-theme=dark] .dp-site .character-name-only,
html[data-theme=dark] .dp-site .results-table{color:var(--dp-ink)}
html[data-theme=dark] .dp-site .results-table td{background:var(--dp-surface);border-color:var(--dp-line);color:var(--dp-ink)}
html[data-theme=dark] .dp-site .results-table th{background:var(--dp-action);color:#fff}
html[data-theme=dark] .dp-site .results-table tr[data-rank='1'] td{background:#443b21!important}
html[data-theme=dark] .dp-site .results-table tr[data-rank='1'] .rank-number{color:#f1d183}
html[data-theme=dark] .dp-site .results-table tr[data-rank='2'] td{background:#2c3b50!important}
html[data-theme=dark] .dp-site .results-table tr[data-rank='2'] .rank-number{color:#c6d8ee}
html[data-theme=dark] .dp-site .results-table tr[data-rank='3'] td{background:#433329!important}
html[data-theme=dark] .dp-site .results-table tr[data-rank='3'] .rank-number{color:#ecc4a2}
html[data-theme=dark] .dp-site .dp-quiz-series a,
html[data-theme=dark] .dp-site .dp-sort-has-images .dp-image-error,
html[data-theme=dark] .dp-site .dp-name-diagnosis .shindancard,
html[data-theme=dark] .dp-site .dp-name-diagnosis .shindanresults{background:var(--dp-surface);color:var(--dp-ink);border-color:var(--dp-line)}
html[data-theme=dark] .dp-site .dp-quiz-series [aria-current]{background:var(--dp-action);color:#fff}
html[data-theme=dark] .dp-kanaupa-content .btn-ghost,

html[data-theme=dark] .dp-kanaupa-content .brush-btn,

html[data-theme=dark] .dp-kanaupa-content .tag-chip,

html[data-theme=dark] .dp-kanaupa-content .series-chips a,

html[data-theme=dark] .dp-kanaupa-content .theme-banner,

html[data-theme=dark] .dp-kanaupa-content .explanation,

html[data-theme=dark] .dp-kanaupa-content .result-advice,

html[data-theme=dark] .dp-kanaupa-content .vs-item{background:var(--dp-soft);border-color:#536982;color:var(--dp-ink)}
html[data-theme=dark] .dp-site.dp-kanaupa .btn-primary{background:var(--dp-action);color:#fff;border-color:#6088bf}
html[data-theme=dark] .dp-kanaupa-content .btn-ghost:hover,
html[data-theme=dark] .dp-kanaupa-content .brush-btn.active,
html[data-theme=dark] .dp-kanaupa-content .tag-chip.active,
html[data-theme=dark] .dp-kanaupa-content .series-chips [aria-current]{background:#2a4161;color:var(--dp-blue)}
html[data-theme=dark] .dp-kanaupa-content .result-card{background:linear-gradient(160deg,#2c3b50,var(--dp-surface));color:var(--dp-ink);border-color:#6883ab}
html[data-theme=dark] .dp-kanaupa-content .result-card .result-text,
html[data-theme=dark] .dp-kanaupa-content .result-card .result-name,
html[data-theme=dark] .dp-kanaupa-content .result-card .result-compatible{color:var(--dp-ink)}
html[data-theme=dark] .dp-kanaupa-content .progress-wrap,
html[data-theme=dark] .dp-kanaupa-content .meter-bg{background:#3a4960}
html[data-theme=dark] .dp-site .dp-game-progress progress{background:#3a4960}
html[data-theme=dark] .dp-site .share-copy,
html[data-theme=dark] .dp-site .dp-share-group .share-copy{background:var(--dp-soft);border:1px solid #6a809e;color:var(--dp-ink)}
html[data-theme=dark] .dp-site .dp-share-group [data-network=x],
html[data-theme=dark] .dp-site .dp-share-group [data-network=threads]{box-shadow:inset 0 0 0 1px #77849a!important}
html[data-theme=dark] .dp-ad-layout .dp-ad-slot{background:repeating-linear-gradient(135deg,#1b293b,#1b293b 10px,#213044 10px,#213044 20px);color:var(--dp-muted);border-color:#60758f}
html[data-theme=dark] .dp-site dialog::backdrop{background:#030a16b3}
@media(forced-colors:active){.dp-theme-control select{forced-color-adjust:auto}}
html[data-theme=dark] .dp-site .dp-quiz-result-title,
html[data-theme=dark] .dp-site .dp-diagnosis-result h2,
html[data-theme=dark] .dp-site .dp-name-diagnosis .shindantitle{color:var(--dp-ink)}
html[data-theme=dark] .dp-site .dp-card-meta{color:var(--dp-muted)}
html[data-theme=dark] .dp-kanaupa-content .pz-howto-open,
html[data-theme=dark] .dp-kanaupa-content .pz-howto-box,
html[data-theme=dark] .dp-kanaupa-content .pz-howto-close,
html[data-theme=dark] .dp-kanaupa-content .hk-lv,
html[data-theme=dark] .dp-kanaupa-content .dr-lv{background:var(--dp-surface);color:var(--dp-ink);border-color:#536982}
html[data-theme=dark] .dp-kanaupa-content .tsukihi-chip{background:#443b21;color:#f3dfa8}
html[data-theme=dark] .dp-kanaupa-content .btn-primary .tsukihi-diff-size{color:#edf4ff}
html[data-theme=dark] .dp-kanaupa-content .reaction-zone.idle{background:var(--dp-action);color:#fff}
html[data-theme=dark] .dp-kanaupa-content .evolve-tile{color:#253553}
html[data-theme=dark] .dp-site .dp-share-group [data-network=line],
html[data-theme=dark] .dp-site .entry-content .dp-share-group [data-network=line]{background-color:#087c37!important;color:#fff!important}
html[data-theme=dark] .dp-site #results-container h2{background:transparent;color:var(--dp-ink);padding:6px 0;margin:0 0 12px}
html[data-theme=dark] .dp-site #restart-button{background:var(--dp-soft)!important;color:var(--dp-ink)!important;border-color:var(--dp-line)}
