style.scss 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258
  1. @import "compass/css3";
  2. $bgc:#24303a;
  3. $chart-bg:#1e2730;
  4. $chart-txt:#4a667a;
  5. $green:#48c15e;
  6. $red:#ef6670;
  7. @import url(http://fonts.googleapis.com/css?family=Lato:400,700);
  8. @font-face{
  9. font-family:Lato;
  10. src:url(https://s3-us-west-2.amazonaws.com/s.cdpn.io/176026/ProximaNova-Regular.otf);
  11. font-weight:300;
  12. }
  13. body,html{
  14. font-family:Lato;
  15. }
  16. h1{
  17. font-size:28px;
  18. line-height:40px;
  19. margin-top:20px;
  20. a{
  21. text-decoration:none;
  22. color:$green;
  23. }
  24. p{
  25. font-size:22px;
  26. }
  27. }
  28. #grid{
  29. @include transform(translate(1px,0px));
  30. }
  31. /* GRAPH - 1 */
  32. #graph-1{
  33. stroke:url(#gradient-1);
  34. stroke-width:1.5;
  35. fill:transparent;
  36. stroke-linecap:round;
  37. stroke-linejoin:round;
  38. @include animation (lineani 1.3s linear forwards);
  39. }
  40. #graph-2{
  41. stroke:url(#gradient-2);
  42. stroke-width:1.5;
  43. fill:transparent;
  44. stroke-linecap:round;
  45. stroke-linejoin:round;
  46. @include animation (lineani 1.3s linear forwards);
  47. }
  48. #poly-1{
  49. fill:url(#gradient-3);
  50. }
  51. #poly-2{
  52. fill:url(#gradient-4);
  53. }
  54. @include keyframes (lineani){
  55. to{
  56. stroke-dashoffset:0;
  57. }
  58. }
  59. .underlay{
  60. stroke-width:5;
  61. fill:transparent;
  62. stroke-linecap:round;
  63. stroke-linejoin:round;
  64. stroke:$bgc;
  65. }
  66. #circle-graph-1{
  67. stroke:url(#gradient-1);
  68. stroke-width:5;
  69. fill:transparent;
  70. stroke-linecap:round;
  71. stroke-linejoin:round;
  72. }
  73. .chart-circle{
  74. @include transform(rotate(90deg));
  75. }
  76. #circle-graph-2{
  77. stroke:url(#gradient-2);
  78. stroke-width:5;
  79. fill:transparent;
  80. stroke-linecap:round;
  81. stroke-linejoin:round;
  82. }
  83. body{
  84. background-color: $bgc;
  85. color:white;
  86. text-align:center;
  87. }
  88. .charts-container{
  89. padding:20px;
  90. width:100%;
  91. max-width:1024px;
  92. display:inline-block;
  93. @include box-sizing(border-box);
  94. }
  95. .chart{
  96. color:$chart-txt;
  97. text-align:left;
  98. position: relative;
  99. height:auto;
  100. background-color: $chart-bg;
  101. display:inline-block;
  102. float:left;
  103. position:relative;
  104. @include box-sizing(border-box);
  105. margin:10px;
  106. padding:15px 20px 65px 20px;
  107. &.circle{
  108. padding:15px 20px 40px 20px;
  109. }
  110. @media screen and (max-width:700px){
  111. width:calc(100% - 20px);
  112. }
  113. @media screen and (min-width:700px){
  114. width:calc(50% - 20px);
  115. }
  116. }
  117. .title{
  118. font-size: 22px;
  119. margin-bottom:12px;
  120. }
  121. .chart-circle{
  122. display:inline-block;
  123. position: relative;
  124. }
  125. .chart-svg{
  126. position:relative;
  127. }
  128. .circle-percentage{
  129. position:absolute;
  130. color:white;
  131. font-size: 48px;
  132. left:50%;
  133. top:50%;
  134. @include transform(translate(-50%,-50%));
  135. @media screen and (max-width:480px){
  136. font-size:32px;
  137. }
  138. }
  139. .align-center{
  140. text-align:center;
  141. }
  142. .chart-line{
  143. width:80%;
  144. }
  145. .valueX{
  146. font-size:14px;
  147. }
  148. .chart-values{
  149. text-align:right;
  150. font-size:18px;
  151. position:absolute;
  152. right:0;
  153. bottom:0;
  154. padding:15px;
  155. }
  156. .h-value{
  157. @include transition(700ms ease-in-out);
  158. opacity:0;
  159. &.visible{
  160. opacity:1;
  161. }
  162. }
  163. .percentage-value{
  164. @include transition(700ms ease-in-out);
  165. color:$green;
  166. margin-top:2px;
  167. opacity:0;
  168. &.negative{
  169. color:$red;
  170. }
  171. &.visible{
  172. opacity:1;
  173. }
  174. }
  175. .total-gain{
  176. color:white;
  177. font-size:48px;
  178. }
  179. .triangle{
  180. width: 0;
  181. height: 0;
  182. border-style: solid;
  183. border-width: 28px 0 0 28px;
  184. position:absolute;
  185. left:0;
  186. bottom:0;
  187. &.red{
  188. border-color: transparent transparent transparent $red;
  189. }
  190. &.green{
  191. border-color: transparent transparent transparent $green;
  192. }
  193. }
  194. .horizontal,
  195. .vertical{
  196. stroke-width:0.1;
  197. stroke:$chart-txt;
  198. }
  199. /* CLEARFIX HELPER */
  200. .cf:before,
  201. .cf:after {
  202. content: " "; /* 1 */
  203. display: table; /* 2 */
  204. }
  205. .cf:after {clear: both;
  206. }
  207. /**
  208. * For IE 6/7 only
  209. * Include this rule to trigger hasLayout and contain floats.
  210. */
  211. .cf {
  212. *zoom: 1;
  213. }
  214. /*IRRELEVANT CSS*/
  215. .followlinks{
  216. position:fixed;
  217. right:35px;
  218. bottom:15px;
  219. display:table;
  220. a {
  221. display:table-cell;
  222. vertical-align:middle;
  223. padding-left:10px;
  224. color:white;
  225. svg path{
  226. fill:white;
  227. }
  228. }
  229. }
  230. .heartIt{
  231. margin-top:50px;
  232. margin-bottom:80px;
  233. p{
  234. font-size:24px;
  235. line-height:40px;
  236. }
  237. img{
  238. width:64px;
  239. height:auto;
  240. opacity:0.7;
  241. @include filter(invert(100%));
  242. }
  243. }
  244. .original{
  245. color:$red;
  246. font-size: 14px;
  247. }