Just over two years ago, when the housing bubble’s collapse was fresher in people’s minds, eight out of 10 people surveyed for a Pew Research report agreed that buying a home was the best long-term investment a person can make.