How do I center my Collections List when I cannot fill the row on Empire theme?

Here’s what I have currently. I have a max of 5 per row. But if I do not have 5 collections, I would like the all to be centered.

Webpage: https://nextpointbearing.myshopify.com/pages/bearings

Password: steelpancakes

Hi @NPB_Marketing ,

You can center the collection items by following the instructions below.

  1. From you Admin page, go to Online store > Themes > Click the three dots on the theme you want to edit > Edit code
  2. Go to Asset folder and open the theme.css file
  3. At very end of the code, add the code below
@media only screen and (min-width 751px) {
li.collection__item.pxu-lia-block.pxu-lia-block--play {
    max-width: 214px;
}

ul.home-section--content.collection-list__content.collection--image-crop-original.no-cta {
    display: flex;
}
}

Result here:

Unfortunately, nothing has changed. Here’s where I placed the code.

Hi @NPB_Marketing

This is Richard from PageFly - Shopify Page Builder App

Please add this code to your theme.liquid above the to get this solved

Step 1: Online Stores > Themes > More Actions > Edit code

Step 2: click on theme.liquid and paste the code above the

If you want it become 2 collection and center, please use this code


Or two small collection but center, then you can use this


Hope this can help you solve the issue

Best regards,

Richard | PageFly

This worked! Thank you! Does this code also apply to 3 and 4 collections? The max width is 5.

Edit: YES! It works for any number. Thank you so much for your help!

Thanks @NPB_Marketing my friend, glad to hear that it’s work for you.

Let me know if you need further help