:root {
  color-scheme: light;
  --bg: #f6f8fb;
  --panel: #ffffff;
  --text: #172033;
  --muted: #667085;
  --line: #e4e7ec;
  --blue: #2563eb;
  --blue-soft: #eff6ff;
  --amber: #b45309;
  --green: #059669;
  --red: #dc2626;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.app-shell {
  display: grid;
  grid-template-columns: 216px minmax(0, 1fr);
  min-height: 100vh;
}
.app-sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  height: 100vh;
  padding: 22px 14px;
  border-right: 1px solid var(--line);
  background: #ffffff;
}
.sidebar-brand {
  min-width: 0;
  padding: 0 8px 18px;
  border-bottom: 1px solid var(--line);
}
.sidebar-brand strong {
  display: block;
  color: var(--text);
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0;
  white-space: nowrap;
}
.app-main {
  min-width: 0;
  max-width: 1520px;
  width: 100%;
  margin: 0 auto;
  padding: 24px;
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}
.topbar > .controls.system-global-controls,
.system-home-active .topbar > .controls.system-global-controls {
  display: none;
}
body:not(.system-home-active) .topbar > .controls.system-home-controls {
  display: none;
}
h1, h2, p { margin: 0; }
h1 { font-size: 26px; letter-spacing: 0; }
h2 { font-size: 16px; }
p, span, th, td { color: var(--muted); }
.controls {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.duty-admin-controls {
  align-items: center;
}
.duty-parttime-add {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.duty-parttime-add input {
  width: 150px;
  min-width: 0;
}
.duty-admin-panel {
  padding: 12px;
}
.duty-admin-panel > .panel-head {
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
}
.duty-admin-panel > .panel-head h2 {
  font-size: 15px;
}
.duty-admin-panel > .panel-head > div > span {
  margin-top: 2px;
  font-size: 11px;
  line-height: 1.35;
}
.duty-admin-panel .duty-admin-controls {
  gap: 6px;
}
.duty-admin-panel .duty-admin-controls input,
.duty-admin-panel .duty-admin-controls button {
  height: 32px;
  font-size: 13px;
}
.duty-admin-panel .duty-parttime-add input {
  width: 128px;
}
.page-scope-controls {
  justify-content: flex-end;
}
.page-account-select {
  min-width: 220px;
}
.page-window-select {
  min-width: 112px;
}
input, select, button {
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  padding: 0 10px;
  font-size: 14px;
}
button {
  border-color: var(--blue);
  background: var(--blue);
  color: white;
  cursor: pointer;
  white-space: nowrap;
}
.secondary-button {
  border-color: var(--line);
  background: #ffffff;
  color: var(--text);
}
.view-tabs {
  display: grid;
  gap: 6px;
  margin-top: 16px;
}
.tab-button {
  display: flex;
  align-items: center;
  width: 100%;
  min-width: 0;
  justify-content: flex-start;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  text-align: left;
}
.tab-button.active {
  border-color: #bfdbfe;
  color: var(--blue);
  background: var(--blue-soft);
}
.view { display: block; }
.system-home-panel,
.business-overview-panel,
.driver-workbench-panel,
.duty-workbench-panel,
.link-inspection-hero,
.fuel-revenue-hero {
  margin-bottom: 12px;
  border-color: #dbeafe;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}
.business-overview-panel .panel-head {
  margin-bottom: 12px;
}
.page-scope-controls .page-date-input {
  width: 140px;
}
.system-landing-panel {
  min-height: 0;
}
.system-home-controls {
  display: grid;
  grid-template-columns: minmax(0, 190px) 124px 124px 78px;
  justify-content: end;
  gap: 6px;
  flex: 0 0 auto;
  width: auto;
}
.system-home-controls select,
.system-home-controls input[type="search"] {
  width: 100%;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
.system-home-controls input {
  width: 100%;
  min-width: 0;
  padding: 0 8px;
}
.system-home-controls button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-width: 0;
  padding: 0 8px;
  white-space: nowrap;
  overflow: hidden;
  transition: transform .12s ease, opacity .12s ease, box-shadow .12s ease;
}
.system-home-controls button:active:not(:disabled) {
  transform: translateY(1px);
}
.system-home-controls button.is-loading {
  cursor: wait;
  opacity: .9;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
  animation: refreshButtonPulse 1.1s ease-in-out infinite;
}
.system-home-controls button.is-loading::after {
  content: "";
  width: 4px;
  height: 4px;
  margin-left: 5px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 7px 0 0 currentColor, 14px 0 0 currentColor;
}
@keyframes refreshButtonPulse {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-1px); }
}
.system-result-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(132px, 156px);
  gap: 10px;
}
.system-result-metrics article {
  min-width: 0;
  min-height: 96px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.system-result-metrics span,
.system-result-metrics em {
  display: block;
  min-width: 0;
  max-width: 100%;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.system-result-metrics span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.system-result-metrics strong {
  display: block;
  margin: 8px 0 6px;
  color: var(--text);
  font-size: clamp(20px, 2vw, 28px);
  line-height: 1.12;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.system-result-metrics .system-collector-card {
  padding: 12px 10px;
}
.system-result-metrics .system-collector-card strong {
  margin: 6px 0;
  font-size: clamp(18px, 1.45vw, 22px);
}
.system-result-metrics .collector-time-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2px;
  font-variant-numeric: tabular-nums;
}
.system-result-metrics .collector-date-line,
.system-result-metrics .collector-time-line {
  display: block;
  min-width: 0;
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}
.system-result-metrics .collector-date-line {
  color: var(--muted);
}
.system-result-metrics .collector-time-line {
  color: var(--text);
}
.fuel-revenue-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.driver-workbench-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.duty-workbench-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.link-inspection-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.fuel-revenue-metrics article,
.driver-workbench-metrics article,
.duty-workbench-metrics article,
.link-inspection-metrics article,
.fuel-tier-grid > div {
  min-width: 0;
  min-height: 92px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.fuel-revenue-metrics span,
.fuel-revenue-metrics em,
.driver-workbench-metrics span,
.driver-workbench-metrics em,
.duty-workbench-metrics span,
.duty-workbench-metrics em,
.link-inspection-metrics span,
.link-inspection-metrics em,
.fuel-tier-grid span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}
.fuel-revenue-metrics strong,
.driver-workbench-metrics strong,
.duty-workbench-metrics strong,
.link-inspection-metrics strong,
.fuel-tier-grid strong {
  display: block;
  margin-top: 8px;
  color: var(--text);
  font-size: clamp(18px, 1.7vw, 24px);
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.fuel-revenue-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}
.fuel-price-form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.fuel-price-modal-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 0;
}
.duty-config-grid,
.duty-schedule-grid,
.duty-plan-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 10px;
}
.duty-plan-panel {
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
}
.duty-admin-panel .duty-plan-panel {
  margin-bottom: 8px;
  padding: 10px;
}
.duty-plan-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  align-items: end;
}
.duty-admin-panel .duty-plan-grid {
  gap: 8px;
  margin-bottom: 6px;
}
.duty-planner {
  display: grid;
  grid-template-columns: minmax(250px, 280px) minmax(0, 1fr);
  align-items: stretch;
  gap: 10px;
  margin-bottom: 12px;
}
.duty-admin-panel .duty-planner {
  gap: 8px;
  margin-bottom: 8px;
}
.duty-anchor-pool,
.duty-timeline-shell {
  align-self: stretch;
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.duty-anchor-pool {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 8px;
  min-height: 0;
  overflow: hidden;
}
.duty-admin-panel .duty-anchor-pool,
.duty-admin-panel .duty-timeline-shell {
  padding: 10px;
}
.duty-admin-panel .duty-anchor-pool {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-items: stretch;
  gap: 8px;
}
.duty-admin-panel .duty-anchor-pool > .duty-planner-head {
  grid-column: auto;
}
.duty-planner-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.duty-admin-panel .duty-planner-head {
  gap: 8px;
  margin-bottom: 6px;
}
.duty-planner-head strong {
  color: var(--text);
  font-size: 14px;
}
.duty-anchor-pool > .duty-planner-head {
  gap: 8px;
}
.duty-anchor-pool > .duty-planner-head strong {
  white-space: nowrap;
}
.duty-anchor-pool > .duty-planner-head span {
  font-size: 11px;
  line-height: 1.35;
}
.duty-planner-head span {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  text-align: right;
  overflow-wrap: anywhere;
}
.duty-planner-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}
.duty-planner-head-actions span {
  min-width: 0;
}
.duty-planner-head-actions button {
  flex: 0 0 auto;
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}
.duty-card-section {
  display: grid;
  gap: 6px;
  min-height: 0;
  margin-top: 0;
}
.duty-admin-panel .duty-card-section {
  gap: 5px;
  margin-top: 0;
  min-width: 0;
}
.duty-card-section > strong {
  color: var(--muted);
  font-size: 12px;
}
.duty-card-section-fulltime {
  grid-template-rows: auto minmax(0, 1fr);
}
.duty-card-section-parttime {
  align-self: end;
  grid-template-rows: auto auto auto;
}
.duty-card-section-parttime .duty-parttime-add {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 5px;
  width: 100%;
}
.duty-card-section-parttime .duty-parttime-add input {
  width: 100%;
  height: 28px;
  min-width: 0;
  padding: 0 7px;
  font-size: 12px;
}
.duty-card-section-parttime .duty-parttime-add button {
  height: 28px;
  padding: 0 8px;
  font-size: 12px;
}
.duty-anchor-cards {
  display: grid;
  grid-auto-flow: row;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: 5px;
  min-height: 0;
  max-height: none;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 0 3px 2px 0;
}
.duty-card-section-fulltime .duty-anchor-cards {
  grid-template-columns: minmax(0, 1fr);
  height: 100%;
}
.duty-anchor-pallet-group {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.duty-anchor-pallet-group + .duty-anchor-pallet-group {
  margin-top: 4px;
}
.duty-anchor-pallet-group-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 5px;
  min-width: 0;
  padding: 3px 5px;
  border-radius: 6px;
  background: #f8fafc;
  color: #64748b;
}
.duty-anchor-pallet-group-head span,
.duty-anchor-pallet-group-head em {
  color: #64748b;
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.2;
}
.duty-anchor-pallet-group-head strong {
  min-width: 0;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-anchor-pallet-group-cards {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.duty-card-section-parttime .duty-anchor-cards {
  max-height: 100px;
}
.duty-admin-panel .duty-anchor-cards {
  grid-auto-columns: minmax(128px, 154px);
  grid-template-rows: minmax(48px, auto);
  gap: 6px;
  max-height: 56px;
}
.duty-operator-cards {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(104px, 130px);
  gap: 6px;
  max-width: 100%;
  overflow-x: auto;
  padding-bottom: 3px;
}
.duty-admin-panel .duty-operator-cards {
  grid-auto-columns: minmax(128px, 154px);
  gap: 6px;
  max-height: 56px;
}
.duty-anchor-card {
  position: relative;
  display: grid;
  place-items: center;
  gap: 0;
  width: 100%;
  height: auto;
  min-height: 30px;
  padding: 4px 7px;
  border: 1px solid #bfdbfe;
  border-left: 3px solid #2563eb;
  border-radius: 6px;
  background: #eff6ff;
  color: var(--text);
  text-align: center;
  cursor: grab;
  user-select: none;
}
.duty-admin-panel .duty-anchor-card {
  min-height: 48px;
  padding: 7px 8px;
}
.duty-card-section-fulltime .duty-anchor-card {
  min-height: 36px;
  padding: 6px 9px;
}
.duty-card-section-fulltime .duty-anchor-card strong {
  font-size: 12px;
}
.duty-anchor-card:active {
  cursor: grabbing;
}
.duty-anchor-card strong,
.duty-shift-chip strong {
  min-width: 0;
  color: var(--text);
  font-size: 11px;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-admin-panel .duty-anchor-card strong,
.duty-admin-panel .duty-shift-chip strong {
  font-size: 12px;
}
.duty-shift-chip strong {
  flex: 0 1 auto;
  max-width: 72px;
}
.duty-operator-zone .duty-shift-chip strong {
  max-width: 88px;
}
.duty-anchor-card span {
  display: none;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-admin-panel .duty-anchor-card span {
  font-size: 11px;
}
.duty-anchor-card.is-dragging,
.duty-shift-chip.is-dragging {
  opacity: .55;
}
.duty-anchor-card.is-selected {
  border-color: var(--blue);
  background: #eff6ff;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .2);
}
.duty-anchor-card.part-time {
  border-color: #ddd6fe;
  border-left-color: #7c3aed;
  background: #f5f3ff;
}
.duty-anchor-card.has-delete {
  padding-right: 22px;
}
.duty-anchor-delete {
  position: absolute;
  top: 3px;
  right: 3px;
  display: grid;
  place-items: center;
  width: 16px;
  min-width: 16px;
  height: 16px;
  min-height: 16px;
  padding: 0;
  border: 1px solid #c4b5fd;
  border-radius: 999px;
  background: #ffffff;
  color: #6d28d9;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}
.duty-anchor-delete:hover,
.duty-anchor-delete:focus {
  border-color: #7c3aed;
  background: #ede9fe;
  outline: none;
}
.duty-anchor-card.operator {
  border-color: #bbf7d0;
  border-left-color: #059669;
  background: #ecfdf5;
}
.duty-anchor-card.is-unavailable,
.duty-shift-chip.is-unavailable {
  border-color: #fecaca;
  background: #fff1f2;
}
.duty-timeline-shell {
  overflow-x: auto;
}
.duty-admin-panel .duty-timeline-shell {
  overflow-x: auto;
  overflow-y: hidden;
}
.duty-timeline-header,
.duty-timeline-slots {
  display: grid;
  min-width: 740px;
}
.duty-timeline-header {
  grid-template-columns: minmax(132px, .8fr) minmax(150px, .9fr) minmax(180px, 1.15fr) minmax(86px, .55fr) minmax(126px, .75fr);
  gap: 5px;
  margin-bottom: 5px;
}
.duty-admin-panel .duty-timeline-header {
  gap: 5px;
  margin-bottom: 5px;
}
.duty-timeline-header div {
  min-height: 28px;
  padding: 5px 6px;
  border: 1px solid #e0e7ff;
  border-radius: 6px;
  background: #eef2ff;
  color: #3730a3;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}
.duty-admin-panel .duty-timeline-header div {
  min-height: 28px;
  padding: 5px 6px;
  font-size: 11px;
}
.duty-timeline-slots {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: 5px;
}
.duty-admin-panel .duty-timeline-slots {
  gap: 5px;
  max-height: min(48vh, 430px);
  overflow-y: auto;
  padding-right: 3px;
}
.duty-pallet-editor {
  display: grid;
  gap: 8px;
  min-width: 740px;
  margin: 0 0 10px;
  padding: 8px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #f8fbff;
}
.duty-pallet-editor.is-focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}
.duty-pallet-editor-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}
.duty-pallet-editor-head strong {
  color: var(--text);
  font-size: 13px;
}
.duty-pallet-editor-head span {
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  text-align: right;
}
.duty-pallet-edit-buttons {
  display: flex;
  gap: 6px;
  min-width: 0;
  overflow-x: auto;
  padding-bottom: 2px;
}
.duty-pallet-edit-button {
  flex: 0 0 auto;
  height: 28px;
  padding: 0 10px;
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 12px;
}
.duty-pallet-edit-button.is-active {
  border-color: var(--blue);
  background: var(--blue);
  color: #ffffff;
}
.duty-pallet-editor-empty {
  display: grid;
  place-items: center;
  min-height: 28px;
  color: #94a3b8;
  font-size: 12px;
}
.duty-pallet-editor-fields {
  display: grid;
  grid-template-columns: minmax(120px, .8fr) minmax(160px, 1fr) minmax(160px, 1fr) minmax(160px, 1fr);
  gap: 8px;
}
.duty-pallet-editor-fields label {
  display: grid;
  gap: 4px;
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
}
.duty-pallet-editor-fields input {
  width: 100%;
  height: 30px;
  min-width: 0;
  padding: 0 8px;
  font-size: 12px;
}
.duty-pallet-editor-fields input[disabled] {
  background: #f1f5f9;
  color: var(--text);
  opacity: 1;
}
.duty-timeline-slots.is-merged {
  grid-auto-flow: row;
}
.duty-timeline-slots.is-merged > * {
  min-width: 0;
}
.duty-time-slot {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr) minmax(260px, 1.45fr) minmax(112px, .65fr) minmax(178px, .9fr);
  align-content: start;
  align-items: stretch;
  gap: 6px;
  min-height: 104px;
  padding: 8px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  transition: border-color .12s ease, background .12s ease, box-shadow .12s ease;
}
.duty-slot-pallet {
  display: grid;
  align-content: center;
  justify-items: stretch;
  gap: 4px;
  min-height: 48px;
  padding: 5px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
  text-align: center;
}
.duty-admin-panel .duty-slot-pallet {
  min-height: 46px;
  padding: 5px;
}
.duty-slot-pallet.duty-merged-cell {
  min-height: 100%;
  border-color: #d9e2ef;
  background: #f8fafc;
}
.duty-slot-pallet strong {
  color: var(--text);
  font-size: 12px;
}
.duty-pallet-time-fields {
  display: grid;
  gap: 5px;
}
.duty-pallet-time-fields label {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.2;
  text-align: left;
}
.duty-pallet-select-label {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.2;
  text-align: left;
}
.duty-slot-pallet input,
.duty-slot-pallet select {
  width: 100%;
  height: 25px;
  min-width: 0;
  padding: 0 7px;
  font-size: 12px;
  text-align: center;
}
.duty-slot-pallet select {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--text);
}
.duty-slot-pallet input[type="datetime-local"] {
  height: 26px;
  padding: 0 4px;
  font-size: 11px;
}
.duty-admin-panel .duty-slot-pallet input,
.duty-admin-panel .duty-slot-pallet select {
  height: 25px;
  font-size: 11px;
}
.duty-slot-pallet span {
  color: #64748b;
  font-size: 11px;
  line-height: 1.35;
}
.duty-admin-panel .duty-slot-pallet span {
  font-size: 10px;
}
.duty-time-slot > span {
  display: grid;
  place-items: center;
  min-height: 42px;
  border-radius: 6px;
  background: #f8fafc;
  color: #94a3b8;
  font-size: 12px;
}
.duty-drop-zone {
  display: grid;
  align-content: center;
  justify-items: stretch;
  gap: 3px;
  min-height: 46px;
  padding: 4px;
  border: 1px dashed #cbd5e1;
  border-radius: 7px;
  background: #f8fafc;
  text-align: center;
}
.duty-admin-panel .duty-drop-zone {
  min-height: 44px;
  padding: 4px;
}
.duty-drop-zone.duty-operator-zone {
  min-height: 100%;
  border-color: #bbf7d0;
  background: #ecfdf5;
}
.duty-operator-stack-cell {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 26px;
  min-height: 46px;
  padding: 8px;
  border: 1px solid #bbf7d0;
  border-radius: 7px;
  background: #f0fdf4;
}
.duty-drop-zone.duty-operator-zone.duty-operator-fixed-zone {
  align-content: start;
  gap: 10px;
  min-height: 118px;
  padding: 12px 10px;
  border-radius: 12px;
}
.duty-admin-panel .duty-drop-zone.duty-operator-zone.duty-operator-fixed-zone {
  min-height: 112px;
  padding: 11px 9px;
}
.duty-operator-stack-empty {
  display: grid;
  place-items: center;
  min-height: 40px;
  color: #94a3b8;
  font-size: 11px;
  text-align: center;
}
.duty-drop-zone.duty-anchor-zone {
  border-color: #bfdbfe;
  background: #eff6ff;
}
.duty-drop-zone.duty-anchor-zone.is-previous-day-slot {
  border-color: #2563eb;
  background: #dbeafe;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .24);
}
.duty-drop-zone.duty-anchor-zone.is-previous-day-slot > span {
  color: #60a5fa;
}
.duty-zone-title {
  display: block;
  color: #065f46;
  font-size: 11px;
  line-height: 1.25;
  text-align: center;
}
.duty-admin-panel .duty-zone-title {
  font-size: 11px;
  line-height: 1.25;
}
.duty-zone-title span {
  color: #047857;
  font-weight: 500;
}
.duty-operator-title {
  color: #065f46;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1.1;
}
.duty-admin-panel .duty-operator-title {
  font-size: 18px;
}
.duty-operator-name-area {
  display: grid;
  gap: 8px;
  justify-items: stretch;
  min-width: 0;
}
.duty-operator-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  width: 100%;
  min-width: 0;
}
.duty-operator-name-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 74px;
  max-width: 100%;
  min-height: 28px;
  padding: 4px 22px 4px 10px;
  border: 1px solid #86efac;
  border-radius: 8px;
  background: #ffffff;
  color: var(--text);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
}
.duty-operator-name-chip span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-operator-name-chip.is-risk {
  border-color: #f59e0b;
  background: #fffbeb;
}
.duty-operator-name-chip.is-unavailable {
  border-color: #fca5a5;
  background: #fff1f2;
}
.duty-operator-empty {
  display: grid;
  place-items: center;
  min-height: 28px;
  border: 1px dashed #86efac;
  border-radius: 8px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}
