Unless Poison and Electricity are the only things in your game, I'd try to take into account the entire set of colors, to make sure they all go well together.
For example, if Earth was Yellow or Brown or Grey, but now you make Electricity blue or purple, it'd be more visually pleasing to make Earth closer to an Orange color.
And if you have Plant or Wind as green, then Poison would be better off as a different color, but if Shadow is purple, then maybe Poison should be black (from death, and the Skull and Crossbones usage to mark poison).
And speaking of Wind, that's one I don't get! Why is wind always green? I guess "because blue is already taken by water!", but I'd personally prefer a white wind (or a very pale green), if not taken by light. And if taken by light, maybe light should be Yellow.
(If white is taken by Holy, then Holy should become pale Blue, because, uh, IDK why :P)
Which probably also explains why electricity is yellow; even though *lightning* may be a different color, "electricity" is seen almost everyday in the form of a very pale yellow light coming from incandescent light-bulbs (though this is increasingly changing due to fluorescent, halogen, and LED lightbulbs now being (properly) required in the USA for energy efficiency).
I'd suggest laying out your entire spectrum of magic in a circle, and then tweaking the colors to balance for all four:
- Are they easily differentiateable at a glance? Even to people that are partially colorblind? (Differentiate not merely by color, but also by shape and form!)
- Are they intuitive? Would new players be able to guess them without being told? Would they accidentally forget in the heat of battle, because of years of playing other games?
- Are they aesthetically pleasing, and do they complement each other?