Scattering for the Klein-Gordon equation with quadratic and variable coefficient cubic nonlinearities