:root{font-family:'DM Sans','Segoe UI',sans-serif;font-size:14px;color:#233c4b;background:#f0f4f6;--mono:'IBM Plex Mono',Consolas,monospace;--line:#dbe5e9;--violet:#7950b5;--green:#28775b;--blue:#507ca4}*{box-sizing:border-box}body{margin:0}button,textarea,select,input{font:inherit}button,a,input,select{outline-offset:3px}button:focus-visible,a:focus-visible,textarea:focus-visible,select:focus-visible,input:focus-visible,[tabindex]:focus-visible{outline:2px solid #a47dde}button{cursor:pointer;border:0;background:none;color:inherit;border-radius:5px;white-space:nowrap}button:hover{background:#eaf0f4}button:disabled{opacity:.4;cursor:default}a{color:inherit;text-decoration:none}textarea{tab-size:2}h1,h2,p,pre{margin:0}h1,h2{font-size:14px;font-weight:600}[hidden]{display:none!important}.topbar{height:67px;padding:0 24px;display:flex;align-items:center;justify-content:space-between;gap:20px;background:#152e3d;color:#d6e5ea}.wordmark{display:flex;gap:7px;align-items:center;font-size:19px;font-weight:550;letter-spacing:-.5px}.wordmark>span:first-child{color:#83e7c3;font-size:30px;font-weight:400}.wordmark-sub{color:#83e7c3;font-weight:400}.languages{display:flex;background:#0c2230;border:1px solid #36505f;padding:4px;border-radius:9px;gap:4px}.languages button{padding:8px 23px;color:#a7becb;font-size:13px}.languages button.active{background:#365963;color:#a5f3d8}.languages button:hover{background:#2b4759}.languages small{font-size:10px;margin-left:4px;opacity:.8}.lab-layout{display:grid;grid-template-columns:minmax(255px,1fr) minmax(320px,1.35fr) minmax(295px,1.1fr);gap:13px;padding:15px;height:calc(100dvh - 67px);min-height:530px}.panel{min-width:0;border:1px solid var(--line);border-radius:10px;background:white;overflow:hidden;display:flex;flex-direction:column;box-shadow:0 2px 4px #263c4b03}.panel-head{min-height:54px;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:0 13px;border-bottom:1px solid var(--line)}.panel-head h1,.panel-head h2{display:flex;align-items:center;gap:9px;white-space:nowrap}.panel-number{border-radius:5px;padding:4px 6px;font:10px var(--mono);letter-spacing:.5px}.green{color:#378369;background:#e8f5ed}.blue{color:#5187b1;background:#eaf3fd}.violet{color:#8564b0;background:#f1eafa}#source-file{min-width:0;max-width:48%;font:11px var(--mono);border:1px solid #d6e4df;border-radius:5px;color:#467b65;padding:6px 4px;background:#f8fcfa}.editor-shell{position:relative;display:flex;flex:1;min-height:0;background:#fcfefd;overflow:hidden}.line-numbers{position:absolute;left:0;top:0;padding:17px 0;width:36px;font:11px/23px var(--mono);color:#abbdb8;text-align:right;pointer-events:none;white-space:pre;user-select:none}.editor-content{position:relative;margin-left:41px;flex:1;min-width:0;overflow:hidden}.editor-content pre,.editor-content textarea{font:12px/23px var(--mono);letter-spacing:0;padding:16px 12px 16px 0;border:0;white-space:pre;tab-size:2;margin:0;box-sizing:border-box}.editor-content pre{position:absolute;left:0;top:0;min-width:100%;color:#35785e;pointer-events:none;will-change:transform}.editor-content textarea{display:block;position:absolute;inset:0;resize:none;width:100%;height:100%;color:transparent;caret-color:#355f50;background:transparent;border:0;overflow:auto;outline:0}.editor-content textarea::selection{background:#bcabe878;color:transparent}.source-highlight{background:#eaddfb;border-radius:3px;box-shadow:inset 0 -2px #a676d1;color:#774fa9}.source-focus{background:#fff0ce;border-radius:3px;box-shadow:inset 0 -1px #d7a344;color:#8d641b}.panel-foot{height:39px;flex-shrink:0;display:flex;align-items:center;gap:8px;border-top:1px solid var(--line);padding:7px 12px;color:#7e929d;font-size:10px;min-width:0;background:#fcfdfe}.panel-foot label{display:flex;align-items:center;gap:3px;white-space:nowrap}.panel-foot input[type=checkbox]{accent-color:#719888;width:12px;height:12px;margin:0 3px 0 0}.panel-foot>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.upload{margin-left:auto;cursor:pointer;color:#5b8978}.panel-foot button{font-size:10px;padding:4px 6px;color:#6d83a0}.graph-origin{display:flex;gap:2px;padding:3px;background:#f0f5f8;border-radius:6px}.graph-origin button{font-size:10px;padding:5px 7px;color:#8c9faa}.graph-origin button.active{color:#487c9d;background:#fff;box-shadow:0 1px 3px #18394212}.graph-toolbar{height:39px;flex-shrink:0;display:flex;align-items:center;gap:12px;padding:0 13px;border-bottom:1px solid #e9eff2;font-size:10px;color:#8097a3}.graph-toolbar label{display:flex;align-items:center;gap:4px;white-space:nowrap}.graph-toolbar input{margin:0;accent-color:#7294ac;width:11px;height:11px}.zoom{margin-left:auto;display:flex;gap:2px;align-items:center}.zoom button{font:13px var(--mono);padding:4px 6px;color:#637f90}.zoom #fit{font:10px 'DM Sans','Segoe UI',sans-serif}.graph-foot{gap:6px}.graph-foot #node-detail{flex:1;min-width:0;font:10px var(--mono)}.selection-key{background:#b58bde;border-radius:3px;width:7px;height:7px;flex-shrink:0}#set-context{color:#ac7b21}.graph-foot #root-context{font:12px var(--mono);border:1px solid #e4cda5;background:#fff5df;color:#a67c30;padding:0 5px}#graph-wrap{flex:1;min-height:0;position:relative;overflow:hidden;background:radial-gradient(#dce8e9 .8px,transparent .8px) 7px 7px/17px 17px #fbfdfd;touch-action:none}#graph{width:100%;height:100%;display:block;user-select:none;cursor:grab}#graph.dragging{cursor:grabbing}#graph-empty{position:absolute;inset:0;display:grid;place-items:center;padding:25px;color:#879bab;font-size:13px;text-align:center;pointer-events:none}.node{cursor:pointer}.node rect{fill:#eef8f2;stroke:#afd7c0;stroke-width:1.2}.node text{font:13px var(--mono);fill:#357b5e;pointer-events:none}.node .node-value{font-size:10px;fill:#7d9b8d}.node.attribute rect{fill:#edf4ff;stroke:#b8cde6;stroke-dasharray:3 2}.node.attribute text{fill:#567dab}.node.text rect{fill:#fff7df;stroke:#e7d498}.node.text text{fill:#a28231}.node.document rect,.node.item rect{fill:#f1f5f8;stroke:#cbd9e2}.node.document text,.node.item text{fill:#668396}.node.selected rect{fill:#eee0ff;stroke:#a070ce;stroke-width:2}.node.selected text{fill:#8354b4}.node.focused rect{stroke:#d1a14f;stroke-width:2.5}.node:hover rect,.node:focus-visible rect{stroke:#547d92;stroke-width:2}.edge{fill:none;stroke:#cbdede;stroke-width:1.4}.edge.selected{stroke:#baa0d7;stroke-width:2}.query-shell{height:165px;flex-shrink:0;background:#fdfbff}.query-shell textarea{width:100%;height:100%;display:block;resize:none;border:0;outline:0;background:transparent;color:#7954a6;padding:17px;font:13px/24px var(--mono);tab-size:2}.query-shell textarea::selection{background:#e2d2f5}body[data-language=xslt] .query-shell,body[data-language=xquery] .query-shell{height:42%;min-height:210px}.run{background:#284b5b;color:#fff;font-size:11px;padding:8px 11px}.run:hover{background:#367287}.query-status{display:flex;align-items:center;justify-content:space-between;gap:7px;border-top:1px solid #f0ebf6;border-bottom:1px solid var(--line);height:34px;flex-shrink:0;padding:0 13px;font-size:10px;color:#8e72b0}.query-status label{display:flex;align-items:center;gap:4px;font-size:10px;color:#8da0ab}.query-status input{width:11px;height:11px;margin:0;accent-color:#8e74b1}#status{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.result-head{height:46px;flex-shrink:0;display:flex;align-items:center;gap:8px;padding:0 13px;background:#fbfcfe;border-bottom:1px solid #e7edf1}.result-head h2{font-size:12px;white-space:nowrap}.result-head>div{display:flex;gap:1px;margin-left:auto;padding:2px;background:#edf3f6;border-radius:5px}.result-head button{font-size:9px;color:#8599a5;padding:5px 6px}.result-head button.active{color:#5d798b;background:#fff;box-shadow:0 1px 2px #29435115}#result-count{display:inline-block;font:10px var(--mono);color:#9272b6;background:#eee7f8;padding:2px 5px;border-radius:4px;margin-left:5px}#copy{font-size:18px;margin-left:0;color:#80939f;padding:0 3px}#result-wrap{flex:1;overflow:auto;min-height:0}#result-items{padding:10px}#result-code{white-space:pre-wrap;overflow-wrap:anywhere;padding:15px;font:12px/23px var(--mono);color:#617c77}#result-preview{height:100%;min-height:240px;width:100%;border:0;display:block}.result-item{display:flex;align-items:flex-start;gap:9px;display:flex;width:100%;text-align:left;border:1px solid #e6dcef;border-radius:6px;background:#fdfaff;padding:9px;margin-bottom:7px}.result-item:hover,.result-item.active{background:#eee2fb;border-color:#cfb7e4}.item-index{font:10px var(--mono);color:#a183bd;background:#f0e8fa;padding:4px 5px;border-radius:4px;flex-shrink:0}.item-info{min-width:0;flex:1}.item-info strong{font:11px var(--mono);font-weight:500;color:#7c5a9f;overflow-wrap:anywhere;display:block}.item-info code{display:block;font:11px/20px var(--mono);color:#8464a0;overflow-wrap:anywhere;white-space:pre-wrap;margin-top:4px;max-height:80px;overflow:hidden}.item-info small{font-size:9px;color:#a28bb7;display:block;margin-top:3px;overflow-wrap:anywhere}.empty{color:#acb4c3;text-align:center;padding:45px 15px;font:14px var(--mono)}.empty strong{display:block;font-size:31px;font-weight:400;margin-bottom:8px}.shortcut{margin-left:auto;font-size:9px}.error #status{color:#b25b68}#error{flex-shrink:0;border-bottom:1px solid #ecced4;padding:10px 12px;background:#fff4f5;color:#b25b68;font:11px/1.7 var(--mono);max-height:110px;overflow:auto;white-space:pre-wrap;overflow-wrap:anywhere}.stale #result-wrap{opacity:.45}.context-ring{stroke:#d9a859;fill:none;stroke-width:2}.graph-foot #node-detail{white-space:nowrap}
@media(min-width:1700px){.lab-layout{grid-template-columns:minmax(330px,1fr) minmax(550px,1.6fr) minmax(400px,1.1fr)}.editor-content pre,.editor-content textarea{font-size:13px}.query-shell textarea{font-size:14px}}
@media(max-width:1050px){.lab-layout{grid-template-columns:minmax(230px,1fr) minmax(290px,1.2fr);grid-template-rows:minmax(500px,65dvh) minmax(360px,1fr);height:auto}.query-panel{grid-column:1/-1;min-height:400px}.query-shell{height:125px}body[data-language=xslt] .query-shell,body[data-language=xquery] .query-shell{height:270px}.graph-panel .panel-head{padding:0 10px}.query-panel #result-wrap{min-height:200px;max-height:450px}.panel-head h1,.panel-head h2{font-size:13px}.editor-content pre,.editor-content textarea{font-size:12px}}
@media(max-width:650px){.topbar{height:61px;padding:0 12px;gap:7px}.wordmark{font-size:14px;gap:4px}.wordmark>span:first-child{font-size:24px}.wordmark-sub{display:none}.languages{gap:1px;padding:3px}.languages button{padding:7px 9px;font-size:11px}.languages small{font-size:8px;margin-left:2px}.lab-layout{height:auto;min-height:0;padding:10px;gap:10px;grid-template-columns:1fr;grid-template-rows:auto}.source-panel{height:360px}.graph-panel{height:450px}.query-panel{min-height:440px;height:600px;grid-column:auto}.panel-head{min-height:49px}.editor-content pre,.editor-content textarea{font-size:12px}.query-shell{height:125px}.query-shell textarea{font-size:12px}body[data-language=xslt] .query-panel,body[data-language=xquery] .query-panel{height:720px}body[data-language=xslt] .query-shell,body[data-language=xquery] .query-shell{height:330px}.graph-toolbar{font-size:11px}.graph-origin button{font-size:11px}.result-head button{font-size:10px}.panel-foot{font-size:10px}.item-info strong{font-size:12px}.item-info code{font-size:12px}.item-info small{font-size:10px}}
.source-attribute{color:#5d86ae}.node .context-ring{fill:none;stroke:#d9a859;stroke-width:2}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}

.topbar{display:grid;grid-template-columns:minmax(max-content,1fr) auto minmax(0,1fr)}.wordmark{justify-self:start}

.workspace-bar{min-height:42px;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:6px 24px;background:#eaf1f3;border-bottom:1px solid var(--line);font-size:11px;color:#587381}.workspace-actions{display:flex;gap:5px}.workspace-actions button{padding:6px 9px;border:1px solid #c5d6dc;background:#f9fcfd;font-size:11px}.workspace-actions button:hover{background:white}.save-error{color:#a04755}.lab-layout{height:calc(100dvh - 110px)}.query-actions{display:flex;gap:6px;align-items:center}#download-query,#download-result{font-size:18px;padding:3px 7px}#download-xml{color:#467b65}.upload{padding:5px 0}@media(max-width:1050px){.lab-layout{height:auto}}@media(max-width:650px){.topbar{display:flex;justify-content:space-between}.workspace-bar{padding:8px 12px;align-items:flex-start;flex-direction:column;gap:7px}.workspace-actions{width:100%}.workspace-actions button{flex:1}.lab-layout{height:auto}}
