.merchant-referral-promo-slot {
  grid-column: span 24 / span 24;
}

.merchant-referral-promo-card {
  overflow: hidden;
  padding-bottom: 16px;
  border: 1px solid #edf0f5;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(20, 34, 66, .03);
}

.merchant-referral-promo-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 56px;
  padding: 0 16px;
  color: #fff;
  background: linear-gradient(100deg, #ff7b43, #ff6840);
}

.merchant-referral-promo-card header strong {
  font-size: 14px;
}

.merchant-referral-promo-card header span {
  flex: none;
  padding: 6px 10px;
  border-radius: 18px;
  color: #ff633d;
  background: #fff;
  font-size: 12px;
}

.merchant-referral-promo-card header b {
  font-weight: 700;
}

.merchant-referral-promo-body {
  padding: 13px 16px 5px;
  color: #5b6473;
  font-size: 13px;
}

.merchant-referral-promo-body p {
  margin: 5px 0;
}

.merchant-referral-promo-body p span {
  margin-right: 4px;
  color: #14b866;
  font-weight: 700;
}

.merchant-referral-promo-body strong {
  margin-left: 3px;
  color: #ff5638;
}

.merchant-referral-open-button {
  display: block;
  min-width: 142px;
  height: 36px;
  margin: 4px auto 0;
  border: 0;
  border-radius: 18px;
  color: #fff;
  background: #08b968;
  cursor: pointer;
  font-weight: 600;
}

.merchant-referral-open-button::before {
  content: '♧';
  margin-right: 7px;
}

.merchant-referral-open-button:hover {
  background: #069e59;
}

.merchant-referral-modal[hidden] {
  display: none;
}

.merchant-referral-modal {
  position: fixed;
  z-index: 3000;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(15, 23, 42, .38);
}

.merchant-referral-dialog {
  overflow: hidden;
  width: min(440px, 100%);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 20px 60px rgba(15, 23, 42, .22);
}

.merchant-referral-dialog-head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 88px;
  padding: 0 54px 0 20px;
  color: #fff;
  background: linear-gradient(105deg, #ff874d, #ff663c);
}

.merchant-referral-dialog-icon {
  display: grid;
  flex: none;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 12px;
  font-size: 21px;
}

.merchant-referral-dialog-head strong,
.merchant-referral-dialog-head small {
  display: block;
}

.merchant-referral-dialog-head strong {
  margin-bottom: 4px;
  font-size: 18px;
}

.merchant-referral-dialog-head small {
  font-size: 12px;
  font-weight: 400;
}

.merchant-referral-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, .2);
  cursor: pointer;
  font-size: 22px;
  line-height: 28px;
}

.merchant-referral-dialog-body {
  padding: 18px 20px 20px;
}

.merchant-referral-copy {
  margin: 0 0 14px;
  color: #4e5868;
  line-height: 1.75;
}

.merchant-referral-rate-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border: 1px solid #ffd7c8;
  border-radius: 12px;
  background: #fffaf7;
  color: #2b3442;
  font-weight: 600;
}

.merchant-referral-rate-row strong {
  color: #ff5b35;
  font-size: 27px;
}

.merchant-referral-tags {
  display: flex;
  gap: 8px;
  margin: 12px 0;
}

.merchant-referral-tags span {
  flex: 1;
  padding: 9px 7px;
  border: 1px solid #e7ebf1;
  border-radius: 10px;
  color: #465064;
  background: #f8fafc;
  text-align: center;
  font-size: 12px;
}

.merchant-referral-link {
  overflow: hidden;
  padding: 13px 14px;
  border-radius: 11px;
  color: #26354c;
  background: #fff6f0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.merchant-referral-dialog-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0 10px;
}

.merchant-referral-dialog-actions button,
.merchant-referral-copy-button {
  height: 42px;
  border: 1px solid #e3e8ef;
  border-radius: 11px;
  background: #f8fafc;
  cursor: pointer;
  font-weight: 600;
}

.merchant-referral-copy-button {
  width: 100%;
  border-color: #1f2937;
  color: #fff;
  background: #1f2937;
}

.merchant-referral-copy-button:disabled {
  cursor: not-allowed;
  opacity: .55;
}

.merchant-referral-copy-fallback {
  position: fixed;
  left: -9999px;
}

@media (max-width: 720px) {
  .merchant-referral-promo-card header {
    align-items: flex-start;
    flex-direction: column;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .merchant-referral-tags {
    flex-direction: column;
  }

  .merchant-referral-dialog-actions {
    grid-template-columns: 1fr;
  }
}
