compass-h5bp 0.1.2 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,34 +1,23 @@
1
- $line-height: 1.4 !default;
2
1
  $font-color: #222 !default;
3
- $font-family: sans-serif !default;
4
2
  $font-size: 1em !default;
5
- $selected-font-color: #fff !default;
3
+ $line-height: 1.4 !default;
6
4
  $selected-background-color: #b3d4fc !default;
5
+ $hr-color: #ccc !default;
7
6
 
8
7
  @mixin h5bp-main {
9
8
  @include h5bp-base-styles;
10
- @include h5bp-chromeframe;
11
9
  }
12
10
 
13
- //
14
11
  // Base styles: opinionated defaults
15
- //
16
12
  @mixin h5bp-base-styles {
17
-
18
- html,
19
- button,
20
- input,
21
- select,
22
- textarea {
13
+ html {
23
14
  color: $font-color;
24
- }
25
-
26
- body {
27
15
  font-size: $font-size;
28
16
  line-height: $line-height;
29
17
  }
30
18
 
31
- // Remove text-shadow in selection highlight: h5bp.com/i
19
+ // Remove text-shadow in selection highlight:
20
+ // https://twitter.com/miketaylr/status/12228805301
32
21
  // These selection rule sets have to be separate.
33
22
  // Customize the background color to match your design.
34
23
  ::-moz-selection {
@@ -46,13 +35,20 @@ $selected-background-color: #b3d4fc !default;
46
35
  display: block;
47
36
  height: 1px;
48
37
  border: 0;
49
- border-top: 1px solid #ccc;
38
+ border-top: 1px solid $hr-color;
50
39
  margin: 1em 0;
51
40
  padding: 0;
52
41
  }
53
42
 
54
- // Remove the gap between images and the bottom of their containers: h5bp.com/i/440
55
- img {
43
+ // Remove the gap between audio, canvas, iframes,
44
+ // images, videos and the bottom of their containers:
45
+ // https://github.com/h5bp/html5-boilerplate/issues/440
46
+ audio,
47
+ canvas,
48
+ iframe,
49
+ img,
50
+ svg,
51
+ video {
56
52
  vertical-align: middle;
57
53
  }
58
54
 
@@ -68,16 +64,3 @@ $selected-background-color: #b3d4fc !default;
68
64
  resize: vertical;
69
65
  }
70
66
  }
71
-
72
- //
73
- // Chrome Frame Prompt
74
- //
75
-
76
- @mixin h5bp-chromeframe {
77
- .chromeframe {
78
- margin: 0.2em 0;
79
- background: #ccc;
80
- color: #000;
81
- padding: 0.2em 0;
82
- }
83
- }
@@ -1,6 +1,6 @@
1
1
  // Print styles
2
- // Inlined to avoid required HTTP connection: h5bp.com/r
3
-
2
+ // Inlined to avoid the additional HTTP request:
3
+ // http://www.phpied.com/delay-loading-your-print-css/
4
4
  @mixin h5bp-media {
5
5
  @media print {
6
6
  @include h5bp-media-print;
@@ -8,68 +8,69 @@
8
8
  }
9
9
 
10
10
  @mixin h5bp-media-print {
11
- * {
12
- background: transparent !important;
13
- color: #000 !important; // Black prints faster: h5bp.com/s
14
- box-shadow: none !important;
15
- text-shadow: none !important;
16
- }
11
+ @media print {
12
+ *,
13
+ *:before,
14
+ *:after {
15
+ background: transparent !important;
16
+ color: #000 !important; // Black prints faster:
17
+ // http://www.sanbeiji.com/archives/953
18
+ box-shadow: none !important;
19
+ text-shadow: none !important;
20
+ }
17
21
 
18
- a,
19
- a:visited {
20
- text-decoration: underline;
21
- }
22
+ a,
23
+ a:visited {
24
+ text-decoration: underline;
25
+ }
22
26
 
23
- a[href]:after {
24
- content: " (" attr(href) ")";
25
- }
27
+ a[href]:after {
28
+ content: " (" attr(href) ")";
29
+ }
26
30
 
27
- abbr[title]:after {
28
- content: " (" attr(title) ")";
29
- }
31
+ abbr[title]:after {
32
+ content: " (" attr(title) ")";
33
+ }
30
34
 
31
- //
32
- // Don't show links for images, or javascript/internal links
33
- //
35
+ // Don't show links that are fragment identifiers,
36
+ // or use the `javascript:` pseudo protocol
37
+ a[href^="#"]:after,
38
+ a[href^="javascript:"]:after {
39
+ content: "";
40
+ }
34
41
 
35
- .ir a:after,
36
- a[href^="javascript:"]:after,
37
- a[href^="#"]:after {
38
- content: "";
39
- }
42
+ pre,
43
+ blockquote {
44
+ border: 1px solid #999;
45
+ page-break-inside: avoid;
46
+ }
40
47
 
41
- pre,
42
- blockquote {
43
- border: 1px solid #999;
44
- page-break-inside: avoid;
45
- }
48
+ // Printing Tables:
49
+ // http://css-discuss.incutio.com/wiki/Printing_Tables
46
50
 
47
- thead {
48
- display: table-header-group; // h5bp.com/t
49
- }
50
-
51
- tr,
52
- img {
53
- page-break-inside: avoid;
54
- }
51
+ thead {
52
+ display: table-header-group;
53
+ }
55
54
 
56
- img {
57
- max-width: 100% !important;
58
- }
55
+ tr,
56
+ img {
57
+ page-break-inside: avoid;
58
+ }
59
59
 
60
- @page {
61
- margin: 0.5cm;
62
- }
60
+ img {
61
+ max-width: 100% !important;
62
+ }
63
63
 
64
- p,
65
- h2,
66
- h3 {
67
- orphans: 3;
68
- widows: 3;
69
- }
64
+ p,
65
+ h2,
66
+ h3 {
67
+ orphans: 3;
68
+ widows: 3;
69
+ }
70
70
 
71
- h2,
72
- h3 {
73
- page-break-after: avoid;
71
+ h2,
72
+ h3 {
73
+ page-break-after: avoid;
74
+ }
74
75
  }
75
76
  }
@@ -1,24 +1,38 @@
1
- //
2
- // Normalize v1.1.1 | MIT License | git.io/normalize
3
- //
4
-
1
+ // normalize.css v3.0.2 | MIT License | git.io/normalize
5
2
  @mixin h5bp-normalize {
6
- @include h5bp-display;
7
- @include h5bp-base;
8
- @include h5bp-links;
9
- @include h5bp-typography;
10
- @include h5bp-lists;
11
- @include h5bp-embeds;
12
- @include h5bp-figures;
13
- @include h5bp-forms;
14
- @include h5bp-tables;
3
+ @include normalize-base;
4
+ @include normalize-display;
5
+ @include normalize-links;
6
+ @include normalize-semantics;
7
+ @include normalize-embedded;
8
+ @include normalize-grouping;
9
+ @include normalize-forms;
10
+ @include normalize-tables;
15
11
  }
16
12
 
13
+ // Base
14
+ @mixin normalize-base {
15
+ // 1. Set default font family to sans-serif.
16
+ // 2. Prevent iOS text size adjust after orientation change, without
17
+ // disabling user zoom.
18
+ html {
19
+ font-family: sans-serif; // 1
20
+ -ms-text-size-adjust: 100%; // 2
21
+ -webkit-text-size-adjust: 100%; // 2
22
+ }
23
+ // Remove default margin.
24
+ body {
25
+ margin: 0;
26
+ }
17
27
 
18
- // Html5 display definitions
19
- @mixin h5bp-display {
28
+ }
20
29
 
21
- // Correct `block` display not defined in IE 6/7/8/9 and Firefox 3.
30
+ // HTML5 display definitions
31
+ @mixin normalize-display {
32
+ // Correct `block` display not defined for any HTML5 element in IE 8/9.
33
+ // Correct `block` display not defined for `details` or `summary` in IE 10/11
34
+ // and Firefox.
35
+ // Correct `block` display not defined for `main` in IE 11.
22
36
  article,
23
37
  aside,
24
38
  details,
@@ -28,422 +42,284 @@
28
42
  header,
29
43
  hgroup,
30
44
  main,
45
+ menu,
31
46
  nav,
32
47
  section,
33
48
  summary {
34
- display: block;
49
+ display: block;
35
50
  }
36
51
 
37
- // Correct `inline-block` display not defined in IE 6/7/8/9 and Firefox 3.
52
+ // 1. Correct `inline-block` display not defined in IE 8/9.
53
+ // 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
38
54
  audio,
39
55
  canvas,
56
+ progress,
40
57
  video {
41
- display: inline-block;
42
- *display: inline;
43
- *zoom: 1;
58
+ display: inline-block; // 1
59
+ vertical-align: baseline; // 2
44
60
  }
45
61
 
46
62
  // Prevent modern browsers from displaying `audio` without controls.
47
63
  // Remove excess height in iOS 5 devices.
48
64
  audio:not([controls]) {
49
- display: none;
50
- height: 0;
51
- }
52
-
53
- // Address styling not present in IE 7/8/9, Firefox 3, and Safari 4.
54
- // Known issue: no IE 6 support.
55
- [hidden] {
56
- display: none;
57
- }
58
-
59
- }
60
-
61
-
62
- // Base
63
- @mixin h5bp-base {
64
-
65
- // 1. Correct text resizing oddly in IE 6/7 when body `font-size` is set using
66
- // `em` units.
67
- // 2. Prevent iOS text size adjust after orientation change, without disabling
68
- // user zoom.
69
- // 1. Prevent system color scheme's background color being used in Firefox, IE,
70
- // and Opera.
71
- // 2. Prevent system color scheme's text color being used in Firefox, IE, and
72
- // Opera.
73
- // 3. Correct text resizing oddly in IE 6/7 when body `font-size` is set using
74
- // `em` units.
75
- // 4. Prevent iOS text size adjust after orientation change, without disabling
76
- // user zoom.
77
- html {
78
- background: #fff; // 1
79
- color: #000; // 2
80
- font-size: 100%; // 3
81
- -webkit-text-size-adjust: 100%; // 4
82
- -ms-text-size-adjust: 100%; // 4
83
- }
84
-
85
- // Address `font-family` inconsistency between `textarea` and other form
86
- // elements.
87
-
88
- html,
89
- button,
90
- input,
91
- select,
92
- textarea {
93
- font-family: sans-serif;
65
+ display: none;
66
+ height: 0;
94
67
  }
95
68
 
96
- // Address margins handled incorrectly in IE 6/7.
97
-
98
- body {
99
- margin: 0;
69
+ // Address `[hidden]` styling not present in IE 8/9/10.
70
+ // Hide the `template` element in IE 8/9/11, Safari, and Firefox < 22.
71
+ [hidden],
72
+ template {
73
+ display: none;
100
74
  }
101
-
102
- }
103
-
104
- // Deprecation
105
- @mixin h5bp-selection {
106
- @warn "The selection mixin has been removed. The selection code is in the h5bp-base-styles mixin starting with Boilerplate version 4.0.";
107
75
  }
108
76
 
109
77
  // Links
110
- @mixin h5bp-links {
111
-
112
- // Address `outline` inconsistency between Chrome and other browsers.
113
- a:focus {
114
- outline: thin dotted;
78
+ @mixin normalize-links {
79
+ // Remove the gray background color from active links in IE 10.
80
+ a {
81
+ background-color: transparent;
115
82
  }
116
83
 
117
84
  // Improve readability when focused and also mouse hovered in all browsers.
118
85
  a:active,
119
86
  a:hover {
120
- outline: 0;
87
+ outline: 0;
121
88
  }
122
-
123
89
  }
124
90
 
125
-
126
- // Typography
127
- @mixin h5bp-typography {
128
-
129
- // Address font sizes and margins set differently in IE 6/7.
130
- // Address font sizes within `section` and `article` in Firefox 4+, Safari 5,
131
- // and Chrome.
132
- h1 {
133
- font-size: 2em;
134
- margin: 0.67em 0;
135
- }
136
-
137
- h2 {
138
- font-size: 1.5em;
139
- margin: 0.83em 0;
140
- }
141
-
142
- h3 {
143
- font-size: 1.17em;
144
- margin: 1em 0;
145
- }
146
-
147
- h4 {
148
- font-size: 1em;
149
- margin: 1.33em 0;
150
- }
151
-
152
- h5 {
153
- font-size: 0.83em;
154
- margin: 1.67em 0;
155
- }
156
-
157
- h6 {
158
- font-size: 0.67em;
159
- margin: 2.33em 0;
160
- }
161
-
162
- // Address styling not present in IE 7/8/9, Safari 5, and Chrome.
91
+ // Text-level semantics
92
+ @mixin normalize-semantics {
93
+ // Address styling not present in IE 8/9/10/11, Safari, and Chrome.
163
94
  abbr[title] {
164
- border-bottom: 1px dotted;
95
+ border-bottom: 1px dotted;
165
96
  }
166
97
 
167
- // Address style set to `bolder` in Firefox 3+, Safari 4/5, and Chrome.
98
+ // Address style set to `bolder` in Firefox 4+, Safari, and Chrome.
168
99
  b,
169
100
  strong {
170
- font-weight: bold;
171
- }
172
-
173
- blockquote {
174
- margin: 1em 40px;
101
+ font-weight: bold;
175
102
  }
176
103
 
177
- // Address styling not present in Safari 5 and Chrome.
104
+ // Address styling not present in Safari and Chrome.
178
105
  dfn {
179
- font-style: italic;
106
+ font-style: italic;
180
107
  }
181
108
 
182
- // Address differences between Firefox and other browsers.
183
- // Known issue: no IE 6/7 normalization.
184
- hr {
185
- -moz-box-sizing: content-box;
186
- box-sizing: content-box;
187
- height: 0;
109
+ // Address variable `h1` font-size and margin within `section` and `article`
110
+ // contexts in Firefox 4+, Safari, and Chrome.
111
+ h1 {
112
+ font-size: 2em;
113
+ margin: 0.67em 0;
188
114
  }
189
115
 
190
- // Address styling not present in IE 6/7/8/9.
116
+ // Address styling not present in IE 8/9.
191
117
  mark {
192
- background: #ff0;
193
- color: #000;
194
- }
195
-
196
- // Address margins set differently in IE 6/7.
197
- p,
198
- pre {
199
- margin: 1em 0;
200
- }
201
-
202
- // Correct font family set oddly in IE 6, Safari 4/5, and Chrome.
203
- code,
204
- kbd,
205
- pre,
206
- samp {
207
- font-family: monospace, serif;
208
- _font-family: 'courier new', monospace;
209
- font-size: 1em;
210
- }
211
-
212
- // Improve readability of pre-formatted text in all browsers.
213
- pre {
214
- white-space: pre;
215
- white-space: pre-wrap;
216
- word-wrap: break-word;
217
- }
218
-
219
- // Address CSS quotes not supported in IE 6/7.
220
- q {
221
- quotes: none;
222
- }
223
-
224
- // Address `quotes` property not supported in Safari 4.
225
- q:before,
226
- q:after {
227
- content: '';
228
- content: none;
118
+ background: #ff0;
119
+ color: #000;
229
120
  }
230
121
 
231
122
  // Address inconsistent and variable font size in all browsers.
232
123
  small {
233
- font-size: 80%;
124
+ font-size: 80%;
234
125
  }
235
126
 
236
127
  // Prevent `sub` and `sup` affecting `line-height` in all browsers.
237
128
  sub,
238
129
  sup {
239
- font-size: 75%;
240
- line-height: 0;
241
- position: relative;
242
- vertical-align: baseline;
130
+ font-size: 75%;
131
+ line-height: 0;
132
+ position: relative;
133
+ vertical-align: baseline;
243
134
  }
244
135
 
245
136
  sup {
246
- top: -0.5em;
137
+ top: -0.5em;
247
138
  }
248
139
 
249
140
  sub {
250
- bottom: -0.25em;
251
- }
252
-
253
- }
254
-
255
-
256
- // Lists
257
- @mixin h5bp-lists {
258
-
259
- // Address margins set differently in IE 6/7.
260
- dl,
261
- menu,
262
- ol,
263
- ul {
264
- margin: 1em 0;
265
- }
266
-
267
- dd {
268
- margin: 0 0 0 40px;
269
- }
270
-
271
- // Address paddings set differently in IE 6/7.
272
- menu,
273
- ol,
274
- ul {
275
- padding: 0 0 0 40px;
276
- }
277
-
278
- // Correct list images handled incorrectly in IE 7.
279
- nav ul,
280
- nav ol {
281
- list-style: none;
282
- list-style-image: none;
141
+ bottom: -0.25em;
283
142
  }
284
-
285
143
  }
286
144
 
287
-
288
145
  // Embedded content
289
- @mixin h5bp-embeds {
290
-
291
- // 1. Remove border when inside `a` element in IE 6/7/8/9 and Firefox 3.
292
- // 2. Improve image quality when scaled in IE 7.
146
+ @mixin normalize-embedded {
147
+ // Remove border when inside `a` element in IE 8/9/10.
293
148
  img {
294
- border: 0; // 1
295
- -ms-interpolation-mode: bicubic; // 2
149
+ border: 0;
296
150
  }
297
151
 
298
- // Correct overflow displayed oddly in IE 9.
152
+ // Correct overflow not hidden in IE 9/10/11.
299
153
  svg:not(:root) {
300
- overflow: hidden;
154
+ overflow: hidden;
301
155
  }
302
-
303
156
  }
304
157
 
305
-
306
- // Figures
307
- @mixin h5bp-figures {
308
-
309
- // Address margin not present in IE 6/7/8/9, Safari 5, and Opera 11.
158
+ // Grouping content
159
+ @mixin normalize-grouping {
160
+ // Address margin not present in IE 8/9 and Safari.
310
161
  figure {
311
- margin: 0;
162
+ margin: 1em 40px;
312
163
  }
313
164
 
314
- }
315
-
316
-
317
- // Forms
318
- @mixin h5bp-forms {
319
-
320
- // Correct margin displayed oddly in IE 6/7.
321
- form {
322
- margin: 0;
165
+ // Address differences between Firefox and other browsers.
166
+ hr {
167
+ -moz-box-sizing: content-box;
168
+ box-sizing: content-box;
169
+ height: 0;
323
170
  }
324
171
 
325
- // Define consistent border, margin, and padding.
326
- fieldset {
327
- border: 1px solid #c0c0c0;
328
- margin: 0 2px;
329
- padding: 0.35em 0.625em 0.75em;
172
+ // Contain overflow in all browsers.
173
+ pre {
174
+ overflow: auto;
330
175
  }
331
176
 
332
- // 1. Correct color not being inherited in IE 6/7/8/9.
333
- // 2. Correct text not wrapping in Firefox 3.
334
- // 3. Correct alignment displayed oddly in IE 6/7.
335
- legend {
336
- border: 0; // 1
337
- padding: 0;
338
- white-space: normal; // 2
339
- *margin-left: -7px; // 3
177
+ // Address odd `em`-unit font size rendering in all browsers.
178
+ code,
179
+ kbd,
180
+ pre,
181
+ samp {
182
+ font-family: monospace, monospace;
183
+ font-size: 1em;
340
184
  }
185
+ }
341
186
 
342
- // 1. Correct font size not being inherited in all browsers.
343
- // 2. Address margins set differently in IE 6/7, Firefox 3+, Safari 5,
344
- // and Chrome.
345
- // 3. Improve appearance and consistency in all browsers.
187
+ // Forms
188
+ @mixin normalize-forms {
189
+ // Known limitation: by default, Chrome and Safari on OS X allow very limited
190
+ // styling of `select`, unless a `border` property is set.
191
+ // 1. Correct color not being inherited.
192
+ // Known issue: affects color of disabled elements.
193
+ // 2. Correct font properties not being inherited.
194
+ // 3. Address margins set differently in Firefox 4+, Safari, and Chrome.
346
195
  button,
347
196
  input,
197
+ optgroup,
348
198
  select,
349
199
  textarea {
350
- font-size: 100%; // 1
351
- margin: 0; // 2
352
- vertical-align: baseline; // 3
353
- *vertical-align: middle; // 3
200
+ color: inherit; // 1
201
+ font: inherit; // 2
202
+ margin: 0; // 3
354
203
  }
355
204
 
356
- // Address Firefox 3+ setting `line-height` on `input` using `!important` in
357
- // the UA stylesheet.
358
- button,
359
- input {
360
- line-height: normal;
205
+ // Address `overflow` set to `hidden` in IE 8/9/10/11.
206
+ button {
207
+ overflow: visible;
361
208
  }
362
209
 
363
210
  // Address inconsistent `text-transform` inheritance for `button` and `select`.
364
211
  // All other form control elements do not inherit `text-transform` values.
365
- // Correct `button` style inheritance in Chrome, Safari 5+, and IE 6+.
366
- // Correct `select` style inheritance in Firefox 4+ and Opera.
212
+ // Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera.
213
+ // Correct `select` style inheritance in Firefox.
367
214
  button,
368
215
  select {
369
- text-transform: none;
216
+ text-transform: none;
370
217
  }
371
218
 
372
219
  // 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
373
- // and `video` controls.
220
+ // and `video` controls.
374
221
  // 2. Correct inability to style clickable `input` types in iOS.
375
222
  // 3. Improve usability and consistency of cursor style between image-type
376
- // `input` and others.
377
- // 4. Remove inner spacing in IE 7 without affecting normal text inputs.
378
- // Known issue: inner spacing remains in IE 6.
223
+ // `input` and others.
379
224
  button,
380
225
  html input[type="button"], // 1
381
226
  input[type="reset"],
382
227
  input[type="submit"] {
383
- -webkit-appearance: button; // 2
384
- cursor: pointer; // 3
385
- *overflow: visible; // 4
228
+ -webkit-appearance: button; // 2
229
+ cursor: pointer; // 3
386
230
  }
387
231
 
388
232
  // Re-set default cursor for disabled elements.
389
233
  button[disabled],
390
234
  html input[disabled] {
391
- cursor: default;
235
+ cursor: default;
236
+ }
237
+
238
+ // Remove inner padding and border in Firefox 4+.
239
+ button::-moz-focus-inner,
240
+ input::-moz-focus-inner {
241
+ border: 0;
242
+ padding: 0;
243
+ }
244
+
245
+ // Address Firefox 4+ setting `line-height` on `input` using `!important` in
246
+ // the UA stylesheet.
247
+ input {
248
+ line-height: normal;
392
249
  }
393
250
 
394
- // 1. Address box sizing set to content-box in IE 8/9.
395
- // 2. Remove excess padding in IE 8/9.
396
- // 3. Remove excess padding in IE 7.
397
- // Known issue: excess padding remains in IE 6.
251
+ // It's recommended that you don't attempt to style these elements.
252
+ // Firefox's implementation doesn't respect box-sizing, padding, or width.
253
+ // 1. Address box sizing set to `content-box` in IE 8/9/10.
254
+ // 2. Remove excess padding in IE 8/9/10.
398
255
  input[type="checkbox"],
399
256
  input[type="radio"] {
400
- box-sizing: border-box; // 1
401
- padding: 0; // 2
402
- *height: 13px; // 3
403
- *width: 13px; // 3
257
+ box-sizing: border-box; // 1
258
+ padding: 0; // 2
259
+ }
260
+
261
+ // Fix the cursor style for Chrome's increment/decrement buttons. For certain
262
+ // `font-size` values of the `input`, it causes the cursor style of the
263
+ // decrement button to change from `default` to `text`.
264
+ input[type="number"]::-webkit-inner-spin-button,
265
+ input[type="number"]::-webkit-outer-spin-button {
266
+ height: auto;
404
267
  }
405
268
 
406
- // 1. Address `appearance` set to `searchfield` in Safari 5 and Chrome.
407
- // 2. Address `box-sizing` set to `border-box` in Safari 5 and Chrome
408
- // (include `-moz` to future-proof).
269
+ // 1. Address `appearance` set to `searchfield` in Safari and Chrome.
270
+ // 2. Address `box-sizing` set to `border-box` in Safari and Chrome
271
+ // (include `-moz` to future-proof).
409
272
  input[type="search"] {
410
- -webkit-appearance: textfield; // 1
411
- -moz-box-sizing: content-box;
412
- -webkit-box-sizing: content-box; // 2
413
- box-sizing: content-box;
273
+ -webkit-appearance: textfield; /* 1 */
274
+ -moz-box-sizing: content-box;
275
+ -webkit-box-sizing: content-box; /* 2 */
276
+ box-sizing: content-box;
414
277
  }
415
278
 
416
- // Remove inner padding and search cancel button in Safari 5 and Chrome
417
- // on OS X.
279
+ // Remove inner padding and search cancel button in Safari and Chrome on OS X.
280
+ // Safari (but not Chrome) clips the cancel button when the search input has
281
+ // padding (and `textfield` appearance).
418
282
  input[type="search"]::-webkit-search-cancel-button,
419
283
  input[type="search"]::-webkit-search-decoration {
420
- -webkit-appearance: none;
284
+ -webkit-appearance: none;
421
285
  }
422
286
 
423
- // Remove inner padding and border in Firefox 3+.
424
- button::-moz-focus-inner,
425
- input::-moz-focus-inner {
426
- border: 0;
427
- padding: 0;
287
+ // Define consistent border, margin, and padding.
288
+ fieldset {
289
+ border: 1px solid #c0c0c0;
290
+ margin: 0 2px;
291
+ padding: 0.35em 0.625em 0.75em;
292
+ }
293
+
294
+ // 1. Correct `color` not being inherited in IE 8/9/10/11.
295
+ // 2. Remove padding so people aren't caught out if they zero out fieldsets.
296
+ legend {
297
+ border: 0; /* 1 */
298
+ padding: 0; /* 2 */
428
299
  }
429
300
 
430
- // 1. Remove default vertical scrollbar in IE 6/7/8/9.
431
- // 2. Improve readability and alignment in all browsers.
301
+ // Remove default vertical scrollbar in IE 8/9/10/11.
432
302
  textarea {
433
- overflow: auto; // 1
434
- vertical-align: top; // 2
303
+ overflow: auto;
435
304
  }
436
305
 
306
+ // Don't inherit the `font-weight` (applied by a rule above).
307
+ // NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
308
+ optgroup {
309
+ font-weight: bold;
310
+ }
437
311
  }
438
312
 
439
-
440
313
  // Tables
441
- @mixin h5bp-tables {
442
-
314
+ @mixin normalize-tables {
443
315
  // Remove most spacing between table cells.
444
316
  table {
445
- border-collapse: collapse;
446
- border-spacing: 0;
317
+ border-collapse: collapse;
318
+ border-spacing: 0;
447
319
  }
448
320
 
321
+ td,
322
+ th {
323
+ padding: 0;
324
+ }
449
325
  }