It's math. You have to figure the hypothenuse
or longest side of the triangle. A rectangle is merely two right angle triangles matched up. Use this link Triangle Hypotenuse Calculator Online -calculates angles and sides of right triangle, draws image of your triangle
Draw a rectangle representing the shower stall.
Width (AB) and Height (BC). You are looking for the diagonal line (AC) that goes from the top corner to the opposite side at the bottom (the pivot point when tipping the shower stall upright). Line AC has to be less than the height of your ceiling where the shower stall has to stand up (take into account that your roof arches so you need to measure the lowest point of the arch that the shower stall has to clear when standing upright. Alternative with the calculator in the link is to give the diagonal (AC) which would be the ceiling height and the width/depth of the shower stall and the calculator will tell you your max height the shower stall can be.
You shower stall will not fit like you want it too. There is a reason we put in a shower pan with FRP walls. You are about to learn it. Have fun.