|
| 1 | +/* |
| 2 | + * HTML5 Boilerplate |
| 3 | + * |
| 4 | + * What follows is the result of much research on cross-browser styling. |
| 5 | + * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal, |
| 6 | + * Kroc Camen, and the H5BP dev community and team. |
| 7 | + */ |
| 8 | + |
| 9 | + |
| 10 | +/* ============================================================================= |
| 11 | + HTML5 element display |
| 12 | + ========================================================================== */ |
| 13 | + |
| 14 | +article, aside, details, figcaption, figure, footer, header, hgroup, nav, section { display: block; } |
| 15 | +audio[controls], canvas, video { display: inline-block; *display: inline; *zoom: 1; } |
| 16 | + |
| 17 | + |
| 18 | +/* ============================================================================= |
| 19 | + Base |
| 20 | + ========================================================================== */ |
| 21 | + |
| 22 | +/* |
| 23 | + * 1. Correct text resizing oddly in IE6/7 when body font-size is set using em units |
| 24 | + * http://clagnut.com/blog/348/#c790 |
| 25 | + * 2. Force vertical scrollbar in non-IE |
| 26 | + * 3. Remove Android and iOS tap highlight color to prevent entire container being highlighted |
| 27 | + * www.yuiblog.com/blog/2010/10/01/quick-tip-customizing-the-mobile-safari-tap-highlight-color/ |
| 28 | + * 4. Prevent iOS text size adjust on device orientation change, without disabling user zoom |
| 29 | + * www.456bereastreet.com/archive/201012/controlling_text_size_in_safari_for_ios_without_disabling_user_zoom/ |
| 30 | + */ |
| 31 | + |
| 32 | +html { font-size: 100%; overflow-y: scroll; -webkit-overflow-scrolling: touch; -webkit-tap-highlight-color: rgba(0,0,0,0); -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; } |
| 33 | + |
| 34 | +body { margin: 0; font-size: 13px; line-height: 1.231; } |
| 35 | + |
| 36 | +body, button, input, select, textarea { font-family: sans-serif; color: #222; } |
| 37 | + |
| 38 | +/* |
| 39 | + * These selection declarations have to be separate |
| 40 | + * No text-shadow: twitter.com/miketaylr/status/12228805301 |
| 41 | + * Also: hot pink! |
| 42 | + */ |
| 43 | + |
| 44 | +::-moz-selection { background: #fe57a1; color: #fff; text-shadow: none; } |
| 45 | +::selection { background: #fe57a1; color: #fff; text-shadow: none; } |
| 46 | + |
| 47 | + |
| 48 | +/* ============================================================================= |
| 49 | + Links |
| 50 | + ========================================================================== */ |
| 51 | + |
| 52 | +a { color: #00e; } |
| 53 | +a:visited { color: #551a8b; } |
| 54 | +a:focus { outline: thin dotted; } |
| 55 | + |
| 56 | +/* Improve readability when focused and hovered in all browsers: people.opera.com/patrickl/experiments/keyboard/test */ |
| 57 | +a:hover, a:active { outline: 0; } |
| 58 | + |
| 59 | + |
| 60 | +/* ============================================================================= |
| 61 | + Typography |
| 62 | + ========================================================================== */ |
| 63 | + |
| 64 | +abbr[title] { border-bottom: 1px dotted; } |
| 65 | + |
| 66 | +b, strong { font-weight: bold; } |
| 67 | + |
| 68 | +blockquote { margin: 1em 40px; } |
| 69 | + |
| 70 | +dfn { font-style: italic; } |
| 71 | + |
| 72 | +hr { display: block; height: 1px; border: 0; border-top: 1px solid #ccc; margin: 1em 0; padding: 0; } |
| 73 | + |
| 74 | +ins { background: #ff9; color: #000; text-decoration: none; } |
| 75 | + |
| 76 | +mark { background: #ff0; color: #000; font-style: italic; font-weight: bold; } |
| 77 | + |
| 78 | +/* Redeclare monospace font family: en.wikipedia.org/wiki/User:Davidgothberg/Test59 */ |
| 79 | +pre, code, kbd, samp { font-family: monospace, monospace; _font-family: 'courier new', monospace; font-size: 1em; } |
| 80 | + |
| 81 | +/* Improve readability of pre-formatted text in all browsers */ |
| 82 | +pre { white-space: pre; white-space: pre-wrap; word-wrap: break-word; } |
| 83 | + |
| 84 | +q { quotes: none; } |
| 85 | +q:before, q:after { content: ""; content: none; } |
| 86 | + |
| 87 | +small { font-size: 85%; } |
| 88 | + |
| 89 | +/* Position subscript and superscript content without affecting line-height: gist.github.com/413930 */ |
| 90 | +sub, sup { font-size: 75%; line-height: 0; position: relative; vertical-align: baseline; } |
| 91 | +sup { top: -0.5em; } |
| 92 | +sub { bottom: -0.25em; } |
| 93 | + |
| 94 | + |
| 95 | +/* ============================================================================= |
| 96 | + Lists |
| 97 | + ========================================================================== */ |
| 98 | + |
| 99 | +ul, ol { margin: 1em 0; padding: 0 0 0 40px; } |
| 100 | +dd { margin: 0 0 0 40px; } |
| 101 | +nav ul, nav ol { list-style: none; margin: 0; padding: 0; } |
| 102 | + |
| 103 | + |
| 104 | +/* ============================================================================= |
| 105 | + Embedded content |
| 106 | + ========================================================================== */ |
| 107 | + |
| 108 | +/* |
| 109 | + * Improve image quality when scaled in IE7 |
| 110 | + * code.flickr.com/blog/2008/11/12/on-ui-quality-the-little-things-client-side-image-resizing/ |
| 111 | + */ |
| 112 | + |
| 113 | +img { border: 0; -ms-interpolation-mode: bicubic; } |
| 114 | + |
| 115 | +/* |
| 116 | + * Correct overflow displayed oddly in IE9 |
| 117 | + */ |
| 118 | + |
| 119 | +svg:not(:root) { |
| 120 | + overflow: hidden; |
| 121 | +} |
| 122 | + |
| 123 | + |
| 124 | +/* ============================================================================= |
| 125 | + Figures |
| 126 | + ========================================================================== */ |
| 127 | + |
| 128 | +figure { margin: 0; } |
| 129 | + |
| 130 | + |
| 131 | +/* ============================================================================= |
| 132 | + Forms |
| 133 | + ========================================================================== */ |
| 134 | + |
| 135 | +form { margin: 0; } |
| 136 | +fieldset { border: 0; margin: 0; padding: 0; } |
| 137 | + |
| 138 | +/* |
| 139 | + * 1. Correct color not inheriting in IE6/7/8/9 |
| 140 | + * 2. Correct alignment displayed oddly in IE6/7 |
| 141 | + */ |
| 142 | + |
| 143 | +legend { border: 0; *margin-left: -7px; padding: 0; } |
| 144 | + |
| 145 | +/* Indicate that 'label' will shift focus to the associated form element */ |
| 146 | +label { cursor: pointer; } |
| 147 | + |
| 148 | +/* |
| 149 | + * 1. Correct font-size not inheriting in all browsers |
| 150 | + * 2. Remove margins in FF3/4 S5 Chrome |
| 151 | + * 3. Define consistent vertical alignment display in all browsers |
| 152 | + */ |
| 153 | + |
| 154 | +button, input, select, textarea { font-size: 100%; margin: 0; vertical-align: baseline; *vertical-align: middle; } |
| 155 | + |
| 156 | +/* |
| 157 | + * 1. Define line-height as normal to match FF3/4 (set using !important in the UA stylesheet) |
| 158 | + * 2. Correct inner spacing displayed oddly in IE6/7 |
| 159 | + */ |
| 160 | + |
| 161 | +button, input { line-height: normal; *overflow: visible; } |
| 162 | + |
| 163 | +/* |
| 164 | + * 1. Display hand cursor for clickable form elements |
| 165 | + * 2. Allow styling of clickable form elements in iOS |
| 166 | + */ |
| 167 | + |
| 168 | +button, input[type="button"], input[type="reset"], input[type="submit"] { cursor: pointer; -webkit-appearance: button; } |
| 169 | + |
| 170 | +/* |
| 171 | + * Consistent box sizing and appearance |
| 172 | + */ |
| 173 | + |
| 174 | +input[type="checkbox"], input[type="radio"] { box-sizing: border-box; } |
| 175 | +input[type="search"] { -moz-box-sizing: content-box; -webkit-box-sizing: content-box; box-sizing: content-box; } |
| 176 | + |
| 177 | +/* |
| 178 | + * Remove inner padding and border in FF3/4 |
| 179 | + * www.sitepen.com/blog/2008/05/14/the-devils-in-the-details-fixing-dojos-toolbar-buttons/ |
| 180 | + */ |
| 181 | + |
| 182 | +button::-moz-focus-inner, input::-moz-focus-inner { border: 0; padding: 0; } |
| 183 | + |
| 184 | +/* Remove default vertical scrollbar in IE6/7/8/9 */ |
| 185 | +textarea { overflow: auto; vertical-align: top; } |
| 186 | + |
| 187 | +/* Colors for form validity */ |
| 188 | +input:valid, textarea:valid { } |
| 189 | +input:invalid, textarea:invalid { background-color: #f0dddd; } |
| 190 | + |
| 191 | + |
| 192 | +/* ============================================================================= |
| 193 | + Tables |
| 194 | + ========================================================================== */ |
| 195 | + |
| 196 | +table { border-collapse: collapse; border-spacing: 0; } |
| 197 | + |
| 198 | + |
| 199 | +/* ============================================================================= |
| 200 | + Primary styles |
| 201 | + Author: |
| 202 | + ========================================================================== */ |
| 203 | +body { |
| 204 | + background: #ebebeb; |
| 205 | +} |
| 206 | + |
| 207 | +#container { |
| 208 | + width: 960px; |
| 209 | + margin: auto; |
| 210 | + min-height: 500px; |
| 211 | + background: #fff; |
| 212 | +} |
| 213 | +#menu { |
| 214 | + background: #444; |
| 215 | + height: 30px; color: #fff; text-align: right; |
| 216 | +} |
| 217 | +#menu ul { |
| 218 | + list-style: none; |
| 219 | + margin: 0; padding: 0; |
| 220 | +} |
| 221 | +#menu ul li { |
| 222 | + float: left; |
| 223 | + margin-left: 10px; |
| 224 | +} |
| 225 | +#menu ul li a { |
| 226 | + color: #fff; |
| 227 | + line-height: 30px; |
| 228 | + text-decoration: none; |
| 229 | +} |
| 230 | +#menu ul li a:hover { |
| 231 | + color: #ccc; |
| 232 | +} |
| 233 | +#header { |
| 234 | + |
| 235 | +} |
| 236 | +#page { |
| 237 | + border-top: 1px solid #ebebeb; |
| 238 | + border-bottom: 1px solid #ebebeb; |
| 239 | + min-height: 400px; |
| 240 | +} |
| 241 | + |
| 242 | +#footer { |
| 243 | + text-align: center; |
| 244 | +} |
| 245 | +/* ============================================================================= |
| 246 | + Non-semantic helper classes |
| 247 | + Please define your styles before this section. |
| 248 | + ========================================================================== */ |
| 249 | + |
| 250 | +/* For image replacement */ |
| 251 | +.ir { display: block; text-indent: -999em; overflow: hidden; background-repeat: no-repeat; text-align: left; direction: ltr; } |
| 252 | +.ir br { display: none; } |
| 253 | + |
| 254 | +/* Hide for both screenreaders and browsers: |
| 255 | + css-discuss.incutio.com/wiki/Screenreader_Visibility */ |
| 256 | +.hidden { display: none; visibility: hidden; } |
| 257 | + |
| 258 | +/* Hide only visually, but have it available for screenreaders: by Jon Neal. |
| 259 | + www.webaim.org/techniques/css/invisiblecontent/ & j.mp/visuallyhidden */ |
| 260 | +.visuallyhidden { border: 0; clip: rect(0 0 0 0); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; } |
| 261 | + |
| 262 | +/* Extends the .visuallyhidden class to allow the element to be focusable when navigated to via the keyboard: drupal.org/node/897638 */ |
| 263 | +.visuallyhidden.focusable:active, .visuallyhidden.focusable:focus { clip: auto; height: auto; margin: 0; overflow: visible; position: static; width: auto; } |
| 264 | + |
| 265 | +/* Hide visually and from screenreaders, but maintain layout */ |
| 266 | +.invisible { visibility: hidden; } |
| 267 | + |
| 268 | +/* Contain floats: nicolasgallagher.com/micro-clearfix-hack/ */ |
| 269 | +.clearfix:before, .clearfix:after { content: ""; display: table; } |
| 270 | +.clearfix:after { clear: both; } |
| 271 | +.clearfix { zoom: 1; } |
| 272 | + |
| 273 | + |
| 274 | + |
| 275 | +/* ============================================================================= |
| 276 | + PLACEHOLDER Media Queries for Responsive Design. |
| 277 | + These override the primary ('mobile first') styles |
| 278 | + Modify as content requires. |
| 279 | + ========================================================================== */ |
| 280 | + |
| 281 | +@media only screen and (min-width: 480px) { |
| 282 | + /* Style adjustments for viewports 480px and over go here */ |
| 283 | + |
| 284 | +} |
| 285 | + |
| 286 | +@media only screen and (min-width: 768px) { |
| 287 | + /* Style adjustments for viewports 768px and over go here */ |
| 288 | + |
| 289 | +} |
| 290 | + |
| 291 | + |
| 292 | +/* ============================================================================= |
| 293 | + Print styles. |
| 294 | + Inlined to avoid required HTTP connection: www.phpied.com/delay-loading-your-print-css/ |
| 295 | + ========================================================================== */ |
| 296 | + |
| 297 | +@media print { |
| 298 | + * { background: transparent !important; color: black !important; text-shadow: none !important; filter:none !important; -ms-filter: none !important; } /* Black prints faster: sanbeiji.com/archives/953 */ |
| 299 | + a, a:visited { color: #444 !important; text-decoration: underline; } |
| 300 | + a[href]:after { content: " (" attr(href) ")"; } |
| 301 | + abbr[title]:after { content: " (" attr(title) ")"; } |
| 302 | + .ir a:after, a[href^="javascript:"]:after, a[href^="#"]:after { content: ""; } /* Don't show links for images, or javascript/internal links */ |
| 303 | + pre, blockquote { border: 1px solid #999; page-break-inside: avoid; } |
| 304 | + thead { display: table-header-group; } /* css-discuss.incutio.com/wiki/Printing_Tables */ |
| 305 | + tr, img { page-break-inside: avoid; } |
| 306 | + img { max-width: 100% !important; } |
| 307 | + @page { margin: 0.5cm; } |
| 308 | + p, h2, h3 { orphans: 3; widows: 3; } |
| 309 | + h2, h3{ page-break-after: avoid; } |
| 310 | +} |
0 commit comments