/* === Design System — Cool Indigo + Clean Grays === */
:root {
  --primary: #4C53F5;
  --primary-pressed: #3b42d8;
  --primary-soft: rgba(76, 83, 245, 0.08);
  --on-primary: #ffffff;
  --brand-navy: #0a1530;
  --link-blue: #4C53F5;
  --brand-orange: #dd5b00;
  --brand-green: #1aae39;
  --brand-purple-800: #391c57;
  --brand-orange-deep: #793400;
  /* Card tints — cooler, muted */
  --tint-blue: #eef0fd;
  --tint-green: #e6f7ee;
  --tint-purple: #f0edfa;
  --tint-amber: #fef7ed;
  --tint-gray: #f3f4f6;
  /* Surface — clean cool grays */
  --canvas: #ffffff;
  --surface: #f3f4f6;
  --surface-soft: #f9fafb;
  --hairline: #e5e7eb;
  --hairline-strong: #d1d5db;
  /* Text — cool charcoal */
  --ink: #111827;
  --charcoal: #374151;
  --slate: #6b7280;
  --steel: #9ca3af;
  --muted: #d1d5db;
  --on-dark: #ffffff;
  --on-dark-muted: #9ca3af;
  /* Semantic */
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --motion-fast: 120ms;
  --motion-base: 200ms;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);
  /* Layout */
  --font-sans: 'Inter', 'PingFang SC', -apple-system, system-ui, sans-serif;
  --sidebar-width: 240px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font-sans);
  font-size: 14px; font-weight: 400; line-height: 1.5;
  color: var(--charcoal); background: #f9fafb;
  -webkit-font-smoothing: antialiased;
  display: flex; min-height: 100vh;
}

/* ===== Sidebar — Slightly darker than main ===== */
.sidebar {
  width: var(--sidebar-width); min-width: var(--sidebar-width);
  background: #f3f4f6; color: var(--charcoal);
  display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; bottom: 0; z-index: 100;
  padding: 16px 10px;
  border-right: 1px solid var(--hairline);
}
.sidebar-logo {
  font-size: 15px; font-weight: 600; color: var(--ink);
  padding: 8px 10px; margin-bottom: 20px;
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; border-radius: 6px;
}
.sidebar-logo:hover { background: rgba(0,0,0,0.04); }
.brand-mark { display: block; flex: 0 0 auto; object-fit: contain; }
.brand-wordmark { display: inline-flex; align-items: baseline; gap: 8px; font-weight: 700; line-height: 1.25; letter-spacing: 0; white-space: nowrap; }
.brand-name-cn { font-family: "PingFang SC", "Microsoft YaHei", sans-serif; font-size: .86em; font-weight: 600; }
.brand-lockup { display: inline-grid; gap: 1px; min-width: 0; line-height: 1.1; }
.brand-lockup small { color: #7f8995; font-size: 10px; font-weight: 500; line-height: 1.2; white-space: nowrap; }
.brand-mark-sidebar { width: 26px; height: 26px; }
.sidebar-logo .logo-icon {
  width: 26px; height: 26px; background: var(--primary);
  border-radius: 6px; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 13px; font-weight: 700;
}
.sidebar-section-label {
  font-size: 11px; font-weight: 600; color: var(--steel);
  text-transform: uppercase; letter-spacing: 0.5px;
  padding: 12px 10px 4px;
}
.sidebar-nav { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.sidebar-link {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 10px; border-radius: 6px;
  font-size: 14px; font-weight: 400; color: var(--slate);
  text-decoration: none; transition: background 0.15s;
}
.sidebar-link:hover { background: rgba(0,0,0,0.04); color: var(--charcoal); }
.sidebar-link.active { background: rgba(0,0,0,0.06); color: var(--ink); font-weight: 500; }
.sidebar-link .nav-icon { width: 20px; text-align: center; font-size: 14px; opacity: 0.7; }
.sidebar-link.active .nav-icon { opacity: 1; }
.nav-icon-svg { opacity: 0.55; flex-shrink: 0; }
.sidebar-link:hover .nav-icon-svg { opacity: 0.75; }
.sidebar-link.active .nav-icon-svg { opacity: 1; color: var(--ink); }
.sidebar-footer { margin-top: auto; padding-top: 10px; border-top: 1px solid var(--hairline); }

/* ===== Main ===== */
.main-wrapper { margin-left: var(--sidebar-width); flex: 1; min-width: 0; min-height: 100vh; }
.site-filing-footer { padding: 16px 24px 24px; text-align: center; color: var(--text-muted, #6b7280); font-size: 12px; }
.site-filing-footer a { color: inherit; text-decoration: none; }
.site-filing-footer a:hover { text-decoration: underline; }
.main-content { width: 100%; min-width: 0; max-width: 1160px; margin: 0 auto; padding: 32px 40px; }
body:not(.auth-page) .main-content { animation: workspace-content-enter 360ms var(--ease-out) both; }
@keyframes workspace-content-enter { from { opacity: 0; transform: translateY(7px); } to { opacity: 1; transform: translateY(0); } }
.mobile-header,
.mobile-nav-dialog { display: none; }
.pricing-page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.pricing-page-head .btn { flex: 0 0 auto; }

/* ===== Typography ===== */
.page-title { font-size: 28px; font-weight: 600; letter-spacing: -0.5px; color: var(--ink); margin-bottom: 6px; }
.page-subtitle { font-size: 15px; color: var(--slate); margin-bottom: 28px; }
.section-title { font-size: 16px; font-weight: 600; color: var(--ink); margin-bottom: 14px; }

/* ===== Cards ===== */
.card {
  background: var(--canvas); border-radius: 12px;
  border: 1px solid var(--hairline);
  padding: 24px; margin-bottom: 16px;
}
.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.card-grid { display: grid; gap: 16px; }
.card-grid-4 { grid-template-columns: repeat(4, 1fr); }
.card-grid-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid-2 { grid-template-columns: repeat(2, 1fr); }

/* Tinted feature cards — cool palette */
.card-tint-blue { background: var(--tint-blue); border-color: transparent; }
.card-tint-green { background: var(--tint-green); border-color: transparent; }
.card-tint-purple { background: var(--tint-purple); border-color: transparent; }
.card-tint-amber { background: var(--tint-amber); border-color: transparent; }
.card-tint-gray { background: var(--tint-gray); border-color: transparent; }
/* Keep old class names for backward compat */
.card-tint-peach { background: var(--tint-amber); }
.card-tint-rose { background: #fce4ec; }
.card-tint-mint { background: var(--tint-green); }
.card-tint-lavender { background: var(--tint-purple); }
.card-tint-sky { background: var(--tint-blue); }
.card-tint-yellow { background: #fefce8; }
.card-tint-cream { background: #f9fafb; }

/* ===== Stat Cards ===== */
.stat-card { padding: 20px 24px; }
.stat-label { font-size: 12px; color: var(--slate); margin-bottom: 6px; font-weight: 500; }
.stat-number { font-size: 30px; font-weight: 600; color: var(--ink); letter-spacing: -0.5px; }

/* ===== Buttons — 8px RECTANGLES (Notion style) ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 16px; border-radius: 8px;
  font-family: var(--font-sans); font-size: 14px; font-weight: 500;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: all 0.15s; white-space: nowrap; line-height: 1.3;
}
.btn-primary { background: var(--primary); color: var(--on-primary); }
.btn-primary:hover { background: var(--primary-pressed); }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--hairline-strong); }
.btn-secondary:hover { background: #f7f6f3; }
.btn-danger { background: var(--error); color: #fff; }
.btn-danger:hover { opacity: 0.9; }
.btn-ghost { background: transparent; color: var(--charcoal); }
.btn-ghost:hover { background: #f7f6f3; }
.btn-sm { font-size: 13px; padding: 5px 12px; }
.btn-xs { font-size: 12px; padding: 3px 10px; border-radius: 6px; }

/* ===== Forms ===== */
.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 13px; font-weight: 500; color: var(--charcoal); margin-bottom: 6px; }
.form-input, .form-select {
  width: 100%; height: 44px; padding: 0 14px;
  border: 1px solid var(--hairline-strong); border-radius: 8px;
  font-family: var(--font-sans); font-size: 14px; color: var(--ink);
  background: var(--canvas); transition: border-color 0.15s;
}
.form-input:focus, .form-select:focus {
  outline: none; border-color: var(--primary); border-width: 2px;
}
.form-input::placeholder { color: var(--muted); }
.form-select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L5 5L9 1' stroke='%23787671' stroke-width='1.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-hint { font-size: 12px; color: var(--steel); margin-top: 4px; }

/* ===== Tables ===== */
.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
  text-align: left; padding: 10px 16px;
  font-size: 12px; font-weight: 500; color: var(--slate);
  border-bottom: 1px solid var(--hairline);
}
.data-table td { padding: 14px 16px; font-size: 14px; color: var(--charcoal); border-bottom: 1px solid var(--hairline); }
.data-table tr:hover td { background: var(--surface-soft); }

/* ===== Badges — Notion style ===== */
.tag {
  display: inline-flex; align-items: center; padding: 2px 8px;
  border-radius: 6px; font-size: 12px; font-weight: 600;
  line-height: 20px;
}
.tag-new { background: var(--hairline); color: var(--slate); }
.tag-matched { background: var(--tint-mint); color: var(--brand-green); }
.tag-imported { background: var(--tint-blue); color: #3730a3; }
.tag-skipped { background: var(--tint-peach); color: var(--brand-orange-deep); }
.tag-running { background: var(--tint-sky); color: #1a56db; }
.tag-success { background: var(--tint-mint); color: var(--brand-green); }
.tag-failed { background: var(--tint-rose); color: var(--error); }
.status-reason {
  max-width: 220px;
  margin-top: 5px;
  color: var(--steel);
  font-size: 12px;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ===== Tabs ===== */
.tabs { display: flex; gap: 4px; margin-bottom: 24px; background: var(--hairline); padding: 4px; border-radius: 10px; width: fit-content; }
.tab {
  padding: 6px 16px; border-radius: 8px; font-size: 14px; font-weight: 500;
  color: var(--steel); text-decoration: none; transition: all 0.1s;
}
.tab:hover { color: var(--charcoal); }
.tab.active { background: var(--canvas); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,0.06); }

/* ===== Supplier Cards ===== */
.supplier-card {
  display: flex; align-items: flex-start; gap: 16px;
  padding: 20px; border-radius: 12px; border: 1px solid var(--hairline);
  background: var(--canvas); margin-bottom: 12px;
}
.supplier-card.best { border-color: var(--primary); background: var(--tint-blue); }
.supplier-rank { width: 32px; height: 32px; border-radius: 8px; background: var(--surface); display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; color: var(--slate); flex-shrink: 0; }
.supplier-card.best .supplier-rank { background: var(--primary); color: var(--on-primary); }
.supplier-info { flex: 1; }
.supplier-info h4 { font-size: 15px; font-weight: 600; color: var(--ink); margin-bottom: 4px; }
.supplier-info .meta { font-size: 13px; color: var(--slate); }
.supplier-price { text-align: right; min-width: 100px; }
.supplier-price .price { font-size: 22px; font-weight: 600; color: var(--ink); }
.supplier-price .moq { font-size: 12px; color: var(--steel); }

/* ===== Comparison Matching ===== */
.comparison-table { min-width: 980px; }
.comparison-product-cell { display: flex; align-items: center; gap: 12px; }
.comparison-product-cell img {
  width: 44px; height: 44px; border-radius: 6px; object-fit: cover; flex-shrink: 0;
}
.comparison-title {
  max-width: 360px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--ink); font-weight: 600;
}
.comparison-detail-grid {
  display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 18px; align-items: start;
}
.source-panel { position: sticky; top: 24px; }
.source-product-image {
  width: 100%; aspect-ratio: 1 / 1; border-radius: 8px; object-fit: cover;
  border: 1px solid var(--hairline); margin-bottom: 16px; background: var(--surface);
}
.source-product-title { font-size: 16px; font-weight: 600; color: var(--ink); line-height: 1.4; margin-bottom: 16px; }
.source-metrics { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.metric-value { font-size: 18px; font-weight: 700; color: var(--ink); }
.supplier-match-card {
  display: grid; grid-template-columns: 32px 72px minmax(0, 1fr); gap: 14px;
  padding: 16px; border: 1px solid var(--hairline); border-radius: 8px;
  background: var(--canvas); margin-bottom: 12px; align-items: start;
}

/* Sourcing is a factual result row; availability differences should not look like alerts. */
.sourcing-status { min-width: 0; padding: 4px 0; border-left: 0; background: transparent; }
.sourcing-status-head { display: flex; align-items: center; min-width: 0; }
.sourcing-status-copy { min-width: 0; }
.sourcing-status-eyebrow { display: block; color: var(--slate); font-size: 9px; line-height: 1.2; }
.sourcing-status-copy strong { display: block; margin-top: 2px; color: var(--ink); font-size: 11px; line-height: 1.3; font-weight: 650; }
.sourcing-status-count { margin-left: auto; color: var(--slate); font-size: 10px; font-weight: 800; white-space: nowrap; }
.sourcing-status-detail, .sourcing-status-reason { margin: 5px 0 0; color: var(--slate); font-size: 10px; line-height: 1.35; }
.sourcing-status-reason { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sourcing-status-complete, .sourcing-status-result, .sourcing-status-empty, .sourcing-status-pending { border-left-color: transparent; }
.sourcing-status-compact { min-width: 0; padding: 4px 0; }
.comparison-row-action .sourcing-status { width: 100%; }
.comparison-row-action .comparison-row-action-button { width: 100%; margin-top: 8px; }
.supplier-match-card.no-image { grid-template-columns: 32px minmax(0, 1fr); }
.supplier-match-card.best { border-color: var(--primary); background: var(--primary-soft); }
.supplier-match-image {
  width: 72px; height: 72px; border-radius: 6px; object-fit: cover; border: 1px solid var(--hairline);
  background: var(--surface); flex-shrink: 0;
}
.supplier-match-main { min-width: 0; }
.supplier-match-title {
  font-size: 15px; font-weight: 600; color: var(--ink); line-height: 1.4; margin-bottom: 5px;
}
.supplier-match-meta { font-size: 13px; color: var(--slate); margin-bottom: 8px; }
.supplier-match-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.comparison-actions {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}

/* ===== Empty State ===== */
.empty-state { text-align: center; padding: 56px 24px; }
.empty-state .empty-icon { font-size: 36px; margin-bottom: 16px; }
.empty-state h3 { font-size: 18px; font-weight: 600; color: var(--ink); margin-bottom: 8px; }
.empty-state p { font-size: 14px; color: var(--steel); max-width: 420px; margin: 0 auto 20px; line-height: 1.5; }

/* ===== Custom Scroll Dropdown ===== */
.custom-select { position: relative; }
.custom-select-trigger { cursor: pointer; user-select: none; }
.custom-select-trigger::after { content: ' ▾'; float: right; color: var(--steel); }
.custom-select-dropdown {
  display: none; position: absolute; top: 100%; left: 0; right: 0; z-index: 50;
  background: var(--canvas); border: 1px solid var(--hairline-strong); border-radius: 8px;
  max-height: 240px; overflow-y: auto; box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.custom-select-dropdown.open { display: block; }
.custom-select-option {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 14px; font-size: 14px; color: var(--charcoal); cursor: pointer;
  transition: background 0.1s;
}
.custom-select-option:hover { background: var(--surface); }
.custom-select-option input[type="radio"] { accent-color: var(--primary); }
.custom-select-option:has(input:checked) { background: var(--primary-soft); font-weight: 500; }

/* Utility */
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.flex-center { display: flex; align-items: center; gap: 8px; }
.gap-sm { gap: 8px; }
.gap-md { gap: 16px; }
.mt-sm { margin-top: 8px; }
.mt-md { margin-top: 16px; }
.mt-lg { margin-top: 24px; }
.mb-md { margin-bottom: 16px; }
.mb-lg { margin-bottom: 24px; }
.text-muted { color: var(--steel); font-size: 13px; }
.text-success { color: var(--success); font-weight: 600; }
.text-error { color: var(--error); }
.text-link { color: var(--link-blue); font-weight: 500; }
.pricing-control-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(110px, 1fr));
  gap: 12px;
  align-items: end;
}
.product-command-row {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.product-command-filters {
  display: grid;
  grid-template-columns: minmax(120px, 0.8fr) minmax(180px, 1.15fr) minmax(160px, 0.95fr) 112px 112px;
  gap: 12px;
  align-items: end;
}
.product-command-filters .form-group {
  margin: 0;
  min-width: 0 !important;
  width: auto !important;
}
.product-command-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
}
.product-command-actions .btn {
  height: 40px;
}
.sync-ranking-btn {
  min-width: 158px;
}
.ranking-position-column {
  width: 148px;
  text-align: center;
}
.ranking-position-cell {
  width: 148px;
  min-width: 148px;
  padding-right: 10px !important;
  padding-left: 10px !important;
  text-align: center;
}
.compliant-rank {
  color: var(--ink);
  font-size: 16px;
  font-weight: 750;
  line-height: 1.2;
}
.source-rank {
  margin-top: 5px;
  color: var(--steel);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.3;
  white-space: nowrap;
}
.brand-risk-source-rank {
  margin-top: 0;
  font-size: 12px;
  font-weight: 600;
}
.operation-in-progress {
  overflow: hidden;
}
.operation-progress-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 88px 32px 20px;
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  pointer-events: none;
}
.operation-progress-overlay[hidden] {
  display: none;
}
.operation-progress-dialog {
  position: relative;
  width: min(440px, 100%);
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(21, 24, 35, 0.2);
  pointer-events: auto;
}
@media (max-width: 700px) {
  .operation-progress-overlay { padding: 72px 16px 16px; }
  .operation-progress-dialog { width: min(440px, 100%); }
}
.operation-progress-dismiss {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--steel);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}
.operation-progress-dismiss:hover {
  background: #f1f2f6;
  color: var(--ink);
}
.operation-progress-heading {
  display: flex;
  align-items: center;
  gap: 14px;
}
.operation-progress-heading strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.4;
}
.operation-progress-heading p {
  margin: 3px 0 0;
  color: var(--steel);
  font-size: 13px;
  line-height: 1.45;
}
.operation-progress-spinner {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border: 3px solid #e3e5ff;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: operation-spinner 0.85s linear infinite;
}
.operation-progress-track {
  height: 7px;
  margin-top: 20px;
  overflow: hidden;
  border-radius: 4px;
  background: #eceef3;
}
.operation-progress-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: 4px;
  background: var(--primary);
  transition: width 0.35s ease;
}
.operation-progress-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 10px;
  color: var(--slate);
  font-size: 12px;
}
.operation-progress-meta > span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.operation-progress-dialog.is-failed .operation-progress-meta {
  align-items: flex-start;
}
.operation-progress-dialog.is-failed .operation-progress-meta > span:first-child {
  overflow: visible;
  overflow-wrap: anywhere;
  text-overflow: clip;
  white-space: normal;
}
.operation-progress-status {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.operation-progress-status strong {
  min-width: 34px;
  color: var(--primary);
  font-size: 12px;
  text-align: right;
}
.operation-progress-status span {
  min-width: 38px;
  color: var(--ink);
  text-align: right;
}
.operation-progress-note {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--hairline);
  color: var(--steel);
  font-size: 12px;
  line-height: 1.5;
  min-height: 32px;
  overflow-wrap: anywhere;
}
.operation-progress-dialog.is-finished .operation-progress-spinner {
  visibility: hidden;
  animation: none;
}
.operation-progress-dialog.is-failed .operation-progress-status strong {
  color: var(--danger);
}
@keyframes operation-spinner {
  to { transform: rotate(360deg); }
}
@keyframes operation-progress-slide {
  from { transform: translateX(-115%); }
  to { transform: translateX(275%); }
}
@media (prefers-reduced-motion: reduce) {
  .operation-progress-spinner,
  .operation-progress-track span {
    animation-duration: 2.4s;
  }
}
.ranking-action-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
}
.ranking-match-form {
  flex: 0 0 auto;
}
.auto-sourcing-form {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--hairline);
}
.auto-sourcing-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}
.auto-sourcing-toggle input {
  accent-color: var(--primary);
}
.auto-sourcing-time {
  width: 120px;
  height: 34px;
  padding: 0 10px;
}
.task-page-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 24px;
}
.task-schedule-box {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px;
  margin-bottom: 16px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: var(--surface-soft);
}
.task-rule-card {
  padding: 20px;
}
.task-rule-meta {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: var(--hairline);
}
.task-rule-meta div {
  min-width: 0;
  padding: 12px;
  background: #fff;
}
.task-rule-meta span {
  display: block;
  color: var(--steel);
  font-size: 12px;
  font-weight: 650;
  margin-bottom: 5px;
}
.task-rule-meta strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
  font-weight: 720;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.task-rule-keywords {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--slate);
  font-size: 13px;
}

/* ===== Executive Dashboard ===== */
.dashboard-shell { display: flex; flex-direction: column; gap: 16px; }
.dashboard-head {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 20px;
}
.dashboard-kicker {
  font-size: 12px; font-weight: 700; color: var(--primary); text-transform: uppercase;
  letter-spacing: 0.08em; margin-bottom: 4px;
}
.dashboard-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.dashboard-status-panel {
  display: flex; justify-content: space-between; align-items: center; gap: 18px;
  padding: 22px 24px; border-radius: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f7f8ff 100%);
  color: var(--charcoal);
  border: 1px solid rgba(76,83,245,0.16);
  border-left: 4px solid var(--primary);
  box-shadow: 0 10px 28px rgba(17,24,39,0.05);
}
.status-label { font-size: 12px; color: var(--slate); margin-bottom: 6px; font-weight: 600; }
.status-title { font-size: 24px; font-weight: 700; letter-spacing: 0; }
.status-subtitle { font-size: 13px; color: var(--slate); margin-top: 4px; }
.status-pill-group { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.status-pill {
  display: inline-flex; align-items: center; height: 28px; padding: 0 10px; border-radius: 999px;
  font-size: 12px; font-weight: 700; background: var(--surface); color: var(--charcoal);
}
.status-pill.healthy { background: var(--tint-green); color: var(--brand-green); }
.status-pill.warning { background: var(--tint-amber); color: var(--brand-orange-deep); }
.status-pill.running { background: var(--tint-blue); color: var(--primary); }
.status-pill.neutral { background: var(--surface); color: var(--slate); }
.metric-grid {
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px;
}
.metric-card {
  background: var(--canvas); border: 1px solid var(--hairline); border-radius: 10px;
  padding: 18px 18px 16px; min-height: 126px;
}
.metric-card.primary { border-color: rgba(76,83,245,0.22); background: #ffffff; box-shadow: inset 0 3px 0 var(--primary); }
.metric-label { font-size: 12px; font-weight: 700; color: var(--slate); margin-bottom: 10px; }
.metric-number { font-size: 34px; line-height: 1; font-weight: 750; color: var(--ink); letter-spacing: 0; }
.metric-note { margin-top: 10px; font-size: 12px; color: var(--steel); }
.dashboard-main-grid {
  display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(320px, 0.8fr); gap: 16px;
}
.dashboard-main-column, .dashboard-side-column { display: flex; flex-direction: column; gap: 16px; }
.panel-card {
  background: var(--canvas); border: 1px solid var(--hairline); border-radius: 12px;
  padding: 20px; overflow: hidden;
}
.panel-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.panel-subtitle { font-size: 12px; color: var(--steel); margin-top: -8px; }
.opportunity-list { display: flex; flex-direction: column; gap: 8px; }
.opportunity-row {
  display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 12px; align-items: center;
  padding: 10px; border-radius: 8px; text-decoration: none; color: inherit; border: 1px solid transparent;
}
.opportunity-row:hover { background: var(--surface-soft); border-color: var(--hairline); }
.opportunity-row img { width: 48px; height: 48px; border-radius: 6px; object-fit: cover; background: var(--surface); }
.opportunity-main { min-width: 0; }
.opportunity-title { font-weight: 650; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.opportunity-meta { font-size: 12px; color: var(--steel); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.opportunity-score {
  min-width: 72px; text-align: right; font-size: 18px; font-weight: 750; color: var(--charcoal);
}
.opportunity-score.good { color: var(--success); }
.opportunity-score.bad { color: var(--error); }
.dashboard-table th, .dashboard-table td { padding-left: 0; padding-right: 12px; }
.pipeline-list { display: flex; flex-direction: column; gap: 14px; }
.pipeline-step { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 10px; align-items: start; }
.pipeline-step > span {
  width: 10px; height: 10px; border-radius: 50%; margin-top: 5px; background: var(--muted);
  box-shadow: 0 0 0 4px var(--surface);
}
.pipeline-step.done > span { background: var(--success); box-shadow: 0 0 0 4px var(--tint-green); }
.pipeline-step strong { display: block; color: var(--ink); font-size: 14px; }
.pipeline-step small { display: block; color: var(--steel); margin-top: 2px; }
.inventory-stack { display: grid; gap: 8px; }
.inventory-stack div {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 0; border-bottom: 1px solid var(--hairline);
}
.inventory-stack div:last-child { border-bottom: 0; }
.inventory-stack span { color: var(--slate); }
.inventory-stack strong { color: var(--ink); font-size: 18px; }
.quick-actions { display: grid; gap: 8px; }
.quick-actions a {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 12px; border-radius: 8px; background: var(--surface-soft);
  color: var(--ink); text-decoration: none; font-weight: 600;
}
.quick-actions a:hover { background: var(--primary-soft); color: var(--primary); }
.quick-actions a::after { content: '→'; color: var(--steel); }
.empty-state.compact { padding: 28px 18px; }
.empty-state.compact h3 { font-size: 15px; }
.empty-state.compact p { font-size: 13px; margin-bottom: 0; }

/* ===== Operations Dashboard v2 ===== */
.ops-dashboard { display: flex; flex-direction: column; gap: 16px; }
.ops-header {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 20px;
  padding-bottom: 4px;
}
.ops-header-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.ops-summary {
  display: grid; grid-template-columns: minmax(0, 1fr) 520px; gap: 16px; align-items: stretch;
}
.ops-status {
  background: var(--canvas); border: 1px solid var(--hairline); border-left: 4px solid var(--primary);
  border-radius: 10px; padding: 22px 24px;
}
.ops-status-label {
  font-size: 12px; font-weight: 700; color: var(--primary); text-transform: uppercase;
  letter-spacing: 0.06em; margin-bottom: 8px;
}
.ops-status-title { font-size: 24px; font-weight: 750; color: var(--ink); letter-spacing: 0; }
.ops-status-copy { margin-top: 6px; color: var(--slate); font-size: 14px; }
.ops-kpis {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  border: 1px solid var(--hairline); border-radius: 10px; overflow: hidden; background: var(--hairline);
}
.ops-kpis div {
  background: var(--canvas); padding: 18px 14px; min-width: 0;
}
.ops-kpis span { display: block; color: var(--slate); font-size: 12px; font-weight: 650; margin-bottom: 8px; }
.ops-kpis strong { display: block; color: var(--ink); font-size: 26px; line-height: 1; letter-spacing: 0; }
.ops-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.ops-primary, .ops-side { min-width: 0; }
.ops-side { display: flex; flex-direction: column; gap: 16px; }
.trusted-panel { padding: 0; }
.trusted-panel .panel-header { padding: 20px 20px 0; margin-bottom: 14px; }
.decision-table-wrap { overflow-x: auto; }
.decision-table { min-width: 980px; }
.decision-table th { background: var(--surface-soft); }
.decision-product { display: flex; align-items: center; gap: 12px; }
.decision-product img {
  width: 48px; height: 48px; border-radius: 6px; object-fit: cover; flex-shrink: 0;
  border: 1px solid var(--hairline); background: var(--surface);
}
.decision-title {
  max-width: 420px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--ink); font-weight: 650;
}
.ops-stat-list { display: grid; gap: 0; }
.ops-stat-list div {
  display: flex; justify-content: space-between; align-items: center;
  padding: 11px 0; border-bottom: 1px solid var(--hairline);
}
.ops-stat-list div:last-child { border-bottom: 0; }
.ops-stat-list span { color: var(--slate); }
.ops-stat-list strong { color: var(--ink); font-size: 18px; }
.recent-task-list { display: grid; gap: 10px; }
.recent-task-row {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding-bottom: 10px; border-bottom: 1px solid var(--hairline);
}
.recent-task-row:last-child { border-bottom: 0; padding-bottom: 0; }
.recent-task-row strong {
  display: block; color: var(--ink); font-size: 13px; max-width: 190px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.recent-task-row span:not(.tag) { display: block; color: var(--steel); font-size: 12px; margin-top: 2px; }
.assurance-card { background: linear-gradient(180deg, #fff 0%, #fafbff 100%); }
.assurance-line {
  display: flex; align-items: center; gap: 9px; color: var(--charcoal);
  padding: 8px 0; font-weight: 600; font-size: 13px;
}
.assurance-line span {
  width: 8px; height: 8px; border-radius: 50%; background: var(--success);
  box-shadow: 0 0 0 4px var(--tint-green);
}

/* ===== Workspace Dashboard v3 ===== */
.workspace-page {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.workspace-topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  padding-bottom: 2px;
}
.workspace-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}
.workspace-flash {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  border: 1px solid rgba(76, 83, 245, 0.18);
  border-left: 3px solid var(--primary);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(17, 24, 39, 0.04);
}
.flash-main {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-width: 0;
}
.flash-main strong {
  display: block;
  color: var(--ink);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
}
.flash-main p {
  margin-top: 3px;
  color: var(--slate);
  font-size: 13px;
  line-height: 1.5;
}
.flash-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  margin-top: 6px;
  flex: 0 0 auto;
  background: var(--success);
  box-shadow: 0 0 0 4px var(--tint-green);
}
.flash-dot.warning {
  background: var(--warning);
  box-shadow: 0 0 0 4px var(--tint-amber);
}
.flash-dot.running {
  background: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-soft);
}
.workspace-section {
  background: var(--canvas);
  border: 1px solid var(--hairline);
  border-radius: 8px;
  padding: 18px;
}
.section-row-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.section-row-title h2 {
  color: var(--ink);
  font-size: 15px;
  line-height: 1.35;
  font-weight: 750;
  letter-spacing: 0;
}
.section-row-title span {
  color: var(--steel);
  font-size: 12px;
  font-weight: 600;
}
.performance-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: var(--hairline);
}
.performance-card {
  min-width: 0;
  min-height: 112px;
  padding: 18px 18px 15px;
  background: linear-gradient(180deg, #fff 0%, #fbfcff 100%);
}
.performance-card span,
.mini-stat-list span {
  display: block;
  color: var(--slate);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.35;
}
.performance-card strong {
  display: block;
  margin-top: 10px;
  color: var(--ink);
  font-size: 30px;
  line-height: 1;
  font-weight: 780;
  letter-spacing: 0;
}
.performance-card small {
  display: block;
  margin-top: 10px;
  color: var(--steel);
  font-size: 12px;
  line-height: 1.35;
}
.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 16px;
  align-items: start;
}
.workspace-main,
.workspace-side {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.side-card {
  padding: 16px;
}
.insight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.insight-card {
  min-width: 0;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  padding: 16px;
  background: #fff;
}
.insight-card p {
  color: var(--charcoal);
  font-size: 13px;
  line-height: 1.6;
}
.agent-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.agent-avatar {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary);
  color: #fff;
  font-size: 13px;
  font-weight: 780;
  flex: 0 0 auto;
}
.agent-avatar.supply {
  background: #0f766e;
}
.agent-head strong {
  display: block;
  color: var(--ink);
  font-size: 14px;
  font-weight: 750;
  line-height: 1.3;
}
.agent-head span {
  display: block;
  margin-top: 1px;
  color: var(--steel);
  font-size: 12px;
  line-height: 1.35;
}
.insight-tags {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.insight-tags span {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 8px;
  border-radius: 6px;
  background: var(--surface-soft);
  border: 1px solid var(--hairline);
  color: var(--slate);
  font-size: 12px;
  font-weight: 650;
}
.workspace-table-card {
  margin: -2px -18px -18px;
  border-top: 1px solid var(--hairline);
}
.workspace-table-card .data-table th {
  background: #fbfcff;
  color: var(--slate);
  font-size: 12px;
  font-weight: 700;
}
.workspace-table-card .data-table th:first-child,
.workspace-table-card .data-table td:first-child {
  padding-left: 18px;
}
.workspace-table-card .data-table th:last-child,
.workspace-table-card .data-table td:last-child {
  padding-right: 18px;
}
.workspace-table-card .data-table tbody tr:last-child td {
  border-bottom: 0;
}
.workspace-review-section .decision-table {
  min-width: 1000px;
}
.workspace-review-section .decision-title {
  max-width: 560px;
}
.mini-stat-list {
  display: grid;
  gap: 0;
}
.mini-stat-list div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--hairline);
}
.mini-stat-list div:first-child {
  padding-top: 2px;
}
.mini-stat-list div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}
.mini-stat-list strong {
  color: var(--ink);
  font-size: 18px;
  line-height: 1;
  font-weight: 750;
}
.task-feed {
  display: grid;
  gap: 0;
}
.task-feed-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px solid var(--hairline);
}
.task-feed-row:first-child {
  padding-top: 0;
}
.task-feed-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}
.task-feed-row > div {
  min-width: 0;
}
.task-feed-row strong {
  display: block;
  max-width: 190px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
}
.task-feed-row span:not(.tag) {
  display: block;
  margin-top: 2px;
  color: var(--steel);
  font-size: 12px;
  line-height: 1.35;
}

