TL;DR: Tree models were specifically designed to handle features like this.
Nice. But isn’t this exactly the kind of situation tree-based models are built to handle—non-linear relationships like the one illustrated? It’s one of the reasons P123 added the AI/ML module in the first place. Marco has done a great job making ML and tree models accessible to everyone.
If you have a lot of features like that, I’d suggest just trying a tree model—see if it works for you.