Since 2014, after Russia realised the intention of Nato to expand further into Ukraine, Putin and Xi had already started planning their moves in anticipation of what the USA intended to do. The USA had been hyping up their intention to deal with China first, starting with a trade war in 2018, instigating unrest in Hong Kong in 2019/2020, and trying to stir up support from the Muslim world against the Chinese by accusing the Chinese of genocide against the Uyghurs in Xinjiang in 2021/2022. Both the latter two moves failed to take off, with the Xinjiang fabrication unproven.
The whole USA plan to take on China first failed, because Russia made its pre-empted move on Ukraine that prevented the USA from concentrating its attack on China. That the Liberation of Donetsk and Lugansk started right after the February 2022 Winter Olympics in Beijing, during which Putin visited Xi, undoubtedly to put their plan into action, was anticipated by the USA, but they could do nothing. All the calculated moves between Russia and China, the diversion of energy towards the East were all worked out well before the USA and the West used the energy sanctions on Russia.
The fact that the USA were dead intent on stopping the Nord Stream 2 from opening up or functioning, even well before its completion, was apparently clear as to what the USA intention was, and you cannot fool a man as astute as Putin. Russia did not panic, having already anticipated this move by the USA and the West by building pipelines to China for energy diversion and probably already have garnered support from India as an alternative energy market, and the Middle East members of OPEC+ and their backup on energy policies.
Moreover, that stipulation that European countries buying Russian energy must pay in Rubles was a masterstroke that the USA and the West did not see. It prevented the collapse of the Ruble into rubbles that Biden was gloating about. Anyway, Biden may not now even remember saying that, so no use reminding him.
It is a no brainer to even think that after taking down China, the USA will not pivot towards confronting Russia by expanding Nato into Ukraine. That had been the USA's intention all along since 2008. Putin and Xi are not as ignorant of the USA's evil motive all over the world.
As long as Russia and China keep up their alliance and solidify on it, any move by the USA against any one of them is not without consequences. Russia has the military prowess, and China the financial strength to weather any conflict that the USA intends to take against both of them together. Not that China is that far behind in military prowess and the USA knows that the window of opportunity to put China down is closing fast.