Removal of phosphorus using AMD-treated lignocellulosic material