/* 能标品牌主题：来源于能标官网和商户端产品参考稿。 */
[data-platform="NB"] {
  --brand-primary: #2490b4;
  --brand-primary-hover: #207f9e;
  --brand-primary-contrast: #ffffff;
  --brand-soft: #edf8fa;
  --brand-line: #d4e9ed;
  --brand-focus-ring: rgba(36, 144, 180, 0.16);
  --brand-shadow: 0 12px 28px rgba(36, 144, 180, 0.18);
  --surface-page: #f7f8fb;
  --surface-panel: #ffffff;
  --color-text: #1f2937;
  --color-muted: #667994;
  --blue: var(--brand-primary);
  --ink: #14233a;
  --muted: var(--color-muted);
  --line: var(--brand-line);
  --soft: var(--brand-soft);
  --ds-bg: var(--surface-page);
  --ds-panel: var(--surface-panel);
  --ds-line: #e5eaf3;
  --ds-text: var(--color-text);
  --ds-muted: var(--color-muted);
}

[data-platform="NB"] .sidebar .brand-row {
  grid-template-columns: minmax(0, 1fr) 34px !important;
  align-items: center !important;
  gap: 8px !important;
  min-height: 64px;
  padding: 0 6px !important;
}

[data-platform="NB"] .brand-identity {
  display: block !important;
  width: 185px;
  min-width: 0;
}

[data-platform="NB"] .brand-logo-full {
  display: block !important;
  width: 185px;
  height: 64px;
  background: url("../../assets/brands/nb/nbts-logo-full.png?v=nb_merchant_20260814") no-repeat center / contain;
}

[data-platform="NB"] .brand-logo-compact,
[data-platform="NB"] .brand-generic {
  display: none !important;
}

[data-platform="NB"] .sidebar.is-collapsed .brand-row {
  grid-template-columns: 46px !important;
  justify-content: center !important;
  padding: 0 !important;
}

[data-platform="NB"] .sidebar.is-collapsed .brand-identity {
  display: block !important;
  width: 32px;
}

[data-platform="NB"] .sidebar.is-collapsed .brand-logo-full {
  display: none !important;
}

[data-platform="NB"] .sidebar.is-collapsed .brand-logo-compact {
  display: block !important;
  width: 32px;
  height: 32px;
  background: url("../../assets/brands/nb/nbts-logo-compact.png?v=nb_merchant_20260814") no-repeat center / contain;
}

[data-platform="NB"] .sidebar.is-collapsed {
  --collapsed-nav-icon-size: 20px;
}

[data-platform="NB"] .sidebar.is-collapsed .side-nav {
  grid-template-columns: 48px !important;
  justify-content: center !important;
  width: 100%;
}

[data-platform="NB"] .sidebar.is-collapsed .new-quote-button,
[data-platform="NB"] .sidebar.is-collapsed .side-nav-item {
  align-self: center;
  justify-self: center;
  margin-inline: 0 !important;
}

[data-platform="NB"] .sidebar.is-collapsed .new-quote-button .plus-mark,
[data-platform="NB"] .sidebar.is-collapsed .side-nav-item::before {
  box-sizing: border-box;
  flex: 0 0 var(--collapsed-nav-icon-size) !important;
  width: var(--collapsed-nav-icon-size) !important;
  height: var(--collapsed-nav-icon-size) !important;
  margin: 0 !important;
  line-height: 1 !important;
}

[data-platform="NB"] .human-handoff-button {
  right: 18px;
  top: calc(50% + 248px);
  bottom: auto;
  height: 44px;
  min-height: 44px;
  padding: 0 14px 0 8px;
  border-radius: 22px;
  gap: 7px;
  background: #207f9e;
  color: #ffffff;
  font-size: 13px;
  line-height: 13px;
  box-shadow: 0 8px 22px rgba(36, 144, 180, 0.24);
}

[data-platform="NB"] .human-handoff-button:hover {
  background: #176f8b;
  box-shadow: 0 10px 24px rgba(36, 144, 180, 0.3);
}

[data-platform="NB"] .human-handoff-icon {
  width: 30px;
  height: 30px;
  background: rgba(255, 255, 255, 0.18);
}

[data-platform="NB"] .hero-panel > .mode-head {
  display: none !important;
}

