@charset "UTF-8";

$os-notifier-css-transition: all 1s ease-out;

.notifier-server-messages {
  display: none;
}

.os-notifier {
  position: absolute;
  top: 0;
  right: 0;
  padding-top: $os-header-height;
  width: 30%;
  height: 100%;
  overflow: hidden;

  ul {
    list-style: none;
    margin: 0;
    padding: 0;
  }

  > li:first-child {
    margin-top: 0;
  }

  li {
    display: block;
    position: relative;
    box-sizing: border-box;
    -moz-transition: $os-notifier-css-transition;
    -webkit-transition: $os-notifier-css-transition;
    -o-transition: $os-notifier-css-transition;
    transition: $os-notifier-css-transition;
    width: 100%;
    max-height: 100%;
    height: 0;
    opacity: 0;
    z-index: 1003;
    background-color: transparent;
    padding: .5rem .5rem 0 0;

    &.preparing-css-animation {
      height: auto;
    }

    &.notifier-active-message {
      opacity: 1;

      &:first-child {
        margin-top: 0;
      }
    }

    &.notifier-leaving-message {
      padding-top: 0;

      .notifier-messsage-content {
        border: none;
        margin: 0;
        top: 0;
      }

      .notifier-close {
        display: none;
      }
    }

    &.notifier-info {

      .notifier-messsage-content {
        background-color: $info-background-color;
        border: 1px solid $info-icon-color;
      }

      .notifier-icon {
        color: $info-icon-color;
      }
    }

    &.notifier-error {

      .notifier-messsage-content {
        background-color: $error-background-color;
        border: 1px solid $error-icon-color;
      }

      .notifier-icon {
        color: $error-icon-color;
      }
    }

    &.notifier-success {

      .notifier-messsage-content {
        background-color: $success-background-color;
        border: 1px solid $success-icon-color;
      }

      .notifier-icon {
        color: $success-icon-color;
      }
    }

    &.notifier-warning {

      .notifier-messsage-content {
        background-color: $warning-background-color;
        border: 1px solid $warning-icon-color;
      }

      .notifier-icon {
        color: $warning-icon-color;
      }
    }

    .notifier-messsage-content {
      background-color: $white;
      @include border-radius(4px);
      @include box-shadow(0 1px 1px #B7C0C7);
      @include box-sizing('border-box');
      margin-top: .5rem;
      padding: 1.5rem;
      position: relative;
    }

    p {
      color: $dark-grey;
      font-weight: $font-weight-light;
      margin-left: 4.5rem;
      position: relative;
      word-wrap: break-word;
    }

    .notifier-icon {
      float: left;
      font-size: 3rem;
    }

    .notifier-close {
      position: absolute;
      right: .5rem;
      top: .3rem;
      height: 12px;
      width: 12px;
      line-height: 12px;
      margin: 0;
      padding: 0;
      z-index: 1;

      .osicon {
        color: $dark-grey;
      }
    }
  }
}

@media (max-width: 768px) {

  .os-notifier {
    width: 40%;
  }
}

@media (max-width: 480px) {

  .os-notifier {
    width: 90%;
  }
}
