STRANGE DAY at the polls in the Far Northeast.

For 13 hours yesterday, labor unions accustomed to working shoulder-to-shoulder found themselves eye-to-eye on the battlefield, getting out the vote for two political novices in a low-profile special election on the fringe of the city.

It was quite civil on the surface. But a civil war was raging underneath.

Organized labor split apart and provided troops to both candidates. Some took up arms for the Republican. Orders are orders.

The result: Democrats lost a state House seat in a district in which President Obama got 57 percent of the vote in 2012 and where Democrats outnumber Republicans, 2-to-1.

Republican Martina White, 26, a financial adviser, was elected state representative in the 170th District, which covers the Bustleton-Somerton-Parkwood area of Northeast Philadelphia.

White easily defeated Democrat Sarah Del Ricci, 34, a horse trainer and director of the Parkwood Therapeutic Riding Center, in the special election to fill the vacancy left by former Democratic state Rep. Brendan Boyle, who was elected to Congress last year.

By most accounts, it was a self-imposed Democratic bloodbath.

Boyle, who in 2008 became the first Democrat to win the seat in the former Republican stronghold, was fuming last night.

"This could have remained a Democratic seat. But unfortunately, a couple Democratic ward leaders in the district chose personal relationships over the best interests of Northeast Philadelphia, the Democratic Party, and an extremely important ally: organized labor," Boyle said in a statement.

The run-up to the special election was nasty.

Boyle had wanted his successor to be Seth Kaplan, chief of staff for his brother, state Rep. Kevin Boyle. But Mike Stack, the lieutenant governor and a Democratic ward leader in the 170th, chose Pennsylvania Turnpike employee John Del Ricci, then later settled on Del Ricci's wife.

Things seemed to get uglier when Stack and his Democratic allies backed state Rep. John Sabatina Jr. to run for Stack's state Senate seat, which became vacant when Stack joined Gov. Wolf. Fraternal Order of Police president John McNesby had wanted to run as a Democrat for Stack's Senate seat.

The FOP and other labor unions that traditionally support Democrats ended up endorsing White in the 170th District race, sending hundreds of volunteers to work the polls and phone banks on her behalf.

White defeated Del Ricci with 57 percent of the vote. She is the first woman to hold the seat.

"I'm kind of speechless. It's incredible, this whole experience," White said from FOP headquarters last night. "I'm going to be working hard for the Northeast."

White, who knocked on about 5,800 doors during the campaign, said her two main priorities in Harrisburg will be securing education funding for Philadelphia children and keeping property taxes in check.

But she could be vulnerable in 2016, a presidential-election year when Democratic turnout will be high. Another battle is likely in next year's primary, when some of the unions that backed White could end up running a candidate to unseat her.

On Twitter: @wbender99