@mixin ax-background($pos, $g1: null, $g2: null) {

  $pos-type: type-of(nth($pos, 1));

  // If $pos is missing from mixin, reassign vars and add default position
  @if ($pos-type == color) or (nth($pos, 1) == "transparent") {
    $g2: $g1;
    $g1: $pos;
    $pos: to top;
  } @else if ($g1 == null) {
    $g1: $pos;
    $pos: to top;
  }

  // @debug($g1);
  @if (length($g1) == 2) {
    $g2: nth($g1, 2);
    $g1: nth($g1, 1);
  } @else if (length($g1) == 3) {
    $pos: nth($g1, 1);
    $g1 : nth($g1, 2);
    $g2: nth($g1, 3);
  } @else {
    @if (type_of(nth($g2, 1)) == color) {
      $g2: nth($g2, 1);
    }
  }

  background-color: $g1;
  background-image: linear-gradient($pos, $g1, $g2);
}

@mixin transform(){

}

@mixin sort-arrow($arrow-size, $ratio-0, $ratio-1, $arrow-color, $opacity, $direction) {
  position: absolute;
  content: ' ';
  width: 0;
  height: 0;
  display: inline-block;
  border-left: $arrow-size/$ratio-0 solid transparent;
  border-right: $arrow-size/$ratio-0 solid transparent;
  @if ($direction == "up") {
    border-bottom: ($arrow-size)/$ratio-1 solid $arrow-color;
  } @else {
    border-top: ($arrow-size)/$ratio-1 solid $arrow-color;
  }
  background: transparent;
  opacity: $opacity;
}