Here is Wikipedia on this topic, which is actually one of the more "US intelligence friendly" sources out there: https://en.m.wikipedia.org/wiki/United_States_involvement_in... This list is endless and shocking.
Pakistan is a big and important country, so their position is actually important. Furthermore, for any empire, it's vital that it gets other smaller countries in line, even if the small country's position would be irrelevant.
The way I see it is that most countries' leaders will always be both popular and unpopular in a significant portion of the country so it is always possible to frame a revolution/coup/insurgence as either a great thing or a bad thing.
I don't know what happened in this case, and in complicated scenarios like these, there are always many factors and forces at play, but it's certainly not unreasonable to think that foreign powers gave a little push in order to see the outcome they wanted in the region.
To further your point: Pakistan has the 5th largest population in the world, has complicated relationships (including contested borders 20 miles from its capital) with #2 and #1, and has a weak enough economy that a little money can go a long way. I would be shocked if the US weren't applying any force to its politics.
Do people really think western powers care that much about Imran Khan's opinion on Russia-Ukraine to pull off a regime change in one of the largest and most unstable countries (that too with nuclear weapons) in the world? It's a tactic for such politicians and countries to make themselves feel more important on the global stage, nothing more.
Pakistan has always been run by its military. Politicians who get out of line quickly get deposed/exiled/assassinated. There is nothing new or surprising with the latest development.