Efficient and sustainable treatment of industrial wastewater using a tannin-based polymer