/* Sign PDF — tool-specific styles (loaded after /assets/base.css) */
.sg-stage { display: grid; grid-template-columns: 300px 1fr; gap: 20px; margin-top: 6px; }
.sg-sidebar h3 { margin: 0 0 12px; font-size: 1rem; }
.sg-tabs { gap: 6px; }
.sg-tabs .tab { padding: 8px 12px; font-size: .82rem; }
.sg-panel { margin: 14px 0; display: flex; flex-direction: column; gap: 10px; }
.sg-pad { width: 100%; height: 150px; background: #fff; border: 1px dashed var(--line); border-radius: var(--radius-sm); cursor: crosshair; touch-action: none; }
.sg-typein, .sg-font { background: var(--bg-soft); border: 1px solid var(--line); color: var(--text);
  padding: 11px 12px; border-radius: var(--radius-sm); font-size: .95rem; font-family: inherit; width: 100%; }
.sg-typein:focus, .sg-font:focus { outline: none; border-color: var(--accent); }
.sg-typepreview { min-height: 80px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm);
  display: grid; place-items: center; color: #111; font-size: 2.2rem; padding: 8px; overflow: hidden; }
.sg-uplabel { width: 100%; text-align: center; }
.sg-add { width: 100%; margin-top: 4px; }
.sg-tip { color: var(--muted-2); font-size: .8rem; margin: 8px 0 0; }

.sg-main { min-width: 0; }
.sg-pagebar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.sg-pagebar .btn { padding: 8px 13px; font-size: .85rem; }
.sg-pagebar .spacer { flex: 1; }
.sg-pagelabel { font-size: .88rem; color: var(--muted); font-variant-numeric: tabular-nums; }

.sg-canvas-wrap { position: relative; display: inline-block; max-width: 100%; border: 1px solid var(--line);
  border-radius: var(--radius-sm); overflow: hidden; background: #fff; box-shadow: var(--shadow-md, 0 10px 30px -16px rgba(0,0,0,.7)); }
#sgCanvas { display: block; max-width: 100%; height: auto; }
.sg-overlay { position: absolute; inset: 0; }
.sg-sig { position: absolute; cursor: move; border: 1px dashed rgba(108,139,255,.9); background-size: 100% 100%;
  background-repeat: no-repeat; touch-action: none; }
.sg-sig .sg-handle { position: absolute; right: -7px; bottom: -7px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent); border: 2px solid #fff; cursor: nwse-resize; }
.sg-sig .sg-del { position: absolute; left: -9px; top: -9px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--danger); color: #fff; border: none; cursor: pointer; font-size: .75rem; line-height: 1; display: grid; place-items: center; }

@media (max-width: 820px) { .sg-stage { grid-template-columns: 1fr; } }