[data-platform="NB"] .agent-banner {
  position: relative;
  display: flex;
  flex: 0 0 130px;
  align-items: center;
  justify-content: center;
  width: min(820px, 100%);
  height: 130px;
  margin: 0 auto 0;
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(104deg, #ffffff 15%, #edf9fb 58%, #e7f5f8 100%);
  box-shadow: inset 0 -1px 0 rgba(36, 144, 180, 0.12);
}

[data-platform="NB"] .agent-robot {
  position: absolute;
  left: 44px;
  bottom: -26px;
  width: auto;
  height: 156px;
  object-fit: contain;
  object-position: center bottom;
}

[data-platform="NB"] .agent-title {
  position: relative;
  margin: 0 18px 0 230px;
  color: #111827;
  font-size: 31px;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: 0;
}

[data-platform="NB"] .agent-accent {
  color: var(--brand-primary);
}

[data-platform="NB"] .mode-switch,
[data-platform="NB"] .workspace:not(.is-chat-active) .mode-switch {
  display: grid !important;
  grid-template-columns: repeat(3, 128px) !important;
  column-gap: 2px !important;
  width: 398px !important;
  max-width: 100% !important;
  height: auto !important;
  min-height: 44px !important;
  margin: 0 auto 14px !important;
  padding: 4px !important;
  border: 1px solid #dce6f3 !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.94) !important;
  box-shadow: 0 1px 2px rgba(18, 33, 60, 0.04) !important;
}

[data-platform="NB"] .mode-pill,
[data-platform="NB"] .workspace:not(.is-chat-active) .mode-pill {
  height: 36px !important;
  min-width: 128px !important;
  padding: 0 16px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: transparent !important;
  color: #102136 !important;
  font-size: 15px !important;
  font-weight: 400 !important;
  line-height: 36px !important;
  white-space: nowrap !important;
  box-shadow: none !important;
}

[data-platform="NB"] .mode-pill.is-active,
[data-platform="NB"] .workspace:not(.is-chat-active) .mode-pill.is-active {
  background: #e8f5f8 !important;
  color: var(--brand-primary) !important;
  box-shadow: inset 0 0 0 1px #a9d8e3, 0 1px 2px rgba(36, 144, 180, 0.12) !important;
}

[data-platform="NB"] .starter-row-head {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  width: 100% !important;
  margin: 18px 0 8px !important;
  color: #7a8798 !important;
  font-size: 13px !important;
  line-height: 18px !important;
}

[data-platform="NB"] .mode-template-download {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid #acd9e4;
  border-radius: 18px;
  background: #f4fafb;
  color: #2187a8;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

[data-platform="NB"] .mode-template-download:hover {
  border-color: #8fcbd9;
  background: #e8f5f8;
  color: #207f9e;
}

[data-platform="NB"] .recent-head {
  color: var(--color-muted);
}

[data-platform="NB"] .recent-head button {
  color: var(--brand-primary);
}

[data-platform="NB"] .recent-item:hover,
[data-platform="NB"] .recent-item.is-active {
  background: var(--brand-soft);
  color: var(--brand-primary);
}

[data-platform="NB"] .workbench-page .view-tag {
  border-color: var(--brand-line);
  background: var(--brand-soft);
  color: #2490b4 !important;
}

[data-platform="NB"] #quoteRecordFilterReset {
  border-color: var(--brand-line);
  background: var(--brand-soft);
  color: var(--brand-primary);
}

[data-platform="NB"] #quoteRecordFilterReset:hover {
  border-color: var(--brand-primary);
  background: #e8f5f8;
  color: var(--brand-primary-hover);
}

[data-platform="NB"] .record-status-pill {
  border-color: var(--brand-line);
  background: var(--brand-soft);
  color: var(--brand-primary);
}

[data-platform="NB"] .record-actions button {
  border-color: var(--brand-line);
  background: var(--brand-soft);
  color: var(--brand-primary);
}

[data-platform="NB"] .record-actions button:hover {
  border-color: var(--brand-primary);
  background: #e8f5f8;
  color: var(--brand-primary-hover);
}

@media (max-width: 760px) {
  [data-platform="NB"] .brand-logo-full {
    width: 132px;
    height: 44px;
  }

  [data-platform="NB"] .human-handoff-button {
    right: 12px;
    top: auto;
    bottom: 14px;
  }

  [data-platform="NB"] .agent-banner {
    flex-basis: 96px;
    height: 96px;
    margin-top: 0;
    border-radius: 18px;
  }

  [data-platform="NB"] .agent-robot {
    left: 12px;
    bottom: -20px;
    width: auto;
    height: 118px;
  }

  [data-platform="NB"] .agent-title {
    margin: 0 10px 0 112px;
    font-size: 20px;
    line-height: 1.3;
  }

  [data-platform="NB"] .mode-switch,
  [data-platform="NB"] .workspace:not(.is-chat-active) .mode-switch {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    width: 100% !important;
  }

  [data-platform="NB"] .mode-pill,
  [data-platform="NB"] .workspace:not(.is-chat-active) .mode-pill {
    min-width: 0 !important;
    padding: 0 4px !important;
    font-size: 12px !important;
  }
}
