Former President Barack Obama, center, with congressional candidates, from left, Josh Harder, T.J. Cox, Gil Cisneros, Katie Porter, Harley Rouda, and Mike Levin in September in Anaheim, California.Ringo H. W. Chiu / Associated Press

LOS ANGELES—If any proof were needed that interest in the hotly contested Southern California midterm races extends far beyond the turf in play, it could be found on a recent Sunday afternoon near the UCLA campus here in Westwood.

That’s where a couple of dozen volunteers at L.A.’s Westside Democratic Headquarters had gathered to staff a phone bank backing Katie Porter, a business-law professor at the University of California at Irvine who is challenging Representative Mimi Walters in Orange County’s heavily Republican 45th Congressional District 50 miles away.

In a room full of campaign paraphernalia—$6 Donald Trump flyswatters and a poster proclaiming The Big Blue Wave Starts With You—Porter showed up in person to cheer on the troops. “When we win, it will be because of the phone calls and door knocking and outreach that everyone here and in the district is doing,” she told them, her voice hoarse from a long weekend of campaigning. “Our democracy is built; it is not bought.”

Polls show that Porter has an edge in the race, and in that battle and the half-dozen other fiercely competitive contests in California where Democrats are hoping to flip red Republican seats blue, the overriding issue is Donald Trump—and his historic unpopularity in a state where Hillary Clinton beat him by more than 4 million votes. Control of the House is at stake, with Democrats needing to take an additional 23 seats across the nation.

Even in Walters’s district, where the GOP still has an edge in voter registration of about 7 percentage points (and where no Democratic candidate for congressional or statewide office has ever broken 50 percent at the polls), Clinton bested Trump by 5 points.

“There are certain individual races where personal dynamics seem to be a factor,” said Mark DiCamillo, the veteran California poll taker who now directs polling for Berkeley’s Institute of Governmental Studies and recently surveyed the tightest California races. “But you would have to surmise that these seats are in play in general because of Trump.” The poll ranked the Republican incumbents from most to least vulnerable, and in each case, the GOP candidate’s fortunes tracked the president’s job-approval rating. And, DiCamillo adds, “the relationship between whether a voter approves or disapproves of Trump is, if anything, even stronger than party affiliation” in explaining likely voters’ intentions.

All that helps explain why both parties have poured resources and surrogates (Barack Obama and Joe Biden have both made appearances for the Democrats) into a state where changing demographics were already making districts like Walters’s less overwhelmingly Republican than in the past. As the midterm campaign enters the homestretch, though, the Democrats enjoy a pronounced financial advantage. An analysis by the Los Angeles Times found that in the seven most competitive House races, Democratic candidates raised a total of $21.6 million over the three months ending September 30, compared with just $4.2 million for the Republicans. GOP candidates, on average, had just about $650,000 on hand, compared with an average of about $1.2 million for each Democrat.

“It’s an absolute spigot,” said Sean Walsh, a longtime California Republican strategist who was press secretary for former Governor Pete Wilson. “Trump’s vulnerabilities could be a crucial factor. But if the Democrats ultimately do poorly in these races and have put in millions and millions of dollars, there’s going to be an awful lot of recriminations about what did you spend and what did you spend it on.”

The Democrats’ top moneybags in the most recent reporting period was Gil Cisneros, a low-key former naval officer and shipping manager for Frito-Lay who won a $266 million California lottery jackpot in 2010. He is running for an open seat in a three-county district (Los Angeles, Orange, and San Diego) vacated by the retirement of the Republican incumbent, Ed Royce. From July 1 to the end of September, Cisneros’s campaign raised $4.6 million, including a $3.5 million loan from himself, compared with just $921,000 for his GOP opponent, Young Kim, a former Royce aide and state assemblywoman. (Cisneros has lent the campaign some $8 million in all.)

Cisneros’s platform—in a district that is home to Richard Nixon’s birthplace and presidential library—includes stronger gun-control laws (or better “gun safety,” as he invariably phrases it). He campaigned recently with Mark Kelly, the former astronaut and Navy-captain husband of former Representative Gabby Giffords of Arizona, whose own crusade for tighter gun laws has lent its support to some 50 candidates around the country this cycle. Cisneros’s status as a veteran has particular appeal, Kelly said. “We think veteran candidates can lean in on these issues in a way that others can’t,” Kelly said.

