.scanner{padding:36px 0 72px}.scan-head{flex-wrap:wrap;justify-content:space-between;align-items:flex-end;gap:16px;margin-bottom:24px;display:flex}.scan-head h1{margin-bottom:4px;font-size:2rem}.scan-head .fine{margin:0}.scan-actions{flex-wrap:wrap;gap:10px;display:flex}@media (hover:hover) and (pointer:fine){.camera-only{display:none!important}}label.btn{cursor:pointer}label.btn:focus-within{outline:3px solid color-mix(in srgb, var(--primary) 40%, transparent);outline-offset:2px}.dropzone{border:2px dashed var(--border);background:var(--surface);text-align:center;border-radius:22px;padding:56px 24px;transition:border-color .2s,background .2s}.dropzone svg{width:64px;height:64px;color:var(--primary);margin:0 auto 12px}.dropzone h2{font-size:1.5rem}.dropzone p{color:var(--text-2);max-width:520px;margin-inline:auto}.dropzone .cta-row{justify-content:center}.dropzone.dragging,body.dragging .pages{border-color:var(--primary);background:var(--primary-soft)}.pages{border-radius:18px;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));gap:18px;display:grid}.pages:empty{display:none}.page-card{background:var(--surface);border:1px solid var(--border);border-radius:16px;flex-direction:column;margin:0;display:flex;overflow:hidden}.page-card .thumb{aspect-ratio:3/4;background:var(--surface-alt);cursor:pointer;border:0;width:100%;padding:8px;display:block;position:relative}.page-card .thumb img{object-fit:contain;width:calc(100% - 16px);height:calc(100% - 16px);position:absolute;inset:8px}.page-card .thumb .edit-hint{color:#fff;opacity:0;background:#11161dbf;border-radius:99px;padding:3px 9px;font-size:.75rem;font-weight:700;transition:opacity .2s;position:absolute;inset:auto 8px 8px auto}.page-card .thumb:hover .edit-hint,.page-card .thumb:focus-visible .edit-hint{opacity:1}.page-card figcaption{justify-content:space-between;align-items:center;padding:4px 6px;display:flex}.page-card .num{color:#fff;background:#11161dbf;border-radius:99px;place-items:center;min-width:26px;height:26px;padding:0 7px;font-size:.85rem;font-weight:800;display:grid;position:absolute;top:8px;left:8px}.icon-btn{width:32px;height:32px;color:var(--text-2);cursor:pointer;background:0 0;border:0;border-radius:9px;place-items:center;display:inline-grid}.icon-btn:hover:not(:disabled){background:var(--surface-alt);color:var(--text)}.icon-btn:disabled{opacity:.3;cursor:default}.icon-btn.danger:hover{color:var(--danger)}.icon-btn svg{width:19px;height:19px}.export{gap:16px;margin-top:24px;display:grid}.export-fields{grid-template-columns:2fr 1fr;gap:14px;display:grid}@media (width<=600px){.export-fields{grid-template-columns:1fr}}.export label span{margin-bottom:6px;font-size:.9rem;font-weight:700;display:block}.export input,.export select{border:1px solid var(--border);background:var(--bg);width:100%;min-height:46px;color:var(--text);font:inherit;border-radius:10px;padding:0 12px}.export-actions{flex-wrap:wrap;gap:10px;display:flex}.export .fine{margin:0}.upsell{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:18px;margin-top:28px;display:flex}.upsell h2{margin-bottom:4px;font-size:1.3rem}.upsell p{color:var(--text-2);max-width:560px;margin:0}.editor{background:var(--surface);width:min(1100px,100vw - 24px);max-height:calc(100vh - 24px);color:var(--text);border:0;border-radius:20px;padding:0;box-shadow:0 30px 80px #0006}.editor::backdrop{background:#0a0e1499}.editor-inner{flex-direction:column;max-height:calc(100vh - 24px);display:flex}.editor-head{border-bottom:1px solid var(--border);justify-content:space-between;align-items:center;gap:12px;padding:14px 18px;display:flex}.editor-head h2{margin:0;font-size:1.15rem}.editor-buttons{gap:8px;display:flex}.editor-body{grid-template-columns:1fr 1fr;gap:18px;padding:18px;display:grid;overflow:auto}@media (width<=760px){.editor-body{grid-template-columns:1fr}}.pane{flex-direction:column;gap:12px;min-width:0;display:flex}.pane-title{color:var(--text-2);margin:0;font-size:.9rem;font-weight:700}.pane .row{flex-wrap:wrap;gap:8px;display:flex}.crop-stage,.result-stage{background:#12161c;border-radius:14px;place-items:center;min-height:260px;padding:18px;display:grid}.crop-wrap{touch-action:none;-webkit-user-select:none;user-select:none;position:relative}.crop-wrap canvas{width:auto;max-width:100%;height:auto;max-height:58vh;display:block}.crop-wrap svg{pointer-events:none;width:100%;height:100%;position:absolute;inset:0;overflow:visible}.handle{border:3px solid var(--primary);cursor:grab;touch-action:none;background:#fff6;border-radius:50%;width:30px;height:30px;margin:-15px 0 0 -15px;padding:0;position:absolute}.handle:active{cursor:grabbing}.handle:after{content:"";position:absolute;inset:-12px}.crop-wrap.invalid polygon{stroke:#ff5a5f}.result-stage canvas{background:#fff;width:auto;max-width:100%;height:auto;max-height:58vh;display:block}.chips{flex-wrap:wrap;gap:8px;display:flex}.chip{border:1px solid var(--border);background:var(--bg);color:var(--text);font:inherit;cursor:pointer;border-radius:99px;padding:8px 14px;font-size:.9rem;font-weight:600}.chip[aria-checked=true]{background:var(--primary);border-color:var(--primary);color:var(--on-primary)}.busy{z-index:50;background:#0a0e1473;place-items:center;display:grid;position:fixed;inset:0}.busy[hidden]{display:none}.busy-box{background:var(--surface);box-shadow:var(--shadow);border-radius:16px;align-items:center;gap:14px;padding:22px 28px;font-weight:700;display:flex}.spinner{border:3px solid var(--primary-soft);border-top-color:var(--primary);border-radius:50%;width:26px;height:26px;animation:.8s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}.toast{z-index:60;background:var(--text);color:var(--bg);box-shadow:var(--shadow);border-radius:12px;max-width:calc(100vw - 32px);padding:12px 18px;font-weight:600;position:fixed;bottom:24px;left:50%;transform:translate(-50%)}
