:root {
  --bg: #f1f4f4;
  --panel: #ffffff;
  --text: #182522;
  --muted: #657471;
  --line: #d8e0de;
  --primary: #176f65;
  --primary-strong: #0f5c54;
  --primary-weak: #e7f3f0;
  --accent: #b2751a;
  --danger: #ae4545;
  --nav: #152521;
  --nav-muted: #a8bbb6;
  --blue: #35698f;
  --amber: #b67a20;
  --rose: #9e5262;
  --shadow: 0 8px 24px rgba(25, 52, 47, 0.07);
  --shadow-small: 0 2px 8px rgba(25, 52, 47, 0.06);
}

html {
  background: var(--bg);
}

body {
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  line-height: 1.45;
  letter-spacing: 0;
}

button,
input,
select,
textarea {
  letter-spacing: 0;
}

button {
  transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid rgba(23, 111, 101, 0.2);
  outline-offset: 2px;
}

input,
select,
textarea {
  min-height: 38px;
  border-color: #cfd9d6;
  border-radius: 6px;
  padding: 8px 10px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

input:hover,
select:hover,
textarea:hover {
  border-color: #aebeba;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(23, 111, 101, 0.09);
}

.app-shell {
  grid-template-columns: 228px minmax(0, 1fr);
  min-height: 100dvh;
}

.sidebar {
  position: sticky;
  top: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  height: 100dvh;
  gap: 8px;
  align-content: start;
  overflow-y: auto;
  padding: 18px 16px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--nav);
}

.sidebar > div:first-child,
.sidebar > .role-card,
.sidebar > .nav {
  grid-column: 1 / -1;
}

.sidebar > div:first-child {
  padding: 2px 4px 11px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar > div:first-child h1 {
  max-width: 180px;
  font-size: 20px;
  line-height: 1.35;
}

.sidebar .eyebrow {
  margin-bottom: 5px;
  color: var(--nav-muted);
  font-size: 11px;
}

.role-card {
  min-height: 66px;
  padding: 11px 12px;
  border-color: rgba(255, 255, 255, 0.13);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  color: #dce8e4;
  font-size: 12px;
  line-height: 1.5;
}

.role-card strong {
  color: #ffffff;
  font-size: 14px;
}

.role-card p {
  display: none;
}

.sidebar > .ghost-btn {
  min-height: 34px;
  padding: 7px 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: #d8e7e2;
  font-size: 12px;
}

.sidebar > .ghost-btn:hover {
  border-color: rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.11);
}

.nav {
  gap: 4px;
  margin-top: 4px;
}

.nav-group {
  gap: 3px;
}

.nav-btn,
.nav-sub-btn {
  position: relative;
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: #c9d7d3;
  font-size: 13px;
}

.nav-btn {
  padding: 9px 11px;
}

.nav-btn:hover,
.nav-sub-btn:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #ffffff;
}

.nav-btn.active {
  border-color: rgba(83, 184, 165, 0.18);
  background: rgba(46, 139, 126, 0.18);
  color: #ffffff;
  font-weight: 700;
}

.nav-btn.active::before {
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: 0;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: #5ac0ad;
  content: "";
}

.nav-sub-list {
  gap: 3px;
  padding-left: 8px;
  border-left-color: rgba(255, 255, 255, 0.12);
}

.nav-sub-btn {
  min-height: 32px;
  padding: 6px 10px;
  color: var(--nav-muted);
  font-size: 12px;
}

.nav-sub-btn.active {
  border-color: transparent;
  background: #e5f2ef;
  color: var(--primary-strong);
  font-weight: 700;
}

.content {
  width: 100%;
  max-width: 1680px;
  margin: 0 auto;
  padding: 18px 22px 32px;
}

.topbar {
  min-height: 54px;
  margin-bottom: 12px;
}

.topbar .eyebrow {
  margin-bottom: 3px;
  color: #788682;
  font-size: 11px;
}

.topbar h2 {
  font-size: 24px;
  line-height: 1.25;
}

.topbar-actions {
  gap: 8px;
}

.topbar-actions .ghost-btn {
  min-height: 34px;
  border: 1px solid #cfe0dc;
  padding: 7px 11px;
}

.mode-pill {
  min-height: 28px;
  border: 1px solid #d6e9e4;
  border-radius: 999px;
  background: #edf7f4;
  color: var(--primary-strong);
  font-size: 12px;
}

.filters {
  position: sticky;
  top: 0;
  z-index: 12;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 9px;
  margin-bottom: 14px;
  padding: 11px 12px;
  border-color: #d3ddda;
  border-radius: 6px;
  box-shadow: 0 6px 18px rgba(25, 52, 47, 0.08);
}

.filters label {
  gap: 4px;
  color: #62716e;
  font-size: 12px;
  font-weight: 600;
}

.filters input,
.filters select,
.filters button {
  min-height: 36px;
}

.task-id-filter {
  grid-column: span 2;
}

.task-id-filter-controls {
  gap: 6px;
}

.task-id-filter button {
  min-width: 58px;
  padding-inline: 10px;
}

.task-lookup-panel {
  margin-bottom: 14px;
  border-radius: 6px;
  box-shadow: var(--shadow-small);
}

.workspace-intro {
  border-radius: 6px;
  box-shadow: none;
}

.metric,
article,
.detail-card,
.task-card,
.form-grid,
.role-guide-card,
.account-form,
.management-panel {
  border-color: var(--line);
  border-radius: 6px;
  box-shadow: var(--shadow-small);
}

.management-board {
  gap: 10px;
}

.management-panel {
  overflow: visible;
  padding: 0;
  box-shadow: var(--shadow);
}

.management-panel-heading {
  align-items: center;
  padding: 13px 16px;
  background: #ffffff;
}

.management-panel-heading h3 {
  font-size: 18px;
}

.management-panel-heading p {
  margin-top: 3px;
  font-size: 12px;
}

.management-export-menu summary {
  min-height: 34px;
  border-color: #cbd8d5;
  border-radius: 6px;
  padding: 7px 10px;
  color: var(--primary-strong);
  font-size: 12px;
}

.management-panel-body {
  gap: 14px;
  padding: 14px 16px 18px;
}

.management-analysis-tabs {
  width: 390px;
  max-width: 100%;
}

