The government's welfare cuts will hit more than 3m people in total, with hundreds of thousands set to lose nearly £5,000 a year on average.