Mitigating the negative impact of soluble and insoluble lignin in biorefineries