/*
 * Copyright (c) 2016-present, Parse, LLC
 * All rights reserved.
 *
 * This source code is licensed under the license found in the LICENSE file in
 * the root directory of this source tree.
 */
@import 'stylesheets/globals.scss';

.dropdown {
  position: relative;
  background: $inputBackgroundColor;
  font-size: 16px;
  height: 80px;
  width: 100%;
  overflow: hidden;
}

.dropdown, .menu {
  text-align: left;
  cursor: pointer;
  white-space: nowrap;
}

.menu {
  max-height: 215px;
  border: 1px solid $blue;
  background: white;
  overflow: auto;

  button {
    @include buttonReset;
    display: block;
    width: 100%;
  }

  .option {
    color: $blue;
    border-bottom: 1px solid $borderGrey;

    &:hover {
      background: rgba(0,0,0,0.1);
    }
  }

  > *:last-child .option {
    border-bottom: none;
  }
}

.current {
  text-align: center;
  height: 80px;

  &:not(.hideArrow){
    &:after {
      @include arrow('down', 12px, 8px, rgba(0,0,0,0.3));
      position: absolute;
      content: '';
      top: 36px;
      right: 20px;
    }
  }

  .option, .placeHolder {
    height: 80px;
    line-height: 80px;
  }

  .placeHolder {
    color: $secondaryTextColor
  }
}

.option {
  line-height: 50px;
  padding: 0 14px 0 14px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.disabled {
  cursor: default;

  .current:after {
    display: none;
  }

  .option {
    padding: 0 14px;
  }
}
