:root{
  --black:#000;--white:#fff;--grey:#6B6B6B;--fill:#E5E5E5;--red:#D32F2F;
  --r-lg:16px;--r-sm:8px;
  --font:"Inter",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  --side-w:clamp(340px,30vw,420px);
}
*{box-sizing:border-box;margin:0;padding:0}
html{-webkit-text-size-adjust:100%}
body{font-family:var(--font);color:var(--black);background:var(--white);line-height:1.5;min-height:100vh}
button,input,select{font:inherit;color:inherit}
button{cursor:pointer;background:none;border:0}
:focus-visible{outline:3px solid var(--black);outline-offset:3px}
.side :focus-visible{outline-color:var(--white)}
[hidden]{display:none!important}
.muted{font-size:13px;line-height:1.45;opacity:.7}
.muted.small{font-size:12px}

/* ---------- buttons ---------- */
.btn-primary{height:56px;width:100%;background:var(--white);color:var(--black);border-radius:var(--r-lg);font-weight:800;font-size:16px}
.btn-primary:disabled{opacity:.4;cursor:not-allowed}
.btn-primary.big{height:64px;font-size:18px}
.done .btn-primary,.empty .btn-primary{background:var(--black);color:var(--white)}
.btn-outline{height:52px;width:100%;border:2px solid var(--white);border-radius:var(--r-lg);font-weight:800;font-size:15px;color:var(--white)}
.link-btn{min-height:44px;padding:0 14px;font-weight:700;font-size:15px;border-radius:var(--r-sm);text-decoration:underline}

/* ---------- landing ---------- */
.topbar{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:24px 5%;flex-wrap:wrap}
.brand{display:flex;align-items:center;text-decoration:none}
.brand img{display:block;height:36px;width:auto}
.topbar-note{font-size:14px;font-weight:600}
.hero-title{margin:clamp(32px,7vh,88px) auto 0;max-width:1040px;padding:0 5%;text-align:center;font-size:clamp(38px,5.5vw,76px);line-height:1.02;font-weight:800;letter-spacing:-.035em;text-wrap:pretty}
.hero{display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:clamp(40px,5vw,80px);padding:clamp(40px,7vh,96px) 8% 0;max-width:1440px;margin:0 auto;align-items:start}
.hero-copy h2{font-size:clamp(26px,2.5vw,36px);line-height:1.1;font-weight:800;letter-spacing:-.025em;margin-bottom:20px}
.hero-copy p{font-size:17px;line-height:1.65;max-width:480px}
.hero-drop{display:flex;flex-direction:column;align-items:center;gap:14px}
.dropzone{width:100%;height:clamp(180px,30vh,300px);background:var(--black);color:var(--white);border:3px dashed var(--black);border-radius:var(--r-lg);font-weight:800;font-size:clamp(24px,2.4vw,32px);letter-spacing:-.02em}
.dropzone.over{background:var(--white);color:var(--black)}
.drop-hint{font-size:15px;font-weight:600}
.drop-meta{font-size:14px;text-align:center;line-height:1.55}
.features{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:48px;max-width:1440px;margin:clamp(56px,9vh,96px) auto 0;padding:0 8%}
.features h3{font-size:20px;font-weight:800;letter-spacing:-.02em;margin-bottom:10px}
.features p{font-size:15px;line-height:1.6;max-width:420px}

/* ---------- shared shell ---------- */
.work-shell,.crop-shell{display:flex;height:100vh;height:100dvh}
.work{flex:1;min-width:0;overflow:auto;padding:40px 48px}
.side{width:var(--side-w);flex:none;background:var(--black);color:var(--white);display:flex;flex-direction:column;overflow:auto}
.side-body{padding:36px 32px 32px;display:flex;flex-direction:column;gap:28px;flex:1}
.side-title{font-size:26px;font-weight:800;letter-spacing:-.02em;text-align:center}
.sheet-handle{display:none}
.mobile-process{display:none}

.field{display:flex;flex-direction:column;gap:10px}
.field-head{display:flex;justify-content:space-between;align-items:baseline}
.field-head label,.field-label{font-size:18px;font-weight:600}
.field-head span{font-weight:800;font-variant-numeric:tabular-nums}
.field.disabled{opacity:.45}

input[type=range]{-webkit-appearance:none;appearance:none;width:100%;height:4px;background:var(--white);border-radius:2px}
input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;width:24px;height:24px;border-radius:var(--r-sm);background:var(--white);border:3px solid var(--black);box-shadow:0 0 0 2px var(--white)}
input[type=range]::-moz-range-thumb{width:18px;height:18px;border-radius:var(--r-sm);background:var(--white);border:3px solid var(--black);box-shadow:0 0 0 2px var(--white)}
input[type=range]:disabled{opacity:.45}

.segmented{display:grid;grid-auto-flow:column;grid-auto-columns:1fr;border:1px solid var(--white);border-radius:var(--r-sm);overflow:hidden}
.segmented button{height:44px;color:var(--white);font-size:13px;font-weight:700;padding:0 4px;border-right:1px solid var(--white)}
.segmented button:last-child{border-right:0}
.segmented button.on{background:var(--white);color:var(--black)}
.segmented button:disabled{opacity:.35;cursor:not-allowed}
.segmented button:focus-visible{outline-offset:-4px}
.segmented.small button{height:40px}

select,input[type=number]{height:48px;width:100%;background:var(--fill);color:var(--black);border:0;border-radius:var(--r-sm);padding:0 14px;font-size:15px;font-weight:600}
.dims{display:grid;grid-template-columns:1fr 44px 1fr;gap:8px;align-items:end}
.dims.two{grid-template-columns:1fr 1fr}
.dims label{display:block;font-size:12px;margin-bottom:6px}
.lock{width:44px;height:48px;border:1px solid var(--white);border-radius:var(--r-sm);color:var(--white);display:flex;align-items:center;justify-content:center}
.lock.on{background:var(--white);color:var(--black)}

.check{display:flex;gap:12px;align-items:flex-start;font-size:14px;font-weight:600;cursor:pointer;line-height:1.4}
.check input{appearance:none;-webkit-appearance:none;flex:none;width:24px;height:24px;border:2px solid var(--white);border-radius:6px;position:relative;cursor:pointer}
.check input:checked{background:var(--white)}
.check input:checked::after{content:"✓";position:absolute;inset:0;display:flex;align-items:center;justify-content:center;color:var(--black);font-size:14px;font-weight:800}
.check small{display:block;font-weight:400;opacity:.7;font-size:12px;margin-top:2px}
.order-note{text-align:center}

.pills{display:flex;flex-wrap:wrap;gap:8px}
.pills button{height:40px;padding:0 14px;border:1px solid var(--white);border-radius:999px;color:var(--white);font-weight:700;font-size:13px}
.pills button.on{background:var(--white);color:var(--black)}

