/* Login / sign-up modal */

.auth-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(4, 3, 10, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.auth-modal[data-open="true"] {
  opacity: 1;
  visibility: visible;
}

.auth-modal__dialog {
  position: relative;
  width: 100%;
  max-width: 380px;
  padding: 40px 28px 24px;
  border-radius: 24px;
  border: 1px solid var(--color-bg-tertiary, #cbd0eb1a);
  background:
    radial-gradient(120% 90% at 50% 115%, #2b3480 0%, rgba(43, 52, 128, 0) 62%),
    radial-gradient(90% 70% at 50% -10%, #1b1f4d 0%, rgba(27, 31, 77, 0) 60%),
    var(--color-bg-primary, #060510);
  box-shadow:
    0 0 0 1px rgba(203, 208, 235, 0.04),
    0 24px 80px rgba(0, 0, 0, 0.65),
    0 0 90px rgba(81, 106, 246, 0.28);
  transform: translateY(8px) scale(0.97);
  opacity: 0;
  transition: transform 0.2s ease-out, opacity 0.2s ease-out;
}

.auth-modal[data-open="true"] .auth-modal__dialog {
  transform: none;
  opacity: 1;
}

.auth-modal__close {
  position: absolute;
  top: -52px;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  background: #26262e;
  color: var(--color-text-primary, #f7f7f7);
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.auth-modal__close:hover {
  background: #33333d;
}

.auth-modal__logo {
  display: block;
  width: 148px;
  height: auto;
  margin: 0 auto 18px;
  color: var(--color-text-primary, #f7f7f7);
}

.auth-modal__title {
  margin: 0 0 28px;
  font-size: 22px;
  line-height: 1.25;
  font-weight: 500;
  letter-spacing: -0.01em;
  text-align: center;
  color: #d7dbf0;
}

.auth-modal__actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-modal__btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 52px;
  padding: 0 16px;
  border-radius: 14px;
  border: 1px solid transparent;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.auth-modal__btn svg {
  position: absolute;
  left: 18px;
  width: 22px;
  height: 22px;
}

.auth-modal__btn--wallet {
  background: #ffffff;
  color: #08070f;
}

.auth-modal__btn--wallet:hover {
  background: #ebebeb;
}

.auth-modal__btn--wallet svg {
  width: 24px;
  height: 24px;
  color: #3b99fc;
}

.auth-modal__legal {
  margin: 22px 0 0;
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
  color: #5d6076;
}

.auth-modal__legal a {
  color: #7b7fa0;
  text-decoration: none;
}

.auth-modal__legal a:hover {
  color: #a0a4c4;
}

@media (max-width: 420px) {
  .auth-modal__dialog {
    padding: 32px 20px 20px;
  }

  .auth-modal__close {
    top: -50px;
  }
}
