Mexico and Brazil, Latin America’s two largest economies, have signed a set of agreements to boost cooperation in trade, agriculture, science, energy and environmental projects. The accords come as both nations face rising tensions with Washington over tariffs and policy disputes.