When the University of Pennsylvania Health System sought new patients for its lung transplant service last year, it turned to Facebook and Google.