Effect of a horizontal magnetic field on convective instabilities in mercury