Collective Punishment

A nation being destroyed does not imply that death is a form of punishment. Death is the end of your stay in this world per Islam. The suffering before the moment of death may be a form of punishment intended to erase some of our sins or it may also be a test of our faith in Allah SWT. This is something we cannot accurately fathom. A persons punishment or reward is alotted after judgement not death.