/* ════════════════════════════════════════════════════════
   wallet-v2.css  v1  —  premium Referral Wallet page
   Leans on ref- classes; wl- prefix for new rules
════════════════════════════════════════════════════════ */

body.wl-page { background: #040d1a !important; }

/* ── Hero: emerald accent ── */
.wl-hero { background: #040d1a; }

.wl-hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(16,185,129,.1);
  border: 1px solid rgba(16,185,129,.26);
  backdrop-filter: blur(12px);
  color: #34d399;
  font-size: 11.5px; font-weight: 700;
  letter-spacing: .6px; text-transform: uppercase;
  padding: 8px 20px; border-radius: 100px; margin-bottom: 28px;
}
.wl-badge-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #10b981; box-shadow: 0 0 9px #10b981;
  animation: live-pulse 1.8s ease-in-out infinite;
}

/* Emerald gradient headline */
.wl-hero-h1 .grad-emerald {
  background: linear-gradient(135deg, #059669 0%, #10b981 30%, #34d399 55%, #6ee7b7 70%, #34d399 85%, #10b981 100%);
  background-size: 200% auto;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmer 4s linear infinite;
  display: inline-block;
}

/* ══════════════════════════════════════════════════
   WALLET MAIN SECTION
══════════════════════════════════════════════════ */
.wl-section {
  background: #040d1a;
  padding: 80px 28px 110px;
}
.wl-inner { max-width: 560px; margin: 0 auto; }

/* ── Lookup card ── */
.wl-lookup-card {
  background: #0a1628;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 24px; padding: 36px 32px;
  margin-bottom: 24px;
  position: relative; overflow: hidden;
}
.wl-lookup-card::before {
  content: ''; position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, #059669, #10b981, #34d399, #6ee7b7);
  border-radius: 24px 24px 0 0;
}
.wl-lookup-title {
  font-size: 20px; font-weight: 800; color: #fff;
  margin: 0 0 8px; display: flex; align-items: center; gap: 10px;
}
.wl-lookup-icon {
  width: 36px; height: 36px; border-radius: 10px; flex-shrink: 0;
  background: rgba(16,185,129,.12); border: 1px solid rgba(16,185,129,.22);
  display: flex; align-items: center; justify-content: center;
}
.wl-lookup-sub {
  font-size: 13.5px; color: rgba(255,255,255,.38); line-height: 1.65; margin: 0 0 24px;
}
.wl-field-label {
  display: block; font-size: 11px; font-weight: 700;
  color: rgba(255,255,255,.34); text-transform: uppercase;
  letter-spacing: .7px; margin-bottom: 8px;
}
.wl-code-input {
  width: 100%; box-sizing: border-box;
  background: rgba(255,255,255,.05) !important;
  border: 1px solid rgba(255,255,255,.1) !important;
  border-radius: 14px;
  color: #e2e8f0 !important; font-size: 16px; font-weight: 800;
  letter-spacing: .12em; padding: 15px 18px;
  outline: none; margin-bottom: 0 !important;
  text-transform: uppercase;
  transition: border-color .2s, box-shadow .2s;
}
.wl-code-input::placeholder { color: rgba(255,255,255,.2); text-transform: none; font-weight: 400; font-size: 14px; letter-spacing: 0; }
.wl-code-input:focus {
  border-color: rgba(16,185,129,.5) !important;
  box-shadow: 0 0 0 3px rgba(16,185,129,.1);
  background: rgba(16,185,129,.05) !important;
}
.wl-lookup-btn {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  width: 100%; margin-top: 12px;
  background: linear-gradient(135deg, #10b981, #059669);
  border: none; border-radius: 14px;
  color: #fff; font-size: 15px; font-weight: 800;
  padding: 15px 28px; cursor: pointer;
  box-shadow: 0 4px 24px rgba(16,185,129,.3);
  transition: transform .18s, box-shadow .18s;
  font-family: 'Inter', sans-serif;
}
.wl-lookup-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(16,185,129,.42); }
.wl-lookup-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

.wl-error {
  margin-top: 14px; padding: 12px 16px;
  background: rgba(239,68,68,.08); border: 1px solid rgba(239,68,68,.22);
  border-radius: 10px; color: #fca5a5; font-size: 13.5px; display: none;
}

/* ── Balance card ── */
.wl-balance-card {
  background: linear-gradient(135deg, #064e3b 0%, #065f46 55%, #047857 100%);
  border: 1px solid rgba(52,211,153,.18);
  border-radius: 26px; padding: 38px 28px;
  margin-bottom: 24px; text-align: center;
  position: relative; overflow: hidden;
  box-shadow: 0 0 40px rgba(16,185,129,.18);
  display: none;
  animation: joker-in .4s cubic-bezier(0.34,1.56,0.64,1) both;
}
@keyframes joker-in {
  from { opacity: 0; transform: scale(0.9) translateY(20px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
.wl-balance-card.visible { display: block; }
.wl-balance-card::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 50% at 50% 0%, rgba(52,211,153,.14), transparent 65%);
  pointer-events: none;
}
.wl-greeting {
  font-size: 14.5px; color: rgba(255,255,255,.46); margin-bottom: 8px;
  position: relative; z-index: 1;
}
.wl-balance-label-txt {
  font-size: 10px; font-weight: 700; color: rgba(255,255,255,.32);
  text-transform: uppercase; letter-spacing: 1.2px; margin-bottom: 10px;
  position: relative; z-index: 1; display: block;
}
.wl-balance-amt {
  font-size: clamp(3rem,7vw,4.8rem); font-weight: 900;
  color: #34d399; line-height: 1; letter-spacing: -2px;
  display: block; margin-bottom: 8px;
  position: relative; z-index: 1;
  text-shadow: 0 0 40px rgba(52,211,153,.38);
}
.wl-ref-txt {
  font-size: 13px; color: rgba(255,255,255,.36);
  margin-bottom: 22px; position: relative; z-index: 1; display: block;
}

/* Tier progress */
.wl-tier-grid {
  display: flex; gap: 8px; justify-content: center; flex-wrap: wrap;
  margin-bottom: 24px; position: relative; z-index: 1;
}
.wl-tier-item {
  background: rgba(0,0,0,.22); border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px; padding: 10px 14px; text-align: center;
  min-width: 70px; transition: transform .2s, border-color .2s;
}
.wl-tier-item.reached {
  background: rgba(52,211,153,.15); border-color: rgba(52,211,153,.42);
  transform: scale(1.06);
}
.wl-tier-count { font-size: 18px; font-weight: 900; color: #34d399; display: block; }
.wl-tier-reward { font-size: 9.5px; color: rgba(255,255,255,.35); margin-top: 3px; display: block; }

/* Referral code */
.wl-code-section { position: relative; z-index: 1; margin-bottom: 22px; }
.wl-code-label-txt {
  font-size: 10px; font-weight: 700; color: rgba(255,255,255,.3);
  text-transform: uppercase; letter-spacing: 1.2px; margin-bottom: 8px; display: block;
}
.wl-code-display {
  font-size: 20px; font-weight: 900; letter-spacing: 4px;
  background: rgba(255,255,255,.08); border: 1px dashed rgba(52,211,153,.3);
  border-radius: 12px; padding: 11px 22px;
  display: inline-block; color: #fff;
}

/* Withdraw trigger button */
.wl-withdraw-btn-trigger {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.15);
  color: #fff; padding: 14px 30px; border-radius: 40px;
  font-weight: 800; font-size: 15px; cursor: pointer;
  box-shadow: 0 4px 20px rgba(0,0,0,.3);
  transition: background .2s, transform .15s;
  font-family: 'Inter', sans-serif;
  position: relative; z-index: 1;
  border: none;
}
.wl-withdraw-btn-trigger:hover {
  background: rgba(255,255,255,.18); transform: translateY(-2px);
}

/* ── Withdraw form card ── */
.wl-withdraw-card {
  background: #0a1628;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 24px; padding: 32px 28px;
  margin-bottom: 24px;
  position: relative; overflow: hidden;
  display: none;
}
.wl-withdraw-card.visible { display: block; }
.wl-withdraw-card::before {
  content: ''; position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, #10b981, #34d399);
  border-radius: 24px 24px 0 0;
}
.wl-withdraw-ttl {
  font-size: 18px; font-weight: 800; color: #fff;
  margin: 0 0 22px; display: flex; align-items: center; gap: 10px;
}
.wl-submit-btn {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  width: 100%; margin-top: 14px;
  background: linear-gradient(135deg, #10b981, #059669);
  border: none; border-radius: 14px;
  color: #fff; font-size: 15px; font-weight: 800;
  padding: 15px 28px; cursor: pointer;
  box-shadow: 0 4px 24px rgba(16,185,129,.3);
  transition: transform .18s, box-shadow .18s;
  font-family: 'Inter', sans-serif;
}
.wl-submit-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(16,185,129,.42); }
.wl-submit-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

.wl-payout-note {
  margin-top: 16px; padding: 14px 16px;
  background: rgba(14,165,233,.07); border: 1px solid rgba(14,165,233,.16);
  border-radius: 12px; font-size: 13px; color: rgba(255,255,255,.44); line-height: 1.7;
}
.wl-payout-note strong { color: #38bdf8; }

.wl-withdraw-status {
  margin-top: 12px; padding: 12px 16px;
  border-radius: 10px; font-size: 13.5px; display: none;
}
.wl-withdraw-status.success {
  background: rgba(16,185,129,.1); border: 1px solid rgba(16,185,129,.25); color: #34d399;
}
.wl-withdraw-status.error {
  background: rgba(239,68,68,.1); border: 1px solid rgba(239,68,68,.25); color: #fca5a5;
}

/* Dark section header override */
.wl-dark-hd.ref-section-hd .ref-section-title { color: #fff; }
.wl-dark-hd.ref-section-hd .ref-section-sub   { color: rgba(255,255,255,.46); }
.wl-dark-hd.ref-section-hd .ref-label-pill {
  background: rgba(16,185,129,.1);
  border: 1px solid rgba(16,185,129,.2);
  color: #34d399;
}

/* Override global input styles */
#codeInput {
  background: rgba(255,255,255,.05) !important;
  border: 1px solid rgba(255,255,255,.1) !important;
  color: #e2e8f0 !important;
  margin-bottom: 0 !important;
  text-transform: uppercase;
}
#upiInput, #amountInput {
  background: rgba(255,255,255,.05) !important;
  border: 1px solid rgba(255,255,255,.1) !important;
  color: #e2e8f0 !important;
  margin-bottom: 0 !important;
}
#upiInput::placeholder, #amountInput::placeholder { color: rgba(255,255,255,.2); }

/* ── Tier progress items (JS-generated with .tp-item) ── */
.tp-item {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px; padding: 10px 14px; text-align: center;
  min-width: 70px; transition: transform .2s, border-color .2s;
}
.tp-item.reached {
  background: rgba(52,211,153,.15);
  border-color: rgba(52,211,153,.42);
  transform: scale(1.06);
}
.tp-item .tp-count { font-size: 18px; font-weight: 900; color: #34d399; display: block; }
.tp-item .tp-reward { font-size: 9.5px; color: rgba(255,255,255,.35); margin-top: 3px; display: block; }

/* ══════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════ */
@media (max-width: 640px) {
  /* Hero badge breathing room */
  .ref-hero.wl-hero {
    padding: 72px 16px 52px !important;
    min-height: auto !important;
  }
  .wl-section { padding: 60px 16px 80px; }
  .wl-lookup-card { padding: 26px 20px; }
  .wl-balance-card { padding: 28px 18px; }
  .wl-withdraw-card { padding: 26px 18px; }
  .wl-balance-amt { font-size: 3rem; }
}
