President Trump proclaimed in a freewheeling speech to a conference of conservatives last weekend that “America is winning again.” But his administration has been on a pronounced losing streak over the past week.

Trump is losing ground on top priorities to curb illegal immigration, cut the trade deficit and blunt North Korea’s nuclear threat — setbacks that complicate his planned reelection message as a can-do president who is making historic progress.

Late last week, Trump flew home empty-handed from a summit with North Korean leader Kim Jong Un in Hanoi — and, within days, new satellite images appeared to show that the North was secretly rebuilding a rocket-launching site.

On Tuesday, the Department of Homeland Security announced that unauthorized border crossings have spiked to the highest pace in 12 years — despite Trump’s hard-line rhetoric and new policies aimed at deterring migrants.

And on Wednesday, the Commerce Department said that the nation’s trade deficit is at a record high — in part due to punitive tariffs Trump imposed on allies and adversaries. Trump vowed throughout his 2016 campaign and during his presidency to shrink the trade deficit, which he views as a measure of other nations taking advantage of the United States.

“The president hasn’t shown much of an ability to cut good deals with Congress or anyone else,” said Rep. Joaquin Castro (D-Tex.), who is mulling a Senate run in 2020. “Almost the only time he has been successful at one of his goals is when he can set the terms unilaterally. That’s why he’s done a lot of executive orders, executive actions, like the travel ban, deregulations, emergency declaration. Those are things that don’t require any negotiation at all.”

Trump took office on a pledge to buck conventional wisdom, sideline Washington’s political class and tackle long-standing problems with a mix of outside-the-box improvisation and dealmaking skills honed during his real estate career. “I alone can fix it,” he declared at the Republican National Convention in 2016.

Yet as he has struggled to fulfill some of his signature campaign promises, Trump has consistently blamed others for his woes.

He has criticized the administrations of President Barack Obama and President George W. Bush for not reforming the immigration system or reining in North Korea. He has railed at Democrats for failing to support his proposed border wall and implored them to ratify new trade deals. And he has even attacked fellow Republicans, obliquely slamming former House speaker Paul D. Ryan (Wis.) during a Rose Garden news conference last month for not having pushed faster to get a deal on the wall.

White House officials argued that rather than being a setback, the immigration trends could bolster Trump’s argument that he is justified in taking unilateral action on the border. Federal authorities detained 76,103 migrants at the southern border in February, up from 58,207 a month earlier.

Press secretary Sarah Sanders said Wednesday that the numbers were clear evidence that Trump was right to declare a national emergency last month.

U.S. President Trump meets North Korean leader Kim Jong Un in Hanoi on Feb. 27 during a summit that later collapsed. (Evan Vucci/AP)

“If that doesn’t define crisis, I don’t know what does,” she said. “Congress should have fixed this problem. The president tried multiple times to get Congress to work with him to address the crisis. They failed to do so, and now the president has to do what is absolutely necessary.”

Republican allies praised the president for eliminating business regulations, helping pass a major tax cut in 2017, appointing two conservative Supreme Court justices and scores of lower-level judges, and nurturing an economy with low unemployment.

They emphasized that challenges such as North Korea will take time and chided Democrats for blocking Trump’s agenda.

“The House is just involved in investigations and really not concerned about legislation,” said Sen. Ron Johnson (R-Wis.).

Sen. David Perdue (R-Ga.) said Trump is “very frustrated right now with all of us. He wants to get results and we’re looking at a two-year period where it’s pretty obvious the other side doesn’t want to do anything.”

But Trump’s critics said his policies have made things worse.

On immigration, the administration has sought to block asylum seekers at legal ports of entry along the border, prompting them to try to find alternative pathways into the country. The president shut down parts of the federal government for 35 days — the longest such closure in U.S. history — in an ill-fated fight for border wall funding, even though experts said the surge of migrant families is not a threat to national security and that a wall would do little to curb it.

On trade, Trump’s tariff war with China has harmed U.S. farmers as Beijing slashed agricultural imports. Although the president has signaled that a trade deal is close, analysts said an accord would not fundamentally alter the U.S. trade relationship with the world’s second-largest economy.

And on North Korea, officials have said, the president’s decision to rush forward with bilateral summits with Kim have led to difficulties for U.S. negotiators engaging with their counterparts over technical and complicated nuclear matters, as Kim has preferred to deal directly with Trump.

Simon Rosenberg, founder of NDN, a liberal think tank, noted that the tax cut has not met GOP projections for economic growth and could add significantly to the ballooning federal deficit.

“The reality is he can’t point to a single thing that’s better today than when he came to office,” Rosenberg said.

Although he has projected confidence, Trump has fretted in private over his difficulties. During the government shutdown, the president’s approval ratings dipped to 37 percent in a Washington Post-ABC News poll, one of the lowest marks of his tenure.

During a marathon speech Saturday to the Conservative Political Action Committee, Trump veered off script, spending much of the time attacking his rivals, including congressional Democrats, special counsel Robert S. Mueller III and news organizations. Trump spent less time on his governing record.

On trade, he defended his use of tariffs and suggested the United States had accrued large trade deficits because past administrations were afraid to use that tool as leverage. On North Korea, he blamed the Obama administration for allowing the Kim regime to send “rockets flying all over the place” and said his team was “making a lot of progress.” On immigration, Trump called current U.S. laws “crazy” and said he felt empowered to declare a national emergency “because our Congress can’t act.”

“Not my fault I inherited this mess, but we’re fixing it,” he said during the speech.

Trump at times also appears determined to prove that he is making progress. He publicly contradicted his own intelligence chiefs, who testified to Congress in January that there is no evidence that North Korea is willing to give up its nuclear program.

Asked by a reporter Wednesday about the satellite images that showed construction work at the ­Sohae Satellite Launching Station, Trump said he would be “very disappointed” if the news is confirmed, but he added that it was “a very early report.”

Senior White House aides have sought to cast the Hanoi summit as a sign of Trump’s negotiating fortitude and unwillingness to settle for a bad deal. Yet Trump has grown frustrated by the largely negative coverage of the summit, a senior White House official said, and his aides briefed lawmakers this week to explain his goals. The official spoke on the condition of anonymity to characterize internal discussions.

Last year, Trump berated Homeland Security Secretary Kirstjen Nielsen over the rising border crossings. Though he no longer blames Nielsen, aides said, Trump told his staff that the shutdown dispute sent an important message to his conservative base that he is fighting for them.

On trade, Trump postponed a March 1 deadline to impose another round of tariffs on China in hopes of a deal. White House aides are planning events for Trump and Vice President Pence in the Midwest this spring to tout an updated trade deal reached last year with Canada and Mexico that Congress has yet to ratify.

Sen. Mike Rounds (R-S.D.) said in an interview that farmers support Trump but are growing antsy.

“These folks are with you, they want to see you be successful,” Rounds said, speaking as if he was sending a message to Trump. “But you’re going to have to deliver some results.”