Morocco to invest US $40bn in energy sector