Why not use a 3/8" stud and nut or just switch to a 3/8" bolt? Use thread sealer on it because they are wet.
I never heard of a 5/8" stud, so maybe I'm reading your post incorrectly. If you mean it was 5/16" diameter into the head, then go with with 5/16" all the way. You did get the broken...