President Trump answers a question from the media as he arrives at the White House on Thursday. (Alex Brandon/AP)

With chants of "build the wall," warnings of rapists coming from Mexico and an unforgiving promise to deport millions, Donald Trump forged a fundamental bond with millions of frustrated Americans who helped him take over the Republican Party and win the White House.

But now the same issue of immigration is straining Trump's ties to hard-line conservatives. Trump's agreement this week with Democratic leaders on a more moderate approach to immigration legislation has sparked bitter talk of betrayal among some of his staunchest defenders on the right — and forced many of them to rethink their loyalties amid confusion over what the president favors.

When Trump on Thursday signaled his embrace of granting legal status to some immigrants who were brought to the United States illegally by their parents, he prompted new questions about whether he would support an eventual path to citizenship for them and raised doubts about how hard he would fight Democrats for the massive wall he promised along the U.S.-Mexico border.

In the eyes of these admirers-turned-critics, Trump's sins include not just a refusal to issue an ultimatum on the wall but his newfound willingness to work with the detested establishments of the Republican and Democratic parties. While party leaders on both sides frame the issue of undocumented childhood immigrants in compassionate terms, others view any accommodation as an affront to U.S. sovereignty and the rule of law.

“If we’re not getting a wall, I’d prefer President Pence,” conservative author Ann Coulter tweeted Thursday.

“Amnesty Don,” declared a bright-red headline on Breitbart News, the website run by former White House chief strategist Stephen K. Bannon — one of many political fire alarms set off by die-hard supporters following the sudden breakthrough Wednesday at a White House dinner.

Yet the lasting political cost of Trump’s engagement with top Democrats on immigration remained ambiguous. While Coulter and others vented, several conservative leaders Thursday remained hesitant about breaking with the president publicly given his continued grass-roots support and their desire to focus Republican ire on the leadership in Congress.

“The jury is still out on whether the base starts to leave him. And I’m not sure what the truth is,” Rep. Steve King (R-Iowa) said in an interview. “If this stands and we end up with amnesty, the base that was pulled together because of immigration will start to peel off in significant ways.”

But, King added, “No one is quite sure about how this will play out and whether it’s truly what we worry it’ll be.”

Trump has cultivated a political persona defined, in part, by his hard-line policy positions but also by the way he speaks as a celebrity populist to the grievances of many Americans amid a fast-changing global economy and culture.

In search of a bipartisan victory that has eluded him, Trump has at times attempted to redefine those promises — to build a “big, beautiful” concrete wall, to deport all undocumented immigrants he has said “have to go.” The thought is that his base on Capitol Hill and in the activist ranks will forgive him because he shares those deeper grievances and anxieties, even if he is an unreliable champion.

The president’s statements seemed to evolve by the hour Thursday, reiterating that he would work with Democrats on shielding the thousands of “dreamers” who rely on the Deferred Action for Childhood Arrivals program, while also assuring angry conservatives that the border wall remains “very important,” even if separate from the latest pact.

In another tweet, he suggested that the wall he had promised “is already under construction in the form of new renovation of old and existing fences and walls.” Hours later, he said that plans for funding the wall, which he once described as a concrete edifice, were yet to come. “The wall will come later,” Trump told reporters.

Then in an email message to supporters signed by Trump, Trump’s political committee told supporters: “There’s been a lot of noise today. . . Let me set the record straight in the simplest language possible: WE WILL BUILD A WALL (NOT A FENCE).”

Polling suggests that Trump has more room to maneuver with his base on the question of dreamers than on other planks of his immigration platform. An analysis of the 2016 presidential election by Hamilton College political scientist Philip Klinkner found that among 2016 Trump voters, 67 percent supported building a southern border wall, 80 percent said speaking English was “very important” to being American, and 80 percent were opposed to letting Syrian refugees into the United States.

But among the same voters, 68 percent said child migrants brought illegally who have been here 10 years and have graduated high school should be allowed to stay in the country.

“That’s what the White House is wrestling with right now,” says Jim McLaughlin, a campaign pollster for Trump who still consults with the White House.

Trump waffled during the campaign over how he would handle the dreamers. In the summer of 2015, he said on CNN that he would deal with the group “with big heart.” Then he changed tack weeks later, telling NBC News of those same migrants, “We are going to keep the families together, but they have to go.”

Behind the scenes of the campaign, Trump spoke often of the possibility of dealing with childhood arrivals with a gentler hand, according to several former Trump campaign advisers.

California-based pastor Samuel Rodriguez, who led a prayer at Trump’s inauguration, said he spoke repeatedly with Trump during the campaign about the dreamers issue.

“His commentary and his commitment to building the wall and stopping illegal immigration was very rigid and very fixed,” said Rodriguez, who serves as the president of the National Hispanic Christian Leadership Conference. “The moment I brought up dreamers, everything shifted. In fact, at one point he brought up the fact that he was a father and a grandfather.”

After the election, Trump began to signal publicly that he planned to “work something out” about young undocumented immigrants. “They got brought here at a very young age, they’ve worked here and they’ve gone to school here,” he said weeks after the election.

Longtime Trump watchers said they understood Trump’s eagerness to convince his core voters Thursday that he remains with them on their animating issue, but warned that he may have gone too far for many of them.

“The base is revolting. The reality is sinking in that the Trump administration is on the precipice of turning into an establishment presidency,” said Sam Nunberg, a former Trump campaign aide.

Days earlier, Bannon said on CBS’s “60 Minutes” that he was “worried about losing the House now because of this, because of DACA,” arguing that Republican voters would lack enthusiasm for Trump and the party if they felt it was drifting to the center on immigration.

“If this goes all the way down to its logical conclusion, in February and March it will be a civil war inside the Republican Party that will be every bit as vitriolic as 2013,” Bannon said, referring to the stalled fight that year over a comprehensive immigration bill.

Conservative radio talk show host Laura Ingraham, who is friendly with Trump, mocked the president after news trickled out about a potential immigration deal.

“Exactly what @realDonaldTrump campaigned on. Not,” Ingraham wrote on Twitter. She later added, “BUILD THE WALL! BUILD THE WALL! … or … maybe … not really.”

But other Trump-supporting conservatives, such as conservative broadcasters Rush Limbaugh and Fox News’s Sean Hannity, stuck by him, directing their irritation at the media and at congressional Republicans rather than at Trump.

“They want you to think Trump has sold you out,” Limbaugh said on his program. “They want you to think that Trump has given away his mandate in exchange for doing deals. . . He’s been frustrated because the Republicans won’t do anything, so he’s going over to the Democrat side, and he’s doing deals.”

Hannity echoed him.

“Well Mitch GREAT JOB!” Hannity tweeted, referring to Senate Majority Leader Mitch McConnell (R-Ky.). “You failed so miserably with Healthcare and ‘excessive expectations’ now @POTUS has to deal with Dem Leaders!”

Hannity added later, “I blame R’s. They caused this. They wanted him to fail and now pushed him into arms of political suicide — IF TRUE.”