A San Francisco home has sold for nearly double its asking price, the latest example of the city’s ultra-hot luxury market.