Light slows down when entering a denser medium due to interactions with atoms, which cause it to take a longer, zig-zag path, reducing its average speed. Upon exiting the medium, light appears to speed up, but it is actually returning to its original straight-line path at the speed of light, as it is no longer impeded by atomic interactions. The phenomenon does not contradict Newton's laws because light behaves differently from massive objects; it travels at a constant speed regardless of the medium. The scattering of photons in a medium can cause a light beam to fade over distance, as individual photons may be deflected in various directions. Understanding these principles clarifies the behavior of light in different environments and the nature of its speed.