First-class counties agree to play red and white-ball cricket this summer