Community Forums › Forums › Archived Forums › Design Tips and Tricks › How to push content down on clicking hamburger menu
Tagged: hamburger menu, nav menu
- This topic has 7 replies, 3 voices, and was last updated 7 years, 7 months ago by Victor Font.
-
AuthorPosts
-
June 27, 2017 at 3:28 am #208337yashitamittal11Member
I am trying to customise the Digital Pro theme. I have just made a few changes to CSS for site-header and navigation menu. On small screen sizes (below 800px), when I click the hamburger menu, it does not push down the content . Instead menu items are overlapping the bottom content.
Github link to the code: https://github.com/yashitamittal11/digital-pro
Changes done in style.css:.site-header { border-top: 3px solid #e44a3c; border-bottom: 3px solid #e44a3c; height: 90px; } .site-header .title-area { background-color: #e44a3c; text-align: center; position: absolute; top: 0px; margin-top: 0; width: 320px; height: 100px; left: 5%; } .site-header .title-area .site-title { margin-top: 10%; } .site-header .title-area .site-title a { color: #fff; } .site-header .widget-area { margin-top: 15px; } @media only screen and (max-width: 1000px) { .site-header { height: 150px; } .site-header .wrap { top: -30px; position: relative; } .site-header .wrap .title-area { position: relative; margin: 0 220px; left: 0; } .nav-primary { margin-top: 50px; text-align: center; width: 100%; } } @media only screen and (max-width: 800px) { .site-header .wrap .title-area { top: -22px; margin: 0 auto; } .menu-toggle { margin-top: -15px; } }
June 27, 2017 at 4:40 am #208341Victor FontModeratorLinking to the code doesn't help. Please post a link to the site.
Regards,
Victor
https://victorfont.com/
Call us toll free: 844-VIC-FONT (842-3668)
Have you requested your free website audit yet?June 28, 2017 at 5:08 am #208367yashitamittal11MemberHi
I am working on localhost. This is not a live site.
Where can I post the code files for free.June 28, 2017 at 7:50 am #208375Brad DaltonParticipantHi.
You'll need to link to a live site if you want CSS help from community volunteers.
June 29, 2017 at 3:36 am #208434yashitamittal11MemberHi
I have made an online website at http://greeninvites.com/
1. I get the hamburger menu below 800px screen width. When I click on menu, the contents overlap the data below. How to fix this.
I am using Digital Pro theme, and have made some customisations because of which this functionality has stopped working properly.2. I have one more small issue. Below 1000px screen width, .site-title is not centered. I have tried
margin: 0 auto;
, but it doesn't work.
Please suggest.June 29, 2017 at 7:45 am #208455Victor FontModeratorLet me answer #2 first. The .site-header padding is pushing the title area to the left. Change the site header padding in a media query and make the left/right padding 0 instead of 8%. You'll also have to change the top to 0. You currently have it set to -22px and it's off the screen.
#1, Add z-index: 1 to nav.genesis-responsive-menu at line 2176 in style.css
Regards,
Victor
https://victorfont.com/
Call us toll free: 844-VIC-FONT (842-3668)
Have you requested your free website audit yet?June 30, 2017 at 1:53 am #208502yashitamittal11MemberHello
#2 I changed the
padding: 0
in site-header, but it is still not working.
The value for padding werepadding: 28px 30px;
. I didn't find the value 8% for padding. So I changed this to 0.#1 I have added
z-index: 1
to nav.genesis-responsive-menu at line 2176 in style.css. But it still overlaps the content.June 30, 2017 at 5:44 am #208509Victor FontModeratorYou changed the site-header padding in the wrong place. It is defined in multiple places. Look in the media queries. Make sure you clear all caches so the browser picks up changes. Also make sure you use your browser's inspect tool to test the changes before you make them permanent. https://victorfont.com/how-to-use-your-browsers-inspect-tool/
Regards,
Victor
https://victorfont.com/
Call us toll free: 844-VIC-FONT (842-3668)
Have you requested your free website audit yet? -
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.