Why does light bend in a denser medium?
It doesn't. Light travels in a straight line in the medium, its path bends at the interface of different density mediums. After it bends it travels with a different speed.
Sorry I haven't answered your question, why. Atomic physics is not my field.
A denser medium typically has a higher index of refraction. When a wave moves at an angle other than 90 degrees into a medium with a higher refractive index than it's currently traveling in, it slows down. The part of the wavefront still moving in the lower refractive index medium continues to move at a higher speed and the wave "bunches up" on itself at the interface, changing its direction. (Bunches up is a highly technical term that means that the wave does something I'm not certain how to describe. :p)
Separate names with a comma.