The problems for Obama are manifest across nearly his entire electoral map this year. According to the pro gay-marriage Human Rights Campaign, an array of battleground states have similar bans, including Colorado, Florida, Nevada, Ohio, Virginia, and Wisconsin. If Obama were to embrace same-sex marriage, he'd be on the wrong side of majorities in those states. He'd also risk creating the perception that he is trampling over the decisions of state residents to determine what they consider the right course of action for themselves.

"You think you're going to win a key state like North Carolina when you just thumb your nose at the voters?" said Brian Brown, president of the conservative National Organization for Marriage. "It makes no sense."

On a national level, supporters of gay marriage have gained remarkable political ground since the issue was last used as a wedge, during the 2004 presidential campaign. In 2004, Gallup found a solid majority of Americans opposed to changing marriage laws; in a poll released Tuesday, the organization found narrow majority support for gay marriage -- 50 percent to 48 percent. Gay marriage is legal in six states and will be in two others if voters don't derail new laws.

"We are in a completely different era than we were in just 2004 when it comes to this issue," said Campbell. "Attitudes have flipped."

During George W. Bush's 2004 re-election campaign, 13 states voted on marriage proposals, part of a conservative drive to boost turnout among evangelical voters supportive of the sitting president. After North Carolina, only four states -- Minnesota, Maine, Maryland and Washington -- are slated to have gay-marriage measures on the ballot.

But the potential for flare-ups is not limited to those states. In Iowa, for instance, another swing state that Obama is counting on, voters ousted three justices who had ruled a gay marriage ban unconstitutional.

Beyond swing-state sensitivities, Obama is also navigating cross-currents within his party. Social liberals and young people are pushing him to support gay marriage. But African-American voters, crucial to an Obama victory, are divided on the issue.

All this explains why the White House has struggled in recent days to define its position. Vice President Joe Biden made headlines Sunday when he expressed support for same-sex marriage, a statement the administration frantically walked back. Although Obama publicly opposed the Tar Heel State measure, his campaign was noticeably absent from weighing in on it. "They are tied in knots over this issue and looking pretty silly," said Whit Ayres, a GOP pollster.

Will Obama try to untie the knots, or leave them in a tangle for now? Either way, the North Carolina results underscore the price he and other Democrats could pay for their successes so far on the road toward gay marriage.