Ab initio crystal structure of nickel(II) hydroxy-terephthalate by synchrotron powder diffraction and magnetic study