/*
 * Analysts SPA — supplemental styles.
 * Base layout comes from /static/management-calls/list_app.css.
 */

.an-rating-badge {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 9px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .03em;
  color: #fff;
  background-color: var(--rating-color, #6b7280);
}

.an-cov-badge {
  font-size: 10px;
  color: #6b7280;
  background: #f1f5f9;
  padding: 1px 6px;
  border-radius: 8px;
}

.an-quick-stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 16px;
  align-items: center;
}
.an-stat-pill {
  background: #f1f5f9;
  border-radius: 4px;
  padding: 2px 10px;
}

.an-section { margin-bottom: 24px; }
.an-section-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #6b7280;
  margin-bottom: 10px;
  padding-bottom: 4px;
  border-bottom: 1px solid #e5e7eb;
}

.an-profile-grid {
  display: grid;
  grid-template-columns: 120px 1fr;
  row-gap: 6px;
  font-size: 13px;
}
.an-profile-row { display: contents; }
.an-profile-key { color: #6b7280; font-weight: 600; padding-right: 12px; align-self: start; }
.an-profile-val { color: #1f2937; white-space: pre-wrap; word-break: break-word; }

.an-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.an-table th {
  text-align: left;
  padding: 5px 8px;
  background: #f9fafb;
  border-bottom: 1px solid #e5e7eb;
  font-weight: 600;
  font-size: 11px;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: .04em;
  white-space: nowrap;
}
.an-table th.sortable:hover { color: #2563eb; cursor: pointer; }
.an-table td {
  padding: 5px 8px;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: top;
}
.an-table tr:hover td { background: #f9fafb; }

.an-company-link {
  cursor: pointer;
  color: #2563eb;
  text-decoration: underline;
  text-decoration-style: dotted;
}
.an-company-link:hover { color: #1d4ed8; }

.an-conviction {
  font-size: 10px;
  background: #fef3c7;
  color: #92400e;
  padding: 1px 6px;
  border-radius: 8px;
  font-weight: 600;
}

.an-report-list { list-style: none; padding: 0; margin: 0; }
.an-report-item {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 5px 0;
  border-bottom: 1px solid #f3f4f6;
  font-size: 12px;
}
.an-report-date { color: #9ca3af; white-space: nowrap; min-width: 90px; }
.an-report-name { color: #1f2937; flex: 1; }
.an-report-ticker {
  background: #eff6ff;
  color: #1d4ed8;
  padding: 1px 6px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 600;
}

.an-loading-msg { font-size: 12px; color: #9ca3af; padding: 8px 0; }
.an-empty-msg   { font-size: 12px; color: #9ca3af; padding: 8px 0; font-style: italic; }

/* ── Wave 2: Rating Activity timeline ───────────────────────────────────── */

.an-activity-timeline {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 12px;
}
.an-activity-item {
  display: grid;
  grid-template-columns: 90px 90px 110px 1fr;
  gap: 10px;
  align-items: baseline;
  padding: 5px 0;
  border-bottom: 1px solid #f3f4f6;
}
.an-activity-date { color: #9ca3af; white-space: nowrap; }
.an-activity-company {
  color: #1d4ed8;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.an-activity-prose { color: #1f2937; }

.an-event-badge {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 9px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .03em;
  color: #fff;
  text-align: center;
  white-space: nowrap;
}
.an-event-analyst_initiation    { background-color: #2563eb; }
.an-event-analyst_rating_change { background-color: #f59e0b; }
.an-event-analyst_target_change { background-color: #14b8a6; }

/* ── Wave 2: Thesis & Bear/Bull signals grid ──────────────────────────── */

.an-signals-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
@media (max-width: 1100px) {
  .an-signals-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .an-signals-grid { grid-template-columns: 1fr; }
}

.an-signals-col {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  padding: 8px 10px;
  min-width: 0;
}
.an-signals-col-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #374151;
  margin-bottom: 6px;
  padding-bottom: 4px;
  border-bottom: 1px solid #e5e7eb;
}
.an-signals-col-bull_case          .an-signals-col-title { color: #047857; }
.an-signals-col-bear_case          .an-signals-col-title { color: #b91c1c; }
.an-signals-col-thesis_pillar      .an-signals-col-title { color: #1d4ed8; }
.an-signals-col-near_term_catalyst .an-signals-col-title { color: #c2410c; }
.an-signals-col-key_debate         .an-signals-col-title { color: #6d28d9; }
.an-signals-col-valuation_argument .an-signals-col-title { color: #0e7490; }

.an-signal-list { list-style: none; padding: 0; margin: 0; }
.an-signal-item {
  padding: 6px 0;
  border-bottom: 1px solid #f3f4f6;
  font-size: 12px;
}
.an-signal-item:last-child { border-bottom: none; }
.an-signal-meta {
  display: flex;
  gap: 6px;
  align-items: baseline;
  font-size: 10px;
  color: #6b7280;
  margin-bottom: 3px;
}
.an-signal-company { font-weight: 700; color: #1d4ed8; }
.an-signal-date    { color: #9ca3af; }
.an-signal-conf {
  background: #eef2ff;
  color: #4338ca;
  padding: 0 5px;
  border-radius: 6px;
  font-weight: 600;
}
.an-signal-text { color: #1f2937; line-height: 1.35; }

/* ── Wave 2: Peer Set panel ───────────────────────────────────────────── */

.an-report-item-clickable { cursor: pointer; }
.an-report-item-clickable:hover { background: #f9fafb; }
.an-report-item-active {
  background: #eff6ff;
  border-left: 2px solid #2563eb;
  padding-left: 6px;
}

.an-peer-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.an-peer-group {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 10px;
  align-items: start;
}
.an-peer-role-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #6b7280;
  padding-top: 4px;
}
.an-peer-group-primary_comp     .an-peer-role-label { color: #b91c1c; }
.an-peer-group-secondary_comp   .an-peer-role-label { color: #c2410c; }
.an-peer-group-named_competitor .an-peer-role-label { color: #92400e; }
.an-peer-group-customer         .an-peer-role-label { color: #047857; }
.an-peer-group-partner          .an-peer-role-label { color: #1d4ed8; }
.an-peer-group-supplier         .an-peer-role-label { color: #6d28d9; }

.an-peer-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.an-peer-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  background: #f1f5f9;
  color: #1f2937;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
}
.an-peer-count {
  color: #6b7280;
  font-weight: 400;
  font-size: 10px;
}
