body.builder{height:100dvh;overflow:hidden;display:flex;flex-direction:column;touch-action:manipulation}
.name{border:0;background:none;font-weight:700;font-size:15px;padding:6px 8px;border-radius:8px;min-width:0;width:200px}
.name:hover,.name:focus{background:var(--card);outline:0}
.work{flex:1;display:grid;grid-template-columns:300px 1fr;min-height:0}
.bin{min-width:0;border-right:1px solid var(--line);display:flex;flex-direction:column;min-height:0;background:#fff}
.bin-head{padding:12px;display:flex;flex-direction:column;gap:10px;border-bottom:1px solid var(--line)}
.parts{flex:1;overflow-y:auto;padding:10px 12px;display:grid;grid-template-columns:repeat(3,1fr);grid-auto-rows:87px;gap:7px;align-content:start}
.part{aspect-ratio:1;border:0;background:var(--card);border-radius:12px;position:relative;cursor:pointer;padding:0;display:flex;flex-direction:column;align-items:center;justify-content:center;overflow:hidden}
.part .tint{width:82%;height:68%;pointer-events:none}
.part span{font-size:10.5px;color:var(--sub);line-height:1.15;padding:0 4px 4px;max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.part.on{outline:2px solid var(--blue);background:#fff}
.part:hover{background:#ececf0}.part.on:hover{background:#fff}
.parts .more{grid-column:1/-1;margin:6px 0}
.colors{border-top:1px solid var(--line);padding:10px 12px 12px}
.colors-head{display:flex;justify-content:space-between;font-size:13px;margin-bottom:8px}.colors-head span{color:var(--sub)}
.swatches{display:grid;grid-template-columns:repeat(10,1fr);gap:6px}
.swatches button{aspect-ratio:1;border-radius:50%;border:0;box-shadow:inset 0 0 0 1px rgba(0,0,0,.14);cursor:pointer;padding:0;position:relative}
.swatches button.trans::after{content:"";position:absolute;inset:3px;border-radius:50%;background:linear-gradient(135deg,rgba(255,255,255,.75),transparent 55%)}
.swatches button.on{outline:2px solid var(--blue);outline-offset:2px}
.stage{position:relative;background:radial-gradient(ellipse at 50% 35%,#fff 0,var(--stage) 75%);min-height:0;overflow:hidden}
#view{position:absolute;inset:0;width:100%;height:100%;display:block;touch-action:none;outline:0}
.hud{position:absolute;right:14px;top:12px;background:#fff;border-radius:12px;padding:7px 12px;font-size:12px;color:var(--sub);box-shadow:var(--shadow);text-align:center;line-height:1.2}
.hud b{display:block;color:var(--ink);font-size:17px}
.hint{position:absolute;left:50%;top:14px;transform:translateX(-50%);background:rgba(29,29,31,.82);color:#fff;font-size:13px;padding:6px 14px;border-radius:99px;white-space:nowrap;pointer-events:none;transition:opacity .4s;max-width:calc(100% - 120px);overflow:hidden;text-overflow:ellipsis}
.tools{position:absolute;left:50%;bottom:16px;transform:translateX(-50%);background:#fff;border-radius:22px;padding:6px;display:flex;gap:2px;box-shadow:var(--shadow);align-items:center}
.tools button{border:0;background:none;width:58px;height:52px;border-radius:16px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;cursor:pointer;color:#424245}
.tools button small{font-size:10.5px;font-weight:600}
.tools button.on{background:var(--blue);color:#fff}
.tools button:hover:not(.on){background:var(--card)}
.tools i{width:1px;height:30px;background:var(--line);margin:0 4px}
.confirm{position:absolute;left:50%;bottom:86px;transform:translateX(-50%);display:flex;gap:8px;background:#fff;padding:6px;border-radius:99px;box-shadow:var(--shadow)}

dialog{border:0;border-radius:20px;padding:20px;width:min(460px,calc(100% - 32px));box-shadow:0 30px 80px -20px rgba(0,0,0,.45)}
dialog::backdrop{background:rgba(0,0,0,.25)}
.dlg-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:14px;font-size:18px}
.dlg-actions{display:grid;gap:8px}.dlg-actions .pill{justify-content:flex-start;padding:11px 16px}
.dlg-note{font-size:12.5px;color:var(--sub);margin:14px 0 0}
@media (max-width:760px){
 .work{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto}
 .bin{order:2;border-right:0;border-top:1px solid var(--line);max-height:42dvh}
 .bin-head{flex-direction:row;align-items:center;padding:8px 10px;gap:8px}
 .bin-head .search{flex:0 0 120px}
 .bin-head .chips{flex-wrap:nowrap;overflow-x:auto}.bin-head .chips::-webkit-scrollbar{display:none}
 .bin-head .chips button{flex:none}
 .parts{grid-template-columns:none;grid-auto-flow:column;grid-auto-columns:76px;grid-template-rows:76px;grid-auto-rows:76px;overflow-x:auto;overflow-y:hidden;padding:8px 10px;flex:none}
 .parts .more{grid-column:auto;margin:0;width:76px;height:76px;padding:0;font-size:12px}
 .colors{padding:6px 10px 10px}.colors-head{display:none}
 .swatches{display:flex;overflow-x:auto;gap:8px;padding:3px}.swatches button{flex:none;width:30px;height:30px}
 .swatches::-webkit-scrollbar{display:none}
 .tools{bottom:10px;padding:4px;border-radius:18px}.tools button{width:50px;height:46px}
 .confirm{bottom:70px}
 .hint{font-size:12px;top:10px}
 .name{width:130px}
}
