/* Shared country picker and country-format hint for all phone fields. */
.lms-country-phone,.lms-phone-country-list,.lms-phone-dropdown {
    --phone-bg:var(--auth-surface,var(--admin-surface,#fff));
    --phone-text:var(--auth-text,var(--text-dark,#111528));
    --phone-muted:var(--auth-muted,#657187);
    --phone-border:var(--auth-border,var(--border-color,#e1e8f0));
    --phone-highlight:rgba(42,172,255,.12);
}
html[data-theme="dark"] .lms-country-phone,html[data-theme="dark"] .lms-phone-country-list,html[data-theme="dark"] .lms-phone-dropdown,
body.dark-mode .lms-country-phone,body.dark-mode .lms-phone-country-list,body.dark-mode .lms-phone-dropdown {
    --phone-bg:#181d31;--phone-text:#f1f5f9;--phone-muted:#aab6cb;--phone-border:#334155;
}
.lms-country-phone { width:100%; min-width:0; color:var(--phone-text); }
.lms-country-phone .iti__selected-flag { border-radius:10px 0 0 10px; gap:2px; }
.lms-country-phone .iti__selected-dial-code { font-size:13px; }
.lms-country-phone .iti__arrow { border-top-color:var(--phone-text); }
.lms-country-phone .iti__arrow--up { border-top:0; border-bottom-color:var(--phone-text); }
.lms-country-phone .iti__selected-flag:hover,.lms-country-phone .iti__selected-flag:focus { background:var(--phone-highlight); }
.lms-country-phone .iti__country-list,.lms-phone-country-list {
    width:min(350px,calc(100vw - 40px)); max-width:calc(100vw - 40px); max-height:260px;
    white-space:normal; color:var(--phone-text); background:var(--phone-bg);
    border:1px solid var(--phone-border); border-radius:12px; box-shadow:0 12px 36px rgba(0,0,0,.18);
    padding:5px; font-size:14px; z-index:20;
}
.lms-country-phone .iti__country,.lms-phone-country-list .iti__country { padding:9px 10px; border-radius:7px; }
.lms-country-phone .iti__country.iti__highlight,.lms-phone-country-list .iti__country.iti__highlight { background:var(--phone-highlight); }
.lms-country-phone .iti__dial-code,.lms-phone-country-list .iti__dial-code { color:var(--phone-muted); }
.lms-country-phone .iti__divider,.lms-phone-country-list .iti__divider { border-color:var(--phone-border); }
.lms-country-phone .iti__flag-box,.lms-phone-country-list .iti__flag-box { flex-shrink:0; }
.lms-phone-dropdown { z-index:1100; }
.lms-phone-dropdown .lms-phone-country-list { width:100%; max-width:100%; }
.lms-phone-fallback { display:block; font-size:12px; line-height:1.5; margin-top:7px; color:var(--auth-muted,var(--text-dark,#657187)); }
.lms-phone-format-hint { display:block; margin:6px 0 0; font-size:12px; line-height:1.5; color:var(--auth-muted,var(--text-muted,#657187)); }
html[data-theme="dark"] .lms-phone-format-hint,body.dark-mode .lms-phone-format-hint { color:#aab6cb; }
.lms-country-phone-fallback { display:flex; align-items:stretch; gap:8px; }
.lms-country-phone-fallback .lms-phone-country-select { flex:0 1 45%; min-width:100px; width:auto; border:1px solid var(--phone-border); border-radius:8px; padding:8px; color:var(--phone-text); background:var(--phone-bg); font:inherit; font-size:13px; }
.lms-country-phone-fallback input { flex:1 1 55%; width:0; min-width:0; }
.lms-country-phone input[aria-invalid="true"] { border-color:var(--auth-error,#dc3545); }
/* Tristan da Cunha is present in current metadata but absent from the pinned
   picker's flag sprite. Keep its country marker legible in the same footprint. */
.lms-country-phone .iti__ta,.lms-phone-country-list .iti__ta { background:none; box-shadow:none; height:15px; font-size:10px; line-height:15px; text-align:center; }
.lms-country-phone .iti__ta::after,.lms-phone-country-list .iti__ta::after { content:"TA"; }
@media (max-width:420px) {
    .lms-country-phone-fallback { flex-wrap:wrap; }
    .lms-country-phone-fallback .lms-phone-country-select,.lms-country-phone-fallback input { flex-basis:100%; width:100%; }
}
