/* /assets/css/pages/drivers.css */

/* ============================================================
   Root variables
============================================================ */
:root {
  --filter-height: 60px;
}

/* ============================================================
   Filters (custom selects)
============================================================ */
.drivers__filters {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
  justify-content: space-between;
}

/* Hide native selects, keep in DOM */
.drivers__filters select.filter-native {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}
.search__input{
  height: 100%;
}
.drivers__filters-right {
  display: flex;
  gap: 10px;
  width: 100%;
    justify-content: flex-end;
}

/* ---- Custom select ---- */
.filter {
  position: relative;
  box-sizing: border-box;
  font-size: 14px;
  width: 100%;
}

.filter__control {
  width: 100%;
  height: var(--filter-height);
  padding: 18px 12px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: transparent;
  border: 1px solid #656565;
  cursor: pointer;
  color: #666666;
  outline: none;
  font-weight: 500;
  font-size: 18px;
}

.filter__block {
  display: flex;
}

.filter__label {
  margin-right: 2px;
  white-space: nowrap;
}

.filter__value {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  display: flex;
  text-overflow: ellipsis;
}

/* States: open / filled */
.filter.is-open .filter__control,
.filter.is-filled .filter__control {
  background: #161616;
  border-color: #161616;
  color: rgba(255, 255, 255, 0.6);
}

.filter.is-open .filter__label,
.filter.is-filled .filter__label {
  color: rgba(255, 255, 255, 0.6);
}

.filter.is-open .filter__value,
.filter.is-filled .filter__value {
  color: #ffffff;
}

/* Dropdown menu */
.filter__menu {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  background: #161616;
  padding: 0 0 12px;
  box-sizing: border-box;
  max-height: 260px;
  overflow-y: auto;
  opacity: 0;
  pointer-events: none;
  transform: translateY(4px);
  transition:
    opacity 0.15s ease,
    transform 0.15s ease;
  z-index: 20;
}

.filter.is-open .filter__menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

/* Options */
.filter__option {
  width: 100%;
  padding: 10px 12px;
  background: none;
  border: none;
  text-align: left;
  font-size: 20px;
  line-height: 24px;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  box-sizing: border-box;
}

.filter__option + .filter__option {
  position: relative;
}

.filter__option + .filter__option::before {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  top: 0;
  border-top: 0.5px solid #666666;
}

.filter__option:hover {
  background: #202020;
  color: #ffffff;
}

.filter__option.is-active {
  position: relative;
  color: #ffffff;
}

.filter__option.is-active::after {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 12px;
  height: 6px;
  border-left: 1.5px solid #ffffff;
  border-bottom: 1.5px solid #ffffff;
  transform: translateY(-60%) rotate(-45deg);
}

/* ============================================================
   Views
============================================================ */
.drivers-view {
  display: none;
}
.drivers-view.is-visible {
  display: flex;
  flex-direction: column;
}

/* ============================================================
   Tables
============================================================ */
#driver-table th,
#driver-table td,
#driver-history-table thead th,
#driver-history-table tbody td {
  text-align: left;
}

tbody tr {
  cursor: pointer;
}

/* History: last column centered */
#driver-history-table thead th:last-child,
#driver-history-table tbody td:last-child {
  text-align: center;
}

/* ============================================================
   Driver card (scoped to .drivers-page)
============================================================ */
.drivers-page .card-header {
  display: grid;
  grid-template-columns: 2rem 1fr;
  align-items: center;
  gap: 1.875rem;
  margin-bottom: 40px;
}

.drivers-page .card-title {
  margin: 0;
  font-size: 24px;
  font-weight: 500;
  color: #000;
  white-space: pre-line;
}

/* PP-08: низкий рейтинг / ответственность — красное ФИО в карточке */
.drivers-page .card-title.is-alert {
  color: #E53935;
}

.drivers-page .card-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
}

/* Header: avatar + name + stats */
.drivers-page .driver-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
}

.driver-head__meta {
  flex: 1;
}

.drivers-page .drivers-avatar {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  overflow: hidden;
  background: #e0e0e0;
  flex-shrink: 0;
}

.drivers-page .drivers-avatar__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* заглушка: силуэт вырезан в svg, белый фон под ним даёт светлую фигуру */
.drivers-page .drivers-avatar__img.drivers-avatar--empty {
  background: #fff;
  object-fit: contain;
}

