/*-------------------------------------------------------*/
/* Helper Classes
/*-------------------------------------------------------*/
.bg-light {
  background-color: $bg-light;
}
.bg-dark {
  background-color: $bg-dark;
}

/* Gradients / Overlays
-------------------------------------------------------*/
.bg-overlay {
  position: relative;
}

.bg-overlay::before {
  content: "";
  display: block;
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  background-color: rgba(#000, 0.5);
  @include transition($all);
}

.bottom-gradient {
  position: relative;

  &:before {
    content: "";
    position: absolute;
    width: 100%;
    height: 70%;
    bottom: 0;
    left: 0;
    z-index: 1;
    @include linear-gradient-from-bottom(rgba(#000, 0.7), transparent);
  }
}

/* Box Shadow
-------------------------------------------------------*/
.box-shadow {
  box-shadow: 0px 10px 27px 0px rgba(#9aa1ab, 0.18);
  @include transition($all);
  position: relative;
  display: block;
  top: 0;
}

/* Title Underline
-------------------------------------------------------*/
.title-underline {
  a {
    background-image: linear-gradient(to right, $heading-color 0%, $heading-color 100%);
    background-size: 0px 2px;
    background-position: 0px 95%;
    background-repeat: no-repeat;
    transition: all 0.25s cubic-bezier(0.785, 0.135, 0.15, 0.86) 0s;
    padding: 0.5% 0px;
  }

  &:hover a {
    background-size: 100% 2px;
    color: inherit;
  }
}

/* Link Underline
-------------------------------------------------------*/
.link-underline {
  position: relative;
  @include transition($all);

  &:after {
    content: "";
    position: absolute;
    display: inline-block;
    background-color: var(--dinery-main-color);
    height: 2px;
    width: 62px;
    left: 0;
    bottom: -8px;
    @include transition($all);
  }

  &:hover,
  &:focus {
    color: var(--dinery-main-color);

    &:after {
      width: 100%;
    }
  }
}

/*-------------------------------------------------------*/
/* Hovers
/*-------------------------------------------------------*/
.hover-overlay {
  display: block;
  position: absolute;
  top: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  visibility: hidden;
  background-color: rgba($bg-dark, 0.68);
  @include transition(0.3s cubic-bezier(0.43, 0.07, 0.61, 0.95));
}

.hover-trigger:hover .hover-overlay {
  opacity: 1;
  visibility: visible;
}

.hover-shine {
  &::before {
    position: absolute;
    pointer-events: none;
    top: 0;
    left: -75%;
    z-index: 2;
    display: block;
    content: "";
    width: 50%;
    height: 100%;
    background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.3) 100%);
    background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.3) 100%);
    -webkit-transform: skewX(-25deg);
    transform: skewX(-25deg);
  }

  &:hover {
    &::before {
      -webkit-animation: shine 0.75s;
      animation: shine 0.75s;
    }
  }
}

@-webkit-keyframes shine {
  100% {
    left: 125%;
  }
}
@keyframes shine {
  100% {
    left: 125%;
  }
}

// Button Animation
.hover-pulse {
  position: relative;
  z-index: 0;

  &::after {
    content: "";
    display: inline-block;
    height: 100%;
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: -1;
    transition: all 0.3s ease-in-out;
    background-color: inherit;
  }

  &:hover::after {
    transform: scaleX(1.2) scaleY(1.6);
    opacity: 0;
  }
}

/* Flexbox
-------------------------------------------------------*/
.justify-content-center {
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
}

.justify-content-between {
  -webkit-box-pack: space-between;
  -ms-flex-pack: justify;
  justify-content: space-between;
}

.align-items-center {
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
}

/* Column Gutters
-------------------------------------------------------*/
.row-40 {
  margin-left: -20px;
  margin-right: -20px;

  & > div {
    padding-left: 20px;
    padding-right: 20px;
  }
}
