:root {
  color-scheme: light;
  --bg: #eef3f7;
  --surface: rgba(255, 255, 255, 0.62);
  --surface-solid: rgba(255, 255, 255, 0.68);
  --glass: rgba(255, 255, 255, 0.58);
  --glass-strong: rgba(255, 255, 255, 0.78);
  --text: #1d1d1f;
  --muted: #6e6e73;
  --soft: #86868b;
  --line: rgba(255, 255, 255, 0.66);
  --line-strong: rgba(125, 137, 150, 0.24);
  --accent: #0a84ff;
  --green: #30a46c;
  --amber: #b36b00;
  --red: #ff453a;
  --violet: #7b61ff;
  --brand-green: #004d3f;
  --active-bg: linear-gradient(180deg, rgba(10, 132, 255, 0.18), rgba(10, 132, 255, 0.1));
  --active-border: rgba(10, 132, 255, 0.24);
  --active-text: #0064c8;
  --shadow: 0 18px 46px rgba(67, 82, 101, 0.12);
  --hairline: 1px solid rgba(255, 255, 255, 0.72);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  margin: 0;
  min-width: 320px;
  font-weight: 400;
}

button,
input,
select {
  font: inherit;
}

select {
  color-scheme: light;
}

select option {
  background: #ffffff;
  color: var(--text);
}

button {
  cursor: pointer;
}

.icon-sprite {
  display: none;
}

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

svg {
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.app-shell {
  min-height: 100vh;
  background: linear-gradient(135deg, #f8fbff 0%, #eef7f2 45%, #f8f1fb 100%);
}

body.is-locked .app-shell {
  display: none;
}

body.is-authenticated .login-screen {
  display: none;
}

.login-screen {
  position: relative;
  display: grid;
  min-height: 100vh;
  place-items: center;
  overflow: hidden;
  padding: 32px 18px;
  background:
    radial-gradient(circle at 20% 18%, rgba(250, 250, 255, 0.92), rgba(250, 250, 255, 0) 32%),
    radial-gradient(circle at 78% 68%, rgba(202, 232, 220, 0.54), rgba(202, 232, 220, 0) 34%),
    linear-gradient(145deg, #edf2f6 0%, #dfe8ee 42%, #f5f1ee 100%);
}

.login-screen::before {
  position: absolute;
  inset: -12%;
  content: "";
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 36%),
    linear-gradient(295deg, rgba(0, 77, 63, 0.12), rgba(0, 77, 63, 0) 48%);
  filter: blur(22px);
  pointer-events: none;
}

.login-card {
  display: grid;
  position: relative;
  z-index: 1;
  justify-items: center;
  width: min(320px, 100%);
  gap: 12px;
}

.login-logo {
  width: 116px;
  aspect-ratio: 1;
  object-fit: cover;
  margin-bottom: 12px;
  border-radius: 50%;
  box-shadow:
    0 18px 48px rgba(67, 82, 101, 0.18),
    inset 0 0 0 1px rgba(255, 255, 255, 0.72);
}

.login-field {
  width: 100%;
}

.login-field input {
  width: 100%;
  min-height: 46px;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  outline: 0;
  background: rgba(255, 255, 255, 0.64);
  color: var(--text);
  padding: 0 18px;
  font-size: 15px;
  font-weight: 650;
  text-align: center;
  box-shadow: 0 12px 34px rgba(67, 82, 101, 0.11);
  backdrop-filter: saturate(180%) blur(22px);
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.login-field input::placeholder {
  color: rgba(29, 29, 31, 0.48);
  font-weight: 520;
}

.login-field input:focus {
  border-color: rgba(10, 132, 255, 0.48);
  background: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 0 0 4px rgba(10, 132, 255, 0.12),
    0 14px 38px rgba(67, 82, 101, 0.12);
}

.login-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  margin-top: 4px;
  border: 1px solid rgba(10, 132, 255, 0.36);
  border-radius: 50%;
  background: rgba(10, 132, 255, 0.9);
  color: #ffffff;
  box-shadow: 0 14px 34px rgba(0, 113, 227, 0.24);
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.login-button svg {
  width: 18px;
  height: 18px;
}

.login-button:hover {
  background: rgba(0, 113, 227, 0.96);
  transform: translateY(-1px);
  box-shadow: 0 17px 38px rgba(0, 113, 227, 0.28);
}

.login-button:focus-visible {
  outline: 4px solid rgba(10, 132, 255, 0.16);
  outline-offset: 4px;
}

.login-note {
  min-height: 22px;
  margin: 2px 0 0;
  color: rgba(29, 29, 31, 0.64);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  text-align: center;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 80;
  display: grid;
  grid-template-columns: auto minmax(220px, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 6px max(16px, calc((100vw - 1500px) / 2 + 18px));
  border-bottom: 1px solid rgba(255, 255, 255, 0.62);
  background: rgba(255, 255, 255, 0.46);
  backdrop-filter: saturate(180%) blur(28px);
  box-shadow: 0 12px 30px rgba(67, 82, 101, 0.08);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: max-content;
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.brand-logo {
  width: 34px;
  height: 34px;
  object-fit: cover;
  border-radius: 8px;
  background: var(--brand-green);
}

.brand-mark {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: var(--text);
  color: #ffffff;
  font-size: 14px;
}

.command-panel {
  position: relative;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 36px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  backdrop-filter: saturate(180%) blur(18px);
  box-shadow: 0 12px 28px rgba(67, 82, 101, 0.08);
  padding: 0 10px;
}

.global-search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  display: none;
  max-height: min(68vh, 520px);
  overflow: auto;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 22px 60px rgba(67, 82, 101, 0.18);
  padding: 10px;
}

.global-search-results.is-open {
  display: grid;
  gap: 10px;
}

.global-search-group {
  display: grid;
  gap: 6px;
}

.global-search-group > strong {
  color: var(--soft);
  font-size: 11px;
  font-weight: 900;
}

.global-search-item {
  display: grid;
  gap: 3px;
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.74);
  color: var(--text);
  padding: 9px 10px;
  text-align: left;
  cursor: pointer;
}

.global-search-item span,
.global-search-item small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.global-search-item span {
  font-size: 13px;
  font-weight: 900;
}

.global-search-item small,
.global-search-empty {
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
  line-height: 1.5;
}

.global-search-empty {
  padding: 10px;
}

.command-panel svg {
  width: 19px;
  height: 19px;
  color: var(--soft);
}

.command-panel input,
.date-control input,
.scanner-tool input {
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
}

.top-controls {
  display: flex;
  align-items: center;
  justify-content: end;
  gap: 10px;
}

.role-switcher {
  max-width: 190px;
  min-height: 36px;
  border: var(--hairline);
  border-radius: 8px;
  background-color: rgba(255, 255, 255, 0.58);
  color: var(--text);
  padding: 0 34px 0 12px;
  font-size: 13px;
  box-shadow: 0 12px 28px rgba(67, 82, 101, 0.08);
  backdrop-filter: saturate(180%) blur(18px);
}

body.is-worker-session #session-name {
  display: none;
}

.role-control {
  display: grid;
  gap: 2px;
  min-width: 150px;
  min-height: 44px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  padding: 6px 10px;
}

.role-control span {
  color: var(--soft);
  font-size: 11px;
  font-weight: 800;
}

.role-control select {
  border: 0;
  background: transparent;
  min-height: 20px;
  padding: 0;
  font-size: 13px;
  font-weight: 800;
}

.date-control {
  display: grid;
  gap: 2px;
  min-width: 136px;
  min-height: 44px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  padding: 6px 10px;
}

.date-control span {
  color: var(--soft);
  font-size: 11px;
  font-weight: 800;
}

.date-control input {
  font-size: 13px;
  font-weight: 700;
}

.icon-button,
.primary-button,
.secondary-button,
.module-button,
.chip-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  border: 1px solid transparent;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.icon-button {
  width: 44px;
  height: 44px;
  color: var(--text);
  background: rgba(0, 0, 0, 0.05);
}

.logout-text-button {
  min-height: 36px;
  border: 1px solid rgba(10, 132, 255, 0.28);
  border-radius: 8px;
  background: rgba(10, 132, 255, 0.88);
  color: #ffffff;
  padding: 0 13px;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.icon-button svg,
.primary-button svg,
.secondary-button svg,
.module-button svg,
.chip-button svg {
  width: 17px;
  height: 17px;
}

.primary-button,
.secondary-button,
.chip-button {
  min-height: 38px;
  padding: 0 14px;
  font-weight: 800;
}

.primary-button {
  border-color: rgba(10, 132, 255, 0.36);
  background: linear-gradient(180deg, rgba(10, 132, 255, 0.94), rgba(0, 113, 227, 0.9));
  color: #ffffff;
}

.secondary-button {
  width: 100%;
  border-color: var(--active-border);
  background: var(--active-bg);
  color: var(--active-text);
}

.chip-button {
  border-color: rgba(255, 255, 255, 0.72);
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: saturate(180%) blur(16px);
  color: var(--text);
  font-size: 13px;
}

.icon-button:hover,
.logout-text-button:hover,
.primary-button:hover,
.secondary-button:hover,
.module-button:hover,
.chip-button:hover {
  transform: translateY(-1px);
}

.system-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  width: min(1800px, calc(100% - 32px));
  margin: 0 auto;
  padding: 14px 0 64px;
}

.sidebar {
  position: sticky;
  top: 58px;
  z-index: 70;
  align-self: start;
  justify-self: start;
  width: max-content;
  max-width: 100%;
  min-width: 0;
  padding: 6px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.52);
  backdrop-filter: saturate(180%) blur(24px);
  box-shadow: var(--shadow);
}

.sidebar-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 12px;
}

.sidebar-heading strong {
  color: var(--text);
}

.module-nav {
  display: flex;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
  padding-bottom: 0;
}

.module-group {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
  min-width: 0;
}

.module-group:not(.is-expanded) .module-subnav {
  display: none;
}

.module-group.is-expanded .module-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-height: none;
  opacity: 1;
  padding: 6px;
  pointer-events: auto;
}

.module-button {
  justify-content: flex-start;
  width: auto;
  min-height: 30px;
  border-color: transparent;
  background: transparent;
  color: var(--muted);
  padding: 0 9px;
  font-size: 13px;
  font-weight: 800;
}

.module-button-main {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.module-button-main span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.module-button.is-active {
  border-color: var(--active-border);
  background: var(--active-bg);
  color: var(--active-text);
}

.module-subnav {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 90;
  display: none;
  gap: 4px;
  width: max-content;
  min-width: 120px;
  max-width: min(680px, calc(100vw - 48px));
  max-height: 0;
  overflow: visible;
  opacity: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 16px 42px rgba(67, 82, 101, 0.14);
  pointer-events: none;
}

.module-subbutton {
  min-width: 0;
  min-height: 26px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  padding: 0 9px;
  text-align: left;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.module-subbutton:hover,
.module-subbutton.is-active {
  background: #f0f2f1;
  color: var(--text);
}

.workspace {
  min-width: 0;
}

.page-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 24px;
  padding: 8px 0 22px;
}

.page-heading.dispatch-page-heading {
  display: none;
}

.eyebrow,
.section-kicker {
  margin: 0 0 6px;
  color: var(--soft);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 9px;
  color: var(--text);
  font-size: clamp(34px, 4vw, 56px);
  line-height: 1.04;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 21px;
  line-height: 1.2;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 5px;
  font-size: 16px;
  line-height: 1.28;
}

.page-copy {
  max-width: 760px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.page-tools {
  display: grid;
  justify-items: end;
  gap: 10px;
  min-width: min(760px, 100%);
}

.range-control {
  display: block;
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  backdrop-filter: none;
}

.range-control > span {
  padding-left: 10px;
  color: var(--soft);
  font-size: 12px;
  font-weight: 900;
}

.range-options {
  display: block;
  width: 100%;
}

.range-option {
  min-height: 32px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  padding: 0 11px;
  font-size: 13px;
  font-weight: 900;
}

.range-option.is-active {
  background: var(--active-bg);
  color: var(--active-text);
  box-shadow: inset 0 0 0 1px var(--active-border);
}

.sync-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: end;
  gap: 8px;
  max-width: 520px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 26px;
  border-radius: 999px;
  padding: 0 10px;
  background: rgba(31, 138, 76, 0.1);
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.status-pill::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.status-pill.warning {
  background: rgba(179, 107, 0, 0.12);
  color: var(--amber);
}

.status-pill.warn {
  background: rgba(179, 107, 0, 0.12);
  color: var(--amber);
}

.status-pill.danger {
  background: rgba(195, 63, 50, 0.11);
  color: var(--red);
}

.status-pill.neutral {
  background: rgba(255, 255, 255, 0.52);
  color: var(--muted);
}

.status-pill.muted {
  background: rgba(255, 255, 255, 0.52);
  color: var(--muted);
}

.summary-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.summary-grid.worker-summary-grid {
  display: none;
}

.summary-grid.worker-summary-grid .summary-panel:nth-child(2) {
  display: none;
}

.summary-grid.worker-summary-grid .summary-panel {
  padding: 10px;
}

.summary-grid.worker-summary-grid .summary-heading {
  display: none;
}

.summary-panel,
.work-surface,
.side-surface,
.analytics-band {
  border: var(--hairline);
  border-radius: 8px;
  background: var(--glass);
  backdrop-filter: saturate(180%) blur(24px);
  box-shadow: var(--shadow);
}

.summary-panel {
  padding: 18px;
}

.summary-heading,
.surface-heading,
.record-top,
.automation-item,
.finance-split,
.scanner-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.summary-heading {
  margin-bottom: 14px;
}

.summary-heading span,
.record-meta,
.record-detail,
.automation-item span,
.scanner-tool p,
.finance-split span,
.bar-label,
.bar-value {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.summary-heading strong {
  font-size: 15px;
}

.dispatch-summary-grid .summary-heading strong {
  display: none;
}

.metric-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metric-item {
  min-height: 84px;
  padding: 12px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.42);
  backdrop-filter: saturate(180%) blur(16px);
}

.metric-item span {
  display: block;
  min-height: 19px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.metric-item strong {
  display: block;
  margin-top: 9px;
  font-size: 25px;
  letter-spacing: 0;
}

.metric-list.region-workload-list {
  display: block;
}

.region-workload-card {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: saturate(180%) blur(16px);
}

.region-workload-chip {
  flex: 1 1 78px;
  min-width: 72px;
  padding: 8px 10px;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
}

.region-workload-chip span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.region-workload-chip strong {
  display: block;
  margin-top: 5px;
  color: var(--text);
  font-size: 20px;
  letter-spacing: 0;
}

.module-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin-top: 16px;
  align-items: start;
}

.module-grid.dispatch-mode {
  grid-template-columns: minmax(0, 1fr);
}

.module-grid.hr-mode {
  grid-template-columns: minmax(0, 1fr);
}

.work-surface,
.side-surface,
.analytics-band {
  min-width: 0;
  padding: 18px;
}

.workspace,
.module-grid,
.work-surface,
.record-list,
.crm-quote-panel {
  width: 100%;
  max-width: none;
}

.work-surface {
  padding: 16px;
}

.dispatch-work-surface {
  padding: 18px;
}

.worker-work-surface {
  padding: 12px;
}

.worker-work-surface .surface-heading {
  display: none;
}

.dispatch-compact-surface .surface-heading {
  justify-content: stretch;
  min-height: auto;
  margin-bottom: 12px;
}

.dispatch-compact-surface .surface-heading > div:first-child {
  display: none;
}

.hr-work-surface {
  padding: 18px;
}

.surface-heading {
  min-height: 42px;
  margin-bottom: 16px;
}

.surface-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: end;
  gap: 8px;
}

.dispatch-compact-surface .surface-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  width: 100%;
}

.dispatch-action-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  min-width: 0;
}

.dispatch-action-metric {
  display: grid;
  align-content: center;
  min-width: 0;
  min-height: 48px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  padding: 8px 10px;
  box-shadow: 0 10px 24px rgba(67, 82, 101, 0.07);
}

.dispatch-action-metric span {
  color: var(--soft);
  font-size: 11px;
  font-weight: 650;
}

.dispatch-action-metric strong {
  display: block;
  min-width: 0;
  margin-top: 4px;
  color: var(--text);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.dispatch-action-button-card {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px 8px;
}

.dispatch-action-button-card span {
  grid-column: 1 / -1;
}

.dispatch-action-button-card .chip-button {
  justify-self: start;
}

.dispatch-action-button-card .chip-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.dispatch-compact-surface #module-action {
  align-self: stretch;
  min-height: 48px;
  white-space: nowrap;
}

.boss-workload-dashboard {
  display: grid;
  gap: 12px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  padding: 14px;
  box-shadow: 0 12px 30px rgba(67, 82, 101, 0.07);
}

.boss-dashboard-head {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(360px, auto);
  align-items: start;
  gap: 12px;
  min-width: 0;
}

.boss-dashboard-head h3 {
  margin: 0;
  color: var(--text);
  font-size: 18px;
  letter-spacing: 0;
}

.boss-dashboard-head span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.workload-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.workload-summary-item {
  display: grid;
  gap: 4px;
  min-width: 0;
  min-height: 58px;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  padding: 10px;
}

