.um-item { position: relative; list-style: none; }
.um-item *, .um-item *::before, .um-item *::after { box-sizing: border-box; }
.um-toggle { background: transparent; border: 0; cursor: pointer; }
.um-caret { display: inline-block; width: 7px; height: 7px; margin-inline-start: 8px; border-inline-end: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform .2s; }
.um-item.is-open .um-caret { transform: translateY(1px) rotate(-135deg); }

.um-panel {
  --um-ink: #1b1b3a; --um-red: #e94f37; --um-line: #e3e8f4; --um-soft: #f3f6fd;
  position: absolute; top: calc(100% + 10px); inset-inline-start: 0; z-index: 1045;
  width: 760px; max-width: calc(100vw - 16px);
  background: #fff; color: var(--um-ink); border: 1px solid var(--um-line); border-radius: 18px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, .18); overflow: hidden; text-align: start; font-family: inherit; line-height: 1.6;
}
.um-panel[hidden] { display: none; }
.um-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 22px; background: linear-gradient(120deg, #2f4fa5, #223774); color: #fff; }
.um-head strong { font-size: 1.02rem; font-weight: 800; }
.um-close { background: transparent; border: 0; color: #fff; font-size: 1.7rem; line-height: 1; cursor: pointer; padding: 0 4px; }
.um-body { display: grid; grid-template-columns: 250px 1fr; height: 340px; }
.um-countries { overflow-y: auto; padding: 10px; background: var(--um-soft); border-inline-end: 1px solid var(--um-line); display: flex; flex-direction: column; gap: 4px; }
.um-ctab { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; text-align: start; background: transparent; border: 0; border-radius: 12px; padding: 10px 14px; font: inherit; font-weight: 700; font-size: .98rem; color: var(--um-ink); cursor: pointer; transition: background .15s, color .15s; }
.um-ctab i { font-style: normal; font-size: .8rem; min-width: 24px; padding: 0 7px; line-height: 22px; text-align: center; border-radius: 999px; background: #dfe6f6; color: #34406b; }
.um-ctab:hover { background: #e6ecfa; }
.um-ctab.is-active { background: var(--um-ink); color: #fff; }
.um-ctab.is-active i { background: var(--um-red); color: #fff; }
.um-ctab:focus-visible, .um-close:focus-visible, .um-toggle:focus-visible, .um-list:focus-visible { outline: 3px solid #4a6fd8; outline-offset: 2px; }
.um-results { display: flex; flex-direction: column; min-width: 0; padding: 14px 18px 8px; }
.um-list-title { margin: 0 0 8px; font-size: 1.05rem; font-weight: 800; color: var(--um-ink); }
.um-list { list-style: none; margin: 0; padding: 0 6px 0 0; overflow-y: auto; flex: 1; }
[dir=rtl] .um-list { padding: 0 0 0 6px; }
.um-list li { display: flex; align-items: baseline; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--um-line); font-size: 1rem; }
.um-list li:last-child { border-bottom: 0; }
.um-list li[hidden] { display: none; }
.um-list li i { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--um-red); transform: translateY(-2px); }
.um-list b { font-weight: 600; }
.um-list span { color: #6b7391; font-size: .92rem; }
.um-note { margin: 0; padding: 12px 22px; background: var(--um-soft); border-top: 1px solid var(--um-line); font-size: .92rem; font-style: italic; color: #4a5278; }

@media (max-width: 1199.98px) {
  .um-item { width: 100%; }
  .um-toggle { width: 100%; justify-content: space-between; }
  .um-panel { position: static; width: 100%; max-width: 100%; margin-top: 6px; box-shadow: none; border-radius: 14px; }
  .um-head { padding: 12px 16px; }
  .um-close { display: none; }
  .um-body { grid-template-columns: 1fr; height: auto; }
  .um-countries { flex-direction: row; overflow-x: auto; overflow-y: hidden; border-inline-end: 0; border-bottom: 1px solid var(--um-line); padding: 10px; scrollbar-width: thin; }
  .um-ctab { width: auto; flex: 0 0 auto; white-space: nowrap; background: #fff; border: 1.5px solid var(--um-line); border-radius: 999px; padding: 7px 14px; gap: 8px; }
  .um-ctab.is-active { border-color: var(--um-ink); }
  .um-list { max-height: 260px; }
  .um-note { padding: 10px 16px; }
}

.um-cap { display: none; }
@media (min-width: 1200px) and (max-width: 1279.98px) {
  .um-item .um-toggle { padding-inline: 0; min-width: 0; }
  .um-item { margin-inline: -4px; }
  .um-label { display: none; }
  .um-cap { display: inline-block; }
}
