:root {
  --crm-accent: #7c3aed;
  --crm-sidebar-w: 15rem;
}

body.crm-body {
  background: #f8fafc;
  min-height: 100vh;
  color: #1e293b;
}

.crm-sidebar {
  width: var(--crm-sidebar-w);
  background: #fff;
  border-right: 1px solid #e2e8f0;
}

.crm-nav-link {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.55rem 0.875rem;
  border-radius: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #4b5563;
  text-decoration: none;
  margin: 0 0.5rem 2px;
}

.crm-nav-link:hover {
  background: #f3f4f6;
}

.crm-nav-link.active {
  background: #ede9fe;
  color: #5b21b6;
  font-weight: 600;
}

.panel-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
}

.data-table {
  width: 100%;
  font-size: 0.8125rem;
  border-collapse: collapse;
}

.data-table thead th {
  text-align: left;
  color: #64748b;
  font-weight: 600;
  border-bottom: 1px solid #e2e8f0;
  padding: 0.5rem 0.75rem;
}

.data-table tbody td {
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid #f1f5f9;
}

.btn-primary {
  background: var(--crm-accent);
  color: #fff;
  border-radius: 0.5rem;
  padding: 0.45rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 600;
}

.btn-ghost {
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.45rem 0.875rem;
  font-size: 0.8125rem;
  background: #fff;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-card {
  background: #fff;
  border-radius: 0.75rem;
  width: min(100%, 32rem);
  max-height: 90vh;
  overflow: auto;
  padding: 1.25rem;
}

.stat-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
  padding: 1rem;
}

.stat-card .value {
  font-size: 1.5rem;
  font-weight: 700;
  color: #5b21b6;
}
