@font-face{font-family:Manrope;src:url('/Manrope.ttf') format('truetype');font-weight:200 800;font-display:swap}
:root{color-scheme:dark;--bg:#101215;--panel:#16191d;--surface:#1d2126;--line:#30353c;--muted:#a4adb8;--ink:#eef1f5;--accent:#a8c6e3;--accent-bg:#263441;font:14px/1.5 Manrope,Arial,sans-serif;background:var(--bg);color:var(--ink)}
*{box-sizing:border-box}
body{margin:0}
button,input,textarea,select{font:inherit}
button,a,input,select,textarea{outline-offset:3px}
:focus-visible{outline:2px solid var(--accent)}
button,select{cursor:pointer}
button,a.quiet{color:inherit;border:1px solid var(--line);background:var(--surface);border-radius:7px}
button:hover:not(:disabled),a.quiet:hover{border-color:#697b8e;background:#2b323b}
button:disabled{opacity:.48;cursor:default}
[hidden]{display:none!important}
h1,h2,h3,p,ol{margin:0}
h1{font-size:clamp(22px,2.4vw,34px);line-height:1.17;letter-spacing:-.055em;overflow-wrap:anywhere}
h2{font-size:15px;letter-spacing:-.025em;font-weight:740}
.top{height:64px;display:flex;align-items:center;padding:0 22px;border-bottom:1px solid var(--line);background:#111417;gap:22px}
.top{position:sticky;top:0;z-index:2}
.brand,.session,.section-title,.dialog-head,.dialog-actions,.node-head,.studio-head,#actions{display:flex;align-items:center}
.brand{gap:10px;flex-shrink:0}
.brand strong{font-size:24px;letter-spacing:-.07em;font-weight:760}
.brand strong span{color:var(--accent)}
.brand img{border-radius:7px;object-fit:contain;background:#111}
.product{color:var(--muted);font-size:13px;border-left:1px solid var(--line);padding-left:20px}
.session{margin-left:auto;gap:16px}
.connection{font-size:12px;color:var(--muted);display:inline-flex;align-items:center;gap:8px}
.connection:before,.badge:before{content:'';width:6px;height:6px;border-radius:50%;background:#77818d;flex:none}
.connection.online:before,.badge.active:before{background:var(--accent)}
.quiet,.primary{display:inline-flex;justify-content:center;align-items:center;text-decoration:none;padding:7px 12px;font-weight:650;font-size:13px}
button.primary{background:var(--accent);color:#14202d;border-color:var(--accent)}
button.primary:hover:not(:disabled){background:#c1d7ec;border-color:#c1d7ec}
.workspace{display:grid;grid-template-columns:clamp(195px,18vw,290px) minmax(0,1fr) clamp(270px,25vw,420px);min-height:calc(100dvh - 64px)}
.library,.inspector{background:var(--panel);min-width:0}
.library{border-right:1px solid var(--line)}
.inspector{border-left:1px solid var(--line)}
.library section,.inspector section,.details{padding:20px}
.library section+section,.inspector section+section{border-top:1px solid var(--line)}
.section-title,.dialog-head,.studio-head{justify-content:space-between;gap:12px}
.section-title{min-height:28px;margin-bottom:13px}
.count,.step,.time,.crumb{font-size:11px;color:var(--muted);font-variant-numeric:tabular-nums}
.count{font-weight:600;background:#252a30;border-radius:5px;padding:2px 6px}
h2 .count{margin-left:3px;vertical-align:middle}
.square{min-width:28px;height:28px;font:19px/1 Arial,sans-serif;padding:0 4px}
.empty,.hint{font-size:13px;color:var(--muted);line-height:1.6}
.item{width:100%;padding:10px 11px;display:grid;text-align:left;gap:2px;margin:4px 0;border:1px solid transparent;background:transparent;overflow-wrap:anywhere}
.item strong{font-size:13px}
.item small,.node small,.preview-hint small,.event-meta,.worker small{font-size:12px;color:var(--muted)}
.item[aria-current=true]{background:var(--accent-bg);border-color:#45586d}
.item[aria-current=true] strong{color:#d4e4f5}
.studio{display:flex;flex-direction:column;min-width:0}
.studio-head{padding:22px clamp(16px,2.2vw,34px);border-bottom:1px solid var(--line);background:#181b1f;min-height:95px}
.project-heading{min-width:0}
.crumb{display:block;margin-bottom:4px}
.badge{display:inline-flex;align-items:center;gap:7px;font-size:11px;font-weight:650;white-space:nowrap;color:var(--muted);padding:5px 9px;border:1px solid var(--line);border-radius:15px}
.badge.active{color:var(--accent);border-color:#45586d}
.canvas{position:relative;display:grid;align-items:center;justify-items:center;flex:1;min-height:366px;padding:42px clamp(16px,2vw,32px);background-color:#15181b;background-image:radial-gradient(#363c43 .85px,transparent 1px);background-size:16px 16px}
.graph{--gap:clamp(30px,4vw,74px);width:min(100%,580px);display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:var(--gap);row-gap:48px}
.node{position:relative;min-width:0;display:flex;align-items:flex-start;flex-direction:column;text-align:left;border-radius:10px;padding:13px 15px 14px;background:#21252a;border:1px solid #424951;box-shadow:0 3px 7px #0003}
.node-head{justify-content:space-between;align-self:stretch;gap:4px;margin-bottom:10px}
.node strong{font-size:16px;letter-spacing:-.035em}
.node small{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.node[aria-pressed=true]{background:#23313e;border-color:#91aec9}
.node[aria-pressed=true]:hover{background:#2b3a48}
.glyph{display:grid;place-items:center;background:#343b44;border-radius:6px;width:28px;height:28px;font:bold 21px/1 Arial;color:#c4d5e6}
.brief-icon,.frame-icon{font-size:25px}
.code-icon{font-size:12px}
.node[data-stage=draw]{grid-area:2 / 2}
.node[data-stage=build]{grid-area:2 / 1}
.node:after,.node:before{pointer-events:none;position:absolute;content:''}
.node[data-stage=brief]:after,.node[data-stage=build]:after{height:2px;width:var(--gap);background:#72879b;left:calc(100% + 1px);top:50%}
.node[data-stage=plan]:after{width:2px;height:48px;background:#72879b;left:50%;top:calc(100% + 1px)}
.node[data-stage=plan]:before,.node[data-stage=build]:before,.node[data-stage=draw]:before{border:solid #92a8bd;border-width:0 2px 2px 0;padding:3px;z-index:1}
.node[data-stage=plan]:before{left:-11px;top:calc(50% - 3px);transform:rotate(-45deg)}
.node[data-stage=build]:before{right:-11px;top:calc(50% - 3px);transform:rotate(135deg)}
.node[data-stage=draw]:before{top:-11px;left:calc(50% - 3px);transform:rotate(45deg)}
.details{min-height:170px;background:#181b1e;border-top:1px solid var(--line);padding-inline:clamp(16px,2.2vw,34px)}
.detail-field{font-size:13px;margin:5px 0;white-space:pre-wrap;overflow-wrap:anywhere}
.detail-field span{color:var(--muted);margin-right:.55em}
#actions{gap:10px;flex-wrap:wrap;margin-top:16px}
#agent-disclosure{margin-top:8px}
#provider-label{display:flex;align-items:center;gap:8px;color:var(--muted);font-size:13px}
input,select,textarea{border:1px solid #414952;border-radius:6px;background:#15191d;color:var(--ink);padding:8px 10px}
textarea{resize:vertical}
.preview-surface{border:1px solid #363c43;overflow:hidden;border-radius:9px;background:#111418}
.browser-bar{display:flex;gap:4px;padding:10px;background:#202429;border-bottom:1px solid var(--line)}
.browser-bar i{width:5px;height:5px;background:#63707c;border-radius:50%}
#preview{aspect-ratio:1.55;min-height:135px;display:grid;place-items:stretch}
.preview-hint{display:grid;justify-items:center;align-content:center;gap:4px;color:#c9d0d7;text-align:center;padding:10px}
.preview-hint strong{font-size:13px}
.window-icon{width:30px;height:22px;border:1.5px solid #8495a5;border-radius:4px;margin-bottom:5px;position:relative}
.window-icon:before{content:'';position:absolute;inset:5px 0 auto;border-top:1px solid #8495a5}
iframe{width:100%;height:100%;border:none;background:#fff}
.snapshot{display:block;width:100%;height:100%;min-height:0;object-fit:contain;background:#111418}
.preview-tools{display:flex;align-items:center;gap:6px}
#download-demo{padding:4px 8px;font-size:12px}
#events{list-style:none;padding:0;max-height:330px;overflow:auto}
#leads,#refs,#workers{max-height:48vh;overflow:auto}
#search{width:100%;margin-bottom:8px}
#pages{display:flex;justify-content:space-between;align-items:center;margin-top:8px;gap:5px;color:var(--muted)}
#load-summary{width:100%;margin-bottom:9px}
#summary-dialog{width:min(560px,calc(100% - 24px))}
#summary-rows{max-height:32dvh;overflow:auto}
#summary-rows label{display:flex;align-items:center;gap:9px;margin:0;padding:7px;border-bottom:1px solid var(--line);cursor:pointer;color:var(--ink);overflow-wrap:anywhere}
#summary-rows label:has(:checked){background:var(--accent-bg)}
#summary-rows small{display:block;color:var(--muted)}
#summary-pages{display:flex;align-items:center;justify-content:space-between;margin:8px 0}
#summary-status{margin-top:8px}
.event,.worker{overflow-wrap:anywhere;padding-block:8px}
.event+.event,.worker+.worker{border-top:1px solid #292e34}
.event-meta{display:flex;gap:7px;align-items:baseline;justify-content:space-between}
.event p,.worker strong{font-size:13px}
.worker small{display:block}
dialog{color:var(--ink);background:#1a1e23;border:1px solid #48535f;border-radius:12px;padding:24px;width:min(430px,calc(100% - 24px));max-height:90dvh;box-shadow:0 25px 85px #0008}
dialog::backdrop{background:#07090cba}
.dialog-head{margin-bottom:18px}
.dialog-head h2{font-size:20px;overflow-wrap:anywhere}
dialog label{display:grid;gap:5px;color:var(--muted);font-size:13px;margin:12px 0}
.dialog-actions{justify-content:flex-end;gap:8px;margin-top:16px}
.form-error,#login-error{color:#f2b4ab;font-size:13px}
#ref-dialog{width:min(720px,calc(100% - 24px))}
#ref-content{margin-bottom:15px}
#ref-content img{max-height:60vh;max-width:100%;display:block;margin:auto}
#ref-content pre{white-space:pre-wrap;overflow-wrap:anywhere;max-height:55vh;overflow:auto}
#preview-dialog{width:min(1280px,96vw)}
#large-preview{height:72dvh}
#notice{position:fixed;bottom:18px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:12px;max-width:92vw;padding:10px 12px;background:#344454;border:1px solid #648098;border-radius:9px;box-shadow:0 4px 24px #0005;z-index:3;font-size:13px}
#notice button{font-size:16px;line-height:1.25}
@media(max-width:1100px){.workspace{grid-template-columns:180px minmax(0,1fr) 265px}.library section,.inspector section{padding:15px}.node{padding:11px}.studio-head{align-items:flex-start;flex-wrap:wrap}}
@media(max-width:850px){.workspace{grid-template-columns:180px minmax(0,1fr)}.inspector{grid-column:1/-1;border:0;border-top:1px solid var(--line);display:grid;grid-template-columns:1.2fr 1fr 1fr}.inspector section+section{border-top:0;border-left:1px solid var(--line)}.canvas{min-height:340px}}
@media(max-width:620px){.top{padding:0 12px;height:54px;gap:8px}.product{display:none}.session{gap:8px}.brand{gap:6px}.brand strong{font-size:21px}.brand img{width:27px;height:27px}.connection{font-size:11px}.workspace{display:flex;flex-direction:column}.library{display:grid;grid-template-columns:1fr 1fr;border:0;border-bottom:1px solid var(--line)}.library section,.inspector section{min-width:0;padding:12px}.library section+section{border:0;border-left:1px solid var(--line)}#leads,#refs{max-height:140px}.section-title{margin-bottom:6px}.studio-head{min-height:70px;padding:12px 15px}.canvas{min-height:280px;padding:20px 14px}.graph{--gap:26px;row-gap:30px}.node[data-stage=plan]:after{height:30px}.node-head{margin-bottom:6px}.details{min-height:125px;padding:14px}.inspector{display:block}.inspector section+section{border-left:0;border-top:1px solid var(--line)}#preview{max-height:55vw}.empty{font-size:12px}}
@media(max-width:360px){.top .connection{font-size:0;gap:0}.node strong{font-size:14px}}
