:root{color-scheme:dark;--paper:#101111;--ink:#f8f7f3;--muted:#c0c2bc;--line:#3a3d3b;--accent:#ffe56a;font-family:system-ui,-apple-system,'Segoe UI',sans-serif;color:var(--ink);background:var(--paper)}
*{box-sizing:border-box}
body{margin:0;min-width:300px}
h1,p,figure{margin:0}
[hidden]{display:none!important}
.masthead{height:73px;max-width:1352px;margin:auto;padding:0 44px;display:flex;align-items:center;border-bottom:1px solid var(--line)}
.brand{display:inline-flex;align-items:center;gap:10px;font-size:26px;font-weight:900;letter-spacing:-1.6px}
.dot{color:var(--accent);margin-left:-9px}
.mark{width:29px;height:26px;border:2px solid currentColor;border-radius:7px;display:grid;place-items:center;position:relative}
.mark:before{content:"";width:11px;height:11px;border:2px solid currentColor;border-radius:50%}
.mark:after{content:"";height:4px;width:4px;border-radius:50%;background:var(--accent);position:absolute;top:3px;right:3px}
.studio{max-width:1260px;margin:auto;padding:48px 44px;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:40px;align-items:center}
h1{font-size:clamp(50px,7vw,104px);font-weight:820;letter-spacing:-.075em;line-height:.96}
h1 span{color:var(--accent)}
.intro>p{font-size:clamp(16px,1.6vw,20px);line-height:1.5;color:var(--muted);margin-top:18px;max-width:350px}
.replace{min-height:58px;padding:0 24px;display:inline-flex;gap:10px;align-items:center;justify-content:center;border:0;border-radius:10px;background:linear-gradient(105deg,#ffe96c,#ffb865);color:#221609;font:750 17px system-ui,sans-serif;cursor:pointer;margin-top:25px}
.replace:hover{background:linear-gradient(105deg,#fff294,#ffca88)}
.replace:focus-visible,.compare:focus-within{outline:3px solid var(--accent);outline-offset:4px}
.intro .status{font-size:14px;margin-top:13px}
.status:empty{display:none}
.intro .status.error{color:#ffab9b}
.preview{min-width:0;max-width:100%;display:grid;justify-items:center}
.compare{--photo-ratio:1.333333;--split:38%;position:relative;isolation:isolate;overflow:hidden;width:min(100%,calc(65svh * var(--photo-ratio)));aspect-ratio:var(--photo-ratio);min-width:min(100%,210px);max-height:65svh;border-radius:10px;border:1px solid var(--line);background:#1c1d1b}
.compare img{position:absolute;inset:0;width:100%;height:100%;display:block;object-fit:contain;pointer-events:none;user-select:none}
.compare .before{clip-path:inset(0 calc(100% - var(--split)) 0 0)}
.stamp{position:absolute;top:12px;padding:6px 9px;z-index:1;background:#141515;color:var(--ink);border-radius:4px;font-size:13px;font-weight:750;pointer-events:none}
.stamp.left{left:12px}.stamp.right{right:12px}
.split-line{position:absolute;left:var(--split);top:0;bottom:0;width:2px;background:#fff;transform:translateX(-50%);pointer-events:none}
.knob{display:grid;place-items:center;position:absolute;top:50%;left:clamp(22px,var(--split),calc(100% - 22px));width:44px;height:44px;transform:translate(-50%,-50%);background:#f8f7f3;border-radius:50%;color:#151613;box-shadow:0 2px 10px #0006;pointer-events:none}
.compare input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:ew-resize;touch-action:pan-y}
figcaption{display:flex;justify-content:space-between;gap:16px;width:min(100%,450px);margin-top:10px;color:var(--muted);font-size:13px}
@media(max-width:760px){
  .masthead{height:60px;padding:0 19px}
  .brand{font-size:23px}
  .studio{display:flex;flex-direction:column;align-items:stretch;gap:19px;padding:19px 18px 30px}
  h1{font-size:clamp(36px,7.7vw,54px)}
  h1 br{display:none}
  .intro>p{margin-top:8px}
  .replace{margin-top:12px;min-height:48px}
  .compare{width:min(100%,calc(49svh * var(--photo-ratio)));max-height:49svh}
}

.progress{display:flex;align-items:center;gap:10px;margin-top:14px;color:var(--ink);font-size:14px;font-variant-numeric:tabular-nums}
.spinner{box-sizing:border-box;width:18px;height:18px;border:2px solid var(--line);border-top-color:var(--accent);border-radius:50%;animation:spin .8s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.spinner{animation:none}}
.download{display:table;margin-top:12px;color:var(--accent);font-weight:700;text-underline-offset:4px;min-height:44px;align-content:center}
.download:focus-visible{outline:3px solid var(--accent);outline-offset:4px}
