I'm going down a different route here and should point out I use libre office but can program my own accounts software.
I would have three columns for the figures. 1 = output (invoice total) 2 = input (payment made) 3 = balance. Expanding this to include invoice numbers, dates & customer name.