HANOI — South Korean President Moon Jae-in put a brave face on the situation Friday morning.

In a nationally televised address for a public holiday, he said the collapse of a high-stakes summit between President Trump and North Korean leader Kim Jong Un only made South Korea’s role “more important” to help the two sides reach “a complete settlement by any means.”

Moon then continued as if nothing had happened, speaking optimistically about denuclearization, economic integration between North and South Korea, and a “new order of peace and security in Northeast Asia.” 

Moon has invested his presidency and personal prestige in engagement with Pyongyang, and hoped peace with North Korea would be his legacy. The failure of the summit leaves that dream in trouble, if not in tatters, so his forced optimism was perhaps understandable, although not universally appreciated.

“Tone deaf,” tweeted Chad O’Carroll, head of the Korea Risk Group, a consultancy. “Impossible without sanctions relief, and not one iota of that was secured on Thursday in Hanoi.”

Lee Jong-chul, a spokesman for the center-right Bareun Mirae Party, said Moon’s speech was seemingly written assuming a deal would be reached in Hanoi. “I wonder if he read the pre-written speech without any changes,” he said.

Moon’s popularity in South Korea was boosted by three successive summits with Kim, but the importance of engagement with North Korea goes well beyond opinion polls: It is at the heart of his presidency.

Moon also helped broker the first meeting between Trump and Kim in Singapore, and this week’s summit in Hanoi, which collapsed after Americans refused to offer extensive sanctions relief in exchange for limited denuclearization measures.

“The summit fallout will deal a blow to the Seoul government,” said Shin Beom-chul, a researcher at Asan Institute for Policy Studies in Seoul. “South Korea cannot go against their ally United States, so it will grudgingly stick to the sanctions enforcement in place.”

Moon had talked grandly of establishing road and rail links with North Korea as a first step toward the sort of economic integration Europe established after World War II. He has also been keen to restart a joint economic zone in Kaesong in North Korea, which was closed in 2016 during North Korea’s nuclear and missile testing, as well as a joint tourism project at Mount Kumgang.

Although sanctions still block the way, Moon said in his speech that he will “consult” with Washington to resume operations at both places. 

“South Korea is in a very, very difficult position,” said Joseph Yun, a former top U.S. diplomat on Korean affairs. “That makes it quite unlikely they can relax any of their unilateral sanctions to allow any North-South economic engagement.” 

The breakdown in talks sent shivers through South Korea’s stock market, which fell sharply just before the close of trading Thursday to end down 1.8 percent. The fall was steepest among “peace stocks,” a group of infrastructure companies sensitive to the prospect of business with North Korea. The market was closed Friday for the holiday.

Representatives of South Korean companies that operated in Kaesong in the past saw their hopes of returning soon shattered.

“Unfortunate times,” said Shin Han-yong, chairman of an association for companies that operated there. 

After switching off the TV showing Trump’s post-summit news conference, Shin fought back tears and told reporters: “This is not the end. We must head to the Kaesong complex.”

Even government advisers could not hide their emotions. 

“I was flustered,” said Kim Kwang-gil, a sanctions expert on the Presidential Committee on Northern Economic Cooperation. “So many people in South Korea who took hope in this summit, especially those anticipating the Kaesong economic complex to resume, are left heartbroken.” 

In Japan, which is threatened by North Korea’s nuclear weapons and missiles, reactions were more mixed. While Tokyo is keen to see North Korea denuclearize, there were widespread concerns that Trump and Moon were moving too fast and giving too much away to Kim. So the disappointment at the lack of a deal was mixed with relief that Trump had not reached a bad deal.

The Nikkei newspaper, which had recently warned Trump “not to compromise easily,” said the president had reached the right decision by not falling for North Korean “deception such as denuclearization by name only.”

The right-wing Sankei Shimbun paper argued that Kim’s “top-down strategy” had backfired, leading to the worst crisis for his leadership since he took over in North Korea in 2011.

Japan’s prime minister, Shinzo Abe, said he had spoken to Trump for 10 minutes. He told public broadcaster NHK that he completely supported Trump’s decision: “With a strong determination to achieve denuclearization of the Korean Peninsula, he didn’t compromise easily and will continue with constructive talks and urged North Korea for specific actions.”

Abe said Trump told him he had twice raised the issue of Japanese citizens abducted by North Korean spies in the 1970s and 1980s. “I’ve heard that they had a serious discussion on the abductees,” he said. “I am determined to meet Chairman Kim next.”

Akiko Kashiwagi in Tokyo contributed to this report.