Deviations from Born-Oppenheimer mass scaling in spectroscopy and ultracold molecular physics