/* bots-component.css - Bots dashboard components
 * BroJack Agent #6 - October 2025
 * Design matches overview-component.css patterns
 */

/* ===== ANIMATIONS ===== */
@keyframes slide-in-bot {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes pulse-status {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(123, 255, 191, 0.7);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(123, 255, 191, 0);
    transform: scale(1.2);
  }
}

@keyframes bot-spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes float-up {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes glow-profit {
  0%, 100% {
    text-shadow: 0 0 5px rgba(123, 255, 191, 0.5);
  }
  50% {
    text-shadow: 0 0 15px rgba(123, 255, 191, 0.8);
  }
}

/* ===== BOTS GRID LAYOUT ===== */
.bots-container {
  position: relative; /* Needed for Coming Soon overlay positioning */
  display: flex;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
  padding: 40px 0;
}

.bots-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto auto auto;
  gap: 24px;
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  background: rgba(28, 35, 56, 0.4);
  border-radius: 32px;
  padding: 40px;
}

/* Grid positioning */
.bots-card.active-bots-card {
  grid-column: 1 / 3;
  grid-row: 1 / 3;
}

.bots-card.performance-card {
  grid-column: 3;
  grid-row: 1 / 3;
}

.bots-card.available-bots-card {
  grid-column: 1;
  grid-row: 3;
}

.bots-card.bot-settings-card {
  grid-column: 2;
  grid-row: 3;
}

.bots-card.recent-trades-card {
  grid-column: 1 / 3;
  grid-row: 4;
}

.bots-card.analytics-card {
  grid-column: 3;
  grid-row: 3 / 5;
}

/* ===== CARD BASE STYLES ===== */
.bots-card {
  background: linear-gradient(311.13deg, #00091E 22.82%, #303365 88.03%);
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: #FFFFFF;
}

.bots-card .card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.bots-card .card-header h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 18px;
  font-weight: 600;
  margin: 0;
  color: #FFFFFF;
}

/* ===== ACTIVE BOTS ===== */
.active-bots-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bot-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  transition: all 0.2s ease;
}

.bot-item:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.bot-icon {
  font-size: 24px;
  flex-shrink: 0;
}

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

.bot-name {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 4px;
  color: #FFFFFF;
}

.bot-strategy {
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  color: #A4A9B6;
}

.bot-profit {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
}

.bot-profit.positive {
  color: #7BFFBF;
  animation: glow-profit 3s ease-in-out infinite;
}

.bot-profit.negative {
  color: #FF5558;
}

.bot-status {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  text-transform: capitalize;
  color: #FFFFFF;
  flex-shrink: 0;
}

.bot-status .status-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.bot-status .status-indicator.running {
  background: #7BFFBF;
  box-shadow: 0 0 8px rgba(123, 255, 191, 0.6);
}

.bot-status .status-indicator.paused {
  background: #FFB86C;
  box-shadow: 0 0 8px rgba(255, 184, 108, 0.6);
}

.btn-bot-action {
  width: 32px;
  height: 32px;
  background: #555DFF;
  border: none;
  border-radius: 50%;
  color: #FFFFFF;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-bot-action:hover {
  background: #6B73FF;
  transform: translateY(-2px);
}

.btn-bot-action i {
  font-size: 12px;
}

/* ===== PERFORMANCE ===== */
.performance-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}

.perf-stat {
  text-align: center;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
}

.perf-value {
  font-family: 'Montserrat', sans-serif;
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 6px;
  color: #FFFFFF;
}

.perf-value.green {
  color: #7BFFBF;
  text-shadow: 0 0 10px rgba(123, 255, 191, 0.5);
}

.perf-label {
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  color: #A4A9B6;
}

.performance-chart {
  width: 100%;
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#bot-performance-chart {
  width: 100%;
  height: auto;
}

/* ===== MARKETPLACE ===== */
.marketplace-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.marketplace-bot {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  transition: all 0.3s ease;
}

.marketplace-bot:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(85, 93, 255, 0.3);
}

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

.mb-name {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 4px;
  color: #FFFFFF;
}

.mb-meta {
  display: flex;
  gap: 12px;
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  color: #A4A9B6;
}

.mb-price {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: #FFB86C;
  flex-shrink: 0;
}

.btn-purchase {
  padding: 8px 16px;
  background: #555DFF;
  border: none;
  border-radius: 8px;
  color: #FFFFFF;
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.btn-purchase:hover {
  background: #6B73FF;
  transform: translateY(-2px);
}

/* ===== CONFIGURATION ===== */
.bot-config {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.config-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.config-item label {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  color: #FFFFFF;
  font-weight: 500;
}

.config-item input[type="range"],
.config-item input[type="number"] {
  width: 100%;
  padding: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #FFFFFF;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  outline: none;
}

.config-item input[type="range"] {
  padding: 0;
  height: 6px;
}

.risk-labels {
  display: flex;
  justify-content: space-between;
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  color: #A4A9B6;
}

.btn-save-config {
  width: 100%;
  padding: 12px;
  background: #555DFF;
  border: none;
  border-radius: 12px;
  color: #FFFFFF;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-save-config:hover {
  background: #6B73FF;
  transform: translateY(-2px);
}

/* ===== RECENT TRADES ===== */
.trades-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.trade-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  font-family: 'Montserrat', sans-serif;
  font-size: 13px;
}

.trade-pair {
  font-weight: 500;
  color: #FFFFFF;
  flex-shrink: 0;
}

.trade-type {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}

.trade-type.buy {
  background: rgba(123, 255, 191, 0.2);
  color: #7BFFBF;
}

.trade-type.sell {
  background: rgba(255, 85, 88, 0.2);
  color: #FF5558;
}

.trade-amount {
  color: #FFFFFF;
  flex: 1;
  min-width: 0;
}

.trade-profit {
  color: #FFFFFF;
  flex-shrink: 0;
}

.trade-profit.positive {
  color: #7BFFBF;
}

.trade-time {
  color: #A4A9B6;
  font-size: 12px;
  flex-shrink: 0;
}

/* ===== ANALYTICS ===== */
.analytics-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.analytic-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
}

.analytic-icon {
  font-size: 32px;
  flex-shrink: 0;
  filter: drop-shadow(0 0 10px rgba(255, 184, 108, 0.6));
}

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

.analytic-value {
  font-family: 'Montserrat', sans-serif;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
  color: #FFFFFF;
}

.analytic-label {
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  color: #A4A9B6;
}

/* ===== PERIOD SELECTOR ===== */
.period-selector {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 6px 12px;
  color: #FFFFFF;
  font-family: 'Montserrat', sans-serif;
  font-size: 12px;
  cursor: pointer;
  outline: none;
}

.period-selector option {
  background: #1C2338;
  color: #FFFFFF;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
  .bots-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }
  
  .bots-card.active-bots-card,
  .bots-card.performance-card,
  .bots-card.available-bots-card,
  .bots-card.bot-settings-card,
  .bots-card.recent-trades-card,
  .bots-card.analytics-card {
    grid-column: auto;
    grid-row: auto;
  }
  
  .performance-stats {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .bots-container {
    padding: 20px 0;
  }
  
  .bots-grid {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 20px;
  }
  
  .performance-stats {
    grid-template-columns: 1fr;
  }
}

