@function colorAlpha($color, $opacity) {
  @return #{'rgb(from #{$color} r g b / #{$opacity})'};
}

@function spacing($top, $right: '', $bottom: '', $left: '') {
  @if ($right == '') {
    @return $top * $spacing;
  }

  @if ($bottom == '') {
    @return ($top * $spacing) ($right * $spacing);
  }

  @if ($left == '') {
    @return ($top * $spacing) ($right * $spacing) ($bottom * $spacing);
  }

  @return ($top * $spacing) ($right * $spacing) ($bottom * $spacing) ($left * $spacing);
}
