Simpler, more performant carousel pager function