.custom-select {
    position: relative;
    width: 100%;
}

.custom-select-btn {
    width: 100%;
    margin: 0;
    border: 1px solid rgba(0,0,0,.1);
    background: rgba(255,255,255,.82);
    color: #111;
    border-radius: 16px;
    padding: 14px;
    font-size: 15px;
    font-weight: 500;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.9);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.custom-select-btn:hover {
    background: rgba(255,255,255,.95);
    transform: none;
}

.custom-select.open .custom-select-btn {
    border-color: rgba(0,0,0,.34);
    box-shadow:
        0 0 0 4px rgba(0,0,0,.06),
        inset 0 1px 0 rgba(255,255,255,.9);
}

.custom-select-arrow {
    font-size: 18px;
    color: #111;
    transition: .2s;
}

.custom-select.open .custom-select-arrow {
    transform: rotate(180deg);
}

.custom-select-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 20;
    padding: 8px;
    border-radius: 18px;
    background: rgba(255,255,255,.96);
    border: 1px solid rgba(0,0,0,.09);
    box-shadow:
        0 24px 55px rgba(0,0,0,.14),
        inset 0 1px 0 rgba(255,255,255,.95);
    backdrop-filter: blur(20px);
}

.custom-select.open .custom-select-menu {
    display: block;
}

.custom-select-item {
    padding: 12px 14px;
    border-radius: 12px;
    color: #1d1d1f;
    font-size: 14px;
    cursor: pointer;
}

.custom-select-item:hover {
    background: #f2f2f4;
}

.custom-select-item.active {
    background: #ececef;
    color: #111;
    font-weight: 700;
}

.country-select {
    z-index: 150;
}

.country-select.open {
    z-index: 9999;
}

.country-menu {
    max-height: 250px;
    overflow: hidden;
}

.country-search {
    width: 100%;
    margin-bottom: 8px;
    padding: 11px 12px;
    border-radius: 12px;
    border: 1px solid rgba(0,0,0,.08);
    background: #f5f5f7;
    color: #111;
    font-size: 13px;
    box-shadow: none;
}

.country-search:focus {
    border-color: rgba(0,0,0,.24);
    box-shadow: 0 0 0 3px rgba(0,0,0,.05);
}

.country-list {
    max-height: 170px;
    overflow-y: auto;
    padding-right: 2px;
}

.country-list::-webkit-scrollbar {
    width: 5px;
}

.country-list::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,.18);
    border-radius: 999px;
}

.country-list::-webkit-scrollbar-track {
    background: transparent;
}

.flag-code {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 18px;
    margin-right: 6px;
    border-radius: 6px;
    background: linear-gradient(180deg, #f7f7f8, #e5e5e7);
    border: 1px solid rgba(0,0,0,.08);
    color: #111;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: -.2px;
    vertical-align: 1px;
}
