:root {
  --primary: #ff3c1f;
  --primary-soft: rgba(255, 60, 31, 0.12);
  --border: rgba(0, 0, 0, 0.08);
  --muted: #777;
}

* {
  box-sizing: border-box;
}
/* ================= GLOBAL STATS GRID ================= */

/* ================= GLOBAL STATS GRID (PREMIUM) ================= */
.main-content {
  margin-left: 250px; 
  padding: 40px;
}


.stats-grid {
  max-width: 1200px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* FIX 3 COLUMN */
  gap: 20px;
  margin-bottom: 40px;
}

.stat-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 24px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 18px;
  transition: all 0.25s ease;
  box-shadow: 0 10px 30px rgba(0,0,0,0.04);
  position: relative;
  overflow: hidden;
}

/* subtle gradient accent */
.stat-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 4px;
  width: 100%;
  background: linear-gradient(90deg, var(--primary), #ff6a4d);
}

/* hover effect */
.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(255,60,31,0.12);
}

/* icon */
.stat-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  background: var(--primary-soft);
  color: var(--primary);
  flex-shrink: 0;
}

/* text */
.stat-content {
  display: flex;
  flex-direction: column;
}

.stat-title {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 6px;
  font-weight: 500;
}

.stat-number {
  font-size: 26px;
  font-weight: 800;
  color: #111;
}

/* ================= MOBILE FIX ================= */

@media (max-width: 900px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}
body {
  margin: 0;
  font-family: Inter, sans-serif;
  background: linear-gradient(180deg, #f4f6ff, #eef1ff);
}
.referral-input {
  margin-top: 15px;
  width: 100%;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid #ddd;
  font-weight: 600;
  text-transform: uppercase;
}

.my-referral-box {
  margin-top: 15px;
  padding: 16px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid #eee;
  text-align: center;
}

#myReferralCode {
  margin-top: 5px;
  font-weight: 800;
  font-size: 18px;
}
.referral-section {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.apply-referral-btn {
  padding: 14px;
  border-radius: 14px;
  border: none;
  background: linear-gradient(135deg, #111, #333);
  color: white;
  font-weight: 700;
  cursor: pointer;
  transition: 0.3s ease;
}

.apply-referral-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(0,0,0,0.2);
}

.apply-referral-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
/* ================= WRAPPER ================= */
/* ================= USER TOTAL BOX ================= */

.user-total-box {
  margin-top: 20px;
  padding: 22px;
  border-radius: 18px;
  background: #ffffff;
  border: 1px solid #ececec;
  text-align: center;
  box-shadow: 0 8px 25px rgba(0,0,0,0.05);
}

.user-total-label {
  font-size: 13px;
  color: #777;
  margin-bottom: 5px;
}

.user-total-value {
  font-size: 28px;
  font-weight: 800;
  color: #111;
}

.mine-wrapper {
  display: flex;
  justify-content: center;
  /*padding: 80px 20px;*/
}

/* ================= CARD ================= */

.mine-card {
  width: 100%;
  max-width: 540px;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(20px);
  border-radius: 26px;
  padding: 48px;
  box-shadow: 0 40px 80px rgba(0,0,0,0.08);
  transition: 0.3s ease;
}

.mine-card:hover {
  transform: translateY(-6px);
}

/* ================= HEADER ================= */

.mine-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

/* title + wallet wrapper */

.mine-title-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.mine-title-text {
  font-size: 20px;
  font-weight: 800;
}

/* wallet badge */

.wallet-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.05);
  color: #444;
  backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.3s ease;
}

.wallet-badge:hover {
  background: rgba(0,0,0,0.08);
  transform: translateY(-1px);
}

/* mining rate badge */

.mine-badge {
  background: var(--primary-soft);
  color: var(--primary);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
}

/* ================= DESCRIPTION ================= */

.mine-description {
  margin-top: 20px;
  font-size: 15px;
  color: var(--muted);
  line-height: 1.6;
}

.mine-description span {
  color: var(--primary);
  font-weight: 700;
}

/* ================= STATS ================= */

.mine-stats {
  margin-top: 30px;
  padding: 30px;
  border-radius: 20px;
  background: var(--primary-soft);
  text-align: center;
}

.stat-label {
  font-size: 13px;
  color: var(--muted);
}

.stat-value {
  font-size: 20px;
  font-weight: 900;
  margin-top: 10px;
  color: var(--primary);
}

.countdown {
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
}

/* ================= BUTTON ================= */

.mine-btn {
  margin-top: 28px;
  width: 100%;
  padding: 16px;
  border-radius: 16px;
  border: none;
  background: linear-gradient(135deg, var(--primary), #ff6a4d);
  color: white;
  font-weight: 700;
  cursor: pointer;
  transition: 0.3s ease;
}

.mine-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(255,60,31,0.25);
}

/* hide connect button after connected */
.mine-btn.connected-hidden {
  display: none;
}

/* ================= MODAL ================= */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(6px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999;
}

.modal-box {
  width: 90%;
  max-width: 360px;
  background: white;
  border-radius: 20px;
  padding: 28px;
  text-align: center;
  box-shadow: 0 25px 60px rgba(0,0,0,0.2);
  animation: popupScale 0.2s ease;
}

@keyframes popupScale {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal-text {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 24px;
}

.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.modal-btn {
  flex: 1;
  padding: 12px;
  border-radius: 12px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s ease;
}

.modal-confirm {
  background: #ff3c1f;
  color: white;
}

.modal-confirm:hover {
  background: #e23318;
}

.modal-cancel {
  background: #f3f3f3;
}

.modal-cancel:hover {
  background: #e6e6e6;
}

/* ================= UTILITY ================= */

.hidden {
  display: none;
}

/* ================= MOBILE ================= */

@media (max-width: 600px) {

  .mine-card {
    padding: 28px;
  }

  .mine-title-wrapper {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  .mine-title-text {
    font-size: 18px;
  }

  .wallet-badge {
    font-size: 11px;
    padding: 5px 12px;
  }

  .stat-value {
    font-size: 20px;
  }

}
