/* ============================================
   CRM Page Styles
   ============================================ */

/* ======================
   Pipeline Stage Badges
   ====================== */
.crm-stage {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.6875rem;
  font-weight: 500;
  white-space: nowrap;
}
.crm-stage--new-lead {
  background: #e8f2fb;
  color: #0364B1;
  border: 1px solid #bfdbfe;
}
.crm-stage--contacted {
  background: #f3e8ff;
  color: #7c3aed;
  border: 1px solid #ddd6fe;
}
.crm-stage--quoted {
  background: #fff7ed;
  color: #c2410c;
  border: 1px solid #fed7aa;
}
.crm-stage--reserved {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
}
.crm-stage--completed {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #86efac;
}

/* ======================
   Activity Feed
   ====================== */
.crm-activity-feed {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 16px 20px;
}
.crm-activity-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #f1f5f9;
}
.crm-activity-item:last-child {
  border-bottom: none;
}
.crm-activity-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-top: 6px;
  flex-shrink: 0;
}
.crm-activity-dot--info { background: #3C8ACC; }
.crm-activity-dot--success { background: #22c55e; }
.crm-activity-dot--purple { background: #7c3aed; }
.crm-activity-dot--warning { background: #f59e0b; }
.crm-activity-dot--gray { background: #94a3b8; }

.crm-activity-content {
  flex: 1;
}
.crm-activity-text {
  font-size: 0.8125rem;
  color: var(--text-primary);
  line-height: 1.5;
}
.crm-activity-text strong {
  font-weight: 600;
}
.crm-activity-text em {
  font-style: normal;
  color: var(--primary);
}
.crm-activity-time {
  font-size: 0.6875rem;
  color: #94a3b8;
  margin-top: 2px;
}

/* ======================
   Deal Panel
   ====================== */
.deal-field {
  margin-bottom: 14px;
}
.deal-field-label {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  font-weight: 600;
  margin-bottom: 4px;
}
.deal-field-value {
  font-size: 0.875rem;
  color: var(--text-primary);
  font-weight: 500;
}
.deal-field-value--link {
  color: var(--primary);
  cursor: pointer;
}
.deal-field-value--large {
  font-size: 1.125rem;
  font-weight: 700;
}

/* Deal panel sections */
.deal-section {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}
.deal-section-title {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #2a60ac;
  font-weight: 700;
  margin-bottom: 10px;
}

/* Deal mini activity */
.deal-mini-activity {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.deal-mini-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.4;
}
.deal-mini-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #cbd5e1;
  margin-top: 5px;
  flex-shrink: 0;
}
.deal-mini-date {
  color: #94a3b8;
  white-space: nowrap;
  margin-left: auto;
  padding-left: 8px;
}

/* Deal action buttons row */
.deal-actions {
  display: flex;
  gap: 8px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}
.deal-actions .btn {
  flex: 1;
  text-align: center;
  font-size: 0.75rem;
  padding: 8px 10px;
}

/* Notes input area */
.deal-notes-input {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.deal-notes-input textarea {
  flex: 1;
  padding: 8px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 5px;
  font-size: 0.8125rem;
  resize: vertical;
  min-height: 60px;
  font-family: inherit;
}
.deal-notes-input .btn {
  align-self: flex-end;
  white-space: nowrap;
}

/* ======================
   Value column styling
   ====================== */
.crm-value {
  font-weight: 600;
  color: var(--text-primary);
}
