@import '../default/var';
.#{$prefix}-carousel {
    overflow: hidden;
    position: relative;
    &:after {
        clear: both;
        content: "";
        font-size: 0;
        display: block;
        visibility: hidden;
    }
    &-item {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        transition: transform 1s;
        &--card {
            opacity: .8;
            width: 50%;
            &.is-active {
                position: absolute;
                z-index: 10;
                opacity: 1;
            }
        }
    }
    &-bar {
        height: 3px;
        position: absolute;
        z-index: 100;
        &--top,
        &--bottom {
            left: 50%;
            transform: translateX(-50%);
        }
        &--top {
            top: 20px;
        }
        &--bottom {
            bottom: 20px;
        }
        &--left {
            left: 20px;
            top: 50%;
            transform: translate(-50%) rotate(90deg);
            transform-origin: center;
        }
        &--right {
            right: 20px;
            top: 50%;
            transform: translate(50%) rotate(90deg);
            transform-origin: center;
        }
        &-item {
            width: 14px;
            height: 3px;
            border-radius: 3px;
            background-color: $carousel-color-item-back;
            display: inline-block;
            margin: 0 10px;
            vertical-align: top;
            transition: all .3s;
            line-height: 3px;
            cursor: pointer;
            &.active {
                background-color: $carousel-color-item-active-back;
                transform: scaleX(1.8);
                transform-origin: center;
            }
        }
    }
    &-arrow {
        width: 100%;
        height: 40px;
        top: 50%;
        padding: 0 20px;
        left: 50%;
        position: absolute;
        z-index: 10;
        box-sizing: border-box;
        transform: translate(-50%, -50%);
        &-left,
        &-right {
            width: 40px;
            height: 40px;
            line-height: 40px;
            border-radius: 50%;
            text-align: center;
            background: $carousel-color-arrow-back;
            &:hover {
                background: $carousel-color-arrow-hover-back;
            }
            color: $carousel-color-item-active-back;
            cursor: pointer;
            .#{$prefix}-icon-arrow-left,
            .#{$prefix}-icon-arrow-right {
                font-size: 12px;
                font-weight: bold;
            }
        }
        &-left {
            float: left;
        }
        &-right {
            float: right;
        }
    }
}