.ts-image-cropper-modal {
    position: fixed;
    inset: 0;
    z-index: 1000000;
    display: none;
}

.ts-image-cropper-modal.show { display: block; }

.ts-image-cropper-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.76);
}

.ts-image-cropper-dialog {
    position: relative;
    width: min(1040px, calc(100vw - 24px));
    max-height: calc(100vh - 24px);
    margin: 12px auto;
    padding: 16px;
    overflow: auto;
    box-sizing: border-box;
    background: #fff;
    border-radius: 12px;
    direction: rtl;
    box-shadow: 0 12px 45px rgba(0,0,0,.35);
}

.ts-image-cropper-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 6px;
}

.ts-image-cropper-help {
    font-size: 13px;
    color: #666;
    margin-bottom: 12px;
    line-height: 1.8;
}

.ts-image-cropper-stage {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 240px;
    background: #1b1b1b;
    border-radius: 9px;
    overflow: hidden;
    touch-action: none;
}

.ts-image-cropper-stage canvas {
    display: block;
    max-width: 100%;
    max-height: calc(100vh - 290px);
    cursor: move;
    touch-action: none;
    user-select: none;
}

.ts-image-cropper-actions {
    display: flex;
    justify-content: flex-start;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 14px;
}

.ts-image-cropper-actions button {
    min-height: 40px;
}

body.ts-image-cropper-open { overflow: hidden; }

@media (max-width: 600px) {
    .ts-image-cropper-dialog {
        width: calc(100vw - 12px);
        max-height: calc(100vh - 12px);
        margin: 6px auto;
        padding: 10px;
        border-radius: 9px;
    }
    .ts-image-cropper-title { font-size: 18px; }
    .ts-image-cropper-help { font-size: 12px; }
    .ts-image-cropper-actions button { flex: 1 1 auto; }
}
