@import "../variables.less";

.@{prefix}search-form-model {
  //padding: 0;
  background: #fff;
  &--default {
    padding: 12px 12px 0;
    margin-bottom: -12px;
    //background: #fafafa;
    //padding-top: 12px;
  }
  // 快捷表单外壳
  &-forms-wrap {
    display: flex;
    align-items: center;
    //padding-bottom: 12px;
    .ant-form-item{
      //line-height: 30px;
      margin:0 8px 12px 0;
      //margin-bottom: 0px !important;
    }
  }
  .show-label-wrap {
    display: flex;
    top: 0 !important;
    // 针对 拥有 a-input-group compact 类型的 itemType 样式进行整合
    & > .ant-input-group-compact {
      position: relative;
      top: 0;
    }
  }
  // defaultForm label 样式
  .item-label {
    width: max-content;
    min-width: max-content;
    height: 30px;
    line-height: 28px;
    padding: 0 10px;
    border: 1px solid @xpb-border-color_1;
    border-right: 0;
    background: #fff;
    //background: #fafafa;
  }

  // input 类型 defaultForm render 有 前缀 | 后缀
  .default-input {
    &.ant-input-group-wrapper {
      top: -2px;
    }
  }

  // compact 类型 外壳样式
  .render-compact-wrap {
    display: flex !important;
    top: 0 !important;
  }

  // 提示标签
  &-tags {
    .ant-tag {
      //height: 30px;
      line-height: 28px;
      background-color: #fff;
      border-radius: 2px;
      border-color: @xpb-color-primary; // rgba(0, 123, 252, 0.65);
      padding: 0 10px;
      margin-right: 8px;
      margin-bottom: 12px;
    }
    .icon-delete {
      margin-left: 10px;
    }
    // 单个标签 多个数据展示的 popover外壳
    &_popover {
      .ant-popover-inner-content {
        padding: 4px 0 4px 12px;
        width: max-content;
        min-width: 70px;
      }
      .local_list {
        .item {
          width: 150px;
          padding-right: 12px;
          //display: flex;
          //align-items: center;
          //min-height: 30px;
          //height: 30px;
          line-height: 30px;
          color: rgba(0, 0, 0, 0.85);
        }
      }
    }
  }
  // 快捷按钮
  .icon-button-box {
    .xpb-iconfont {
      font-size: 16px;
    }
    margin-right: 8px;
    &:last-child {
      margin-right: 0;
    }
    .ant-btn{
      padding: 0;
      width: 30px;
      line-height:30px;
      text-align: center;
      font-size: 16px;
      color: rgba(0, 0, 0, 0.45);
      &:hover {
        color: @xpb-color-primary;
      }
    }
  }

  // 更多表单弹窗外壳
  .more-form {
    &-wrap {
      position: relative;
      display: inline-flex;
    }
    &-pop {
      position: absolute;
      top: 45px;
      //padding: 12px 16px;
      color: rgba(0, 0, 0, 0.65);
      z-index: 99;
      background-color: #fff;
      background-clip: padding-box;
      border-radius: 2px;
      box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
      left: -160px;
      //transform: translateX(-50%);
      &::after {
        content: "";
        position: absolute;
        display: block;
        width: 9px;
        height: 9px;
        top: -4.5px;
        left: 50%;
        background-color: #fff;
        box-shadow: -2px -2px 5px rgba(0, 0, 0, 0.06);
        transform: translateX(-50%) rotate(45deg);
      }
      // 定位方向
      &.is-left{
        left: 0;
        transform: none;
        &::after{
          left: 15px;
        }
      }
      &.is-right{
        left: -320px;
        transform: none;
        &::after{
          left: auto;
          right: 6px
        }
      }
      // forms 内容区
      &_content {
        max-height: 336px;
        overflow-y: auto;
        padding: 0 16px;
        .more-item {
          display: flex;
          align-items: center;
          margin-top: 12px;
          &_label {
            color: rgba(0,0,0,0.85);
            width: 82px;
            padding-right: 8px;
            //width: 74px;
            text-align: right;
            //// 修正 ... 看不到的情况
            //&.text-overflow_ellipsis_line_2 {
            //  text-align: left;
            //}
          }
          &_value-wrap {
            //padding-left: 8px;
            flex: 1;
          }
        }
      }
      // 按钮区
      &_button {
        box-shadow: 0 2px 4px 5px rgba(238, 238, 238, 0.5);
        margin-top: 12px;
        padding: 6px 16px;
        text-align: right;
      }
    }

  }
}