/* ============================================
   TAP MINER - PROFESSIONAL UI v5.0
   Premium Mobile Game Design
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;500;600;700;800;900&family=Inter:wght@400;500;600;700;800;900&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Primary Colors - Logo Matched */
  --blue: #1FA3FF;
  --blue-light: #4DB8FF;
  --blue-dark: #0B6FD6;
  --blue-glow: rgba(31, 163, 255, 0.5);
  
  --gold: #FFC400;
  --gold-light: #FFD54F;
  --gold-dark: #E6A000;
  --gold-glow: rgba(255, 196, 0, 0.4);
  
  --cyan: #00E5FF;
  --cyan-glow: rgba(0, 229, 255, 0.5);
  
  --green: #2DFF7A;
  --green-dark: #00C853;
  --green-glow: rgba(45, 255, 122, 0.4);
  
  --orange: #FF8C00;
  --red: #FF4444;
  --purple: #A855F7;
  --pink: #FF69B4;
  
  /* Background */
  --bg-primary: #0A0E14;
  --bg-secondary: #111922;
  --bg-card: #151E29;
  --bg-card-hover: #1A2634;
  --bg-elevated: #1E2A38;
  
  /* Text */
  --text-primary: #FFFFFF;
  --text-secondary: #A0AEC0;
  --text-muted: #5A6A7A;
  
  /* Borders */
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-light: rgba(255, 255, 255, 0.1);
  
  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow-blue: 0 0 20px var(--blue-glow);
  --shadow-glow-gold: 0 0 20px var(--gold-glow);
  
  /* Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;
}

/* ============================================
   BASE STYLES
   ============================================ */

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  user-select: none;
  -webkit-user-select: none;
}

#app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: 
    radial-gradient(ellipse at 50% 0%, rgba(31, 163, 255, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 100%, rgba(255, 196, 0, 0.06) 0%, transparent 50%),
    var(--bg-primary);
}

/* Subtle particle overlay */
#app::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: 
    radial-gradient(circle at 20% 30%, rgba(255, 196, 0, 0.15) 0%, transparent 2px),
    radial-gradient(circle at 80% 20%, rgba(255, 196, 0, 0.1) 0%, transparent 1px),
    radial-gradient(circle at 40% 80%, rgba(31, 163, 255, 0.12) 0%, transparent 2px),
    radial-gradient(circle at 90% 70%, rgba(255, 196, 0, 0.08) 0%, transparent 1px);
  pointer-events: none;
  z-index: 0;
  animation: twinkle 4s ease-in-out infinite;
}

@keyframes twinkle {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

/* Ambient glow orbs */
.orb { display: none; }

/* ============================================
   HEADER
   ============================================ */

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: rgba(17, 25, 34, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 100;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, var(--gold), var(--orange));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  box-shadow: var(--shadow-glow-gold);
}

.user-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.username {
  font-weight: 700;
  font-size: 14px;
  color: var(--text-primary);
}

.level {
  font-size: 11px;
  font-weight: 600;
  color: var(--gold);
  font-family: 'Orbitron', sans-serif;
}

.coins-display {
  display: flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, rgba(255, 196, 0, 0.15), rgba(255, 196, 0, 0.05));
  border: 1px solid rgba(255, 196, 0, 0.3);
  padding: 8px 14px;
  border-radius: var(--radius-full);
}

.coin-icon {
  font-size: 18px;
}

.coins {
  font-size: 15px;
  font-weight: 800;
  font-family: 'Orbitron', sans-serif;
  color: var(--gold);
}

/* ============================================
   NAVIGATION TABS
   ============================================ */

.tabs {
  display: flex;
  background: var(--bg-secondary);
  padding: 6px;
  margin: 10px 12px;
  gap: 4px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
}

.tab {
  flex: 1;
  padding: 12px 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 18px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.tab.active {
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  color: white;
  box-shadow: var(--shadow-glow-blue);
}

.tab:not(.active):hover {
  background: var(--bg-card);
  color: var(--text-secondary);
}

/* ============================================
   TAB CONTENT
   ============================================ */

.tab-content {
  display: none;
  flex: 1;
  padding: 16px;
  padding-bottom: 100px;
  position: relative;
  z-index: 10;
}

.tab-content.active {
  display: flex;
  flex-direction: column;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   SECTION TITLES
   ============================================ */

.section-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin: 20px 0 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border-light), transparent);
}

/* ============================================
   CARDS
   ============================================ */

.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  padding: 16px;
  transition: all 0.2s ease;
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-light);
}

/* ============================================
   PRESTIGE BANNER
   ============================================ */

