Shopify themes, liquid, logos, and UX
Hi, I am wondering can someone help me with CSS to make my product page variants picked show in the same row?
Something like in the photo I attached, both on mobile and PC.
My website is domisana.com
Hi @Domisana
1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.css / based.css file and paste the code in the bottom of the file.
variant-selects {
display: flex !important;
gap: 10px !important;
}
.product-form__input.product-form__input--dropdown {
flex: 50% !important;
}
If my reply is helpful, kindly click like and mark it as an accepted solution.
If you are happy with my help, you can help me buy a COFFEE
Thanks!
Hello @Domisana ,
Follow these steps:
1. Go to Online Store -> Theme -> Edit code
2. Open your base.css file and paste the following code at the bottom:
variant-selects {
display: flex !important;
gap: 4px !important;
}
.product-form__input--dropdown {
flex: 48% !important;
}
Regards
Guleria
Hi @Domisana
Try this one.
@media only screen and (min-width: 749px) {
.product__info-container variant-selects {
display: flex;
gap: 4%;
width: fit-content;
flex-wrap: nowrap;
}
.product-form__input {
flex: 0 0 48% !important;
max-width: 48% !important;
box-sizing: border-box;
}
}
Your Feedback Matters! Please mark the solution and give likes to posts that helped you. Your appreciation fuels our motivation to assist you better!
Thank you for the answer! I just noticed that I also have quantity which I would like to fit into the row as well. Could you please modify the code so all 3 fit into one row?
Btw, on mobile, you see that variant is not entirely visible, it is cut
June brought summer energy to our community. Members jumped in with solutions, clicked ...
By JasonH Jun 5, 2025Learn how to build powerful custom workflows in Shopify Flow with expert guidance from ...
By Jacqui May 7, 2025Did You Know? May is named after Maia, the Roman goddess of growth and flourishing! ...
By JasonH May 2, 2025