.crop-modes{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:14px 0}.crop-mode{display:grid;align-content:start;gap:8px;min-width:0;padding:15px;border:2px solid var(--line);border-radius:12px;background:white;text-align:left;color:var(--ink);font-size:.8rem;line-height:1.4}.crop-mode strong{font-size:.875rem;letter-spacing:0;line-height:1.3}.crop-mode>span:not(.crop-mode-art){color:var(--muted)}.crop-mode[aria-pressed=true]{border-color:var(--graphite);background:#edfacd;box-shadow:0 0 0 1px var(--graphite)}.crop-mode-selection{font-size:.75rem;font-weight:700;color:var(--muted);align-self:end}.crop-mode[aria-pressed=true] .crop-mode-selection{color:#365310}.crop-mode-art{display:block;position:relative;width:66px;height:42px;border:1px solid #8b9b75;overflow:hidden;background:white;border-radius:3px}.crop-mode-art::before{content:"";display:block;position:absolute;inset:0;background:linear-gradient(155deg,#c1d693 0 40%,#819965 40% 60%,#355643 60%)}.crop-mode-art.fit::before{inset:0 13px}.crop-mode-art.fill::before{inset:-8px;transform:scale(1.1)}.crop-mode-art.keep::before{background:repeating-linear-gradient(135deg,#e4e9d9,#e4e9d9 5px,#f8faf4 5px,#f8faf4 10px)}.bulk-crop-mode{grid-column:1/-1}.bulk-crop-mode .crop-modes{grid-template-columns:repeat(3,minmax(0,1fr));margin-bottom:0}
.order-page .photo-card{padding:18px;display:flex;flex-direction:column;gap:8px}.order-page .photo-frame{height:205px;margin-bottom:4px}.order-page .photo-card .crop-modes{margin:4px 0 12px}.order-page .photo-card .photo-edit-button{display:flex;min-height:46px;font-size:.875rem;align-items:center;padding:12px 16px;background:var(--graphite);color:var(--lime);border:1px solid var(--graphite);text-decoration:none}.order-page .photo-card .photo-edit-button:hover{background:#30372c}.order-page .photo-card .photo-card-controls{grid-template-columns:100px}.order-page .photo-card .photo-quality{margin:4px 0}.photo-preparation-heading{border-top:1px solid var(--line);padding-top:26px;margin:24px 0 20px}.photo-preparation-heading p,#flow-self-settings>p{font-size:.875rem;color:var(--muted);margin:12px 0}
dialog.crop-dialog{width:min(1420px,calc(100vw - 32px));max-width:none;max-height:calc(100dvh - 32px);padding:0;border:0;border-radius:22px;background:var(--paper);color:var(--ink);overflow:auto}dialog.crop-dialog::backdrop{background:#0b100eda;backdrop-filter:blur(4px)}.crop-head{display:flex;align-items:start;justify-content:space-between;gap:20px;padding:24px 28px;background:white;border-bottom:1px solid var(--line)}.crop-head h2{font-size:1.65rem;letter-spacing:-.04em;margin:8px 0}.crop-head p{font-size:.875rem;color:var(--muted);overflow-wrap:anywhere;max-width:800px}.crop-close{border:1px solid var(--line);border-radius:10px;background:white;font-size:1.75rem;width:44px;height:44px;flex-shrink:0;line-height:1}.crop-layout{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:28px;padding:28px}.crop-preview-panel{min-width:0}.crop-preview-label{display:flex;flex-wrap:wrap;justify-content:space-between;gap:12px;font-size:.875rem;margin:0 0 14px}.crop-preview-label>span{color:var(--muted)}.crop-stage{height:clamp(260px,56dvh,650px);background:#343a35;border:1px solid #4e574e;border-radius:14px;padding:22px;display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative;min-width:0}.crop-stage canvas{display:block;max-width:100%;max-height:100%;width:auto;height:auto;box-shadow:0 6px 30px #0005;touch-action:none;cursor:grab;outline-offset:4px}.crop-stage[data-movable=false] canvas{cursor:default}.crop-stage canvas:active{cursor:grabbing}.crop-stage>p{font-size:.9375rem;color:#d7decd;text-align:center;max-width:340px}.crop-help{font-size:.8125rem;color:var(--muted);margin:14px 0 10px}.crop-settings{background:white;border:1px solid var(--line);border-radius:16px;padding:22px;align-self:start}.crop-settings h3{font-size:1.25rem;letter-spacing:-.035em}.crop-settings .crop-mode{padding:12px}.crop-zoom-row{display:flex;justify-content:space-between;gap:12px;margin:22px 0 8px;font-size:.875rem}.crop-zoom-row output{font:700 .875rem Arial,sans-serif;letter-spacing:0}.crop-zoom-controls{display:flex;align-items:center;gap:10px}.crop-zoom-controls button{border:1px solid var(--line);border-radius:9px;min-width:40px;min-height:40px;background:white;color:var(--ink);font-size:1.25rem}.crop-zoom-controls input{min-width:0;width:100%;min-height:40px;padding:0;accent-color:#73981c}.crop-settings .form-hint{font-size:.75rem;line-height:1.6}.crop-tools{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:20px 0}.crop-tools button{background:#f2f5eb;border:1px solid var(--line);border-radius:9px;padding:12px 8px;font-size:.8125rem;min-height:46px;color:var(--ink)}.crop-position summary{cursor:pointer;font-size:.8125rem;padding:12px 0}.crop-position label{font-size:.75rem}.crop-position input{padding:0;accent-color:#73981c}.crop-footer{border-top:1px solid var(--line);background:white;padding:18px 28px 24px}.crop-footer>p{font-size:.8125rem;color:var(--muted);margin-bottom:16px}.crop-actions{display:flex;justify-content:end;flex-wrap:wrap;gap:10px}.crop-actions .button{font-size:.8125rem;min-height:46px;padding:12px 18px}
@media(max-width:1100px){.crop-layout{grid-template-columns:minmax(0,1fr) 300px;gap:18px;padding:20px}.crop-settings{padding:16px}.crop-stage{padding:16px}.order-page .photo-preview{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:800px){dialog.crop-dialog{width:calc(100vw - 16px);max-height:calc(100dvh - 16px);border-radius:16px}.crop-layout{grid-template-columns:1fr}.crop-head{padding:18px}.crop-stage{height:46dvh;min-height:260px}.crop-settings .crop-modes{grid-template-columns:1fr 1fr}.crop-footer{padding:18px}.crop-actions{display:grid;grid-template-columns:1fr 1fr}.crop-actions .button{width:100%}.crop-actions #crop-save{grid-column:1/-1;order:-1}.crop-help{font-size:.8125rem}.crop-head h2{font-size:1.4rem}}
@media(max-width:520px){.order-page .photo-preview{grid-template-columns:1fr}.bulk-crop-mode .crop-modes{grid-template-columns:1fr}.bulk-crop-mode .crop-mode{grid-template-columns:66px 1fr}.bulk-crop-mode .crop-mode-art{grid-row:1/4}.crop-layout{padding:14px;gap:14px}.crop-stage{padding:12px}.crop-mode{padding:12px;gap:6px}.crop-head .eyebrow{font-size:.65rem}.crop-actions .button{padding:12px 8px;font-size:.75rem}.crop-settings .crop-mode-art{width:60px}.crop-preview-label{font-size:.8125rem}.crop-head p{font-size:.75rem}}
.bulk-crop-mode>span{font-size:.8rem;display:block}.order-page .photo-card button.photo-frame{width:100%;border:0;padding:16px;background:#e6eadf;cursor:pointer;text-decoration:none}.order-page .photo-card button.photo-frame:hover{background:#dde8ce}
/* Keep exit/save actions visible while the editor body scrolls. */
dialog.crop-dialog[open]{display:flex;flex-direction:column;height:min(1000px,calc(100dvh - 32px));overflow:hidden}.crop-head,.crop-footer{flex-shrink:0}.crop-layout{flex:1;min-height:0;overflow:auto}.crop-stage canvas{user-select:none}.crop-stage[data-movable=false] canvas{touch-action:pan-y}
@media(max-width:800px){dialog.crop-dialog[open]{height:calc(100dvh - 16px)}.crop-dialog .crop-actions #crop-save{grid-column:auto;order:initial}.crop-dialog .crop-footer>p{font-size:.75rem;margin-bottom:10px}.crop-dialog .crop-footer{padding:12px 18px}.crop-dialog .crop-actions{gap:8px}}
@media(max-width:800px){.crop-zoom-controls button{min-width:48px;min-height:48px}.crop-zoom-controls input{min-height:48px}.crop-settings input,.crop-settings select{font-size:16px}.crop-close{min-width:48px;min-height:48px}.crop-actions .button{min-height:48px}}
@media(max-width:600px){dialog.crop-dialog,dialog.crop-dialog[open]{inset:0;margin:0;width:100vw;max-width:100vw;height:100dvh;max-height:100dvh;border-radius:0}.crop-head{padding:14px 16px}.crop-head h2{font-size:1.3rem}.crop-head p{max-width:calc(100vw - 110px)}.crop-footer{padding-bottom:calc(12px + env(safe-area-inset-bottom))!important}.crop-dialog .crop-actions #crop-save{grid-column:2;grid-row:1;background:var(--lime);color:var(--ink)}.crop-dialog .crop-actions #crop-cancel{grid-column:1;grid-row:1}.crop-dialog .crop-actions #crop-prev,.crop-dialog .crop-actions #crop-next{grid-row:2}.crop-dialog .crop-actions .button{font-size:13px}}
@media(max-width:900px) and (max-height:500px){.crop-stage{min-height:150px;height:42dvh}.crop-head h2{font-size:1.15rem;margin:4px 0}.crop-head p{font-size:12px}.crop-footer>p{margin-bottom:6px}.crop-layout{padding:12px}.crop-actions .button{min-height:44px}}
.crop-head .crop-scope{font-size:12px;color:#587020;margin:0 0 6px;font-weight:700}.crop-retry{min-height:44px;margin-top:12px;font-size:14px}.checkout-photo .text-link{min-height:44px;display:flex;align-items:center;justify-content:center;font-size:12px;white-space:normal;text-decoration:underline;text-underline-offset:3px}
@media(min-width:801px){.crop-layout{overflow:hidden;grid-template-rows:minmax(0,1fr)}.crop-preview-panel{display:flex;flex-direction:column;min-height:0}.crop-stage{height:auto;min-height:140px;flex:1}.crop-preview-label,.crop-help,.crop-preview-panel>.photo-quality{flex-shrink:0}.crop-settings{align-self:stretch;min-height:0;max-height:100%;overflow-y:auto;overscroll-behavior:contain}.crop-preview-panel>.photo-quality{margin:0}.crop-preview-panel>.crop-retry{flex-shrink:0}}
@media(min-width:801px) and (max-height:850px){.crop-head{padding:14px 22px}.crop-head h2{margin:4px 0;font-size:1.35rem}.crop-head p{font-size:12px}.crop-layout{padding:18px;gap:18px}.crop-footer{padding:12px 22px}.crop-footer>p{margin-bottom:10px;font-size:12px}.crop-help{font-size:12px;margin:10px 0}.crop-actions .button{min-height:44px}.crop-preview-label{margin-bottom:10px;font-size:13px}}
@media(max-width:800px){.crop-stage{height:min(38dvh,360px);min-height:220px}.crop-head h2{margin:4px 0}.crop-head .crop-scope{font-size:11px}.crop-head p{margin:0}.crop-stage .crop-retry{min-height:44px}}
@media(max-width:800px) and (max-height:700px){.crop-stage{height:28dvh;min-height:150px}.crop-help{font-size:11px;margin:10px 0}.crop-head{padding:12px 16px}}
