:root {
  color-scheme: light;
  --ink: #17202a;
  --muted: #667085;
  --line: #d7dde6;
  --panel: #ffffff;
  --surface: #f4f6f8;
  --nav: #18212f;
  --nav-soft: #263244;
  --blue: #2368b4;
  --green: #11845b;
  --amber: #b26a00;
  --red: #b42318;
  --violet: #7357c8;
  --radius: 8px;
  font-family: "Segoe UI", Arial, sans-serif;
}

html {
  height: 100%;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  height: 100%;
  min-height: 100vh;
  overflow: hidden;
  background: var(--surface);
  color: var(--ink);
}

.flow-marker-definitions {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
  pointer-events: none;
}

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

.app-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  height: 100%;
  min-height: 100vh;
}

.network-view.active .network-layout {
  flex: 1 1 auto;
  height: auto;
  min-height: 0;
}

.network-view.active .network-stage {
  min-height: 0;
}

.network-workspace-fullscreen .network-view.active {
  position: fixed;
  z-index: 2100;
  inset: 0;
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: #f4f6f8;
  padding: 8px;
}

.network-workspace-fullscreen .network-toolbar {
  border-radius: 6px 6px 0 0;
}

.network-workspace-fullscreen .network-layout {
  border-radius: 0 0 6px 6px;
}

.sidebar {
  display: none;
  flex-direction: column;
  gap: 24px;
  background: var(--nav);
  color: #fff;
  padding: 22px 18px;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: var(--radius);
  background: #2f7f75;
  font-weight: 800;
}

.brand-block h1,
.brand-block p,
.topbar h2,
.topbar p,
.panel h3 {
  margin: 0;
}

.brand-block h1 {
  font-size: 18px;
  line-height: 1.15;
}

.brand-block p {
  color: #b9c6d3;
  font-size: 13px;
  margin-top: 3px;
}

.nav-list {
  display: grid;
  gap: 8px;
}

.nav-item,
.ghost-button,
.primary-button,
.secondary-button,
.icon-button,
.quick-choice {
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
}

.nav-item {
  min-height: 40px;
  padding: 0 12px;
  text-align: left;
  color: #dce5ef;
  background: transparent;
}

.nav-item.active,
.nav-item:hover {
  background: var(--nav-soft);
  color: #fff;
}

.sidebar-actions,
.data-tools {
  display: grid;
  gap: 8px;
}

.sidebar-actions {
  margin-top: auto;
}

.ghost-button {
  display: grid;
  place-items: center;
  min-height: 38px;
  color: #e6eef7;
  background: rgba(255, 255, 255, 0.08);
}

.ghost-button:hover {
  background: rgba(255, 255, 255, 0.14);
}

.file-button {
  text-align: center;
}

.data-tools {
  border-top: 1px solid rgba(255, 255, 255, 0.13);
  padding-top: 14px;
}

.data-tools label {
  color: #b9c6d3;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.data-tools select {
  width: 100%;
  border-color: rgba(255, 255, 255, 0.14);
  background: var(--nav-soft);
  color: #fff;
}

#importJson,
#importCsv {
  display: none;
}

.workspace {
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  padding: 24px;
}

.topbar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.eyebrow {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.topbar h2 {
  font-size: 28px;
}

.topbar-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.save-status {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  padding: 0 10px;
  white-space: nowrap;
}

input,
select,
textarea {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 0 10px;
}

textarea {
  min-height: 76px;
  padding: 9px 10px;
  resize: vertical;
}

input[type="search"] {
  width: min(36vw, 420px);
}

#statusFilter {
  width: 178px;
}

#clearFilters {
  min-width: 62px;
}

.primary-button {
  min-height: 38px;
  padding: 0 14px;
  color: #fff;
  background: var(--blue);
  font-weight: 700;
}

.primary-button:hover {
  background: #1b5799;
}

.secondary-button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-weight: 700;
}

.secondary-button:hover {
  background: #f3f6f9;
}

.icon-button {
  min-width: 38px;
  min-height: 34px;
  padding: 0 10px;
  background: #edf1f5;
  color: var(--ink);
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.metric {
  min-height: 106px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 16px;
}

.metric span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.metric strong {
  display: block;
  margin-top: 12px;
  font-size: 28px;
}

.metric small {
  display: block;
  color: var(--muted);
  margin-top: 6px;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.6fr);
  gap: 16px;
  margin-bottom: 16px;
}

.data-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 16px;
  align-items: start;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 16px;
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.panel h3 {
  font-size: 17px;
}

.count-pill,
.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 0 9px;
  background: #eef2f6;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.shipment-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 10px;
}

.board-column {
  min-height: 260px;
  border: 1px solid #e2e7ee;
  border-radius: var(--radius);
  background: #f8fafc;
  padding: 10px;
}

.board-column h4 {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
}

.shipment-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 10px;
  margin-bottom: 8px;
}

.shipment-card strong {
  display: block;
  font-size: 14px;
}

.shipment-card span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 5px;
}

.inline-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin-bottom: 12px;
}

.task-list {
  display: grid;
  gap: 8px;
}

.task-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 9px;
  align-items: center;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 10px;
}

.task-row.done span {
  color: var(--muted);
  text-decoration: line-through;
}

.risk-panel,
.quality-panel,
.timeline-panel,
.sku-balance-panel {
  margin-top: 0;
}

.risk-list,
.quality-list,
.timeline-list {
  display: grid;
  gap: 8px;
}

.risk-item,
.quality-item,
.timeline-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 9px 10px;
}

.risk-dot,
.quality-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--blue);
}

.risk-item.high .risk-dot {
  background: var(--red);
}

.risk-item.medium .risk-dot {
  background: var(--amber);
}

.risk-item.low .risk-dot {
  background: var(--blue);
}

.quality-item.error .quality-dot {
  background: var(--red);
}

.quality-item.warning .quality-dot {
  background: var(--amber);
}

.quality-item.info .quality-dot {
  background: var(--blue);
}

.risk-item strong,
.quality-item strong,
.timeline-item strong {
  display: block;
  font-size: 14px;
}

.risk-item span,
.quality-item span,
.timeline-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 3px;
}

.risk-type,
.quality-type,
.timeline-date {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.timeline-date span {
  display: block;
  margin-top: 3px;
  text-align: right;
  text-transform: none;
}

.timeline-tag {
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 26px;
  border-radius: 999px;
  background: #e8f1fb;
  color: var(--blue);
  font-size: 11px;
  font-weight: 900;
}

.timeline-item.overdue .timeline-tag {
  background: #fde8e5;
  color: var(--red);
}

.timeline-item.soon .timeline-tag {
  background: #fff4dd;
  color: var(--amber);
}

.empty-state {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

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

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 820px;
}

.compact-table {
  min-width: 640px;
}

th,
td {
  border-bottom: 1px solid #e6ebf1;
  padding: 11px 10px;
  text-align: left;
  font-size: 14px;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

tbody tr:hover {
  background: #f7f9fb;
}

.table-empty {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.note-cell {
  max-width: 220px;
  color: var(--muted);
  font-size: 13px;
}

.action-cell {
  display: flex;
  gap: 7px;
  min-width: 132px;
}

.table-action {
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  padding: 0 9px;
}

.table-action:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.table-action.danger:hover {
  border-color: var(--red);
  color: var(--red);
}

.record-form {
  display: grid;
  gap: 11px;
}

.record-form label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.record-form button {
  margin-top: 4px;
}

.status-green {
  background: #e7f6ef;
  color: var(--green);
}

.status-amber {
  background: #fff4dd;
  color: var(--amber);
}

.status-red {
  background: #fde8e5;
  color: var(--red);
}

.status-blue {
  background: #e8f1fb;
  color: var(--blue);
}

.status-violet {
  background: #f0ecff;
  color: var(--violet);
}

dialog {
  border: 0;
  border-radius: var(--radius);
  padding: 0;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.22);
}

dialog::backdrop {
  background: rgba(17, 24, 39, 0.36);
}

.dialog-card {
  width: min(520px, calc(100vw - 32px));
  padding: 18px;
  background: #fff;
}

.inquiry-maker-dialog {
  width: min(960px, calc(100vw - 32px));
  padding: 0;
}

.inquiry-maker-dialog > .panel-heading,
.inquiry-maker-footer {
  padding: 16px 18px;
}

.inquiry-maker-dialog > .panel-heading {
  border-bottom: 1px solid var(--line);
}

.inquiry-maker-body {
  max-height: min(680px, calc(100vh - 190px));
  overflow-y: auto;
  padding: 0 18px;
}

.inquiry-maker-section {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.inquiry-maker-section:last-child {
  border-bottom: 0;
}

.inquiry-maker-section h4 {
  margin: 0 0 11px;
  color: var(--ink);
  font-size: 12px;
  text-transform: uppercase;
}

.inquiry-maker-grid {
  display: grid;
  gap: 11px;
}

.inquiry-maker-grid.two-columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

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

.inquiry-maker-grid label {
  display: grid;
  gap: 5px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.inquiry-maker-grid .span-two {
  grid-column: span 2;
}

.inquiry-maker-heading,
.inquiry-maker-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.inquiry-maker-heading h4 {
  margin-bottom: 0;
}

.compact-command {
  min-height: 30px;
  padding: 0 9px;
  font-size: 11px;
}

.inquiry-entity-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 20px;
}

.inquiry-flow-builder {
  overflow-x: auto;
  border: 1px solid #d7dde6;
  background: #f8fafb;
  padding: 10px;
  scrollbar-width: thin;
}

.inquiry-flow-track {
  display: flex;
  align-items: stretch;
  gap: 8px;
  min-width: max-content;
}

.inquiry-flow-fixed,
.inquiry-flow-step {
  display: grid;
  align-content: center;
  min-height: 68px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #fff;
}

.inquiry-flow-fixed {
  position: relative;
  width: 132px;
  padding: 9px 10px;
}

.inquiry-flow-fixed::after,
.inquiry-flow-zone::after {
  position: absolute;
  top: 50%;
  right: -9px;
  color: #98a2b3;
  content: "\203A";
  font-size: 20px;
  transform: translate(50%, -50%);
}

.inquiry-flow-fixed:last-child::after {
  display: none;
}

.inquiry-flow-fixed small,
.inquiry-flow-fixed strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.inquiry-flow-fixed small {
  color: #667085;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
}

.inquiry-flow-fixed strong {
  margin-top: 3px;
  font-size: 11px;
}

.inquiry-flow-fixed .fi,
.inquiry-flow-fixed > .fa-solid {
  position: absolute;
  right: 8px;
  bottom: 7px;
  width: 18px;
}

.inquiry-flow-zone {
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 90px;
  min-height: 82px;
  border: 1px dashed #aeb9c6;
  background: #fff;
  padding: 18px 7px 7px;
}

.inquiry-flow-zone-label {
  position: absolute;
  top: 4px;
  left: 7px;
  color: #667085;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.inquiry-flow-zone:has(.inquiry-flow-step) {
  border-style: solid;
}

.inquiry-flow-step {
  grid-template-columns: 20px minmax(72px, 112px) 20px;
  align-items: center;
  gap: 5px;
  min-width: 132px;
  padding: 7px;
  cursor: grab;
}

.inquiry-flow-step > i {
  color: #475467;
}

.inquiry-flow-step strong,
.inquiry-flow-step small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.inquiry-flow-step strong {
  font-size: 10px;
}

.inquiry-flow-step small {
  margin-top: 3px;
  color: #667085;
  font-size: 8px;
}

.inquiry-flow-step small .fi {
  width: 15px;
}

.inquiry-flow-step button,
.inquiry-flow-add {
  display: grid;
  place-items: center;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.inquiry-flow-step button {
  width: 20px;
  height: 20px;
  color: #b42318;
}

.inquiry-flow-step button .lucide,
.inquiry-flow-add .lucide {
  width: 14px;
  height: 14px;
}

.inquiry-flow-add {
  width: 32px;
  height: 32px;
  border: 1px solid #cbd5e1;
  border-radius: 50%;
  background: #fff;
  color: #2368b4;
}

.maker-country-group {
  display: grid;
  align-content: start;
  gap: 3px;
}

.maker-country-heading {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 27px;
  color: var(--ink);
  font-size: 11px;
  font-weight: 800;
}

.maker-country-heading .fi {
  width: 20px;
  box-shadow: 0 0 0 1px rgba(23, 32, 42, 0.14);
}

.maker-entity-option {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  width: 100%;
  border: 0;
  border-bottom: 1px solid #edf0f4;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  padding: 4px 0;
  text-align: left;
}

.maker-entity-option > i {
  color: #566576;
  text-align: center;
}

.maker-entity-option strong,
.maker-entity-option small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.maker-entity-option strong {
  font-size: 11px;
}

.maker-entity-option small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.inquiry-draft-list {
  display: grid;
  gap: 4px;
  margin-top: 10px;
}

.inquiry-draft-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  border-top: 1px solid #edf0f4;
  color: var(--ink);
  font-size: 11px;
}

.inquiry-draft-row small {
  display: block;
  color: var(--muted);
  font-size: 9px;
}

.draft-remove-button {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: var(--red);
  cursor: pointer;
}

.inquiry-maker-footer {
  border-top: 1px solid var(--line);
  background: #fff;
}

.inquiry-maker-footer .primary-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
}

.inquiry-maker-footer .lucide {
  width: 16px;
  height: 16px;
}

.inquiry-maker-message {
  color: var(--red);
  font-size: 11px;
  font-weight: 700;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.quick-choice {
  min-height: 70px;
  border: 1px solid var(--line);
  background: #f8fafc;
  color: var(--ink);
  font-weight: 800;
}

.quick-choice:hover {
  border-color: var(--blue);
  background: #eef6ff;
}

.network-view {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
}

.network-view.active {
  display: flex;
  flex-direction: column;
}

.network-toolbar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  min-height: 48px;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: var(--radius) var(--radius) 0 0;
  background: var(--panel);
  padding: 7px 10px;
}

.mode-switch {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #edf1f5;
  padding: 2px;
}

.mode-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 32px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 0 11px;
  font-weight: 700;
}

.mode-button.active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(23, 32, 42, 0.12);
}

