:root { --ink:#17231e; --muted:#728078; --line:#dce4df; --paper:#fbfcf9; --mint:#dcefe5; --teal:#287963; --orange:#f3a15e; --shadow:0 10px 30px rgba(25,52,40,.10); }
.flow-endpoint { position:absolute; top:50%; transform:translateY(-50%); width:58px; height:58px; display:flex; align-items:center; justify-content:center; pointer-events:auto; }.flow-start { left:16px; }.flow-output { right:16px; }.endpoint-port { width:25px; height:25px; border:2px solid var(--teal); border-radius:50%; background:#fff; box-shadow:0 0 0 7px rgba(220,239,229,.75); cursor:crosshair; }.endpoint-out { background:radial-gradient(circle at center, var(--teal) 0 4px, #fff 4.5px); }.endpoint-label { position:absolute; top:42px; width:150px; color:#7d9086; font:500 9px/1.35 'DM Mono',monospace; letter-spacing:.1em; white-space:normal; overflow:visible; text-overflow:clip; text-align:center; overflow-wrap:anywhere; }.flow-start .endpoint-label { left:-46px; }.flow-output .endpoint-label { right:-46px; }.flow-endpoint:has(.endpoint-port:hover) .endpoint-port { border-color:var(--orange); box-shadow:0 0 0 7px rgba(243,161,94,.22); }
* { box-sizing:border-box; } body { margin:0; color:var(--ink); background:var(--paper); font-family:Manrope,system-ui,sans-serif; } button,input { font:inherit; }
.topbar { height:72px; border-bottom:1px solid var(--line); display:flex; align-items:center; justify-content:space-between; padding:0 34px; background:#fff; }
.brand { display:flex; gap:10px; align-items:center; font-weight:800; letter-spacing:.16em; font-size:13px; }.brand-mark { color:var(--orange); font-size:22px; }.topbar-actions,.toolbar-actions { display:flex; align-items:center; gap:14px; }.save-state { color:var(--muted); font:12px 'DM Mono',monospace; }.status-dot { display:inline-block; width:7px; height:7px; border-radius:50%; background:#4fb58d; margin-right:7px; }
.data-version { color:#8b9891; font:10px 'DM Mono',monospace; letter-spacing:.05em; }
.button { cursor:pointer; border:1px solid transparent; border-radius:8px; padding:10px 14px; font-size:12px; font-weight:700; }.button-ghost,.icon-button { background:#fff; border-color:var(--line); color:var(--ink); }.button-ghost:hover,.icon-button:hover { border-color:#a9c8b9; background:#f4faf6; }.button-primary { width:100%; background:var(--ink); color:#fff; padding:14px; text-align:left; }.button-primary:hover { background:#287963; }.button-primary span { font-size:19px; vertical-align:-2px; margin-right:8px; }.import-label { cursor:pointer; }.import-label input { display:none; }.icon-button:disabled { cursor:not-allowed; opacity:.45; background:#f5f8f6; }.icon-button:disabled:hover { border-color:var(--line); background:#f5f8f6; }
.app-shell { height:calc(100vh - 72px); display:grid; grid-template-columns:282px 1fr; }.sidebar { padding:35px 28px 24px; border-right:1px solid var(--line); display:flex; flex-direction:column; }.eyebrow,.section-label { font:500 10px 'DM Mono',monospace; color:#8b9891; letter-spacing:.13em; }.sidebar h1 { font-size:25px; line-height:1.25; letter-spacing:-.05em; margin:20px 0 12px; }.sidebar h1 em { color:var(--teal); font-style:normal; }.intro { color:var(--muted); font-size:12px; line-height:1.75; margin:0 0 25px; }.sidebar-section { border-top:1px solid var(--line); margin-top:32px; padding-top:20px; }.layer-list { margin-top:14px; display:grid; gap:7px; }.layer-item { padding:10px 11px; border-radius:7px; display:flex; justify-content:space-between; color:var(--muted); font-size:12px; cursor:pointer; }.layer-item:hover { background:#f1f7f3; color:var(--ink); }.layer-item.active { background:var(--mint); color:#20604f; font-weight:700; }.layer-item span:last-child { font:11px 'DM Mono',monospace; opacity:.7; }.guide { margin-top:auto; }.guide-row { display:flex; gap:12px; padding:9px 0; color:var(--muted); font-size:11px; }.guide-key { color:var(--teal); font:500 9px 'DM Mono',monospace; min-width:39px; }.sidebar-foot { color:#a6b0aa; font:10px 'DM Mono',monospace; margin-top:25px; }
.board-area { min-width:0; display:flex; flex-direction:column; }.board-toolbar { height:64px; border-bottom:1px solid var(--line); display:flex; align-items:center; justify-content:space-between; padding:0 28px; }.breadcrumbs { font-size:12px; color:var(--muted); }.crumb { cursor:pointer; }.crumb:hover { color:var(--teal); }.crumb.current { color:var(--ink); font-weight:700; }.crumb-sep { margin:0 9px; color:#bdc8c1; }.icon-button { cursor:pointer; border-radius:7px; padding:8px 11px; font-size:12px; }.icon-button span { font-size:11px; margin-left:4px; }.icon-button.danger:hover { color:#a24b3f; border-color:#e7c8c2; background:#fff7f5; }
.board { flex:1; min-height:0; position:relative; overflow:hidden; background-color:#f8fbf8; background-image:radial-gradient(#d9e6df 1px,transparent 1px); background-size:22px 22px; outline:none; }.connections { position:absolute; inset:0; width:100%; height:100%; pointer-events:auto; overflow:visible; }.connection-hit { pointer-events:stroke; cursor:pointer; }.connection { pointer-events:stroke; cursor:pointer; }.connection.selected { stroke:#287963; stroke-width:5; filter:drop-shadow(0 0 3px rgba(40,121,99,.3)); }.link-preview { pointer-events:none; }.edge-handle { fill:#fff; stroke:#287963; stroke-width:3; cursor:grab; pointer-events:all; }.nodes { position:absolute; inset:0; pointer-events:none; }.node { position:absolute; width:176px; min-height:92px; padding:17px 16px 14px; background:#fff; border:1px solid #cedbd4; border-radius:9px; box-shadow:var(--shadow); cursor:grab; user-select:none; pointer-events:auto; }.node:active { cursor:grabbing; }.node:hover { border-color:#77aa94; }.node.selected { border:2px solid var(--teal); padding:16px 15px 13px; }.node-title { font-size:13px; font-weight:800; line-height:1.35; padding-right:8px; }.node-subtitle { margin-top:7px; color:var(--muted); font-size:10px; line-height:1.45; }.node-tag { display:inline-block; margin-bottom:13px; color:var(--teal); font:500 9px 'DM Mono',monospace; text-transform:uppercase; letter-spacing:.08em; }.node-actions { position:absolute; right:7px; top:7px; opacity:0; display:flex; gap:2px; }.node:hover .node-actions,.node.selected .node-actions { opacity:1; }.node-action { border:0; background:transparent; color:#90a39a; cursor:pointer; font-size:14px; line-height:1; padding:2px; }.node-action:hover { color:var(--ink); }.port { position:absolute; top:50%; width:11px; height:11px; border-radius:50%; border:2px solid #fff; background:var(--teal); box-shadow:0 0 0 1px var(--teal); transform:translateY(-50%); cursor:crosshair; z-index:3; }.port.in { left:-6px; background:#fff; }.port.out { right:-6px; }.node.entry { border-left:4px solid var(--orange); }.node.output { border-right:4px solid #5a8fd0; }.node.entry .port.in,.node.output .port.out { display:none; }
.empty-state { position:absolute; inset:0; display:flex; flex-direction:column; justify-content:center; align-items:center; color:var(--muted); gap:7px; pointer-events:none; }.empty-state strong { color:var(--ink); font-size:14px; }.empty-state span { font-size:11px; }.empty-icon { font-size:26px; color:var(--teal); }.hidden { display:none !important; }.selection-rect { position:absolute; z-index:5; border:1px solid var(--teal); background:rgba(220,239,229,.35); pointer-events:none; }.board-footer { height:42px; border-top:1px solid var(--line); display:flex; align-items:center; gap:23px; padding:0 28px; color:var(--muted); font:10px 'DM Mono',monospace; }.legend-dot { display:inline-block; width:7px; height:7px; border-radius:50%; margin-right:6px; background:var(--orange); }.legend-dot.output { background:#5a8fd0; }.footer-note { margin-left:auto; color:#a1aca5; }.toast { position:fixed; right:25px; bottom:25px; background:var(--ink); color:#fff; border-radius:7px; padding:12px 16px; font-size:12px; opacity:0; transform:translateY(10px); transition:.2s; pointer-events:none; }.toast.show { opacity:1; transform:none; }
@media(max-width:760px) { .topbar { padding:0 15px; }.topbar-actions .save-state,.topbar-actions .import-label { display:none; }.app-shell { grid-template-columns:1fr; height:auto; }.sidebar { border-right:0; border-bottom:1px solid var(--line); padding:22px 20px; }.sidebar h1 { margin:12px 0 8px; }.sidebar-section,.guide,.sidebar-foot { display:none; }.board-area { height:calc(100vh - 270px); min-height:500px; }.board-toolbar { padding:0 16px; }.board-footer { padding:0 16px; }.footer-note { display:none; } }
.board-footer .footer-note { margin-left:0; }
.footer-status { margin-left:auto; display:flex; align-items:center; gap:18px; }
.diagram-stats { display:flex; align-items:center; gap:12px; color:#8b9891; font:700 10px 'DM Mono',monospace; }
html, body { height:100%; overflow:hidden; }
.flow-start .endpoint-label { left:4px; }
.flow-output .endpoint-label { right:4px; }
.node.has-detail { background:#dcefe5; border-color:#6eae91; }
.node.has-detail:hover { background:#d0e9da; border-color:#4f9678; }
.node.has-detail::before { content:attr(data-box-count); position:absolute; top:31px; right:8px; width:22px; height:22px; display:grid; place-items:center; border:2px solid #fff; border-radius:50%; background:#287963; color:#fff; box-shadow:0 2px 5px rgba(25,52,40,.18); font:700 10px/1 Manrope,sans-serif; }
.node.has-detail .node-title { padding-right:30px; }
.app-shell { grid-template-columns:1fr; }
.toolbar-actions .button-primary { width:auto; padding:8px 12px; text-align:center; }
.help-modal { width:min(580px,100%); padding:30px; border:1px solid var(--line); border-radius:12px; background:#fff; box-shadow:0 22px 60px rgba(25,52,40,.22); }.help-modal h2 { margin:7px 0 8px; font-size:23px; letter-spacing:-.04em; }.help-intro { margin:0 0 22px; color:var(--muted); font-size:12px; line-height:1.6; }.help-grid { display:grid; grid-template-columns:1fr 1fr; gap:0 24px; border-top:1px solid var(--line); }.help-grid .guide-row { border-bottom:1px solid #edf1ee; padding:11px 0; }.help-close { width:auto; margin-top:23px; text-align:center; }
.about-modal { width:min(360px,100%); padding:30px; border:1px solid var(--line); border-radius:12px; background:#fff; box-shadow:0 22px 60px rgba(25,52,40,.22); }.about-modal h2 { margin:7px 0 24px; font-size:23px; letter-spacing:-.04em; }.about-details { border-top:1px solid var(--line); }.about-details > div { display:flex; flex-direction:column; gap:4px; padding:13px 0; border-bottom:1px solid #edf1ee; font-size:12px; }.about-label { color:var(--muted); font:500 9px 'DM Mono',monospace; text-transform:uppercase; letter-spacing:.1em; }.about-details a { color:var(--teal); text-decoration:none; font-weight:700; }.about-details a:hover { text-decoration:underline; }.about-close { width:auto; margin-top:23px; text-align:center; }
.modal-backdrop { position:fixed; inset:0; z-index:20; display:grid; place-items:center; padding:20px; background:rgba(23,35,30,.28); backdrop-filter:blur(3px); }.editor-modal { width:min(410px,100%); padding:27px; border:1px solid var(--line); border-radius:12px; background:#fff; box-shadow:0 22px 60px rgba(25,52,40,.22); }.editor-modal h2 { margin:7px 0 23px; font-size:21px; letter-spacing:-.04em; }.modal-kicker { color:var(--teal); font:500 10px 'DM Mono',monospace; letter-spacing:.13em; }.editor-modal label { display:block; margin:15px 0; color:var(--ink); font-size:11px; font-weight:700; }.editor-modal input,.editor-modal textarea { display:block; width:100%; margin-top:7px; padding:11px 12px; border:1px solid var(--line); border-radius:7px; outline:none; color:var(--ink); background:#fbfdfb; font-size:12px; resize:vertical; }.editor-modal input:focus,.editor-modal textarea:focus { border-color:var(--teal); box-shadow:0 0 0 3px rgba(40,121,99,.1); }.optional { margin-left:7px; color:var(--muted); font-weight:400; }.modal-actions { display:flex; justify-content:flex-end; gap:9px; margin-top:24px; }.modal-actions .button-primary { width:auto; text-align:center; }
