* Gravity: Gravity pulls air molecules towards the Earth's surface. This means there's more air compressed in the lower atmosphere, leading to higher density.
* Atmospheric pressure: The weight of the air above pushes down on the air below, creating atmospheric pressure. This pressure is higher at sea level, and decreases as you go up. Since density is related to pressure, higher pressure at lower altitudes means denser air.
* Temperature: Air temperature typically decreases with altitude. Colder air molecules move slower and are closer together, resulting in higher density.
In simpler terms: Imagine a stack of pillows. The bottom pillow is compressed by the weight of all the pillows above it. The top pillow has much less weight pushing down on it. The bottom pillow is denser because it's more compressed. The same concept applies to air.
Here's an analogy: Think of a balloon filled with air. If you squeeze the balloon, the air molecules inside get closer together, increasing its density. The air at the bottom of the atmosphere is like a squeezed balloon, while the air at the top of a mountain is like a less-squeezed balloon.