.mode-button .lucide,
.icon-tool .lucide,
.icon-button .lucide {
  width: 16px;
  height: 16px;
  stroke-width: 2;
}

.network-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.network-filter select {
  width: min(300px, 28vw);
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
}

.inquiry-filter-group {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 8px;
  flex: 1 1 420px;
}

.inquiry-filter-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.link-mode-field {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  white-space: nowrap;
}

.link-mode-field select {
  width: 104px;
  min-height: 32px;
  padding: 0 25px 0 8px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  text-transform: none;
}

.edge-edit-controls {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-left: 1px solid var(--line);
  padding-left: 8px;
}

.edge-edit-controls label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.edge-edit-controls input {
  width: 56px;
  min-height: 32px;
  padding: 0 6px;
  text-align: center;
}

.edge-arrow-controls {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 2px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f7f9fb;
}

.edge-arrow-controls .icon-tool {
  width: 30px;
  height: 28px;
  min-height: 28px;
}

.edge-arrow-controls .icon-tool.active {
  border-color: #3f3568;
  background: #4f3f78;
  color: #fff;
}

.inquiry-chips,
.country-chips {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.inquiry-chips::-webkit-scrollbar,
.country-chips::-webkit-scrollbar {
  display: none;
}

.inquiry-chip,
.country-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 32px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--muted);
  cursor: pointer;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 700;
}

