alyssazack Posted October 3, 2022 Share Posted October 3, 2022 Site URL: https://caipirinhala.com/ I implemented the following code to hid the mobile navigation bar but it moved the logo header to left justified instead of centered. Any code I can add to fix it? @media screen and (max-width:767px) { .header-display-desktop { display: flex !important; } .header-display-mobile { display: none !important; } .header-burger { display: none; } .header-title-nav-wrapper { flex: 1 0 100% !important; } .header-nav { display: flex !important; width: 70% !important; flex: 1 1 70% !important; } .header-title { flex: 1 0 30% !important; } } Link to comment
Ziggy Posted October 3, 2022 Share Posted October 3, 2022 3 minutes ago, alyssazack said: .header-nav { display: flex !important; width: 70% !important; flex: 1 1 70% !important; } .header-title { flex: 1 0 30% !important; } This code is setting the .header-nav to 70% of the width, and this .header-title to 30%. You want the header title to be 100% and Nav to be 0%. Try this: @media screen and (max-width:767px) { .header-display-desktop { display: flex !important; } .header-display-mobile { display: none !important; } .header-burger { display: none; } .header-title-nav-wrapper { flex: 1 0 100% !important; } .header-nav { display: flex !important; width: 0% !important; flex: 1 1 0% !important; } .header-title { flex: 1 0 100% !important; } } 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
alyssazack Posted November 21, 2022 Author Share Posted November 21, 2022 Hi Ziggy, somehow just seeing this. The code you suggested did not work. Any other recommendations? Thanks! Link to comment
Solution tuanphan Posted November 23, 2022 Solution Share Posted November 23, 2022 On 11/22/2022 at 6:13 AM, alyssazack said: Hi Ziggy, somehow just seeing this. The code you suggested did not work. Any other recommendations? Thanks! Add this to Design > Custom CSS @media screen and (max-width:767px) { .header-title-nav-wrapper { flex-direction: column !important; } } Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment