.freight-menu [data-freight-changes] {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.freight-menu [data-freight-changes] b {
  min-width: 22px;
  height: 20px;
  display: inline-grid;
  place-items: center;
  border: 1px solid #78add0;
  border-radius: 999px;
  background: #e5f4fd;
  color: #24658f;
  padding: 0 6px;
  font-size: 11px;
  box-shadow: inset 0 1px 0 #fff;
}

.freight-menu [data-freight-changes].active {
  border-color: #69a6ca;
  background: linear-gradient(180deg, #fafdff, #dceef8);
  color: #235d85;
  box-shadow: inset 3px 0 0 #62a6cc, 0 4px 10px rgba(37, 92, 128, .1);
}

.freight-change-backdrop {
  position: fixed;
  inset: 0;
  z-index: 3560;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(20, 38, 55, .42);
  backdrop-filter: blur(3px);
}

.freight-change-backdrop.hidden {
  display: none;
}

.freight-change-dialog {
  width: min(1480px, 92vw);
  height: min(880px, 86vh);
  min-height: 620px;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  overflow: hidden;
  border: 1px solid #8fb2ca;
  border-radius: 8px;
  background: #f7fbfe;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .98),
    0 2px 0 rgba(255, 255, 255, .42),
    0 24px 54px rgba(10, 32, 50, .25),
    0 44px 110px rgba(10, 32, 50, .28);
  animation: freight-change-enter .2s ease-out;
}

.freight-change-dialog > * {
  min-width: 0;
}

@keyframes freight-change-enter {
  from { opacity: 0; transform: translateY(8px) scale(.992); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.freight-change-head {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  border-bottom: 1px solid #c6d7e4;
  background: linear-gradient(180deg, #ffffff, #edf6fb);
  padding: 16px 20px 14px 22px;
  box-shadow: inset 0 4px 0 #6eb0d2, 0 1px 0 #fff;
}

.freight-change-head > div:first-child {
  min-width: 0;
}

.freight-change-head span {
  color: #648197;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
}

.freight-change-head h2 {
  margin: 0;
  color: #1d4d70;
  font-size: 24px;
  line-height: 1.15;
  letter-spacing: 0;
}

.freight-change-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 3px 0 2px;
}

.freight-change-mode-badge {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #99bfd6;
  border-radius: 4px;
  background: #eaf6fd;
  color: #2c6f98;
  padding: 0 9px;
  font-size: 10px;
  line-height: 1;
  font-weight: 950;
  white-space: nowrap;
}

.freight-change-mode-badge.px {
  border-color: #a8cbbb;
  background: #eef8f3;
  color: #397762;
}

.freight-change-head p {
  margin: 0;
  color: #607b90;
  font-size: 12px;
  font-weight: 750;
}

.freight-change-head-tools {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex: 0 0 auto;
}

.freight-change-head-tools > button {
  width: 36px;
  height: 36px;
  border: 1px solid #a6bfd1;
  border-bottom-color: #7e9db4;
  border-radius: 5px;
  background: linear-gradient(#fff, #eaf3f8);
  color: #315b78;
  font-size: 23px;
  line-height: 1;
  box-shadow: inset 0 1px 0 #fff, 0 2px 0 #c4d5e1, 0 7px 14px rgba(31, 69, 94, .12);
  cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}

.freight-change-head-tools > button:hover {
  transform: translateY(-1px);
  border-color: #70a5c6;
  box-shadow: inset 0 1px 0 #fff, 0 3px 0 #b1cad9, 0 10px 18px rgba(31, 69, 94, .16);
}

.freight-change-batch-picker {
  display: grid;
  gap: 4px;
}

.freight-change-batch-picker span {
  color: #668298;
  font-size: 10px;
}

.freight-change-batch-picker select {
  width: min(430px, 38vw);
  height: 36px;
  border: 1px solid #a6bfd1;
  border-radius: 5px;
  background: #fff;
  color: #244d6c;
  padding: 0 32px 0 10px;
  font-weight: 850;
  box-shadow: inset 0 1px 2px rgba(24, 67, 96, .05);
}

.freight-change-summary {
  min-height: 94px;
  display: grid;
  grid-template-columns: minmax(330px, 2fr) repeat(5, minmax(74px, .48fr));
  gap: 0;
  border-bottom: 1px solid #cbdbe6;
  background: #fff;
}

.freight-change-summary-lead {
  display: grid;
  align-content: center;
  gap: 4px;
  border-right: 1px solid #d8e4ec;
  padding: 14px 22px;
}

.freight-change-summary-lead > span {
  color: #7090a6;
  font-size: 10px;
  font-weight: 900;
}

.freight-change-summary-lead strong {
  color: #173f60;
  font-size: 17px;
  line-height: 1.35;
}

.freight-change-summary-lead small {
  color: #72889a;
  font-size: 11px;
  font-weight: 750;
}

.freight-change-metric {
  display: grid;
  place-content: center;
  gap: 3px;
  border-right: 1px solid #e0e9ef;
  text-align: center;
}

.freight-change-metric span {
  color: #74899a;
  font-size: 11px;
  font-weight: 850;
}

.freight-change-metric strong {
  color: #446378;
  font-size: 23px;
  line-height: 1;
}

.freight-change-metric.stopped strong { color: #9e5658; }
.freight-change-metric.new strong { color: #3981ad; }
.freight-change-metric.up strong { color: #c45b57; }
.freight-change-metric.down strong { color: #248071; }

.freight-change-summary-note {
  grid-column: 1 / -1;
  min-height: 28px;
  display: flex;
  align-items: center;
  gap: 18px;
  border-top: 1px solid #e4ebf0;
  background: #f8fbfd;
  color: #6a8193;
  padding: 0 22px;
  font-size: 11px;
  font-weight: 750;
}

.freight-change-summary-note b {
  color: #3a5e78;
}

.freight-change-summary-note .review {
  color: #9c5b47;
}

.freight-change-toolbar {
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid #cbdbe6;
  background: #f4f9fc;
  padding: 10px 18px;
}

.freight-change-filters {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  border: 1px solid #bed2e0;
  border-radius: 6px;
  background: #eaf3f8;
  padding: 3px;
}

.freight-change-filters button {
  height: 31px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid transparent;
  border-radius: 4px;
  background: transparent;
  color: #557186;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
  transition: color .15s ease, background .15s ease, box-shadow .15s ease;
}

.freight-change-filters button:hover {
  color: #275f84;
  background: rgba(255, 255, 255, .66);
}

.freight-change-filters button.active {
  border-color: #9fc1d8;
  background: #fff;
  color: #24638c;
  box-shadow: 0 2px 6px rgba(37, 83, 113, .1);
}

.freight-change-filter-count {
  min-width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  border: 1px solid #efc0bd;
  border-radius: 9px;
  background: #fff4f3;
  color: #c44742;
  padding: 0 5px;
  font-size: 10px;
  line-height: 1;
  font-weight: 950;
}

.freight-change-filters button.active .freight-change-filter-count {
  border-color: #e8aaa6;
  background: #ffefed;
  color: #b9332f;
}

.freight-change-search {
  min-width: min(390px, 34vw);
  height: 38px;
  display: flex;
  align-items: center;
  border: 1px solid #afc7d8;
  border-radius: 6px;
  background: #fff;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(20, 59, 85, .04);
}

.freight-change-search > span {
  height: 100%;
  display: inline-flex;
  align-items: center;
  border-right: 1px solid #d5e1e9;
  color: #52758e;
  padding: 0 11px;
  font-size: 11px;
  font-weight: 900;
}

.freight-change-search input {
  min-width: 0;
  flex: 1;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #254a66;
  padding: 0 11px;
  font-weight: 750;
}

.freight-change-body {
  min-height: 0;
  overflow: auto;
  scrollbar-gutter: stable;
  background: #eef5f9;
  padding: 12px 16px 18px;
}

.freight-change-result-meta {
  min-height: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #718799;
  padding: 0 3px 8px;
  font-size: 11px;
}

.freight-change-result-meta strong {
  color: #3f6178;
  font-size: 12px;
}

.freight-change-routes {
  display: grid;
  gap: 8px;
}

.freight-change-band-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  padding: 10px 0 6px;
  color: #264960;
  font-size: 12px;
}

.freight-change-band-title small {
  color: #aa4942;
  font-size: 11px;
}

.freight-change-bands .freight-change-item {
  min-height: 36px;
}

.freight-change-route {
  overflow: hidden;
  border: 1px solid #c0d2df;
  border-left: 4px solid #7faac6;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 3px 10px rgba(34, 70, 95, .06);
}

.freight-change-route.stopped { border-left-color: #ba7474; }
.freight-change-route.new { border-left-color: #5c9fc7; }
.freight-change-route.increase { border-left-color: #d27670; }
.freight-change-route.decrease { border-left-color: #4a9a89; }
.freight-change-route.mixed { border-left-color: #8c91ad; }

.freight-change-route-head {
  width: 100%;
  min-height: 58px;
  display: grid;
  grid-template-columns: 96px minmax(230px, 1.2fr) minmax(330px, 1.5fr) auto 72px;
  align-items: center;
  gap: 13px;
  border: 0;
  background: linear-gradient(180deg, #fff, #fbfdff);
  color: #264960;
  padding: 8px 14px;
  text-align: left;
  cursor: pointer;
}

.freight-change-route-flags {
  display: grid;
  gap: 3px;
}

.freight-change-route-mode {
  min-height: 18px;
  display: inline-grid;
  place-items: center;
  border: 1px solid #b7cedd;
  border-radius: 3px;
  background: #f2f8fc;
  color: #427392;
  padding: 0 5px;
  font-size: 9px;
  line-height: 1;
  font-weight: 900;
  white-space: nowrap;
}

.freight-change-route-mode.px {
  border-color: #bad3c7;
  background: #f1f8f4;
  color: #447963;
}

.freight-change-route-head:hover {
  background: #f6fbfe;
}

.freight-change-type {
  min-height: 25px;
  display: inline-grid;
  place-items: center;
  border: 1px solid #b6cbd9;
  border-radius: 4px;
  background: #eff6fa;
  color: #4f6f84;
  padding: 0 7px;
  font-size: 11px;
  font-weight: 900;
}

.stopped .freight-change-type { border-color: #dfb6b4; background: #fff1f0; color: #985353; }
.new .freight-change-type { border-color: #a8cbe0; background: #eef8fe; color: #35769e; }
.increase .freight-change-type { border-color: #e6b2ad; background: #fff2f0; color: #b4524d; }
.decrease .freight-change-type { border-color: #a7d2c7; background: #edf9f5; color: #287667; }

.freight-change-route-head > strong {
  min-width: 0;
  color: #153f5f;
  font-size: 16px;
  line-height: 1.25;
}

.freight-change-route-head > strong i {
  color: #75a7c5;
  padding: 0 6px;
  font-style: normal;
}

.freight-change-route-meta {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
  color: #617c90;
  font-size: 11px;
}

.freight-change-route-meta b,
.freight-change-route-meta em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.freight-change-route-meta b {
  color: #345f7d;
}

.freight-change-route-meta em {
  font-style: normal;
  font-weight: 750;
}

.freight-change-review {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #e2b39d;
  border-radius: 4px;
  background: #fff6ef;
  color: #9c5a3f;
  padding: 0 8px;
  font-size: 10px;
  font-weight: 900;
}

.freight-change-item-count {
  color: #698399;
  font-size: 11px;
  font-weight: 850;
  text-align: right;
  white-space: nowrap;
}

.freight-change-item-count i {
  display: inline-block;
  margin-left: 5px;
  color: #4d7895;
  font-size: 15px;
  font-style: normal;
  transition: transform .16s ease;
}

.freight-change-route.expanded .freight-change-item-count i {
  transform: rotate(180deg);
}

.freight-change-route-detail {
  display: none;
  border-top: 1px solid #d7e3eb;
  background: #f9fcfe;
  padding: 0 14px 12px;
}

.freight-change-route.expanded .freight-change-route-detail {
  display: block;
  animation: freight-change-detail .16s ease-out;
}

@keyframes freight-change-detail {
  from { opacity: 0; transform: translateY(-3px); }
  to { opacity: 1; transform: translateY(0); }
}

.freight-change-item-head,
.freight-change-item {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(210px, 1.25fr) minmax(210px, 1.25fr) minmax(160px, .8fr);
  gap: 14px;
  align-items: center;
}

.freight-change-item-head {
  min-height: 32px;
  border-bottom: 1px solid #ccdae4;
  color: #71889b;
  font-size: 10px;
  font-weight: 900;
}

.freight-change-item {
  min-height: 49px;
  border-bottom: 1px solid #e2eaf0;
  color: #3d5a70;
  padding: 7px 0;
  font-size: 12px;
}

.freight-change-item:last-of-type {
  border-bottom: 0;
}

.freight-change-item > span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.freight-change-item > span:first-child {
  display: grid;
  gap: 2px;
}

.freight-change-item > span:first-child strong {
  color: #244e6b;
}

.freight-change-item small {
  color: #8093a2;
  font-size: 10px;
  font-weight: 750;
}

.freight-change-item .old {
  color: #718394;
  text-decoration-color: #c6d0d7;
}

.freight-change-item .new {
  color: #234f6e;
  font-weight: 900;
}

.freight-change-item .delta {
  display: grid;
  gap: 2px;
}

.freight-change-item .delta b {
  color: #667d8f;
}

.freight-change-item.increase .delta b,
.freight-change-item.new .delta b { color: #bc5752; }
.freight-change-item.decrease .delta b { color: #287e6e; }
.freight-change-item.stopped .delta b { color: #985a5a; }

.freight-change-route-actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 10px;
}

.freight-change-route-actions button,
.freight-change-foot button,
.freight-change-pagination button {
  min-height: 34px;
  border: 1px solid #9fbed2;
  border-bottom-color: #769db7;
  border-radius: 5px;
  background: linear-gradient(#fff, #e8f3f9);
  color: #2c6388;
  padding: 0 14px;
  font-size: 12px;
  font-weight: 900;
  box-shadow: inset 0 1px 0 #fff, 0 2px 0 #c2d6e2, 0 6px 12px rgba(39, 83, 112, .09);
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.freight-change-route-actions button:hover,
.freight-change-foot button:hover,
.freight-change-pagination button:hover {
  transform: translateY(-1px);
  border-color: #68a5c9;
  box-shadow: inset 0 1px 0 #fff, 0 3px 0 #adcbdc, 0 9px 16px rgba(39, 83, 112, .13);
}

.freight-change-foot {
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid #bed2df;
  background: linear-gradient(180deg, #f8fbfd, #eaf3f8);
  padding: 11px 18px;
}

.freight-change-foot.acknowledgement { justify-content: flex-end; }

.freight-change-foot > div {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}

.freight-change-foot button.primary {
  min-width: 166px;
  border-color: #6da9ca;
  border-bottom-color: #4b8cb0;
  background: linear-gradient(180deg, #edf9ff, #cce9f8);
  color: #1f658f;
  box-shadow: inset 0 1px 0 #fff, 0 2px 0 #94c5de, 0 8px 18px rgba(52, 118, 157, .15);
}

.freight-change-foot button:disabled,
.freight-change-pagination button:disabled {
  opacity: .55;
  transform: none;
  cursor: default;
  box-shadow: none;
}

.freight-change-pagination span {
  color: #647e91;
  font-size: 11px;
  font-weight: 850;
}

.freight-change-loading,
.freight-change-empty {
  min-height: 100%;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 12px;
  color: #5f7b90;
  text-align: center;
}

.freight-change-loading i {
  width: 26px;
  height: 26px;
  border: 3px solid #c9dde9;
  border-top-color: #5fa1c7;
  border-radius: 50%;
  animation: freight-change-spin .8s linear infinite;
}

@keyframes freight-change-spin {
  to { transform: rotate(360deg); }
}

.freight-change-empty i {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid #99c9b9;
  border-radius: 50%;
  background: #edf9f5;
  color: #2e7d6d;
  font-size: 20px;
  font-style: normal;
  box-shadow: 0 8px 18px rgba(44, 115, 97, .1);
}

.freight-change-empty.error i {
  border-color: #dfaaa5;
  background: #fff1f0;
  color: #a6534d;
}

.freight-change-no-items {
  color: #708899;
  padding: 16px 0 5px;
  text-align: center;
  font-size: 12px;
  font-weight: 750;
}

@media (max-width: 1080px) {
  .freight-change-dialog {
    width: calc(100vw - 24px);
    height: calc(100vh - 24px);
    min-height: 0;
  }

  .freight-change-summary {
    grid-template-columns: minmax(280px, 2fr) repeat(5, minmax(62px, .45fr));
  }

  .freight-change-route-head {
    grid-template-columns: 96px minmax(190px, 1fr) minmax(260px, 1.2fr) auto 66px;
  }
}

@media (max-width: 760px) {
  .freight-change-bands .freight-change-item { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .freight-change-bands .freight-change-item > span:first-child { grid-column: 1 / -1; }
  .freight-change-bands .freight-change-item .delta { grid-column: auto; }
  .freight-change-bands [data-band-label]::before { content: attr(data-band-label); display: block; margin-bottom: 3px; color: #71889b; font-size: 10px; font-weight: 700; }
  .freight-change-backdrop { padding: 6px; }
  .freight-change-dialog { width: calc(100vw - 12px); height: calc(100vh - 12px); }
  .freight-change-head { display: grid; grid-template-columns: minmax(0, 1fr); align-items: flex-start; gap: 9px; padding: 14px; }
  .freight-change-head-tools { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) 36px; align-items: end; gap: 8px; }
  .freight-change-head-tools.acknowledgement { grid-template-columns: minmax(0, 1fr); }
  .freight-change-head p { display: none; }
  .freight-change-batch-picker { min-width: 0; }
  .freight-change-batch-picker select { width: 100%; }
  .freight-change-summary { grid-template-columns: repeat(5, 1fr); }
  .freight-change-summary-lead { grid-column: 1 / -1; border-right: 0; padding: 10px 14px; }
  .freight-change-summary-note { overflow-x: auto; padding: 0 12px; white-space: nowrap; }
  .freight-change-toolbar { align-items: stretch; flex-direction: column; gap: 7px; padding: 8px; }
  .freight-change-filters { overflow-x: auto; }
  .freight-change-filters button { white-space: nowrap; }
  .freight-change-search { width: 100%; min-width: 0; }
  .freight-change-body { padding: 8px; }
  .freight-change-route-head { grid-template-columns: 88px minmax(0, 1fr) 60px; gap: 8px; }
  .freight-change-route-meta, .freight-change-review { display: none; }
  .freight-change-item-head { display: none; }
  .freight-change-item { grid-template-columns: 1fr 1fr; gap: 6px 12px; }
  .freight-change-item .delta { grid-column: 1 / -1; }
  .freight-change-foot { padding: 8px; }
  .freight-change-foot button.primary { min-width: 142px; }
}