.inquiry-chip.active,
.country-chip.active {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

.inquiry-chip-number {
  display: inline-grid;
  place-items: center;
  min-width: 22px;
  height: 20px;
  border-radius: 4px;
  background: #eef1f5;
  color: #344054;
  font-size: 10px;
  font-weight: 900;
}

.inquiry-chip.active .inquiry-chip-number {
  background: #fff;
  color: #171a1f;
}

.country-chips {
  margin: 4px 0 12px;
  padding-bottom: 4px;
}

.country-chip {
  min-width: 36px;
  min-height: 30px;
  padding: 0 8px;
}

.country-chip .fi,
.stakeholder-row .fi,
.flow-node-flag .fi {
  box-shadow: 0 0 0 1px rgba(23, 32, 42, 0.12);
}

.network-count {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.canvas-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.icon-tool {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
}

.compact-tool {
  width: 30px;
  height: 30px;
  flex-basis: 30px;
}

.icon-tool:hover {
  border-color: #9caabc;
  background: #f5f7f9;
}

.icon-tool[aria-pressed="true"] {
  border-color: #2368b4;
  background: #eaf3fb;
  color: #174f87;
}

.danger-tool {
  color: var(--red);
}

[data-tooltip]::after {
  position: absolute;
  z-index: 30;
  right: 0;
  top: calc(100% + 7px);
  display: none;
  width: max-content;
  max-width: 180px;
  border-radius: 4px;
  background: var(--nav);
  color: #fff;
  content: attr(data-tooltip);
  font-size: 11px;
  font-weight: 600;
  padding: 5px 7px;
  pointer-events: none;
}

[data-tooltip]:hover::after,
[data-tooltip]:focus-visible::after {
  display: block;
}

.network-layout {
  --library-width: 265px;
  position: relative;
  display: grid;
  grid-template-columns: var(--library-width) minmax(0, 1fr);
  flex: 1 1 auto;
  min-height: 0;
  height: auto;
  border: 1px solid var(--line);
  background: var(--panel);
  overflow: hidden;
}

.node-library,
.node-inspector {
  min-width: 0;
  background: #fff;
  padding: 12px;
  overflow-y: auto;
}

.node-library {
  border-right: 1px solid var(--line);
}

.network-layout.library-collapsed {
  grid-template-columns: minmax(0, 1fr);
}

.network-layout.library-collapsed .node-library {
  display: none;
}

.library-collapse-toggle {
  flex: 0 0 auto;
}

.library-collapse-toggle .lucide {
  width: 16px;
  height: 16px;
}

.node-inspector {
  border-left: 1px solid var(--line);
}

.side-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 32px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.inquiry-library-section {
  margin-bottom: 9px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 9px;
}

.inquiry-library {
  display: grid;
  gap: 4px;
  max-height: 252px;
  overflow-y: auto;
  padding-right: 3px;
}

.inquiry-library-item {
  display: grid;
  gap: 3px;
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  padding: 6px 7px;
  text-align: left;
}

.inquiry-library-item:hover,
.inquiry-library-item:focus-visible {
  border-color: #8ea1b8;
  background: #f6f8fa;
}

.inquiry-library-item.active {
  border-color: #2368b4;
  background: #eef6ff;
  box-shadow: inset 3px 0 0 #2368b4;
}

.inquiry-library-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 8px;
}

.inquiry-library-header strong {
  min-width: 0;
  font-size: 11px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.inquiry-library-header > span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.inquiry-chip-state,
.inquiry-library-state,
.quote-state {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
}

.inquiry-chip-state.valid,
.inquiry-library-state.valid,
.quote-state.valid {
  color: var(--green);
}

.inquiry-chip-state.expired,
.inquiry-library-state.expired,
.quote-state.expired {
  color: var(--amber);
}

.inquiry-chip-state.not-quoted,
.inquiry-library-state.not-quoted,
.quote-state.not-quoted {
  color: var(--red);
}

.inquiry-chip.active .inquiry-chip-state {
  color: #fff;
}

.inquiry-library-header small,
.inquiry-library-lane {
  color: var(--muted);
  font-size: 9px;
  line-height: 1.25;
}

.inquiry-library-lane {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.inquiry-mini-flow {
  display: flex;
  align-items: flex-start;
  gap: 2px;
  min-width: 0;
  overflow-x: auto;
  padding: 1px 0 2px;
  scrollbar-width: none;
}

.inquiry-mini-flow::-webkit-scrollbar {
  display: none;
}

.inquiry-mini-entity {
  display: grid;
  justify-items: center;
  gap: 0;
  width: 27px;
  flex: 0 0 27px;
}

.inquiry-mini-icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 23px;
  height: 23px;
  border: 1px solid currentColor;
  border-radius: 50%;
  background: #fff;
  font-size: 11px;
}

.inquiry-mini-icon .fi {
  position: absolute;
  right: -5px;
  bottom: -2px;
  width: 10px;
  border: 1px solid #fff;
  box-shadow: 0 0 0 1px rgba(23, 32, 42, 0.16);
}

.inquiry-mini-entity small {
  display: none;
}

.inquiry-mini-arrow {
  flex: 0 0 auto;
  margin-top: 7px;
  color: #9aa5b3;
  font-size: 7px;
}

.inquiry-stakeholder-dialog {
  width: min(1040px, calc(100vw - 48px));
  max-width: none;
  max-height: min(760px, calc(100vh - 48px));
  padding: 0;
  overflow: hidden;
}

.inquiry-stakeholder-dialog > .panel-heading {
  padding: 16px 18px;
}

.dialog-eyebrow {
  display: block;
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.stakeholder-assignment-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  min-height: 520px;
  border-top: 1px solid var(--line);
}

.stakeholder-assignment-panel {
  min-width: 0;
  padding: 16px;
  overflow: hidden;
}

.stakeholder-assignment-panel + .stakeholder-assignment-panel {
  border-left: 1px solid var(--line);
  background: #f7f9fb;
}

.assignment-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.assignment-heading strong {
  font-size: 13px;
}

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

.stakeholder-assignment-grid,
.inquiry-stakeholder-box {
  display: grid;
  align-content: start;
  gap: 14px;
  max-height: 460px;
  overflow-y: auto;
  padding: 3px;
}

.inquiry-stakeholder-box {
  min-height: 430px;
  border: 2px dashed #aab5c3;
  border-radius: 6px;
  background: #fff;
  padding: 10px;
}

.inquiry-stakeholder-box:empty {
  background: #f4f8fc;
}

.assignment-stage-group {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.assignment-stage-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 27px;
  border-bottom: 1px solid #dfe5ec;
  color: #334155;
}

.assignment-stage-title {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.assignment-stage-title i {
  width: 15px;
  color: #64748b;
  text-align: center;
}

.assignment-stage-count {
  display: grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  border-radius: 10px;
  background: #e8edf3;
  color: #475569;
  font-size: 9px;
  font-weight: 800;
}

.assignment-stage-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
  gap: 8px;
}

.stakeholder-assignment-card {
  position: relative;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px;
  min-width: 0;
  min-height: 54px;
  border: 1px solid #d8dee7;
  border-radius: 6px;
  background: #fff;
  padding: 7px;
}

.stakeholder-assignment-card[draggable="true"] {
  cursor: grab;
}

.stakeholder-assignment-card[draggable="true"]:active {
  cursor: grabbing;
}

.stakeholder-assignment-card.assigned {
  padding-right: 27px;
}

.assignment-card-icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  font-size: 18px;
}

.assignment-card-icon.factory,
.assignment-card-icon.shipper { color: #c84032; }
.assignment-card-icon.port { color: #1769aa; }
.assignment-card-icon.airport { color: #8a4f9e; }
.assignment-card-icon.rail_terminal,
.assignment-card-icon.depot { color: #54606f; }
.assignment-card-icon.warehouse { color: #087a6b; }
.assignment-card-icon.trader { color: #8053a6; }
.assignment-card-icon.company { color: #2f6f63; }
.assignment-card-icon.bank { color: #3f6f4f; }
.assignment-card-icon.importer { color: #234d7d; }
.assignment-card-icon.agent { color: #a15f00; }
.assignment-card-icon.consignee { color: #145d8c; }

.assignment-card-copy {
  min-width: 0;
}

.assignment-card-copy strong,
.assignment-card-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.assignment-card-copy strong {
  font-size: 11px;
}

.assignment-card-copy small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.stakeholder-assignment-card > .fi {
  width: 17px;
}

.assignment-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border: 0;
  background: transparent;
  color: #9b2c2c;
  cursor: pointer;
}

.assignment-empty {
  grid-column: 1 / -1;
  align-self: center;
  justify-self: center;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.inquiry-mini-icon.factory { color: #c84032; }
.inquiry-mini-icon.port { color: #1769aa; }
.inquiry-mini-icon.airport { color: #8a4f9e; }
.inquiry-mini-icon.rail_terminal { color: #495765; }
.inquiry-mini-icon.depot { color: #54606f; }
.inquiry-mini-icon.warehouse { color: #087a6b; }
.inquiry-mini-icon.trader { color: #8053a6; }
.inquiry-mini-icon.company { color: #2f6f63; }
.inquiry-mini-icon.bank { color: #3f6f4f; }
.inquiry-mini-icon.importer { color: #234d7d; }
.inquiry-mini-icon.agent { color: #a15f00; }
.inquiry-mini-icon.consignee { color: #145d8c; }
.inquiry-mini-icon.inquiry { color: #b42318; }

.inquiry-mini-empty {
  color: var(--muted);
  font-size: 10px;
  padding: 5px 0;
}

.node-palette {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

.side-heading-actions {
  display: flex;
  align-items: center;
  gap: 5px;
}

.side-command {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  border: 1px solid #cfd8e3;
  border-radius: 5px;
  background: #fff;
  color: #344054;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
  padding: 4px 7px;
}

.side-command:hover,
.side-command:focus-visible {
  border-color: #7d91aa;
  background: #f1f5f9;
  color: #173f68;
}

.entity-template-group {
  display: grid;
  gap: 6px;
}

.entity-template-group + .entity-template-group {
  border-top: 1px solid var(--line);
  padding-top: 11px;
}

.entity-template-group h5 {
  margin: 0;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
}

.stakeholder-library {
  display: grid;
  gap: 16px;
}

.stakeholder-country-section {
  display: grid;
  gap: 9px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}

.stakeholder-country-section:last-child {
  border-bottom: 0;
}

.stakeholder-country-title {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  color: var(--ink);
}

.stakeholder-country-title .fi {
  width: 22px;
  box-shadow: 0 0 0 1px rgba(23, 32, 42, 0.16);
}

.stakeholder-country-title strong {
  font-size: 13px;
}

.stakeholder-country-title small {
  display: grid;
  place-items: center;
  min-width: 24px;
  height: 22px;
  border-radius: 5px;
  background: #edf1f5;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.stakeholder-role-subgroup {
  display: grid;
  gap: 3px;
}

.stakeholder-role-subgroup h5 {
  margin: 0;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
}

.stakeholder-role-group {
  display: grid;
  gap: 7px;
}

.stakeholder-role-group h4 {
  margin: 0;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.stakeholder-country-group {
  display: grid;
  gap: 3px;
}

.stakeholder-country-heading {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 22px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.stakeholder-row {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 50px;
  border: 0;
  border-bottom: 1px solid #e5e9ef;
  background: transparent;
  color: var(--ink);
  cursor: grab;
  padding: 5px 2px;
  text-align: left;
}

.stakeholder-row:hover,
.stakeholder-row:focus-visible {
  background: #f3f6f8;
}

.stakeholder-row > i {
  font-size: 19px;
  text-align: center;
}

.stakeholder-row-text {
  min-width: 0;
}

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

.stakeholder-row strong {
  font-size: 12px;
}

.stakeholder-row small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.stakeholder-row .fi {
  align-self: start;
  margin-top: 5px;
}

.stakeholder-empty {
  color: var(--muted);
  font-size: 12px;
  padding: 18px 2px;
}

.palette-item {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  height: 70px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  cursor: grab;
  padding: 7px 4px;
}

.palette-item:hover,
.palette-item:focus-visible {
  border-color: #98a7ba;
  background: #f5f7f9;
}

.palette-item:active {
  cursor: grabbing;
}

.palette-item-new {
  border-style: dashed;
  background: #f8fafc;
}

.palette-item-new:hover,
.palette-item-new:focus-visible {
  border-color: #171a1f;
  background: #eef2f6;
}

.entity-template-dialog-card {
  width: min(440px, calc(100vw - 32px));
  max-height: min(760px, calc(100vh - 32px));
  overflow-y: auto;
}

.icon-choice-fieldset {
  display: grid;
  gap: 6px;
  min-width: 0;
  margin: 0;
  border: 0;
  padding: 0;
}

.icon-choice-fieldset legend {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.icon-choice-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
  padding: 2px;
}

.icon-choice {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  min-width: 0;
  min-height: 58px;
  border: 1px solid #d1d9e4;
  border-radius: 6px;
  background: #fff;
  color: #111;
  cursor: pointer;
  padding: 6px 3px;
}

.icon-choice:hover,
.icon-choice:focus-visible {
  border-color: #6f8299;
  background: #f5f7fa;
  outline: none;
}

.icon-choice.selected {
  border-color: #171a1f;
  background: #e9edf2;
  box-shadow: 0 0 0 2px rgba(23, 26, 31, 0.12);
}

.icon-choice i {
  font-size: 22px;
}

.icon-choice span {
  max-width: 100%;
  color: #475467;
  font-size: 9px;
  font-weight: 800;
  overflow-wrap: anywhere;
  text-align: center;
}

.palette-item i {
  font-size: 20px;
}

.entity-symbol-image {
  display: block;
  width: 1em;
  height: 1em;
  object-fit: contain;
  filter: brightness(0) saturate(100%);
}

.palette-item .entity-symbol-image {
  width: 24px;
  height: 24px;
}

.flow-node-icon .entity-symbol-image {
  width: 58px;
  height: 58px;
}

.inquiry-mini-icon .entity-symbol-image,
.assignment-card-icon .entity-symbol-image {
  width: 20px;
  height: 20px;
}

.network-map-marker .entity-symbol-image {
  width: 22px;
  height: 22px;
}

.palette-item span {
  max-width: 100%;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.palette-item[data-node-type="factory"] i,
.flow-node.factory .flow-node-icon,
.network-map-marker.factory {
  color: #c84032;
}

.palette-item[data-node-type="shipper"] i,
.flow-node.shipper .flow-node-icon,
.network-map-marker.shipper {
  color: #c84032;
}

.palette-item[data-node-type="port"] i,
.flow-node.port .flow-node-icon,
.network-map-marker.port {
  color: #1769aa;
}

.palette-item[data-node-type="airport"] i,
.flow-node.airport .flow-node-icon,
.network-map-marker.airport {
  color: #8a4f9e;
}

.palette-item[data-node-type="rail_terminal"] i,
.flow-node.rail_terminal .flow-node-icon,
.network-map-marker.rail_terminal {
  color: #495765;
}

.palette-item[data-node-type="depot"] i,
.flow-node.depot .flow-node-icon,
.network-map-marker.depot {
  color: #54606f;
}

.palette-item[data-node-type="warehouse"] i,
.flow-node.warehouse .flow-node-icon,
.network-map-marker.warehouse {
  color: #087a6b;
}

.palette-item[data-node-type="trader"] i,
.flow-node.trader .flow-node-icon,
.network-map-marker.trader {
  color: #8053a6;
}

.palette-item[data-node-type="company"] i,
.flow-node.company .flow-node-icon,
.network-map-marker.company {
  color: #2f6f63;
}

.palette-item[data-node-type="bank"] i,
.flow-node.bank .flow-node-icon,
.network-map-marker.bank {
  color: #3f6f4f;
}

.palette-item[data-node-type="importer"] i,
.flow-node.importer .flow-node-icon,
.network-map-marker.importer {
  color: #234d7d;
}

.palette-item[data-node-type="agent"] i,
.flow-node.agent .flow-node-icon,
.network-map-marker.agent {
  color: #a15f00;
}

.palette-item[data-node-type="consignee"] i,
.flow-node.consignee .flow-node-icon,
.network-map-marker.consignee {
  color: #145d8c;
}

.palette-item[data-node-type="inquiry"] i,
.flow-node.inquiry .flow-node-icon,
.network-map-marker.inquiry {
  color: #b42318;
}

.palette-item i,
.flow-node-icon,
.assignment-card-icon,
.inquiry-mini-icon,
.network-map-marker,
.stakeholder-row > i,
.maker-entity-option > i:first-child,
.inquiry-flow-step > i:first-child,
.inquiry-draft-row > i:first-child {
  color: #111 !important;
}

.route-legend,
.flow-legend {
  display: grid;
  gap: 7px;
  margin-top: 16px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.route-legend span,
.flow-legend span,
.map-key span {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.flow-swatch {
  display: inline-block;
  width: 28px;
  height: 0;
  border-top: 3px solid currentColor;
}

.flow-swatch.product {
  color: #c56a24;
}

.flow-swatch.information {
  color: #2368b4;
  border-top-style: dashed;
}

.flow-swatch.finance {
  color: #16835f;
  border-top-style: dotted;
}

.icon-attribution {
  display: inline-block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 9px;
  text-decoration: none;
}

.icon-attribution:hover,
.icon-attribution:focus-visible {
  color: #2368b4;
  text-decoration: underline;
}

.icon-attribution-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0 10px;
}

.route-swatch {
  display: inline-block;
  width: 24px;
  height: 3px;
  border-radius: 2px;
  background: #8b97a6;
}

.route-swatch.ocean {
  background: #2779bd;
}

.route-swatch.air {
  height: 0;
  border-top: 3px dashed #8a4f9e;
  background: transparent;
}

.route-swatch.road {
  background: #c56a24;
}

.route-swatch.rail {
  background: #495765;
}

.route-swatch.commercial {
  background: #1d8a63;
}

.route-swatch.finance {
  background: #16835f;
}

.network-stage,
.network-mode,
#drawflow,
#networkMap {
  min-width: 0;
  width: 100%;
  height: 100%;
}

.network-stage {
  position: relative;
  overflow: hidden;
  background: #f7f9fb;
}

.network-mode {
  display: none;
}

.network-mode.active {
  display: block;
}

#drawflow {
  position: relative;
  background-color: #f8fafb;
  background-image: radial-gradient(circle, #cad3df 1px, transparent 1px);
  background-size: 18px 18px;
  overflow: hidden;
}

#drawflow .drawflow {
  position: relative;
  z-index: 1;
  width: 7200px;
  height: 2200px;
  background: transparent;
  transform-origin: 0 0;
}

.chart-country-lanes {
  position: absolute;
  z-index: 0;
  top: 0;
  left: 0;
  display: grid;
  grid-template-columns: repeat(6, 1460px);
  width: 8760px;
  min-height: 100%;
  transform-origin: 0 0;
  pointer-events: none;
}

.chart-country-lanes.compact {
  display: block;
}

.chart-country-lanes.compact .chart-country-lane {
  position: absolute;
  top: 0;
  bottom: 0;
}

.chart-country-lanes.compact .chart-country-heading {
  cursor: default;
}

.chart-country-lane {
  position: relative;
  border-right: 2px solid rgba(255, 255, 255, 0.95);
  background: rgba(255, 246, 246, 0.66);
}

.chart-country-lane:nth-child(even) {
  background: rgba(241, 246, 251, 0.76);
}

.chart-country-lane:last-child {
  border-right: 0;
}

.chart-country-heading {
  position: absolute;
  top: 22px;
  left: 28px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #d21f2b;
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  cursor: grab;
  pointer-events: auto;
  touch-action: none;
  user-select: none;
}

.chart-country-heading.dragging {
  cursor: grabbing;
}

.chart-country-heading .fi {
  width: 24px;
  box-shadow: 0 0 0 1px rgba(23, 32, 42, 0.14);
}

.chart-country-stages {
  position: absolute;
  inset: 58px 0 0;
  display: grid;
  grid-template-columns: 290px 340px 280px 550px;
}

.chart-country-stages span {
  border-left: 1px dashed rgba(85, 103, 124, 0.22);
  color: #677485;
  font-size: 11px;
  font-weight: 800;
  padding: 7px 0 0 18px;
  text-transform: uppercase;
}

.chart-country-stages span:first-child {
  border-left: 0;
}

#drawflow .drawflow > svg.connection {
  z-index: 1;
}

#drawflow .drawflow > .parent-node {
  z-index: 3;
}

#drawflow .drawflow-node {
  width: 258px;
  min-height: 190px;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  box-shadow: none;
  cursor: default;
  padding: 0;
  touch-action: none;
  user-select: none;
}

#drawflow .drawflow-node:hover {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

#drawflow .drawflow-node .flow-node-icon {
  border-radius: 6px;
  cursor: grab;
  transition: transform 150ms ease, background 150ms ease, box-shadow 150ms ease;
}

#drawflow .drawflow-node .flow-node-icon:hover {
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 0 0 3px rgba(35, 104, 180, 0.12);
  transform: translateY(-2px) scale(1.035);
}

#drawflow .drawflow-node .flow-node-icon:active {
  cursor: grabbing;
}

#drawflow .drawflow-node.selected {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

#drawflow .drawflow-node.selected .flow-node-icon {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 0 3px rgba(35, 104, 180, 0.22);
}

#drawflow .drawflow-node.network-hidden,
#drawflow .connection.network-hidden {
  display: none;
}

.flow-node {
  display: grid;
  grid-template-columns: 66px 36px minmax(0, 1fr);
  grid-template-areas:
    "icon flag status"
    "kind kind kind"
    "name name name"
    "meta meta meta";
  gap: 4px 8px;
  align-content: start;
  align-items: start;
  min-height: 188px;
  padding: 8px 10px 10px;
}

.flow-node-icon {
  grid-area: icon;
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  background: transparent;
  font-size: 54px;
  line-height: 1;
}

.flow-node-kind {
  grid-area: kind;
  color: #d21f2b;
  font-size: 19px;
  line-height: 1.1;
  font-weight: 800;
  text-transform: none;
}

.flow-node strong {
  grid-area: name;
  min-width: 0;
  color: #171c24;
  font-size: 16px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.flow-node small {
  grid-area: meta;
  display: block;
  color: #303844;
  font-size: 13px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.flow-node-flag {
  grid-area: flag;
  align-self: center;
  justify-self: start;
  font-size: 23px;
}

.node-status-icon {
  grid-area: status;
  align-self: start;
  justify-self: end;
  font-size: 32px;
  color: #8995a3;
}

.node-status-icon.valid {
  color: var(--green);
}

.node-status-icon.expired {
  color: var(--amber);
}

.node-status-icon.not-quoted {
  color: var(--red);
}

#drawflow .drawflow-node .input,
#drawflow .drawflow-node .output {
  position: absolute;
  top: calc(var(--inquiry-hub-y, 95px) - 10px);
  left: calc(var(--inquiry-hub-x, 129px) - 10px);
  right: auto;
  width: 20px;
  height: 20px;
  margin: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  opacity: 0;
  pointer-events: none;
  transition: top 140ms ease, left 140ms ease, width 140ms ease, height 140ms ease;
}

#drawflow .drawflow-node .inputs,
#drawflow .drawflow-node .outputs {
  position: absolute;
  top: 0;
  left: 0;
  right: auto;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

#drawflow .drawflow-node .output_1 {
  z-index: 9;
  pointer-events: auto;
}

#drawflow .drawflow-node .input_1 {
  pointer-events: none;
}

#drawflow .drawflow-node .output_1 {
  clip-path: none;
}

#drawflow.flow-port-dragging[data-drag-flow="product"] .drawflow-node:not(.flow-ports-pinned) .input_1,
#drawflow.flow-port-dragging[data-drag-flow="information"] .drawflow-node:not(.flow-ports-pinned) .input_2,
#drawflow.flow-port-dragging[data-drag-flow="finance"] .drawflow-node:not(.flow-ports-pinned) .input_3 {
  z-index: 15;
  top: calc(var(--inquiry-hub-y, 95px) - 15px);
  left: calc(var(--inquiry-hub-x, 129px) - 15px);
  width: 30px;
  height: 30px;
  clip-path: none;
  opacity: 0;
  pointer-events: auto;
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .input,
#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .output {
  z-index: 10;
  width: 32px;
  height: 32px;
  opacity: 1;
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .input {
  clip-path: none;
  pointer-events: none;
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .output {
  clip-path: none;
  pointer-events: auto;
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .input_1,
#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .output_1 {
  top: calc(var(--flow-port-1-y, var(--inquiry-hub-y, 95px)) - 16px);
  left: calc(var(--flow-port-1-x, var(--inquiry-hub-x, 129px)) - 16px);
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .input_2,
#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .output_2 {
  top: calc(var(--flow-port-2-y, var(--inquiry-hub-y, 95px)) - 16px);
  left: calc(var(--flow-port-2-x, var(--inquiry-hub-x, 129px)) - 16px);
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .input_3,
#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .output_3 {
  top: calc(var(--flow-port-3-y, var(--inquiry-hub-y, 95px)) - 16px);
  left: calc(var(--flow-port-3-x, var(--inquiry-hub-x, 129px)) - 16px);
}

.inquiry-hub-visual {
  position: absolute;
  z-index: 11;
  top: var(--inquiry-hub-y, 95px);
  left: var(--inquiry-hub-x, 129px);
  width: 18px;
  height: 18px;
  border: 4px solid #171a1f;
  border-radius: 50%;
  background: #171a1f;
  box-shadow: 0 0 0 2px #fff, 0 2px 5px rgba(23, 32, 42, 0.22);
  pointer-events: auto;
  transform: translate(-50%, -50%);
  transition: border-color 120ms ease, background 120ms ease, box-shadow 120ms ease;
}

.inquiry-hub-visual::before {
  position: absolute;
  inset: -15px;
  border-radius: 50%;
  content: "";
}

.inquiry-hub-number {
  position: absolute;
  z-index: 2;
  inset: -4px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 8px;
  font-weight: 900;
  line-height: 1;
  pointer-events: none;
}

.flow-port-dot {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border: 2px solid #fff;
  border-radius: 50%;
  color: #fff;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.3);
  transition: top 140ms ease, left 140ms ease, opacity 110ms ease, transform 140ms ease;
}

.flow-port-dot i {
  color: #fff;
  font-size: 9px;
}

.flow-port-dot.flow-product {
  background: #c56a24;
  box-shadow: 0 2px 6px rgba(197, 106, 36, 0.28);
}

.flow-port-dot.flow-information {
  background: #2368b4;
  box-shadow: 0 2px 6px rgba(35, 104, 180, 0.28);
}

.flow-port-dot.flow-finance {
  background: #16835f;
  box-shadow: 0 2px 6px rgba(22, 131, 95, 0.28);
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .inquiry-hub-visual {
  z-index: 12;
  border-color: #171a1f;
  background: #171a1f;
  box-shadow: 0 0 0 2px #fff, 0 2px 5px rgba(23, 32, 42, 0.22);
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .flow-port-dot {
  top: calc(50% + var(--flow-port-dy));
  left: calc(50% + var(--flow-port-dx));
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

#drawflow .drawflow-node:has(.output_1:hover) .flow-port-dot.flow-product,
#drawflow .drawflow-node:has(.output_2:hover) .flow-port-dot.flow-information,
#drawflow .drawflow-node:has(.output_3:hover) .flow-port-dot.flow-finance {
  filter: brightness(1.08);
  transform: translate(-50%, -50%) scale(1.14);
}

.inquiry-hub-visual::after {
  position: absolute;
  bottom: -30px;
  left: 50%;
  width: max-content;
  max-width: 170px;
  border: 1px solid #d7dde6;
  border-radius: 4px;
  background: #fff;
  color: #344054;
  content: attr(data-inquiry-label);
  font-size: 9px;
  font-weight: 700;
  opacity: 0;
  padding: 3px 6px;
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity 100ms ease;
  white-space: nowrap;
}

#drawflow .drawflow-node:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .inquiry-hub-visual::after {
  opacity: 1;
}

#drawflow .drawflow-node.network-copy-port {
  z-index: 4;
  pointer-events: none;
}

#drawflow .drawflow-node.network-copy-port .drawflow_content_node {
  visibility: hidden;
}

#drawflow .drawflow-node.network-copy-port .input_1,
#drawflow .drawflow-node.network-copy-port .output_1 {
  pointer-events: auto;
}

#drawflow .drawflow-node.network-copy-port:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .input,
#drawflow .drawflow-node.network-copy-port:is(.flow-ports-expanded, :has(.inquiry-hub-visual:hover, .input:hover, .output:hover)) .output,
#drawflow .drawflow-node.network-copy-port .inquiry-hub-visual {
  pointer-events: auto;
}

#drawflow.flow-port-dragging .drawflow-node:not(.flow-ports-pinned) .input,
#drawflow.flow-port-dragging .drawflow-node:not(.flow-ports-pinned) .output {
  z-index: 9 !important;
  top: calc(var(--inquiry-hub-y, 95px) - 10px) !important;
  left: calc(var(--inquiry-hub-x, 129px) - 10px) !important;
  width: 20px !important;
  height: 20px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

#drawflow.flow-port-dragging .drawflow-node:not(.flow-ports-pinned) .flow-port-dot {
  opacity: 0 !important;
  pointer-events: none !important;
  transform: translate(-50%, -50%) scale(0.3) !important;
}

#drawflow.flow-port-dragging .drawflow-node:not(.flow-ports-pinned) .inquiry-hub-visual {
  z-index: 11 !important;
  border-color: #171a1f !important;
  background: #171a1f !important;
  box-shadow: 0 0 0 2px #fff, 0 2px 5px rgba(23, 32, 42, 0.22) !important;
}

.node-library [hidden] {
  display: none !important;
}

.stakeholder-role-subgroup > h5 {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.stakeholder-role-subgroup > h5 small {
  border-radius: 4px;
  background: #eef1f5;
  color: #667085;
  font-size: 10px;
  padding: 2px 5px;
}

#drawflow.flow-port-dragging[data-drag-flow="product"] .drawflow-node:not(.flow-ports-pinned) .input_1,
#drawflow.flow-port-dragging[data-drag-flow="information"] .drawflow-node:not(.flow-ports-pinned) .input_2,
#drawflow.flow-port-dragging[data-drag-flow="finance"] .drawflow-node:not(.flow-ports-pinned) .input_3 {
  z-index: 15 !important;
  top: calc(var(--inquiry-hub-y, 95px) - 15px) !important;
  left: calc(var(--inquiry-hub-x, 129px) - 15px) !important;
  width: 30px !important;
  height: 30px !important;
  clip-path: none !important;
  opacity: 0 !important;
  pointer-events: auto !important;
}

#drawflow .connection .main-path {
  stroke: #8d99a8;
  stroke-width: 2px;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}

#drawflow .connection .edge-hit-path {
  fill: none;
  stroke: transparent;
  stroke-width: 10px;
  pointer-events: stroke;
  cursor: pointer;
}

#drawflow .edge-select-button {
  position: absolute;
  z-index: 12;
  width: 34px;
  height: 34px;
  padding: 0;
  transform: translate(-50%, -50%);
  border: 1px solid transparent;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  pointer-events: auto;
}

#drawflow .edge-select-button:hover,
#drawflow .edge-select-button:focus-visible {
  border-color: transparent;
  background: transparent;
  outline: none;
}

#drawflow .connection:hover .main-path {
  stroke-width: 2.75px;
  filter: drop-shadow(0 1px 1px rgba(23, 32, 42, 0.18));
}

#drawflow .connection.relationship-selected .main-path {
  stroke-width: 3.5px;
  filter: drop-shadow(0 0 3px rgba(35, 104, 180, 0.45));
}

#drawflow .connection .edge-sequence-label {
  fill: #17202a;
  stroke: #fff;
  stroke-width: 4px;
  paint-order: stroke;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  pointer-events: auto;
}

#drawflow .connection .edge-line-label {
  stroke: #fff;
  stroke-width: 8px;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 0;
}

#drawflow .connection.flow-product .edge-line-label { fill: #c56a24; }
#drawflow .connection.flow-information .edge-line-label { fill: #2368b4; }
#drawflow .connection.flow-finance .edge-line-label { fill: #16835f; }

#drawflow .connection .edge-note-label {
  fill: currentColor;
  stroke: rgba(255, 255, 255, 0.98);
  stroke-width: 3px;
  paint-order: stroke;
  font-size: 11px;
  font-weight: 700;
  pointer-events: none;
}

#drawflow .connection.flow-product .edge-note-label { fill: #c56a24; }
#drawflow .connection.flow-information .edge-note-label { fill: #2368b4; }
#drawflow .connection.flow-finance .edge-note-label { fill: #16835f; }

.relationship-dialog-card {
  width: min(520px, calc(100vw - 32px));
}

.country-lane-dialog-card {
  width: min(620px, calc(100vw - 32px));
}

.country-lane-add-row,
.country-lane-row {
  display: grid;
  align-items: center;
  gap: 8px;
}

.country-lane-add-row {
  grid-template-columns: minmax(0, 1fr) auto;
  margin: 12px 0;
}

.country-lane-list {
  display: grid;
  max-height: min(520px, 62vh);
  overflow-y: auto;
  border-top: 1px solid #dbe2ea;
}

.country-lane-row {
  grid-template-columns: minmax(0, 1fr) 42px 36px 36px;
  min-height: 52px;
  border-bottom: 1px solid #e4e9ef;
}

.country-lane-name {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.country-lane-name strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.country-lane-name small {
  color: var(--muted);
  font-weight: 800;
}

.country-lane-row input[type="color"] {
  width: 36px;
  height: 32px;
  padding: 2px;
}

.relationship-summary {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 0 14px;
  padding: 10px 12px;
  border: 1px solid #dbe2ea;
  border-radius: 6px;
  background: #f6f8fb;
  color: #354052;
  font-size: 13px;
  font-weight: 700;
}

.relationship-summary i {
  flex: 0 0 auto;
  color: #246bb3;
}

#drawflow .connection.route-ocean .main-path {
  stroke: #2779bd;
}

#drawflow .connection.route-air .main-path {
  stroke: #8a4f9e;
  stroke-dasharray: 8 5;
}

#drawflow .connection.route-road .main-path {
  stroke: #c56a24;
}

#drawflow .connection.route-rail .main-path {
  stroke: #495765;
  stroke-dasharray: 7 4;
}

#drawflow .connection.route-commercial .main-path {
  stroke: #1d8a63;
  stroke-dasharray: 5 4;
}

#drawflow .connection.route-finance .main-path {
  stroke: #16835f;
  stroke-dasharray: 3 4;
}

