/* Unified CRM Sales Pipeline hub — premium visual layer */
.crm-unified-hero {
    margin: 0 0 24px;
    padding: 28px 32px;
    border-radius: 20px;
    background: linear-gradient(135deg, #0d47a1 0%, #1565c0 35%, #00838f 100%);
    color: #fff;
    box-shadow: 0 16px 40px rgba(13, 71, 161, 0.25);
}
.crm-unified-hero h2 { margin: 0 0 8px; font-size: 28px; font-weight: 700; }
.crm-unified-hero p { margin: 0; opacity: 0.92; font-size: 15px; max-width: 640px; }
.crm-kanban-lane-hint {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #78909c;
    margin-top: 4px;
}
.crm-pipeline-board-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 10px;
    background: rgba(255,255,255,0.12);
    color: #fff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    border: 1px solid rgba(255,255,255,0.2);
    transition: background 0.2s;
}
.crm-pipeline-board-link:hover { background: rgba(255,255,255,0.22); color: #fff; }
.crm-activity-stat-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}
.crm-activity-stat {
    background: linear-gradient(180deg, #fafbfc 0%, #fff 100%);
    border: 1px solid #e3e8ee;
    border-radius: 14px;
    padding: 16px 18px;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
}
.crm-activity-stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.crm-activity-stat strong { display: block; font-size: 26px; color: #1a237e; }
.crm-activity-stat span { font-size: 12px; color: #607d8b; text-transform: uppercase; letter-spacing: 0.04em; }

.crm-analytics-page { display: flex; flex-direction: column; gap: 20px; }
.crm-analytics-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }
.crm-analytics-card { background: #fff; border-radius: 14px; padding: 18px 20px; box-shadow: 0 8px 24px rgba(0,0,0,0.06); border: 1px solid #e3e8ee; }
.crm-analytics-card h3 { margin: 0 0 8px; font-size: 13px; color: #607d8b; text-transform: uppercase; letter-spacing: 0.04em; }
.crm-analytics-value { font-size: 28px; font-weight: 700; color: #0d47a1; }
.crm-analytics-card p { margin: 8px 0 0; font-size: 12px; color: #78909c; }
.crm-analytics-section { background: #fff; border-radius: 14px; padding: 20px 24px; box-shadow: 0 8px 24px rgba(0,0,0,0.06); }
.crm-analytics-section h3 { margin: 0 0 14px; font-size: 18px; }
.crm-analytics-table { display: flex; flex-direction: column; gap: 8px; }
.crm-analytics-row { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 12px; padding: 10px 12px; border-radius: 8px; background: #f5f7fa; font-size: 13px; }
.crm-analytics-row-link { cursor: pointer; }
.crm-analytics-row-link:hover { background: #e3f2fd; }
.crm-analytics-empty { color: #78909c; font-size: 14px; margin: 0; }

/* Sidebar quick actions (pipeline detail + registry actions) */
.crm-sidebar-actions-stack { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.crm-sidebar-actions-divider { height: 1px; background: #eceff1; margin: 4px 0; }
.crm-sidebar-quick-actions { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.crm-sidebar-quick-actions-heading { margin: 0 0 4px; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #78909c; }
.crm-sidebar-quick-actions-list { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.crm-sidebar-quick-action {
    display: flex; align-items: center; gap: 10px; width: 100%; min-width: 0; box-sizing: border-box;
    padding: 10px 12px; background: #fff; border: 1px solid #e0e0e0; border-radius: 8px;
    cursor: pointer; font-size: 13px; font-weight: 600; color: #37474f; text-align: left;
    transition: background .15s ease, border-color .15s ease, transform .15s ease;
}
.crm-sidebar-quick-action:hover:not(:disabled) { background: #f5f7fa; border-color: #90a4ae; transform: translateX(2px); }
.crm-sidebar-quick-action:disabled { opacity: .65; cursor: wait; }
.crm-sidebar-quick-action-accent { border-color: #bbdefb; background: #f3f8ff; }
.crm-sidebar-quick-action-icon {
    width: 32px; height: 32px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center;
    color: #fff; flex-shrink: 0; font-size: 14px;
}
.crm-sidebar-quick-action-label { flex: 1; min-width: 0; line-height: 1.25; }
.crm-sidebar-quick-action-spinner { margin-left: auto; flex-shrink: 0; }

@media (max-width: 768px) {
    .module-kanban-board { flex-direction: column; overflow-x: visible; }
    .module-kanban-board .kanban-column { min-width: 100%; max-width: 100%; }
    .crm-unified-hero { padding: 20px; }
    .crm-unified-hero h2 { font-size: 22px; }
    .crm-analytics-row { grid-template-columns: 1fr; gap: 4px; }
}
