I also believe that Putin is quite smart. So, why did he fail? How could Putin miscalculate so badly? I believe that Putin miscalculated only one thing: Biden.
I think Putin knew that the Germans would not be a factor, they would not help Ukraine. And he knew that the Germans can vastly influence the rest of the EU, so the EU would not be a factor either. Fears of "escalation", of energy dependance, of World War 3, of economy ... the 27 countries of the EU would talk and talk and talk, and do nothing. Then Britain has its problems with Brexit, and it is too weak to do anything anyway.
Putin knew that the only one who can do anything to help Ukraine is America. But America has its own problems, it is divided, Biden is old, he gave up in Afghanistan, actually Biden did not just give up but messed up badly in Afghanistan, Biden is weak, he will have no desire to get involved into another military conflict.
In summary, I believe that the German "neutrality" was the most important factor in Putin's decision to go to war. And the second most important factor was the debacle in Afghanistan. If any of these two factors were not present, we'd not have this war. And Putin's major miscalculation was that he did not expect Biden to actually support Ukraine that much.