.bb-retention-overlay {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(4, 6, 18, 0.82);
  backdrop-filter: blur(6px);
  animation: bb-retention-fade 0.2s ease;
}

.bb-retention-modal {
  width: min(100%, 380px);
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(165deg, #1a1f45 0%, #12162e 45%, #0d1024 100%);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  padding: 1.5rem 1.25rem 1.1rem;
  color: #eef1ff;
  text-align: center;
  animation: bb-retention-pop 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.bb-retention-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 0.85rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 30% 30%, rgba(0, 229, 168, 0.35), rgba(0, 229, 168, 0.08) 70%);
  box-shadow: 0 0 0 6px rgba(0, 229, 168, 0.12), 0 0 28px rgba(0, 229, 168, 0.22);
  font-size: 2rem;
}

.bb-retention-title {
  margin: 0;
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #ffd166;
  text-transform: uppercase;
}

.bb-retention-subtitle {
  margin: 0.15rem 0 0.75rem;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  color: #ff6b9d;
  text-transform: uppercase;
}

.bb-retention-text {
  margin: 0 0 1rem;
  font-size: 0.92rem;
  line-height: 1.45;
  color: #b8c0e0;
}

.bb-retention-text strong,
.bb-retention-text .bb-retention-highlight {
  color: #00e5a8;
  font-weight: 700;
}

.bb-retention-box {
  background: rgba(8, 10, 24, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 0.85rem 1rem;
  margin-bottom: 0.85rem;
  text-align: left;
}

.bb-retention-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: #9aa3c7;
}

.bb-retention-row + .bb-retention-row {
  margin-top: 0.55rem;
}

.bb-retention-row.bonus {
  color: #00e5a8;
  font-weight: 600;
}

.bb-retention-row.bonus .bb-retention-value {
  color: #00e5a8;
}

.bb-retention-divider {
  border: none;
  border-top: 1px dashed rgba(255, 255, 255, 0.14);
  margin: 0.75rem 0;
}

.bb-retention-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.bb-retention-total-label {
  font-size: 0.95rem;
  font-weight: 700;
  color: #eef1ff;
}

.bb-retention-total-value {
  font-size: 1.35rem;
  font-weight: 800;
  color: #00e5a8;
  text-shadow: 0 0 18px rgba(0, 229, 168, 0.35);
}

.bb-retention-timer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  background: rgba(255, 107, 157, 0.12);
  border: 1px solid rgba(255, 107, 157, 0.22);
  color: #ff8cb3;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.bb-retention-timer strong {
  color: #ffb3cc;
  font-size: 0.92rem;
}

.bb-retention-cta {
  width: 100%;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  margin-bottom: 0.65rem;
  background: linear-gradient(180deg, #00f0b0 0%, #00c98a 100%);
  color: #062318;
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 229, 168, 0.28);
}

.bb-retention-cta:disabled {
  opacity: 0.65;
  cursor: wait;
}

.bb-retention-secondary {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 0.78rem 1rem;
  margin-bottom: 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  color: #eef1ff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer;
}

.bb-retention-dismiss {
  border: none;
  background: none;
  color: #7d86a8;
  font-size: 0.78rem;
  cursor: pointer;
  text-decoration: underline;
  padding: 0.25rem;
}

@keyframes bb-retention-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes bb-retention-pop {
  from { opacity: 0; transform: translateY(12px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.bb-pix-bonus-banner {
  width: 100%;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.85rem 0.95rem;
  border-radius: 12px;
  border: 1px solid rgba(0, 229, 168, 0.35);
  background: linear-gradient(135deg, rgba(0, 229, 168, 0.14) 0%, rgba(0, 194, 255, 0.08) 100%);
  box-shadow: 0 0 20px rgba(0, 229, 168, 0.12);
  text-align: left;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.bb-pix-bonus-banner.visible {
  opacity: 1;
  transform: translateY(0);
}

.bb-pix-bonus-banner--error {
  border-color: rgba(255, 84, 112, 0.4);
  background: linear-gradient(135deg, rgba(255, 84, 112, 0.12) 0%, rgba(255, 84, 112, 0.05) 100%);
  box-shadow: 0 0 16px rgba(255, 84, 112, 0.1);
}

.bb-pix-bonus-banner-icon {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(0, 229, 168, 0.18);
  font-size: 1rem;
}

.bb-pix-bonus-banner--error .bb-pix-bonus-banner-icon {
  background: rgba(255, 84, 112, 0.18);
}

.bb-pix-bonus-banner-body {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.bb-pix-bonus-banner-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: #00e5a8;
  letter-spacing: 0.02em;
}

.bb-pix-bonus-banner--error .bb-pix-bonus-banner-title {
  color: #ff6b85;
}

.bb-pix-bonus-banner-text {
  font-size: 0.82rem;
  line-height: 1.45;
  color: #b8c0e0;
}

.bb-pix-bonus-banner-text strong {
  color: #00e5a8;
  font-weight: 700;
}

.bb-retention-toast {
  position: fixed;
  top: max(1rem, env(safe-area-inset-top, 0px));
  left: 50%;
  z-index: 10100;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  width: min(calc(100% - 2rem), 420px);
  padding: 0.95rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(0, 229, 168, 0.35);
  background: linear-gradient(135deg, rgba(18, 28, 52, 0.98) 0%, rgba(10, 14, 32, 0.98) 100%);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  color: #eef1ff;
  opacity: 0;
  transform: translate(-50%, -12px);
  transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.bb-retention-toast--info {
  border-color: rgba(0, 194, 255, 0.35);
}

.bb-retention-toast--error {
  border-color: rgba(255, 84, 112, 0.4);
}

.bb-retention-toast--info .bb-retention-toast-title {
  color: #00c2ff;
}

.bb-retention-toast--info .bb-retention-toast-icon {
  background: rgba(0, 194, 255, 0.16);
}

.bb-retention-toast--error .bb-retention-toast-title {
  color: #ff6b85;
}

.bb-retention-toast--error .bb-retention-toast-icon {
  background: rgba(255, 84, 112, 0.16);
}

.bb-retention-toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.bb-retention-toast.leaving {
  opacity: 0;
  transform: translate(-50%, -8px);
}

.bb-retention-toast-icon {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(0, 229, 168, 0.16);
  font-size: 1rem;
}

.bb-retention-toast-body {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.bb-retention-toast-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: #00e5a8;
  letter-spacing: 0.02em;
}

.bb-retention-toast-text {
  font-size: 0.82rem;
  line-height: 1.4;
  color: #b8c0e0;
}

@media (max-width: 768px) {
  .bb-retention-toast {
    top: auto;
    bottom: max(1rem, env(safe-area-inset-bottom, 0px));
    transform: translate(-50%, 12px);
  }

  .bb-retention-toast.visible {
    transform: translate(-50%, 0);
  }

  .bb-retention-toast.leaving {
    transform: translate(-50%, 8px);
  }
}
