Surgeons can push the limits of better and better surgery if they can spend their entire career focused on just that. If they’re required to farm or sew clothes half of every day, they will not be able to advance surgery as far.
The same specialization-driven innovation happens between companies who can trade freely, and between countries who can trade freely. Paul Krugman won a Nobel prize for exploring this idea.
Tariffs allow otherwise more expensive domestic products to compete against cheaper products from abroad.
In and of itself, that says nothing about quality one way or another. In practice, it often means the opposite of what you suggest: domestic goods are often of higher quality, and/or are made by workers in better conditions, because of stricter laws here than in the places manufacturing has moved to. (And not by coincidence—the cheaper labor and looser laws are exactly why manufacturing moved to those places.)
Of course, all of this only applies when tariffs are carefully considered, strategically applied, and left in place for a long and predictable length of time.