.prestige-banner {
  background: linear-gradient(135deg, var(--gold), var(--orange));
  border-radius: var(--radius-lg);
  padding: 14px 18px;
  margin-bottom: 12px;
  cursor: pointer;
  text-align: center;
  box-shadow: var(--shadow-glow-gold);
  animation: prestigePulse 2s ease-in-out infinite;
}

@keyframes prestigePulse {
  0%, 100% { box-shadow: 0 0 20px var(--gold-glow); }
  50% { box-shadow: 0 0 30px var(--gold-glow), 0 0 40px rgba(255, 140, 0, 0.3); }
}

.prestige-text {
  font-size: 16px;
  font-weight: 800;
  color: #1a1a1a;
  font-family: 'Orbitron', sans-serif;
}

.prestige-info {
  font-size: 11px;
  color: rgba(0,0,0,0.6);
  margin-top: 2px;
}

/* ============================================
   DAILY BANNER
   ============================================ */

.daily-banner {
  background: linear-gradient(135deg, var(--gold), var(--orange));
  border-radius: var(--radius-lg);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  cursor: pointer;
  box-shadow: var(--shadow-glow-gold);
}

.daily-text {
  color: #1a1a1a;
  font-weight: 700;
  font-size: 14px;
}

.daily-reward {
  background: #1a1a1a;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  color: var(--gold);
  font-weight: 800;
  font-size: 12px;
  font-family: 'Orbitron', sans-serif;
}

/* ============================================
   QUESTS SECTION
   ============================================ */

.quests-section {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}

.quests-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
}

.quest-progress-badge {
  background: var(--green);
  color: #1a1a1a;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 800;
}

.quests-list {
  padding: 0 12px 12px;
}

.quest-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  margin-bottom: 8px;
}

.quest-icon {
  font-size: 22px;
  width: 36px;
  text-align: center;
}

.quest-info {
  flex: 1;
  min-width: 0;
}

.quest-name {
  font-weight: 600;
  font-size: 12px;
  margin-bottom: 6px;
}

.quest-progress-bar {
  height: 5px;
  background: rgba(255,255,255,0.1);
  border-radius: 3px;
  overflow: hidden;
}

.quest-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  border-radius: 3px;
  transition: width 0.3s ease;
}

.quest-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.quest-reward {
  font-size: 11px;
  color: var(--gold);
  font-weight: 700;
}

.quest-claim {
  background: var(--green);
  color: #1a1a1a;
  border: none;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 10px;
  cursor: pointer;
  text-transform: uppercase;
}

.quest-item.completed .quest-progress-fill {
  background: var(--green);
}

.quest-item.claimed {
  opacity: 0.5;
}

/* ============================================
   STATS BAR
   ============================================ */

.stats-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.stat {
  flex: 1;
  background: var(--bg-card);
  padding: 14px 12px;
  border-radius: var(--radius-lg);
  text-align: center;
  border: 1px solid var(--border-subtle);
}

.stat-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.stat-value {
  font-size: 18px;
  font-weight: 800;
  font-family: 'Orbitron', sans-serif;
}

.stat:first-child .stat-value {
  color: var(--green);
}

.stat:last-child .stat-value {
  color: var(--gold);
}

/* Energy Bar */
.energy-bar {
  height: 6px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 3px;
  margin: 8px 0;
  overflow: hidden;
}

.energy-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--green-dark), var(--green), var(--cyan));
  border-radius: 3px;
  transition: width 0.3s ease;
}

/* ============================================
   MINING AREA
   ============================================ */

.mining-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px 0;
}

.miner-container {
  text-align: center;
  position: relative;
}

.miner {
  width: 180px;
  height: 180px;
  background: 
    radial-gradient(circle at 50% 50%, rgba(0, 229, 255, 0.2) 0%, transparent 60%),
    linear-gradient(180deg, var(--bg-elevated) 0%, var(--bg-secondary) 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  transition: transform 0.1s ease;
  box-shadow: 
    0 0 0 3px var(--cyan),
    0 0 0 6px rgba(0, 229, 255, 0.3),
    0 0 40px var(--cyan-glow),
    0 0 80px rgba(0, 229, 255, 0.2);
  animation: minerGlow 3s ease-in-out infinite;
}

@keyframes minerGlow {
  0%, 100% { 
    box-shadow: 
      0 0 0 3px var(--cyan),
      0 0 0 6px rgba(0, 229, 255, 0.3),
      0 0 40px var(--cyan-glow),
      0 0 80px rgba(0, 229, 255, 0.2);
  }
  50% { 
    box-shadow: 
      0 0 0 4px var(--cyan),
      0 0 0 8px rgba(0, 229, 255, 0.4),
      0 0 50px var(--cyan-glow),
      0 0 100px rgba(0, 229, 255, 0.3);
  }
}

.miner:active {
  transform: scale(0.95);
}

.pickaxe {
  font-size: 70px;
  filter: drop-shadow(0 0 15px var(--gold-glow));
  animation: swing 1s ease-in-out infinite;
  transform-origin: 60% 60%;
}

@keyframes swing {
  0%, 100% { transform: rotate(-15deg); }
  50% { transform: rotate(15deg); }
}

/* Pulsing Rings */
.ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 2px solid var(--cyan);
  animation: ringExpand 2s ease-out infinite;
  pointer-events: none;
}