@media (max-width: 1100px) {
  .product-command-filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .product-command-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 768px) {
  body { display: block; }
  .sidebar { display: none; }
  .mobile-header {
    position: sticky;
    top: 0;
    z-index: 90;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--hairline);
    background: rgba(255,255,255,0.98);
    padding: 0 16px;
  }
  .mobile-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--ink);
    text-decoration: none;
  }
  .brand-mark-mobile { width: 28px; height: 28px; }
  .mobile-brand .logo-icon {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 6px;
    background: var(--primary);
    color: #fff;
    font-size: 10px;
  }
  .mobile-menu-button {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid var(--hairline);
    border-radius: 6px;
    background: #fff;
    color: var(--ink);
  }
  .mobile-nav-dialog[open] {
    width: min(320px, 88vw);
    max-width: none;
    height: 100vh;
    max-height: none;
    display: flex;
    flex-direction: column;
    border: 0;
    border-left: 1px solid var(--hairline);
    margin: 0 0 0 auto;
    padding: 16px;
    background: #fff;
    color: var(--charcoal);
  }
  .mobile-nav-dialog::backdrop { background: rgba(17,24,39,0.4); }
  .mobile-nav-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
  }
  .mobile-nav-links { display: grid; gap: 3px; }
  .mobile-nav-links .sidebar-link { min-height: 40px; }
  .mobile-nav-section {
    color: var(--steel);
    font-size: 11px;
    font-weight: 650;
    padding: 14px 10px 4px;
  }
  .mobile-nav-account {
    display: flex;
    align-items: center;
    gap: 9px;
    border-top: 1px solid var(--hairline);
    margin-top: auto;
    padding-top: 16px;
  }
  .mobile-nav-account strong,
  .mobile-nav-account small { display: block; }
  .mobile-nav-account small { color: var(--steel); margin-top: 2px; }
  .mobile-nav-logout .btn { width: 100%; margin-top: 12px; }
  .main-wrapper { margin-left: 0; }
  .main-content { padding: 20px; }
  .pricing-page-head { flex-direction: column; }
  .card-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .card-grid-3 { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .pricing-control-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-command-filters { grid-template-columns: 1fr; }
  .product-command-actions .btn { width: 100%; }
  .ranking-action-row { flex-direction: column; align-items: stretch; }
  .ranking-match-form { flex: 1; }
  .ranking-match-form .btn { width: 100%; }
  .auto-sourcing-form { align-items: stretch; }
  .auto-sourcing-toggle,
  .auto-sourcing-time,
  .auto-sourcing-form .btn {
    width: 100%;
  }
  .task-page-head {
    flex-direction: column;
    align-items: stretch;
  }
  .task-schedule-box {
    align-items: stretch;
  }
  .task-rule-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .comparison-detail-grid { grid-template-columns: 1fr; }
  .source-panel { position: static; }
  .supplier-match-card { grid-template-columns: 32px minmax(0, 1fr); }
  .supplier-match-image { display: none; }
  .comparison-actions { align-items: stretch; flex-direction: column; }
  .dashboard-head, .dashboard-status-panel { flex-direction: column; align-items: stretch; }
  .dashboard-actions, .status-pill-group { justify-content: flex-start; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-main-grid { grid-template-columns: 1fr; }
  .opportunity-row { grid-template-columns: 42px minmax(0, 1fr); }
  .opportunity-score { grid-column: 2; text-align: left; }
  .ops-header, .ops-summary { grid-template-columns: 1fr; flex-direction: column; }
  .ops-header-actions { justify-content: flex-start; }
  .ops-kpis { grid-template-columns: repeat(2, 1fr); }
  .ops-layout { grid-template-columns: 1fr; }
  .workspace-topbar,
  .workspace-flash,
  .section-row-title {
    flex-direction: column;
    align-items: stretch;
  }
  .workspace-actions {
    justify-content: flex-start;
  }
  .performance-grid,
  .insight-grid,
  .workspace-grid {
    grid-template-columns: 1fr;
  }
  .workspace-section {
    padding: 16px;
  }
  .workspace-table-card {
    margin: -2px -16px -16px;
  }
  .workspace-table-card .data-table th:first-child,
  .workspace-table-card .data-table td:first-child {
    padding-left: 16px;
  }
}

/* ===== Authentication and administrator controls ===== */
.sidebar-admin-nav {
  display: grid;
  gap: 2px;
  margin-bottom: 8px;
}
.sidebar-account {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px;
}
.sidebar-account-avatar {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 6px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 12px;
  font-weight: 750;
}
.sidebar-account-meta {
  min-width: 0;
  flex: 1;
}
.sidebar-account-meta strong,
.sidebar-account-meta span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sidebar-account-meta strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}
.sidebar-account-meta span {
  color: var(--steel);
  font-size: 11px;
}
.sidebar-account-actions {
  display: flex;
  align-items: center;
  gap: 2px;
}
.sidebar-account-actions form { display: flex; }
.sidebar-account-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--slate);
  cursor: pointer;
  padding: 0;
  text-decoration: none;
}
.sidebar-account-icon:hover,
.sidebar-account-icon.active { background: rgba(0,0,0,0.05); color: var(--ink); }
.sidebar-logout:hover { color: var(--error); }

