Spin-orbit and spin-rotation coupling in doublet states of diatomic molecules