LOS ANGELES (AP) — A rare summer thunderstorm brought lightning that sparked several small blazes in Northern California on Sunday and stoked a huge forest fire that has forced hundreds of people from their homes north of Los Angeles.

More than 4,500 buildings remained threatened by the wildfire, which was burning toward thick, dry brush in the Angeles National Forest. Firefighters already battling the blaze in steep, rugged terrain in scorching heat faced more hurdles Saturday when hundreds of lightning strikes and winds up to 15 mph (24 kph) pushed the flames uphill.

“We set up a containment line at the top of the hills so the fire doesn’t spill over to the other side and cause it to spread, but it was obviously difficult given the erratic wind and some other conditions,” said fire spokesman Jake Miller.

Get the app: Download the CBS Sacramento News app for iOS and Android

The Lake Fire was just 12% contained as of Sunday morning and has burned nearly 28 square miles (72 square kilometers) of brush and trees. Fire officials said 33 buildings had been destroyed, including at least a dozen homes.

Temperatures were expected to hit the mid-90s to 100s, Miller said, a slight drop from Saturday when the mercury hit 111 degrees (44 Celsius) on Saturday at the firefighters’ base camp. Thunderstorm and gusty wind could return in the late afternoon.

Thunderstorm and excessive heat were also a concern for firefighters battling a blaze that blackened almost 4 square miles (10 square kilometers) in the foothills above the Los Angeles suburb of Azusa. The fire, believed to be started Thursday by a homeless man, is only 3% contained.

Many areas of the state saw triple-digit temperatures through the weekend and the combination of prolonged heat and smoke from wildfires sent ozone pollution to levels not seen in a decade in some areas. Air quality may reach unhealthy to very unhealthy levels in several regions of Southern California on Sunday and Monday afternoons, the South Coast Air Quality Management District said.

In Northern California, a thunderstorm moving rapidly from the Pacific Ocean onshore brought thunder and more than 4,000 lightning strikes, some of which ignited small fires and knocked out power across the San Francisco Bay Area.

Wind gusts reached 75 mph (121 kph), according to the National Weather Service.

“This is probably the most widespread and violent summer thunderstorm event in memory for Bay Area, & it’s also one of the hottest nights in years,” tweeted Daniel Swain, a climate scientist at the University of California, Los Angeles.

Unsettling weather triggered an unusual warning by the weather service of a fire-induced tornado at an out-of-control forest fire that broke out north of Lake Tahoe on Saturday afternoon.

A massive fire cloud known as a pyrocumulonimbus formed over the fire, which started east of the town of Loyalton. When high winds came into contact with the fire and whipped it into the air, a spectacular tornado-shaped spiral of flames was formed.

The fire has burned at least 31 square miles (80 square kilometers) and triggered evacuation orders for sparsely populated portions of Plumas, Lassen and Sierra County, said Tahoe National Forest spokesman Joe Flannery.

Firefighters aided by water-dropping helicopters and air tankers faced “extreme fire behavior,” he said, and worked through the night to extinguish spot fires and protect threatened structures.

At one point, the fast-moving fire jumped a highway and came dangerously close to a fire truck. A fire crew from Truckee tweeted a video of firefighters dragging hoses as they ran alongside a moving truck that was dodging the flames.