.duty-operator-select {
  display: grid;
  width: 100%;
  min-width: 0;
}
.duty-operator-select select {
  width: 100%;
  min-width: 0;
  height: 30px;
  padding: 0 6px;
  border: 1px solid #86efac;
  border-radius: 8px;
  background: #ffffff;
  color: var(--text);
  font-size: 11px;
  font-weight: 800;
  text-align: center;
  text-align-last: center;
}
.duty-operator-select option {
  text-align: center;
}
.duty-operator-select em {
  color: #047857;
  font-size: 10px;
  font-style: normal;
  line-height: 1.35;
}
.duty-operator-time-hint {
  display: block;
  width: 100%;
  color: #047857;
  font-size: 10px;
  line-height: 1.35;
  text-align: center;
}
.duty-operator-coverage {
  display: block;
  width: 100%;
  color: #047857;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
  text-align: center;
}
.duty-drop-zone > span {
  display: grid;
  place-items: center;
  min-height: 32px;
  color: #94a3b8;
  font-size: 12px;
}
.duty-admin-panel .duty-drop-zone > span {
  min-height: 34px;
  font-size: 11px;
}
.duty-drop-zone.is-over {
  border-color: var(--blue);
  background: #eff6ff;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .18);
}
.duty-drop-zone.is-replace-target {
  border-color: #f59e0b;
  background: #fffbeb;
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, .2);
}
.duty-previous-shift-hint {
  display: block;
  width: 100%;
  min-width: 0;
  padding: 4px 6px;
  border: 1px solid #93c5fd;
  border-radius: 6px;
  background: #dbeafe;
  color: #1d4ed8;
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.25;
  overflow: visible;
  text-align: center;
  text-overflow: clip;
  white-space: normal;
}
.duty-previous-shift-hint.is-empty {
  border-color: #cbd5e1;
  background: #f1f5f9;
  color: #64748b;
}
.duty-previous-shift-hint.is-warning {
  border-color: #f59e0b;
  background: #fffbeb;
  color: #92400e;
}
.duty-previous-shift-hint.is-danger {
  border-color: #fecaca;
  background: #fff1f2;
  color: #b91c1c;
}
.duty-previous-slot-marker {
  display: block;
  width: 100%;
  min-width: 0;
  padding: 4px 6px;
  border: 1px solid #93c5fd;
  border-radius: 6px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  line-height: 1.3;
  overflow: visible;
  text-align: center;
  text-overflow: clip;
  white-space: normal;
}
.duty-shift-chip {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
  min-height: 28px;
  padding: 3px 20px 3px 6px;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #f8fbff;
  cursor: default;
  text-align: left;
}
.duty-shift-chip.is-movable {
  cursor: grab;
}
.duty-shift-chip.is-movable:active {
  cursor: grabbing;
}
.duty-admin-panel .duty-shift-chip {
  min-height: 30px;
  padding: 4px 22px 4px 6px;
}
.duty-operator-zone .duty-shift-chip {
  min-height: 26px;
  padding: 3px 20px 3px 6px;
}
.duty-shift-chip.operator {
  border-color: #bbf7d0;
  background: #ecfdf5;
}
.duty-shift-chip.is-risk {
  border-color: #f59e0b;
  background: #fffbeb;
}
.duty-shift-chip span,
.duty-shift-chip em {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 112px;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-admin-panel .duty-shift-chip span,
.duty-admin-panel .duty-shift-chip em {
  font-size: 10px;
  line-height: 1.25;
}
.duty-shift-hours-select {
  flex: 0 0 auto;
  justify-self: center;
  width: 56px;
  height: 20px;
  padding: 0 4px;
  border: 1px solid #bfdbfe;
  border-radius: 5px;
  background: #ffffff;
  color: #1e3a8a;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
}
.duty-shift-chip.is-risk .duty-shift-hours-select {
  border-color: #f59e0b;
  color: #92400e;
}
.duty-shift-remove {
  position: absolute;
  top: 50%;
  right: 4px;
  transform: translateY(-50%);
  display: inline-grid;
  place-items: center;
  width: 14px;
  min-width: 14px;
  height: 14px;
  padding: 0;
  border: 1px solid #fecaca;
  border-radius: 999px;
  background: #fff1f2;
  color: #b91c1c;
  font-size: 12px;
  line-height: 1;
}
.duty-roster-time,
.duty-roster-hours {
  display: grid;
  align-content: center;
  min-height: 46px;
  padding: 4px;
  border: 1px solid #e2e8f0;
  border-radius: 7px;
  background: #ffffff;
  color: var(--text);
  font-size: 11px;
  line-height: 1.35;
  text-align: center;
}
.duty-admin-panel .duty-roster-time,
.duty-admin-panel .duty-roster-hours {
  min-height: 44px;
  padding: 4px;
  font-size: 11px;
}
.duty-admin-panel .duty-roster-hours strong {
  font-size: 11px;
}
.duty-admin-panel .duty-roster-hours span {
  font-size: 10px;
}
.duty-roster-time {
  gap: 2px;
  justify-items: center;
}
.duty-roster-time-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-width: 0;
  white-space: nowrap;
}
.duty-roster-time-item strong {
  font-size: 11px;
}
.duty-roster-time-item span {
  color: var(--muted);
  font-size: 10px;
}
.duty-roster-time-item.is-custom strong,
.duty-roster-time-item.is-custom span {
  color: #92400e;
}
.duty-roster-hours {
  gap: 2px;
  justify-items: center;
}
.duty-roster-hour-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-width: 0;
  white-space: nowrap;
}
.duty-roster-hours strong {
  font-size: 11px;
}
.duty-roster-hours span {
  color: var(--muted);
  font-size: 10px;
}
.duty-roster-empty {
  color: #94a3b8;
}
.fuel-price-form-grid label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
}
.duty-config-grid label,
.duty-schedule-grid label,
.duty-plan-grid label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
}
.duty-admin-panel .duty-schedule-grid {
  gap: 8px;
  margin-bottom: 6px;
}
.duty-admin-panel .duty-schedule-grid input {
  height: 32px;
}
.fuel-price-form-grid .wide {
  grid-column: span 4;
}
.fuel-price-modal-grid .wide {
  grid-column: span 2;
}
.fuel-tier-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
}
.fuel-tier-converted textarea {
  background: #f8fafc;
  color: var(--text);
  cursor: default;
}
.duty-config-grid .wide,
.duty-schedule-grid .wide {
  grid-column: span 4;
}
.fuel-price-form-grid textarea {
  min-height: 92px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  font: inherit;
  line-height: 1.5;
}
.fuel-rule-status-row {
  display: flex;
  align-items: center;
  min-height: 28px;
  margin-bottom: 8px;
  font-size: 13px;
}
.duty-status-row,
.duty-window-preview {
  display: flex;
  align-items: center;
  min-height: 30px;
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.duty-admin-panel .duty-status-row,
.duty-admin-panel .duty-window-preview {
  min-height: 24px;
  margin-top: 4px;
  font-size: 12px;
  line-height: 1.35;
}
.duty-status-row.ok {
  color: var(--green);
}
.duty-status-row.bad {
  color: var(--red);
}
.driver-workbench-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(142px, 160px)) minmax(72px, 88px);
  gap: 6px;
  align-items: center;
}
.driver-workbench-controls input,
.driver-workbench-controls button {
  width: 100%;
}
.driver-status-line {
  min-height: 22px;
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.driver-status-line.ok {
  color: var(--green);
}
.driver-status-line.warn,
.driver-status-line.bad {
  color: var(--red);
}
.driver-pallet-list {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.driver-pallet-chip {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 6px 8px;
  border: 1px solid #dbeafe;
  border-radius: 6px;
  background: #eff6ff;
}
.driver-pallet-chip strong {
  color: var(--text);
  font-size: 12px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.driver-pallet-chip em,
.driver-pallet-more {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.driver-shift-detail {
  display: grid;
  gap: 2px;
  margin-top: 6px;
}
.driver-shift-detail span {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.driver-status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.driver-status-badge.driver-good {
  color: #047857;
  background: #d1fae5;
}
.driver-status-badge.driver-normal {
  color: #1d4ed8;
  background: #dbeafe;
}
.driver-status-badge.driver-warn {
  color: #b45309;
  background: #fef3c7;
}
.duty-window-preview {
  padding: 8px 10px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  color: #1d4ed8;
}
.fuel-rule-table-wrap {
  width: 100%;
  overflow-x: auto;
}
.driver-workbench-table-wrap {
  width: 100%;
  overflow-x: auto;
}
.duty-workbench-table-wrap {
  width: 100%;
  overflow-x: auto;
}
.duty-calendar-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, .9fr);
  gap: 14px;
  align-items: start;
}
.duty-calendar-panel,
.duty-calendar-detail {
  min-width: 0;
}
.duty-calendar-panel {
  overflow-x: auto;
}
.duty-calendar-title,
.duty-calendar-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.duty-calendar-title strong,
.duty-calendar-detail-head strong {
  color: var(--text);
  font-size: 15px;
}
.duty-calendar-title span,
.duty-calendar-detail-head span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  text-align: right;
}
.duty-calendar-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin: -2px 0 10px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafc;
}
.duty-calendar-tabs button {
  height: 28px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.duty-calendar-tabs button.active {
  background: #2563eb;
  color: #ffffff;
  box-shadow: 0 1px 3px rgba(37, 99, 235, .18);
}
.duty-calendar-tabs button:focus-visible {
  outline: 2px solid #93c5fd;
  outline-offset: 1px;
}
.duty-calendar-weekdays,
.duty-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}
.duty-calendar-weekdays {
  margin-bottom: 6px;
}
.duty-calendar-weekdays span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}
.duty-calendar-day {
  min-height: 88px;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #ffffff;
  overflow: visible;
}
.duty-calendar-day.is-current {
  border-color: #93c5fd;
  background: #eff6ff;
}
.duty-calendar-day.is-blank {
  border-color: transparent;
  background: transparent;
}
.duty-calendar-day-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  margin-bottom: 6px;
  min-height: 16px;
}
.duty-calendar-day-head strong {
  color: var(--muted);
  font-size: 12px;
  line-height: 1;
}
.duty-calendar-night-badge {
  display: inline-grid;
  place-items: center;
  height: 16px;
  min-width: 34px;
  padding: 0 5px;
  border-radius: 999px;
  background: #111827;
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}
.duty-calendar-pallets {
  display: grid;
  gap: 4px;
}
.duty-calendar-pallet-wrap {
  position: relative;
  display: grid;
  gap: 4px;
  min-width: 0;
}
.duty-calendar-pallet {
  width: 100%;
  height: 24px;
  min-width: 0;
  padding: 0 8px;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #f8fafc;
  color: var(--text);
  font: inherit;
  font-size: 12px;
  line-height: 22px;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}
