Factory sunroofs have little holes in each corner attached to lengths of tubing for the purpose of water extraction.
I wouldn't recommend going the factory transplant route, unless you want to replace the whole roof skin.
It would be much easier to go with an aftermarket one...![]()