@use "sass:color";

// scss-docs-start color-functions
// Tint a color: mix a color with white
@function tint-color($color, $weight) {
  @return color.mix(white, $color, $weight);
}

// Shade a color: mix a color with black
@function shade-color($color, $weight) {
  @return color.mix(black, $color, $weight);
}

// Shade the color if the weight is positive, else tint it
@function shift-color($color, $weight) {
  @if $weight > 0 {
    @return shade-color($color, $weight);
  } @else {
    @return tint-color($color, -$weight);
  }
}
// scss-docs-end color-functions
