The atmospheres of the gas giant planets are certainly deep enough (several earth diameters) for pressure effects to be the dominant source of heating, as opposed to solar radiation. See the para featuring refs 29 to 32 in:-
http://en.wikipedia.org/wiki/Jupiter
Also, the inverse square law tells us that a planet ~five times further away from the sun than us, as Jupiter is, gets 1/25 as much solar energy per unit area. I can't get much agreement from the 'net on what the figure for earth is because it is now snarled up by solar panel promotional bunf. If you look at
http://en.wikipedia.org/wiki/Insolation#Projection_effect
you'll see what sun angle (on account of latitude) does to affect how much energy the ground absorbs.
There's even a bit about Milankovich cycles, as the cyclical axial tilt changes further alter the projection angle effect.
//It should also explain why Earth is warmer on average than its nearby moon with hardly any//
My Collins guide (Ridpath/Tirion) says "Each spot on the moon is subjected to two weeks of daylight, during which temperatures reach the boiling point of water (100'C), followed by a two-week night when temperatures plummet to -170'C."
I make that an average of -35'C for the moon. I don't know what average you prefer to ascribe to earth (please let us know) but is a mere 10 miles* of atmosphere enough to account for the discrepancy?
(*Actually, if I remember rightly, about 90% of our atmosphere is found in the bottom 10,000 feet)
Greenhouse effect is what stops the planet from being an ice cube and that's with under half a percent CO2 in the mix.