But if you sin unintentionally, and do not observe all these commandments that YHWH has spoken to Moses...
Numbers 15:22 #shlach

The people are collectively guilty if they collectively engaged in sin, even unintentionally. Individuals who might not have been guilty of the same mistake still share in the collective guilt of the congregation. It doesn't matter if we think it's fair.