/**
 * 自定义 radio 样式，为 a-checkbox 添加类
 * 小尺寸：custom-radio
 * 大尺寸：custom-radio-large
 *
 * 自定义 radio-group 样式，为 a-radio-group 添加类
 * 小尺寸：custom-radio-group
 * 大尺寸：custom-radio-group-large
 */
.custom-radio-group .ant-radio-wrapper,
.custom-radio {
  .ant-radio,
  .ant-radio-input,
  .ant-radio-inner {
    width: 16px;
    height: 16px;
    border-radius: 16px;
  }

  .ant-radio + span {
    color: #262626;
  }

  &.ant-radio-wrapper-disabled {
    .ant-radio-checked.ant-radio-disabled {
      .ant-radio-inner {
        background-color: #fff;

        &::after {
          background-color: #d9d9d9;
        }
      }
    }
  }

  .ant-radio-checked {
    .ant-radio-inner {
      border-color: $yili-btn-border-color;
      background-color: #fff;

      &::after {
        border-color: $yili-default-color;
        background-color: $yili-default-color;
      }
    }
  }
}

.custom-radio-group-large .ant-radio-wrapper,
.custom-radio-large {
  .ant-radio,
  .ant-radio-input,
  .ant-radio-inner {
    width: 20px;
    height: 20px;
    border-radius: 20px;
  }

  .ant-radio + span {
    color: #262626;
  }

  &.ant-radio-wrapper-disabled {
    .ant-radio-checked.ant-radio-disabled {
      .ant-radio-inner {
        background-color: #fff;

        &::after {
          background-color: #d9d9d9;
        }
      }
    }
  }

  .ant-radio-checked {
    .ant-radio-inner {
      border-color: $yili-btn-border-color;
      background-color: #fff;

      &::after {
        top: 2px;
        left: 2px;
        width: 14px;
        height: 14px;
        border-color: $yili-default-color;
        border-radius: 14px;
        background-color: $yili-default-color;
      }
    }
  }
}
