.dial-code-picker {
  position: relative;
  flex-shrink: 0;
}

.dial-code-picker__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  width: 100%;
  min-height: 46px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 16px;
  background: #f8fafc;
  color: #001f5b;
  font-weight: 800;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.dial-code-picker__trigger:hover {
  background: #eef2ff;
}

.dial-code-picker__trigger:focus-visible {
  outline: 2px solid #001f5b;
  outline-offset: 2px;
}

.dial-code-picker__value {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.dial-code-picker__flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
}

.dial-code-picker__flag-img,
.dial-code-picker-modal__flag-img {
  display: block;
  object-fit: cover;
  border-radius: 3px;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.08);
  flex-shrink: 0;
}

.dial-code-picker__flag-emoji,
.dial-code-picker-modal__flag-emoji {
  font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
  font-size: 1.1rem;
  line-height: 1;
}

.dial-code-picker__dial {
  white-space: nowrap;
}

.dial-code-picker__chevron {
  font-size: 0.75rem;
  color: #64748b;
  flex-shrink: 0;
}

/* Variante pages auth */
.dial-code-picker--auth {
  width: 118px;
}

.dial-code-picker--auth .dial-code-picker__trigger {
  min-height: 50px;
  border-radius: 16px;
}

/* Variante formulaires dashboard */
.dial-code-picker--form .dial-code-picker__trigger {
  min-height: 42px;
  border-radius: var(--radius-md, 12px) 0 0 var(--radius-md, 12px);
  border: 1px solid var(--border-color, #e2e8f0);
  background: #fff;
}

.dial-code-picker--form-sm .dial-code-picker__trigger {
  min-height: 31px;
  font-size: 0.875rem;
  padding: 0 8px;
}

/* Modal */
.dial-code-picker-modal {
  position: fixed;
  inset: 0;
  z-index: 1080;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 22px;
}

.dial-code-picker-modal.is-open {
  display: flex;
}

.dial-code-picker-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
}

.dial-code-picker-modal__card {
  position: relative;
  width: min(100%, 480px);
  max-height: 78vh;
  background: #fff;
  border-radius: 22px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.18);
}

.dial-code-picker-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid #e2e8f0;
}

.dial-code-picker-modal__title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 800;
  color: #001f5b;
}

.dial-code-picker-modal__close {
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 1.1rem;
  padding: 4px;
  cursor: pointer;
}

.dial-code-picker-modal__search {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 16px;
  padding: 0 12px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #f8fafc;
}

.dial-code-picker-modal__search i {
  color: #64748b;
}

.dial-code-picker-modal__search input {
  flex: 1;
  min-height: 46px;
  border: 0;
  background: transparent;
  font-size: 0.9rem;
  color: #001f5b;
  outline: none;
}

.dial-code-picker-modal__list {
  overflow-y: auto;
  padding: 0 16px 16px;
}

.dial-code-picker-modal__row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin-bottom: 8px;
  padding: 10px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #fff;
  text-align: left;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.dial-code-picker-modal__row:hover {
  background: #f8fafc;
}

.dial-code-picker-modal__row.is-selected {
  background: #eef2ff;
  border-color: #001f5b;
}

.dial-code-picker-modal__flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dial-code-picker-modal__info {
  flex: 1;
  min-width: 0;
}

.dial-code-picker-modal__name {
  display: block;
  font-size: 0.95rem;
  font-weight: 800;
  color: #001f5b;
}

.dial-code-picker-modal__row.is-selected .dial-code-picker-modal__name {
  color: #001f5b;
}

.dial-code-picker-modal__code {
  display: block;
  margin-top: 2px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
}

.dial-code-picker-modal__badge {
  border-radius: 999px;
  background: #eef2ff;
  color: #001f5b;
  font-size: 0.8rem;
  font-weight: 800;
  padding: 6px 10px;
  white-space: nowrap;
}

.dial-code-picker-modal__check {
  color: #16a34a;
  font-size: 1.1rem;
}

.dial-code-picker-modal__empty {
  min-height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  font-size: 0.9rem;
  font-weight: 600;
}
