@font-face {
  font-family: 'Golos Text';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(assets/font-0.ttf) format('truetype');
}
@font-face {
  font-family: 'Golos Text';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(assets/font-1.ttf) format('truetype');
}
@font-face {
  font-family: 'Golos Text';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(assets/font-2.ttf) format('truetype');
}
@font-face {
  font-family: 'Golos Text';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(assets/font-3.ttf) format('truetype');
}
@font-face {
  font-family: 'Neucha';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(assets/font-4.ttf) format('truetype');
}

/* Art direction: monochrome drafting desk. VARIANCE 6 / MOTION 3 / DENSITY 4. */
:root{font-family:'Golos Text',sans-serif;color:#25272d;background:#f6f7f9;font-synthesis:none;--accent:#4665cf;--accent-soft:#edf1fd;--border:#e6e8ed;--muted:#767b86;--radius:12px}*{box-sizing:border-box}body{margin:0;overflow:hidden}button,input{font:inherit}button{cursor:pointer;color:inherit;border:0;background:none;transition:background .18s,color .18s,box-shadow .18s,transform .18s}button:disabled{opacity:.3;cursor:default}button:active:not(:disabled){transform:scale(.96)}button:focus-visible,input:focus-visible{outline:2px solid var(--accent);outline-offset:3px}.ui-icon{display:inline-block;width:20px;height:20px;background:currentColor;mask:var(--icon) center/contain no-repeat;-webkit-mask:var(--icon) center/contain no-repeat;flex-shrink:0}
header{height:72px;background:#fff;display:flex;align-items:center;padding:0 28px;gap:20px;border-bottom:1px solid var(--border);position:relative;z-index:6}.brand{display:flex;align-items:center;gap:10px;color:#24272e;text-decoration:none;font-size:24px;font-weight:600;letter-spacing:-1.2px}.brandmark{position:relative;width:32px;height:34px;border:1.5px solid #2d3038;border-radius:5px;display:grid;place-items:center;font:italic 30px 'Neucha';transform:rotate(-7deg);background:#fff}.brandmark span{position:absolute;right:3px;top:-2px;font-size:18px;color:var(--accent)}.brand-sub{font-size:12px;letter-spacing:.4px;font-weight:400;margin-left:-4px;margin-top:10px;color:#7d828c}.divider{height:24px;width:1px;background:var(--border)}.document-meta{font-size:12px;color:#89909c;margin-right:-10px}#title{border:0;width:260px;font-size:14px;font-weight:500;color:#363a45;background:transparent;padding:6px}.saved{font-size:12px;color:#89909c}.header-actions{margin-left:auto;display:flex;align-items:center;gap:22px}.plain{font-size:13px;color:#606672}.plain span{margin-left:6px;border:1px solid #d9dce3;border-radius:50%;display:inline-grid;place-items:center;width:18px;height:18px}.primary{display:inline-flex;align-items:center;justify-content:center;gap:9px;white-space:nowrap;background:#2b2f38;color:white;padding:12px 17px;border:1px solid #2b2f38;border-radius:7px;font-size:14px;font-weight:500}.primary:hover{background:#464c59}.primary .ui-icon{width:17px;height:17px}
.workspace{height:calc(100dvh - 104px);position:relative;display:flex}aside{position:absolute;z-index:5;left:20px;top:20px;bottom:88px;width:262px;background:#fff;border:1px solid var(--border);border-radius:var(--radius);padding:22px 17px 0;display:flex;flex-direction:column;box-shadow:0 4px 24px #222d4907;overflow:hidden}.library-heading{display:flex;align-items:center;justify-content:space-between}.library-heading h1{font-size:20px;font-weight:600;letter-spacing:-.6px;margin:0}.library-heading>span{font-size:12px;color:#788190;background:#f2f3f6;border-radius:4px;padding:3px 7px;font-variant-numeric:tabular-nums}.muted{font-size:12px;color:#7c8290;margin:8px 0 20px}.search{display:flex;align-items:center;gap:9px;border:1px solid var(--border);border-radius:6px;padding:11px 10px;background:#fafbfc}.search>.ui-icon{width:17px;height:17px;color:#8a909c}.search input{border:0;outline:none;min-width:0;width:100%;font-size:14px;background:transparent;color:#383e49}.search input::placeholder{color:#89909c}.search kbd{font:11px monospace;background:#fff;border:1px solid #e1e4ea;padding:1px 5px;border-radius:3px;color:#939aa6}.tabs{display:flex;gap:2px;margin-top:15px;border-bottom:1px solid var(--border);padding-bottom:13px}.tabs button{font-size:12px;padding:7px 10px;border-radius:5px;color:#747b89}.tabs button.active{background:var(--accent-soft);color:var(--accent);font-weight:500}.collection{display:flex;align-items:center;justify-content:space-between;font-size:12px;color:#8a909c;margin:19px 1px 10px}.collection-count{font-variant-numeric:tabular-nums;font-size:11px}.icon-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;overflow:auto;flex:1;align-content:start;padding-bottom:16px;scrollbar-width:thin;scrollbar-color:#dfe2e9 transparent}.library-item{height:118px;border:1px solid transparent;border-radius:8px;background:#fff;padding:7px 4px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px}.library-item:hover{background:#f4f6fc;border-color:#e5eafa}.library-item img{width:83px;height:83px;object-fit:contain;pointer-events:none}.library-item span{font-size:12px;line-height:1.3;color:#59616e;text-align:center}.sidebar-note{display:flex;align-items:center;gap:11px;border-top:1px solid var(--border);margin:0 -17px;padding:15px 17px;background:#fcfcfd}.note-key{font-size:22px;color:#8c96ab}.sidebar-note p{font-size:11px;line-height:1.6;color:#8a919e;margin:0}
main{flex:1;position:relative;overflow:hidden;touch-action:none;background-color:#f8f9fb;background-image:radial-gradient(#d8dce5 .7px,transparent .7px);background-size:20px 20px}.canvas-label{position:absolute;top:28px;left:315px;display:flex;align-items:center;gap:12px;font-size:12px;color:#838b99;z-index:3;pointer-events:none}.canvas-document{font-weight:500;color:#707988}.badge{font-size:11px;border-left:1px solid #dce1e9;padding:0 12px;color:#a1a7b1}#world{position:absolute;width:2400px;height:1800px;transform-origin:0 0}#connections{position:absolute;top:0;left:0;overflow:visible;pointer-events:none}#edges path{pointer-events:stroke;cursor:pointer}.node{position:absolute;width:144px;min-height:125px;display:flex;flex-direction:column;align-items:center;cursor:grab;border:1px solid transparent;border-radius:7px;padding:6px;user-select:none;z-index:2}.node.selected{border:1px solid var(--accent);background:#edf1fd60;box-shadow:0 0 0 3px #4665cf0b}.node img{width:105px;height:87px;object-fit:contain;pointer-events:none;mix-blend-mode:multiply}.node-label{font-family:'Neucha',cursive;font-size:20px;line-height:1.2;text-align:center;white-space:pre-wrap;max-width:200px;min-width:70px;padding:3px;cursor:text;outline:none}.node-label[contenteditable=true]{background:#fff;user-select:text;box-shadow:0 0 0 1px var(--accent);border-radius:4px}.node.text{min-height:40px;width:210px;justify-content:center}.port{position:absolute;width:10px;height:10px;background:#fff;border:1.5px solid var(--accent);border-radius:50%;opacity:0;cursor:crosshair;z-index:4}.node:hover .port,.node.selected .port,main.connect .port{opacity:1}.port.right{right:-6px;top:48%}.port.left{left:-6px;top:48%}.port.bottom{bottom:-6px;left:48%}.port.top{top:-6px;left:48%}.node.group{z-index:0;width:330px;height:360px;min-height:0;align-items:flex-start;border:1.5px dashed var(--node-color,#98a5bf);background:color-mix(in srgb,var(--node-color,#98a5bf) 4%,transparent);border-radius:12px;padding:0}.group .node-label{margin:-16px 0 0 16px;padding:5px 12px;background:#f8f9fb;border-radius:4px;font:500 15px 'Golos Text';color:#657086;letter-spacing:.2px}.group.selected{outline:2px solid var(--accent)}
.tools{position:absolute;bottom:26px;left:calc(50% + 130px);transform:translateX(-50%);display:flex;gap:4px;align-items:center;background:#fff;border:1px solid #e0e4ec;box-shadow:0 5px 20px #27365409;padding:7px;border-radius:11px;z-index:4}.tools button{width:42px;height:42px;border-radius:6px;display:grid;place-items:center;color:#7a8494;position:relative}.tools button .ui-icon{width:21px;height:21px}.tools button:hover:not(:disabled){background:#e9edf5;color:#354158;box-shadow:inset 0 0 0 1px #ced6e4}.tools button.active{background:var(--accent-soft);color:var(--accent)}.tools>span,.zoom>span{height:23px;width:1px;background:var(--border);margin:0 5px}.canvas-hint{position:absolute;bottom:103px;left:calc(50% + 130px);transform:translateX(-50%);font-size:12px;white-space:nowrap;color:#939baa;pointer-events:none}.canvas-hint span{padding:0 9px}.zoom{position:absolute;right:24px;bottom:33px;border:1px solid #e0e4ec;border-radius:7px;padding:4px;display:flex;align-items:center;background:#fff;z-index:4}.zoom button{height:30px;min-width:29px;font-size:18px;color:#737e90;display:grid;place-items:center}.zoom .ui-icon{width:16px;height:16px}#zoom-value{font-size:12px;min-width:46px;font-variant-numeric:tabular-nums}.selection-panel{position:absolute;right:22px;top:75px;align-items:center;gap:13px;background:white;padding:12px;border:1px solid var(--border);border-radius:8px;z-index:4;font-size:12px;box-shadow:0 5px 20px #27365408}.selection-panel:not([hidden]){display:flex}.selection-panel>span{color:#7a8597}.swatches{display:flex;gap:7px}.swatches button{width:17px;height:17px;background:var(--swatch);border-radius:50%;border:2px solid #fff;outline:1px solid #dfe4ec}.selection-panel>button{display:grid;place-items:center;color:#8590a2;padding:3px}.selection-panel>button .ui-icon{width:18px;height:18px}.toast{position:absolute;bottom:160px;left:calc(50% + 130px);transform:translateX(-50%);background:#303746;color:#fff;border-radius:7px;font-size:13px;padding:12px 18px;opacity:0;pointer-events:none;transition:opacity .2s;z-index:9}.toast.show{opacity:1}footer{height:32px;border-top:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:0 24px;font-size:11px;color:#929baa;background:#fff}footer span{white-space:nowrap}footer #stats{font-variant-numeric:tabular-nums}dialog{border:1px solid var(--border);border-radius:12px;padding:35px;max-width:520px;color:#3a4352;box-shadow:0 20px 100px #26375422}dialog::backdrop{background:#27334b44;backdrop-filter:blur(3px)}dialog h2{font-size:25px;letter-spacing:-.7px}dialog ol{padding-left:22px;font-size:14px;line-height:1.7}dialog li{margin:12px 0}dialog p{font-size:12px;color:#788394;line-height:1.8}button.dialog-close:not(.primary){position:absolute;right:15px;top:12px;font-size:25px}.eyebrow{font-size:11px;letter-spacing:1px;color:#8b96a8}.empty-library{grid-column:1/-1;padding:30px 10px;font-size:14px;color:#7e899b;text-align:center}
@media(max-width:1150px){.saved,.plain,.document-meta{display:none}.tools{left:calc(50% + 120px)}.canvas-hint{display:none}.zoom{bottom:105px}.canvas-label{left:306px}.header-actions{gap:12px}}
@media(max-width:750px){header{height:64px;padding:0 16px;gap:12px}.brand{font-size:21px}.brand-sub,.divider,.canvas-label{display:none}#title{width:160px;font-size:12px;min-width:0}.header-actions{gap:0}.primary{padding:10px;font-size:12px}.workspace{height:calc(100dvh - 94px)}aside{left:10px;top:12px;bottom:92px;width:162px;padding:16px 10px 0}.library-heading h1{font-size:16px}.muted,.collection,.search kbd,.sidebar-note{display:none}.search{margin:15px 0;padding:8px}.search input{font-size:12px}.search>.ui-icon{width:14px;height:14px}.tabs{margin:0 0 12px;padding-bottom:10px;flex-wrap:wrap}.tabs button{font-size:11px;padding:5px 6px}.icon-grid{gap:0}.library-item{height:100px;padding:5px 2px}.library-item img{width:63px;height:63px}.library-item span{font-size:10px}.tools{left:50%;bottom:20px;gap:1px;padding:5px}.tools button{width:34px;height:36px}.tools>span{margin:0 3px}.tools button .ui-icon{width:19px;height:19px}.zoom{bottom:90px;right:12px}.selection-panel{right:10px;top:20px;gap:8px}.selection-panel>span{display:none}.toast{left:50%;bottom:160px;max-width:90%;text-align:center}footer{height:30px;padding:0 12px;font-size:10px}footer>span:last-child{display:none}}
@media(max-width:450px){header .brandmark{width:28px;height:30px}header .brand{font-size:19px;gap:7px}header #title{flex:1;width:70px}header .primary{font-size:0;padding:9px}header .primary>.ui-icon{width:19px;height:19px}.header-actions{flex-shrink:0}aside{width:116px;padding:14px 8px 0}.library-heading h1{font-size:14px}.library-heading>span,.tabs{display:none}.icon-grid{grid-template-columns:1fr}.library-item{height:95px}.library-item img{width:70px;height:70px}.library-item span{font-size:11px}.tools button{width:32px}.tools>span{margin:0 2px}footer{font-size:9px}}
@media(prefers-reduced-motion:reduce){button,.toast{transition:none}}

.canvas-hint{display:none}
/* Practice mode: a separate draft and a compact brief beside the canvas. */
.tasks-button{display:flex;align-items:center;gap:8px;border:1px solid var(--border);padding:10px 12px;border-radius:7px;font-size:13px;color:#4e586a;white-space:nowrap}.tasks-button:hover{background:#f3f5fa}.tasks-button>.ui-icon{width:17px;height:17px}.task-count{font-size:10px;color:#6e7d9c;background:#edf1fa;padding:2px 5px;border-radius:3px}.tasks-dialog{width:min(760px,calc(100vw - 32px));max-width:760px;padding:38px}.tasks-dialog>h2{font-size:34px;line-height:1.1;letter-spacing:-1.3px;margin:18px 0 14px}.tasks-intro{max-width:460px}.task-card{display:grid;grid-template-columns:190px 1fr;border:1px solid var(--border);border-radius:9px;overflow:hidden;margin:24px 0}.task-card-art{position:relative;background:#f3f5fa;display:flex;align-items:center;justify-content:center}.task-card-art img{width:100px;height:120px;object-fit:contain}.task-card-art img+img{margin-left:-22px;margin-top:48px;transform:rotate(8deg)}.task-card-art>span{position:absolute;left:16px;top:16px;font:12px monospace;color:#9aa5ba}.task-card-details{padding:25px}.task-card-details h3{font-size:21px;letter-spacing:-.5px;margin:12px 0}.task-card-details p{font-size:14px;line-height:1.6;margin-bottom:20px}.tasks-preserve{border-top:1px solid var(--border);padding-top:16px;margin-bottom:0!important;font-size:12px!important}.task-level{font-size:11px;color:#8b95a5}.task-panel{position:absolute;right:20px;top:20px;bottom:88px;width:302px;border:1px solid var(--border);border-radius:12px;background:#fff;z-index:5;padding:19px 20px;overflow:auto;box-shadow:0 4px 24px #222d4907}.task-panel[hidden]{display:none}.task-panel-top{display:flex;align-items:center;justify-content:space-between;font-size:12px;color:var(--accent);margin-bottom:19px;font-weight:500}.task-panel-top button{font-size:23px;color:#8a94a5;line-height:1}.task-panel h2{font-size:25px;letter-spacing:-.8px;line-height:1.15;margin:10px 0 15px}.task-story{font-size:13px;line-height:1.7;color:#727d8f;margin:0 0 18px}.task-requirements{padding:14px 0;border-top:1px solid var(--border);border-bottom:1px solid var(--border)}.task-requirements h3{font-size:12px;font-weight:500;margin:0 0 8px}.task-requirements p{font-size:12px;color:#8993a4;line-height:1.6;margin:0}.task-progress{display:flex;justify-content:space-between;font-size:11px;margin-top:20px;color:#79859a;font-variant-numeric:tabular-nums}.task-progress-track{height:3px;background:#edf0f6;border-radius:2px;margin-top:9px}.task-progress-track span{height:100%;display:block;background:var(--accent);transition:width .2s}#task-checklist{list-style:none;padding:0;margin:18px 0;display:grid;gap:13px}#task-checklist li{display:flex;align-items:flex-start;gap:9px;font-size:12px;line-height:1.5;color:#838fa2}.check-mark{width:16px;height:16px;flex-shrink:0;display:grid;place-items:center;border:1px solid #dfe5ee;border-radius:50%;font-size:12px;color:#a4afc0;margin-top:1px}.passed{color:#4f6284!important}.passed .check-mark{background:#eef2fd;border-color:#aebde6;color:#4665cf}.missing .check-mark{border-color:#d2b59a;color:#b5875a}.task-panel-bottom{border-top:1px solid var(--border);padding-top:16px}.task-panel-bottom>.primary{width:100%;font-size:13px}.task-panel-bottom>p{font-size:10px;color:#9aa3b2;line-height:1.6;margin:10px 0 13px}.task-link{padding:0;font-size:11px;color:#7d89a0;text-decoration:underline;text-underline-offset:3px}.task-advice,.task-success{padding:13px;border-radius:7px;margin-bottom:16px;background:#f5f7fc;color:#687b9d;font-size:12px}.task-success{background:#eaf7ed;color:#2b6841}.task-advice b,.task-success b{font-size:12px;font-weight:500}.task-advice p,.task-success p{font-size:12px;line-height:1.6;margin:7px 0 0}.expand-task{position:absolute;right:20px;top:20px;z-index:5;padding:12px 15px;display:flex;align-items:center;gap:14px;background:#fff;border:1px solid var(--border);border-radius:7px;color:#657899;font-size:12px;box-shadow:0 4px 24px #222d4907}.expand-task[hidden]{display:none}#task-empty{position:absolute;left:calc(50% - 30px);top:40%;transform:translate(-50%,-50%);text-align:center;pointer-events:none;z-index:1}#task-empty[hidden]{display:none}#task-empty h2{font-size:23px;letter-spacing:-.7px;color:#7a879e;font-weight:500;margin:12px 0}#task-empty p{font-size:13px;line-height:1.8;color:#a0aabc}.empty-drawing{display:flex;justify-content:center;opacity:.65}.empty-drawing img{width:94px;height:94px;object-fit:contain}.empty-drawing img+img{margin-left:-8px;transform:rotate(9deg)}.task-active .selection-panel{right:344px}.task-active.task-collapsed .selection-panel{right:22px}.task-active .tools{left:calc(50% - 20px)}.task-active.task-collapsed .tools{left:calc(50% + 130px)}
@media(max-width:1300px){.header-actions{gap:12px}.header-actions .plain,.saved{display:none}}
@media(max-width:1150px){.task-panel{top:20px;bottom:88px;right:16px;width:302px}.task-active .selection-panel{right:22px;top:85px}.task-active .tools{left:calc(50% + 120px)}#task-empty{left:calc(50% + 120px);top:40%}.task-active:not(.task-collapsed) #task-empty{opacity:.25}}
@media(max-width:750px){.tasks-button{font-size:12px;padding:8px;gap:5px}.tasks-button .ui-icon,.task-count{display:none}header{gap:10px}#title{width:120px}.task-panel{top:10px;bottom:84px;right:10px;width:min(302px,calc(100vw - 20px));box-shadow:0 12px 40px #27334b22}.task-active .tools,.task-active.task-collapsed .tools{left:50%}.task-active .selection-panel{top:65px;right:10px}.expand-task{top:12px;right:10px;font-size:11px;padding:10px}#task-empty{left:calc(50% + 60px);top:43%;width:210px}#task-empty h2{font-size:17px}#task-empty p{font-size:11px}.empty-drawing img{width:70px;height:70px}.tasks-dialog{padding:25px}.tasks-dialog>h2{font-size:28px}.task-card{grid-template-columns:1fr}.task-card-art{height:125px}.task-card-art img{height:90px}.task-card-art img+img{margin-top:0}.task-card-details{padding:20px}.task-card-details h3{font-size:19px}}
@media(max-width:450px){header .brand{font-size:17px}header .brandmark{display:none}header #title{font-size:11px}.tasks-button{font-size:11px;padding:8px}.header-actions{gap:7px}}
.task-panel-bottom{position:sticky;bottom:-19px;background:#fff;margin:0 -20px -19px;padding:14px 20px 18px;box-shadow:0 -8px 14px #ffffffee}.task-secondary-actions{display:flex;align-items:center;justify-content:space-between;gap:12px}.task-card-status{font-size:11px;color:#4665cf;margin-left:12px}
/* Arch Forge wordmark and document header. */
header{gap:22px}.brand{gap:10px;letter-spacing:0;flex-shrink:0}.brand-symbol{width:36px;height:36px;display:block}.brand-name{font-size:23px;font-weight:600;letter-spacing:-1.05px;line-height:1;display:flex;gap:5px;align-items:baseline}.brand-name>span{font-weight:400;color:#606a7c;letter-spacing:-.8px}.brand:hover .brand-name>span{color:#4665cf}.document-meta{color:#939cac;font-size:12px;margin-right:-10px}#title{font-weight:500;letter-spacing:-.2px}.divider{height:25px;background:#e1e5ee}.canvas-label .badge{color:#929dad;font-size:11px}
@media(max-width:750px){header{gap:12px;padding:0 14px}.brand-symbol{width:29px;height:29px}.brand-name{font-size:19px;gap:4px}.brand{gap:7px}}
@media(max-width:450px){header{gap:9px;padding:0 12px}.brand-symbol{width:25px;height:25px}.brand-name{font-size:17px;letter-spacing:-.7px}.brand-name>span{letter-spacing:-.6px}.brand{gap:5px}header #title{min-width:0;flex:1}}
/* Main navigation is separate from document controls. */
header{height:72px;padding:0 28px;gap:48px;box-shadow:none}.main-nav{height:100%;display:flex;align-items:stretch;gap:30px}.main-nav a{display:flex;align-items:center;text-decoration:none;font-size:14px;color:#838c9c;position:relative;white-space:nowrap;transition:color .18s}.main-nav a:hover{color:#343e50}.main-nav a.active{color:#354e9e;font-weight:500}.main-nav a.active:after{content:'';position:absolute;bottom:0;left:0;right:0;height:2px;background:#4665cf}.main-nav a:focus-visible{outline:2px solid #4665cf;outline-offset:5px}.workspace[hidden],.tasks-page[hidden]{display:none}.document-bar{position:absolute;left:310px;top:22px;z-index:3;max-width:calc(100% - 530px)}.document-bar #title{width:300px;max-width:100%;font-size:14px;color:#717e93;padding:8px;border-radius:5px;min-width:0}.document-bar #title:hover{background:#fff}.canvas-actions{position:absolute;right:22px;top:20px;display:flex;align-items:center;gap:10px;z-index:4}.canvas-actions .primary{font-size:12px;padding:10px 13px}.canvas-help{width:32px;height:32px;border:1px solid #dbe1eb;background:#fff;border-radius:50%;color:#8b97ad;font-size:14px}.canvas-help:hover{color:#4665cf;border-color:#a3b4df}.task-active:not(.task-collapsed) .canvas-actions{right:344px}.task-active .document-bar{max-width:calc(100% - 820px)}.task-active.task-collapsed .document-bar{max-width:calc(100% - 530px)}.task-active.task-collapsed .canvas-actions{top:70px}.tasks-page{height:calc(100dvh - 104px);overflow:auto;background:#f8f9fb;max-width:none;width:100%;padding:60px 32px;color:#3a4352}.tasks-page-inner{max-width:960px;margin:0 auto}.tasks-page h2{font-size:40px;line-height:1.12;letter-spacing:-1.4px;margin:16px 0}.tasks-page .tasks-intro{font-size:15px;line-height:1.7;max-width:520px;color:#7b8699}.tasks-page .task-card{max-width:760px;background:#fff;grid-template-columns:240px 1fr;margin:35px 0 28px}.tasks-page .task-card-details{padding:32px}.tasks-page .task-card-details p{color:#8490a3}.tasks-page .tasks-preserve{max-width:760px;color:#929db0;font-size:12px;line-height:1.7}.tasks-page .eyebrow{font-size:11px;letter-spacing:1px}
@media(max-width:1150px){.document-bar{left:305px;max-width:calc(100% - 495px)}.task-active:not(.task-collapsed) .canvas-actions{right:22px;top:75px}.task-active .document-bar{max-width:calc(100% - 495px)}.task-active:not(.task-collapsed) .canvas-actions{display:none}}
@media(max-width:750px){header{height:64px;padding:0 16px;gap:25px}.main-nav{gap:22px}.main-nav a{font-size:13px}.document-bar{left:184px;top:14px;max-width:calc(100% - 225px)}.document-bar #title{font-size:12px;width:180px}.canvas-actions{right:12px;top:auto;bottom:135px;gap:7px}.canvas-actions .primary{font-size:11px;padding:9px}.canvas-help{width:28px;height:28px}.task-active .document-bar,.task-active.task-collapsed .document-bar{max-width:calc(100% - 225px)}.task-active.task-collapsed .canvas-actions{top:auto;bottom:135px}.tasks-page{height:calc(100dvh - 94px);padding:36px 20px}.tasks-page h2{font-size:30px}.tasks-page .task-card{grid-template-columns:1fr}.tasks-page .task-card-art{height:150px}.tasks-page .task-card-details{padding:24px}.tasks-page .tasks-intro{font-size:14px}}
@media(max-width:450px){header{gap:20px;padding:0 12px}.main-nav{gap:17px}.main-nav a{font-size:12px}.brand-symbol{width:25px;height:25px}.brand-name{font-size:17px}.document-bar{left:140px;max-width:calc(100% - 158px)}.task-active .document-bar,.task-active.task-collapsed .document-bar{max-width:calc(100% - 158px)}.task-active.task-collapsed .document-bar{top:57px}}
footer{position:fixed;bottom:0;left:0;width:100%;z-index:6}.catalog-view footer{display:none}.catalog-view .tasks-page{height:calc(100dvh - 72px)}
@media(max-width:750px){.catalog-view .tasks-page{height:calc(100dvh - 64px)}}
.tabs[hidden]{display:none}.task-active .library-heading h1{font-size:18px;letter-spacing:-.4px}
@media(max-width:750px){.task-active .library-heading h1{font-size:14px}}
@media(max-width:450px){.task-active .library-heading h1{font-size:12px}}
.projects-page{height:calc(100dvh - 72px);overflow:auto;background:#f8f9fb;padding:55px 32px}.projects-page[hidden]{display:none}.projects-inner{max-width:1080px;margin:0 auto}.projects-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:34px}.projects-heading h1{font-size:36px;letter-spacing:-1.2px;margin:15px 0 9px}.projects-heading p{font-size:14px;color:#929bad;margin:0}.projects-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:22px}.project-card{text-align:left;background:#fff;border:1px solid #e3e7ef;border-radius:10px;overflow:hidden;padding:0;transition:border-color .18s,transform .18s}.project-card:hover{border-color:#afbeda;transform:translateY(-2px)}.project-preview{height:160px;background-color:#f4f6fa;background-image:radial-gradient(#d5dce8 .7px,transparent .7px);background-size:16px 16px;display:flex;align-items:center;justify-content:center;gap:0;padding:15px;overflow:hidden}.project-preview img{width:66px;height:77px;object-fit:contain;min-width:0}.project-preview>span{font:20px 'Neucha';color:#a8b2c4}.project-card-info{padding:21px}.project-card-info h2{font-size:17px;letter-spacing:-.3px;line-height:1.4;margin:0 0 10px;overflow-wrap:anywhere}.project-card-info p{font-size:12px;color:#8b96a9;margin:0 0 18px}.project-card-info time{font-size:11px;color:#a2adbd}#projects-message{color:#8793a6;font-size:14px;margin-bottom:24px;line-height:1.7}#new-project-dialog{width:440px}#new-project-form label{display:block;font-size:13px;margin:25px 0 10px}#project-name{display:block;width:100%;border:1px solid #dce2ee;border-radius:6px;padding:12px;font-size:14px;color:#44516b}#new-project-error{font-size:12px;color:#a7664e;line-height:1.6;margin:12px 0}#new-project-form>.primary{margin-top:12px}.document-bar{display:flex;align-items:center;gap:7px}#back-projects{font-size:20px;color:#7e8da6;padding:4px}#save-status{cursor:pointer}.task-active #back-projects{display:none}
@media(max-width:1000px){.projects-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:750px){.projects-page{height:calc(100dvh - 64px);padding:35px 20px}.projects-heading h1{font-size:29px}.projects-heading{align-items:flex-start}.projects-heading>.primary{font-size:12px;padding:11px}.projects-heading .eyebrow{font-size:9px}.projects-heading p{font-size:12px}.project-card-info{padding:17px}.project-preview{height:130px}}
@media(max-width:480px){.projects-grid{grid-template-columns:1fr}.projects-heading{flex-wrap:wrap;gap:20px}.projects-heading h1{margin-top:12px}.project-preview{height:170px}.projects-page{padding:30px 18px}}

/* Keep connections above group backgrounds; wide transparent strokes make arrows easy to select. */
#connections{z-index:3}#edges .edge-line,#edges #connection-preview{pointer-events:none}#edges .edge-hit{pointer-events:stroke;cursor:pointer}#duplicate[hidden]{display:none}

.tasks-page-inner{max-width:1180px}.task-catalog-heading{display:flex;justify-content:space-between;align-items:center;gap:24px;margin-bottom:28px}.task-catalog-heading h2{margin:12px 0;font-size:34px}.task-catalog-heading .tasks-intro{max-width:650px;margin:0}.task-total{font-size:13px;color:#8a95a7;white-space:nowrap}.task-filters{display:flex;gap:12px;margin-bottom:20px}.task-filters input,.task-filters select{background:#fff;border:1px solid #dfe4ee;border-radius:6px;padding:11px 13px;font:inherit;font-size:13px;color:#48566d}.task-filters input{width:320px;max-width:100%}.task-filters input:focus,.task-filters select:focus{outline:2px solid #4665cf44;outline-offset:1px}.task-table-scroll{overflow:auto;border:1px solid #e0e5ee;border-radius:8px;background:#fff}.task-table{width:100%;border-collapse:collapse;text-align:left;font-size:13px}.task-table th{background:#f1f3f7;color:#8a95a6;font-weight:400;font-size:11px;padding:14px 18px;white-space:nowrap;position:sticky;top:0}.task-table td{border-top:1px solid #e9edf3;padding:19px 18px;vertical-align:middle}.task-table tr:hover td{background:#fafbfe}.task-number{color:#a0aabc;width:52px;font-variant-numeric:tabular-nums}.task-name{min-width:240px}.task-title-link{padding:0;color:#344258;font-weight:500;font-size:14px;text-align:left}.task-title-link:hover{color:#4665cf}.task-name p{font-size:12px;color:#929daf;line-height:1.5;margin:7px 0 0;max-width:440px}.task-difficulty,.task-duration{color:#7f8a9c;white-space:nowrap}.task-status{font-size:11px;white-space:nowrap;padding:5px 8px;border-radius:4px;background:#f2f4f7;color:#8c97a8}.task-status.started{background:#fff5e9;color:#a17b45}.task-status.complete{background:#eef2fd;color:#4665cf}.task-action{text-align:right;white-space:nowrap}.task-open{padding:8px 10px;color:#4665cf;font-size:12px;border:1px solid #e0e6f2;border-radius:5px}.task-open:hover{background:#eef2fd;border-color:#b9c7e8}.tasks-pagination{display:flex;align-items:center;justify-content:space-between;margin:17px 0 30px;font-size:12px;color:#929daf}.tasks-pagination>div{display:flex;align-items:center;gap:13px}.tasks-pagination button{border:1px solid #dfe5ee;border-radius:5px;background:white;padding:6px 10px;color:#6b7b96}.tasks-pagination button:disabled{opacity:.35;cursor:default}.tasks-page .tasks-preserve{max-width:none}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}.restart-task-button{font-size:12px;color:#647590;border:1px solid #dce3ef;border-radius:6px;background:white;padding:9px 12px;white-space:nowrap}.restart-task-button:hover{border-color:#aebdde;color:#4665cf}.restart-task-button[hidden]{display:none}#restart-task{font-size:12px;padding:8px 10px;border:1px solid #dce3ef;border-radius:5px;text-decoration:none;color:#5f718d}
@media(max-width:900px){.task-difficulty{display:none}.task-table th,.task-table td{padding:14px 12px}.task-name{min-width:210px}.task-name p{max-width:320px}}
@media(max-width:600px){.task-catalog-heading{align-items:flex-start}.task-total{padding-top:18px}.task-filters{flex-wrap:wrap}.task-filters input{flex:1;min-width:160px}.task-filters select{max-width:150px}.task-number,.task-duration{display:none}.task-table th,.task-table td{padding:13px 10px}.task-name{min-width:170px}.task-name p{display:none}.task-title-link{font-size:12px}.task-status{font-size:10px;padding:4px}.task-open{font-size:10px;padding:7px}.task-active .canvas-actions{bottom:140px;right:12px}.task-active.task-collapsed .canvas-actions{bottom:140px}.tasks-page{padding:28px 16px}}

.port.left,.port.right{top:50%;transform:translateY(-50%)}.port.top,.port.bottom{left:50%;transform:translateX(-50%)}

.task-filters{flex-wrap:wrap}.library-item span{overflow-wrap:anywhere}.task-difficulty{font-weight:500}@media(max-width:900px){.task-table .task-difficulty{display:table-cell}}@media(max-width:600px){.task-table .task-difficulty{display:none}}

.task-name p{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}@media(max-width:600px){.task-name p{display:none}}
.account-button{margin-left:auto;max-width:240px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:9px 16px;border:1px solid #d8deea;border-radius:8px;background:white;color:#4665cf;font:inherit;font-size:13px;cursor:pointer}#account-dialog{width:min(440px,calc(100vw - 32px));max-height:85vh;overflow:auto;padding:30px;border:1px solid #d8deea;border-radius:16px;color:#303746}#account-dialog::backdrop{background:#1b24334d}#account-dialog h2{font-size:25px;margin:12px 0}#account-dialog p{font-size:13px;line-height:1.6;color:#657086}#account-dialog form{display:grid;gap:10px}#account-dialog label{font-size:13px}#account-dialog input{width:100%;box-sizing:border-box;border:1px solid #d8deea;border-radius:8px;padding:11px;font:inherit}#account-dialog button{cursor:pointer}#account-dialog button:disabled{opacity:.5;cursor:wait}.account-close{float:right;background:none;border:0;font-size:24px}.google-login{width:100%;padding:12px;background:white;border:1px solid #d8deea;border-radius:8px;font:inherit;margin-top:12px}.auth-divider{text-align:center;margin:18px 0;color:#657086;font-size:12px}.auth-actions{display:flex;gap:10px;margin:4px 0 10px}.auth-actions button{flex:1;padding:11px;border:1px solid #d8deea;border-radius:8px}.phone-auth{margin-top:20px;border-top:1px solid #e6eaf0;padding-top:16px}.phone-auth summary{cursor:pointer;font-size:14px;margin-bottom:14px}#account-dialog #account-message{color:#b34a46}#account-signout{display:block;margin-top:20px;padding:10px 16px;background:white;border:1px solid #d8deea;border-radius:8px}@media(max-width:600px){.account-button{max-width:100px;padding:8px}.main-nav{gap:10px}#account-dialog{padding:22px}}
.role-badge{display:inline-block;border:1px solid #d8d7ce;border-radius:20px;padding:5px 12px;font-size:12px}.task-edit{display:block;margin:8px 0 0 auto;font-size:12px;color:#565f47;text-decoration:underline;background:none;border:0;cursor:pointer}#task-editor{width:min(860px,94vw);max-height:90vh;box-sizing:border-box;padding:32px;border:1px solid #ccc8ba;border-radius:18px;background:#faf9f4;color:#242922}#task-editor::backdrop{background:rgba(30,35,28,.4)}#task-editor h2{font-size:28px;margin:8px 0}#task-editor h3{margin:28px 0 12px}#task-editor p{font-size:14px;line-height:1.5;color:#62665c}#task-editor label{display:flex;flex-direction:column;gap:6px;font-size:13px;font-weight:500}#task-editor input:not([type=checkbox]),#task-editor textarea,#task-editor select{font:inherit;box-sizing:border-box;width:100%;border:1px solid #cfcec5;border-radius:7px;padding:10px;background:white;color:#242922}#task-editor textarea{resize:vertical}.editor-fields{display:grid;grid-template-columns:1fr 1fr;gap:16px}.editor-fields label:nth-child(n+3):nth-child(-n+6){grid-column:1/-1}.editor-connection{display:grid;grid-template-columns:1fr 1fr 2fr auto;align-items:end;gap:10px;margin-bottom:12px}#editor-rules fieldset{border:1px solid #d8d5cb;border-radius:10px;padding:14px;display:grid;gap:10px;margin:16px 0}#editor-rules legend label{display:block;font-size:14px}#editor-rules input[type=checkbox]{accent-color:#4f6542}.editor-footer{display:flex;justify-content:flex-end;gap:12px;position:sticky;bottom:-32px;background:#faf9f4;padding:18px 0}#task-editor button:not(.primary):not(.dialog-close){border:1px solid #cacbbf;padding:9px 13px;border-radius:7px;background:#fff;font:inherit;cursor:pointer}#task-editor-message{color:#a3332a!important}#task-editor input:focus,#task-editor textarea:focus,#task-editor select:focus{outline:2px solid #87957b;outline-offset:2px}@media(max-width:650px){#task-editor{padding:22px}.editor-fields,.editor-connection{grid-template-columns:1fr}.editor-footer{bottom:-22px}}
.brand-name{font-family:'Neucha',cursive;font-size:32px;font-weight:400;letter-spacing:.1px;transform:rotate(-1.5deg);gap:7px}.brand-name>span{font-weight:400;letter-spacing:0;transform:rotate(2deg) translateY(1px)}.brand-symbol{transform:rotate(-2deg)}.edge-handle{pointer-events:all!important;cursor:grab;fill:white;stroke:#4665cf;stroke-width:2}#edge-sides{display:flex;gap:8px}#edge-sides[hidden]{display:none}#edge-sides label{font-size:11px;display:grid;gap:3px}#edge-sides select{max-width:135px;font:inherit;padding:5px;border:1px solid #d9dce3;border-radius:5px;background:#fff}.save-drawing{display:flex;align-items:center;gap:6px;border:1px solid #d9dce3;border-radius:7px;background:white;color:#4665cf;padding:9px 12px;font:500 13px 'Golos Text';cursor:pointer}.save-drawing svg{width:19px;height:19px}.save-drawing:disabled{opacity:.5}.selection-panel{flex-wrap:wrap;max-width:min(420px,calc(100% - 24px))}@media(max-width:750px){.brand-name{font-size:27px}.save-drawing span{display:none}.save-drawing{padding:8px}}@media(max-width:450px){.brand-name{font-size:22px;gap:4px}.selection-panel{top:110px}}

.canvas-actions,.task-active:not(.task-collapsed) .canvas-actions,.task-active.task-collapsed .canvas-actions{display:flex;top:20px;bottom:auto}.save-drawing{width:40px;height:40px;padding:9px;justify-content:center}.save-drawing svg{width:21px;height:21px}@media(max-width:750px){.canvas-actions,.task-active:not(.task-collapsed) .canvas-actions,.task-active.task-collapsed .canvas-actions{top:14px;bottom:auto;right:12px}}
#task-editor.admin-task-panel{position:absolute;right:0;top:0;bottom:0;width:390px;max-width:none;max-height:none;box-sizing:border-box;margin:0;padding:28px 22px;overflow:auto;z-index:5;border:0;border-left:1px solid #dce1e9;border-radius:0;background:#fff;color:#303746}#task-editor.admin-task-panel[hidden]{display:none}#task-editor.admin-task-panel h2{font-size:24px}.admin-task-panel .editor-fields{grid-template-columns:1fr;gap:12px}.admin-task-panel .editor-fields label{grid-column:1!important}.admin-task-panel .editor-connection{grid-template-columns:1fr 1fr}.admin-task-panel .editor-connection label:nth-child(3){grid-column:1/-1}.admin-task-panel .editor-footer{bottom:-28px;background:#fff;padding:15px 0}.reference-mode{flex-direction:row!important;align-items:center;margin:20px 0 5px}.reference-mode input{width:auto!important}.reference-note{font-size:12px!important}.admin-task-panel details{margin:22px 0}.admin-task-panel summary{cursor:pointer;font-size:13px;color:#657086}.admin-editing .canvas-actions{right:410px!important;top:20px!important}.admin-editing .document-bar{max-width:calc(100% - 760px)}.admin-editing .main-nav #show-tasks{color:#354e9e}.admin-saving #canvas{pointer-events:none;opacity:.7}.admin-editing #task-panel,.admin-editing #task-empty,.admin-editing #expand-task{display:none!important}@media(max-width:750px){#task-editor.admin-task-panel{top:auto;bottom:0;width:100%;height:45vh;border-top:1px solid #dce1e9;border-left:0;padding:20px}body.admin-editing .workspace{position:relative}body.admin-editing #canvas{height:calc(100% - 45vh);align-self:flex-start}.admin-editing aside{bottom:calc(45vh + 12px)}.admin-editing .canvas-actions{right:12px!important;top:14px!important}.admin-editing .document-bar{max-width:calc(100% - 225px)}.admin-task-panel .editor-footer{bottom:-20px}.admin-editing #task-editor .editor-fields{grid-template-columns:1fr 1fr}}

.admin-editing .tools{left:calc((100% + 302px - 390px)/2)}.admin-editing .zoom,.admin-editing .selection-panel{right:410px}.admin-editing .zoom{bottom:90px}.admin-editing .canvas-hint{display:none}@media(max-width:750px){.admin-editing .tools{left:50%;bottom:12px}.admin-editing .zoom{right:12px;bottom:65px}.admin-editing .selection-panel{right:12px;top:65px}}
.editor-icon-picker{margin:0 0 24px}.editor-icon-picker>p{font-size:14px;line-height:1.5;color:#657086}.editor-icon-picker summary{margin:16px 0;cursor:pointer;font-weight:600}.editor-icon-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.editor-icon-choice{position:relative;display:flex;flex-direction:column;align-items:center;gap:6px;padding:12px 5px 8px;min-width:0;border:1px solid #dce2ec!important;border-radius:10px;background:white;font-size:14px!important;line-height:1.3}.editor-icon-choice:hover{background:#f0f3ff;border-color:#4665cf!important}.editor-icon-choice img{width:50px;height:46px;object-fit:contain}.editor-icon-action{position:absolute;top:3px;right:8px;font-size:20px;color:#4665cf}.editor-icon-picker input{width:100%}

.port::before{content:"";position:absolute;width:calc(32px / var(--canvas-zoom,1));height:calc(32px / var(--canvas-zoom,1));left:50%;top:50%;transform:translate(-50%,-50%);border-radius:50%}.port:hover{background:#dfe7ff;box-shadow:0 0 0 7px #4665cf18}
.task-add-icon{width:100%;padding:11px 12px;margin:14px 0;border:1px dashed #aab8da;border-radius:8px;background:#f5f7ff;color:#354e9e;font:500 14px 'Golos Text';cursor:pointer}.task-add-icon[hidden]{display:none}.library-entry{position:relative;min-width:0}.library-entry>.library-item{width:100%}.library-remove{position:absolute;right:3px;top:3px;width:24px;height:24px;border:1px solid #dce2ec;border-radius:50%;background:white;color:#657086;font-size:19px;line-height:1;cursor:pointer}.library-remove:hover{color:#a3332a;background:#fff1ed}#task-icon-dialog{width:min(620px,calc(100vw - 32px));max-height:85vh;overflow:auto;padding:28px;border:1px solid #dce1e9;border-radius:16px;color:#303746;background:white}#task-icon-dialog::backdrop{background:#202a4655}#task-icon-dialog h2{margin:0 30px 20px 0;font-size:25px}.icon-dialog-search{display:grid;gap:7px;font-size:14px;margin-bottom:20px}.icon-dialog-search input{padding:12px;border:1px solid #dce1e9;border-radius:8px;font:inherit;width:100%;box-sizing:border-box}#task-icon-dialog .editor-icon-grid{grid-template-columns:repeat(4,minmax(0,1fr))}#task-icon-dialog .editor-icon-choice{min-height:105px;cursor:pointer}#task-icon-dialog .editor-icon-choice:disabled{opacity:.5;cursor:default;background:#f5f7fb}#task-icon-message{font-size:14px;color:#2b6841;min-height:20px}#task-icon-done{display:block;margin-left:auto}@media(max-width:500px){#task-icon-dialog{padding:20px}#task-icon-dialog .editor-icon-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}

/* Task text stays in its reader layout until a field is explicitly edited. */
#task-editor .editor-panel-title{font-size:18px;margin:12px 0 5px}#task-editor .editor-panel-note{font-size:12px;color:#79859a;margin:0 0 18px}#task-editor .editor-check-settings{margin:0 0 22px}#task-editor .editor-fields{display:block}#task-editor .editor-preview-field{position:relative;padding-right:34px;min-width:0}#task-editor .editor-preview-value{white-space:pre-wrap;overflow-wrap:anywhere;margin:0}#task-editor .editor-preview-value[hidden],#task-editor .editor-field-edit[hidden]{display:none}#task-editor button.editor-field-edit{position:absolute;right:0;top:0;display:grid;place-items:center;width:28px;height:28px;padding:5px;border:0;background:transparent;color:#8b95a5;border-radius:6px}#task-editor .editor-field-edit .ui-icon{width:17px;height:17px}#task-editor button.editor-field-edit:hover{background:#eef2fd;color:#4665cf}#task-editor button.editor-field-edit:focus-visible{outline:2px solid #4665cf;outline-offset:2px}#task-editor .editor-preview-meta{display:flex;align-items:flex-start;flex-wrap:wrap;gap:8px 14px;margin-bottom:14px}#task-editor .editor-preview-meta .editor-preview-value{font-size:11px;line-height:28px;color:#8b95a5}#task-editor .editor-preview-heading h2{font-size:25px;letter-spacing:-.8px;line-height:1.15;margin:0 0 15px}#task-editor .editor-preview-story p{font-size:13px;line-height:1.7;color:#727d8f;margin:0 0 18px}#task-editor .editor-preview-section{padding:16px 0;border-top:1px solid #e2e7ef}#task-editor .editor-preview-section h3{font-size:12px;font-weight:500;margin:0 0 8px;color:#303746}#task-editor .editor-preview-section p{font-size:12px;color:#8993a4;line-height:1.6}#task-editor .editor-preview-success .editor-preview-field{padding:12px 42px 12px 12px;background:#eaf7ed;border-radius:7px}#task-editor .editor-preview-success p{color:#2b6841}#task-editor .editor-preview-success .editor-field-edit{top:8px;right:6px}#task-editor .editor-preview-catalog h4{font-size:14px;font-weight:500;margin:0 0 8px}#task-editor .editor-preview-catalog .editor-preview-field+.editor-preview-field{margin-top:8px}#task-editor .editor-preview-field.is-editing{padding-right:0;margin-bottom:12px}#task-editor .editor-preview-field input,#task-editor .editor-preview-field textarea,#task-editor .editor-preview-field select{border-color:#c8d4ee;color:#303746;font-size:13px;line-height:1.6}#task-editor .editor-preview-field :is(input,textarea,select):focus{outline:2px solid #4665cf;outline-offset:1px}#task-editor .editor-inline-actions{display:flex;gap:8px;margin-top:8px}#task-editor .editor-inline-actions button{font-size:12px;padding:6px 10px;border-color:#dce1e9}#task-editor .editor-inline-actions button:first-child{color:#354e9e;background:#eef2fd;border-color:#d8e1fa}#task-editor .editor-preview-meta .is-editing{flex-basis:100%}#task-editor #reference-preview{width:100%;font-size:13px;color:#354e9e;border-color:#dce1e9;margin:4px 0 0}#task-editor .editor-footer{gap:8px;border-top:1px solid #e2e7ef;box-shadow:0 -8px 14px #ffffffee}#task-editor .editor-footer button{white-space:nowrap;font-size:12px;padding:10px 12px}#task-editor .editor-footer .primary{flex:1}#task-editor button:disabled{opacity:.5;cursor:wait}
#task-editor.admin-task-panel button.editor-field-edit{box-sizing:border-box;border:0;padding:5px;background:transparent}#task-editor.admin-task-panel button.editor-field-edit:hover{background:#eef2fd}#task-editor.admin-task-panel .editor-inline-actions button{font-size:12px;padding:6px 10px}

#task-editor #task-editor-message[data-status="saved"]{color:#2b6841!important}#task-editor #task-editor-message[data-status="saving"]{color:#657086!important}
.library-rename{position:absolute;left:3px;top:3px;display:grid;place-items:center;width:24px;height:24px;padding:4px;border:1px solid #dce2ec;border-radius:6px;background:#fff;color:#657086;cursor:pointer}.library-rename .ui-icon{width:15px;height:15px}.library-rename:hover{color:#4665cf;background:#eef2fd}#task-element-dialog{width:min(460px,calc(100vw - 32px));box-sizing:border-box;padding:28px;border:1px solid #dce1e9;border-radius:16px;background:#fff;color:#303746}#task-element-dialog::backdrop{background:#202a4655}#task-element-dialog h2{margin:0 30px 22px 0;font-size:23px}.task-element-identity{display:flex;align-items:center;gap:18px}.task-element-identity img{width:82px;height:82px;object-fit:contain}.task-element-identity label{flex:1;min-width:0;display:grid;gap:8px;font-size:13px}.task-element-identity input{width:100%;box-sizing:border-box;padding:11px;border:1px solid #dce1e9;border-radius:8px;color:#303746;font:inherit}.task-element-identity input:focus{outline:2px solid #4665cf;outline-offset:1px}.task-element-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:24px}.task-element-actions button{padding:10px 14px;border:1px solid #dce1e9;border-radius:8px;background:#fff;font:inherit;font-size:13px;cursor:pointer}.task-element-actions .primary{background:#2b303b;color:#fff}.library-rename:focus-visible{outline:2px solid #4665cf;outline-offset:2px}
/* Project library and inspector. */
#search{width:100%;box-sizing:border-box;border:1px solid #dce1e9;border-radius:8px;padding:10px 12px;margin:10px 0 0;background:#fff;font:inherit;font-size:13px}#search[hidden],#create-element[hidden]{display:none}.tabs{flex-wrap:wrap;gap:4px}.tabs button{padding:7px 9px}#create-element{margin:10px 0}.project-properties{position:absolute;right:0;top:0;bottom:0;width:300px;box-sizing:border-box;padding:24px 20px;overflow:auto;background:#fff;border-left:1px solid #dce1e9;z-index:5}.project-properties[hidden]{display:none}.property-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:22px}.property-heading h2{font-size:17px;margin:0}.property-heading button{border:0;background:none;color:#8993a4;font-size:24px;cursor:pointer}.property-empty{color:#8993a4;font-size:13px;line-height:1.7}.property-kind{font-size:11px;color:#8993a4;margin:0 0 10px}.property-icon{display:block;width:95px;height:85px;object-fit:contain;margin:0 auto 20px}#property-fields label{display:grid;gap:8px;margin:16px 0;font-size:12px;color:#657086}#property-fields input,#property-fields select{width:100%;box-sizing:border-box;border:1px solid #dce1e9;border-radius:8px;padding:10px;background:white;font:inherit;color:#303746;font-size:13px}#property-fields :is(input,select):focus{outline:2px solid #4665cf;outline-offset:1px}.property-button{width:100%;border:1px solid #dce1e9;border-radius:8px;padding:10px;margin:4px 0;background:#fff;color:#657086;font:inherit;font-size:12px;cursor:pointer}.threat-action{color:#bd4355;border-color:#edc5cb;background:#fff5f6}.project-properties #selection-panel{position:static;display:flex;flex-wrap:wrap;padding:14px 0;margin-top:20px;border:0;border-top:1px solid #e2e7ef;box-shadow:none;background:#fff;max-width:100%;transform:none}.project-properties #selection-panel[hidden]{display:none}.project-properties #selection-panel>span{display:none}.project-properties #edge-sides{width:100%;margin-bottom:12px}.project-properties #edge-sides label{flex:1}.project-properties #edge-sides select{width:100%}.project-properties-open .canvas-actions{right:320px}.project-properties-open .zoom{right:320px}.project-properties-open .tools{left:calc((100% + 302px - 300px)/2)}.project-properties-open .canvas-hint{right:320px}.edge-label{font:12px 'Golos Text';paint-order:stroke;stroke:#fff;stroke-width:5px;stroke-linejoin:round;pointer-events:all;cursor:pointer}
#custom-element-dialog{width:min(470px,calc(100vw - 32px));box-sizing:border-box;padding:28px;border:1px solid #dce1e9;border-radius:16px;background:white;color:#303746}#custom-element-dialog::backdrop{background:#202a4655}#custom-element-dialog h2{margin:0 35px 20px 0;font-size:24px}#custom-element-preview{display:block;width:90px;height:80px;object-fit:contain;margin:0 auto 20px}#custom-element-form label{display:grid;gap:8px;margin:16px 0;font-size:13px}#custom-element-form :is(input:not([type=checkbox]),select){box-sizing:border-box;max-width:100%;width:100%;border:1px solid #dce1e9;border-radius:8px;padding:11px;background:white;font:inherit;color:#303746}#custom-element-form .custom-threat-toggle{display:flex;align-items:center;gap:8px}.upload-note{font-size:11px;color:#8993a4}#custom-element-error{color:#bd4355;font-size:12px}#custom-element-submit{display:block;width:100%;margin-top:20px}#custom-element-submit:disabled{opacity:.5}.project-properties-open .canvas-document{max-width:calc(100% - 610px)}
@media(max-width:1000px){.project-properties{top:auto;bottom:78px;right:12px;width:270px;max-height:55vh;border:1px solid #dce1e9;border-radius:12px;padding:18px}.project-properties-open .canvas-actions{right:12px}.project-properties-open .zoom{right:12px}.project-properties-open .tools{left:50%}.project-properties-open .canvas-hint{display:none}.project-properties .property-heading{margin-bottom:12px}.property-icon{height:55px;margin-bottom:10px}}

/* Give the library the full workspace height and keep its controls compact. */
.workspace>aside{left:0;top:0;bottom:0;width:282px;padding:16px 14px 0;border-radius:0;border-top:0;border-bottom:0;border-left:0;box-shadow:none}
.workspace>aside>*{flex-shrink:0}
.library-heading h1{font-size:18px}
.library-controls{display:flex;align-items:center;gap:6px;margin-top:12px}
.library-controls[hidden]{display:none}
.library-controls #search{flex:1;min-width:0;width:0;height:34px;padding:7px 10px;margin:0;font-size:12px;border-radius:6px;background:#fafbfc}
.library-controls #create-element{flex:0 0 34px;width:34px;height:34px;margin:0;padding:0;border:1px solid #dce1e9;border-radius:6px;background:#f5f7ff;color:#354e9e;font-size:24px;line-height:1}
.library-controls #create-element:hover{background:#e8edfc;border-color:#aab8da}
aside .tabs{margin:10px 0 8px;padding-bottom:8px;gap:2px}
aside .tabs button{padding:6px 8px;font-size:11px}
aside .collection{display:none}
.task-active aside .collection{display:flex;margin:8px 0 10px;gap:8px;line-height:1.5}
aside #task-add-icon{padding:8px 10px;margin:10px 0;font-size:12px}
.workspace>aside>.icon-grid{min-height:0;flex:1;gap:4px;padding:0 0 8px;overscroll-behavior:contain;scrollbar-gutter:stable}
aside .library-item{height:118px;padding:5px 3px;gap:3px}
aside .library-item img{width:88px;height:88px}
aside .library-item span{font-size:11px;line-height:1.3}
aside .sidebar-note{margin:0 -14px;padding:7px 14px;justify-content:center}
aside .sidebar-note p{font-size:10px;line-height:1.4}
@media(min-width:751px) and (max-width:1000px){.tools,.task-active .tools,.task-active.task-collapsed .tools,.project-properties-open .tools{left:calc(50% + 141px);gap:1px;padding:5px}.tools button{width:34px;height:36px}.tools>span{margin:0 3px}}
@media(max-width:750px){.workspace>aside{width:172px;bottom:78px;padding:12px 10px 0;border-bottom:1px solid var(--border);border-bottom-right-radius:10px}.library-controls{margin-top:10px;gap:4px}.library-controls #search{padding:6px;font-size:11px}.library-controls #create-element{flex-basis:30px;width:30px}.library-heading h1{font-size:16px}aside .tabs{margin-top:8px;gap:1px}aside .tabs button{padding:5px 6px;font-size:10px}aside .library-item{height:104px}aside .library-item img{width:64px;height:64px}aside .library-item span{font-size:10px}.workspace>aside>.icon-grid{gap:2px}aside .sidebar-note{display:none}}
@media(max-width:450px){.workspace>aside{width:126px;padding:12px 8px 0}.library-heading h1{font-size:14px}.library-controls{flex-wrap:wrap}.library-controls #search{flex-basis:100%;width:100%}.library-controls #create-element{flex-basis:100%;height:28px;font-size:21px}.workspace>aside>.icon-grid{margin-top:8px}aside .library-item{height:108px}aside .library-item img{width:78px;height:78px}aside .library-item span{font-size:11px}}

/* Tool lock follows the active-tool styling and stays usable on small screens. */
.tools #tool-lock.active{background:var(--accent-soft);color:var(--accent)}
@media(max-width:450px){.tools{gap:0;padding:4px}.tools button{width:29px}.tools>span{margin:0 2px}}
@media(min-width:1001px){.project-properties-open .zoom{bottom:100px}}

/* Hover remains visible even when a tool is already selected or locked. */
.tools button.active:hover:not(:disabled),.tools #tool-lock.active:hover:not(:disabled){background:#dce5ff;color:#304eb9;box-shadow:inset 0 0 0 1px #aebfe9}
.tools button>.ui-icon{pointer-events:none}
.tools button:disabled{box-shadow:none;cursor:not-allowed}

/* Connection mode uses the drawing cursor across the whole component. */
#canvas.connect .node:not(.group),#canvas.connect .node:not(.group) .node-label:not([contenteditable=true]){cursor:crosshair}

/* Screen-space marquee follows the canvas zoom and never intercepts input. */
#selection-marquee{position:absolute;border:1px solid var(--accent);background:#4665cf14;z-index:3;pointer-events:none}
#selection-marquee[hidden]{display:none}

/* Toolbar feedback is immediate, including after canvas selection. */
.tools button{transition:none}

/* Folders group independent exercises and ordered journeys. */
.task-folders{display:flex;flex-wrap:wrap;gap:10px;margin:0 0 22px}
.task-folder{display:flex;align-items:center;gap:12px;padding:12px 15px;background:#fff;border:1px solid var(--border);border-radius:8px;font-size:13px;color:#657086}
.task-folder:hover{background:#f3f5fa;border-color:#bdc9e2}
.task-folder.active{background:var(--accent-soft);border-color:#b4c3ec;color:#354e9e}
.folder-count{font-size:11px;padding:2px 5px;border-radius:4px;background:#eef1f6;font-variant-numeric:tabular-nums}
.editor-journey label{display:grid;gap:8px;margin:14px 0;font-size:12px}
.editor-journey input,.editor-journey select{box-sizing:border-box;width:100%;max-width:100%;border:1px solid #dce1e9;border-radius:6px;padding:9px;background:#fff;color:#303746;font:inherit}
@media(max-width:600px){.task-folder{font-size:12px;padding:10px;gap:8px}.task-folders{gap:8px}}

.task-folder>.ui-icon{width:18px;height:18px}
@media(max-width:600px){.task-table .task-name{min-width:130px}.task-table td{padding:13px 8px}.task-table .task-status{font-size:9px;padding:5px}.task-table .task-open{padding:7px 5px}}
/* Protection badges keep a readable screen size and open the same editor in tasks and projects. */
.edge-protection{pointer-events:all;cursor:pointer}
.edge-protection circle{fill:#fff;stroke:#86b698}
.edge-protection:hover circle,.edge-protection:focus-visible circle{fill:#edf7e9;stroke:#4665cf}
.edge-protection image,.edge-protection text{pointer-events:none}
.edge-protection text{fill:#3c7958;font-family:'Golos Text',sans-serif;font-weight:500}
#edge-protection-dialog{width:min(570px,calc(100vw - 32px));max-width:570px;max-height:85dvh;overflow:auto;padding:26px}
#edge-protection-title{margin:0 30px 8px 0;font-size:23px}
#edge-protection-caption{margin:0;color:#a14956;font-size:13px}
#edge-protection-choices{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:18px 0}
.protection-choice{position:relative;min-width:0;display:flex;flex-direction:column;align-items:center;gap:8px;padding:12px 6px;border:1px solid #e1e8de;border-radius:9px;background:#fcfdfb;color:#526951;font-size:12px}
.protection-choice img{width:80px;height:80px;object-fit:contain;pointer-events:none}
.protection-choice:hover{background:#f0f7ea;border-color:#a8c5a5}
.protection-choice[aria-pressed=true]{background:#edf6e7;border-color:#80ab7e}
.protection-check{position:absolute;right:7px;top:5px;color:#518251;font-size:18px}
#edge-protection-done{display:block;margin-left:auto}
.protection-action{color:#427a54;border-color:#b8d3b3;background:#f5fbf1}
@media(max-width:450px){#edge-protection-dialog{padding:20px}#edge-protection-choices{grid-template-columns:repeat(2,minmax(0,1fr))}}
/* Panning belongs to the world transform; focusing badges must not scroll the canvas. */
#canvas{overflow:clip}
.protection-drag-ghost{position:fixed;z-index:20;width:54px;height:54px;display:grid;place-items:center;transform:translate(-50%,-50%);pointer-events:none;background:#fff;border:1px solid #86b698;border-radius:50%;box-shadow:0 4px 16px #27365420}
.protection-drag-ghost img{width:44px;height:44px}
.edge-line.protection-drop-target{stroke:#639b69;stroke-width:4px}
.tabs button[hidden]{display:none}
.node.connection-target{outline:2px solid #4665cf;outline-offset:5px;border-radius:10px}
/* Task brief sits below the canvas; the right sidebar always shows properties. */
.task-active .workspace{--task-dock-height:min(260px,34vh);--task-space:var(--task-dock-height)}.task-active.task-collapsed .workspace{--task-space:44px}
.task-active #task-panel{left:302px;right:300px;top:auto;bottom:0;width:auto;height:var(--task-dock-height);box-sizing:border-box;border-radius:0;border:0;border-top:1px solid var(--border);padding:14px 20px;overflow:hidden;box-shadow:0 -4px 18px #222d4907}
.task-active .task-panel-top{height:22px;margin:0 0 12px}.task-active #task-details{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) 180px;gap:22px;height:calc(100% - 34px);min-height:0}
.task-active .task-summary,.task-active .task-conditions{overflow:auto;min-height:0;padding-right:6px;scrollbar-width:thin}.task-active #task-panel h2{font-size:21px;margin:8px 0}.task-active .task-story{margin-bottom:12px}.task-active .task-requirements{padding:10px 0;border-bottom:0}.task-active .task-progress{margin-top:0}.task-active #task-checklist{margin:12px 0;gap:8px}
.task-active .task-panel-bottom{position:static;margin:0;padding:0 0 0 18px;border-top:0;border-left:1px solid var(--border);box-shadow:none;overflow:auto}.task-active .task-secondary-actions{flex-wrap:wrap;gap:10px}.task-active .tools,.task-active.task-collapsed .tools{bottom:calc(var(--task-space) + 16px);left:calc((100% + 302px - 300px)/2)}.task-active .zoom{bottom:calc(var(--task-space) + 90px)}.task-active .canvas-hint{display:none}
.task-active #expand-task{left:302px;right:300px;top:auto;bottom:0;height:44px;box-sizing:border-box;border-radius:0;justify-content:flex-start}.task-active #task-empty{left:calc((100% + 302px - 300px)/2);top:30%;opacity:1}
@media(max-width:1200px){.task-active #task-details{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.task-active .task-panel-bottom{grid-column:1/-1;border-left:0;border-top:1px solid var(--border);padding:12px 0}.task-active #task-panel{overflow:auto}.task-active #task-details{height:auto}.task-active .task-panel-bottom>.primary{width:auto;padding:10px 20px}.task-active .task-panel-bottom>p{display:none}.task-active .task-secondary-actions{display:inline-flex;margin-left:15px}}
@media(max-width:1000px){.task-active #task-panel,.task-active #expand-task{right:0}.task-active .tools,.task-active.task-collapsed .tools{left:calc((100% + 302px)/2)}.task-active .project-properties{bottom:calc(var(--task-space) + 78px);max-height:calc(100% - var(--task-space) - 100px)}.task-active #task-empty{left:calc((100% + 302px)/2)}}
@media(max-width:750px){.task-active #task-panel,.task-active #expand-task{left:182px;padding:12px}.task-active #task-details{grid-template-columns:1fr;gap:14px}.task-active .task-panel-bottom{grid-column:auto}.task-active .task-secondary-actions{display:flex;margin:12px 0 0}.task-active .tools,.task-active.task-collapsed .tools{left:50%}.task-active #task-empty{left:calc((100% + 182px)/2)}}
@media(max-width:450px){.task-active #task-panel,.task-active #expand-task{left:136px}.task-active #task-empty{left:calc((100% + 136px)/2);width:170px}.task-active #task-panel h2{font-size:18px}}
#collapse-task{display:grid;place-items:center;width:30px;height:30px;border-radius:6px;flex-shrink:0}#collapse-task:hover{background:#eef2fd;color:#4665cf}#collapse-task:focus-visible{outline:2px solid #4665cf;outline-offset:2px}
.library-item.library-previewing{background:#eef2fd;box-shadow:inset 0 0 0 1px #afbee8;border-radius:8px}#property-actions[hidden]{display:none}.property-button:disabled{opacity:.5;cursor:default}body.admin-library-preview .project-properties{width:390px;z-index:6}.sidebar-note p{line-height:1.5}
.property-description{margin:16px 0 20px;padding:14px;background:#f5f7fb;border:1px solid #e4e9f1;border-radius:10px}.property-description h3{font-size:12px;font-weight:600;color:#4d5d78;margin:0 0 7px}.property-description h3:not(:first-child){margin-top:14px}.property-description p{font-size:13px;line-height:1.65;color:#657086;margin:0;overflow-wrap:anywhere}
.community-page{height:calc(100dvh - 80px);overflow:auto;background:#f8f9fc}.community-page[hidden]{display:none}.community-inner{max-width:1150px;margin:0 auto;padding:48px 32px 80px}.community-heading{display:flex;gap:24px;align-items:start;justify-content:space-between}.community-heading h1{font-size:36px;letter-spacing:-1px;margin:12px 0}.community-heading p{max-width:640px;font-size:14px;line-height:1.7;color:#7d89a0}.community-create{display:flex;gap:8px;flex-shrink:0}.community-create button{font-size:12px;padding:12px 15px}.community-tabs{display:flex;gap:8px;border-bottom:1px solid #dce1e9;padding:20px 0 12px;flex-wrap:wrap}.community-tabs button{padding:10px 14px;border-radius:7px;color:#7d89a0;font-size:13px}.community-tabs .active{background:#eef2fd;color:#4665cf}.community-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;margin-top:24px}.community-card{background:white;border:1px solid #e0e5ee;border-radius:12px;padding:24px;display:flex;flex-direction:column;align-items:start;min-width:0}.community-card>img{width:90px;height:85px;object-fit:contain;align-self:center;margin-bottom:18px}.community-card h2{font-size:20px;margin:4px 0 10px;overflow-wrap:anywhere}.community-card>p{font-size:13px;line-height:1.65;color:#7d89a0;white-space:pre-wrap;overflow-wrap:anywhere}.community-author{font-size:11px!important;margin-top:auto}.community-card-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px;width:100%}.community-card-actions button{font-size:12px}.community-empty{grid-column:1/-1;color:#7d89a0;font-size:14px;padding:30px 0}.community-status{display:inline-block;font-size:11px;padding:5px 9px;border-radius:5px;background:#f1f3f8;color:#7d89a0}.community-status.pending{background:#fff4df;color:#a4712c}.community-status.approved{background:#eaf7ed;color:#2b6841}.community-status.rejected{background:#fff0f1;color:#b44d61}.community-review-note{padding:10px;background:#fff6eb;border-radius:6px}.community-dialog{width:min(760px,calc(100vw - 32px));max-height:calc(100dvh - 40px);box-sizing:border-box;padding:30px;border:1px solid #dce1e9;border-radius:14px;overflow:auto;color:#303746}.community-dialog::backdrop{background:#202a4655}.community-dialog h2{font-size:25px;margin:0 32px 18px 0}.community-dialog h3{font-size:14px;margin-top:22px}.community-dialog p{font-size:13px;line-height:1.7;color:#7d89a0;white-space:pre-wrap;overflow-wrap:anywhere}.community-field{display:grid;gap:8px;font-size:13px;color:#657086;margin:18px 0}.community-field input,.community-field textarea,.community-field select,.community-reference select{padding:11px;box-sizing:border-box;width:100%;border:1px solid #dce1e9;border-radius:7px;font:inherit;background:white;color:#303746}.community-field input[type=checkbox]{width:20px;height:20px}.community-form-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:20px}.community-form-actions button{font-size:12px;padding:12px 16px}.community-reference{padding:16px;border:1px solid #dce1e9;border-radius:10px;margin-top:22px}.community-reference h3{margin:0}.community-reference select{margin-top:12px}.community-diagram{background:#f8f9fc;border:1px solid #dce1e9;border-radius:9px;padding:12px;margin:12px 0}.community-diagram svg{display:block;width:100%;max-height:400px}.community-finish{position:absolute;top:64px;left:322px;z-index:6;font-size:12px;padding:11px 14px}.community-finish[hidden]{display:none}#custom-element-form textarea{padding:11px;border:1px solid #dce1e9;border-radius:8px;font:inherit;box-sizing:border-box;width:100%}
@media(max-width:900px){.community-heading{display:block}.community-create{margin:20px 0}.community-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.community-inner{padding:30px 20px}.community-finish{left:190px}}
@media(max-width:600px){.community-grid{grid-template-columns:1fr}.community-dialog{padding:24px}.community-heading h1{font-size:29px}.main-nav{gap:4px}.main-nav a{padding:8px;font-size:11px}.community-finish{left:145px;max-width:calc(100% - 155px)}}
.community-project-select{width:100%;padding:12px;border:1px solid #dce1e9;border-radius:7px;font:inherit}.community-diagram svg text{fill:#303746}
.community-language{display:flex;align-items:center;gap:10px;margin:16px 0;color:#657086;font-size:14px}.community-language select,#custom-element-language{padding:8px 12px;border:1px solid #dce1ec;border-radius:8px;background:white;color:#303746;font:inherit}
/* The inspector occupies a stable area; switching its content never moves the camera. */
.task-active .workspace,.task-active.task-collapsed .workspace{--task-space:0px}
.project-properties #task-panel,.task-active .project-properties #task-panel{position:static;inset:auto;width:100%;height:auto;min-height:0;border:0;border-radius:0;box-shadow:none;padding:0;overflow:visible;background:transparent}
.project-properties #task-details,.task-active .project-properties #task-details{display:block;height:auto}
.project-properties #task-details[hidden]{display:none}
.project-properties .task-panel-bottom,.task-active .project-properties .task-panel-bottom{position:static;border-left:0;border-top:1px solid var(--border);padding:16px 0;margin-top:20px;overflow:visible}
.project-properties .task-panel-bottom>.primary{width:100%}.project-properties .task-secondary-actions{display:flex;flex-wrap:wrap;margin:12px 0 0}.project-properties .task-summary,.project-properties .task-conditions{overflow:visible}
.task-active .tools,.task-active.task-collapsed .tools{bottom:16px}.task-active .zoom{bottom:90px}
.task-active .project-properties{bottom:0;max-height:none}.project-properties #expand-task,.task-active .project-properties #expand-task{position:static;inset:auto;width:100%;height:auto;white-space:normal;text-align:left}
.inspector-tabs{display:flex;gap:8px;border-bottom:1px solid var(--border);margin:0 0 18px;padding-bottom:10px}.inspector-tabs[hidden]{display:none}.inspector-tabs button{border:0;background:transparent;color:#738096;font:inherit;font-size:13px;padding:8px 9px;border-radius:7px;cursor:pointer}.inspector-tabs button.active{background:#edf1fc;color:#3b58aa}.diagram-comment{border-bottom:1px solid var(--border);padding:14px 0}.diagram-comment p{white-space:pre-wrap;overflow-wrap:anywhere;font-size:14px;line-height:1.6;margin:10px 0}.comment-author{display:flex;flex-wrap:wrap;gap:6px;font-size:12px;color:#657086}.comment-author time{font-size:11px;color:#8b96a8}.comment-form{margin-top:20px}.comment-form label{display:block;font-size:13px;color:#657086}.comment-form textarea{display:block;box-sizing:border-box;width:100%;margin:8px 0 12px;padding:10px;border:1px solid #dce1ec;border-radius:8px;resize:vertical;font:inherit}.comment-form .primary{width:100%}.comment-form p{font-size:12px;color:#bd4355}
.node-protection{position:absolute;transform:translate(-50%,-50%);display:flex;align-items:center;justify-content:center;padding:2px;border:1.5px solid #86b698;border-radius:50%;background:#fff;cursor:pointer;z-index:4}.node-protection img{width:100%!important;height:100%!important;object-fit:contain;margin:0!important;pointer-events:none}.node-protection:hover,.node-protection:focus-visible{background:#edf7e9;border-color:#4665cf}.node.protection-drop-target{outline:2px solid #639b69;outline-offset:5px;border-radius:10px}
@media(max-width:1000px){.task-active .project-properties{bottom:78px;max-height:65vh}.task-active .tools,.task-active.task-collapsed .tools{left:50%}}
/* Language is a compact header preference, separate from workspace navigation. */
.header-actions{margin-left:auto;display:flex;align-items:center;gap:14px;flex-shrink:0;align-self:center}.header-actions .account-button{margin-left:0;max-width:180px}
.language-switch{display:flex;align-items:center;gap:2px;padding:3px;border:1px solid #e2e6ee;border-radius:10px;background:#f3f5f9;box-sizing:border-box;flex-shrink:0}
.language-switch button{display:flex;align-items:center;justify-content:center;min-width:39px;height:29px;padding:0 9px;border:0;border-radius:7px;background:transparent;color:#8490a3;font-family:'Golos Text',sans-serif;font-size:12px;font-weight:500;letter-spacing:.25px;line-height:1;cursor:pointer;transition:background .15s,color .15s,box-shadow .15s}
.language-switch button:hover{color:#4665cf;background:#e9edf7}.language-switch button[aria-pressed=true]{background:#fff;color:#3b55a4;box-shadow:0 1px 3px #26375a14,0 0 0 1px #dde3ee80}.language-switch button:focus-visible{outline:2px solid #4665cf;outline-offset:3px}
@media(max-width:900px) and (min-width:751px){header{gap:25px;padding:0 20px}.main-nav{gap:20px}.header-actions{gap:10px}.header-actions .account-button{max-width:110px}}
@media(max-width:750px){header{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-rows:56px 44px;gap:0 12px;height:100px;padding:0 16px;box-sizing:border-box}.brand{grid-column:1;grid-row:1;width:max-content}.header-actions{grid-column:2;grid-row:1;gap:9px}.header-actions .account-button{max-width:80px;padding:8px 10px;font-size:12px}.main-nav{grid-column:1/-1;grid-row:2;gap:26px;height:44px;min-width:0}.main-nav a{font-size:13px}.language-switch{border-radius:9px;padding:2px}.language-switch button{height:28px;min-width:35px;padding:0 7px}.workspace{height:calc(100dvh - 132px)}.projects-page,.community-page,.catalog-view .tasks-page{height:calc(100dvh - 100px)}}
@media(max-width:350px){header{padding:0 12px;column-gap:8px}.brand-name{font-size:16px}.header-actions{gap:6px}.header-actions .account-button{max-width:62px;padding:8px}.main-nav{gap:20px}}
@media(prefers-reduced-motion:reduce){.language-switch button{transition:none}}
#global-component-dialog .community-field input[type=file]{font-size:12px}.component-load-notice{font-size:12px;line-height:1.5;color:#7b8699;padding:8px 0}.component-load-notice[hidden]{display:none}#global-component-message{font-size:13px;line-height:1.5;color:#bd4355}#global-component-save{width:100%;margin-top:16px}
.component-tags{display:flex;flex-wrap:wrap;gap:6px;margin-top:14px}.component-tags span{font-size:11px;color:#697891;background:#f0f3f8;border:1px solid #e1e7ef;border-radius:5px;padding:4px 7px;overflow-wrap:anywhere}
.zone-draw-preview{position:absolute;z-index:2;pointer-events:none;border:1.5px dashed #6b84ba;border-radius:12px;background:#92a5cf12;box-sizing:border-box}.zone-draw-preview[hidden]{display:none}.zone-resize-handle{position:absolute;display:none;width:10px;height:10px;box-sizing:border-box;border:1.5px solid #4665cf;border-radius:3px;background:#fff;z-index:5}.group.selected .zone-resize-handle{display:block}.zone-resize-handle.nw{top:-5px;left:-5px;cursor:nwse-resize}.zone-resize-handle.ne{top:-5px;right:-5px;cursor:nesw-resize}.zone-resize-handle.sw{bottom:-5px;left:-5px;cursor:nesw-resize}.zone-resize-handle.se{bottom:-5px;right:-5px;cursor:nwse-resize}.zone-resize-handle:focus-visible{outline:2px solid #4665cf;outline-offset:3px}

.project-properties .swatches{width:100%;display:grid;grid-template-columns:repeat(6,26px);gap:12px;padding:3px 2px}.project-properties .swatches button{width:26px;height:26px}.project-properties .swatches button:hover{outline:2px solid #8993a4}.project-properties .swatches button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}

#custom-element-form [hidden]{display:none!important}#property-fields textarea{width:100%;box-sizing:border-box;border:1px solid #dce1e9;border-radius:8px;padding:10px;background:white;font:inherit;color:#303746;font-size:13px;resize:vertical}#property-fields textarea:focus{outline:2px solid var(--accent);outline-offset:1px}#property-fields .custom-threat-toggle{display:flex;align-items:center;gap:8px}#property-fields .custom-threat-toggle input{width:auto}

.property-icon-wrap{position:relative;width:108px;margin:0 auto 20px}.property-icon-wrap .property-icon{margin:0;width:108px;height:95px}.property-icon-edit{position:absolute;right:0;bottom:0;width:28px;height:28px;display:grid;place-items:center;background:#fff;border:1px solid #dce1e9;border-radius:50%;color:#657086;box-shadow:0 2px 6px #27365412;cursor:pointer}.property-icon-edit .ui-icon{width:15px;height:15px}.property-icon-edit:hover{background:var(--accent-soft);color:var(--accent);border-color:var(--accent)}.property-icon-edit:focus-visible{outline:2px solid var(--accent);outline-offset:3px}#property-icon-dialog{width:min(360px,calc(100vw - 32px));box-sizing:border-box}#property-icon-form label{display:grid;gap:8px;margin:16px 0;font-size:12px;color:#657086}#property-icon-form select,#property-icon-form input{width:100%;box-sizing:border-box;border:1px solid #dce1e9;border-radius:8px;padding:10px;background:white;font:inherit;color:#303746}#property-icon-form [hidden]{display:none}#property-icon-message{color:#bd4355}#property-icon-form .primary{width:100%}

.sidebar-view-switch{display:flex;gap:3px;padding:3px;margin-bottom:14px;background:#f0f2f7;border:1px solid #e1e5ed;border-radius:8px}.sidebar-view-switch button{flex:1;min-width:0;padding:7px 4px;font-size:11px;border-radius:5px;color:#788394}.sidebar-view-switch button.active{background:#fff;color:#354e9e;box-shadow:0 1px 3px #27365412}.sidebar-view-switch button:focus-visible,.object-tree-item:focus-visible{outline:2px solid var(--accent);outline-offset:2px}aside.show-object-tree>:not(.sidebar-view-switch):not(#object-tree){display:none!important}#object-tree{display:flex;flex:1;min-height:0;flex-direction:column}#object-tree[hidden]{display:none}.object-tree-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:12px}.object-tree-heading h2{font-size:15px;margin:0}.object-tree-heading>span{font-size:11px;color:#8993a4}.object-tree-list{overflow:auto;min-height:0;flex:1;padding:2px 3px 10px;overscroll-behavior:contain}.object-tree-row{display:grid;grid-template-columns:16px 24px minmax(0,1fr);gap:5px;align-items:center;min-height:38px;padding:3px 5px;border-radius:6px;cursor:pointer}.object-tree-row:hover{background:#f2f4f9}.object-tree-item.selected>.object-tree-row{background:#eaf0ff;color:#354e9e;box-shadow:inset 0 0 0 1px #cbd7f7}.object-tree-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}.object-tree-icon{width:24px;height:24px;object-fit:contain;display:grid;place-items:center;color:#7c88a0;font-size:17px}.object-tree-toggle{width:16px;height:24px;color:#788394;font-size:17px;display:grid;place-items:center}.object-tree-children{margin-left:13px;padding-left:3px;border-left:1px solid #e4e8f0}.object-tree-connections{font-size:11px;color:#8993a4;margin:18px 4px 7px}.object-tree-hint{font-size:10px;color:#8993a4;line-height:1.5;margin:0;padding:8px 0}.layout-controls h3{font-size:13px;margin:20px 0 12px}.layout-controls>p{font-size:11px;color:#788394;margin:14px 0 8px}.layout-align-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}.layout-align-grid button{font-size:11px;line-height:1.4;min-height:38px;padding:8px 4px;border:1px solid #dce1e9;border-radius:6px;color:#657086;background:#fff}.layout-align-grid button:hover:not(:disabled){background:#eef2fd;border-color:#b6c5ea}.layout-align-grid button:disabled{opacity:.4;cursor:default}.layout-align-grid button:focus-visible{outline:2px solid var(--accent);outline-offset:2px}@media(max-width:750px){.sidebar-view-switch{margin-bottom:10px}.sidebar-view-switch button{font-size:10px;padding:6px 1px}.object-tree-heading h2{font-size:12px}.object-tree-row{grid-template-columns:12px 20px minmax(0,1fr);gap:3px;padding:3px 2px}.object-tree-name{font-size:10px}.object-tree-icon{width:20px;height:20px}.object-tree-children{margin-left:8px;padding-left:2px}.object-tree-hint{font-size:9px}}

body.admin-library-preview .project-properties{width:min(390px,calc(100vw - 24px))}

#property-icon-dialog{width:min(700px,calc(100vw - 32px));max-height:calc(100dvh - 32px);padding:28px;overflow:auto}#property-icon-title{font-size:22px;margin:0 0 18px}#property-icon-search{width:100%;margin-bottom:12px}.icon-picker-categories{display:flex;flex-wrap:wrap;gap:5px;margin-bottom:16px}.icon-picker-categories button{padding:7px 10px;font-size:12px;color:#788394;border-radius:6px}.icon-picker-categories button.active{background:#eaf0ff;color:#354e9e}.icon-picker-library{display:grid;grid-template-columns:repeat(auto-fill,minmax(100px,1fr));gap:8px;max-height:min(46dvh,430px);overflow:auto;padding:3px;overscroll-behavior:contain}.icon-picker-option{display:flex;flex-direction:column;align-items:center;gap:7px;padding:10px 5px;min-height:112px;border:1px solid #e2e7ef;border-radius:8px;background:#fff;font-size:11px;line-height:1.4;color:#657086;cursor:pointer}.icon-picker-option img{width:72px;height:67px;object-fit:contain}.icon-picker-option:hover{background:#f5f7fc;border-color:#bdcbe8}.icon-picker-option.active{background:#eef3ff;border:2px solid #4665cf;padding:9px 4px;color:#354e9e}.icon-picker-option:focus-visible,.icon-picker-categories button:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.icon-picker-selection{display:flex;align-items:center;gap:12px;border-top:1px solid #e2e7ef;margin-top:16px;padding-top:14px;font-size:12px;color:#657086}.icon-picker-selection .property-icon{width:44px;height:40px;margin:0}.icon-picker-empty{grid-column:1/-1;text-align:center;padding:30px;color:#8993a4}@media(max-width:500px){#property-icon-dialog{padding:22px 16px}.icon-picker-library{grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}.icon-picker-option img{width:60px;height:58px}.icon-picker-option{font-size:10px;min-height:102px}.icon-picker-categories button{padding:6px 7px;font-size:11px}}

.property-heading h2{margin-right:auto}.property-heading #properties-save{display:grid;place-items:center;flex:0 0 32px;width:32px;height:32px;padding:6px;margin-right:8px;font-size:inherit;color:#657086;border:1px solid #dce1e9;border-radius:7px;background:#fff;cursor:pointer}.property-heading #properties-save .ui-icon{width:19px;height:19px}.property-heading #properties-save:hover:not(:disabled){background:#eef2fd;color:#354e9e;border-color:#b6c5ea}.property-heading #properties-save:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.property-heading #properties-save:disabled{opacity:.5;cursor:wait}.property-heading #properties-save[hidden]{display:none}

.project-properties .property-heading{position:sticky;top:0;z-index:2;background:#fff;padding:6px 0}

#nodes{position:relative;z-index:2;isolation:isolate}.object-tree-row{grid-template-columns:16px 24px minmax(0,1fr) 38px}.object-tree-actions{display:flex;gap:2px;opacity:0;pointer-events:none}.object-tree-actions button{width:18px;height:25px;padding:0;display:grid;place-items:center;border-radius:4px;font-size:15px;color:#657086}.object-tree-item.selected>.object-tree-row .object-tree-actions,.object-tree-row:hover>.object-tree-actions,.object-tree-item:focus-within>.object-tree-row .object-tree-actions{opacity:1;pointer-events:auto}.object-tree-actions button:hover:not(:disabled){background:#d9e3fa;color:#354e9e}.object-tree-actions button:disabled{opacity:.25;cursor:default}.object-tree-actions button:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.object-tree-item.layer-drop-before>.object-tree-row{box-shadow:inset 0 2px 0 var(--accent)}.object-tree-item.layer-drop-after>.object-tree-row{box-shadow:inset 0 -2px 0 var(--accent)}@media(max-width:750px){.object-tree-row{grid-template-columns:12px 20px minmax(0,1fr)}.object-tree-actions{grid-column:2/-1;display:none;justify-content:flex-end}.object-tree-item.selected>.object-tree-row .object-tree-actions,.object-tree-item:focus-within>.object-tree-row .object-tree-actions{display:flex}}

.object-tree-row{user-select:none;cursor:grab}.object-tree-row:active{cursor:grabbing}

#property-fields>label{display:grid;gap:7px;font-size:12px;color:#68768c}#property-fields>label input,#property-fields>label textarea{width:100%;box-sizing:border-box}#property-fields>.primary{width:100%;margin-top:12px}#property-fields>a.property-button{display:block;text-align:center;text-decoration:none}.public-project-page{max-width:1100px;margin:auto;padding:34px 28px 80px}.public-project-heading{display:flex;justify-content:space-between;gap:16px}.public-project-page h1{font-size:32px;margin:28px 0 14px}.public-project-description{white-space:pre-wrap;line-height:1.6;overflow-wrap:anywhere}.public-project-diagram{margin:24px 0;border:1px solid #dce2ec;border-radius:16px;background:#f8f9fc;padding:24px;overflow:hidden}.public-project-diagram svg{display:block;width:100%;max-height:650px}.public-project-comments{max-width:680px;margin:32px auto}.public-project-comments .comment-form textarea{width:100%;box-sizing:border-box;min-height:90px}.public-project-comments .comment-form button{margin-top:10px}.public-project-comments .diagram-comment p{white-space:pre-wrap;overflow-wrap:anywhere}

.public-project-page{height:calc(100dvh - 80px);overflow:auto;box-sizing:border-box;width:100%}.public-project-page[hidden]{display:none}.public-project-diagram .community-diagram{border:0;padding:0;margin:0}.public-project-diagram svg{max-height:650px}.public-project-heading button{font-size:13px}

/* The first-project invitation uses the same illustrated components as the editor. */
.projects-empty[hidden]{display:none}
.projects-page.is-empty{padding-top:0;padding-bottom:0;overflow-x:hidden}
.projects-page.is-empty .projects-inner{min-height:100%;display:flex;flex-direction:column}
.projects-page.is-empty .projects-heading,.projects-page.is-empty .projects-grid{display:none}
.projects-empty{position:relative;isolation:isolate;display:grid;place-items:center;flex:1;min-height:560px}
.starter-diagram{position:absolute;z-index:-1;top:50%;left:50%;width:1080px;height:600px;transform:translate(-50%,-50%);pointer-events:none;opacity:.62;mask-image:radial-gradient(ellipse at center,#000 45%,transparent 75%);-webkit-mask-image:radial-gradient(ellipse at center,#000 45%,transparent 75%);background-image:radial-gradient(#ccd4e2 .7px,transparent .7px);background-size:24px 24px}
.starter-connections{position:absolute;inset:0;width:100%;height:100%;color:#a3b1cc}
.starter-node{position:absolute;width:130px;text-align:center;color:#75829a;font:18px 'Neucha',sans-serif}
.starter-node img{display:block;width:100px;height:100px;object-fit:contain;margin:0 auto 7px}
.starter-user{left:65px;top:155px;transform:rotate(-5deg)}
.starter-browser{left:325px;top:75px;transform:rotate(3deg)}
.starter-server{left:810px;top:160px;transform:rotate(4deg)}
.starter-database{left:810px;top:375px;transform:rotate(-3deg)}
.starter-cloud{left:505px;top:440px;transform:rotate(-4deg)}
.starter-email{left:65px;top:355px;transform:rotate(3deg)}
.projects-empty-content{position:relative;text-align:center;padding:50px 30px;background:radial-gradient(ellipse,#f8f9fb 48%,#f8f9fbeb 65%,#f8f9fb00 74%)}
.projects-empty-content .eyebrow{color:var(--accent);font-size:11px;letter-spacing:1.6px}
.projects-empty-content h1{font-size:clamp(32px,4vw,46px);line-height:1.14;letter-spacing:-1.6px;margin:19px 0 18px;font-weight:700}
.projects-empty-content p{font-size:15px;line-height:1.7;color:#737e91;margin:0 0 28px}
.projects-empty-content .primary{background:var(--accent);padding:15px 24px;border-radius:8px;font-size:14px;box-shadow:0 5px 14px #4665cf20;white-space:nowrap}
.projects-empty-content .primary:hover{background:#3654bb;box-shadow:0 7px 18px #4665cf30;transform:translateY(-2px)}
.projects-page.is-empty #projects-message{text-align:center;max-width:560px;align-self:center;margin:0 0 30px;font-size:12px;color:#737e91}
.projects-page.is-empty #projects-message:empty{display:none}
@media(min-width:1600px){.projects-page.is-empty .projects-inner{max-width:1280px}.starter-diagram{transform:translate(-50%,-50%) scale(1.12)}}
@media(max-width:750px){.projects-empty{min-height:500px}.starter-diagram{transform:translate(-50%,-50%) scale(.8);opacity:.42}.projects-empty-content{padding:42px 16px}.projects-empty-content h1{letter-spacing:-1px}.projects-empty-content p{font-size:14px}.projects-page.is-empty #projects-message{margin-bottom:22px}}
@media(max-width:480px){.projects-empty{min-height:440px}.starter-diagram{transform:translate(-50%,-50%) scale(.65);opacity:.32}.projects-empty-content{padding:36px 8px}.projects-empty-content .eyebrow{font-size:9px;letter-spacing:1.1px}.projects-empty-content p{font-size:13px}.projects-page.is-empty{overflow-x:hidden}}
@media(prefers-reduced-motion:reduce){.projects-empty-content .primary{transition:none}.projects-empty-content .primary:hover{transform:none}}
