[data-popup-backdrop] {
display: flex; justify-content: flex-end; align-items: flex-start;
}
This will open the popup on the top right side of the screen
and if you want it on the right centre of the screen you need on the align-items to put: centre. So the justify-content controls vertically and the align-items horizontally.
And if you want to remove the margins that do not have any space, do/copy this to your module's theme:
.popup-dialog {
margin: var(--space-none);
}
Try to put this CSS on your modules theme