Smaller hero buttons on mobile devices

Hi

I want to reduce the size on my mobile hero buttons, they are too big and cover bigger part of the screen, wish to have smaller and a nice border radius on them. Can we figure something out? :slightly_smiling_face:

Storeurl:

www.dekanten.no

Hi @Dekanten ,

  1. Go to Online Store → Theme → Edit code.
  2. Open your theme.liquid file
  3. In theme.liquid, paste the below code before

If my reply is helpful, kindly click like and mark it as an accepted solution.

Thanks!

1 Like

Hello @Dekanten

You can add code by following these steps

  1. Go to Online Store → Theme → Edit code.

  2. Open your theme.liquid file

  3. Paste the below code before on theme.liquid

@media screen and (max-width: 767px) { .banner__buttons.banner__buttons--multiple a::before, .banner__buttons.banner__buttons--multiple a::after { border-radius: 15px; } .banner--content-align-center .banner__buttons--multiple>* { border-radius: 15px; } .banner--content-align-mobile-center .banner__buttons--multiple>* { flex-grow: 1; min-width: 18rem !important; } #Banner-template--21636163502354__image_banner_B7RaMJ .banner__buttons.banner__buttons--multiple { width: 74% !important; margin: 0 auto; } }

Was my reply helpful? Click Like to let me know!
Was your question answered? Mark it as an Accepted Solution.

1 Like

Hi,

I added the code but the button is grey colored on the edges, outside the border. Can we fix this too? :slightly_smiling_face:

See attached image.

Yes we can. Give me a mint. I am giving you the fix

1 Like

@Dekanten , check the below code:

.button:before , .button:after { border-radius: 25px !important; }