Xavier Becerra, the new attorney general of California, paused midway through his breakfast to issue a warning to the president of the United States.

“Be careful,” he said in a singsongy voice. “Be careful!” A wicked smile appeared.

The previous day, Super Bowl Sunday, Donald J. Trump had told Fox News’s Bill O’Reilly that “California in many ways is out of control” and suggested that one way to bring the state to heel might be depriving it of federal funds. This came three days after the president tweeted a threat to cut funding to UC Berkeley in the wake of violent protests against a planned speech by the right-wing provocateur Milo Yiannopoulos.

“If you try to do something that I don’t believe comports with our regime of laws, starting with the U.S. Constitution, we’ll test you,” Becerra continued.

Becerra and I were sitting in a hotel restaurant in Fresno, where he was about to launch a statewide listening tour. He was not quite two weeks into his new job, and was looking forward to discussing what he called “bread-and-butter issues” with constituents. But Topic A this morning—as on so many of his mornings thus far—was instead California’s brewing clash with Trump.

The president’s open hostility toward Becerra’s state was perhaps predictable, and not merely because California went for Hillary Clinton by 30 points. On a whole range of issues, from gun safety to health care to financial deregulation to environmental protection to marijuana legalization to immigration, Trump’s deep-red vision for Making America Great Again has put him on a collision course with deep-blue California. As attorney general, Becerra will be the point man for the state’s legal response.

He wants Trump to know how unimpressed he is by the chief executive’s promiscuous smack talk. “I don’t put a lot of stock in what he says. I put stock in what he does,” Becerra told me. “And even what he does is not necessarily what’s staying in place, as we see with these executive orders.” (Indeed, as Becerra plowed through his mound of bacon, eggs, and pancakes, the Ninth Circuit Court of Appeals was getting ready to put a bullet through Trump’s original travel ban.) “As for me, I work with what is operational. Not what is”—Becerra’s fingers spidered furiously beside his temple—“in his mind.”

A former member of Congress, Becerra brings to battle decades of Washington experience. He says this is likely part of why Governor Jerry Brown tapped him to replace the previous attorney general, Kamala Harris, who was in November elected California’s junior senator. “The governor knew that much of what would occupy the next attorney general’s time would be things coming from Washington.”

The job carries considerable risks: By definition, it puts Becerra in the crosshairs of the famously vindictive Trump. (When the pro-Trump trolls get fired up, Becerra’s Twitter feed can be a dark and scary place.) But the potential rewards are also considerable: If he succeeds in derailing at least some of the president’s policies, while making others politically costly, Becerra could find himself a Democratic hero.

With Republicans in control of both the White House and Congress, Democratic attorneys general across the country are stepping up—and joining forces with one another—to act as a legal barricade against Trump’s policies. Immediately upon being appointed, Becerra was welcomed to the fight by a number of his new colleagues, most notably New York Attorney General Eric Schneiderman, who is said to be picking apart Trump’s business dealings. An effort of this magnitude requires “teamwork,” Becerra says, with different states taking the lead on different issues.

He is particularly primed to challenge Trump’s assault on “sanctuary cities”—cities that limit cooperation between local police and immigration agents. In his first week on the job, he sat down with the state’s sheriffs and had a heart-to-heart on the topic. “Rather than wait for Trump to send something our way and then react to it, I wanted to make sure they understood how the new attorney general interpreted state and federal law,” he told me.

Two state laws in particular clash with Trump’s vision of mass deportations: the 2013 trust Act, which limits the detention of immigrants by local law enforcement, and the 2016 truth Act, which strengthens the rights of immigrants detained in jail. “I tried to make pretty clear to the sheriffs what I thought we could and could not do.”

When it comes to the so-called Trump resistance, Becerra sees California playing a special role by virtue of its size and “forward leaning” politics. “Sometimes it takes a generation, but we pull the country in certain directions.” The state has shifted leftward in the past two decades, particularly on race and immigration. Back in the 1990s, “we were where the country seems to be … on immigration. Look at Prop 187,” he said, invoking the anti-immigrant ballot initiative pushed by Republican Governor Pete Wilson in 1994. Recalling the “Yes on 187” campaign’s infamous ads (which showed migrants streaming over the Mexican border as a narrator darkly warned, “They keep coming”), Becerra observed, “That’s exactly what Donald Trump is saying: ‘We’ve got to do this ban because they’re coming!’ ” Although voters approved Prop 187, which promised to deny illegal immigrants access to government services, the measure was blocked by the courts and never enforced. It did have one lasting consequence, however: a political backlash that hobbled the state’s Republican Party for a quarter century and counting.

Some observers have likened a potential California offensive against Trump to Texas’s assault on Barack Obama’s agenda. During the Obama presidency, Texas Attorney General (now Governor) Greg Abbott and his successor, Ken Paxton, sued the federal government over everything from the Affordable Care Act to the president’s transgender-bathroom directive to environmental regulations. Abbott once quipped that his job entailed going into the office, suing the federal government, and going back home. All told, Texas sued the Obama administration nearly 50 times—including a farewell filing on the president’s second-to-last day in office. Not every case was a winner, not even close. As of Trump’s inauguration, Texas had won seven, lost 12, and dropped nine, though 20 cases are still pending. Abbott and Paxton nonetheless thrilled the Republican faithful with their fierce resistance.

Becerra is quick to note that California is coming from a totally different direction than Texas. But he has no qualms about following “the mechanical aspects” of the Lone Star model. “If you’re going to protect the rights of your people,” he said, “you gotta do what you’ve gotta do.”

Midway through his Fresno visit—after touring the local Bureau of Forensic Sciences lab but before sitting down with area farmworkers—Becerra stopped for a Q&A with local reporters. Clutching a stack of papers, he headed into a charmless, windowless room near the front of the bureau’s building, where he found a couple dozen journalists raring to grill him about the status of California-versus-Trump.

Specifically, they wanted to know about the amicus brief Becerra’s office had filed that morning, joining 15 other attorneys general in supporting Washington State’s suit to kill Trump’s January 27 travel ban. Some asked why Becerra had waited until that morning to enter the fray. Others wondered why he considered the ban unconstitutional. At one point, a reporter from a Spanish-language network asked a long question that Becerra, who is of Mexican heritage, answered at even greater length in fluent Spanish.

Through it all, Becerra remained unruffled. He is, in many respects, a photo negative of Trump: genial and steady, disciplined and studious, eloquent and precise—cautious, even—with language. His default expression is a Mona Lisa smile. His close-cropped hair, black with silver sprinkles, is perfection.

Also unlike Trump, Becerra has spent decades in the political trenches. After four years as a deputy attorney general in the late 1980s, he served in the California Assembly. From there, he went on to the U.S. House, where he spent 24 years representing low-income, overwhelmingly Latino areas of Los Angeles. During his last two terms, he was the chairman of the House Democratic Caucus, the fourth-highest Democratic leadership position in the House.

Becerra does appear to enjoy a good political scrap, but he knows how to argue without losing his cool and how to attack without coming across as unpleasant. His good friend Judy Chu, who represents California’s 27th District in the House, told me that he is a master at rallying public support: “His ability to rev up the crowds and get them excited about fighting back is his strong point.” During the 2016 campaign cycle, he crisscrossed the country on behalf of numerous House candidates. He also served as one of Hillary Clinton’s top emissaries to Latino voters, and he was among the politicians often floated as a potential running mate for Clinton.

All of which raises the question of his ambitions. At 59, Becerra is more than a decade younger than many of his party’s leaders. He considered running for retiring Senator Barbara Boxer’s seat in 2016, but ultimately ceded the field to Harris. Already, he has launched his 2018 campaign to win a full term as attorney general. Might he yet run for senator, when Dianne Feinstein retires? Governor? President? He declined to speculate. “How far will I take it? I don’t know,” he said. “I’m like Captain Kirk. I’ve never been here before.”

For now, he clearly relishes his role as a burr in Donald Trump’s backside. At times, he seems to be practically daring the new president to come at California. “I don’t have to respect an executive order that violates the Fourth Amendment,” Becerra told me, proclaiming Trump’s immigration views “not just idiotic but unconstitutional.” He insisted, “The Feds have every right to enforce immigration law. That’s their province. They don’t have the right to tell us how to enforce local public-safety laws.”

Becerra’s fight against Trump’s us-versus-them rhetoric is, at heart, deeply personal. His mother, Maria Teresa, emigrated from Mexico as a young woman. His father, Manuel, was born in Sacramento but raised in Tijuana. He later returned to settle in the state capital, and over the years, he held a variety of menial jobs: picking crops, working construction, canning soup. Becerra was the first in the family to graduate from a four-year college, receiving his undergraduate and law degrees from Stanford.

He is given to talking about how far his family—and his state—have traveled since his parents’ early adulthood, when California restaurants posted signs proclaiming no dogs or mexicans allowed. This history gives him a decidedly unsentimental perspective on the grievances of Trump voters, and on the political hand-wringing over the plight of the white working class. “I don’t think folks in the Rust Belt states couldn’t walk into a restaurant and eat the food they had harvested themselves,” he said.

Which isn’t to say that Becerra doesn’t get Trump voters’ angst. “They’re feeling left out, which is ironic in a way,” he said, conveying a mix of sadness and frustration. “They shouldn’t feel left out, because a lot of folks have been in the same boat with them for a long time.”