200 nations agree to move off fossil fuels in historic pact