.pagination-outer{ text-align: center; } .pagination{ font-family: 'Poppins', sans-serif; display: inline-flex; position: relative; } .pagination li a.page-link{ color: #6F1E51; background: #e7e7e7; font-size: 22px; font-weight: 500; line-height: 38px; height: 38px; width: 38px; padding: 0; margin: 0 5px; border: none; border-radius: 0; border: none; position: relative; z-index: 1; transition: all 0.3s ease 0s; } .pagination li a.page-link:hover, .pagination li a.page-link:focus, .pagination li.active a.page-link:hover, .pagination li.active a.page-link{ color: #fff; background: transparent; border: none; } .pagination li a.page-link:before, .pagination li a.page-link:after{ content: ''; background-color: #6F1E51; height: 0; width: 100%; position: absolute; left: 0; top: 0; z-index: -1; transition: all 0.3s ease 0s; clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%); } .pagination li a.page-link:after{ top: auto; bottom: 0; } .pagination li a.page-link:hover:before, .pagination li a.page-link:focus:before, .pagination li.active a.page-link:hover:before, .pagination li.active a.page-link:before, .pagination li a.page-link:hover:after, .pagination li a.page-link:focus:after, .pagination li.active a.page-link:hover:after, .pagination li.active a.page-link:after{ height: 70%; } @media only screen and (max-width: 480px){ .pagination{ font-size: 0; display: inline-block; } .pagination li{ display: inline-block; vertical-align: top; margin: 10px 0; } }