in the most basic terms, what is a tariff and what is it's purpose?

A tariff is a tax a country charges for imported goods and services. Its purpose is to make domestically produced goods less expensive than foreign produced goods.

https://www.investopedia.com/terms/t/tariff.asp

A tariff is a tax imposed by a government on goods or services that are imported from or exported to another country. Its purpose is primarily economic, aiming to protect domestic industries and maintain a favorable balance of trade. By imposing a tariff on imported goods, the cost of those goods is increased and makes them less competitive compared to domestically produced goods. This encourages consumers to buy goods produced within their own country and supports domestic industries. Additionally, tariffs can generate revenue for the government and can be used as a tool in international trade negotiations.