implementing gradient color for scales