:root{font-family:"Trebuchet MS",Arial,sans-serif;color:#173f37;background:#f7faf7;font-synthesis:none;--ink:#173f37;--green:#087969;--lime:#d4ee83;--line:#dce6de;--pink:#fae3e9;--mint:#e3f1ec}*{box-sizing:border-box}body{margin:0}button,select{font:inherit}button{cursor:pointer}button,a,select{-webkit-tap-highlight-color:transparent}button:focus-visible,a:focus-visible,select:focus-visible{outline:3px solid #1375b3;outline-offset:4px}button{color:var(--ink)}.site-header{max-width:1240px;margin:auto;min-height:100px;display:flex;align-items:center;justify-content:space-between;padding:20px 32px}.brand{display:flex;gap:10px;align-items:center;text-decoration:none;color:var(--ink);font-weight:800;font-size:30px;letter-spacing:-1.1px}.brand img{width:30px;height:40px;object-fit:contain;transform:rotate(-10deg)}.brand-dot{color:var(--green)}.help-button{display:flex;align-items:center;gap:9px;border:0;background:transparent;font-size:15px;padding:10px}.question-icon{width:22px;height:22px;border:1.5px solid #75928a;border-radius:50%;display:grid;place-items:center;font-weight:bold}main{max-width:1240px;padding:16px 32px 26px;margin:auto}.intro{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin-bottom:24px}.eyebrow{font-size:12px;letter-spacing:1.6px;font-weight:800;color:#507668}.intro h1{font-family:Georgia,serif;font-weight:400;font-size:30px;letter-spacing:-.75px;margin:8px 0 0}.range-tag{font-size:14px;border:1px solid var(--line);padding:9px 13px;border-radius:24px;white-space:nowrap}.game-layout{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(330px,1fr);gap:22px}.bug-card,.bank-card{border:1px solid var(--line);border-radius:22px;overflow:hidden;background:white}.challenge-head{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:23px 25px 21px}.challenge-head h2,.bank-heading h2{font-size:23px;letter-spacing:-.7px;margin:7px 0 0}.challenge-head h2 span{color:var(--green)}.text-button{background:transparent;border:0;font-size:14px;font-weight:bold;padding:8px 0;white-space:nowrap;color:#356b5d}.text-button span{font-size:23px;line-height:14px;margin-right:4px;vertical-align:middle}.text-button:hover{color:#073b31;text-decoration:underline;text-underline-offset:4px}.garden{background:#eaf4e9;position:relative;padding:18px 0 16px;min-height:453px;isolation:isolate}.garden:before{content:"";position:absolute;inset:0;background-image:radial-gradient(#82a886 1px,transparent 1px);background-size:24px 24px;opacity:.17;z-index:-1}.garden-label{font-size:13px;color:#466d55;text-align:center;display:flex;gap:8px;align-items:center;justify-content:center}.tiny-line{width:14px;height:2px;background:#7b9f64;border-radius:3px}.bug-stage{position:relative;aspect-ratio:600/500;max-width:548px;margin:0 auto;width:100%}.limbs{width:100%;height:100%;position:absolute;inset:0;overflow:visible}.limbs path{fill:none;stroke:#275d49;stroke-width:5;stroke-linecap:round;stroke-linejoin:round}.bug-art{position:absolute;left:33%;top:23%;width:34%;height:54.4%;object-fit:contain;filter:drop-shadow(0 10px 7px #436e421f);user-select:none;pointer-events:none}.bug-number{position:absolute;left:50%;top:59.7%;transform:translate(-50%,-50%);font-weight:900;letter-spacing:-2px;font-size:clamp(32px,4.8vw,53px);color:#133f36;text-shadow:0 1px 0 #ffffff60;pointer-events:none}.socket{position:absolute;width:11%;aspect-ratio:1;border-radius:50%;transform:translate(-50%,-50%);background:#fcfffa;border:2px dashed #7d9e7b;box-shadow:0 3px 0 #52774910;display:grid;place-items:center;font-weight:bold;font-size:clamp(21px,2.5vw,30px);padding:0;transition:background .2s,border-color .2s,box-shadow .2s}.socket:empty:after{content:"+";font-size:25px;font-weight:400;color:#71906c}.socket.filled{background:#fff;border:2px solid #507d69}.socket.selected,.socket.drag-over{border:2px solid var(--green);box-shadow:0 0 0 5px #08796926;background:#f5ffe6}.socket.correct{background:#d3eed7;border:2px solid #438355;color:#285a36}.socket.retry{background:var(--pink);border:2px solid #ba7187;color:#713e4b}.socket.correct:after,.socket.retry:after{position:absolute;right:-1px;bottom:-3px;background:#438355;color:#fff;width:19px;height:19px;border-radius:50%;font-size:12px;display:grid;place-items:center;content:"✓";border:2px solid #eaf4e9}.socket.retry:after{content:"↻";background:#ba7187}.anatomy-note{text-align:center;color:#476b55;font-size:13px;padding:4px 16px 0}.bug-toolbar{padding:13px 25px;display:flex;justify-content:space-between;align-items:center;min-height:60px;font-size:14px;color:#517260}.bank-card{padding:23px 24px 20px;display:flex;flex-direction:column}.bank-heading h2{margin-top:7px}.bank-heading p{font-size:14px;line-height:1.5;color:#5b7168;margin:10px 0 18px;max-width:310px}.number-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px;flex:1}.number-tile{border:1px solid #dce7df;border-radius:9px;background:#fafcf9;min-height:35px;position:relative;font-size:18px;font-weight:bold;padding:5px 0;transition:background .15s,transform .15s;touch-action:manipulation}.number-tile:hover{background:#e4efdf;transform:translateY(-1px)}.number-tile.selected{color:white;background:var(--green);border-color:var(--green);box-shadow:0 0 0 2px #b6ddcb}.number-tile.used{background:#e4eee7;color:#385d4d}.number-tile.used:after{content:"";position:absolute;width:4px;height:4px;background:#62846d;border-radius:50%;right:5px;bottom:5px}.number-tile.used.selected{color:white;background:var(--green)}.number-tile[draggable=true]{cursor:grab}.number-tile:active{cursor:grabbing}.bank-tip{display:flex;gap:8px;align-items:flex-start;color:#60746a;font-size:12px;line-height:1.5;margin-top:17px}.bank-tip>span:first-child{color:#498253;font-size:18px;line-height:1.1}.check-bar{border-radius:18px;border:1px solid var(--line);background:white;display:flex;justify-content:space-between;align-items:center;gap:24px;padding:19px 24px;margin-top:20px}.check-message{display:flex;gap:14px;align-items:center}.check-symbol{display:grid;place-items:center;color:var(--green);width:40px;height:40px;background:#eff5e9;border-radius:50%;flex-shrink:0;font-size:27px}.check-message strong{font-size:16px}.check-message p{font-size:14px;color:#617268;margin:5px 0 0;line-height:1.4}.primary-button{display:inline-flex;justify-content:center;align-items:center;gap:20px;background:var(--green);border:1px solid var(--green);border-radius:12px;color:white;font-weight:bold;font-size:16px;padding:15px 22px;white-space:nowrap;min-height:51px;box-shadow:0 3px 0 #045b4d}.primary-button:hover{background:#06695a}.primary-button:active{transform:translateY(2px);box-shadow:0 1px 0 #045b4d}.check-bar.success{background:#edf7e9;border-color:#acc795}.check-bar.success .check-symbol{background:#cfe6b4}.game-footer{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-top:18px;font-size:13px;color:#6d8176}.game-footer label{display:flex;gap:10px;align-items:center;font-size:13px}.game-footer select{background:white;border:1px solid #d1dfd4;border-radius:7px;padding:5px 8px;font-size:14px;color:var(--ink);min-width:65px}dialog{border:1px solid var(--line);border-radius:24px;padding:35px;max-width:520px;width:calc(100% - 32px);color:var(--ink);box-shadow:0 24px 100px #123c352b}dialog::backdrop{background:#123c3560;backdrop-filter:blur(3px)}dialog h2{font-family:Georgia,serif;font-weight:400;font-size:30px;margin:13px 0 15px}dialog p,dialog li{font-size:16px;line-height:1.55}dialog ol{padding-left:23px}dialog li{padding-left:6px;margin:11px 0}.dialog-close{position:absolute;top:12px;right:14px;width:35px;height:35px;border:0;background:#eff5ef;border-radius:50%;font-size:25px}dialog .help-small{font-size:14px;color:#5b7468}dialog .primary-button{margin-top:7px}.bug-stage.celebrate .bug-art{animation:happy-wiggle .8s ease-in-out}.bug-stage.celebrate .bug-number{animation:number-pop .7s ease-in-out}@keyframes happy-wiggle{0%,100%{transform:rotate(0)}25%{transform:rotate(-6deg)}75%{transform:rotate(6deg)}}@keyframes number-pop{50%{transform:translate(-50%,-50%) scale(1.12)}}@media(min-width:1100px){.number-grid{gap:7px}.number-tile{min-height:35px}}@media(max-width:950px){.site-header{min-height:85px}main{padding-top:8px}.game-layout{grid-template-columns:minmax(0,1.45fr) minmax(280px,1fr);gap:16px}.bank-card{padding:20px 18px}.challenge-head{padding:20px 18px}.challenge-head h2{font-size:20px}.garden{min-height:0}.garden-label{font-size:12px}.intro h1{font-size:26px}.number-grid{gap:5px}.number-tile{min-height:32px}.socket{width:12%}.bank-heading h2{font-size:22px}.anatomy-note{font-size:12px}.bug-number{font-size:44px}.bug-toolbar{padding:13px 18px}.check-bar{padding:17px 20px}}@media(max-width:730px){.site-header{padding:18px 20px;min-height:80px}.brand{font-size:27px}.help-button{font-size:14px;padding-right:0}main{padding:9px 18px 22px}.intro{align-items:center;margin-bottom:20px;gap:12px}.intro h1{font-size:24px;max-width:330px;line-height:1.2}.intro .eyebrow{font-size:10px;letter-spacing:1.15px}.range-tag{font-size:12px;padding:8px 10px}.game-layout{grid-template-columns:1fr;gap:16px}.garden{padding:15px 0 17px}.bug-stage{max-width:490px}.bug-number{font-size:49px}.socket{width:11%;font-size:27px}.bank-card{padding:20px}.bank-heading p{max-width:none;margin:7px 0 15px}.number-grid{grid-template-columns:repeat(10,minmax(0,1fr));gap:6px}.number-tile{min-height:43px;font-size:16px}.bank-tip{font-size:13px;margin-top:13px}.check-bar{flex-wrap:wrap;gap:17px;padding:20px;margin-top:16px}.check-message{align-items:flex-start}.check-bar .primary-button{width:100%}.game-footer{font-size:12px;gap:10px}.game-footer label{font-size:12px;gap:6px}.game-footer>span{max-width:150px}.anatomy-note{font-size:13px}.garden-label{font-size:13px}.challenge-head h2{font-size:22px}.check-message strong{font-size:16px}.eyebrow{font-size:12px}.bug-toolbar{font-size:14px}}@media(max-width:420px){.intro h1{font-size:22px}.range-tag{display:none}.number-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:7px}.number-tile{min-height:41px;font-size:18px}.socket{width:12%;font-size:24px}.bug-number{font-size:41px}.brand{font-size:25px}.brand img{width:27px;height:36px}.challenge-head h2{font-size:21px}.challenge-head{gap:9px}.text-button{font-size:13px}.garden-label{font-size:12px}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
/* Character choices, level controls and the optional rectangle workbench. */
[hidden]{display:none!important}
.header-actions{display:flex;align-items:center;gap:15px}
.choose-bug-button{display:flex;align-items:center;gap:9px;padding:8px 13px;border:1px solid #d0dfd1;border-radius:11px;background:white;font-weight:bold;font-size:14px}
.choose-bug-button img{width:23px;height:30px;object-fit:contain}
.choose-bug-button:hover{background:#eef6e9}
.level-picker{display:grid;grid-template-columns:repeat(5,1fr);gap:10px}
.level-button{border:1px solid #d7e4d9;border-radius:12px;background:white;padding:11px 14px;display:flex;align-items:center;justify-content:space-between;gap:8px;text-align:left}
.level-button strong{font-size:15px}.level-button span{font-size:13px;color:#587467}
.level-button[aria-checked=true]{background:#087969;border-color:#087969;color:white;box-shadow:0 3px 0 #04594d}
.level-button[aria-checked=true] span{color:#e6f3ea}.level-button:hover{border-color:#087969}
.level-description{font-size:14px;color:#5d7868;margin:14px 0 21px}
.bank-heading h2{display:flex;flex-wrap:wrap;gap:9px;align-items:center}.bank-heading h2 span{font-family:'Trebuchet MS',Arial,sans-serif;font-size:13px;font-weight:400;letter-spacing:0;border-radius:20px;background:#eef4eb;padding:5px 8px}
.bank-card{align-self:start;max-height:none}.number-grid{flex:none;max-height:435px;overflow-y:auto;align-content:start;padding:2px 5px 4px 2px;scrollbar-width:thin;scrollbar-color:#8bb699 #f2f7ef}.number-tile{min-height:37px}
.helper-toggle{display:flex;align-items:center;gap:9px;font-size:14px;color:#35614d;margin:0 0 15px;cursor:pointer}
.helper-toggle input{width:18px;height:18px;margin:0;accent-color:#087969;cursor:pointer}
.bug-art{object-fit:fill}.bug-dialog{max-width:650px;padding:30px 34px}.bug-dialog>p{margin-top:0;color:#5b7468}.bug-dialog h3{font-size:16px;margin:23px 0 11px}
.bug-choices{display:grid;grid-template-columns:repeat(3,1fr);gap:13px}
.bug-choice{border:1px solid #d1dfd4;border-radius:15px;background:#f4f8f0;padding:13px 8px;display:flex;flex-direction:column;align-items:center;gap:9px;min-width:0}
.bug-choice img{height:124px;width:100%;object-fit:contain;filter:drop-shadow(0 5px 3px #183c3418)}.bug-choice strong{font-size:16px}
.bug-choice:hover{background:#e9f3df;border-color:#7caa79}.bug-choice[aria-pressed=true]{border:2px solid #087969;padding:12px 7px;background:#e8f3db;box-shadow:0 0 0 3px #08796916}
#scary-choices .bug-choice{background:#eef0fa}#scary-choices .bug-choice[aria-pressed=true]{border-color:#5c4a98;background:#e6e1f6}
body[data-bug-group=scary] .garden{background:#e9edf6}body[data-bug-group=scary] .garden:before{background-image:radial-gradient(#7983a1 1px,transparent 1px)}body[data-bug-group=scary] .limbs path{stroke:#454267}
body[data-bug-group=scary] .socket{border-color:#8784a3}body[data-bug-group=scary] .socket.correct{border-color:#438355}body[data-bug-group=scary] .socket.retry{border-color:#ba7187}
.rectangle-helper{border-top:1px solid #d9e5d7;margin-top:17px;padding-top:13px}.helper-heading{display:flex;justify-content:space-between;align-items:center;gap:10px}.helper-heading strong{font-size:16px}.helper-heading .text-button{font-size:13px}
.array-equation{font-weight:bold;color:#35644e;font-size:15px;margin:8px 0 11px;line-height:1.35}.array-window{position:relative;min-height:70px;height:155px;padding:12px 33px 12px 12px;border:1px solid #d4e2d1;border-radius:12px;background:#f3f8ed;display:flex;align-items:center;justify-content:center;overflow:auto}
#array-svg{width:100%;height:100%;max-height:125px;overflow:visible}.array-handle{position:absolute;right:5px;bottom:7px;width:28px;height:32px;border-radius:7px;border:1px solid #82a584;background:#d6e9c4;color:#315344;cursor:ns-resize;touch-action:none;font-size:20px;font-weight:bold;display:grid;place-items:center;padding:0}
.array-controls{display:flex;align-items:center;gap:14px;margin-top:13px}.array-controls label{font-size:14px;white-space:nowrap;font-weight:bold}.array-controls output{display:inline-block;min-width:20px;color:#087969;text-align:center}.array-controls input{width:100%;accent-color:#087969;cursor:ns-resize}.array-detail{font-size:12px;line-height:1.4;color:#5d7868;margin:8px 0 0}
.bank-card.with-helper .number-grid{max-height:245px}.pattern-question{position:relative;display:flex;align-items:flex-start;gap:15px;margin-top:16px;padding:22px 55px 20px 22px;border:1px solid #d4deaa;background:#f3f8d9;border-radius:17px}.pattern-question h2{font-size:20px;margin:7px 0 8px;letter-spacing:-.4px}.pattern-question p{font-size:15px;line-height:1.55;margin:5px 0}.pattern-question .eyebrow{font-size:11px;letter-spacing:1.1px}.pattern-spark{font-size:28px;color:#607833}#pattern-answer{border-top:1px solid #d4deaa;padding-top:12px;margin-top:10px}
@media(max-width:1050px){.level-button{display:block;padding:10px 13px}.level-button span{display:block;margin-top:4px}.challenge-head .text-button{font-size:12px}.challenge-head h2{font-size:21px}}
@media(max-width:730px){.site-header{flex-wrap:wrap;gap:14px}.header-actions{gap:9px}.choose-bug-button{font-size:13px;padding:6px 9px}.choose-bug-button img{width:20px;height:26px}.help-button{font-size:13px;gap:6px}.question-icon{width:19px;height:19px}.level-picker{gap:6px}.level-button{padding:9px 7px;text-align:center}.level-button strong{font-size:13px}.level-button span{font-size:11px}.level-description{font-size:13px;margin:13px 0 18px}.number-grid{max-height:290px}.bank-card.with-helper .number-grid{max-height:200px}.number-tile{min-height:39px}.bug-choice img{height:105px}.bug-dialog{padding:30px 20px}.bug-choices{gap:9px}.bug-choice strong{font-size:15px}.array-window{height:180px}#array-svg{max-height:150px}.challenge-head .text-button{font-size:12px}.intro{margin-bottom:18px}.game-footer{margin-bottom:6px}.pattern-question{padding-left:18px;gap:11px}.pattern-spark{font-size:22px}}
@media(max-width:480px){.site-header{padding:17px 18px 11px}.brand{width:100%;font-size:27px}.header-actions{width:100%;justify-content:space-between}.choose-bug-button{font-size:14px}.help-button{font-size:14px}.site-header{gap:9px}.level-button span{font-size:10px}.level-button strong{font-size:12px}.bug-choice img{height:91px}.challenge-head h2{font-size:20px}.challenge-head .text-button{max-width:118px;white-space:normal;text-align:right;line-height:1.3}.range-tag{display:none}}
@media(max-width:730px){.level-button span{font-size:12px}.level-button strong{font-size:13px}}
@media(max-width:480px){.level-button{padding:9px 4px}.level-button span{font-size:12px}.level-button strong{font-size:13px}}
.socket.three-digits{font-size:23px}.bug-number.three-digits{font-size:43px}
@media(max-width:730px){.socket{min-width:42px}.socket.three-digits{font-size:20px}.bug-number.three-digits{font-size:35px}}
@media(max-width:360px){.socket{min-width:38px;font-size:22px}.socket.three-digits{font-size:18px}.bug-number.three-digits{font-size:32px}}
.number-tile,.socket{touch-action:none;user-select:none;cursor:grab}.drag-number{position:fixed;z-index:9999;pointer-events:none;transform:translate(-50%,-50%);width:48px;height:48px;border-radius:50%;display:grid;place-items:center;background:#087969;color:white;font-size:24px;font-weight:bold;border:2px solid white;box-shadow:0 6px 18px #164f3840}
/* Earned bugs and the anatomy shown on character choices. */
.header-actions{flex-wrap:wrap;justify-content:flex-end}.collection-button{display:flex;align-items:center;gap:9px;border:1px solid #d0dfd1;background:#eef6e9;border-radius:11px;padding:12px 13px;font-size:14px;font-weight:bold}.collection-button span{display:grid;place-items:center;min-width:24px;height:24px;border-radius:50%;background:#d5e9bd;padding:0 5px;font-size:13px}
.limbs .friendly-tail{stroke-width:7}.limbs .stinger-shape{fill:#454267;stroke:#454267;stroke-width:3}
.choice-art{position:relative;width:100%;padding-bottom:29px}.choice-art img{display:block}.choice-appendage{position:absolute;bottom:0;left:calc(50% - 25px);width:50px;height:40px;overflow:visible}.choice-appendage path{fill:none;stroke:#275d49;stroke-width:3;stroke-linecap:round;stroke-linejoin:round}.choice-appendage circle{fill:#fcfffa;stroke:#507d69;stroke-width:2}.choice-appendage .choice-stinger{fill:#454267;stroke:#454267}.bug-choice>span{font-size:11px;color:#537464;line-height:1.35}.bug-choice{gap:6px}
.collection-dialog,.compare-dialog{max-width:960px;max-height:calc(100vh - 32px);overflow:auto}.collection-intro{color:#5b7468}.collection-tabs{display:flex;gap:8px;flex-wrap:wrap;margin:18px 0}.collection-tabs button{border:1px solid #cbdccd;background:#f4f8f0;border-radius:20px;padding:9px 13px;font-size:14px}.collection-tabs button[aria-selected=true]{background:#087969;color:white;border-color:#087969}.collection-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(175px,1fr));gap:15px}.collection-empty{grid-column:1/-1;border:1px dashed #b2c9ad;border-radius:15px;padding:32px 20px;background:#f4f8ed;text-align:center;color:#5d7868}.collection-card{min-width:0;border:1px solid #d0dfd1;border-radius:15px;background:#f1f7ec;padding:8px 8px 12px;text-align:center}.collection-card:hover{border-color:#087969;background:#e8f3e2}.collection-card>strong,.collection-card-name{display:block}.collection-card-name{font-size:13px;color:#5b7468;margin-top:5px}.collected-stage{max-width:240px;pointer-events:none}.collected-stage .bug-number{font-size:26px;letter-spacing:-1px}.collected-stage .socket{width:11%;min-width:0;font-size:14px;cursor:default}.collected-stage .socket.three-digits{font-size:11px}.collected-stage .socket:after{display:none}.collected-stage[data-bug-group=friendly] .limbs path{stroke:#275d49}.collected-stage[data-bug-group=scary] .limbs path{stroke:#454267}.collected-detail-dialog{max-width:620px;max-height:calc(100vh - 32px);overflow:auto}.collected-detail-dialog .collected-stage{max-width:470px;background:#eaf4e9;border-radius:15px}.collected-detail-dialog .collected-stage[data-bug-group=scary]{background:#e9edf6}.collected-detail-dialog .bug-number{font-size:40px}.collected-detail-dialog .socket{font-size:24px}.collected-detail-dialog .socket.three-digits{font-size:19px}.saved-factors{text-align:center;margin:15px 0 5px}.collected-detail-dialog .help-small{text-align:center}.collection-compare{border-top:1px solid #d7e3d5;padding-top:18px;margin-top:20px;display:flex;align-items:center;justify-content:space-between;gap:20px}.collection-compare p{font-size:14px;color:#5b7468;margin:0}.primary-button:disabled{opacity:.55;cursor:default;box-shadow:none}
.compare-pickers{display:grid;grid-template-columns:1fr 1fr;gap:20px;margin:18px 0 10px}.compare-pickers label{display:flex;align-items:center;gap:10px;font-size:15px;font-weight:bold}.compare-pickers select{padding:8px;border:1px solid #b8cebc;border-radius:9px;background:white;color:var(--ink);max-width:100%;flex:1}.compare-bugs{display:grid;grid-template-columns:1fr 1fr;gap:20px}.compare-bug{padding:10px;background:#eaf4e9;border-radius:16px;text-align:center}.compare-bug .collected-stage{max-width:330px}.compare-bug .socket{font-size:19px}.compare-bug .socket.three-digits{font-size:14px}.compare-bug .bug-number{font-size:32px}.compare-bug h3{font-size:17px;margin:6px 0 3px}.compare-bug .saved-factors{font-size:14px;margin:8px 0}.compare-bug .socket.shared{background:#bcdfc4}.compare-bug .socket.highest{border:3px solid #087969;box-shadow:0 0 0 4px #08796924}.compare-answer{border-top:1px solid #d0dfd1;margin-top:20px;padding-top:17px}.compare-answer h3{font-size:18px;margin:0 0 12px}.compare-numbers{display:flex;gap:8px;flex-wrap:wrap}.compare-number{min-width:44px;min-height:44px;border:1px solid #c8d9cb;border-radius:9px;background:#f4f8f0;padding:8px;font-weight:bold}.compare-number[aria-pressed=true]{border:2px solid #087969;background:#e0efc8}.compare-number.correct{background:#d3eed7;border-color:#438355}.compare-number.retry{background:#fae3e9;border-color:#ba7187}.compare-check-row{display:flex;gap:20px;align-items:center;justify-content:space-between;margin-top:18px}.compare-check-row p{font-size:15px;line-height:1.5;margin:0;color:#466d55}
@media(max-width:730px){.header-actions{justify-content:flex-start;gap:8px}.collection-button{padding:8px 10px}.collection-dialog,.compare-dialog{padding:30px 20px 22px}.collection-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.collection-tabs{gap:6px}.collection-tabs button{font-size:13px;padding:8px 10px}.collected-stage .socket{font-size:12px}.collected-stage .socket.three-digits{font-size:10px}.collection-compare{flex-wrap:wrap;gap:12px}.compare-pickers,.compare-bugs{gap:10px}.compare-pickers label{display:block;font-size:14px}.compare-pickers select{display:block;width:100%;margin-top:7px}.compare-bug{padding:6px}.compare-bug .socket{font-size:14px}.compare-bug .socket.three-digits{font-size:11px}.compare-bug .bug-number{font-size:27px}.compare-bug .saved-factors{font-size:12px}.compare-check-row{flex-wrap:wrap;gap:12px}.compare-check-row .primary-button{width:100%}.collected-detail-dialog .socket{font-size:23px}.bug-dialog{max-height:calc(100vh - 32px);overflow:auto}}
@media(max-width:380px){.collection-tabs button{font-size:12px}.collected-stage .socket{font-size:11px}.compare-bug .socket{font-size:12px}.compare-bug .bug-number{font-size:23px}.compare-bug h3{font-size:15px}.compare-bug .saved-factors{font-size:11px}}
.collection-button{background:#155d4a;border:1px solid #0d4e3d;color:white;padding:12px 18px;font-size:16px;min-height:49px;box-shadow:0 3px 0 #0a3e32}.collection-button:before{content:"▦";color:#d4ee83;font-size:24px;line-height:1}.collection-button:hover{background:#0d4e3d}.collection-button span{background:#d4ee83;color:#173f37;font-size:14px;min-width:27px;height:27px}.bug-toolbar{flex-wrap:wrap;gap:10px}.bug-clear-actions{display:flex;align-items:center;gap:16px;margin-left:auto}.bug-clear-actions .text-button{white-space:normal;text-align:right}.socket.unused{background:#fcfffa;border:2px dashed #7d9e7b}.socket.unused:after{content:"+";position:static;width:auto;height:auto;border:0;background:none;border-radius:0;font-size:25px;color:#71906c}
@media(max-width:730px){.collection-button{font-size:15px;padding:10px 14px}.bug-toolbar{font-size:13px}.bug-clear-actions{gap:14px}}
@media(max-width:480px){.header-actions{gap:10px}.compare-bugs{grid-template-columns:1fr}.compare-bug .collected-stage{max-width:300px}.compare-bug .socket{font-size:20px}.compare-bug .socket.three-digits{font-size:16px}.compare-bug .bug-number{font-size:35px}.compare-bug h3{font-size:18px}.compare-bug .saved-factors{font-size:14px}}
.choice-short{display:none}
.level-picker{grid-template-columns:repeat(4,minmax(0,1fr))}
@media(max-width:480px){.choice-wide{display:none}.choice-short{display:inline}.choose-bug-button{font-size:13px;padding:6px 8px;gap:6px;min-height:49px}.help-button{min-height:44px}}
@media(max-width:360px){.level-button strong{font-size:12px;white-space:nowrap}}
.bank-card .check-bar{flex-direction:column;align-items:stretch;gap:12px;padding:16px 0 0;margin-top:18px;border:0;border-top:1px solid var(--line);border-radius:0}.bank-card .check-bar.success{background:transparent}.bank-card .check-bar .primary-button{order:-1;width:100%}.bank-card .check-symbol{display:none}.bank-card .check-message strong{font-size:14px}.bank-card .check-message p{font-size:13px}.socket.three-digits{font-size:20px}
@media(min-width:731px) and (max-height:900px){.site-header{min-height:70px;padding:12px 32px}main{padding-top:8px}.intro{margin-bottom:12px;align-items:center}.intro .eyebrow{display:none}.intro h1{font-size:27px;margin:0}.level-button{padding:8px 12px}.level-description{margin:8px 0 12px}.challenge-head{padding:14px 20px}.garden{min-height:0;padding-top:9px;padding-bottom:9px}.bug-toolbar{min-height:47px;padding:10px 20px}.bank-card{padding:18px}.bank-heading p{font-size:13px;margin:8px 0 13px}.number-grid{max-height:clamp(130px,calc(100dvh - 485px),330px)}.number-tile{min-height:33px}.bank-tip{margin-top:12px}.bank-card .check-bar{margin-top:13px;padding-top:13px}#bug-stage{max-width:clamp(330px,calc((100dvh - 420px) * var(--stage-ratio)),548px)}}
@media(max-width:360px){.header-actions{flex-wrap:nowrap;gap:7px}.collection-button,.choose-bug-button{flex-shrink:0;white-space:nowrap}.collection-button{font-size:14px;padding:9px;gap:6px}.collection-button span{min-width:22px;height:22px;font-size:12px}.help-button{font-size:0;padding:4px;gap:0;min-width:30px}.help-button .question-icon{font-size:15px}.intro .eyebrow{display:none}.intro{margin-bottom:13px}.level-description{margin:9px 0 13px}}
@media(min-width:731px) and (max-width:900px){.site-header{padding-left:24px;padding-right:24px;gap:14px}.brand{font-size:25px;white-space:nowrap;flex-shrink:0}.header-actions{gap:8px}.collection-button{font-size:14px;padding:10px;gap:6px}.choose-bug-button{font-size:13px;padding:7px 8px;gap:6px}.choose-bug-button img{width:20px;height:27px}.help-button{font-size:13px;padding:7px;gap:5px}.question-icon{width:19px;height:19px}}
/* Keep the desktop game inside the available window height. */
.level-button.level-complete{opacity:.55}.text-button:disabled{cursor:default;opacity:.5}.socket:disabled{cursor:default;pointer-events:none}
@media(min-width:731px){
  body{height:100dvh;display:flex;flex-direction:column}
  .site-header{width:100%;flex-shrink:0}
  main{width:100%;flex:1;min-height:0;display:flex;flex-direction:column;padding-bottom:12px}
  .intro,.level-picker,.level-description,.game-footer{flex-shrink:0}
  .game-layout{flex:1;min-height:0}
  .bug-card{display:flex;flex-direction:column;min-height:0}
  .challenge-head,.bug-toolbar{flex-shrink:0}
  .garden{flex:1;min-height:0;display:flex;flex-direction:column;justify-content:center}
  .garden-label,.anatomy-note{flex-shrink:0}
  #bug-stage{flex-shrink:0;max-width:100%;margin:auto}
  #bug-stage .socket{font-size:var(--circle-font,24px)}
  #bug-stage .socket.three-digits{font-size:var(--circle-three-font,18px)}
  #bug-stage .bug-number{font-size:var(--body-font,42px)}
  .bank-card{align-self:stretch;min-height:0;max-height:100%;overflow-y:auto}
  .bank-heading,.helper-toggle,.bank-tip,.rectangle-helper,.bank-card .check-bar{flex-shrink:0}
  .number-grid{flex:1;min-height:42px;max-height:none!important}
  .game-footer{margin-top:8px}
  .pattern-question{flex-shrink:0;margin-top:8px;padding-top:12px;padding-bottom:12px}
  .pattern-question h2{font-size:17px;margin:3px 0}
  .pattern-question p{font-size:13px;margin:3px 0}
}
/* Both completed bugs and the answer stay visible in the comparison. */
.compare-dialog{height:min(720px,calc(100dvh - 24px));max-height:calc(100dvh - 24px);padding:20px 24px;overflow:hidden}
.compare-dialog[open]{display:flex;flex-direction:column;gap:0}
.compare-dialog>.eyebrow{font-size:10px;flex-shrink:0}
.compare-dialog>h2{font-size:26px;margin:8px 36px 6px 0;flex-shrink:0}
.compare-dialog>p{font-size:14px;line-height:1.4;margin:0;flex-shrink:0}
.compare-pickers{margin:12px 0 8px;flex-shrink:0}
.compare-pickers select{padding:6px 8px}
.compare-bugs{flex:1;min-height:0;grid-template-columns:1fr 1fr;gap:12px}
.compare-bug{display:flex;flex-direction:column;align-items:center;min-height:0;padding:6px 10px;overflow:hidden}
.compare-bug h3{flex-shrink:0;margin:3px 0;font-size:16px}
.compare-bug .collected-stage{flex-shrink:0;margin:auto;max-width:100%}
.compare-bug .socket{font-size:var(--circle-font,16px)}
.compare-bug .socket.three-digits{font-size:var(--circle-three-font,12px)}
.compare-bug .bug-number{font-size:var(--body-font,28px)}
.compare-bug .saved-factors{flex-shrink:0;font-size:13px;line-height:1.4;margin:5px 0 2px}
.compare-answer{flex-shrink:0;margin-top:12px;padding-top:10px}
.compare-answer h3{display:none}
.compare-numbers{gap:6px;max-height:98px;overflow-y:auto;padding:2px}
.compare-number{min-width:42px;min-height:42px;padding:6px}
.compare-check-row{margin-top:10px;gap:12px}
.compare-check-row p{font-size:13px;line-height:1.4}
.compare-check-row .primary-button{min-height:44px;padding:10px 16px;font-size:14px;flex-shrink:0}
@media(max-width:730px){.compare-dialog{padding:18px 16px}.compare-dialog>h2{font-size:23px}.compare-pickers{gap:10px;margin:10px 0 8px}.compare-pickers label{font-size:13px}.compare-pickers select{margin-top:4px}.compare-bug{padding:5px}.compare-bug .saved-factors{font-size:12px}.compare-check-row .primary-button{width:auto}}
@media(max-width:480px){.compare-dialog{width:calc(100% - 16px);height:calc(100dvh - 16px);max-height:calc(100dvh - 16px);padding:16px 12px}.compare-dialog>.eyebrow{display:none}.compare-dialog>h2{font-size:21px;margin-top:4px}.compare-dialog>p{font-size:12px}.compare-bugs{gap:8px}.compare-bug h3{font-size:14px}.compare-bug .saved-factors{font-size:11px}.compare-check-row{flex-direction:column;align-items:stretch;gap:6px}.compare-check-row p{font-size:12px}.compare-check-row .primary-button{width:100%;min-height:42px}.compare-answer{margin-top:8px;padding-top:8px}}
@media(min-width:731px) and (max-height:750px){.intro{display:none}.level-description{font-size:12px;margin:7px 0 10px}.challenge-head{padding:12px 16px}.challenge-head .eyebrow{font-size:10px}.bank-card{padding:14px}.bank-heading>.eyebrow{display:none}.bank-heading p{font-size:12px;margin:7px 0 10px}.bank-card .check-bar{gap:8px}.bank-card .check-message strong{font-size:13px}.bank-card .check-message p{font-size:12px}.bug-toolbar{font-size:12px;padding:8px 16px}.anatomy-note{font-size:12px}.game-footer>span{font-size:12px}}
@media(min-width:731px){.bank-card.with-helper .bank-heading>.eyebrow,.bank-card.with-helper .bank-heading p,.bank-card.with-helper .bank-tip{display:none}.bank-card.with-helper .bank-heading h2{margin:0 0 10px}.bank-card.with-helper .number-grid{flex:none;grid-template-columns:repeat(10,minmax(0,1fr));gap:4px;max-height:76px!important;min-height:0}.bank-card.with-helper .number-tile{font-size:14px;min-height:30px;padding:4px 0}.bank-card.with-helper .rectangle-helper{margin-top:8px;padding-top:8px}.bank-card.with-helper .array-window{min-height:60px;height:clamp(60px,calc(100dvh - 650px),110px);padding:6px 32px 6px 6px}.bank-card.with-helper .helper-heading strong{font-size:14px}.bank-card.with-helper .helper-heading .text-button{padding:3px 0}.bank-card.with-helper .array-equation{font-size:13px;margin:4px 0 6px}.bank-card.with-helper .array-controls{margin-top:6px}.bank-card.with-helper .array-detail{font-size:11px;margin-top:4px}.bank-card.with-helper .check-message strong{display:none}}
body:has(dialog[open]){overflow:hidden}.number-tile:disabled{pointer-events:none;cursor:default}.number-tile:disabled:hover{transform:none}
