A federal judge in California refused to dismiss lawsuits alleging social media sites like YouTube and Facebook caused young users to get addicted and develop mental health problems.