How can I effectively hide a section on a desktop view?

Hey, I want to hide this section on desktop. I already tried CSS codes but none of them work and I don’t know why, because when I tried same code on different section..it worked. The section that I want to hide is the huge ,image with overlay section".. thank you for help

It’s on the shower head product page (it’s the comparison table), theme: focal, pass: dewchi

link: https://shower-head-storetest.myshopify.com/products/nashover-shower-head

1 Like

example:

In the section look for the image you want to hide. and place a custom class.

This is the section of the first image

-Now an example of CSS code passes you

@media only screen and (min-width: 400px) {
.desktop-visible { display:none;}
}

Hi @Jacobdss

Check this one.

  • From your Shopify admin dashboard, click on “Online Store” and then “Themes”.
  • Find the theme that you want to edit and click on “Actions” and then “Edit code”.
  • 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:
@media only screen and (min-width: 749px){
div#shopify-section-template--16993351172348__a71ff6a9-698e-4189-aa20-c68c983b3d13 {
    display: none !important;
}
}

Please don’t forget to Like and Mark Solution to the post that helped you. Thanks!

Doesn’t work for me..

Where should I put the code? There is html, so I can’t put it into theme.css

It the app right? its better to contact the app provider.

It’s not app, I made the comparison in canva and inserted the picture into text with overlay section and I just want to hide the text with overlay section on desktop.

some other solution could be just reducing the size of it only on computer, any ideas of code for that?

Did you try to hide in the customize theme? If its a section. Try this one again.

@media only screen and (min-width: 749px){
.image-overlay {
    display: none !important;
}
}

And Save.

Please don’t forget to Like and Mark Solution to the post that helped you. Thanks!

Hi @Jacobdss ,

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