The USSR was instrumental to mankind becoming a spacefaring species. The US wasnt even interested until the USSR started and lost interest once they landed a man on the moon and declared that they had "won" the race. Were they still around space exploration probably wouldn't have stalled.
They were also instrumental in keeping the US government in line. US elites were terrified that the USSR and domestic communists might join forces to overthrow them. Elite fear of communists is why people in the 1950s could easily afford college, medical care and a roof over their head and why they were guaranteed a job doing something meaningful like building a dam or a bridge.
You're probably right that it's better that our finest minds are dedicated to making people click on ads and take out loans, though. This truly is the pinnacle of civilization. You have a whole computer in your pocket. You might have been able to buy a house in the 1950s and not be bankrupted by medical bills, but you couldn't play flappy birds.
You don’t go from knowing nothing about rockets to launching a satellite in a year.
Further, the US slowed down but didn’t abandon its manned space program. It was spending a frankly crazy amount of money on a publicly stunt to get people to the moon, but we’ve continued to invest in the space program over the long term. Actually going past the moon requires long term habitation in space thus the interest in space stations.
The US wasnt particularly interested in space exploration unless the USSR did it first though.
Just like the UK wasnt interested in setting up an NHS until it became glaringly evident how well the soviet NHS (also called the NHS) worked and the US won't set one up even though ~70% of the population want one.