@import '../styles/themes/themes.less';
@import '../info-box/info-box.less';

.@{bk-prefix}-modal-mask {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
}

.@{bk-prefix}-modal-wrapper {
  position: fixed;
}

.@{bk-prefix}-modal-body {
  height: 100%;
  overflow: hidden;
  background: #fff;
  border-radius: 2px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.@{bk-prefix}-modal-content {
  position: relative;
  max-height: 100vh;
}
.@{bk-prefix}-modal-footer {
  position: relative;
}

.@{bk-prefix}-modal-close {
  position: absolute;
  top: 6px;
  right: 6px;
  display: flex;
  width: 32px;
  height: 32px;
  font-size: 18px;
  color: #979ba5;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: 0.15s;

  &:hover {
    background: #f0f1f5;
  }
}

.modal-fadein-enter-from {
  opacity: 0;
  .@{bk-prefix}-modal-body {
    transform: translateY(-20px);
  }
}

.modal-fadein-enter-to {
  opacity: 1;
  .@{bk-prefix}-modal-body {
    transform: translateY(0);
  }
}

.modal-fadein-leave-from {
  opacity: 1;
  .@{bk-prefix}-modal-body {
    transform: translateY(0);
  }
}

.modal-fadein-leave-to {
  opacity: 0;
  .@{bk-prefix}-modal-body {
    transform: translateY(-20px);
  }
}

.modal-fadein-enter-active,
.modal-fadein-leave-active {
  transition: opacity 0.15s linear;
  .@{bk-prefix}-modal-body {
    transition: transform 0.08s linear;
  }
}

.modal-right-enter-from {
  transform: translateX(100%);
}

.modal-right-enter-to {
  transform: translateX(0);
}

.modal-right-leave-from {
  transform: translateX(0);
}

.modal-right-leave-to {
  transform: translateX(100%);
}

.modal-right-enter-active,
.modal-right-leave-active {
  transition: transform 0.15s ease;
}

.modal-left-enter-from {
  transform: translateX(-100%);
}

.modal-left-enter-to {
  transform: translateX(0);
}

.modal-left-leave-from {
  transform: translateX(0);
}

.modal-left-leave-to {
  transform: translateX(-100%);
}

.modal-left-enter-active,
.modal-left-leave-active {
  transition: transform 0.15s ease;
}
