I'm attaching a spreadsheet showing how to calculate net 12 months without vlookup. At the end of the month, you just woudl have to add the date, sales and defects and drag down the calculated fields.
running totals/net 12 month totals are tricky to calculate. There might be a better way to do it but this is how I would do it.
I'm not a huge pivot table fan because pivot tables resize to match your data set which can throw off referrences, I prefer working with sumifs, countifs and vlookup to create something similar and then just check the balance against the balance being looked up to make sure nothing is being missed.
Hope this helps!