it basically started winding down from Detente onwards..
after that, Reagan's intensification of the arms race and propaganda, made it very hard for the USSR to compete economically, so when Gorbachev came to power he knew he'd have to end the war so they might actually ahve some money to fix...