/* ── Intraday Signal Bot Stylesheet ──────────────────────────────────── */

.intraday-container {
  max-width: 1440px;
  margin: 0 auto;
  padding: 24px 20px 60px;
}

/* ── Header ─────────────────────────────────────────────────────────── */
.intraday-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 20px;
  padding: 20px 24px;
  background: var(--card-bg, rgba(18, 26, 44, 0.7));
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
  border-radius: 16px;
  backdrop-filter: blur(12px);
}

.header-title-section h1 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary, #ffffff);
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 6px 0;
}

.header-subtitle {
  font-size: 0.875rem;
  color: var(--text-secondary, #94a3b8);
  margin: 0;
}

.regime-badge {
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 20px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.regime-trending {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.regime-range_bound {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.regime-volatile {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.regime-low_volume {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.regime-unknown {
  background: rgba(255, 255, 255, 0.08);
  color: #94a3b8;
}

/* ── Control Inputs ─────────────────────────────────────────────────── */
.intraday-controls {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.control-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.control-group label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary, #94a3b8);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.ticker-select-wrapper {
  position: relative;
  display: inline-block;
}

.ticker-input {
  width: 140px;
  padding: 8px 14px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.2));
  border-radius: 8px;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.95rem;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ticker-input:focus {
  border-color: var(--accent-cyan, #06b6d4);
  outline: none;
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.25);
}

.timeframe-select {
  padding: 8px 12px;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.15));
  border-radius: 8px;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
}

.btn-start {
  padding: 10px 20px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-start:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(16, 185, 129, 0.4);
}

.btn-stop {
  padding: 10px 20px;
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-stop:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(239, 68, 68, 0.4);
}

/* ── Status Bar ─────────────────────────────────────────────────────── */
.status-bar {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 10px 20px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(6, 182, 212, 0.2);
  border-radius: 10px;
  margin-bottom: 20px;
  font-size: 0.8125rem;
  color: var(--text-secondary, #94a3b8);
  flex-wrap: wrap;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  display: inline-block;
  margin-right: 6px;
}

.pulse {
  animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.status-val {
  color: #ffffff;
  font-weight: 700;
  margin-left: 4px;
}

.last-tick {
  margin-left: auto;
  font-size: 0.75rem;
  opacity: 0.8;
}

/* ── Main Workspace ─────────────────────────────────────────────────── */
.intraday-workspace {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 20px;
  margin-bottom: 24px;
}

@media (max-width: 1024px) {
  .intraday-workspace {
    grid-template-columns: 1fr;
  }
}

/* ── Chart Card ─────────────────────────────────────────────────────── */
.chart-card {
  background: var(--card-bg, rgba(18, 26, 44, 0.7));
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  min-height: 520px;
}

.chart-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.chart-title {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.chart-symbol {
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
}

.chart-price {
  font-size: 1.125rem;
  font-weight: 700;
  color: #06b6d4;
}

.chart-change {
  font-size: 0.875rem;
  font-weight: 600;
}

.chart-change.up { color: #10b981; }
.chart-change.down { color: #ef4444; }

.chart-overlays-legend {
  display: flex;
  gap: 12px;
  font-size: 0.75rem;
  font-weight: 600;
}

.vwap-legend { color: #f59e0b; }
.ema9-legend { color: #06b6d4; }
.ema21-legend { color: #a855f7; }
.bb-legend { color: #64748b; }

.chart-container {
  flex: 1;
  position: relative;
  width: 100%;
  min-height: 440px;
  border-radius: 8px;
  overflow: hidden;
  background: #0b0f19;
}

.chart-placeholder {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #0b0f19;
}

.placeholder-content {
  text-align: center;
  color: #64748b;
  max-width: 320px;
}

.placeholder-icon {
  font-size: 3rem;
  display: block;
  margin-bottom: 12px;
}

/* ── Signals Feed Card ───────────────────────────────────────────────── */
.signals-card {
  background: var(--card-bg, rgba(18, 26, 44, 0.7));
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  max-height: 580px;
}

.signals-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.signals-card-header h2 {
  font-size: 1.125rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.count-badge {
  background: #06b6d4;
  color: #000;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 12px;
}

.signals-subtext {
  font-size: 0.75rem;
  color: #64748b;
}

.signals-feed {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-right: 4px;
}

.empty-feed {
  text-align: center;
  color: #64748b;
  margin: auto 0;
  padding: 30px 10px;
}

.empty-icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 8px;
}

/* ── Signal Item Card ────────────────────────────────────────────────── */
.signal-item-card {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 14px;
  transition: all 0.25 ease;
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

.signal-item-card.signal-buy {
  border-left: 4px solid #10b981;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.signal-item-card.signal-sell {
  border-left: 4px solid #ef4444;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.08) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.signal-item-card.signal-watch {
  border-left: 4px solid #f59e0b;
}

.signal-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.signal-badge {
  font-weight: 800;
  font-size: 0.8125rem;
  padding: 3px 8px;
  border-radius: 6px;
  text-transform: uppercase;
}

.badge-buy { background: rgba(16, 185, 129, 0.2); color: #10b981; }
.badge-sell { background: rgba(239, 68, 68, 0.2); color: #ef4444; }
.badge-watch { background: rgba(245, 158, 11, 0.2); color: #f59e0b; }

.signal-confidence {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #06b6d4;
}

.signal-strategy-title {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.signal-levels-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  background: rgba(0, 0, 0, 0.3);
  padding: 8px;
  border-radius: 6px;
  margin-bottom: 8px;
  font-size: 0.75rem;
}

.lvl-box {
  display: flex;
  flex-direction: column;
}

.lvl-label { color: #64748b; font-size: 0.6875rem; }
.lvl-val { font-weight: 700; color: #ffffff; }

.signal-narrative {
  font-size: 0.78125rem;
  color: #cbd5e1;
  line-height: 1.4;
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed rgba(255, 255, 255, 0.08);
}

.signal-time {
  font-size: 0.6875rem;
  color: #64748b;
  margin-top: 6px;
  text-align: right;
}

/* ── Indicator Cards ─────────────────────────────────────────────────── */
.indicators-section {
  margin-top: 20px;
}

.section-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 14px;
}

.indicators-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.indicator-card {
  background: var(--card-bg, rgba(18, 26, 44, 0.7));
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
}

.indicator-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.ind-name {
  font-size: 0.75rem;
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
}

.ind-badge {
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
}

.indicator-val {
  font-size: 1.375rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 4px;
}

.indicator-sub {
  font-size: 0.6875rem;
  color: #64748b;
}

.ind-progress-bar {
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  margin-top: 8px;
  overflow: hidden;
}

.ind-progress-fill {
  height: 100%;
  background: #06b6d4;
  transition: width 0.3s ease;
}
