.sg{display:flex;flex-direction:column;gap:14px}
.sg-pad-wrap{position:relative;border:2px dashed #C9D3E2;border-radius:12px;background:#fff;height:240px;touch-action:none}
#pad{display:block;width:100%;height:100%;border-radius:10px;cursor:crosshair}
.sg-tip{position:absolute;inset:auto 0 12px;text-align:center;margin:0;color:var(--faint);font-size:14px;pointer-events:none}
.sg-tip::before{content:"";position:absolute;left:12%;right:12%;top:-34px;border-top:1px solid #E3E8F0}
.sg-tools,.sg-out{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
.sg-tools .btn{min-height:36px;font-size:14px;padding:0 14px}
.sg-width{display:flex;align-items:center;gap:8px;font-size:14px;color:var(--text)}
.sg-width input{accent-color:var(--navy)}
.sg-file{position:relative}
.sg-file input{position:absolute;width:1px;height:1px;opacity:0}
.wm-msg{margin:0;color:#B42318;font-size:14px}
.sg-doc{border-top:1px solid var(--line);padding-top:16px;display:flex;flex-direction:column;gap:12px}
.sg-doc-head{display:flex;flex-direction:column;gap:2px}
.sg-doc-head b{color:var(--ink);word-break:break-all}
.sg-page{position:relative;margin:0 auto 6px;box-shadow:0 2px 10px rgba(11,47,99,.15);background:#fff;max-width:100%;user-select:none}
.sg-page canvas,.sg-page img.bg{display:block;width:100%;height:auto}
.sg-page-bar{display:flex;justify-content:space-between;align-items:center;margin:14px auto 6px;font-size:13.5px;color:var(--muted)}
.sg-page-bar .btn{min-height:32px;font-size:13.5px;padding:0 12px}
.sg-stamp{position:absolute;cursor:move;border:1px dashed rgba(31,63,191,.6);touch-action:none}
.sg-stamp img{display:block;width:100%;height:100%;pointer-events:none}
.sg-stamp .rs{position:absolute;right:-9px;bottom:-9px;width:18px;height:18px;border-radius:50%;background:var(--navy);border:2px solid #fff;cursor:nwse-resize;touch-action:none}
.sg-stamp .rm{position:absolute;right:-10px;top:-10px;width:20px;height:20px;border-radius:50%;border:0;background:#B42318;color:#fff;font-size:12px;line-height:20px;padding:0;cursor:pointer}
.sg-doc-foot{display:flex;justify-content:flex-end;gap:10px;flex-wrap:wrap}
@media (max-width:640px){.sg-pad-wrap{height:200px}}
.sg-doc{scroll-margin-top:72px}
.sg-status{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;padding:12px 16px;border-radius:10px;font-size:14.5px;line-height:1.6}
.sg-status.ok{background:var(--green-bg);border:1px solid var(--green-line);color:var(--green-d)}
.sg-status.todo{background:#FFFAEB;border:1px solid #FEDF89;color:#93370D}
.sg-status .btn{min-height:34px;font-size:14px;padding:0 14px}
