And Democrats have moved closer to Mr. Trump’s $5.7 billion price tag. Representative James E. Clyburn of South Carolina, the No. 3 House Democrat, told reporters this past week that lawmakers in his party were prepared to spend that much on a border security package that would include what he called a “smart wall,” featuring drones, sensors and more Border Patrol agents.

“This has become a shutdown over semantics,” said Steve Israel, a Democratic former congressman from New York, who ran the party’s campaign committee. “This has become Donald Trump’s shutdown over the definition of a wall, and Democrats have succeeded at redefining border security from bricks and mortar to investments in modern technology.”

But the path ahead remains complicated. Mr. Trump is desperate to fulfill his 2016 campaign pledge for a “big, beautiful wall” along the southern border — a huge sticking point for Democrats, who see the president in a weakened position now that he has caved to their core demand of reopening the government first and negotiating border security later.

Progressives especially are feeling emboldened and do not like the idea that Mr. Trump is once again tying the debate over border security to a threat to shut down the government.

“I think it’s offensive, even to some of the centrists and moderates, that he links his program on immigration with the functioning of government,” said Representative Ro Khanna of California, a leader of the House Progressive Caucus. “The vast majority, not just the progressives, will say not a dime goes for the border wall. And that’s especially true because we just won this fight.”

Even so, Mr. Trump may have already put forth the broad outlines of a deal, with his proposal to pair money for a barrier with protections for some undocumented immigrants. The Senate rejected that plan this past week. Still, if the protections were expansive enough, and included a path to citizenship for the young undocumented immigrants known as Dreamers, some centrist Democrats might be persuaded to sign on.