I like the card idea, but i need an explanation.
The simplest way i see it being implemented is "Always if ATK is greater than 12, set it equal to 12. If ATK is changed, change HP by ATKinitial - ATKfinal"
The simplest way I see it being implemented is "Always if ATK is greater than 12, set it equal to 12. If ATK is changed, set HP to 12-ATK."
Then add another line for the card with the same syntax, but for HP.
Although you still have to somehow add another line or reword the second line so that changing one stat doesn't trigger a chain reaction.
But, even so, that way wouldn't work for rage potion, because you increase the attack by five, (lowering the HP by five) and then lower the HP by five (increasing the ATK by five), which makes +10|-10, much different than the intended outcome.
So the only way to get around that is to add a line of code for every single form of stat manipulation, from Owl's Eye to Fire Bolts. Or have I overlooked something obvious?