/* Scoped node editor: neutral controls, typed sockets, unbounded camera. */
.node-editor{border:1px solid #d8d8d8;border-radius:12px;background:#fff;margin:20px 0;overflow:hidden;color:#292929}.node-editor *{box-sizing:border-box}.editor-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:25px 26px}.editor-heading h2{margin:5px 0;font-size:24px}.editor-heading p{margin:0;color:#666;font-size:13px}.editor-eyebrow{font-size:10px;font-weight:600;letter-spacing:2px;color:#777}.node-editor .actions{display:flex;align-items:center;gap:6px;flex-wrap:wrap}.node-editor button,.node-editor a.button{font:inherit;font-size:12px;line-height:1.3;border:1px solid #cecece;border-radius:5px;background:#fff;color:#292929;padding:8px 10px;cursor:pointer;text-decoration:none}.node-editor button:hover:not(:disabled){background:#f1f1f1;border-color:#999}.node-editor button:focus-visible,.node-editor a:focus-visible{outline:2px solid #517bba;outline-offset:3px}.node-editor button:disabled{opacity:.48;cursor:not-allowed}.node-editor button.primary{background:#292929;color:white;border-color:#292929}.node-editor button.primary:hover:not(:disabled){background:#444}.node-editor .badge{background:#eee;border-radius:4px;font-size:11px;padding:4px 6px;white-space:nowrap}.node-editor .online{background:#e9f2ec;color:#345441}.graph-toolbar{display:flex;gap:12px;align-items:center;justify-content:space-between;padding:10px 18px;border-top:1px solid #e4e4e4;background:#fafafa;flex-wrap:wrap}.graph-toolbar.secondary{padding-top:6px;padding-bottom:6px;background:#fff}.graph-toolbar.secondary button{font-size:11px;padding:6px 9px}.graph-toolbar #graph-zoom{min-width:40px;text-align:center;font-size:11px;color:#777}.graph-message{margin:0;padding:12px 24px;font-size:13px;background:#edf4ee;border-top:1px solid #dce9df}.graph-message.error{background:#fff1ed;color:#8b3b2c}.graph-help{padding:18px 24px;font-size:13px;border-top:1px solid #ddd;background:#fafafa}.graph-help p{margin:10px 0;max-width:980px}.graph-frame{height:760px;min-height:420px;position:relative;overflow:hidden;background-color:#f3f3f2;background-image:radial-gradient(circle,#c5c7c6 1px,transparent 1px);background-size:24px 24px;touch-action:none;outline:none;isolation:isolate}.graph-frame:focus-visible{box-shadow:inset 0 0 0 2px #879ebc}.graph-frame.panning,.graph-frame.panning *{cursor:grabbing!important;user-select:none!important}.graph-board{position:absolute;left:0;top:0;width:1px;height:1px;transform-origin:0 0}.graph-wires{position:absolute;left:0;top:0;width:1px;height:1px;overflow:visible;pointer-events:none;z-index:0}.graph-wire{fill:none;stroke:#99a4a5;stroke-width:3;pointer-events:stroke;cursor:pointer;stroke-linecap:round}.graph-wire.text{stroke:#8999bc}.graph-wire.selected{stroke:#345fc0;stroke-width:5}.graph-wire.pending{stroke:#555;stroke-dasharray:7 5;pointer-events:none}.graph-nodes{position:absolute;left:0;top:0}.graph-node{position:absolute;width:340px;background:#fff;border:1px solid #d1d1d1;border-radius:10px;box-shadow:0 3px 12px #00000008;z-index:1}.graph-node.selected{outline:2px solid #687f9f;outline-offset:2px;z-index:2}.graph-node-heading{height:44px;padding:13px 15px;background:#fafafa;border-radius:10px 10px 0 0;border-bottom:1px solid #ececec;display:flex;justify-content:space-between;align-items:center;cursor:grab;user-select:none;font-size:13px;touch-action:none}.graph-node-heading span{color:#999}.graph-body{padding:12px 14px 14px}.graph-body label{display:block;font-size:12px;font-weight:600;margin:10px 0}.graph-body input:not([type="range"]),.graph-body select,.graph-body textarea{display:block;margin:6px 0 0;width:100%;min-width:0;max-width:100%;border:1px solid #ccc;border-radius:4px;padding:8px;font:12px/1.5 system-ui,sans-serif;color:#292929;background:#fff}.graph-body textarea{height:150px;min-height:70px;resize:vertical;font-weight:400}.graph-body input[type="range"]{width:100%;margin:10px 0;accent-color:#555}.graph-body details{border-top:1px solid #e9e9e9;margin-top:13px;padding-top:10px;font-size:12px}.graph-body summary{cursor:pointer}.graph-body .graph-run,.graph-body>button.primary,.graph-result>button.primary{width:100%;margin:7px 0}.graph-two{display:grid;grid-template-columns:1fr 1fr;gap:8px}.graph-two label{min-width:0}.graph-seed{display:flex;align-items:end;gap:7px}.graph-seed label{flex:1}.graph-seed button{margin-bottom:10px}.graph-small{font-size:11px;line-height:1.5;color:#777;overflow-wrap:anywhere;margin:8px 0}.graph-mode{font-size:11px;color:#666;margin-top:9px}.graph-socket{position:relative;display:flex;align-items:center;height:26px;font-size:11px;color:#727979}.graph-socket.out{justify-content:flex-end}.graph-socket.in .graph-port{left:-22px}.graph-socket.out .graph-port{right:-22px}.node-editor .graph-port{position:absolute;width:16px;height:16px;border:3px solid #fff;border-radius:50%;padding:0;background:#98a5a2;box-shadow:0 0 0 1px #9ba6a3;cursor:crosshair}.node-editor .text .graph-port{background:#8a99bb;box-shadow:0 0 0 1px #8a99bb}.node-editor .graph-port:hover,.node-editor .graph-port.connecting{background:#343e4c;transform:scale(1.3)}.node-editor .graph-port.connected{border-width:2px;background:#536b66}.node-editor .text .graph-port.connected{background:#526994}.graph-placeholder{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:10px;text-align:center;min-height:130px;background:#f7f7f7;border:1px dashed #ddd;border-radius:5px;color:#898989;font-size:28px;padding:20px;margin:10px 0}.graph-placeholder span{font-size:13px}.graph-placeholder small{font-size:11px;overflow-wrap:anywhere}.node-editor button.graph-picture{display:block;padding:0;border:0;background:#f6f6f6;width:100%;margin:10px 0;border-radius:5px;overflow:hidden;cursor:zoom-in}.graph-picture img{display:block;width:100%;max-height:400px;object-fit:contain}.graph-result-title{font-size:12px;display:flex;justify-content:space-between;gap:8px;align-items:center;overflow-wrap:anywhere;margin:8px 0}.graph-result a.button{display:block;text-align:center;margin-top:8px}.graph-compare-images{position:relative;overflow:hidden;background:#ececec;margin-top:10px}.graph-compare-images>img,.graph-compare-a,.graph-compare-a img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain}.graph-compare-a{background:#ececec}.compare-a-label,.compare-b-label{position:absolute;top:8px;padding:3px 6px;background:#ffffffc9;font-size:11px}.compare-a-label{left:8px}.compare-b-label{right:8px}.type-note{background:#fffdf3}.type-note .graph-node-heading{background:#f8f6ea}.type-note textarea{background:transparent;border-color:#e2dfd1;min-height:180px}.graph-marquee{position:absolute;background:#6b84a522;border:1px solid #718eb5;pointer-events:none;z-index:5}.graph-hint{position:absolute;bottom:12px;left:16px;pointer-events:none;background:#ffffffdb;color:#888;font-size:11px;padding:7px 9px;border-radius:5px;z-index:3}.graph-footer{display:flex;justify-content:space-between;gap:12px;padding:10px 18px;font-size:11px;color:#777;border-top:1px solid #ddd}.graph-history{padding:14px 18px;border-top:1px solid #e1e1e1;font-size:13px}.graph-history summary{cursor:pointer}.graph-gallery{display:flex;gap:10px;overflow:auto;padding-top:14px}.node-editor .graph-gallery-item{flex:0 0 130px;text-align:left;min-width:0}.graph-gallery-item img{width:100%;height:100px;object-fit:cover;display:block;border-radius:3px}.graph-gallery-item span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-top:5px;font-size:10px}.graph-gallery-item small{display:block;margin-top:6px;color:#777;font-size:10px}.graph-lightbox{border:1px solid #ddd;border-radius:10px;padding:14px;max-width:95vw;max-height:95vh}.graph-lightbox::backdrop{background:#0009}.graph-lightbox img{display:block;max-width:88vw;max-height:80vh;object-fit:contain;margin-top:10px}.node-editor:fullscreen{margin:0;border:0;border-radius:0;overflow:auto;display:flex;flex-direction:column}.node-editor:fullscreen .graph-frame{height:auto;flex:1;min-height:400px}.node-editor:fullscreen .graph-history{max-height:200px;overflow:auto}.legacy-runs{margin-top:20px}.legacy-runs>summary{font-weight:600;cursor:pointer;padding:14px;border:1px solid #ddd;border-radius:6px}.node-editor [hidden]{display:none!important}@media(max-width:760px){.editor-heading{padding:18px;flex-direction:column;align-items:flex-start}.graph-frame{height:650px}.graph-hint{display:none}.graph-footer{flex-direction:column}.graph-toolbar{padding:8px 10px}.node-editor .actions{gap:5px}}

/* Web 07 reference sets and anchored mention menu; no inline style attributes. */
.graph-socket.references .graph-port{background:#92908d;box-shadow:0 0 0 1px #92908d}.graph-wire.references{stroke:#92908d}.ref-item{border:1px solid #ddd;border-radius:6px;margin:10px 0;padding:9px}.ref-preview{position:relative;background:#f5f5f5;min-height:60px}.ref-preview img{width:100%;height:135px;object-fit:contain;display:block}.ref-preview>span{position:absolute;top:4px;left:4px;padding:2px 7px;background:#fff;border-radius:3px;font-size:11px}.ref-disabled .ref-preview{opacity:.4}.graph-body .ref-enable{display:flex;align-items:center;gap:5px;font-size:11px;margin:0;margin-right:auto}.graph-body .ref-enable input{width:14px;margin:0;padding:0}.ref-item .actions{gap:4px}.ref-item .actions button{padding:5px 8px}.ref-item label{margin:7px 0}.mention-menu{border:1px solid #ccc;border-radius:6px;max-height:220px;overflow:auto;padding:4px;margin-top:7px;background:#fff}.node-editor .mention-menu button{display:flex;width:100%;gap:8px;text-align:left;align-items:center;border:0;background:#fff;padding:7px}.mention-menu button[aria-selected="true"]{background:#edf0f3!important}.mention-menu img{width:40px;height:40px;object-fit:cover;border-radius:4px}.mention-menu span{overflow-wrap:anywhere}.mention-menu small{display:block;font-size:10px}.mention-menu p{font-size:11px;padding:8px;margin:0}.receipt-images{display:flex;gap:6px;flex-wrap:wrap}.receipt-images>div{width:64px}.receipt-images img{width:64px;height:64px;object-fit:contain;background:#f5f5f5}.receipt-images span{font-size:10px;overflow-wrap:anywhere;display:block}.receipt-prompt{white-space:pre-wrap;overflow-wrap:anywhere;font-size:11px;background:#f7f7f7;padding:7px}.reference-receipt{font-size:11px}

/* Web08: native text editing above a matching, non-interactive highlight layer. */
.prompt-editor{position:relative;display:block;margin-top:6px;background:#fff;border-radius:4px;isolation:isolate}
.graph-body .prompt-editor textarea{position:relative;z-index:1;margin:0;background:transparent;overscroll-behavior:contain;tab-size:8;white-space:pre-wrap;overflow-wrap:break-word;word-break:normal}
.prompt-backdrop{position:absolute;inset:1px;overflow:hidden;pointer-events:none;z-index:0;border-radius:3px}
.prompt-ink{display:block;box-sizing:border-box;margin:0;border:0;padding:8px;font:400 12px/1.5 system-ui,sans-serif;letter-spacing:normal;white-space:pre-wrap;overflow-wrap:break-word;word-break:normal;tab-size:8;color:transparent;transform-origin:0 0}
.prompt-ink mark{color:transparent;font:inherit;padding:0;margin:0;border-radius:2px;text-decoration-line:underline;text-decoration-thickness:1px;text-underline-offset:2px}
.prompt-ink .mention-valid{background:#e4edf9;text-decoration-color:#416b9c}
.prompt-ink .mention-invalid{background:#fff0dd;text-decoration-color:#ad6127;text-decoration-style:wavy}
.graph-body textarea,.mention-menu{overscroll-behavior:contain}
