Rick Santorum’s departure from the presidential race could not come soon enough for Mitt Romney. In proving himself more tenacious than anyone predicted, Santorum dramatized one of Romney’s major problems, created another and forced the now-inevitable Republican nominee into a strategic dilemma.

Republicans may condemn class warfare, but their primaries turned into a class struggle. Romney performed best among voters with high incomes, and he was consistently weaker with the white working class, even in the late primaries where he put Santorum away. And Romney cannot win without rolling up very large margins among less well-off whites.

At the same time, Santorum’s strength among evangelical Christians pressured Romney to toughen his positions even as the Republican Party as a whole, at both the state and national levels, has pushed policies on contraception and abortion that have alienated many women, particularly the college-educated.

This is Romney’s other problem: Among college-educated white men, Romney had a healthy 57 percent to 39 percent lead over President Obama in the latest Washington Post/ABC News poll. But among college-educated white women, Obama led Romney by 60 percent to 40 percent. This netted to a rather astounding 38-point gender gap, compared with a net 27-point gap among all white voters. (Thanks to Peyton Craighill of The Washington Post’s polling staff for extracting these numbers, which are based on registered voters.) Overall, the poll taken before Santorum left the race showed Obama leading Romney by 51 percent to 44 percent.

Thus the box the primaries built for Romney: He must simultaneously court evangelical Christians and working-class voters who have eluded him so far and also reassure socially moderate women higher up the class ladder who, for now, are providing Obama with decisive margins. It’s not easy to do both.

Even if the most conservative Republicans who supported Santorum and Newt Gingrich largely fall into line out of antipathy to Obama, Romney still has to worry about whether they’ll be enthusiastic enough to turn out in the large numbers he’ll need. Yet if he concentrates on winning back upscale women, who now favor Obama by even larger margins than they gave him in 2008, Romney will only aggravate his enthusiasm problem on the right.

Romney’s predicament is Obama’s opportunity. The president is moving aggressively to take advantage of the class opening afforded him by the candidate of “a couple of Cadillacs,” “I like being able to fire people” and “corporations are people, my friend.” In a series of speeches in Florida the day Santorum withdrew, Obama hit repeatedly on the twin themes of fairness and opportunity. He called for a nation in which “everybody gets a fair shot, and everybody does a fair share, and everybody plays by the same set of rules,” while eviscerating Rep. Paul Ryan’s fiscal plan, which Romney supports, as a budget “that showers the wealthiest Americans with even more tax cuts.”

Most conservatives seem oblivious to the party’s working-class problem, but not all. Henry Olsen, a vice president at the American Enterprise Institute, says Republicans need to understand that the GOP’s success in the 2010 House races was built in less affluent districts at a moment when Obama’s approval rating among white working-class men was so low “that it was only a few points higher than Richard Nixon’s was at the time of his resignation.”

Olsen sees Obama’s echoes of Bill Clinton’s pledges to help those who “work hard and play by the rules” as shrewd politics aimed at rehabilitating his standing with such Americans. And in Romney, Obama faces a candidate whose “troubles in the primary electorate demonstrated his trouble in connecting with the white working class.” Romney, Olsen says, “has difficulties with his background, difficulties with his manner, some difficulties Obama shares.”

Romney isn’t losing downscale whites. The Post/ABC poll showed him leading Obama by 19 points among white voters without a college education. The problem: That’s roughly the lead John McCain had in this group in 2008, and we know who won that election. Obama, Olsen said, can lose the white working class “by a substantial margin” and still win because of his strength among African Americans, Latinos and well-educated women.

Yes, it’s still early. Renewed economic jitters in Europe could spoil a fragile U.S. recovery. But for now, Romney finds himself in a political maze with no obvious path out. He’s there partly because of his own mistakes, but he was also led to this point because of the unlikely strength of Rick Santorum’s challenge.

ejdionne@washpost.com