.workload-summary-item span,
.workload-row span,
.workload-row small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.workload-summary-item strong {
  color: var(--text);
  font-size: 18px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.workload-table {
  display: grid;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.44);
}

.workload-row {
  display: grid;
  grid-template-columns: minmax(132px, 1.2fr) repeat(4, minmax(66px, 0.58fr)) minmax(180px, 1.5fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 10px 12px;
  border-top: 1px solid rgba(125, 137, 150, 0.1);
}

.workload-row:first-child {
  border-top: 0;
}

.workload-head-row {
  min-height: 38px;
  background: rgba(125, 137, 150, 0.08);
}

.workload-head-row span {
  color: var(--soft);
  font-size: 11px;
  font-weight: 900;
}

.workload-row > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.workload-row strong {
  color: var(--text);
  font-size: 16px;
  font-weight: 900;
}

.workload-worker-cell strong {
  font-size: 14px;
}

.workload-risk-cell strong {
  color: var(--red);
}

.workload-distribution-cell span,
.workload-distribution-cell small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.workload-distribution-cell i {
  display: block;
  overflow: hidden;
  width: 100%;
  height: 6px;
  margin-top: 4px;
  border-radius: 999px;
  background: rgba(125, 137, 150, 0.14);
}

.workload-distribution-cell u {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--green));
  text-decoration: none;
}

.record-list,
.automation-list {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.record-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  min-height: 86px;
  padding: 14px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: saturate(180%) blur(16px);
}

.record-row:first-child,
.metric-item:nth-child(-n + 4) {
  border-color: rgba(125, 137, 150, 0.14);
}

.store-directory-system {
  display: grid;
  gap: 14px;
}

.store-directory-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.store-directory-head h3 {
  margin: 0;
  font-size: 24px;
}

.store-directory-head span {
  max-width: 520px;
  color: var(--muted);
  text-align: right;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.5;
}

.store-directory-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.store-directory-card {
  display: grid;
  gap: 12px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  padding: 14px;
}

.store-card-title {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.store-card-title strong {
  display: block;
  color: var(--text);
  font-size: 18px;
  font-weight: 900;
}

.store-card-title span,
.store-directory-card p,
.store-card-address span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.5;
}

.store-card-title em {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(52, 199, 89, 0.12);
  color: var(--green);
  padding: 5px 9px;
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}

.store-card-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
}

.store-card-metrics div {
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.76);
  padding: 9px;
}

.store-card-metrics dt,
.store-card-metrics dd {
  margin: 0;
}

.store-card-metrics dt {
  color: var(--soft);
  font-size: 11px;
  font-weight: 800;
}

.store-card-metrics dd {
  margin-top: 4px;
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}

.store-card-address {
  display: grid;
  gap: 4px;
  border-radius: 8px;
  background: rgba(232, 245, 240, 0.72);
  padding: 10px;
}

.store-card-address strong {
  color: var(--text);
  font-size: 13px;
  line-height: 1.55;
}

.store-management-system,
.store-edit-list {
  display: grid;
  gap: 14px;
}

.store-sales-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.store-sales-summary-card {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
  padding: 14px;
}

.store-sales-summary-card > strong {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.store-sales-summary-card > span {
  color: var(--text);
  font-size: 26px;
  font-weight: 950;
}

.store-sales-summary-card dl {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
}

.store-sales-summary-card div {
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.8);
  padding: 8px;
}

.store-sales-summary-card dt,
.store-sales-summary-card dd {
  margin: 0;
}

.store-sales-summary-card dt {
  color: var(--soft);
  font-size: 11px;
  font-weight: 850;
}

.store-sales-summary-card dd {
  margin-top: 4px;
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
}

.store-edit-card {
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  padding: 14px;
}

.store-edit-form {
  display: grid;
  gap: 12px;
}

.store-edit-card-head,
.store-edit-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.store-edit-card-head h4 {
  margin: 2px 0 0;
  color: var(--text);
  font-size: 19px;
  font-weight: 950;
}

.store-edit-card-head > span {
  border-radius: 999px;
  background: rgba(47, 128, 237, 0.1);
  color: var(--blue);
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 900;
}

.store-edit-form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.store-edit-form-grid label {
  display: grid;
  gap: 6px;
}

.store-edit-form-grid label > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.store-edit-form-grid input,
.store-edit-form-grid select,
.store-edit-form-grid textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--text);
  padding: 10px 11px;
  font: inherit;
  font-weight: 800;
}

.store-edit-form-grid textarea {
  resize: vertical;
  line-height: 1.5;
}

.store-edit-form-grid input[readonly],
.store-edit-form-grid textarea[readonly],
.store-edit-form-grid select:disabled {
  background: rgba(241, 245, 249, 0.78);
  color: var(--muted);
}

.store-edit-wide {
  grid-column: span 2;
}

.store-edit-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.record-main {
  min-width: 0;
}

.record-top {
  justify-content: flex-start;
  margin-bottom: 6px;
}

.module-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.8fr) minmax(0, 1.2fr);
  gap: 18px;
}

.panel {
  min-width: 0;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.48);
  backdrop-filter: saturate(180%) blur(18px);
}

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

.module-points {
  display: grid;
  gap: 12px;
}

.module-points > div {
  padding: 14px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
}

.module-points strong {
  display: block;
  margin-bottom: 5px;
}

.module-points span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.table-wrap {
  overflow-x: auto;
  max-width: 100%;
}

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

.integration-settings {
  margin-top: 14px;
}

.form-grid {
  display: grid;
  gap: 12px;
}

.form-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.crm-quotation-system {
  display: grid;
  grid-template-columns: minmax(620px, 1.35fr) minmax(360px, 0.8fr);
  align-items: start;
  gap: 14px;
  min-width: 0;
}

.crm-quotation-system.is-preview-hidden {
  grid-template-columns: minmax(0, 1fr);
}

.crm-quote-panel,
.crm-quote-list,
.crm-quote-preview-panel {
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.64);
  padding: 14px;
}

.crm-quote-panel .panel-heading,
.crm-quote-list .panel-heading,
.crm-quote-preview-panel .panel-heading {
  margin-bottom: 12px;
}

.crm-quote-panel h3,
.crm-quote-list h3,
.crm-quote-preview-panel h3 {
  margin: 2px 0 0;
  font-size: 18px;
}

.crm-quote-panel .panel-heading span,
.crm-quote-list .panel-heading span,
.crm-quote-preview-panel .panel-heading span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.crm-quote-list {
  grid-column: 1 / -1;
}

.crm-quote-form {
  display: grid;
  gap: 12px;
}

.crm-quote-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

.crm-quote-form label,
.crm-quote-static {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.crm-quote-form label span,
.crm-quote-static span,
.crm-quote-result span,
.crm-quote-card-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.crm-quote-form input,
.crm-quote-form select,
.crm-quote-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--text);
  padding: 9px 10px;
  font: inherit;
  font-size: 13px;
  font-weight: 760;
}

.crm-quote-form textarea {
  resize: vertical;
}

.crm-quote-form input[readonly] {
  background: rgba(240, 244, 248, 0.88);
  color: var(--muted);
}

.crm-quote-static {
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(240, 244, 248, 0.7);
  padding: 9px 10px;
}

.crm-quote-static strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  min-height: 20px;
}

.crm-quote-customer-box {
  gap: 8px;
}

.crm-quote-customer-lines {
  display: grid;
  gap: 6px;
}

.crm-quote-customer-lines p {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  margin: 0;
}

.crm-quote-customer-lines em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.crm-quote-customer-lines strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.45;
  word-break: break-word;
}

.crm-quote-brain-sync {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(59, 130, 246, 0.18);
  border-radius: 8px;
  background: rgba(239, 246, 255, 0.76);
  color: #2563eb;
  padding: 9px 10px;
  font-size: 12px;
  line-height: 1.5;
}

.crm-quote-brain-sync strong {
  flex: 0 0 auto;
  color: #1d4ed8;
  font-weight: 950;
}

.crm-quote-brain-sync span {
  font-weight: 850;
}

.crm-quote-suite-section {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.crm-quote-suite-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.crm-quote-suite-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.crm-quote-suite-head .chip-button {
  min-height: 32px;
  padding: 0 10px;
}

.crm-quote-suite-head > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.crm-quote-suite-grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-auto-flow: row;
  gap: 10px;
  overflow: visible;
  padding-bottom: 0;
}

.crm-quote-suite-card {
  display: grid;
  gap: 8px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 10px;
}

.crm-quote-suite-card header {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.crm-quote-suite-card header strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 950;
}

.crm-suite-common-wrap {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 8px;
  align-items: stretch;
  min-width: 0;
}

.crm-suite-measure-thumb {
  display: grid;
  grid-template-rows: minmax(74px, 1fr) auto;
  gap: 5px;
  min-height: 112px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--text);
  padding: 6px;
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.crm-suite-measure-thumb img {
  width: 100%;
  height: 74px;
  border-radius: 6px;
  object-fit: cover;
  object-position: top center;
  background: rgba(226, 232, 240, 0.9);
}

.crm-suite-measure-thumb span {
  overflow: hidden;
  color: var(--muted);
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.crm-suite-measure-thumb.is-empty {
  place-items: center;
  min-height: 112px;
  border-style: dashed;
  background: rgba(248, 250, 252, 0.7);
  cursor: default;
}

.crm-suite-common-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  min-width: 0;
}

.crm-quote-suite-card label {
  gap: 4px;
}

.crm-quote-suite-card input,
.crm-quote-suite-card select {
  padding: 8px;
  font-size: 12px;
}

.curtain-box-width-field.is-warning span,
.curtain-box-width-field.is-warning input {
  color: #dc2626;
}

.curtain-box-width-field.is-warning input {
  border-color: rgba(220, 38, 38, 0.42);
  background: rgba(254, 242, 242, 0.9);
}

.crm-suite-items {
  display: grid;
  gap: 7px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.74);
  padding: 8px;
}

.crm-suite-items-head,
.crm-suite-subtotal {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.crm-suite-items-head > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.crm-suite-items-head span,
.crm-suite-subtotal span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.crm-suite-item-list {
  display: grid;
  gap: 5px;
}

.crm-suite-item-row {
  display: grid;
  grid-template-columns: 84px minmax(86px, 1fr) 104px 96px 68px 78px 68px 82px minmax(150px, 1.2fr) minmax(84px, 1fr) 34px;
  gap: 5px;
  align-items: start;
}

body.quote-top-nav-mode .crm-suite-item-row {
  grid-template-columns:
    84px
    minmax(140px, 1.02fr)
    minmax(126px, 0.92fr)
    112px
    76px
    88px
    78px
    90px
    minmax(240px, 1.48fr)
    minmax(200px, 1.24fr)
    34px;
}

.crm-suite-item-row.is-tieback-item {
  border-radius: 8px;
  background: rgba(239, 246, 255, 0.66);
  padding: 0;
}

.crm-suite-item-row.is-tieback-item select,
.crm-suite-item-row.is-tieback-item input[readonly] {
  background: rgba(226, 232, 240, 0.72);
  color: var(--muted);
}

.crm-suite-item-row.is-fixed-multiplier .crm-suite-multiplier-field {
  visibility: hidden;
  pointer-events: none;
}

.crm-suite-pull-position-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-self: start;
  align-items: start;
  gap: 2px;
  min-width: 0;
  padding-top: 0;
}

.crm-suite-fabric-mode-cell {
  display: grid;
  min-width: 0;
}

.crm-suite-fabric-mode-cell.is-empty {
  min-height: 36px;
}

.crm-suite-pull-position-cell select {
  width: 100%;
  min-width: 0;
}

.crm-suite-pull-position-cell.is-empty {
  padding-top: 0;
}

.crm-suite-pull-position-cell.is-formula {
  align-self: stretch;
  align-items: center;
}

.crm-suite-pull-position-cell.is-track-options {
  align-items: stretch;
}

.crm-track-option-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.crm-fabric-process-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.crm-process-addon-controls {
  display: grid;
  grid-template-columns: minmax(58px, 0.85fr) minmax(76px, 1fr);
  gap: 5px;
}

.crm-free-order-button {
  width: 100%;
  min-height: 36px;
  border: 1px solid rgba(37, 99, 235, 0.22);
  border-radius: 8px;
  background: rgba(219, 234, 254, 0.72);
  color: #2563eb;
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.crm-free-order-button.is-active {
  border-color: rgba(16, 185, 129, 0.28);
  background: rgba(209, 250, 229, 0.78);
  color: #047857;
}

.crm-free-order-disabled {
  display: block;
  min-height: 36px;
}

.crm-suite-item-row.is-process-addon-item {
  border-radius: 8px;
  background: rgba(239, 246, 255, 0.66);
}

.crm-suite-item-row.is-process-addon-item input[readonly] {
  background: rgba(226, 232, 240, 0.72);
  color: var(--muted);
}

.crm-suite-item-row.is-free-order input[data-suite-item-field="price"],
.crm-suite-item-row.is-free-order input[data-suite-item-field="subtotal"] {
  color: var(--muted);
  text-decoration: line-through;
  text-decoration-thickness: 2px;
}

.crm-electric-inline-note {
  justify-self: center;
  width: 100%;
  min-width: 0;
  overflow: visible;
  border: 0;
  background: transparent;
  color: #2563eb;
  padding: 0;
  font: inherit;
  font-size: 11px;
  font-weight: 900;
  text-align: center;
  line-height: 1.35;
  white-space: normal;
  word-break: break-all;
  cursor: pointer;
}

.crm-electric-inline-note:hover {
  text-decoration: underline;
}

.crm-suite-item-row.is-head {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  padding: 0 4px;
}

.crm-suite-item-row .icon-button {
  width: 32px;
  height: 32px;
  min-height: 32px;
  border-radius: 8px;
  color: #ef4444;
}

.crm-suite-item-row > input,
.crm-suite-item-row > select,
.crm-suite-fabric-mode-cell select,
.crm-suite-pull-position-cell select {
  height: 36px;
  min-height: 36px;
  box-sizing: border-box;
}

.crm-suite-sku-suggestions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  min-height: 0;
}

.crm-suite-sku-suggestions:empty {
  display: none;
}

.crm-suite-sku-suggestions span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.crm-suite-sku-suggestions button {
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 999px;
  background: rgba(219, 234, 254, 0.8);
  color: #1d4ed8;
  padding: 5px 8px;
  font: inherit;
  font-size: 11px;
  font-weight: 900;
  cursor: pointer;
}

.crm-suite-formula-note {
  color: #2563eb;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.5;
  text-align: left;
}

.crm-suite-subtotal {
  justify-content: flex-end;
  border-top: 1px solid rgba(125, 137, 150, 0.14);
  padding-top: 7px;
}

.quote-pricing-system {
  display: grid;
  gap: 12px;
}

.quote-sku-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
  padding: 12px;
}

.quote-sku-form label {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.quote-sku-form label span,
.quote-sku-list header span,
.quote-sku-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.quote-sku-form input,
.quote-sku-form select {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  padding: 9px 10px;
  font: inherit;
  font-size: 13px;
  font-weight: 850;
}

.quote-sku-form-wide,
.quote-sku-form-actions {
  grid-column: span 2;
}

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

.quote-sku-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.quote-product-import-panel {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
  padding: 12px;
}

.quote-product-import-head,
.quote-product-import-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.quote-product-import-head div {
  display: grid;
  gap: 2px;
}

.quote-product-import-head h4 {
  margin: 0;
  color: var(--text);
  font-size: 17px;
  font-weight: 950;
}

.quote-product-import-head span,
.quote-product-import-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.quote-product-import-actions {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.quote-product-import-file {
  cursor: pointer;
}

.quote-product-import-file input {
  display: none;
}

.quote-product-search {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  align-items: end;
  gap: 10px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
  padding: 12px;
}

.quote-product-search label {
  display: grid;
  gap: 5px;
}

.quote-product-search span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.quote-product-search input {
  width: 100%;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  padding: 10px 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 850;
}

.quote-product-search strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 950;
  white-space: nowrap;
}

.quote-sku-list {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 12px;
}

.quote-sku-list header,
.quote-sku-row {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(160px, 0.7fr) auto;
  align-items: center;
  gap: 10px;
}

.quote-sku-row {
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.78);
  padding: 10px;
}

.quote-sku-row.is-disabled {
  opacity: 0.58;
}

.quote-sku-row div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.quote-sku-row strong {
  color: var(--text);
  font-weight: 950;
}

.quote-product-folder-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.quote-product-folder {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 12px;
  min-width: 0;
}

.quote-product-folder > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid rgba(125, 137, 150, 0.12);
  padding-bottom: 8px;
}

.quote-product-folder > header strong {
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
}

.quote-product-folder > header span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.quote-product-folder-list {
  display: grid;
  gap: 8px;
}

.quote-product-folder .quote-sku-row {
  grid-template-columns: minmax(0, 1.2fr) minmax(130px, 0.55fr) auto;
}

.quote-sku-actions {
  display: flex !important;
  flex-direction: row;
  justify-content: flex-end;
  gap: 6px;
}

.brain-center-system {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.brain-center-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 14px;
}

.brain-center-head h3 {
  margin: 0;
  color: var(--text);
  font-size: 22px;
  font-weight: 950;
}

.brain-center-head span,
.brain-form-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.brain-form {
  display: grid;
  gap: 12px;
}

