.hsc-btn.is-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.82;
}

.hsc-btn.is-loading svg {
  opacity: 0;
}

.hsc-btn.is-loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 24px;
  height: 24px;
  margin: -12px 0 0 -12px;
  border: 3px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 999px;
  animation: nexfonNumberSpin 0.8s linear infinite;
}

@keyframes nexfonNumberSpin {
  to {
    transform: rotate(360deg);
  }
}

.nexfon-number-modal-open {
  overflow: hidden;
}

.nexfon-number-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: grid;
  place-items: center;
  padding: 22px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

.nexfon-number-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.nexfon-number-modal__overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 30%, rgba(151, 83, 236, 0.28), transparent 32%),
    rgba(11, 6, 20, 0.62);
  backdrop-filter: blur(7px);
}

.nexfon-number-modal__dialog {
  position: relative;
  direction: rtl;
  width: min(100%, 560px);
  max-height: min(88vh, 680px);
  overflow: auto;
  padding: clamp(20px, 3vw, 30px);
  border: 1px solid rgba(153, 102, 220, 0.28);
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(250, 247, 255, 0.96)), #fff;
  box-shadow: 0 22px 62px rgba(32, 18, 54, 0.24);
  transform: translateY(16px) scale(0.98);
  transition: transform 0.22s ease;
}

.nexfon-number-modal.is-open .nexfon-number-modal__dialog {
  transform: translateY(0) scale(1);
}

.nexfon-number-modal__close {
  position: absolute;
  top: 14px;
  left: 14px;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(113, 62, 166, 0.18);
  border-radius: 12px;
  background: #fff;
  color: #111827;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.nexfon-number-modal__close:hover {
  border-color: rgba(113, 62, 166, 0.34);
  background: rgba(113, 62, 166, 0.06);
  color: #713ea6;
  transform: translateY(-1px);
}

.nexfon-number-modal__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  margin-bottom: 12px;
  padding: 5px 16px;
  border: 1px solid rgba(113, 62, 166, 0.28);
  border-radius: 999px;
  background: rgba(113, 62, 166, 0.08);
  color: #713ea6;
  font-size: 0.98rem;
  font-weight: 900;
}

.nexfon-number-modal__title {
  margin: 0 0 8px;
  color: #111827;
  font-size: clamp(1.32rem, 2.4vw, 1.78rem);
  font-weight: 900;
  line-height: 1.4;
}

.nexfon-number-modal__body {
  margin: 0 0 18px;
  color: #667085;
  font-size: 0.9rem;
  font-weight: 650;
  line-height: 1.9;
}

.nexfon-number-modal.is-available .nexfon-number-modal__badge {
  border-color: rgba(35, 185, 120, 0.28);
  background: rgba(35, 185, 120, 0.09);
  color: #169b67;
}

.nexfon-number-modal__form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 14px;
}

.nexfon-number-modal__form label {
  display: grid;
  gap: 6px;
  color: #111827;
  font-size: 0.82rem;
  font-weight: 850;
}

.nexfon-number-modal__full {
  grid-column: 1 / -1;
}

.nexfon-number-modal__form input {
  width: 100%;
  min-height: 50px;
  padding: 0 15px;
  border: 2px solid #e2e6ee;
  border-radius: 15px;
  outline: none;
  background: #f8fafc;
  color: #111827;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 750;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.nexfon-number-modal__form input:focus {
  border-color: #7b45b4;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(123, 69, 180, 0.11);
}

.nexfon-number-modal__form button[type="submit"] {
  grid-column: 1 / -1;
  min-height: 52px;
  border: 0;
  border-radius: 15px;
  background: linear-gradient(135deg, #713ea6, #8b55ee);
  color: #fff;
  font: inherit;
  font-size: 0.98rem;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 14px 30px rgba(113, 62, 166, 0.24);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.nexfon-number-modal__form button[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(113, 62, 166, 0.32);
  filter: saturate(1.08) brightness(1.02);
}

.nexfon-number-modal__form button[type="submit"]:disabled {
  cursor: wait;
  opacity: 0.74;
  transform: none;
  filter: none;
}

.nexfon-number-modal__feedback {
  grid-column: 1 / -1;
  min-height: 24px;
  margin: 0;
  color: #667085;
  font-size: 0.82rem;
  font-weight: 750;
  line-height: 1.8;
}

.nexfon-number-modal__feedback.error {
  color: #dc2626;
}

.nexfon-number-modal__feedback.success {
  color: #169b67;
}

html[dir="ltr"] .nexfon-number-modal__dialog {
  direction: ltr;
  text-align: left;
}

html[dir="ltr"] .nexfon-number-modal__close {
  right: 14px;
  left: auto;
}

.nexfon-number-modal.is-ltr .nexfon-number-modal__dialog,
.nexfon-number-modal.is-ltr .nexfon-number-modal__form,
.nexfon-number-modal.is-ltr .nexfon-number-modal__feedback {
  direction: ltr;
  text-align: left;
}

.nexfon-number-modal.is-ltr .nexfon-number-modal__close {
  right: 14px;
  left: auto;
}

.nexfon-number-modal.is-rtl .nexfon-number-modal__dialog,
.nexfon-number-modal.is-rtl .nexfon-number-modal__form,
.nexfon-number-modal.is-rtl .nexfon-number-modal__feedback {
  direction: rtl;
  text-align: right;
}

@media (max-width: 640px) {
  .nexfon-number-modal {
    padding: 14px;
  }

  .nexfon-number-modal__dialog {
    padding: 24px 16px 20px;
    border-radius: 22px;
  }

  .nexfon-number-modal__form {
    grid-template-columns: 1fr;
  }
}
