.avatar-editor{width:min(520px,calc(100vw - 24px));max-width:none;max-height:calc(100dvh - 24px);padding:0;overflow:visible;border:1px solid #ffffff12;border-radius:19px;background:#111114;color:#f1eff5;box-shadow:0 28px 90px #000b}
.avatar-editor::backdrop{background:#030304c9;backdrop-filter:blur(5px)}
.avatar-editor-panel{padding:22px 22px 18px}
.avatar-editor-header{display:flex;align-items:center;justify-content:space-between;gap:15px;margin-bottom:18px}
.avatar-editor-header h2{margin:0;color:#f1eff5;font-size:19px;font-weight:750;letter-spacing:-.035em}
.avatar-editor-close{display:grid;width:34px;height:34px;place-items:center;border:0;border-radius:10px;background:transparent;color:#96939d;font-size:27px;line-height:1;cursor:pointer;transition:color .18s,background .18s}
.avatar-editor-close:hover{background:#ffffff0c;color:#fff}
.avatar-editor-stage{position:relative;display:grid;width:100%;height:min(350px,48vh);min-height:230px;place-items:center;overflow:hidden;border-radius:12px;background:#1d1d21;touch-action:none;cursor:grab;isolation:isolate}
.avatar-editor-stage:active{cursor:grabbing}
.avatar-editor-media{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;transform-origin:center;user-select:none;-webkit-user-drag:none}
.avatar-editor-window{position:absolute;z-index:1;width:min(80%,280px);aspect-ratio:1;border:3px solid #fff;border-radius:50%;box-shadow:0 0 0 999px #08080c80,0 0 22px #f3e6ff75;pointer-events:none}
.avatar-editor-hint{position:absolute;z-index:2;bottom:8px;left:50%;margin:0;padding:5px 9px;border-radius:999px;background:#08080bcc;color:#dbd7e1;font-size:10px;white-space:nowrap;transform:translateX(-50%);pointer-events:none}
.avatar-editor-controls{display:grid;grid-template-columns:20px 1fr 23px;align-items:center;gap:12px;margin:22px 4px 17px;color:#a4a2ab}
.avatar-editor-controls svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.avatar-editor-controls .avatar-editor-large-icon{width:22px;height:22px}
.avatar-editor-zoom{width:100%;height:4px;margin:0;accent-color:#fff;cursor:pointer}
.avatar-editor-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-top:14px;border-top:1px solid #ffffff10}
.avatar-editor-footer span{color:#8d8994;font-size:11px}
.avatar-editor-save{min-height:40px;padding:0 16px;border:1px solid #b788ff66;border-radius:11px;background:linear-gradient(135deg,#8a48e8,#6f36cf);color:#fff;font:inherit;font-size:12px;font-weight:750;cursor:pointer;box-shadow:0 7px 20px #7138c433;transition:filter .18s,transform .18s}
.avatar-editor-save:hover{filter:brightness(1.12);transform:translateY(-1px)}
.avatar-editor-save:disabled{opacity:.55;cursor:wait;transform:none}
@media(max-width:560px){.avatar-editor-panel{padding:18px 16px 14px}.avatar-editor-header h2{font-size:17px}.avatar-editor-stage{height:min(64vw,42vh);min-height:210px}.avatar-editor-footer{align-items:flex-start;flex-direction:column}.avatar-editor-save{width:100%}}
@media(prefers-reduced-motion:reduce){.avatar-editor *{transition:none!important}}