.drivers-page .driver-stats {
  display: flex;
  gap: 28px;
  align-items: flex-end;
  flex-wrap: wrap;
}

.drivers-page .driver-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-bottom: 2px solid #000000;
  border-bottom-right-radius: 1px;
  border-bottom-left-radius: 1px;
}

.drivers-page .driver-stat__value {
  font-size: 28px;
  font-weight: 500;
  color: #333333;
}

.drivers-page .driver-stat__value--with-icon {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
}

.drivers-page .driver-stat__icon {
  width: 28px;
  height: 28px;
  display: block;
}

.drivers-page .driver-stat__label {
  font-size: 16px;
  color: #333333;
  margin-bottom: 10px;
}

/* ============================================================
   Tabs (3 tabs)
============================================================ */
.drivers-page .tabs {
  display: flex;
  gap: 0;
  padding: 3px;
  border: 1px solid #161616;
  margin: 40px 0 24px;
}

.drivers-page .tab {
  flex: 1 1 0;
  min-width: 0;
  min-height: 40px;
  background: #ffffff;
  border: none;
  color: #999999;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  line-height: 40px;
  padding: 0 8px;
  white-space: nowrap;
}

.drivers-page .tab.is-active {
  background: #161616;
  color: #ffffff;
}

.drivers-page .tab-panes {
  margin-top: 12px;
  overflow: auto;
  height: 100%;
}

.drivers-page .tab-pane {
  display: none;
}

.drivers-page .tab-pane.is-active {
  display: block;
  height: 100%;
}

/* ============================================================
   Info grid (driver details)
============================================================ */
.drivers-page .info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 34px;
}

.drivers-page .info-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.col-partner {
  height: 33px;
  margin-bottom: 24px;
}

.drivers-page .info-col.full-width {
  grid-column: 1 / -1;
}
.drivers-page .info-col.full-width:last-child .info-row {
  justify-content: flex-start;
  gap: 5px;
}

.drivers-page .info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 0.5px solid #666666;
}

.drivers-page .info-label {
  color: #666666;
  font-size: 18px;
}

.drivers-page .info-section-sep {
  grid-column: 1 / -1;
  padding-bottom: 8px;
  border-bottom: 1px solid #656565;
  font-size: 20px;
  font-weight: 500;
  color: #333333;
}

.drivers-page .info-value-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  font-weight: 500;
}

.drivers-page .info-value {
  display: inline-block;
  min-height: 24px;
  line-height: 24px;
  font-size: 18px;
  color: #333333;
  outline: none;
  border: none;
  text-align: right;
}

.drivers-page .info-value:empty::before {
  content: attr(data-placeholder);
  color: #9b9b9b;
}

/* blocks spacing */
.drivers-page .info-grid.payout-info {
  gap: 10px 34px;
  margin-top: 24px;
}

/* Trips block */
#driver-trips-block {
  margin-top: 40px;
}

#driver-trips-block .info-col {
  gap: 40px;
}

/* Авто: value + icon */
.drivers-page .info-value-wrap--icon {
  gap: 8px;
}

/* Icons via <img> */
.drivers-page .info-icon,
.drivers-page .section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #333333;
}

.drivers-page .info-icon img,
.drivers-page .section-icon img {
  width: 18px;
  height: 18px;
  display: block;
}

/* Activity dot */
.drivers-page .status-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  flex: 0 0 12px;
  margin-right: 6px;
  background: #e53935;
}

.drivers-page .status-dot.is-online {
  background: #38b236;
}

/* ============================================================
   ✅ NEW LAYOUT: Активность + Статус (две строки) в ЛЕВОЙ колонке
============================================================ */
.drivers-page .info-rows-stack {
  display: flex;
  gap: 10px; /* ваш отступ между двумя строками */
}
.drivers-page .info-rows-stack .info-row {
  width: 100%;
}
/* ============================================================
   ✅ "Все заказы" — отдельная строка справа, на всю ширину строки, всё вправо
============================================================ */
.drivers-page .info-row--orders {
  justify-content: flex-end;
}

.drivers-page .info-value--link {
  text-decoration: underline;
  cursor: pointer;
}

