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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: linear-gradient(135deg, #0f172a 0%, #581c87 50%, #0f172a 100%);
  background-attachment: fixed;
  min-height: 100vh;
  color: #f1f5f9;
}

.loader {
  text-align: center;
  padding: 40px;
  font-size: 24px;
  color: white;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 16px;
}

.card {
  background: rgba(30, 41, 59, 0.95);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.avatar {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #7c3aed, #a78bfa);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 700;
}

.header-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.btn {
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.3s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.btn-primary {
  background: #7c3aed;
  color: white;
}

.btn-primary:hover {
  background: #6d28d9;
}

.btn-success {
  background: #10b981;
  color: white;
}

.btn-success:hover {
  background: #059669;
}

.btn-danger {
  background: #ef4444;
  color: white;
}

.btn-danger:hover {
  background: #dc2626;
}

.btn-secondary {
  background: #475569;
  color: white;
}

.btn-secondary:hover {
  background: #334155;
}

.btn-blue {
  background: #3b82f6;
  color: white;
}

.btn-blue:hover {
  background: #2563eb;
}

.btn-small {
  padding: 6px 12px;
  font-size: 12px;
}

.input {
  width: 100%;
  padding: 12px;
  border: 1px solid #475569;
  border-radius: 8px;
  background: #1e293b;
  color: white;
  font-size: 14px;
  margin-bottom: 12px;
}

.input:focus {
  outline: none;
  border-color: #7c3aed;
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.1);
}

textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #475569;
  border-radius: 8px;
  background: #1e293b;
  color: white;
  font-family: inherit;
  resize: vertical;
  font-size: 14px;
}

textarea:focus {
  outline: none;
  border-color: #7c3aed;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-5 {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.crypto-card {
  background: rgba(30, 41, 59, 0.95);
  border-radius: 12px;
  padding: 16px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.3s;
}

.crypto-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(124, 58, 237, 0.3);
}

.crypto-card.active {
  border-color: #7c3aed;
  background: rgba(124, 58, 237, 0.1);
}

.crypto-name {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.crypto-price {
  font-size: 28px;
  font-weight: 800;
  color: #10b981;
}

.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.badge-success {
  background: #10b981;
  color: white;
}

.badge-danger {
  background: #ef4444;
  color: white;
}

.badge-warning {
  background: #f59e0b;
  color: white;
}

.badge-info {
  background: #3b82f6;
  color: white;
}

.hidden {
  display: none;
}

.order-item, .user-item, .notif-item {
  background: rgba(51, 65, 85, 0.8);
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 12px;
}

.order-header, .user-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.order-details {
  font-size: 13px;
  color: #cbd5e1;
  line-height: 1.8;
}

.button-group {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.login-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.login-card {
  background: rgba(30, 41, 59, 0.95);
  border-radius: 20px;
  padding: 40px;
  max-width: 440px;
  width: 100%;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.login-header {
  text-align: center;
  margin-bottom: 32px;
}

.login-avatar {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, #7c3aed, #a78bfa);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 36px;
}

.login-title {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 8px;
}

.login-subtitle {
  color: #94a3b8;
  font-size: 16px;
}

.demo-accounts {
  background: rgba(51, 65, 85, 0.6);
  border-radius: 12px;
  padding: 16px;
  margin-top: 24px;
  font-size: 13px;
}

.demo-accounts p {
  margin-bottom: 8px;
}

.notification-badge {
  position: relative;
}

.notification-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ef4444;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
}

.scroll-container {
  max-height: 400px;
  overflow-y: auto;
  padding-right: 8px;
}

.scroll-container::-webkit-scrollbar {
  width: 6px;
}

.scroll-container::-webkit-scrollbar-track {
  background: rgba(51, 65, 85, 0.3);
  border-radius: 3px;
}

.scroll-container::-webkit-scrollbar-thumb {
  background: #7c3aed;
  border-radius: 3px;
}

.notif-success {
  background: rgba(16, 185, 129, 0.1);
  border-left: 4px solid #10b981;
}

.notif-warning {
  background: rgba(245, 158, 11, 0.1);
  border-left: 4px solid #f59e0b;
}

.notif-info {
  background: rgba(59, 130, 246, 0.1);
  border-left: 4px solid #3b82f6;
}

.chart-placeholder {
  background: rgba(51, 65, 85, 0.5);
  border-radius: 12px;
  padding: 40px;
  text-align: center;
  color: #94a3b8;
  font-size: 14px;
  margin: 20px 0;
}

.funds-modal {
  background: rgba(30, 41, 59, 0.95);
  border-radius: 12px;
  padding: 20px;
  margin-top: 12px;
}

.funds-type-buttons {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.label {
  display: block;
  font-size: 13px;
  color: #94a3b8;
  margin-bottom: 4px;
}

@media (max-width: 768px) {
  .container {
    padding: 12px;
  }

  .card {
    padding: 16px;
  }

  .crypto-card {
    padding: 12px;
  }

  .crypto-name {
    font-size: 16px;
  }

  .crypto-price {
    font-size: 24px;
  }

  .grid-5 {
    grid-template-columns: repeat(2, 1fr);
  }

  .header {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-buttons {
    width: 100%;
  }

  .btn {
    flex: 1;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .grid-5 {
    grid-template-columns: 1fr;
  }

  .login-card {
    padding: 24px;
  }

  .login-title {
    font-size: 24px;
  }
}

/* Fix pour le bouton créer utilisateur */
.card h2 {
  margin: 0;
}

.btn-success {
  white-space: nowrap;
}