Craft theme - header margin error

Craft theme - header margin error

INFRA
Shopify Partner
132 0 53

Hi guys,

 

Something weird is happening with the header on my Craft theme. I've tried a few "margin-bottom: -80px" code, but some will take spacing off the mobile view from the section below so I'm not sure where it's going wrong!

Then I added this code below, but it caused the other pages on desktop to be cut off at the top.

 

Any other solutions for this? Thanks!

 

 

 

 

@media (min-width: 749px) {
   {
    margin-bottom: -80px;
  }
}

 

 

 

 

website 

 

Screenshot 2024-09-06 at 16.57.23.png

Replies 5 (5)

BSSCommerce-HDL
Shopify Partner
2086 742 936

Hi @INFRACan you kindly share your store link with us? We will check it and suggest you a solution if possible.

If our suggestions are useful, please let us know by giving it a like, marking it as a solution.

Simicart: Transform your Shopify store into a stunning and fully functional mobile app with just a few simple steps.
Product Labels & Badges:
Get more sales with striking labels, badges, and banners from our 10,000+ available templates.

BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now

BSSCommerce-HDL
Shopify Partner
2086 742 936

Hi @INFRA

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

Step 2: Search file theme.liquid

Step 3: Insert this code above </head> tag:

<style>
section#shopify-section-template--23441632330004__slideshow {
    margin-top: 0 !important;
}
</style>

 

Hope this can help you,

If our suggestions are useful, please let us know by giving it a like or marking it as a solution. Thank you 😍

If our suggestions are useful, please let us know by giving it a like, marking it as a solution.

Simicart: Transform your Shopify store into a stunning and fully functional mobile app with just a few simple steps.
Product Labels & Badges:
Get more sales with striking labels, badges, and banners from our 10,000+ available templates.

BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now

topnewyork
Globetrotter
633 113 134

Hi @INFRA ,

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file
3. In theme.liquid, paste the below code before </head>

 

 

<style>
.section+.section {
    margin: 0 !important;
}
</style>

topnewyork_0-1725606399478.png

 

 

If my reply is helpful, kindly click like and mark it as an accepted solution.

Thanks!

Need a Shopify developer?
Hire us at Top New York Web Design
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel

GTLOfficial
Shopify Partner
481 97 91

HEllo @INFRA 

Go to online store ----> themes ----> actions ----> edit code---->base.css ----> line number 149
search this code and delete and then save.

 

.section + .section {
margin-top: var(--spacing-sections-mobile);
}

@media screen and (min-width: 750px) {
.section + .section {
margin-top: var(--spacing-sections-desktop);
}
}

 result
19.png

 

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

- Buy me a Pizza
- If helpful then please Like and Accept Solution.
- Want to modify or custom changes or bug fix on the store Hire me. GTL web solutions
- Want Complete Storefront: Send an email ⇨- Email: info@gtlofficial.com - Skype: ritesh_27dh

Tech_Coding
Shopify Partner
173 49 49

Hello @INFRA 

You can add code by following these steps

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file

3. Paste the below code before </body> on theme.liquid
<style>
  .section+.section {
      margin-top: 0 !important;
  }
</style>

Tech_Coding_0-1725606616024.png

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.
Shopify UI Developer
Your Coffee Tips adds a little sweetness to my day.