_typography.scss 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218
  1. ///
  2. /// Paradigm Shift by HTML5 UP
  3. /// html5up.net | @ajlkn
  4. /// Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
  5. ///
  6. /* Typography */
  7. html {
  8. font-size: 18pt;
  9. @include breakpoint('<=xlarge') {
  10. font-size: 13pt;
  11. }
  12. @include breakpoint('<=medium') {
  13. font-size: 14pt;
  14. }
  15. @include breakpoint('<=small') {
  16. font-size: 12pt;
  17. }
  18. @include breakpoint('<=xsmall') {
  19. font-size: 11pt;
  20. }
  21. }
  22. body {
  23. background-color: _palette(bg);
  24. color: _palette(fg);
  25. }
  26. body, input, select, textarea {
  27. color: _palette(fg-bold);
  28. font-family: _font(family);
  29. font-size: 1rem;
  30. font-weight: _font(weight);
  31. letter-spacing: _font(kerning);
  32. line-height: 2;
  33. }
  34. a {
  35. @include vendor('transition', 'border-bottom-color #{_duration(transition)} ease-in-out');
  36. text-decoration: none;
  37. color: _palette(fg-bold);
  38. border-bottom: dotted 1px;
  39. &:hover {
  40. text-decoration: none;
  41. border-bottom-color: transparent;
  42. }
  43. }
  44. strong, b {
  45. font-weight: _font(weight-bold);
  46. color: _palette(fg-bold);
  47. }
  48. em, i {
  49. font-style: italic;
  50. }
  51. p {
  52. margin: 0 0 _size(element-margin) 0;
  53. }
  54. h1, h2, h3, h4, h5, h6 {
  55. color: _palette(fg-bold);
  56. font-family: _font(family-heading);
  57. font-weight: _font(weight-heading-light);
  58. letter-spacing: _font(kerning-heading);
  59. line-height: 1.75;
  60. margin: 0 0 (_size(element-margin) * 0.75) 0;
  61. text-transform: uppercase;
  62. a {
  63. color: inherit;
  64. text-decoration: none;
  65. }
  66. }
  67. h1 {
  68. font-family: _font(family);
  69. font-size: 5rem;
  70. font-weight: _font(weight-extrabold);
  71. letter-spacing: _font(kerning-heading-alt);
  72. line-height: 1.1;
  73. margin: 0 0 (_size(element-margin) * 0.75) 0;
  74. text-transform: none;
  75. }
  76. h2 {
  77. font-size: 1.25rem;
  78. font-weight: _font(weight-heading);
  79. margin: 0 0 _size(element-margin) 0;
  80. }
  81. h3 {
  82. font-size: 0.875rem;
  83. }
  84. h4 {
  85. font-size: 0.875rem;
  86. }
  87. h5 {
  88. font-size: 0.75rem;
  89. }
  90. h6 {
  91. font-size: 0.625rem;
  92. }
  93. @include breakpoint('<=small') {
  94. h1 {
  95. font-size: 4.5rem;
  96. line-height: 1.1;
  97. }
  98. h2 {
  99. font-size: 1.25rem;
  100. line-height: 1.7;
  101. }
  102. h3 {
  103. font-size: 0.9rem;
  104. }
  105. h4 {
  106. font-size: 0.75rem;
  107. }
  108. h5 {
  109. font-size: 0.675rem;
  110. }
  111. }
  112. @include breakpoint('<=xxsmall') {
  113. h1 {
  114. font-size: 3.75rem;
  115. }
  116. h2 {
  117. font-size: 1.125rem;
  118. }
  119. h3 {
  120. font-size: 0.8rem;
  121. }
  122. h4 {
  123. font-size: 0.675rem;
  124. }
  125. h5 {
  126. font-size: 0.675rem;
  127. }
  128. }
  129. sub {
  130. font-size: 0.8rem;
  131. position: relative;
  132. top: 0.5rem;
  133. }
  134. sup {
  135. font-size: 0.8rem;
  136. position: relative;
  137. top: -0.5rem;
  138. }
  139. blockquote {
  140. border-left: solid 0.5rem _palette(border);
  141. font-style: italic;
  142. margin: 0 0 _size(element-margin) 0;
  143. padding: (_size(element-margin) * 0.5) 0 (_size(element-margin) * 0.5) _size(element-margin);
  144. }
  145. code {
  146. background: _palette(border-bg);
  147. border-radius: _size(border-radius);
  148. font-family: _font(family-fixed);
  149. font-size: 0.9rem;
  150. margin: 0 0.25rem;
  151. padding: 0.25rem 0.65rem;
  152. }
  153. pre {
  154. -webkit-overflow-scrolling: touch;
  155. font-family: _font(family-fixed);
  156. font-size: 0.9rem;
  157. margin: 0 0 _size(element-margin) 0;
  158. width: 100%;
  159. code {
  160. display: block;
  161. line-height: 1.75;
  162. padding: 1rem 1.5rem;
  163. overflow-x: auto;
  164. }
  165. }
  166. hr {
  167. border: 0;
  168. border-bottom: solid 2px _palette(border);
  169. margin: (_size(element-margin) * 1.5) 0;
  170. &.major {
  171. margin: (_size(element-margin) * 2.5) 0;
  172. }
  173. @include breakpoint('<=small') {
  174. &.major {
  175. margin: (_size(element-margin) * 1.5) 0;
  176. }
  177. }
  178. }