Google agrees to $391.5M settlement with 40 states over location-tracking of users