You can do this with a site-to-site wireguard VPN. You will need to set up the proper routing rules on each termination. On the Internet facing side you will want to do DNAT (modifies destination, keeps source) to redirect the incoming traffic to your non- internet facing side through the tunnel. Then on the non- internet facing you need to set up Routing rules to ensure all traffic headed for public IPs is traversing the tunnel. Then back on the Internet facing side you need to SNAT (modify source, keep destination) the traffic coming through the tunnel headed for the Internet. Hopefully this helps. People saying this goes against standards are not really correct as this is a great application for NAT.
When you get a 502 it usually means that your reverse proxy is unable to connect to your backend server. I’m not sure if you’ve obfuscated the URL in your post but 0.0.0.0 is not a valid IP (it just means ALL IPs). If you are attempting to connect on the same machine that is hosting use 127.0.0.1. if you are on the same network then use the local IP.