Online connections hold double-edged impact on teen mental health, study finds