@steps-prefix-cls: ~"@{css-prefix}steps";

.@{steps-prefix-cls} {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    width: 100%;
    font-size: 0;
    line-height: 1.8;

    &-item {
        display: inline-block;
        position: relative;
        vertical-align: top;
        -webkit-box-flex: 1;
        -ms-flex: 1;
        flex: 1;
        overflow: hidden;
        &:last-child{
            -webkit-box-flex: 0;
            -ms-flex: 0;
            flex: none;
        }

        &.@{steps-prefix-cls}-status-wait {
            .@{steps-prefix-cls}-head-inner {
                background-color: @gray-100;
                border-color:@gray-100;
                > .@{steps-prefix-cls}-icon, span {
                    color: @steps-wait-title-color;
                }
            }
            .@{steps-prefix-cls}-title {
                color: @steps-wait-title-color;
            }
            .@{steps-prefix-cls}-content {
                // color: @color-complementary-5;
                color: @steps-wait-title-color;
            }
            .@{steps-prefix-cls}-tail > i {
                // background-color: @color-complementary-7;
                background: @steps-tail-color;
            }
        }

        &.@{steps-prefix-cls}-status-process {
            .@{steps-prefix-cls}-head-inner {
                border-color: @primary-color;
                background-color: @primary-color;
                > .@{steps-prefix-cls}-icon, span {
                    color: @color-functional-white;
                    cursor: pointer;
                }
            }
            .@{steps-prefix-cls}-title {
                color: @steps-main-title-color;
                &:hover{
                    color:@color-brand-hover;
                }
                &:active{
                    color: @color-brand-press;
                }
            }
            .@{steps-prefix-cls}-content {
                // color: @color-complementary-5;
                color: @steps-wait-title-color;
            }
            .@{steps-prefix-cls}-tail > i {
                // background-color: @color-complementary-7;
                background: @steps-tail-color;
            }
        }

        &.@{steps-prefix-cls}-status-finish {
            .@{steps-prefix-cls}-head-inner {
                background-color: @steps-main-bg-color;
                border-color:  @steps-main-bg-color;
                > .@{steps-prefix-cls}-icon, span {
                    color: @color-brand-primary;
                    cursor: pointer;
                }
            }
            .@{steps-prefix-cls}-tail > i:after {
                width: 100%;
                // background: @primary-color;
                background: @steps-tail-color;
                transition: all @transition-time @ease-in-out;
                opacity: 1;
            }
            .@{steps-prefix-cls}-title {
                color: @steps-main-title-color;
                &:hover{
                    color:@color-brand-hover;
                }
                &:active{
                    color: @color-brand-press;
                }
            }
            .@{steps-prefix-cls}-content {
                // color: @color-complementary-5;
                color: @steps-wait-title-color;
            }
        }

        &.@{steps-prefix-cls}-status-error {
            .@{steps-prefix-cls}-head-inner {
                background-color: @error-color;
                border-color: @error-color;
                > .@{steps-prefix-cls}-icon {
                    color: @color-functional-white;
                }
            }
            .@{steps-prefix-cls}-title {
                color: @error-color;
            }
            .@{steps-prefix-cls}-content {
                color: @error-color;
            }
            .@{steps-prefix-cls}-tail > i {
                background-color: @color-complementary-7;
            }
        }

        &.@{steps-prefix-cls}-next-error {
            .@{steps-prefix-cls}-tail > i,
            .@{steps-prefix-cls}-tail > i:after {
                background-color: @error-color;
            }
        }

        &.@{steps-prefix-cls}-custom {
            .@{steps-prefix-cls}-head-inner {
                // background: none;
                // border: 0;
                width: 28px;
                height: 28px;
                > .@{steps-prefix-cls}-icon {
                    font-size: 16px;
                    top: 0px;
                    width: 16px;
                    height: 16px;

                    &.haloe-icon {
                        font-size: 16px;
                    }
                }
            }
            &.@{steps-prefix-cls}-status-process {
                .@{steps-prefix-cls}-head-inner > .@{steps-prefix-cls}-icon {
                    color: @primary-color;
                }
            }
        }

        &.@{steps-prefix-cls}-isBg.@{steps-prefix-cls}-status-wait {
            .@{steps-prefix-cls}-head-inner {
              background-color: @color-functional-white;
            }
        }
    }
    &-item:last-child &-tail{
        display: none;
    }

    .@{steps-prefix-cls}-head,
    .@{steps-prefix-cls}-main {
        position: relative;
        display: inline-block;
        // vertical-align: top;
    }
    .@{steps-prefix-cls}-head {
        background: @color-bg-card;
        border-color:@color-brand-primary
    }

    .@{steps-prefix-cls}-head-inner {
        display: block;
        width: 28px;
        height: 28px;
        line-height: 24px;
        margin-right: 8px;
        text-align: center;
        // border: 1px solid @color-complementary-7;
        border: 1px solid @steps-tail-color;
        border-radius: 50%;
        font-size: 14px;
        transition: background-color @transition-time @ease-in-out;

        > .@{steps-prefix-cls}-icon {
            line-height: 1;
            position: relative;

            &.haloe-icon {
                font-size: 16px;
                &-ios-checkmark-empty,
                &-ios-close-empty {
                    font-weight: bold;
                }
            }
        }
    }

    .@{steps-prefix-cls}-custom .haloe-icon {
      font-size: 16px!important;
    }

    .@{steps-prefix-cls}-main {
        margin-top: 2.5px;
        display: inline;
    }
    .@{steps-prefix-cls}-custom .@{steps-prefix-cls}-title{
        margin-top: 2.5px;
    }

    .@{steps-prefix-cls}-title {
        display: inline-block;
        margin-bottom: 4px;
        padding-right: 10px;
        font-size: 14px;
        font-weight: 400;
        color: @color-complementary-3;
        background: @color-bg-card;

        > a:first-child:last-child {
            color: @color-complementary-5;
        }
    }
    .@{steps-prefix-cls}-item-last {
        .@{steps-prefix-cls}-title {
            padding-right: 0;
            width: 100%;
        }
    }
    .@{steps-prefix-cls}-content {
        font-size: 12px;
        color: @color-complementary-5;
    }
    .@{steps-prefix-cls}-tail {
        width: 100%;
        padding: 0 10px;
        position: absolute;
        left: 0;
        top: 13px;
        > i {
            display: inline-block;
            width: 100%;
            height: 1px;
            vertical-align: top;
            background: @color-complementary-7;
            border-radius: 1px;
            position: relative;
            &:after {
                content: '';
                width: 0;
                height: 100%;
                background: @color-complementary-7;
                opacity: 0;
                position: absolute;
                top: 0;
            }
        }
    }

    &.@{steps-prefix-cls}-small {
        .@{steps-prefix-cls}-head-inner {
            width: 18px;
            height: 18px;
            line-height: 16px;
            margin-right: 10px;
            text-align: center;
            border-radius: 50%;
            font-size: 12px;

            > .@{steps-prefix-cls}-icon.haloe-icon {
                font-size: 16px;
                top: 0;
            }
        }
        .@{steps-prefix-cls}-main {
            margin-top: 0;
        }
        .@{steps-prefix-cls}-title {
            margin-bottom: 4px;
            margin-top: 0;
            color: @color-complementary-3;
            font-size: 12px;
            font-weight: bold;
        }
        .@{steps-prefix-cls}-content {
            font-size: 12px;
            color: @color-complementary-5;
            padding-left: 30px;
        }
        .@{steps-prefix-cls}-tail {
            top: 8px;
            padding: 0 8px;
            > i {
                height: 1px;
                width: 100%;
                border-color:@color-brand-press;
                border-radius: 1px;
            }
        }
    }

    &.@{steps-prefix-cls}-small .@{steps-prefix-cls}-item.@{steps-prefix-cls}-custom .@{steps-prefix-cls}-head-inner,
    .@{steps-prefix-cls}-item.@{steps-prefix-cls}-custom.@{steps-prefix-cls}-status-process .@{steps-prefix-cls}-head-inner {
        border-color: @primary-color;
        background-color: @primary-color;
        > .@{steps-prefix-cls}-icon, span {
            color: @color-functional-white;
            cursor: pointer;
        }
    }
    .@{steps-prefix-cls}-item.@{steps-prefix-cls}-custom.@{steps-prefix-cls}-status-finish .@{steps-prefix-cls}-head-inner {
        background-color: @steps-main-bg-color;
        border-color:  @steps-main-bg-color;
        > .@{steps-prefix-cls}-icon, span {
            color: @color-brand-primary;
            cursor: pointer;
        }
    }
}

