@font-face {
  font-family: "Manrope";
  src: url("../public/fonts/manrope-400.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Manrope";
  src: url("../public/fonts/manrope-500.ttf") format("truetype");
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: "Manrope";
  src: url("../public/fonts/manrope-600.ttf") format("truetype");
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: "Manrope";
  src: url("../public/fonts/manrope-700.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

:root {
  color-scheme: light;
  --canvas: #f4f6f2;
  --surface: #ffffff;
  --surface-soft: #f7f8f6;
  --surface-cool: #edf1f5;
  --ink: #151618;
  --muted: #555b62;
  --faint: #666c72;
  --line: #dde1df;
  --line-strong: #c8cdcb;
  --violet: #7800ff;
  --violet-dark: #5d00c8;
  --violet-soft: #f1e7ff;
  --lime: #73f500;
  --danger: #b73642;
  --focus: #111214;
  --radius: 14px;
  --shadow: 0 18px 45px rgba(34, 39, 44, 0.12);
  font-family: "Manrope", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

html {
  background: #c7cbcc;
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: clip;
  background: var(--canvas);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.45;
}

body,
button,
input,
select {
  font: inherit;
}

button,
select,
input {
  color: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

button:not(:disabled),
select:not(:disabled),
input:not(:disabled) {
  cursor: pointer;
}

button:disabled,
select:disabled,
input:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

::selection {
  background: var(--violet);
  color: #fff;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #ecefec;
}

::-webkit-scrollbar-thumb {
  border: 2px solid #ecefec;
  border-radius: 99px;
  background: #9ca19e;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  z-index: 300;
  top: 8px;
  left: 8px;
  padding: 9px 12px;
  border-radius: 8px;
  background: #111214;
  color: #fff;
  transform: translateY(-160%);
  transition: transform 160ms ease-out;
}

.skip-link:focus {
  transform: translateY(0);
}

.icon {
  display: block;
  flex: 0 0 auto;
}

.app-shell {
  min-height: 100vh;
  background: var(--canvas);
}

.topbar {
  position: relative;
  z-index: 20;
  display: grid;
  grid-template-columns: 175px minmax(0, 1fr) auto;
  align-items: center;
  min-height: 64px;
  padding: 9px 28px;
  gap: 14px;
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 9px;
  border: 0;
  background: transparent;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.03em;
}

.brand-mark {
  width: 28px;
  height: 28px;
}

.topnav {
  display: flex;
  min-width: 0;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}

.topnav::-webkit-scrollbar {
  display: none;
}

.nav-pill {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 7px;
  height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.64);
  color: #303236;
  white-space: nowrap;
  transition: background-color 180ms ease-out, color 180ms ease-out;
}

.nav-pill:hover {
  background: #fff;
}

.nav-pill.is-active {
  background: #050506;
  color: #fff;
}

.top-tools,
.heading-actions,
.panel-actions,
.panel-tools,
.gantt-controls,
.dialog-actions {
  display: flex;
  align-items: center;
}

.top-tools {
  gap: 7px;
}

.search-control {
  display: flex;
  align-items: center;
  width: 41px;
  height: 41px;
  padding: 0 11px;
  gap: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  transition: background-color 180ms ease-out;
}

.search-control:focus-within,
.search-control.has-value {
  width: 170px;
  background: #fff;
}

.search-control input {
  width: 112px;
  border: 0;
  outline: 0;
  background: transparent;
  cursor: text;
}

.search-control input::placeholder {
  color: var(--muted);
}

.icon-button {
  position: relative;
  display: inline-grid;
  width: 41px;
  height: 41px;
  flex: 0 0 auto;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.76);
  transition: background-color 160ms ease-out, transform 160ms ease-out;
}

.icon-button:hover:not(:disabled) {
  background: #fff;
  transform: translateY(-1px);
}

.icon-button.small {
  width: 34px;
  height: 34px;
}

.notification-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ed4b3f;
}

.page-heading {
  display: flex;
  min-height: 103px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 19px 30px 13px;
  gap: 24px;
}

.title-cluster {
  display: flex;
  align-items: flex-start;
  gap: 13px;
}

.heading-back {
  margin-top: 2px;
}

.heading-back .icon {
  transform: rotate(180deg);
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 34px;
  line-height: 1.1;
  font-weight: 500;
  letter-spacing: -0.035em;
}

.title-cluster p {
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
}

.demo-inline {
  color: #44494d;
  font-weight: 600;
}

.demo-inline::before {
  margin: 0 6px;
  color: var(--faint);
  content: "·";
}

.heading-actions {
  gap: 8px;
}

.dispatcher-select {
  display: flex;
  align-items: center;
  min-width: 260px;
  height: 43px;
  padding: 0 13px;
  gap: 9px;
  border-radius: 999px;
  background: #fff;
}

.dispatcher-select select {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  appearance: none;
  background: transparent;
}

.avatar {
  display: grid;
  width: 43px;
  height: 43px;
  place-items: center;
  border-radius: 50%;
  background: #dce9df;
  color: #183727;
  font-weight: 700;
}

.button {
  display: inline-flex;
  min-height: 39px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  white-space: nowrap;
  font-weight: 500;
  transition: background-color 160ms ease-out, color 160ms ease-out, transform 160ms ease-out;
}

.button:hover:not(:disabled) {
  transform: translateY(-1px);
}

.button-dark {
  min-height: 43px;
  background: #050506;
  color: #fff;
}

.button-dark:hover:not(:disabled) {
  background: #25262a;
}

.button-light {
  background: #fff;
  color: #414449;
}

.button-light:hover:not(:disabled) {
  background: #f5f6f7;
}

.button-violet {
  background: var(--violet);
  color: #fff;
}

.button-violet:hover:not(:disabled) {
  background: var(--violet-dark);
}

.button-violet-outline {
  border: 1px solid var(--violet);
  background: #fff;
  color: var(--violet-dark);
}

.button-danger,
.button-danger-light {
  color: var(--danger);
}

.button-danger {
  background: #fff;
  box-shadow: inset 0 0 0 1px #e9c9ce;
}

.button-danger-light {
  background: #fff4f5;
}

.popover {
  position: absolute;
  z-index: 80;
  top: 58px;
  right: 28px;
  width: 330px;
  padding: 8px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.popover-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5px 5px 10px 9px;
}

.vehicle-option,
.more-popover button {
  display: flex;
  width: 100%;
  align-items: center;
  border: 0;
  border-radius: 10px;
  background: transparent;
  text-align: left;
}

.vehicle-option {
  min-height: 52px;
  gap: 10px;
  padding: 7px 9px;
}

.vehicle-option:hover,
.more-popover button:hover,
.vehicle-option.is-selected {
  background: var(--surface-soft);
}

.vehicle-option.is-selected {
  box-shadow: inset 0 0 0 1px var(--violet);
}

.vehicle-option-icon {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 50%;
  background: #f0f1ef;
}

.vehicle-option > span:nth-child(2) {
  display: grid;
  flex: 1;
}

.vehicle-option small,
.vehicle-option-state {
  color: var(--muted);
  font-size: 10px;
}

.vehicle-option-state {
  padding-left: 8px;
}

.more-popover {
  width: 230px;
}

.more-popover button {
  min-height: 42px;
  gap: 10px;
  padding: 0 11px;
}

.truck-workspace {
  min-height: 388px;
  padding: 0 28px;
  outline: none;
}

.metrics {
  display: grid;
  width: min(625px, 52vw);
  grid-template-columns: 1.25fr 0.9fr 0.9fr;
  margin-left: clamp(320px, 34vw, 480px);
  gap: 34px;
}

.metric > span {
  color: #373a3e;
  font-size: 12px;
}

.metric > div {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 5px;
}

.metric strong {
  font-size: 24px;
  line-height: 1;
  font-weight: 500;
  letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
}

.metric em {
  padding: 3px 7px;
  border-radius: 999px;
  color: #162013;
  font-size: 10px;
  font-style: normal;
  font-weight: 600;
}

.metric em.positive {
  background: var(--lime);
}

.metric em.violet {
  background: var(--violet);
  color: #fff;
}

.metric small {
  display: block;
  max-width: 230px;
  margin-top: 7px;
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vehicle-context {
  display: flex;
  width: max-content;
  max-width: 390px;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 3px 10px;
  margin-top: -43px;
  padding-left: 54px;
}

.vehicle-context strong {
  font-size: 16px;
}

.vehicle-context > span {
  color: var(--muted);
  font-size: 10px;
}

.vehicle-context .active-window {
  flex-basis: 100%;
}

.truck-scene {
  position: relative;
  height: 329px;
  margin-top: 18px;
}

.truck-pan {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.pan-hint {
  display: none;
}

.truck-canvas {
  position: absolute;
  left: 96px;
  bottom: -2px;
  width: min(1100px, 78vw);
  transform: scale(var(--vehicle-zoom));
  transform-origin: 48% 88%;
  transition: transform 200ms ease-out;
}

.truck-canvas img {
  display: block;
  width: 100%;
  height: auto;
  user-select: none;
}

.trailer-grid {
  position: absolute;
  top: 17.5%;
  left: 29.35%;
  display: grid;
  width: 68.4%;
  height: 39.5%;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 2px;
  padding: 3px;
  border: 1px solid rgba(69, 71, 74, 0.48);
  background: rgba(236, 238, 237, 0.78);
}

.trailer-grid.is-high-contrast {
  border-color: #5e6164;
  background: rgba(224, 227, 225, 0.94);
}

.trailer-slot {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(80, 84, 87, 0.13);
  border-radius: 5px;
  background: rgba(224, 226, 225, 0.88);
  color: #4d5154;
  text-align: left;
  transition: border-color 160ms ease-out, background-color 160ms ease-out, transform 160ms ease-out;
}

.trailer-slot:hover,
.trailer-slot:focus-visible {
  z-index: 2;
  border-color: var(--violet);
  background: rgba(255, 255, 255, 0.97);
}

.trailer-slot:active {
  transform: scale(0.98);
}

.slot-top {
  position: absolute;
  top: 4px;
  right: 5px;
  left: 5px;
  display: flex;
  justify-content: space-between;
  gap: 5px;
  font-size: 10px;
}

.slot-top b {
  font-weight: 600;
}

.slot-top small {
  font-size: inherit;
}

.slot-plus {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  width: 21px;
  height: 21px;
  place-items: center;
  border: 1px solid rgba(65, 68, 71, 0.18);
  border-radius: 50%;
  transform: translate(-50%, -34%);
}

.slot-unit,
.slot-status {
  position: absolute;
  bottom: 4px;
  left: 5px;
  max-width: 46%;
  overflow: hidden;
  font-size: 10px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.slot-status {
  right: 5px;
  left: auto;
  color: var(--muted);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
}

.trailer-slot.is-confirmed {
  background: rgba(245, 245, 244, 0.92);
}

.trailer-slot.is-reserved {
  border-color: var(--violet);
  background: repeating-linear-gradient(135deg, rgba(120, 0, 255, 0.13) 0, rgba(120, 0, 255, 0.13) 6px, rgba(255, 255, 255, 0.95) 6px, rgba(255, 255, 255, 0.95) 12px);
}

.trailer-slot.is-selected {
  z-index: 2;
  border-color: var(--violet);
  box-shadow: inset 0 0 0 1px var(--violet);
}

.vehicle-zoom-controls {
  position: absolute;
  z-index: 6;
  bottom: 24px;
  left: 0;
  display: grid;
  gap: 4px;
  padding: 5px;
  border-radius: 999px;
  background: rgba(226, 229, 226, 0.9);
}

.load-panel {
  position: absolute;
  z-index: 8;
  top: -17px;
  right: 0;
  display: flex;
  width: 365px;
  height: 318px;
  flex-direction: column;
  padding: 15px 14px 12px;
  border-radius: 16px;
  outline: none;
  background: rgba(237, 241, 245, 0.97);
  box-shadow: var(--shadow);
}

.load-panel-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 0 2px;
}

.load-panel-title small {
  color: var(--muted);
  font-size: 10px;
}

.load-panel-title h2 {
  margin-top: 1px;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.025em;
}

.panel-actions {
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.panel-actions .button {
  min-height: 31px;
  padding: 0 10px;
  font-size: 10px;
}

.panel-tools {
  margin-left: auto;
  gap: 4px;
}

.planning-table {
  min-height: 0;
  margin-top: 10px;
  overflow-y: auto;
}

.planning-table-head,
.planning-row {
  display: grid;
  grid-template-columns: minmax(96px, 1.35fr) 0.8fr 0.72fr 104px;
  align-items: center;
  column-gap: 5px;
}

.planning-table-head {
  padding: 0 6px 5px;
  color: #52565a;
  font-size: 10px;
  font-weight: 600;
}

.planning-row {
  min-height: 35px;
  margin: 3px 0;
  padding: 3px 4px 3px 7px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 3px 10px rgba(49, 54, 60, 0.04);
  transition: box-shadow 160ms ease-out, transform 160ms ease-out;
}

[data-density="comfortable"] .planning-row {
  min-height: 43px;
  border-radius: 11px;
}

.planning-row:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 15px rgba(49, 54, 60, 0.08);
}

.planning-row.is-selected {
  box-shadow: inset 0 0 0 1px var(--violet), 0 5px 13px rgba(49, 54, 60, 0.07);
}

.row-main {
  display: grid;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
}

.row-main span {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 5px;
}

.row-main strong,
.row-main small,
.slot-list,
.status-text {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row-main small {
  color: var(--muted);
  font-size: 10px;
}

.slot-list {
  color: #5e6266;
}

.status-text {
  display: inline-flex;
  width: max-content;
  max-width: 100%;
  align-items: center;
  gap: 4px;
  color: #4d5256;
  text-transform: capitalize;
}

.status-text::before {
  width: 5px;
  height: 5px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #7c8287;
  content: "";
}

.status-reserved::before {
  background: var(--violet);
}

.status-confirmed::before {
  background: #4c9c17;
}

.row-actions {
  display: flex;
  justify-content: flex-end;
  gap: 2px;
}

.mini-action {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #f6f7f5;
}

.mini-action:hover:not(:disabled) {
  background: #ebecea;
}

.panel-empty,
.list-empty,
.drawer-empty {
  display: grid;
  place-items: center;
  min-height: 100px;
  padding: 18px;
  color: var(--muted);
  text-align: center;
}

.panel-empty strong,
.list-empty strong {
  color: var(--ink);
  font-weight: 600;
}

.panel-empty span,
.list-empty span {
  font-size: 10px;
}

.dispatch-note {
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 18px;
  margin-top: auto;
  padding-top: 5px;
  color: var(--muted);
  font-size: 10px;
}

.shipment-strip {
  display: flex;
  min-height: 84px;
  margin: 5px 28px 10px;
  gap: 8px;
  overflow-x: auto;
  outline: none;
  scroll-snap-type: x proximity;
}

.shipment-card {
  position: relative;
  display: grid;
  min-width: 245px;
  flex: 1 0 245px;
  grid-template-columns: 1fr 116px;
  align-items: center;
  min-height: 78px;
  padding: 12px 12px 11px 15px;
  overflow: hidden;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.77);
  text-align: left;
  scroll-snap-align: start;
  transition: background-color 160ms ease-out, box-shadow 160ms ease-out;
}

.shipment-card:hover {
  background: #fff;
}

.shipment-card.is-selected {
  background: #fff;
  box-shadow: inset -1px 0 0 var(--violet), inset 0 -1px 0 var(--violet);
}

.shipment-card span {
  z-index: 1;
  display: grid;
  min-width: 0;
}

.shipment-card small {
  color: var(--muted);
  font-size: 10px;
}

.shipment-card strong {
  margin-top: 3px;
  font-size: 13px;
  font-weight: 700;
}

.shipment-card em {
  margin-top: 2px;
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shipment-card img {
  width: 128px;
  height: auto;
  max-width: none;
  transform: translateX(-2px);
  mix-blend-mode: multiply;
}

.strip-empty {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border-radius: 12px;
  background: #fff;
}

.strip-empty button {
  border: 0;
  background: transparent;
  color: var(--violet-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.schedule-workspace {
  display: grid;
  grid-template-columns: 318px minmax(0, 1fr);
  min-height: 310px;
  margin: 0 28px 24px;
  gap: 10px;
  outline: none;
}

.freight-panel,
.gantt-panel {
  min-width: 0;
  overflow: hidden;
  border-radius: 14px;
  background: #fff;
}

.section-toolbar {
  display: flex;
  min-height: 57px;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  gap: 14px;
}

.section-toolbar.compact {
  padding-right: 9px;
}

.section-toolbar h2 {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.025em;
}

.section-toolbar > div:first-child > span {
  color: var(--muted);
  font-size: 10px;
}

.segmented {
  display: flex;
  padding: 3px;
  border-radius: 999px;
  background: #f1f2f0;
}

.segmented button {
  min-height: 28px;
  padding: 0 9px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 10px;
}

.segmented button.is-active {
  background: #fff;
  color: var(--ink);
}

.freight-time-labels {
  display: flex;
  justify-content: space-between;
  padding: 7px 17px 10px;
  color: var(--faint);
  font-size: 10px;
}

.freight-list {
  max-height: 250px;
  padding: 0 11px 12px;
  overflow-y: auto;
}

.freight-row {
  display: grid;
  width: 100%;
  grid-template-columns: 18px minmax(0, 1fr) auto;
  align-items: center;
  min-height: 45px;
  margin-bottom: 7px;
  padding: 5px 9px;
  gap: 8px;
  border: 0;
  border-radius: 8px;
  background: #f2f3f1;
  text-align: left;
}

.freight-row.is-selected {
  box-shadow: inset 0 0 0 1px var(--violet);
  background: var(--violet-soft);
}

.row-check {
  display: grid;
  width: 16px;
  height: 16px;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background: #fff;
}

.freight-row > span:nth-child(2) {
  display: grid;
  grid-template-columns: 17px minmax(0, 1fr);
  align-items: center;
  column-gap: 6px;
}

.freight-row strong {
  font-size: 10px;
}

.freight-row small {
  grid-column: 2;
  color: var(--muted);
  font-size: 10px;
  text-transform: capitalize;
}

.freight-row b {
  font-size: 10px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.gantt-controls {
  gap: 7px;
}

.gantt-controls input {
  height: 34px;
  padding: 0 8px;
  border: 0;
  border-radius: 999px;
  background: #f3f4f2;
  font-size: 10px;
}

.zoom-label {
  min-width: 42px;
  color: var(--muted);
  font-size: 10px;
  text-align: center;
}

.gantt-scroll {
  width: 100%;
  overflow-x: auto;
}

.gantt-canvas {
  position: relative;
  min-width: max(920px, calc(var(--day-count) * 250px));
}

.gantt-header {
  display: grid;
  grid-template-columns: repeat(var(--day-count), 1fr);
  min-height: 62px;
}

.gantt-day {
  display: grid;
  align-content: center;
  gap: 7px;
  padding: 8px 11px;
  border-left: 1px solid #eceeed;
  background: #fafbf9;
}

.gantt-day strong {
  font-size: 10px;
  font-weight: 600;
}

.gantt-day span {
  display: flex;
  justify-content: space-between;
}

.gantt-day i {
  color: var(--faint);
  font-size: 10px;
  font-style: normal;
}

.route-band,
.gantt-row {
  position: relative;
  background-color: #fff;
  background-image: linear-gradient(to right, transparent calc(25% - 1px), #eceeed calc(25% - 1px), #eceeed 25%, transparent 25%);
  background-size: calc(100% / var(--day-count)) 100%;
}

.route-band {
  height: 31px;
  border-top: 1px solid #eceeed;
  border-bottom: 1px solid #eceeed;
}

.route-segment {
  position: absolute;
  top: 6px;
  height: 19px;
  min-width: 44px;
  overflow: hidden;
  border: 0;
  border-radius: 5px;
  color: #303236;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.route-segment.is-violet {
  background: #ddc0ff;
  color: #4d008f;
}

.route-segment.is-grey {
  background: #dbdddc;
}

.gantt-rows {
  position: relative;
}

.gantt-row {
  height: 52px;
  border-bottom: 1px solid #f0f1ef;
}

.gantt-bar {
  position: absolute;
  top: 7px;
  display: flex;
  min-width: 54px;
  height: 38px;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
  padding: 0 11px;
  overflow: hidden;
  border: 0;
  border-radius: 6px;
  background: var(--violet);
  color: #fff;
  text-align: left;
  transition: filter 160ms ease-out, transform 160ms ease-out;
}

.gantt-bar:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.gantt-bar.is-reserved {
  background: repeating-linear-gradient(135deg, var(--violet) 0, var(--violet) 7px, #913bff 7px, #913bff 14px);
}

.gantt-bar.is-selected {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.gantt-bar strong,
.gantt-bar span {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gantt-bar strong {
  font-weight: 600;
}

.outside-range {
  position: absolute;
  top: 18px;
  left: 11px;
  color: var(--faint);
  font-size: 10px;
}

.now-line {
  position: absolute;
  z-index: 3;
  top: 40px;
  bottom: 0;
  width: 1px;
  background: #ff725e;
  pointer-events: none;
}

.now-line span {
  position: absolute;
  top: -16px;
  left: 4px;
  color: #ad3325;
  font-size: 10px;
  font-weight: 600;
}

.drawer-scrim {
  position: fixed;
  z-index: 90;
  inset: 0;
  background: rgba(15, 16, 18, 0.16);
}

.drawer {
  position: fixed;
  z-index: 100;
  top: 12px;
  right: 12px;
  bottom: 12px;
  width: min(390px, calc(100vw - 24px));
  padding: 50px 24px 24px;
  overflow-y: auto;
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow);
}

.drawer-close {
  position: absolute;
  top: 12px;
  right: 12px;
}

.drawer h2 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.03em;
}

.drawer > p {
  max-width: 40ch;
  margin: 8px 0 24px;
  color: var(--muted);
}

.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}

.setting-row span {
  display: grid;
  gap: 3px;
}

.setting-row small {
  color: var(--muted);
}

.setting-row input {
  width: 20px;
  height: 20px;
  accent-color: var(--violet);
}

.drawer .button-danger {
  margin-top: 28px;
}

.alert-list {
  display: grid;
  margin: 0;
  padding: 0;
  gap: 8px;
  list-style: none;
}

.alert-list li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 13px;
  border-radius: 10px;
  background: #fff3e4;
  color: #6b4218;
}

.detail-list {
  margin: 0;
}

.detail-list div,
.record-facts div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.detail-list dt,
.record-facts dt {
  color: var(--muted);
}

.detail-list dd,
.record-facts dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

.demo-label {
  display: block;
  margin-top: 14px;
  color: var(--muted);
}

dialog {
  width: min(680px, calc(100vw - 32px));
  max-height: min(760px, calc(100vh - 32px));
  padding: 0;
  overflow: auto;
  border: 0;
  border-radius: 16px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 26px 80px rgba(21, 23, 26, 0.26);
}

dialog::backdrop {
  background: rgba(18, 20, 22, 0.32);
}

.dialog-form {
  padding: 23px;
}

.dialog-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.dialog-heading h2 {
  margin-top: 3px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.03em;
}

.dialog-heading p {
  margin-top: 6px;
  color: var(--muted);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 13px;
  margin-top: 20px;
}

.field {
  display: grid;
  gap: 6px;
}

.field-wide {
  grid-column: 1 / -1;
}

.field > span,
.slot-picker legend {
  color: #52565b;
  font-size: 10px;
  font-weight: 600;
}

.field input,
.field select {
  width: 100%;
  height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  outline: none;
  background: var(--surface-soft);
  cursor: text;
}

.field select {
  cursor: pointer;
}

.field input:focus,
.field select:focus {
  border-color: var(--violet);
  box-shadow: 0 0 0 3px var(--violet-soft);
}

.unit-summary {
  display: grid;
  align-content: center;
  padding: 9px 12px;
  border-radius: 9px;
  background: var(--surface-cool);
  color: var(--muted);
  font-size: 10px;
}

.unit-summary strong {
  color: var(--ink);
  font-size: 11px;
}

.slot-picker {
  margin: 20px 0 0;
  padding: 0;
  border: 0;
}

.slot-picker legend {
  width: 100%;
  margin-bottom: 8px;
}

.slot-picker legend span {
  float: right;
  color: var(--muted);
  font-weight: 400;
}

.slot-picker > div {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 6px;
}

.slot-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.slot-choice span {
  display: grid;
  height: 36px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface-soft);
  font-size: 10px;
  font-weight: 600;
}

.slot-choice input:checked + span {
  border-color: var(--violet);
  background: var(--violet-soft);
  color: var(--violet-dark);
}

.slot-choice input:focus-visible + span {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.slot-choice.has-load span {
  background: #eceeec;
}

.validation-note {
  margin-top: 10px;
  color: var(--muted);
  font-size: 10px;
}

.form-error {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 16px;
  padding: 10px 12px;
  border-radius: 9px;
  background: #fff0f1;
  color: #852631;
}

.record-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: 18px 0 0;
  border-top: 1px solid var(--line);
}

.record-facts div {
  display: grid;
  gap: 3px;
  padding: 10px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.record-facts div:last-child {
  border-right: 0;
}

.record-facts dd {
  text-align: left;
}

.dialog-actions {
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.toast-stack {
  position: fixed;
  z-index: 200;
  right: 18px;
  bottom: 18px;
  display: grid;
  gap: 8px;
  pointer-events: none;
}

.toast {
  max-width: min(380px, calc(100vw - 36px));
  padding: 11px 14px;
  border-radius: 10px;
  background: #17181a;
  color: #fff;
  box-shadow: 0 12px 30px rgba(16, 18, 20, 0.2);
}

.toast-error {
  background: #8f2b35;
}

@media (max-width: 1180px) {
  .topbar {
    grid-template-columns: 145px minmax(0, 1fr) auto;
    padding-inline: 18px;
  }

  .brand {
    font-size: 16px;
  }

  .nav-pill {
    padding-inline: 12px;
  }

  .page-heading {
    padding-inline: 20px;
  }

  .metrics {
    margin-left: 300px;
  }

  .truck-workspace {
    padding-inline: 20px;
  }

  .truck-canvas {
    left: 68px;
    width: 900px;
  }

  .load-panel {
    width: 340px;
  }

  .shipment-strip,
  .schedule-workspace {
    margin-right: 20px;
    margin-left: 20px;
  }

  .schedule-workspace {
    grid-template-columns: 280px minmax(0, 1fr);
  }
}

@media (max-width: 900px) {
  .topbar {
    grid-template-columns: 1fr auto;
  }

  .topnav {
    grid-column: 1 / -1;
    grid-row: 2;
    padding-bottom: 4px;
  }

  .page-heading {
    flex-wrap: wrap;
  }

  .heading-actions {
    width: 100%;
    flex-wrap: wrap;
    padding-left: 54px;
  }

  .truck-workspace {
    padding: 10px 16px 0;
  }

  .metrics {
    width: 100%;
    margin: 0;
    gap: 14px;
  }

  .vehicle-context {
    margin-top: 18px;
    padding-left: 0;
  }

  .truck-scene {
    height: auto;
  }

  .truck-pan {
    position: relative;
    height: 330px;
    overflow-x: auto;
    overflow-y: hidden;
  }

  .truck-canvas {
    left: 40px;
    width: 920px;
  }

  .load-panel {
    position: relative;
    top: auto;
    right: auto;
    width: 100%;
    height: auto;
    min-height: 285px;
    margin-top: 10px;
  }

  .vehicle-zoom-controls {
    position: sticky;
    z-index: 10;
    left: 4px;
    width: max-content;
    transform: translateY(290px);
  }

  .shipment-strip {
    margin: 12px 16px 10px;
  }

  .schedule-workspace {
    grid-template-columns: 1fr;
    margin: 0 16px 20px;
  }

  .freight-list {
    display: flex;
    max-height: none;
    overflow-x: auto;
  }

  .freight-row {
    min-width: 230px;
    margin-right: 7px;
  }

  .freight-time-labels {
    display: none;
  }
}

@media (max-width: 620px) {
  body {
    font-size: 12px;
  }

  .topbar {
    padding: 8px 12px;
  }

  .brand-mark {
    width: 24px;
    height: 24px;
  }

  .top-tools {
    justify-self: end;
  }

  .search-control:focus-within,
  .search-control.has-value {
    width: 136px;
  }

  .page-heading {
    min-height: 0;
    padding: 17px 12px;
  }

  h1 {
    font-size: 27px;
  }

  .title-cluster p {
    margin-top: 7px;
  }

  .heading-actions {
    padding-left: 0;
  }

  .dispatcher-select {
    min-width: 0;
    flex: 1 1 210px;
  }

  .button-dark span {
    display: none;
  }

  .button-dark {
    width: 43px;
    padding: 0;
  }

  .metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .pan-hint {
    position: sticky;
    z-index: 12;
    top: 8px;
    left: 12px;
    display: flex;
    width: max-content;
    align-items: center;
    gap: 5px;
    padding: 6px 9px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: #4b5054;
    font-size: 10px;
    box-shadow: 0 5px 14px rgba(34, 39, 44, 0.08);
  }

  .metric > div {
    display: grid;
    justify-items: start;
  }

  .metric strong {
    font-size: 18px;
  }

  .metric em {
    font-size: 10px;
  }

  .metric small {
    white-space: normal;
  }

  .planning-table-head,
  .planning-row {
    grid-template-columns: minmax(92px, 1fr) 0.62fr 0.65fr 82px;
  }

  .planning-table {
    overflow-x: auto;
  }

  .planning-row,
  .planning-table-head {
    min-width: 455px;
  }

  .panel-tools {
    width: 100%;
    margin-left: 0;
  }

  .shipment-strip {
    margin-inline: 12px;
  }

  .shipment-card {
    min-width: 260px;
    flex-basis: 260px;
  }

  .schedule-workspace {
    margin-inline: 12px;
  }

  .section-toolbar {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .gantt-controls {
    width: 100%;
  }

  .form-grid,
  .record-facts {
    grid-template-columns: 1fr;
  }

  .slot-picker > div {
    grid-template-columns: repeat(3, 1fr);
  }

  .record-facts div {
    grid-template-columns: 1fr 1fr;
    border-right: 0;
  }

  .dialog-actions .button {
    flex: 1 1 auto;
  }

  .popover {
    right: 12px;
    left: 12px;
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* Phase-two operational workspaces inherit the approved Truck&Co visual system. */
.topnav {
  gap: 3px;
}

.nav-pill {
  min-width: max-content;
  padding-inline: 10px;
  font-size: 11px;
}

.title-cluster p {
  max-width: 78ch;
  text-wrap: pretty;
}

.module-shell {
  margin: 0 28px 28px;
  min-height: 680px;
  overflow: hidden;
  border-radius: 16px;
  background: var(--surface);
}

.module-heading {
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 24px 22px;
  border-bottom: 1px solid var(--line);
}

.module-heading h2,
.module-heading p,
.module-heading h3,
.module-heading h4 {
  margin: 0;
}

.module-heading h2 {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.03em;
}

.module-heading p {
  margin-top: 4px;
  color: var(--muted);
}

.module-actions,
.calendar-controls,
.insight-controls,
.detail-actions,
.detail-title,
.breakdown-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.filter-bar {
  display: flex;
  align-items: end;
  gap: 10px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-soft);
}

.filter-bar label {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
}

.filter-bar select,
.calendar-controls input,
.insight-controls select,
.message-composer select {
  height: 38px;
  min-width: 140px;
  padding: 0 34px 0 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface);
}

.filter-count {
  margin-left: auto;
  padding-bottom: 9px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.shipment-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  min-height: 590px;
}

.shipment-list {
  padding: 10px;
  border-right: 1px solid var(--line);
}

.shipment-list-row {
  display: grid;
  width: 100%;
  min-height: 86px;
  grid-template-columns: minmax(190px, 0.8fr) minmax(260px, 1.5fr) 100px 88px;
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  text-align: left;
  transition: background-color 160ms ease-out, transform 160ms ease-out;
}

.shipment-list-row:hover,
.shipment-list-row.is-selected {
  background: var(--violet-soft);
}

.shipment-list-row:active {
  transform: translateY(1px);
}

.shipment-list-row > b {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.shipment-identity,
.shipment-identity > span,
.shipment-route,
.document-row > span:first-child {
  display: flex;
  min-width: 0;
  align-items: center;
}

.shipment-identity > span,
.shipment-route,
.document-row > span:first-child {
  flex-direction: column;
  align-items: flex-start;
}

.shipment-identity img {
  width: 88px;
  margin-right: 10px;
  mix-blend-mode: multiply;
}

.shipment-list-row strong,
.shipment-list-row small {
  overflow: hidden;
  max-width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shipment-list-row small,
.shipment-list-row em {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
}

.shipment-route strong {
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-badge {
  display: inline-flex;
  width: max-content;
  min-height: 24px;
  align-items: center;
  justify-content: center;
  padding: 3px 8px;
  border-radius: 999px;
  background: #edf0ee;
  color: #424744;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.status-badge.is-planned,
.status-badge.is-reserved,
.status-badge.is-scheduled,
.status-badge.is-uploaded,
.status-badge.is-draft {
  background: var(--violet-soft);
  color: var(--violet-dark);
}

.status-badge.is-in-transit,
.status-badge.is-in-service {
  background: var(--violet);
  color: var(--surface);
}

.status-badge.is-delivered,
.status-badge.is-received,
.status-badge.is-completed,
.status-badge.is-valid {
  background: var(--lime);
  color: #172013;
}

.status-badge.is-cancelled {
  background: #f8e8e9;
  color: var(--danger);
}

.shipment-detail,
.reservation-detail,
.service-detail,
.team-context,
.trip-summary,
.document-preview-panel {
  padding: 22px;
  background: var(--surface-cool);
}

.detail-title {
  justify-content: space-between;
}

.detail-title h3,
.detail-title p,
.detail-section h4,
.team-context h4 {
  margin: 0;
}

.detail-title h3 {
  font-size: 19px;
  letter-spacing: -0.025em;
}

.detail-title p {
  margin-top: 2px;
  color: var(--muted);
}

.route-readout {
  display: grid;
  grid-template-columns: 1fr 42px 1fr;
  align-items: center;
  gap: 10px;
  margin: 24px 0;
}

.route-readout span {
  display: grid;
  gap: 3px;
}

.route-readout small,
.route-readout em {
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
}

.route-readout i {
  height: 1px;
  background: var(--violet);
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 0;
  border-top: 1px solid var(--line-strong);
  border-left: 1px solid var(--line-strong);
}

.detail-grid div {
  padding: 11px;
  border-right: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.detail-grid dt,
.detail-grid dd {
  margin: 0;
}

.detail-grid dt {
  color: var(--muted);
  font-size: 10px;
}

.detail-grid dd {
  margin-top: 3px;
  font-weight: 700;
}

.detail-section {
  margin-top: 22px;
}

.detail-section h4,
.team-context h4 {
  margin-bottom: 9px;
  font-size: 12px;
}

.freight-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.freight-chip-row > span {
  display: grid;
  min-width: 88px;
  padding: 7px 8px;
  border-radius: 7px;
  background: var(--surface);
  font-size: 10px;
  font-weight: 700;
}

.freight-chip-row small {
  color: var(--muted);
  font-size: 10px;
}

.event-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.event-list li {
  display: grid;
  grid-template-columns: 8px 1fr;
  gap: 8px;
  padding: 7px 0;
  border-bottom: 1px solid var(--line-strong);
}

.event-list li > span {
  width: 7px;
  height: 7px;
  margin-top: 5px;
  border-radius: 50%;
  background: var(--violet);
}

.event-list div {
  display: grid;
}

.event-list small,
.muted-copy {
  color: var(--muted);
  font-size: 10px;
}

.detail-actions {
  flex-wrap: wrap;
  margin-top: 20px;
}

.text-action {
  min-height: 34px;
  padding: 0 6px;
  border: 0;
  background: transparent;
  color: var(--violet-dark);
  font-size: 11px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.danger-text {
  color: var(--danger);
}

.module-empty {
  display: grid;
  min-height: 180px;
  place-content: center;
  justify-items: center;
  gap: 5px;
  padding: 24px;
  color: var(--muted);
  text-align: center;
}

.trip-layout {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr) 280px;
  grid-template-rows: minmax(510px, 1fr) auto;
  min-height: 650px;
}

.stop-rail {
  padding: 20px 12px;
  border-right: 1px solid var(--line);
}

.stop-rail h3,
.trip-timeline h3,
.service-schedule h3,
.service-history h3,
.room-list h3,
.chart-title h3,
.breakdown-title h3 {
  margin: 0;
  font-size: 14px;
}

.stop-rail ol {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.stop-rail li {
  position: relative;
  padding: 4px 0 10px;
}

.stop-rail li::after {
  position: absolute;
  top: 38px;
  bottom: -2px;
  left: 17px;
  width: 1px;
  background: var(--line-strong);
  content: "";
}

.stop-rail li:last-child::after {
  display: none;
}

.stop-rail li > button {
  display: grid;
  width: 100%;
  grid-template-columns: 34px 1fr;
  gap: 1px 9px;
  padding: 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  text-align: left;
}

.stop-rail li.is-selected > button {
  background: var(--violet-soft);
}

.stop-rail li > button > span {
  display: grid;
  width: 28px;
  height: 28px;
  grid-row: 1 / 3;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface);
  font-size: 10px;
  font-weight: 700;
}

.stop-rail li.is-complete > button > span {
  border-color: var(--lime);
  background: var(--lime);
}

.stop-rail small {
  color: var(--muted);
  font-size: 10px;
}

.stop-tools {
  display: flex;
  gap: 3px;
  margin: 3px 0 0 50px;
}

.stop-tools button {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: var(--surface-soft);
}

.route-map {
  position: relative;
  container-type: size;
  min-height: 510px;
  overflow: hidden;
  background: #f0f3f1;
}

.route-map::before,
.route-map::after {
  position: absolute;
  border: 1px solid #e1e5e2;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.62);
  content: "";
}

.route-map::before {
  top: 13%;
  left: 19%;
  width: 24%;
  height: 20%;
}

.route-map::after {
  right: 16%;
  bottom: 10%;
  width: 27%;
  height: 25%;
}

.route-map > svg {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
}

.map-roads path {
  fill: none;
  stroke: #d5dad7;
  stroke-width: 1.4;
  vector-effect: non-scaling-stroke;
}

.map-route-line {
  fill: none;
  stroke: var(--violet);
  stroke-width: 3.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.map-note {
  position: absolute;
  z-index: 4;
  top: 16px;
  left: 16px;
  padding: 7px 10px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 10px;
}

.map-stop,
.map-truck {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%);
}

.map-stop {
  width: 30px;
  height: 30px;
  border: 3px solid var(--surface);
  border-radius: 50%;
  background: var(--ink);
  color: var(--surface);
  box-shadow: 0 5px 14px rgba(34, 39, 44, 0.14);
  font-size: 10px;
  font-weight: 700;
}

.map-stop.is-selected {
  background: var(--violet);
}

.map-truck {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--lime);
  color: var(--ink);
  box-shadow: 0 7px 18px rgba(34, 39, 44, 0.2);
}

.map-location-card {
  position: absolute;
  z-index: 4;
  right: 16px;
  bottom: 16px;
  display: grid;
  min-width: 210px;
  gap: 3px;
  padding: 12px;
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.map-location-card span,
.map-location-card button {
  color: var(--muted);
  font-size: 10px;
}

.map-location-card button {
  width: max-content;
  margin-top: 5px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--violet-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.trip-summary {
  border-left: 1px solid var(--line);
}

.trip-summary img {
  width: 100%;
  margin: 10px 0 22px;
  mix-blend-mode: multiply;
}

.trip-summary h3,
.trip-summary dl,
.trip-summary p {
  margin: 0;
}

.trip-summary h3 {
  font-size: 15px;
}

.trip-summary dl {
  margin: 16px 0;
}

.trip-summary dl div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line-strong);
}

.trip-summary dt,
.trip-summary dd {
  margin: 0;
}

.trip-summary dt,
.trip-summary > small {
  color: var(--muted);
  font-size: 10px;
}

.trip-summary dd {
  font-weight: 700;
  text-align: right;
}

.trip-progress {
  height: 6px;
  margin: 20px 0 5px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--line-strong);
}

.trip-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--violet);
}

.trip-summary .button,
.complete-note {
  width: 100%;
  margin-top: 16px;
}

.complete-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 38px;
  border-radius: 999px;
  background: var(--lime);
  font-weight: 700;
}

.trip-timeline {
  grid-column: 1 / -1;
  padding: 18px 22px 22px;
  border-top: 1px solid var(--line);
}

.trip-timeline > div {
  display: flex;
  align-items: start;
  margin-top: 14px;
  overflow-x: auto;
}

.trip-timeline button {
  display: grid;
  min-width: 132px;
  gap: 2px;
  padding: 8px;
  border: 0;
  background: transparent;
  text-align: left;
}

.trip-timeline button > span {
  display: grid;
  width: 24px;
  height: 24px;
  margin-bottom: 5px;
  place-items: center;
  border-radius: 50%;
  background: var(--line);
  font-size: 10px;
}

.trip-timeline button.is-active > span {
  background: var(--violet);
  color: var(--surface);
}

.trip-timeline button small,
.trip-timeline i small {
  color: var(--muted);
  font-size: 10px;
}

.trip-timeline i {
  display: grid;
  min-width: 96px;
  margin-top: 17px;
  padding-top: 10px;
  border-top: 1px solid var(--violet);
  font-size: 10px;
  font-style: normal;
  text-align: center;
}

.route-planner {
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.route-planner-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}

.route-planner-heading h3,
.route-planner-heading p {
  margin: 0;
}

.route-planner-heading h3 {
  font-size: 17px;
}

.route-planner-heading p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.route-planner-controls {
  display: flex;
  align-items: center;
  gap: 7px;
}

.route-planner-controls input {
  width: 148px;
  height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface-soft);
}

.route-calendar-scroll {
  overflow-x: auto;
}

.route-calendar {
  display: grid;
  min-width: 980px;
  grid-template-columns: repeat(7, minmax(140px, 1fr));
}

.route-calendar-day {
  border-right: 1px solid var(--line);
}

.route-calendar-day:last-child {
  border-right: 0;
}

.route-calendar-day > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  min-height: 55px;
  padding: 10px;
  border-bottom: 1px solid var(--line);
}

.route-calendar-day > header span,
.route-calendar-card small,
.route-service-block small {
  color: var(--muted);
  font-size: 10px;
}

.route-calendar-day.is-today > header strong {
  color: var(--violet-dark);
}

.route-day-drop {
  min-height: 190px;
  padding: 8px;
  background: var(--surface-soft);
  transition: background-color 160ms ease-out, box-shadow 160ms ease-out;
}

.route-day-drop.is-dragover {
  background: var(--violet-soft);
  box-shadow: inset 0 0 0 2px var(--violet);
}

.route-calendar-card {
  margin-bottom: 7px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.route-calendar-card.is-selected {
  border-color: var(--violet);
  box-shadow: inset 0 0 0 1px var(--violet);
}

.route-calendar-card.is-movable {
  cursor: grab;
}

.route-calendar-card.is-movable:active {
  cursor: grabbing;
}

.route-calendar-card.is-locked {
  opacity: 0.68;
}

.route-calendar-card > button {
  display: grid;
  width: 100%;
  gap: 7px;
  padding: 10px;
  border: 0;
  border-radius: inherit;
  background: transparent;
  text-align: left;
}

.route-calendar-card > button > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.route-calendar-card b {
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.route-calendar-card .status-badge {
  width: max-content;
  font-style: normal;
}

.route-service-block {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin-bottom: 7px;
  padding: 9px;
  border: 1px solid var(--danger);
  border-radius: 9px;
  background: var(--surface);
  color: var(--danger);
}

.route-service-block span {
  display: grid;
  gap: 2px;
}

.route-day-empty {
  display: grid;
  min-height: 54px;
  place-items: center;
  border: 1px dashed var(--line-strong);
  border-radius: 9px;
  color: var(--faint);
  font-size: 10px;
}

.reservation-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  min-height: 620px;
}

.calendar-controls {
  flex-wrap: wrap;
}

.calendar-controls input {
  min-width: 138px;
}

.reservation-calendar {
  overflow-x: auto;
  padding: 16px;
  border-right: 1px solid var(--line);
}

.reservation-days {
  display: grid;
  min-width: 760px;
  grid-template-columns: repeat(var(--calendar-days), minmax(104px, 1fr));
  margin-left: 42px;
}

.reservation-days > span {
  display: grid;
  gap: 5px;
  padding: 8px;
  border-right: 1px solid var(--line);
}

.reservation-days small {
  color: var(--faint);
  font-size: 10px;
}

.reservation-lanes {
  position: relative;
  min-width: 802px;
  min-height: 494px;
  border-top: 1px solid var(--line);
}

.reservation-lane {
  display: grid;
  min-height: 154px;
  grid-template-columns: 42px 1fr;
  border-bottom: 1px solid var(--line);
}

.reservation-lane > b {
  padding: 12px;
  color: var(--muted);
}

.reservation-lane > div {
  display: grid;
  grid-template-columns: repeat(var(--calendar-days), minmax(104px, 1fr));
}

.reservation-drop {
  border-left: 1px solid var(--line);
  background-color: var(--surface-soft);
}

.reservation-drop:hover {
  background-color: var(--violet-soft);
}

.reservation-block {
  position: absolute;
  z-index: 2;
  top: calc(7px + var(--lane) * 154px + var(--stack) * 46px);
  left: calc(42px + var(--left) * 0.94%);
  display: grid;
  width: calc(var(--width) * 0.94%);
  min-width: 82px;
  height: 40px;
  min-height: 40px;
  gap: 0;
  padding: 5px 8px;
  overflow: hidden;
  border: 0;
  border-radius: 7px;
  background: var(--violet);
  color: var(--surface);
  text-align: left;
}

.reservation-block.is-reserved {
  border: 1px solid var(--violet);
  background: var(--violet-soft);
  color: var(--violet-dark);
}

.reservation-block.is-selected {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.reservation-block span {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reservation-block strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reservation-detail {
  border-left: 0;
}

.drag-hint {
  margin-top: 20px;
  color: var(--muted);
  font-size: 10px;
}

.vehicle-record-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(340px, 1fr) 360px;
  min-height: 470px;
}

.vehicle-profile,
.service-schedule {
  padding: 22px;
  border-right: 1px solid var(--line);
}

.vehicle-profile > img {
  width: 100%;
  max-width: 390px;
  mix-blend-mode: multiply;
}

.vehicle-profile h3,
.vehicle-profile p {
  margin: 0;
}

.vehicle-profile h3 {
  font-size: 22px;
}

.vehicle-profile p {
  color: var(--muted);
}

.availability-marker {
  display: inline-flex;
  margin-top: 10px;
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--lime);
  font-size: 10px;
  font-weight: 700;
}

.vehicle-profile dl {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 24px 0 0;
}

.vehicle-profile dl div {
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}

.vehicle-profile dt,
.vehicle-profile dd {
  margin: 0;
}

.vehicle-profile dt {
  color: var(--muted);
  font-size: 10px;
}

.vehicle-profile dd {
  margin-top: 2px;
  font-weight: 700;
}

.service-row {
  display: grid;
  width: 100%;
  grid-template-columns: 38px 1fr auto;
  align-items: center;
  gap: 9px;
  margin-top: 10px;
  padding: 11px;
  border: 0;
  border-radius: 10px;
  background: var(--surface-soft);
  text-align: left;
}

.service-row.is-selected {
  box-shadow: inset 0 0 0 1px var(--violet);
  background: var(--violet-soft);
}

.service-row > span:nth-child(2) {
  display: grid;
}

.service-row small {
  color: var(--muted);
  font-size: 10px;
}

.service-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: var(--surface);
}

.service-detail > p {
  color: var(--muted);
  font-size: 10px;
}

.service-history {
  padding: 18px 22px 22px;
  border-top: 1px solid var(--line);
}

.history-row {
  display: grid;
  grid-template-columns: 120px 1fr 1fr;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.history-row span,
.history-row small {
  color: var(--muted);
}

.document-tabs {
  width: max-content;
  margin: 12px 18px;
}

.document-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  min-height: 590px;
  border-top: 1px solid var(--line);
}

.document-list {
  padding: 10px;
  border-right: 1px solid var(--line);
}

.document-list-head,
.document-row {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 130px 90px 90px;
  gap: 10px;
  align-items: center;
}

.document-list-head {
  padding: 7px 10px;
  color: var(--muted);
  font-size: 10px;
}

.document-row {
  width: 100%;
  min-height: 64px;
  padding: 8px 10px;
  border: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  text-align: left;
}

.document-row:hover,
.document-row.is-selected {
  background: var(--violet-soft);
}

.document-row > span:first-child {
  position: relative;
  padding-left: 30px;
}

.document-row > span:first-child .icon {
  position: absolute;
  left: 0;
}

.document-row small {
  color: var(--muted);
  font-size: 10px;
}

.document-dropzone {
  display: grid;
  min-height: 110px;
  margin-top: 12px;
  place-content: center;
  justify-items: center;
  border: 1px dashed var(--line-strong);
  border-radius: 10px;
  color: var(--muted);
  text-align: center;
}

.document-dropzone strong {
  margin-top: 5px;
  color: var(--ink);
}

.document-dropzone span {
  font-size: 10px;
}

.document-preview {
  display: grid;
  min-height: 430px;
  margin-top: 16px;
  overflow: hidden;
  place-items: center;
  border-radius: 10px;
  background: var(--surface);
  color: var(--muted);
}

.document-preview img,
.document-preview iframe {
  width: 100%;
  height: 430px;
  border: 0;
  object-fit: contain;
}

.document-preview pre {
  width: 100%;
  height: 430px;
  margin: 0;
  overflow: auto;
  padding: 18px;
  white-space: pre-wrap;
}

.upload-button {
  cursor: pointer;
}

.team-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 310px;
  min-height: 650px;
}

.room-list,
.message-pane {
  border-right: 1px solid var(--line);
}

.room-list {
  padding: 18px 10px;
}

.room-list h3 {
  padding: 0 8px 10px;
}

.room-list > button {
  display: grid;
  width: 100%;
  grid-template-columns: 34px 1fr;
  gap: 1px 8px;
  padding: 9px 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  text-align: left;
}

.room-list > button.is-selected {
  background: var(--violet-soft);
}

.room-list > button > span {
  display: grid;
  width: 31px;
  height: 31px;
  grid-row: 1 / 3;
  place-items: center;
  border-radius: 9px;
  background: var(--ink);
  color: var(--surface);
  font-size: 10px;
  font-weight: 700;
}

.room-list small {
  color: var(--muted);
  font-size: 10px;
}

.message-pane {
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-width: 0;
}

.message-heading {
  display: flex;
  min-height: 70px;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
}

.message-heading h3,
.message-heading p {
  margin: 0;
}

.message-heading p,
.message-heading > span {
  color: var(--muted);
  font-size: 10px;
}

.message-list {
  max-height: 500px;
  overflow-y: auto;
  padding: 16px 18px;
  background: var(--surface-soft);
}

.message {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.contact-avatar,
.contact-row > span {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 9px;
  background: var(--surface-cool);
  font-size: 10px;
  font-weight: 700;
}

.message > div {
  width: fit-content;
  max-width: min(540px, 92%);
  padding: 10px 12px;
  border-radius: 5px 12px 12px;
  background: var(--surface);
}

.message.is-own {
  grid-template-columns: minmax(0, 1fr) 34px;
}

.message.is-own > .contact-avatar {
  grid-column: 2;
}

.message.is-own > div {
  grid-row: 1;
  justify-self: end;
  border-radius: 12px 5px 12px 12px;
  background: var(--violet-soft);
}

.message header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.message time {
  color: var(--muted);
  font-size: 10px;
}

.message p {
  margin: 5px 0 7px;
}

.message div > button {
  margin: 2px 4px 0 0;
  padding: 3px 6px;
  border: 0;
  border-radius: 5px;
  background: var(--surface-cool);
  color: var(--violet-dark);
  font-size: 10px;
}

.message-composer {
  padding: 12px;
  border-top: 1px solid var(--line);
}

.message-composer textarea {
  width: 100%;
  resize: vertical;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
}

.message-composer > div {
  display: flex;
  gap: 6px;
  margin-top: 7px;
}

.message-composer .button {
  margin-left: auto;
}

.team-context h3 {
  margin: 0 0 14px;
}

.context-truck {
  display: grid;
  margin-bottom: 18px;
}

.context-truck img {
  width: 100%;
  mix-blend-mode: multiply;
}

.context-truck span {
  color: var(--muted);
  font-size: 10px;
}

.team-context h4 {
  margin-top: 24px;
}

.contact-row {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 8px;
  margin-top: 9px;
}

.contact-row div {
  display: grid;
}

.contact-row small {
  color: var(--muted);
  font-size: 10px;
}

.demo-only-note {
  padding: 6px 9px;
  border-radius: 999px;
  background: var(--violet-soft);
  color: var(--violet-dark);
  font-size: 10px;
  font-weight: 700;
}

.insight-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  min-height: 420px;
}

.utilization-chart {
  padding: 20px 24px;
  border-right: 1px solid var(--line);
}

.chart-title h3,
.chart-title p {
  margin: 0;
}

.chart-title p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.utilization-chart svg {
  width: 100%;
  height: 300px;
  overflow: visible;
}

.chart-grid line {
  stroke: var(--line);
}

.chart-line {
  fill: none;
  stroke: var(--violet);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.utilization-chart circle {
  fill: var(--surface);
  stroke: var(--violet);
  stroke-width: 4;
}

.utilization-chart text {
  fill: var(--muted);
  font-family: Manrope, sans-serif;
  font-size: 10px;
}

.insight-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--surface-cool);
}

.insight-summary > div {
  display: grid;
  align-content: center;
  padding: 16px;
  border-right: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.insight-summary span,
.insight-summary small {
  color: var(--muted);
  font-size: 10px;
}

.insight-summary strong {
  margin: 4px 0;
  font-size: 22px;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.insight-summary .margin-result {
  grid-column: 1 / -1;
  background: var(--violet);
  color: var(--surface);
}

.insight-summary .margin-result span,
.insight-summary .margin-result small {
  color: rgba(255, 255, 255, 0.78);
}

.tour-breakdown {
  padding: 20px 24px 24px;
  border-top: 1px solid var(--line);
}

.breakdown-title {
  justify-content: space-between;
  margin-bottom: 12px;
}

.breakdown-head,
.breakdown-row {
  display: grid;
  grid-template-columns: minmax(180px, 1.4fr) 100px repeat(5, minmax(88px, 0.7fr));
  align-items: center;
  gap: 9px;
  min-width: 860px;
}

.breakdown-head {
  padding: 7px 10px;
  color: var(--muted);
  font-size: 10px;
}

.breakdown-row {
  width: 100%;
  min-height: 54px;
  padding: 7px 10px;
  border: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  text-align: left;
}

.breakdown-row:hover {
  background: var(--violet-soft);
}

.breakdown-row > span:first-child {
  display: grid;
}

.breakdown-row small {
  color: var(--muted);
  font-size: 10px;
}

.freight-picker {
  margin: 4px 0 0;
  padding: 0;
  border: 0;
}

.freight-picker legend {
  margin-bottom: 8px;
  font-weight: 700;
}

.freight-picker legend span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 400;
}

.freight-picker > div {
  display: grid;
  max-height: 230px;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
  overflow-y: auto;
}

.freight-picker label {
  display: grid;
  grid-template-columns: 18px 1fr;
  align-items: center;
  gap: 7px;
  padding: 8px;
  border-radius: 8px;
  background: var(--surface-soft);
}

.freight-picker label > span {
  display: grid;
}

.freight-picker small {
  color: var(--muted);
  font-size: 10px;
}

.timing-edit-list {
  display: grid;
  max-height: 410px;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  overflow-y: auto;
}

@media (max-width: 1180px) {
  .nav-pill {
    padding-inline: 8px;
    font-size: 10px;
  }

  .shipment-layout,
  .document-layout {
    grid-template-columns: minmax(0, 1fr) 340px;
  }

  .trip-layout {
    grid-template-columns: 210px minmax(0, 1fr) 250px;
  }

  .vehicle-record-layout {
    grid-template-columns: 1fr 1fr;
  }

  .service-detail {
    grid-column: 1 / -1;
    border-top: 1px solid var(--line);
  }

  .team-layout {
    grid-template-columns: 190px minmax(0, 1fr) 270px;
  }
}

@media (max-width: 900px) {
  .module-shell {
    margin-inline: 16px;
  }

  .module-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .module-actions,
  .calendar-controls,
  .insight-controls {
    width: 100%;
  }

  .shipment-layout,
  .reservation-layout,
  .document-layout,
  .insight-top {
    grid-template-columns: 1fr;
  }

  .shipment-list,
  .reservation-calendar,
  .document-list,
  .utilization-chart {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .trip-layout {
    grid-template-columns: 190px minmax(520px, 1fr);
    overflow-x: auto;
  }

  .trip-summary {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 190px 1fr;
    gap: 12px;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .trip-summary img {
    grid-row: 1 / 6;
  }

  .trip-timeline {
    grid-column: 1 / -1;
  }

  .vehicle-record-layout,
  .team-layout {
    grid-template-columns: 1fr;
  }

  .vehicle-profile,
  .service-schedule,
  .room-list,
  .message-pane {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .room-list {
    display: flex;
    overflow-x: auto;
  }

  .room-list h3 {
    display: none;
  }

  .room-list > button {
    min-width: 180px;
  }

  .team-context {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .team-context h3,
  .team-context h4 {
    grid-column: 1 / -1;
  }

  .tour-breakdown {
    overflow-x: auto;
  }

  .route-planner-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .route-planner-controls {
    width: 100%;
  }
}

@media (max-width: 620px) {
  .module-shell {
    margin: 0 10px 18px;
    min-height: 0;
    border-radius: 12px;
  }

  .module-heading {
    min-height: 0;
    gap: 14px;
    padding: 16px;
  }

  .module-heading h2 {
    font-size: 20px;
  }

  .module-actions,
  .insight-controls,
  .message-composer > div {
    align-items: stretch;
    flex-direction: column;
  }

  .calendar-controls {
    display: grid;
    width: 100%;
    grid-template-columns: 34px minmax(0, 1fr) 34px;
    align-items: center;
  }

  .calendar-controls input {
    width: 100%;
    min-width: 0;
  }

  .calendar-controls .segmented,
  .calendar-controls > .button {
    grid-column: 1 / -1;
  }

  .route-planner-heading {
    padding: 16px;
  }

  .route-planner-controls {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) 34px;
  }

  .route-planner-controls input {
    width: 100%;
    min-width: 0;
  }

  .route-planner-controls > .button {
    grid-column: 1 / -1;
  }

  .route-calendar {
    min-width: 840px;
    grid-template-columns: repeat(7, 120px);
  }

  .module-actions .button-dark {
    width: auto;
    padding-inline: 16px;
  }

  .filter-bar {
    align-items: stretch;
    flex-wrap: wrap;
  }

  .filter-bar label {
    flex: 1 1 130px;
  }

  .filter-count {
    width: 100%;
    margin-left: 0;
  }

  .shipment-list {
    overflow-x: auto;
  }

  .shipment-list-row {
    min-width: 720px;
  }

  .shipment-detail,
  .reservation-detail,
  .service-detail,
  .team-context,
  .trip-summary,
  .document-preview-panel {
    padding: 16px;
  }

  .trip-layout {
    display: block;
    overflow: visible;
  }

  .stop-rail {
    padding: 16px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .stop-rail ol {
    display: flex;
    gap: 7px;
    overflow-x: auto;
  }

  .stop-rail li {
    min-width: 176px;
  }

  .stop-rail li::after {
    display: none;
  }

  .route-map {
    min-height: 390px;
  }

  .trip-summary {
    grid-template-columns: 1fr;
  }

  .trip-summary img {
    grid-row: auto;
  }

  .vehicle-record-layout {
    grid-template-columns: 1fr;
  }

  .vehicle-profile,
  .service-schedule {
    padding: 16px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .history-row {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .document-layout {
    display: block;
  }

  .document-list {
    overflow-x: auto;
  }

  .document-list-head,
  .document-row {
    min-width: 680px;
  }

  .team-context {
    display: block;
  }

  .message-list {
    max-height: 430px;
  }

  .message-composer select,
  .message-composer .button,
  .insight-controls select {
    width: 100%;
  }

  .message-composer .button {
    margin-left: 0;
  }

  .insight-summary {
    grid-template-columns: 1fr;
  }

  .insight-summary .margin-result {
    grid-column: auto;
  }

  .utilization-chart {
    overflow-x: auto;
  }

  .utilization-chart svg {
    min-width: 620px;
  }

  .freight-picker > div,
  .timing-edit-list {
    grid-template-columns: 1fr;
  }
}