.brain-rule-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.brain-rule-card {
  display: grid;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  padding: 12px;
}

.brain-rule-card header,
.brain-form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.brain-rule-card header div {
  display: grid;
  gap: 2px;
}

.brain-rule-card header span,
.brain-rule-fields span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.brain-rule-card header strong {
  color: var(--text);
  font-size: 16px;
  font-weight: 950;
}

.brain-rule-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.brain-rule-switch input {
  width: 16px;
  height: 16px;
}

.brain-formula-note {
  border-radius: 8px;
  background: rgba(59, 130, 246, 0.08);
  color: #1d4ed8;
  padding: 9px 10px;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.55;
}

.brain-rule-fields {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.brain-rule-fields label {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.brain-rule-fields input,
.brain-rule-fields select {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  padding: 8px 9px;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
}

.brain-rule-fields input:disabled,
.brain-rule-fields select:disabled {
  background: rgba(240, 244, 248, 0.78);
  color: var(--muted);
}

.brain-form-actions {
  justify-content: flex-start;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.7);
  padding: 12px;
}

.crm-suite-subtotal strong {
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
}

.crm-suite-wide {
  grid-column: 1 / -1;
}

.crm-quote-wide {
  grid-column: 1 / -1;
}

.crm-quote-span-2 {
  grid-column: span 2;
}

.crm-quote-span-3 {
  grid-column: span 3;
}

.crm-quote-span-4 {
  grid-column: span 4;
}

.crm-quote-span-6 {
  grid-column: 1 / -1;
}

.crm-quote-result {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid rgba(48, 164, 108, 0.18);
  border-radius: 8px;
  background: rgba(48, 164, 108, 0.12);
}

.crm-quote-result div {
  display: grid;
  gap: 4px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.74);
}

.crm-quote-result strong {
  color: var(--text);
  font-size: 17px;
  font-weight: 950;
}

.crm-measure-preview {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(10, 132, 255, 0.18);
  border-radius: 8px;
  background: rgba(10, 132, 255, 0.06);
  padding: 10px;
}

.crm-measure-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.crm-measure-preview-head span,
.crm-measure-preview-files span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-measure-preview-files {
  display: grid;
  gap: 6px;
}

.crm-measure-preview-files p {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
}

.crm-measure-preview-files a,
.crm-measure-pdf-button {
  color: var(--active-text);
  border: 0;
  border-radius: 999px;
  background: var(--active-bg);
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  padding: 5px 8px;
  text-decoration: none;
  cursor: pointer;
}

.crm-measure-test-file {
  margin-top: 2px;
}

.crm-measure-preview-files em {
  color: var(--text);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  padding: 5px 8px;
}

.crm-measure-import {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.crm-measure-import label {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.crm-measure-import textarea {
  min-height: 74px;
}

.crm-measure-import-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.crm-measure-file-button {
  position: relative;
  display: inline-grid;
  min-height: 34px;
  align-content: center;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  color: var(--text);
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.crm-measure-file-button input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.crm-measure-import-actions > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-measure-dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  background: transparent;
  padding: 32px;
  pointer-events: none;
}

.crm-measure-dialog-backdrop.is-full {
  background: rgba(15, 23, 42, 0.18);
  padding-top: 72px;
}

.crm-measure-dialog-backdrop.is-suite {
  inset: 84px 24px auto auto;
  width: min(560px, calc(100vw - 48px));
  max-height: 48vh;
  padding: 0;
  justify-content: flex-end;
}

.crm-measure-dialog {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 12px;
  width: min(1040px, calc(100vw - 64px));
  max-height: calc(100vh - 64px);
  min-width: 760px;
  border: 1px solid rgba(125, 137, 150, 0.2);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.98);
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.24);
  padding: 14px;
  pointer-events: auto;
}

.crm-measure-dialog-backdrop.is-suite .crm-measure-dialog {
  width: 100%;
  min-width: 0;
  max-height: 48vh;
  padding: 10px;
  box-shadow: 0 18px 46px rgba(15, 23, 42, 0.2);
}

.crm-measure-dialog header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
}

.crm-measure-dialog header span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.crm-measure-dialog header h3 {
  margin: 3px 0 2px;
  font-size: 20px;
  line-height: 1.2;
}

.crm-measure-dialog header p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-measure-dialog-body {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 12px;
  min-height: 0;
}

.crm-measure-dialog-backdrop.is-suite .crm-measure-dialog-body {
  grid-template-columns: minmax(0, 1fr);
}

.crm-measure-dialog-backdrop.is-suite .crm-measure-dialog-pages {
  display: none;
}

.crm-measure-dialog-pages {
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: 0;
  overflow: auto;
  padding-right: 2px;
}

.crm-measure-dialog-page {
  display: grid;
  gap: 5px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  padding: 6px;
  font: inherit;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.crm-measure-dialog-page.is-active {
  border-color: rgba(10, 132, 255, 0.45);
  background: var(--active-bg);
  color: var(--active-text);
}

.crm-measure-dialog-page img {
  width: 100%;
  height: 96px;
  border-radius: 6px;
  object-fit: cover;
  object-position: top center;
  background: rgba(226, 232, 240, 0.9);
}

.crm-measure-dialog-main {
  display: grid;
  gap: 10px;
  min-height: 0;
  overflow: auto;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
  padding: 10px;
}

.crm-measure-dialog-main > img {
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  object-position: top center;
  border-radius: 6px;
  background: rgba(226, 232, 240, 0.8);
}

.crm-measure-dialog-backdrop.is-suite .crm-measure-dialog-main > img {
  max-height: 30vh;
}

.crm-measure-dialog-suite {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 10px;
  align-items: center;
  border-radius: 8px;
  background: rgba(236, 253, 245, 0.9);
  color: var(--text);
  padding: 10px 12px;
}

.crm-measure-dialog-suite span,
.crm-measure-dialog-suite em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}

.crm-measure-dialog-suite strong {
  font-size: 15px;
  font-weight: 950;
}

.crm-electric-dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.22);
  padding: 32px;
}

.crm-electric-dialog {
  display: grid;
  gap: 12px;
  width: min(680px, calc(100vw - 64px));
  margin: auto;
  border: 1px solid rgba(125, 137, 150, 0.2);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.98);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.22);
  padding: 14px;
}

.crm-electric-dialog header,
.crm-electric-dialog footer {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.crm-electric-dialog header span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.crm-electric-dialog header h3 {
  margin: 3px 0 2px;
  font-size: 20px;
  line-height: 1.2;
}

.crm-electric-dialog header p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-electric-dialog-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.crm-electric-dialog-grid label {
  display: grid;
  gap: 5px;
}

.crm-electric-dialog-grid label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-electric-dialog-note {
  grid-column: 1 / -1;
}

.crm-quote-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.crm-quote-list {
  display: grid;
  align-content: start;
  gap: 10px;
}

.crm-customer-system {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: start;
  gap: 14px;
  min-width: 0;
}

.crm-customer-main-panel,
.crm-chat-panel,
.crm-import-panel,
.crm-order-history {
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.66);
  padding: 14px;
}

.crm-customer-main-panel {
  display: grid;
  gap: 14px;
}

.crm-lead-table,
.crm-aftercare-list,
.crm-order-history {
  display: grid;
  gap: 10px;
}

.crm-lead-row {
  display: grid;
  grid-template-columns: 150px minmax(120px, 0.8fr) 130px 88px minmax(220px, 1.5fr) 112px;
  align-items: center;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  padding: 10px;
}

.crm-lead-row strong,
.crm-lead-row span,
.crm-order-row strong,
.crm-order-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.crm-lead-import-panel,
.crm-lead-feedback {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(10, 132, 255, 0.14);
  border-radius: 8px;
  background: rgba(10, 132, 255, 0.06);
  padding: 12px;
}

.crm-lead-import-panel > div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.crm-lead-import-panel strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 950;
}

.crm-lead-import-panel span,
.crm-lead-muted {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.crm-lead-feedback {
  justify-content: flex-start;
  color: #0a66c2;
  font-size: 13px;
  font-weight: 900;
}

.crm-lead-stage-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.crm-lead-stage-card {
  display: grid;
  gap: 5px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  padding: 10px;
}

.crm-lead-stage-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-lead-stage-card strong {
  color: var(--text);
  font-size: 22px;
  font-weight: 950;
}

.crm-lead-board {
  display: grid;
  gap: 10px;
}

.crm-lead-card {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  padding: 12px;
}

.crm-lead-card-main {
  display: grid;
  grid-template-columns: minmax(280px, 1.4fr) minmax(360px, 1fr);
  gap: 12px;
  align-items: start;
}

.crm-lead-card-main strong {
  display: block;
  color: var(--text);
  font-size: 17px;
  font-weight: 950;
  margin-top: 3px;
}

.crm-lead-card-main p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.crm-lead-card-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.crm-lead-card-meta span {
  border-radius: 8px;
  background: rgba(240, 244, 248, 0.82);
  color: var(--muted);
  padding: 7px 8px;
  font-size: 12px;
  font-weight: 850;
}

.crm-lead-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.crm-lead-store-assign select {
  min-width: 240px;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--text);
  padding: 8px 10px;
  font: inherit;
  font-size: 13px;
  font-weight: 800;
}

.crm-lead-history {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  border-top: 1px solid rgba(125, 137, 150, 0.12);
  padding-top: 8px;
}

.crm-lead-history span {
  border-radius: 999px;
  background: rgba(125, 137, 150, 0.1);
  color: var(--muted);
  padding: 5px 8px;
  font-size: 12px;
  font-weight: 820;
}

.chip-button.danger {
  color: #c62828;
  background: rgba(255, 82, 82, 0.08);
}

.crm-wechat-link {
  border: 0;
  background: rgba(10, 132, 255, 0.1);
  color: #0a66c2;
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
}

.crm-new-customer-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.crm-import-panel,
.crm-order-history {
  background: rgba(240, 244, 248, 0.55);
}

.crm-import-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.crm-import-head strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 950;
}

.crm-import-head span,
.crm-chat-profile span,
.crm-aftercare-info span,
.crm-order-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

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

.crm-import-list button {
  display: grid;
  gap: 4px;
  width: 100%;
  border: 1px solid rgba(10, 132, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  padding: 9px 10px;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.crm-import-list strong,
.crm-import-list span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.crm-customer-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

.crm-customer-form label {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.crm-customer-form label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-customer-form input,
.crm-customer-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--text);
  padding: 9px 10px;
  font: inherit;
  font-size: 13px;
  font-weight: 760;
}

.crm-customer-form textarea {
  resize: vertical;
}

.crm-customer-paste,
.crm-customer-wide {
  grid-column: 1 / -1;
}

.crm-deposit-preview {
  align-self: end;
  min-height: 40px;
  border: 1px dashed rgba(48, 164, 108, 0.35);
  border-radius: 8px;
  background: rgba(48, 164, 108, 0.08);
  color: var(--muted);
  padding: 10px;
  font-size: 12px;
  font-weight: 850;
}

.crm-customer-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.crm-customer-feedback.is-hidden {
  display: none;
}

.crm-order-row {
  display: grid;
  grid-template-columns: minmax(260px, 1.4fr) 160px 150px;
  gap: 10px;
  align-items: center;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  padding: 10px;
}

.crm-order-row > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.crm-order-row-actions {
  justify-items: end;
}

.crm-order-row-actions .chip-button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.crm-chat-panel {
  position: sticky;
  top: 16px;
  display: grid;
  gap: 12px;
}

.crm-chat-profile,
.crm-aftercare-info {
  display: grid;
  gap: 8px;
}

.crm-chat-profile p,
.crm-aftercare-info p {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 8px;
  margin: 0;
}

.crm-chat-profile strong,
.crm-aftercare-info strong {
  min-width: 0;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  word-break: break-word;
}

.crm-chat-messages {
  display: grid;
  gap: 8px;
  max-height: 320px;
  overflow: auto;
}

.crm-chat-message {
  display: grid;
  gap: 4px;
  border-radius: 8px;
  background: rgba(240, 244, 248, 0.75);
  padding: 9px;
}

.crm-chat-message span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.crm-chat-message strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.45;
}

.crm-chat-compose {
  display: grid;
  gap: 8px;
}

.crm-chat-compose textarea {
  width: 100%;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--text);
  padding: 9px 10px;
  font: inherit;
  font-size: 13px;
  resize: vertical;
}

.crm-aftercare-card {
  display: grid;
  gap: 12px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  padding: 12px;
}

.crm-aftercare-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.crm-aftercare-card header > span {
  border-radius: 999px;
  background: rgba(48, 164, 108, 0.12);
  color: #188552;
  padding: 5px 8px;
  font-size: 12px;
  font-weight: 900;
}

.crm-aftercare-info {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.crm-flow-timeline {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.crm-flow-timeline span {
  display: grid;
  gap: 3px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(240, 244, 248, 0.68);
  padding: 8px;
}

.crm-flow-timeline span.is-active {
  border-color: rgba(10, 132, 255, 0.22);
  background: rgba(10, 132, 255, 0.08);
}

.crm-flow-timeline strong,
.crm-flow-timeline em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.crm-import-center {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(460px, 0.85fr);
  gap: 14px;
  align-items: start;
  min-width: 0;
}

.crm-import-main,
.crm-import-side,
.crm-import-preview-panel,
.crm-import-report,
.crm-import-history {
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
  padding: 14px;
}

.crm-import-main,
.crm-import-side,
.crm-import-preview-panel,
.crm-import-report,
.crm-import-history,
.crm-pilot-board,
.crm-import-batch-list {
  display: grid;
  gap: 12px;
}

.crm-import-source-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.crm-import-source-card {
  display: grid;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(10, 132, 255, 0.16);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.78);
  padding: 12px;
}

.crm-import-source-card header,
.crm-import-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.crm-import-source-card header {
  display: grid;
}

.crm-import-source-card strong,
.crm-import-head strong {
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
}

.crm-import-source-card span,
.crm-import-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.crm-import-source-card label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.crm-import-source-card input,
.crm-import-source-card textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  padding: 9px 10px;
  font: inherit;
  font-size: 13px;
}

.crm-import-source-card textarea {
  resize: vertical;
}

.crm-import-card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.crm-import-summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid rgba(10, 132, 255, 0.16);
  border-radius: 8px;
  background: rgba(10, 132, 255, 0.08);
}

.crm-import-summary-strip div,
.crm-import-report-grid div {
  display: grid;
  gap: 4px;
  background: rgba(255, 255, 255, 0.72);
  padding: 10px;
}

.crm-import-summary-strip span,
.crm-import-report-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.crm-import-summary-strip strong,
.crm-import-report-grid strong {
  color: var(--text);
  font-size: 22px;
  font-weight: 950;
}

.crm-import-preview-table {
  display: grid;
  overflow: hidden;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
}

.crm-import-preview-row {
  display: grid;
  grid-template-columns: 48px 1fr 120px 90px 120px minmax(220px, 1.4fr);
  min-width: 0;
  border-bottom: 1px solid rgba(125, 137, 150, 0.12);
}

.crm-import-preview-table.is-product .crm-import-preview-row {
  grid-template-columns: 48px minmax(180px, 1.2fr) minmax(140px, 0.8fr) 90px 88px minmax(220px, 1fr);
}

.crm-import-preview-row:last-child {
  border-bottom: 0;
}

.crm-import-preview-row.is-head {
  background: rgba(240, 244, 248, 0.84);
}

.crm-import-preview-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 9px 10px;
  color: var(--text);
  font-size: 12px;
  font-weight: 850;
}

.crm-import-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.crm-pilot-row {
  display: grid;
  grid-template-columns: 32px minmax(220px, 1.3fr) 120px 100px 112px;
  gap: 10px;
  align-items: center;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  padding: 10px;
}

.crm-pilot-row > span {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(10, 132, 255, 0.12);
  color: #0a66c2;
  font-size: 12px;
  font-weight: 950;
}

.crm-pilot-row div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.crm-pilot-row strong,
.crm-pilot-row em,
.crm-pilot-row small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.crm-pilot-row strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 950;
}

.crm-pilot-row em,
.crm-pilot-row small {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.crm-pilot-row div > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.crm-pilot-action {
  justify-items: end;
}

.crm-pilot-action .chip-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.crm-import-report-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid rgba(48, 164, 108, 0.16);
  border-radius: 8px;
  background: rgba(48, 164, 108, 0.08);
}