.@{steps-prefix-cls}-vertical {
    display: block;
    .@{steps-prefix-cls}-item {
        display: block;
        overflow: visible;
    }

    .@{steps-prefix-cls}-tail {
        position: absolute;
        left: 13px;
        top: 0;
        height: 100%;
        width: 1px;
        padding: 34px 0 4px 0;
        > i {
            height: 100%;
            width: 1px;
            &:after {
                height: 100%;
                width: 0;
            }
        }
    }

    .@{steps-prefix-cls}-status-finish {
        .@{steps-prefix-cls}-tail > i:after {
            height: 100%;
        }
    }

    .@{steps-prefix-cls}-head {
        float: left;
        &-inner {
            margin-right: 16px;
        }
    }

    .@{steps-prefix-cls}-main {
        min-height: 47px;
        overflow: hidden;
        display: block;
        .@{steps-prefix-cls}-title {
            line-height: 26px;
        }
        .@{steps-prefix-cls}-content {
            padding-bottom: 12px;
            padding-left: 0;
        }
    }

    .@{steps-prefix-cls}-custom .@{steps-prefix-cls}-icon {
        left: 4px;
    }
    &.@{steps-prefix-cls}-small .@{steps-prefix-cls}-custom .@{steps-prefix-cls}-icon {
        left: 0;
    }
}

