-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpositioning.css
116 lines (109 loc) · 2.02 KB
/
positioning.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
/*limited reset*/
html, body, div, section, article, aside, header, hgroup, footer, nav, h1, h2, h3, h4, h5, h6, p, blockquote, address, time, span, em, strong, img, ol, ul, li, figure, canvas, video, th, td, tr {
margin: 0;
padding: 0;
border: 0;
vertical-align:baseline;
}
/*html5 display rule*/
address, article, aside, canvas, details, figcaption, figure, footer, header, hgroup, nav, menu, nav, section, summary {
display: block;
}
/* general styles */
body {
font-family: Georgia, sans-serif;
font-size: 96%;
}
ul {
list-style-type: none;
}
img {
border: 1px solid red;
}
/* header and main nav styles */
header {
position: fixed;
background-color: lightgrey;
width: 100%;
top: 0;
left: 0;
padding: 10px 20px;
}
header ul {
background-color: crimson;
text-align: center;
}
header li {
padding: 10px;
display: inline-block;
}
header a:link,
header a:visited,
header a:hover
header a:active {
color: white;
}
/* content wrapper */
#wrapper {
overflow:auto;
width: 960px;
margin: 120px auto 0;
padding: 10px 20px;
}
/* left nav column */
section:first-child {
padding: 10px;
float:left;
width: 186px;
}
/* The main section */
section + section {
width: 520px;
border: 1px solid darkgrey;
padding: 0 16px;
float:left;
}
section + section h2 {
padding:10px;
margin:0 -16px;
color:white;
background-color: lightgrey;
}
/* Article elements only appear in main section */
article {
clear: both;
}
article h3 {
padding-bottom:10px;
margin:24px 0;
color:grey;
border-bottom: 2px dashed darkgrey;
}
article p {
margin-bottom: 20px;
}
/* Images in first paragraph of article float left, otherwise right */
article p:first-of-type img {
float: left;
margin: 0 10px 10px 0;
}
article img {
float: right;
margin: 0 0 10px 10px;
}
/* right column */
aside {
padding: 10px;
margin-left: 20px;
width: 160px;
float:right;
background-color: lightblue;
}
aside h2, aside li {
margin-bottom: 24px;
}
footer {
margin-top: 24px;
padding: 10px;
text-align: center;
}