Created
March 21, 2014 06:22
-
-
Save liveme/9680667 to your computer and use it in GitHub Desktop.
reset
This file contains 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
/** | |
* @ Name: reset.css V1.0.0 | |
* @ Author: liveme | |
* @ Update: 2013-10-25 | |
* @ Copyright: 基于 normalize.css | MIT License | |
*/ | |
/* =============== 基础排版 =============== */ | |
html { | |
font-size: 62.5%; /* 10/16=62.5% */ | |
-webkit-font-smoothing: antialiased; | |
} | |
body { | |
background-color:#fff; | |
color:#333; | |
font: 12px/1.5 'Helvetica Neue',Helvetica,Arial,Sans-serif; | |
font-size: 1.2rem; | |
} | |
body,div,dl,dt,dd,ul,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,figure,legend,input,button,textarea,blockquote { | |
margin:0; | |
padding:0; | |
} | |
a { | |
color:#0078B6; | |
text-decoration:none; | |
} | |
a:hover { | |
text-decoration:underline; | |
} | |
a:active { | |
background-color: transparent; | |
} | |
a:active,a:hover,a:focus { | |
outline: 0; | |
} | |
h1 { | |
font-size: 32px; | |
font-size: 3.2rem; | |
} | |
h2 { | |
font-size: 24px; | |
font-size: 2.4rem; | |
} | |
h3 { | |
font-size: 18px; | |
font-size: 1.8rem; | |
} | |
h4 { | |
font-size: 16px; | |
font-size: 1.6rem; | |
} | |
h5 { | |
font-size: 14px; | |
font-size: 1.4rem; | |
} | |
h6 { | |
font-size: 12px; | |
font-size: 1.2rem; | |
} | |
/* =============== 列表 =============== */ | |
dl,menu,ol,ul { | |
margin: 1em 0; | |
} | |
dd { | |
margin: 0 0 0 40px; | |
} | |
menu,ol,ul { | |
padding: 0 0 0 40px; | |
} | |
nav ul,nav ol { | |
list-style: none; | |
list-style-image: none; | |
} | |
/* =============== 表格 =============== */ | |
table { | |
border-collapse: collapse; | |
border-spacing: 0; | |
} | |
/* =============== 表单 =============== */ | |
fieldset { | |
border: 1px solid #c0c0c0; | |
margin: 0 2px; | |
padding: 0.35em 0.625em 0.75em; | |
} | |
legend { | |
border: 0 none; | |
white-space: normal; /* 修正 Firefox3 中文字不换行的问题 */ | |
*margin-left: -7px; /* 修正 IE6-7 中怪异的对齐方式. */ | |
} | |
button,input,select,textarea { | |
font-size: 100%; | |
font-family: Tahoma,Arial; | |
vertical-align: baseline; | |
*vertical-align: middle; | |
} | |
button,input { | |
line-height: normal; | |
*overflow: visible; | |
} | |
button,select { | |
text-transform: none; | |
} | |
textarea { | |
overflow: auto; /* 移除 IE6-11 中默认的垂直滚动条 */ | |
vertical-align: top; | |
} | |
button,html input[type="button"],input[type="reset"],input[type="submit"] { | |
-webkit-appearance: button; | |
cursor: pointer; | |
*overflow: visible; | |
} | |
button[disabled],html input[disabled] { | |
cursor: default; | |
} | |
input[type="checkbox"],input[type="radio"] { | |
box-sizing: border-box; | |
padding: 0; | |
*height: 13px; | |
*width: 13px; | |
} | |
input[type="search"] { | |
-webkit-appearance: textfield; | |
-moz-box-sizing: content-box; | |
-webkit-box-sizing: content-box; | |
box-sizing: content-box; | |
} | |
input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration { | |
-webkit-appearance: none; | |
} | |
button::-moz-focus-inner,input::-moz-focus-inner { | |
border: 0; | |
padding: 0; | |
} | |
/* =============== 嵌入元素 =============== */ | |
img { | |
border: 0; | |
vertical-align: middle; | |
-ms-interpolation-mode: bicubic; /* 修复 IE7 图片缩放失真 */ | |
} | |
svg:not(:root) { | |
overflow: hidden; | |
} | |
/* =============== 其他元素 =============== */ | |
abbr[title] { | |
border-bottom: 1px dotted; | |
} | |
b,strong { | |
font-weight: bold; | |
} | |
blockquote { | |
margin: 1em 40px; | |
} | |
dfn { | |
font-style: italic; | |
} | |
hr { | |
-moz-box-sizing: content-box; | |
box-sizing: content-box; | |
height: 0; | |
} | |
mark { | |
background: #CDE1FC; | |
color: #000; | |
padding: 2px 5px; | |
border-radius: 3px; | |
} | |
code,kbd,pre,samp { | |
font-family: Consolas,Menlo,Monaco,"Lucida Console","Courier New",monospace,serif; | |
font-size: 1em; | |
} | |
code { | |
font: bold 14px/1.5 Consolas,Menlo,Monaco,"Lucida Console","Courier New",monospace,serif; | |
background-color: #F8F8F8; | |
color: #444; | |
margin: 0 2px; | |
padding: 0px 5px; | |
border: 1px solid #DDD; | |
border-radius: 3px; | |
} | |
pre { | |
white-space: pre; | |
white-space: pre-wrap; | |
word-wrap: break-word; | |
} | |
q { | |
quotes: none; | |
} | |
q:before,q:after { | |
content: ''; | |
content: none; | |
} | |
small { | |
font-size: 85.7%; /* 12/14=0.8571428571 */ | |
font-size: 1.2rem; | |
} | |
sub,sup { | |
font-size: 75%; | |
line-height: 0; | |
position: relative; | |
vertical-align: baseline; | |
} | |
sup { | |
top: -0.5em; | |
} | |
sub { | |
bottom: -0.25em; | |
} | |
/* =============== HTML5元素 =============== */ | |
article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary { | |
display: block; | |
} | |
audio,canvas,video { | |
display: inline-block; | |
*display: inline; | |
*zoom: 1; | |
} | |
audio:not([controls]) { | |
display: none; | |
height: 0; | |
} | |
[hidden],template { | |
display: none; | |
} | |
[draggable] { | |
cursor: move; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment