Nations have come to a compromise over plans to raise and deliver billions in funding for biodiversity protection, paving the way for action to counter the growing problem of species loss.