.crm-import-report-grid em {
  color: var(--green);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.crm-import-batch-list button {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 120px;
  gap: 10px;
  align-items: center;
  width: 100%;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--text);
  padding: 10px;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.crm-import-batch-list button.is-active {
  border-color: rgba(10, 132, 255, 0.34);
  background: rgba(10, 132, 255, 0.08);
}

.crm-import-batch-list strong,
.crm-import-batch-list span,
.crm-import-batch-list em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.crm-import-batch-list strong {
  font-size: 13px;
  font-weight: 950;
}

.crm-import-batch-list span,
.crm-import-batch-list em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.crm-flow-timeline strong {
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
}

.crm-flow-timeline em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.customer-quote-preview {
  overflow: auto;
  max-height: min(1120px, 78vh);
  border-radius: 8px;
  background: #f6f8fa;
  padding: 12px;
}

.customer-quote-template {
  width: min(100%, 794px);
  margin: 0 auto;
  border: 1px solid rgba(125, 137, 150, 0.2);
  border-radius: 4px;
  background: #ffffff;
  color: #16181d;
  padding: 34px;
  box-shadow: 0 14px 36px rgba(67, 82, 101, 0.16);
}

.sales-sheet-template {
  width: min(100%, 820px);
  padding: 22px;
  font-size: 12px;
  line-height: 1.35;
}

.sales-sheet-title {
  text-align: center;
}

.sales-sheet-title h2 {
  margin: 0 0 12px;
  color: #111827;
  font-size: 22px;
  font-weight: 950;
  letter-spacing: 0;
}

.sales-sheet-customer {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  margin-bottom: 8px;
}

.sales-sheet-customer p {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 6px;
  margin: 0;
  min-width: 0;
}

.sales-sheet-customer p.is-wide {
  grid-column: auto;
}

.sales-sheet-customer span {
  color: #111827;
  font-weight: 900;
}

.sales-sheet-customer strong {
  color: #111827;
  font-weight: 760;
  word-break: break-word;
}

.sales-sheet-note span,
.sales-sheet-note strong {
  color: #c0392b;
}

.sales-sheet-products {
  display: grid;
  gap: 6px;
}

.sales-sheet-suite {
  border: 1.5px solid #111827;
  border-bottom: 0;
}

.sales-sheet-suite header {
  display: grid;
  grid-template-columns: 1fr 1fr 0.7fr 0.9fr 1fr;
  gap: 8px;
  align-items: center;
  border-bottom: 1.5px solid #111827;
  background: #f8fafc;
  padding: 3px 6px;
  text-align: center;
  font-size: 13px;
  font-weight: 950;
}

.sales-sheet-table {
  display: grid;
  overflow-x: auto;
}

.sales-sheet-row {
  display: grid;
  grid-template-columns: 64px 46px 82px 72px 68px 48px 92px 48px 46px 54px 58px;
  min-width: 678px;
}

.sales-sheet-row span {
  min-width: 0;
  border-right: 1px solid #111827;
  border-bottom: 1px solid #111827;
  padding: 4px 3px;
  color: #111827;
  font-size: 11px;
  font-weight: 760;
  line-height: 1.35;
  text-align: center;
  word-break: break-word;
}

.sales-sheet-row span:last-child {
  border-right: 0;
}

.sales-sheet-row.is-head span {
  background: #f1f5f9;
  font-size: 10px;
  font-weight: 950;
}

.sales-sheet-image {
  display: grid;
  place-items: center;
  min-height: 58px;
  color: #9ca3af !important;
}

.sales-sheet-total {
  display: flex;
  justify-content: flex-end;
  gap: 22px;
  border: 1.5px solid #111827;
  border-top: 0;
  padding: 6px 8px;
  color: #1d4ed8;
  font-weight: 950;
}

.sales-sheet-footer {
  margin-top: 8px;
  color: #111827;
  font-size: 12px;
  font-weight: 760;
}

.sales-sheet-footer p {
  margin: 0;
}

.customer-quote-header,
.customer-quote-brand,
.customer-quote-total,
.customer-quote-signatures {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.customer-quote-header.is-minimal {
  justify-content: flex-end;
  border-bottom: 2px solid #111827;
  padding-bottom: 12px;
}

.customer-quote-brand img {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  object-fit: contain;
}

.customer-quote-brand strong {
  display: block;
  font-size: 24px;
  font-weight: 950;
}

.customer-quote-brand span,
.customer-quote-no span,
.customer-quote-contact span,
.customer-quote-info span,
.customer-quote-files span,
.customer-quote-total span,
.customer-quote-signatures span {
  color: #6b7280;
  font-size: 12px;
  font-weight: 800;
}

.customer-quote-no {
  display: grid;
  gap: 4px;
  text-align: right;
}

.customer-quote-no strong {
  font-size: 18px;
  font-weight: 950;
}

.customer-quote-title {
  margin: 30px 0 18px;
  border-top: 2px solid #111827;
  border-bottom: 1px solid #d1d5db;
  padding: 18px 0;
  text-align: center;
}

.customer-quote-title h2 {
  margin: 0;
  font-size: 28px;
  letter-spacing: 0;
}

.customer-quote-title p,
.customer-quote-terms p {
  margin: 8px 0 0;
  color: #4b5563;
  font-size: 13px;
  line-height: 1.7;
}

.customer-quote-section {
  display: grid;
  gap: 6px;
  margin-top: 18px;
  border: 1px solid #e5e7eb;
  border-radius: 4px;
  padding: 10px 12px;
}

.customer-quote-section h3 {
  margin: 0;
  color: #111827;
  font-size: 15px;
  font-weight: 950;
}

.customer-quote-contact-line {
  display: grid;
  grid-template-columns: auto minmax(90px, 0.7fr) auto minmax(110px, 0.7fr) auto minmax(0, 2fr);
  gap: 8px 10px;
  align-items: center;
}

.customer-quote-contact-line span {
  color: #6b7280;
  font-size: 12px;
  font-weight: 800;
}

.customer-quote-contact-line strong {
  font-size: 14px;
  font-weight: 900;
  line-height: 1.6;
  word-break: break-word;
}

.customer-quote-info {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.customer-quote-info div,
.customer-quote-files,
.customer-quote-terms {
  display: grid;
  gap: 6px;
  border: 1px solid #e5e7eb;
  border-radius: 4px;
  padding: 10px 12px;
}

.customer-quote-info strong {
  font-size: 14px;
  font-weight: 900;
  line-height: 1.5;
}

.customer-quote-files {
  margin-top: 10px;
}

.customer-quote-files p {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
}

.customer-quote-files em {
  border-radius: 999px;
  background: #f1f5f9;
  color: #111827;
  padding: 5px 8px;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.customer-quote-table {
  display: grid;
  margin-top: 4px;
  border: 1px solid #111827;
  border-bottom: 0;
}

.customer-quote-row {
  display: grid;
  grid-template-columns: 0.9fr 1fr 1.25fr 0.7fr 0.8fr;
}

.customer-quote-row span {
  min-width: 0;
  border-right: 1px solid #111827;
  border-bottom: 1px solid #111827;
  padding: 9px 8px;
  font-size: 12px;
  font-weight: 760;
  line-height: 1.45;
  word-break: break-word;
}

.customer-quote-row span:last-child {
  border-right: 0;
}

.customer-quote-row.is-head span {
  background: #f3f4f6;
  font-weight: 950;
  text-align: center;
}

.customer-quote-total {
  margin-top: 14px;
  border-top: 2px solid #111827;
  padding-top: 12px;
}

.customer-quote-total strong {
  color: #b42318;
  font-size: 26px;
  font-weight: 950;
}

.customer-quote-terms {
  margin-top: 14px;
}

.customer-quote-terms strong {
  font-size: 14px;
  font-weight: 950;
}

.customer-quote-signatures {
  margin-top: 26px;
}

.customer-quote-signatures div {
  display: grid;
  gap: 28px;
  width: 31%;
  border-bottom: 1px solid #111827;
  padding-bottom: 7px;
}

.customer-quote-signatures strong {
  min-height: 18px;
  font-size: 14px;
}

.crm-quote-card {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.78);
  padding: 12px;
}

.crm-quote-card-head,
.crm-quote-sync-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.crm-quote-card-head strong {
  display: block;
  margin-bottom: 3px;
  font-size: 15px;
}

.crm-quote-card-head span,
.crm-quote-sync-line span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.crm-quote-card-head em {
  border-radius: 999px;
  background: rgba(48, 164, 108, 0.12);
  color: var(--green);
  padding: 5px 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.crm-quote-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.crm-quote-card-grid div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.crm-quote-card-grid strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.sales-quote-management {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.sales-quote-toolbar {
  display: flex;
  justify-content: flex-end;
  min-width: 0;
}

.sales-quote-toolbar .time-range-template {
  justify-content: flex-end;
}

.sales-quote-status-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

.sales-quote-status-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 4px 10px;
  min-width: 0;
  min-height: 92px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: inherit;
  cursor: pointer;
  padding: 14px;
  text-align: left;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.sales-quote-status-card:hover,
.sales-quote-status-card.is-active {
  border-color: rgba(10, 132, 255, 0.35);
  box-shadow: 0 14px 34px rgba(10, 132, 255, 0.1);
  transform: translateY(-1px);
}

.sales-quote-status-strip span,
.sales-quote-lane header span,
.sales-quote-card-grid span,
.sales-quote-card-actions span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.sales-quote-status-strip strong {
  color: var(--text);
  font-size: 22px;
  font-weight: 950;
}

.sales-quote-status-card em {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.sales-quote-dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.32);
  padding: 36px;
}

.sales-quote-dialog {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 14px;
  width: min(1180px, calc(100vw - 72px));
  max-height: calc(100vh - 72px);
  min-width: 760px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.98);
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.22);
  padding: 16px;
}

.sales-quote-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.sales-quote-dialog-head h3 {
  margin: 2px 0 0;
  font-size: 22px;
}

.sales-quote-dialog-actions,
.sales-quote-action-group {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}

.sales-quote-dialog-actions > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.sales-quote-dialog-list {
  display: grid;
  align-content: start;
  gap: 12px;
  min-height: 0;
  overflow: auto;
  padding-right: 4px;
}

.sales-quote-list-panel {
  display: grid;
  gap: 12px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
  padding: 14px;
}

.sales-quote-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-width: 0;
}

.sales-quote-list-head h3 {
  margin: 2px 0 0;
  font-size: 20px;
}

.sales-quote-list-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}

.sales-quote-list-actions > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.sales-quote-row-list {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.sales-quote-row {
  display: grid;
  grid-template-columns: minmax(150px, 1.15fr) minmax(90px, 0.62fr) minmax(150px, 0.9fr) minmax(210px, 1.35fr) minmax(130px, 0.9fr) auto;
  align-items: center;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.13);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.82);
  padding: 10px;
}

.sales-quote-row.has-receipt {
  grid-template-columns: minmax(150px, 0.9fr) minmax(90px, 0.5fr) minmax(140px, 0.72fr) minmax(96px, 0.58fr) minmax(190px, 0.92fr) minmax(280px, 1.25fr) auto;
}

.sales-quote-row.is-completed {
  border-color: rgba(48, 164, 108, 0.18);
}

.sales-quote-row > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.sales-quote-row span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
}

.sales-quote-row strong {
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sales-quote-row-main strong {
  font-size: 14px;
}

.sales-quote-row-files {
  display: flex !important;
  flex-wrap: wrap;
  gap: 5px;
}

.sales-quote-row-files em {
  max-width: 120px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(10, 132, 255, 0.1);
  color: var(--active-text);
  padding: 4px 7px;
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sales-quote-row-receipt .sales-quote-receipt-panel {
  gap: 6px;
  padding: 8px;
}

.sales-quote-row-receipt .sales-quote-receipt-grid {
  grid-template-columns: minmax(0, 1fr) 112px;
}

.sales-quote-row-receipt .sales-quote-receipt-image {
  max-height: 110px;
}

.sales-quote-row-actions {
  display: flex !important;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px;
}

.sales-quote-board {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
  min-width: 0;
}

.sales-quote-lane {
  display: grid;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  padding: 12px;
}

.sales-quote-lane header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.sales-quote-lane header > div:first-child {
  flex: 0 0 auto;
}

.sales-quote-lane-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  min-width: 0;
  flex: 1 1 auto;
}

.sales-quote-lane-search {
  display: block;
  width: min(260px, 72%);
  min-width: 180px;
}

.sales-quote-lane-search input {
  box-sizing: border-box;
  width: 100%;
  height: 34px;
  border: 1px solid rgba(125, 137, 150, 0.2);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  outline: none;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 850;
}

.sales-quote-lane-search input:focus {
  border-color: rgba(10, 132, 255, 0.52);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.12);
}

.sales-quote-lane h3 {
  margin: 2px 0 0;
  font-size: 18px;
}

.sales-quote-card {
  display: grid;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(10, 132, 255, 0.16);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.82);
  padding: 12px;
}

.sales-quote-card.is-completed {
  border-color: rgba(48, 164, 108, 0.18);
}

.sales-quote-card-head,
.sales-quote-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.sales-quote-card-head strong {
  display: block;
  margin-bottom: 3px;
  font-size: 15px;
}

.sales-quote-card-head span,
.sales-quote-card p {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  line-height: 1.5;
}

.sales-quote-card p {
  margin: 0;
}

.sales-quote-card-head em {
  border-radius: 999px;
  background: rgba(10, 132, 255, 0.12);
  color: var(--active-text);
  padding: 5px 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.sales-quote-card.is-completed .sales-quote-card-head em {
  background: rgba(48, 164, 108, 0.12);
  color: var(--green);
}

.sales-quote-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.sales-quote-card-grid div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.sales-quote-card-grid strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.sales-quote-receipt-panel {
  display: grid;
  gap: 9px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  padding: 10px;
}

.sales-quote-receipt-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.sales-quote-receipt-head span,
.sales-quote-receipt-grid span,
.sales-quote-receipt-status span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.sales-quote-receipt-head strong,
.sales-quote-receipt-status strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.sales-quote-receipt-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(150px, 0.75fr);
  gap: 8px;
}

.sales-quote-receipt-grid label {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.sales-quote-receipt-grid input {
  box-sizing: border-box;
  width: 100%;
  min-height: 34px;
  border: 1px solid rgba(125, 137, 150, 0.2);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  padding: 6px 8px;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
}

.sales-quote-receipt-status {
  display: grid;
  gap: 3px;
  border-radius: 8px;
  background: rgba(125, 137, 150, 0.08);
  padding: 8px;
}

.sales-quote-receipt-status.is-ok {
  background: rgba(48, 164, 108, 0.12);
}

.sales-quote-receipt-status.is-ok strong {
  color: var(--green);
}

.sales-quote-receipt-status.is-bad {
  background: rgba(255, 59, 48, 0.1);
}

.sales-quote-receipt-status.is-bad strong {
  color: var(--red);
}

.sales-quote-receipt-status em {
  color: var(--active-text);
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
}

.sales-quote-receipt-image {
  width: 100%;
  max-height: 180px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: #fff;
  object-fit: contain;
}

.sales-quote-receipt-image.is-finance {
  max-height: 220px;
}

.sales-quote-receipt-remove {
  justify-self: start;
  color: var(--red);
}

.sales-quote-receipt-panel .chip-button:disabled,
.sales-quote-card-actions .chip-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.sales-quote-address-line,
.sales-quote-file-list {
  display: grid;
  gap: 5px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  padding: 9px 10px;
}

.sales-quote-address-line span,
.sales-quote-file-list span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.sales-quote-address-line strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.45;
}

.sales-quote-file-list div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.sales-quote-file-list em {
  border-radius: 999px;
  background: rgba(10, 132, 255, 0.1);
  color: var(--active-text);
  padding: 5px 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.hr-system {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.hr-project-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(320px, 1fr));
  gap: 14px;
  min-width: 0;
}

.hr-project-card,
.hr-wecom-panel {
  min-width: 0;
  padding: 16px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.48);
  backdrop-filter: saturate(180%) blur(18px);
}

.hr-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
}

.hr-card-head h3 {
  margin: 0;
  font-size: 18px;
}

.hr-card-copy {
  min-height: 44px;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.position-permission-panel {
  display: grid;
  gap: 10px;
  min-width: 0;
  margin-bottom: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(125, 137, 150, 0.14);
}

.position-permission-head {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.position-permission-head strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 900;
}

.position-permission-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.position-permission-list {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.position-permission-row {
  display: grid;
  grid-template-columns: minmax(92px, 0.7fr) minmax(0, 1.3fr);
  gap: 10px;
  align-items: start;
  min-width: 0;
  padding: 8px 0;
  border-top: 1px solid rgba(125, 137, 150, 0.1);
}

.position-permission-row:first-child {
  border-top: 0;
}

.position-permission-row div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.position-permission-row strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.position-permission-row span {
  color: var(--soft);
  font-size: 11px;
  font-weight: 650;
}

.position-permission-row p {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  min-width: 0;
  margin: 0;
}

.position-permission-row em {
  border: 1px solid rgba(0, 113, 227, 0.14);
  border-radius: 8px;
  background: rgba(0, 113, 227, 0.06);
  color: var(--blue);
  padding: 3px 7px;
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
}

.wecom-import-panel,
.employee-permission-overview,
.role-template-config-panel,
.permission-tree-panel,
.subaccount-permission-panel,
.position-selected-employee {
  min-width: 0;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
}

.wecom-import-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.wecom-import-steps span,
.position-selected-employee {
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
}

.wecom-import-steps span {
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(0, 113, 227, 0.12);
  border-radius: 8px;
  background: rgba(0, 113, 227, 0.05);
  text-align: center;
}

.role-template-list,
.employee-permission-list,
.permission-tree-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  min-width: 0;
}

.employee-permission-row {
  display: grid;
  grid-template-columns: minmax(150px, 0.85fr) minmax(120px, 0.7fr) minmax(0, 1.35fr) minmax(0, 1fr) 64px 70px;
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.64);
}

.employee-permission-person,
.employee-permission-template,
.position-selected-main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.employee-permission-person strong,
.employee-permission-template strong,
.position-selected-main strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.employee-permission-person span,
.employee-permission-template span,
.position-selected-main span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
}

