*{box-sizing:border-box}body{margin:0;font:15px system-ui,sans-serif;color:#20372f;background:#f3f5f1}header,main{max-width:1550px;margin:auto;padding:17px 22px}header,.bar,.heading,.tabs,.buttons{display:flex;align-items:center;gap:9px;flex-wrap:wrap}header{justify-content:space-between;border-bottom:1px solid #d3dcd6}header span,small{color:#62766b}a{color:#116651}button,.btn,select,input{font:inherit}button,.btn,select,input:not([type=checkbox]){border:1px solid #cdd7ce;border-radius:7px;background:white;padding:7px 10px}button,.btn{cursor:pointer}button.active,.primary{background:#15503e;color:white}.bar{margin-bottom:14px}.bar label,aside label{display:grid;gap:4px;font-size:13px}aside label{margin:13px 0}aside label:has(input[type=checkbox]){display:block}.workspace{display:grid;grid-template-columns:190px 1fr 1fr;gap:12px}section,aside{min-width:0;background:white;border-radius:12px;padding:14px}canvas{width:100%;height:auto;display:block;cursor:crosshair;background:#f8faf8;margin:10px 0}#source,#target{max-height:460px;object-fit:contain;height:auto;max-height:none}h2{font-size:17px;margin:0}.heading{justify-content:space-between}#pieces button{display:block;text-align:left;width:100%;margin:5px 0}aside input{min-width:0;width:100%}aside input[type=checkbox]{width:auto}output{display:block;padding:12px 2px;color:#245942;min-height:42px}.proof{margin-top:8px}#proofs{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}figure{margin:0}figcaption{text-align:center;font-size:13px}dialog{border:0;border-radius:12px}button:disabled{opacity:.45;cursor:default}@media(max-width:900px){.workspace{grid-template-columns:1fr 1fr}aside{grid-column:1/-1}#pieces button{display:inline-block;width:auto}aside label{display:inline-block;margin:5px}aside input:not([type=checkbox]){width:130px}}@media(max-width:620px){.workspace{grid-template-columns:1fr}#proofs{grid-template-columns:1fr 1fr}main{padding:10px}}
.drag-piece{position:fixed;z-index:30;pointer-events:none;max-height:none;max-width:none;margin:0;opacity:.84;background:transparent;filter:drop-shadow(0 3px 5px #1238)}.drag-piece[hidden]{display:none}#source,#target{touch-action:none}#source{cursor:grab}#saved{display:block;margin-top:10px}
#sheetWindow{width:100%;overflow:auto;max-height:65vh;overscroll-behavior:contain}#sheetWindow #source{max-width:none;flex:none;display:block;margin:0}#measureInfo{display:block;margin:6px 0}

header,main{width:100%;max-width:none}.workspace{grid-template-columns:minmax(170px,13%) minmax(0,0.85fr) minmax(0,1.3fr)}#targetWindow{width:100%;overflow:auto;max-height:72vh;background:#f5f8f6;overscroll-behavior:contain}#targetWindow canvas{margin:0;max-width:none}.buttons{margin:8px 0}@media(max-width:900px){.workspace{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:620px){.workspace{grid-template-columns:minmax(0,1fr)}}#pieces .layerRow{display:flex;gap:9px;align-items:center}#pieces .layerRow canvas{width:34px;height:34px;margin:0;border:1px solid #d5ded7;border-radius:5px;background:#f5f6f4;cursor:pointer}#pieces .layerRow small{display:block;color:inherit;font-size:11px;opacity:.8}