#drawflow .connection.route-customs .main-path {
  stroke: #b42318;
  stroke-dasharray: 2 4;
}

#drawflow .connection.flow-product .main-path {
  stroke: #c56a24;
  stroke-dasharray: 12 7;
  stroke-linecap: round;
  marker-end: url(#flow-arrow-product);
  animation: chart-flow-forward 2.2s linear infinite;
}

#drawflow .connection.flow-information .main-path {
  stroke: #2368b4;
  stroke-dasharray: 7 5;
  stroke-linecap: round;
  marker-end: url(#flow-arrow-information);
  animation: chart-flow-forward 2.2s linear infinite;
}

#drawflow .connection.flow-finance .main-path {
  stroke: #16835f;
  stroke-dasharray: 2 5;
  stroke-linecap: round;
  marker-end: url(#flow-arrow-finance);
  animation: chart-flow-forward 2.2s linear infinite;
}

#drawflow .connection.flow-product .main-path,
#drawflow .connection.flow-information .main-path,
#drawflow .connection.flow-finance .main-path {
  stroke-width: 2px;
  stroke-dasharray: 8 6;
}

#drawflow .connection.arrow-none .main-path {
  marker-start: none;
  marker-end: none;
}

#drawflow .connection.flow-product.arrow-back .main-path { marker-start: url(#flow-arrow-product); marker-end: none; }
#drawflow .connection.flow-information.arrow-back .main-path { marker-start: url(#flow-arrow-information); marker-end: none; }
#drawflow .connection.flow-finance.arrow-back .main-path { marker-start: url(#flow-arrow-finance); marker-end: none; }

