I figured out that it can be transformed in $|z| = iz$ and using the trigonometric method I get: $|z| = |z|(\cos(x) + i\sin(x))(\cos(\pi/2) + i\sin (\pi/2))$ which becomes $|z| = |z|(\sin(x) - i\cos(x))$
I delete $|z|$ from both sides and get $1 = \sin(x) - i\cos(x)$
But don't know how to continue... PS: I am open to other types of solutions, if more elegant. Thank you