Well, you could try this approach, but Bubble applies a default margin, so for even more control, you could simply create your own popup using a group nested within a floating group.
The parent FG would be set to inf width and height so that it covers the viewport and would serve as the semitransparent “overlay”, and the group inside would be styled like a popup and contain the content. Your close button would be the first child of the FG and remain in the upper left.
If you wanted the close button positioned relative to the popup’s content, just make it the first child of the content group and use negative left/top margins to position it “outside” the group. In other words, it would be inside hierarchically but outside visually.
-Steve