Remove line between section

Topic summary

A Shopify store owner seeks help removing unwanted horizontal lines appearing between custom sections on their product page, along with reducing spacing between sections.

Solutions Provided:

  • CSS modifications: Multiple contributors offered custom CSS code snippets to add to the theme’s stylesheet (base.css, style.css, or theme.css), targeting .bordered-section classes with properties like border-block-start-width: 0px and adjusted margins.

  • Theme settings approach: One responder suggested checking the theme’s built-in section settings, which may include options to toggle borders on/off without code modifications.

  • Implementation methods: Solutions involve either editing code files directly through the theme editor or using the Custom CSS field in Theme Settings.

Additional Development:

A French-speaking user later joined with a similar line-removal issue on their store (nemeos.fr), having spent 5 hours attempting CSS fixes unsuccessfully. However, a follow-up response indicates the lines are not visible on their provided link, suggesting the issue may have resolved or requires clarification.

The discussion remains open with multiple viable solutions offered but no confirmed resolution from the original poster.

Summarized with AI on October 29. AI used: claude-sonnet-4-5-20250929.

Please help remove the lines present on my Shopify product page. I created this section custom.

Also, if possible, let me know how to decrease the space between the section too.

Here’s my store details -

https://quickstart-c4988d9a.myshopify.com/products/unc-blue-sweatsuit
password - iafawm

Please the check the product page and select product “UNC BLUE SWEATSUIT”

1 Like

Hi @Lalvikas

Try this one.

  1. From your Shopify admin dashboard, click on “Online Store” and then “Themes”.
  2. Find the theme that you want to edit and click on “Actions” and then “Edit code”.
  3. In the “Assets” folder, click on “base.css, style.css or theme.css” file, depending on which file your theme uses to store its CSS styles. At the bottom of the file, add the following CSS code:
.shopify-section:not(:first-child):has(.bordered-section) {
    border-block-start-width: 0px !important;
}

.section-spacing.bordered-section {
    margin-top: 1rem;
    margin-bottom: 1rem;
}

Your Feedback Matters! Please mark the solution and give likes to posts that helped you. Your appreciation fuels our motivation to assist you better!

1 Like

Hi @Lalvikas ,

You can follow the steps here:

Step 1: Shopify admin > Online store > Customize: https://prnt.sc/XQ6IDB99kUCd
Step 2: From the left menu > Theme settings > Open Custom CSS: https://prnt.sc/ypQ7nly2wv27
Step 3: Copy the code below and paste it there

Here is the code for step 3:

.section-spacing.bordered-section:has(.product-tabs) {
    margin-block: 0 !important;
}

Here is the result:

Please let me know if it works!

Best,

Daisy

1 Like

Hi @Lalvikas

Please check the settings of your theme. It has the option to turn off those lines on each section’ settings.

Hello @Lalvikas
Go to online store ----> themes ----> actions ----> edit code ---->theme.css
add this code at the end of the file and save.

.shopify-section:not(:first-child):has(.bordered-section) {
border-block-start-width: 0px;
}

Result

If this was helpful, hit the like button and accept the solution.
Thanks

1 Like

Bonjour, j’ai le même problème pour les lignes. J’ai passé 5h à essayer en modifiant le css de règler le problème. Impossible de vous aider ?

J’ai mis des photos pour vous montrer le problème…

Merci de m’éclairer, je suis désespérer.

Boutique : nemeos.fr

Hi @basile3848

I’m not seeing the lines from the link you provided, and the sample image is also not showing.