@import "susy";

/*============================
=            Grid            =
============================*/

$tablet:      layout(750px 6);
$desktop-sm:  layout(960px 12);
$desktop-lg:  layout(95% 12);
$susy: (
    columns: 3,
    gutters: .25,
    gutter-position: inside,
    container: 1450px
);

$line-int: 30;

$font-size: 18;
$em: $font-size * 1;

$line: $line-int / $em;



.container {
    transition: all 0.15s ease-in-out;
    @include container;
    margin: 0 auto;
}

.row {
  &:after {
    content: '';
    display: block;
    clear: both;
  }
}

.col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12 { transition: all 0.15s ease-in-out; }

.col-1     { @include span(3 of 3); }
.col-2     { @include span(3 of 3); }
.col-3     { @include span(3 of 3); }
.col-4     { @include span(3 of 3); }
.col-5     { @include span(3 of 3); }
.col-6     { @include span(3 of 3); }
.col-7     { @include span(3 of 3); }
.col-8     { @include span(3 of 3); }
.col-9     { @include span(3 of 3); }
.col-10    { @include span(3 of 3); }
.col-11    { @include span(3 of 3); }
.col-12    { @include span(3 of 3); }

@include susy-breakpoint(780px, $tablet) {
  .col-1     { @include span(1 of 6); }
  .col-2     { @include span(1 of 6); }
  .col-3     { @include span(2 of 6); }
  .col-4     { @include span(2 of 6); }
  .col-5     { @include span(3 of 6); }
  .col-6     { @include span(3 of 6); }
  .col-7     { @include span(3 of 6); }
  .col-8     { @include span(4 of 6); }
  .col-9     { @include span(4 of 6); }
  .col-10    { @include span(5 of 6); }
  .col-11    { @include span(5 of 6); }
  .col-12    { @include span(6 of 6); }

  .col-offset-1     { margin-left: span(1 of 6); }
  .col-offset-2     { margin-left: span(1 of 6); }
  .col-offset-3     { margin-left: span(2 of 6); }
  .col-offset-4     { margin-left: span(2 of 6); }
  .col-offset-5     { margin-left: span(3 of 6); }
  .col-offset-6     { margin-left: span(3 of 6); }
  .col-offset-7     { margin-left: span(3 of 6); }
  .col-offset-8     { margin-left: span(4 of 6); }
  .col-offset-9     { margin-left: span(4 of 6); }
  .col-offset-10    { margin-left: span(5 of 6); }
  .col-offset-11    { margin-left: span(5 of 6); }
  .col-offset-third { margin-left: 33.33333%; }

  body {
      /* 20px / 28px */
      font-size: ($font-size - 2) / 16 * 1em;
      line-height: #{$line-int / $em}em;
  }

  .container {
      @include container;
  }

}
@include susy-breakpoint(1100px, $desktop-sm) {
  .col-1     { @include span(1 of 12); }
  .col-2     { @include span(2 of 12); }
  .col-3     { @include span(3 of 12); }
  .col-4     { @include span(4 of 12); }
  .col-5     { @include span(5 of 12); }
  .col-6     { @include span(6 of 12); }
  .col-7     { @include span(7 of 12); }
  .col-8     { @include span(8 of 12); }
  .col-9     { @include span(9 of 12); }
  .col-10    { @include span(10 of 12); }
  .col-11    { @include span(11 of 12); }
  .col-12    { @include span(12 of 12); }

  .col-offset-1     { margin-left: span(1 of 12); }
  .col-offset-2     { margin-left: span(2 of 12); }
  .col-offset-3     { margin-left: span(3 of 12); }
  .col-offset-4     { margin-left: span(4 of 12); }
  .col-offset-5     { margin-left: span(5 of 12); }
  .col-offset-6     { margin-left: span(6 of 12); }
  .col-offset-7     { margin-left: span(7 of 12); }
  .col-offset-8     { margin-left: span(8 of 12); }
  .col-offset-9     { margin-left: span(9 of 12); }
  .col-offset-10    { margin-left: span(10 of 12); }
  .col-offset-11    { margin-left: span(11 of 12); }
  .col-offset-third { margin-left: 50%; }

  body {
      /* 20px / 28px */
      font-size: $font-size / 16 * 1em;
      line-height: #{$line-int / $em}em;
  }

  .container {
      @include container;
  }

}

@include susy-breakpoint(1600px, $desktop-lg) {
  .container {
      @include container;
  }
}

/*-----  End of Grid  ------*/


$duration: 0.45s;
$easing: cubic-bezier(.3,.53,0,1);

$color1: #00FCFF;
$color2: #FF1DAC;

body {
}

.gg-grid {
    transition: all $duration $easing;
    overflow: hidden;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2147483647;
}

.gg-grid-container {
    position: relative;
    width: 100%;
    height: 100%;
    div {
        transition: all $duration $easing;
        border: 1px solid $color2;
        border-width: 0 1px;
        position: absolute;
        width: 0;
        height: 100%;
    }
}

.gg-grid-line-container {
    position: absolute;
    width: 100%;
    height: 100%;
    div {
        box-sizing: border-box;
        border-top: 1px dotted $color1;
        width: 100%;
    }
}

.gg-grid-hidden {
    .gg-grid-container {
        div {
            opacity: 0;
            &:before {
                opacity: 0;
            }
        }
    }
    .gg-grid-line-container {
        div {
            opacity: 0;
        }
    }
}

$grid-switch-size: 30px;

.gg-grid-switch {
    cursor: pointer;
    user-select: none;
    position: fixed;
    z-index: 99;
    width: $grid-switch-size;
    height: $grid-switch-size;
    bottom: 24px;
    right: 24px;
    i {
        transition: all $duration $easing;
        position: absolute;
        width: 4px;
        margin-left: -2px;
        height: $grid-switch-size;
        background: black;
    }
    i:first-child {
        height: $grid-switch-size*1.25;
        transform: translate($grid-switch-size/2, -$grid-switch-size/8) rotate(45deg);
    }
    i:nth-child(2) {
        height: $grid-switch-size*1.25;
        transform: translate($grid-switch-size/2, -$grid-switch-size/8) rotate(45deg);
    }
    i:nth-child(3) {
        height: $grid-switch-size*1.25;
        transform: translate($grid-switch-size/2, -$grid-switch-size/8) rotate(-45deg);
    }
    i:nth-child(4) {
        height: $grid-switch-size*1.25;
        transform: translate($grid-switch-size/2, -$grid-switch-size/8) rotate(-45deg);
    }
}

.gg-grid-hidden .gg-grid-switch {
    i:first-child {
        height: $grid-switch-size;
        transform: translate($grid-switch-size*0.125, 0px);
    }
    i:nth-child(2) {
        height: $grid-switch-size;
        transform: translate($grid-switch-size*0.375, 0px);
    }
    i:nth-child(3) {
        height: $grid-switch-size;
        transform: translate($grid-switch-size*0.625, 0px);
    }
    i:nth-child(4) {
        height: $grid-switch-size;
        transform: translate($grid-switch-size*0.875, 0px);
    }
}


