New research shows that spaces like libraries and after-school programs have a positive effect on teen health