.auth-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: block;
  background: #fff;
}
.auth-shell {
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(390px, 0.92fr);
  align-items: stretch;
  gap: 0;
  padding: 0;
}
.auth-intro {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: clamp(36px, 5vw, 76px) clamp(32px, 6vw, 96px) 36px;
  color: #fff;
  background: var(--brand-navy);
  border: 0;
  border-radius: 0;
  overflow: hidden;
  position: relative;
}
.auth-intro-topline,
.auth-intro-footer,
.auth-panel-head,
.auth-form-footnote {
  display: flex;
  align-items: center;
}
.auth-intro-topline { gap: 12px; }
.auth-intro-mark {
  width: 40px;
  height: 40px;
  display: block;
  flex: 0 0 auto;
}
.auth-intro-name { display: block; color: #fff; font-size: 18px; }
.auth-intro-label {
  display: block;
  margin-top: 4px;
  color: rgba(255,255,255,0.64);
  font-size: 11px;
  letter-spacing: 0;
}
.auth-intro-copy { margin-top: auto; max-width: 440px; }
.auth-kicker-light { color: #86d8d4; }
.auth-intro-copy h1 {
  margin: 12px 0 14px;
  color: #fff;
  font-size: clamp(34px, 3.8vw, 48px);
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.12;
}
.auth-intro-copy p {
  max-width: 320px;
  color: rgba(255,255,255,0.68);
  font-size: 15px;
  line-height: 1.8;
}
.auth-signal {
  position: relative;
  z-index: 1;
  margin-top: 34px;
  width: min(100%, 440px);
  padding: 16px 18px 14px;
  border: 1px solid rgba(144, 178, 230, 0.2);
  border-radius: 10px;
  background: rgba(255,255,255,0.045);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}
.auth-signal-head,
.auth-signal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.auth-signal-head {
  color: rgba(255,255,255,0.72);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
}
.auth-signal-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.46);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0;
}
.auth-signal-live i {
  width: 5px;
  height: 5px;
  display: block;
  border-radius: 50%;
  background: #75d9c4;
  box-shadow: 0 0 0 3px rgba(117,217,196,0.1);
}
.auth-signal-chart {
  position: relative;
  height: 112px;
  margin: 12px 0 8px;
  overflow: hidden;
}
.auth-signal-chart svg { width: 100%; height: 100%; display: block; }
.auth-chart-grid { fill: none; stroke: rgba(255,255,255,0.09); stroke-width: 1; }
.auth-chart-line {
  fill: none;
  stroke: #86d8d4;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 5px rgba(134,216,212,0.24));
  stroke-dasharray: 620;
  stroke-dashoffset: 620;
  animation: auth-chart-draw 900ms var(--ease-out) 260ms forwards;
}
.auth-chart-point { fill: #0a1530; stroke: #86d8d4; stroke-width: 2; }
.auth-chart-label {
  position: absolute;
  color: rgba(255,255,255,0.35);
  font-size: 9px;
  letter-spacing: 0.04em;
}
.auth-chart-label-top { top: 2px; left: 0; }
.auth-chart-label-bottom { right: 0; bottom: 0; }
.auth-signal-footer { border-top: 1px solid rgba(255,255,255,0.09); padding-top: 11px; }
.auth-signal-footer strong { color: rgba(255,255,255,0.84); font-size: 11px; font-weight: 600; }
.auth-signal-footer span { color: rgba(255,255,255,0.38); font-size: 10px; }
@keyframes auth-chart-draw { to { stroke-dashoffset: 0; } }
.auth-flow {
  display: grid;
  gap: 17px;
  margin-top: 28px;
  max-width: 440px;
}
.auth-flow-row {
  min-height: 46px;
  display: grid;
  grid-template-columns: 32px 1px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
}
.auth-flow-index { color: #86d8d4; font-size: 11px; letter-spacing: 0.08em; }
.auth-flow-line { height: 100%; background: rgba(255,255,255,0.22); }
.auth-flow-row strong { display: block; color: #fff; font-size: 13px; font-weight: 600; }
.auth-flow-row small { display: block; margin-top: 3px; color: rgba(255,255,255,0.5); font-size: 12px; }
.auth-flow-row { opacity: 0; transform: translateY(8px); animation: auth-rise 420ms var(--ease-out) forwards; }
.auth-flow-row:nth-child(1) { animation-delay: 180ms; }
.auth-flow-row:nth-child(2) { animation-delay: 230ms; }
.auth-flow-row:nth-child(3) { animation-delay: 280ms; }
@keyframes auth-rise { to { opacity: 1; transform: translateY(0); } }
.auth-intro-footer {
  gap: 10px;
  margin-top: auto;
  padding-top: 30px;
  color: rgba(255,255,255,0.42);
  font-size: 10px;
  letter-spacing: 0.12em;
}
.auth-footer-rule { width: 42px; height: 1px; background: rgba(255,255,255,0.24); }
.auth-panel {
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border: 1px solid var(--hairline);
  border-top: 0;
  border-right: 0;
  border-bottom: 0;
  border-left: 1px solid var(--hairline);
  border-radius: 0;
  background: #fff;
  padding: clamp(40px, 6vw, 92px) clamp(32px, 6vw, 96px);
  box-shadow: none;
}
.auth-panel-head {
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  align-self: stretch;
  margin-bottom: 74px;
}
.auth-panel > .auth-heading,
.auth-panel > .auth-form,
.auth-panel > .auth-alert,
.auth-panel > .auth-form-footnote,
.auth-panel > .auth-back {
  width: min(100%, 400px);
  align-self: center;
}
.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  font-size: 18px;
  font-weight: 650;
}
.auth-brand .logo-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--primary);
  color: #fff;
  font-size: 10px;
  font-weight: 750;
}
.auth-brand .brand-mark-auth { width: 36px; height: 36px; }
.auth-secure-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--steel);
  font-size: 11px;
}
.auth-secure-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--success); }
.auth-heading { margin-bottom: 24px; }
.auth-heading h1 {
  color: var(--ink);
  font-size: 30px;
  font-weight: 650;
  margin: 8px 0 9px;
  letter-spacing: 0;
}
.auth-heading p {
  color: var(--slate);
  line-height: 1.6;
}
.auth-kicker {
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
}
.auth-alert,
.admin-flash {
  border: 1px solid #fecaca;
  border-radius: 6px;
  background: #fef2f2;
  color: #991b1b;
  padding: 10px 12px;
  margin-bottom: 16px;
  font-size: 13px;
}
.admin-flash-success {
  border-color: #a7f3d0;
  background: #ecfdf5;
  color: #065f46;
}
.auth-form .form-input { height: 46px; }
.auth-submit {
  width: 100%; height: 48px; margin-top: 8px; justify-content: space-between; padding: 0 16px 0 18px;
  box-shadow: 0 8px 16px rgba(76,83,245,0.16);
  transition: transform var(--motion-fast) var(--ease-out), box-shadow var(--motion-fast) var(--ease-out), background-color var(--motion-fast) var(--ease-out);
}
.auth-submit:hover { box-shadow: 0 11px 20px rgba(76,83,245,0.22); }
.auth-submit:active { box-shadow: 0 5px 10px rgba(76,83,245,0.16); }
.auth-submit:focus-visible,
.auth-back:focus-visible,
.auth-brand:focus-visible { outline: 3px solid rgba(76,83,245,0.24); outline-offset: 3px; }
.auth-submit-arrow { font-size: 18px; line-height: 1; }
.auth-form-footnote {
  justify-content: center;
  gap: 9px;
  margin-top: 58px;
  color: var(--steel);
  font-size: 11px;
}
.auth-form-footnote-rule { width: 24px; height: 1px; background: var(--hairline); }
.auth-back {
  display: block;
  color: var(--slate);
  font-size: 13px;
  text-align: center;
  text-decoration: none;
  margin-top: 20px;
}
.auth-back:hover { color: var(--primary); }
@media (prefers-reduced-motion: reduce) {
  .auth-chart-line,
  .auth-flow-row { animation: none; opacity: 1; transform: none; stroke-dashoffset: 0; }
  .auth-submit { transition: none; }
}
.mfa-qr-shell {
  width: 176px;
  height: 176px;
  margin: 0 auto 18px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
  padding: 8px;
}
.mfa-qr-shell img { width: 100%; height: 100%; display: block; }
.mfa-manual-key {
  display: grid;
  gap: 6px;
  margin-bottom: 20px;
  padding: 11px 12px;
  border-radius: 6px;
  background: #f5f6f8;
  color: var(--slate);
  font-size: 12px;
}
.mfa-manual-key code {
  color: var(--ink);
  font-size: 13px;
  overflow-wrap: anywhere;
}
.mfa-code-input { font-size: 18px; font-variant-numeric: tabular-nums; }
.mfa-recovery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 20px 0;
}
.mfa-recovery-grid code {
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: #f8fafc;
  color: var(--ink);
  padding: 9px 7px;
  text-align: center;
  font-size: 12px;
}
.mfa-recovery-continue {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.admin-page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}
.admin-identity {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: #fff;
  padding: 7px 10px;
}
.admin-identity span { color: var(--ink); font-weight: 600; }
.admin-identity strong {
  color: var(--primary);
  background: var(--primary-soft);
  border-radius: 4px;
  padding: 2px 6px;
  font-size: 11px;
}
.admin-stat-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
  margin-bottom: 20px;
}
.admin-stat-strip > div {
  min-width: 0;
  padding: 16px 18px;
  border-right: 1px solid var(--hairline);
}
.admin-stat-strip > div:last-child { border-right: 0; }
.admin-stat-strip span,
.admin-stat-strip strong { display: block; }
.admin-stat-strip span { color: var(--slate); font-size: 12px; }
.admin-stat-strip strong { color: var(--ink); font-size: 24px; margin-top: 3px; }
.admin-tabs { margin-bottom: 16px; }
.admin-filter-band,
.admin-section-note {
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
  margin-bottom: 12px;
  padding: 14px 16px;
}
.admin-filter-form {
  display: grid;
  grid-template-columns: 130px minmax(180px, 1fr) 140px auto;
  gap: 12px;
  align-items: end;
}
.admin-filter-form .form-group { margin: 0; }
.admin-filter-form .form-select { height: 40px; }
.admin-section-note { color: var(--slate); }
.admin-table-shell {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}
.admin-table-shell .data-table { min-width: 920px; }
.admin-table-shell .data-table tbody tr:last-child td { border-bottom: 0; }
.admin-risk-table th:last-child,
.admin-risk-table td:last-child {
  position: sticky;
  right: 0;
  z-index: 2;
  background: #fff;
  box-shadow: -8px 0 12px -12px rgba(17, 24, 39, 0.45);
}
.admin-risk-table tr:hover td:last-child { background: var(--surface-soft); }
.admin-product-cell {
  --admin-product-image-size: 64px;
  display: grid;
  grid-template-columns: var(--admin-product-image-size) minmax(200px, 1fr);
  align-items: center;
  gap: 12px;
  min-width: 276px;
}
.admin-product-image {
  width: var(--admin-product-image-size);
  height: var(--admin-product-image-size);
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 6px;
  border: 1px solid var(--hairline);
  background: var(--surface-soft);
}
.admin-product-image-media {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.admin-product-image-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  padding: 6px;
  background: var(--surface-soft);
  color: var(--steel);
  font-size: 11px;
  line-height: 1.3;
  text-align: center;
}
.admin-product-image-placeholder[hidden] { display: none; }
.admin-product-copy { min-width: 0; }
.admin-product-cell strong,
.admin-product-cell span { display: block; }
.admin-product-cell strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--ink);
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.admin-product-cell span { color: var(--steel); font-size: 12px; margin-top: 4px; }
.admin-cell-note { font-size: 12px; margin-top: 3px; }
.admin-reason {
  max-width: 300px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.admin-rule-key {
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  margin-top: 3px;
}

.brand-review-dialog {
  width: min(560px, calc(100vw - 32px));
  max-height: calc(100vh - 48px);
  margin: auto;
  border: 0;
  border-radius: 8px;
  background: #fff;
  color: var(--charcoal);
  padding: 0;
  box-shadow: 0 24px 64px rgba(17, 24, 39, 0.24);
  overflow-y: auto;
}
.brand-review-dialog::backdrop { background: rgba(17, 24, 39, 0.48); }
.brand-review-dialog form { padding: 24px; }
.dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.dialog-head h2 { color: var(--ink); font-size: 20px; margin-top: 3px; }
.dialog-close {
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  color: var(--slate);
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}
.dialog-product-summary {
  border-left: 3px solid var(--primary);
  background: var(--surface-soft);
  padding: 11px 12px;
  margin: 18px 0;
}
.dialog-product-summary strong,
.dialog-product-summary span { display: block; }
.dialog-product-summary strong { color: var(--ink); line-height: 1.4; }
.dialog-product-summary span { color: var(--slate); font-size: 12px; margin-top: 4px; }
.admin-choice-group { border: 0; margin-bottom: 16px; }
.admin-choice-group legend { color: var(--charcoal); font-size: 13px; font-weight: 600; margin-bottom: 7px; }
.segmented-choice {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.segmented-choice input { position: absolute; opacity: 0; pointer-events: none; }
.segmented-choice span {
  min-height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid var(--hairline-strong);
  border-radius: 6px;
  background: #fff;
  color: var(--charcoal);
  cursor: pointer;
  font-weight: 550;
}
.segmented-choice input:checked + span {
  border-color: var(--primary);
  background: var(--primary-soft);
  color: var(--primary);
}
.admin-textarea {
  min-height: 88px;
  height: auto;
  padding: 10px 12px;
  resize: vertical;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 22px;
}

.admin-primary-tabs {
  margin: 20px 0 16px;
  overflow-x: auto;
  scrollbar-width: thin;
}
.admin-primary-tabs .tab {
  flex: 0 0 auto;
  white-space: nowrap;
}
.admin-stat-strip small {
  display: block;
  color: var(--steel);
  font-size: 11px;
  margin-top: 5px;
}
.admin-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 16px;
}
.admin-panel-band {
  min-width: 0;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
  padding: 18px;
}
.admin-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}
.admin-panel-head h2 {
  color: var(--ink);
  font-size: 15px;
  margin: 0;
}
.admin-panel-head p {
  color: var(--steel);
  font-size: 12px;
  margin: 4px 0 0;
}
.admin-panel-head a {
  color: var(--primary);
  font-size: 12px;
  text-decoration: none;
  white-space: nowrap;
}
.provider-cost-list > div {
  display: grid;
  grid-template-columns: minmax(100px, 1fr) 72px 80px;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  border-top: 1px solid var(--hairline);
  font-size: 13px;
}
.provider-cost-list > div:first-child { border-top: 0; }
.provider-cost-list strong { color: var(--charcoal); font-weight: 550; }
.provider-cost-list b { color: var(--ink); text-align: right; }
.operation-compact-list > div {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  border-top: 1px solid var(--hairline);
}
.operation-compact-list > div:first-child { border-top: 0; }
.operation-compact-list strong,
.operation-compact-list small { display: block; }
.operation-compact-list strong {
  color: var(--ink);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.operation-compact-list small { color: var(--steel); font-size: 11px; margin-top: 3px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #9ca3af; }
.status-dot-success { background: #16a34a; }
.status-dot-failed { background: #dc2626; }
.status-dot-running { background: var(--primary); }
.admin-empty-line {
  color: var(--steel);
  font-size: 13px;
  padding: 20px 0;
  text-align: center;
}
.admin-create-user { margin-bottom: 16px; }
.admin-create-user-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(145px, 1fr)) auto;
  align-items: end;
  gap: 12px;
}
.admin-create-user-form .form-group { margin: 0; }
.admin-create-user-form .btn { min-height: 40px; }
.admin-create-administrator-form {
  display: grid;
  grid-template-columns: minmax(210px, 0.7fr) minmax(280px, 1fr) auto;
  align-items: end;
  gap: 12px;
}
.admin-create-administrator-form .form-group { margin: 0; }
.admin-create-administrator-form .btn { min-height: 40px; }
.admin-administrators-table { min-width: 900px !important; }
.admin-administrators-table td { vertical-align: middle; }
.admin-account-audit-section { margin-top: 16px; }
.admin-account-audit-shell { border: 0; }
.admin-account-audit-table { min-width: 680px !important; }
.admin-audit-action {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--surface-soft);
  color: var(--slate);
  font-size: 11px;
  font-weight: 600;
}
.admin-audit-action-created,
.admin-audit-action-enabled { color: #166534; background: #f0fdf4; }
.admin-audit-action-disabled { color: #991b1b; background: #fef2f2; }
.admin-audit-action-password_reset { color: #1d4ed8; background: #eff6ff; }
.admin-users-table { min-width: 1120px !important; }
.admin-users-table td { vertical-align: top; }
.admin-action-menu { position: relative; }
.admin-action-menu summary {
  color: var(--primary);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  list-style: none;
}
.admin-action-menu summary::-webkit-details-marker { display: none; }
.admin-action-menu > div {
  position: absolute;
  z-index: 8;
  right: 0;
  top: 24px;
  width: 280px;
  border: 1px solid var(--hairline-strong);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 32px rgba(17, 24, 39, 0.16);
  padding: 14px;
}
.admin-action-menu form {
  display: grid;
  gap: 7px;
  border-top: 1px solid var(--hairline);
  padding-top: 12px;
  margin-top: 12px;
}
.admin-action-menu form:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.user-management-content { padding: 24px; }
.user-management-dialog form { padding: 0; }
.user-management-dialog .dialog-head p {
  color: var(--slate);
  font-size: 13px;
  margin: 5px 0 0;
}
.user-management-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--surface-soft);
  margin: 18px 0;
}
.user-management-summary > div {
  padding: 12px;
  border-right: 1px solid var(--hairline);
}
.user-management-summary > div:last-child { border-right: 0; }
.user-management-summary span,
.user-management-summary strong { display: block; }
.user-management-summary span { color: var(--steel); font-size: 11px; }
.user-management-summary strong { color: var(--ink); font-size: 14px; margin-top: 4px; }
.user-management-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 10px;
  border-top: 1px solid var(--hairline);
  padding-top: 16px !important;
  margin-top: 16px;
}
.user-management-form .form-group { margin: 0; }
.user-management-form:has(.form-group + .form-group) {
  grid-template-columns: repeat(2, minmax(0, 1fr)) auto;
}
.user-management-danger {
  display: flex;
  justify-content: flex-end;
  border-top: 1px solid var(--hairline);
  padding-top: 16px !important;
  margin-top: 18px;
}
.user-management-danger .btn { color: var(--error); }
.admin-ledger-section { margin-top: 16px; }
.quota-ledger-list > div {
  display: grid;
  grid-template-columns: 110px minmax(180px, 1fr) 52px 80px;
  gap: 12px;
  align-items: center;
  min-height: 42px;
  border-top: 1px solid var(--hairline);
  font-size: 12px;
}
.quota-ledger-list > div:first-child { border-top: 0; }
.quota-ledger-list span,
.quota-ledger-list small { color: var(--steel); }
.quota-ledger-list b { text-align: right; }
.quota-ledger-list .positive { color: #15803d; }
.quota-ledger-list .negative { color: #b91c1c; }
.admin-usage-filter { grid-template-columns: minmax(180px, 1fr) 160px 140px auto; }
.admin-operation-filter { grid-template-columns: minmax(220px, 1fr) 180px auto; }
.admin-usage-table { min-width: 1060px !important; }
.admin-operation-table { min-width: 1100px !important; }
.admin-error-note {
  max-width: 320px;
  color: #b91c1c;
  font-size: 11px;
  line-height: 1.4;
  margin-top: 4px;
}
.admin-operation-summary {
  max-width: 360px;
  color: var(--slate);
  font-size: 12px;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ===== Customer account and quota ===== */
.account-page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}
.account-page-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.account-page-actions svg { flex: 0 0 auto; }
.account-stat-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}
.account-stat-strip > div {
  min-width: 0;
  padding: 16px 18px;
  border-right: 1px solid var(--hairline);
}
.account-stat-strip > div:last-child { border-right: 0; }
.account-stat-strip span,
.account-stat-strip strong,
.account-stat-strip small { display: block; }
.account-stat-strip span {
  color: var(--slate);
  font-size: 12px;
}
.account-stat-strip strong {
  min-height: 30px;
  margin-top: 4px;
  overflow: hidden;
  color: var(--ink);
  font-size: 20px;
  font-weight: 650;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-stat-strip small {
  margin-top: 4px;
  overflow: hidden;
  color: var(--steel);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-plan-band,
.account-history-band,
.account-ledger-band {
  min-width: 0;
  margin-bottom: 16px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
  padding: 20px;
}
.account-plan-head,
.account-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}
.account-plan-head h2,
.account-section-head h2 {
  margin: 0;
  color: var(--ink);
  font-size: 16px;
  font-weight: 650;
}
.account-plan-head p,
.account-section-head p {
  margin: 4px 0 0;
  color: var(--steel);
  font-size: 12px;
}
.account-section-kicker {
  display: block;
  margin-bottom: 4px;
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
}
.account-quota-meter {
  width: 100%;
  height: 8px;
  margin: 20px 0 18px;
  overflow: hidden;
  border-radius: 4px;
  background: #eceef3;
}
.account-quota-meter > span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}
.account-quota-meter.unlimited > span {
  width: 100%;
  background: var(--success);
}
.account-plan-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--hairline);
}
.account-plan-meta > div {
  min-width: 0;
  padding: 14px 16px 0 0;
}
.account-plan-meta span,
.account-plan-meta strong { display: block; }
.account-plan-meta span {
  color: var(--steel);
  font-size: 11px;
}
.account-plan-meta strong {
  margin-top: 3px;
  color: var(--charcoal);
  font-size: 13px;
  font-weight: 600;
}
.account-section-head { margin-bottom: 16px; }
.account-status-tabs {
  display: flex;
  flex: 0 0 auto;
  gap: 3px;
  padding: 3px;
  border-radius: 8px;
  background: var(--surface);
}
.account-status-tabs a {
  min-width: 54px;
  padding: 5px 10px;
  border-radius: 6px;
  color: var(--slate);
  font-size: 12px;
  font-weight: 550;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
}
.account-status-tabs a:hover { color: var(--ink); }
.account-status-tabs a.active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(17, 24, 39, 0.09);
}
.account-table-shell {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  border: 1px solid var(--hairline);
  border-radius: 8px;
}
.account-operation-table {
  min-width: 900px;
  table-layout: fixed;
}
.account-operation-table th:nth-child(1) { width: 110px; }
.account-operation-table th:nth-child(2) { width: 138px; }
.account-operation-table th:nth-child(3) { width: 180px; }
.account-operation-table th:nth-child(4) { width: 105px; }
.account-operation-table th:nth-child(6) { width: 80px; }
.account-operation-table th:nth-child(7) { width: 70px; }
.account-operation-table td:nth-child(4),
.account-operation-table td:nth-child(6),
.account-operation-table td:nth-child(7) { white-space: nowrap; }
.account-operation-table tbody tr:last-child td { border-bottom: 0; }
.account-time-cell {
  color: var(--slate) !important;
  font-size: 12px !important;
  white-space: nowrap;
}
.account-operation-scope {
  max-width: 185px;
  overflow: hidden;
  color: var(--charcoal);
  font-size: 12px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-operation-result {
  max-width: 300px;
  color: var(--slate);
  font-size: 12px;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.account-refund-note {
  margin-top: 4px;
  color: #15803d;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}
.account-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: var(--steel);
  font-size: 12px;
}
.account-pagination > div {
  display: flex;
  align-items: center;
  gap: 8px;
}
.account-ledger-list > div {
  display: grid;
  grid-template-columns: 100px minmax(180px, 1fr) 48px 76px;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  border-top: 1px solid var(--hairline);
}
.account-ledger-list > div:first-child { border-top: 0; }
.account-ledger-list > div > span,
.account-ledger-list > div > small {
  color: var(--steel);
  font-size: 11px;
}
.account-ledger-list strong,
.account-ledger-list small { display: block; }
.account-ledger-list strong {
  color: var(--charcoal);
  font-size: 13px;
  font-weight: 600;
}
.account-ledger-list div > small {
  margin-top: 3px;
  overflow: hidden;
  color: var(--steel);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-ledger-list b { text-align: right; }
.account-ledger-list .positive { color: #15803d; }
.account-ledger-list .negative { color: #b91c1c; }
.account-empty-line {
  display: block !important;
  padding: 18px 0;
  color: var(--steel);
  font-size: 12px;
  text-align: center;
}

@media (max-width: 768px) {
  .auth-shell { display: block; padding: 0; }
  .auth-intro { min-height: 0; height: auto; padding: 22px 22px 24px; border-radius: 0; }
  .auth-intro-copy { margin-top: 42px; }
  .auth-intro-copy h1 { font-size: 32px; }
  .auth-intro-copy p { font-size: 13px; }
  .auth-signal { margin-top: 28px; }
  .auth-flow { display: none; }
  .auth-intro-footer { padding-top: 30px; }
  .auth-panel { min-height: 0; padding: 30px 24px 34px; border: 0; border-top: 1px solid var(--hairline); border-radius: 0; }
  .auth-panel-head { margin-bottom: 48px; }
  .admin-page-head { flex-direction: column; }
  .admin-primary-tabs { width: 100%; }
  .admin-stat-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-stat-strip > div:nth-child(2) { border-right: 0; }
  .admin-stat-strip > div:nth-child(-n+2) { border-bottom: 1px solid var(--hairline); }
  .admin-filter-form { grid-template-columns: 1fr; }
  .admin-risk-table th:last-child,
  .admin-risk-table td:last-child {
    position: static;
    box-shadow: none;
  }
  .admin-overview-grid { grid-template-columns: 1fr; }
  .admin-create-user-form { grid-template-columns: 1fr; }
  .admin-create-administrator-form { grid-template-columns: 1fr; }
  .user-management-summary { grid-template-columns: 1fr; }
  .user-management-summary > div { border-right: 0; border-bottom: 1px solid var(--hairline); }
  .user-management-summary > div:last-child { border-bottom: 0; }
  .user-management-form,
  .user-management-form:has(.form-group + .form-group) { grid-template-columns: 1fr; }
  .quota-ledger-list > div { grid-template-columns: 90px minmax(120px, 1fr) 44px; }
  .quota-ledger-list small { display: none; }
  .account-page-head,
  .account-plan-head,
  .account-section-head { flex-direction: column; }
  .account-page-actions { width: 100%; }
  .account-page-actions .btn { flex: 1 1 0; }
  .account-stat-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-stat-strip > div:nth-child(2) { border-right: 0; }
  .account-stat-strip > div:nth-child(-n+2) { border-bottom: 1px solid var(--hairline); }
  .account-plan-band,
  .account-history-band,
  .account-ledger-band { padding: 16px; }
  .account-plan-meta { grid-template-columns: 1fr; }
  .account-plan-meta > div { padding-right: 0; }
  .account-status-tabs {
    width: 100%;
    overflow-x: auto;
  }
  .account-status-tabs a { flex: 1 0 auto; }
  .account-ledger-list > div {
    grid-template-columns: 78px minmax(0, 1fr) 38px;
    gap: 9px;
  }
  .account-ledger-list > div > small { display: none; }
  .account-pagination {
    align-items: flex-start;
    flex-direction: column;
  }
  .main-wrapper { width: 100%; }
}

@media (max-width: 380px) {
  .auth-signal-footer { display: block; }
  .auth-signal-footer span { display: block; margin-top: 4px; }
}

@media (max-width: 420px) {
  .account-page-actions { flex-direction: column; }
  .account-page-actions .btn { width: 100%; }
  .account-stat-strip strong { font-size: 18px; }
}

/* ===== Pricing center ===== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.pricing-workbench {
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}
.pricing-workbench-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 58px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--hairline);
}
.pricing-workbench-tabs {
  display: inline-flex;
  gap: 3px;
  padding: 3px;
  border-radius: 7px;
  background: var(--surface);
}
.pricing-workbench-tabs button {
  min-height: 32px;
  padding: 5px 13px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--slate);
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
}
.pricing-workbench-tabs button.active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(17, 24, 39, 0.1);
}
.pricing-workbench-panel[hidden] { display: none; }
.pricing-workbench-selectors {
  display: grid;
  grid-template-columns: minmax(140px, 0.55fr) minmax(240px, 1.35fr) minmax(190px, 0.75fr);
  align-items: end;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--hairline);
  background: var(--surface-soft);
}
.pricing-workbench-selectors label { min-width: 0; }
.pricing-workbench-selectors label > span {
  display: block;
  margin-bottom: 5px;
  color: var(--slate);
  font-size: 11px;
  font-weight: 500;
}
.pricing-workbench-selectors .form-select {
  height: 40px;
  border-radius: 6px;
  font-size: 13px;
}
.pricing-workbench-save .btn {
  min-width: 104px;
  height: 40px;
  white-space: nowrap;
}
#pricing-workbench-form.is-dirty .pricing-workbench-save .btn {
  box-shadow: 0 0 0 3px rgba(76, 83, 245, 0.12);
}
.pricing-workbench-selection {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  align-items: center;
  gap: 11px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--hairline);
  background: #fff;
}
.pricing-workbench-selection-image {
  width: 50px;
  height: 50px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--surface);
}
.pricing-workbench-selection-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.pricing-workbench-selection-copy,
.pricing-workbench-selection-copy span,
.pricing-workbench-selection-copy strong,
.pricing-workbench-selection-copy small { min-width: 0; }
.pricing-workbench-selection-copy span,
.pricing-workbench-selection-copy strong,
.pricing-workbench-selection-copy small { display: block; }
.pricing-workbench-selection-copy span {
  margin-bottom: 2px;
  color: var(--steel);
  font-size: 10px;
}
.pricing-workbench-selection-copy strong,
.pricing-workbench-selection-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-workbench-selection-copy strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}
.pricing-workbench-selection-copy small {
  margin-top: 3px;
  color: var(--slate);
  font-size: 11px;
}
.pricing-workbench-fields {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  background: var(--hairline);
}
.pricing-workbench-fields > div,
.pricing-workbench-fields > label {
  display: block;
  min-width: 0;
  min-height: 78px;
  padding: 12px 13px;
  background: #fff;
}
.pricing-workbench-fields > div > span,
.pricing-workbench-fields > div > strong,
.pricing-workbench-fields > label > span { display: block; }
.pricing-workbench-fields > div > span,
.pricing-workbench-fields > label > span {
  min-height: 30px;
  color: var(--slate);
  font-size: 10px;
  line-height: 1.4;
}
.pricing-workbench-fields > div > span b,
.pricing-workbench-fields > label > span b {
  display: inline-flex;
  width: 18px;
  height: 18px;
  align-items: center;
  justify-content: center;
  margin-right: 6px;
  border-radius: 4px;
  background: var(--surface);
  color: var(--primary);
  font-size: 9px;
  font-weight: 700;
}
.pricing-workbench-fields > div > strong {
  margin-top: 6px;
  overflow: hidden;
  color: var(--ink);
  font-size: 17px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-workbench-editable { background: #fbfcff !important; }
.pricing-field-input {
  display: flex;
  height: 32px;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
  padding: 0 7px;
  border: 1px solid #cfd5df;
  border-radius: 5px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.pricing-field-input:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(76, 83, 245, 0.1);
}
.pricing-field-input input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 650;
}
.pricing-field-input i {
  flex: 0 0 auto;
  color: var(--slate);
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
}
.pricing-workbench-fields .pricing-workbench-cost { background: #eef8f7; }
.pricing-workbench-fields .pricing-workbench-settlement { background: #fff5f6; }
.pricing-workbench-fields .pricing-workbench-profit,
.pricing-workbench-fields .pricing-workbench-margin { background: #eef9f2; }
.pricing-workbench-empty {
  padding: 42px 20px;
  color: var(--steel);
  text-align: center;
}
.pricing-settings-card {
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}
.pricing-settings-summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 18px;
  align-items: center;
  gap: 16px;
  min-height: 58px;
  padding: 0 18px;
  cursor: pointer;
  list-style: none;
}
.pricing-settings-summary::-webkit-details-marker { display: none; }
.pricing-settings-summary:hover { background: var(--surface-soft); }
.pricing-settings-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 650;
}
.pricing-settings-title svg { color: var(--slate); }
.pricing-settings-snapshot {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  min-width: 0;
  color: var(--slate);
  font-size: 12px;
  white-space: nowrap;
}
.pricing-settings-chevron {
  color: var(--steel);
  transition: transform 0.16s ease;
}
.pricing-settings-card[open] .pricing-settings-chevron { transform: rotate(90deg); }
.pricing-settings-form { border-top: 1px solid var(--hairline); }
.pricing-settings-groups {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.pricing-settings-group {
  min-width: 0;
  padding: 18px;
  border-right: 1px solid var(--hairline);
}
.pricing-settings-group:last-child { border-right: 0; }
.pricing-settings-group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 13px;
}
.pricing-settings-group-head strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}
.pricing-settings-group-head span {
  color: var(--steel);
  font-size: 11px;
}
.pricing-settings-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
.pricing-settings-grid-settlement { grid-template-columns: 1fr; }
.pricing-settings-grid label,
.pricing-logistics-form label {
  display: block;
  min-width: 0;
}
.pricing-settings-grid label > span,
.pricing-logistics-form label > span {
  display: block;
  margin-bottom: 5px;
  overflow: hidden;
  color: var(--slate);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-settings-grid .form-input,
.pricing-logistics-form .form-input {
  height: 38px;
  padding: 0 10px;
  border-radius: 6px;
  font-size: 13px;
}
.pricing-settings-actions {
  display: flex;
  justify-content: flex-end;
  padding: 12px 18px;
  border-top: 1px solid var(--hairline);
  background: var(--surface-soft);
}
.pricing-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 16px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}
.pricing-stats > div {
  min-width: 0;
  padding: 15px 18px;
  border-right: 1px solid var(--hairline);
}
.pricing-stats > div:last-child { border-right: 0; }
.pricing-stats span,
.pricing-stats strong { display: block; }
.pricing-stats span {
  margin-bottom: 4px;
  overflow: hidden;
  color: var(--slate);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-stats strong {
  color: var(--ink);
  font-size: 21px;
  font-weight: 650;
}
.pricing-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin: 22px 0 10px;
}
.pricing-section-heading > div { min-width: 0; }
.pricing-section-heading strong,
.pricing-section-heading > div > span { display: block; }
.pricing-section-heading strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 650;
}
.pricing-section-heading > div > span,
.pricing-section-mode {
  margin-top: 3px;
  color: var(--steel);
  font-size: 11px;
}
.pricing-section-mode { white-space: nowrap; }
.pricing-comparison-heading { margin-top: 24px; }
.pricing-table-shell {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}
.pricing-table {
  min-width: 1040px;
  table-layout: fixed;
}
.pricing-table th:nth-child(1) { width: 220px; }
.pricing-table th:nth-child(2) { width: 190px; }
.pricing-table th:nth-child(3) { width: 72px; }
.pricing-table th:nth-child(4) { width: 105px; }
.pricing-table th:nth-child(5),
.pricing-table th:nth-child(6) { width: 165px; }
.pricing-table th:nth-child(7) { width: 100px; }
.pricing-table td { vertical-align: middle; }
.pricing-option-group:last-child .pricing-main-row td { border-bottom: 0; }
.pricing-main-row td { height: 84px; }
.pricing-product-cell {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.pricing-product-image {
  position: relative;
  width: 48px;
  height: 48px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--surface);
}
.pricing-product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.pricing-product-image.image-unavailable::after,
.pricing-product-image:empty::after {
  content: '';
  position: absolute;
  inset: 15px;
  border: 1px solid var(--muted);
  border-radius: 3px;
}
.pricing-product-copy { min-width: 0; }
.pricing-product-copy strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.pricing-product-copy span {
  display: block;
  margin-top: 5px;
  color: var(--steel);
  font-size: 11px;
}
.pricing-supplier-cell { min-width: 0; }
.pricing-supplier-cell strong,
.pricing-supplier-cell small,
.pricing-supplier-cell a { display: block; }
.pricing-supplier-cell strong {
  overflow: hidden;
  color: var(--charcoal);
  font-size: 12px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-supplier-cell strong span {
  display: inline-block;
  margin-right: 6px;
  color: var(--primary);
  font-size: 11px;
}
.pricing-supplier-cell small {
  margin-top: 3px;
  overflow: hidden;
  color: var(--steel);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-supplier-cell a {
  margin-top: 5px;
  color: var(--link-blue);
  font-size: 11px;
  font-weight: 550;
  text-decoration: none;
}
.pricing-money {
  display: block;
  color: var(--ink);
  font-size: 14px;
  font-weight: 650;
  white-space: nowrap;
}
.pricing-secondary-money {
  display: block;
  margin-top: 3px;
  color: var(--steel);
  font-size: 11px;
  white-space: nowrap;
}
.pricing-scenario-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 3px 8px;
}
.pricing-scenario-cell > span {
  grid-column: 1 / -1;
  color: var(--steel);
  font-size: 11px;
}
.pricing-scenario-cell > strong {
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-scenario-cell > em {
  display: inline-flex;
  min-width: 46px;
  justify-content: center;
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--surface);
  color: var(--slate);
  font-size: 11px;
  font-style: normal;
  font-weight: 650;
}
.pricing-scenario-cell > em.is-positive { background: #e8f7ef; color: #087f5b; }
.pricing-scenario-cell > em.is-negative { background: #fef0f0; color: #b42318; }
.pricing-unavailable {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 3px 8px;
  border-radius: 5px;
  background: var(--surface);
  color: var(--slate);
  font-size: 11px;
}
.pricing-row-action { text-align: right; }
.pricing-detail-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-width: 94px;
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid var(--hairline-strong);
  border-radius: 6px;
  background: #fff;
  color: var(--charcoal);
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 550;
}
.pricing-detail-toggle:hover { border-color: #aeb3bd; background: var(--surface-soft); }
.pricing-detail-toggle svg { transition: transform 0.16s ease; }
.pricing-detail-toggle[aria-expanded='true'] svg { transform: rotate(180deg); }
.pricing-detail-row[hidden] { display: none; }
.pricing-detail-row > td {
  padding: 0 !important;
  border-bottom: 1px solid var(--hairline) !important;
  background: #fbfcfe !important;
}
.pricing-detail-panel { padding: 18px; }
.pricing-logistics-form {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) repeat(5, 94px) auto;
  align-items: end;
  gap: 10px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--hairline);
}
.pricing-logistics-heading { align-self: center; min-width: 0; }
.pricing-logistics-heading strong,
.pricing-logistics-heading span { display: block; }
.pricing-logistics-heading strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}
.pricing-logistics-heading span {
  margin-top: 3px;
  overflow: hidden;
  color: var(--steel);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-logistics-form .btn { height: 38px; }
.pricing-scenario-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.pricing-scenario-detail {
  min-width: 0;
  padding: 18px 18px 2px 0;
  border-right: 1px solid var(--hairline);
}
.pricing-scenario-detail + .pricing-scenario-detail {
  padding-right: 0;
  padding-left: 18px;
  border-right: 0;
}
.pricing-scenario-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  min-height: 43px;
}
.pricing-scenario-detail-head span,
.pricing-scenario-detail-head strong { display: block; }
.pricing-scenario-detail-head span {
  color: var(--ink);
  font-size: 14px;
  font-weight: 650;
}
.pricing-scenario-detail-head strong {
  margin-top: 2px;
  color: var(--steel);
  font-size: 10px;
  font-weight: 500;
}
.pricing-scenario-detail-head em {
  color: var(--slate);
  font-size: 11px;
  font-style: normal;
  white-space: nowrap;
}
.pricing-logistics-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin: 9px 0 13px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--hairline);
}
.pricing-logistics-metrics span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
  padding: 7px 9px;
  background: #fff;
  color: var(--steel);
  font-size: 10px;
}
.pricing-logistics-metrics strong {
  overflow: hidden;
  color: var(--charcoal);
  font-size: 10px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pricing-scenario-empty {
  min-height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed var(--hairline-strong);
  border-radius: 6px;
  color: var(--steel);
  font-size: 12px;
}
.pricing-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: var(--steel);
  font-size: 12px;
}
.pricing-pagination > div {
  display: flex;
  align-items: center;
  gap: 8px;
}
.pricing-page-count {
  min-width: 54px;
  color: var(--slate);
  text-align: center;
}

@media (max-width: 1100px) {
  .pricing-workbench-fields { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pricing-settings-groups { grid-template-columns: minmax(0, 1fr) minmax(190px, 0.55fr); }
  .pricing-settings-grid-settlement { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pricing-settings-group-settlement { grid-column: 1 / -1; }
  .pricing-settings-group:first-child {
    grid-column: 1 / -1;
    border-right: 0;
    border-bottom: 1px solid var(--hairline);
  }
  .pricing-logistics-form { grid-template-columns: repeat(5, minmax(82px, 1fr)) auto; }
  .pricing-logistics-heading { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  .pricing-workbench-head {
    align-items: stretch;
    flex-direction: column;
    gap: 9px;
  }
  .pricing-workbench-tabs { width: 100%; }
  .pricing-workbench-tabs button { flex: 1 1 0; }
  .pricing-workbench-head .pricing-settings-snapshot {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    overflow-x: auto;
  }
  .pricing-workbench-selectors { grid-template-columns: 1fr; }
  .pricing-workbench-save .btn { width: 100%; }
  .pricing-workbench-selection { grid-template-columns: 44px minmax(0, 1fr); }
  .pricing-workbench-selection-image { width: 44px; height: 44px; }
  .pricing-workbench-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-workbench-fields > div,
  .pricing-workbench-fields > label { min-height: 83px; }
  .pricing-workbench-fields > :last-child { grid-column: 1 / -1; }
  .pricing-settings-summary { grid-template-columns: minmax(0, 1fr) 18px; }
  .pricing-settings-snapshot { display: none; }
  .pricing-settings-groups { grid-template-columns: 1fr; }
  .pricing-settings-group,
  .pricing-settings-group:first-child {
    grid-column: auto;
    border-right: 0;
    border-bottom: 1px solid var(--hairline);
  }
  .pricing-settings-group:last-child { border-bottom: 0; }
  .pricing-settings-grid-settlement { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-stats > div:nth-child(2) { border-right: 0; }
  .pricing-stats > div:nth-child(-n+2) { border-bottom: 1px solid var(--hairline); }
  .pricing-stats strong { font-size: 18px; }
  .pricing-section-heading { align-items: flex-start; }
  .pricing-section-mode { display: none; }
  .pricing-table-shell {
    overflow: visible;
    border: 0;
    background: transparent;
  }
  .pricing-table,
  .pricing-table tbody,
  .pricing-table tr,
  .pricing-table td {
    display: block;
    width: 100%;
    min-width: 0;
  }
  .pricing-table { table-layout: auto; }
  .pricing-table thead { display: none; }
  .pricing-option-group {
    margin-bottom: 10px;
    overflow: hidden;
    border: 1px solid var(--hairline);
    border-radius: 8px;
    background: #fff;
  }
  .pricing-main-row {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .pricing-main-row td {
    height: auto;
    padding: 11px 12px;
    border-bottom: 0;
  }
  .pricing-main-row td:nth-child(1),
  .pricing-main-row td:nth-child(2),
  .pricing-main-row td:nth-child(7) { grid-column: 1 / -1; }
  .pricing-main-row td:nth-child(1),
  .pricing-main-row td:nth-child(2) { border-bottom: 1px solid var(--hairline); }
  .pricing-main-row td:nth-child(3),
  .pricing-main-row td:nth-child(4),
  .pricing-main-row td:nth-child(5),
  .pricing-main-row td:nth-child(6) { border-bottom: 1px solid var(--hairline); }
  .pricing-main-row td:nth-child(3),
  .pricing-main-row td:nth-child(5) { border-right: 1px solid var(--hairline); }
  .pricing-main-row td[data-label]::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 6px;
    color: var(--steel);
    font-size: 10px;
    font-weight: 500;
  }
  .pricing-product-cell { grid-template-columns: 44px minmax(0, 1fr); }
  .pricing-product-image { width: 44px; height: 44px; }
  .pricing-supplier-cell strong,
  .pricing-supplier-cell small { white-space: normal; }
  .pricing-row-action { text-align: left; }
  .pricing-detail-toggle { width: 100%; }
  .pricing-detail-row:not([hidden]) { display: block; }
  .pricing-detail-row > td { border-bottom: 0 !important; }
  .pricing-detail-panel { padding: 14px; }
  .pricing-logistics-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-logistics-heading { grid-column: 1 / -1; }
  .pricing-logistics-form .btn { width: 100%; }
  .pricing-scenario-detail-grid { grid-template-columns: 1fr; }
  .pricing-scenario-detail,
  .pricing-scenario-detail + .pricing-scenario-detail {
    padding: 16px 0;
    border-right: 0;
  }
  .pricing-scenario-detail:first-child { border-bottom: 1px solid var(--hairline); }
  .pricing-pagination { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 420px) {
  .pricing-settings-grid-settlement { grid-template-columns: 1fr; }
  .pricing-settings-actions .btn { width: 100%; }
  .pricing-logistics-form { grid-template-columns: 1fr; }
  .pricing-logistics-heading { grid-column: auto; }
  .pricing-stats > div { padding: 13px; }
}

/* ===== Pricing center A+ workbench ===== */
.pricing-page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.pricing-rules-toolbar {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}

.pricing-rule-group {
  min-width: 0;
  padding: 12px 14px;
  border-right: 1px solid var(--hairline);
}

.pricing-rule-group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 9px;
}

.pricing-rule-group-head strong {
  color: var(--ink);
  font-size: 11px;
  font-weight: 650;
}

.pricing-rule-group-head span {
  color: var(--steel);
  font-size: 9px;
}

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

.pricing-rule-fields label {
  display: block;
  min-width: 0;
}

.pricing-rule-fields label > span {
  display: block;
  margin-bottom: 4px;
  overflow: hidden;
  color: var(--slate);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-rule-fields label > div {
  display: flex;
  height: 30px;
  align-items: center;
  gap: 4px;
  padding: 0 7px;
  border: 1px solid var(--hairline-strong);
  border-radius: 5px;
  background: #fff;
}

.pricing-rule-fields input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 650;
}

.pricing-rule-fields i {
  flex: 0 0 auto;
  color: var(--steel);
  font-size: 8px;
  font-style: normal;
  white-space: nowrap;
}

.pricing-rules-action {
  display: flex;
  align-items: center;
  padding: 12px;
}

.pricing-rules-action .btn { white-space: nowrap; }

.pricing-workbench {
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}

.pricing-workbench-selectors {
  display: grid;
  grid-template-columns: minmax(140px, 0.55fr) minmax(240px, 1.35fr) minmax(190px, 0.75fr) auto;
  align-items: end;
  gap: 10px;
  padding: 13px 14px;
  border-bottom: 1px solid var(--hairline);
  background: var(--surface-soft);
}

.pricing-workbench-selectors label { min-width: 0; }

.pricing-workbench-selectors label > span {
  display: block;
  margin-bottom: 4px;
  color: var(--slate);
  font-size: 10px;
}

.pricing-workbench-selectors .form-select {
  width: 100%;
  height: 36px;
  border-radius: 6px;
  font-size: 12px;
}

.pricing-noscript-save { padding: 12px 14px; border-bottom: 1px solid var(--hairline); }

.pricing-unsaved-dialog {
  width: min(420px, calc(100vw - 32px));
  max-width: none;
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--hairline-strong);
  border-radius: 8px;
  background: #fff;
  color: var(--charcoal);
  box-shadow: 0 24px 70px rgba(17, 24, 39, 0.24);
}

.pricing-unsaved-dialog::backdrop { background: rgba(17, 24, 39, 0.38); }

.pricing-unsaved-dialog form { padding: 22px; }

.pricing-unsaved-dialog form > strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
}

.pricing-unsaved-dialog form > p {
  margin: 7px 0 18px;
  color: var(--slate);
  font-size: 12px;
  line-height: 1.55;
}

.pricing-unsaved-actions {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 8px;
}

.pricing-unsaved-actions .btn { min-width: 0; padding-right: 10px; padding-left: 10px; }

.pricing-workbench-selection {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 11px;
  min-height: 75px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--hairline);
}

.pricing-workbench-selection-image {
  position: relative;
  width: 54px;
  height: 54px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--surface);
}

