Hello, I want to change the color of some backgrounds in some collection pages, not the header or footer color. Please explain how to do this on the custom css of each collection page. Looking to have color #DFD8CF.
thank you!
Hello, I want to change the color of some backgrounds in some collection pages, not the header or footer color. Please explain how to do this on the custom css of each collection page. Looking to have color #DFD8CF.
thank you!
To change the background color of specific collection pages in Shopify using custom CSS, you can follow these steps:
body.template-collection-handle {
background-color: #DFD8CF;
}
Replace collection-handle in template-collection-handle with the handle of the collection page you want to target. For example, if the handle of the collection is “shirts,” the CSS selector would be body.template-collection-shirts.
The CSS code above targets the body element of the specific collection pages based on their template. It sets the background-color property to the desired color, #DFD8CF. This will change the background color of the targeted collection pages.
Hello, thank you for the help but it did not work. Any other idea?
Hi @settolive
Can you kindly share your store link (with the password, if any) with us? We will check it and suggest you a solution if possible.
Hi @settolive ,
Is this the result you want - We try to edit the background colors of some product-cards
To do this, You need to follow these steps:
Step 1: Go to: online store => themes => edit code
Step 2: Find the file base.css and paste the following code in it
/* start bss fix */
.grid__item:has(#title-template--18720610877747__product-grid-8233653829939),
.grid__item:has(#title-template--18720610877747__product-grid-8274433605939) {
background-color: #DFD8CF;
}
/* end bss fix */
Note: The parts in brackets “title-template–18720610877747__product-grid-8233653829939” are the cards you want to select.
Example:
You can also find and add some variables by entering a line of code like this
/* start bss fix */
.grid__item:has(#title-template--18720610877747__product-grid-8233653829939),
.grid__item:has(#title-template--18720610877747__product-grid-8274433605939),
.grid__item:has(
Hope this suggestion can help you.
Hello! Thank you for above but no, I want to change is the white page body background, not the product card. Can you help me with this?