/* The country code button in front of a phone field, and the searchable list it opens (phone.js). */
.cc { position: relative; display: inline-flex; align-items: center; gap: 5px; margin: 0; padding: 0 12px 0 0; border: 0; border-right: 1px solid rgba(31, 26, 61, 0.12); border-radius: 0; background: none; font: inherit; font-size: 18px; font-weight: 600; color: var(--ink, #1f1a3d); white-space: nowrap; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.cc i { font-style: normal; font-size: 20px; line-height: 1; }
.cc b { font-weight: inherit; direction: ltr; unicode-bidi: isolate; } /* "+91", never "91+", in Arabic too */
.cc svg { width: 12px; height: 12px; opacity: 0.55; }
.cc:focus-visible { outline: 2px solid var(--accent, #6a5cff); outline-offset: 4px; border-radius: 6px; }

.cc-sheet { width: min(480px, 100vw); max-width: 100vw; height: min(640px, 86vh); max-height: 86vh; margin: auto auto 0; padding: 0; border: 0; border-radius: 28px 28px 0 0; background: #fbfaff; color: #1f1a3d; display: flex; flex-direction: column; box-shadow: 0 -10px 40px rgba(31, 26, 61, 0.25); font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif; overflow: hidden; }
.cc-sheet:not([open]) { display: none; }
.cc-sheet::backdrop { background: rgba(20, 16, 40, 0.45); }
@media (min-width: 600px) { .cc-sheet { margin: auto; border-radius: 24px; } }
.cc-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 16px 6px 20px; }
.cc-head h2 { margin: 0; font-size: 20px; font-weight: 700; }
.cc-close { min-height: 40px; padding: 0 14px; border: 0; border-radius: 999px; background: rgba(31, 26, 61, 0.07); color: inherit; font: inherit; font-size: 16px; font-weight: 500; cursor: pointer; }
.cc-search { margin: 8px 16px 10px; min-height: 48px; padding: 0 16px; border: 1.5px solid rgba(31, 26, 61, 0.14); border-radius: 14px; background: #fff; color: inherit; font: inherit; font-size: 17px; outline: none; -webkit-appearance: none; appearance: none; }
.cc-search:focus { border-color: #6a5cff; }
.cc-list { flex: 1; min-height: 0; margin: 0; padding: 0 8px 16px; list-style: none; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.cc-list li { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 12px; border-radius: 12px; cursor: pointer; font-size: 17px; }
.cc-list li[aria-selected="true"] { background: rgba(106, 92, 255, 0.1); }
.cc-list li.current .cc-name { font-weight: 600; }
.cc-flag { font-size: 22px; line-height: 1; width: 28px; text-align: center; flex: none; }
.cc-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cc-code { flex: none; color: rgba(31, 26, 61, 0.6); font-variant-numeric: tabular-nums; }
.cc-empty { margin: 8px 24px 24px; color: rgba(31, 26, 61, 0.6); font-size: 16px; line-height: 1.4; }
[dir="rtl"] .cc { padding: 0 0 0 12px; border-right: 0; border-left: 1px solid rgba(31, 26, 61, 0.12); }
[dir="rtl"] .cc-code { direction: ltr; unicode-bidi: isolate; }
/* In the app at night the country list is a dark sheet too. */
body.night .cc-sheet { background: #24225a; color: #f1ecff; box-shadow: 0 -10px 40px rgba(4, 3, 18, 0.5); }
body.night .cc-close { background: rgba(255, 255, 255, 0.1); }
body.night .cc-search { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.14); }
body.night .cc-search:focus { border-color: #c9b8ff; }
body.night .cc-list li[aria-selected="true"] { background: rgba(201, 184, 255, 0.14); }
body.night .cc-code, body.night .cc-empty { color: rgba(241, 236, 255, 0.6); }
body.night .cc { border-color: rgba(255, 255, 255, 0.14); }

/* Under the phone field: the number Lull will text, in full, and a one-tap fix when the country code looks wrong.
   In the colour of the text around it, so it fits the website, the app and the dashboard, light or dark. */
.cc-hint { margin: 8px 2px 0; font-size: 14px; line-height: 1.45; color: inherit; opacity: 0.72; text-align: start; overflow-wrap: anywhere; }
.cc-hint[hidden] { display: none; }
.cc-hint .cc-check { font-weight: 600; opacity: 1; }
.cc-use { display: inline-flex; align-items: center; gap: 4px; margin: 2px 0 0; padding: 3px 10px; border: 1px solid; border-color: color-mix(in srgb, currentColor 28%, transparent); border-radius: 999px; background: transparent; color: inherit; font: inherit; font-weight: 600; cursor: pointer; white-space: nowrap; }
.cc-use:hover { border-color: currentColor; }
.cc-use:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.cc-hint .cc-num { white-space: nowrap; direction: ltr; unicode-bidi: isolate; }