.ring-1 { width: 200px; height: 200px; animation-delay: 0s; }
.ring-2 { width: 240px; height: 240px; animation-delay: 0.4s; opacity: 0.7; }
.ring-3 { width: 280px; height: 280px; animation-delay: 0.8s; opacity: 0.4; }

@keyframes ringExpand {
  0% { transform: translate(-50%, -50%) scale(0.9); opacity: 0.8; }
  100% { transform: translate(-50%, -50%) scale(1.1); opacity: 0; }
}

.glow {
  position: absolute;
  inset: -20px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 229, 255, 0.3) 0%, transparent 70%);
  animation: glowPulse 2s ease-in-out infinite;
  pointer-events: none;
}

@keyframes glowPulse {
  0%, 100% { opacity: 0.5; transform: scale(0.95); }
  50% { opacity: 1; transform: scale(1.05); }
}

.tap-text {
  margin-top: 24px;
  font-size: 14px;
  font-weight: 800;
  font-family: 'Orbitron', sans-serif;
  background: linear-gradient(180deg, #fff, var(--blue-light), var(--blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 3px;
  text-transform: uppercase;
}

.tap-power {
  margin-top: 8px;
  font-size: 28px;
  font-weight: 900;
  font-family: 'Orbitron', sans-serif;
  background: linear-gradient(180deg, var(--gold-light), var(--gold), var(--gold-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 2px 10px var(--gold-glow));
}

.sparks-container {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.spark {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: spark-fly 0.5s ease-out forwards;
}

@keyframes spark-fly {
  0% {
    transform: translate(0, 0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translate(var(--tx, 50px), var(--ty, -50px)) scale(0);
    opacity: 0;
  }
}

.floating-coins {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1000;
  overflow: hidden;
}

.float-coin {
  position: absolute;
  font-size: 32px;
  pointer-events: none;
  animation: float-up 0.8s ease-out forwards;
  opacity: 1;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.8);
}

@keyframes float-up {
  0% {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translateY(-80px) scale(0.5);
    opacity: 0;
  }
}

/* ============================================
   UPGRADES
   ============================================ */

.upgrades-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.upgrade-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card);
  padding: 14px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  transition: all 0.2s ease;
}

.upgrade-item:hover {
  border-color: var(--border-light);
  background: var(--bg-card-hover);
}

.upgrade-icon {
  font-size: 28px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
}

.upgrade-info {
  flex: 1;
  min-width: 0;
}

.upgrade-name {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 2px;
}

.upgrade-effect {
  font-size: 11px;
  color: var(--green);
}

.upgrade-level {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 2px;
}

.upgrade-cost {
  text-align: right;
}

.upgrade-cost .cost {
  font-size: 14px;
  font-weight: 700;
  color: var(--gold);
  font-family: 'Orbitron', sans-serif;
}

.btn-upgrade {
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  border: none;
  padding: 10px 16px;
  border-radius: var(--radius-full);
  color: white;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  margin-top: 6px;
  transition: all 0.2s ease;
}

.btn-upgrade:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-blue);
}

.btn-upgrade:disabled {
  background: var(--text-muted);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ============================================
   EXPEDITIONS
   ============================================ */

.expeditions-header {
  text-align: center;
  margin-bottom: 20px;
}

.expeditions-header h2 {
  font-size: 20px;
  font-family: 'Orbitron', sans-serif;
  margin-bottom: 6px;
}

.expeditions-header p {
  font-size: 13px;
  color: var(--text-secondary);
}

.expedition-stats {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--text-muted);
}

.active-expeditions {
  margin-bottom: 20px;
}

.active-expedition {
  background: linear-gradient(135deg, rgba(30, 35, 50, 0.9), rgba(20, 25, 35, 0.95));
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 12px;
  border: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.active-expedition.completed {
  border-color: var(--green);
  background: linear-gradient(135deg, rgba(0, 210, 106, 0.1), rgba(20, 30, 25, 0.95));
  box-shadow: 0 4px 20px rgba(0, 210, 106, 0.15);
}

.active-expedition.failed {
  border-color: #ff4757;
  background: linear-gradient(135deg, rgba(255, 71, 87, 0.1), rgba(30, 20, 20, 0.95));
  box-shadow: 0 4px 20px rgba(255, 71, 87, 0.15);
}

.active-expedition .expedition-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.active-expedition .expedition-result {
  font-size: 15px;
  font-weight: 700;
}

.active-expedition.completed .expedition-result {
  color: var(--green);
}

.active-expedition.failed .expedition-result {
  color: #ff4757;
}

.exp-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.exp-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.exp-bet {
  font-size: 12px;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.1);
  padding: 4px 10px;
  border-radius: 20px;
}

.exp-result {
  font-size: 16px;
  font-weight: 700;
  padding: 8px 0;
}

.exp-result.success {
  color: var(--green);
}

.exp-result.failed {
  color: #ff4757;
}

.expedition-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 14px;
  margin-bottom: 10px;
  border: 1px solid var(--border-subtle);
}

.expedition-card.active {
  border-color: var(--blue);
  box-shadow: 0 0 15px rgba(31, 163, 255, 0.15);
}

.expedition-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.expedition-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card);
  padding: 14px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: all 0.2s ease;
}

.expedition-item:hover {
  border-color: var(--blue);
  background: var(--bg-card-hover);
}

.expedition-icon {
  font-size: 32px;
}

.expedition-info {
  flex: 1;
}

.expedition-name {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 4px;
}

.expedition-details {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: var(--text-muted);
}

.expedition-multiplier {
  color: var(--green);
  font-weight: 700;
  font-size: 16px;
  font-family: 'Orbitron', sans-serif;
}

/* ============================================
   WALLET
   ============================================ */

.wallet-header {
  background: linear-gradient(135deg, var(--gold), var(--orange));
  border-radius: var(--radius-xl);
  padding: 28px 20px;
  text-align: center;
  position: relative;
  margin-bottom: 20px;
  box-shadow: var(--shadow-glow-gold);
}

.balance-label {
  display: block;
  font-size: 11px;
  color: rgba(0, 0, 0, 0.5);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 4px;
}

.balance-coins {
  display: block;
  font-size: 36px;
  font-weight: 900;
  font-family: 'Orbitron', sans-serif;
  color: #1a1a1a;
}

.balance-usd {
  display: block;
  font-size: 14px;
  color: rgba(0, 0, 0, 0.6);
  margin-top: 4px;
}

.vip-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  background: #1a1a1a;
  color: var(--gold);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 800;
}

/* Boost Tiers */
.boost-tiers {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.boost-tier {
  flex: 1;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 16px 10px;
  text-align: center;
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.boost-tier:hover {
  border-color: var(--gold);
  transform: translateY(-2px);
}

.boost-tier.featured {
  border-color: var(--gold);
  box-shadow: 0 0 20px var(--gold-glow);
}

.boost-tier.premium {
  border-color: var(--purple);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.3);
}

.tier-badge {
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: #1a1a1a;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-size: 9px;
  font-weight: 800;
}

.tier-amount {
  font-size: 22px;
  font-weight: 900;
  font-family: 'Orbitron', sans-serif;
  color: var(--gold);
  margin-bottom: 4px;
}

.tier-bonus {
  font-size: 12px;
  font-weight: 700;
  color: var(--green);
}

.tier-duration {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Staking Pools */
.staking-pools {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.staking-pool {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  transition: all 0.2s ease;
}

.staking-pool:hover {
  border-color: var(--border-light);
}

.staking-pool.featured {
  border-color: var(--gold);
}

.staking-pool.premium {
  border-color: var(--cyan);
}

.pool-icon {
  font-size: 26px;
}

.pool-info {
  flex: 1;
}

.pool-name {
  font-weight: 700;
  font-size: 13px;
}

.pool-stats {
  font-size: 11px;
  color: var(--text-muted);
}

.btn-stake {
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  border: none;
  padding: 10px 16px;
  border-radius: var(--radius-full);
  color: white;
  font-weight: 700;
  font-size: 11px;
  cursor: pointer;
}

/* Active Stakes */
.active-stakes {
  margin-top: 16px;
}

.active-stakes h4 {
  font-size: 13px;
  margin-bottom: 10px;
  color: var(--text-secondary);
}

.stake-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 10px;
  border: 1px solid var(--border-subtle);
}

.stake-card-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.stake-pool-name {
  font-weight: 700;
  font-size: 13px;
}

.stake-amount {
  color: var(--gold);
  font-weight: 700;
  font-family: 'Orbitron', sans-serif;
}

.stake-pending {
  color: var(--green);
  font-size: 12px;
  margin-bottom: 10px;
}

.stake-actions {
  display: flex;
  gap: 8px;
}

.btn-claim {
  background: linear-gradient(135deg, #00d26a, #00a854);
  color: #fff;
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 15px rgba(0, 210, 106, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.2s ease;
}

.btn-claim:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 210, 106, 0.5);
}

.btn-claim:active {
  transform: translateY(0);
}

.btn-claim-stake, .btn-withdraw-stake {
  flex: 1;
  padding: 10px;
  border-radius: var(--radius-md);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  border: none;
}

.btn-claim-stake {
  background: var(--green);
  color: #1a1a1a;
}

.btn-withdraw-stake {
  background: var(--gold);
  color: #1a1a1a;
}

.btn-withdraw-stake:disabled {
  background: var(--text-muted);
  cursor: not-allowed;
}

/* Withdraw Box */
.withdraw-box {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 16px;
  border: 1px solid var(--border-subtle);
}

.withdraw-info {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.withdraw-input-group {
  display: flex;
  gap: 10px;
}

.withdraw-input-group input {
  flex: 1;
  min-width: 0;
  padding: 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  color: white;
  font-size: 16px;
  font-weight: 600;
}

.withdraw-input-group input:focus {
  outline: none;
  border-color: var(--cyan);
}

.btn-withdraw {
  padding: 14px 18px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  border: none;
  border-radius: var(--radius-md);
  color: white;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  white-space: nowrap;
}

.withdraw-preview {
  text-align: center;
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-secondary);
}

/* ============================================
   LEADERBOARD / RANK
   ============================================ */

.achievements-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.achievements-header h2 {
  font-size: 18px;
  font-family: 'Orbitron', sans-serif;
}

.achievement-progress {
  background: var(--bg-card);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 700;
}

.achievements-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 20px;
}

.achievement-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 12px 6px;
  text-align: center;
  border: 1px solid var(--border-subtle);
}

.achievement-card.locked {
  opacity: 0.4;
  filter: grayscale(0.8);
}

.achievement-card.unlocked {
  border-color: var(--gold);
  box-shadow: 0 0 10px var(--gold-glow);
}

.achievement-card .icon {
  font-size: 24px;
  margin-bottom: 4px;
}

.achievement-card .name {
  font-size: 9px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--text-secondary);
}

/* Tournament */
.tournament-info {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 20px;
  border: 1px solid var(--border-subtle);
}

.tournament-timer {
  text-align: center;
  font-size: 13px;
  margin-bottom: 12px;
  color: var(--text-secondary);
}

.tournament-timer span {
  color: var(--gold);
  font-weight: 700;
  font-family: 'Orbitron', sans-serif;
}

.tournament-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}

.t-tab {
  flex: 1;
  padding: 10px;
  background: var(--bg-secondary);
  border: none;
  border-radius: var(--radius-md);
  color: var(--text-muted);
  font-size: 11px;
  cursor: pointer;
}

.t-tab.active {
  background: var(--blue);
  color: white;
}

.tournament-leaderboard .t-entry {
  display: flex;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.t-entry .rank {
  width: 30px;
  font-weight: 700;
  color: var(--gold);
}

.t-entry .name {
  flex: 1;
  font-size: 13px;
}

.t-entry .score {
  font-weight: 700;
  font-family: 'Orbitron', sans-serif;
  color: var(--cyan);
  font-size: 13px;
}

/* Leaderboard */
.leaderboard {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}

.leader-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: linear-gradient(135deg, rgba(30, 35, 50, 0.9), rgba(25, 30, 40, 0.95));
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  transition: all 0.2s;
}

.leader-item:first-child {
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.15), rgba(30, 30, 20, 0.95));
  border-color: var(--gold);
  box-shadow: 0 4px 20px rgba(255, 215, 0, 0.15);
}

.leader-item:nth-child(2) {
  background: linear-gradient(135deg, rgba(192, 192, 192, 0.1), rgba(30, 30, 35, 0.95));
  border-color: #c0c0c0;
}

.leader-item:nth-child(3) {
  background: linear-gradient(135deg, rgba(205, 127, 50, 0.1), rgba(30, 28, 25, 0.95));
  border-color: #cd7f32;
}

.leader-rank {
  font-size: 20px;
  width: 36px;
  text-align: center;
}

.leader-rank.gold { color: var(--gold); }
.leader-rank.silver { color: #c0c0c0; }
.leader-rank.bronze { color: #cd7f32; }

.leader-name {
  flex: 1;
  font-weight: 600;
  font-size: 15px;
  color: var(--text-primary);
}

.leader-coins {
  font-weight: 700;
  font-family: 'Orbitron', sans-serif;
  font-size: 16px;
  color: var(--gold);
}

.your-rank {
  text-align: center;
  padding: 18px;
  margin-top: 20px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  border-radius: var(--radius-lg);
  font-weight: 700;
  font-size: 16px;
  color: white;
  box-shadow: 0 4px 20px rgba(31, 163, 255, 0.3);
}

/* ============================================
   FRIENDS
   ============================================ */

.friends-header {
  text-align: center;
  margin-bottom: 20px;
}

.friends-header h2 {
  font-size: 20px;
  font-family: 'Orbitron', sans-serif;
  margin-bottom: 6px;
}

.friends-header p {
  font-size: 13px;
  color: var(--text-secondary);
}

.referral-stats {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.ref-stat {
  flex: 1;
  background: var(--bg-card);
  padding: 16px;
  border-radius: var(--radius-lg);
  text-align: center;
  border: 1px solid var(--border-subtle);
}

.ref-value {
  display: block;
  font-size: 28px;
  font-weight: 900;
  font-family: 'Orbitron', sans-serif;
  color: var(--gold);
  margin-bottom: 4px;
}

.ref-label {
  font-size: 11px;
  color: var(--text-muted);
}

.invite-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  border: none;
  border-radius: var(--radius-lg);
  color: white;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  box-shadow: var(--shadow-glow-blue);
}

/* ============================================
   MODALS
   ============================================ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal {
  background: var(--bg-elevated);
  border-radius: var(--radius-xl);
  padding: 24px;
  max-width: 360px;
  width: 100%;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-lg);
}

.modal h3 {
  font-size: 18px;
  font-family: 'Orbitron', sans-serif;
  text-align: center;
  margin-bottom: 16px;
}

.modal-stats {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}

.modal-stat {
  flex: 1;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  padding: 12px;
  text-align: center;
  border: 1px solid var(--border-subtle);
}

.modal-stat .label {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.modal-stat .value {
  display: block;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.bet-input-container {
  margin-bottom: 12px;
}

.bet-input-container label {
  display: block;
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.bet-input-container input {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 18px;
  font-weight: 600;
  text-align: center;
  outline: none;
  transition: all 0.2s;
}

.bet-input-container input:focus {
  border-color: var(--blue);
  background: rgba(255, 255, 255, 0.12);
}

.bet-shortcuts {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.bet-shortcuts button {
  flex: 1;
  padding: 10px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.bet-shortcuts button:hover {
  background: var(--blue);
  color: white;
  border-color: var(--blue);
}

.bet-shortcuts button:last-child {
  background: linear-gradient(135deg, var(--gold), #ffaa00);
  color: #1a1a1a;
  border: none;
  font-weight: 700;
}

.potential-reward {
  margin-top: 12px;
  padding: 12px;
  background: linear-gradient(135deg, rgba(0, 210, 106, 0.15), rgba(0, 150, 76, 0.1));
  border: 1px solid rgba(0, 210, 106, 0.3);
  border-radius: var(--radius-md);
  text-align: center;
  font-size: 15px;
  color: var(--green);
  font-weight: 600;
}

.potential-reward span {
  font-weight: 700;
  font-size: 17px;
}

.modal-buttons {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.btn-cancel {
  flex: 1;
  padding: 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  color: var(--text-secondary);
  font-weight: 600;
  cursor: pointer;
}

.btn-start, .btn-spin, .btn-prestige, .btn-stake-confirm {
  flex: 1;
  padding: 14px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  border: none;
  border-radius: var(--radius-lg);
  color: white;
  font-weight: 700;
  cursor: pointer;
}

/* Stake Modal */
.stake-modal .stake-info {
  display: flex;
  gap: 10px;
  margin-bottom: 12px;
}

.stake-modal .stake-stat {
  flex: 1;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 12px;
  text-align: center;
}

.stake-modal .stake-stat .label {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.stake-modal .stake-stat .value {
  font-size: 16px;
  font-weight: 800;
  color: var(--cyan);
  font-family: 'Orbitron', sans-serif;
}

.stake-limits {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  margin-bottom: 16px;
}

.stake-limit {
  text-align: center;
}

.stake-limit .limit-label {
  display: block;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.stake-limit .limit-value {
  font-size: 18px;
  font-weight: 900;
  font-family: 'Orbitron', sans-serif;
  color: var(--cyan);
}

.stake-limit-divider {
  color: var(--text-muted);
  font-size: 18px;
}

.stake-input-container {
  margin-bottom: 12px;
}

.stake-input-container label {
  display: block;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.stake-input-container input {
  width: 100%;
  padding: 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  color: white;
  font-size: 18px;
  font-weight: 700;
  text-align: center;
}

.stake-shortcuts {
  display: flex;
  gap: 8px;
  margin: 10px 0;
}

.stake-shortcuts button {
  flex: 1;
  padding: 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 12px;
  cursor: pointer;
}

.stake-shortcuts button:hover {
  background: var(--bg-card);
  border-color: var(--border-light);
}

.stake-preview {
  text-align: center;
  font-size: 14px;
  color: var(--green);
  font-weight: 600;
}

/* Prestige Modal */
.prestige-modal {
  text-align: center;
}

.prestige-desc {
  color: var(--text-secondary);
  font-size: 13px;
  margin-bottom: 16px;
}

.prestige-info-box {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.prestige-stat {
  flex: 1;
  background: rgba(255, 196, 0, 0.1);
  border: 1px solid var(--gold);
  border-radius: var(--radius-md);
  padding: 12px;
}

.prestige-stat .label {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.prestige-stat .value {
  font-size: 22px;
  font-weight: 900;
  font-family: 'Orbitron', sans-serif;
  color: var(--gold);
}

.prestige-rewards {
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 12px;
  text-align: left;
}

.prestige-rewards h4 {
  font-size: 11px;
  margin-bottom: 8px;
  color: var(--text-muted);
}

.reward-item {
  font-size: 12px;
  padding: 3px 0;
}

.prestige-warning {
  font-size: 11px;
  color: var(--orange);
  padding: 10px;
  background: rgba(255, 140, 0, 0.1);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
}

/* Spin Modal */
.spin-modal {
  text-align: center;
}

.spin-wheel {
  width: 200px;
  height: 200px;
  margin: 20px auto;
  position: relative;
}

.wheel-pointer {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 28px;
  color: var(--gold);
  z-index: 10;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

.wheel-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: conic-gradient(
    var(--blue) 0deg 36deg,
    var(--gold) 36deg 72deg,
    var(--green) 72deg 108deg,
    var(--purple) 108deg 144deg,
    var(--orange) 144deg 180deg,
    var(--cyan) 180deg 216deg,
    var(--pink) 216deg 252deg,
    var(--blue-dark) 252deg 288deg,
    var(--green-dark) 288deg 324deg,
    var(--red) 324deg 360deg
  );
  border: 4px solid var(--gold);
  box-shadow: 0 0 20px var(--gold-glow);
  transition: transform 4s cubic-bezier(0.17, 0.67, 0.12, 0.99);
}

.spin-result {
  background: var(--bg-secondary);
  padding: 16px;
  border-radius: var(--radius-md);
  margin: 16px 0;
}

.result-text {
  font-size: 20px;
  font-weight: 800;
  font-family: 'Orbitron', sans-serif;
  color: var(--gold);
}

/* Achievement Popup */
.achievement-popup {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--gold), var(--orange));
  padding: 14px 20px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 9999;
  animation: popupSlide 0.4s ease;
  box-shadow: 0 8px 32px rgba(255, 196, 0, 0.4);
}

@keyframes popupSlide {
  from { transform: translateX(-50%) translateY(-60px); opacity: 0; }
  to { transform: translateX(-50%) translateY(0); opacity: 1; }
}

.achievement-popup .achievement-icon {
  font-size: 32px;
}

.achievement-popup .achievement-title {
  font-size: 10px;
  text-transform: uppercase;
  color: rgba(0,0,0,0.6);
}

.achievement-popup .achievement-name {
  font-size: 14px;
  font-weight: 800;
  color: #1a1a1a;
}

/* ============================================
   LOADING & GATE
   ============================================ */

.loading {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.loader {
  font-size: 48px;
  animation: bounce 0.6s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.loading p {
  margin-top: 16px;
  color: var(--text-muted);
}

.loading.hidden {
  display: none;
}

.community-gate {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
  padding: 20px;
}

.gate-content {
  text-align: center;
  max-width: 320px;
}

.gate-icon {
  font-size: 64px;
  margin-bottom: 16px;
}

.gate-content h2 {
  font-size: 22px;
  font-family: 'Orbitron', sans-serif;
  margin-bottom: 10px;
}

.gate-content p {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 20px;
}

.gate-benefits {
  text-align: left;
  margin-bottom: 24px;
}

.benefit {
  padding: 8px 0;
  font-size: 13px;
  color: var(--text-secondary);
}

.btn-join-community {
  display: block;
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  border-radius: var(--radius-lg);
  color: white;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  margin-bottom: 12px;
}

.btn-verify {
  width: 100%;
  padding: 14px;
  background: transparent;
  border: 2px solid var(--green);
  border-radius: var(--radius-lg);
  color: var(--green);
  font-weight: 700;
  cursor: pointer;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 360px) {
  .miner {
    width: 150px;
    height: 150px;
  }
  
  .pickaxe {
    font-size: 56px;
  }
  
  .tap-power {
    font-size: 24px;
  }
  
  .achievements-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================
   ENHANCED TOAST NOTIFICATIONS
   ============================================ */

.toast {
  position: fixed;
  bottom: 100px;
  left: 50%;
  transform: translateX(-50%);
  padding: 14px 24px;
  border-radius: var(--radius-lg);
  font-weight: 600;
  font-size: 14px;
  z-index: 10000;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: toast-in 0.3s ease-out;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.toast-icon {
  font-size: 18px;
}

.toast-info {
  background: linear-gradient(135deg, #3a3f4b, #2a2f3a);
  color: var(--text-primary);
  border: 1px solid var(--border-light);
}

.toast-success {
  background: linear-gradient(135deg, #00d26a, #00a854);
  color: white;
}

.toast-error {
  background: linear-gradient(135deg, #ff4757, #c0392b);
  color: white;
}

.toast-warning {
  background: linear-gradient(135deg, #f39c12, #e67e22);
  color: #1a1a1a;
}

.toast-coins {
  background: linear-gradient(135deg, var(--gold), var(--orange));
  color: #1a1a1a;
}

.toast-achievement {
  background: linear-gradient(135deg, #9b59b6, #8e44ad);
  color: white;
}

.toast-hide {
  animation: toast-out 0.3s ease-in forwards;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateX(-50%) translateY(20px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

@keyframes toast-out {
  from { opacity: 1; transform: translateX(-50%) translateY(0); }
  to { opacity: 0; transform: translateX(-50%) translateY(-20px); }
}

/* ============================================
   ACHIEVEMENT UNLOCK POPUP
   ============================================ */

.achievement-popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10001;
  animation: fade-in 0.3s ease-out;
}

.achievement-popup {
  background: linear-gradient(135deg, #2a2f3a, #1e2330);
  border-radius: 20px;
  padding: 30px;
  text-align: center;
  border: 2px solid var(--gold);
  box-shadow: 0 0 50px rgba(255, 215, 0, 0.3);
  animation: popup-bounce 0.5s ease-out;
  max-width: 300px;
}

.achievement-popup-icon {
  font-size: 64px;
  margin-bottom: 16px;
  animation: icon-pulse 1s ease-in-out infinite;
}

.achievement-popup-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--gold);
  margin-bottom: 8px;
}

.achievement-popup-name {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  font-family: 'Orbitron', sans-serif;
}

.achievement-popup-desc {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.achievement-popup-reward {
  font-size: 24px;
  font-weight: 700;
  color: var(--green);
  margin-bottom: 20px;
}

.achievement-popup-btn {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--gold), var(--orange));
  border: none;
  border-radius: var(--radius-lg);
  color: #1a1a1a;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
}

@keyframes popup-bounce {
  0% { transform: scale(0.5); opacity: 0; }
  70% { transform: scale(1.05); }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes icon-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* ============================================
   OFFLINE EARNINGS POPUP
   ============================================ */

.offline-popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10001;
  animation: fade-in 0.3s ease-out;
}

.offline-popup {
  background: linear-gradient(135deg, #2a2f3a, #1e2330);
  border-radius: 20px;
  padding: 30px;
  text-align: center;
  border: 1px solid var(--border-light);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: popup-bounce 0.5s ease-out;
  max-width: 300px;
}

.offline-popup-icon {
  font-size: 56px;
  margin-bottom: 12px;
}

.offline-popup-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.offline-popup-time {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.offline-popup-earnings {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 24px;
}

.offline-coins {
  font-size: 36px;
  font-weight: 700;
  color: var(--gold);
  font-family: 'Orbitron', sans-serif;
}

.offline-label {
  font-size: 14px;
  color: var(--text-muted);
}

.offline-popup-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, var(--green), #00a854);
  border: none;
  border-radius: var(--radius-lg);
  color: white;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0, 210, 106, 0.3);
}

.fade-out {
  animation: fade-out 0.3s ease-in forwards;
}

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

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