$lightGray: #dadada;
$white: #fff;
$darkGray: #333;
$shadow: rgba(0,0,0,0.2);
$primary: #4C66BE;

.react-select-popover {
  position: relative;
  display: block;

  .hidden-select-box {
    display: none;
  }

  .popover {
    position: absolute;
    left: 0;
    box-sizing: border-box;
    width: 100%;
    max-width: 28em;
    padding: 1em;
    border: 1px solid $lightGray;
    background: $white;
    margin-top: 20px;

    .tag {
      cursor: pointer;
    }

    .empty-list {
      color: #ccc;
      text-transform: uppercase;
      text-align: center;
      font-size: 12px;
      letter-spacing: 1px;
      display: block;
      font-weight: 100;
      margin: 10px 0;
    }
  }

  .popover, .popover:before {
    box-shadow: 0 0 2px $shadow;
  }

  .popover:before,
  .popover:after {
    content: '';
    display: block;
    position: absolute;
    width: 15px;
    height: 15px;
    border: 1px solid $lightGray;
    background: $white;
    transform: rotate(45deg);
  }

  .popover:before {
    z-index: -1;
  }

  .popover.arrow-top:before,
  .popover.arrow-top:after {
    bottom: 100%;
    left: 20px;
    margin-bottom: -7px;
    border-bottom: 0;
    border-right: 0;
  }

  .select-input {
    width: 100%;
    max-width: 28em;
    min-height: 30px;
    border: 1px solid $lightGray;
    border-radius: 2px;
    background: $white;
    padding: 10px;
    margin: 0;
    padding: 0;

    &.active {
      border-color: #91A0D3;
      box-shadow: 0 0 5px rgba(126, 146, 208, 0.4);
    }

    .empty-list {
      color: #ccc;
      display: inline-block;
      line-height: 12px;
      padding-left: 10px;
      font-size: 12px;
    }

    .search-input {
      width: 50px;
      height: 20px;
      margin: 0;
      padding: 0;
      line-height: 20px;
      margin: 10px;
      display: inline-block;
      outline: none;
      font-size: 14px;
      border: none;
      background: transparent;
      box-shadow: none;
      color: $darkGray;
    }
  }

  .tag {
    display: inline-block;
    padding: 5px 8px;
    border-radius: 3px;
    line-height: 15px;
    font-size: 15px;
    margin: 5px;

    background-color: $lightGray;
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#eeeeee', endColorstr='#f4f4f4', GradientType=0 );
    background-image: linear-gradient(to bottom, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%);

    color: $darkGray;
    box-shadow: 0 0 2px $white inset, 0 1px 2px $shadow;
    border: 1px solid darken(#f0f0f0, 20%);

    &.active {
      border-color: $primary;
      color: $primary;
      button {
        color: $primary;
      }
    }

    button {
      background: none;
      border: none;
      outline: none;
      cursor: pointer;
      color: lighten($darkGray, 40%);
      font-size: 14px;
      line-height: 12px;
      padding: 0 6px 0 2px;
      position: relative;
      top: -1px;

      &:hover {
        color: $darkGray;
      }
    }
  }
}
