Dynamics of Planets, Stars, and Black Hole Binaries: Tides, Spin Resonances, and Gravitational Waves