Foucault was not a philosopher in the deep and abstruse ontological and epistemological sense, but more of a political and social theorist, with an emphasis on psychology. His writing are heavily politically motivated. His main idea as outlined in Madness and Civilization and other books, that mental disorder is a social construct, was perhaps a way of reconciling or justifying his own lifestyle, so rather than his behavior being deviant, it’s only deviant because society says it’s so. I don’t think Foucault’s homosexuality can be completely disregarded in the analysis of his works. A second theme is the centrality of power, in his book Discipline and Punish. Other themes include counter-enlightenment thought. Although he is of the ‘left’, which is a very broad category, Foucault was a social constructivist, which stands in opposition–to quote one of Jordan Peterson’s favorite phrases–to the biological essentialism of liberals such as Sam Harris and Steven Pinker. At the same time, he was an existentialist, and in the postmodernist sense, opposed the collectivist and deterministic theories of Marx, in favor of one’s own ability to ‘will to power,’ in the spirit of Nietzsche, whom Foucault was very heavily influenced by. This is why Foucault, a deconstructionist, opposed the constructionist social and linguistics theories of Chomsky despite both being of the ‘left’. The Enlightenment is predicated on the belief that reason and rationality are the bedrock of civilization; Foucault questioned all these notions, calling into doubt the benevolence of reason and seeing civilization itself as a force to control than emancipate people.