#visual-crop-dialog{box-sizing:border-box;width:min(100vw,56rem);height:100dvh;max-width:100vw;max-height:100dvh;margin:auto;padding:0;border:0;border-radius:0;background:#11100d;color:#f7f2e7;overflow:hidden}
#visual-crop-dialog[open]{display:flex;flex-direction:column}
#visual-crop-dialog .crop-top{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:.6rem .8rem;flex:none}
#visual-crop-dialog h2{font-size:1.15rem;margin:0}
#visual-crop-dialog button{min-height:44px}
.crop-guide{padding:0 .8rem .5rem;flex:none;font-size:.9rem;line-height:1.4}
.crop-guide p{margin:.2rem 0}.crop-guide strong{color:#e6c267}
#visual-crop-viewport{flex:1;min-height:100px;overflow:auto;background:#050504;overscroll-behavior:contain}
#visual-crop-surface{display:flex;align-items:center;justify-content:center;min-width:100%;min-height:100%}
#visual-crop-frame{position:relative;flex:none;touch-action:none;user-select:none}
#visual-crop-photo{display:block;width:100%;height:100%;pointer-events:none}
#visual-crop-shade{position:absolute;inset:0;background:#0009;pointer-events:none}
#visual-crop-dialog #visual-crop-box{position:absolute;box-sizing:border-box;border:2px solid #f3ce71;cursor:move;outline-offset:-5px;min-width:0;min-height:0;background:transparent;border-radius:0;padding:0}
#visual-crop-frame [data-crop-corner]{position:absolute;transform:translate(-50%,-50%);width:48px;height:48px;min-width:48px;padding:0;border:0;background:transparent;touch-action:none}
#visual-crop-frame [data-crop-corner]::after{content:'';display:block;width:18px;height:18px;background:#f3ce71;border:2px solid #15120b;border-radius:50%;margin:auto;box-shadow:0 0 0 2px #f3ce71}
#visual-crop-frame[data-pan=true]{cursor:grab}
.crop-toolbar{display:flex;flex-wrap:wrap;justify-content:center;gap:.35rem;padding:.4rem .65rem;flex:none}.crop-toolbar button{padding:.4rem .75rem}.crop-toolbar button[aria-pressed=true]{background:#e6c267;color:#17130a}
.crop-bottom{padding:0 .8rem max(.7rem,env(safe-area-inset-bottom));flex:none}.crop-bottom p{margin:0 0 .4rem;font-size:.8rem;color:#d2c8b5}
.crop-decisions{display:flex;gap:.5rem}.crop-decisions button{flex:1;min-width:0;padding:.6rem .5rem;white-space:normal;overflow-wrap:break-word}
@media(min-width:700px){#visual-crop-dialog{height:94dvh;border-radius:1rem}.crop-guide{display:flex;gap:1.2rem}}
@media(max-height:520px){.crop-guide p{margin:0}.crop-guide{font-size:.8rem}.crop-top{padding:.25rem .8rem!important}.crop-toolbar{padding:.2rem}.crop-bottom p{display:none}}
