/* Workflow visual system — Dentaly API documentation palette. */
:root{
 --wf-surface:#fff;--wf-canvas:#f8fafd;--wf-border:#d8e1ed;--wf-edge:#63758b;
 --wf-action-bg:#fff;--wf-action-line:#b3c2d3;--wf-action-ink:#435b73;
 --wf-start-bg:#edf4ff;--wf-start-line:#7fa9e9;--wf-start-ink:#1856b3;
 --wf-system-bg:#eef4fb;--wf-system-line:#9cb5d4;--wf-system-ink:#31577e;
 --wf-result-bg:#edf7f2;--wf-result-line:#85b7a0;--wf-result-ink:#176746;
 --wf-decision-bg:#fff7e8;--wf-decision-line:#c6a062;--wf-decision-ink:#855810;
 --wf-exception-bg:#fff0f1;--wf-exception-line:#cf9aa1;--wf-exception-ink:#a13241;
 --wf-planned-bg:#f4f6fa;--wf-planned-line:#a2afbf;--wf-planned-ink:#5c6f84;
 --wf-select:#1e78ea;
}
:root[data-theme=dark]{
 --wf-surface:#252532;--wf-canvas:#1d1d29;--wf-border:#3b485a;--wf-edge:#99abc1;
 --wf-action-bg:#252f3f;--wf-action-line:#586f8e;--wf-action-ink:#b9cbe2;
 --wf-start-bg:#263b5b;--wf-start-line:#6f9de1;--wf-start-ink:#b2d0ff;
 --wf-system-bg:#27364b;--wf-system-line:#7593bc;--wf-system-ink:#b9d1f2;
 --wf-result-bg:#233f35;--wf-result-line:#6ba58b;--wf-result-ink:#a8e3c5;
 --wf-decision-bg:#403524;--wf-decision-line:#bf9b64;--wf-decision-ink:#f2ce96;
 --wf-exception-bg:#462d36;--wf-exception-line:#bf7885;--wf-exception-ink:#ffc0c8;
 --wf-planned-bg:#2a303b;--wf-planned-line:#8798ac;--wf-planned-ink:#bccbdd;
 --wf-select:#93bdff;
}
.workflow-diagram{background:var(--wf-surface);border:1px solid var(--wf-border);border-radius:12px}
.workflow-diagram .diagram-head{padding:9px 13px;min-height:47px;background:var(--wf-surface)}
.wf-heading{display:flex;align-items:baseline;gap:10px;flex-wrap:wrap;line-height:1.45}.wf-heading strong{font-size:13px;font-weight:500;color:var(--ink)}.wf-heading small{font-size:11px;color:var(--muted)}
.workflow-diagram .diagram-stage{padding:12px 10px;background:var(--wf-canvas);overflow:auto;scrollbar-width:thin}
.workflow-diagram .workflow-svg{display:block;width:var(--natural);max-width:100%;min-width:var(--minimum);height:auto;margin:0 auto;overflow:visible}
.wf-lane rect{fill:var(--wf-surface);stroke:var(--wf-border);stroke-width:1}
.workflow-svg .wf-lane text{font:500 14px var(--ui);fill:var(--muted)}
.wf-node{--node-bg:var(--wf-action-bg);--node-line:var(--wf-action-line);--node-ink:var(--wf-action-ink);cursor:pointer;outline:none}
.wf-node.start,.wf-swatch.start{--node-bg:var(--wf-start-bg);--node-line:var(--wf-start-line);--node-ink:var(--wf-start-ink)}
.wf-node.system,.wf-swatch.system{--node-bg:var(--wf-system-bg);--node-line:var(--wf-system-line);--node-ink:var(--wf-system-ink)}
.wf-node.result,.wf-swatch.result{--node-bg:var(--wf-result-bg);--node-line:var(--wf-result-line);--node-ink:var(--wf-result-ink)}
.wf-node.decision,.wf-swatch.decision{--node-bg:var(--wf-decision-bg);--node-line:var(--wf-decision-line);--node-ink:var(--wf-decision-ink)}
.wf-node.exception,.wf-swatch.exception{--node-bg:var(--wf-exception-bg);--node-line:var(--wf-exception-line);--node-ink:var(--wf-exception-ink)}
.wf-node.planned,.wf-swatch.planned{--node-bg:var(--wf-planned-bg);--node-line:var(--wf-planned-line);--node-ink:var(--wf-planned-ink)}
.wf-node .wf-shape{fill:var(--node-bg);stroke:var(--node-line);stroke-width:1;stroke-linejoin:round;transition:stroke .14s,stroke-width .14s}
.wf-node.planned .wf-shape{stroke-dasharray:4 3}
.wf-node:hover .wf-shape,.wf-node:focus-visible .wf-shape,.wf-node.selected .wf-shape{stroke:var(--wf-select);stroke-width:1.8}
.wf-node .wf-glyph{color:var(--node-ink);pointer-events:none}.wf-node foreignObject{pointer-events:none}
.wf-label{height:100%;width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:2px;padding:1px 2px;line-height:1.26;font:500 13px/1.26 var(--ui);text-align:center;color:var(--ink);overflow-wrap:anywhere}
.wf-label small{display:block;font:400 10px/1.3 var(--ui);color:var(--node-ink)}.wf-label.question{font-size:13px;color:var(--node-ink)}
.workflow-svg .wf-edge{fill:none;stroke:var(--wf-edge);stroke-width:1.2;stroke-linejoin:round;stroke-linecap:round}
.workflow-svg .wf-edge.reject{stroke:var(--wf-exception-ink)}.workflow-svg .wf-edge.review{stroke:var(--wf-decision-ink)}.workflow-svg .wf-edge.planned{stroke:var(--wf-planned-line);stroke-dasharray:5 5}
.workflow-svg marker .arrow-normal{fill:var(--wf-edge)}.workflow-svg marker .arrow-reject{fill:var(--wf-exception-ink)}.workflow-svg marker .arrow-review{fill:var(--wf-decision-ink)}.workflow-svg marker .arrow-planned{fill:var(--wf-planned-line)}
.workflow-svg .wf-branch-label{font:500 11px var(--ui);fill:var(--muted);paint-order:stroke;stroke:var(--wf-canvas);stroke-width:4px;stroke-linejoin:round}.workflow-svg .wf-branch-label.reject{fill:var(--wf-exception-ink)}.workflow-svg .wf-branch-label.review{fill:var(--wf-decision-ink)}
.workflow-svg.inspecting .wf-node:not(.selected){opacity:.58}.workflow-svg.inspecting .wf-connection{opacity:.54}
.wf-legend{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:8px 14px;padding:10px 12px;border-top:1px solid var(--wf-border);font-size:11px;color:var(--muted);background:var(--wf-surface)}
.wf-legend-item{display:inline-flex;align-items:center;gap:5px;white-space:nowrap}.wf-swatch{--node-bg:var(--wf-action-bg);--node-line:var(--wf-action-line);display:inline-block;width:14px;height:10px;border:1px solid var(--node-line);background:var(--node-bg);border-radius:3px}.wf-swatch.decision{width:9px;height:9px;transform:rotate(45deg);border-radius:1px;margin-inline:2px}.wf-swatch.planned{border-style:dashed}
.wf-note{margin:0;padding:9px 13px;border-top:1px solid var(--wf-border);font-size:12px;color:var(--muted);line-height:1.65}
.wf-guide{border-top:1px solid var(--wf-border);padding:10px 12px;background:var(--wf-surface)}.wf-controls{display:flex;align-items:center;gap:6px;flex-wrap:wrap}.wf-control-label{font-size:12px;color:var(--muted);margin-inline-end:auto}.wf-controls button{min-height:30px;font-size:11px;padding:4px 9px}.wf-controls button:disabled{opacity:.48;cursor:default;pointer-events:none}.wf-counter{font:400 10.5px var(--mono);direction:ltr;min-width:52px;text-align:center;color:var(--muted)}.wf-detail{margin:8px 0 0;font-size:12px;line-height:1.65;min-height:20px;color:var(--ink)}
#zoomBody .workflow-diagram .workflow-svg{width:100%;max-width:none;min-width:0}
@media(max-width:800px){.workflow-diagram .diagram-stage{padding:10px 8px}.workflow-diagram .workflow-svg{min-width:var(--minimum)}.wf-control-label{flex-basis:100%;margin:0}.wf-legend{justify-content:flex-start;gap:7px 10px}}
@media(prefers-reduced-motion:reduce){.wf-node .wf-shape{transition:none}}
@media print{
 :root,:root[data-theme=dark]{
 --wf-surface:#fff;--wf-canvas:#f8fafd;--wf-border:#d8e1ed;--wf-edge:#63758b;
 --wf-action-bg:#fff;--wf-action-line:#b3c2d3;--wf-action-ink:#435b73;
 --wf-start-bg:#edf4ff;--wf-start-line:#7fa9e9;--wf-start-ink:#1856b3;
 --wf-system-bg:#eef4fb;--wf-system-line:#9cb5d4;--wf-system-ink:#31577e;
 --wf-result-bg:#edf7f2;--wf-result-line:#85b7a0;--wf-result-ink:#176746;
 --wf-decision-bg:#fff7e8;--wf-decision-line:#c6a062;--wf-decision-ink:#855810;
 --wf-exception-bg:#fff0f1;--wf-exception-line:#cf9aa1;--wf-exception-ink:#a13241;
 --wf-planned-bg:#f4f6fa;--wf-planned-line:#a2afbf;--wf-planned-ink:#5c6f84;--wf-select:#1e78ea
 }
 .wf-guide{display:none!important}.workflow-diagram .diagram-stage{overflow:visible;padding:5px}
 .workflow-diagram .workflow-svg{width:var(--natural);max-width:100%;min-width:0;max-height:145mm}
 .workflow-svg.inspecting .wf-node,.workflow-svg.inspecting .wf-connection{opacity:1!important}
 .wf-node.selected .wf-shape{stroke:var(--node-line);stroke-width:1}
 .wf-legend{font-size:9.5pt;padding:5px 8px}.wf-note{font-size:9.5pt}
}
