The Geometry of Celestial Mechanics