@import 'ant-design-vue/es/style/themes/index';

.hb-flow-chart-wraper {
    &.border {
        border: 1px solid @border-color-base;
    }

    .hb-flow-chart-header {
        height: 50px;
        display: flex;
        padding: 0 @padding-md;
        align-items: center;
        justify-content: space-between;
        background-color: @white;
        border-bottom: 1px solid @border-color-base;

        .hb-flow-chart-header-left {
            display: flex;
            height: 100%;
            align-items: center;

            .node-tmp-item {
                margin-left: @padding-md;
                padding: 5px @padding-md;
                border: 1px solid @border-color-base;
                border-radius: @border-radius-base;
                cursor: move;
                user-select: none;

                span {
                    margin-left: @padding-md/2;
                }

                &:hover {
                    box-shadow: 0px 0px 5px 2px @primary-3;
                }
            }

        }

        .hb-flow-chart-header-center {
            display: flex;
            height: 100%;
            align-items: center;

            .action-item {
                margin-left: @padding-md;
                padding: 5px @padding-md;
                border: 1px solid @border-color-base;
                border-radius: @border-radius-base;
            }
        }

        .hb-flow-chart-zoom {
            span {
                margin: 0 @padding-md/2;
            }
        }
    }

    .hb-flow-chart-main {
        background-image: linear-gradient(90deg,
                rgba(0, 0, 0, 0.02) 10%,
                transparent 0),
            linear-gradient(rgba(0, 0, 0, 0.02) 10%, transparent 0);
        background-size: 10px 10px;
        position: relative;
        overflow: hidden;
        outline: none !important;

        .flow-content {
            width: 100%;
            height: 100%;
            position: relative;

            &:focus {
                border: none;
                outline: none;
            }
        }

        .hb-flow-chart-node-item {
            position: absolute;
            min-width: 1;

            .config-info {
                text-align: center;
            }

            .status-box {
                text-align: center;

                .success-status {
                    color: @green-6;

                    i {
                        color: @green-6;
                    }
                }

                .error-status {
                    color: @error-color;

                    i {
                        color: @error-color;
                    }
                }
            }
        }

        .hb-flow-chart-node-item-instance {
            padding: 5px @padding-md;
            position: relative;
            border: 1px solid @border-color-base;
            background-color: #fbf4dc;
            cursor: move;
            overflow: initial;

            &.active {
                border-color: @primary-color;
                background-color: @primary-4;
            }

            &.start {
                border-radius: 50%;
                border: 1px solid @border-color-base;
                background-color: #fbf4dc;
            }

            &.circle {
                width: 100px;
                height: 100px;
                border-radius: 50%;
                display: flex;
                align-items: center;
                justify-content: center;

                .delete-icon {
                    right: 5px;
                    top: 5px;
                }
            }

            .delete-icon {
                position: absolute;
                right: -9px;
                top: -9px;
                width: 18px;
                height: 18px;
                border-radius: 50%;
                border: 1px solid @error-color;
                background-color: @error-color;
                color: @white;
                display: none;
                align-items: center;
                justify-content: center;
                cursor: pointer;

                i {
                    font-size: 12px;
                    font-weight: bold;
                    color: @white;
                }
            }

            &:hover {
                .delete-icon {
                    display: flex;
                }
            }

            .flow-node-drag {
                position: absolute;
                left: 0;
                top: 0;
                z-index: 9;
                width: 100%;
                height: 100%;
                cursor: crosshair;
            }
        }

    }

}