Improved pagination feature