/* Адаптивные стили для личного кабинета TokenLand */
body {
  font-family: 'Inter', sans-serif;
  background-color: #f4f7f6;
  margin: 0;
  padding: 0;
}

.dashboard-container {
  display: flex;
  flex-direction: row;
  min-height: 100vh;
}

.sidebar {
  width: 260px;
  background: #1c1f26;
  color: #fff;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: center;
}

.sidebar a {
  color: #fff;
  text-decoration: none;
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 8px;
  transition: background 0.2s;
  width: 100%;
  justify-content: center;
}

.sidebar a:hover {
  background: #2a2d36;
}

.main-content {
  flex-grow: 1;
  padding: 40px;
}

.welcome {
  background: #fff;
  padding: 24px;
  border-radius: 12px;
  margin-bottom: 32px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.welcome h1 {
  margin-top: 0;
}

.balance-box {
  font-size: 18px;
  color: #333;
  margin-top: 8px;
}

.section-title {
  font-size: 20px;
  margin: 32px 0 16px;
  font-weight: bold;
}

.invest-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.invest-table th, .invest-table td {
  padding: 14px 18px;
  border-bottom: 1px solid #eee;
  text-align: left;
}

.invest-table th {
  background-color: #f9fafc;
  font-weight: bold;
}

.market-item {
  background: #fff;
  padding: 18px;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  margin-bottom: 16px;
}

/* ===== Аватарка ===== */
.avatar-form {
  position: relative;
  margin-bottom: 16px;
}

.avatar-wrapper {
  display: block;
  position: relative;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid #fff;
  box-shadow: 0 0 0 2px #61cd81;
}

.avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  font-size: 12px;
  text-align: center;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  padding: 4px 0;
  opacity: 0;
  transition: 0.3s;
}

.avatar-wrapper:hover .avatar-overlay {
  opacity: 1;
}

.avatar-wrapper input[type="file"] {
  display: none;
}

/* Темная тема (по желанию) */
body.dark-mode {
  background-color: #121212;
  color: #fff;
}

body.dark-mode .welcome,
body.dark-mode .invest-table,
body.dark-mode .market-item {
  background: #1e1e1e;
  color: #ddd;
  box-shadow: none;
}

@media (max-width: 768px) {
  .dashboard-container {
    flex-direction: column;
  }
  .sidebar {
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: space-around;
    padding: 16px;
  }
  .main-content {
    padding: 20px;
  }
  .sidebar a {
    font-size: 14px;
    justify-content: center;
  }
}