/* ============================================================
   "Личные данные" with icon on the right
============================================================ */
.drivers-page .info-section-sep--with-icon {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drivers-page .section-icon.is-hidden {
  display: none;
}

.drivers-page [hidden] {
  display: none !important;
}

/* ============================================================
   Documents tab (NEW layout like Partners)
============================================================ */
.drivers-page .docs-block {
  display: flex;
  height: 100%;
  flex-direction: column;
  gap: 24px;
  padding-bottom: 0;
}
.bottom-doc {
  margin: 16px 0;
}
/* whole doc item */
.drivers-page .driver-doc {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* header line: title + (status/approve) + (file link sometimes) + edit icon */
.drivers-page .driver-doc .doc-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid #656565;
}

.drivers-page .doc-top__left {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.drivers-page .doc-top__right {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

/* title like partners */
.drivers-page .doc-title {
  font-size: 20px;
  font-weight: 500;
  color: #333333;
  white-space: nowrap;
}

/* status pill like partners */
.drivers-page .doc-status {
  font-size: 14px;
  padding: 5px 8px;
  border: 0.5px solid #656565;
  color: #38b236;
  background: #fff;
  border-radius: 1px;
  white-space: nowrap;
}

/* approve button like partners */
.drivers-page .mini-btn--approve {
  background: #38b236;
  color: #fff;
  border: none;
  padding: 3.5px 20px;
  font-size: 16px;
  cursor: pointer;
  border-radius: 1px;
  white-space: nowrap;
}

/* edit icon on the right */
.drivers-page .doc-edit-btn {
  width: 18px;
  height: 18px;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.drivers-page .doc-edit-btn img {
  width: 18px;
  height: 18px;
  display: block;
}

/* rows layout:
   left side = 2 fields (gap 10px)
   right side = 1 field (full) */
.drivers-page .doc-row-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 34px;
  align-items: start;
}

.drivers-page .doc-left-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px; /* важно: 10px между двумя полями */
  align-items: start;
}

.drivers-page .doc-left-one,
.drivers-page .doc-right-one {
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* file links */
.drivers-page .doc-file-list {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.drivers-page .doc-file-list a {
  font-weight: 500;
  font-size: 18px;
  color: #333333;
  text-decoration: underline;
}

/* contract note text */
.drivers-page .doc-note {
  font-size: 16px;
  color: #666666;
  margin-top: 8px;
}
/* ===== icon button (for small svg clicks) ===== */
.drivers-page .icon-btn {
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  line-height: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Activity icon button alignment */
.drivers-page .driver-activity-edit img {
  width: 18px;
  height: 18px;
  display: block;
}

/* Responsibility pencil button */
.drivers-page .driver-resp-edit img {
  width: 20px;
  height: 20px;
  display: block;
}

/* ===== Activity modal "select" (always open) ===== */
.drivers-page .activity-select {
  border: 1px solid #999999;
  background: #ffffff;
  width: 100%;
}

.drivers-page .activity-select__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 12px;
  border-bottom: 1px solid #999999;
}

.drivers-page .activity-select__placeholder {
  font-size: 24px;
  font-weight: 500;
  color: #999999;
}

.drivers-page .activity-select__arrow {
  width: 18px;
  height: 10px;
  background-color: #666666;
  -webkit-mask-image: url("/assets/img/arrow.svg");
  mask-image: url("/assets/img/arrow.svg");
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
  transform: rotate(-180deg); /* как на скрине (стрелка вверх) */
}

.drivers-page .activity-select__list {
  display: flex;
  flex-direction: column;
}

.drivers-page .activity-option {
  border: 0;
  background: transparent;
  text-align: left;
  padding: 18px 12px;
  font-size: 24px;
  font-weight: 500;
  color: #333333;
  cursor: pointer;
  position: relative;
}

.drivers-page .activity-option + .activity-option {
  border-top: 1px solid #dcdcdc;
}

.drivers-page .activity-option.is-inactive {
  opacity: 0.5;
}

.drivers-page .activity-option.is-active {
  opacity: 1;
}

.drivers-page .activity-option.is-active::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 14px;
  height: 8px;
  border-left: 2px solid #000;
  border-bottom: 2px solid #000;
  transform: translateY(-60%) rotate(-45deg);
}

/* ===== Responsibility view ===== */
.drivers-page .resp-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.drivers-page .resp-title {
  margin: 0;
  font-size: 20px;
  font-weight: 500;
  color: #333333;
}

/* last column for delete buttons */
#driver-resp-table thead th:last-child,
#driver-resp-table tbody td:last-child {
  text-align: right;
}

.drivers-page .resp-delete-btn {
  min-width: 160px;
  height: 40px;
  border: 0;
  background: #d32525;
  color: #ffffff;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
}

/* ===== POPUP: Activity ===== */

.activity {
  font-size: 14px;
  color: #666666;
}

.activity-select {
  padding: 18px 10px;
  display: flex;
  border: 1px solid #999999;
  gap: 10px;
  flex-direction: column;
}

.activity-select__head {
  width: 100%;
  display: flex;
  justify-content: space-between;
}

.activity-select__head .activity-select__placeholder {
  font-size: 20px;
  line-height: 24px;
  color: #666666;
}

.activity-select__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* строка "кнопка + галка" */
#driver-activity-options .activity-line-block {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* кнопка (base / inactive) */
#driver-activity-options .activity-option {
  border: none;
  background: none;
  font-size: 20px;
  line-height: 24px;
  color: #666666; /* серый по умолчанию */
  height: 44px;
  text-align: left;
  padding: 0;
  cursor: pointer;
}

/* ❗️убираем активные стили с кнопки (теперь они на .activity-line-block) */
#driver-activity-options .activity-option.is-active {
  color: inherit;
  border-bottom: none;
  border-radius: 0;
}

