WASHINGTON — Voters sent Democrats sobering warnings this week: They’re not crazy about President Obama, the new health care law or the state of the economy – messages that could cause the party trouble as the 2014 election campaign intensifies.

Tuesday’s gubernatorial contests in New Jersey and Virginia provided fresh evidence that the voter mood remains glum and unpredictable.

Republican Gov. Chris Christie coasted to a second term in New Jersey, winning support from traditional Democratic constituencies, such as women and racial minorities. But it’s Virginia that’s being studied particularly closely, since it’s a state that can swing presidential elections. Democrats on Wednesday hailed Terry McAuliffe’s victory over tea party hero Ken Cuccinelli, a race where a mainstream Republican would have been favored. McAuliffe outraised and outspent Cuccinelli by more than 3 to 2, including a late surge of money that allowed him to dominate television advertising.

But all that money, as well as last-minute appearances by President Obama and Vice President Joe Biden, got McAuliffe only a 2.5-percentage point win.

Democratic problems were on display in this race, trouble that’s likely to dog the party into the coming year:

n Health care. Cuccinelli worked feverishly to make the election a referendum on the Affordable Care Act, popularly known as Obamacare. Democrats cheered Wednesday, saying that despite all the bad news about the botched web site launch, McAuliffe prevailed.

But voters signaled that Democrats need to be careful. More than half said they were opposed to the law, and they backed Cuccinelli 8 to 1. If that opposition intensifies, it could cause trouble in other swing states.

n Obama. Cuccinelli tried to paint McAuliffe as the president’s surrogate. It didn’t work, but in many states, “This president looks like he could be a drag,” said Kyle Kondik, the managing editor of Sabato’s Crystal Ball, an elections analysis web site, at the University of Virginia Center for Politics.

In Arkansas, for instance, last month’s statewide poll found that 29 percent of likely voters approved of Obama’s performance, while two-thirds disapproved. Those attitudes hurt incumbent Sen. Mark Pryor, D-Ark., who faces re-election next year. About one-third approved of the job he’s doing.

n Imperiled incumbents. Voters are skeptical of almost anyone who holds office in Washington – Republican or Democrat.

The unknown for Democrats in the 2014 equations is whether the party can separate itself from Obama. Incumbent presidents’ parties usually get battered in his sixth year. Democrats’ ambitions rest partly on confidence that the economy continues to grow. They’re counting on gradual acceptance of the health care law. Most important, they see a Republican Party with an extremist image that they hope will send fence-sitting voters their way.

Democrats pointed out Wednesday that most of the competitive Senate races next year feature Republican nominating battles between tea party favorites and more mainstream candidates.

The more the tea party prevails, Democrats think, the better the Democrats’ chances.