@media (max-height: 666px) {
    .referral-dialog {
        top: 0;
        transform: none;
        margin: 5px auto;
    }
}
    .referral-dialog {
        width: auto;
        max-width: 600px;
        height: 82vh;
        min-height: 610px;
        font-weight: 400;
        -moz-osx-font-smoothing: grayscale;
        -webkit-font-smoothing: antialiased;
    }
        .referral-explanation {
            height: 234px;
            margin-bottom: 30px;
            padding: 1px 20px;
            box-sizing: border-box;
            text-align: center;
            color: #333;
        }
            .referral-explanation h2 {
                margin-top: 0;
            }
            .fa.referral-step {
                font-size: 28px;
                padding: 24px;
                margin: 12px 48px;
                border-radius: 50%;
                position: relative;
                background-color: #3498DB;
                color: white;
            }
                .fa.referral-step:after {
                    content: 'Invite colleagues below';
                    position: absolute;
                    font-size: 14px;
                    font-family: Lato;
                    color: #3498DB;
                    border-radius: 50%;
                    line-height: 18px;
                    top: 100%;
                    font-weight: 700;
                    width: 200px;
                    white-space: pre;
                    left: 50%;
                    transform: translate(-50%, 10px);
                }
                .fa-thumbs-up.referral-step:after {
                    content: 'They join and get\A one FREE month';
                }
                .fa-trophy.referral-step:after {
                    content: 'You get one FREE month\A for each colleague';
                }
            .referral-explanation .fa-chevron-right {
                color: #3498DB;
                font-size: 21px;
            }
        .referral-social {
            margin: 10px 0 48px;
            color: #333;
        }
            .referral-social > p {
                margin-bottom: 5px;
            }
            .referral-social > input {
                font-family: Lato;
                font-size: 14px;
                font-weight: 400;
                padding: 10px;
                width: calc(100% - 105px);
                margin-top: 0;
                box-sizing: border-box;
                -webkit-box-sizing: border-box;
                margin-right: 10px;
            }
            .referral-social > .fa {
                cursor: pointer;
                margin: 0 5px;
                font-size: 40px;
                position: relative;
                top: 9px;
            }
            .referral-social > .fa-facebook-square {
                color: #3b5998;
            }
            .referral-social > .fa-twitter-square {
                color: #55acee;
            }
        .referral-dialog > a {
            font-size: 14px;
            color: #3498DB;
            text-decoration: none;
        }
        .referral-select-all, .referral-deselect-all {
            color: #3498DB;
            text-decoration: underline;
            margin-bottom: 10px;
            display: inline-block;
            cursor: pointer;
        }
            .referral-select-all:before {
                content: 'Select All';
            }
            .referral-deselect-all:before {
                content: 'Deselect All';
            }
        .referral-select {
            height: calc(100% - 431px);
            overflow-y: scroll;
            background-color: white;
            border-radius: 5px;
            border: 1px solid #ccc;
            color: #333;
            position: relative;
            margin-bottom: 5px;
        }
            .referral-option, .referral-custom {
                display: block;
                height: 44px;
                line-height: 44px;
                border-bottom: 1px solid #eee;
                overflow: hidden;
            }
            .referral-option.selected {
                background-color: #E1F0FA;/*rgba(52, 152, 219, 0.15);*/
            }
                .referral-option-checkbox, .referral-option-email {
                    margin-left: 10px;
                }
                .referral-option-email {
                    display: inline-flex;
                    max-width: calc(100% - 36px);
                }
                .referral-custom-input {
                    line-height: 28px;
                    margin: 6px;
                    margin-right: 0;
                    padding: 0;
                    padding-left: 5px;
                    width: calc(100% - 125px);
                    /**
                    line-height: 44px;
                    border: 0;
                    margin: 0;
                    padding-left: 10px;
                    width: calc(100% - 120px);
                    outline: 0;
                    /**/
                    float: left;
                    font-size: 15px;
                    font-family: Lato;
                }
                .referral-custom-add {
                    border: 0;
                    color: white;
                    font-family: Lato;
                    font-size: 15px;
                    height: 32px;
                    border-radius: 4px;
                    cursor: pointer;
                    outline: 0;
                }
                .referral-custom-add {
                    background-color: #3498DB;
                    float: right;
                    margin: 6px;
                    min-width: 93px;
                }
            .referral-option:last-child {
                border-bottom: 0;
            }
        .referral-confirm {
            float: right;
            background-color: #36AE4F;
            border-radius: 5px;
            border: 0;
            color: #fff;
            font-size: 14px;
            height: 32px;
            margin-top: -11px;
            margin-right: -10px;
            font-family: Lato;
            cursor: pointer;
        }
        .referral-confirm[disabled] {
            cursor: default;
            pointer-events: none;
            opacity: 0.2;
        }
