How can I fix alignment issues with a custom button on both mobile and desktop?

Hey! I was working on this website for my friends and they needed a custom button which I did but, it is not aligning properly on both mobile & desktop. Is there a way I could properly center it without moving other sections in the website? Here’s the code button I did:


[

](http://r.lessentiel-bienetre.fr/products/huile-bio-5?addVariant=42214806683803
)

Here is how it looks on mobile:


(not properly centered up)

And on desktop it looks good but it moves this section:


which should be all in one line…

Any help would be really appreciated!! Thank you

1 Like

@devbug

can you please share store url

hey Kutan, my bad there it is : https://www.lessentielbienetre.com

1 Like

Hi @devbug ,

Please share your store URL and if your store is password protected then please provide password too.

So that we can help you.

Thank you.

@devbug

thanks can you try this css code


1 Like

thank you, this indeed centered the button well, but it still messes the “découvrez également” sections" under. also for some reason the link linked to the button goes down all the way through the website , as in it is clickable even when not hovering the button

hi, it’s https://www.lessentielbienetre.com thank you so much

1 Like

@devbug

add this hover text color code

button.generated-text:hover {
    background: #ced9c6;
}

also do you need a Smooth Scroll

1 Like

it looks good thank you, although for some reason the link linked to the button is hoverable pretty much anywhere around the website and the sections aren’t one lined as they should be :disappointed_face:

1 Like

@devbug

yes, please add this code

  1. Go to Online Store->Theme->Edit code
  2. Asset->/theme.css ->paste below code at the bottom of the file.
.homepage-collection-grid .grid {
    display: flex;
    flex-wrap: wrap;
}
1 Like

thank you so much

1 Like

@devbug its my pleasure to help us

1 Like