By David Bailey
(Reuters) - North Dakota Democrat Heidi Heitkamp narrowly defeated Republican U.S. Representative Rick Berg in the last undecided U.S. Senate race in the nation, unofficial returns showed on Wednesday.
The outcome of Tuesday's race capped a disappointing election night for Senate Republicans, who had hoped to make a net gain of four seats to take the majority. They ended up losing two seats to Democrats in Indiana and Massachusetts, and a third to an independent in Maine.
Republicans had counted on winning in North Dakota after Democratic Senator Kent Conrad announced he was retiring after 26 years.
Heitkamp prevailed by nearly 3,000 votes, or just under 1 percent, out of nearly 320,000 votes cast, according to unofficial state election returns.
Berg conceded the election to Heitkamp on Wednesday and thanked supporters. He said he did not expect the outcome to change with the final certification of the vote.
"I know a lot of people on both sides of the aisle worked very hard in this election," Heitkamp said in a statement on Facebook after Berg's concession. "I am so grateful for the people who gave me their votes and this victory."
Heitkamp, 57, a cancer survivor, served two terms as North Dakota's attorney general in the 1990s and ran unsuccessfully for governor in 2000.
Democrats had held all three of the congressional seats in the conservative-leaning state as recently as 2010. But Heitkamp will be serving with Republican Senator John Hoeven and Kevin Cramer, a Republican elected on Tuesday to fill Berg's seat.
Berg, 53, is in his first term as North Dakota's only U.S. representative.
Republican presidential nominee Mitt Romney took North Dakota by a wide margin, 58 percent to President Barack Obama's 39 percent.
Berg and Heitkamp both support North Dakota's oil business as production has soared over the past five years to make it the second biggest oil-producing state behind Texas, fueling the local economy and generating big state budget surpluses.
(Additional reporting by Todd Melby in Minneapolis; Editing by Greg McCune and Xavier Briand)