#drawflow .connection.flow-product.arrow-both .main-path { marker-start: url(#flow-arrow-product); marker-end: url(#flow-arrow-product); }
#drawflow .connection.flow-information.arrow-both .main-path { marker-start: url(#flow-arrow-information); marker-end: url(#flow-arrow-information); }
#drawflow .connection.flow-finance.arrow-both .main-path { marker-start: url(#flow-arrow-finance); marker-end: url(#flow-arrow-finance); }

#drawflow .connection .flow-tracer {
  pointer-events: none;
  stroke: #fff;
  stroke-width: 1.5px;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 3px currentColor);
}

#drawflow .connection .cargo-mode-tracer {
  overflow: visible;
  color: #c56a24;
  filter: drop-shadow(0 1px 2px rgba(23, 32, 42, 0.3));
}

.cargo-mode-image {
  pointer-events: none;
}

.cargo-mode-fallback {
  display: none;
  fill: currentColor;
  stroke: none;
  font-family: "Font Awesome 6 Free";
  font-size: 11px;
  font-weight: 900;
}

.cargo-mode-fallback.is-visible {
  display: block;
}

#drawflow .connection .cargo-mode-ocean { color: #2779bd; }
#drawflow .connection .cargo-mode-air { color: #8a4f9e; }
#drawflow .connection .cargo-mode-road { color: #26313d; }
#drawflow .connection .cargo-mode-rail { color: #495765; }

#drawflow .connection .flow-tracer-product {
  color: #c56a24;
  fill: #c56a24;
}

#drawflow .connection .flow-tracer-information {
  color: #2368b4;
  fill: #2368b4;
}

#drawflow .connection .flow-tracer-finance {
  color: #16835f;
  fill: #16835f;
}

@keyframes chart-flow-forward {
  to {
    stroke-dashoffset: -38;
  }
}

@keyframes map-flow-forward {
  to {
    stroke-dashoffset: -44;
  }
}

.leaflet-overlay-pane path.map-flow {
  stroke-linecap: round;
  stroke-width: 2px;
  stroke-dasharray: 8 6;
  animation: map-flow-forward 2.2s linear infinite;
}

.flow-animation-paused #drawflow .connection .main-path,
.flow-animation-paused .leaflet-overlay-pane path.map-flow {
  animation-play-state: paused;
}

@media (prefers-reduced-motion: reduce) {
  #drawflow .connection .main-path,
  .leaflet-overlay-pane path.map-flow {
    animation: none !important;
  }

  #drawflow .connection .flow-tracer {
    display: none;
  }

  .map-route-vehicle-wrapper {
    display: none;
  }
}

.inspector-heading {
  margin-bottom: 8px;
}

.inspector-empty {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  min-height: 220px;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
}

.inspector-empty i {
  font-size: 28px;
  color: #9aa7b7;
}

.inspector-form {
  display: grid;
  gap: 10px;
}

.inspector-form label,
.inspector-form .form-field {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.location-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 36px;
  align-items: center;
  gap: 7px;
}

