I'm in general chemistry, and I was wondering how ionic species crystallize and form the shapes they do, specifically in regard to the struvite precipitate $\ce{MgNH_4PO_4. 6H_2O}$.
Deconstructing the ionic species, we get $\ce{NH_4^+}$, which does not have a dipole moment (I think), $\ce{PO_4^{3-}}$, which also does not have a dipole moment, $\ce{H_2O}$, which has its dipole moment pointing towards the oxygen, and $\ce{Mg^{2+}}$, which is just an ion floating in solution.
Drawing the Lewis structures of these molecules and writing the Lewis structures, I'm not really sure how the crystal would form. But I do have a guess.
I feel as if the $+1$ formal charge on the nitrogen in $\ce{NH_4^+}$ will be attracted to one of the $-1$ formal charges on the oxygens in $\ce{PO_4^{3-}}$, while the magnesium ion will take in some of the free electrons on the other two oxygens. The $\ce{H_2O}$ will then form hydrogen bonds with the net dipole moment generated?
But this all sounds so hand-wavy to me, and I know it's probably wrong. Furthermore, I can't really visualize what this would look like. I honestly don't have a good understanding of how things work with crystallization. This is, after all, my first semester of chemistry.
If someone could give me tips and hints on how a struvite unit arranges its ions via electrostatic interactions to make something stable, I would appreciate it. Resources and pages in textbooks would be appreciated too!