Why does water flow downhill? Researching this topic, I found everyone just saying because of gravity. But that makes no sense to me. Gravity exerts a downward force:

But water flowing downhill goes sideways. There must be a sideways force  that is driving the water to the right (this force also has to overcome friction).
A ball could be forced sideways by the ground:

Adding these two forces, we clearly get a small force to the right.
But if water really worked like that, only the lowest level of water molecules would slide or roll sideways. Which is clearly not the case. All layers are moving.
And this only works on a tilted ground anyway. What about that: 

The ground is flat, so it can't cause any sideways force. But the water still moves sideways. Whats going on here?
 A: 
It's a flat ground, so it can't cause any sideward force. But the water still moves. Whats going on here?

The defining property of a fluid is that the shear stress is proportional to the shear rate. This means that if you have two parallel plates separated by a layer of fluid then the force required to slide the plates (shear stress) is proportional to how fast they are sliding (shear rate). The constant of proportionality is the viscosity. 
What may not be apparent is that there is a shear stress when gravity acts on that unsupported pile of water on flat ground in your last example. In that configuration the water is loaded in what is called pure compression. When a material is loaded in pure compression in the vertical direction then there is shear stress at 45 degrees from the vertical direction. This shear stress, applied to a fluid, causes the fluid to deform in shear. In other words, the fluid flows down. 
The amount of shear stress can be calculated using the principal stress approach. In this case, if the vertical direction is z, then the principal stresses are $\sigma_{zz}=\rho g h$ and $\sigma_{xx}=\sigma_{yy}=0$. The maximum shear stress is $\tau_{max}=(\sigma_{max}-\sigma_{min})/2=\rho g h/2$. This not only shows that the fluid will flow, but also that it flows faster the higher the unsupported pile of water is. This is consistent with common experience. 
Note also, although not part of your question, this same principle also explains why hydrostatic pressure is isotropic. In order for the fluid to be static there can be no shear rate and hence no shear stress. Since shear stress is half of the difference between the maximum and minimum principal stress and that must be zero then the maximum principal stress must equal the minimum principal stress. Therefore hydrostatic pressure must be isotropic. 
A: The molecules try to increase the entropy, so in order increase they will only be in a thin layer. The above layers will fall down to decrease the energy
