You can get a sunburn even while sitting in the shade, by reflection and scattering.
Work Step by Step
Ultraviolet light is reflected by sand and also scattered by particles that make up the atmosphere (in fact, uv is scattered even more than visible light is scattered). The indirect exposure to uv light gives you the sunburn. This is discussed on pages 511-512.