.employee-operation-tags em {
  border-color: rgba(38, 167, 111, 0.16);
  background: rgba(38, 167, 111, 0.08);
  color: var(--green);
}

.role-template-row {
  display: grid;
  grid-template-columns: minmax(150px, 0.68fr) minmax(0, 1.32fr);
  gap: 10px;
  align-items: start;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.64);
}

.role-template-main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.role-template-main strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.role-template-main span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.45;
}

.template-permission-tags,
.tree-module-list,
.tree-operation-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
  margin: 0;
}

.template-permission-tags em,
.tree-module-list span,
.tree-operation-list span {
  border: 1px solid rgba(0, 113, 227, 0.14);
  border-radius: 8px;
  background: rgba(0, 113, 227, 0.06);
  color: var(--blue);
  padding: 4px 7px;
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
  line-height: 1.2;
}

.permission-tree-node {
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.64);
  overflow: hidden;
}

.permission-tree-node summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  cursor: pointer;
  padding: 10px;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  list-style: none;
}

.permission-tree-node summary::-webkit-details-marker {
  display: none;
}

.permission-tree-node summary::before {
  content: "";
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--blue);
  border-bottom: 2px solid var(--blue);
  transform: rotate(-45deg);
  transition: transform 0.18s ease;
}

.permission-tree-node[open] summary::before {
  transform: rotate(45deg);
}

.permission-tree-node summary span {
  min-width: 0;
  flex: 1 1 auto;
  overflow-wrap: anywhere;
}

.permission-tree-node summary em {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(38, 167, 111, 0.12);
  color: var(--green);
  padding: 4px 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  white-space: nowrap;
}

.permission-tree {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0 10px 10px 24px;
  list-style: none;
}

.permission-tree li {
  position: relative;
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 10px;
  min-width: 0;
  padding-left: 14px;
}

.permission-tree li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 8px;
  border-top: 1px solid rgba(125, 137, 150, 0.5);
}

.permission-tree li::after {
  content: "";
  position: absolute;
  left: 0;
  top: -8px;
  bottom: 10px;
  border-left: 1px solid rgba(125, 137, 150, 0.28);
}

.permission-tree li strong {
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.8;
}

.tree-operation-list span {
  border-color: rgba(38, 167, 111, 0.16);
  background: rgba(38, 167, 111, 0.08);
  color: var(--green);
}

.position-config-form {
  display: grid;
  gap: 12px;
}

.permission-check-section {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.permission-check-section h4 {
  margin: 0;
  color: var(--text);
  font-size: 13px;
}

.permission-check-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.permission-check-grid.action-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.permission-check {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--text);
  font-size: 12px;
  font-weight: 750;
}

.permission-check input {
  width: 15px;
  height: 15px;
  accent-color: var(--blue);
  flex: 0 0 auto;
}

.permission-check span {
  min-width: 0;
  overflow-wrap: anywhere;
}

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

.hr-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.hr-field input[readonly] {
  border-color: rgba(23, 163, 74, 0.22);
  background: rgba(23, 163, 74, 0.07);
  color: var(--green);
  font-weight: 900;
}

.hr-field span {
  color: var(--soft);
  font-size: 12px;
  font-weight: 800;
}

.hr-field input,
.hr-field select {
  width: 100%;
  min-width: 0;
  min-height: 40px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  outline: 0;
  background: rgba(255, 255, 255, 0.62);
  color: var(--text);
  padding: 0 11px;
  font-size: 13px;
  font-weight: 700;
}

.hr-field input:focus,
.hr-field select:focus {
  border-color: rgba(0, 113, 227, 0.6);
  box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.12);
}

.hr-form-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.hr-form-actions .primary-button {
  min-height: 36px;
}

.hr-form-feedback {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.hr-wecom-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(320px, 1.2fr);
  gap: 14px;
}

.hr-connection-list {
  display: grid;
  gap: 10px;
}

.hr-connection-item {
  min-height: 82px;
  padding: 14px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.52);
}

.hr-connection-item strong,
.hr-connection-item span {
  display: block;
}

.hr-connection-item strong {
  margin-bottom: 6px;
}

.hr-connection-item span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.dispatch-system {
  display: grid;
  grid-template-columns: minmax(300px, 1.05fr) minmax(300px, 1fr) minmax(300px, 0.95fr);
  gap: 14px;
  min-width: 0;
  max-width: 100%;
}

.dispatch-reference-layout {
  display: grid;
  grid-template-columns: minmax(300px, 0.85fr) minmax(420px, 1.15fr);
  gap: 14px;
  min-width: 0;
  max-width: 100%;
  margin-bottom: 14px;
}

.dispatch-panel {
  min-width: 0;
  max-width: 100%;
  padding: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  background: #fbfbfd;
}

.dispatch-reference-panel {
  min-width: 0;
  max-width: 100%;
  padding: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  background: #fbfbfd;
}

.dispatch-panel-head,
.dispatch-ticket-top,
.dispatch-engineer,
.dispatch-customer,
.dispatch-timeline-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.dispatch-panel-head {
  margin-bottom: 14px;
}

.dispatch-panel h3 {
  margin: 0;
  font-size: 18px;
}

.dispatch-module-points {
  display: grid;
  gap: 10px;
}

.dispatch-module-points div {
  display: grid;
  gap: 4px;
  min-height: 64px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.dispatch-module-points strong {
  font-size: 15px;
}

.dispatch-module-points span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.dispatch-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  max-width: 100%;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.dispatch-filter {
  flex: 1 0 auto;
  min-height: 32px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  padding: 0 10px;
  font-size: 13px;
  font-weight: 900;
}

.dispatch-filter.is-active {
  background: var(--active-bg);
  color: var(--active-text);
  box-shadow: inset 0 0 0 1px var(--active-border);
}

.dispatch-toggle {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 12px 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.dispatch-toggle input {
  width: 36px;
  height: 20px;
  margin: 0;
  appearance: none;
  position: relative;
  border-radius: 999px;
  background: #c7c7cc;
  transition: background 160ms ease;
}

.dispatch-toggle input::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.18);
  transition: transform 160ms ease;
}

.dispatch-toggle input:checked {
  background: var(--accent);
}

.dispatch-toggle input:checked::after {
  transform: translateX(16px);
}

.dispatch-ticket-list,
.dispatch-engineer-list,
.dispatch-timeline {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.dispatch-ticket {
  display: grid;
  gap: 8px;
  width: 100%;
  min-width: 0;
  min-height: 126px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 13px;
  color: var(--text);
  text-align: left;
}

.dispatch-ticket.is-selected {
  border-color: rgba(0, 113, 227, 0.45);
  box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.12);
}

.dispatch-ticket-top strong {
  min-width: 0;
  font-size: 15px;
  overflow-wrap: anywhere;
}

.dispatch-ticket-top span {
  flex: 0 0 auto;
  color: var(--violet);
  font-size: 12px;
  font-weight: 900;
}

.dispatch-ticket-meta,
.dispatch-engineer span,
.dispatch-route-copy span,
.dispatch-customer span,
.dispatch-note,
.dispatch-timeline-item span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.dispatch-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dispatch-route {
  position: relative;
  min-height: 208px;
  overflow: hidden;
  margin-bottom: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.035) 1px, transparent 1px),
    linear-gradient(rgba(0, 0, 0, 0.035) 1px, transparent 1px),
    #ffffff;
  background-size: 34px 34px;
}

.dispatch-route-line {
  position: absolute;
  top: 72px;
  left: 70px;
  right: 70px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--green));
}

.dispatch-route-node {
  position: absolute;
  top: 45px;
  display: grid;
  place-items: center;
  gap: 7px;
  width: 78px;
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
}

.dispatch-route-node.origin {
  left: 24px;
}

.dispatch-route-node.target {
  right: 24px;
}

.dispatch-route-node svg {
  width: 42px;
  height: 42px;
  padding: 10px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.13);
}

.dispatch-route-copy {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  display: grid;
  gap: 5px;
}

.dispatch-route-copy strong {
  font-size: 17px;
}

.dispatch-engineer {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.dispatch-engineer div {
  min-width: 0;
}

.dispatch-engineer strong {
  display: block;
  margin-bottom: 4px;
}

.dispatch-score {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border: 0;
  border-radius: 50%;
  background: conic-gradient(var(--accent) var(--score), #ececf0 0);
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.dispatch-score:hover {
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.12);
}

.dispatch-customer {
  justify-content: flex-start;
  margin-bottom: 14px;
}

.dispatch-customer strong,
.dispatch-customer span {
  display: block;
}

.dispatch-avatar {
  display: grid;
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 50%;
  background: var(--active-bg);
  color: var(--active-text);
  font-weight: 900;
}

.dispatch-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0 0 12px;
}

.dispatch-detail-grid div {
  min-width: 0;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.dispatch-detail-grid dt {
  color: var(--soft);
  font-size: 12px;
  font-weight: 900;
}

.dispatch-detail-grid dd {
  margin: 4px 0 0;
  font-size: 13px;
  line-height: 1.4;
}

.dispatch-note {
  margin-bottom: 14px;
  padding: 12px;
  border-radius: 8px;
  background: #ffffff;
}

.dispatch-return {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.dispatch-return div {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.dispatch-return span {
  display: block;
  color: var(--soft);
  font-size: 12px;
  font-weight: 900;
}

.dispatch-return strong {
  display: block;
  margin-top: 5px;
  font-size: 13px;
  line-height: 1.4;
}

.dispatch-timeline-item {
  align-items: flex-start;
  justify-content: flex-start;
}

.dispatch-timeline-item svg {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  padding: 6px;
  border-radius: 50%;
  background: #ffffff;
  color: var(--accent);
}

.dispatch-timeline-item strong {
  display: block;
  margin-bottom: 3px;
  font-size: 14px;
}

.dispatch-install-table {
  min-width: 0;
  max-width: 100%;
  margin-top: 14px;
  padding: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  background: #fbfbfd;
}

.dispatch-integration-settings {
  min-width: 0;
  max-width: 100%;
  margin-top: 14px;
  padding: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  background: #fbfbfd;
}

.dispatch-form-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.7fr) minmax(260px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.dispatch-form-grid label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.dispatch-form-grid label span {
  color: var(--soft);
  font-size: 12px;
  font-weight: 900;
}

.dispatch-form-grid select,
.dispatch-form-grid input {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--text);
  padding: 0 12px;
}

.dispatch-form-actions {
  display: grid;
  gap: 6px;
  min-width: 120px;
}

.dispatch-form-actions span {
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.dispatch-calendar-panel {
  min-width: 0;
  max-width: 100%;
  margin-bottom: 14px;
  padding: 16px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.48);
  backdrop-filter: saturate(180%) blur(22px);
}

.worker-calendar-panel {
  margin-bottom: 0;
  padding: 12px;
}

.calendar-panel-head {
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.dispatch-calendar-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
  min-width: 0;
}

.calendar-range {
  min-height: 34px;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--muted);
  padding: 0 10px;
  font-size: 13px;
  font-weight: 900;
}

.calendar-range.is-active {
  background: var(--active-bg);
  color: var(--active-text);
  box-shadow: inset 0 0 0 1px var(--active-border);
}

.dispatch-calendar-actions input {
  min-height: 34px;
  min-width: 138px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--text);
  padding: 0 10px;
  font-weight: 800;
}

.dispatch-engineer-filter {
  display: grid;
  gap: 4px;
  min-width: 132px;
}

.dispatch-engineer-filter span {
  color: var(--soft);
  font-size: 11px;
  font-weight: 900;
}

.dispatch-engineer-filter select {
  min-height: 34px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--text);
  padding: 0 10px;
  font-size: 13px;
  font-weight: 900;
}

.calendar-day-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 8px;
  margin-bottom: 14px;
}

.calendar-day {
  display: grid;
  gap: 8px;
  min-width: 0;
  min-height: 190px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: saturate(180%) blur(16px);
  color: var(--text);
  padding: 10px;
  text-align: left;
}

.calendar-date-row,
.calendar-engineer-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.calendar-day strong {
  font-size: 15px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calendar-date-row em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.calendar-engineer-stack {
  display: grid;
  gap: 7px;
  align-self: end;
}

.calendar-engineer-line {
  display: grid;
  grid-template-columns: minmax(48px, 1fr) auto;
  row-gap: 4px;
}

.calendar-engineer-line span,
.calendar-engineer-line b,
.calendar-engineer-line small {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calendar-engineer-line small {
  grid-column: 1 / -1;
  color: var(--soft);
  font-size: 11px;
  line-height: 1.35;
  overflow: visible;
  overflow-wrap: anywhere;
  text-overflow: clip;
  white-space: normal;
  word-break: normal;
}

.calendar-engineer-line i {
  grid-column: 1 / -1;
  display: block;
  overflow: hidden;
  height: 6px;
  border-radius: 999px;
  background: rgba(125, 137, 150, 0.16);
}

.calendar-engineer-line u {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--green));
  text-decoration: none;
}

.calendar-day.is-active {
  border-color: rgba(10, 132, 255, 0.32);
  background: linear-gradient(180deg, rgba(10, 132, 255, 0.9), rgba(0, 113, 227, 0.86));
  color: #ffffff;
}

.calendar-day.is-active span,
.calendar-day.is-active em,
.calendar-day.is-active b,
.calendar-day.is-active small {
  color: rgba(255, 255, 255, 0.78);
}

.calendar-day.is-active .calendar-engineer-line i {
  background: rgba(255, 255, 255, 0.22);
}

.calendar-day.is-active .calendar-engineer-line u {
  background: #ffffff;
}

.calendar-range-note {
  margin: -4px 0 14px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.calendar-day-detail-note {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin: -2px 0 12px;
  border: 1px solid var(--active-border);
  border-radius: 999px;
  background: var(--active-bg);
  color: var(--active-text);
  padding: 0 11px;
  font-size: 12px;
  font-weight: 650;
}

.engineer-work-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.engineer-work-row {
  min-width: 0;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  backdrop-filter: saturate(180%) blur(16px);
  box-shadow: 0 14px 34px rgba(67, 82, 101, 0.09);
  overflow: hidden;
}

.engineer-work-summary {
  display: grid;
  grid-template-columns: minmax(140px, 0.32fr) minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 14px;
  border-bottom: 1px solid rgba(125, 137, 150, 0.14);
}

.engineer-work-summary > div {
  min-width: 0;
}

.engineer-work-summary strong {
  display: block;
  overflow-wrap: anywhere;
  font-size: 16px;
}

.engineer-work-summary span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.engineer-progress,
.engineer-region,
.engineer-overdue {
  min-height: 64px;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid rgba(125, 137, 150, 0.12);
  background: rgba(255, 255, 255, 0.48);
}

.engineer-work-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(96px, 1fr));
  gap: 8px;
  min-width: 0;
}

.engineer-progress strong,
.engineer-region strong,
.engineer-overdue strong {
  margin-top: 6px;
  font-size: 20px;
}

.engineer-region strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.engineer-progress i {
  display: block;
  overflow: hidden;
  height: 6px;
  margin-top: 8px;
  border-radius: 999px;
  background: rgba(125, 137, 150, 0.16);
}

.engineer-progress u {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--green));
  text-decoration: none;
}

.engineer-overdue.has-overdue {
  background: rgba(255, 59, 48, 0.1);
}

.engineer-overdue.has-overdue strong {
  color: var(--red);
}

.engineer-order-frame {
  display: grid;
  gap: 10px;
  margin: 12px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.5);
  padding: 12px;
}

.engineer-order-frame-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(125, 137, 150, 0.12);
}

.engineer-order-frame-head span {
  color: var(--soft);
  font-size: 12px;
  font-weight: 650;
}

.engineer-order-frame-head strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 650;
  white-space: nowrap;
}

.engineer-order-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 10px;
  padding: 0;
}

.engineer-order-card {
  display: grid;
  gap: 8px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 12px;
  box-shadow: 0 8px 20px rgba(67, 82, 101, 0.06);
}

.engineer-order-card.is-overdue {
  border-color: rgba(255, 59, 48, 0.38);
  background: rgba(255, 59, 48, 0.06);
}

.engineer-order-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.engineer-order-badges {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
  min-width: 0;
}

.engineer-order-card.is-admin-card .tag.neutral,
.engineer-order-badges.is-admin-view .tag.neutral {
  display: none;
}

.engineer-order-top strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.engineer-order-card p {
  margin: 0;
  color: var(--text);
  font-weight: 900;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.engineer-order-card > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.engineer-storage-location {
  border-radius: 8px;
  background: rgba(0, 113, 227, 0.08);
  color: var(--blue) !important;
  padding: 7px 8px;
  font-weight: 850;
}

.engineer-order-address {
  border-radius: 8px;
  background: rgba(20, 184, 166, 0.09);
  color: #0f766e !important;
  padding: 7px 8px;
  font-weight: 850;
}

.engineer-order-schedule b,
.engineer-order-schedule em {
  font-style: normal;
  font-weight: 900;
}

.engineer-order-schedule b {
  color: var(--text);
}

.engineer-order-schedule b.is-urgent,
.engineer-order-schedule em {
  color: var(--red);
}

.worker-view-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
}

.worker-title-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}

.worker-view-head h3 {
  margin: 0;
  font-size: 18px;
}

.worker-head-metrics {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}

