Structural principles of the hydrated polyborates