Environmental gradients and the evolution of tri-trophic interactions.