@import '../../style/theme/default.less';

@upload-prefix-cls: ~'@{kui-prefix}-upload';

.@{upload-prefix-cls} {
  &-cropper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
  }

  &-grid {
    position: absolute;
    top: 138px;
    left: 50%;
    width: 670px;
    height: 670px;
    transform: translate(-50%, 0);

    &-line {
      position: absolute;
      z-index: 2;
      pointer-events: none;

      &-1 {
        top: 224px;
        left: 0;
        width: 100%;
        height: 1px;
        background-color: rgba(255, 255, 255, 0.4);
      }

      &-2 {
        top: 448px;
        left: 0;
        width: 100%;
        height: 1px;
        background-color: rgba(255, 255, 255, 0.4);
      }

      &-3 {
        top: 0;
        left: 224px;
        width: 1px;
        height: 100%;
        background-color: rgba(255, 255, 255, 0.4);
      }

      &-4 {
        top: 0;
        left: 448px;
        width: 1px;
        height: 100%;
        background-color: rgba(255, 255, 255, 0.4);
      }

      &-5 {
        top: 0;
        left: 0;
        width: 2px;
        height: 100%;
        background-color: #fff;
      }

      &-6 {
        top: 0;
        left: 0;
        width: 100%;
        height: 2px;
        background-color: #fff;
      }

      &-7 {
        top: 0;
        right: 0;
        width: 2px;
        height: 100%;
        background-color: #fff;
      }

      &-8 {
        bottom: 0;
        left: 0;
        width: 100%;
        height: 2px;
        background-color: #fff;
      }
    }

    &-corner {
      position: absolute;
      z-index: 2;
      width: 32px;
      height: 32px;
      pointer-events: none;

      &-1 {
        top: -6px;
        left: -6px;
        border-top: solid 6px #fff;
        border-left: solid 6px #fff;
      }

      &-2 {
        top: -6px;
        right: -6px;
        border-top: solid 6px #fff;
        border-right: solid 6px #fff;
      }

      &-3 {
        right: -6px;
        bottom: -6px;
        border-right: solid 6px #fff;
        border-bottom: solid 6px #fff;
      }

      &-4 {
        bottom: -6px;
        left: -6px;
        border-bottom: solid 6px #fff;
        border-left: solid 6px #fff;
      }
    }
  }

  &-mask {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    pointer-events: none;
    box-shadow: 0 0 999px 999px rgba(0, 0, 0, 0.35);
  }

  &-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    max-width: initial;
    height: auto;
  }

  &-rotate {
    position: absolute;
    bottom: 228px;
    left: 40px;
    font-size: 44px;
    color: #fff;
  }

  &-footer {
    position: absolute;
    bottom: 70px;
    left: 0;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding: 0 50px;
  }

  &-cancel {
    font-family: PingFangSC-Medium, PingFang SC;
    font-size: 34px;
    font-weight: 500;
    color: #fff;
  }

  &-reset {
    font-family: PingFangSC-Regular, PingFang SC;
    font-size: 34px;
    font-weight: 400;
    color: #fff;
    transition: all 0.3s;
  }

  &-done {
    font-family: PingFangSC-Medium, PingFang SC;
    font-size: 34px;
    font-weight: 500;
    color: #fff;
  }

  &-disabled {
    opacity: 0.3;
  }
}
