USA TODAY, WASHINGTON – Nancy Pelosi, the only woman to have ever served as House speaker, was re-elected to the post on Thursday as Democrats took control of the House after eight years in the minority.

“Our nation is at an historic moment,” the California Democrat said. “Two months ago, the American people spoke, and demanded a new dawn.”

With a big boost from female voters, Democrats won a net 40 seats in the House in November’s midterm elections. That was their biggest gain since the post-Watergate election of 1974 when Democrats picked up 49 seats.

The midterm elections ushered in a record number of women and racially diverse lawmakers.

The shift in power in the House sets the stage for an era of divided government, with Democrats poised to clash with the Republican-dominated Senate and President Donald Trump on issues ranging from immigration to the budget to ongoing investigations involving the president and members of his administration.