@charset "UTF-8";
/* A separate arcade screen keeps live competition out of the chemistry workspace. */
.endless-links{display:flex;align-items:center;gap:14px}.endless-entry-footer .high-scores-link{color:#ffc481;text-decoration:none;font-weight:650}
.run-online{display:flex;gap:16px;align-items:center;margin:20px 0;padding-top:16px;border-top:1px solid #ffffff16}.run-online p{font-size:11px;line-height:1.6;color:#96aabd;margin:0}
#leaderboard-dialog{width:min(680px,calc(100vw - 28px));max-height:calc(100dvh - 28px);padding:0;border:1px solid #ffc48165;border-radius:18px;background:#101e2b;box-shadow:0 0 0 5px #ffc48109,0 24px 100px #0009;overflow:auto}
#leaderboard-dialog::backdrop{background:#071018d9;backdrop-filter:blur(8px)}
.arcade-topline{display:flex;align-items:center;justify-content:space-between;padding:13px 22px;border-bottom:1px solid #ffc48120;color:#9aabba;font:10px/1.4 Consolas,"Courier New",monospace;letter-spacing:2px}
.arcade-topline .icon-button{width:30px;height:30px;min-width:30px}.arcade-masthead{padding:23px 24px 19px;text-align:center;background:repeating-linear-gradient(0deg,transparent,transparent 3px,#ffffff02 3px,#ffffff02 4px)}
.arcade-kicker{font:10px/1.5 Consolas,"Courier New",monospace;letter-spacing:3px;color:#97b1c5;margin:0 0 7px}
#leaderboard-title{font:900 clamp(27px,6vw,42px)/1.12 Consolas,"Courier New",monospace;letter-spacing:5px;color:#ffe1a7;margin:0;text-shadow:0 3px #9b612f,0 0 32px #ffc48122;outline:none}
.arcade-record{display:flex;justify-content:center;gap:16px;align-items:center;margin-top:14px;font:12px/1.4 Consolas,"Courier New",monospace;color:#8aa1b4;letter-spacing:2px}.arcade-record strong{font-size:21px;color:#7ce4b3;letter-spacing:4px;font-variant-numeric:tabular-nums}
.arcade-board-status{display:flex;align-items:center;justify-content:space-between;padding:10px 24px;border-top:1px solid #ffffff0a;border-bottom:1px solid #ffffff0a;gap:8px;font:10px/1.5 Consolas,"Courier New",monospace;letter-spacing:1px;color:#7ce4b3}
#leaderboard-live:before{content:'●';margin-right:7px;font-size:8px}.arcade-board-status button{border:0;background:transparent;color:#abc0d0;font:inherit;padding:4px}.arcade-board-status .is-offline{color:#ffc481}
.arcade-table-wrap{max-height:300px;overflow:auto;scrollbar-width:thin;padding:0 24px}.arcade-table-wrap table{width:100%;border-collapse:collapse;table-layout:fixed;font:16px/1.5 Consolas,"Courier New",monospace;font-variant-numeric:tabular-nums}
.arcade-table-wrap th{position:sticky;top:0;background:#101e2b;color:#91a7b9;font:10px/1.5 Consolas,"Courier New",monospace;letter-spacing:1px;padding:13px 0;text-align:left;border-bottom:1px solid #ffffff14;z-index:1}
.arcade-table-wrap th:first-child{width:15%}.arcade-table-wrap th:nth-child(2){width:35%}.arcade-table-wrap th:nth-child(3){width:30%}.arcade-table-wrap th:nth-child(4){width:20%}.arcade-table-wrap td{padding:10px 0;border-bottom:1px solid #ffffff08;white-space:nowrap}.arcade-table-wrap th:nth-child(n+3),.arcade-table-wrap td:nth-child(n+3){text-align:right}
.arcade-table-wrap td:first-child{color:#7e95a9}.arcade-table-wrap td:nth-child(2){font-weight:700;letter-spacing:2px}.arcade-table-wrap td:nth-child(3){color:#b1ebcd;font-weight:700}.arcade-table-wrap td:last-child{font-size:13px;color:#91a7b9}
.arcade-table-wrap .rank-1 td{color:#ffe1a7}.arcade-table-wrap .rank-2 td{color:#c5dbea}.arcade-table-wrap .rank-3 td{color:#d9aa88}.arcade-table-wrap .your-score{background:#7ce4b30a}.arcade-badge{display:inline-block;vertical-align:middle;margin-left:7px;padding:2px 4px;border:1px solid #7ce4b340;border-radius:3px;font:8px/1.3 Consolas,"Courier New",monospace;letter-spacing:.5px;color:#7ce4b3}
.arcade-empty{text-align:center;padding:27px 10px 23px}.arcade-empty>span{display:block;color:#ffc481;font:28px/1 Consolas,"Courier New",monospace;letter-spacing:8px;margin-bottom:16px}.arcade-empty strong{font:700 14px/1.5 Consolas,"Courier New",monospace;letter-spacing:1px;color:#d6e1eb}.arcade-empty p{font-size:12px;line-height:1.7;color:#93aabc;margin:8px 0 0}
.arcade-personal{text-align:center;font:10px/1.6 Consolas,"Courier New",monospace;letter-spacing:1px;color:#7ce4b3;border-top:1px solid #ffffff10;border-bottom:1px solid #ffffff10;padding:12px 16px;margin:0}
.arcade-entry{padding:20px 24px 12px}.arcade-entry>label{display:block;font:10px/1.5 Consolas,"Courier New",monospace;letter-spacing:1.5px;color:#d2deea;margin-bottom:10px}.arcade-entry-row{display:flex;align-items:stretch;gap:10px}
#arcade-initials{width:104px;min-width:0;flex-shrink:0;padding:8px 6px 8px 14px;border:1px solid #ffc4818a;border-radius:5px;background:#09141e;color:#ffe1a7;font:700 26px/1.4 Consolas,"Courier New",monospace;letter-spacing:7px;text-align:center;text-transform:uppercase}
.arcade-entry-row button{padding:10px 16px;font-size:12px;border:1px solid #ffffff25;border-radius:5px;background:#1a2b3b}.arcade-entry-row #arcade-play{margin-left:auto;background:#ffc481;color:#18232c;border-color:#ffc481;font-weight:700}
#arcade-entry-note{font-size:11px;line-height:1.6;color:#8fa6b9;margin:10px 0 0}#arcade-status{font-size:11px;line-height:1.6;color:#7ce4b3;margin:8px 0 0}#arcade-status.notice{color:#ffc481}.arcade-error{color:#ffc481;font-size:12px;line-height:1.6;margin:0;padding:0 24px}.arcade-error:not(:empty){padding-top:12px;padding-bottom:12px}
.arcade-footer{margin:0;padding:13px 24px 18px;text-align:center;font:9px/1.6 Consolas,"Courier New",monospace;letter-spacing:1px;color:#8a9eaf}.arcade-footer span{color:#ffc481;margin:0 8px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:480px){.arcade-topline{padding:10px 16px;font-size:8px}.arcade-masthead{padding:20px 14px 16px}.arcade-board-status{padding:10px 16px;font-size:8px}.arcade-table-wrap{padding:0 16px;max-height:230px}.arcade-table-wrap table{font-size:14px}.arcade-table-wrap th{font-size:8px;letter-spacing:0}.arcade-badge{margin-left:4px;font-size:7px;letter-spacing:0}.arcade-entry{padding:16px}.arcade-entry-row{flex-wrap:wrap;gap:8px}.arcade-entry-row button{font-size:11px;padding:10px 12px}#arcade-initials{width:91px;font-size:24px}.arcade-entry-row #arcade-play{flex:1;white-space:nowrap}.arcade-footer{font-size:8px;padding:0 12px 14px;letter-spacing:0}.arcade-footer span{margin:0 4px}.run-online{align-items:flex-start;flex-direction:column;gap:8px}.endless-links{gap:8px}}
:root{font-family:"Segoe UI",Arial,sans-serif;color:#e4edf5;background:#101c28;--ink:#e4edf5;--muted:#96aabd;--line:#ffffff16;--green:#7ce4b3;--amber:#ffc481;--blue:#97c7ff;font-synthesis:none;color-scheme:dark}
*{box-sizing:border-box}html,body{margin:0;width:100%;height:100%;overflow:hidden}button{font:inherit;color:inherit;cursor:pointer;touch-action:manipulation}button:disabled{opacity:.35;cursor:default}button:focus-visible,a:focus-visible,summary:focus-visible{outline:2px solid var(--amber);outline-offset:4px}[hidden]{display:none!important}.icon-library{position:absolute;width:0;height:0;overflow:hidden}.icon{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}.skip-link{position:fixed;left:15px;top:-80px;z-index:50;background:#e4edf5;color:#101c28;padding:12px;border-radius:8px}.skip-link:focus{top:15px}.universe{position:relative;width:100%;height:100dvh;min-height:320px;overflow:hidden;isolation:isolate;background:radial-gradient(ellipse at 25% 40%,#163d493a,transparent 58%),radial-gradient(ellipse at 75% 65%,#25405a40,transparent 55%),#101c28;outline:none}.universe:before{content:"";position:absolute;inset:0;pointer-events:none;z-index:-1;opacity:.3;background-image:radial-gradient(#9cc5d34d .7px,transparent .7px);background-size:36px 36px}
.hud{height:76px;padding:0 32px;display:flex;align-items:center;justify-content:space-between;gap:16px;position:relative;z-index:3}.brand{display:flex;align-items:center;gap:11px;font-size:19px;letter-spacing:-.5px;color:#c5d5e1}.brand strong{font-weight:650;color:#f1f6fa}.brand-orbit{width:33px;height:33px;border:1px solid #82bea68c;border-radius:50%;display:grid;place-content:center;font-family:Georgia,serif;font-style:italic;color:#97e9c3;position:relative}.brand-orbit:after{content:"";position:absolute;width:5px;height:5px;border-radius:50%;background:#8ce7b9;right:1px;top:5px}.brand-orbit sup{position:absolute;font-size:10px;right:7px;top:3px}.level-picker{background:#ffffff06;border:1px solid #ffffff20;border-radius:24px;padding:12px 18px;display:flex;gap:18px;align-items:center;min-height:43px;position:absolute;left:50%;transform:translateX(-50%)}#level-kicker{font-size:11px;letter-spacing:1.8px}.level-picker:hover{background:#ffffff10}.hud-right{display:flex;align-items:center;gap:24px}.score{display:flex;gap:8px;align-items:center;font-size:13px;color:var(--muted)}.score .icon{color:var(--amber);width:16px}.score strong{font-size:15px;font-weight:600;color:#e5edf4}.icon-button{border:1px solid #ffffff24;background:#ffffff05;border-radius:50%;width:36px;min-width:36px;height:36px;display:grid;place-content:center;font-size:17px}.icon-button:hover{background:#ffffff14}.objective{text-align:center;pointer-events:none;position:absolute;top:86px;left:12px;right:12px}.objective h1{font-size:25px;font-weight:500;letter-spacing:-.6px;margin:0 0 8px}.objective p{font-size:13px;color:var(--muted);margin:0}.field-status{position:absolute;top:162px;left:0;right:0;display:flex;justify-content:center;align-items:center;gap:26px;font-size:11px;color:#96aabd;pointer-events:none}.field-status>span{display:flex;align-items:center;gap:6px}.field-status strong{font-weight:500;color:#d5e5ee}.field-status strong span{font-weight:400;color:#8ca4b6}.status-dot{width:5px;height:5px;border-radius:50%;background:#7ce4b3}.electron-metric{opacity:.8}
.atom-grid{position:absolute;inset:196px 24px 148px;overflow:hidden;touch-action:manipulation}.atom-card{position:absolute;top:0;left:0;width:var(--atom-size,280px);height:calc(var(--atom-size,280px) + 42px);will-change:transform;isolation:isolate;user-select:none}.bohr{display:block;width:100%;height:var(--atom-size,280px);overflow:visible}.shell{fill:none;stroke:#7094ae46;stroke-width:1.1;pointer-events:none}.shell.outer{stroke:#94bbd080;stroke-width:1.5}.stable .shell.outer{stroke:#7ce4b3;stroke-width:2;filter:drop-shadow(0 0 7px #71e6ac80)}.nucleus{fill:#233f51;stroke:#8eafc242;stroke-width:1.2;cursor:grab;touch-action:none;filter:drop-shadow(0 0 16px #5cacc325)}.nucleus:hover{fill:#305367;stroke:#a5d1df90}.nucleus-symbol{fill:#eaf4fa;font-size:31px;font-weight:550;text-anchor:middle;dominant-baseline:central;pointer-events:none}.nucleus-number{font-size:9px;text-anchor:middle;fill:#9fbbce;pointer-events:none}.electron-dot{fill:#c1e9ed;stroke:#172735;stroke-width:2}.electron-hit{fill:transparent;stroke:transparent}.inner-electron .electron-dot{fill:#5e8699}.electron.moved .electron-dot{fill:var(--amber)}.outer-electron{cursor:grab;touch-action:none;outline:none}.outer-electron:hover .electron-dot,.outer-electron:focus-visible .electron-dot{fill:white;stroke:#a6e0e7;filter:drop-shadow(0 0 5px #a6e0e7b0)}.outer-electron:focus-visible .electron-hit{stroke:var(--amber);stroke-width:1.5;stroke-dasharray:3 3}.electron.selected .electron-dot{fill:var(--amber);filter:drop-shadow(0 0 7px #ffcd8f)}.atom-card.is-source .shell.outer{stroke:var(--amber);stroke-width:2}.atom-card.is-target .shell.outer{stroke:white;stroke-dasharray:4 5;stroke-width:2}.charge-badge{position:absolute;top:10%;right:7%;min-width:35px;height:30px;display:grid;place-content:center;border:1px solid #8aa8bb35;background:#152735e8;border-radius:20px;color:#adc0ce;font-size:13px;padding:0 9px;pointer-events:none}.charge-badge.positive{color:#ffc481;border-color:#ffc48155;background:#332c25}.charge-badge.negative{color:#9ecbff;border-color:#9ecbff55;background:#1c3049}.atom-heading{text-align:center;margin-top:-4px;line-height:18px}.atom-name{font-size:14px;font-weight:500;letter-spacing:.3px;color:#d3e2ed}.atom-name small{font-size:10px;color:#7e9bb2;margin-left:4px}.atom-info{text-align:center;font-size:11px;color:#8fa8bb;margin-top:4px;line-height:16px}.outer-count strong{font-weight:500;color:#c2d6e4}.atom-status{margin-left:8px;display:inline-flex;align-items:center;gap:3px;color:var(--green)}.atom-status .icon{width:12px;height:12px}.configuration{display:none}.receive-button{position:absolute;inset:calc(var(--atom-size) / 2 - 30px) 12% auto;height:60px;opacity:0;border:0;border-radius:30px;background:#214455;pointer-events:none;font-size:12px}.receive-button:focus-visible{opacity:1;pointer-events:auto;z-index:3;box-shadow:0 0 35px #101c28}.atom-card.grabbed{z-index:5}.atom-card.grabbed .nucleus{fill:#355b6c;cursor:grabbing}
.bottom-hud{position:absolute;bottom:18px;left:32px;right:32px}.feedback{text-align:center;font-size:12px;line-height:1.5;color:#9ab1c3;min-height:33px;padding:0 8px 12px;max-width:850px;margin:auto}.feedback.notice{color:var(--amber)}.control-row{display:grid;grid-template-columns:1fr auto 1fr;gap:20px;align-items:center}.control-dock{display:flex;align-items:center;gap:6px;padding:6px;border:1px solid #b9d4e523;border-radius:16px;background:#1b2a39d9;box-shadow:0 5px 30px #0002;backdrop-filter:blur(14px)}.tool-button{display:flex;align-items:center;justify-content:center;gap:8px;min-height:40px;background:none;border:0;border-radius:10px;font-size:12px;padding:10px 14px;white-space:nowrap}.tool-button:hover:not(:disabled){background:#ffffff0c}.motion-symbol{font-size:17px;line-height:15px;font-weight:600}.dock-divider{height:20px;width:1px;background:#ffffff17;margin:0 5px}.legend{display:flex;align-items:center;gap:15px;font-size:10px;color:#829cae;flex-wrap:wrap}.legend span{display:flex;align-items:center;gap:6px}.legend i{width:6px;height:6px;border-radius:50%;background:#c1e9ed}.legend i.transferred{background:var(--amber)}.legend i.stable-ring{background:none;border:1px solid var(--green);width:9px;height:9px}.transfer-count{text-align:right;font-size:12px;color:#829cae}.transfer-count strong{font-size:16px;color:#d3e2ed;font-weight:500;margin-right:5px}.field-footnote{display:flex;justify-content:space-between;font-size:9px;color:#698397;letter-spacing:.2px;margin-top:14px}.field-footnote span:last-child{font-size:8px;letter-spacing:1.3px}.drag-electron{position:fixed;left:0;top:0;width:25px;height:25px;margin:-12px;z-index:50;pointer-events:none;border-radius:50%;display:grid;place-content:center;background:var(--amber);color:#20303c;border:2px solid #fff0d3;box-shadow:0 0 25px #ffb46890;font-weight:bold}.dragging,.dragging *,.moving-atom,.moving-atom *{cursor:grabbing!important;user-select:none}
.success-panel{position:absolute;left:50%;top:50%;transform:translate(-50%,-45%);width:min(620px,calc(100% - 32px));max-height:calc(100% - 210px);overflow:auto;z-index:10;padding:25px 28px;background:#142733f5;border:1px solid #7ce4b350;border-radius:20px;box-shadow:0 30px 100px #0009;backdrop-filter:blur(24px);animation:reveal .35s ease}.success-heading{display:flex;justify-content:space-between;gap:15px;align-items:start}.eyebrow{font-size:9px;letter-spacing:1.8px;color:var(--green);font-weight:600}.success-panel h2{font-size:21px;line-height:1.4;font-weight:500;margin:8px 0}.points-pill{font-size:10px;color:var(--green);background:#7ce4b311;border-radius:20px;padding:8px;white-space:nowrap}.success-panel p{font-size:12px;line-height:1.65;color:#a4bdce;margin:8px 0}.final-ions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:13px 0}.success-formula{font-size:37px;letter-spacing:-1px;margin-right:10px}.success-formula sub{font-size:.6em}.final-ion{padding:5px 9px;background:#ffffff09;border:1px solid #ffffff17;border-radius:7px;font-size:14px}.positive{color:var(--amber)}.negative{color:var(--blue)}.success-details{display:grid;grid-template-columns:1fr 1fr;align-items:center;gap:20px;border-top:1px solid var(--line);padding-top:14px;margin-top:16px}.lattice{display:grid;grid-template-columns:repeat(var(--columns),1fr);gap:6px;max-width:290px;margin:0 auto 8px}.lattice-ion{height:26px;border-radius:50%;display:grid;place-content:center;background:#ffc4811c;border:1px solid #ffc48144;color:var(--amber);font-size:9px;animation:attract .8s ease-out both;animation-delay:calc(var(--index)*25ms)}.lattice-ion.negative{background:#97c7ff1c;color:var(--blue);border-color:#97c7ff44}.lattice-wrap small{font-size:8px;color:#7f9bad;line-height:1.5;display:block;text-align:center}.success-actions{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-top:20px}.success-actions>span{font-size:10px;color:#83bfa6}.primary-button{background:#b7f2d5;color:#142b26;border:0;border-radius:10px;padding:13px 17px;min-height:44px;display:inline-flex;align-items:center;justify-content:center;gap:14px;font-size:12px;font-weight:600;cursor:pointer}.primary-button:hover{background:#d5ffe9}.dismiss-result{display:block;margin:18px auto 0;border:0;background:none;color:#94aec0;font-size:11px;padding:8px;text-decoration:underline;text-underline-offset:3px}.result-button{position:absolute;bottom:145px;left:50%;transform:translateX(-50%);border:1px solid #7ce4b344;background:#1d3c36;color:var(--green);border-radius:25px;padding:11px 16px;font-size:12px;display:flex;align-items:center;gap:10px}.confetti{position:absolute;left:var(--x);top:-12px;width:5px;height:9px;background:var(--color);pointer-events:none;animation:confetti 1.5s ease-out both}
 dialog{border:1px solid #7296ab40;border-radius:20px;background:#172735;color:var(--ink);max-width:540px;width:calc(100% - 32px);max-height:calc(100dvh - 40px);padding:25px 28px;box-shadow:0 20px 100px #0008}dialog::backdrop{background:#07111bd1;backdrop-filter:blur(5px)}.dialog-heading{display:flex;align-items:center;justify-content:space-between;gap:15px}.dialog-heading .eyebrow{font-size:8px}.dialog-heading .icon-button{border:0}.dialog-heading h2,dialog h2{font-size:26px;letter-spacing:-.5px;font-weight:500;margin:8px 0 20px}.help-steps{padding:0;list-style:none;counter-reset:steps;display:grid;gap:20px}.help-steps li{counter-increment:steps;position:relative;padding-left:36px}.help-steps li:before{content:counter(steps);position:absolute;left:0;top:0;width:23px;height:23px;border-radius:50%;background:#7ce4b31c;display:grid;place-content:center;color:var(--green);font-size:11px}.help-steps b{display:block;font-size:14px;font-weight:500}.help-steps span{display:block;font-size:12px;line-height:1.65;color:var(--muted);margin-top:6px}.help-note{font-size:12px;line-height:1.65;padding:14px;background:#7ce4b309;border-radius:10px;margin:20px 0;color:#aac4d2}details{font-size:12px;line-height:1.65;color:var(--muted);margin:18px 0 25px}summary{cursor:pointer;color:#d3e2ed}dialog>.primary-button{width:100%}.journey-heading{display:flex;justify-content:space-between;color:var(--muted);font-size:12px}.progress-track{height:3px;background:#ffffff10;border-radius:4px;margin:13px 0 20px;overflow:hidden}.progress-track>div{background:var(--green);height:100%;width:0}.level-list{display:grid;grid-template-columns:1fr 1fr;gap:8px}.level-button{display:flex;align-items:center;gap:10px;padding:12px 10px;background:#ffffff03;border:1px solid #ffffff10;border-radius:10px;text-align:left;min-height:65px}.level-button.active{background:#7ce4b310;border-color:#7ce4b34d}.level-button.done .level-number{color:var(--green)}.level-button:not(:disabled):hover{background:#ffffff0b}.level-number{width:25px;display:grid;place-content:center;color:var(--muted);font-size:12px}.level-number .icon{width:15px;height:15px}.level-copy strong{font-size:11px;font-weight:500;display:block}.level-copy small{font-size:10px;color:var(--muted);margin-top:6px;display:block}.save-status{font-size:10px;color:#7f9bab;margin:20px 0 0}.noscript{position:fixed;inset:30%;padding:20px;background:#172735;z-index:50}
@keyframes reveal{from{opacity:0}to{opacity:1}}@keyframes attract{from{opacity:0;transform:translate(calc(var(--pull)*18px),8px)}to{opacity:1;transform:translate(0,0)}}@keyframes confetti{from{opacity:1}to{top:95%;opacity:0;transform:rotate(220deg)}}@keyframes arrive{from{filter:drop-shadow(0 0 12px #ffc481);opacity:.2}to{filter:none;opacity:1}}.electron.arrived{animation:arrive .45s ease-out}
@media(max-width:850px){.hud{padding:0 20px}.brand{font-size:17px}.hud-right{gap:15px}.bottom-hud{left:20px;right:20px}.control-row{grid-template-columns:1fr auto}.legend{display:none}.control-dock{justify-self:start}.atom-grid{left:12px;right:12px}.objective h1{font-size:23px}}
@media(max-width:520px){.hud{height:63px;padding:0 15px;gap:8px}.brand{font-size:15px;gap:7px}.brand-orbit{width:25px;height:25px;font-size:15px}.brand-orbit sup{font-size:8px;right:4px;top:1px}.brand-orbit:after{width:4px;height:4px;right:0;top:4px}.score{gap:4px;font-size:10px}.score strong{font-size:13px}.score .icon{width:13px}.hud-right{gap:13px}.icon-button{width:30px;min-width:30px;height:30px}.level-picker{top:73px;min-height:32px;padding:6px 12px;gap:10px}#level-kicker{font-size:9px;letter-spacing:1px}.objective{top:119px}.objective h1{font-size:20px;margin-bottom:6px}.objective p{font-size:11px}.field-status{top:181px;gap:15px;font-size:10px}.electron-metric{display:none!important}.atom-grid{inset:208px 8px 137px}.bottom-hud{left:12px;right:12px;bottom:12px}.feedback{font-size:10px;min-height:36px;padding-bottom:10px;max-width:370px}.control-row{gap:6px}.control-dock{padding:4px;gap:0;border-radius:13px}.tool-button{padding:9px 10px;min-height:39px;font-size:11px;gap:6px}.tool-button .icon{width:15px;height:15px}.dock-divider{margin:0 2px}.motion-symbol{font-size:14px}#motion-label{font-size:10px}.transfer-count{font-size:10px;display:flex;flex-direction:column;gap:3px}.transfer-count strong{font-size:14px;margin:0}.field-footnote{font-size:8px;margin-top:12px}.field-footnote span:last-child{font-size:6px;letter-spacing:.8px}.atom-name{font-size:12px}.atom-info{font-size:9px}.atom-status{margin-left:4px}.charge-badge{font-size:11px;min-width:28px;height:25px;right:5%;padding:0 6px}.success-panel{padding:20px;top:49%;max-height:calc(100% - 185px)}.success-panel h2{font-size:18px}.success-heading{gap:8px}.success-details{grid-template-columns:1fr;gap:10px}.success-details p{font-size:11px}.lattice-wrap{max-width:245px;margin:auto}.success-actions{flex-wrap:wrap;gap:10px}.success-actions>.primary-button{width:100%}.success-panel p{font-size:11px}.final-ions{gap:5px}.success-formula{font-size:32px}.points-pill{font-size:9px;padding:7px}.level-list{grid-template-columns:1fr}.level-button{min-height:50px}.level-copy strong{font-size:12px}dialog{padding:20px}.dialog-heading .eyebrow{font-size:7px}.result-button{bottom:130px}.many-atoms .atom-status{font-size:0}.many-atoms .atom-status .icon{width:11px;height:11px}}
@media(max-height:650px) and (min-width:600px){.hud{height:55px}.objective{top:57px}.objective h1{font-size:20px;margin-bottom:5px}.objective p{font-size:11px}.field-status{top:113px}.atom-grid{top:138px;bottom:116px}.bottom-hud{bottom:10px}.field-footnote{margin-top:7px}.feedback{min-height:27px;padding-bottom:8px}.success-panel{max-height:calc(100% - 120px);top:48%}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important;scroll-behavior:auto!important}.confetti{display:none}}
.atom-heading{display:flex;justify-content:center;align-items:center;gap:7px;height:22px}.charge-badge{position:static;min-width:25px;height:21px;padding:0 6px;font-size:11px}.atom-info{margin-top:2px}

/* Charge is distinct from stability: warm/cool ions, green stable shells. */
.charge-positive{--ion-color:#ffa08a;--ion-fill:#492f31}
.charge-negative{--ion-color:#8dc6ff;--ion-fill:#203e61}
.charge-halo{fill:none;stroke:none;pointer-events:none}
.charged .charge-halo{fill:var(--ion-color);fill-opacity:.045;stroke:var(--ion-color);stroke-opacity:.35;stroke-width:7;filter:blur(7px)}
.charged .nucleus{fill:var(--ion-fill);stroke:var(--ion-color);stroke-width:2;filter:drop-shadow(0 0 14px var(--ion-color))}
.charged .nucleus-symbol,.nucleus-charge{fill:var(--ion-color)}
.nucleus-charge{font-size:19px;font-weight:750}
.charged:not(.stable) .shell.outer{stroke:var(--ion-color);stroke-opacity:.8}
.charged .atom-heading{height:28px;margin-top:-10px}
.charged .atom-name{color:var(--ion-color)}
.charged .charge-badge{min-width:46px;height:29px;padding:0 9px;font-size:21px;font-weight:750;background:var(--ion-color);color:#142332;border:0;box-shadow:0 0 20px color-mix(in srgb,var(--ion-color) 30%,transparent)}
.charge-changed .charge-halo{animation:charge-flash .85s ease-out}
.charge-changed .charge-badge{animation:charge-pop .45s ease-out}
@keyframes charge-flash{0%{stroke-opacity:1;fill-opacity:.18;stroke-width:15}100%{stroke-opacity:.35;fill-opacity:.045;stroke-width:7}}
@keyframes charge-pop{0%{transform:scale(.7)}55%{transform:scale(1.18)}100%{transform:scale(1)}}
@media(max-width:520px){.charged .charge-badge{font-size:17px;min-width:36px;height:25px;padding:0 7px}.charged .atom-heading{gap:5px}.charged .atom-name{font-size:11px}}

/* Give the atoms most of the window and keep controls along its edges. */
.hud{height:57px}
.objective{top:62px}
.objective h1{font-size:21px;margin-bottom:5px}
.objective p{font-size:11px}
.field-status{top:111px;font-size:10px}
.atom-grid{inset:134px 16px 118px}
.bottom-hud{bottom:12px;left:24px;right:24px}
.field-footnote{margin-top:10px}
.atom-card{z-index:1}
.bond-layer{position:absolute;inset:0;width:100%;height:100%;overflow:visible;pointer-events:none;z-index:0}
.ionic-bond{fill:none;stroke-linecap:round;pointer-events:none}
.bond-aura{stroke-width:15;filter:blur(6px);stroke-opacity:.7}
.bond-light{stroke-width:5;stroke-opacity:.4;filter:blur(1px)}
.bond-core{stroke-width:2;stroke-opacity:.95;animation:bond-glow 2s ease-in-out infinite alternate}
.bond-layer.still .bond-core{animation-play-state:paused}
.legend i.bond-sample{width:17px;height:2px;border-radius:2px;background:linear-gradient(90deg,#ffa08a,#d8f9ff,#8dc6ff);box-shadow:0 0 7px #b4edff}
@keyframes bond-glow{from{stroke-opacity:.65}to{stroke-opacity:1}}

/* A brief fighting-game announcement; the field stays fully interactive. */
.bond-callout{position:absolute;left:50%;top:47%;transform:translate(-50%,-50%);width:min(720px,92%);z-index:8;pointer-events:none;user-select:none;text-align:center}
.bond-callout-impact{position:relative;isolation:isolate;opacity:0;padding:28px 0 24px}
.bond-callout-impact:before{content:"";position:absolute;z-index:-1;inset:-16px -10%;background:radial-gradient(ellipse,#101c28ed 10%,#101c28b0 36%,transparent 70%);pointer-events:none}
.bond-callout-title{display:block;font-family:Impact,"Arial Black",sans-serif;font-size:clamp(30px,6.4vw,84px);font-weight:900;font-style:italic;line-height:1.1;letter-spacing:.025em;white-space:nowrap;color:#ffe4a1;text-shadow:0 2px 0 #9f522c,0 5px 0 #542521,0 0 12px #ffb34c88,0 0 42px #ef762e66}
.bond-callout-caption{display:inline-block;margin-top:17px;padding:9px 18px 0;border-top:1px solid #ffc77980;color:#ffdc9e;font-size:clamp(9px,1.1vw,12px);font-weight:600;letter-spacing:.27em;text-transform:uppercase;text-shadow:0 2px 8px #000}
.bond-callout-count{display:block;margin-bottom:8px;font-family:Impact,"Arial Black",sans-serif;font-size:clamp(64px,10vw,132px);font-weight:900;font-style:italic;line-height:.95;color:#fff0bb;text-shadow:0 3px 0 #a85426,0 7px 0 #592820,0 0 24px #ffb34cb0,0 0 65px #ef762e80}
.bond-callout.combo .bond-callout-title{color:#ffcb79}
.bond-callout.super-combo .bond-callout-count{font-size:clamp(76px,12vw,156px);color:#fff7d8;text-shadow:0 3px 0 #c06032,0 7px 0 #652623,0 0 28px #ffa23c,0 0 85px #ff673ab0}
.bond-callout.super-combo .bond-callout-title{color:#ffac77;text-shadow:0 2px 0 #ad442b,0 5px 0 #542521,0 0 18px #ff8c4099,0 0 52px #ef762e88}
.bond-callout.playing .bond-callout-impact{animation:bond-impact var(--callout-duration,1800ms) both}
@keyframes bond-impact{0%{opacity:0;transform:scale(1.32) translateY(8px);filter:blur(3px)}12%{opacity:1;transform:scale(.97);filter:blur(0)}20%,57%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(1.04) translateY(-22px);filter:blur(2px)}}
@media(max-width:520px){.bond-callout{top:48%}.bond-callout-title{font-size:clamp(28px,8.8vw,46px)}.bond-callout-caption{margin-top:13px;letter-spacing:.16em}}
@media(prefers-reduced-motion:reduce){.bond-callout.playing .bond-callout-impact{opacity:1;animation:none!important}}
@media(max-width:520px){.hud{height:51px}.level-picker{top:55px;min-height:28px;padding:5px 12px}.objective{top:93px}.objective h1{font-size:18px;margin-bottom:4px}.objective p{font-size:10px}.field-status{top:147px}.atom-grid{inset:170px 8px 116px}.bottom-hud{left:12px;right:12px;bottom:10px}.feedback{min-height:31px;padding-bottom:8px}.field-footnote{margin-top:8px}.result-button{bottom:118px}}
@media(max-height:650px) and (min-width:600px){.hud{height:45px}.objective{top:47px}.objective h1{font-size:18px}.field-status{top:92px}.atom-grid{top:115px;bottom:105px}.bottom-hud{bottom:8px}.field-footnote{margin-top:6px}}

/* The opening screen shares the quiet, open space of the atom field. */
button.brand{border:0;padding:0;background:none;text-align:left;border-radius:7px}
button.brand:hover{filter:brightness(1.2)}
@media(min-width:521px) and (max-width:700px){.hud .brand>span:last-child{display:none}}
.change-difficulty{display:flex;align-items:center;justify-content:center;gap:12px;margin:18px auto 0;border:1px solid var(--line);border-radius:10px;padding:11px 18px;background:#ffffff06;font-size:12px}
.change-difficulty:hover{background:#ffffff10}
.random-set-controls{text-align:center;border-top:1px solid var(--line);margin-top:20px;padding-top:18px}
.random-set-controls p{font-size:11px;line-height:1.6;color:var(--muted);margin:10px 0 0}
.new-set-result{display:block;margin:13px auto 0;padding:9px 14px;border:1px solid #b7f2d555;border-radius:9px;background:#b7f2d50a;color:#b7f2d5;font-size:12px}
.splash{position:relative;isolation:isolate;display:grid;place-items:center;width:100%;height:100dvh;overflow:auto;padding:48px 36px;background:radial-gradient(ellipse at 18% 30%,#204e4d55,transparent 50%),radial-gradient(ellipse at 85% 65%,#24385770,transparent 48%),#101c28}
.splash{align-items:safe center}
.splash-content{width:min(1040px,100%);text-align:center;position:relative}
.splash-brand{display:flex;align-items:center;justify-content:center;gap:14px;color:#99b6bb;font-size:10px;letter-spacing:2.8px;margin-bottom:26px}
.splash-brand .brand-orbit{width:36px;height:36px;font-size:22px;letter-spacing:0}
.splash h1{font-size:clamp(36px,5.6vw,74px);font-weight:300;line-height:1.1;letter-spacing:-3.5px;margin:0;color:#c1d2de}
.splash h1 strong{font-weight:600;color:#f0f7fb}
.title-dot{color:var(--green)}
.splash-intro{color:#a1b7c8;font-size:15px;line-height:1.6;margin:19px 0 48px}
.splash h2{font-size:12px;letter-spacing:1.6px;text-transform:uppercase;font-weight:500;color:#c2d1de;margin:0 0 20px}
.difficulty-explainer{font-size:12px;line-height:1.6;color:#96aabd;margin:-9px 0 22px}
.difficulty-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;outline:none}
.difficulty-card{--accent:#8de5bc;display:flex;flex-direction:column;position:relative;overflow:hidden;align-items:stretch;text-align:left;padding:22px 24px 20px;border:1px solid #9dc0d32b;border-radius:20px;background:linear-gradient(150deg,#203a4570,#182637c9);box-shadow:0 10px 30px #0000000d;transition:transform .18s,border-color .18s,background .18s}
.difficulty-card[data-difficulty="medium"]{--accent:#a4caff}
.difficulty-card[data-difficulty="challenging"]{--accent:#d4b5ff}
.endless-entry{margin:18px auto 0;max-width:1040px;text-align:left}
.endless-card{display:flex;align-items:center;gap:18px;width:100%;padding:18px 24px;border:1px solid #ffc48140;border-radius:16px;background:linear-gradient(110deg,#49342a50,#1b2b3a80);text-align:left}
.endless-card:hover{background:#ffc48112;border-color:#ffc48190}
.endless-symbol{font-size:42px;line-height:1;color:var(--amber)}
.endless-card strong{display:block;font-size:20px;font-weight:550;color:#fff0df}
.endless-card strong+span{display:block;margin-top:5px;font-size:12px;color:#a8bac9;line-height:1.5}
#endless-action{margin-left:auto;white-space:nowrap;color:var(--amber);font-size:12px}
.endless-entry-footer{display:flex;justify-content:space-between;align-items:center;margin-top:9px;padding:0 5px;font-size:11px;color:#9fb5c7}
.endless-entry-footer button{border:0;background:none;font-size:11px;padding:5px;color:#d9c5ac;text-decoration:underline;text-underline-offset:3px}
.run-message{font-size:12px;color:var(--green);line-height:1.6}
.run-rules{font-size:11px;color:var(--muted);line-height:1.7}
.run-actions{display:flex;gap:10px;flex-wrap:wrap;margin:18px 0 25px}
.run-history-heading{display:flex;align-items:center;justify-content:space-between;font-size:14px;font-weight:500;margin:20px 0 12px}
.run-history-heading span{font-size:10px;color:var(--muted)}
.run-history-list{list-style:none;padding:0;margin:0;display:grid;gap:8px}
.run-history-list li{padding:12px;border:1px solid var(--line);border-radius:10px;display:flex;justify-content:space-between;gap:12px;align-items:center}
.run-history-list strong{display:block;color:#ffe0b8;font-size:16px}
.run-history-list time,.run-history-list small{display:block;font-size:10px;color:var(--muted);line-height:1.8}
.run-history-list li>span:last-child{text-align:right}
.run-detail{font-size:11px;line-height:1.7;color:var(--muted)}
.export-runs{margin-top:16px;width:100%}
#endless-title{outline:none}
@media(max-width:600px){.endless-entry{max-width:440px;margin-top:12px}.endless-card{padding:16px;gap:12px;flex-wrap:wrap}.endless-symbol{font-size:32px}.endless-card strong{font-size:20px}.endless-card strong+span{font-size:10px}#endless-action{font-size:11px}.run-actions{flex-direction:column}.run-actions button{width:100%}}
.difficulty-card:hover{transform:translateY(-5px);border-color:var(--accent);background:linear-gradient(150deg,#294450a0,#1b2b40e0)}
.difficulty-card:focus-visible{outline:2px solid var(--accent);outline-offset:5px}
.difficulty-meta{display:flex;justify-content:space-between;gap:10px;font-size:9px;letter-spacing:1.5px;color:var(--accent)}
.difficulty-meta>span{color:#8fa8bb}
.difficulty-preview{width:100%;height:120px;display:block;margin:16px 0 18px;overflow:visible;color:var(--accent)}
.preview-shell{fill:none;stroke:currentColor;stroke-opacity:.45;stroke-width:.9}
.preview-shell.inner{stroke-opacity:.2}
.preview-nucleus{fill:currentColor;fill-opacity:.5;filter:drop-shadow(0 0 7px currentColor)}
.preview-electron{fill:currentColor}
.difficulty-card>strong{font-size:25px;letter-spacing:-.7px;font-weight:550;color:#eaf3fa}
.difficulty-description{color:#9fb5c7;font-size:12px;line-height:1.65;max-width:225px;min-height:40px;margin-top:9px}
.difficulty-bottom{display:flex;justify-content:space-between;align-items:center;gap:8px;border-top:1px solid #ffffff12;padding-top:20px;margin-top:24px}
.difficulty-action{color:var(--accent);font-size:11px;display:flex;align-items:center;gap:9px}
.difficulty-action .icon{width:15px;height:15px}
.difficulty-progress{font-size:10px;color:#8da7bb;white-space:nowrap}
.dense-atoms .atom-name{font-size:10px;letter-spacing:0}
.dense-atoms .atom-info{font-size:9px}
.dense-atoms .atom-status{font-size:0;margin-left:3px}
.dense-atoms .charged .charge-badge{font-size:15px;min-width:26px;height:22px;padding:0 5px}
.dense-atoms .charged .atom-heading{gap:3px}
@media(max-width:520px){.dense-atoms .atom-name{font-size:8px}.dense-atoms .atom-name small{font-size:7px;margin-left:2px}.dense-atoms .atom-info{font-size:8px}.dense-atoms .charge-badge{font-size:9px;min-width:19px;height:17px;padding:0 3px}.dense-atoms .charged .charge-badge{font-size:11px;min-width:20px;height:18px;padding:0 3px}.difficulty-explainer{font-size:10px}}
.splash-note{font-size:11px;color:#a1b6c8;margin:26px 0 0;line-height:1.9}
.splash-note>span{display:block;color:#738da2;font-size:10px}
.splash-orbits{position:absolute;inset:0;overflow:hidden;pointer-events:none;z-index:-1}
.splash-orbits i{position:absolute;display:block;border:1px solid #81b0bb12;border-radius:50%;width:510px;height:510px;top:-290px;left:-120px}
.splash-orbits i:after{content:"";position:absolute;width:6px;height:6px;border-radius:50%;background:#8de5bc66;top:85%;left:85%;box-shadow:0 0 22px #8de5bc55}
.splash-orbits i:nth-child(2){width:630px;height:630px;left:auto;top:auto;right:-370px;bottom:-100px}
.splash-orbits i:nth-child(3){width:750px;height:750px;left:auto;top:auto;right:-430px;bottom:-160px}
@media(max-width:850px) and (min-width:601px){.splash{padding:32px 24px}.difficulty-options{gap:12px}.difficulty-card{padding:18px 16px}.difficulty-bottom{flex-wrap:wrap;gap:12px}.difficulty-meta{font-size:8px;letter-spacing:1px}}
@media(max-width:600px){.splash{padding:28px 20px}.splash-brand{font-size:8px;letter-spacing:2px;gap:10px;margin-bottom:17px}.splash-brand .brand-orbit{width:28px;height:28px;font-size:18px}.splash h1{font-size:clamp(32px,8.2vw,48px);letter-spacing:-1.7px}.splash-intro{font-size:11px;margin:12px 0 27px}.splash h2{font-size:10px;margin-bottom:15px}.difficulty-options{grid-template-columns:1fr;gap:12px;max-width:440px;margin:auto}.difficulty-card{padding:17px 18px 14px;border-radius:16px}.difficulty-meta{font-size:8px;letter-spacing:1.2px;justify-content:flex-start;gap:14px}.difficulty-preview{position:absolute;right:6px;top:22px;width:104px;height:57px;margin:0;opacity:.65}.difficulty-card>strong{font-size:22px;margin-top:7px;letter-spacing:-.4px}.difficulty-description{font-size:11px;line-height:1.5;min-height:0;max-width:none;margin-top:8px}.difficulty-bottom{padding-top:10px;margin-top:12px}.difficulty-action{font-size:10px}.difficulty-progress{font-size:9px}.splash-note{margin-top:17px;font-size:10px}.splash-note>span{font-size:9px}.difficulty-card:hover{transform:translateY(-2px)}}
@media(max-height:700px) and (min-width:601px){.splash{padding:24px}.splash-brand{margin-bottom:14px}.splash h1{font-size:52px}.splash-intro{margin:12px 0 24px;font-size:13px}.difficulty-preview{height:80px;margin:12px 0}.difficulty-card{padding:18px}.difficulty-card>strong{font-size:23px}.difficulty-bottom{padding-top:14px;margin-top:14px}.splash-note{margin-top:18px}}
@media(max-height:900px) and (min-width:601px){.splash{padding:24px}.splash-brand{margin-bottom:14px}.splash h1{font-size:52px}.splash-intro{margin:12px 0 24px;font-size:13px}.difficulty-preview{height:80px;margin:12px 0}.difficulty-card{padding:18px}.difficulty-bottom{padding-top:14px;margin-top:14px}.endless-card{padding:14px 20px}.splash-note{margin-top:14px}}

/* Personal times stay in the existing status row, leaving the field open. */
.field-status{gap:20px}
.time-metric{font-size:11px}
.time-metric strong{font-size:12px;font-variant-numeric:tabular-nums;font-family:Consolas,"Courier New",monospace;min-width:8ch}
#attempt-time{color:#e5edf4}
#best-time{color:var(--amber)}
.level-copy .level-time{font-size:9px;color:#a1b6c8;margin-top:8px;line-height:1.6}
.level-time b{font-variant-numeric:tabular-nums;font-weight:500;color:var(--amber)}
.level-time span{display:block;color:#7e99ae}
#success-heading{outline:none}
.result-timing{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin:16px 0;padding:16px 18px;border:1px solid #9ac6dd26;background:#ffffff04;border-radius:12px}
.result-timing>div{display:flex;flex-direction:column;gap:6px}
.result-timing>div+div{border-left:1px solid #ffffff18;padding-left:18px}
.result-timing span{text-transform:uppercase;font-size:9px;letter-spacing:1.4px;color:#93afc2}
.result-timing strong{font-size:28px;font-weight:600;letter-spacing:-.6px;font-variant-numeric:tabular-nums;color:#e6f3fb}
.result-timing>div+div strong{color:var(--amber)}
.record-time{border-color:#ffc48155;background:#ffc48107}
.record-banner{text-align:center;margin:18px 0 6px;animation:record-reveal .5s ease-out both}
.record-banner strong{display:block;font-family:Impact,"Arial Black",sans-serif;font-size:36px;letter-spacing:1px;color:#ffe4a1;text-shadow:0 2px 0 #7d432b,0 0 22px #ffb34c66}
.record-banner span{display:block;margin-top:7px;font-size:11px;color:#e4c79c}
.success-panel .first-time-note{font-size:10px;color:#93bfaf;text-align:center;margin-top:-8px}
.success-actions{display:block;margin:16px 0 22px}
.success-actions>span{display:block;margin-bottom:12px}
.success-buttons{display:flex;justify-content:flex-end;gap:10px}
.retry-button{display:inline-flex;align-items:center;justify-content:center;gap:9px;padding:12px 18px;border:1px solid #aac8da4d;border-radius:10px;background:#ffffff08;font-size:12px;min-height:44px}
.retry-button:hover{background:#ffffff14}
/* Connect the particle model to charge arithmetic and chemical notation. */
.atom-card{height:calc(var(--atom-size,280px) + 62px)}
.atom-name-short{display:none}
.compact-atom .atom-name-full{display:none}
.compact-atom .atom-name-short{display:inline}
.compact-atom .atom-heading{gap:3px}
.compact-atom .charge-badge{font-size:14px;min-width:28px;height:22px;padding:0 5px}
.charge-calculation{display:flex;justify-content:center;align-items:center;gap:3px;white-space:nowrap;font-size:11px;line-height:18px;color:#b4cbd9;font-variant-numeric:tabular-nums}
.charge-calculation strong{font-weight:600;color:var(--ink)}
.charge-electrons{border-radius:3px;padding:0 2px}
.electron-count-changed .charge-electrons{color:var(--amber);background:#ffc48120;animation:electron-count-flash 1.6s ease-out}
@keyframes electron-count-flash{from{background:#ffc48170}to{background:#ffc48120}}
.prediction-context,.prediction-note{color:var(--muted);font-size:13px;line-height:1.7}
.prediction-note{font-size:11px;margin:18px 0 0}
.prediction-choices{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:22px 0}
.prediction-choices button{min-height:80px;border:1px solid #97c7ff55;background:#97c7ff0b;border-radius:12px;font-size:27px}
.prediction-choices button:hover{background:#97c7ff20;border-color:var(--blue)}
.prediction-choices span{display:block;font-size:11px;margin-top:5px;color:var(--muted)}
#prediction-title{outline:none;font-size:24px;line-height:1.4}
.success-panel .prediction-reflection{border-left:2px solid var(--amber);padding:8px 12px;background:#ffc48109;color:#ead4b9}
.formula-builder{margin:18px 0;padding:18px;border:1px solid #97c7ff45;border-radius:14px;background:#97c7ff08}
.formula-builder h3{margin:8px 0;font-size:19px;font-weight:500}
.formula-inputs{display:flex;flex-wrap:wrap;gap:16px;margin:16px 0}
.formula-inputs label{display:flex;align-items:baseline;gap:5px;font-size:28px}
.formula-inputs select{font:inherit;font-size:17px;color:var(--ink);background:#203b4d;border:1px solid #97c7ff70;border-radius:7px;min-width:52px;height:44px;cursor:pointer}
select:focus-visible{outline:2px solid var(--amber);outline-offset:3px}
.success-panel .formula-equation{font-size:14px;color:#d7eafa;min-height:24px;font-variant-numeric:tabular-nums}
.formula-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}
#formula-feedback{color:var(--green);margin-bottom:0}
#formula-feedback.notice{color:var(--amber)}
#formula-explanation{outline:none}
@media(max-width:520px){.charge-calculation{font-size:10px;gap:2px}.formula-builder{padding:13px}.formula-inputs{gap:12px}.formula-inputs label{font-size:24px}.formula-actions{flex-direction:column}.formula-actions button{width:100%}#prediction-title{font-size:21px}.prediction-choices{gap:7px}}
@media(max-width:520px){.result-button{top:55px;bottom:auto;left:auto;right:8px;transform:none;max-width:52px;min-height:28px;padding:4px;font-size:9px;line-height:1.2;border-radius:7px}.result-button .icon{display:none}}
@keyframes record-reveal{from{opacity:0;transform:scale(1.12)}to{opacity:1;transform:scale(1)}}
@media(max-width:650px){.field-status{gap:12px}.field-status .electron-metric{display:none}}
@media(max-width:520px){.field-status{display:grid;grid-template-columns:repeat(2,max-content);gap:6px 22px}.atom-grid{top:181px}.result-timing{padding:12px;gap:10px}.result-timing>div+div{padding-left:12px}.result-timing strong{font-size:22px}.result-timing span{font-size:8px;letter-spacing:.7px}.record-banner strong{font-size:30px}.record-banner span{font-size:10px}.success-buttons{flex-direction:column}.success-buttons>button{width:100%}}

/* Completion, formula practice, and explanation each get their own view. */
.universe:has(.success-panel:not([hidden])) .atom-grid{opacity:.3}
.universe:has(.success-panel:not([hidden])) .bottom-hud .feedback{visibility:hidden}
.success-panel{width:min(520px,calc(100% - 32px));top:50%;transform:translate(-50%,-50%);max-height:calc(100% - 160px);padding:28px}
.success-panel h2{font-size:24px;line-height:1.35;margin:10px 0 12px}
.success-panel .result-summary{color:var(--green);margin:0 0 24px}
.result-actions{display:flex;gap:10px;margin:22px 0 18px;align-items:stretch}
.result-actions>button{flex:1}
.success-panel details{margin:18px 0 0}
.success-panel summary{padding:10px 0;color:var(--muted);font-size:12px}
.success-panel .result-timing{padding:12px;margin:8px 0}
.success-panel .result-timing strong{font-size:23px}
.success-panel .record-banner{text-align:left;display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:0 0 18px;animation:none}
.success-panel .record-banner strong{font-family:inherit;font-size:11px;letter-spacing:.6px;text-shadow:none;color:var(--amber)}
.success-panel .record-banner span{margin:0;font-size:11px}
.result-footer{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:4px 16px;margin-top:14px;padding-top:12px;border-top:1px solid var(--line)}
.result-link{display:inline-flex;align-items:center;min-height:36px;padding:6px 0;border:0;background:none;color:var(--muted);font-size:11px;text-decoration:underline;text-underline-offset:3px}
.result-link:hover{color:var(--ink)}
.result-back{margin:-8px 0 4px;text-decoration:none}
.success-panel[data-step="learning"] [data-overview-control]{display:none}
.success-panel .formula-builder{border:0;background:none;margin:0;padding:0}
.success-panel .formula-hint{font-size:11px;color:var(--muted)}
.success-panel .formula-inputs{margin:22px 0 10px}
.success-panel .formula-inputs{display:grid;grid-template-columns:repeat(auto-fit,minmax(112px,1fr));gap:12px}
.formula-ion{min-width:0}
.formula-ion>label{display:block;font-size:24px;margin-bottom:8px}
.formula-stepper{display:flex;align-items:center;border:1px solid #97c7ff70;border-radius:9px;overflow:hidden;background:#203b4d}
.formula-stepper button{flex:0 0 32px;min-height:44px;padding:0;border:0;background:transparent;font-size:22px}
.formula-stepper button:hover{background:#97c7ff20}
.formula-stepper input{min-width:0;width:100%;height:44px;padding:0 2px;border:0;border-inline:1px solid #97c7ff30;border-radius:0;background:transparent;color:var(--ink);text-align:center;font:inherit;font-size:20px;appearance:textfield;-moz-appearance:textfield}
.formula-stepper input::-webkit-inner-spin-button,.formula-stepper input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
.formula-stepper input:focus-visible{outline:2px solid var(--amber);outline-offset:-3px}
.formula-stepper button:focus-visible{outline-offset:-3px}
.formula-contribution{display:block;margin-top:7px;color:var(--muted);font-size:11px}
.formula-charge-total{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:18px;padding:12px 15px;border:1px solid var(--line);border-radius:10px;background:#ffffff04;font-size:13px}
.formula-charge-total strong{font-size:26px;font-variant-numeric:tabular-nums}
.formula-charge-total .balanced{color:var(--green)}
.success-panel .formula-actions>.primary-button{width:100%}
.success-panel .formula-actions{margin-top:18px}
#formula-title,#formula-answer-title{outline:none}
#formula-answer-title .success-formula{font-size:38px}
#formula-outcome{color:var(--green)}
#prediction-review{margin-top:16px;font-size:11px}
.success-panel .success-details{grid-template-columns:1fr;padding-top:12px;gap:12px}
@media(max-width:520px){.success-panel{width:calc(100% - 24px);padding:22px 20px;max-height:calc(100dvh - 100px)}.success-panel h2{font-size:22px}.result-actions{flex-direction:column}.result-actions>.primary-button{order:-1}.success-panel .result-summary{margin-bottom:18px}.result-footer{gap:2px 12px}}
