/* Shared theme coverage for secondary pages, generated controls and dialogs. */
:root{--tc-surface:#f8fbff;--tc-panel:#edf3fa;--tc-text:#203449;--tc-muted:#4e657c;--tc-line:#aebfd1;--tc-link:#1958ac;--tc-selected:#dbeaff;--tc-danger:#a3233c}
html:not(.kk-native) .account-ui .app-download-link{color:var(--tc-text);background:var(--tc-surface);border:1px solid var(--tc-line)}
html[data-theme=dark]{--tc-surface:#192b3f;--tc-panel:#122237;--tc-text:#edf5ff;--tc-muted:#bdcfe2;--tc-line:#526d89;--tc-link:#abcfff;--tc-selected:#29496c;--tc-danger:#ffb5c1}
html:not(.kk-native) :is(.assistant,.assistant-heading,.assistant-chat,#assistant-picker,#assistant-preview){color:var(--tc-text)}
html:not(.kk-native) :is(.assistant-chat,#assistant-picker,#assistant-preview){background:var(--tc-surface);border:1px solid var(--tc-line)}
html:not(.kk-native) #assistant-messages{background:var(--tc-panel)}
html:not(.kk-native) .assistant :is(p,small,label,time,.assistant-empty),html:not(.kk-native) :is(#assistant-status,.assistant-note){color:var(--tc-muted);opacity:1}
html:not(.kk-native) .assistant .assistant-bubble{background:var(--tc-selected);color:var(--tc-text);border:1px solid var(--tc-line)}
html:not(.kk-native) .assistant .assistant-bubble p{color:var(--tc-text)}
html:not(.kk-native) .assistant :is(.assistant-heading a,.assistant-bubble a){color:var(--tc-link);text-underline-offset:4px}
html:not(.kk-native) :is(.assistant,#assistant-picker,#assistant-preview) :is(button,input:not([type=hidden]),textarea){background:var(--tc-surface);color:var(--tc-text);border:1px solid var(--tc-line);font-size:16px;min-height:44px;box-shadow:none}
html:not(.kk-native) :is(.assistant,#assistant-picker,#assistant-preview) :is(input,textarea)::placeholder{color:var(--tc-muted);opacity:1}
html:not(.kk-native) .assistant #assistant-send{background:#185ec7;color:#fff;border-color:#185ec7}
html:not(.kk-native) .assistant .assistant-bar{border-color:var(--tc-line)}
html:not(.kk-native) .assistant :is(.assistant-message time,.assistant-message-actions button,.assistant-file small,.assistant-note){font-size:13px}
html:not(.kk-native) .assistant .assistant-message-actions button{min-height:36px;padding:6px 10px;border-radius:9px}
html:not(.kk-native) :is(#assistant-picker,#assistant-preview) h2{color:var(--tc-text)}
html:not(.kk-native) #assistant-preview-body pre{color:var(--tc-text);background:var(--tc-panel);padding:16px;border-radius:12px;white-space:pre-wrap;overflow-wrap:anywhere}
html:not(.kk-native) :is(.assistant,#assistant-picker,#assistant-preview) :is(a,button,input,textarea):focus-visible{outline:3px solid var(--tc-link);outline-offset:3px}
html:not(.kk-native) .drive-shell .trash-item{color:var(--tc-text);background:var(--tc-surface);border-color:var(--tc-line)}
html:not(.kk-native) .drive-shell .drive-notice{color:var(--tc-text);background:var(--tc-selected);border-color:var(--tc-line)}
html:not(.kk-native) .drive-shell .error{color:var(--tc-danger);background:var(--tc-panel);border:1px solid var(--tc-danger)}
html[data-theme=dark]:not(.kk-native) :is(.platform-download-menu,.platform-mini,.platform-download-option,.appearance-dialog,#detail){background:var(--tc-surface);color:var(--tc-text);border-color:var(--tc-line)}
html[data-theme=dark] :is(.platform-mini-copy span,.platform-option-copy small,.platform-option-action,.platform-download-all,.platform-loading){color:var(--tc-muted)}
html[data-theme=dark] .platform-download-menu .platform-download-option{color:var(--tc-text);background:var(--tc-panel);border-color:var(--tc-line)}
html[data-theme=dark] .platform-download-option[href]:is(:hover,:focus-visible){background:var(--tc-selected)}
html[data-theme=dark] :is(.platform-icon,.platform-android,.platform-ios,.download-device-icon){color:var(--tc-link);background:var(--tc-selected)}
html[data-theme=dark] .public-site :is(.download-tags span,.download-coming,.download-button,.resource-access,.resource-facts,.resource-copy .resource-pick,.resource-copy details,.resource-category-note,.resource-edition,.edition-top,.feedback-form,.gallery-pagination a,.resource-pagination a,.detail-new-tab,.detail-back){color:var(--tc-text);background:var(--tc-panel);border-color:var(--tc-line)}
html[data-theme=dark] .public-site :is(.download-platform,.download-device>p,.mini-download-copy>p,.download-section-title p,.resource-copy small,.resource-facts span,.resource-category-note p,.resource-edition p,.edition-top>span:last-child,.detail-heading small,.credit-label,.selected-credit,.related-story h3 span,.tools-roadmap>small,.page-title>span,.page-title p){color:var(--tc-muted)!important}
html[data-theme=dark] .public-site :is(.resource-sidebar>a[aria-current],.selected-nav a[aria-current],.filter-bar button,.save[aria-pressed=true]){background:var(--tc-selected)!important;color:var(--tc-text)!important;border-color:var(--tc-line)!important}
html[data-theme=dark] .public-site :is(.feedback-form textarea,.resource-mobile-topics select,.tool-input input,.tool-input select,.tool-input textarea,#tool-result textarea,.tool-output input,.tool-output select){color:var(--tc-text)!important;background:var(--tc-panel)!important;border-color:var(--tc-line)!important}
html[data-theme=dark] .public-site :is(input,textarea)::placeholder{color:var(--tc-muted);opacity:1}
html[data-theme=dark] .public-site :is(.tool-symbol,.tool-recents a,.tool-grid a:hover,.tool-grid article:hover,.tool-button,.tool-workflow-actions button,.tool-presets button){background:var(--tc-selected)!important;color:var(--tc-text)!important;border-color:var(--tc-line)!important}
html[data-theme=dark] .public-site :is(.tool-note,.tool-credits,.tool-input .hint){color:var(--tc-muted)}
html[data-theme=dark] .public-site #tool-status.error{color:var(--tc-danger);background:var(--tc-panel)}
/* QR codes retain their white background and dark captions in either theme. */
html[data-theme=dark] .public-site :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]):not([type=submit]):not([type=button]),select,textarea){background:var(--tc-panel)!important;color:var(--tc-text)!important;border-color:var(--tc-line)!important}
html[data-theme=dark] .public-site .about-copy h2{color:var(--tc-text)}
html[data-theme=dark] .public-site .resource-directory .resource-sidebar h2{color:var(--tc-text)}
html:not(.kk-native) :is(#assistant-picker,#assistant-preview)::backdrop{background:#07111db3;backdrop-filter:blur(8px)}
html[data-theme=dark] .public-site .download-qr p{color:#435970!important}
html[data-theme=dark] .public-site .public-daily .page-title,html[data-theme=dark] .public-site.public-daily .page-title{color:var(--tc-text)}
html[data-theme=dark] .public-site .daily-feature :is(p,small){color:var(--tc-muted)!important}
html[data-theme=dark] .public-site .daily-feature .save{background:var(--tc-selected);color:var(--tc-text)}
html[data-theme=dark] :is(.help-grid>section,.release-notes,.service-row){background:var(--tc-surface);color:var(--tc-text);border-color:var(--tc-line)}
html[data-theme=dark] :is(.help-grid p,.help-grid li,.release-notes p,.service-row p,.detail-copy p){color:var(--tc-muted)}
html[data-theme=dark] .home .compact-home{color:var(--tc-text)}
html[data-theme=dark] .home .compact-heading :is(a,.eyebrow),html[data-theme=dark] .home .compact-links :is(p,small){color:var(--tc-muted)}
html[data-theme=light] .home .home-image-credits{color:#4e657c}
html[data-theme=dark] .home .home-image-credits{color:var(--tc-muted)}
html[data-theme=dark] #detail .dialog-close{color:var(--tc-text);background:var(--tc-panel);border:1px solid var(--tc-line)}
html:not(.kk-native) .account-ui :is(.error,[role=alert]){color:var(--tc-danger);background:var(--tc-panel);border-color:var(--tc-danger)}
@media(max-width:650px){html:not(.kk-native) .assistant-compose-actions button{font-size:14px;flex:1 1 auto}html:not(.kk-native) .assistant #assistant-send{flex:1 1 100%;margin-left:0}html:not(.kk-native) .assistant-bar{align-items:end}html:not(.kk-native) .assistant-heading{flex-wrap:wrap}html:not(.kk-native) .assistant-file{max-width:100%;min-width:0}}
