Mexico said Wednesday the United States will be shooting itself in the foot if President-elect Donald Trump implements his threats to impose 25-percent tariffs on Mexican imports.

Trump on Monday fired the warning shot in a looming trade war with the top three US trading partners by threatening to impose huge tariffs on Mexico, Canada and China if they failed to stop illegal migration and drug smuggling into the United States.

He said he would charge 25 percent tariffs on Mexican and Canadian imports and 10 percent on Chinese goods “above any additional tariffs” on the world’s second-biggest economy.

Mexico’s Economy Minister Marcelo Ebrard warned that the cost to US companies of the tariffs on Mexico would be “huge.”

“Around 400,000 jobs will be lost” in the United States, he said, citing a study based on figures from US carmakers that manufacture in Mexico.

He added the tariffs would also hit US consumers hard.

Ebrard cited the US market for pickup trucks, most of which are manufactured in Mexico, as an example, claiming the tariffs would add $3,000 to the cost of a new vehicle.

“The impact of this measure will chiefly be felt by consumers in the United States… That is why we say that it would be a shot in the foot,” he said, speaking alongside President Claudia Sheinbaum during her regular morning conference.

Mexico and China have been particularly vociferous in their opposition to Trump’s threats of a trade war from day one of his second presidential term, which begins on January 20.

Sheinbaum has declared the threats “unacceptable” and pointed out that Mexico’s drug cartels exist mainly to serve drug use in the United States.

She has written to Trump to propose a meeting, which she says would happen “ideally” before he takes office.

China has warned that “no one will win a trade war.”

During his first term as president, Trump launched full-blown trade hostilities with Beijing, imposing significant tariffs on hundreds of billions of dollars of Chinese goods.

China responded with retaliatory tariffs on American products, particularly affecting US farmers.

The United States, Mexico and Canada are tied to a three-decade-old largely duty-free trade agreement, called the USMCA, that was renegotiated under Trump after he complained that US businesses, especially automakers, were losing out.