The Americans are viewed as the winners of the space race because of the Moon landing in 1969, but did it stop there? It seems like space stations and Mars landings would have been avenues for getting the upper hand on the Americans, so why did the Space Race end in 1969?
The short answer: the Space Race continued, but in low gear.
Space stations were the next step.
The Soviets launched their first space station, Salyut 1, in 1971. It wasn't entirely successful, more through the fault of the Soyuz 7K-OKS spacecraft bringing and returning the crews. The first flight, Soyuz 10, failed to dock successfully, and returned to Earth without the crew entering the space station, and the second crew, on Soyuz 11, spent 23 days aboard Salyut 1, but died on re-entry on their return to Earth. Salyut 1 was de-orbited before the Soyuz craft could be modified and used for another crew.
Their next three attempts to launch space stations were unsuccessful, with the first of these, in 1972, not reaching orbit due to a rocket failure, and the next attempt, Salyut 2 in 1973, reaching orbit but, apparently punctured by explosion of the final stage of its launch rocket, lost air. The third attempt, about a month later, also reached orbit, but malfunctioned and fired its orbit correction rockets until it used all its fuel.
Three days after this last launch, the US successfully launched their space station, Skylab, which was occupied by 3 crews, for a total of about 24 weeks, into early 1974.
The next two Soviet space station launches, both in 1974, were successful. Three further space stations were launched in the Salyut program, in 1976, 1977, and 1982, and were followed by the much larger Mir space station - a behemoth of 130 tons compared to its 20 ton predecessors (Skylab was also big, at 77 tons) and the Zvezda module of the International Space Station (ISS). Mir's size was enabled by modular design allowing the final version to be assembled in orbit (from 1986 to 1996). The ISS, over three times the weight of Mir, was also modular, with multiple nations providing modules.
The story of these space stations begins as one of competition - the Space Race was still on, even after the Moon landings - and finishes as one of cooperation, featuring the multi-national ISS.
The first space station missions were of relatively short duration (even Skylab was only in operation for under a year). The final two Salyut space stations, Salyut 6 and Salyut 7, were both in operation for about 4 years, and Mir operated for even longer (15 years). ISS, first crewed in 2000, is approaching its 20th year of occupation, and is still going, with plans to operate until 2030.
Big as it is, ISS is a tiny thing compared to many science fiction space stations. Why is it so? ISS is very expensive, with construction and operating costs totalling about US$150 billion. Considering the annual NASA budget of about $20 billion, it's easy to see why it's an international project. It's also easy to see why we don't have giant science-fiction-style space stations. The US was willing to spend a lot on the space race, with NASA eating over 4% of the Federal budget at peak, but this dropped after the Apollo program, to well under 1% of the Federal budget, or to about 1/3 of the peak budget in inflation-adjusted dollars.
Moon bases would be very expensive too, and we haven't yet been able to achieve manned missions to Mars. It could be argued that the reason we don't have giant space stations, Moon bases, and Mars landing is purely a matter of money. But it should also be kept in mind that these things take time, and the development of technologies (e.g., mining machines are being developed for possible use on the Moon and Mars to maximise the use of local resources). The problems need to be discovered, and then solved. The cost for a Mars program is bigger than the cost of a single Mars mission. Estimates for the cost of a Mars mission vary from a low, low $6 billion to a probably more realistic $80-100 billion (which would be spread over many years).
ISS and its predecessors have been useful platforms for learning how to build bigger space stations, and potentially space stations in orbit around the Moon and Mars, and have lessons for bases on the ground as well. Having people spend 1 year in space, even if merely in low Earth orbit, is a step towards spending a year or so in space on the way to Mars. Without this experience, travel to Mars would present much more of an unknown problem, and a Mars mission would have been much less feasible in the 1970s. Part of the reason the Space Race went into low gear was that we had to take little steps and learn along the way - it wasn't just a matter of smaller post-Apollo budgets.