An organic compound A, C8H4O3, in dry benzene in the presence of anhydrous AlCl3 gives compound B. The compound B, on treatment with PCl5, followed by reaction with H2 / Pd(BaSO4) gives compound C, which on reaction with hydrazine gives a cyclised compound D (C14H10N2 ). Identify A, B, C, and D. Explain the formation of D from C.