.pisell-lowcode-floating-layer-root {
  position: fixed;
  inset: 0;
  z-index: 1000;
  pointer-events: none;
}

.pisell-lowcode-floating-layer-mask {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  transition: opacity 0.2s ease;
}

.pisell-lowcode-floating-layer-content-wrapper {
  position: absolute;
  max-width: 100vw;
  transition: opacity 0.2s ease, transform 0.2s ease;
  will-change: opacity, transform;
  backface-visibility: hidden;
}

.pisell-lowcode-floating-layer-mode-drawer {
  &.pisell-lowcode-floating-layer-right {
    .pisell-lowcode-floating-layer-content-wrapper {
      top: 0;
      right: 0;
      bottom: 0;
    }
  }

  &.pisell-lowcode-floating-layer-left {
    .pisell-lowcode-floating-layer-content-wrapper {
      top: 0;
      bottom: 0;
      left: 0;
    }
  }

  &.pisell-lowcode-floating-layer-top {
    .pisell-lowcode-floating-layer-content-wrapper {
      top: 0;
      right: 0;
      left: 0;
    }
  }

  &.pisell-lowcode-floating-layer-bottom {
    .pisell-lowcode-floating-layer-content-wrapper {
      right: 0;
      bottom: 0;
      left: 0;
    }
  }
}

.pisell-lowcode-floating-layer-mode-modal {
  .pisell-lowcode-floating-layer-content-wrapper {
    top: 0;
    left: 0;
    overflow: hidden;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
  }
}

.pisell-lowcode-floating-layer-content {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 6px 16px 0 rgba(0, 0, 0, 0.08),
    0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05);
}

.pisell-lowcode-floating-layer-header {
  position: relative;
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  box-sizing: border-box;
  min-height: 56px;
  padding: 16px 24px;
  border-bottom: 0;
}

.pisell-lowcode-floating-layer-header-with-close {
  padding-right: 72px;
}

.pisell-lowcode-floating-layer-header-title {
  display: flex;
  min-width: 0;
  flex: 1;
  align-items: center;
}

.pisell-lowcode-floating-layer-title {
  min-width: 0;
  flex: 1;
  color: rgba(0, 0, 0, 0.88);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
}

.pisell-lowcode-floating-layer-close {
  position: absolute;
  top: 50%;
  right: 12px;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: rgba(0, 0, 0, 0.45);
  cursor: pointer;
  line-height: 1;
  transform: translateY(-50%);
}

.pisell-lowcode-floating-layer-close > * {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  line-height: 1;
}

.pisell-lowcode-floating-layer-close-icon {
  position: relative;
  display: block;
  width: 18px;
  height: 18px;
}

.pisell-lowcode-floating-layer-close-icon::before,
.pisell-lowcode-floating-layer-close-icon::after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 2px;
  border-radius: 1px;
  background: currentColor;
  content: '';
  transform-origin: center;
}

.pisell-lowcode-floating-layer-close-icon::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.pisell-lowcode-floating-layer-close-icon::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.pisell-lowcode-floating-layer-close:hover {
  background: rgba(0, 0, 0, 0.06);
  color: rgba(0, 0, 0, 0.88);
}

.pisell-lowcode-floating-layer-extra {
  flex: 0 0 auto;
  margin-inline-start: 12px;
}

.pisell-lowcode-floating-layer-body {
  flex: 1 1 auto;
  min-height: 0;
  padding: 0 24px;
  overflow: auto;
}

.pisell-lowcode-floating-layer-footer {
  flex: 0 0 auto;
  padding: 24px;
  border-top: 1px solid rgba(5, 5, 5, 0.06);
}

.pisell-lowcode-floating-layer-default-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
