_base.scss 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  1. // reset
  2. body, h1, h2, h3, h4, h5, h6,
  3. p, blockquote, pre, hr,
  4. dl, dd, ol, ul, figure {
  5. margin: 0;
  6. padding: 0;
  7. }
  8. * {
  9. box-sizing: border-box;
  10. }
  11. body {
  12. // background style
  13. background-color: #454545;
  14. // from svgbackgrounds.com
  15. background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 2000 1500'%3E%3Cdefs%3E%3CradialGradient id='a' gradientUnits='objectBoundingBox'%3E%3Cstop offset='0' stop-color='%23000000'/%3E%3Cstop offset='1' stop-color='%23454545'/%3E%3C/radialGradient%3E%3ClinearGradient id='b' gradientUnits='userSpaceOnUse' x1='0' y1='750' x2='1550' y2='750'%3E%3Cstop offset='0' stop-color='%23232323'/%3E%3Cstop offset='1' stop-color='%23454545'/%3E%3C/linearGradient%3E%3Cpath id='s' fill='url(%23b)' d='M1549.2 51.6c-5.4 99.1-20.2 197.6-44.2 293.6c-24.1 96-57.4 189.4-99.3 278.6c-41.9 89.2-92.4 174.1-150.3 253.3c-58 79.2-123.4 152.6-195.1 219c-71.7 66.4-149.6 125.8-232.2 177.2c-82.7 51.4-170.1 94.7-260.7 129.1c-90.6 34.4-184.4 60-279.5 76.3C192.6 1495 96.1 1502 0 1500c96.1-2.1 191.8-13.3 285.4-33.6c93.6-20.2 185-49.5 272.5-87.2c87.6-37.7 171.3-83.8 249.6-137.3c78.4-53.5 151.5-114.5 217.9-181.7c66.5-67.2 126.4-140.7 178.6-218.9c52.3-78.3 96.9-161.4 133-247.9c36.1-86.5 63.8-176.2 82.6-267.6c18.8-91.4 28.6-184.4 29.6-277.4c0.3-27.6 23.2-48.7 50.8-48.4s49.5 21.8 49.2 49.5c0 0.7 0 1.3-0.1 2L1549.2 51.6z'/%3E%3Cg id='g'%3E%3Cuse href='%23s' transform='scale(0.12) rotate(60)'/%3E%3Cuse href='%23s' transform='scale(0.2) rotate(10)'/%3E%3Cuse href='%23s' transform='scale(0.25) rotate(40)'/%3E%3Cuse href='%23s' transform='scale(0.3) rotate(-20)'/%3E%3Cuse href='%23s' transform='scale(0.4) rotate(-30)'/%3E%3Cuse href='%23s' transform='scale(0.5) rotate(20)'/%3E%3Cuse href='%23s' transform='scale(0.6) rotate(60)'/%3E%3Cuse href='%23s' transform='scale(0.7) rotate(10)'/%3E%3Cuse href='%23s' transform='scale(0.835) rotate(-40)'/%3E%3Cuse href='%23s' transform='scale(0.9) rotate(40)'/%3E%3Cuse href='%23s' transform='scale(1.05) rotate(25)'/%3E%3Cuse href='%23s' transform='scale(1.2) rotate(8)'/%3E%3Cuse href='%23s' transform='scale(1.333) rotate(-60)'/%3E%3Cuse href='%23s' transform='scale(1.45) rotate(-30)'/%3E%3Cuse href='%23s' transform='scale(1.6) rotate(10)'/%3E%3C/g%3E%3C/defs%3E%3Cg %3E%3Cg transform=''%3E%3Ccircle fill='url(%23a)' r='3000'/%3E%3Cg opacity='0.5'%3E%3Ccircle fill='url(%23a)' r='2000'/%3E%3Ccircle fill='url(%23a)' r='1800'/%3E%3Ccircle fill='url(%23a)' r='1700'/%3E%3Ccircle fill='url(%23a)' r='1651'/%3E%3Ccircle fill='url(%23a)' r='1450'/%3E%3Ccircle fill='url(%23a)' r='1250'/%3E%3Ccircle fill='url(%23a)' r='1175'/%3E%3Ccircle fill='url(%23a)' r='900'/%3E%3Ccircle fill='url(%23a)' r='750'/%3E%3Ccircle fill='url(%23a)' r='500'/%3E%3Ccircle fill='url(%23a)' r='380'/%3E%3Ccircle fill='url(%23a)' r='250'/%3E%3C/g%3E%3Cg transform='rotate(-129.6 0 0)'%3E%3Cuse href='%23g' transform='rotate(10)'/%3E%3Cuse href='%23g' transform='rotate(120)'/%3E%3Cuse href='%23g' transform='rotate(240)'/%3E%3C/g%3E%3Ccircle fill-opacity='0.87' fill='url(%23a)' r='3000'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  16. background-attachment: fixed;
  17. background-size: cover;
  18. background-repeat: no-repeat;
  19. // display
  20. display: flex;
  21. min-height: 100vh;
  22. flex-direction: column;
  23. overflow-wrap: break-word;
  24. // font
  25. font: $base-font-weight #{$base-font-size}/#{$base-line-height} $base-font-family;
  26. color:$base-font-color;
  27. -webkit-text-size-adjust: 100%;
  28. -webkit-font-feature-settings: "kern" 1;
  29. -moz-font-feature-settings: "kern" 1;
  30. -o-font-feature-settings: "kern" 1;
  31. font-feature-settings: "kern" 1;
  32. font-kerning: normal;
  33. }
  34. // block elements - bottom margin
  35. h1, h2, h3, h4, h5, h6,
  36. p, blockquote, pre,
  37. ul, ol, dl, figure,
  38. %vertical-rhythm {
  39. margin-bottom: $spacing-unit / 2;
  40. }
  41. // wrapper
  42. .wrapper {
  43. max-width: calc(#{$content-width} - (#{$spacing-unit}));
  44. margin-right: auto;
  45. margin-left: auto;
  46. padding-right: $spacing-unit / 2;
  47. padding-left: $spacing-unit / 2;
  48. @extend %clearfix;
  49. @media screen and (min-width: $on-laptop) {
  50. max-width: calc(#{$content-width} - (#{$spacing-unit} * 2));
  51. padding-right: $spacing-unit;
  52. padding-left: $spacing-unit;
  53. }
  54. }
  55. %clearfix:after {
  56. content: "";
  57. display: table;
  58. clear: both;
  59. }
  60. // code
  61. pre,
  62. code {
  63. font-family: $code-font-family;
  64. font-size: 0.9375em;
  65. border-radius: 3px;
  66. }
  67. code {
  68. padding: 1px 5px;
  69. }
  70. pre {
  71. padding: 8px 12px;
  72. overflow-x: auto;
  73. padding: 20px;
  74. background: $header-color;
  75. border-radius: 20px;
  76. > code {
  77. border: 0;
  78. padding-right: 0;
  79. padding-left: 0;
  80. }
  81. }
  82. hr {
  83. margin-top: $spacing-unit;
  84. margin-bottom: $spacing-unit;
  85. }
  86. main {
  87. display: block; // IE fix
  88. }
  89. // images
  90. img {
  91. max-width: 100%;
  92. vertical-align: middle;
  93. }
  94. p {
  95. img:first-child:last-child {
  96. border-radius:10px;
  97. margin:20px 0;
  98. box-shadow: 0 0 30px rgba(0,0,0,.1);
  99. }
  100. }
  101. // fig
  102. figure > img {
  103. display: block;
  104. }
  105. figcaption {
  106. font-size: $small-font-size;
  107. }
  108. // lists
  109. ul, ol {
  110. margin-left: $spacing-unit;
  111. }
  112. li {
  113. > ul,
  114. > ol {
  115. margin-bottom: 0;
  116. }
  117. }
  118. // headings
  119. h1, h2, h3, h4, h5, h6 {
  120. font-weight: 600;
  121. color:#fff;
  122. }
  123. a {
  124. color: $theme-color;
  125. text-decoration: none;
  126. &:hover {
  127. // color: $text-color;
  128. text-decoration: underline;
  129. }
  130. }
  131. strong {
  132. color: $theme-color;
  133. }
  134. blockquote {
  135. border-left: 10px solid $theme-color;
  136. padding-left: $spacing-unit / 2;
  137. @include relative-font-size(1.125);
  138. letter-spacing: -1px;
  139. margin: $spacing-unit 0;
  140. padding: 15px;
  141. border-radius: 10px;;
  142. background-color: change-color($color: $theme-color, $alpha: 0.1);
  143. > :last-child {
  144. margin-bottom: 0;
  145. }
  146. }
  147. table {
  148. margin-bottom: $spacing-unit;
  149. width: 100%;
  150. text-align: left;
  151. border-collapse: collapse;
  152. border-radius: 10px;
  153. overflow: hidden;
  154. tr {
  155. &:nth-child(even) {
  156. background-color: #3c3c3c;
  157. }
  158. }
  159. th, td {
  160. padding: ($spacing-unit / 3) ($spacing-unit / 2);
  161. }
  162. th {
  163. background-color: #454545;
  164. }
  165. @include media-query($on-laptop) {
  166. display: block;
  167. overflow-x: auto;
  168. -webkit-overflow-scrolling: touch;
  169. -ms-overflow-style: -ms-autohiding-scrollbar;
  170. }
  171. }