/* Contrast rules have their own important layer so old theme specificity cannot
   paint white lettering on the blanket white background. Regular mode is untouched. */
@layer kang-readable-contrast {
 body:is(.high-contrast,.contrast){color:#111!important;background-color:#fff!important;color-scheme:light!important}
 body:is(.high-contrast,.contrast) :is(h1,h2,h3,h4,h5,h6,p,li,dt,dd,label,legend,summary,span,strong,small,b,em,i,a,button,input,textarea,select,option,optgroup,output,figcaption,th,td,time,code,pre){color:#111!important;-webkit-text-fill-color:currentColor!important;text-shadow:none!important}
 /* Inline words must not create opaque white squares inside a dark control. */
 body:is(.high-contrast,.contrast) :is(br,svg,img,picture){background-color:transparent!important}
 body:is(.high-contrast,.contrast) :is(a,button,select,input,textarea){background-color:#fff!important;border-color:#111!important}
 body:is(.high-contrast,.contrast) a{text-decoration:underline!important;text-decoration-thickness:2px!important;text-underline-offset:.18em}
 body:is(.high-contrast,.contrast) :is(button,select,input,textarea){border-width:2px!important}
 body:is(.high-contrast,.contrast) :is(a.solid,a.primary,button.solid,.mag-primary,.comic-home-link,.regional-original,button[aria-pressed=true],button[aria-selected=true],a[aria-current=page],.mc-course-nav a[aria-current=page]){color:#fff!important;-webkit-text-fill-color:currentColor!important;background-color:#111!important;border-color:#111!important}
 body:is(.high-contrast,.contrast) :is(a.solid,a.primary,button.solid,.mag-primary,.comic-home-link,.regional-original,button[aria-pressed=true],button[aria-selected=true],a[aria-current=page],.mc-course-nav a[aria-current=page]) *{color:inherit!important;-webkit-text-fill-color:currentColor!important;background-color:transparent!important}
 body:is(.high-contrast,.contrast) :is(button:disabled,input:disabled,select:disabled){color:#111!important;background-color:#fff!important;border-color:#111!important;border-style:dashed!important;opacity:1!important}
 body:is(.high-contrast,.contrast) :is(input,textarea)::placeholder{color:#595959!important;-webkit-text-fill-color:#595959!important;opacity:1!important}
 body:is(.high-contrast,.contrast) :is(a,button,input,textarea,select,summary,[tabindex]):focus-visible{outline:4px solid #005fcc!important;outline-offset:4px!important}
 body:is(.high-contrast,.contrast) .comic-home-link svg{stroke:currentColor!important;fill:none!important}
 /* Step badges and map numbers remain a matched light-on-dark pair. */
 body:is(.high-contrast,.contrast) :is(.mc-number,.traffic-card-number,.traffic-number-pin){background-color:#111!important;color:#fff!important;-webkit-text-fill-color:currentColor!important;border-color:#111!important}
 body:is(.high-contrast,.contrast) :is(.mc-number,.traffic-card-number,.traffic-number-pin) *{background-color:transparent!important;color:inherit!important;-webkit-text-fill-color:currentColor!important}
 /* The linked playroom card is a white panel in this mode, including its copy. */
 body:is(.high-contrast,.contrast) .mag-play{background-color:#fff!important;color:#111!important;border:3px solid #111!important}
 body:is(.high-contrast,.contrast) .mag-play :is(div,h2,p,span){background-color:transparent!important;color:#111!important;-webkit-text-fill-color:currentColor!important}
 body:is(.high-contrast,.contrast) .mag-play-cta{border:2px solid #111!important;padding:.25em .45em!important}
 /* Preserve the full hero artwork; only the text column needs opaque paper. */
 body:is(.high-contrast,.contrast) :is(.mag-hero-inner,.mag-hero-art){background-color:transparent!important}
 body:is(.high-contrast,.contrast) .mag-hero-copy{background-color:#fff!important}
}