/* галочку скрываем всем */
#driver-activity-options .driver-stat__icon {
  display: none;
}

/* галочка только у активного */
#driver-activity-options .activity-option.is-active + .driver-stat__icon {
  display: inline-block;
}

/* активная строка: border-bottom + цвет текста */
#driver-activity-options .activity-line-block:has(.activity-option.is-active) {
  border-bottom: 0.5px solid #666666;
  border-radius: 0;
}

#driver-activity-options
  .activity-line-block:has(.activity-option.is-active)
  .activity-option {
  color: #333333;
}

.docs-alert-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #d32525;
  vertical-align: text-top;
}

.info-row:has(.info-value-wrap .dateValid) {
  border-bottom-color: #d32525;
}
.dateValid {
  color: #d32525;
}

.doc-agreement .doc-title {
  font-size: 24px;
}
.doc-agreement .doc-top {
  border-bottom: none !important;
  padding-bottom: 0 !important;
}
.doc-agreement {
  gap: 10px;
}

.doc-agreement .doc-note {
  font-size: 14px;
  margin-top: 0;
}

.info-value[data-key="partnerName"],
.info-value[data-key="carTitle"] {
  text-decoration: underline;
  cursor: pointer;
}

.driver-check input {
  width: auto;
}

.block-driver-check {
  text-align: left;
  display: flex;
  gap: 10px;
  justify-content: flex-start;
}

.driver-check {
  width: 50%;
}

/* === Кастомный чекбокс как на макете === */
.driver-check {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  user-select: none;
}

/* прячем нативный чекбокс, но оставляем доступным */
.driver-check input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.driver-check span {
  color: #666 !important;
  font-size: 20px;
  position: relative;
  padding-left: 32px;
}

/* квадрат */
.driver-check span::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 24px;
  height: 24px;
  transform: translateY(-50%);
  border: 2px solid #bdbdbd;
  border-radius: 2px;
  background: #fff;
  box-sizing: border-box;
}

/* checked - чёрный квадрат + галочка */
.driver-check input[type="checkbox"]:checked + span::before {
  background: #111;
  border-color: #111;
  background-image: url("/assets/img/drivers/check.svg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px 14px;
}

/* фокус с клавиатуры */
.driver-check input[type="checkbox"]:focus-visible + span::before {
  outline: 2px solid #111;
  outline-offset: 3px;
}

#driver-personal-edit-modal .field input {
  max-width: none;
  width: 100%;
}
#driver-personal-edit {
  cursor: pointer;
}

.driver-pay-toggle {
  display: flex;
  gap: 10px;
  flex-direction: column;
}

.drivers-car-cell {
  display: flex;
  justify-content: space-between;
  margin-right: 10px;
}

tbody tr td:first-child {
  text-decoration: underline;
}

/* ============================================================
   Журнал линии водителя
============================================================ */
.drivers-page .dline {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 280px;
  padding-bottom: 24px;
}

.drivers-page .dline__toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}

