.gdrts-stars-rating {
    &:not(.gdrts-state-active) {
        cursor: default;
    }

    &.gdrts-state-active .gdrts-stars-empty:not(.gdrts-vote-saving) {
        cursor: pointer;
    }

    .gdrts-labels {
        display: none;
    }
}

.gdrts-with-image {
    position: relative;

    .gdrts-stars-empty,
    .gdrts-stars-active,
    .gdrts-stars-current {
        display: inline-block;
        height: 100%;
        position: absolute;
        left: 0;
        top: 0;
    }

    &.gdrts-image-star {
        .gdrts-stars-empty, .gdrts-stars-active, .gdrts-stars-current {
            background: url('stars/star.png') repeat-x;
            background-size: 40px;
        }
    }

    &.gdrts-image-heart {
        .gdrts-stars-empty, .gdrts-stars-active, .gdrts-stars-current {
            background: url('stars/heart.png') repeat-x;
            background-size: 40px;
        }
    }

    &.gdrts-image-snowflake {
        .gdrts-stars-empty, .gdrts-stars-active, .gdrts-stars-current {
            background: url('stars/snowflake.png') repeat-x;
            background-size: 40px;
        }
    }

    &.gdrts-image-christmas {
        .gdrts-stars-empty, .gdrts-stars-active, .gdrts-stars-current {
            background: url('stars/christmas.png') repeat-x;
            background-size: 40px;
        }
    }

    &.gdrts-image-oxygen {
        .gdrts-stars-empty, .gdrts-stars-active, .gdrts-stars-current {
            background: url('stars/oxygen.png') repeat-x;
            background-size: 40px;
        }
    }

    &.gdrts-image-crystal {
        .gdrts-stars-empty, .gdrts-stars-active, .gdrts-stars-current {
            background: url('stars/crystal.png') repeat-x;
            background-size: 40px;
        }
    }

    .gdrts-stars-empty {
        width: 100%;
        z-index: 0;

        background-position: left bottom !important;
    }

    .gdrts-stars-current {
        z-index: 1;

        background-position: left center !important;
    }

    .gdrts-stars-active {
        z-index: 2;

        background-position: left top !important;
    }
}

.gdrts-with-fonticon {
    unicode-bidi: bidi-override;
    position: relative;
    white-space: nowrap;

    .gdrts-stars-empty {
        display: inline-block;
        position: relative;
        font-size: 32px;
    }

    .gdrts-stars-empty,
    .gdrts-stars-active,
    .gdrts-stars-current {
        &::before {
            display: block;
        }
    }

    .gdrts-stars-active,
    .gdrts-stars-current {
        font-family: inherit;
        position: absolute;
        overflow: hidden;
        top: 0;
        left: 0;
    }

    .gdrts-stars-current {
        z-index: 1;
    }

    .gdrts-stars-active {
        z-index: 2;
    }

    .gdrts-stars-empty {
        color: #DDD;
    }

    .gdrts-stars-current {
        color: #FF0;
    }

    .gdrts-stars-active {
        color: #D00;
    }
}

.gdrts-rating-distribution {
    margin: 10px 0 0;
}

.gdrts-distribution-wrapper {
    box-sizing: border-box;
    padding: 8px 10px;
    border: 1px solid #AAA;
    background: #EEE;
    width: 100%;
    max-width: 360px;

    * {
        box-sizing: border-box;
    }

    ul {
        list-style: none;
        margin: 0 !important;
        padding: 0 !important;

        li {
            list-style: none;
            padding: 2px 0;
            margin: 0;
            line-height: 18px;
            font-size: 11px;
        }
    }

    .gdrts-distribution-stars {
        margin-right: 1%;
        margin-top: 1px;
        width: 20%;
        float: left;
    }

    .gdrts-distribution-line {
        width: 60%;
        float: left;
        background: #FFF;
        border: 1px solid #DDD;
    }

    .gdrts-distribution-votes {
        margin-left: 1%;
        margin-top: 1px;
        width: 18%;
        float: left;
        text-align: right
    }

    .gdrts-distribution-line-fill {
        text-indent: -9999px;
        background: #EA2B2B;
    }
}

.gdrts-badge-wrapper {
    display: block;
    position: relative;
    margin: 0 auto;
}

.gdrts-badge-icon {
    position: relative;
}

.gdrts-badge-text {
    left: 0;
    position: absolute;
    text-align: center;
    top: 0;
    width: 100%;
    font-weight: bold;
}

.gdrts-badge-image {
    &.gdrts-image-star .gdrts-badge-icon {
        background: url('stars/star.png') no-repeat center;
    }

    &.gdrts-image-heart .gdrts-badge-icon {
        background: url('stars/heart.png') no-repeat center;
    }

    &.gdrts-image-snowflake .gdrts-badge-icon {
        background: url('stars/snowflake.png') no-repeat center;
    }

    &.gdrts-image-christmas .gdrts-badge-icon {
        background: url('stars/christmas.png') no-repeat center;
    }

    &.gdrts-image-oxygen .gdrts-badge-icon {
        background: url('stars/oxygen.png') no-repeat center;
    }

    &.gdrts-image-crystal .gdrts-badge-icon {
        background: url('stars/crystal.png') no-repeat center;
    }
}

.gdrts-with-fonticon {
    &.gdrts-fonticon-font {
        .gdrts-stars-empty {
            font-family: "gdrts-icons";
        }
    }
}

.gdrts-badge-font {
    &.gdrts-fonticon-font {
        .gdrts-badge-icon {
            font-family: "gdrts-icons";
        }
    }
}
