@function dynamic-color($color, $lightness: 50, $dark-color: $text-color, $light-color: $brand-white) { @if (lightness($color) > $lightness){ @return $dark-color; // Lighter background, return dark color } @else { @return $light-color; // Darker background, return light color } } @function paired-color($brand-color) { $return-color: dynamic-color($brand-color) !default; @if ($brand-color == $brand-color-d){ $return-color: $brand-color-a; } @if ($brand-color == $brand-color-e){ $return-color: $brand-color-b; } @if ($brand-color == $brand-color-f){ $return-color: $brand-color-c; } @return $return-color; } @function tint($color, $percentage) { @return mix(#fff, $color, $percentage); } @function shade($color, $percentage) { @return mix(#000, $color, $percentage); } @mixin placeholder($color) { &:-moz-placeholder { color: $color; // Firefox 4-18 } &::-moz-placeholder { color: $color; // Firefox 19+ } &:-ms-input-placeholder { color: $color; // Internet Explorer 10+ } &::-webkit-input-placeholder { color: $color; // Safari and Chrome } }