Fostering affinity through smarter loyalty programs