The synthesis of three new classes of heteroarenes, built through the sequential fusion of naphthalene, benzo/naphtho[b]oxepine and thiochromene rings with pyran and pyrimidine ring systems to give ‘U and Z’ shaped structural frameworks is reported. The methodology is based on the synthesis of pyran fused intermediates, 1-methylthio-3-oxo-5,6-dihydro-3H-benzo[f]chromene-2-carbonitrile (3), 4-methylthio-2-oxo-5,6-dihydro-2H-benzo/naphtho[b]pyrano[2,3-d]oxepine-3-carbonitriles (10, 20) and 4-methylthio-2-oxo-2,5-dihydrothiochromeno[4,3-b]pyran-3-carbonitriles (15) from the reaction of 2-tetralone, benzo/naphtho[b]oxepin-5-ones and thiochromen-4-ones with methyl 2-cyano-3,3-dimethylthioacrylate respectively. Further condensation of intermediates 3, 10, 20 and 15 with amidines led to the formation of tetracyclic ‘U’ shaped 4-amino-2-aryl-7,8-dihydro-5-oxo-5H-naphtho[2,1-b]pyrimido[4,5-d]pyrans (8) and ‘Z’ shaped 4-amino-2-aryl-5-oxo-12,13-dihydro-5H-benzo/naphtho[b]oxepino[5,4-b]pyrimido[4,5-d]pyrans (12, 22) and 4-amino-2-aryl-5-oxo-5,12-dihydrothiochromeno[4,3-b]pyrimido[4,5-d]pyrans (17). Compound 12f forms a chain of dimers through N–H⋯O interactions as indicated by the X-ray structure analysis, and the quantum chemical calculations performed at the MP2 level indicate that this interaction energy is 10 kJ mol−1.