.drivers-page .dline__step {
  width: 36px;
  height: 36px;
  border: 1px solid #161616;
  background: #fff;
  cursor: pointer;
  position: relative;
  flex: 0 0 auto;
}

.drivers-page .dline__step:disabled {
  opacity: 0.35;
  cursor: default;
}

.drivers-page .dline__step::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  border-top: 2px solid #161616;
  border-right: 2px solid #161616;
}

.drivers-page .dline__step--prev::before {
  transform: translate(-30%, -50%) rotate(-135deg);
}

.drivers-page .dline__step--next::before {
  transform: translate(-70%, -50%) rotate(45deg);
}

.drivers-page .dline__date {
  border: none;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-size: 18px;
  font-weight: 700;
  color: #161616;
  text-transform: lowercase;
  padding: 0 4px;
}

.drivers-page .dline__date:hover {
  color: #9c6230;
}

.drivers-page .dline__pick {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.drivers-page .dline__today,
.drivers-page .dline__refresh,
.drivers-page .dline__retry {
  height: 36px;
  padding: 0 14px;
  border: 1px solid #161616;
  background: #fff;
  color: #161616;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.drivers-page .dline__refresh {
  margin-left: auto;
}

.drivers-page .dline__today:hover,
.drivers-page .dline__refresh:hover,
.drivers-page .dline__retry:hover,
.drivers-page .dline__step:hover:not(:disabled) {
  background: #161616;
  color: #fff;
}

.drivers-page .dline__step:hover:not(:disabled)::before {
  border-color: #fff;
}

.drivers-page .dline__stats:empty {
  display: none;
}

.drivers-page .dline__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid #e4e4e4;
  background: #fff;
}

.drivers-page .dline-stat {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.drivers-page .dline-stat + .dline-stat {
  border-left: 1px solid #eee;
}

.drivers-page .dline-stat__label {
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #888;
}

.drivers-page .dline-stat__value {
  font-size: 20px;
  font-weight: 700;
  color: #161616;
  font-variant-numeric: tabular-nums;
}

.drivers-page .dline-stat__live {
  align-self: flex-start;
  margin-top: 2px;
  font-size: 12px;
  font-weight: 700;
  color: #1f7a4d;
}

.drivers-page .dline-stat__live::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 6px;
  border-radius: 50%;
  background: #1f7a4d;
  box-shadow: 0 0 0 0 rgba(31, 122, 77, 0.6);
  animation: dline-pulse 1.6s ease-out infinite;
}

@keyframes dline-pulse {
  70% { box-shadow: 0 0 0 6px rgba(31, 122, 77, 0); }
  100% { box-shadow: 0 0 0 0 rgba(31, 122, 77, 0); }
}

.drivers-page .dline-shift {
  background: #fff;
  border: 1px solid #e4e4e4;
  padding: 14px 16px 8px;
}

.drivers-page .dline-shift + .dline-shift {
  margin-top: 10px;
}

.drivers-page .dline-shift__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f0f0f0;
  margin-bottom: 4px;
}

.drivers-page .dline-shift__range {
  font-size: 16px;
  font-weight: 700;
  color: #161616;
  font-variant-numeric: tabular-nums;
}

.drivers-page .dline-shift__car,
.drivers-page .dline-shift__online {
  font-size: 14px;
  color: #555;
}

.drivers-page .dline-shift__online {
  margin-left: auto;
  font-weight: 700;
  color: #1f7a4d;
}

.drivers-page .dline-shift__live {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9c6230;
}

.drivers-page .dline-tl {
  list-style: none;
  margin: 0;
  padding: 6px 0 8px;
}

.drivers-page .dline-ev {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 8px 12px;
  padding: 8px 0 8px 14px;
  position: relative;
}

.drivers-page .dline-ev::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: #e6e6e6;
}

