.dg-search {
  position: relative;
  box-sizing: border-box;

  & &__component {
    &,
    &.el-input__inner {
      width: 220px;
    }
  }

  &-form &__component {
    width: 180px;
  }

  &-form {
    display: flex;

    &.el-form--inline {
      .el-form-item__label {
        font-size: 12px;
      }
    }

    .el-form-item--mini.el-form-item {
      margin-bottom: 12px;
    }
  }

  &-optional {
    .el-form-item__content {
      width: 100%;
      display: flex;
      align-items: flex-end;
    }

    & &__select {
      flex: 0 0 108px;
      width: 108px;
      vertical-align: top;
      margin-right: -1px;

      .el-input__inner {
        border-top-right-radius: 0;
        border-bottom-right-radius: 0;
        vertical-align: top;
      }
    }

    & &__component.dg-editor {
      width: 180px;
      flex: 0 0 180px;
      vertical-align: top;

      [class*='__inner'],
      &[class*='__inner'] {
        border-top-left-radius: 0;
        border-bottom-left-radius: 0;
        vertical-align: top;
      }
    }

    &__more.el-button {
      margin-right: 12px;
      margin-bottom: 12px;

      .el-icon {
        font-size: 14px;
      }
    }
  }

  &-result {
    line-height: 20px;
    margin-bottom: 12px;
    &__label,
    &__empty {
      font-size: 12px;
      color: #606266;
    }

    &__empty {
      color: #909399;
    }

    & &__clear {
      margin-left: 8px;
      padding: 3px 6px;
    }

    &-item {
      & + & {
        margin-left: 8px;
      }
    }
  }

  &-panel {
    .el-popover {
      right: 4px;
      left: 4px;
      top: 100%;
      padding: 16px;
    }

    &-form {
      display: grid;
      grid-template-columns: repeat(auto-fill, (220px + 120px));
      column-gap: 12px;
      justify-content: space-around;
    }

    &-form__submit.el-form-item {
      grid-column: 1 / -1;
      margin-bottom: 0;
      margin-top: 24px;
      text-align: center;

      .el-form-item__content {
        margin-left: 0 !important;
      }
    }
  }

  &__spacer {
    flex: 1;
  }
}