.@{steps-prefix-cls}-vertical.@{steps-prefix-cls}-small {
    .@{steps-prefix-cls}-tail {
        position: absolute;
        left: 9px;
        top: 0;
        padding: 26px 0 4px 0;
        > i {
            height: 100%;
        }
    }

    .@{steps-prefix-cls}-title {
        line-height: 18px;
    }
}

.@{steps-prefix-cls}-horizontal {
    &.@{steps-prefix-cls}-hidden {
        visibility: hidden;
    }
    .@{steps-prefix-cls}-content {
        //max-width: 100px;
        padding-left: 35px;
    }
    .@{steps-prefix-cls}-item:not(:first-child) .@{steps-prefix-cls}-head {
        padding-left: 10px;
        margin-left: -10px;
    }
}

.@{steps-prefix-cls}-title {
  .@{steps-prefix-cls}-main {
    display: block !important;
  }
}

.@{steps-prefix-cls}-noNumber {
    .@{steps-prefix-cls}-item {
        &.@{steps-prefix-cls}-status-finish {
            .@{steps-prefix-cls}-head-inner {
                background-color: @color-brand-primary;
                border-width: 1.5px;
                border-color:@color-brand-primary;
            }
        }
        &.@{steps-prefix-cls}-status-wait {
            .@{steps-prefix-cls}-head-inner {
                background-color: @gray-300;
                border-width: 1.5px;
                border-color:@gray-300;
            }
        }
    }

    .@{steps-prefix-cls}-head-inner {
        width: 10px;
        height: 10px;
        margin: 7px 10px 0 0;
    }

    &.@{steps-prefix-cls}-vertical {
        .@{steps-prefix-cls}-tail {
            width: 70px;
            padding-top: 24px;
            left: 4px;
        }
        .@{steps-prefix-cls}-main {
            height: 90px;
            line-height: 20px;
            margin-top: 0px;
        }
    }
  }