Nitrogen-containing heterocyclic compounds represented by the following Formula (1) are provided. The compounds or salts thereof have a strong EP1 antagonistic activity when they are administered to a human or an animal, and they are useful as an effective component of a pharmaceutical agent for prophylaxis and/or treatment of an overactive bladder, for example. Furthermore, they are useful as an effective component of a pharmaceutical agent for the prophylaxis and/or treatment of symptoms including frequent urination, urinary urgency and urinary incontinence.