The funniest thing is that all the while China is the largest creditor of USA by far, and USA has had foreign investment pouring in overall all those decades.
USA had the money not just to maintain but rapidly advance, and a head start. To bite the dust in this situation is some serious incompetence.