The effect comes from surface plasmon resonance — electrons on the surface of gold nanoparticles oscillate when hit by light.