A compound represented by formula (IA) or a pharmaceutically acceptable salt thereof, which is useful for the treatment or prevention of diseases such sleep disorder, depression, anxiety disorder, panic disorder, schizophrenia, drug dependence, Alzheimer's disease, Parkinson's disease, Huntington's chorea, eating disorder, pain, gastrointestinal diseases, epilepsy, inflammation, immune-related diseases, endocrine-related diseases, and hypertension, and of which the action relies on an orexin (OX) receptor antagonistic activity.