/* Responsive corrections after the existing cascade. */
html{scroll-padding-top:calc(var(--course-header-height,64px) + 12px)}
:where(button,a,input,textarea,select,summary,[tabindex]):focus-visible{outline:3px solid #14b8c8!important;outline-offset:3px}
#xpHeader.unified-learning-progress{display:flex!important;min-width:0;max-width:220px}
#content :where(input:not([type=radio]):not([type=checkbox]),textarea,select,video,img,iframe,pre){max-width:100%;box-sizing:border-box}
#content :where(p,li,button,td,th,pre){overflow-wrap:anywhere}
#content pre{white-space:pre-wrap}
#content .course-tab{white-space:normal;min-height:44px}
#content .option{white-space:normal;max-width:100%}
.topbar{height:auto!important;min-height:64px;flex-wrap:wrap}
.topbar .brand{min-width:0!important;flex:1 1 180px}
.topbar .tools{flex:0 1 auto;max-width:100%;flex-wrap:wrap}
.device-gate{align-items:safe center}
@media(max-width:850px){
 .topbar{gap:6px!important;padding:8px!important;z-index:1300}
 .topbar .brand{flex:1 1 calc(100% - 60px)}
 .topbar .audio-controls,.topbar .tools,.topbar .device-switch{order:0!important;margin:0!important}
 #xpHeader.unified-learning-progress{flex:1 1 100%!important;width:100%!important;max-width:none!important}
 #sidebar{top:var(--course-header-height,120px)!important;height:auto!important;bottom:0!important;z-index:1250!important}
 .shell.aside-open .mobile-sidebar-overlay{top:var(--course-header-height,120px)!important}
 #content .hero{min-height:0!important}
 #content .grid,#content .campaign-steps{grid-template-columns:minmax(0,1fr)!important}
 #content .navrow,#content .scene-complete,#content .campaign-actions{flex-wrap:wrap;gap:10px}
 #content .navrow>*{min-width:0;max-width:100%}
 #content .course-section-body{padding:12px!important}
 #content .course-tab{font-size:clamp(.72rem,3vw,.95rem)!important;padding:10px 3px!important}
 #content .table-responsive{overflow-x:auto;max-width:100%}
 #content table{max-width:100%;overflow-wrap:anywhere}
 .device-dialog{max-height:100%;overflow:auto}
}
@media print{.topbar{display:none!important}}
