@use "sass:meta";
@use "sass:string";
// @use'../variables' as*;

@mixin apply-to-all($mixin, $list) {
    @each $element in $list {
      @include meta.apply($mixin, $element);
    }
}

//Variable
$sizes: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10;

/*=== Position Top positive utilities ===*/
@mixin object-position-top($value) {
  .fui-top-#{$value} {
    top: $value+px !important;
  }
}
@include apply-to-all(meta.get-mixin("object-position-top"), $sizes);


/*=== Position Bottom positive utilities ===*/
@mixin object-position-bottom($value) {
  .fui-bottom-#{$value} {
    bottom: $value+px !important;
  }
}
@include apply-to-all(meta.get-mixin("object-position-bottom"), $sizes);


/*=== Position Top negative utilities ===*/
@mixin object-position-top($value) {
    .fui-top-n-#{$value} {
      top: -$value+px !important;
    }
}
@include apply-to-all(meta.get-mixin("object-position-top"), $sizes);


/*=== Position Bottom negative utilities ===*/
@mixin object-position-bottom($value) {
  .fui-bottom-n-#{$value} {
    bottom: -$value+px !important;
  }
}
@include apply-to-all(meta.get-mixin("object-position-bottom"), $sizes);




[dir=ltr]{
/*=== Position Start positive utilities ===*/
@mixin object-position-start($value) {
    .fui-start-#{$value} {
      left: $value+px !important;
    }
}
@include apply-to-all(meta.get-mixin("object-position-start"), $sizes);


/*=== Position End positive utilities ===*/
@mixin object-position-end($value) {
    .fui-end-#{$value} {
      right: $value+px !important;
    }
}
@include apply-to-all(meta.get-mixin("object-position-end"), $sizes);


/*=== Position Start negative utilities ===*/
@mixin object-position-start($value) {
    .fui-start-n-#{$value} {
      left: -$value+px !important;
    }
}
@include apply-to-all(meta.get-mixin("object-position-start"), $sizes);


/*=== Position End negative utilities ===*/
@mixin object-position-end($value) {
    .fui-end-n-#{$value} {
      right: -$value+px !important;
    }
}
@include apply-to-all(meta.get-mixin("object-position-end"), $sizes);

}

@media (min-width:1400px){
  .position-xxl-fixed{
    position: fixed !important;
  }
  .position-xxl-absolute{
    position: absolute !important;
  }
  .position-xxl-relative{
    position: relative !important;
  }
  .position-xxl-sticky{
    position: sticky !important;
  }
  .position-xxl-static{
    position: static !important;
  }
}


@media (min-width:1200px){
  .position-xl-fixed{
    position: fixed !important;
  }
  .position-xl-absolute{
    position: absolute !important;
  }
  .position-xl-relative{
    position: relative !important;
  }
  .position-xl-sticky{
    position: sticky !important;
  }
  .position-xl-static{
    position: static !important;
  }
}


@media (min-width:992px){
  .position-lg-fixed{
    position: fixed !important;
  }
  .position-lg-absolute{
    position: absolute !important;
  }
  .position-lg-relative{
    position: relative !important;
  }
  .position-lg-sticky{
    position: sticky !important;
  }
  .position-lg-static{
    position: static !important;
  }
}


@media (min-width:768px){
  .position-md-fixed{
    position: fixed !important;
  }
  .position-md-absolute{
    position: absolute !important;
  }
  .position-md-relative{
    position: relative !important;
  }
  .position-md-sticky{
    position: sticky !important;
  }
  .position-md-static{
    position: static !important;
  }
}


@media (min-width:575px){
  .position-sm-fixed{
    position: fixed !important;
  }
  .position-sm-absolute{
    position: absolute !important;
  }
  .position-sm-relative{
    position: relative !important;
  }
  .position-sm-sticky{
    position: sticky !important;
  }
  .position-sm-static{
    position: static !important;
  }
}






/*=== RTL ===*/

[dir=rtl]{
    /*=== Position Start positive utilities ===*/
    @mixin object-position-start($value) {
        .fui-start-#{$value} {
          right: $value+px !important;
        }
    }
    @include apply-to-all(meta.get-mixin("object-position-start"), $sizes);


    /*=== Position End positive utilities ===*/
    @mixin object-position-end($value) {
        .fui-end-#{$value} {
            left: $value+px !important;
        }
    }
    @include apply-to-all(meta.get-mixin("object-position-end"), $sizes);


    /*=== Position Start negative utilities ===*/
    @mixin object-position-start($value) {
        .fui-start-n-#{$value} {
            right: -$value+px !important;
            left: inherit !important;
        }
    }
    @include apply-to-all(meta.get-mixin("object-position-start"), $sizes);


    /*=== Position End negative utilities ===*/
    @mixin object-position-end($value) {
        .fui-end-n-#{$value} {
            left: -$value+px !important;
            right: inherit !important;
        }
    }
    @include apply-to-all(meta.get-mixin("object-position-end"), $sizes);


}