An inflammatory process involving the brain (encephalitis) and meninges (meningitis), most often produced by pathogenic organisms which invade the central nervous system, and occasionally by toxins, autoimmune disorders, and other conditions.