But a candidate like Porter is making a somewhat riskier bet in a district that Walters won just two years ago with almost 60 percent of the vote. Porter, a Harvard Law School protégée of Elizabeth Warren, supports strong consumer protections and government-financed, single-payer health care. That is a comparatively unpopular stance in a district that is growing bluer in urban areas like Irvine but retains strong conservative pockets in the smaller inland towns and an overall Republican advantage in registered voters. By contrast, Walters, a former stockbroker and state legislator, has campaigned as strongly pro-business, a position that still resonates in much of the district. At the same time, Republicans in Southern California, like their counterparts around the country, appear to have been energized by the fracas surrounding Justice Brett Kavanaugh’s confirmation hearings.

“Orange County—even though they’re kind of coastal Chardonnay, Tommy Bahama’s Republicans—stuff like the Kavanaugh hearings has made them really mad,” Walsh said. “That may well have snatched victory from the jaws of defeat for us in some of these districts.”

Of the most competitive districts, only one seems a safe bet for the Democrats: the 49th, in Southern Orange and northern coastal San Diego County, where Representative Darrell Issa is retiring after barely winning reelection two years ago. Registered Republicans still outnumber Democrats by about 5 percentage points, but Mike Levin, an environmental lawyer and former executive director of the Orange County Democratic Party, appears to have a comfortable lead over Diane Harkey, chair of the State Board of Equalization, which oversees tax collection policies. Harkey has vowed to oppose tax increases, and California’s immigration-sanctuary law, while Levin also favors single-payer health care, a $15 minimum wage, and free community-college tuition.

At the same time, the 50th Congressional District in inland San Diego and Riverside Counties—which Trump carried by 15 points in 2016—appears to be leaning Republican, even though the incumbent, Duncan Hunter, and his wife were indicted in August on charges of misusing more than $250,000 in campaign funds for personal expenses. His Democratic challenger, Ammar Campa-Najjar, a onetime Obama-campaign worker and former public-affairs officer at the Department of Labor, has struggled to gain traction.

California’s other competitive races include the 10th Congressional District, in the state’s great Central Valley, its agricultural heartland, where high voter turnout has kept the seat in Republican hands in recent years despite a slight Democratic advantage among registered voters. Latinos account for nearly the same proportion of residents as whites, but low Hispanic turnout has hurt the Democrats. The Republican incumbent, Jeff Denham, a former state senator and Air Force veteran, is locked in a tight race with Josh Harder, a native of the area who gave up his job at a Silicon Valley venture capital firm to move back home last year and run for Congress. Denham voted to repeal Obamacare and in favor of the Trump tax cuts, and his work on behalf of immigrant “Dreamers” ultimately came to naught—all of which could hurt him in a district where immigrants account for roughly one-fifth of the population.

The 25th Congressional District, which reaches from eastern Ventura County through the northernmost suburbs of Los Angeles County, is a district in transition. In the past six years, its voter registration has flipped from having a slight Republican edge to a comparable Democratic one, which has made the Republican incumbent, Steve Knight, a former state legislator, vulnerable to a strong challenge from the Democrat, Katie Hill, who grew up in the area and worked in the nonprofit sector in Los Angeles as an advocate for services to the homeless. Most analysts rate this race a toss-up.

Finally, there is the 48th Congressional District in coastal Orange County, where the 30-year GOP incumbent is Dana Rohrabacher, a onetime speechwriter for Ronald Reagan whose libertarian-surfer streak has helped him stay in office despite the district’s growing political diversity. But Rohrabacher’s close ties to Russia and strong support for Vladimir Putin have left him newly vulnerable in light of Trump’s own Putin saga, and Democrat Harley Rouda, a onetime Republican real-estate investor, has mounted a strong challenge. Rouda has invested more than $1.5 million of his own money in the race, and he backs the billionaire Tom Steyer’s effort to impeach Trump—catnip for the left, but also not a sure thing in a district where Republicans still have a roughly 10-point advantage in voter registration.

For all these reasons, California Democrats may be guardedly optimistic, but as the flood of money shows, they are not taking any outcome for granted. Melissa Grant, a lawyer by trade who volunteers as the co-manager and chair of the Westside Democratic Headquarters in L.A., where phone-bankers have worked to support not just Katie Porter but Democrats in the other contested races, too, noted that the call center was at capacity on a recent weekend and enthusiasm was high. But she also acknowledged that the solid-blue turf of Los Angeles is not always the clearest electoral vantage point. “We were in a bubble with Hillary in 2016,” she said, clearly hoping that history will not repeat itself this fall.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.