/* v1.8 Công cụ kỹ thuật */
.t18-card{width:min(1280px,96vw);height:min(860px,92vh);display:flex;flex-direction:column;padding:0;overflow:hidden}
.t18-card.t18-expanded{width:99vw;height:98vh}
.t18-head{display:flex;align-items:center;justify-content:space-between;padding:14px 18px 8px}
.t18-title{display:flex;align-items:center;gap:10px}.t18-title h3{margin:0;font-size:18px}
.t18-logo{width:36px;height:36px;border-radius:10px;background:linear-gradient(135deg,#1565ff,#7c3aed);display:flex;align-items:center;justify-content:center;font-size:18px}
.t18-actions{display:flex;gap:4px}
.t18-tabs{display:flex;gap:4px;padding:0 18px;border-bottom:1px solid #e2e8f0}
.t18-tabs button{border:0;background:none;padding:10px 14px;font-size:14px;font-weight:600;color:#64748b;border-bottom:2px solid transparent;cursor:pointer}
.t18-tabs button.active{color:#1565ff;border-bottom-color:#1565ff}
.t18-pane{flex:1;min-height:0;overflow:auto;padding:14px 18px}
.t18-pane.hidden{display:none}
.t18-split{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.25fr);gap:14px;height:100%;min-height:0}
.t18-api-split{grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);height:calc(100% - 52px)}
.t18-col{display:flex;flex-direction:column;min-height:0;gap:6px;position:relative}
.t18-bar{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.t18-spacer{flex:1}
.t18-editor{flex:1;min-height:160px;width:100%;box-sizing:border-box;font:13px/1.5 ui-monospace,Consolas,monospace;border:1px solid #cbd5e1;border-radius:10px;padding:10px;resize:none;background:#0f172a;color:#e2e8f0}
.t18-editor.small{flex:0 0 auto;min-height:110px;height:120px;background:#f8fafc;color:#0f172a}
.t18-hint{font-size:11px;color:#94a3b8}
.t18-out{flex:1;min-height:0;overflow:auto;border:1px solid #e2e8f0;border-radius:10px;padding:10px;background:#fff}
.t18-empty{color:#94a3b8;text-align:center;padding:40px 12px;font-size:13px}
.t18-menu{position:absolute;top:34px;left:0;z-index:5;background:#fff;border:1px solid #e2e8f0;border-radius:10px;box-shadow:0 10px 30px rgba(15,23,42,.15);padding:4px;display:flex;flex-direction:column}
.t18-menu.hidden{display:none}
.t18-menu button{border:0;background:none;text-align:left;padding:7px 10px;border-radius:6px;cursor:pointer}.t18-menu button:hover{background:#eff6ff}
.t18-sum{border:1px solid #e2e8f0;border-radius:10px;padding:10px;margin-bottom:10px;background:#f8fafc}
.t18-sum-head{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-bottom:8px;font-size:13px}
.t18-badge{background:#1565ff;color:#fff;border-radius:6px;padding:2px 8px;font-weight:700;font-family:ui-monospace,Consolas,monospace}
.t18-muted{color:#94a3b8}
.t18-kv{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:6px 12px;font-size:12px}
.t18-kv span{display:block;color:#64748b;font-size:11px}.t18-kv b{word-break:break-all}
.t18-warn{margin-top:8px;background:#fff7ed;color:#9a3412;border-radius:8px;padding:6px 8px;font-size:12px}
.t18-ok{margin-top:8px;color:#15803d;font-size:12px;font-weight:600}
.t18-seg{border:1px solid #e2e8f0;border-radius:8px;margin-bottom:6px;overflow:hidden}
.t18-seg summary{display:flex;gap:8px;align-items:center;padding:6px 10px;background:#f1f5f9;cursor:pointer;font-size:13px}
.t18-seg summary b{font-family:ui-monospace,Consolas,monospace;color:#1d4ed8}.t18-seg summary em{margin-left:auto;font-style:normal;color:#94a3b8;font-size:11px}
.t18-fields{width:100%;border-collapse:collapse;font-size:12px}
.t18-fields td{border-top:1px solid #f1f5f9;padding:4px 8px;vertical-align:top}
.t18-fid{font-family:ui-monospace,Consolas,monospace;color:#7c3aed;white-space:nowrap;width:70px}
.t18-fname{color:#64748b;width:190px}
.t18-fval{font-family:ui-monospace,Consolas,monospace;word-break:break-all;cursor:copy}.t18-fval:hover{background:#eff6ff}
.t18-comps{display:flex;flex-wrap:wrap;gap:4px;margin-top:3px}
.t18-comps span{background:#f1f5f9;border-radius:4px;padding:0 5px}.t18-comps i{font-style:normal;color:#94a3b8;margin-right:4px;font-size:10px}
.t18-find{flex:1;min-width:160px}
.t18-check{display:inline-flex;align-items:center;gap:4px;font-size:12px;white-space:nowrap}
.t18-api-line{display:flex;gap:6px;margin-bottom:10px}
.t18-api-line input{flex:1;min-width:0}
#t18ApiMethod{font-weight:800;width:110px}
.t18-resp-head{display:flex;gap:12px;align-items:center;font-size:12px;margin-bottom:8px;color:#475569}
.t18-status{font-weight:800;padding:2px 8px;border-radius:6px}.t18-status.ok{background:#dcfce7;color:#15803d}.t18-status.bad{background:#fee2e2;color:#b91c1c}
.t18-subtabs{display:flex;gap:4px;margin-bottom:6px}.t18-subtabs button{border:1px solid #e2e8f0;background:#fff;border-radius:6px;padding:3px 10px;font-size:12px;cursor:pointer}.t18-subtabs button.active{background:#0f172a;color:#fff;border-color:#0f172a}
.t18-code{margin:0;background:#0f172a;color:#e2e8f0;border-radius:8px;padding:10px;font:12px/1.5 ui-monospace,Consolas,monospace;white-space:pre-wrap;word-break:break-word}
.t18-code.hidden{display:none}
.t18-err{background:#fef2f2;color:#b91c1c;border-radius:8px;padding:10px;font-size:13px}
.t18-hist-list{max-height:180px;overflow:auto;border:1px solid #e2e8f0;border-radius:8px}
.t18-hist{display:grid;grid-template-columns:62px minmax(0,1fr) 44px;gap:6px;width:100%;border:0;border-bottom:1px solid #f1f5f9;background:#fff;padding:5px 8px;text-align:left;font-size:12px;cursor:pointer}
.t18-hist:hover{background:#f8fafc}.t18-hist span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.t18-hist em{font-style:normal;font-weight:700;text-align:right}.t18-hist em.ok{color:#16a34a}.t18-hist em.bad{color:#dc2626}
.t18-net-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(320px,1fr));gap:12px;margin-bottom:12px}
.t18-box{border:1px solid #e2e8f0;border-radius:10px;padding:12px}.t18-box h4{margin:0 0 8px}.t18-box.hidden{display:none}
.t18-ports{max-width:160px}
.t18-presets{display:flex;flex-wrap:wrap;gap:4px;margin-top:4px}
.t18-chip{border:1px solid #e2e8f0;background:#f8fafc;border-radius:999px;padding:2px 9px;font-size:11px;cursor:pointer}.t18-chip:hover{background:#eff6ff;border-color:#bfdbfe}
.t18-net-out{display:flex;flex-direction:column;gap:4px}
.t18-net-row{display:flex;gap:12px;align-items:center;border:1px solid #e2e8f0;border-radius:8px;padding:7px 10px;font-size:13px}
.t18-dot{width:10px;height:10px;border-radius:50%;flex:0 0 auto}.t18-dot.ok{background:#16a34a}.t18-dot.bad{background:#dc2626}.t18-dot.wait{background:#f59e0b;animation:t18pulse 1s infinite}
@keyframes t18pulse{50%{opacity:.3}}
.t18-err-inline{color:#b91c1c}
.t18-pane[data-pane="dicom"] #toolTab-dicom{display:block}
@media(max-width:900px){.t18-split,.t18-api-split{grid-template-columns:1fr;height:auto}.t18-editor{min-height:200px}}
