/* Feedback always defines both foreground and background, across both themes. */
html body :is(.pocket-feedback,.mobile-flow-feedback,.story-feedback,.activity-feedback){background:#dcf7e8!important;color:#194b39!important;text-shadow:none!important;border:1px solid #81c5a4}
html body :is(.pocket-feedback,.mobile-flow-feedback,.story-feedback,.activity-feedback) :is(p,strong,b,small,span,em){color:inherit!important;text-shadow:none!important}
html body :is(.feedback-review,.mobile-flow-feedback.review,.story-feedback.review,.activity-feedback.review){background:#ffedc5!important;color:#67431a!important;border-color:#d9ae60}
html body :is(.pocket-choices,.mobile-flow-options) button.is-correct{background:#dcf7e8!important;color:#194b39!important;opacity:1}
html body :is(.pocket-choices,.mobile-flow-options) button.is-incorrect{background:#ffe3dd!important;color:#752b24!important;opacity:1}
html body :is(.pocket-choices,.mobile-flow-options) button:is(.is-correct,.is-incorrect) *{color:inherit!important}
html body :is(button,summary,.pocket-file){min-height:44px}
html body :is(.pocket-nav button,.pocket-hint,.pocket-grid span,.pocket-hero small,.pocket-word span,.pocket-word em,.story-stop-name,.pocket-sync){font-size:max(12px,.75rem)}
html body :is(input,textarea){font-size:max(16px,1rem)}
html[data-view=cards] .studio-banner{min-height:130px;padding-block:16px}
html[data-view=cards] .studio-banner img{max-height:105px}
html[data-view=cards] .studio-card-panel{scroll-margin-top:16px}
.pocket-celebration,.pocket-celebration *{pointer-events:none!important}
html body .lm-mini{bottom:calc(104px + env(safe-area-inset-bottom));width:100px;height:100px;pointer-events:none;opacity:.9}
#restoreProgress{max-height:90dvh;overflow:auto;width:min(480px,calc(100% - 28px));padding:24px;color:#342c34;background:#fff5e7;border:0;border-radius:24px}
#restoreProgress>button{display:block;width:100%;margin-top:12px}
.story-grammar-intro .story-line{background:#fff5e6e6;color:#273846;border-radius:20px;padding:18px}
.story-grammar-intro>p{background:#173649e8;color:#fff9e8;border-radius:18px;padding:16px;line-height:1.6}
@media(max-height:500px){html body .lm-mini{width:70px;height:70px;bottom:95px}.pocket-flash{min-height:220px!important}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{scroll-behavior:auto!important}}

/* Keep Chinese glyphs on a CJK-capable system font across Android and iOS. */
:lang(zh),.story-new,.story-built button,.story-blocks button,.pinyin-candidates button{font-family:system-ui,-apple-system,"PingFang SC","PingFang TC","Microsoft YaHei","Noto Sans CJK SC","Noto Sans CJK TC",sans-serif;overflow-wrap:anywhere}
.story-player .story-blocks button:disabled:not([data-used=true]){visibility:visible;opacity:.65}
.pocket-cinema[data-loading=true] .cinema-actor,.pocket-cinema[data-loading=failed] .cinema-actor{visibility:hidden}
.cinema-fallback{position:absolute;height:90%;width:70%;left:15%;object-fit:contain;filter:drop-shadow(0 8px 9px #30283955)}
.lm-animation-poster{position:absolute;inset:0;display:grid;place-items:center;font-size:60px;color:#ffe394;pointer-events:none}.lm-animation-poster img{width:80%;height:90%;object-fit:contain}
.lm-scene:is([data-loading=true],[data-loading=failed]) :is(.lm-actor,.lm-particles){visibility:hidden}

.cinema-fallback,.cinema-cast,.cinema-particles{pointer-events:none}
