A group of women bought 507 kg 275 g of wheat flour. They donated 377 kg 800 g of the flour to children’s homes. How much flour remained?