.pricing-workbench-selection-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pricing-workbench-selection-image.image-unavailable::after {
  content: '';
  position: absolute;
  inset: 17px;
  border: 1px solid var(--muted);
  border-radius: 3px;
}

.pricing-workbench-selection-copy { min-width: 0; }

.pricing-workbench-selection-copy span,
.pricing-workbench-selection-copy strong,
.pricing-workbench-selection-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-workbench-selection-copy span {
  color: var(--steel);
  font-size: 9px;
}

.pricing-workbench-selection-copy strong {
  margin: 2px 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}

.pricing-workbench-selection-copy small {
  color: var(--slate);
  font-size: 10px;
}

.pricing-field-groups { background: #fff; }

.pricing-field-group + .pricing-field-group {
  border-top: 1px solid var(--hairline);
}

.pricing-field-group-head {
  display: flex;
  min-height: 42px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 13px;
  border-bottom: 1px solid var(--hairline);
  background: var(--surface-soft);
}

.pricing-field-group-title {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 8px;
}

.pricing-field-group-title > div { min-width: 0; }

.pricing-field-group-title strong,
.pricing-field-group-title span {
  display: block;
}

.pricing-field-group-title strong {
  color: var(--ink);
  font-size: 11px;
  font-weight: 650;
}

.pricing-field-group-title > div > span {
  margin-top: 1px;
  overflow: hidden;
  color: var(--steel);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-group-icon {
  display: grid !important;
  width: 25px;
  height: 25px;
  flex: 0 0 25px;
  place-items: center;
  border-radius: 5px;
  background: #fff;
  color: var(--primary);
  box-shadow: inset 0 0 0 1px var(--hairline);
}

.pricing-group-status {
  flex: 0 0 auto;
  color: #087f5b;
  font-size: 9px;
  font-weight: 650;
}

.pricing-dimensions-toggle {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  gap: 5px;
  padding: 5px 8px;
  border: 1px solid var(--hairline-strong);
  border-radius: 5px;
  background: #fff;
  color: var(--charcoal);
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 600;
}

.pricing-dimensions-toggle:hover { border-color: #aeb3bd; }

.pricing-dimensions-panel {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 9px;
  padding: 11px 13px;
  border-bottom: 1px solid var(--hairline);
  background: #fbfcfe;
}

.pricing-dimensions-panel[hidden] { display: none; }

.pricing-dimensions-panel label { min-width: 0; }

.pricing-dimensions-panel span {
  display: block;
  margin-bottom: 4px;
  color: var(--slate);
  font-size: 9px;
}

.pricing-dimensions-panel input,
.pricing-dimensions-panel select {
  width: 100%;
  height: 32px;
  min-width: 0;
  padding: 0 8px;
  border: 1px solid var(--hairline-strong);
  border-radius: 5px;
  outline: 0;
  background: #fff;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 11px;
}

.pricing-field-grid {
  display: grid;
  gap: 1px;
  background: var(--hairline);
}

.pricing-group-procurement .pricing-field-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.pricing-group-cost .pricing-field-grid,
.pricing-group-settlement .pricing-field-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.pricing-group-profit .pricing-field-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pricing-field {
  position: relative;
  display: block;
  min-width: 0;
  min-height: 92px;
  padding: 11px 12px;
  background: #fff;
}

.pricing-field-label {
  display: flex;
  min-height: 27px;
  align-items: flex-start;
  gap: 6px;
  color: var(--slate);
  font-size: 9px;
  line-height: 1.35;
}

.pricing-field-label b {
  display: inline-grid;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  place-items: center;
  border-radius: 4px;
  background: var(--surface);
  color: var(--primary);
  font-size: 9px;
  font-weight: 750;
}

.pricing-field-state {
  position: absolute;
  top: 8px;
  right: 8px;
  max-width: calc(100% - 95px);
  overflow: hidden;
  color: var(--steel);
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-field-control {
  display: flex;
  height: 34px;
  align-items: center;
  gap: 4px;
  margin-top: 5px;
  padding: 0 7px;
  border: 1px solid #cfd5df;
  border-radius: 5px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pricing-field-control:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(76, 83, 245, 0.09);
}

.pricing-field-control input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 700;
}

.pricing-field-control i {
  flex: 0 0 auto;
  color: var(--slate);
  font-size: 10px;
  font-style: normal;
  font-weight: 600;
}

.pricing-field-control button {
  display: inline-grid;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--primary);
  cursor: pointer;
}

.pricing-field-control button:hover { background: var(--primary-soft); }

.pricing-field-cost { background: #edf8fb; }
.pricing-field-settlement { background: #fff7ed; }
.pricing-field-profit { min-height: 98px; background: #eef9f2; }
.pricing-field-profit .pricing-field-control input { color: #087f5b; font-size: 18px; }
.pricing-field-profit.is-negative { background: #fef0f0; }
.pricing-field-profit.is-negative .pricing-field-control input { color: #b42318; }

.pricing-channel-field {
  grid-column: span 2;
  min-height: 108px;
}

.pricing-channel-control {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(100px, 0.55fr);
  gap: 7px;
  margin-top: 5px;
}

.pricing-channel-control > select {
  width: 100%;
  min-width: 0;
  height: 34px;
  padding: 0 7px;
  border: 1px solid #cfd5df;
  border-radius: 5px;
  outline: 0;
  background: #fff;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 10px;
}

.pricing-channel-control .pricing-field-control { margin-top: 0; }

[data-pricing-channel-summary] {
  display: block;
  min-height: 12px;
  margin-top: 5px;
  overflow: hidden;
  color: var(--slate);
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

[data-pricing-channel-summary].is-error { color: #b42318; }

.pricing-workbench-empty {
  padding: 42px 20px;
  color: var(--steel);
  text-align: center;
}

.pricing-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 16px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}

.pricing-stats > div {
  min-width: 0;
  padding: 12px 14px;
  border-right: 1px solid var(--hairline);
}

.pricing-stats > div:last-child { border-right: 0; }
.pricing-stats span,
.pricing-stats strong { display: block; }
.pricing-stats span { color: var(--steel); font-size: 9px; }
.pricing-stats strong { margin-top: 3px; color: var(--ink); font-size: 17px; font-weight: 650; }

.pricing-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin: 22px 0 9px;
}

.pricing-section-heading strong,
.pricing-section-heading span { display: block; }
.pricing-section-heading strong { color: var(--ink); font-size: 14px; font-weight: 650; }
.pricing-section-heading span { margin-top: 2px; color: var(--slate); font-size: 10px; }

.pricing-comparison-heading { align-items: center; }

.pricing-comparison-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.pricing-comparison-filter label {
  color: var(--steel);
  font-size: 10px;
  font-weight: 600;
}

.pricing-comparison-filter select {
  width: min(220px, 32vw);
  min-width: 150px;
  height: 34px;
  padding: 0 30px 0 10px;
  border: 1px solid #cfd5df;
  border-radius: 5px;
  outline: 0;
  background: #fff;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 11px;
}

.pricing-comparison-filter select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(76, 83, 245, 0.09);
}

.pricing-table-shell {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}

.pricing-table {
  min-width: 1080px;
  table-layout: fixed;
}

.pricing-table th:nth-child(1) { width: 225px; }
.pricing-table th:nth-child(2) { width: 190px; }
.pricing-table th:nth-child(3) { width: 148px; }
.pricing-table th:nth-child(4) { width: 120px; }
.pricing-table th:nth-child(5),
.pricing-table th:nth-child(6) { width: 170px; }
.pricing-table td { vertical-align: middle; }
.pricing-main-row td { height: 76px; }
.pricing-main-row:last-child td { border-bottom: 0; }

.pricing-product-cell {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.pricing-product-image {
  position: relative;
  width: 46px;
  height: 46px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--surface);
}

.pricing-product-image img { width: 100%; height: 100%; object-fit: cover; }
.pricing-product-image.image-unavailable::after,
.pricing-product-image:empty::after {
  content: '';
  position: absolute;
  inset: 14px;
  border: 1px solid var(--muted);
  border-radius: 3px;
}

.pricing-product-copy,
.pricing-supplier-cell { min-width: 0; }

.pricing-product-copy strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.pricing-product-copy span {
  display: block;
  margin-top: 4px;
  color: var(--steel);
  font-size: 10px;
}

.pricing-supplier-cell strong,
.pricing-supplier-cell small,
.pricing-supplier-cell a { display: block; }

.pricing-supplier-cell strong {
  overflow: hidden;
  color: var(--charcoal);
  font-size: 11px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-supplier-cell strong span {
  display: inline-block;
  margin-right: 6px;
  color: var(--primary);
  font-size: 10px;
}

.pricing-supplier-cell small {
  margin-top: 3px;
  overflow: hidden;
  color: var(--steel);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-supplier-cell a {
  margin-top: 4px;
  color: var(--link-blue);
  font-size: 10px;
  font-weight: 550;
  text-decoration: none;
}

.pricing-money { display: block; color: var(--ink); font-size: 14px; font-weight: 650; white-space: nowrap; }
.pricing-secondary-money { display: block; margin-top: 4px; color: var(--slate); font-size: 11px; line-height: 1.5; white-space: normal; overflow-wrap: anywhere; }
.pricing-table .supplier-quote-note { margin-top: 4px; font-size: 11px; line-height: 1.5; }

.pricing-scenario-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 3px 7px;
}

.pricing-scenario-cell > span { grid-column: 1 / -1; color: var(--steel); font-size: 10px; }
.pricing-scenario-cell > strong { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.pricing-scenario-cell > em {
  display: inline-flex;
  min-width: 44px;
  justify-content: center;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--surface);
  color: var(--slate);
  font-size: 10px;
  font-style: normal;
  font-weight: 650;
}

.pricing-scenario-cell > em.is-positive { background: #e8f7ef; color: #087f5b; }
.pricing-scenario-cell > em.is-negative { background: #fef0f0; color: #b42318; }

.pricing-unavailable {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 3px 8px;
  border-radius: 5px;
  background: var(--surface);
  color: var(--slate);
  font-size: 10px;
}

.pricing-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 13px;
  color: var(--steel);
  font-size: 11px;
}

.pricing-pagination > div { display: flex; align-items: center; gap: 8px; }
.pricing-page-count { min-width: 54px; color: var(--slate); text-align: center; }

@media (max-width: 1100px) {
  .pricing-rules-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-rule-group:nth-child(2) { border-right: 0; }
  .pricing-rule-group:nth-child(3),
  .pricing-rules-action { border-top: 1px solid var(--hairline); }
  .pricing-group-procurement .pricing-field-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pricing-channel-field { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  .pricing-page-head { align-items: stretch; flex-direction: column; }
  .pricing-page-head .btn { width: 100%; }
  .pricing-rules-toolbar { grid-template-columns: 1fr; }
  .pricing-rule-group,
  .pricing-rule-group:nth-child(2),
  .pricing-rule-group:nth-child(3) {
    border-right: 0;
    border-bottom: 1px solid var(--hairline);
  }
  .pricing-rule-group:nth-child(3) { border-top: 0; }
  .pricing-rules-action { justify-content: flex-end; border-top: 0; }
  .pricing-rules-action .btn { width: 100%; }
  .pricing-workbench-selectors { grid-template-columns: 1fr; }
  .pricing-workbench-selection { grid-template-columns: 48px minmax(0, 1fr); }
  .pricing-workbench-selection-image { width: 48px; height: 48px; }
  .pricing-field-group-head { align-items: flex-start; }
  .pricing-field-group-title > div > span { white-space: normal; }
  .pricing-group-status { display: none; }
  .pricing-dimensions-toggle span { display: none; }
  .pricing-dimensions-panel { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-group-procurement .pricing-field-grid,
  .pricing-group-cost .pricing-field-grid,
  .pricing-group-settlement .pricing-field-grid,
  .pricing-group-profit .pricing-field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .pricing-group-procurement [data-pricing-code='G'],
  .pricing-group-cost [data-pricing-code='K'] {
    grid-column: 1 / -1;
  }
  .pricing-channel-field { grid-column: 1 / -1; }
  .pricing-field-state { display: none; }
  .pricing-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-stats > div:nth-child(2) { border-right: 0; }
  .pricing-stats > div:nth-child(-n+2) { border-bottom: 1px solid var(--hairline); }
  .pricing-comparison-heading { align-items: stretch; flex-direction: column; }
  .pricing-comparison-filter {
    align-items: stretch;
    flex-direction: column;
    width: 100%;
  }
  .pricing-comparison-filter select { width: 100%; min-width: 0; }
  .pricing-table-shell { overflow: visible; border: 0; background: transparent; }
  .pricing-table,
  .pricing-table tbody,
  .pricing-table tr,
  .pricing-table td { display: block; width: 100%; min-width: 0; }
  .pricing-table { table-layout: auto; }
  .pricing-table thead { display: none; }
  .pricing-main-row {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 10px;
    overflow: hidden;
    border: 1px solid var(--hairline);
    border-radius: 8px;
    background: #fff;
  }
  .pricing-main-row td { height: auto; padding: 11px 12px; border-bottom: 0; }
  .pricing-main-row td:nth-child(1),
  .pricing-main-row td:nth-child(2) { grid-column: 1 / -1; border-bottom: 1px solid var(--hairline); }
  .pricing-main-row td:nth-child(3),
  .pricing-main-row td:nth-child(4),
  .pricing-main-row td:nth-child(5),
  .pricing-main-row td:nth-child(6) { border-bottom: 1px solid var(--hairline); }
  .pricing-main-row td:nth-child(3),
  .pricing-main-row td:nth-child(5) { border-right: 1px solid var(--hairline); }
  .pricing-main-row td[data-label]::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 6px;
    color: var(--steel);
    font-size: 9px;
  }
  .pricing-product-cell { grid-template-columns: 44px minmax(0, 1fr); }
  .pricing-product-image { width: 44px; height: 44px; }
  .pricing-supplier-cell strong,
  .pricing-supplier-cell small { white-space: normal; }
  .pricing-pagination { align-items: flex-start; flex-direction: column; }
  .pricing-unsaved-actions { grid-template-columns: 1fr; }
  .pricing-unsaved-actions .btn { width: 100%; }
}

@media (max-width: 420px) {
  .pricing-rule-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-rule-fields label:last-child { grid-column: 1 / -1; }
  .pricing-channel-control { grid-template-columns: 1fr; }
  .pricing-field { min-height: 98px; padding: 10px; }
  .pricing-field-label { min-height: 31px; }
  .pricing-field-control input { font-size: 14px; }
  .pricing-stats > div { padding: 11px; }
}

/* ===== Pricing editor — core inputs first, results at the side ===== */
.pricing-editor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 280px);
  gap: 12px;
  padding: 12px;
  background: #f6f8fb;
  letter-spacing: 0;
}

.pricing-editor-main,
.pricing-profit-panel {
  min-width: 0;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}

.pricing-editor-main { overflow: hidden; }

.pricing-editor-heading {
  display: flex;
  min-height: 62px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 15px;
  border-bottom: 1px solid var(--hairline);
  background: #fff;
}

.pricing-editor-heading-copy,
.pricing-editor-heading-actions { min-width: 0; }

.pricing-editor-heading-copy strong,
.pricing-editor-heading-copy span,
.pricing-editor-heading-actions > span { display: block; }

.pricing-editor-heading-copy strong {
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
}

.pricing-editor-heading-copy span {
  margin-top: 3px;
  color: var(--slate);
  font-size: 11px;
}

.pricing-editor-heading-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pricing-editor-heading-actions > span {
  color: var(--steel);
  font-size: 10px;
  white-space: nowrap;
}

.pricing-input-section {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr);
  border-top: 1px solid var(--hairline);
}

.pricing-input-section:first-of-type { border-top: 0; }

.pricing-input-section-head {
  display: block;
  min-width: 0;
  padding: 15px 10px 12px 13px;
  border-right: 1px solid var(--hairline);
  background: #fbfcfe;
}

.pricing-input-section-head > b {
  display: inline-grid;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  place-items: center;
  border-radius: 5px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 10px;
  font-weight: 750;
  margin-bottom: 9px;
}

.pricing-input-section-head > div { min-width: 0; }
.pricing-input-section-head strong,
.pricing-input-section-head span { display: block; }
.pricing-input-section-head strong { color: var(--ink); font-size: 13px; font-weight: 700; }
.pricing-input-section-head span {
  margin-top: 4px;
  color: var(--steel);
  font-size: 10px;
  line-height: 1.5;
  word-break: keep-all;
}

.pricing-core-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 12px;
}

.pricing-logistics-grid { grid-template-columns: minmax(180px, 0.75fr) minmax(300px, 1.25fr); }
.pricing-core-field { min-width: 0; }
.pricing-core-channel-field { min-width: 0; }
.pricing-core-field-secondary { opacity: 0.88; }

.pricing-field {
  position: relative;
  display: block;
  min-width: 0;
  min-height: 86px;
  padding: 10px 11px;
  border: 1px solid #dbe1ea;
  border-radius: 7px;
  background: #fff;
  letter-spacing: 0;
}

.pricing-field-manual { background: #fff; }
.pricing-field-auto { border-color: #e5e9ef; background: #f8fafc; }
.pricing-field-readonly { border-color: #bfd8ce; background: #f3faf7; }
.pricing-field-manual .pricing-field-label { color: var(--ink); }
.pricing-field-auto .pricing-field-label { color: var(--charcoal); }
.pricing-field-readonly .pricing-field-label { color: #176b4d; }
.pricing-field-readonly .pricing-field-label b { background: #dff3e9; color: #176b4d; }

.pricing-field-label {
  display: flex;
  min-height: 21px;
  align-items: flex-start;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.35;
}

.pricing-field-label b {
  display: inline-grid;
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  place-items: center;
  border-radius: 5px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 10px;
  font-weight: 750;
}

.pricing-field-state {
  position: static;
  display: block;
  max-width: 100%;
  margin: 3px 0 0 27px;
  overflow: hidden;
  color: var(--steel);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-field-auto .pricing-field-state { color: #8a94a3; }
.pricing-field-lock-state { color: #2d7a5d; }

.pricing-field-control {
  display: flex;
  height: 44px;
  align-items: center;
  gap: 5px;
  margin-top: 7px;
  padding: 0 9px;
  border: 1px solid #c9d1dd;
  border-radius: 6px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pricing-field-control:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(76, 83, 245, 0.1);
}

.pricing-field-control input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 20px;
  font-weight: 720;
  letter-spacing: 0;
}

.pricing-field-auto .pricing-field-control { border-color: #d7dde6; background: #fff; }
.pricing-field-readonly .pricing-field-control { border-color: #c9ded5; background: #eaf6f0; box-shadow: none; }
.pricing-field-readonly .pricing-field-control:focus-within { border-color: #c9ded5; box-shadow: none; }
.pricing-field-readonly .pricing-field-control input { color: #176b4d; cursor: not-allowed; }
.pricing-official-reference .pricing-field-state { margin-left: 0; }
.pricing-official-reference output {
  min-width: 0;
  color: #176b4d;
  font-size: 20px;
  font-weight: 720;
}
.pricing-field-control i { flex: 0 0 auto; color: var(--slate); font-size: 11px; font-style: normal; font-weight: 650; }

.tiktok-price-cell {
  display: flex;
  min-width: 138px;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
}

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

.tiktok-price-line {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.tiktok-price-line > strong { color: var(--ink); font-size: 14px; }

.tiktok-detail-link {
  display: inline-grid;
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  place-items: center;
  border: 1px solid #d8dbe6;
  border-radius: 5px;
  color: var(--primary);
  background: #fff;
}

.tiktok-detail-link[hidden] { display: none; }

.tiktok-detail-link:hover { border-color: var(--primary); background: #f5f6ff; }
.tiktok-detail-link:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.tiktok-price-source,
.tiktok-price-range,
.tiktok-sync-status {
  display: block;
  color: var(--steel);
  font-size: 11px;
  line-height: 1.45;
  white-space: normal;
  overflow-wrap: anywhere;
}
.tiktok-price-source:empty { display: none; }
.tiktok-price-source[hidden],
.tiktok-price-range[hidden],
.tiktok-sync-status[hidden] { display: none; }
.tiktok-sync-status[data-state='success'] { color: var(--success); }
.tiktok-sync-status[data-state='failed'] { color: var(--warning); }
.tiktok-detail-link[aria-busy='true'] { opacity: .6; }

.pricing-reference-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.pricing-tiktok-link {
  width: 22px;
  height: 22px;
  flex-basis: 22px;
  margin-left: auto;
}

.pricing-field-control button {
  display: inline-grid;
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--primary);
  cursor: pointer;
}

.pricing-field-control button:hover { background: var(--primary-soft); }
.pricing-core-field-secondary .pricing-field { background: #fbfcfd; }
.pricing-field-cost,
.pricing-field-settlement { background: #f7f9fb; }
.pricing-field-profit { min-height: 104px; border-color: #c7e5d3; background: #eef9f2; }
.pricing-field-profit .pricing-field-control input { color: #087f5b; font-size: 22px; }
.pricing-field-profit.is-negative { border-color: #efc1c1; background: #fef0f0; }
.pricing-field-profit.is-negative .pricing-field-control input { color: #b42318; }

.pricing-channel-field {
  min-height: 116px;
  border-color: #d7dde6;
}

.pricing-channel-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(150px, 0.8fr);
  gap: 8px;
  margin-top: 7px;
}

.pricing-channel-control > select {
  width: 100%;
  min-width: 0;
  height: 44px;
  padding: 0 9px;
  border: 1px solid #c9d1dd;
  border-radius: 6px;
  outline: 0;
  background: #fff;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 11px;
}

.pricing-channel-control > select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(76, 83, 245, 0.1); }
.pricing-channel-control .pricing-field-control {
  min-width: 0;
  margin-top: 0;
  padding-right: 7px;
  padding-left: 7px;
}

.pricing-channel-control .pricing-field-control input {
  min-width: 0;
  font-size: 18px;
}

[data-pricing-channel-summary] {
  display: block;
  min-height: 13px;
  margin-top: 5px;
  overflow: hidden;
  color: var(--slate);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

[data-pricing-channel-summary].is-error { color: #b42318; }

.pricing-system-results {
  margin: 12px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: #fff;
}

.pricing-system-results-head {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--hairline);
  background: #fbfcfe;
}

.pricing-system-results-head strong,
.pricing-system-results-head span { display: block; }
.pricing-system-results-head strong { color: var(--ink); font-size: 13px; font-weight: 700; }
.pricing-system-results-head div > span { margin-top: 2px; color: var(--steel); font-size: 10px; }
.pricing-system-results-head > span { color: var(--primary); font-size: 10px; font-weight: 650; white-space: nowrap; }

.pricing-system-results-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  background: var(--hairline);
}

.pricing-system-results-grid .pricing-field {
  min-height: 78px;
  border: 0;
  border-radius: 0;
  background: #f8fafc;
}

.pricing-system-results-grid .pricing-field-label { color: var(--slate); font-size: 11px; }
.pricing-system-results-grid .pricing-field-label b { width: 18px; height: 18px; flex-basis: 18px; background: #eef1f5; color: var(--slate); font-size: 9px; }
.pricing-system-results-grid .pricing-field-state { font-size: 9px; }
.pricing-system-results-grid .pricing-field-control { height: 36px; margin-top: 5px; padding: 0 7px; border-color: #d8dee7; }
.pricing-system-results-grid .pricing-field-control input { font-size: 17px; }

.pricing-editor-sidebar {
  position: sticky;
  top: 12px;
  display: grid;
  min-width: 0;
  align-self: start;
  gap: 12px;
}

.pricing-profit-panel {
  position: static;
  overflow: hidden;
}

.pricing-profit-panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 16px;
  border-bottom: 1px solid var(--hairline);
}

.pricing-profit-panel-head strong { color: var(--ink); font-size: 16px; font-weight: 750; }
.pricing-profit-panel-head span { color: var(--steel); font-size: 10px; white-space: nowrap; }

.pricing-profit-cost {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 16px;
  border-bottom: 1px solid var(--hairline);
  background: #f7f9fb;
}

.pricing-profit-cost span { color: var(--slate); font-size: 11px; }
.pricing-profit-cost span small {
  display: block;
  margin-top: 3px;
  color: var(--steel);
  font-size: 9px;
}
.pricing-profit-cost strong { color: var(--ink); font-size: 23px; font-weight: 750; white-space: nowrap; }
.pricing-profit-total-cost { background: #eef2ff; }
.pricing-profit-fields { display: grid; grid-template-columns: 1fr; gap: 10px; padding: 12px; }
.pricing-selling-card {
  border: 1px solid #cfd3ff;
  border-radius: 7px;
  background: #f8f8ff;
}

.pricing-selling-strip {
  margin: 0 12px 12px;
  overflow: hidden;
  box-shadow: none;
}

.pricing-selling-card-head {
  padding: 11px 12px;
  border-bottom: 1px solid #dfe2ff;
  background: #f5f5ff;
}

.pricing-selling-card-head strong,
.pricing-selling-card-head span { display: block; }

.pricing-selling-card-head strong { color: var(--ink); font-size: 14px; }
.pricing-selling-card-head span { margin-top: 2px; color: var(--steel); font-size: 10px; }

.pricing-selling-strip-body {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: #dfe2ff;
}

.pricing-selling-strip-body > * {
  min-width: 0;
  margin: 0;
  padding: 12px;
  border-radius: 0;
  background: #f8f8ff;
}

.pricing-selling-reference,
.pricing-selling-delta {
  display: flex;
  min-height: 110px;
  align-items: flex-start;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
}

.pricing-selling-reference span,
.pricing-selling-delta span { color: var(--slate); font-size: 10px; }

.pricing-selling-reference strong { color: var(--ink); font-size: 22px; }
.pricing-selling-delta strong { color: var(--primary); font-size: 16px; }
.pricing-selling-input-wrap { min-width: 0; }
.pricing-selling-input-wrap .pricing-field {
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.pricing-selling-field { border-color: #9ca5ff; background: #fff; }
.pricing-selling-field .pricing-field-control input { color: var(--primary); font-size: 24px; }
.pricing-selling-field .pricing-field-control button:disabled { color: #aab1bd; cursor: not-allowed; }
.pricing-selling-field .pricing-field-control button:disabled:hover { background: transparent; }

.pricing-profit-actions { display: grid; gap: 10px; padding: 0 2px 2px; border-top: 0; }
.pricing-profit-actions > span { min-height: 16px; color: var(--steel); font-size: 10px; }
.pricing-profit-actions .btn { width: 100%; }

@media (max-width: 1100px) {
  .pricing-editor-layout { grid-template-columns: 1fr; }
  .pricing-editor-sidebar { position: static; }
  .pricing-system-results-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .pricing-system-results-grid .pricing-field { grid-column: span 2; }
  .pricing-system-results-grid .pricing-field:nth-child(n + 4) { grid-column: span 3; }
  .pricing-profit-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 768px) {
  .pricing-editor-layout { grid-template-columns: 1fr; padding: 8px; }
  .pricing-input-section { grid-template-columns: 1fr; }
  .pricing-input-section-head { display: flex; align-items: center; gap: 8px; border-right: 0; border-bottom: 1px solid var(--hairline); padding: 11px 12px; }
  .pricing-input-section-head > b { margin-bottom: 0; }
  .pricing-core-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-logistics-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-core-channel-field { grid-column: 1 / -1; }
  .pricing-system-results-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-system-results-grid .pricing-field,
  .pricing-system-results-grid .pricing-field:nth-child(n + 4) { grid-column: auto; }
  .pricing-system-results-grid .pricing-field:last-child { grid-column: 1 / -1; }
  .pricing-profit-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pricing-profit-actions .btn { width: 100%; }
}

@media (max-width: 520px) {
  .pricing-editor-heading { align-items: flex-start; flex-direction: column; gap: 10px; }
  .pricing-editor-heading-actions { width: 100%; justify-content: space-between; }
  .pricing-editor-heading-actions .pricing-dimensions-toggle { flex: 0 0 auto; }
  .pricing-core-grid,
  .pricing-logistics-grid,
  .pricing-profit-fields { grid-template-columns: 1fr; }
  .pricing-channel-control { grid-template-columns: 1fr; }
  .pricing-core-channel-field { grid-column: auto; }
  .pricing-core-field .pricing-field-label { font-size: 12px; }
  .pricing-core-field .pricing-field-control input { font-size: 18px; }
  .pricing-system-results-grid .pricing-field-control input { font-size: 16px; }
  .pricing-profit-cost { align-items: flex-start; flex-direction: column; gap: 4px; }
  .pricing-selling-strip { margin: 0 8px 8px; }
  .pricing-selling-strip-body { grid-template-columns: 1fr; }
  .pricing-selling-strip-body > * { padding: 11px; }
  .pricing-selling-reference,
  .pricing-selling-delta { min-height: 78px; }
}

/* Comparison supplier decision and My Library */
.comparison-filter-bar {
  display: flex;
  align-items: end;
  gap: 10px;
  margin: 18px 0 14px;
  padding: 12px 14px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: #fff;
}

.comparison-category-filter { width: min(320px, 100%); margin: 0; }
.comparison-results-shell {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
}
.comparison-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 48px;
  padding: 0 16px;
  border-bottom: 1px solid var(--hairline);
  background: #fbfcfe;
}
.comparison-results-header > div { min-width: 0; }
.comparison-results-header strong {
  display: block;
  margin-top: 2px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 650;
}
.comparison-results-kicker,
.comparison-results-count,
.comparison-zone-label {
  color: var(--steel);
  font-size: 10px;
  font-weight: 600;
}
.comparison-results-count { flex: 0 0 auto; color: var(--slate); }
.comparison-results-list { min-width: 0; }
.comparison-row {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(180px, 1fr) 118px 126px;
  gap: 16px;
  align-items: center;
  min-width: 0;
  min-height: 86px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--hairline);
  background: #fff;
}
.comparison-row:last-child { border-bottom: 0; }
.comparison-row > * { min-width: 0; }
.comparison-source-zone {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
}
.comparison-results-list .comparison-product-cell {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.comparison-product-image {
  position: relative;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: #f7f8fa;
}
.comparison-product-image img { width: 100%; height: 100%; object-fit: cover; }
.comparison-image-fallback {
  display: none;
  color: var(--steel);
  font-size: 9px;
  text-align: center;
}
.comparison-product-image.is-empty .comparison-image-fallback { display: block; }
.comparison-product-copy { min-width: 0; }
.comparison-results-list .comparison-title {
  max-width: none;
  overflow: hidden;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.comparison-product-meta,
.comparison-supplier-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  margin-top: 5px;
  overflow: hidden;
  color: var(--steel);
  font-size: 10px;
  line-height: 1.3;
}
.comparison-product-meta span,
.comparison-supplier-meta span { min-width: 0; }
.comparison-source-metrics {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}
.comparison-source-metrics > div { min-width: 0; }
.comparison-source-metrics span {
  display: block;
  color: var(--steel);
  font-size: 9px;
  line-height: 1.3;
  white-space: nowrap;
}
.comparison-source-metrics strong {
  display: block;
  margin-top: 4px;
  overflow: hidden;
  color: var(--ink);
  font-size: 12px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.comparison-source-metrics > div:first-child strong {
  overflow-wrap: anywhere;
  text-overflow: clip;
  white-space: normal;
}
.comparison-supplier-zone,
.comparison-cost-zone,
.comparison-row-action { min-width: 0; }
.comparison-supplier-shop,
.comparison-supplier-title,
.comparison-cost-note {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.comparison-supplier-shop {
  margin-top: 5px;
  color: var(--charcoal);
  font-size: 11px;
  font-weight: 650;
}
.comparison-supplier-title {
  margin-top: 3px;
  color: var(--slate);
  font-size: 10px;
  line-height: 1.35;
}
.comparison-no-result {
  margin-top: 5px;
  color: var(--steel);
  font-size: 11px;
}
.comparison-cost-zone {
  padding-left: 16px;
  border-left: 1px solid var(--hairline);
}
.comparison-purchase-price {
  display: block;
  margin-top: 5px;
  color: var(--ink);
  font-size: 16px;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
}
.comparison-purchase-price.is-empty { color: var(--steel); }
.comparison-cost-note {
  display: block;
  margin-top: 4px;
  color: var(--steel);
  font-size: 9px;
}
.comparison-row-action {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 9px;
}
.comparison-status-line {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--slate);
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
}
.comparison-status-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: var(--steel);
}
.comparison-status-dot.is-complete { background: var(--success); }
.comparison-status-dot.is-partial { background: var(--warning); }
.comparison-row-action-button { width: 100%; }
.comparison-empty-state { margin: 0; border: 0; border-radius: 0; }

@media (max-width: 1080px) {
  .comparison-row {
    grid-template-columns: minmax(0, 1.55fr) minmax(170px, 0.95fr) 108px 116px;
    gap: 12px;
    padding-right: 12px;
    padding-left: 12px;
  }
  .comparison-source-zone { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .comparison-source-metrics { min-width: 0; }
  .comparison-cost-zone { padding-left: 12px; }
}

@media (max-width: 860px) {
  .comparison-row {
    grid-template-columns: minmax(0, 1fr) 118px;
    gap: 12px;
  }
  .comparison-source-zone { grid-column: 1 / -1; }
  .comparison-supplier-zone { grid-column: 1; }
  .comparison-cost-zone { grid-column: 2; }
  .comparison-row-action {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding-top: 10px;
    border-top: 1px solid var(--hairline);
  }
  .comparison-row-action-button { width: auto; min-width: 108px; }
}

.supplier-selection-form { display: grid; gap: 12px; }
.supplier-choice-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
}
.supplier-choice-control input { width: 16px; height: 16px; accent-color: var(--primary); }
.supplier-selection-submit {
  display: flex;
  justify-content: flex-end;
  padding-top: 2px;
}

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

.library-notice {
  margin-top: 16px;
  padding: 10px 13px;
  border: 1px solid #b7e4cc;
  border-radius: 6px;
  background: #effaf4;
  color: #087f5b;
  font-size: 12px;
  font-weight: 600;
}

.library-notice-error { border-color: #f4c7c7; background: #fff5f5; color: #b42318; }

.library-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-top: 18px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: #fff;
}

.library-summary > div {
  min-width: 0;
  padding: 14px 16px;
  border-right: 1px solid var(--hairline);
}
.library-summary > div:last-child { border-right: 0; }
.library-summary span,
.library-primary-metrics span,
.library-sales-totals span {
  display: block;
  color: var(--steel);
  font-size: 10px;
  line-height: 1.35;
}
.library-summary strong {
  display: block;
  margin-top: 5px;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.1;
}

.library-filter-bar {
  display: flex;
  align-items: end;
  gap: 10px;
  margin: 14px 0;
  padding: 12px 14px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: #fbfcfe;
}
.library-filter-bar .form-group { width: 220px; margin: 0; }

.library-list { display: grid; gap: 10px; }
.library-item {
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 3px 14px rgba(29, 41, 57, 0.04);
}
.library-item-main {
  display: grid;
  grid-template-columns: minmax(340px, 1.8fr) minmax(360px, 1fr) 118px;
  align-items: center;
  gap: 20px;
  min-height: 96px;
  padding: 14px 16px;
}
.library-product-identity {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.library-image-frame {
  display: grid;
  width: 68px;
  height: 68px;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: #f7f8fa;
}
.library-image-frame img { width: 100%; height: 100%; object-fit: cover; }
.library-image-fallback { padding: 6px; color: var(--steel); font-size: 10px; text-align: center; }
.library-product-copy { min-width: 0; }
.library-supplier-title {
  overflow: hidden;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.library-source-title {
  margin-top: 4px;
  overflow: hidden;
  color: var(--steel);
  font-size: 11px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.library-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 8px;
  color: var(--slate);
  font-size: 10px;
}
.library-meta-line a { color: var(--primary); font-weight: 650; }
.library-primary-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  min-width: 0;
}
.library-primary-metrics > div {
  min-width: 0;
  padding: 2px 12px;
  border-left: 1px solid var(--hairline);
}
.library-primary-metrics strong {
  display: block;
  margin-top: 5px;
  overflow: hidden;
  color: var(--ink);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.library-primary-metrics strong.negative { color: #b42318; }
.library-status-form { margin: 0; }
.library-status-form select { min-width: 0; width: 100%; font-size: 11px; }

.library-details { border-top: 1px solid var(--hairline); }
.library-details > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: #fbfcfe;
  color: var(--slate);
  font-size: 11px;
  font-weight: 650;
  cursor: pointer;
  list-style: none;
}
.library-details > summary::-webkit-details-marker { display: none; }
.library-details > summary::before {
  content: '+';
  display: inline-grid;
  width: 18px;
  height: 18px;
  margin-right: 8px;
  place-items: center;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  color: var(--primary);
}
.library-details[open] > summary::before { content: '−'; }
.library-details-summary { margin-left: auto; color: var(--steel); font-weight: 500; }
.library-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(360px, 0.75fr);
  gap: 0;
  border-top: 1px solid var(--hairline);
}
.library-pricing-detail,
.library-sales-panel,
.library-trend-panel { padding: 18px; }
.library-pricing-detail { border-right: 1px solid var(--hairline); }
.library-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 13px;
}
.library-section-head h2 { margin: 0; color: var(--ink); font-size: 14px; line-height: 1.3; }
.library-section-head p { margin: 3px 0 0; color: var(--steel); font-size: 10px; }
.library-pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
}
.library-pricing-grid > div {
  min-width: 0;
  min-height: 62px;
  padding: 10px 11px;
  border-right: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  background: #fff;
}
.library-pricing-grid > div:nth-child(3n) { border-right: 0; }
.library-pricing-grid > div:nth-last-child(-n+3) { border-bottom: 0; }
.library-pricing-grid span { display: block; color: var(--steel); font-size: 9px; line-height: 1.35; }
.library-pricing-grid strong { display: block; margin-top: 7px; color: var(--ink); font-size: 13px; }
.library-pricing-grid .library-profit-field { background: #f0faf5; }
.library-pricing-grid .library-profit-field strong { color: #087f5b; }
.library-inline-empty { padding: 24px; border: 1px dashed var(--hairline); color: var(--steel); text-align: center; }

.library-sales-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}
.library-sales-form .form-group { margin: 0; }
.library-sales-form .btn { align-self: end; min-height: 38px; }
.library-sales-totals {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 13px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
}
.library-sales-totals > div { padding: 10px 11px; border-right: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.library-sales-totals > div:nth-child(2n) { border-right: 0; }
.library-sales-totals > div:nth-last-child(-n+2) { border-bottom: 0; }
.library-sales-totals strong { display: block; margin-top: 4px; color: var(--ink); font-size: 13px; }

.library-trend-panel { border-top: 1px solid var(--hairline); }
.library-trend-switch { display: inline-flex; border: 1px solid var(--hairline); border-radius: 6px; overflow: hidden; }
.library-trend-switch button {
  min-width: 52px;
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-right: 1px solid var(--hairline);
  background: #fff;
  color: var(--slate);
  font: inherit;
  font-size: 10px;
  cursor: pointer;
}
.library-trend-switch button:last-child { border-right: 0; }
.library-trend-switch button.active { background: #eef2ff; color: #3f46c8; font-weight: 700; }
.library-chart {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: #fff;
}
.library-chart svg { display: block; width: 100%; height: 220px; }
.library-chart-empty { display: grid; min-height: 218px; place-items: center; color: var(--steel); font-size: 11px; }
.library-chart-empty[hidden] { display: none; }
.library-chart-grid { stroke: #e8ebf0; stroke-width: 1; }
.library-chart-axis { fill: #7b8494; font-size: 9px; }
.library-chart-line { fill: none; stroke: #4c53f5; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.library-chart-dot { fill: #fff; stroke: #4c53f5; stroke-width: 2.5; }
.library-sales-history-wrap { margin-top: 13px; overflow-x: auto; }
.library-sales-history { min-width: 700px; }
.library-sales-history th,
.library-sales-history td { padding: 8px 10px; font-size: 10px; }
.icon-button {
  display: inline-grid;
  width: 28px;
  height: 28px;
  padding: 0;
  place-items: center;
  border: 1px solid var(--hairline);
  border-radius: 5px;
  background: #fff;
  color: var(--slate);
  cursor: pointer;
}
.icon-button.danger:hover { border-color: #e8a6a6; color: #b42318; }
.library-empty-state {
  padding: 56px 24px;
  border: 1px dashed var(--hairline);
  border-radius: 8px;
  background: #fff;
  text-align: center;
}
.library-empty-state h2 { margin: 0; color: var(--ink); font-size: 18px; }
.library-empty-state p { margin: 8px 0 18px; color: var(--steel); font-size: 12px; }

@media (max-width: 1280px) {
  .library-item-main { grid-template-columns: minmax(300px, 1.4fr) minmax(320px, 1fr) 112px; gap: 12px; }
  .library-primary-metrics > div { padding: 2px 8px; }
  .library-detail-layout { grid-template-columns: 1fr; }
  .library-pricing-detail { border-right: 0; border-bottom: 1px solid var(--hairline); }
}

@media (max-width: 900px) {
  .library-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .library-summary > div:nth-child(3) { border-right: 0; }
  .library-summary > div:nth-child(-n+3) { border-bottom: 1px solid var(--hairline); }
  .library-item-main { grid-template-columns: 1fr 116px; }
  .library-primary-metrics { grid-column: 1 / -1; grid-row: 2; }
  .library-status-form { grid-column: 2; grid-row: 1; }
}

@media (max-width: 680px) {
  .comparison-filter-bar,
  .library-heading,
  .library-filter-bar { align-items: stretch; flex-direction: column; }
  .comparison-category-filter,
  .library-filter-bar .form-group { width: 100%; }
  .library-heading .btn,
  .comparison-filter-bar .btn,
  .library-filter-bar .btn,
  .supplier-selection-submit .btn { width: 100%; }
  .comparison-results-header { min-height: 44px; padding: 0 12px; }
  .comparison-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    min-height: 0;
    padding: 13px 12px;
  }
  .comparison-source-zone {
    grid-column: 1 / -1;
    grid-template-columns: minmax(0, 1fr);
    gap: 11px;
  }
  .comparison-source-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding-top: 10px;
    border-top: 1px solid var(--hairline);
  }
  .comparison-supplier-zone {
    grid-column: 1;
    padding-top: 10px;
    border-top: 1px solid var(--hairline);
  }
  .comparison-cost-zone {
    grid-column: 2;
    min-width: 108px;
    padding-top: 10px;
    padding-left: 12px;
    border-top: 1px solid var(--hairline);
    border-left: 1px solid var(--hairline);
  }
  .comparison-row-action {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding-top: 10px;
    border-top: 1px solid var(--hairline);
  }
  .comparison-row-action-button { width: auto; min-width: 108px; }
  .library-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .library-summary > div,
  .library-summary > div:nth-child(3) { border-right: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
  .library-summary > div:nth-child(2n) { border-right: 0; }
  .library-summary > div:last-child { grid-column: 1 / -1; border-right: 0; border-bottom: 0; }
  .library-item-main { grid-template-columns: 1fr; align-items: stretch; }
  .library-status-form { grid-column: 1; grid-row: auto; }
  .library-primary-metrics { grid-column: 1; grid-row: auto; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--hairline); }
  .library-primary-metrics > div { padding: 10px; border-bottom: 1px solid var(--hairline); }
  .library-primary-metrics > div:nth-child(odd) { border-left: 0; }
  .library-primary-metrics > div:nth-last-child(-n+2) { border-bottom: 0; }
  .library-details > summary { align-items: flex-start; }
  .library-details-summary { display: none; }
  .library-pricing-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .library-pricing-grid > div,
  .library-pricing-grid > div:nth-child(3n) { border-right: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
  .library-pricing-grid > div:nth-child(2n) { border-right: 0; }
  .library-pricing-grid > div:nth-last-child(-n+3) { border-bottom: 1px solid var(--hairline); }
  .library-pricing-grid > div:last-child { border-bottom: 0; }
  .library-sales-form { grid-template-columns: 1fr; }
  .library-section-head { align-items: stretch; flex-direction: column; }
  .library-section-head .btn { width: 100%; }
  .library-trend-panel,
  .library-pricing-detail,
  .library-sales-panel { padding: 14px; }
  .library-chart { min-height: 190px; }
  .library-chart svg { height: 190px; }
}

@media (max-width: 420px) {
  .comparison-results-list .comparison-product-cell {
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 9px;
  }
  .comparison-product-image { width: 44px; height: 44px; }
  .comparison-source-metrics span { font-size: 8px; }
  .comparison-source-metrics strong { font-size: 11px; }
  .comparison-purchase-price { font-size: 15px; }
}

.admin-sales-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin: 16px 0 12px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: #fff;
}
.admin-sales-summary > div { padding: 13px 15px; border-right: 1px solid var(--hairline); }
.admin-sales-summary > div:last-child { border-right: 0; }
.admin-sales-summary span { display: block; color: var(--steel); font-size: 10px; }
.admin-sales-summary strong { display: block; margin-top: 5px; color: var(--ink); font-size: 18px; }
.admin-sales-filters {
  display: flex;
  align-items: end;
  gap: 10px;
  margin-bottom: 12px;
  padding: 12px 14px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: #fbfcfe;
}
.supplier-quote { margin-top: 8px; padding: 8px 0; border-top: 1px solid var(--hairline); min-width: 0; font-size: 12px; line-height: 1.65; }
.supplier-quote-line { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; color: var(--steel); }
.supplier-quote-line strong { font-size: 12px; color: var(--ink); }
.supplier-quote-spec { font-size: 12px; line-height: 1.6; overflow-wrap: anywhere; white-space: normal; color: var(--slate); }
.supplier-quote-note { display: block; color: var(--steel); font-size: 12px; line-height: 1.6; overflow-wrap: anywhere; }
.pricing-purchase-source { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 8px; margin-top: 6px; font-size: 12px; color: var(--steel); }
.pricing-purchase-source button { padding: 2px 0; border: 0; background: none; font: inherit; cursor: pointer; }
.pricing-purchase-source button:disabled { opacity: 0.5; cursor: default; }
.pricing-workbench-selection-copy .supplier-quote { width: 100%; }
.pricing-workbench-selection-copy [data-pricing-supplier-warning][hidden] { display: none !important; }
.admin-sales-filters .form-group { width: 240px; margin: 0; }
.admin-sales-table-shell { overflow-x: auto; border: 1px solid var(--hairline); border-radius: 7px; background: #fff; }
.admin-sales-table { min-width: 1080px; }
.admin-sales-table td { font-size: 11px; }
.admin-sales-table td > small,
.admin-sales-product small { display: block; margin-top: 4px; color: var(--steel); font-size: 9px; }
.admin-sales-product { min-width: 280px; }
.admin-sales-product strong { display: block; overflow: hidden; max-width: 300px; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 768px) {
  .admin-sales-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-sales-summary > div { border-right: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
  .admin-sales-summary > div:nth-child(2n) { border-right: 0; }
  .admin-sales-summary > div:last-child { grid-column: 1 / -1; border-right: 0; border-bottom: 0; }
  .admin-sales-filters { align-items: stretch; flex-direction: column; }
  .admin-sales-filters .form-group,
  .admin-sales-filters .btn { width: 100%; }
}
