Archived topic
Different menu item padding for sticky menu
5 replies · Started by Erol on August 15, 2017
Hi I have set the menu items have 40px right and left padding for main nav but on sticky menu I am using logo image which pushes the menu items into a second line because of the padding between items. I cannot find the right selectors to reduce the padding-right and padding-left values for stciky menu so that all menu items are aligned in one line. Any help? Best regards
Hi there,
Try this CSS:
.main-navigation.navigation-stick .main-nav ul li a {
padding-left: 20px;
padding-right: 20px;
}
Adding CSS: https://docs.generatepress.com/article/adding-css/
Many thanks for quick help. Code helps but it does not work for menu items with child items :( Those with child items keep wide padding for right and left.
Please see url for dev site http://www.gma.presmultdemo.com/damages/fire-damage/
Try this CSS to change it for sticky navigation:
.main-navigation.navigation-stick .main-nav ul li.menu-item-has-children .dropdown-menu-toggle
padding-right: 10px;
}
It worked. Many thanks once again for prompt help :)
No problem!