:root{--chem-ink:#18324b;--chem-blue:#235fd4;--chem-border:#dbe3ef;--chem-soft:#f5f8fe;--chem-green:#0d7a61;--chem-red:#bc4659;--chem-gold:#fef3d2}body{background:#f6f8fb;color:var(--chem-ink)}.chem-page{max-width:1140px;padding-bottom:70px}.chem-intro{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:28px 0 19px}.chem-eyebrow{font-size:11px;letter-spacing:1.65px;font-weight:800;color:#396bbf}.chem-intro h1{font-size:clamp(28px,4vw,42px);line-height:1.16;letter-spacing:-1px;margin:8px 0}.chem-intro p{max-width:720px;font-size:16px;color:#4c6179;line-height:1.55;margin:0}.chem-highscore{min-width:130px;border-radius:15px;border:1px solid var(--chem-border);background:white;padding:15px;text-align:center}.chem-highscore small{display:block;font-size:12px;color:#657890}.chem-highscore strong{display:block;font-size:25px;margin-top:5px;color:#235fd4}.chem-shell{padding:24px;background:white;border:1px solid var(--chem-border);border-radius:20px;box-shadow:0 12px 30px #243e6210}.chem-headrow{display:flex;gap:12px;justify-content:space-between;align-items:center}.chem-mode{display:flex;gap:6px;min-width:0;overflow-x:auto;scrollbar-width:thin}.chem-mode button{border:0;white-space:nowrap;border-radius:12px;background:#f0f4fa;font-size:14px;color:#425979;font-weight:700;padding:12px 14px}.chem-mode button.active{color:white;background:#245fd1}.chem-minor,.chem-muted{color:#314b6b;font-weight:700;border:1px solid #cfdaea;border-radius:11px;padding:10px 14px;background:white;white-space:nowrap;cursor:pointer}.chem-options{display:flex;gap:12px;flex-wrap:wrap;margin:17px 0 15px}.chem-options label,.chem-worksheet-options label{font-size:12px;color:#60758e;font-weight:700;display:flex;align-items:center;gap:8px}.chem-options select,.chem-worksheet-options select,.chem-worksheet-options input{color:#20364f;background:#f8faff;border:1px solid #d4deec;padding:9px 10px;border-radius:10px;max-width:200px;font-size:14px}.chem-scoreline{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;font-size:13px;font-weight:750;color:#506580}.chem-scoreline span:nth-child(2){color:var(--chem-blue)}.chem-progress{height:6px;background:#edf1f8;border-radius:99px;margin-top:8px;overflow:hidden}.chem-progress>div{height:100%;width:0;background:#346ada;transition:width .2s}.chem-question{text-align:center;padding:29px 6px 22px}.chem-question-text{color:#65778e;font-size:14px;font-weight:650;margin-bottom:14px}.chem-equation{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:8px}.chem-species{display:flex;align-items:center;gap:5px;padding:6px;border:1px solid #dce5f0;border-radius:13px;background:#f8fbff}.chem-coefficient{display:grid;grid-template-rows:29px 39px 29px;width:47px}.chem-coefficient button{display:flex;justify-content:center;align-items:center;background:#ecf3ff;color:#285ebc;border:1px solid #cfdff8;border-radius:7px;font-size:18px;font-weight:800;padding:0}.chem-coefficient input{width:100%;min-width:0;text-align:center;border:1px solid #bdcee5;background:white;border-radius:7px;font-size:20px;font-weight:800;color:#173b6a;-moz-appearance:textfield}.chem-coefficient input::-webkit-inner-spin-button{-webkit-appearance:none}.chem-molecule{font-size:clamp(22px,2.65vw,29px);font-weight:850;color:#1b2e45;letter-spacing:-.5px;white-space:nowrap}.chem-molecule sub{font-size:.57em;vertical-align:sub;font-weight:700}.chem-sep{font-size:24px;color:#9baac0;font-weight:900}.chem-arrow{font-size:28px;color:#3164ba;padding:0 3px}.chem-underhint{font-size:12px;color:#718199;margin:12px 0 0}.chem-atom-title{display:flex;align-items:center;gap:10px;justify-content:space-between;border-top:1px solid #e8edf5;padding-top:18px}.chem-atom-title strong{font-size:16px}.chem-balancebadge{font-size:12px;border-radius:20px;padding:6px 10px;background:#fff4d6;color:#815a03;font-weight:800}.chem-balancebadge.good{background:#def8ef;color:#0c775d}.chem-atoms{display:grid;gap:9px;margin-top:15px}.chem-atomrow{display:grid;grid-template-columns:42px minmax(0,1fr) 42px;gap:11px;align-items:center}.chem-atomrow>strong{font-size:14px}.chem-atomrow>span:last-child{text-align:right;font-size:12px;color:#657890;font-weight:700}.chem-bars{display:grid;gap:5px}.chem-bar{display:grid;grid-template-columns:48px 1fr 37px;gap:7px;align-items:center;font-size:11px;font-weight:750;color:#586b84}.chem-track{height:9px;background:#eef2f7;border-radius:20px;overflow:hidden}.chem-track>i{height:100%;display:block;border-radius:20px;transition:width .18s;background:#3583da}.chem-bar.product i{background:#e2a13b}.chem-atomrow.matched .chem-bar i{background:#25a47e}.chem-controls{margin:23px 0 10px;display:flex;flex-wrap:wrap;gap:8px}.chem-controls button{cursor:pointer}.chem-primary{background:#255fd3;color:white;border:0;border-radius:11px;padding:13px 18px;font-weight:800;cursor:pointer;min-height:46px}.chem-primary span{opacity:.6;margin-left:6px}.chem-muted{min-height:44px}.chem-feedback{padding:16px 18px;background:#f4f7fe;border:1px solid #dfe7f3;border-radius:13px;color:#4e6076;line-height:1.5;font-size:14px;display:grid;gap:3px}.chem-feedback strong{color:#1e3c60;font-size:15px}.chem-feedback.ok{background:#edf9f2;border-color:#c7eadc}.chem-feedback.warn{background:#fff8ed;border-color:#f5dfae}.chem-feedback.bad{background:#fff1f2;border-color:#f1cdd4}.chem-finish{padding:20px;background:#eef7ff;border-radius:14px;margin-top:18px}.chem-finish strong{font-size:20px}.chem-finish p{margin:6px 0 14px}.chem-secondary{display:grid;gap:11px;margin-top:16px}.chem-panel{background:white;border:1px solid #dfe6ee;border-radius:14px;overflow:hidden}.chem-panel summary{padding:18px 20px;cursor:pointer;font-size:16px;font-weight:800;color:#203956;list-style:none}.chem-panel summary::-webkit-details-marker{display:none}.chem-panel summary:after{content:'⌄';float:right;color:#50749e}.chem-panel[open] summary:after{content:'⌃'}.chem-panel summary span{display:inline-block;margin-left:8px;font-size:12px;font-weight:500;color:#7789a2}.chem-panel-body{border-top:1px solid #e9eef6;padding:18px 22px;font-size:14px;line-height:1.7}.chem-panel-body ol{margin-top:4px;padding-left:24px}.chem-panel-body li{margin:5px 0}.chem-worksheet-options{display:flex;flex-wrap:wrap;gap:15px;margin-bottom:15px}.chem-search{display:block;font-weight:700}.chem-search input,.chem-customrow input{display:block;margin:8px 0;padding:13px;border-radius:10px;border:1px solid #cad8e7;width:100%;font-size:15px;color:#264462}.chem-catalog{display:grid;gap:6px;max-height:370px;overflow-y:auto;margin-top:12px}.chem-catalog button{display:flex;gap:8px;justify-content:space-between;text-align:left;padding:10px 12px;background:#f7f9fd;border:1px solid #e3eaf5;border-radius:10px;color:#203e5c;cursor:pointer}.chem-catalog small{color:#8391a2}.chem-customrow{display:flex;gap:8px;align-items:center}.chem-customrow input{flex:1;min-width:0}.chem-customrow button{white-space:nowrap}.chem-panel output{display:block;font-weight:700;padding:8px 0}.chem-copy{margin:32px 0 0;max-width:900px;color:#475d78;line-height:1.75;font-size:15px}.chem-copy h2,.chem-copy h3{color:#163755;margin:18px 0 8px}.chem-note{border-left:3px solid #90a8c8;padding-left:14px;font-size:13px;color:#6d8097}.print-page{display:none}@media(max-width:650px){.chem-intro{margin:12px 0 10px;align-items:start}.chem-intro h1{font-size:26px;margin:5px 0}.chem-intro p{font-size:13px;line-height:1.38}.chem-highscore{display:none}.chem-shell{padding:14px 12px;border-radius:15px}.chem-headrow{align-items:start;gap:6px}.chem-mode{max-width:calc(100vw - 128px);padding-bottom:5px}.chem-mode button{padding:10px 12px;font-size:12px}.chem-minor{font-size:12px;padding:10px 8px}.chem-options{gap:8px;margin:8px 0 14px}.chem-options label{font-size:11px;gap:3px}.chem-options select{padding:8px 5px;max-width:128px;font-size:12px}.chem-count-label{display:none!important}.chem-question{padding:12px 0 12px}.chem-species{padding:4px;gap:3px}.chem-coefficient{width:37px;grid-template-rows:25px 37px 25px}.chem-coefficient input{font-size:17px}.chem-molecule{font-size:21px}.chem-equation{gap:5px}.chem-sep{font-size:17px}.chem-arrow{font-size:23px}.chem-bar{grid-template-columns:37px 1fr 29px}.chem-atomrow{grid-template-columns:26px minmax(0,1fr) 32px;gap:5px}.chem-controls button{padding:11px 12px;font-size:13px;min-height:41px}.chem-controls .chem-primary{flex:1 1 100%}.chem-panel summary{padding:15px;font-size:14px}.chem-panel summary span{display:block;margin-left:0;margin-top:3px}.chem-panel-body{padding:15px}.chem-customrow{display:block}.chem-customrow .chem-primary{width:100%}}
@media print{body{background:white!important}body>header,body>main{display:none!important}.print-page:not([hidden]){display:block!important;margin:0;padding:0;color:black;font-family:Arial,sans-serif}.print-title{font-size:20pt;margin:0 0 12pt}.print-meta{font-size:10pt;margin-bottom:14pt}.print-item{break-inside:avoid;padding:7pt 0;font-size:12pt}.print-answerpage{break-before:page}.print-answerpage h2{font-size:18pt}.print-printformula sub{font-size:65%}@page{size:A4;margin:15mm}}

.chem-atom-actions{display:flex;align-items:center;gap:8px}.chem-atom-actions .chem-minor{font-size:12px;min-height:32px;padding:6px 10px}.chem-dots{display:flex;gap:3px;flex-wrap:wrap;align-items:center;min-height:19px}.chem-dot{display:inline-grid;place-items:center;width:18px;height:18px;border-radius:50%;font-size:8px;color:white;background:#3d81c6;font-weight:800}.chem-bar.product .chem-dot{background:#d58f28}.chem-atomrow.matched .chem-dot{background:#209d7b}.chem-extra{font-weight:800;font-size:11px;color:#455e7a}.chem-bar.tiles{grid-template-columns:48px minmax(0,1fr) 37px}.chem-bar.tiles .chem-dots{overflow:visible}@media(max-width:650px){.chem-atom-title{flex-wrap:wrap}.chem-atom-actions{gap:4px}.chem-atom-actions .chem-minor{font-size:11px;padding:5px 7px}.chem-bar.tiles{grid-template-columns:37px minmax(0,1fr) 29px}.chem-dot{width:16px;height:16px;font-size:7px}}
