/* Live Dashboard Styles — matches existing dark/light theme */

.dash-section {
  max-width: 900px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.dash-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.dash-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
}

.pulse-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--text-secondary, #888);
  display: inline-block;
}

.pulse-active {
  background: #22c55e;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
  50% { opacity: 0.8; box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); }
}

/* Summary bar */
.dash-summary {
  display: flex;
  gap: 2rem;
  align-items: center;
  padding: 1rem 1.5rem;
  border-radius: 12px;
  background: var(--card-bg, #f8f9fa);
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.dash-stat {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.dash-stat-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary, #666);
  font-weight: 600;
}

.dash-stat-value {
  font-size: 1.25rem;
  font-weight: 700;
  font-family: 'IBM Plex Mono', monospace;
}

/* Status indicators */
.status-open { color: #22c55e; }
.status-idle { color: #eab308; }
.status-closed { color: var(--text-secondary, #888); }

/* PnL colors */
.pnl-green { color: #22c55e; }
.pnl-red { color: #ef4444; }

/* Trade cards container */
#trade-cards-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 640px) {
  #trade-cards-container {
    grid-template-columns: 1fr 1fr;
  }
}

/* Individual trade card */
.dash-trade-card {
  border-radius: 12px;
  padding: 1rem 1.25rem;
  background: var(--card-bg, #f8f9fa);
  border-left: 4px solid var(--text-secondary, #ccc);
  transition: transform 0.15s;
}

.dash-trade-card:hover {
  transform: translateY(-1px);
}

.card-setup { border-left-color: #eab308; }
.card-active { border-left-color: #3b82f6; }
.card-win { border-left-color: #22c55e; }
.card-loss { border-left-color: #ef4444; }

.card-header-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.side-tag {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  letter-spacing: 0.05em;
}

.side-ce { background: #dbeafe; color: #1d4ed8; }
.side-pe { background: #fce7f3; color: #be185d; }

[data-theme="dark"] .side-ce { background: #1e3a5f; color: #93c5fd; }
[data-theme="dark"] .side-pe { background: #4a1942; color: #f9a8d4; }

.card-symbol {
  font-size: 0.8rem;
  font-family: 'IBM Plex Mono', monospace;
  color: var(--text-secondary, #666);
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Status badges */
.dash-badge {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.badge-setup { background: #fef3c7; color: #92400e; }
.badge-active { background: #dbeafe; color: #1e40af; }
.badge-closed { background: #e5e7eb; color: #374151; }

[data-theme="dark"] .badge-setup { background: #422006; color: #fbbf24; }
[data-theme="dark"] .badge-active { background: #1e3a5f; color: #60a5fa; }
[data-theme="dark"] .badge-closed { background: #1f2937; color: #9ca3af; }

/* Card details */
.card-details {
  margin-bottom: 0.5rem;
}

.card-row {
  display: flex;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--text-secondary, #666);
  margin-bottom: 0.25rem;
  font-family: 'IBM Plex Mono', monospace;
  flex-wrap: wrap;
}

.card-exit {
  font-size: 0.8rem;
  color: var(--text-secondary, #666);
  font-family: 'IBM Plex Mono', monospace;
  margin-top: 0.25rem;
}

.card-pnl {
  font-size: 1rem;
  font-weight: 700;
  font-family: 'IBM Plex Mono', monospace;
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border-color, #e5e7eb);
}

/* Empty state */
.dash-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 2rem;
  color: var(--text-secondary, #888);
  font-size: 0.9rem;
}