.location-search-button {
  min-height: 36px;
  padding: 0 11px;
}

.location-map-link {
  width: 36px;
  height: 36px;
  color: #2368b4;
  text-decoration: none;
}

.location-search-results {
  display: grid;
  max-height: 218px;
  overflow-y: auto;
  border: 1px solid #dbe2ea;
  border-radius: 6px;
  background: #fff;
}

.location-search-results[hidden] {
  display: none;
}

.location-search-result {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: start;
  gap: 9px;
  min-width: 0;
  border: 0;
  border-bottom: 1px solid #e6ebf1;
  background: #fff;
  color: #17202a;
  cursor: pointer;
  padding: 9px 10px;
  text-align: left;
}

.location-search-result:last-child {
  border-bottom: 0;
}

.location-search-result:hover,
.location-search-result:focus-visible {
  background: #f2f6fb;
  outline: none;
}

.location-search-result > span {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.location-search-result strong,
.location-search-result small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.location-search-result small,
.location-search-message {
  color: #667085;
  font-size: 11px;
  font-weight: 600;
}

.location-search-message {
  padding: 11px;
}

.coordinate-details {
  border: 1px solid #dbe2ea;
  border-radius: 6px;
  background: #f8fafc;
  padding: 8px 10px;
}

.coordinate-details summary {
  color: #55657a;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}

.coordinate-details[open] summary {
  margin-bottom: 9px;
}

.coordinate-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.node-dialog-card {
  width: min(640px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  overflow-y: auto;
}

.dialog-heading-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

#networkMap {
  background: #e8eef1;
}

.map-filter-panel {
  position: absolute;
  z-index: 540;
  top: 12px;
  right: 12px;
  width: min(306px, calc(100% - 76px));
  max-height: calc(100% - 72px);
  border: 1px solid rgba(23, 32, 42, 0.16);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.96);
  padding: 9px;
  overflow-y: auto;
  box-shadow: 0 2px 8px rgba(23, 32, 42, 0.12);
  scrollbar-width: thin;
}

.map-filter-panel__heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}

.map-filter-panel__heading > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.map-filter-panel__heading svg {
  width: 14px;
  height: 14px;
  color: #087a6b;
}

.map-filter-reset {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: #475467;
  cursor: pointer;
}

.map-filter-reset:hover,
.map-filter-reset:focus-visible {
  border-color: #087a6b;
  color: #087a6b;
}

.map-filter-reset svg {
  width: 13px;
  height: 13px;
  color: currentColor;
}

.map-filter-group {
  display: grid;
  gap: 4px;
  margin-top: 7px;
}

.map-filter-label {
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.map-filter-chip-row {
  display: flex;
  align-items: center;
  gap: 4px;
  padding-bottom: 2px;
  overflow-x: auto;
  scrollbar-width: none;
}

.map-filter-chip-row::-webkit-scrollbar {
  display: none;
}

#mapEntityFilters,
#mapSourceFilters,
#mapSupplierFilters,
#mapDisplayFilters {
  flex-wrap: wrap;
  overflow-x: visible;
}

.map-filter-chip {
  flex: 0 0 auto;
  min-height: 25px;
  border: 1px solid #d7dee7;
  border-radius: 999px;
  background: #fff;
  color: #475467;
  cursor: pointer;
  padding: 0 8px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0;
  white-space: nowrap;
}

.map-filter-chip:hover,
.map-filter-chip:focus-visible {
  border-color: #7aa89d;
  background: #f0f7f5;
  color: #075f53;
}

.map-filter-chip.active {
  border-color: #087a6b;
  background: #087a6b;
  color: #fff;
}

.map-filter-summary {
  margin-top: 7px;
  border-top: 1px solid var(--line);
  padding-top: 6px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
  line-height: 1.35;
}

.map-entity-filters {
  position: absolute;
  z-index: 520;
  top: 12px;
  left: 54px;
  display: flex;
  align-items: center;
  gap: 5px;
  max-width: calc(100% - 72px);
  border: 1px solid rgba(23, 32, 42, 0.16);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.95);
  padding: 4px;
  overflow-x: auto;
  box-shadow: 0 2px 8px rgba(23, 32, 42, 0.12);
  scrollbar-width: none;
}

.map-entity-filters::-webkit-scrollbar {
  display: none;
}

.map-entity-chip {
  flex: 0 0 auto;
  min-height: 28px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: #475467;
  cursor: pointer;
  padding: 0 9px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  white-space: nowrap;
}

.map-entity-chip:hover,
.map-entity-chip:focus-visible {
  background: #eef6ff;
}

.map-entity-chip.active {
  border-color: #2368b4;
  background: #2368b4;
  color: #fff;
}

.supplier-depot-controls {
  position: absolute;
  z-index: 520;
  top: 58px;
  right: 12px;
  width: 246px;
  border: 1px solid rgba(23, 32, 42, 0.16);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.96);
  padding: 10px;
  box-shadow: 0 2px 8px rgba(23, 32, 42, 0.12);
}

.supplier-depot-controls__heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}

.supplier-depot-controls__heading > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.supplier-depot-controls__heading svg {
  width: 15px;
  height: 15px;
  color: #087a6b;
}

.supplier-depot-controls__fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 9px;
}

.supplier-depot-controls__fields.is-disabled {
  opacity: 0.48;
}

.supplier-depot-controls__fields label {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.supplier-depot-controls__fields select {
  width: 100%;
  min-height: 32px;
  padding: 0 7px;
  font-size: 11px;
}

.supplier-depot-link-toggle {
  grid-column: 1 / -1;
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 7px !important;
  color: #475467 !important;
  font-weight: 700 !important;
}

.supplier-depot-link-toggle input {
  width: 15px;
  height: 15px;
  min-height: 0;
  margin: 0;
  accent-color: #087a6b;
}

.supplier-depot-controls__summary {
  margin-top: 8px;
  border-top: 1px solid var(--line);
  padding-top: 7px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.compact-switch {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.compact-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.compact-switch > span[aria-hidden="true"] {
  position: relative;
  display: block;
  width: 34px;
  height: 19px;
  border-radius: 999px;
  background: #c8d0da;
  transition: background 0.18s ease;
}

.compact-switch > span[aria-hidden="true"]::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(23, 32, 42, 0.24);
  transition: transform 0.18s ease;
}

.compact-switch input:checked + span[aria-hidden="true"] {
  background: #087a6b;
}

.compact-switch input:checked + span[aria-hidden="true"]::after {
  transform: translateX(15px);
}

.compact-switch input:focus-visible + span[aria-hidden="true"] {
  outline: 2px solid #2368b4;
  outline-offset: 2px;
}

.supplier-pod-icon,
.supplier-depot-icon {
  border: 0;
  background: transparent;
}

.supplier-pod-marker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #18212f;
  color: #fff;
  padding: 0 10px;
  box-shadow: 0 3px 10px rgba(23, 32, 42, 0.25);
  white-space: nowrap;
}

.supplier-pod-marker b {
  font-size: 10px;
  letter-spacing: 0;
}

.supplier-depot-marker {
  position: relative;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #087a6b;
  color: #fff;
  box-shadow: 0 3px 10px rgba(23, 32, 42, 0.24);
}

.supplier-depot-marker__count {
  position: absolute;
  top: -6px;
  right: -6px;
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #c56a24;
  color: #fff;
  font-size: 9px;
}

.supplier-depot-link {
  pointer-events: auto;
}

.supplier-depot-popup span {
  max-width: 280px;
}

.map-key {
  position: absolute;
  z-index: 500;
  left: 12px;
  bottom: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid rgba(23, 32, 42, 0.16);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.94);
  padding: 7px 9px;
  box-shadow: 0 2px 8px rgba(23, 32, 42, 0.12);
}

.quote-swatch {
  display: inline-block;
  width: 19px;
  border-top: 3px dashed currentColor;
}

.quote-swatch.valid {
  color: var(--green);
}

.quote-swatch.expired {
  color: var(--amber);
}

.network-map-icon {
  border: 0;
  background: transparent;
}

.map-route-vehicle-wrapper {
  overflow: visible;
  border: 0;
  background: transparent;
  pointer-events: none !important;
}

.map-route-vehicle {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  transform-origin: center;
}

.map-route-vehicle img {
  display: block;
  width: 19px;
  height: 19px;
  object-fit: contain;
  filter: drop-shadow(0 1px 2px rgba(23, 32, 42, 0.45));
}

.map-route-vehicle-ocean img {
  filter: invert(36%) sepia(86%) saturate(1014%) hue-rotate(169deg) brightness(86%) contrast(91%) drop-shadow(0 1px 2px rgba(23, 32, 42, 0.35));
}

.map-route-vehicle-air {
  transform: rotate(var(--map-route-angle, 0deg));
}

.map-route-vehicle-fallback {
  display: none;
  color: #26313d;
  font-family: "Font Awesome 6 Free";
  font-size: 14px;
  font-weight: 900;
  filter: drop-shadow(0 1px 2px rgba(23, 32, 42, 0.35));
}

.map-route-vehicle-wrapper.image-error img {
  display: none;
}

.map-route-vehicle-wrapper.image-error .map-route-vehicle-fallback {
  display: block;
}

.network-map-marker {
  position: relative;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(23, 32, 42, 0.2);
  font-size: 12px;
}

.network-map-marker .marker-flag {
  position: absolute;
  right: -6px;
  bottom: -5px;
  display: grid;
  place-items: center;
  width: 16px;
  height: 12px;
  border: 1.5px solid #fff;
  border-radius: 2px;
  background: #fff;
  font-size: 9px;
}

.network-map-marker.is-selected {
  box-shadow: 0 0 0 3px rgba(35, 104, 180, 0.2), 0 2px 6px rgba(23, 32, 42, 0.24);
}

.network-map-marker.is-supplier {
  background: #f4fbf9;
}

.map-marker-count {
  position: absolute;
  top: -6px;
  left: -6px;
  display: grid;
  place-items: center;
  min-width: 15px;
  height: 15px;
  border: 1.5px solid #fff;
  border-radius: 999px;
  background: #c56a24;
  color: #fff;
  padding: 0 3px;
  font-size: 8px;
  line-height: 1;
}

.map-marker-cluster {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #087a6b;
  color: #fff;
  box-shadow: 0 0 0 3px rgba(8, 122, 107, 0.16), 0 2px 6px rgba(23, 32, 42, 0.24);
}

.map-marker-cluster b {
  font-size: 10px;
  line-height: 1;
}

.quote-map-marker {
  position: relative;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 2px solid #2368b4;
  border-radius: 50%;
  background: #fff;
  color: #2368b4;
  box-shadow: 0 2px 7px rgba(23, 32, 42, 0.24);
  font-size: 19px;
}

.quote-map-marker.destination {
  border-color: #b26a00;
  color: #b26a00;
}

.quote-map-marker .marker-flag {
  position: absolute;
  right: -7px;
  bottom: -2px;
  display: grid;
  place-items: center;
  width: 23px;
  height: 17px;
  border: 2px solid #fff;
  border-radius: 3px;
  background: #fff;
  font-size: 13px;
}

