Why is the moon moving away from the sun?
Actually it is more correct to state that the Moon is moving away from the Earth slowly over time. If the Moon is between the Earth and Sun, then the Moon is moving closer to the Sun but if the Earth is between the Sun and the Moon, then the Moon is moving further from the Sun.
The Earth and the Moon get about 4 cm further apart every year. This has to do with the gravitational pull that each body has on the other. It also is related to the fact that the Earth rotates on its axis much faster than the Moon rotates on its axis. The gravitational effect of the Moon on the Earth causes the tides and also causes the Earth to have a slightly oblong shape. The friction caused by these tidal bulges causes the Earth's rotation to slowly decrease over time. The effect of the Earth on the Moon causes it to try to speed up its orbit, thus imparting energy to the Moon's orbit and causing it to increase it size (thus moving further away from the Earth).
The universe or the cosmos is expanding because of the Big Bang and all the celestial bodies are getting apart. Its because of this that the moon is going away from us toooooooooo slowly 4 centimetres per year.
It means that it will take 25 years to go just 1 metre. hahaha