$--selectRole-base-font-size: 12px;
$--selectRole-title-font-size: 14px;
$--selectRole-base-font-weight: bold;
$--selectRole-split-line-color: #dcdfe6;
$--selectRole-notice-font-color: #b2b2b2;
$--selectRole-primary-font-color: #027aff;
$--selectRole-box-hover-bgColor: #f5f7fa;
$--selectRole-box-active-bgColor: #e6f2ff;
$--selectRole-box-border-radius: 2px;
$--selectRole-box-border-color: #ebeef5;
$--selectRole-expend-icon-color: #dcdfe6;
$--selectRole-sign-primary-bgColor: #027aff;
$--selectRole-sign-orange-bgColor: #f5a623;
$--selectRole-input-border-color: #e4e7ed;
$--selectRole-input-hover-border-color: #c0c4cc;
$--selectRole-base-height: 32px;

.select-role-modal {
  .header {
    display: flex;
    align-items: center;
    .header-title {
      flex: 0 0 72px;
      width: 72px;
      margin-right: 12px;
      font-size: $--selectRole-title-font-size;
      font-weight: $--selectRole-base-font-weight;
      border-right: 1px solid $--selectRole-split-line-color;
    }
    .header-search-input {
      .el-input__inner {
        padding-left: 30px !important;
        border: 0;
      }
      .el-input__prefix {
        display: flex;
        align-items: center;
        justify-content: center;
      }
      .x-svg-icon .svg-icon {
        width: 18px !important;
        height: 18px !important;
      }
    }
  }
  .main {
    margin: -12px 0;
    .x-loading {
      width: 100% !important;
    }
  }
  .selected-block {
    display: flex;
    height: 120px;
    padding: 16px 0;
    margin: 0 -6px;
    overflow-y: auto;
    border-top: 1px solid $--selectRole-box-border-color;
    box-sizing: border-box;
    flex-wrap: wrap;
    .role-tag {
      margin: 0 6px 12px;
    }
  }
  .footer {
    display: flex;
    .footer-notice {
      display: flex;
      align-items: center;
      justify-items: flex-start;
      flex: 1;
      .footer-notice-text {
        font-size: $--selectRole-base-font-size;
        color: $--selectRole-notice-font-color;
      }
      .footer-link-addrole {
        margin-left: 32px;
      }
    }
  }
}

.select-role-modal {
  .header {
    display: flex;
    align-items: center;
    .header-title {
      flex: 0 0 72px;
      width: 72px;
      margin-right: 12px;
      font-size: $--selectRole-title-font-size;
      font-weight: $--selectRole-base-font-weight;
      border-right: 1px solid $--selectRole-split-line-color;
    }
    .header-search-input {
      .el-input__inner {
        padding-left: 30px !important;
        border: 0;
      }
      .el-input__prefix {
        display: flex;
        align-items: center;
        justify-content: center;
      }
      .x-svg-icon .svg-icon {
        width: 18px !important;
        height: 18px !important;
      }
    }
  }
  .main {
    margin: -12px 0;
  }
  .selected-block {
    display: flex;
    height: 120px;
    padding: 16px 0;
    margin: 0 -6px;
    overflow-y: auto;
    border-top: 1px solid $--selectRole-box-border-color;
    box-sizing: border-box;
    flex-wrap: wrap;
    .role-tag {
      margin: 0 6px 12px;
    }
  }
  .footer {
    display: flex;
    .footer-notice {
      display: flex;
      align-items: center;
      justify-items: flex-start;
      flex: 1;
      .footer-notice-text {
        font-size: $--selectRole-base-font-size;
        color: $--selectRole-notice-font-color;
      }
      .footer-link-addrole {
        margin-left: 32px;
      }
    }
  }
}

.role-option {
  display: flex;
  padding: 10px 0;
  cursor: pointer;
  align-items: center;
  > div {
    display: flex;
    height: 24px;
    font-size: $--selectRole-base-font-size;
    line-height: 24px;
    align-items: center;
  }
  &:hover {
    .role-name {
      color: $--selectRole-primary-font-color;
    }
  }
  &:hover {
    background-color: $--selectRole-box-hover-bgColor;
  }
  .role-sign {
    color: #fff;
    text-align: center;
    border-radius: $--selectRole-box-border-radius;
    justify-content: center;
    flex: 0 0 42px;
    &.role-sign-tenant {
      background-color: $--selectRole-sign-primary-bgColor;
    }
    &.role-sign-app {
      background-color: $--selectRole-sign-orange-bgColor;
    }
  }
  .role-name {
    margin-left: 12px;
    flex: 1;
  }
  .role-option-icon {
    margin: 0 10px;
    .radio, .checkbox {
      color: $--selectRole-notice-font-color;
    }
    .radio-active, .checkbox-active {
      color: $--selectRole-primary-font-color;
    }
  }
}

.role-tag {
  display: flex;
  height: 24px;
  padding: 0 6px;
  line-height: 24px;
  background-color: $--selectRole-box-hover-bgColor;
  border-radius: 12px;
  align-items: center;
  .role-name {
    padding-left: 8px;
    font-size: $--selectRole-base-font-size;
  }
  .role-tag-close {
    display: flex;
    width: 20px;
    height: 24px;
    line-height: 24px;
    color: $--selectRole-notice-font-color;
    align-items: center;
    justify-content: center;
    .pointer {
      width: 16px;
      height: 16px;
    }
  }
}