.drivers-page .dline-ev--start::before { background: #1f7a4d; }
.drivers-page .dline-ev--online::before { background: #1f7a4d; }
.drivers-page .dline-ev--pause::before { background: #c4a15a; }
.drivers-page .dline-ev--lost::before { background: #c4473a; }
.drivers-page .dline-ev--miss::before { background: #c47a2c; }
.drivers-page .dline-ev--block::before { background: #161616; }
.drivers-page .dline-ev--gap::before { background: #c9c9c9; }
.drivers-page .dline-ev--close::before { background: #161616; }
.drivers-page .dline-ev--note::before,
.drivers-page .dline-ev--orders::before { background: #e6e6e6; }

.drivers-page .dline-ev__time {
  font-size: 13px;
  font-weight: 600;
  color: #666;
  font-variant-numeric: tabular-nums;
  padding-top: 2px;
}

.drivers-page .dline-ev__body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.drivers-page .dline-ev__title {
  font-size: 14px;
  font-weight: 700;
  color: #161616;
}

.drivers-page .dline-ev__dur {
  margin-left: 8px;
  font-weight: 600;
  color: #555;
}

.drivers-page .dline-ev--lost .dline-ev__title { color: #c4473a; }
.drivers-page .dline-ev--pause .dline-ev__title { color: #8a6a2f; }
.drivers-page .dline-ev--gap .dline-ev__title { color: #888; font-weight: 600; }

.drivers-page .dline-ev--close .dline-ev__line {
  display: block;
  margin-top: 2px;
  font-size: 18px;
  font-weight: 800;
  color: #161616;
  font-variant-numeric: tabular-nums;
}

.drivers-page .dline-ev__meta {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  font-weight: 500;
  color: #777;
}

.drivers-page .dline-ev.is-open .dline-ev__dur {
  color: #1f7a4d;
}

.drivers-page .dline-orders {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.drivers-page .dline-orders--loose {
  padding: 8px 0 10px;
}

.drivers-page .dline-order {
  display: grid;
  grid-template-columns: 52px 78px minmax(0, 1fr) auto;
  gap: 2px 10px;
  align-items: baseline;
  width: 100%;
  text-align: left;
  border: none;
  background: #fafafa;
  color: inherit;
  font: inherit;
  padding: 8px 10px;
  cursor: pointer;
}

.drivers-page .dline-order:hover {
  background: #f6f1ea;
}

.drivers-page .dline-order__time,
.drivers-page .dline-order__no {
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #161616;
}

.drivers-page .dline-order__no {
  color: #9c6230;
}

.drivers-page .dline-order__route {
  font-size: 13px;
  color: #333;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.drivers-page .dline-order__side {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px 8px;
  font-size: 12px;
  font-weight: 700;
  color: #333;
}

.drivers-page .dline-order__st {
  font-weight: 700;
}

.drivers-page .dline-order__st.is-end { color: #1f7a4d; }
.drivers-page .dline-order__st.is-canceled { color: #c4473a; }
.drivers-page .dline-order__st.is-run,
.drivers-page .dline-order__st.is-taken,
.drivers-page .dline-order__st.is-arrived { color: #9c6230; }

.drivers-page .dline-order__cash {
  color: #888;
  font-weight: 600;
}

.drivers-page .dline-order__steps {
  grid-column: 1 / -1;
  font-size: 12px;
  color: #888;
}

.drivers-page .dline-empty {
  padding: 28px 8px;
  color: #666;
  font-size: 15px;
}

.drivers-page .dline-empty--err p {
  margin-bottom: 12px;
}

.drivers-page .dline-warn {
  margin-bottom: 8px;
  padding: 8px 12px;
  background: #fff8ee;
  border: 1px solid #ead7b8;
  color: #6b5428;
  font-size: 13px;
}

.drivers-page .dline-skel {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.drivers-page .dline-skel span {
  display: block;
  height: 64px;
  background: linear-gradient(90deg, #eee 0%, #f7f7f7 50%, #eee 100%);
  background-size: 200% 100%;
  animation: dline-shimmer 1.2s ease-in-out infinite;
}

.drivers-page .dline-skel span:nth-child(2) { height: 120px; }
.drivers-page .dline-skel span:nth-child(3) { height: 80px; }

@keyframes dline-shimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

@media (max-width: 860px) {
  .drivers-page .dline__stats {
    grid-template-columns: 1fr 1fr;
  }
  .drivers-page .dline-stat:nth-child(3) {
    border-left: none;
    border-top: 1px solid #eee;
  }
  .drivers-page .dline-stat:nth-child(4) {
    border-top: 1px solid #eee;
  }
  .drivers-page .dline-ev {
    grid-template-columns: 1fr;
    gap: 2px;
  }
  .drivers-page .dline-order {
    grid-template-columns: 52px 78px minmax(0, 1fr);
  }
  .drivers-page .dline-order__side {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}