.quote-map-marker.grouped-port {
  width: 30px;
  height: 30px;
  border-width: 1.5px;
  font-size: 14px;
}

.quote-map-marker.grouped-port.is-cluster {
  border-color: #18578f;
  background: #2368b4;
  color: #fff;
  box-shadow: 0 0 0 3px rgba(35, 104, 180, 0.16), 0 2px 7px rgba(23, 32, 42, 0.24);
}

.quote-map-marker.grouped-port .marker-flag {
  right: -7px;
  bottom: -5px;
  width: 18px;
  height: 14px;
  border-width: 1.5px;
  font-size: 10px;
}

.quote-port-count {
  position: absolute;
  top: -8px;
  right: -8px;
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border: 2px solid #fff;
  border-radius: 9px;
  background: #b42318;
  color: #fff;
  box-shadow: 0 1px 4px rgba(23, 32, 42, 0.24);
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}

.map-popup {
  min-width: 190px;
}

.map-popup strong,
.map-popup span {
  display: block;
}

.map-popup span {
  margin-top: 4px;
  color: #667085;
  font-size: 12px;
}

.map-popup a {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  margin-top: 9px;
  border-radius: 5px;
  background: #2368b4;
  color: #fff;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.route-popup strong,
.route-popup span {
  display: block;
}

.route-popup span {
  margin-top: 3px;
  color: #667085;
  font-size: 12px;
}

.route-popup a {
  display: inline-block;
  margin-top: 8px;
  font-weight: 700;
}

.network-layout.quotes-active {
  grid-template-columns: minmax(0, 1fr);
}

.network-layout.quotes-active .node-library {
  display: none;
}

#quotesMode {
  overflow: auto;
  background: #fff;
}

.quote-library-workspace {
  min-width: 0;
  color: var(--ink);
}

.quote-library-header,
.quote-section-heading,
.quote-library-actions,
.quote-chart-legend,
.quote-form-footer {
  display: flex;
  align-items: center;
}

.quote-library-header {
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px 14px;
}

.quote-library-header h3,
.quote-section-heading h4,
.quote-library-header p,
.quote-section-heading p {
  margin: 0;
}

.quote-library-header h3 {
  margin-top: 2px;
  font-size: 20px;
}

.quote-library-actions {
  gap: 8px;
}

.quote-section-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.quote-library-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}

.quote-library-actions .lucide {
  width: 16px;
  height: 16px;
}

.quote-privacy-shield {
  min-height: calc(100vh - 230px);
  place-content: center;
  justify-items: center;
  gap: 10px;
  border-top: 1px solid var(--line);
  color: #475467;
  background: #f8fafb;
}

.quote-privacy-shield:not([hidden]) {
  display: grid;
}

.quote-privacy-shield .lucide {
  width: 28px;
  height: 28px;
}

.quote-data-hidden .quote-library-actions > :not(#toggleQuotePricesButton),
.quote-data-hidden .quote-summary,
.quote-data-hidden .quote-filterbar,
.quote-data-hidden .quote-matrix-section,
.quote-data-hidden .quote-trend-section,
.quote-data-hidden .quote-table-section {
  display: none;
}

.quote-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #f8fafb;
}

.quote-summary-metric {
  display: grid;
  gap: 3px;
  min-width: 0;
  border-right: 1px solid var(--line);
  padding: 13px 18px;
}

.quote-summary-metric:last-child {
  border-right: 0;
}

.quote-summary-metric span,
.quote-forecast-strip span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.quote-summary-metric strong {
  font-size: 22px;
  line-height: 1.1;
}

.quote-summary-metric small,
.quote-forecast-strip small,
.quote-section-heading p {
  color: var(--muted);
  font-size: 11px;
}

.quote-summary-metric.valid strong {
  color: var(--green);
}

.quote-summary-metric.expired strong {
  color: var(--amber);
}

.quote-summary-metric.anomaly strong {
  color: var(--red);
}

.quote-filterbar {
  display: grid;
  grid-template-columns: minmax(210px, 1.25fr) minmax(185px, 0.8fr) minmax(280px, 1.45fr) minmax(145px, 0.65fr);
  gap: 10px;
  padding: 13px 20px;
}

.quote-filterbar label,
.quote-chip-filter {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.quote-filterbar input,
.quote-filterbar select {
  min-height: 36px;
  width: 100%;
  text-transform: none;
}

.quote-filter-chips {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  min-height: 36px;
  border: 1px solid #cfd8e3;
  border-radius: 6px;
  background: #fff;
  padding: 4px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.quote-filter-chip {
  flex: 0 0 auto;
  min-height: 26px;
  border: 1px solid #d7dde6;
  border-radius: 999px;
  background: #f8fafb;
  color: #475467;
  cursor: pointer;
  padding: 3px 9px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
  white-space: nowrap;
}

.quote-filter-chip:hover,
.quote-filter-chip:focus-visible {
  border-color: #7f9bbb;
  background: #eef6ff;
}

.quote-filter-chip.active {
  border-color: #2368b4;
  background: #2368b4;
  color: #fff;
}

.quote-search-field {
  position: relative;
  align-self: end;
}

.quote-search-field .lucide {
  position: absolute;
  z-index: 1;
  left: 10px;
  bottom: 10px;
  width: 16px;
  height: 16px;
  color: var(--muted);
}

.quote-search-field input {
  padding-left: 34px;
}

.quote-matrix-section {
  border-top: 1px solid var(--line);
  padding: 14px 20px 18px;
}

.quote-matrix-section .secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 34px;
}

.quote-matrix-section .secondary-button .lucide {
  width: 15px;
  height: 15px;
}

.quote-matrix-wrap {
  max-height: min(620px, calc(100vh - 285px));
  margin-top: 10px;
  border: 1px solid #cfd8e3;
  overflow: auto;
  scrollbar-width: thin;
}

.quote-matrix-section.is-expanded {
  position: fixed;
  z-index: 2200;
  inset: 12px;
  display: flex;
  flex-direction: column;
  border: 1px solid #b8c5d4;
  border-radius: 6px;
  background: #fff;
  padding: 14px;
  box-shadow: 0 18px 52px rgba(23, 32, 42, 0.24);
}

.quote-matrix-section.is-expanded .quote-matrix-wrap {
  flex: 1;
  height: calc(100vh - 96px);
  max-height: none;
}

.quote-matrix-expanded {
  overflow: hidden;
}

.quote-prices-hidden .matrix-price-cell,
.quote-prices-hidden .matrix-change-cell,
.quote-prices-hidden .quote-table tbody .numeric-cell,
.quote-prices-hidden .quote-forecast-strip strong {
  position: relative;
  color: transparent !important;
  text-shadow: none !important;
  user-select: none;
}

.quote-prices-hidden .matrix-price-cell::after,
.quote-prices-hidden .matrix-change-cell::after,
.quote-prices-hidden .quote-table tbody .numeric-cell::after,
.quote-prices-hidden .quote-forecast-strip strong::after {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #667085;
  content: "••••";
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
}

.quote-prices-hidden input[data-entry-price20],
.quote-prices-hidden input[data-entry-price40] {
  -webkit-text-security: disc;
}

.quote-prices-hidden #quoteTrendCanvas {
  opacity: 0.18;
  filter: blur(7px);
  pointer-events: none;
}

.quote-prices-hidden .quote-chart-wrap::after {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #475467;
  content: "Prices hidden";
  font-size: 13px;
  font-weight: 800;
  pointer-events: none;
}

.quote-matrix-table {
  width: max-content;
  min-width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 11px;
  line-height: 1.25;
}

.quote-matrix-table th,
.quote-matrix-table td {
  min-width: 86px;
  height: 34px;
  border-right: 1px dotted #aeb9c6;
  border-bottom: 1px dotted #aeb9c6;
  padding: 6px 8px;
  background: #fff;
  text-align: left;
  vertical-align: middle;
  white-space: nowrap;
}

.quote-matrix-table thead th {
  position: sticky;
  z-index: 4;
  background: #eef2f6;
  color: #344054;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
}

.quote-matrix-table thead tr:first-child th {
  top: 0;
  height: 34px;
}

.quote-matrix-table thead tr:nth-child(2) th {
  top: 34px;
}

.quote-matrix-groups > th:not(.quote-round-group) {
  background: #e9f3ee;
  color: #245a45;
  text-align: center;
}

.quote-matrix-table .quote-round-group,
.quote-matrix-table .quote-entry-group {
  min-width: 430px;
  background: #0754a3;
  color: #fff;
  text-align: left;
}

.quote-matrix-table .quote-entry-group {
  min-width: 344px;
  background: #116149;
}

.quote-round-group span,
.quote-round-group small,
.quote-entry-group span,
.quote-entry-group small {
  display: block;
}

.quote-round-group small,
.quote-entry-group small {
  margin-top: 2px;
  color: #d7e8fb;
  font-size: 9px;
  font-weight: 600;
  text-transform: none;
}

.quote-matrix-table .matrix-change-cell {
  min-width: 136px;
  color: #475467;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.quote-matrix-table .matrix-entry-controls {
  min-width: 98px;
  background: #edf8f3;
  text-align: center;
}