.worker-head-total,
.worker-head-chip {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 28px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  padding: 0 8px;
  color: inherit;
  font: inherit;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.worker-head-total {
  border-color: rgba(10, 132, 255, 0.18);
  background: rgba(10, 132, 255, 0.08);
}

.worker-head-total.is-active,
.worker-head-chip.is-active {
  border-color: rgba(10, 132, 255, 0.34);
  background: rgba(10, 132, 255, 0.14);
  box-shadow: 0 8px 20px rgba(10, 132, 255, 0.08);
}

.worker-head-total small,
.worker-head-chip small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 760;
}

.worker-head-total b,
.worker-head-chip b {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.worker-view-head input {
  width: min(190px, 58vw);
  min-height: 38px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
  color: var(--text);
  padding: 0 10px;
  font-size: 14px;
  font-weight: 800;
}

.worker-view-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
}

.worker-calendar-panel .engineer-work-list {
  grid-template-columns: 1fr;
  gap: 8px;
}

.worker-calendar-panel .engineer-work-row {
  border: 0;
  background: transparent;
  backdrop-filter: none;
  overflow: visible;
}

.worker-calendar-panel .engineer-order-list {
  padding: 0;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.worker-order-detail {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.48);
}

.worker-order-detail div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.worker-order-detail .worker-detail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.worker-order-detail span {
  color: var(--soft);
  font-size: 12px;
  font-weight: 650;
}

.worker-order-detail strong,
.worker-order-detail p {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.worker-order-detail .worker-address-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.worker-copy-address,
.worker-nav-address {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 10px;
  border: 1px solid rgba(0, 113, 227, 0.18);
  border-radius: 999px;
  background: rgba(0, 113, 227, 0.08);
  color: var(--blue);
  font-size: 12px;
  font-weight: 760;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}

.worker-nav-address {
  border-color: rgba(40, 160, 96, 0.22);
  background: rgba(40, 160, 96, 0.1);
  color: var(--green);
}

.worker-copy-address.is-copied {
  border-color: rgba(40, 160, 96, 0.22);
  background: rgba(40, 160, 96, 0.1);
  color: var(--green);
}

.worker-empty-content {
  padding: 10px;
  border: 1px dashed rgba(125, 137, 150, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.46);
  color: var(--muted) !important;
}

.worker-image-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 8px !important;
}

.worker-image-item {
  display: grid;
  gap: 5px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--text);
  padding: 6px;
  text-decoration: none;
}

.worker-image-item img {
  width: 100%;
  aspect-ratio: 1.2;
  border-radius: 6px;
  object-fit: cover;
  background: rgba(125, 137, 150, 0.12);
}

.worker-image-item small {
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.worker-order-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 6px;
  padding: 10px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.45);
}

.worker-order-controls label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.worker-order-controls label span {
  color: var(--soft);
  font-size: 12px;
  font-weight: 650;
}

.worker-order-controls select,
.worker-order-controls input {
  width: 100%;
  min-width: 0;
  min-height: 38px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background-color: rgba(255, 255, 255, 0.62);
  color: var(--text);
  padding: 0 10px;
  font: inherit;
  font-size: 13px;
}

.worker-photo-field,
.worker-signature-field {
  grid-column: 1 / -1;
}

.worker-photo-field input,
.worker-signature-field input {
  display: grid;
  align-content: center;
  border-style: dashed;
  padding: 8px;
}

.worker-photo-field em,
.worker-signature-field em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 650;
}

.worker-order-actions {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.worker-order-actions button {
  min-height: 36px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--text);
  font-weight: 650;
}

.worker-order-actions .worker-complete-action {
  border-color: var(--active-border);
  background: var(--active-bg);
  color: var(--active-text);
}

.worker-defer-field {
  grid-column: 1 / -1;
  padding: 10px;
  border: 1px solid rgba(10, 132, 255, 0.18);
  border-radius: 8px;
  background: rgba(10, 132, 255, 0.08);
}

.worker-defer-field input {
  background-color: rgba(255, 255, 255, 0.76);
}

.worker-order-actions button:disabled,
.worker-order-controls select:disabled,
.worker-order-controls input:disabled {
  cursor: not-allowed;
  opacity: 0.52;
}

.dispatch-measurement-queue {
  display: grid;
  gap: 12px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.66);
  padding: 14px;
}

.dispatch-measurement-list {
  display: grid;
  gap: 10px;
}

.dispatch-panel-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}

.dispatch-panel-actions span,
.dispatch-action-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dispatch-action-feedback {
  margin: -6px 0 2px;
}

.dispatch-assignment-toolbar {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 10px;
  align-items: end;
  min-width: 0;
}

.dispatch-assignment-toolbar > strong {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.dispatch-assignment-search {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.dispatch-assignment-search span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.dispatch-measurement-row {
  display: grid;
  grid-template-columns: minmax(260px, 1.3fr) 130px 120px 110px;
  gap: 10px;
  align-items: center;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  padding: 10px;
}

.dispatch-assignment-row {
  grid-template-columns: minmax(280px, 1.25fr) 110px 120px 150px 110px;
}

.dispatch-measurement-row > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.dispatch-measurement-row strong,
.dispatch-measurement-row span,
.dispatch-measurement-row small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dispatch-measurement-row span,
.dispatch-measurement-row small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dispatch-measurement-row small {
  display: block;
}

.dispatch-measurement-row .chip-button {
  justify-self: end;
}

.dispatch-order-drawer {
  position: fixed;
  inset: 0;
  z-index: 80;
  pointer-events: none;
}

.dispatch-drawer-backdrop {
  display: none;
}

.dispatch-drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  display: grid;
  grid-template-rows: auto minmax(0, auto);
  width: min(520px, 100%);
  height: auto;
  max-height: calc(100vh - 16px);
  min-width: 0;
  border-left: var(--hairline);
  border-bottom: var(--hairline);
  border-radius: 8px 0 0 8px;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: saturate(180%) blur(32px);
  box-shadow: -24px 0 60px rgba(67, 82, 101, 0.18);
  pointer-events: auto;
}

.dispatch-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px;
  border-bottom: 1px solid rgba(125, 137, 150, 0.14);
}

.drawer-close-button {
  min-height: 36px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  color: var(--text);
  padding: 0 12px;
  font-weight: 900;
}

.dispatch-new-order-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-content: start;
  overflow-y: auto;
  max-height: calc(100vh - 90px);
  padding: 18px;
}

.dispatch-new-order-form label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.dispatch-source-lock {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(48, 164, 108, 0.2);
  border-radius: 8px;
  background: rgba(48, 164, 108, 0.08);
  padding: 10px 12px;
}

.dispatch-source-lock span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.dispatch-source-lock strong {
  color: #188552;
  font-size: 13px;
  font-weight: 950;
}

.dispatch-new-order-form label span {
  color: var(--soft);
  font-size: 12px;
  font-weight: 900;
}

.dispatch-new-order-form input,
.dispatch-new-order-form select,
.dispatch-new-order-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.64);
  color: var(--text);
  padding: 0 12px;
  font: inherit;
}

.dispatch-new-order-form input:focus,
.dispatch-new-order-form select:focus,
.dispatch-new-order-form textarea:focus,
.record-action:focus-visible,
.drawer-close-button:focus-visible {
  border-color: rgba(10, 132, 255, 0.58);
  outline: 0;
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.12);
}

.dispatch-new-order-form input[readonly] {
  background: rgba(125, 137, 150, 0.1);
  color: var(--soft);
  cursor: not-allowed;
}

.dispatch-new-order-form input,
.dispatch-new-order-form select {
  min-height: 42px;
}

.dispatch-new-order-form textarea {
  resize: vertical;
  min-height: 96px;
  padding-top: 10px;
}

.dispatch-file-field input {
  display: grid;
  align-content: center;
  min-height: 76px;
  border-style: dashed;
  background: rgba(255, 255, 255, 0.42);
  padding: 16px;
}

.dispatch-drawer-wide,
.dispatch-drawer-actions {
  grid-column: 1 / -1;
}

.dispatch-drawer-actions {
  display: grid;
  gap: 8px;
}

.dispatch-new-order-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.dispatch-table-wrap {
  overflow-x: auto;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.dispatch-table-wrap table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
}

.dispatch-table-wrap th,
.dispatch-table-wrap td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  font-size: 13px;
  vertical-align: middle;
}

.dispatch-table-wrap th {
  color: var(--soft);
  font-weight: 900;
}

.dispatch-table-wrap td {
  color: var(--text);
}

.dispatch-table-wrap tr:last-child td {
  border-bottom: 0;
}

.dispatch-table-wrap td span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.record-title {
  display: block;
  color: var(--text);
  font-size: 16px;
  font-weight: 900;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 0 9px;
  background: rgba(255, 255, 255, 0.5);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.tag.blue {
  background: rgba(0, 113, 227, 0.1);
  color: #0064c8;
}

.tag.green {
  background: rgba(31, 138, 76, 0.11);
  color: var(--green);
}

.tag.red {
  background: rgba(195, 63, 50, 0.11);
  color: var(--red);
}

.tag.amber {
  background: rgba(179, 107, 0, 0.12);
  color: var(--amber);
}

.tag.neutral {
  background: rgba(255, 255, 255, 0.56);
  color: var(--muted);
}

.record-detail {
  margin-bottom: 0;
}

.record-action {
  min-width: 122px;
  min-height: 38px;
  border: var(--hairline);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: saturate(180%) blur(12px);
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.record-action.is-done {
  border-color: rgba(31, 138, 76, 0.25);
  background: rgba(31, 138, 76, 0.1);
  color: var(--green);
}

.automation-item {
  min-height: 54px;
  padding: 12px 0;
  border-top: 1px solid rgba(125, 137, 150, 0.16);
}

.automation-item:first-child {
  border-top: 0;
}

.automation-item strong {
  font-size: 14px;
}

.automation-item svg {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  color: var(--green);
}

.scanner-tool {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(125, 137, 150, 0.16);
}

.scanner-title {
  justify-content: flex-start;
}

.scanner-title svg {
  width: 22px;
  height: 22px;
  color: var(--accent);
}

.scanner-tool input {
  width: 100%;
  min-height: 44px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  padding: 0 12px;
}

.scanner-tool p {
  margin-bottom: 0;
}

.module-grid.production-war-mode {
  grid-template-columns: minmax(0, 1fr);
}

.production-work-surface {
  padding: 18px;
}

.production-work-surface > .surface-heading {
  display: none;
}

.production-war-room {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.production-war-hero,
.production-live-metrics,
.production-scan-panel,
.production-query-panel,
.production-new-order-panel,
.production-pad-panel,
.production-overdue-panel,
.production-sync-board,
.production-order-card {
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.66);
}

.production-war-hero {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: stretch;
  padding: 16px;
  background:
    linear-gradient(135deg, rgba(0, 113, 227, 0.1), rgba(38, 167, 111, 0.08)),
    rgba(255, 255, 255, 0.7);
}

.production-war-hero h2 {
  margin: 2px 0 6px;
  color: var(--text);
  font-size: 24px;
  line-height: 1.2;
}

.production-war-hero span,
.production-panel-head span,
.production-query-result span,
.production-pad-current span,
.production-pad-order header span,
.production-pad-grid span,
.production-sync-grid span,
.production-order-grid span,
.production-location-line span,
.production-sync-line small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.production-live-stack {
  display: grid;
  gap: 5px;
  min-width: 158px;
  align-content: center;
  justify-items: end;
  text-align: right;
}

.production-live-stack strong {
  color: var(--text);
  font-size: 26px;
  font-weight: 900;
  line-height: 1;
}

.production-live-stack em {
  border-radius: 999px;
  background: rgba(38, 167, 111, 0.12);
  color: var(--green);
  padding: 5px 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
}

.production-live-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
}

.production-live-metrics div {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 12px;
  background: rgba(248, 250, 252, 0.72);
}

.production-live-metrics span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 760;
}

.production-live-metrics strong {
  color: var(--text);
  font-size: 22px;
  font-weight: 900;
}

.production-new-order-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.production-new-order-form {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.production-form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

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

.production-quick-order-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.38fr);
  gap: 12px;
  align-items: start;
  min-width: 0;
}

.production-quick-main {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.production-new-order-form label {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.production-new-order-form label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.production-new-order-form input,
.production-new-order-form select,
.production-new-order-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  padding: 9px 10px;
  font: inherit;
  font-size: 13px;
  font-weight: 760;
}

.production-new-order-form textarea {
  resize: vertical;
}

.production-size-input input {
  min-height: 46px;
  border-color: rgba(10, 132, 255, 0.24);
  background: rgba(255, 255, 255, 0.94);
  font-size: 18px;
  font-weight: 900;
}

.production-size-tools {
  display: grid;
  grid-template-columns: minmax(180px, 0.32fr) minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
  min-width: 0;
}

.production-image-uploader {
  min-height: 78px;
  place-items: center;
  border: 1px dashed rgba(10, 132, 255, 0.4);
  border-radius: 8px;
  background: rgba(10, 132, 255, 0.08);
  color: var(--active-text);
  cursor: pointer;
  text-align: center;
}

.production-image-uploader input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.production-image-uploader span {
  color: var(--active-text);
  font-size: 13px;
}

.production-image-preview {
  min-height: 64px;
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--muted);
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
}

.production-image-preview img {
  width: 88px;
  height: 54px;
  border-radius: 6px;
  object-fit: cover;
  background: #ffffff;
}

.production-advanced-fields {
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.48);
  padding: 10px;
}

.production-advanced-fields summary {
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.production-advanced-fields .production-form-grid {
  margin-top: 10px;
}

.production-rule-panel {
  position: sticky;
  top: 12px;
  display: grid;
  gap: 12px;
  border: 1px solid rgba(48, 164, 108, 0.22);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(236, 248, 241, 0.92), rgba(255, 255, 255, 0.76));
  padding: 12px;
  min-width: 0;
}

.production-rule-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.production-rule-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.production-rule-head strong {
  color: var(--green);
  font-size: 14px;
  font-weight: 950;
}

.production-rule-list,
.production-calc-result {
  display: grid;
  gap: 8px;
}

.production-rule-list div,
.production-calc-result div {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  border-bottom: 1px solid rgba(125, 137, 150, 0.14);
  padding-bottom: 8px;
}

.production-rule-list div:last-child,
.production-calc-result div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.production-rule-list span,
.production-calc-result span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.production-rule-list strong {
  color: var(--text);
  font-size: 12px;
  font-weight: 850;
}

.production-calc-result {
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  padding: 10px;
}

.production-calc-result strong {
  color: var(--text);
  font-size: 18px;
  font-weight: 950;
}

.production-form-wide {
  grid-column: 1 / -1;
}

.production-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.production-new-order-feedback {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.production-station-config-panel {
  display: grid;
  gap: 12px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  padding: 14px;
}

.production-station-config-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.production-station-config-grid label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.production-station-config-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.production-station-config-grid input {
  width: 100%;
  min-width: 0;
  height: 40px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: #fff;
  padding: 0 10px;
  font: inherit;
  font-weight: 800;
}

.production-workflow {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  min-width: 0;
}

.production-step {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
}

.production-step strong,
.production-order-top strong,
.production-panel-head h3,
.production-sync-grid strong,
.production-location-line strong,
.production-order-grid strong {
  min-width: 0;
  color: var(--text);
  font-weight: 900;
  overflow-wrap: anywhere;
}

.production-step strong {
  font-size: 13px;
}

.production-step span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 760;
}

.production-step i,
.production-progress-track {
  display: block;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(125, 137, 150, 0.13);
  overflow: hidden;
}

.production-step i u,
.production-progress-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--green));
}

.production-control-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  min-width: 0;
}

.production-scan-panel,
.production-query-panel,
.production-pad-panel,
.production-overdue-panel,
.production-sync-board {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.production-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  min-width: 0;
}

.production-panel-head h3 {
  margin: 0;
  font-size: 18px;
}

.production-scan-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(140px, 0.55fr) minmax(0, 0.8fr) auto;
  gap: 10px;
  align-items: end;
  min-width: 0;
}

.production-scan-grid label,
.production-query-row {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.production-scan-grid label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.production-scan-grid input,
.production-scan-grid select,
.production-query-row input {
  width: 100%;
  min-width: 0;
  min-height: 42px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--text);
  padding: 0 10px;
  font: inherit;
}

.production-feedback {
  margin: 0;
  border-radius: 8px;
  background: rgba(0, 113, 227, 0.08);
  color: var(--blue);
  padding: 9px 10px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.5;
}

.production-query-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.production-query-results {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.production-pad-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.production-pad-tabs button {
  min-height: 32px;
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.72);
  color: var(--muted);
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.production-pad-tabs button.is-active {
  border-color: var(--active-border);
  background: var(--active-bg);
  color: var(--active-text);
}

.production-pad-current {
  display: grid;
  gap: 4px;
  min-width: 0;
  border-radius: 8px;
  background: rgba(0, 113, 227, 0.07);
  padding: 10px;
}

.production-pad-current strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 900;
}

.production-pad-current em {
  color: var(--blue);
  font-size: 12px;
  font-style: normal;
  font-weight: 820;
  line-height: 1.5;
}

.production-pad-orders {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.production-pad-order {
  display: grid;
  gap: 9px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.13);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.74);
  padding: 10px;
}

