Jump to content

CSS for mobile banner

Go to solution Solved by Ziggy,

Recommended Posts

Hi all, 

So i have some code to change the background of the header on my homepage.
I noticed that this doesn't work on a mobile device. Can anyone share with me the code to do this?
I also need to change the hamburger menu icon colour for mobile as well.
 


/* Header BGcolor for homepage */
.homepage header#header {
    background-color: #ffffff !important;
}

/* Menu text color for homepage */
.homepage header#header div.header-nav-item>a {
    color: #000000 !important;
}

 

Kind regards,

Pace

Link to comment
  • Replies 6
  • Views 1.1k
  • Created
  • Last Reply

Top Posters In This Topic

Can you share your website URL?

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 
 🖼️ Pinch-to-Zoom Gallery Lightbox Plugin (Referral link) 

 Did I help? Buy me a coffee?

Link to comment
  • Solution
On 5/21/2024 at 12:40 PM, pace said:

I also need to change the hamburger menu icon colour for mobile as well.

Use this:

.homepage {
  :not(.header--menu-open) .burger-inner .top-bun, :not(.header--menu-open) .burger-inner .patty, :not(.header--menu-open) .burger-inner .bottom-bun {
    background-color:#a91a1a;
  }
}

 

On 5/21/2024 at 12:40 PM, pace said:

So i have some code to change the background of the header on my homepage.
I noticed that this doesn't work on a mobile device. Can anyone share with me the code to do this?

What are you trying to change? The header on mobile is white and the text is black.

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 
 🖼️ Pinch-to-Zoom Gallery Lightbox Plugin (Referral link) 

 Did I help? Buy me a coffee?

Link to comment
Posted (edited)

Hey Ziggy, thanks for the response, but how do I ensure that my mobile devices get the same header colour as the desktop clients.

Currently my desktop clients get a white header, but my mobile clients get a dark one.

What i've noticed, is that mobile devices using the brave browser get a black header, but mobile clients use safari, get a white header.

Edited by pace
Link to comment
On 5/25/2024 at 12:39 PM, pace said:

What i've noticed, is that mobile devices using the brave browser get a black header, but mobile clients use safari, get a white header.

I'm not sure how to explain that.

What settings do you have for the header? Dynamic? Solid?

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 
 🖼️ Pinch-to-Zoom Gallery Lightbox Plugin (Referral link) 

 Did I help? Buy me a coffee?

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.