Can't center-align navigation menu in theme Mystile
-
Hi,
Site: https://www.allihop.dk
I have successfully centered the main nav menu by creating a “Child theme” and adding the following in a style.css file:
/* Theme Name: Mystile Child Theme URI: https://example.com/twenty-thirteen-child/ Description: Mystile Theme Author: None Author URI: https://example.com Template: mystile Version: 1.0.0 */ /* =Imports styles from the parent theme -------------------------------------------------------------- */ @import url('../mystile/style.css'); /* =Theme customization starts here -------------------------------------------------------------- */ #header hgroup { float: none !important; text-align: center; } #header #logo { float: none; } #header #navigation, #header #navigation ul.nav { float: none !important; } #header #navigation { margin: 0 auto !important; } #header .nav-toggle { position: relative; margin-left: auto; margin-right: auto; }
This worked just fine from the start, but now the menu is again aligned to the left. I have fiddled around in the css sheets on main theme and perhaps i have come to undo something…
I also have added the following in main themse “custom.css” file:
/* Desktop styles go here */ @media only screen and (min-width: 767px) { #primary-menu ul { display: table !important; } }
Thanks in advance,
//Daniel
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Can't center-align navigation menu in theme Mystile’ is closed to new replies.