.duty-calendar-pallet:hover,
.duty-calendar-pallet:focus-visible {
  border-color: #2563eb;
  outline: none;
}
.duty-calendar-pallet.active {
  border-color: #2563eb;
  background: #2563eb;
  color: #ffffff;
}
.duty-calendar-pallet-actions {
  display: none;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
}
.duty-calendar-pallet-wrap.is-action-open .duty-calendar-pallet-actions {
  display: grid;
}
.duty-calendar-pallet-edit {
  display: grid;
  place-items: center;
  width: 100%;
  height: 20px;
  padding: 0;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #eff6ff;
  color: #1d4ed8;
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}
.duty-calendar-pallet-delete {
  display: grid;
  place-items: center;
  width: 100%;
  height: 20px;
  padding: 0;
  border: 1px solid #fecaca;
  border-radius: 6px;
  background: #fff1f2;
  color: #b91c1c;
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}
.duty-calendar-pallet-edit:hover,
.duty-calendar-pallet-edit:focus-visible {
  background: #2563eb;
  color: #ffffff;
  outline: none;
}
.duty-calendar-pallet-delete:hover,
.duty-calendar-pallet-delete:focus-visible {
  background: #ef4444;
  color: #ffffff;
  outline: none;
}
.duty-calendar-detail {
  padding-left: 14px;
  border-left: 1px solid var(--line);
}
.duty-calendar-detail-rows {
  display: grid;
  gap: 10px;
}
.duty-calendar-detail-section {
  display: grid;
  gap: 8px;
  min-width: 0;
}
.duty-calendar-detail-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafc;
}
.duty-calendar-detail-section-head strong {
  color: var(--text);
  font-size: 13px;
}
.duty-calendar-detail-section-head span {
  color: var(--muted);
  font-size: 12px;
}
.duty-calendar-detail-section-body {
  display: grid;
  gap: 8px;
}
.duty-calendar-detail-section.is-anchor .duty-calendar-detail-section-body {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.duty-calendar-detail-card {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #ffffff;
}
.duty-calendar-detail-card.is-risk {
  border-color: #fecaca;
  background: #fef2f2;
}
.duty-calendar-detail-card div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.duty-calendar-detail-card strong {
  color: var(--text);
  font-size: 14px;
}
.duty-calendar-detail-card span,
.duty-calendar-detail-card small,
.duty-calendar-detail-card em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}
.duty-calendar-detail-card p {
  margin: 6px 0 3px;
  color: var(--text);
  font-size: 13px;
}
.duty-night-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.duty-night-summary-grid article {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafc;
}
.duty-night-summary-grid span,
.duty-night-summary-grid em {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}
.duty-night-summary-grid strong {
  display: block;
  margin: 3px 0;
  color: var(--text);
  font-size: 18px;
  line-height: 1.2;
  word-break: break-word;
}
.duty-night-table-wrap {
  width: 100%;
  overflow-x: hidden;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #ffffff;
}
.duty-night-table {
  width: calc(100% - 8px);
  min-width: 0;
  border-collapse: collapse;
  border-spacing: 0;
  box-sizing: border-box;
  table-layout: fixed;
}
.duty-night-col-anchor {
  width: 30%;
}
.duty-night-col-count,
.duty-night-col-days,
.duty-night-col-streak,
.duty-night-col-latest,
.duty-night-col-action {
  width: 14%;
}
.duty-night-table th,
.duty-night-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
  vertical-align: middle;
}
.duty-night-table th:first-child,
.duty-night-table td:first-child {
  text-align: left;
}
.duty-night-table th {
  background: #f8fafc;
  color: var(--muted);
  font-weight: 800;
  white-space: nowrap;
}
.duty-night-table td:first-child strong,
.duty-night-table td:first-child span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-night-table tr:last-child td {
  border-bottom: 0;
}
.duty-night-table td:nth-child(2),
.duty-night-table td:nth-child(3),
.duty-night-table td:nth-child(4),
.duty-night-table td:nth-child(5) {
  white-space: nowrap;
}
.duty-night-table td strong,
.duty-night-table td span {
  display: block;
}
.duty-night-table td span {
  margin-top: 2px;
  color: var(--muted);
}
.duty-night-table tr.is-expanded > td {
  background: #f8fafc;
}
.duty-night-detail-toggle {
  min-width: 54px;
  height: 28px;
  padding: 0 10px;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #eff6ff;
  color: #1d4ed8;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.duty-night-detail-toggle:hover,
.duty-night-detail-toggle:focus-visible,
.duty-night-detail-toggle.is-open {
  border-color: #2563eb;
  background: #2563eb;
  color: #ffffff;
  outline: none;
}
.duty-night-detail-none {
  display: inline-block;
  color: var(--muted);
  font-size: 12px;
}
.duty-night-detail-row td {
  padding: 0;
  background: #f8fafc;
}
.duty-night-detail-panel {
  display: grid;
  gap: 6px;
  padding: 8px 10px 10px;
  border-top: 1px solid #bfdbfe;
  background: #f8fafc;
}
.duty-night-detail-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}
.duty-night-detail-chip {
  display: grid;
  grid-template-columns: auto minmax(64px, 1fr);
  grid-template-areas:
    "date pallet"
    "time time";
  column-gap: 6px;
  row-gap: 2px;
  min-width: 132px;
  max-width: 190px;
  padding: 6px 7px;
  border: 1px solid #bfdbfe;
  border-radius: 7px;
  background: #eff6ff;
}
.duty-night-detail-chip strong {
  grid-area: date;
  color: #1d4ed8;
  font-size: 12px;
  line-height: 1.2;
  white-space: nowrap;
}
.duty-night-detail-chip em {
  grid-area: pallet;
  color: var(--text);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-night-detail-chip small {
  grid-area: time;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}
.duty-night-detail-more,
.duty-night-detail-empty {
  display: inline-grid;
  place-items: center;
  min-height: 42px;
  padding: 6px 10px;
  border: 1px dashed var(--line);
  border-radius: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.duty-night-detail-more {
  border-style: solid;
  background: #f8fafc;
  color: #1d4ed8;
}
.duty-calendar-empty {
  grid-column: 1 / -1;
  min-height: 96px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line);
  border-radius: 7px;
  color: var(--muted);
  font-size: 13px;
}
.duty-calendar-empty.compact {
  min-height: 46px;
  font-size: 12px;
}
.link-inspection-table-wrap {
  width: 100%;
  overflow-x: auto;
}
.fuel-rule-table {
  width: 100%;
  min-width: 840px;
  border-collapse: collapse;
  table-layout: fixed;
}
.driver-workbench-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}
.duty-workbench-table {
  width: 100%;
  min-width: 1080px;
  border-collapse: collapse;
}
.link-inspection-table {
  width: 100%;
  min-width: 1080px;
  border-collapse: collapse;
}
.fuel-rule-table th,
.fuel-rule-table td,
.driver-workbench-table th,
.driver-workbench-table td,
.duty-workbench-table th,
.duty-workbench-table td,
.link-inspection-table th,
.link-inspection-table td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.link-inspection-table td:first-child {
  min-width: 92px;
  max-width: 120px;
  white-space: nowrap;
}
.fuel-rule-table th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.fuel-rule-table th:nth-child(1) { width: 22%; }
.fuel-rule-table th:nth-child(2) { width: 22%; }
.fuel-rule-table th:nth-child(3) { width: 18%; }
.fuel-rule-table th:nth-child(4) { width: 11%; }
.fuel-rule-table th:nth-child(5) { width: 13%; }
.fuel-rule-table th:nth-child(6) { width: 9%; }
.fuel-rule-table th:nth-child(7) { width: 5%; }
.fuel-rule-table td {
  color: var(--text);
  overflow-wrap: anywhere;
  line-height: 1.35;
}
.fuel-rule-table td strong {
  display: block;
  font-weight: 700;
}
.fuel-rule-table td span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}
.fuel-rule-status-badge {
  color: var(--muted);
}
.fuel-rule-status-badge.active {
  color: #15803d;
}
.fuel-rule-status-badge.pending {
  color: #1d4ed8;
}
.fuel-rule-status-badge.expired {
  color: #64748b;
}
.fuel-rule-account-cell strong,
.fuel-rule-name-cell strong {
  line-height: 1.35;
}
.fuel-rule-table .table-action {
  width: 100%;
  min-width: 44px;
  padding: 0 6px;
}
.fuel-tier-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}
.system-status-good {
  color: #15803d !important;
}
.system-status-bad {
  color: #b91c1c !important;
}
.system-status-neutral {
  color: var(--text) !important;
}
.system-account-results {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}
.system-account-card {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.system-account-card[data-system-account-jump] {
  cursor: pointer;
  transition: border-color .12s ease, box-shadow .12s ease, background-color .12s ease;
}
.system-account-card[data-system-account-jump]:hover {
  border-color: #93c5fd;
  background: #fbfdff;
  box-shadow: 0 6px 18px rgba(15, 23, 42, .06);
}
.system-account-card[data-system-account-jump]:focus-visible {
  outline: 3px solid rgba(37, 99, 235, .22);
  outline-offset: 2px;
}
.system-account-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.system-account-card-head > div {
  min-width: 0;
}
.system-account-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}
.system-account-card h3 {
  margin: 0;
  min-width: 0;
  color: var(--text);
  font-size: 16px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.account-type-badge {
  flex: 0 0 auto;
  max-width: 88px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  line-height: 1.25;
  white-space: nowrap;
}
.account-type-badge.external_creator {
  background: #fef3c7;
  color: #92400e;
}
.account-extra-badge {
  flex: 0 0 auto;
  max-width: 88px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #ecfdf5;
  color: #047857;
  font-size: 11px;
  line-height: 1.25;
  white-space: nowrap;
}
.system-account-card .result-headline {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.system-result-badge {
  flex: 0 0 auto;
  max-width: 92px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #eef2ff;
  color: #3730a3;
  font-size: 12px;
  line-height: 1.25;
  text-align: center;
}
.system-result-badge.good {
  background: #dcfce7;
  color: #166534;
}
.system-result-badge.warn {
  background: #fef3c7;
  color: #92400e;
}
.system-result-badge.bad {
  background: #fee2e2;
  color: #991b1b;
}
.link-inspection-controls {
  justify-content: flex-end;
}
.link-inspection-controls input {
  width: 140px;
}
.link-inspection-controls button {
  min-width: 76px;
}
.link-inspection-controls button.is-loading {
  opacity: .88;
  cursor: wait;
}
.link-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  max-width: 100%;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}
.link-status-badge.ok {
  background: #dcfce7;
  color: #166534;
}
.link-status-badge.warn {
  background: #fef3c7;
  color: #92400e;
}
.link-status-badge.bad {
  background: #fee2e2;
  color: #991b1b;
}
.link-status-badge.neutral {
  background: #f1f5f9;
  color: #475569;
}
.link-chain-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
  gap: 8px;
}
.link-chain-step {
  min-width: 0;
  min-height: 112px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.link-chain-step.ok {
  border-color: #bbf7d0;
  background: #f0fdf4;
}
.link-chain-step.warn {
  border-color: #fde68a;
  background: #fffbeb;
}
.link-chain-step.bad {
  border-color: #fecaca;
  background: #fff1f2;
}
.link-chain-step strong,
.link-chain-step span,
.link-chain-step em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}
.link-chain-step strong {
  margin: 8px 0 5px;
  color: var(--text);
  font-size: 14px;
  line-height: 1.3;
}
.link-chain-step span,
.link-chain-step em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}
.link-inspection-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(320px, .6fr);
  gap: 12px;
  margin-top: 12px;
}
.link-run-list {
  display: grid;
  gap: 8px;
  max-height: 560px;
  overflow: auto;
  scrollbar-gutter: stable;
}
.link-run-card {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.link-run-card > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}
.link-run-card strong,
.link-run-card span,
.link-run-card em,
.link-run-card p {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}
.link-run-card strong {
  color: var(--text);
  font-size: 14px;
}
.link-run-card span,
.link-run-card em,
.link-run-card p {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}
.link-run-card p {
  margin: 6px 0 0;
  color: var(--red);
}
.link-raw-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.link-raw-grid article {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.link-raw-grid span,
.link-raw-grid strong,
.link-raw-grid em {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}
.link-raw-grid span,
.link-raw-grid em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}
.link-raw-grid strong {
  margin: 7px 0 4px;
  color: var(--text);
  font-size: 22px;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}
