Second generation nitrogen doped titania nanoparticles: a comprehensive electronic and microstructural picture