.tr{min-width:0;display:grid;gap:10px;line-height:1.5}
.tr [hidden]{display:none!important}
.tr-top,.tr [data-tr-body]{min-width:0;display:grid;gap:9px}
.tr p,.tr label,.tr summary{margin:0;font-size:13px}
.tr-file-row{display:flex;align-items:center;gap:9px;flex-wrap:wrap}
.tr .tr-file{position:relative;display:inline-flex;align-items:center;min-height:40px;padding:6px 11px;border:1px solid #bdd0df;border-radius:7px;background:#edf4fa;color:#234967;cursor:pointer}
.tr .tr-file:focus-within{outline:2px solid #215b83;outline-offset:2px}
.tr .tr-file input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}
.tr .tr-helper,.tr .tr-top p{color:var(--mc-text,#405850)}
.tr [data-tr-filename]{overflow-wrap:anywhere;font-weight:650}
.tr .tr-status{border:1px solid #bfd7cc;padding:7px 9px;border-radius:7px;background:#eef7f2}
.tr .tr-status.tr-error{background:#fff2eb;border-color:#efcbb7;color:#7b321d}
.tr-controls,.tr-actions{display:flex;align-items:end;flex-wrap:wrap;gap:7px}
.tr-controls label{display:grid;gap:4px;min-width:0;color:var(--mc-ink,#172f31);font-weight:650}
.tr-controls label:first-child{flex:1 1 125px}
.tr-controls select,.tr-controls input[type="number"]{min-height:38px;min-width:0;width:100%;padding:5px 8px;border-radius:7px;border:1px solid #c5d7d0;background:#fff;color:#172f31;font:inherit;font-weight:500}
.tr button{min-height:38px;padding:5px 9px;border:1px solid #bfd5cb;border-radius:7px;background:#fff;color:#194a3b;font:inherit;font-size:13px;font-weight:650;cursor:pointer}
.tr button[aria-pressed="true"],.tr button[data-tr-action^="apply"]{background:#155c4b;border-color:#155c4b;color:#fff}
.tr button:disabled{opacity:.44;cursor:default}
.tr-actions>span{color:#405850;font-size:12px;align-self:center}
.tr .tr-snap{display:inline-flex;align-items:center;gap:4px;min-height:38px;white-space:nowrap}
.tr-cad-preview,.tr-sheet-wrap{background:#f2f6f4;border:1px solid #d4e2dd;border-radius:8px;padding:6px;overflow:auto}
.tr-cad-preview{display:grid;place-items:center;padding:12px}
.tr-cad-preview svg{display:block;width:100%;height:clamp(120px,28vh,230px);overflow:visible}
.tr-cad-preview polygon{fill:#dcefe6;stroke:#1d6f56;stroke-width:2;vector-effect:non-scaling-stroke}
.tr-sheet-wrap{max-height:min(64vh,680px)}
.tr-sheet{position:relative;width:100%;min-width:280px;cursor:crosshair;touch-action:manipulation}
.tr-sheet canvas{display:block;width:100%;height:auto;background:white}
.tr-sheet svg{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;overflow:visible}
.tr-ruler{stroke:#b63527;fill:none}
.tr-outline{stroke:#096f58;fill:none}
.tr-candidate{stroke:#096f58;fill:#69bd9b;fill-opacity:.26}
.tr-measure{stroke:#174ea6;fill:none}
.tr-number{fill:#f3b645;fill-opacity:.3;stroke:#905909}
circle.tr-ruler,circle.tr-outline,circle.tr-measure{fill:#fff}
.tr-measurements ul,.tr details ul{margin:4px 0;padding-left:20px;font-size:13px}
.tr-measurements li{margin-bottom:4px}
.tr-measurements button{min-height:32px;margin-left:4px}
@media(max-width:520px){.tr-controls label{flex:1 1 100px}.tr-controls label[data-tr-labels]{flex-basis:100%}.tr .tr-sheet-wrap{max-height:55vh}}
