:root{--bg:#eef2f7;--panel:#fff;--text:#17243a;--muted:#64748b;--border:#d8e1ec;--blue:#2563eb;--teal:#0d9488;--orange:#d97706;--red:#dc2626;--navy:#16345b;--purple:#7c3aed;--top-cols:minmax(0,1fr) minmax(0,1.35fr) minmax(0,1fr);--bottom-cols:minmax(0,1.2fr) minmax(0,1fr)}*{box-sizing:border-box}body,html{margin:0}body{background:var(--bg);color:var(--text);font:14px/1.4 Arial,Helvetica,sans-serif}h2{font-size:15px;margin:0 0 6px;color:#183b65}button{border:0;border-radius:6px;padding:7px 11px;font-size:12px;font-weight:700;cursor:pointer;background:var(--teal);color:#fff;white-space:nowrap}button.blue{background:var(--blue)}button.orange{background:#e99a19;color:#241700}button.grey{background:#64748b}button.red{background:var(--red)}button:hover{filter:brightness(.93)}button:disabled{opacity:.4;cursor:not-allowed}#toolbar{position:sticky;top:0;z-index:50;display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;padding:7px 14px;background:#fff;border-bottom:2px solid #dce5ef;box-shadow:0 2px 6px rgba(30,50,80,.08)}.brand{display:flex;align-items:center;gap:8px;line-height:1.1;margin-right:4px}.brand-logo{display:flex;align-items:center;justify-content:center}.brand-text{display:flex;flex-direction:column}.brand .eyebrow{color:var(--teal);font-size:9px;font-weight:700;letter-spacing:2px}.brand b{font-size:17px;color:var(--navy)}.scenarios{display:flex;gap:5px;flex-wrap:wrap;flex:1}.scen-btn{background:#e8eef6;color:#334155;font-size:12px;padding:6px 10px}.scen-btn.active{background:var(--navy);color:#fff}#scenSelect{display:none;flex:1;min-width:160px;padding:7px 9px;border-radius:6px;border:1.5px solid #cbd5e1;background:#f8fafc;color:var(--navy);font-weight:700;font-size:12.5px}.actions{display:flex;gap:6px;flex-wrap:wrap;align-items:center}main{max-width:1900px;margin:0 auto;padding:10px;display:flex;flex-direction:column;gap:10px}#topRow{display:grid;gap:10px;grid-template-columns:var(--top-cols);align-items:stretch}.panel{background:var(--panel);border:1px solid var(--border);border-radius:9px;padding:10px 12px;min-width:0;box-shadow:0 2px 5px rgba(30,50,80,.04);display:flex;flex-direction:column}#bottom{display:grid;gap:10px;grid-template-columns:var(--bottom-cols);align-items:start}.code-box{background:#0f172a;color:#e2e8f0;border-radius:7px;padding:8px 0;font:13px/1.58 Consolas,"Courier New",monospace;overflow-x:auto;flex:1}.code-line{display:flex;align-items:center;padding:1px 10px;border-left:4px solid transparent;white-space:pre}.code-line.active{background:rgba(250,204,21,.22);border-left-color:#facc15;color:#fff}.code-line.crash{background:rgba(220,38,38,.35);border-left-color:#ef4444;color:#fecaca}.ln{color:#64748b;width:24px;display:inline-block;user-select:none;text-align:right;margin-right:10px;font-size:11px}.ptr{width:16px;display:inline-block;color:#facc15;font-weight:700}.kw{color:#93c5fd;font-weight:700}.ty{color:#5eead4}.num-lit{color:#fca5a5}.str-lit{color:#fde047}.cmt{color:#94a3b8;font-style:italic}.console-wrap{margin-top:8px}.console{background:#1e293b;color:#a7f3d0;border-radius:6px;padding:7px 9px;font:12px/1.5 Consolas,monospace;min-height:64px;max-height:105px;overflow-y:auto;white-space:pre-wrap}.console .err-out{color:#fca5a5;font-weight:700}.legend{display:flex;gap:12px;flex-wrap:wrap;color:#475569;font-size:11px;margin-top:8px}.legend i{display:inline-block;width:11px;height:11px;border-radius:3px;margin-right:4px;vertical-align:-1px;border:1.5px solid}#workPanel{max-height:660px}#workHead{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin-bottom:6px}#status{flex:1;min-width:140px;background:#ecfdf5;color:#087e65;border-radius:5px;padding:5px 8px;font-size:12px;font-weight:600}#status.err{background:#fef2f2;color:#b91c1c}#workBody{flex:1;overflow-y:auto;padding-right:3px}#workBody.single-mode .step.past{display:none}#workBody.all-mode .step.past{display:block;opacity:.72}.step{border-left:5px solid #cbd5e1;background:#f8fafc;border-radius:6px;padding:8px 10px;margin-bottom:8px}.step.cur{border-color:var(--blue);background:#eff6ff}.step.cur.crash-step{border-color:var(--red);background:#fef2f2}.step h4{margin:0 0 4px;font-size:13px;color:#16345b}.step p{margin:3px 0 6px;color:#334155;font-size:12.5px}.phase-badge,.rule-badge{display:inline-block;font:700 11px Consolas,monospace;padding:2px 7px;border-radius:4px;margin-bottom:5px;background:#dbeafe;color:#1e40af}.phase-compile{background:#dbeafe;color:#1e40af}.phase-runtime{background:#ccfbf1;color:#0f766e}.phase-static{background:#fef3c7;color:#92400e}.phase-err{background:#fee2e2;color:#991b1b}.eye-btn{background:#f1f5f9;border:1px dashed #cbd5e1;color:#475569;padding:4px 8px;border-radius:4px;font-size:11px;cursor:pointer;margin-top:4px;transition:.15s}.eye-btn:hover{background:#e2e8f0;color:#0f172a;border-color:#94a3b8}.ask-wrap{display:none;margin-top:6px}.ask-wrap.show{display:block}.ask{font-size:12px;color:#7c2d12;background:#fffbeb;border-left:3px solid #f59e0b;padding:6px 9px;border-radius:4px;line-height:1.45}.think-btn{display:inline-flex;align-items:center;justify-content:center;background:#fef3c7;border:1px solid #f59e0b;border-radius:12px;padding:0 6px;margin-left:5px;font-size:13px;line-height:1.35;cursor:pointer;vertical-align:middle;transition:transform .12s,background .15s}.think-btn:hover{background:#fde68a;transform:scale(1.12);filter:none}.think-btn.open{background:#f59e0b;color:#fff}.ans-box{display:none;margin-top:6px;padding:6px 9px;background:#fff;border:1px dashed #f59e0b;border-radius:4px;color:#1e293b;font-size:12px;line-height:1.45}.ans-box.show{display:block}.note{background:#eff6ff;border-left:3px solid #3b82f6;border-radius:5px;padding:8px 10px;font-size:12.5px;color:#23446b;margin:6px 0}.next{background:#ecfdf5;border:1px dashed #0d9488;color:#065f55;border-radius:6px;padding:7px 10px;font-size:12.5px;font-weight:700}details.panel-acc{background:var(--panel);border:1px solid var(--border);border-radius:9px;padding:10px 12px;min-width:0;box-shadow:0 2px 5px rgba(30,50,80,.04)}details.panel-acc>summary{list-style:none;cursor:pointer;font-size:15px;font-weight:700;color:#183b65;display:flex;justify-content:space-between;align-items:center}details.panel-acc>summary::-webkit-details-marker{display:none}details.panel-acc>summary::after{content:"▾";font-size:13px;color:#64748b}details.panel-acc[open]>summary{margin-bottom:8px}details.panel-acc:not([open])>summary::after{content:"▸"}table{border-collapse:collapse;width:100%;font-size:12px}td,th{padding:5px 7px;border-bottom:1px solid #e2e8f0;text-align:left}th{background:#f1f5f9;color:#475569}code{background:#f1f5f9;padding:1px 4px;border-radius:3px;font-family:Consolas,monospace;color:#0f172a}footer{text-align:center;color:#64748b;padding:10px;font-size:11px}@media(max-width:960px){.scenarios{display:none}#scenSelect{display:block;max-width:340px}#bottom,#topRow{grid-template-columns:1fr}#workPanel{max-height:none}}@media(max-width:768px){body{padding-bottom:64px}#toolbar{padding:6px 10px;gap:6px}.brand b{font-size:14.5px}.brand .eyebrow{font-size:8px;letter-spacing:1.2px}.scenarios{display:none}#scenSelect{display:block}.actions{position:fixed;bottom:0;left:0;right:0;z-index:60;background:#fff;border-top:2px solid #dce5ef;padding:7px 10px;justify-content:space-between;box-shadow:0 -2px 10px rgba(30,50,80,.12)}.actions button{min-height:38px;padding:7px 10px;font-size:12px}#stAll{display:none}main{padding:7px;gap:8px}.panel{padding:8px 10px}.code-box{font-size:11.5px;line-height:1.42;padding:5px 0}.console{min-height:46px;max-height:80px;font-size:11.5px}}.brand-logo{display:flex;align-items:center;justify-content:center;flex-shrink:0}.brand-logo img,.brand-logo svg{height:30px!important;width:auto!important;max-width:150px!important;display:block}#brandEyebrow{white-space:normal!important;line-height:1.15!important;max-width:220px;display:inline-block}