Created
November 18, 2013 22:45
-
-
Save exarcheia-web/7536746 to your computer and use it in GitHub Desktop.
Grid System - Demo
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
| /* Grid System - Demo */ | |
| * { | |
| box-sizing: border-box; | |
| } | |
| .site-header { | |
| background: hotpink; | |
| padding: 20px; | |
| } | |
| .site-container { | |
| background: rgba(0,0,0,0.2); | |
| width: 80%; | |
| margin: 60px auto 0; | |
| } | |
| .g-mother:after { | |
| content: ""; | |
| display: table; | |
| clear: both; | |
| } | |
| [class*="g-c"] { | |
| float: left; | |
| } | |
| [class*="g-c"]:last-of-type { | |
| border: none; | |
| } | |
| .box { | |
| height: 200px; | |
| background: rgba(255,0,0,0.3); | |
| margin-bottom: 1px; | |
| border-right: 1px solid white; | |
| } | |
| .g-c20 { | |
| width: 20%; | |
| } | |
| .g-c50 { | |
| width: 50%; | |
| } |
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
| <div class="site-container"> | |
| <header class="site-header"> | |
| <a href="#" class="site-logo">My logo</a> | |
| </header> | |
| <section class="g-mother"> | |
| <div class="box g-c20 g-mother"> | |
| <div class="box g-c50"></div> | |
| <div class="box g-c50"></div> | |
| </div> | |
| <div class="box g-c20"></div> | |
| <div class="box g-c20"></div> | |
| <div class="box g-c20"></div> | |
| <div class="box g-c20"></div> | |
| </section> | |
| </div> |
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
| // alert('Hello world!'); |
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
| {"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"css"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment