/* Affiliate dashboard — responsive overrides */
.nw-affi-invite-wrapper,
.nw-affi-invite-wrapper .container {
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

.nw-affi-invite-wrapper *,
.nw-affi-invite-wrapper *::before,
.nw-affi-invite-wrapper *::after {
  box-sizing: border-box;
}

/* Gift icon in "Invitation Code" heading — was exploding without explicit size */
.nw-affi-qr-invite-heading {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  flex-wrap: nowrap;
  min-width: 0;
}

.nw-affi-qr-invite-heading img,
.nw-affi-qr-invite-heading img[alt="invite-gift"] {
  width: 28px !important;
  height: 28px !important;
  max-width: 28px !important;
  max-height: 28px !important;
  flex: 0 0 28px !important;
  object-fit: contain;
  display: block;
}

.nw-affi-qr-invite-heading h3 {
  margin: 0;
  min-width: 0;
  flex: 1 1 auto;
  font-size: clamp(14px, 4vw, 16px) !important;
  line-height: 1.3;
  word-break: break-word;
}

.nw-affi-qr-invite-code {
  width: 100% !important;
  max-width: 100%;
  overflow: hidden;
}

.nw-affi-share-link-sec {
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.nw-affi-share-link-sec span {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap !important;
}

.nw-affi-qr-invite-wrapper .affi-qr-btn-wrapper {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: stretch !important;
  gap: 10px !important;
  width: 100%;
}

.nw-affi-qr-sec {
  width: 100px !important;
  max-width: 100%;
  flex: 0 0 auto;
}

.nw-affi-qr-sec canvas,
.nw-affi-qr-sec img {
  width: 100% !important;
  height: auto !important;
  max-width: 100px;
  display: block;
  margin: 0 auto;
}

.nw-affi-qr-invite-wrapper .af-form-btn-sec {
  width: auto !important;
  flex: 1 1 160px !important;
  margin-left: 0 !important;
  margin-bottom: 0 !important;
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
  min-width: 0;
}

.nw-affi-qr-invite-wrapper .af-form-btn-sec button {
  min-width: 0 !important;
  width: auto !important;
  flex: 1 1 120px !important;
  height: 45px !important;
  max-width: 100%;
}

/* Top invite hero illustration */
.nw-affi-invite-content-wrapper {
  gap: 12px;
  flex-wrap: wrap;
}

.nw-affi-invite-content {
  flex: 1 1 180px;
  min-width: 0;
}

.nw-affi-invite-img,
.nw-affi-invite-content-wrapper > div:last-child {
  flex: 0 0 auto;
}

.nw-affi-invite-img img,
.nw-affi-invite-content-wrapper img[alt="affi-invite-img"] {
  width: clamp(72px, 22vw, 110px) !important;
  height: auto !important;
  max-width: 110px !important;
  display: block;
  object-fit: contain;
}

/* Decorative ellipse backgrounds must not dominate the card */
.ellip-bg-img,
img.ellip-bg-img,
img[alt="ellip-bg"] {
  max-width: min(160px, 42%) !important;
  width: auto !important;
  height: auto !important;
  opacity: 0.55;
  pointer-events: none;
}

.nw-affi-how-to-get-bonus-content-sec img,
.nw-affi-how-to-get-bonus-content-sec img[alt^="affi-bonus"] {
  width: 42px !important;
  height: 42px !important;
  object-fit: contain;
  flex-shrink: 0;
}

.nw-affi-add-new-user-btn span img,
.nw-affi-add-new-user-btn img[alt="affi-add-user"] {
  width: 22px !important;
  height: 22px !important;
  object-fit: contain;
}

/* Copy / share button icons */
.nw-affi-qr-invite-wrapper .af-form-btn-sec img,
.affi-yellow-btn img,
img[alt="affi-copy"] {
  width: 16px !important;
  height: 16px !important;
  object-fit: contain;
  flex-shrink: 0;
}

/* Bottom affiliate nav */
.affiliate-footer img,
.nw-affi-footer img,
.affi-footer img {
  width: 24px !important;
  height: 24px !important;
  object-fit: contain;
}

@media (max-width: 576px) {
  .nw-affi-invite-sec {
    padding: 10px !important;
  }

  .nw-affi-invite-sec h2 {
    font-size: 17px !important;
  }

  .nw-affi-invite-sec p {
    font-size: 13px !important;
  }

  .nw-affi-qr-invite-wrapper .affi-qr-btn-wrapper {
    flex-direction: column;
    align-items: stretch !important;
  }

  .nw-affi-qr-sec {
    width: 120px !important;
    margin: 0 auto;
  }

  .nw-affi-qr-invite-wrapper .af-form-btn-sec {
    width: 100% !important;
    flex: 1 1 100% !important;
  }

  .nw-affi-qr-invite-wrapper .af-form-btn-sec button {
    width: 100% !important;
    flex: 1 1 100% !important;
  }

  .nw-affi-how-to-get-bonus-content {
    flex-direction: column;
    gap: 8px;
  }

  .nw-affi-status-digit-para {
    flex: 1 1 100%;
  }
}
