Changing Panels Unit, Threshold and Ranges with Varibles

Hey community.

I need some help on changing units, thresholds and ranges, after selecting a variable between mAh and SOC (Custom Variables).
Screenshot 2023-09-04 122147

Here is the bar graph using SOC, everything works as the panel was designed around these values.

Now of course when i go to using it in mAh, everything is out of spec and just wrong.

I dont think it should be too difficult, i just need a rough idea on how to approach this. I dont really have that right now, as im new to grafana.