.link-issue-cell {
  min-width: 220px;
  max-width: 360px;
  white-space: normal !important;
  overflow-wrap: anywhere;
}
.system-account-grid {
  display: grid;
  grid-template-columns: minmax(116px, 0.78fr) minmax(128px, 0.9fr) minmax(108px, 0.78fr) minmax(260px, 1.54fr);
  gap: 8px;
}
.system-account-grid div {
  min-width: 0;
  min-height: 64px;
  padding: 9px 10px;
  border-radius: 8px;
  background: #f8fafc;
}
.system-account-grid span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.3;
}
.system-account-grid em {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.system-account-grid strong {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.system-account-grid .system-live-type-tile {
  background: #f8fbff;
}
.system-account-grid .system-live-type-tile strong {
  font-size: 14px;
}
.system-account-grid .system-live-type-tile em {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.35;
}
.system-account-grid .system-profit-status-tile {
  grid-column: 6;
  grid-row: 1 / span 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.system-account-grid .system-profit-status-tile strong {
  font-size: 18px;
  line-height: 1.15;
}
.system-home-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.system-home-metrics article {
  min-width: 0;
  min-height: 88px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.system-home-metrics span,
.system-home-metrics em {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}
.system-home-metrics strong {
  display: block;
  margin: 8px 0 6px;
  color: var(--text);
  font-size: clamp(18px, 1.6vw, 24px);
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.system-home-metrics .verification-metric {
  grid-column: span 1;
  min-height: 76px;
}
.system-home-metrics .verification-rate-metric {
  grid-column: span 1;
}
.pinned-profit-panel {
  margin-bottom: 12px;
}
#accountLiveDetail {
  scroll-margin-top: 16px;
}
.profit-controls input {
  width: 140px;
}
.profit-summary {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 10px;
}
.profit-summary .insight {
  min-height: 76px;
}
.profit-summary .insight strong {
  font-size: 20px;
}
.profit-calculator {
  margin: 10px 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.profit-calculator-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.profit-calculator-head span {
  display: block;
  margin-top: 4px;
  font-size: 12px;
}
.profit-calculator-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}
.profit-calculator label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
}
.profit-calculator input,
.profit-calculator select {
  width: 100%;
}
.profit-account-name {
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text);
  display: flex;
  font-size: 14px;
  font-weight: 700;
  min-height: 38px;
  overflow: hidden;
  padding: 0 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.profit-calc-remark {
  width: 100%;
  margin-top: 8px;
}
.profit-calc-preview {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}
.profit-calc-preview .compact-metric {
  min-height: 68px;
  background: #ffffff;
}
.profit-table-wrap {
  overflow-x: auto;
  scrollbar-gutter: stable;
}
.profit-table {
  min-width: 1480px;
  margin-top: 4px;
}
.profit-status {
  display: inline-block;
  min-width: 52px;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 12px;
  text-align: center;
}
.profit-good {
  background: #dcfce7;
  color: #166534;
}
.profit-bad {
  background: #fee2e2;
  color: #991b1b;
}
.profit-neutral {
  background: #eef2ff;
  color: #3730a3;
}
.profit-rule-popover {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.profit-rule-button {
  width: 34px;
  min-width: 34px;
  padding: 0;
  border-radius: 999px;
  font-weight: 700;
}
.profit-rule-tooltip {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 20;
  display: none;
  width: min(520px, calc(100vw - 48px));
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--text);
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.14);
  font-size: 12px;
  line-height: 1.6;
  white-space: normal;
}
.profit-rule-tooltip.bad {
  border-color: #fecaca;
  color: #991b1b;
}
.profit-rule-popover:hover .profit-rule-tooltip,
.profit-rule-popover:focus-within .profit-rule-tooltip {
  display: block;
}
.money-cell span,
.profit-table td span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}
.table-action {
  height: 28px;
  padding: 0 8px;
  border-color: var(--line);
  background: #ffffff;
  color: var(--text);
  font-size: 12px;
}
.danger-action {
  border-color: #fecaca;
  color: #b42318;
}
.scopebar, .status, .metrics, .grid {
  display: grid;
  gap: 12px;
  margin-bottom: 12px;
}
.scopebar { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
.status { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.metrics { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.grid {
  grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr);
  align-items: start;
}
.detail-grid { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); }
.scopebar > div, .status > div, .metrics article, .panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}
.scopebar > div, .status > div, .metrics article {
  padding: 14px;
}
.scopebar span, .status span, .metrics span {
  display: block;
  font-size: 13px;
  margin-bottom: 8px;
}
.scopebar strong, .status strong, .metrics strong {
  display: block;
  min-height: 28px;
  font-size: 22px;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}
.scopebar strong {
  min-height: auto;
  color: var(--text);
  font-size: 15px;
  line-height: 1.35;
}
.metrics article:nth-child(1), .metrics article:nth-child(6) {
  background: var(--blue-soft);
  border-color: #bfdbfe;
}
.account-live-detail {
  margin-bottom: 12px;
}
.account-today-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.account-today-metrics article {
  min-height: 96px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.account-today-metrics article:nth-child(1) {
  border-color: #bfdbfe;
  background: #eff6ff;
}
.account-today-metrics article:nth-child(2) {
  border-color: #fed7aa;
  background: #fff7ed;
}
.account-today-metrics article:nth-child(3) {
  border-color: #bbf7d0;
  background: #f0fdf4;
}
.account-today-metrics span {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
}
.account-today-metrics strong {
  display: block;
  min-height: 30px;
  color: var(--text);
  font-size: 24px;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}
.account-analysis-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.account-analysis-wide {
  grid-column: 1 / -1;
}
.account-conclusion-panel {
  margin-top: 12px;
}
.conclusion-headline {
  display: block;
  margin-bottom: 12px;
  color: var(--text);
  font-size: 18px;
  line-height: 1.45;
}
.conclusion-sources {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.source-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}
.source-ok {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #166534;
}
.source-warn {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #9a3412;
}
.source-neutral {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}
.conclusion-columns {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 12px;
}
.conclusion-columns h3 {
  margin-bottom: 8px;
  color: var(--text);
  font-size: 14px;
  line-height: 1.4;
}
.conclusion-list {
  display: grid;
  gap: 8px;
}
.action-list {
  margin-top: 8px;
}
.conclusion-item {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.conclusion-item strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.35;
}
.conclusion-item p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}
.conclusion-item em {
  display: block;
  margin-top: 6px;
  color: #2563eb;
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}
.analysis-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.analysis-card-grid.five-col {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
.compact-metric {
  min-height: 78px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.compact-metric span, .compact-metric em {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}
.compact-metric strong {
  display: block;
  margin: 5px 0;
  color: var(--text);
  font-size: 19px;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}
.analysis-card-grid.trend-result-grid {
  grid-template-columns: 1fr;
}
.trend-analysis-result {
  display: grid;
  gap: 10px;
  min-width: 0;
}
.trend-summary {
  min-width: 0;
  padding: 10px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
}
.trend-summary span {
  display: block;
  margin-bottom: 6px;
  color: #1d4ed8;
  font-size: 12px;
  line-height: 1.4;
}
.trend-summary strong {
  display: block;
  color: var(--text);
  font-size: 15px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.trend-evidence {
  display: grid;
  gap: 6px;
}
.trend-evidence p,
.trend-action em {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}
.trend-impact {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}
.trend-impact span {
  color: var(--text);
  font-weight: 700;
}
.trend-impact em {
  flex: 1 1 100%;
  color: var(--muted);
  font-style: normal;
  overflow-wrap: anywhere;
}
.trend-actions {
  display: grid;
  gap: 8px;
}
.trend-action {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.trend-action strong {
  display: block;
  color: var(--text);
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.notice {
  margin-bottom: 12px;
  padding: 12px 14px;
  border: 1px solid #fed7aa;
  border-radius: 8px;
  background: #fff7ed;
  color: #9a3412;
  font-size: 14px;
  line-height: 1.5;
}
.hidden { display: none; }
.active-view { display: block; }
body.modal-open {
  overflow: hidden;
}
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, .36);
}
.modal-backdrop.hidden {
  display: none;
}
.modal-panel {
  width: min(880px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 24px 80px rgba(15, 23, 42, .22);
}
.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}
.modal-head h2 {
  margin: 0;
  color: var(--text);
  font-size: 18px;
  line-height: 1.25;
}
.modal-head span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}
.modal-close {
  width: 34px;
  min-width: 34px;
  height: 34px;
  padding: 0;
  border-color: var(--line);
  background: #ffffff;
  color: var(--text);
  font-size: 22px;
  line-height: 1;
}
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}
.modal-actions button {
  min-width: 92px;
}
.panel {
  padding: 16px;
  margin-bottom: 12px;
  min-width: 0;
  overflow: visible;
}
.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.panel-head > div {
  min-width: 0;
}
.panel-head > div > span {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.panel-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}
.panel-actions > span {
  margin-top: 0;
}
.model-tag {
  max-width: 180px;
  padding: 3px 8px;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 12px;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
canvas {
  width: 100%;
  height: 320px;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.insight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.insight {
  min-height: 86px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.insight span, .insight em {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}
.insight strong {
  display: block;
  margin: 6px 0;
  color: var(--text);
  font-size: 22px;
  font-variant-numeric: tabular-nums;
}
.module-panel {
  overflow: visible;
}
#adDataView .module-panel .panel-head {
  align-items: flex-start;
}
.ad-controls {
  display: grid;
  grid-template-columns: minmax(0, 168px) 104px 126px 126px 64px 96px 78px 54px;
  justify-content: end;
  gap: 6px;
  width: 100%;
  max-width: 782px;
}
.ad-controls > * {
  width: 100%;
  min-width: 0;
  padding-left: 8px;
  padding-right: 8px;
}
.ad-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 10px;
}
.ad-metrics article, .strategy-metrics article {
  min-width: 0;
  min-height: 86px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.ad-metrics article:nth-child(1) {
  border-color: #bbf7d0;
  background: #f0fdf4;
}
.ad-metrics article:nth-child(2) {
  border-color: #bfdbfe;
  background: #eff6ff;
}
.ad-metrics article:nth-child(3) {
  border-color: #fde68a;
  background: #fffbeb;
}
.ad-metrics span, .strategy-metrics span {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.system-account-grid .profit-good {
  border: 1px solid #bbf7d0;
  background: #f0fdf4;
}
.system-account-grid .profit-good strong {
  color: #166534;
}
.system-account-grid .profit-bad {
  border: 1px solid #fecaca;
  background: #fff1f2;
}
.system-account-grid .profit-bad strong {
  color: #991b1b;
}
.system-account-grid .profit-neutral {
  border: 1px solid #c7d2fe;
  background: #eef2ff;
}
.system-account-grid .profit-neutral strong {
  color: #3730a3;
}
.ad-metrics strong, .strategy-metrics strong {
  display: block;
  max-width: 100%;
  min-height: 27px;
  color: var(--text);
  font-size: 21px;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.ad-metrics strong {
  letter-spacing: 0;
}
.ad-table-shell {
  overflow-x: auto;
  scrollbar-gutter: stable;
}
.ad-finance-table {
  min-width: 920px;
  table-layout: fixed;
}
.ad-finance-table th,
.ad-finance-table td {
  white-space: normal;
}
.ad-finance-table th:nth-child(1),
.ad-finance-table td:nth-child(1) {
  width: 112px;
  min-width: 0;
  max-width: none;
}
.ad-finance-table th:nth-child(2),
.ad-finance-table td:nth-child(2) {
  width: 260px;
  overflow-wrap: anywhere;
}
.ad-finance-table th:nth-child(n+3),
.ad-finance-table td:nth-child(n+3) {
  text-align: right;
  overflow-wrap: anywhere;
}
.ad-trend-panel {
  overflow: hidden;
}
.ad-chart-shell {
  min-height: 340px;
}
#adChart {
  height: 340px;
  background: #fff;
}
.ad-attribution-panel .ad-note-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.ad-account-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.ad-account-card {
  min-height: 164px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.ad-account-card > div:first-child {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.ad-account-card strong {
  color: var(--text);
  font-size: 15px;
  line-height: 1.35;
}
.ad-account-card span, .ad-account-card em {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}
.ad-account-card dl {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 12px;
}
.ad-account-card dt {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12px;
}
.ad-account-card dd {
  margin: 0;
  color: var(--text);
  font-size: 18px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.ad-mapping-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, .85fr);
  gap: 12px;
}
.ad-mapping-column {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.ad-mapping-toolbar {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}
.ad-mapping-toolbar input {
  flex: 1;
  min-width: 0;
}
.ad-mapping-list,
.ad-live-account-list {
  display: grid;
  gap: 8px;
  max-height: 380px;
  overflow: auto;
  padding-right: 2px;
}
.ad-map-row,
.ad-live-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 72px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  min-width: 0;
}
.ad-map-row.mapped,
.ad-live-row.selected {
  border-color: #bfdbfe;
  background: #eff6ff;
}
.ad-map-row input,
.ad-live-row input {
  width: 16px;
  height: 16px;
  padding: 0;
}
.ad-map-row strong,
.ad-live-row strong {
  display: block;
  color: var(--text);
  font-size: 14px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.ad-map-row span,
.ad-map-row em,
.ad-live-row span,
.ad-live-row em {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.ad-map-row dl {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  min-width: 220px;
  margin: 0;
}
.ad-map-row dt {
  color: var(--muted);
  font-size: 11px;
}
.ad-map-row dd {
  margin: 2px 0 0;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.empty-block {
  min-height: 88px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: #fbfcff;
  font-size: 14px;
}
.ad-note-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.payload-editor {
  width: 100%;
  min-height: 180px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  resize: vertical;
  color: var(--text);
  font: 13px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.form-status {
  min-height: 24px;
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
}
.strategy-controls select {
  min-width: 110px;
}
.strategy-metrics {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
}
.strategy-metrics article:nth-child(1) {
  border-color: #bfdbfe;
  background: var(--blue-soft);
}
.strategy-metrics article:nth-child(6) {
  border-color: #bbf7d0;
  background: #f0fdf4;
}
.strategy-core-grid {
  align-items: start;
  grid-template-columns: minmax(280px, .95fr) minmax(300px, 1fr) minmax(360px, 1.15fr);
}
.competitor-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.competitor-rule-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.competitor-rule-grid label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}
.competitor-rule-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.competitor-rule-tooltip {
  width: min(560px, calc(100vw - 48px));
}
.competitor-rule-tooltip p {
  margin: 0 0 8px;
  color: var(--text);
}
.competitor-rule-tooltip span {
  display: block;
  color: var(--muted);
}
.rank-metric {
  display: grid;
  gap: 3px;
  min-width: 0;
}
.rank-metric strong {
  color: var(--text);
  font-size: 12px;
  line-height: 1.35;
  white-space: normal;
  overflow-wrap: anywhere;
}
.rank-metric span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  white-space: normal;
  overflow-wrap: anywhere;
}
.competitor-table-panel > table {
  display: block;
  overflow: auto;
  scrollbar-gutter: stable;
}
.competitor-table-panel > table thead {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--panel);
}
.competitor-table-panel > table th {
  background: var(--panel);
}
.competitor-top-table-shell {
  position: relative;
  max-width: 100%;
  max-height: 540px;
  overflow: auto;
  scrollbar-gutter: stable;
}
.competitor-top-table {
  min-width: 980px;
  table-layout: fixed;
}
.competitor-top-table thead {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--panel);
}
.competitor-top-table th {
  background: var(--panel);
  white-space: normal;
}
.competitor-top-table th,
.competitor-top-table td {
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.competitor-top-table th:nth-child(1),
.competitor-top-table td:nth-child(1) {
  width: 18%;
  min-width: 0;
  max-width: none;
}
.competitor-top-table thead th:first-child,
.competitor-top-table tbody tr:not(.competitor-more-row) > td:first-child {
  position: sticky;
  left: 0;
  z-index: 2;
  background: #ffffff;
  box-shadow: 1px 0 0 var(--line), 10px 0 14px rgba(15, 23, 42, .06);
}
.competitor-top-table thead th:first-child {
  z-index: 3;
  background: var(--panel);
}
.competitor-top-table th:nth-child(2),
.competitor-top-table td:nth-child(2),
.competitor-top-table th:nth-child(3),
.competitor-top-table td:nth-child(3) {
  width: 17%;
}
.competitor-top-table th:nth-child(4),
.competitor-top-table td:nth-child(4),
.competitor-top-table th:nth-child(5),
.competitor-top-table td:nth-child(5) {
  width: 10%;
}
.competitor-top-table th:nth-child(6),
.competitor-top-table td:nth-child(6) {
  width: 12%;
}
.competitor-top-table th:nth-child(7),
.competitor-top-table td:nth-child(7) {
  width: 16%;
}
.competitor-top-table td span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.competitor-actions {
  white-space: normal;
}
.competitor-actions .table-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 2px 4px 2px 0;
}
.competitor-actions .table-action + .table-action {
  margin-left: 0;
}
.competitor-more-row td {
  background: #fbfcff;
}
.competitor-more-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 8px;
}
.competitor-more-grid .compact-metric {
  min-height: 64px;
  background: #ffffff;
  min-width: 0;
}
.competitor-more-grid .compact-metric strong {
  font-size: 14px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.competitor-more-grid .compact-metric span,
.competitor-more-grid .compact-metric em {
  overflow-wrap: anywhere;
  word-break: break-word;
}
.rule-textarea {
  width: 100%;
  min-height: 88px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  resize: vertical;
  color: var(--text);
  font: 13px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.rule-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 26px;
  margin-top: 10px;
}
.rule-tags span {
  display: inline-flex;
  max-width: 100%;
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fbfcff;
  color: var(--muted);
  font-size: 12px;
}
.source-list {
  display: grid;
  gap: 8px;
}
.source-item {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.source-item strong, .source-item span, .source-item em {
  display: block;
}
.source-item strong {
  color: var(--text);
  font-size: 13px;
}
.source-item span {
  margin-top: 4px;
  color: var(--muted);
  font: 12px/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  white-space: normal;
  overflow-wrap: anywhere;
}
.source-item em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.5;
}
.strategy-source-panel {
  margin-top: 12px;
}
.strategy-source-panel .panel-head {
  margin-bottom: 8px;
}
.compact-source-list {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}
.compact-source-list .source-item {
  min-width: 0;
  padding: 8px;
  border-radius: 6px;
}
.compact-source-list .source-item strong {
  font-size: 12px;
  line-height: 1.35;
}
.compact-source-list .source-item span {
  margin-top: 3px;
  font-size: 11px;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.compact-source-list .source-item em {
  display: none;
}
.strategy-grid {
  grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr);
}
.strategy-action-panel {
  overflow: auto;
}
.strategy-action-panel table {
  min-width: 680px;
}
.signal-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.signal {
  min-height: 74px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}
.signal span {
  display: block;
  margin-bottom: 6px;
  font-size: 12px;
}
.signal strong {
  color: var(--text);
  font-size: 18px;
  font-variant-numeric: tabular-nums;
}
.strategy-list {
  display: grid;
  gap: 10px;
}
.strategy-card {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.strategy-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.strategy-card h3 {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.4;
}
.strategy-card p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.badge {
  display: inline-block;
  min-width: 44px;
  padding: 3px 7px;
  border-radius: 999px;
  color: var(--text);
  font-size: 12px;
  text-align: center;
  white-space: nowrap;
}
.badge-high {
  background: #fee2e2;
  color: #991b1b;
}
.badge-medium {
  background: #fef3c7;
  color: #92400e;
}
.badge-low {
  background: #e0f2fe;
  color: #075985;
}
.status-pill {
  color: var(--muted);
  font-size: 12px;
}
.action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.action-buttons button {
  height: 28px;
  padding: 0 8px;
  border-color: var(--line);
  background: #ffffff;
  color: var(--text);
  font-size: 12px;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
#businessOverviewView .panel:not(.pinned-profit-panel) > table {
  display: block;
  max-height: 560px;
  overflow: auto;
  scrollbar-gutter: stable;
}
#businessOverviewView .panel:not(.pinned-profit-panel) > table thead {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--panel);
}
#businessOverviewView .panel:not(.pinned-profit-panel) > table th {
  background: var(--panel);
}
th, td {
  padding: 9px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  white-space: nowrap;
}
td:first-child {
  min-width: 260px;
  max-width: 420px;
  white-space: normal;
}
td:first-child, th:first-child { color: var(--text); }
.list {
  display: grid;
  gap: 8px;
  max-height: 360px;
  overflow: auto;
}
.item {
  border-bottom: 1px solid var(--line);
  padding: 8px 0;
  font-size: 13px;
}
.item strong { display: block; margin-bottom: 4px; }
.analysis {
  color: var(--text);
  font-size: 14px;
  line-height: 1.7;
}
.analysis p { margin-bottom: 10px; }
.analysis strong {
  display: block;
  margin-top: 10px;
}
.analysis ul {
  margin: 6px 0 0;
  padding-left: 18px;
}
.ok { color: var(--green); }
.warn { color: var(--amber); }
.bad { color: var(--red); }
@media (max-width: 900px) {
  .app-shell {
    grid-template-columns: 1fr;
  }
  .app-sidebar {
    position: sticky;
    top: 0;
    z-index: 20;
    height: auto;
    padding: 12px 16px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .sidebar-brand {
    padding: 0 0 10px;
  }
  .view-tabs {
    grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
    margin-top: 10px;
  }
  .tab-button {
    justify-content: center;
    text-align: center;
  }
  .topbar { align-items: flex-start; flex-direction: column; }
  .controls { width: 100%; }
  .controls > * { min-width: 0; }
  .scopebar, .status, .metrics, .grid, .detail-grid, .insight-grid, .system-result-metrics, .system-account-results, .system-account-grid, .system-home-metrics, .profit-summary, .profit-calculator-grid, .profit-calc-preview, .account-today-metrics, .conclusion-columns, .account-analysis-grid, .analysis-card-grid, .analysis-card-grid.five-col, .fuel-revenue-metrics, .driver-workbench-metrics, .duty-workbench-metrics, .link-inspection-metrics, .link-chain-grid, .link-inspection-layout, .link-raw-grid, .fuel-revenue-layout, .fuel-price-form-grid, .duty-config-grid, .duty-schedule-grid, .duty-plan-grid, .duty-planner, .duty-calendar-layout, .fuel-tier-grid, .ad-metrics, .ad-grid, .ad-account-cards, .ad-mapping-grid, .strategy-metrics, .strategy-core-grid, .competitor-grid, .competitor-summary, .competitor-rule-grid, .competitor-more-grid, .strategy-grid, .signal-grid, .compact-source-list { grid-template-columns: 1fr; }
  .fuel-price-form-grid .wide,
  .duty-config-grid .wide,
  .duty-schedule-grid .wide {
    grid-column: auto;
  }
  .fuel-tier-detail-grid {
    grid-template-columns: 1fr;
  }
  .duty-anchor-cards {
    grid-auto-columns: minmax(132px, 1fr);
    max-height: 132px;
  }
  .duty-operator-cards {
    grid-auto-columns: minmax(132px, 1fr);
  }
  .duty-timeline-header,
  .duty-timeline-slots,
  .duty-pallet-editor {
    min-width: 920px;
  }
  .duty-calendar-detail {
    padding-top: 12px;
    padding-left: 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }
  .account-analysis-wide { grid-column: auto; }
  .system-account-grid .system-profit-status-tile {
    grid-column: auto;
    grid-row: auto;
  }
  .panel-head { align-items: flex-start; flex-direction: column; }
  .system-home-controls {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    justify-content: stretch;
    flex: 1 1 auto;
    width: 100%;
  }
  .ad-controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    justify-content: stretch;
    max-width: none;
  }
  .profit-calculator-head { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 600px) {
  .app-main { padding: 20px; }
  .view-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }
  input, select, button {
    width: 100%;
    min-width: 0;
  }
  .tab-button {
    width: 100%;
  }
  .ad-controls input {
    width: 100%;
  }
  .profit-controls input {
    width: 100%;
  }
  .ad-mapping-toolbar {
    display: grid;
    grid-template-columns: 1fr;
  }
  .ad-map-row {
    grid-template-columns: 24px minmax(0, 1fr);
  }
  .ad-map-row dl {
    grid-column: 1 / -1;
    min-width: 0;
  }
  .duty-calendar-weekdays,
  .duty-calendar-grid {
    min-width: 520px;
  }
  .duty-calendar-detail-section.is-anchor .duty-calendar-detail-section-body {
    grid-template-columns: 1fr;
  }
}
