html body main .learning-guide,html body main .learning-workspace,html body main .investigation{background:#f5f9fc!important;color:#142b40!important;border:1px solid #bccfdd!important;border-radius:16px;padding:1.4rem!important;margin:1.5rem auto!important;max-width:1160px;min-width:0}
html body main :is(.learning-guide,.learning-workspace,.investigation) :is(h2,h3,h4,p,li,label,span,summary,small,output,legend,strong){color:#142b40!important;-webkit-text-fill-color:#142b40!important;opacity:1!important;text-shadow:none!important}
.learning-guide>h2,.learning-workspace>h2{margin-top:0}.learning-guide-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}.learning-guide-grid>div{background:#fff;border-radius:10px;padding:1rem}.learning-guide dt{font-weight:750}.learning-guide dd{margin:.3rem 0 1rem}.learning-actions,.lesson-step-nav{display:flex;flex-wrap:wrap;gap:.65rem;align-items:center;margin:1rem 0}
html body :is(.learning-guide,.learning-workspace,.investigation,.learning-dialog,.draft-toolbar) button,html body .lesson-step-nav a{background:#123950!important;color:#fff!important;-webkit-text-fill-color:#fff!important;border:2px solid transparent;border-radius:8px;padding:.7rem 1rem;font:700 1rem/1.2 system-ui;cursor:pointer;min-height:44px;text-decoration:none}
html body :is(.learning-workspace,.investigation,.learning-dialog) button:disabled{opacity:.55!important;cursor:wait}.lesson-step-nav a:focus-visible,button:focus-visible{outline:3px solid #c07800!important;outline-offset:3px}
.learning-fields,.investigation-controls{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem}.learning-fields label,.investigation-controls label{display:grid;gap:.4rem;font-weight:700}.learning-fields .wide{grid-column:1/-1}
html body :is(.learning-workspace,.investigation,.learning-dialog) :is(input,select,textarea){width:100%;font:1rem/1.5 system-ui;background:#fff!important;color:#142b40!important;-webkit-text-fill-color:#142b40!important;border:1px solid #6c889b;border-radius:7px;padding:.65rem;min-width:0}
.learning-fields textarea{min-height:125px;resize:vertical}.learning-fields textarea[data-trial-log]{min-height:150px}.draft-toolbar{padding:1rem;border:1px solid #91b3bf;border-radius:10px;background:#e9f4f3;color:#142b40;margin:1rem 0}.draft-toolbar p{margin:0}.draft-toolbar small{display:block;line-height:1.5}
.learning-dialog{border:0;border-radius:14px;padding:1.5rem;max-width:min(900px,94vw);max-height:88vh;overflow:auto;background:#f4f8fb;color:#142b40;box-shadow:0 20px 70px #0008}.learning-dialog::backdrop{background:#041321b3}.learning-dialog h2{font-size:1.5rem}.report-paper{background:#fff;padding:1.4rem;border:1px solid #c0ced7}.report-paper p{white-space:pre-wrap;overflow-wrap:anywhere}.report-paper h4{margin-bottom:.3rem}.learning-dialog input{max-width:100%}
.investigation svg{display:block;width:100%;max-height:290px;background:#fff;border:1px solid #c3d4df;border-radius:10px;margin:1rem 0}.investigation svg text{font:14px system-ui;fill:#142b40}.investigation-readout{font-size:1.15rem;font-weight:700;padding:1rem;background:#dcefed;border-radius:10px}.investigation-hint{font-size:.95rem}.investigation-table{width:100%;border-collapse:collapse;background:white}.investigation-table td,.investigation-table th{padding:.5rem;border-bottom:1px solid #c3d4df;text-align:left}.investigation-status{min-height:2em}
.resource-preview-frame{width:100%;height:55vh;border:1px solid #c0ced7}.resource-role{font-size:.8rem;font-weight:750;background:#e1edf4;padding:.25rem .5rem;border-radius:5px}.resource-preview-image{max-height:55vh;object-fit:contain;max-width:100%}
@media(max-width:700px){.learning-guide-grid,.learning-fields,.investigation-controls{grid-template-columns:1fr}.learning-guide,.learning-workspace,.investigation{width:calc(100% - 24px)!important}.learning-guide-grid{gap:.5rem}.learning-guide-grid>div{padding:.75rem}.lesson-step-nav{gap:.4rem}.lesson-step-nav a{font-size:.85rem!important}.learning-dialog{padding:1rem}.report-paper{padding:.75rem}.resource-filter-grid{grid-template-columns:1fr 1fr!important}}
@media print{.draft-toolbar,.lesson-step-nav,.learning-actions{display:none!important}}
/* Override legacy lesson-specific color rules for accessible control contrast. */
html body #main :is(.investigation,.learning-workspace,.draft-toolbar) button,
html body dialog.learning-dialog button{color:#fff!important;-webkit-text-fill-color:#fff!important;background:#123950!important}
html body #main :is(.investigation,.learning-workspace) button:disabled{color:#314b5e!important;-webkit-text-fill-color:#314b5e!important;background:#dce5eb!important;opacity:1!important}
html body #main .investigation svg text{font-size:18px!important;font-weight:500!important}
@media(max-width:700px){html{scroll-padding-top:9rem}}
html body #main .investigation svg text{stroke:none!important}
