:root{font-family:'Segoe UI',Roboto,Helvetica,Arial,sans-serif;color:#1c1f2b;background:#f4f5fa;--blue:#2a306c;--navy:#2a306c;--navy2:#3a4290;--border:#e3e6ef;--muted:#6b7280}*{box-sizing:border-box}body{margin:0;height:100vh;display:flex;flex-direction:column;overflow:hidden}header{height:74px;background:var(--navy);color:#fff;display:flex;align-items:center;gap:20px;padding:9px 16px}.brand{min-width:240px}.brand h1{font-size:19px;margin:0;color:#fff;letter-spacing:.3px}.brand h1 .tld{color:#9fb0ff;font-weight:600}.brand p{margin:3px 0 0;font-size:10.5px;color:#c3c9ea}.workflow{display:flex;align-self:stretch;align-items:center;gap:4px;flex:1;justify-content:center}.workflow button{border:0;background:transparent;padding:8px 10px;color:#aab1d6;font-size:11.5px;cursor:pointer}.workflow button span{display:inline-grid;place-items:center;width:19px;height:19px;border-radius:50%;background:#ffffff22;margin-right:5px;color:#dfe3ff}.workflow button.active{color:#fff;font-weight:700}.workflow button.active span{background:#fff;color:var(--navy)}.header-actions{display:flex;gap:6px;align-items:center}.header-actions button,.header-actions .file-btn{background:#ffffff18;border:1px solid #ffffff44;color:#fff}.header-actions .primary{background:#fff;color:var(--navy);border-color:#fff;font-weight:700}.header-actions .dark{background:#151a3d;border-color:#151a3d;color:#fff}button,.file-btn,select,input,textarea{font:inherit}button,.file-btn{border:1px solid #ccd5df;background:#fff;border-radius:8px;padding:7px 10px;cursor:pointer;font-size:11.5px;font-weight:600;color:#1c1f2b}.primary{background:var(--navy);color:#fff;border-color:var(--navy)}.dark{background:#151a3d;color:white;border-color:#151a3d}.danger{color:#b42318;border-color:#f1b8b3}.ghost{padding:4px 7px}.file-btn input{display:none}main{flex:1;display:grid;grid-template-columns:285px minmax(420px,1fr) 330px;min-height:0}.left-panel,.right-panel{background:#fff;overflow:auto;padding:12px}.left-panel{border-right:1px solid var(--border)}.right-panel{border-left:1px solid var(--border)}section{min-width:0}.left-panel section,.right-panel section{border-bottom:1px solid #edf0f3;padding-bottom:13px;margin-bottom:13px}h2{font-size:13px;margin:0 0 9px}.subhead{margin-top:18px}.panel-title,.review-head{display:flex;justify-content:space-between;align-items:center}.score{font-size:18px;font-weight:800;color:var(--navy)}label{display:block;font-size:10.5px;color:#5d6775;margin:7px 0}input,select,textarea{width:100%;border:1px solid #ccd5df;border-radius:6px;padding:6px 7px;background:#fff;color:#17202a}textarea{resize:vertical}.two-col{display:grid;grid-template-columns:1fr 1fr;gap:7px}.row{display:flex;gap:6px;align-items:center}.row>*{flex:1}.stack{display:grid;gap:6px}.tool-grid{display:grid;grid-template-columns:1fr 1fr;gap:5px}.tool-grid button.active{outline:2px solid var(--navy);background:#eef1fb}.hint,.muted{font-size:10.5px;color:#7a8492;line-height:1.4}.hidden{display:none!important}details{margin:9px 0;border-top:1px solid #eef1f4;padding-top:7px}summary{font-size:10.5px;font-weight:700;color:#4b5563;cursor:pointer}.check{display:flex!important;align-items:center;gap:6px}.check input{width:auto}.canvas-wrap{position:relative;overflow:hidden;background:#fff}.canvas-toolbar{height:38px;border-bottom:1px solid var(--border);background:#fbfcfd;display:flex;align-items:center;gap:12px;padding:0 10px;font-size:10.5px}.canvas-toolbar label{display:flex;gap:5px;align-items:center;margin:0}.canvas-toolbar select{padding:3px;width:auto}.grow{flex:1}#canvas{width:100%;height:calc(100% - 38px);display:block;touch-action:none;background:#fff}.wall{stroke-width:5;stroke-linecap:round;cursor:pointer}.wall.incomplete{stroke:#2474d2}.wall.complete{stroke:#111827}.wall.interior{stroke-width:3}.selected{filter:drop-shadow(0 0 3px #f59e0b)}.room{fill:rgba(37,99,235,.065);stroke:#64748b;stroke-width:1.3;stroke-dasharray:5 4;cursor:pointer}.room.selected{fill:rgba(245,158,11,.12)}.window{stroke:#0ea5e9;stroke-width:7;cursor:pointer}.door{stroke:#9a6b42;stroke-width:7;cursor:pointer}.device{cursor:pointer}.grille{fill:#fff;stroke:#374151;stroke-width:1.5}.equipment{fill:#fff;stroke:#7c3aed;stroke-width:2;cursor:pointer}.walkway{fill:rgba(245,158,11,.1);stroke:#f59e0b;stroke-width:1.5;stroke-dasharray:5 3}.damper{fill:#fff;stroke:#b42318;stroke-width:2}.route-supply{fill:none;stroke:#be123c;stroke-width:4;stroke-linejoin:round}.route-return{fill:none;stroke:#7c3aed;stroke-width:3;stroke-dasharray:9 4}.route-exhaust{fill:none;stroke:#6b7280;stroke-width:3;stroke-dasharray:3 3}.route-refrigerant{fill:none;stroke:#15803d;stroke-width:2.5;stroke-dasharray:7 4}.route-label,.object-label{font-size:10px;paint-order:stroke;stroke:#fff;stroke-width:3;fill:#111827}.point{fill:var(--blue)}.draft{stroke:var(--blue);stroke-width:2;stroke-dasharray:5 4;fill:none}.proposal{fill:none;stroke:#db2777;stroke-width:4;stroke-dasharray:8 5;opacity:.8}.proposal-label{font-size:10px;fill:#be185d;paint-order:stroke;stroke:white;stroke-width:3}#properties .prop-grid{display:grid;grid-template-columns:1fr 1fr;gap:6px}#properties .wide{grid-column:1/-1}#properties button{margin-top:7px;width:100%}.badge{display:inline-block;padding:3px 6px;border-radius:10px;font-size:9.5px;background:#edf2f7;margin:2px}.badge.warn{background:#fff2cc}.badge.error{background:#fee4e2;color:#b42318}.badge.ok{background:#e6f7ed;color:#067647}.issue{border-left:3px solid #d0d5dd;padding:5px 7px;margin:5px 0;font-size:10px;line-height:1.35;background:#fafbfc}.issue.error{border-color:#d92d20}.issue.warning{border-color:#f79009}.system-card,.equipment-card,.code-card,.sheet-card{border:1px solid var(--border);border-radius:7px;padding:7px;margin:6px 0;font-size:10.5px}.system-card input,.system-card select{padding:4px}.card-title{display:flex;justify-content:space-between;align-items:center;gap:6px}.summary-table{width:100%;font-size:10px;border-collapse:collapse}.summary-table td,.summary-table th{padding:4px;border-bottom:1px solid #eef0f3;text-align:left}.summary-table td:last-child,.summary-table th:last-child{text-align:right;font-variant-numeric:tabular-nums}.metric-grid{display:grid;grid-template-columns:1fr 1fr;gap:6px}.metric{border:1px solid #e6eaf0;border-radius:7px;padding:7px}.metric b{display:block;font-size:15px}.metric span{font-size:9px;color:#667085}pre{white-space:pre-wrap;word-break:break-word;font-size:9.5px;max-height:245px;overflow:auto;background:#f6f8fa;padding:8px;border-radius:6px}dialog{width:min(820px,92vw);border:0;border-radius:10px;box-shadow:0 20px 70px rgba(0,0,0,.25)}dialog::backdrop{background:rgba(0,0,0,.35)}.dialog-actions{display:flex;justify-content:flex-end;gap:7px;margin-top:12px}@media(max-width:1180px){main{grid-template-columns:250px 1fr}.right-panel{display:none}.workflow button{padding:7px 5px}.workflow button span{display:none}.brand{min-width:180px}.header-actions button:not(.primary):not(.dark),.header-actions .file-btn{display:none}}@media(max-width:820px){main{grid-template-columns:190px 1fr}.brand p{display:none}.workflow{display:none}.header{gap:6px}.tool-grid{grid-template-columns:1fr}.left-panel{padding:8px}}

/* ---- EngineerSH sign-in gate ---- */
#engGate{position:fixed;inset:0;z-index:9000;display:flex;align-items:center;justify-content:center;background:linear-gradient(140deg,#2a306c,#151a3d)}
#engGate .eg-card{background:#fff;border-radius:14px;box-shadow:0 24px 80px #000a;max-width:440px;width:92vw;padding:30px 32px;text-align:center}
#engGate .eg-logo{font-size:26px;font-weight:900;color:var(--navy);letter-spacing:.3px}
#engGate .eg-logo .tld{color:#8a94d8;font-weight:700}
#engGate .eg-sub{font-size:12.5px;color:#6b7280;margin:4px 0 16px;font-weight:700;letter-spacing:1.6px;text-transform:uppercase}
#engGate .eg-tool{font-size:14.5px;color:#1c1f2b;margin-bottom:14px}
#engGateMsg{font-size:13px;color:#3f4658;line-height:1.6;margin-bottom:16px}
#engGateMsg .eg-hint{font-size:11.5px;color:#8a90a4}
#engGateSignIn{background:var(--navy);color:#fff;border-color:var(--navy);padding:10px 18px;font-size:13px;border-radius:9px}
#engGate .eg-foot{margin-top:18px;font-size:10.5px;color:#9aa1b6}
