Exactly what I was told as a child, and hence have 'known' for more than fifty years.
Wait, no, it doesn't work like that.
Not sure if UVA could cause the “color” you describe. Supposedly only UVB causes tanning and sunburn. Might also just be a reaction to the heat?