How to minimize padding

Topic summary

A user needed help reducing the padding/spacing between a title and an image on their Shopify store, as shown in an attached screenshot.

Solutions Provided:

Two community members offered CSS-based solutions:

  • Solution 1: Add custom CSS targeting .title-wrapper-with-link.title-wrapper--self-padded-tablet-down.title-wrapper--no-top-margin with margin-bottom: 2px !important;

  • Solution 2: Add CSS targeting .title-wrapper--no-top-margin with margin-bottom: 0px !important;

Both solutions required editing the theme’s CSS file (theme.css or base.css) through the Shopify code editor.

Resolution:

The issue was successfully resolved. The original poster confirmed that both suggested solutions worked, and the discussion concluded with the problem solved.

Summarized with AI on November 2. AI used: claude-sonnet-4-5-20250929.

Hello friends, how can I minimize the padding between titel and image?

Hi @NikosBat , kindly provide your store URL please and if it is password protected, please share the password as well. Thanks

Hi @NikosBat

  1. Go to Online Store → Theme → Edit code.
  2. Open your theme.css / based.css file and paste the code in the bottom of the file.
.title-wrapper-with-link.title-wrapper--self-padded-tablet-down.title-wrapper--no-top-margin {
    margin-bottom: 2px !important;
}

Result:

If my reply is helpful, kindly click like and mark it as an accepted solution.
If you are happy with my help, you can help me buy a COFFEE
Thanks!

1 Like

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

.title-wrapper--no-top-margin {
margin-bottom: 0px !important;
}

Result

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

1 Like

@NikosBat

I have updated the above code; paste it, and your issue will be resolved.

Thanks Rahul_dhiman that solved my problem

Thanks Websensepro that solved my problem

Happy to help you…!!!