Idiot is not. It comes from a Greek word for someone who doesn’t pay attention to politics.
A little bit of both, apparently.
https://en.m.wikipedia.org/wiki/Idiot
If this is correct, then it started out as a word for private citizen and then evolved in Greek to mean ignorant.
Then in the 19th Century was coined as a medical term.