.leads-page-header { margin-bottom: 0; }
.leads-page-header > .page-header { margin-bottom: 0; }
.leads-page-actions { width: 100%; align-items: flex-start; flex-wrap: wrap; column-gap: 10px; row-gap: 12px; margin-top: 40px; margin-bottom: 0; }
.leads-page-actions .filter-toolbar > .search-field { width: 255px; min-width: 0; max-width: 255px; flex: 0 1 255px; margin-left: auto; }
.leads-filter-options { width: 100%; margin-bottom: 0; }
.leads-summary { display: flex; gap: 12px; margin-top: 16px; overflow-x: auto; scroll-behavior: smooth; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; touch-action: pan-x pan-y; }
.leads-summary::-webkit-scrollbar { display: none; }
.leads-summary.is-dragging { scroll-behavior: auto; scroll-snap-type: none; cursor: grabbing; user-select: none; }
.leads-summary__item { display: flex; min-width: 0; height: 80px; min-height: 80px; max-height: 80px; flex: 0 0 auto; align-items: center; gap: 10px; overflow: hidden; padding: 8px 10px; border: 1px solid var(--color-border); border-radius: var(--radius-surface); background: var(--color-surface); box-shadow: var(--shadow-card); font: inherit; text-align: left; cursor: pointer; transition: background-color .2s, border-color .2s; }
.leads-summary__item.is-page-start { scroll-snap-align: start; scroll-snap-stop: always; }
.leads-summary.is-dragging .leads-summary__item { cursor: grabbing; }
.leads-summary__item.is-active { border-color: var(--color-accent); background: var(--color-accent-soft); }
@media (hover: hover) and (pointer: fine) {
  .leads-summary__item:not(.is-active):hover { background: var(--color-surface-hover); }
}
.leads-summary__icon { display: grid; width: 40px; height: 40px; flex: 0 0 40px; place-items: center; border-radius: var(--radius-round); background: var(--lead-summary-soft); color: var(--lead-summary-color); }
.leads-summary__icon::before { width: 20px; height: 20px; background: currentColor; content: ""; -webkit-mask: var(--lead-summary-icon) center / contain no-repeat; mask: var(--lead-summary-icon) center / contain no-repeat; }
.leads-summary__content { display: grid; min-width: 0; gap: 0; }
.leads-summary__content > span { max-width: 100%; color: var(--color-text-secondary); font-size: var(--font-sm); line-height: var(--line-sm); font-weight: 400; white-space: nowrap; }
.leads-summary__content strong { color: var(--color-text-primary); font-size: var(--font-lg); line-height: var(--line-lg); font-weight: var(--table-total-font-weight); }
.leads-summary__spinner { width: var(--font-lg); height: var(--font-lg); border-width: 2px; vertical-align: middle; }
.leads-summary__item--info { --lead-summary-color: var(--color-status-info-background); --lead-summary-soft: var(--color-info-soft); --lead-summary-icon: url("/assets/icons/star.svg"); }
.leads-summary__item--teal { --lead-summary-color: var(--color-status-teal-background); --lead-summary-soft: var(--color-info-soft); --lead-summary-icon: url("/assets/icons/people.svg"); }
.leads-summary__item--urgent { --lead-summary-color: #f41f20; --lead-summary-soft: var(--color-danger-soft); --lead-summary-icon: url("/assets/icons/fire.svg"); }
.leads-summary__item--warning { --lead-summary-color: var(--color-status-warning-background); --lead-summary-soft: var(--color-warning-soft); --lead-summary-icon: url("/assets/icons/clock.svg"); }
.leads-summary__item--overdue { --lead-summary-color: #f41f20; --lead-summary-soft: var(--color-danger-soft); --lead-summary-icon: url("/assets/icons/flash.svg"); }
.leads-summary__item--overdue-status { --lead-summary-color: #f41f20; --lead-summary-soft: var(--color-danger-soft); --lead-summary-icon: url("/assets/icons/clock.svg"); }
.leads-summary__item--danger { --lead-summary-color: #f41f20; --lead-summary-soft: var(--color-danger-soft); --lead-summary-icon: url("/assets/icons/heart-broken.svg"); }
.leads-summary__item--success { --lead-summary-color: var(--color-status-success-background); --lead-summary-soft: var(--color-success-soft); --lead-summary-icon: url("/assets/icons/ruble.svg"); }
.leads-summary-pagination { display: flex; min-height: 18px; align-items: center; justify-content: center; gap: 6px; margin-top: 6px; }
.leads-summary-pagination[hidden] { display: none; }
.leads-summary-pagination__dot { width: 7px; height: 7px; padding: 0; border: 0; border-radius: var(--radius-round); background: var(--color-border-strong); cursor: pointer; transition: width .15s, background-color .15s; }
.leads-summary-pagination__dot.is-active { width: 18px; border-radius: var(--radius-round); background: var(--color-accent); }
.lead-form__urgent { display: flex; width: fit-content; align-items: center; gap: 8px; color: var(--color-text-primary); cursor: pointer; }
.lead-form__urgent:has(input:disabled) { color: var(--color-text-secondary); cursor: not-allowed; }
.leads-table__number { display: inline-flex; min-width: 0; align-items: center; white-space: nowrap; }
.leads-table td > .leads-table__number { display: flex; width: max-content; }
.leads-table__number .users-table__name { display: inline-flex; min-width: 0; flex-flow: row nowrap; align-items: center; gap: 4px; white-space: nowrap; }
.leads-table__urgent-icon { display: inline-block; width: 16px; height: 16px; flex: 0 0 16px; background: #f41f20; -webkit-mask: url("/assets/icons/fire.svg") center / contain no-repeat; mask: url("/assets/icons/fire.svg") center / contain no-repeat; }
.leads-table__urgent-icon.is-placeholder { visibility: hidden; }
.leads-filters .search-field,
.leads-filters .select-field,
.leads-filters .select-field select { width: 255px; min-width: 0; }
.leads-mobile-list { display: none; }
.leads-table { min-width: 1760px; }
.leads-table__counterparty-link { cursor: pointer; }
.leads-table__counterparty-link:hover,
.leads-table__counterparty-link:focus-visible { text-decoration: underline; text-underline-offset: 3px; }
.lead-form { display: grid; gap: 16px; }
.lead-form__status { display: flex; align-items: center; gap: 10px; }
@media (max-width: 767px) {
  .leads-filters .select-field,
  .leads-filters .select-field select { width: 100%; }
  .leads-list { border: 0; background: transparent; box-shadow: none; }
  .leads-list > .table-scroll { display: none; }
  .leads-list.table-panel--loading { height: 42px; min-height: 42px; max-height: 42px; }
  .leads-list.table-panel--loading .leads-mobile-list { display: none; }
  .leads-list > .table-overlay-loader { inset: 0; border-radius: var(--radius-surface); }
  .leads-mobile-list { display: grid; gap: 12px; }
  .leads-mobile-card { overflow: hidden; }
  .leads-mobile-card.is-selected { background: var(--color-accent-soft); }
  .leads-mobile-card--empty { padding: 20px; color: var(--color-text-secondary); text-align: center; }
  .leads-mobile-card__details { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 8px 28px; padding: 14px 12px; }
  .leads-mobile-card__details dt { color: var(--color-text-tertiary); white-space: nowrap; }
  .leads-mobile-card__details dd { min-width: 0; overflow-wrap: anywhere; }
  .leads-mobile-card__details .status { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

