Created
June 1, 2017 04:44
-
-
Save andimariadi/3152da92017b0ffee8cc54fc7eec119d to your computer and use it in GitHub Desktop.
Header melayang
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| body{ | |
| margin: 0 auto; | |
| } | |
| .navigasi { | |
| background-color: #2980b9; | |
| position: fixed; | |
| width: 100%; | |
| height: 70px; | |
| top: 0; | |
| } | |
| .container { | |
| margin-top: 70px; | |
| padding: 15px; | |
| } | |
| nav a { | |
| color: #fff; | |
| font-size: 24px; | |
| text-decoration: none; | |
| } | |
| nav a:hover { | |
| text-decoration: none; | |
| } | |
| nav ul { | |
| list-style: none; | |
| } | |
| nav ul li { | |
| float: left; | |
| padding: 5px 20px; | |
| } | |
| nav ul li:hover { | |
| background-color: #FFF; | |
| border-radius: 5px; | |
| } | |
| nav ul li ul { | |
| display: none; | |
| list-style: none; | |
| margin-left: -20px; | |
| } | |
| nav ul li ul li { | |
| float: none; | |
| padding: 5px 20px; | |
| margin-left: -40px; | |
| } | |
| nav ul li ul li:hover { | |
| background-color: #DDD; | |
| border-radius: 0px; | |
| } | |
| nav ul li:hover > ul { | |
| display: block; | |
| position: absolute; | |
| background: #F1F1F1; | |
| } | |
| nav ul li:hover > ul a { | |
| color: #2980b9; | |
| } | |
| nav ul li:hover > a { | |
| color: #2980b9; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment