.country-code-picker {
    position: relative;
    flex: 0 0 205px;
    min-width: 0;
    font-family: inherit;
}

.country-code-picker.is-ready .country-code-select {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
}

.country-code-picker:not(.is-ready) .country-code-select {
    width: 100%;
    min-height: 46px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    padding: 10px;
}

.country-code-trigger {
    display: flex;
    width: 100%;
    min-height: 46px;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    padding: 10px 12px;
    color: #111827;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.25rem;
    text-align: left;
    cursor: pointer;
    transition: border-color .15s, box-shadow .15s;
}

.country-code-picker--joined .country-code-trigger {
    border-radius: 6px 0 0 6px;
}

.country-code-trigger:hover { border-color: #9ca3af; }
.country-code-trigger:focus,
.country-code-picker.is-open .country-code-trigger {
    outline: none;
    border-color: var(--primary-color, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .14);
}

.country-code-trigger-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.country-code-chevron {
    width: 16px;
    height: 16px;
    flex: none;
    color: #6b7280;
    transition: transform .15s;
}

.country-code-picker.is-open .country-code-chevron { transform: rotate(180deg); }

.country-code-panel {
    position: absolute;
    z-index: 10050;
    top: calc(100% + 8px);
    left: 0;
    width: min(320px, calc(100vw - 32px));
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, .12), 0 8px 10px -6px rgba(0, 0, 0, .1);
}

.country-code-search-wrap {
    padding: 10px;
    border-bottom: 1px solid #f3f4f6;
}

.country-code-search {
    width: 100%;
    border: 1px solid #d1d5db !important;
    border-radius: 8px !important;
    background: #f9fafb !important;
    padding: 9px 11px !important;
    color: #111827 !important;
    font-size: 14px !important;
    box-shadow: none !important;
}

.country-code-search:focus {
    outline: none !important;
    border-color: var(--primary-color, #2563eb) !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .12) !important;
}

.country-code-list {
    max-height: 260px;
    overflow-y: auto;
    padding: 6px;
    scrollbar-width: thin;
}

.country-code-option {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    border: 0;
    border-radius: 8px;
    background: transparent;
    padding: 9px 10px;
    color: #374151;
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

.country-code-option:hover,
.country-code-option.is-active { background: #f3f4f6; color: #111827; }
.country-code-option.is-selected { background: #eff6ff; color: #1d4ed8; font-weight: 600; }
.country-code-empty { padding: 20px 12px; color: #6b7280; font-size: 14px; text-align: center; }

@media (max-width: 575.98px) {
    .country-code-picker { flex-basis: 175px; }
}
