How can I change the add to cart button color on multiple product pages?

Topic summary

Goal: Make the “Add to cart” button use color #00c7ff on three specific product pages (50 ml measuring cylinder, free sample, mixing bottle) to match the main product page.

Proposed fix: A reply suggested adding custom CSS in theme.liquid targeting add-to-cart forms by product ID.

Details: The provided code appears incomplete/malformed (an empty code block, duplicated selectors for the same product ID, and a CSS rule with a missing value and non-English keywords), so it doesn’t define the #00c7ff background color.

Outcome: After applying the suggestion, the requester got an error (shared via screenshot) and the button colors did not change.

Status: Unresolved. A corrected CSS snippet (with proper selectors and a defined background-color: #00c7ff) or an alternative approach is still needed.

Summarized with AI on January 2. AI used: gpt-5.

On this product page, the add to cart button color is 00c7ff: https://empiricalwater.com/products/empirical-water

I need that same button color to apply to the add to cart button on these product pages as well:

https://empiricalwater.com/products/50-ml-measuring-cylinder

https://empiricalwater.com/products/empirical-water-free-sample

https://empiricalwater.com/products/mixing-bottle

As you can see the add to card button is currently white on those 3 pages.

Thanks!

Hi @empiricalarby ,

You can try this code by following these steps:

Step 1: Go to Online Store->Theme->Edit code.

Step 2: Search file theme.liquid

Step 3: Paste the below code at the bottom of the file → Save


Hope my solution works perfectly for you!

Best regards,

Oliver | PageFly

<phong cách>

[data-type=“add-to-cart-form”][data-productid=“8318539006203”],

[data-type=“add-to-cart-form”][data-productid=“8318539006203”],

[data-type=“add-to-cart-form”][data-productid=“8318539006203”]{

màu nền:

}

1 Like

Thanks, unfortunately this was the result:

Let me know if you have a solution. Cheers