.management-analysis-tabs.admin-customer-tabs {
  width: 430px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.admin-customer-dashboard {
  gap: 18px;
  min-width: 0;
}

.admin-customer-filter-panel {
  padding: 12px 0 14px;
  border-block: 1px solid var(--line);
}

.admin-customer-filter-heading,
.admin-customer-detail-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.admin-customer-filter-heading h4,
.admin-customer-detail-heading h4,
.admin-customer-detail-section h5 {
  margin: 0;
  color: #183d35;
}

.admin-customer-filter-heading span,
.admin-customer-detail-heading span {
  color: var(--muted);
  font-size: 12px;
}

.admin-customer-filters {
  display: grid;
  grid-template-columns: repeat(5, minmax(128px, 1fr));
  align-items: end;
  gap: 9px;
  min-width: 0;
}

.admin-customer-filters label {
  display: grid;
  gap: 5px;
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.admin-customer-filters select,
.admin-customer-filters input {
  width: 100%;
  min-width: 0;
  min-height: 34px;
}

.admin-customer-keyword {
  grid-column: span 2;
}

.admin-customer-filters > button {
  min-height: 34px;
  white-space: nowrap;
}

.admin-customer-status {
  min-height: 18px;
  color: var(--muted);
  font-size: 12px;
}

.admin-customer-status.error {
  color: #a33d3d;
}

.admin-customer-kpi-strip,
.admin-customer-secondary-strip {
  display: grid;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background: #fff;
}

.admin-customer-kpi-strip {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.admin-customer-secondary-strip {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 8px;
  background: #fafcfc;
}

.admin-customer-kpi {
  display: grid;
  min-width: 0;
  min-height: 68px;
  align-content: center;
  gap: 5px;
  padding: 9px 12px;
  border: 0;
  border-right: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.admin-customer-kpi:last-child {
  border-right: 0;
}

.admin-customer-kpi:hover,
.admin-customer-kpi:focus-visible,
.admin-customer-kpi.active {
  background: #eef7f4;
}

.admin-customer-kpi span {
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 11px;
}

.admin-customer-kpi strong {
  color: #183d35;
  font-size: 21px;
}

.admin-customer-auxiliary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  padding: 9px 2px 0;
  color: var(--muted);
  font-size: 12px;
}

.admin-customer-auxiliary span {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.admin-customer-auxiliary b {
  color: var(--text);
  font-size: 14px;
}

.admin-customer-distributions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  min-width: 0;
}

.admin-customer-distributions > section {
  min-width: 0;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.admin-customer-bar-list {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.admin-customer-bar {
  display: grid;
  grid-template-columns: minmax(74px, 118px) minmax(48px, 1fr) 32px;
  align-items: center;
  gap: 8px;
  min-width: 0;
  min-height: 34px;
  padding: 4px 5px;
  border: 0;
  border-radius: 3px;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.admin-customer-bar:hover,
.admin-customer-bar:focus-visible {
  background: #f1f7f5;
}

.admin-customer-bar > span {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 12px;
}

.admin-customer-bar > i {
  display: block;
  height: 7px;
  overflow: hidden;
  border-radius: 2px;
  background: #e4ece9;
}

.admin-customer-bar > i b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}

.admin-customer-bar > strong {
  text-align: right;
}

.admin-customer-list-section {
  min-width: 0;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.admin-customer-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 5px;
}

.admin-customer-table {
  width: 100%;
  min-width: 1120px;
  border-collapse: collapse;
  background: #fff;
  font-size: 12px;
}

.admin-customer-table th,
.admin-customer-table td {
  padding: 9px 8px;
  border-bottom: 1px solid #e8eeec;
  text-align: left;
  vertical-align: middle;
}

.admin-customer-table th {
  background: #f5f8f7;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}

.admin-customer-table tbody tr:last-child td {
  border-bottom: 0;
}

.admin-customer-table tbody tr:hover {
  background: #f8fbfa;
}

.admin-customer-completeness {
  display: inline-block;
  min-width: 46px;
  padding: 3px 6px;
  border-radius: 3px;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
}

.admin-customer-completeness.complete {
  background: #e8f5ef;
  color: #216b4d;
}

.admin-customer-completeness.incomplete {
  background: #fff4df;
  color: #976316;
}

.admin-customer-pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-height: 38px;
  padding-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

.admin-customer-detail {
  min-width: 0;
  padding-top: 15px;
  border-top: 2px solid #b9cec9;
}

.admin-customer-detail-section {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.admin-customer-detail-section:last-child {
  border-bottom: 0;
}

.admin-customer-profile-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin-top: 9px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--line);
}

.admin-customer-profile-grid > div {
  display: grid;
  min-width: 0;
  gap: 4px;
  padding: 9px;
  background: #fff;
}

.admin-customer-profile-grid span,
.admin-customer-note > span {
  color: var(--muted);
  font-size: 11px;
}

.admin-customer-profile-grid strong {
  overflow-wrap: anywhere;
  font-size: 12px;
}

.admin-customer-note {
  margin-top: 9px;
}

.admin-customer-note p {
  margin: 4px 0 0;
  white-space: pre-wrap;
}

.admin-customer-batch-detail {
  border-bottom: 1px solid var(--line);
}

.admin-customer-batch-detail summary {
  display: grid;
  grid-template-columns: minmax(150px, .5fr) minmax(0, 1fr);
  gap: 10px;
  padding: 9px 2px;
  cursor: pointer;
}

.admin-customer-batch-detail summary span {
  color: var(--muted);
  font-size: 12px;
}

.admin-customer-item-list,
.admin-customer-history-list {
  display: grid;
  gap: 1px;
  padding-bottom: 8px;
  background: var(--line);
}

.admin-customer-item-list > div,
.admin-customer-history-list > div {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(110px, .5fr) minmax(140px, .7fr);
  gap: 8px;
  padding: 8px;
  background: #fafcfc;
  font-size: 12px;
}

.admin-customer-item-list small {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.segmented-control {
  gap: 2px;
  padding: 3px;
  border-radius: 6px;
  background: #f1f5f4;
}

.segmented-control button {
  min-height: 32px;
  border: 0;
  border-radius: 4px;
}

.segmented-control button.active {
  background: #ffffff;
  color: var(--primary-strong);
  box-shadow: 0 1px 4px rgba(25, 52, 47, 0.1);
}

.analysis-kpi-grid {
  gap: 9px;
}

.analysis-kpi {
  --metric-accent: var(--primary);
  position: relative;
  min-height: 82px;
  gap: 8px;
  padding: 12px 13px;
  border-top: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(25, 52, 47, 0.04);
}

.analysis-kpi::before {
  position: absolute;
  top: 0;
  left: 13px;
  width: 26px;
  height: 3px;
  border-radius: 0 0 2px 2px;
  background: var(--metric-accent);
  content: "";
}

.analysis-kpi:nth-child(2n) {
  --metric-accent: var(--blue);
  border-top-color: var(--line);
}

.analysis-kpi:nth-child(3n) {
  --metric-accent: var(--amber);
  border-top-color: var(--line);
}

.analysis-kpi:nth-child(5n) {
  --metric-accent: var(--rose);
}

.analysis-kpi span {
  font-size: 12px;
  font-weight: 600;
}

.analysis-kpi strong {
  color: #17231f;
  font-size: 23px;
}

.analysis-kpi-action:hover,
.analysis-kpi-action:focus-visible {
  border-color: #b9cec9;
  background: #f7fbfa;
  box-shadow: 0 4px 12px rgba(25, 52, 47, 0.08);
}

.overview-section {
  padding: 14px 0 2px;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
}

.overview-section-heading {
  margin-bottom: 9px;
}

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

.analysis-bar-list {
  gap: 3px;
}

.analysis-bar-row {
  min-height: 40px;
  padding: 6px 8px;
  border-radius: 4px;
}

.analysis-bar-row:hover,
.analysis-bar-row:focus-visible {
  background: #f1f7f5;
}

.analysis-bar-track {
  height: 8px;
  border-radius: 2px;
  background: #e5ecea;
}

.analysis-bar-track i {
  background: var(--primary);
}

.analysis-bar-row:nth-child(2n) .analysis-bar-track i {
  background: var(--blue);
}

.people-performance-row {
  grid-template-columns: minmax(84px, 130px) minmax(0, 1fr) 64px;
  gap: 14px;
  min-height: 58px;
  padding: 8px 10px;
  border-bottom-color: #e7edeb;
}

.people-performance-row:nth-child(even) {
  background: #fafcfc;
}

.people-name {
  color: var(--primary-strong);
  font-size: 13px;
}

.people-performance-metric {
  grid-template-columns: 40px minmax(0, 1fr) 28px;
}

.stacked-status-track {
  height: 16px;
  border-radius: 2px;
  background: #e5ebe9;
}

.stacked-status-bar {
  border-radius: 2px;
}

.stack-segment.complete {
  background: #398064;
}

.stack-segment.incomplete {
  background: #c1812c;
}

.anomaly-badge {
  min-width: 60px;
  min-height: 30px;
  border: 1px solid #ebc8c8;
  background: #fff5f5;
  color: #a33d3d;
  font-size: 12px;
}

.anomaly-count-zero {
  color: #98a5a2;
  font-size: 12px;
  text-align: center;
}

.task-layout {
  grid-template-columns: minmax(360px, 0.82fr) minmax(520px, 1.18fr);
  gap: 16px;
  align-items: start;
}

.task-layout > div:last-child {
  position: sticky;
  top: 72px;
}

.section-heading {
  min-height: 30px;
  align-items: center;
  margin-bottom: 9px;
}

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

.task-search-panel {
  gap: 6px;
  margin-bottom: 9px;
}

.task-search-panel button {
  min-height: 36px;
}

.task-list,
.team-task-list {
  gap: 7px;
}

.task-card {
  position: relative;
  min-height: 78px;
  padding: 11px 12px 10px 14px;
  overflow: hidden;
  box-shadow: none;
}

.task-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: #c5d2cf;
  content: "";
}

.task-card:hover {
  border-color: #b7c9c5;
  background: #fbfdfc;
}

.task-card.active {
  border-color: #73a99f;
  background: #edf7f4;
  box-shadow: 0 3px 10px rgba(23, 111, 101, 0.08);
}

.task-card.active::before {
  background: var(--primary);
}

.task-card strong {
  font-size: 14px;
}

.task-card p {
  margin-top: 4px;
  font-size: 12px;
  line-height: 1.45;
}

.admin-task-card {
  min-height: 0;
  padding: 12px 13px 12px 15px;
}

.admin-task-card-head {
  min-width: 0;
}

.admin-task-facts {
  padding-top: 9px;
  border-top: 1px solid #e6ecea;
}

.sales-task-group {
  border-radius: 6px;
}

.sales-task-group-header {
  min-height: 38px;
  background: #e9efed;
}

.sales-task-group-header:hover {
  background: #dfe9e6;
}

#taskDetail {
  max-height: calc(100dvh - 142px);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 15px 16px 18px;
  box-shadow: var(--shadow);
  scrollbar-gutter: stable;
}

#taskDetail.empty {
  min-height: 140px;
}

.detail-card > strong:first-child,
.detail-card > h3:first-child {
  font-size: 18px;
}

.detail-grid {
  gap: 8px;
  margin: 10px 0;
}

.detail-section {
  gap: 8px;
  margin-top: 12px;
}

.detail-section h4 {
  margin: 4px 0 0;
  padding-bottom: 6px;
  border-bottom: 1px solid #e5ebe9;
  color: #31413d;
  font-size: 14px;
}

.detail-item {
  min-height: 58px;
  padding: 8px 10px;
  border-color: #dfe6e4;
  border-radius: 5px;
  background: #fcfdfd;
}

.detail-item span {
  margin-bottom: 2px;
  font-size: 11px;
  font-weight: 600;
}

.round-card {
  border-radius: 5px;
  background: #fcfdfd;
}

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

.quote-decision-option {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 10px 12px;
  background: #f7fbfa;
  box-shadow: inset 0 0 0 1px #dceae6;
}

.quote-decision-option textarea,
.quote-decision-option select,
.quote-decision-option button {
  width: 100%;
  max-width: 100%;
}

.quote-decision-option > strong {
  color: #263b35;
  font-size: 13px;
}

.quote-return-option {
  border-left-color: var(--accent);
  background: #fffbf3;
}

.quote-termination-option,
.quote-termination-record {
  border-left-color: var(--danger);
  background: #fff7f7;
}

.quote-termination-option .field {
  margin: 0;
}

.status-quote-terminated {
  border-color: #e6b8b8;
  background: #fff0f0;
  color: #963b3b;
}

.log-panel,
.log-collapsed {
  border-radius: 5px;
}

.form-header {
  gap: 4px;
  margin-bottom: 12px;
}

.form-header h3 {
  font-size: 20px;
}

.form-grid,
.account-form {
  padding: 14px;
}

.form-section {
  border-radius: 6px;
  box-shadow: none;
}

.account-form {
  grid-template-columns: repeat(4, minmax(150px, 1fr)) auto;
  gap: 9px;
  margin-bottom: 12px;
}

.account-form button[type="submit"] {
  min-height: 38px;
  white-space: nowrap;
}

.account-table {
  position: relative;
  max-height: calc(100dvh - 250px);
  margin-top: 0;
  overflow: auto;
  border-radius: 6px;
  background: #ffffff;
  scrollbar-gutter: stable;
}

.account-summary {
  position: sticky;
  top: 0;
  z-index: 4;
  min-height: 40px;
  align-items: center;
  padding: 8px 11px;
  background: #f7faf9;
}

.account-table .table-head {
  position: sticky;
  top: 40px;
  z-index: 3;
  background: #e7efed;
  color: #4f605c;
  font-weight: 700;
}

.account-table .table-row:not(.table-head):hover {
  background: #f8fbfa;
}

.account-table .table-row .table-cell:last-child {
  position: sticky;
  right: 0;
  z-index: 2;
  background: #ffffff;
  box-shadow: -7px 0 12px rgba(25, 52, 47, 0.06);
}

.account-table .table-head .table-cell:last-child {
  z-index: 5;
  background: #e7efed;
}

.account-table .table-row:not(.table-head):hover .table-cell:last-child {
  background: #f8fbfa;
}

.account-table .table-cell {
  padding: 8px 9px;
  font-size: 12px;
}

.account-table .table-link {
  min-height: 30px;
  margin: 2px;
  padding: 5px 8px;
}

.sales-team-management {
  margin-top: 18px;
}

.table {
  border-radius: 6px;
}

.table-head {
  background: #eaf0ee;
  color: #566662;
}

.table-cell {
  padding: 8px 9px;
}

.management-board .compact-assignment-table .table-head .table-cell,
.compact-assignment-table .table-head .table-cell,
.overview-data-table .table-head .table-cell {
  background: #274840;
}

.assignment-detail-panel {
  border-radius: 6px;
  background: #f8faf9;
}

.login-screen {
  background: #e9efed;
}

.login-panel {
  border-radius: 6px;
  box-shadow: inset 0 3px var(--primary), 0 18px 48px rgba(25, 52, 47, 0.12);
}

.login-panel h1 {
  font-size: 26px;
}

.multi-product-mode-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0 0 14px;
  padding: 10px 12px;
  border-block: 1px solid var(--line);
  background: #f7faf9;
}

.multi-product-mode-panel > span {
  color: var(--muted);
  font-size: 12px;
}

.multi-product-form {
  min-width: 0;
  gap: 14px;
  background: #f4f7f6;
}

.multi-product-heading,
.multi-product-item-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.multi-product-section {
  gap: 0;
  overflow: hidden;
  padding: 0;
}

.multi-product-section > .form-section-grid {
  padding: 14px;
}

.multi-product-section-heading {
  min-height: 66px;
  padding: 12px 14px;
  background: #fbfcfc;
}

.multi-product-section-title {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 11px;
}

.multi-product-section-title > div {
  min-width: 0;
}

.multi-product-section-number {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border-radius: 5px;
  background: #e5f1ee;
  color: #145c51;
  font-size: 11px;
  font-weight: 800;
}

.form-section-heading .multi-product-shared-label {
  min-width: 0;
  border: 1px solid #c8ddd7;
  border-radius: 999px;
  background: #edf6f4;
  color: #176258;
}

.multi-product-items {
  display: grid;
  gap: 9px;
  min-width: 0;
  padding: 10px;
  background: #f4f7f6;
}

.multi-product-item {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #d8e1df;
  border-radius: 6px;
  background: #ffffff;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.multi-product-item.expanded {
  border-color: #a9c9c1;
  box-shadow: 0 3px 12px rgba(31, 73, 64, 0.07);
}

.multi-product-item-heading {
  min-height: 60px;
  padding: 10px 12px;
  background: #ffffff;
}

.multi-product-item-title {
  display: grid;
  min-width: 0;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
}

.multi-product-item-index {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 5px;
  background: #e7f1ef;
  color: #175e54;
  font-size: 11px;
  font-weight: 800;
}

.multi-product-item-title > div {
  min-width: 0;
}

.multi-product-item-title strong {
  display: block;
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.multi-product-item-meta {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.multi-product-item-meta i {
  color: #a3afac;
  font-style: normal;
}

.multi-product-item-status {
  font-weight: 700;
}

.multi-product-item-status.complete {
  color: #176258;
}

.multi-product-item-status.progress {
  color: #8a6500;
}

.multi-product-item-status.empty {
  color: #7b8784;
}

.multi-product-item-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
}

.multi-product-item-actions .ghost-btn {
  min-width: 58px;
  min-height: 32px;
  padding: 6px 10px;
}

.multi-product-item-actions .ghost-btn.danger {
  border-color: #e3c5c5;
  background: #fffafa;
  color: #9b4040;
}

.multi-product-item-actions .ghost-btn.danger:hover:not(:disabled) {
  border-color: #d8aaaa;
  background: #fff3f3;
}

.multi-product-item-actions .ghost-btn:disabled {
  opacity: 0.45;
}

.multi-product-item-fields {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 13px 14px 15px;
  border-top: 1px solid #e4eae8;
  background: #fcfdfd;
}

.multi-product-item-fields[hidden] {
  display: none;
}

.multi-product-item-fields .multi-product-name-field {
  grid-column: span 2;
}

.multi-product-batch-summary {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid #cbded9;
  border-radius: 6px;
  background: #edf6f4;
}

.multi-product-batch-summary span {
  color: var(--muted);
  font-size: 12px;
}

.multi-product-batch-summary strong {
  color: #164f47;
  font-size: 14px;
}

.multi-attachment-list {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 9px 10px;
  border-left: 3px solid #b9cbc7;
  background: #f7faf9;
}

.multi-attachment-list.empty {
  color: var(--muted);
}

.multi-attachment-list > p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.multi-attachment-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.multi-attachment-row > span {
  min-width: 0;
}

.multi-attachment-row strong,
.multi-attachment-row small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.multi-product-compatibility {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin-bottom: 14px;
  border: 1px solid var(--line);
  background: var(--line);
}

.multi-product-compatibility > div {
  min-width: 0;
  padding: 10px 11px;
  background: #ffffff;
}

.multi-product-compatibility strong,
.multi-product-compatibility span {
  display: block;
}

.multi-product-compatibility strong {
  font-size: 12px;
}

.multi-product-compatibility span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.management-metrics-summary {
  display: grid;
  min-width: 0;
  gap: 18px;
  margin-bottom: 14px;
}

.management-metrics-group {
  display: grid;
  min-width: 0;
  gap: 10px;
  padding: 0 0 16px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
}

.management-metrics-group:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.management-metrics-heading {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.management-metrics-heading strong {
  font-size: 14px;
  line-height: 1.35;
}

.management-metrics-heading span {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.management-metrics-grid {
  display: grid;
  min-width: 0;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
}

.rd-sampling-grid {
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.legacy-grid {
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.management-summary-card {
  display: grid;
  min-width: 0;
  min-height: 86px;
  align-content: start;
  gap: 4px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--text);
  text-align: left;
  font: inherit;
}

.management-summary-card span,
.management-summary-card strong,
.management-summary-card small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.management-summary-card span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.management-summary-card strong {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.2;
}

.management-summary-card small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.management-summary-card.is-static {
  cursor: default;
}

.management-summary-card-action {
  cursor: pointer;
}

.management-summary-card-action:hover,
.management-summary-card-action.is-active {
  border-color: var(--primary);
  background: var(--primary-weak);
}

.management-summary-card-action:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.management-metrics-legacy {
  padding: 10px;
  background: #f4f6f7;
}

.management-metrics-legacy .management-summary-card {
  background: #f7f8f9;
  color: #4f5a61;
}

.management-metrics-legacy .management-summary-card-action:hover,
.management-metrics-legacy .management-summary-card-action.is-active {
  background: var(--primary-weak);
}

.task-card-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.compatibility-tag.new-model {
  border-color: #9fc8bd;
  background: #e5f3ef;
  color: #125e55;
}

.compatibility-tag.legacy {
  border-color: #d7c59f;
  background: #f7f0df;
  color: #73551f;
}

.task-batch-line {
  color: #49655e;
  font-size: 11px;
}

.compatibility-detail {
  border-top: 1px solid #98bdb4;
  background: #f7fbfa;
}

.compatibility-detail.legacy {
  border-top-color: #c8ae78;
  background: #fdfaf3;
}

.compatibility-detail > p {
  margin: 0;
  color: var(--muted);
}

.compatibility-tag.demo {
  border-color: #dcc99d;
  background: #fff8e8;
  color: #76551e;
}

.customer-asset-shell {
  min-width: 0;
}

.customer-asset-heading {
  margin-bottom: 10px;
}

.customer-asset-demo {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  border: 1px solid #e4d3aa;
  border-radius: 6px;
  background: #fffaf0;
  padding: 8px 10px;
  color: #6f5b36;
  font-size: 11px;
}

.customer-asset-demo strong {
  color: #76501a;
}

.customer-asset-toolbar {
  display: grid;
  grid-template-columns: auto 150px minmax(260px, 1fr) auto;
  align-items: end;
  gap: 8px;
  border-block: 1px solid var(--line);
  padding: 9px 0;
}

.customer-asset-toolbar label {
  min-width: 0;
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-toolbar select,
.customer-asset-toolbar input,
.customer-asset-toolbar button {
  min-height: 36px;
}

.customer-asset-search span {
  display: block;
}

.customer-asset-summary {
  display: flex;
  min-height: 46px;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
}

.customer-asset-summary strong {
  color: var(--ink);
  font-size: 18px;
}

.customer-asset-list {
  min-width: 0;
  border-bottom: 1px solid var(--line);
}

.customer-asset-row {
  min-width: 0;
  border-top: 1px solid var(--line);
  background: #fff;
}

.customer-asset-row > summary {
  display: grid;
  grid-template-columns: minmax(190px, 1fr) minmax(110px, 0.5fr) minmax(180px, 0.8fr) minmax(180px, 0.85fr) minmax(145px, 0.6fr);
  min-width: 0;
  min-height: 66px;
  align-items: center;
  gap: 12px;
  padding: 10px 8px;
  cursor: pointer;
  list-style: none;
}

.customer-asset-row > summary::-webkit-details-marker {
  display: none;
}

.customer-asset-row > summary:hover {
  background: #f7faf9;
}

.customer-asset-row > summary > span {
  min-width: 0;
}

.customer-asset-row > summary strong,
.customer-asset-row > summary small {
  display: block;
  overflow-wrap: anywhere;
}

.customer-asset-row > summary strong {
  font-size: 12px;
}

.customer-asset-row > summary small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-identity strong {
  color: #174f47;
  font-size: 13px;
}

.customer-asset-latest {
  text-align: right;
}

.customer-asset-readonly {
  border-top: 1px solid #e4ebe9;
  background: #f7faf9;
  padding: 7px 9px;
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-detail {
  border-top: 1px solid var(--line);
  background: #fafcfb;
  padding: 0 10px 12px;
}

.customer-asset-detail-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 4px 8px;
}

.customer-asset-detail-heading strong {
  color: var(--ink);
  font-size: 12px;
}

.customer-asset-detail-heading span {
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-profile {
  padding-bottom: 12px;
}

.customer-asset-profile-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-block: 1px solid #dfe8e5;
  background: #fff;
}

.customer-asset-profile-grid > div {
  min-width: 0;
  padding: 9px 10px;
}

.customer-asset-profile-grid span,
.customer-asset-profile-grid strong {
  display: block;
  overflow-wrap: anywhere;
}

.customer-asset-profile-grid span {
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-profile-grid strong {
  margin-top: 3px;
  color: var(--ink);
  font-size: 11px;
}

.customer-asset-stats,
.customer-asset-history {
  border-top: 1px solid var(--line);
}

.customer-asset-stat-row {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 8px 18px;
  padding: 5px 4px 12px;
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-stat-row strong {
  margin-right: 4px;
  color: #19584f;
  font-size: 13px;
}

.customer-asset-batch + .customer-asset-batch {
  border-top: 1px solid var(--line);
}

.customer-asset-batch-heading {
  display: flex;
  min-height: 46px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 4px;
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-batch-heading strong,
.customer-asset-batch-heading small {
  display: block;
}

.customer-asset-batch-heading strong {
  color: var(--ink);
  font-size: 11px;
}

.customer-asset-items {
  border-top: 1px solid #e4ebe9;
}

.customer-asset-item {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(150px, 0.6fr) minmax(170px, 0.7fr);
  min-width: 0;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #e8eeec;
  padding: 8px 4px;
}

.customer-asset-item:last-child {
  border-bottom: 0;
}

.customer-asset-item strong,
.customer-asset-item small {
  display: block;
  overflow-wrap: anywhere;
}

.customer-asset-item strong {
  font-size: 11px;
}

.customer-asset-item small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.customer-asset-tabs {
  width: fit-content;
  margin-bottom: 8px;
}

.customer-legacy-filters {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 8px;
  border-bottom: 1px solid var(--line);
  padding: 9px 0;
}

.customer-legacy-filters label,
.customer-profile-form-grid label,
.customer-profile-link-form label {
  min-width: 0;
  color: var(--muted);
  font-size: 10px;
}

.customer-legacy-filters input,
.customer-legacy-filters select,
.customer-profile-form-grid input,
.customer-profile-form-grid select,
.customer-profile-form-grid textarea,
.customer-profile-link-form input,
.customer-profile-link-form select {
  width: 100%;
  min-width: 0;
}

.customer-asset-editor {
  border-bottom: 1px solid #cadbd6;
  background: #f7faf9;
  padding: 12px 10px;
}

.customer-asset-editor-heading,
.customer-legacy-decision,
.customer-asset-profile-actions,
.customer-profile-form-actions {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.customer-asset-editor-heading > div,
.customer-asset-editor-heading strong,
.customer-asset-editor-heading span {
  display: block;
  min-width: 0;
}

.customer-asset-editor-heading strong {
  font-size: 13px;
}

.customer-asset-editor-heading span,
.customer-legacy-decision > span,
.customer-asset-profile-actions span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.customer-profile-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
  margin-top: 12px;
}

.customer-profile-form-grid .full {
  grid-column: 1 / -1;
}

.customer-profile-form-actions {
  justify-content: flex-start;
  margin-top: 10px;
}

.customer-profile-form-actions .form-error,
.customer-profile-link-form .form-error {
  color: #a53b32;
  font-size: 11px;
}

.customer-legacy-decision {
  margin-top: 10px;
  border-block: 1px solid #dce7e4;
  padding: 9px 0;
}

.customer-legacy-conflicts,
.customer-legacy-consistency,
.customer-similar-hint {
  margin-top: 9px;
  border: 1px solid #ded7c6;
  border-radius: 6px;
  background: #fffdf8;
  padding: 9px 10px;
  color: #685b3f;
  font-size: 10px;
}

.customer-legacy-conflicts > strong,
.customer-legacy-consistency strong,
.customer-legacy-consistency span,
.customer-similar-hint strong,
.customer-similar-hint span,
.customer-similar-hint small {
  display: block;
}

.customer-legacy-conflicts > div {
  display: grid;
  grid-template-columns: 90px repeat(auto-fit, minmax(150px, 1fr));
  gap: 6px 10px;
  border-top: 1px solid #ebe3d2;
  margin-top: 7px;
  padding-top: 7px;
}

.customer-legacy-conflicts small,
.customer-similar-hint small {
  overflow-wrap: anywhere;
}

.customer-profile-link-form {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(180px, 1fr) auto minmax(160px, 0.7fr);
  align-items: end;
  gap: 9px;
  margin-top: 12px;
}

.customer-legacy-list-heading,
.customer-legacy-row {
  display: grid;
  grid-template-columns: 28px minmax(220px, 1.2fr) minmax(130px, 0.7fr) minmax(150px, 0.75fr) minmax(150px, 0.75fr);
  min-width: 0;
  align-items: center;
  gap: 10px;
}

.customer-legacy-list-heading {
  min-height: 34px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
}

.customer-legacy-row {
  min-height: 58px;
  border-top: 1px solid var(--line);
  padding-block: 8px;
}

.customer-legacy-row.linked {
  background: #fafcfb;
}

.customer-legacy-row > span,
.customer-legacy-row strong,
.customer-legacy-row small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.customer-legacy-row strong {
  font-size: 11px;
}

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

.customer-legacy-select {
  display: grid;
  place-items: center;
}

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

.customer-legacy-link-state strong {
  color: #19584f;
}

.customer-asset-profile-actions {
  justify-content: flex-start;
  border-bottom: 1px solid #dfe8e5;
  background: #fff;
  padding: 9px 10px;
}

.customer-legacy-linked-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(170px, 0.7fr) minmax(300px, auto);
  min-width: 0;
  align-items: center;
  gap: 10px;
  border-top: 1px solid #e4ebe9;
  padding: 8px 4px;
}

.customer-legacy-linked-row strong,
.customer-legacy-linked-row small {
  display: block;
  overflow-wrap: anywhere;
}

.customer-legacy-linked-row small,
.customer-asset-empty-row {
  color: var(--muted);
  font-size: 10px;
}

.customer-legacy-linked-actions {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.customer-legacy-linked-actions select {
  min-width: 130px;
  max-width: 190px;
}

.customer-asset-empty-row {
  border-top: 1px solid #e4ebe9;
  padding: 10px 4px;
}

.request-hub {
  min-width: 0;
}

.request-hub:not(.sales-request-mode) {
  display: grid;
  grid-template-columns: minmax(340px, 0.78fr) minmax(460px, 1.22fr);
  gap: 14px 18px;
}

.request-hub:not(.sales-request-mode) > :not(.request-detail-panel) {
  grid-column: 1;
}

.request-hub:not(.sales-request-mode) .request-detail-panel {
  position: sticky;
  top: 86px;
  grid-column: 2;
  grid-row: 1 / span 5;
  align-self: start;
}

.request-hub:not(.sales-request-mode) .request-filter-panel {
  grid-template-columns: minmax(180px, 1fr) auto auto;
}

.request-hub:not(.sales-request-mode) .request-search {
  grid-column: auto;
}

.request-hub-heading {
  margin-bottom: 10px;
}

.request-personal-todos {
  display: grid;
  grid-template-columns: minmax(170px, 0.75fr) minmax(320px, 1.5fr) auto;
  min-height: 84px;
  align-items: center;
  gap: 18px;
  margin-bottom: 12px;
  border: 1px solid #e3c88d;
  border-radius: 7px;
  background: #fffaf0;
  padding: 13px 15px;
  box-shadow: 0 5px 16px rgba(113, 79, 24, 0.06);
}

.request-todo-lead span,
.request-todo-lead strong,
.request-todo-lead p {
  display: block;
}

.request-todo-lead span {
  color: #76501a;
  font-size: 14px;
  font-weight: 800;
}

.request-todo-lead strong {
  margin-top: 2px;
  color: #945809;
  font-size: 30px;
  line-height: 1;
}

.request-todo-lead p {
  margin: 5px 0 0;
  color: #725f40;
  font-size: 11px;
  font-weight: 700;
}

.request-todo-breakdown {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.request-todo-breakdown button {
  min-width: 0;
  min-height: 48px;
  border: 0;
  border-left: 1px solid #ead9b5;
  border-radius: 0;
  background: transparent;
  color: #59462a;
  padding: 4px 12px;
  text-align: left;
}

.request-todo-breakdown button:hover {
  background: #fff4dd;
}

.request-todo-breakdown span,
.request-todo-breakdown strong {
  display: block;
}

.request-todo-breakdown span {
  color: #786343;
  font-size: 10px;
  white-space: nowrap;
}

.request-todo-breakdown strong {
  margin-top: 2px;
  font-size: 18px;
}

.sales-task-scope-panel {
  margin-bottom: 10px;
}

.request-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 10px;
  border-block: 1px solid var(--line);
}

.request-metrics > div {
  min-width: 0;
  min-height: 56px;
  border-right: 1px solid var(--line);
  padding: 9px 12px;
}

.request-metrics > div:last-child {
  border-right: 0;
}

.request-metrics span,
.request-metrics strong,
.request-metrics small {
  display: block;
}

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

.request-metrics strong {
  margin: 3px 0;
  font-size: 15px;
}

.request-filter-panel {
  display: grid;
  grid-template-columns: 120px 150px 120px minmax(190px, 1fr) auto auto;
  align-items: end;
  gap: 8px;
  margin-bottom: 10px;
  border-block: 1px solid var(--line);
  background: #f8faf9;
  padding: 9px 0;
}

.request-filter-panel label {
  min-width: 0;
}

.request-filter-panel label > span,
.request-filter-panel label:not(.request-search) {
  color: var(--muted);
  font-size: 10px;
}

.request-filter-panel select,
.request-filter-panel input,
.request-filter-panel button {
  min-height: 38px;
}

.request-filter-panel .subtle {
  grid-column: 1 / -1;
}

.request-batch-list {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 8px;
}

.request-batch {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

.request-batch:not([open]) > :not(summary) {
  display: none;
}

.request-batch summary {
  display: grid;
  grid-template-columns: minmax(220px, 1.25fr) minmax(130px, 0.65fr) minmax(190px, 0.9fr) minmax(170px, auto);
  min-width: 0;
  min-height: 66px;
  align-items: center;
  gap: 12px;
  padding: 10px 13px;
  cursor: pointer;
  list-style: none;
}

.request-batch summary::-webkit-details-marker {
  display: none;
}

.request-batch summary:hover {
  background: #f7faf9;
}

.request-batch[open] summary {
  background: #f8fbfa;
}

.request-batch summary > * {
  min-width: 0;
}

.request-batch summary strong,
.request-batch summary small {
  display: block;
  overflow-wrap: anywhere;
}

.request-batch summary small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.request-kind {
  display: inline-flex;
  min-height: 20px;
  align-items: center;
  margin-right: 7px;
  border-radius: 3px;
  padding: 2px 6px;
  font-size: 9px;
  font-weight: 800;
}

.request-kind.quote {
  background: #eaf0f7;
  color: #315e82;
}

.request-kind.sample {
  background: #e7f2ee;
  color: #2f7257;
}

.request-summary-action {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  color: var(--muted);
  font-size: 10px;
}

.request-readonly-strip {
  display: flex;
  gap: 8px;
  border-top: 1px solid #e4ebe9;
  background: #f8f6fb;
  padding: 7px 13px;
  color: var(--muted);
  font-size: 10px;
}

.request-readonly-strip strong {
  color: #6c5185;
}

.request-items {
  border-top: 1px solid var(--line);
  background: #fafcfb;
  padding: 6px 13px 10px;
}

.request-item-row {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(150px, 0.75fr) minmax(170px, 0.8fr) 100px;
  min-width: 0;
  min-height: 50px;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #e4ebe9;
  font-size: 11px;
}

.request-item-row:last-child {
  border-bottom: 0;
}

.request-item-row.selected {
  background: #edf6f3;
}

.request-item-row span,
.request-item-row strong,
.request-item-row small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.request-item-row strong,
.request-item-row small {
  display: block;
}

.request-item-row small {
  margin-top: 2px;
  color: var(--muted);
}

.request-detail-panel {
  min-width: 0;
  margin-top: 14px;
}

.request-detail-panel.sales-detail-drawer {
  position: fixed;
  z-index: 120;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(620px, calc(100vw - 220px));
  margin: 0;
  overflow-y: auto;
  border-left: 1px solid #cbd8d5;
  background: #fff;
  box-shadow: -10px 0 28px rgba(31, 65, 58, 0.14);
}

.request-detail-heading {
  position: sticky;
  z-index: 2;
  top: 0;
  min-height: 58px;
  margin: 0;
  padding: 11px 16px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.request-detail-heading h3 {
  margin: 0;
}

.request-detail-close {
  min-width: 64px;
  white-space: nowrap;
}

.sales-detail-body {
  min-width: 0;
  padding: 0 16px 24px;
}

.sales-detail-primary {
  padding: 17px 0 16px;
}

.sales-detail-title {
  display: flex;
  min-width: 0;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.sales-detail-title > div {
  min-width: 0;
}

.sales-detail-title h3,
.sales-detail-title p {
  overflow-wrap: anywhere;
}

.sales-detail-title h3 {
  margin: 0;
  color: var(--ink);
  font-size: 19px;
}

.sales-detail-title p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.sales-detail-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 14px;
  border-block: 1px solid var(--line);
}

.sales-detail-facts > div {
  min-width: 0;
  padding: 10px 9px;
}

.sales-detail-facts span,
.sales-detail-facts strong,
.sales-detail-requirement span {
  display: block;
}

.sales-detail-facts span,
.sales-detail-requirement span {
  color: var(--muted);
  font-size: 10px;
}

.sales-detail-facts strong {
  margin-top: 3px;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 11px;
}

.sales-detail-facts .sales-detail-bottleneck {
  grid-column: span 3;
  border-top: 1px solid var(--line);
}

.sales-detail-requirement {
  padding: 12px 9px;
  border-bottom: 1px solid var(--line);
}

.sales-detail-requirement p {
  margin: 4px 0 0;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.6;
}

.sales-detail-actions {
  padding-top: 14px;
}

.sales-detail-actions > strong {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
}

.sales-detail-secondary {
  border-top: 1px solid #cfdad7;
}

.sales-detail-secondary > details {
  border-bottom: 1px solid var(--line);
}

.sales-detail-secondary > details > summary {
  padding: 13px 2px;
  cursor: pointer;
  color: #20574f;
  font-size: 12px;
  font-weight: 700;
}

.sales-detail-secondary > details > .detail-grid,
.sales-detail-secondary > details > .attachment-list,
.sales-detail-secondary > details > .round-list,
.sales-detail-secondary > details > .log-panel,
.sales-detail-secondary > details > h4 {
  margin-inline: 2px;
}

.sales-detail-secondary > details > :last-child {
  margin-bottom: 14px;
}

@media (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 210px minmax(0, 1fr);
  }

  .sidebar {
    padding-inline: 13px;
  }

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

  .task-layout {
    grid-template-columns: minmax(330px, 0.8fr) minmax(440px, 1.2fr);
  }

  .multi-product-compatibility {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .management-metrics-grid,
  .rd-sampling-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .multi-product-item-fields {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .multi-product-item-fields .multi-product-name-field {
    grid-column: span 2;
  }

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

  .customer-asset-row > summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .customer-asset-latest {
    text-align: left;
  }

  .request-search {
    grid-column: 1 / -1;
  }
}

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

  .sidebar {
    position: static;
    width: 100%;
    height: auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: visible;
  }

  .content {
    padding: 16px;
  }

  .filters {
    position: static;
  }

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

  .task-layout > div:last-child {
    position: static;
  }

  .request-hub:not(.sales-request-mode) {
    display: block;
  }

  .request-hub:not(.sales-request-mode) .request-detail-panel {
    position: static;
  }

  .request-personal-todos {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .customer-asset-toolbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-asset-search {
    grid-column: 1 / -1;
  }

  .customer-asset-row > summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-asset-profile-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-legacy-filters,
  .customer-profile-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-profile-link-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-profile-link-form .form-error {
    grid-column: 1 / -1;
  }

  .customer-legacy-list-heading,
  .customer-legacy-row {
    grid-template-columns: 28px minmax(180px, 1fr) minmax(120px, 0.65fr) minmax(140px, 0.7fr) minmax(130px, 0.65fr);
  }

  .customer-asset-list:has(.customer-legacy-row) {
    overflow-x: auto;
  }

  .customer-legacy-list-heading,
  .customer-legacy-row {
    min-width: 730px;
  }

  .customer-legacy-linked-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-legacy-linked-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .request-detail-panel.sales-detail-drawer {
    width: min(620px, 100vw);
  }

  .request-batch summary {
    grid-template-columns: minmax(0, 1fr) minmax(130px, 0.45fr);
  }

  .request-batch summary > :nth-child(3) {
    grid-column: 1;
  }

  .request-summary-action {
    grid-column: 2;
    grid-row: 1 / span 2;
  }

  #taskDetail,
  .account-table {
    max-height: none;
  }

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

  .account-table .table-row .table-cell:last-child {
    position: static;
    box-shadow: none;
  }

  .multi-product-item-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .sidebar {
    grid-template-columns: 1fr 1fr;
    padding: 14px;
  }

  .sidebar > div:first-child,
  .sidebar > .role-card,
  .sidebar > .nav {
    grid-column: 1 / -1;
  }

  .content {
    padding: 14px 12px 24px;
  }

  .topbar {
    align-items: flex-start;
  }

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

  .filters,
  .analysis-kpi-grid,
  .account-form {
    grid-template-columns: 1fr;
  }

  .management-analysis-tabs,
  .overview-mode,
  .management-analysis-view,
  .analysis-kpi-grid {
    width: 100%;
    min-width: 0;
  }

  .management-analysis-tabs.admin-customer-tabs {
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .management-analysis-tabs.admin-customer-tabs button {
    min-width: 0;
    overflow-wrap: anywhere;
    white-space: normal;
  }

  .admin-customer-filter-heading,
  .admin-customer-detail-heading {
    align-items: flex-start;
  }

  .admin-customer-filters,
  .admin-customer-distributions,
  .admin-customer-profile-grid {
    grid-template-columns: 1fr;
  }

  .admin-customer-keyword {
    grid-column: auto;
  }

  .admin-customer-kpi-strip,
  .admin-customer-secondary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-customer-kpi {
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
  }

  .admin-customer-kpi:nth-child(2n) {
    border-right: 0;
  }

  .admin-customer-auxiliary,
  .admin-customer-pagination {
    justify-content: flex-start;
  }

  .admin-customer-table {
    min-width: 1040px;
  }

  .admin-customer-batch-detail summary,
  .admin-customer-item-list > div,
  .admin-customer-history-list > div {
    grid-template-columns: 1fr;
  }

  .task-id-filter {
    grid-column: auto;
  }

  .people-performance-row {
    grid-template-columns: minmax(72px, 96px) minmax(0, 1fr) 54px;
    gap: 8px;
    padding-inline: 4px;
  }

  .management-panel-heading {
    align-items: flex-start;
  }

  .multi-product-mode-panel,
  .multi-product-heading,
  .multi-product-item-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .multi-product-mode-panel .segmented-control,
  .multi-product-heading button,
  .multi-product-item-heading button {
    width: 100%;
  }

  .multi-product-section-heading {
    align-items: flex-start;
  }

  .multi-product-section-title {
    align-items: flex-start;
  }

  .multi-product-item-heading {
    padding: 11px;
  }

  .multi-product-item-title {
    width: 100%;
  }

  .multi-product-item-actions {
    width: 100%;
  }

  .multi-product-item-actions .ghost-btn {
    width: auto;
    flex: 1;
  }

  .multi-product-item-fields {
    grid-template-columns: minmax(0, 1fr);
    padding: 12px 11px 13px;
  }

  .multi-product-item-fields .multi-product-name-field {
    grid-column: auto;
  }

  .multi-product-batch-summary {
    align-items: flex-start;
    flex-direction: column;
  }

  .multi-product-compatibility {
    grid-template-columns: 1fr;
  }

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

  .management-metrics-grid,
  .rd-sampling-grid,
  .legacy-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .management-summary-card {
    min-height: 76px;
  }

  .multi-attachment-row {
    grid-template-columns: minmax(0, 1fr) 58px;
  }

  .request-personal-todos,
  .request-filter-panel,
  .request-metrics {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-asset-demo,
  .customer-asset-summary,
  .customer-asset-batch-heading {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .customer-asset-toolbar,
  .customer-asset-row > summary,
  .customer-asset-item,
  .customer-asset-profile-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-legacy-filters,
  .customer-profile-form-grid,
  .customer-profile-link-form,
  .customer-legacy-linked-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-profile-form-grid .full,
  .customer-profile-link-form .form-error,
  .customer-legacy-linked-actions {
    grid-column: auto;
  }

  .customer-asset-tabs,
  .customer-asset-tabs button,
  .customer-profile-link-form button {
    width: 100%;
  }

  .customer-asset-editor-heading,
  .customer-legacy-decision,
  .customer-asset-profile-actions,
  .customer-profile-form-actions,
  .customer-legacy-linked-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .customer-legacy-conflicts > div {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-legacy-linked-actions select {
    width: 100%;
    max-width: none;
  }

  .customer-legacy-list-heading {
    display: none;
  }

  .customer-legacy-row {
    grid-template-columns: 28px minmax(0, 1fr);
    min-width: 0;
    align-items: start;
  }

  .customer-legacy-row > span {
    grid-column: 2;
  }

  .customer-asset-detail-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .customer-asset-toolbar > *,
  .customer-asset-search {
    grid-column: auto;
    width: 100%;
  }

  .customer-asset-latest {
    text-align: left;
  }

  .request-todo-breakdown {
    grid-template-columns: minmax(0, 1fr);
  }

  .request-todo-breakdown button {
    border-top: 1px solid #ead9b5;
    border-left: 0;
  }

  .request-filter-panel > *,
  .request-search {
    grid-column: auto;
    width: 100%;
  }

  .request-metrics > div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .request-batch summary {
    grid-template-columns: minmax(0, 1fr);
  }

  .request-batch summary > :nth-child(3),
  .request-summary-action {
    grid-column: auto;
    grid-row: auto;
  }

  .request-summary-action {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .request-readonly-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .request-item-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
    padding: 10px 0;
  }

  .request-item-row .ghost-btn {
    width: 100%;
  }

  .request-detail-panel.sales-detail-drawer {
    inset: 0;
    width: 100vw;
    max-width: 100vw;
    border-left: 0;
    box-shadow: none;
  }

  .request-detail-heading,
  .sales-detail-body {
    padding-inline: 12px;
  }

  .sales-detail-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .sales-detail-facts {
    grid-template-columns: minmax(0, 1fr);
  }

  .sales-detail-facts .sales-detail-bottleneck {
    grid-column: auto;
  }
}

.management-dashboard-summary {
  display: grid;
  min-width: 0;
}

.management-dashboard-section {
  display: grid;
  gap: 14px;
  padding: 20px 0 22px;
  border-bottom: 1px solid var(--line);
}

.management-dashboard-section:first-child {
  padding-top: 4px;
}

.management-dashboard-section:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.management-dashboard-section .management-metrics-heading {
  display: grid;
  grid-template-columns: minmax(72px, auto) minmax(0, 1fr);
  align-items: baseline;
  gap: 14px;
}

.management-dashboard-section .management-metrics-heading strong {
  font-size: 17px;
  font-weight: 700;
}

.quote-dashboard-section .management-metrics-heading strong {
  color: #176d63;
}

.sample-dashboard-section .management-metrics-heading strong {
  color: #2b6387;
}

.anomaly-dashboard-section .management-metrics-heading strong {
  color: #9a3d36;
}

.management-metrics-subheading {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 10px;
  padding-top: 2px;
}

.management-metrics-subheading strong {
  flex: 0 0 auto;
  font-size: 13px;
}

.management-metrics-subheading span {
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

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

.sample-dashboard-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

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

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

.management-anomaly-list {
  display: grid;
  min-width: 0;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.management-dashboard-section .management-summary-card {
  min-height: 98px;
  gap: 7px;
  padding: 14px 15px;
  border-color: #dbe3e7;
  border-radius: 6px;
  box-shadow: 0 3px 12px rgb(25 45 54 / 5%);
}

.management-dashboard-section .management-summary-card strong {
  font-size: 26px;
  font-weight: 700;
}

.management-dashboard-section .management-summary-card small {
  min-height: 15px;
}

.quote-dashboard-section .management-summary-card.is-priority {
  border-color: #a9cec8;
  background: #f1f8f6;
}

.sample-dashboard-section .management-summary-card.is-priority {
  border-color: #aec7d7;
  background: #f2f7fa;
}

.management-dashboard-section .management-summary-card-action:hover,
.management-dashboard-section .management-summary-card-action.is-active {
  border-color: #16786f;
  background: #eef7f5;
  box-shadow: 0 5px 16px rgb(23 76 70 / 10%);
}

.anomaly-dashboard-section .management-summary-card.is-alert {
  border-color: #d7aaa5;
  background: #fff7f5;
}

.anomaly-dashboard-section .management-summary-card.is-alert strong {
  color: #a33f36;
}

@media (max-width: 760px) {
  .quote-dashboard-grid,
  .sample-dashboard-grid,
  .quote-timing-grid,
  .management-anomaly-summary,
  .management-anomaly-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .management-dashboard-section .management-metrics-heading {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .management-metrics-subheading {
    display: grid;
    gap: 3px;
  }
}

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