.production-pad-order header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.production-pad-order header div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.production-pad-order header strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.production-pad-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
}

.production-pad-grid div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.production-pad-grid strong {
  min-width: 0;
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.production-pad-panel {
  padding: 0;
  overflow: hidden;
  background: #eef4ff;
}

.production-pad-app {
  display: grid;
  min-width: 0;
  background: #edf4ff;
}

.production-pad-titlebar {
  display: grid;
  grid-template-columns: minmax(130px, 1fr) auto minmax(130px, 1fr);
  align-items: center;
  min-height: 48px;
  background: #0876ef;
  color: #ffffff;
  padding: 0 16px;
}

.production-pad-titlebar span,
.production-pad-titlebar em {
  min-width: 0;
  font-size: 15px;
  font-style: normal;
  font-weight: 850;
  overflow-wrap: anywhere;
}

.production-pad-titlebar strong {
  font-size: 17px;
  font-weight: 900;
}

.production-pad-titlebar em {
  justify-self: end;
  color: #ffd36a;
}

.production-pad-toolbar {
  display: grid;
  grid-template-columns: minmax(150px, 0.65fr) minmax(220px, 0.85fr) minmax(190px, 0.7fr) minmax(260px, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 12px 16px 8px;
}

.production-pad-worker,
.production-pad-position-select,
.production-pad-station-select {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.production-pad-worker span,
.production-pad-position-select span,
.production-pad-station-select span {
  color: #0876ef;
  font-size: 13px;
  font-weight: 900;
}

.production-pad-worker strong {
  min-width: 0;
  color: #172554;
  font-size: 15px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.production-pad-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 82px;
  gap: 8px;
  min-width: 0;
}

.production-pad-search input {
  min-width: 0;
  min-height: 42px;
  border: 1px solid rgba(8, 118, 239, 0.24);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.86);
  color: #172554;
  padding: 0 10px;
  font-size: 15px;
  font-weight: 850;
}

.production-pad-search button,
.production-pad-actions button,
.production-pad-process button,
.production-pad-footer button {
  border: 0;
  border-radius: 6px;
  color: #ffffff;
  font-weight: 900;
  cursor: pointer;
}

.production-pad-search button {
  min-height: 42px;
  background: #0876ef;
  font-size: 15px;
}

.production-pad-position-select .production-pad-tabs,
.production-pad-station-select .production-pad-tabs {
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 2px;
}

.production-pad-position-select .production-pad-tabs button,
.production-pad-station-select .production-pad-tabs button {
  flex: 0 0 auto;
  min-height: 32px;
  border-color: rgba(8, 118, 239, 0.18);
  background: rgba(255, 255, 255, 0.74);
  color: #2563eb;
}

.production-pad-position-select .production-pad-tabs button.is-active,
.production-pad-station-select .production-pad-tabs button.is-active {
  background: #0876ef;
  color: #ffffff;
}

.production-pad-body {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.75fr);
  gap: 12px;
  min-width: 0;
  padding: 0 16px 10px;
}

.production-pad-main {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.production-pad-customer {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.production-pad-customer > strong {
  color: #b45309;
  font-size: 16px;
  font-weight: 900;
}

.production-pad-spec-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(74px, 1fr));
  gap: 10px 12px;
  min-width: 0;
}

.production-pad-spec-grid div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.production-pad-spec-grid span,
.production-pad-footer span,
.production-pad-material-row span {
  color: #2563eb;
  font-size: 13px;
  font-weight: 820;
  line-height: 1.35;
}

.production-pad-spec-grid b {
  min-width: 0;
  color: #0f172a;
  font-size: 15px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.production-pad-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.production-pad-actions button {
  min-height: 42px;
  background: #f59e0b;
  padding: 0 14px;
  font-size: 14px;
}

.production-pad-image {
  display: grid;
  gap: 4px;
  place-items: center;
  width: 148px;
  min-height: 82px;
  border: 1px solid rgba(8, 118, 239, 0.2);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.72);
  color: #64748b;
}

.production-pad-image span {
  color: #2563eb;
  font-size: 12px;
  font-weight: 850;
}

.production-pad-image strong {
  font-size: 12px;
}

.production-pad-image img {
  width: 100%;
  max-height: 118px;
  object-fit: contain;
  border-radius: 6px;
}

.production-pad-image small {
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.production-pad-image.is-muted {
  opacity: 0.74;
}

.production-pad-process {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.production-pad-process button {
  min-height: 42px;
  border: 1px solid rgba(8, 118, 239, 0.25);
  background: rgba(255, 255, 255, 0.82);
  color: #172554;
  padding: 0 18px;
  font-size: 14px;
}

.production-pad-process span {
  color: #475569;
  font-size: 12px;
  font-weight: 780;
  line-height: 1.5;
}

.production-pad-side {
  display: grid;
  align-content: start;
  justify-items: center;
  gap: 18px;
  min-width: 0;
  padding-top: 4px;
}

.production-pad-remark {
  display: grid;
  gap: 8px;
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(8, 118, 239, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  padding: 12px;
}

.production-pad-remark span {
  color: #0876ef;
  font-size: 13px;
  font-weight: 900;
}

.production-pad-remark strong {
  min-width: 0;
  color: #0f172a;
  font-size: 15px;
  font-weight: 900;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.production-pad-side dl {
  display: grid;
  gap: 7px;
  width: 100%;
  margin: 0;
}

.production-pad-side dl div {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 6px;
  min-width: 0;
}

.production-pad-side dt,
.production-pad-side dd {
  margin: 0;
  min-width: 0;
  font-size: 13px;
  font-weight: 850;
  overflow-wrap: anywhere;
}

.production-pad-side dt {
  color: #0f172a;
}

.production-pad-side dd {
  color: #475569;
}

.production-pad-due {
  display: block;
  color: #0f172a;
  font-size: clamp(26px, 4vw, 42px);
  font-weight: 950;
  line-height: 1.1;
  text-align: center;
}

.production-pad-due.warning,
.production-pad-due.overdue {
  color: #b91c1c;
}

.production-pad-due.done {
  color: #15803d;
}

.production-pad-side p {
  width: 100%;
  margin: 0;
  border-radius: 6px;
  background: rgba(8, 118, 239, 0.08);
  color: #1d4ed8;
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.5;
}

.production-pad-side p.production-pad-start-line {
  background: rgba(22, 163, 74, 0.1);
  color: #15803d;
}

.production-pad-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: center;
  min-width: 0;
  border-top: 1px solid rgba(8, 118, 239, 0.12);
  padding: 10px 16px 6px;
}

.production-pad-footer button {
  min-width: 92px;
  min-height: 36px;
  background: #0876ef;
  font-size: 14px;
}

.production-pad-material-table {
  display: grid;
  min-width: 0;
  padding: 0 16px 14px;
}

.production-pad-material-row {
  display: grid;
  grid-template-columns: 78px 150px 100px 80px 80px minmax(190px, 1fr) 100px;
  gap: 8px;
  min-width: 860px;
  border-bottom: 1px solid rgba(8, 118, 239, 0.12);
  padding: 8px 0;
}

.production-pad-material-row.is-head span {
  color: #0f172a;
  font-weight: 900;
}

.production-pad-empty {
  display: grid;
  gap: 6px;
  padding: 18px;
}

.production-pad-empty strong {
  color: var(--text);
  font-size: 18px;
  font-weight: 900;
}

.production-pad-empty span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 780;
}

.production-overdue-list {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.production-overdue-item {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255, 59, 48, 0.14);
  border-radius: 8px;
  background: rgba(255, 59, 48, 0.06);
  color: var(--text);
  font: inherit;
  padding: 9px;
  text-align: left;
  cursor: pointer;
}

.production-overdue-item.is-active {
  border-color: rgba(255, 59, 48, 0.34);
  background: rgba(255, 59, 48, 0.11);
  box-shadow: inset 0 0 0 1px rgba(255, 59, 48, 0.12);
}

.production-overdue-item strong,
.production-overdue-item span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.production-overdue-item strong {
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
}

.production-overdue-item span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.production-overdue-item em {
  border-radius: 999px;
  background: rgba(255, 59, 48, 0.12);
  color: var(--red);
  padding: 4px 7px;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.production-overdue-detail {
  display: grid;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.72);
  padding: 12px;
}

.production-overdue-detail.is-empty {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  line-height: 1.6;
}

.production-overdue-detail-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  min-width: 0;
}

.production-overdue-detail-head div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.production-overdue-detail-head span,
.production-overdue-detail-grid span,
.production-overdue-detail-lines span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 820;
}

.production-overdue-detail-head strong {
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}

.production-overdue-detail-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.production-overdue-detail-grid div,
.production-overdue-detail-lines p {
  display: grid;
  gap: 3px;
  min-width: 0;
  margin: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.7);
  padding: 8px;
}

.production-overdue-detail-grid strong,
.production-overdue-detail-lines strong {
  min-width: 0;
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.production-overdue-detail-lines {
  display: grid;
  gap: 8px;
}

.production-query-result {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.12);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.72);
  color: var(--text);
  padding: 9px;
  text-align: left;
  cursor: pointer;
}

