reset.scss 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. @charset "UTF-8";
  2. body,
  3. h1,
  4. h2,
  5. h3,
  6. h4,
  7. h5,
  8. h6,
  9. hr,
  10. p,
  11. blockquote,
  12. /* structural elements 结构元素 */
  13. dl,
  14. dt,
  15. dd,
  16. ul,
  17. ol,
  18. li,
  19. /* list elements 列表元素 */
  20. pre,
  21. /* text formatting elements 文本格式元素 */
  22. fieldset,
  23. lengend,
  24. button,
  25. input,
  26. textarea,
  27. /* form elements 表单元素 */
  28. th,
  29. td {
  30. /* search elements 表格元素 */
  31. margin: 0;
  32. padding: 0;
  33. }
  34. /* 设置默认字体 */
  35. body,
  36. html {
  37. font-size: 14px;
  38. font-family: -apple-system, BlinkMacSystemFont, segoe ui, Roboto, helvetica neue, Arial, noto sans, sans-serif, apple color emoji, segoe ui emoji, segoe ui symbol, noto color emoji;
  39. }
  40. h1 {
  41. font-size: 18px;
  42. /* 18px / 12px = 1.5 */
  43. }
  44. h2 {
  45. font-size: 16px;
  46. }
  47. h3 {
  48. font-size: 14px;
  49. }
  50. h4,
  51. h5,
  52. h6 {
  53. font-size: 100%;
  54. }
  55. address,
  56. cite,
  57. dfn,
  58. em,
  59. var {
  60. font-style: normal;
  61. }
  62. /* 将斜体扶正 */
  63. code,
  64. kbd,
  65. pre,
  66. samp,
  67. tt {
  68. font-family: "Courier New", Courier, monospace;
  69. }
  70. /* 统一等宽字体 */
  71. small {
  72. font-size: 12px;
  73. }
  74. /* 小于 12px 的中文很难阅读,让 small 正常化 */
  75. /* 重置列表元素 */
  76. ul,
  77. ol {
  78. list-style: none;
  79. }
  80. /* 重置文本格式元素 */
  81. a {
  82. text-decoration: none;
  83. }
  84. a:hover {
  85. text-decoration: underline;
  86. }
  87. abbr[title],
  88. acronym[title] {
  89. /* 注:1.ie6 不支持 abbr; 2.这里用了属性选择符,ie6 下无效果 */
  90. border-bottom: 1px dotted;
  91. cursor: help;
  92. }
  93. q:before,
  94. q:after {
  95. content: '';
  96. }
  97. /* 重置表单元素 */
  98. legend {
  99. color: #000;
  100. }
  101. /* for ie6 */
  102. fieldset,
  103. img {
  104. border: none;
  105. }
  106. /* img 搭车:让链接里的 img 无边框 */
  107. /* 注:optgroup 无法扶正 */
  108. button,
  109. input,
  110. select,
  111. textarea {
  112. font-size: 100%;
  113. /* 使得表单元素在 ie 下能继承字体大小 */
  114. }
  115. /* 重置表格元素 */
  116. table {
  117. border-collapse: collapse;
  118. border-spacing: 0;
  119. }
  120. /* 重置 hr */
  121. hr {
  122. border: none;
  123. height: 1px;
  124. }
  125. *,
  126. *:before,
  127. *:after {
  128. box-sizing: inherit;
  129. }
  130. a:focus,
  131. a:active {
  132. outline: none;
  133. }
  134. a,
  135. a:focus,
  136. a:hover {
  137. cursor: pointer;
  138. color: inherit;
  139. text-decoration: none;
  140. }
  141. div:focus {
  142. outline: none;
  143. }
  144. .f-l {
  145. float: left;
  146. }
  147. .f-r {
  148. float: right;
  149. }
  150. .clearfix:after {
  151. visibility: hidden;
  152. display: block;
  153. font-size: 0;
  154. content: '';
  155. clear: both;
  156. height: 0;
  157. }
  158. .gc-hide {
  159. display: none !important;
  160. }