@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;700;900&display=swap');

:root {
  --bg-color: #0c1515; /* Asosiy to'q fon */
  --primary-green: #10b981;
  --accent-gold: #fbbf24;
  --nav-bg: #111827;
}

/* --- ENG MUHIM QISM (Oq fonni yo'qotish) --- */
html {
  background-color: #0c1515 !important; /* Brauzer foni qora */
  height: 100%;
  overscroll-behavior: none; /* Tepaga tortganda oq ko'rinmasligi uchun */
}

body {
  font-family: 'Inter', sans-serif;
  background-color: #0c1515 !important;
  color: #e5e7eb;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  width: 100%;
  overflow-x: hidden;
  
  /* Chiroyli Gradient Fon */
  background-image: 
      radial-gradient(circle at 50% 0%, rgba(16, 185, 129, 0.15) 0%, transparent 60%),
      radial-gradient(circle at 50% 100%, rgba(0, 0, 0, 1) 0%, transparent 100%);
  background-attachment: fixed; /* Fon qotib turadi */
  
  /* Mobil optimizatsiya */
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

/* --- HOME (Coin) --- */
#avecoin-wrapper {
  width: 260px; height: 260px;
  max-width: 65vw; max-height: 65vw;
  border-radius: 50%;
  /* Orqasi shaffof bo'lmasligi uchun QORA fon beramiz */
  background-color: #000 !important; 
  box-shadow: 
      0 0 40px rgba(16, 185, 129, 0.25), 
      inset 0 0 30px rgba(0,0,0,0.9);
  position: relative; 
  overflow: hidden; 
  margin: 20px auto;
  border: 4px solid #1a1a1a;
  z-index: 10;
}

.coin-image { 
    width: 100%; height: 100%; 
    object-fit: cover; 
    border-radius: 50%; 
    display: block; 
}

/* --- NAVIGATION BAR --- */
#nav-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 50;
  background-color: var(--nav-bg) !important; /* To'q fon */
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex; justify-content: space-around; align-items: center; 
  height: 4.5rem;
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -10px 30px rgba(0,0,0,0.8);
}

.nav-btn {
  transition: transform 0.2s;
  color: #6b7280;
  padding: 0.5rem; background: transparent; border: none;
  display: flex; flex-direction: column; align-items: center; font-size: 0.7rem;
}
.nav-btn.active { color: var(--primary-green); transform: translateY(-4px); }
.nav-btn:not(.active):hover { color: #d1d5db; }

/* --- TABS (Tasks) --- */
.tab-wrapper {
  position: relative;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(10px);
  border-radius: 12px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  height: 50px;
  display: flex; align-items: center; overflow: hidden; 
  width: 100%; box-sizing: border-box;
}

#floating-bg {
  position: absolute; top: 4px; left: 4px;
  width: calc(50% - 4px); height: calc(100% - 8px);
  border-radius: 10px;
  transition: transform 0.3s ease-out;
  z-index: 0;
}

.tab-btn {
  flex: 1; position: relative; z-index: 10;
  background: transparent; border: none;
  color: #9ca3af; font-weight: 700; font-size: 11px;
  text-transform: uppercase; letter-spacing: 0.5px;
  display: flex; align-items: center; justify-content: center; gap: 4px;
}
.tab-btn.active { color: white; }

/* Tab Themes */
.green-mode #floating-bg { background: #10b981; }
.green-mode.tab-wrapper { border-color: rgba(16, 185, 129, 0.3); }
.red-mode #floating-bg { background: #ef4444; }
.red-mode.tab-wrapper { border-color: rgba(239, 68, 68, 0.3); }

/* --- TASK CARDS --- */
.task-card {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 10px 12px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  min-height: 64px; margin-bottom: 8px;
}
.task-btn {
  background: rgba(255, 255, 255, 0.05);
  color: var(--primary-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 6px 12px; border-radius: 8px;
  font-size: 11px; font-weight: 700;
  min-width: 70px; text-align: center;
}
.task-card.completed .task-btn {
  background: #2563eb !important; color: white !important; border: none !important;
}

/* Animations & Utils */
.animate-fade-in { animation: fadeIn 0.4s ease-out forwards; }
.animate-slide-up { animation: slideUp 0.3s ease-out forwards; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { transform: translateY(10px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.custom-scrollbar::-webkit-scrollbar { width: 0px; background: transparent; }
.truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }