Fixed percentage calculation issues