added pagination macro and styles