Novel tools for visual ion sensing and toxic chemical removal from wastewater developed