:root{--paper:#f3f1e9;--card:#fffef9;--ink:#171915;--muted:#777970;--line:#d8d6cc;--acid:#c9f45b;--acid-dark:#78952e;--danger:#b64b3d;--shadow:0 18px 55px rgba(36,39,30,.09)}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;min-width:320px;background:var(--paper);color:var(--ink);font-family:"Avenir Next","PingFang SC","Microsoft YaHei",sans-serif;-webkit-font-smoothing:antialiased}button,input{font:inherit}button{color:inherit}.hidden{display:none!important}
.topbar{height:64px;padding:0 18px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line)}.brand{display:flex;align-items:center;gap:10px;color:inherit;text-decoration:none;font-weight:750;letter-spacing:-.02em}.brand-mark{width:31px;height:31px;border-radius:50%;display:grid;place-items:center;background:var(--ink);color:var(--acid);font-size:14px}.privacy-badge{font-size:11px;color:var(--muted);display:flex;align-items:center;gap:7px}.privacy-badge i{width:7px;height:7px;border-radius:50%;background:#8aae34;box-shadow:0 0 0 4px rgba(138,174,52,.12)}
main{width:min(100% - 28px,980px);margin:auto}.intro{padding:44px 4px 28px}.kicker{margin:0 0 13px;font-size:10px;font-weight:800;letter-spacing:.16em;color:#71833f}.intro h1{margin:0;font-size:clamp(43px,15vw,72px);line-height:.94;letter-spacing:-.065em;font-weight:640}.intro h1 span{color:#747a6a}.intro-copy{margin:20px 0 0;color:var(--muted);font-size:14px;line-height:1.7}
.tool-shell{background:var(--card);border:1px solid var(--line);border-radius:18px;box-shadow:var(--shadow);overflow:clip}.dropzone{min-height:245px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:9px;padding:28px;cursor:pointer;outline:none;background:radial-gradient(circle at 50% 10%,rgba(201,244,91,.2),transparent 42%)}.dropzone:focus-visible,.dropzone.drag{box-shadow:inset 0 0 0 3px var(--acid-dark)}.upload-glyph{width:62px;height:62px;margin-bottom:5px;border-radius:50%;display:grid;place-items:center;background:var(--ink);color:var(--acid);font-size:32px;font-weight:300}.dropzone strong{font-size:20px}.dropzone small{color:var(--muted)}
.selection-panel{padding:18px 14px 10px}.section-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:14px;font-size:14px}.section-head #countText{font-size:24px;font-weight:750}.text-actions{display:flex;gap:16px}.text-actions button{border:0;background:none;padding:10px 0;color:var(--muted);font-size:12px;text-decoration:underline;cursor:pointer}.file-list{display:flex;gap:10px;overflow-x:auto;padding:2px 2px 12px;scroll-snap-type:x proximity;scrollbar-width:none}.file-list::-webkit-scrollbar{display:none}.file-card{position:relative;flex:0 0 112px;scroll-snap-align:start}.file-card img{display:block;width:112px;height:112px;border-radius:12px;object-fit:cover;background:#e7e5dc}.file-card .remove{position:absolute;top:6px;right:6px;width:28px;height:28px;border:0;border-radius:50%;background:rgba(18,20,17,.78);color:white;cursor:pointer}.file-card p{margin:7px 1px 0;font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.file-card small{display:block;margin:3px 1px;color:var(--muted);font-size:9px}.file-card.failed img{outline:2px solid var(--danger)}
.format-field{border:0;margin:14px 0 0;padding:0}.format-field legend{margin-bottom:9px;font-size:12px;font-weight:700}.segments{display:grid;grid-template-columns:repeat(4,1fr);padding:3px;border-radius:12px;background:#ebe9e1}.segments label{cursor:pointer}.segments input{position:absolute;opacity:0;pointer-events:none}.segments span{min-height:43px;display:grid;place-items:center;border-radius:9px;font-size:12px;color:var(--muted)}.segments input:checked+span{background:var(--card);color:var(--ink);font-weight:750;box-shadow:0 2px 10px rgba(24,26,21,.08)}.segments input:focus-visible+span{outline:2px solid var(--acid-dark)}
.switches{margin-top:12px;border-top:1px solid var(--line)}.switch-row{min-height:72px;display:flex;align-items:center;justify-content:space-between;gap:18px;border-bottom:1px solid var(--line);cursor:pointer}.switch-row span{display:flex;flex-direction:column;gap:3px}.switch-row b{font-size:13px}.switch-row small{font-size:10px;color:var(--muted);line-height:1.4}.switch-row input{position:absolute;opacity:0}.switch-row i{position:relative;width:48px;height:28px;flex:none;border-radius:99px;background:#cfcec7;transition:.2s}.switch-row i:after{content:"";position:absolute;width:22px;height:22px;left:3px;top:3px;border-radius:50%;background:white;box-shadow:0 1px 4px rgba(0,0,0,.2);transition:.2s}.switch-row input:checked+i{background:var(--ink)}.switch-row input:checked+i:after{transform:translateX(20px);background:var(--acid)}.switch-row input:focus-visible+i{outline:2px solid var(--acid-dark);outline-offset:2px}.switch-row input:disabled+i{opacity:.45}
.sticky-action{position:sticky;bottom:0;padding:12px 0 max(8px,env(safe-area-inset-bottom));background:linear-gradient(transparent,var(--card) 22%)}.primary-action{width:100%;min-height:54px;border:0;border-radius:13px;padding:0 18px;background:var(--ink);color:white;font-weight:750;display:flex;align-items:center;justify-content:space-between;cursor:pointer}.primary-action span{color:var(--acid);font-size:23px}.primary-action:disabled{opacity:.55}.status{margin-top:13px;padding:12px 14px;border-radius:10px;background:#eff5df;color:#526321;font-size:12px}.status.error{background:#f8e5e1;color:#8a382e}.progress-wrap{height:6px;margin-top:10px;border-radius:99px;background:#dfded7;overflow:hidden}.progress-wrap div{height:100%;width:0;background:var(--acid-dark);transition:width .2s}
.results{padding:52px 2px 10px}.results-head{display:flex;flex-direction:column;align-items:flex-start;gap:17px}.results h2{font-size:25px;letter-spacing:-.04em;margin:0}.outline-action,.save-button,.retry-button{min-height:48px;border:1px solid var(--ink);border-radius:11px;background:transparent;padding:0 17px;font-weight:700;cursor:pointer}.results-summary{color:var(--muted);font-size:12px;margin:16px 0}.result-list{display:grid;grid-template-columns:1fr;gap:18px}.result-card{overflow:hidden;border:1px solid var(--line);border-radius:16px;background:var(--card)}.result-card>img{display:block;width:100%;height:auto;min-height:220px;max-height:75vh;object-fit:contain;background:repeating-conic-gradient(#eceae3 0 25%,#f7f6f0 0 50%) 50%/18px 18px;-webkit-touch-callout:default}.result-meta{padding:14px}.result-meta h3{font-size:13px;margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.result-meta p{font-size:10px;color:var(--muted);margin:6px 0 12px}.save-button{width:100%;background:var(--acid);border-color:#a8cc4c}.result-card.failed{padding:16px;border-color:#dca69f}.result-card.failed p{color:var(--danger);font-size:12px}.retry-button{width:100%}
.trust-strip{margin:42px 0 32px;padding:18px 0;display:flex;flex-direction:column;gap:12px;border-top:1px solid var(--line);border-bottom:1px solid var(--line);font-size:10px;color:var(--muted);letter-spacing:.05em}footer{padding:22px 18px 35px;display:flex;flex-direction:column;gap:7px;color:var(--muted);font-size:10px;border-top:1px solid var(--line)}
button:focus-visible,a:focus-visible{outline:3px solid var(--acid-dark);outline-offset:3px}
@media (min-width:800px){.topbar{padding:0 5vw}.intro{padding:72px 4px 42px}.tool-shell{border-radius:22px}.selection-panel{padding:24px}.results-head{flex-direction:row;align-items:end;justify-content:space-between}.result-list{grid-template-columns:repeat(2,1fr)}.trust-strip{flex-direction:row;justify-content:space-between}footer{padding:26px 5vw;flex-direction:row;justify-content:space-between}}
@media (prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
