/* Fork A tool styles: crop, html paste, blank pdf preview */
.crop-wrap { display: grid; gap: 1rem; }
@media (min-width: 992px) { .crop-wrap { grid-template-columns: minmax(0, 1fr) 230px; align-items: start; } .crop-wrap .crop-margins { grid-template-columns: 1fr 1fr; } .crop-controls { position: sticky; top: 90px; } }
/* Option wrapper also carries the class "opt-radio" (opt-{type}); only the inner radiogroup is a grid. */
.opt.opt-radio { display: block; }
.crop-stage { position: relative; margin: 0 auto; max-width: 100%; width: fit-content; background: #fff; border-radius: 8px; box-shadow: var(--shadow); touch-action: none; user-select: none; }
.crop-canvas { display: block; max-width: 100%; max-height: 70vh; width: auto; height: auto; border-radius: 8px; }
.crop-rect { position: absolute; border: 2px solid var(--brand); box-shadow: 0 0 0 9999px rgba(27, 35, 65, .45); cursor: move; border-radius: 2px; }
.crop-stage { overflow: hidden; }
.crop-h { position: absolute; width: 16px; height: 16px; background: #fff; border: 2px solid var(--brand); border-radius: 50%; touch-action: none; }
.crop-nw { left: -9px; top: -9px; cursor: nwse-resize; } .crop-ne { right: -9px; top: -9px; cursor: nesw-resize; }
.crop-sw { left: -9px; bottom: -9px; cursor: nesw-resize; } .crop-se { right: -9px; bottom: -9px; cursor: nwse-resize; }
.crop-n { left: calc(50% - 8px); top: -9px; cursor: ns-resize; } .crop-s { left: calc(50% - 8px); bottom: -9px; cursor: ns-resize; }
.crop-w { top: calc(50% - 8px); left: -9px; cursor: ew-resize; } .crop-e { top: calc(50% - 8px); right: -9px; cursor: ew-resize; }
.crop-margins { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .5rem; }
.crop-controls { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: .75rem; }
@media (max-width: 575.98px) { .crop-margins { grid-template-columns: repeat(2, 1fr); } .crop-h { width: 22px; height: 22px; } }
.paste-html { max-width: 640px; margin: 1.25rem auto 0; text-align: start; }
.paste-html textarea { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .85rem; }
.paste-toggle { margin-top: .75rem; }
.blank-preview { display: flex; justify-content: center; padding: 1rem; }
.blank-preview canvas { background: #fff; box-shadow: var(--shadow); border-radius: 4px; max-width: 100%; height: auto; max-height: 60vh; }
.render-host { position: fixed; left: -10000px; top: 0; border: 0; background: #fff; }
