Shadow motion

 

Moving shadows are a strong cue to depth change. In this demonstration, the yellow square remains fixed in position on the screen, but when the dark grey area representing its shadow drifts downwards to the right the square appears to move forward away from the background. The cue provided by the moving shadow overrides contradictory information that the size of the square remains constant (size should increase as the square moves closer). The strength of the effect does depend on the properties of the shadow region. For example, shadows with a penumbra, and which fall below the object, work best.
The illusion shows that our perception of the spatial layout of scenes relies on the visual system's assumptions that light sources and large background objects are more likely to remain stationary than small objects. So motion of the shadow is attributed to the object casting it rather than to the light source or the background.
See:
Kersten, D., Mamassian, P., Knill, D. (1997) Moving cast shadows induce apparent motion in depth. Perception, 26, 171-192.
Mamassian, P., Knill, D. C., & Kersten, D. (1998). The perception of cast shadows. Trends in cognitive sciences, 2(8), 288-295.