@mixin make-notification__item-colors($color, $icon-color: white) {
  border-color: $color;

  .notifications__item__icon-container{
    background: $color;
    color: $icon-color;
  }
}

.notifications {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  max-width: 400px;
  z-index: $z-index-notifications;
}

.notifications__item {
  min-height: 60px;
  margin: 20px;
  //padding: 20px 30px 20px 60px;
  background: white;
  border: 1px solid transparent;
  box-shadow: 0 0 5px rgba(0,0,0,.2);
  animation: notifications__item--fade-in 0.5s;
  transition: opacity 0.5s ease, height 0.5s ease, margin 0.5s ease, top 0.5s ease;
  position: relative; // used for animations
  top: 0;
  opacity: 1;

  @include make-notification__item-colors($color-light-blue);
}

@keyframes notifications__item--fade-in {
  from {
    top: -10px;
    opacity: 0;
  }

  to {
    top: 0;
    opacity: 1;
  }
}

.notifications__item__icon-container {
  position: absolute;
  top: 0;
  bottom: 0;

  width: 40px;
}

.notifications__item__icon {
  display: inline-block;
  margin: 10px;
}

.notifications__item__content {
  padding: 20px 30px 20px 20px;
  margin-left: 40px;
}

.notifications__item--info {
  @include make-notification__item-colors($color-light-blue);
}

.notifications__item--success {
  @include make-notification__item-colors($color-green);
}

.notifications__item--error {
  @include make-notification__item-colors($color-red);
}

.notifications__item--fade-out {
  opacity: 0;
  height: 0;
  min-height: auto;
  margin-top: 2 * (-1px + -20px) + -20px; // 2 * (-border + -padding) + -margin-bottom
}

// Copyright AXA Versicherungen AG 2015
