Jim Harbaugh might have learned more about his San Francisco 49ers during 20 minutes of sleepwalking than at any other time in his two years as their coach. His 49ers turned a nearly historic collapse into a stunning victory and a playoff berth. They withstood a 28-point comeback by the New England Patriots to win 41-34 on Sunday night in a showdown of NFL powers played in a chilling rain.