@normal-steps-desc-height: 68px;
@normal-steps-height: 48px;
@small-steps-height: 36px;
@color-white: #fff;
@container-padding-left: 40px;

.@{steps-prefix-cls}-tntd-navigation.@{steps-prefix-cls}-horizontal{
    overflow: hidden;
    padding-top: 12px;

    // 小尺寸
    &.@{steps-prefix-cls}-small {
      .@{steps-prefix-cls}-item {
        height: @small-steps-height;
        min-height: @small-steps-height;
        &-container {
          margin-left: 0;
          padding-bottom:0;
        }

        &::after {
            content: '';
            border-top: @small-steps-height/2 solid transparent;
            border-bottom: @small-steps-height/2 solid transparent;
            border-left: @small-steps-height/2 solid @border-color-split;
            right: -@small-steps-height/2;
          }

        &::before {
            content: '';
            border-top: @small-steps-height/2 solid @border-color-split;
            border-bottom: @small-steps-height/2 solid @border-color-split;
            border-left: @small-steps-height/2 solid @color-white;
        }
      }
    }

    // 默认尺寸
    .@{steps-prefix-cls}-item {
      overflow: visible;
      position: relative;
      text-align: left;
      display: flex;
      min-height: @normal-steps-height;
      &:not(:last-of-type){
        margin-right: 2px !important;
      }
      background: @border-color-split;
      width : 0 !important;
      &-container {
        display: flex;
        align-items: center;
        width: 100%;
        text-align: left;
        padding-left: @container-padding-left + 24px;
        padding-bottom: 0;
        margin-left: 0;
        transition: opacity 0.3s;
        z-index: 11;

        .@{steps-prefix-cls}-item-content {
          max-width: calc(100% - @container-padding-left);
        }

        .@{steps-prefix-cls}-item-title {
          max-width: 100%;
          padding-right: 0;
          overflow: hidden;
          white-space: nowrap;
          text-overflow: ellipsis;
          line-height: 14px;
          font-size: 14px;
          font-weight: normal;
          color:@text-color;
          &::after {
            display: none;
          }
          .@{steps-prefix-cls}-item-subtitle{
            color:fade(@text-color,80%);
          }
        }

        .@{steps-prefix-cls}-item-description{
            margin-top: 5px;
            line-height: 14px;
            font-size: 12px;
            max-width: 100%;
            overflow: hidden;
            white-space: nowrap;
            text-overflow: ellipsis;
        }
    }

    &:not(.@{steps-prefix-cls}-item-active) {
        .@{steps-prefix-cls}-item-container[role='button'] {
          cursor: pointer;
          &:hover {
            opacity: 0.85;
          }
        }
    }

    &:last-child {
        flex: 1;
        &::after {
          display: none;
        }
    }

    &:first-child {
        &.@{steps-prefix-cls}-item-container{
            padding-left: @container-padding-left;
        }
        &:before {
            display: none;
        }
    }

    &::after {
        content: '';
        display: block;
        border:none;
        border-top: @normal-steps-height/2 solid transparent;
        border-bottom: @normal-steps-height/2 solid transparent;
        border-left: @normal-steps-height/2 solid @border-color-split;
        position: absolute;
        right: -@normal-steps-height/2;
        top: 0;
        z-index: 10;
        transform: rotate(0deg);
        margin-top:0;
        margin-left: 0;
    }

    &::before {
        content: '';
        display: block;
        background: none;;
        border-top: @normal-steps-height/2 solid @border-color-split;
        border-bottom: @normal-steps-height/2 solid @border-color-split;
        border-left: @normal-steps-height/2 solid @color-white;
        position: absolute;
        height: 0;
        width: 0;
        left: 0px;
        top: 0;
        transition: none;
    }

    &-finish{
        background-color:  @steps-nav-finish-color !important;
        border-color: @steps-nav-finish-color !important;
        &::before{
            border-top-color:  @steps-nav-finish-color !important;
            border-bottom-color:  @steps-nav-finish-color !important;
        }
        &::after{
            border-left-color:  @steps-nav-finish-color !important;
        }
        .@{steps-prefix-cls}-item-title,
        .@{steps-prefix-cls}-item-subtitle{
            color:@color-white !important;
        }
        .@{steps-prefix-cls}-item-description{
            color:fade(@color-white,80%) !important;
        }
    }

    &-process{
        background-color:  @steps-nav-active-color !important;
        border-color: @steps-nav-active-color !important;
        &::before{
            border-top-color:  @steps-nav-active-color !important;
            border-bottom-color:  @steps-nav-active-color !important;
        }
        &::after{
            border-left-color:  @steps-nav-active-color !important;
        }
        .@{steps-prefix-cls}-item-title,
        .@{steps-prefix-cls}-item-subtitle{
            color:@color-white !important;
        }
        .@{steps-prefix-cls}-item-description{
            color:fade(@color-white,80%) !important;
        }
      }
    }

    // 存在描述的导航步骤
    &.@{steps-prefix-cls}-tntd-navigation-contain-desc{
        .@{steps-prefix-cls}-item {
            height: @normal-steps-desc-height;
            &::after {
                content: '';
                border-top: @normal-steps-desc-height/2 solid transparent;
                border-bottom: @normal-steps-desc-height/2 solid transparent;
                border-left: @normal-steps-desc-height/2 solid @border-color-split;
                position: absolute;
                right: -@normal-steps-desc-height/2;
            }
            &::before {
                content: '';
                border-top: @normal-steps-desc-height/2 solid @border-color-split;
                border-bottom: @normal-steps-desc-height/2 solid @border-color-split;
                border-left: @normal-steps-desc-height/2 solid @color-white;
                position: absolute;
                height: 0;
                width: 0;
                left: 0px;
                top: 0;
                transition: none;
            }
        }
    }

    // icon控制
    .@{steps-prefix-cls}-item-icon{
        display: none;
    }
    .@{steps-prefix-cls}-item.@{steps-prefix-cls}-item-active{
        .@{steps-prefix-cls}-item-container{
            border-top:1px solid @steps-nav-active-color !important;
            border-bottom:1px solid @steps-nav-active-color !important;
        }
        &.ant-step-tntd-navigation-desc{
            .@{steps-prefix-cls}-item-icon{
                margin-top: -18px;
            }
        }
        .@{steps-prefix-cls}-item-icon{
            .@{steps-prefix-cls}-icon{
                display: none;
            }
            display: inline-block;
            width: 6px;
            height:6px;
            border-radius: 100%;
            background: @color-white;
            border: 1px solid @color-white;
            margin-right: 6px;
        }
    }
}

  @media (max-width: @screen-xs) {
      > .@{steps-prefix-cls}-item {
        margin-right: 0 !important;
        &::before {
          display: none;
        }
        &.@{steps-prefix-cls}-item-active::before {
          top: 0;
          right: 0;
          left: unset;
          display: block;
          width: 3px;
          height: calc(100% - 24px);
        }
        &::after {
          position: relative;
          top: -2px;
          left: 50%;
          display: block;
          width: 8px;
          height: 8px;
          margin-bottom: 8px;
          text-align: center;
          transform: rotate(135deg);
        }
        > .@{steps-prefix-cls}-item-container > .@{steps-prefix-cls}-item-tail {
          visibility: hidden;
        }
      }
    }