.production-query-result strong,
.production-query-result em {
  min-width: 0;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.production-query-result em {
  border-radius: 999px;
  background: rgba(0, 113, 227, 0.08);
  color: var(--blue);
  padding: 4px 7px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.production-order-list {
  display: grid;
  gap: 8px;
  min-width: 0;
  overflow-x: auto;
}

.production-print-panel {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.production-print-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.production-print-toolbar > div:first-child {
  display: grid;
  gap: 3px;
  min-width: 240px;
}

.production-print-toolbar h3 {
  margin: 0;
  color: var(--text);
  font-size: 18px;
  font-weight: 900;
}

.production-print-toolbar span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.production-print-filters {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.production-print-filters label {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.production-print-filters input {
  width: 150px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--text);
  font: inherit;
  font-weight: 850;
  padding: 0 10px;
}

.production-customer-order-list {
  display: grid;
  gap: 6px;
  min-width: 1160px;
}

.production-customer-order-row {
  display: grid;
  grid-template-columns: 34px minmax(260px, 1.8fr) 86px 110px 140px 110px 140px;
  gap: 10px;
  align-items: center;
  border: 1px solid rgba(31, 35, 40, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  padding: 10px 12px;
  min-height: 58px;
}

.production-customer-order-row.is-head {
  min-height: auto;
  border-color: transparent;
  background: rgba(248, 250, 252, 0.88);
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  text-transform: none;
}

.production-customer-order-row strong,
.production-customer-order-row span {
  min-width: 0;
}

.production-customer-order-row > strong {
  font-size: 14px;
  font-weight: 900;
  color: var(--text);
}

.production-print-check {
  display: grid;
  place-items: center;
  min-width: 0;
}

.production-print-check input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--primary);
}

.production-print-stage {
  display: none;
}

.production-customer-main {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.production-customer-main strong {
  color: var(--text);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.production-customer-main span {
  color: var(--muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.production-order-card {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.production-order-card.is-outbound {
  border-color: rgba(38, 167, 111, 0.22);
  background: rgba(246, 253, 249, 0.82);
}

.production-order-top,
.production-location-line,
.production-sync-line {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  min-width: 0;
}

.production-order-top div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.production-order-side {
  display: grid;
  justify-items: end;
  gap: 8px;
  min-width: 96px;
}

.production-print-button {
  min-height: 30px;
  padding: 6px 10px;
  font-size: 12px;
}

.production-order-top strong {
  font-size: 15px;
}

.production-order-top span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 740;
  overflow-wrap: anywhere;
}

.production-order-top em,
.production-sync-line span {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(255, 159, 10, 0.13);
  color: var(--amber);
  padding: 5px 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.production-qr-wrap {
  display: grid;
  justify-items: center;
  gap: 4px;
  min-width: 0;
}

.production-qr-code {
  display: grid;
  grid-template-columns: repeat(25, 3px);
  grid-auto-rows: 3px;
  gap: 1px;
  border: 1px solid rgba(17, 24, 39, 0.12);
  border-radius: 6px;
  background: #fff;
  padding: 5px;
}

.production-qr-code i {
  display: block;
  border-radius: 1px;
  background: transparent;
}

.production-qr-code i.is-active {
  background: var(--text);
}

.production-qr-wrap span {
  max-width: 108px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  line-height: 1.2;
  overflow-wrap: anywhere;
  text-align: center;
}

.production-wash-label-stack {
  display: grid;
  gap: 8px;
  justify-items: center;
}

.production-wash-label {
  display: grid;
  justify-items: stretch;
  gap: 2px;
  width: min(100%, 204px);
  margin: 2px auto 0;
  border: 1px solid rgba(17, 24, 39, 0.22);
  background: #ffffff;
  color: #111111;
  padding: 7px 8px 9px;
  font-family: "Songti SC", "STSong", "SimSun", serif;
  line-height: 1.16;
}

.production-wash-dash {
  height: 1px;
  margin: 2px 0 5px;
  border-top: 1px dashed #111111;
}

.production-wash-title {
  display: block;
  text-align: center;
  font-size: 20px;
  font-weight: 900;
  line-height: 1.1;
}

.production-wash-fields {
  display: grid;
  gap: 1px;
}

.production-wash-fields p,
.production-wash-label p {
  margin: 0;
  color: #111111;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.production-wash-fields p {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  align-items: start;
  gap: 3px;
  font-size: 12px;
}

.production-wash-fields span {
  color: #222222;
  font-weight: 850;
  white-space: nowrap;
}

.production-wash-fields strong {
  min-width: 0;
  color: #111111;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.production-wash-field-address strong {
  display: -webkit-box;
  line-clamp: 2;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.production-wash-table {
  display: grid;
  grid-template-columns: 1fr 1.3fr 0.7fr;
  border: 1px solid #111111;
  margin: 2px 0 5px;
}

.production-wash-table span {
  min-width: 0;
  border-right: 1px solid #111111;
  color: #111111;
  padding: 4px 3px;
  font-size: 13px;
  font-weight: 850;
  text-align: center;
  overflow-wrap: anywhere;
}

.production-wash-table span:last-child {
  border-right: 0;
}

.production-wash-qr {
  display: grid;
  grid-template-columns: repeat(25, 4px);
  grid-auto-rows: 4px;
  gap: 0;
  justify-self: center;
  margin-top: 4px;
  padding: 4px;
  background: #ffffff;
}

.production-wash-qr i {
  display: block;
  background: #ffffff;
}

.production-wash-qr i.is-active {
  background: #111111;
}

.production-wash-label em {
  color: #111111;
  font-size: 13px;
  font-style: normal;
  font-weight: 850;
  text-align: center;
}

.production-wash-label small {
  color: #111111;
  font-size: 8px;
  font-weight: 750;
  text-align: center;
  overflow-wrap: anywhere;
}

.production-order-card.is-outbound .production-order-top em,
.production-order-card.is-outbound .production-sync-line span {
  background: rgba(38, 167, 111, 0.13);
  color: var(--green);
}

.production-order-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  gap: 8px;
}

.production-order-grid div {
  display: grid;
  gap: 3px;
  min-width: 0;
  min-height: 62px;
  align-content: start;
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.72);
  padding: 8px;
}

.production-order-grid strong {
  font-size: 12px;
}

.production-delivery-alert {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: max-content;
  max-width: 100%;
  min-height: 24px;
  border-radius: 999px;
  background: rgba(125, 137, 150, 0.12);
  color: var(--muted);
  padding: 3px 7px;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.35;
  overflow-wrap: anywhere;
  text-align: center;
  white-space: normal;
}

.production-order-grid .production-delivery-alert {
  width: 100%;
}

.production-delivery-alert.ok {
  background: rgba(0, 113, 227, 0.09);
  color: var(--blue);
}

.production-delivery-alert.warning,
.production-delivery-alert.overdue {
  background: rgba(255, 59, 48, 0.12);
  color: var(--red);
}

.production-delivery-alert.done {
  background: rgba(38, 167, 111, 0.13);
  color: var(--green);
}

.production-location-line {
  border-top: 1px solid rgba(125, 137, 150, 0.12);
  padding-top: 10px;
}

.production-location-line strong {
  color: var(--blue);
  font-size: 13px;
  text-align: right;
}

.production-sync-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.production-sync-grid div {
  display: grid;
  gap: 4px;
  min-width: 0;
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.72);
  padding: 10px;
}

.production-data-report {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.production-data-head,
.production-data-card,
.production-data-table {
  min-width: 0;
  border: 1px solid rgba(125, 137, 150, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.66);
  padding: 14px;
}

.production-data-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.production-data-head h2 {
  margin: 0;
}

.production-data-head span,
.production-data-card header span,
.production-data-metrics span,
.production-data-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  line-height: 1.5;
}

.production-data-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.production-data-card {
  display: grid;
  gap: 12px;
}

.production-data-card header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.production-data-card header strong,
.production-data-metrics strong {
  color: var(--text);
  font-weight: 900;
}

.production-data-card .production-workflow {
  grid-template-columns: repeat(7, minmax(54px, 1fr));
  overflow-x: auto;
  padding-bottom: 2px;
}

.production-data-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.production-data-metrics div {
  display: grid;
  gap: 3px;
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.72);
  padding: 9px;
}

.production-data-table {
  display: grid;
  gap: 1px;
  overflow-x: auto;
}

.production-data-row {
  display: grid;
  grid-template-columns: 130px 150px 90px 78px 138px minmax(180px, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 790px;
  padding: 9px 10px;
  background: rgba(248, 250, 252, 0.72);
}

.production-data-row-head {
  border-radius: 8px 8px 0 0;
  background: rgba(0, 113, 227, 0.08);
}

.production-data-row-head span {
  color: var(--text);
  font-weight: 900;
}

.analytics-band {
  margin-top: 16px;
}

.bar-chart {
  display: grid;
  grid-template-columns: repeat(6, minmax(90px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.dispatch-volume-chart {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.chart-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.chart-range {
  min-height: 32px;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  color: var(--muted);
  padding: 0 10px;
  font-size: 13px;
  font-weight: 900;
}

.chart-range.is-active {
  background: var(--active-bg);
  color: var(--active-text);
  box-shadow: inset 0 0 0 1px var(--active-border);
}

.time-range-template {
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 12px;
  min-width: 0;
}

.time-range-fields,
.time-range-presets {
  display: flex;
  align-items: flex-end;
  flex-wrap: nowrap;
  gap: 12px;
  min-width: 0;
}

.time-range-field {
  display: grid;
  gap: 6px;
  min-width: 156px;
}

.time-range-field span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
  line-height: 1;
}

.time-range-date-input,
.time-range-button {
  min-height: 48px;
  border: 1px solid rgba(125, 137, 150, 0.18);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  box-shadow: 0 8px 20px rgba(67, 82, 101, 0.05);
  font: inherit;
  font-size: 20px;
  font-weight: 950;
  letter-spacing: 0;
}

.time-range-date-input {
  width: 100%;
  padding: 0 16px;
}

.time-range-button {
  min-width: 76px;
  padding: 0 18px;
  color: var(--muted);
  cursor: pointer;
}

.time-range-button.is-active {
  border-color: rgba(10, 132, 255, 0.42);
  background: rgba(10, 132, 255, 0.13);
  color: var(--text);
  box-shadow: inset 0 0 0 1px rgba(10, 132, 255, 0.22), 0 8px 20px rgba(10, 132, 255, 0.08);
}

.time-range-chart .time-range-date-input,
.time-range-chart .time-range-button {
  min-height: 42px;
  font-size: 15px;
}

.time-range-chart .time-range-field {
  min-width: 134px;
}

.bar-item {
  display: grid;
  align-content: end;
  min-height: 176px;
  gap: 8px;
}

.bar-track {
  position: relative;
  min-height: 128px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.48);
  overflow: hidden;
}

.bar-fill {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  min-height: 8px;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, #0071e3, #34a853);
}

.bar-label,
.bar-value {
  display: block;
  text-align: center;
}

.bar-value {
  color: var(--text);
  font-weight: 900;
}

.bar-detail {
  display: block;
  color: var(--soft);
  font-size: 12px;
  text-align: center;
}

.bar-category-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 5px;
  min-height: 24px;
}

.bar-category-list em {
  border: 1px solid rgba(125, 137, 150, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.56);
  color: var(--muted);
  padding: 3px 7px;
  font-size: 11px;
  font-style: normal;
  font-weight: 650;
  white-space: nowrap;
}

.finance-split {
  margin-top: 8px;
  justify-content: flex-start;
  flex-wrap: wrap;
}

.is-hidden {
  display: none;
}

body.is-pad-shell {
  background: #edf4ff;
}

body.is-pad-shell .topbar,
body.is-pad-shell .sidebar,
body.is-pad-shell .page-heading,
body.is-pad-shell .summary-grid,
body.is-pad-shell .production-war-hero,
body.is-pad-shell .production-live-metrics,
body.is-pad-shell .production-station-config-panel,
body.is-pad-shell .production-new-order-panel,
body.is-pad-shell .production-workflow,
body.is-pad-shell .production-overdue-panel,
body.is-pad-shell .production-order-list,
body.is-pad-shell .production-sync-board,
body.is-pad-shell .analytics-band {
  display: none;
}

body.is-pad-shell .system-layout {
  width: 100%;
  padding: 0;
}

body.is-pad-shell .module-grid,
body.is-pad-shell .production-control-grid {
  display: block;
}

body.is-pad-shell .work-surface,
body.is-pad-shell .production-work-surface,
body.is-pad-shell .production-war-room {
  border: 0;
  border-radius: 0;
  background: #edf4ff;
  box-shadow: none;
  padding: 0;
}

body.is-pad-shell .production-pad-panel {
  min-height: 100vh;
  border: 0;
  border-radius: 0;
}

select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: 34px !important;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%) !important;
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 12px) 50% !important;
  background-repeat: no-repeat !important;
  background-size: 6px 6px, 6px 6px !important;
}

h1,
h2,
h3,
.brand,
.module-button,
.module-subbutton,
.primary-button,
.secondary-button,
.chip-button,
.logout-text-button,
.calendar-range,
.chart-range,
.role-switcher,
.dispatch-engineer-filter select,
.metric-item strong,
.engineer-work-summary strong,
.engineer-order-card p,
.record-title {
  font-weight: 650;
}

.eyebrow,
.section-kicker,
.summary-heading span,
.metric-item span,
.calendar-engineer-line span,
.calendar-engineer-line b,
.tag,
.status-pill,
.dispatch-new-order-form label span,
.hr-field span {
  font-weight: 600;
}

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

  .top-controls {
    justify-content: end;
    flex-wrap: nowrap;
  }
}

@media (max-width: 1180px) {
  .system-layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }

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

  .module-grid,
  .page-heading {
    grid-template-columns: 1fr;
  }

  .dispatch-reference-layout,
  .dispatch-system,
  .production-control-grid,
  .hr-project-grid,
  .hr-wecom-grid {
    grid-template-columns: 1fr;
  }

  .production-scan-grid,
  .production-order-list {
    grid-template-columns: 1fr;
  }

  .production-workflow {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

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

  .production-quick-order-grid {
    grid-template-columns: 1fr;
  }

  .production-rule-panel {
    position: static;
  }

  .production-pad-toolbar {
    grid-template-columns: minmax(140px, 0.6fr) minmax(200px, 0.8fr) minmax(170px, 0.7fr) minmax(240px, 1fr);
  }

  .production-pad-body {
    grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.65fr);
  }

  .production-pad-spec-grid {
    grid-template-columns: repeat(4, minmax(74px, 1fr));
  }

  .dispatch-form-grid,
  .hr-form-grid {
    grid-template-columns: 1fr;
  }

  .boss-dashboard-head {
    grid-template-columns: 1fr;
  }

  .crm-quotation-system {
    grid-template-columns: 1fr;
  }

  .sales-quote-board {
    grid-template-columns: 1fr;
  }

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

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

  .store-directory-grid {
    grid-template-columns: 1fr;
  }

  .page-tools {
    justify-items: start;
  }

  .sync-strip {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  .login-screen {
    padding: 18px;
  }

  .login-card {
    width: min(300px, 100%);
  }

  .login-logo {
    width: 104px;
  }

  .topbar {
    grid-template-columns: 1fr;
    padding: 12px 16px;
  }

  .brand {
    width: max-content;
  }

  .top-controls {
    display: flex;
    justify-content: flex-start;
    width: 100%;
  }

  .logout-text-button,
  .primary-button {
    width: 100%;
  }

  .range-control {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
    gap: 6px;
  }

  .system-layout {
    width: calc(100% - 32px);
    padding: 16px 0 44px;
  }

  .sidebar {
    padding: 12px;
  }

  .module-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
    width: 100%;
    overflow: visible;
  }

  .module-group {
    min-width: 0;
  }

  .module-button {
    width: 100%;
  }

  .module-subnav {
    padding-left: 10px;
  }

  .production-pad-titlebar,
  .production-pad-toolbar,
  .production-pad-body {
    grid-template-columns: 1fr;
  }

  .production-pad-titlebar {
    gap: 4px;
    justify-items: start;
    padding: 10px 12px;
  }

  .production-pad-titlebar em {
    justify-self: start;
  }

  .production-pad-toolbar,
  .production-pad-body,
  .production-pad-footer,
  .production-pad-material-table {
    padding-left: 12px;
    padding-right: 12px;
  }

  .production-pad-spec-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .production-pad-side {
    justify-items: stretch;
  }

  .production-pad-due {
    text-align: left;
  }

  h1 {
    font-size: 34px;
  }

  .summary-grid,
  .metric-list {
    grid-template-columns: 1fr;
  }

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

  .boss-workload-dashboard {
    padding: 12px;
  }

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

  .workload-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .workload-head-row {
    display: none;
  }

  .workload-distribution-cell {
    grid-column: 1 / -1;
  }

  .position-permission-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .role-template-row,
  .permission-tree li {
    grid-template-columns: 1fr;
  }

  .permission-tree-node summary {
    align-items: flex-start;
  }

  .permission-tree-node summary em {
    white-space: normal;
  }

  .permission-tree {
    padding-left: 16px;
  }

  .wecom-import-steps,
  .permission-check-grid,
  .permission-check-grid.action-grid {
    grid-template-columns: 1fr;
  }

  .record-action {
    width: 100%;
  }

  .dispatch-work-surface,
  .hr-work-surface,
  .dispatch-panel,
  .dispatch-calendar-panel,
  .dispatch-reference-panel,
  .dispatch-integration-settings,
  .hr-project-card,
  .hr-wecom-panel {
    padding: 14px;
  }

  .calendar-panel-head,
  .engineer-work-summary,
  .engineer-order-top {
    align-items: stretch;
  }

  .dispatch-calendar-actions {
    justify-content: flex-start;
  }

  .calendar-day-list,
  .engineer-work-list,
  .dispatch-new-order-form {
    grid-template-columns: 1fr;
  }

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

  .engineer-work-stats {
    grid-template-columns: 1fr;
  }

  .engineer-order-badges {
    justify-content: flex-start;
  }

  .engineer-order-list {
    grid-template-columns: 1fr;
  }

  .production-war-hero,
  .production-panel-head,
  .production-pad-order header,
  .production-order-top,
  .production-location-line,
  .production-sync-line {
    flex-direction: column;
    align-items: stretch;
  }

  .production-live-stack {
    justify-items: start;
    text-align: left;
  }

  .customer-quote-preview {
    padding: 8px;
  }

  .customer-quote-template {
    padding: 22px;
  }

  .customer-quote-info {
    grid-template-columns: 1fr;
  }

  .customer-quote-table {
    overflow-x: auto;
  }

  .customer-quote-row {
    min-width: 560px;
  }

  .customer-quote-contact-line {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .sales-sheet-customer,
  .sales-sheet-suite header {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .sales-sheet-customer p.is-wide {
    grid-column: auto;
  }

  .production-live-metrics,
  .production-sync-grid,
  .production-order-grid,
  .production-pad-grid,
  .production-overdue-detail-grid,
  .production-data-metrics,
  .crm-quote-result,
  .crm-quote-card-grid,
  .sales-quote-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .production-data-grid {
    grid-template-columns: 1fr;
  }

  .production-query-result {
    grid-template-columns: 1fr;
  }

  .production-overdue-item {
    grid-template-columns: 1fr;
  }

  .production-data-head,
  .production-data-card header,
  .production-overdue-detail-head {
    flex-direction: column;
    align-items: stretch;
  }

  .production-query-result em {
    width: max-content;
    white-space: normal;
  }

  .worker-view-head,
  .worker-order-actions {
    grid-template-columns: 1fr;
  }

  .worker-view-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .worker-calendar-panel .worker-view-head {
    align-items: center;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px;
  }

  .worker-title-line {
    flex: 1 1 220px;
  }

  .worker-head-metrics {
    gap: 5px;
  }

  .worker-head-total,
  .worker-head-chip {
    min-height: 26px;
    padding: 0 7px;
  }

  .worker-view-head input {
    width: min(150px, 46vw);
  }

  .worker-calendar-panel .engineer-order-list {
    padding: 0;
  }

  .worker-order-controls {
    grid-template-columns: 1fr;
  }

  .dispatch-detail-grid {
    grid-template-columns: 1fr;
  }

  .dispatch-return {
    grid-template-columns: 1fr;
  }

  .dispatch-route-line {
    left: 58px;
    right: 58px;
  }

  .dispatch-route-node.origin {
    left: 8px;
  }

  .dispatch-route-node.target {
    right: 8px;
  }
}

@media (max-width: 680px) {
  .dispatch-calendar-panel {
    padding: 12px;
  }

  .worker-view-head {
    margin-bottom: 10px;
  }

  .dispatch-calendar-actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .calendar-day-list {
    display: flex;
    gap: 8px;
    margin-left: -2px;
    margin-right: -2px;
    overflow-x: auto;
    padding: 0 2px 6px;
    scroll-snap-type: x mandatory;
  }

  .calendar-day {
    flex: 0 0 142px;
    min-height: 124px;
    padding: 10px;
    scroll-snap-align: start;
  }

  .calendar-engineer-line {
    grid-template-columns: 1fr auto;
  }

  .engineer-work-row {
    border-radius: 8px;
  }

  .engineer-work-summary,
  .engineer-order-list {
    padding: 12px;
  }

  .engineer-order-card {
    gap: 10px;
    padding: 12px;
  }

  .engineer-order-top {
    flex-direction: column;
  }

  .engineer-order-badges {
    width: 100%;
  }

  .worker-order-detail,
  .worker-order-controls {
    padding: 9px;
  }

  .worker-order-actions button {
    min-height: 44px;
  }
}

@media (max-width: 520px) {
  .production-live-metrics,
  .production-sync-grid,
  .production-order-grid,
  .production-pad-grid,
  .production-overdue-detail-grid,
  .production-data-metrics,
  .production-form-grid,
  .production-form-grid.compact,
  .production-size-tools,
  .crm-quote-grid,
  .crm-quote-result,
  .crm-quote-card-grid,
  .sales-quote-status-strip,
  .sales-quote-card-grid,
  .production-query-row {
    grid-template-columns: 1fr;
  }

  .crm-quote-span-2,
  .crm-quote-span-3,
  .crm-quote-span-4,
  .crm-quote-span-6 {
    grid-column: 1 / -1;
  }

  .crm-quote-suite-card {
    grid-template-columns: 1fr;
  }

  .crm-quote-card-head,
  .crm-quote-sync-line,
  .customer-quote-header,
  .customer-quote-total,
  .customer-quote-signatures,
  .sales-quote-card-head,
  .sales-quote-card-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .customer-quote-signatures div {
    width: 100%;
  }

  .production-image-preview {
    grid-template-columns: 1fr;
  }

  .production-image-preview img {
    width: 100%;
    height: 120px;
  }

  .production-work-surface,
  .production-war-hero,
  .production-scan-panel,
  .production-query-panel,
  .production-overdue-panel,
  .production-sync-board,
  .production-data-head,
  .production-data-card,
  .production-data-table,
  .production-order-card {
    padding: 12px;
  }

  .production-order-side {
    justify-items: start;
  }

  .production-pad-panel {
    padding: 0;
  }

  .production-pad-search {
    grid-template-columns: 1fr;
  }

  .production-pad-spec-grid {
    grid-template-columns: 1fr;
  }

  .production-pad-material-table {
    overflow-x: auto;
  }

  .dispatch-compact-surface .surface-actions,
  .dispatch-action-metrics {
    grid-template-columns: 1fr;
  }

  .dispatch-compact-surface #module-action {
    width: 100%;
  }
}

@media print {
  @page {
    size: A4;
    margin: 12mm;
  }

  body.is-printing-quote {
    background: #ffffff !important;
  }

  body.is-printing-quote * {
    visibility: hidden !important;
  }

  body.is-printing-quote .customer-quote-preview,
  body.is-printing-quote .customer-quote-preview *,
  body.is-printing-quote .customer-quote-template,
  body.is-printing-quote .customer-quote-template * {
    visibility: visible !important;
  }

  body.is-printing-quote .customer-quote-preview {
    position: fixed;
    inset: 0;
    overflow: visible;
    max-height: none;
    background: #ffffff;
    padding: 0;
  }

  body.is-printing-quote .customer-quote-template {
    width: auto;
    min-height: 0;
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    padding: 0;
  }

  body.is-printing-production-order {
    background: #ffffff !important;
  }

  body.is-printing-production-order * {
    visibility: hidden !important;
  }

  body.is-printing-production-order .production-order-card.is-print-target,
  body.is-printing-production-order .production-order-card.is-print-target *,
  body.is-printing-production-order .production-print-stage.is-print-target,
  body.is-printing-production-order .production-print-stage.is-print-target * {
    visibility: visible !important;
  }

  body.is-printing-production-order .production-order-card.is-print-target,
  body.is-printing-production-order .production-print-stage.is-print-target {
    position: fixed;
    inset: 0;
    width: auto;
    min-height: 0;
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: #ffffff;
    overflow: visible;
  }

  body.is-printing-production-order .production-print-stage.is-print-target {
    display: grid !important;
    gap: 12px;
  }

  body.is-printing-production-order .production-print-stage.is-print-target .production-order-card {
    page-break-after: always;
    break-after: page;
  }

  body.is-printing-production-order .production-print-stage.is-print-target .production-order-card:last-child {
    page-break-after: auto;
    break-after: auto;
  }

  body.is-printing-production-order .production-print-button {
    display: none !important;
  }
}

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