:root{color:#1f2937;font-synthesis:none;background:#f3f4f6;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif}*{box-sizing:border-box}body{min-width:320px;min-height:100vh;margin:0}body.modal-open{overflow:hidden}button,input{font:inherit}button{touch-action:manipulation}.container{background:#fff;width:min(100%,760px);min-height:100vh;margin:0 auto;padding:28px 18px 60px}.app-header{margin-bottom:24px}h1{margin:0;font-size:clamp(28px,8vw,38px);line-height:1.2}.description{color:#6b7280;margin:12px 0 0;line-height:1.7}.select-button{color:#fff;cursor:pointer;-webkit-user-select:none;user-select:none;background:#2563eb;border-radius:14px;justify-content:center;align-items:center;min-height:58px;padding:12px 20px;font-weight:700;display:flex}.select-button:hover{background:#1d4ed8}.select-button:active{transform:scale(.98)}.select-button input{display:none}.page-summary{justify-content:space-between;align-items:center;gap:12px;margin:24px 0 12px;display:flex}#page-count{margin:0;font-weight:700}.clear-button{color:#dc2626;cursor:pointer;background:#fff;border:1px solid #ef4444;border-radius:10px;padding:8px 12px;font-weight:700}.preview-list{gap:22px;display:grid}.preview-card{background:#fff;border:1px solid #e5e7eb;border-radius:18px;overflow:hidden;box-shadow:0 5px 18px #00000017}.page-header{border-bottom:1px solid #e5e7eb;justify-content:space-between;align-items:center;gap:12px;padding:13px 14px;display:flex}.page-header p{margin:0;font-weight:800}.page-actions{align-items:center;gap:6px;display:flex}.small-button,.delete-button{cursor:pointer;border-radius:9px;min-width:42px;min-height:38px;font-weight:700}.small-button{color:#374151;background:#f9fafb;border:1px solid #d1d5db}.small-button:disabled{cursor:not-allowed;opacity:.35}.delete-button{color:#dc2626;background:#fff;border:1px solid #ef4444;padding:6px 12px}.image-frame{background:#d1d5db;justify-content:center;align-items:center;min-height:240px;padding:12px;display:flex}.image-frame img{object-fit:contain;image-rendering:auto;background:#fff;border-radius:8px;width:100%;max-height:680px;display:block}.processing-box{color:#4b5563;background:#f9fafb;border-radius:10px;justify-content:center;align-items:center;width:100%;min-height:260px;font-weight:700;display:flex}.editing-panel{gap:20px;padding:18px 16px;display:grid}.editing-group{gap:10px;display:grid}.editing-title{margin:0;font-weight:800}.crop-button{color:#fff;cursor:pointer;background:#0284c7;border:0;border-radius:12px;min-height:52px;padding:10px 14px;font-weight:800}.crop-button:hover{background:#0369a1}.crop-button:disabled,.tool-button:disabled,.enhance-button:disabled,.reset-button:disabled{cursor:wait;opacity:.55}.button-row{grid-template-columns:1fr 1fr;gap:10px;display:grid}.tool-button{color:#1f2937;cursor:pointer;background:#f8fafc;border:1px solid #cbd5e1;border-radius:10px;min-height:46px;padding:9px 12px;font-weight:700}.brightness-header{justify-content:space-between;align-items:center;display:flex}.brightness-value{color:#2563eb;font-weight:800}.brightness-slider{cursor:pointer;accent-color:#2563eb;width:100%}.enhance-button{color:#374151;cursor:pointer;background:#fff;border:1px solid #cbd5e1;border-radius:10px;min-height:48px;padding:10px 12px;font-weight:700}.enhance-button.active{color:#166534;background:#dcfce7;border-color:#16a34a}.reset-button{color:#4b5563;cursor:pointer;background:#fff;border:1px solid #9ca3af;border-radius:10px;min-height:44px;padding:9px 12px;font-weight:700}.pdf-area{background:#eff6ff;border:1px solid #dbeafe;border-radius:16px;margin-top:30px;padding:18px}.pdf-area label{margin-bottom:8px;font-weight:800;display:block}#pdf-name{color:#111827;background:#fff;border:1px solid #cbd5e1;border-radius:10px;width:100%;min-height:50px;padding:10px 12px}#pdf-name:focus{border-color:#2563eb;outline:3px solid #2563eb2e}.create-pdf-button{color:#fff;cursor:pointer;background:#16a34a;border:0;border-radius:12px;width:100%;min-height:56px;margin-top:14px;padding:12px 18px;font-weight:800}.create-pdf-button:disabled{cursor:wait;opacity:.6}.status{min-height:24px;margin:12px 0 0;font-weight:700}.status[data-type=working]{color:#1d4ed8}.status[data-type=success]{color:#15803d}.status[data-type=error]{color:#dc2626}.crop-modal{z-index:1000;background:#000000bd;place-items:center;padding:18px;display:grid;position:fixed;inset:0}.crop-dialog{background:#fff;border-radius:18px;width:min(100%,1020px);max-height:calc(100vh - 36px);display:grid;overflow:auto;box-shadow:0 24px 70px #00000059}.crop-dialog-header{border-bottom:1px solid #e5e7eb;justify-content:space-between;align-items:flex-start;gap:18px;padding:18px;display:flex}.crop-dialog-header h2{margin:0;font-size:22px}.crop-dialog-header p{color:#6b7280;margin:7px 0 0;line-height:1.55}.crop-orientation-buttons{gap:8px;margin-top:14px;display:flex}.orientation-button{color:#374151;cursor:pointer;background:#fff;border:1px solid #cbd5e1;border-radius:9px;min-height:40px;padding:7px 13px;font-weight:800}.orientation-button.active{color:#075985;background:#e0f2fe;border-color:#0284c7}.icon-close-button{color:#374151;cursor:pointer;background:#fff;border:1px solid #d1d5db;border-radius:50%;flex:none;place-items:center;width:42px;height:42px;font-size:26px;line-height:1;display:grid}.crop-canvas-frame{background:#111827;place-items:center;min-height:280px;padding:14px;display:grid;overflow:auto}#crop-canvas{touch-action:none;cursor:move;width:auto;max-width:100%;max-height:calc(100vh - 285px);display:block}.crop-dialog-actions{border-top:1px solid #e5e7eb;grid-template-columns:auto auto 1fr;gap:10px;padding:16px 18px 18px;display:grid}.primary-button,.secondary-button{cursor:pointer;border-radius:10px;min-height:48px;padding:10px 15px;font-weight:800}.primary-button{color:#fff;background:#0284c7;border:0}.secondary-button{color:#374151;background:#fff;border:1px solid #cbd5e1}[hidden]{display:none!important}@media (width<=620px){.container{padding:22px 12px 48px}.page-header{align-items:flex-start}.page-actions{flex-wrap:wrap;justify-content:flex-end}.editing-panel{padding:16px 13px}.crop-modal{padding:0}.crop-dialog{border-radius:0;width:100%;height:100dvh;max-height:100dvh}.crop-dialog-header{padding:14px}.crop-canvas-frame{min-height:0;padding:8px}#crop-canvas{max-height:calc(100dvh - 300px)}.crop-dialog-actions{grid-template-columns:1fr 1fr;padding:12px}.primary-button{grid-column:1/-1}}
