The present invention relates to a novel compound having an antiviral effect, more specifically, a pyridone derivative having HIV integrase inhibitory activity, and a medicament containing the same, in particular, an anti-HIV agent. The compound of the present invention has integrase inhibitory activity and/or cell proliferation inhibitory activity against viruses, in particular, HIV and drug-resistant strains thereof. Thus, the compound is useful in preventing or treating various diseases, viral infections (for example, AIDS), and the like in which integrase participates.