Imagine that for some reason, defying any obstacle, Congress passes a law to just exchange common law for civil law (...)
"Common law" or "civil law" is not some sort of clear-cut statute that can be established or revoked by signing the appropriate legal instrument.
[Imagine that] they prohibit judges from using binding precedent either horizontally or vertically.
The federal Congress (or state houses) could certainly pass a statute requiring that (federal or state) courts rule according to criteria X, Y and Z, and explicitly require additional motivation beyond precedent. That would throw the whole system into chaos, but it could in theory be done.
Arguably, there might be constitutional issues. Article III or the federal US Constitution says that the Supreme Court "shall have appellate Jurisdiction, both as to Law and Fact, with such Exceptions, and under such Regulations as the Congress shall make". One might wonder if it is really "appelate jurisdiction" if it does not set precedent. (But all that could be bypassed by a constitutional amendment anyway.)
As an aside, and as mentioned in the comments under the original post, that would be widely out of line of how civil law systems work. Precedent is binding vertically, and in most civil-law jurisdictions repeated precedent (jurisprudence constante) is binding horizontally.
Actually, that the US doesn't use a civil law code is somewhat odd given that it started its revolution and constitutionalization in an era where countries in revolt did often change to some sort of law codes, like France and Latin America.
I think there are a few historical misconceptions in that sentence.
The basic premise of a civil law code is rooted in the Enlightement ideas that such a code should be based on a rational fundation of law principles and replace a hodgepodge of local customs and rulings.
It has no a priori affinity with constitutionalization; as Wikipedia shows, civil law codes were promulgated in the late 18th century in various German-speaking states, before the French invasion(s). Those countries were absolute monarchies at the time and nowhere close constitutional government.
In fact, so was France in 1804, when the civil code was promulgated. At that time, Napoleon was firmly in control and operated under a very lightweight constitution that had done away with the constraints on executive power given in the declaration of the rights of man and of the citizen (French equivalent of the US Bill of Rights). It was not a divine-right-of-kings monarchy, but it was still a brutal autocracy.
The Napoleonic code was more successful, not because it was revolutionary and copied by other revolutionary countries, but because Napoleon exported it by force across continental Europe, and as a consequence to its colonies (including most of Latin America). That brutal change did not happen in the UK (which was never under French domination) or its colonies (notably non-Quebec Canada).
The US were never invaded by Napoleon either and therefore did not adopt the Napoleonic code. (Whether the US could have produced their own civil code at some point during or after the independence war with the UK is a fun bit of alternate history, but they did not.)
I would argue that the difference between "civil law systems" and "common law systems" is not one of philosophy, where different legal thinkers decided to establish whole sets of law based on different basic principles. It is rather one of history, where many civil law systems look the same because they were forcibly aligned in the early 19th century, and many common law systems look the same because they were either the UK or colonies of the UK.
Rather than "civil law systems" and "common law systems", they could be called "1804-Napoleonic-code-derived systems" and "Englo-British-medieval-law-derived systems". The distance in legal philosophies between current-day France and UK in probably smaller than the distance between the 1792 Prussian Allgemeines Landrecht für die Preussischen Staaten and the 1804 French Code Civil.