HELENA, Mont. — A powerful winter storm socked much of Montana with a wave of heavy snowfall on Sunday, with weekend totals climbing to 40 inches in some places, and breaking century-long daily records.

Never mind that it has only just turned to fall. Gov. Steve Bullock declared a winter emergency as cars skidded off highways, communities lost power and farmers despaired at the damage to crops that were still in the ground.

“It’s a February storm in September,” said Jeff Mow, the superintendent of Glacier National Park in the state’s mountainous northwest. “We’re used to this kind of storm, just not this time of year.”