Also, blue light scatters as it passes through minute particles in the atmosphere. (I'm not a scientist, so I'm sure someone will argue with the way I'm stating this). As wavelengths get longer, they scatter less. This is why the sky is blue. Some of the blue is taken out of the full spectrum, remaining in the sky. So as the atmospheric prism transmits light going toward the red, we begin to see that gorgeous reddish glow. I've always suggested to folks, when they see a beautiful sunset, turn around and enjoy what it's lighting.
Long ago, back in the 60's, I read all of AA's Basic Photo series. Some things really stuck. One of those was where he wrote about using colored filters to control atmospheric perspective. If you want planes to recede, you know, like "Purple mountain majesty [...] amber waves of grain" you'd use a blue filter, which records the blue light due to moisture in the air. The greater the distance, the more you'd see of the haze, and things far away could be even invisible. Using a hard red filter, like a #25 or #29 (Wratten) the atmospheric haze is minimized; the red light cuts right through. You can see this effect most clearly by using infrared film with a filter that cuts out all but the infrared. It is quite amazing; I've used this to describe the edge where the clear cut logging abuts the old growth forest in the Olympic National Park in Washington State. The air is very moist over there (rain forest) so haze is the normal state. Infrared cut right through it showing no haze at all. In the image, each tree is clearly visible.
Randy's statement above: "as the sun sets, more of its light has to go through the "atmospheric prism" and more of the violet, blue and green light gets refracted away from your view and the redder the light becomes" is interesting in that were it NOT true that reddish light penetrates haze, we would expect that with the added depth of the atmosphere as seen looking toward the horizon, we would experience greater obscuring due to the haze. We don't, though. If you look out at the ocean on a sunny midday, the horizon is far less clear than it would be at sunset.
One thing I've always wondered but never (yet!) tested: If one were to set up two cameras, one with pan film and the other with infrared looking toward the horizon and with both, make the exposure at the exact moment that the sun goes down, would the infrared film show the image of part of the sun where the pan would not?