/* Заявки: Kanban (07.10.2026). Под 768px остават сегашните карти (телефон), от 768px - колони по статус. */
.leads-kanban { display: none; }

@media (min-width: 768px) {
    .leads-kanban {
        display: grid; grid-template-columns: repeat(4, minmax(240px, 1fr)); gap: 12px; margin-top: 4px;
        overflow-x: auto; scroll-snap-type: x proximity; padding-bottom: 8px;
    }
    #sales-leads .leads-table-container,
    #sales-leads .leads-cards-container { display: none !important; }
}

.kb-col { background: #fbf4ec; border: 1px solid #efe4d8; border-radius: 16px; padding: 10px; min-width: 0; scroll-snap-align: start; align-self: start; }
.kb-col h4 { margin: 2px 4px 10px; font-size: .86rem; display: flex; justify-content: space-between; align-items: center; color: #2b231d; }
.kb-count { background: #f3e6d6; color: #a8743f; border-radius: 999px; padding: 2px 9px; font-size: .74rem; font-weight: 800; }
.kb-col--new h4 { color: #2b231d; }
.kb-col--new .kb-count { background: #3a2f26; color: #f1d3a6; }
.kb-col--prepared .kb-count { background: #e7f4e8; color: #2f7a35; }
.kb-col--rejected .kb-count { background: #fbe9e7; color: #b3261e; }

.kb-card { background: #fff; border: 1px solid #efe4d8; border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; display: grid; gap: 4px; font-size: .86rem; }
.kb-name { color: #2b231d; line-height: 1.25; overflow-wrap: anywhere; }
.kb-sub { color: #5a4a3a; }
.kb-phone { color: #a8743f; font-weight: 700; text-decoration: none; }
.kb-meta { color: #8a7866; font-size: .78rem; }
.kb-acts { display: flex; gap: 6px; margin-top: 6px; }
.kb-btn {
    flex: 1; min-height: 36px; padding: 6px 8px; border-radius: 9px; border: 1px solid #e6d4bf; background: #fff; color: #2b231d;
    font: inherit; font-size: .78rem; font-weight: 800; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.kb-btn i { color: #a8743f; }
.kb-btn:hover { background: #fbf4ec; }
.kb-btn--pri { background: #3a2f26; border-color: #3a2f26; color: #fff; }
.kb-btn--pri i { color: #f1d3a6; }
.kb-empty { text-align: center; color: #a08c77; font-size: .82rem; padding: 14px 6px; }

/* Подреждане на заглавието, числата и филтрите (07.10.2026) - `#sales-leads` бие старите правила в sales-funnel.css */
#sales-leads .leads-container { padding: 0; max-width: none; }
@media (min-width: 768px) {
    #sales-leads .leads-header { display: flex; align-items: center; justify-content: flex-start; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; }
    #sales-leads .leads-header h1 { font-size: 1.35rem; font-weight: 800; color: #2b231d; margin: 0; white-space: nowrap; }
    #sales-leads .leads-header h1 i { color: #a8743f; }
    #sales-leads .leads-stats { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 0 auto; }
    #sales-leads .stat-card {
        min-width: 0; padding: 8px 14px; display: flex; align-items: baseline; gap: 8px; text-align: left;
        background: #fbf4ec; color: #2b231d; box-shadow: none; border: 1px solid #efe4d8; border-radius: 12px;
    }
    #sales-leads .stat-card:hover { transform: none; }
    #sales-leads .stat-card:first-child { background: linear-gradient(135deg, #3a2f26, #57432f); color: #fff; border: 0; }
    #sales-leads .stat-number { font-size: 1.2rem; margin: 0; }
    #sales-leads .stat-label { font-size: .78rem; opacity: .75; text-transform: none; letter-spacing: 0; }
    #sales-leads .leads-filters { flex-direction: row; align-items: center; gap: 12px; padding: 0; background: none; margin-bottom: 14px; flex-wrap: wrap; }
    #sales-leads .filter-group { flex-direction: row; align-items: center; gap: 8px; }
    #sales-leads .filter-group label { font-size: .84rem; color: #8a7866; }
    #sales-leads .filter-group select { min-height: 40px; padding: 8px 12px; border: 1px solid #efe4d8; border-radius: 10px; font-size: .9rem; width: auto; }
    #sales-leads #refreshLeads { background: #3a2f26; border: 1px solid #3a2f26; box-shadow: none; min-height: 40px; padding: 8px 14px; border-radius: 10px; color: #fff; font-weight: 700; }
    #sales-leads #refreshLeads i { color: #f1d3a6; }
}

@media (min-width: 768px) {
    #sales-leads .stat-card:first-child .stat-number { color: #f1d3a6; }
    #sales-leads .stat-card:first-child .stat-label { color: #e3d4c2; opacity: 1; }
}