.quote-matrix-table .matrix-entry-controls input {
  width: 92px;
  min-height: 28px;
  border-color: #9bc6b5;
  background: #fff;
  padding: 4px 6px;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.quote-matrix-table .matrix-entry-controls input[type="date"] {
  width: 112px;
}

.quote-matrix-table .matrix-entry-controls button {
  margin: auto;
  border-color: #6da58f;
  color: #116149;
}

.quote-matrix-table tbody tr {
  cursor: pointer;
}

.quote-matrix-table tbody tr:hover td,
.quote-matrix-table tbody tr.selected td {
  background: #f2f7fb;
}

.quote-matrix-table tbody tr.selected td {
  box-shadow: inset 0 1px #9fc0df, inset 0 -1px #9fc0df;
}

.quote-matrix-table .matrix-sticky {
  position: sticky;
  z-index: 3;
}

.quote-matrix-table thead .matrix-sticky,
.quote-matrix-table .matrix-route-group {
  z-index: 7;
}

.quote-matrix-table .matrix-route-group {
  position: sticky;
  left: 0;
}

.quote-matrix-table .matrix-no {
  left: 0;
  min-width: 48px;
  width: 48px;
  text-align: center;
}

.quote-matrix-table .matrix-origin {
  left: 48px;
  min-width: 72px;
  width: 72px;
  text-align: center;
}

.quote-matrix-table .matrix-pol {
  left: 120px;
  min-width: 76px;
  width: 76px;
  font-weight: 800;
}

.quote-matrix-table tbody .matrix-sticky {
  background: #fff;
}

.quote-matrix-table tbody tr:hover .matrix-sticky,
.quote-matrix-table tbody tr.selected .matrix-sticky {
  background: #f2f7fb;
}

.quote-matrix-table .matrix-pol.pol-hcm {
  background: #a71111;
  color: #fff;
}

.quote-matrix-table .matrix-pol.pol-hph {
  background: #155f63;
  color: #fff;
}

.quote-matrix-table .matrix-price-action-heading,
.quote-matrix-table .matrix-price-action {
  min-width: 54px;
  width: 54px;
  text-align: center;
}

.quote-matrix-table .matrix-price-action-heading {
  vertical-align: middle;
}

.quote-matrix-table .matrix-price-action button {
  margin: auto;
}

.quote-matrix-table .matrix-price-cell {
  color: #135fba;
  font-variant-numeric: tabular-nums;
  font-weight: 750;
  text-align: right;
}

.quote-matrix-table .matrix-date-cell {
  min-width: 92px;
  color: #135fba;
  font-variant-numeric: tabular-nums;
}

.quote-matrix-table .matrix-date-cell.valid {
  background: #eaf7f0;
  color: #087443;
}

.quote-matrix-table .matrix-date-cell.expired {
  background: #fff5e5;
  color: #9a5b00;
}

.quote-matrix-table .matrix-date-cell.anomaly,
.quote-matrix-table .matrix-price-cell.anomaly {
  background: #feefed;
  color: #b42318;
}

.quote-matrix-table .matrix-quote-empty {
  color: #98a2b3;
  text-align: center;
}

.quote-matrix-table .country-US {
  color: #9e2418;
  font-weight: 700;
}

.quote-matrix-table .country-CA {
  color: #a36a00;
  font-weight: 700;
}

.quote-matrix-table .country-AU {
  color: #157347;
  font-weight: 700;
}

.quote-trend-section,
.quote-table-section {
  border-top: 1px solid var(--line);
}

.quote-trend-section {
  padding: 15px 20px 0;
}

.quote-section-heading {
  justify-content: space-between;
  gap: 16px;
}

.quote-section-heading h4 {
  font-size: 14px;
}

.quote-section-heading p {
  margin-top: 3px;
}

.quote-chart-legend {
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}

.quote-chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.quote-series-key {
  display: inline-block;
  width: 22px;
  border-top: 3px solid;
}

.quote-series-key.twenty {
  color: #c56a24;
}

.quote-series-key.forty {
  color: #2368b4;
}

.quote-series-key.forecast {
  border-top-style: dashed;
  color: #8995a3;
}

.quote-chart-wrap {
  position: relative;
  min-height: 300px;
  margin-top: 8px;
  overflow-x: auto;
  scrollbar-width: thin;
}

#quoteTrendCanvas {
  display: block;
}

.quote-chart-empty {
  display: grid;
  place-items: center;
  min-height: 280px;
  color: var(--muted);
  font-size: 13px;
}

.quote-forecast-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 -20px;
  border-top: 1px solid var(--line);
  background: #f8fafb;
}

.quote-forecast-strip > div {
  display: grid;
  gap: 3px;
  min-width: 0;
  border-right: 1px solid var(--line);
  padding: 11px 18px;
}

.quote-forecast-strip > div:last-child {
  border-right: 0;
}

.quote-forecast-strip strong {
  font-size: 15px;
  overflow-wrap: anywhere;
}

.quote-table-section {
  padding: 14px 20px 20px;
}

.quote-table-wrap {
  max-height: 360px;
  margin-top: 10px;
  border: 1px solid var(--line);
  overflow: auto;
}

.quote-table {
  min-width: 1180px;
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.quote-table th {
  position: sticky;
  z-index: 2;
  top: 0;
  background: #eef2f6;
  color: #475467;
  font-size: 9px;
  text-transform: uppercase;
}

.quote-table th,
.quote-table td {
  border-bottom: 1px solid var(--line);
  padding: 8px 9px;
  text-align: left;
  vertical-align: middle;
}

.quote-table tbody tr {
  cursor: pointer;
}

.quote-table tbody tr:hover {
  background: #f7f9fb;
}

.quote-table tbody tr.quote-row-anomaly {
  background: #fff7ed;
}

.quote-table td strong,
.quote-table td small {
  display: block;
}

.quote-table td small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.quote-table .numeric-cell {
  text-align: right;
  white-space: nowrap;
}

.quote-notes-cell {
  max-width: 230px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quote-validity-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: max-content;
  border-radius: 999px;
  padding: 4px 7px;
  font-size: 10px;
  font-weight: 800;
}

.quote-validity-pill.valid {
  background: #e8f7f0;
  color: var(--green);
}

.quote-validity-pill.expired {
  background: #fff3df;
  color: var(--amber);
}

.quote-validity-pill.anomaly {
  background: #feeceb;
  color: var(--red);
}

.empty-table-cell {
  height: 100px;
  color: var(--muted);
  text-align: center !important;
}

.quote-dialog-card {
  width: min(760px, calc(100vw - 32px));
}

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

.quote-form-grid label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.quote-form-grid .span-two {
  grid-column: span 2;
}

.quote-form-footer {
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

#quoteFormMessage,
#ddpRouteFormMessage {
  color: var(--red);
  font-size: 12px;
}

@media (max-width: 1080px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 5;
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 14px;
  }

  .nav-list {
    grid-template-columns: repeat(8, minmax(104px, 1fr));
    overflow-x: auto;
  }

  .sidebar-actions {
    grid-template-columns: repeat(2, 1fr);
    margin-top: 0;
  }

  .data-tools {
    grid-template-columns: repeat(5, minmax(120px, 1fr));
    align-items: end;
  }

  .metric-grid,
  .shipment-board {
    grid-template-columns: repeat(2, minmax(160px, 1fr));
  }

  .split-layout,
  .data-layout {
    grid-template-columns: 1fr;
  }

  .network-layout {
    --library-width: 240px;
    grid-template-columns: 240px minmax(0, 1fr);
    height: auto;
    min-height: 680px;
  }

  .network-stage {
    min-height: 680px;
  }

  .node-inspector {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 140px minmax(0, 1fr);
    gap: 14px;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .inspector-heading {
    align-content: start;
  }

  .inspector-empty {
    min-height: 120px;
  }

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

  .inspector-form .coordinate-fields {
    grid-column: span 2;
  }

  .quote-summary,
  .quote-forecast-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quote-summary-metric:nth-child(2),
  .quote-forecast-strip > div:nth-child(2) {
    border-right: 0;
  }

  .quote-summary-metric:nth-child(-n + 2),
  .quote-forecast-strip > div:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .quote-filterbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .workspace {
    padding: 16px;
  }

  .inquiry-stakeholder-dialog {
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
    overflow-y: auto;
  }

  .stakeholder-assignment-layout {
    grid-template-columns: 1fr;
  }

  .stakeholder-assignment-panel + .stakeholder-assignment-panel {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .stakeholder-assignment-grid,
  .inquiry-stakeholder-box {
    max-height: 260px;
  }

  .assignment-stage-grid {
    grid-template-columns: repeat(auto-fill, minmax(135px, 1fr));
  }

  .inquiry-stakeholder-box {
    min-height: 220px;
  }

  .inquiry-maker-grid.two-columns,
  .inquiry-maker-grid.three-columns,
  .inquiry-entity-picker {
    grid-template-columns: 1fr;
  }

  .inquiry-maker-grid .span-two {
    grid-column: auto;
  }

  .inquiry-maker-heading,
  .inquiry-maker-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .inquiry-maker-footer .primary-button {
    justify-content: center;
    width: 100%;
  }

  .topbar,
  .topbar-controls {
    align-items: stretch;
    flex-direction: column;
  }

  .save-status {
    justify-content: center;
  }

  input[type="search"] {
    width: 100%;
  }

  #statusFilter {
    width: 100%;
  }

  #clearFilters {
    width: 100%;
  }

  .metric-grid,
  .shipment-board,
  .quick-grid {
    grid-template-columns: 1fr;
  }

  .network-toolbar {
    flex-wrap: wrap;
  }

  .network-filter {
    order: 2;
    width: calc(100% - 44px);
  }

  .inquiry-filter-group {
    order: 2;
    width: calc(100% - 44px);
    flex-basis: calc(100% - 44px);
  }

  .network-filter select {
    width: 100%;
  }

  #newInquiryButton {
    order: 2;
  }

  .link-mode-field {
    order: 3;
  }

  .network-count {
    margin-left: auto;
  }

  .canvas-tools {
    margin-left: 0;
  }

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

  .node-library {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    max-height: 320px;
    overflow-y: auto;
  }

  .node-palette {
    display: flex;
    min-width: max-content;
  }

  .stakeholder-library {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .palette-item {
    width: 76px;
    height: 66px;
    aspect-ratio: auto;
  }

  .route-legend,
  .flow-legend {
    display: none;
  }

  .network-stage {
    min-height: 560px;
  }

  .node-inspector {
    grid-column: auto;
    display: block;
  }

  .inspector-form {
    grid-template-columns: 1fr;
  }

  .inspector-form .coordinate-fields {
    grid-column: auto;
  }

  .map-key {
    flex-wrap: wrap;
    right: 12px;
  }

  .map-filter-panel {
    top: 8px;
    right: 8px;
    width: min(286px, calc(100% - 58px));
    max-height: 250px;
  }

  .mode-button {
    padding: 0 8px;
    font-size: 12px;
  }

  .quote-library-header,
  .quote-section-heading,
  .quote-form-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .quote-library-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .quote-summary,
  .quote-filterbar,
  .quote-forecast-strip,
  .quote-form-grid {
    grid-template-columns: 1fr;
  }

  .quote-summary-metric,
  .quote-summary-metric:nth-child(2),
  .quote-forecast-strip > div,
  .quote-forecast-strip > div:nth-child(2) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .quote-summary-metric:last-child,
  .quote-forecast-strip > div:last-child {
    border-bottom: 0;
  }

  .quote-chart-legend {
    justify-content: flex-start;
  }

  .quote-form-grid .span-two {
    grid-column: auto;
  }

  .quote-form-footer .primary-button {
    width: 100%;
  }
}

.sidebar {
  display: none !important;
}

@media print {
  :root {
    color-scheme: light;
  }

  body {
    background: #fff;
  }

  .app-shell {
    display: block;
  }

  .sidebar,
  .topbar-controls,
  .form-panel,
  .action-cell,
  .table-action,
  dialog {
    display: none !important;
  }

  .workspace {
    padding: 0;
  }

  .topbar {
    display: block;
    margin-bottom: 14px;
    border-bottom: 1px solid #ccd3dd;
    padding-bottom: 10px;
  }

  .view {
    display: none !important;
  }

  .view.active {
    display: block !important;
  }

  .panel,
  .metric {
    border-color: #ccd3dd;
    break-inside: avoid;
    box-shadow: none;
  }

  .data-layout,
  .split-layout {
    display: block;
  }

  .data-layout .panel,
  .split-layout .panel,
  .risk-panel,
  .quality-panel,
  .timeline-panel,
  .sku-balance-panel {
    margin-bottom: 12px;
  }

  .table-wrap {
    overflow: visible;
  }

  table {
    min-width: 0;
    font-size: 11px;
  }

  th,
  td {
    padding: 7px 6px;
  }
}
.dialog-actions {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 4px;
}

.dialog-actions > button {
  flex: 1 1 0;
}
