:root {
    --primary: #111;
    --secondary: #fd0;
}

.cl-phone-select * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.cl-phone-select {
    position: relative;
    width: 100%;
    max-width: 100%;
    box-shadow: 2px 8px 10px rgba(0, 0, 0, 0.08);
    border: 1px solid #ced4da;
    border-radius: 1.5rem;
}

.cl-phone-select .iconify {
    position: relative;
}

.cl-phone-select input {
    width: 100%;
    padding: .6rem .5rem;
    font-size: 1.1rem;
    border: .1rem solid transparent;
    outline: none;
}

.cl-phone-select .flag strong {
    display: none;
}

input[type="tel"] {
    border-radius: 0 1.5rem 1.5rem 0;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

.cl-phone-select input:focus {
    border-color: #a898bf;
    border-left: 0;
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(80, 49, 126, 0.25);
}

.cl-phone-select .selected-option {
    background-color: #eee;
    border-radius: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cl-phone-select .selected-option .flag{
    position: relative;
    width: 4rem;
    padding: 0 2.8rem 0 .5rem;
    text-align: center;
    cursor: pointer;
}

.cl-phone-select .selected-option .flag::after{
    position: absolute;
    content: "";
    right: .7rem;
    top: 30%;
    transform: translateY(-50%) rotate(45deg);
    width: .7rem;
    height: .7rem;
    border-right: .12rem solid var(--primary);
    border-bottom: .12rem solid var(--primary);

    transition: .2s;
}

.cl-phone-select .selected-option .flag.active::after{
    top: 70%;
}

.cl-phone-select .selected-option .flag.active::after{
    transform: translateY(-50%) rotate(225deg);
}

.cl-phone-select .options {
    box-shadow: 2px 8px 10px rgba(0, 0, 0, 0.08);
    position: absolute;
    top: 4rem;
    width: 100%;
    background-color: #fff;
    border-radius: .5rem;
    display: none;
    z-index: 10;
}

.cl-phone-select .options.active {
    display: block;
}

.cl-phone-select .options::before {
    position: absolute;
    content: "";
    left: 1rem;
    top: -1rem;
    width: 0;
    height: 0;
    border: .6rem solid transparent;
    border-bottom-color: var(--primary);
}

.cl-phone-select input.search-box {
    background: var(--primary) !important;
    color: #fff !important;
    border-radius: .5rem .5rem 0 0 !important;
    padding: .5rem 1rem;
}

.cl-phone-select ol {
    list-style: none;
    max-height: 12rem;
    overflow: overlay;
    border: 1px solid #d5d5d5;
    border-top: 0;
    border-bottom-right-radius: .5rem;
    border-bottom-left-radius: .5rem;
}

.cl-phone-select ol::-webkit-scrollbar {
    width: 0.6rem;
}

.cl-phone-select ol::-webkit-scrollbar-thumb {
    width: 0.4rem;
    height: 3rem;
    background-color: #ccc;
    border-radius: .4rem;
}

.cl-phone-select ol li {
    padding: .4rem 1rem;
    display: flex;
    justify-content: space-between;
    cursor: pointer;
}

.cl-phone-select ol li.hide {
    display: none;
}

.cl-phone-select ol li:not(:last-child) {
    border-bottom: .1rem solid #eee;
}

.cl-phone-select ol li:hover {
    background-color: lightcyan;
}

.cl-phone-select ol li .country-name {
    margin-left: .4rem;
}