/* ---------- work area ---------- */
.work-toolbar{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;margin-bottom:24px;font-weight:700;font-size:15px}
.toolbar-actions{display:flex;gap:4px}
.toolbar-actions button{height:44px;padding:0 14px;font-weight:700;font-size:15px;border-radius:var(--r-sm)}
.toolbar-actions button:hover{background:var(--fill)}
.toolbar-actions .danger{color:var(--red)}
.work-home{display:inline-flex;margin-bottom:22px}
.work-home img{display:block;height:28px;width:auto}
.warn{border:1px solid var(--black);border-radius:var(--r-sm);padding:12px 14px;font-size:13px;line-height:1.45;font-weight:600;display:flex;gap:10px;align-items:flex-start;margin-bottom:20px}
.warn svg{flex:none;margin-top:1px}
.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:20px}
.card{border:1px solid var(--black);border-radius:var(--r-lg);padding:10px;display:flex;flex-direction:column;gap:10px;background:var(--white)}
.card.err{border-width:2px}
.thumb{position:relative;aspect-ratio:1;background:var(--grey);border-radius:10px;overflow:hidden}
.thumb img{width:100%;height:100%;object-fit:cover;display:block}
.card.err .thumb{background:var(--fill)}
.card-check,.card-remove{position:absolute;top:0;width:44px;height:44px;display:flex;align-items:center;justify-content:center}
.card-check{left:0}.card-remove{right:0}
.card-check span{width:24px;height:24px;border-radius:6px;border:2px solid var(--black);background:var(--white);color:var(--white);display:flex;align-items:center;justify-content:center;font-size:14px;font-weight:800}
.card.sel .card-check span{background:var(--black)}
.card-remove span{width:32px;height:32px;border-radius:var(--r-sm);background:var(--red);color:var(--white);font-size:18px;display:flex;align-items:center;justify-content:center}
.card-name{font-size:13px;font-weight:700;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.card-meta{font-size:12px;font-variant-numeric:tabular-nums}
.card.done .card-meta{font-weight:800}
.status{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:rgba(0,0,0,.5)}
.status>div{width:44px;height:44px;border-radius:50%;display:flex;align-items:center;justify-content:center}
.status.working>div{border:4px solid rgba(255,255,255,.35);border-top-color:var(--white);animation:spin .8s linear infinite}
.status.pending>div{border:4px solid rgba(255,255,255,.35)}
.status.ok>div{background:var(--white);color:var(--black);font-size:22px;font-weight:800}
.status.fail>div{background:var(--white);color:var(--black);font-size:22px;font-weight:800}
@keyframes spin{to{transform:rotate(360deg)}}
.processing{margin-bottom:28px;display:flex;flex-direction:column;gap:10px;align-items:flex-start}
.processing h2{font-size:28px;font-weight:800;letter-spacing:-.02em}
.progress{width:100%;max-width:520px;height:16px;border:2px solid var(--black);border-radius:var(--r-sm);overflow:hidden}
.progress-bar{height:100%;background:var(--black);width:0;transition:width .3s}
.empty{display:flex;flex-direction:column;align-items:flex-start;gap:12px;padding-top:40px}
.empty h2{font-size:28px;font-weight:800}
.empty .btn-primary{width:auto;padding:0 24px;height:52px}

/* ---------- crop ---------- */
.crop-main{flex:1;min-width:0;display:flex;flex-direction:column}
.crop-bar{height:88px;flex:none;display:flex;align-items:center;justify-content:space-between;padding:0 32px;gap:16px}
.crop-bar strong{font-size:20px;font-weight:800}
.crop-nav{display:flex;align-items:center;gap:6px;font-weight:700;font-size:14px;font-variant-numeric:tabular-nums}
.crop-nav button{width:44px;height:44px;border:1px solid var(--black);border-radius:var(--r-sm);font-size:22px;line-height:1}
.crop-body{flex:1;min-height:0;display:flex}
.rail{width:96px;flex:none;padding:16px;display:flex;flex-direction:column;gap:12px;overflow:auto}
.rail button{width:64px;height:64px;border-radius:var(--r-sm);overflow:hidden;border:3px solid transparent;background:var(--grey);flex:none;padding:0}
.rail button.on{border-color:var(--black)}
.rail img{width:100%;height:100%;object-fit:cover;display:block}
.crop-stage{flex:1;position:relative;overflow:hidden;background:#333;touch-action:none;padding:48px}
.crop-img-wrap{position:absolute;user-select:none}
.crop-img-wrap img{display:block;width:100%;height:100%;pointer-events:none}
.dim{position:absolute;background:rgba(0,0,0,.5);pointer-events:none}
.dim-t{left:0;right:0;top:0}.dim-b{left:0;right:0;bottom:0}
.dim-l{left:0}.dim-r{right:0}
.crop-rect{position:absolute;border:1px solid var(--white);cursor:move;box-sizing:content-box;margin:-1px}
.thirds{position:absolute;inset:0;pointer-events:none;background:
  linear-gradient(rgba(255,255,255,.5),rgba(255,255,255,.5)) 0 33.33%/100% 1px no-repeat,
  linear-gradient(rgba(255,255,255,.5),rgba(255,255,255,.5)) 0 66.66%/100% 1px no-repeat,
  linear-gradient(rgba(255,255,255,.5),rgba(255,255,255,.5)) 33.33% 0/1px 100% no-repeat,
  linear-gradient(rgba(255,255,255,.5),rgba(255,255,255,.5)) 66.66% 0/1px 100% no-repeat}
.handle{position:absolute;width:32px;height:32px;transform:translate(-50%,-50%);display:flex;align-items:center;justify-content:center}
.handle::after{content:"";width:12px;height:12px;background:var(--white)}
.handle[data-h=nw]{left:0;top:0;cursor:nwse-resize}.handle[data-h=n]{left:50%;top:0;cursor:ns-resize}.handle[data-h=ne]{left:100%;top:0;cursor:nesw-resize}
.handle[data-h=e]{left:100%;top:50%;cursor:ew-resize}.handle[data-h=se]{left:100%;top:100%;cursor:nwse-resize}.handle[data-h=s]{left:50%;top:100%;cursor:ns-resize}
.handle[data-h=sw]{left:0;top:100%;cursor:nesw-resize}.handle[data-h=w]{left:0;top:50%;cursor:ew-resize}

/* ---------- done ---------- */
.done{display:flex;flex-direction:column;align-items:center;padding:clamp(56px,12vh,120px) 6% 40px;min-height:100vh}
.done .done-title{font-size:clamp(30px,3.5vw,48px);font-weight:800;letter-spacing:-.03em;text-align:center;text-wrap:pretty}
.saved{margin-top:24px;font-size:clamp(36px,5vw,72px);font-weight:800;letter-spacing:-.04em;line-height:1.05;text-align:center;font-variant-numeric:tabular-nums;text-wrap:pretty}
.done-actions{margin-top:clamp(32px,6vh,56px);display:flex;flex-direction:column;align-items:center;gap:8px;width:min(420px,100%)}
.ad-slot{margin-top:clamp(32px,6vh,56px);width:min(728px,100%);min-height:90px;border:1px dashed var(--black);border-radius:var(--r-sm);display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:700}
.done #start-over{margin-top:auto;padding-top:40px}

/* ---------- mobile ---------- */
@media (max-width:760px){
  .work-shell,.crop-shell{flex-direction:column;height:auto;min-height:100dvh}
  .work{padding:16px 20px 220px;overflow:visible}
  .grid{grid-template-columns:repeat(2,1fr);gap:12px}
  .side{position:fixed;left:0;right:0;bottom:0;width:auto;z-index:6;border-radius:var(--r-lg) var(--r-lg) 0 0;max-height:80dvh}
  .side:not(.open) .side-body{display:none}
  .side.open{height:80dvh}
  .sheet-handle{display:flex;flex-direction:column;align-items:center;gap:10px;padding:10px 0 14px;color:var(--white);width:100%;font-size:13px;font-weight:600}
  .sheet-handle span:first-child{width:40px;height:4px;border-radius:2px;background:var(--white)}
  .side-body{padding:0 20px 24px;gap:22px}
  .side-body .btn-primary,.side-title{display:none}
  .mobile-process{display:block;position:fixed;left:20px;right:20px;bottom:64px;z-index:7;background:var(--black);color:var(--white);width:auto}
  .side.open ~ .mobile-process{display:none}
  .crop-shell{background:var(--black);height:100dvh;min-height:0}
  .crop-main{color:var(--white)}
  .crop-bar{height:64px;padding:0 16px}
  .crop-nav button{border-color:var(--white)}
  .crop-body{flex-direction:column-reverse;padding-bottom:64px}
  .rail{width:auto;flex-direction:row;padding:8px 16px}
  .rail button{width:52px;height:52px}
  .rail button.on{border-color:var(--white)}
  .crop-stage{padding:16px}
  #crop-side .btn-primary{display:block;background:var(--white);color:var(--black)}
  .done{min-height:100dvh}
}
@media (prefers-reduced-motion:reduce){
  .progress-bar{transition:none}
  .status.working>div{animation-duration:2s}
}

/* conversion landing pages */
.lp-title{margin-top:clamp(28px,5vh,56px)}
.lp-sub{max-width:640px;margin:20px auto 0;padding:0 6%;text-align:center;font-size:18px;line-height:1.6}
.lp-drop{max-width:520px;margin:clamp(32px,5vh,52px) auto 0;padding:0 6%;display:flex;flex-direction:column;align-items:center;gap:14px}
.lp-drop .dropzone{height:clamp(150px,24vh,220px)}
.screen>.site-head{margin-bottom:8px}

/* scroll cue + section divider */
.scroll-cue{display:flex;flex-direction:column;align-items:center;gap:6px;margin:clamp(40px,6vh,72px) auto 0;padding:12px 20px;width:max-content;color:inherit;text-decoration:none;font-size:14px;font-weight:600;border-radius:var(--r-sm)}
.scroll-cue:hover{background:var(--fill)}
.scroll-cue svg{animation:nudge 2.2s ease-in-out infinite}
@keyframes nudge{0%,60%,100%{transform:translateY(0)}30%{transform:translateY(5px)}}
.sep{border:0;border-top:1px solid var(--fill);max-width:820px;margin:clamp(64px,9vh,104px) auto 0;width:88%}
html{scroll-behavior:smooth}
#how-it-works{scroll-margin-top:32px}
@media (prefers-reduced-motion:reduce){.scroll-cue svg{animation:none}html{scroll-behavior:auto}}

/* ================= content pages & homepage content ================= */
.home-content,.prose{max-width:820px;margin:0 auto;padding:0 6%}
.home-content{margin-top:clamp(44px,6vh,64px)}
.home-content h2,.prose h2{font-size:clamp(24px,2.6vw,34px);font-weight:800;letter-spacing:-.025em;margin:56px 0 18px;text-wrap:balance}
.home-content h3,.prose h3{font-size:19px;font-weight:800;letter-spacing:-.015em;margin:32px 0 8px}
.prose h1{font-size:clamp(32px,4.4vw,52px);font-weight:800;letter-spacing:-.035em;line-height:1.05;margin-bottom:20px;text-wrap:pretty}
.prose{padding-top:48px;padding-bottom:64px}
.prose p,.home-content p{font-size:16px;line-height:1.7;margin-bottom:16px}
.prose .lede{font-size:19px;line-height:1.6;margin-bottom:20px}
.prose ul,.prose ol{margin:0 0 18px 22px}
.prose li{font-size:16px;line-height:1.7;margin-bottom:8px}
.prose a,.home-content a:not(.cta-btn){color:var(--black);text-underline-offset:3px}
.updated{font-size:13px;opacity:.6;margin-bottom:32px}
.crumb{font-size:13px;margin-bottom:24px;opacity:.75}
.crumb a{color:inherit}
.note{font-size:14px;opacity:.8}
table{width:100%;border-collapse:collapse;margin:8px 0 24px;font-size:15px}
th,td{text-align:left;padding:11px 12px;border-bottom:1px solid var(--fill)}
th{font-weight:800;border-bottom:2px solid var(--black);white-space:nowrap}
pre{background:var(--black);color:var(--white);padding:18px;border-radius:var(--r-sm);overflow-x:auto;margin:0 0 20px;font-size:13px;line-height:1.6}
code{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:.92em}
p code,li code{background:var(--fill);padding:2px 5px;border-radius:4px}
pre code{background:none;padding:0}

.steps{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:28px;margin-bottom:16px}
.steps span{display:flex;align-items:center;justify-content:center;width:38px;height:38px;border-radius:50%;background:var(--black);color:var(--white);font-weight:800;margin-bottom:12px}
.steps h3{margin-top:0}

.faq details{border-bottom:1px solid var(--fill)}
.faq summary{padding:16px 32px 16px 0;font-weight:600;font-size:16px;cursor:pointer;list-style:none;position:relative}
.faq summary::-webkit-details-marker{display:none}
.faq summary::after{content:"+";position:absolute;right:4px;top:14px;font-size:22px;font-weight:400}
.faq details[open] summary::after{content:"\2212"}
.faq p{padding:0 0 18px;opacity:.85;margin:0}

.card-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:16px;margin-bottom:16px}
.card-list a{display:block;border:1px solid var(--black);border-radius:var(--r-lg);padding:22px;text-decoration:none}
.card-list a:hover{background:var(--black);color:var(--white)}
.card-list h2,.card-list h3{font-size:18px;font-weight:800;margin:0 0 8px}
.card-list p{font-size:14px;line-height:1.55;margin:0;opacity:.8}

.site-head{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:22px 6%;border-bottom:1px solid var(--fill);flex-wrap:wrap}
.site-head nav{display:flex;gap:22px}
.site-head nav a{font-size:15px;font-weight:600;color:inherit;text-decoration:none}
.site-head nav a:hover{text-decoration:underline}

.cta-strip{background:var(--black);color:var(--white);text-align:center;padding:clamp(48px,8vh,80px) 6%;margin-top:48px}
.cta-strip h2{font-size:clamp(24px,3vw,36px);font-weight:800;letter-spacing:-.025em;margin-bottom:10px}
.cta-strip p{opacity:.75;margin-bottom:26px}
.cta-btn{display:inline-block;background:var(--white);color:var(--black);padding:17px 40px;border-radius:var(--r-lg);font-weight:800;text-decoration:none}

.site-foot{border-top:1px solid var(--fill);margin-top:clamp(80px,12vh,120px);padding:56px 6% 40px}
.foot-cols{display:grid;grid-template-columns:2fr 1fr 1fr;gap:40px;max-width:1100px;margin:0 auto 40px}
.foot-cols h4{font-size:14px;font-weight:800;margin-bottom:14px}
.foot-cols a{display:block;font-size:14px;color:inherit;text-decoration:none;margin-bottom:9px;opacity:.75}
.foot-cols a:hover{opacity:1;text-decoration:underline}
.foot-cols .brand{margin-bottom:14px;opacity:1}
.foot-cols p{font-size:14px;line-height:1.6;opacity:.75;max-width:320px}
.foot-legal{max-width:1100px;margin:0 auto;font-size:12px;line-height:1.6;opacity:.55}
@media (max-width:700px){
  .foot-cols{grid-template-columns:1fr;gap:32px}
  .site-head nav{gap:16px}
  table{font-size:14px}
  th,td{padding:9px 8px}
}

.card-list.compact{grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:12px}
.card-list.compact a{padding:16px 18px}
.card-list.compact h3{margin:0;font-size:16px}

/* post images */
.prose figure{margin:0 0 24px}
.prose figure img,.prose>img,.featured{display:block;width:100%;height:auto;border-radius:var(--r-lg);background:var(--fill)}
.featured{margin:0 0 28px}
.prose figcaption{font-size:13px;opacity:.7;margin-top:8px;line-height:1.5}
.card-list a img{display:block;width:100%;height:auto;aspect-ratio:1.91;object-fit:cover;border-radius:10px;margin-bottom:12px;background:var(--fill)}
