/* ==========================================================================
   Dashboard (members-only) – scoped under .dash
   3-column app shell: sidebar | main | context rail
   Polish pass: collapsible sidebar, active context, toast, tighter spacing
   ========================================================================== */

.dash {
  --dash-sidebar-width: 260px;
  --dash-sidebar-collapsed: 56px;

  --dash-space-1: 0.75rem;
  --dash-space-2: 1rem;
  --dash-space-3: 1.5rem;
  --dash-space-4: 2.5rem;
  --dash-radius: 8px;
  --dash-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
  --dash-shadow-card: 0 2px 10px rgba(0, 0, 0, 0.08);
  --dash-border: 1px solid rgba(0, 0, 0, 0.09);
  box-sizing: border-box;
  font-family: inherit;
  height: 100dvh;
  overflow: hidden;
}

.dash *,
.dash *::before,
.dash *::after {
  box-sizing: border-box;
}

/* Lock viewport — no page-level scroll (Claude.ai style) */
body.page-onyx-signals-dashboard {
  height: 100dvh;
  overflow: hidden;
}

body.page-onyx-signals-dashboard #main {
  height: 100dvh;
}

/* Hide Ghost chrome on the dashboard */
body.page-onyx-signals-dashboard .c-header,
body.page-onyx-signals-dashboard .c-footer,
body.page-onyx-signals-dashboard footer,
body.page-onyx-signals-dashboard .gh-portal-triggerbtn-wrapper,
body.page-onyx-signals-dashboard .gh-portal-triggerbtn-container,
body.page-onyx-signals-dashboard .gh-portal-triggerbtn-iframe,
body.page-onyx-signals-dashboard iframe[title="portal-trigger"] {
  display: none !important;
  pointer-events: none !important;
}

/* Gate (logged out) */
.dash-gate {
  max-width: 420px;
  margin: var(--dash-space-4) auto;
  padding: var(--dash-space-4);
  text-align: center;
  background: #fff;
  border: var(--dash-border);
  border-radius: var(--dash-radius);
  box-shadow: var(--dash-shadow-card);
}

.dash-gate__message {
  margin: 0 0 var(--dash-space-3);
  font-size: 1.125rem;
  line-height: 1.5;
  color: var(--color-text-secondary, #555);
}

.dash-gate__title {
  margin: 0 0 var(--dash-space-2);
  font-size: 1.5rem;
  font-weight: 700;
}

.dash-gate__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--dash-space-2);
  justify-content: center;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.dash-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--dash-radius);
  text-decoration: none;
  cursor: pointer;
  border: none;
  background: transparent;
  color: inherit;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s, box-shadow 0.15s;
}

.dash-btn--primary {
  background: var(--color-accent, #0ea5e9);
  color: #fff;
}

.dash-btn--primary:hover {
  background: var(--color-accent-hover, #0284c7);
  color: #fff;
}

.dash-btn--secondary {
  border: 1.5px solid rgba(0, 0, 0, 0.15);
}

.dash-btn--secondary:hover {
  border-color: rgba(0, 0, 0, 0.3);
}

.dash-btn--small {
  padding: 0.35rem 0.75rem;
  font-size: 0.8125rem;
}

.dash-btn--ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.6rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #666;
  background: transparent;
  border: none;
}

.dash-btn--ghost:hover {
  color: #333;
  background: #f1f5f9;
}

.dash-btn__label {
  font-size: 0.8125rem;
}

/* ==========================================================================
   Sidebar brand block
   ========================================================================== */

.dash-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.25rem;
  border-bottom: var(--dash-border);
  margin-bottom: 0.25rem;
}

.dash-brand__btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1;
  min-width: 0;
  padding: 0.3rem;
  border: none;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  border-radius: var(--dash-radius);
  cursor: pointer;
  transition: background 0.15s;
}

.dash-brand__btn:hover {
  background: #f1f5f9;
}

.dash-brand__avatar {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #0f172a;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.dash-brand__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.dash-brand__name {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-brand__sub {
  font-size: 0.625rem;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  line-height: 1.3;
}

.dash-brand__right {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.dash-brand__logo {
  height: 28px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

/* Collapsed brand: avatar + toggle stacked */
.dash--collapsed .dash-brand {
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 0.5rem 0;
}

.dash--collapsed .dash-brand__btn {
  justify-content: center;
  padding: 0.25rem;
  width: auto;
}

.dash--collapsed .dash-brand__text {
  display: none;
}

.dash--collapsed .dash-brand__logo {
  display: none;
}

/* ==========================================================================
   App shell grid
   ========================================================================== */

.dash-shell {
  display: grid;
  grid-template-columns: var(--dash-sidebar-width) 1fr;
  grid-template-areas:
    "sidebar main";
  gap: var(--dash-space-2);
  padding: 0 var(--dash-space-2) 0;
  height: 100%;
  overflow: hidden;
  transition: grid-template-columns 0.2s ease;
}

/* Sidebar */
.dash-sidebar {
  grid-area: sidebar;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--dash-sidebar-width);
  height: 100vh;
  overflow: hidden;
  min-width: 0;
  z-index: 10;
  background: #fff;
  transition: width 0.2s ease;
  padding: 0 14px 0 18px;
  border-right: 1px solid rgba(0,0,0,0.08);
}

/* Sidebar topbar */
.dash-sidebar__topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 0.25rem;
  flex-shrink: 0;
}

/* Sidebar scrollable content */
.dash-sidebar__content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  scrollbar-width: none;
  scrollbar-color: rgba(0,0,0,0.15) transparent;
}
.dash-sidebar__content::-webkit-scrollbar {
  width: 0;
}
.dash-sidebar__content:hover {
  scrollbar-width: thin;
}
.dash-sidebar__content:hover::-webkit-scrollbar {
  width: 6px;
}
.dash-sidebar__content:hover::-webkit-scrollbar-track {
  background: transparent;
}
.dash-sidebar__content:hover::-webkit-scrollbar-thumb {
  background: rgba(0,0,0,0.15);
  border-radius: 4px;
}
.dash-sidebar__content:hover::-webkit-scrollbar-thumb:hover {
  background: rgba(0,0,0,0.25);
}

/* Create Data Room section (above demos) */
.dash-sidebar__dataroom {
  padding: 0.5rem 0.5rem;
  border-top: 1px solid rgba(0,0,0,0.08);
  flex-shrink: 0;
}
.dash-dataroom-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.6rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #fff;
  background: var(--color-accent, #0ea5e9);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
}
.dash-dataroom-btn:hover {
  background: var(--color-accent-hover, #0284c7);
  transform: translateY(-1px);
}
.dash-dataroom-btn:active {
  transform: translateY(0);
}
.dash-dataroom-btn svg {
  flex-shrink: 0;
}
.dash-dataroom-menu {
  display: none;
  flex-direction: column;
  gap: 0.25rem;
  margin-top: 0.4rem;
}
.dash-dataroom-menu.is-open {
  display: flex;
}
.dash-dataroom-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--dash-text, #1e293b);
  background: rgba(0,0,0,0.03);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.12s;
  text-align: left;
}
button.dash-dataroom-option:hover {
  background: rgba(0,0,0,0.07);
}
.dash-dataroom-option svg {
  flex-shrink: 0;
  opacity: 0.6;
}
.dash-dataroom-search {
  cursor: default;
}
.dash-dataroom-input {
  flex: 1;
  min-width: 0;
  padding: 0.25rem 0;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--dash-text, #1e293b);
  background: transparent;
  border: none;
  outline: none;
}
.dash-dataroom-input::placeholder {
  color: rgba(0,0,0,0.35);
}

/* Sidebar demo buttons (stacked above footer) */
.dash-sidebar__demos {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.25rem;
  padding: 0.5rem 0.25rem;
  border-top: 1px solid rgba(0,0,0,0.08);
  flex-shrink: 0;
}

/* Sidebar footer (pinned bottom) */
.dash-sidebar__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.625rem 0.25rem;
  border-top: 1px solid rgba(0,0,0,0.08);
  flex-shrink: 0;
}

.dash-sidebar__footerBtn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: none;
  background: none;
  cursor: pointer;
  padding: 0.3rem;
  border-radius: var(--dash-radius);
  color: inherit;
  font: inherit;
}
.dash-sidebar__footerBtn:hover {
  background: #f1f5f9;
}

.dash-sidebar__footerName {
  font-size: 0.8125rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-sidebar__footerRight {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

/* Watchlist overlay */
.dash-watchlist-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  z-index: 20;
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.2s ease;
  pointer-events: none;
}

.dash-watchlist-overlay.is-open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

.dash-watchlist-overlay__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.dash-watchlist-overlay__title {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  font-weight: 700;
  margin: 0;
}

.dash-watchlist-overlay__close {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  cursor: pointer;
  border-radius: var(--dash-radius);
  color: #666;
}
.dash-watchlist-overlay__close:hover {
  background: #f1f5f9;
  color: #333;
}

.dash-watchlist-overlay__body {
  flex: 1;
  overflow-y: auto;
  padding: 0.5rem 0.75rem;
}

/* Main workspace */
.dash-main {
  grid-area: main;
  min-width: 0;
  max-width: 820px;
  width: 100%;
  justify-self: center;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-bottom: 12vh;
  overflow: hidden;
}

.dash-main__inner {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}

/* When chat is active, kill the shell's right padding so the scrollbar
   sits flush against the viewport edge (like Claude.ai) */
.dash-shell:has(.dash-main--chatActive) {
  padding-right: 0;
}

.dash-main--chatActive {
  justify-content: flex-start;
  padding-top: 1.5rem;
  padding-bottom: 0;
  /* Fill the full 1fr grid area so the scrollbar sits at the right edge */
  max-width: none;
  justify-self: stretch;
}

.dash-main--chatActive .dash-chatTopbar {
  max-width: 820px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

.dash-main--chatActive .dash-main__inner {
  flex: 1 1 0;
  min-height: 0;
  overflow: hidden;
}

.dash-main--chatActive .dash-chat {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dash-main--chatActive .dash-chat__messages {
  max-height: none;
  flex: 1 1 0;
  min-height: 0;
  padding-right: 0;
}

/* Centre assistant bubbles within the full-width scroll area */
.dash-main--chatActive .dash-chat__bubble--assistant {
  max-width: 820px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

/* Keep user bubbles right-aligned but constrained within centered track */
.dash-main--chatActive .dash-chat__bubble--user {
  max-width: min(70%, 574px);  /* 70% of 820px */
  margin-left: auto;
  margin-right: max(0px, calc((100% - 820px) / 2));
}

/* Centre the composer and reply bar within the full-width layout */
.dash-main--chatActive .dash-composer,
.dash-main--chatActive .dash-replyBar {
  max-width: 820px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

/* ==========================================================================
   Collapsible sidebar
   ========================================================================== */

.dash-sidebar__toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  padding: 0;
  color: #666;
  background: none;
  border: none;
  border-radius: var(--dash-radius);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.dash-sidebar__toggle:hover {
  background: #f1f5f9;
  color: #333;
}

.dash-sidebar__toggle-icon {
  flex-shrink: 0;
  transition: transform 0.2s;
}


/* Collapsed state */
.dash--collapsed .dash-shell {
  grid-template-columns: var(--dash-sidebar-collapsed) 1fr;
}

.dash--collapsed .dash-sidebar__toggle-icon {
  transform: rotate(180deg);
}

.dash--collapsed .dash-panel__title-text {
  display: none;
}

.dash--collapsed .dash-watchlist__list,
.dash--collapsed .dash-catalysts__list,
.dash--collapsed .dash-updates__list {
  display: none;
}

.dash--collapsed .dash-sidebar {
  width: var(--dash-sidebar-collapsed);
  padding: 0 6px;
}

.dash--collapsed .dash-sidebar .dash-panel,
.dash--collapsed .dash-sidebar .dash-analyses,
.dash--collapsed .dash-sidebar .dash-recents,
.dash--collapsed .dash-sidebar .dash-signals {
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.dash--collapsed .dash-sidebar .dash-panel__title {
  margin: 0;
  justify-content: center;
}

/* Collapsed footer */
.dash--collapsed .dash-sidebar__footerName {
  display: none;
}
.dash--collapsed .dash-sidebar__footerRight {
  display: none;
}
.dash--collapsed .dash-sidebar__footer {
  justify-content: center;
  padding: 0.5rem 0;
}

/* Collapsed: hide watchlist overlay and demo buttons */
.dash--collapsed .dash-watchlist-overlay {
  display: none;
}
.dash--collapsed .dash-sidebar__dataroom {
  display: none;
}
.dash--collapsed .dash-sidebar__demos {
  display: none;
}

/* Logos + avatar fallback */
.dash-watchlist__logo {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}

.dash-watchlist__avatar {
  display: none;
}

.dash-watchlist__conditionIcon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dash-watchlist__conditionIcon svg {
  display: block;
}
.dash-watchlist__conditionIcon--info {
  background: #dbeafe;
  color: #2563eb;
}
.dash-watchlist__conditionIcon--eye {
  background: #ccfbf1;
  color: #0d9488;
}
.dash-watchlist__conditionIcon--brain {
  background: #ede9fe;
  color: #7c3aed;
}
.dash-watchlist__conditionIcon--liver {
  background: #fef3c7;
  color: #d97706;
}
.dash-watchlist__conditionIcon--heart {
  background: #ffe4e6;
  color: #e11d48;
}

.dash-watchlist__targetIcon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dash-watchlist__targetIcon svg {
  display: block;
}
.dash-watchlist__targetIcon--receptor {
  background: #ccfbf1;
  color: #0d9488;
}
.dash-watchlist__targetIcon--pathway {
  background: #dbeafe;
  color: #2563eb;
}
.dash-watchlist__targetIcon--gene {
  background: #fef3c7;
  color: #d97706;
}

.dash--collapsed .dash-watchlist__list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.35rem;
}

.dash--collapsed .dash-watchlist__row {
  padding: 0;
  border: none;
  justify-content: center;
  display: flex;
}

.dash--collapsed .dash-watchlist__avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 0.6875rem;
  font-weight: 700;
}

.dash--collapsed .dash-watchlist__conditionIcon {
  width: 28px;
  height: 28px;
}

.dash--collapsed .dash-watchlist__targetIcon {
  width: 28px;
  height: 28px;
}

.dash--collapsed .dash-watchlist__logo,
.dash--collapsed .dash-watchlist__info,
.dash--collapsed .dash-watchlist__status,
.dash--collapsed .dash-watchlist__badge,
.dash--collapsed .dash-watchlist__chevron,
.dash--collapsed .dash-watchlist__tags {
  display: none;
}

.dash--collapsed .dash-watchlist__row:hover {
  margin: 0;
  padding: 0;
  background: none;
}

/* Saved panel collapsed in sidebar */
.dash--collapsed .dash-analyses__body {
  display: none;
}

.dash--collapsed .dash-analyses__toggle {
  justify-content: center;
}

.dash--collapsed .dash-analyses__chevron {
  display: none;
}

/* Signals nav collapsed in sidebar */
.dash--collapsed .dash-signals__list {
  display: none;
}

/* CSS Tooltips for collapsed panels */
.dash--collapsed .dash-sidebar [data-tooltip] {
  position: relative;
}

.dash--collapsed .dash-sidebar [data-tooltip]:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  left: calc(100% + 8px);
  top: 50%;
  transform: translateY(-50%);
  padding: 0.3rem 0.6rem;
  font-size: 0.6875rem;
  font-weight: 500;
  white-space: nowrap;
  background: #1e293b;
  color: #fff;
  border-radius: 4px;
  z-index: 20;
  pointer-events: none;
}

/* ==========================================================================
   Panel icons (sidebar section headers)
   ========================================================================== */

.dash-panel__icon {
  flex-shrink: 0;
  color: #888;
}

.dash-panel__title {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* ==========================================================================
   Panels (shared)
   ========================================================================== */

.dash-panel {
  padding: var(--dash-space-2);
  background: #fff;
  border: var(--dash-border);
  border-radius: var(--dash-radius);
  box-shadow: var(--dash-shadow);
}

.dash-panel__title {
  font-size: 0.875rem;
  font-weight: 700;
  margin: 0 0 var(--dash-space-1);
  letter-spacing: -0.01em;
}

/* Sidebar panels (flat, no box) */
.dash-sidebar .dash-panel,
.dash-sidebar .dash-analyses,
.dash-sidebar .dash-recents,
.dash-sidebar .dash-signals {
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  min-width: 0;
}

.dash-sidebar .dash-panel__title {
  font-size: 0.8125rem;
  margin: 0 0 0.5rem;
}

/* ==========================================================================
   Greeting row (lives inside .dash-main__inner)
   ========================================================================== */

.dash-greetingRow {
  display: flex;
  align-items: stretch;
  gap: 0.75rem;
  min-height: 4.5rem;
  margin-top: 0;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.dash-greetingRow--hidden {
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
}

.dash-greetingCol {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.dash-greeting__date {
  display: inline;
  font-size: 0.65rem;
  font-weight: 500;
  color: #aaa;
  letter-spacing: 0.02em;
  margin-left: 0.5em;
  vertical-align: middle;
}

.dash-greeting {
  min-width: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.4;
  color: var(--color-text-primary, #111);
  margin: 0;
  overflow-wrap: break-word;
}

.dash-greeting__update {
  display: block;
  transition: opacity 0.2s ease;
}

.dash-greeting:empty {
  display: none;
}

.dash-greeting__name {
  color: var(--color-accent, #0ea5e9);
}

.dash-greeting__welcome {
  font-size: 2.25rem;
  line-height: 1.2;
}

.dash-greeting__source {
  display: inline-flex;
  align-items: center;
  gap: 0.25em;
  font-size: 0.65rem;
  font-weight: 600;
  color: #8b919a;
  margin-left: 0.5em;
  padding: 0.15em 0.5em;
  text-decoration: none;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  vertical-align: middle;
  cursor: grab;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
  letter-spacing: 0.01em;
  line-height: 1.6;
}

.dash-greeting__source:hover {
  color: #4b5563;
  background: #eef0f3;
  border-color: #d1d5db;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.dash-greeting__source:active {
  cursor: grabbing;
}

.dash-greeting__source--dragging {
  opacity: 0.4;
  cursor: grabbing;
}

.dash-greeting__sourceIcon {
  flex-shrink: 0;
  opacity: 0.55;
}

/* Vertical "next" button to the right of greeting text */
.dash-greetingNext {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  width: 36px;
  flex-shrink: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: #999;
  cursor: pointer;
  padding: 0.4rem 0;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  user-select: none;
}

.dash-greetingNext:hover {
  background: transparent;
  color: #555;
  border-color: transparent;
}

.dash-greetingNext:active {
  background: transparent;
}

.dash-greetingNext__chevron {
  flex-shrink: 0;
}

.dash-greetingNext__count {
  font-size: 0.625rem;
  font-weight: 600;
  color: inherit;
  white-space: nowrap;
  letter-spacing: 0.02em;
}

/* "Previous" button to the left of greeting text — invisible until row hover */
.dash-greetingPrev {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 36px;
  flex-shrink: 0;
  margin-left: -44px;
  border: none;
  border-radius: 0;
  background: transparent;
  color: #999;
  cursor: pointer;
  padding: 0.4rem 0;
  opacity: 0;
  transition: opacity 0.2s ease, color 0.15s ease;
  user-select: none;
}

.dash-greetingRow:hover .dash-greetingPrev {
  opacity: 1;
}

.dash-greetingPrev:hover {
  color: #555;
}

.dash-greetingPrev:active {
  background: transparent;
}

.dash-greetingPrev__chevron {
  flex-shrink: 0;
}

/* Greeting company pill (inline tag in greeting text) */
.dash-greetingPill {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.1em 0.45em 0.1em 0.2em;
  background: #e9eef5;
  border: 1px solid #d5dce6;
  border-radius: 999px;
  font-size: 0.85em;
  font-weight: 600;
  color: #334155;
  line-height: 1;
  white-space: nowrap;
  vertical-align: middle;
}

.dash-greetingPill__logo {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}

.dash-greetingPill__initials {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #d5dce6;
  color: #64748b;
  font-size: 0.6em;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ==========================================================================
   Home view (welcome, watchlist cards, saved projects, recent activity, news)
   ========================================================================== */

.dash-home {
  display: flex;
  flex-direction: column;
  gap: var(--dash-space-4);
  padding-top: 0.5rem;
}

.dash-home__welcome {
  margin-bottom: 0.25rem;
}

.dash-home__section {
  margin: 0;
}

.dash-home__sectionTitle {
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--color-text-secondary, #475569);
  letter-spacing: 0.02em;
  margin: 0 0 var(--dash-space-2);
  text-transform: uppercase;
}

.dash-home__watchlistCards {
  display: flex;
  flex-wrap: wrap;
  gap: var(--dash-space-2);
}

.dash-home__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 0.875rem 0.75rem 0.75rem;
  width: 120px;
  flex-shrink: 0;
  background: #fff;
  border: var(--dash-border);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  font-family: inherit;
  text-align: center;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.dash-home__card:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
}

.dash-home__card:active {
  background: #f1f5f9;
}

/* Logo wrapper — fixed 44px circle */
.dash-home__cardLogoWrap {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  background: #f1f5f9;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.15rem;
}

.dash-home__cardLogo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

/* Initials fallback */
.dash-home__cardAvatar {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: #64748b;
  background: #e2e8f0;
  border-radius: 50%;
  text-transform: uppercase;
  user-select: none;
}

.dash-home__cardName {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-primary, #111);
  line-height: 1.25;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-home__cardStatus {
  font-size: 0.6rem;
  color: var(--color-text-secondary, #64748b);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-width: 100%;
}

[data-color-scheme="dark"] .dash-home__card {
  background: #1a1f2e;
}

[data-color-scheme="dark"] .dash-home__card:hover {
  background: #1e2535;
  border-color: rgba(255,255,255,0.18);
}

[data-color-scheme="dark"] .dash-home__cardLogoWrap {
  border-color: rgba(255,255,255,0.1);
  background: #252b3b;
}

[data-color-scheme="dark"] .dash-home__cardAvatar {
  background: #2d3548;
  color: #94a3b8;
}

.dash-home__savedList,
.dash-home__activityList {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dash-home__savedItem,
.dash-home__activityItem {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.5rem 0.75rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: var(--dash-radius);
  font-size: 0.875rem;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s, box-shadow 0.12s;
}
.dash-home__savedItem:hover,
.dash-home__activityItem:hover {
  background: #f1f5f9;
  border-color: #6366f1;
  box-shadow: 0 1px 4px rgba(99,102,241,0.08);
}

.dash-home__savedItem {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.dash-home__savedIcon {
  flex-shrink: 0;
  color: #6366f1;
  opacity: 0.7;
}

.dash-home__savedTitle {
  flex: 1;
  font-weight: 500;
  color: var(--color-text-primary, #111);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-home__savedTime {
  flex-shrink: 0;
  font-size: 0.75rem;
  color: var(--color-text-secondary, #64748b);
}

.dash-home__activityItem {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.dash-home__activityType {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--color-text-secondary, #64748b);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.dash-home__activityQuery {
  color: var(--color-text-primary, #111);
  line-height: 1.4;
}

.dash-home__empty {
  font-size: 0.875rem;
  color: var(--color-text-secondary, #64748b);
  margin: 0;
}

.dash-home__loading {
  font-size: 0.8125rem;
  color: var(--color-text-secondary, #64748b);
}

/* Onyx News card grid */
.dash-home__newsList {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--dash-space-2, 0.75rem);
}

.dash-news__card {
  display: flex;
  flex-direction: column;
  background: #f8fafc;
  border: var(--dash-border, 1px solid #e2e8f0);
  border-radius: var(--dash-radius, 8px);
  overflow: hidden;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.dash-news__card:hover {
  border-color: #cbd5e1;
  box-shadow: var(--dash-shadow-card, 0 2px 8px rgba(0,0,0,0.08));
}

.dash-news__cardMedia {
  display: block;
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 2;
  background-color: #e2e8f0;
  overflow: hidden;
  flex-shrink: 0;
}

.dash-news__cardMedia--placeholder {
  background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
}

.dash-news__cardImage {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity 0.2s ease;
}

.dash-news__card:hover .dash-news__cardImage {
  opacity: 0.88;
}

.dash-news__cardContent {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1;
  padding: 0.625rem 0.75rem 0.5rem;
  gap: 0.375rem;
}

.dash-news__headline {
  margin: 0;
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dash-news__link {
  text-decoration: none;
  color: inherit;
}

.dash-news__link:hover {
  color: var(--color-accent, #0ea5e9);
}

.dash-news__date {
  font-size: 0.6875rem;
  color: var(--color-text-secondary, #64748b);
}

.dash-news__empty {
  font-size: 0.875rem;
  color: var(--color-text-secondary, #64748b);
  margin: 0;
  grid-column: 1 / -1;
}

/* ── Industry News — per-source horizontal scroll sections ──────────── */
.dash-industry__container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.dash-industry__section {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.dash-industry__sectionHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.dash-industry__sectionTitle {
  margin: 0;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--color-accent, #0ea5e9);
}

.dash-industry__nav {
  display: flex;
  gap: 0.25rem;
  flex-shrink: 0;
}

.dash-industry__navBtn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: var(--dash-border, 1px solid #e2e8f0);
  background: none;
  cursor: pointer;
  color: var(--color-text, #0f172a);
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  padding: 0;
}

.dash-industry__navBtn:hover:not(:disabled) {
  background: var(--color-accent, #0ea5e9);
  border-color: var(--color-accent, #0ea5e9);
  color: #fff;
}

.dash-industry__navBtn:disabled {
  opacity: 0.3;
  cursor: default;
}

.dash-industry__trackWrap {
  overflow: hidden;
}

.dash-industry__track {
  display: flex;
  gap: 0.75rem;
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Card width set by JS to exactly 1/3 of wrapper; flex basis applied inline */
.dash-industry__card {
  flex-shrink: 0;
}

[data-color-scheme="dark"] .dash-industry__navBtn {
  border-color: rgba(255,255,255,0.12);
  color: #e2e8f0;
}

[data-color-scheme="dark"] .dash-industry__navBtn:hover:not(:disabled) {
  background: var(--color-accent, #0ea5e9);
  border-color: var(--color-accent, #0ea5e9);
  color: #fff;
}

@media (max-width: 840px) {
  .dash-home__newsList { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .dash-home__newsList { grid-template-columns: 1fr; }
}

[data-color-scheme="dark"] .dash-news__card {
  background: #1a1f2e;
  border-color: rgba(255,255,255,0.08);
}

[data-color-scheme="dark"] .dash-news__card:hover {
  border-color: rgba(255,255,255,0.15);
  box-shadow: 0 2px 12px rgba(0,0,0,0.35);
}

[data-color-scheme="dark"] .dash-news__cardMedia {
  background-color: #252b3b;
}

[data-color-scheme="dark"] .dash-news__cardMedia--placeholder {
  background: linear-gradient(135deg, #252b3b 0%, #1e2535 100%);
}

/* FDA Press Releases — same card grid as Onyx News */
.dash-home__fdaList {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--dash-space-2, 0.75rem);
}

@media (max-width: 840px) {
  .dash-home__fdaList { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .dash-home__fdaList { grid-template-columns: 1fr; }
}

/* FDA logo card image — navy brand background with centred SVG */
.dash-fda__cardMedia {
  background-color: #0d2240;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dash-fda__logo {
  position: relative;
  width: 72%;
  height: auto;
  object-fit: contain;
}

[data-color-scheme="dark"] .dash-fda__cardMedia {
  background-color: #0a1a30;
}

/* ==========================================================================
   Chat welcome hero (logo + plan bar above composer)
   ========================================================================== */

.dash-chatHero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding-bottom: 1.5rem;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.dash-chatHero--hidden {
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
}

.dash-chatHero__plan {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  color: var(--color-text-secondary, #64748b);
  background: var(--color-surface, #f1f5f9);
  border: 1px solid var(--color-border, #e2e8f0);
  border-radius: 999px;
  padding: 0.2rem 0.75rem;
  user-select: none;
}

.dash-chatHero__planText {
  font-weight: 500;
}

.dash-chatHero__planDot {
  opacity: 0.4;
}

.dash-chatHero__upgrade {
  font-weight: 600;
  color: var(--color-accent, #0ea5e9);
  text-decoration: none;
  cursor: pointer;
}

.dash-chatHero__upgrade:hover {
  text-decoration: underline;
}

.dash-chatHero__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.dash-chatHero__brandIcon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  color: var(--color-text-primary, #1e293b);
  opacity: 0.72;
}

[data-color-scheme="dark"] .dash-chatHero__brandIcon {
  color: #e2e8f0;
  opacity: 0.65;
}

.dash-chatHero__tagline {
  font-size: 1rem;
  font-weight: 500;
  color: var(--color-text-primary, #1e293b);
  opacity: 0.7;
  letter-spacing: -0.01em;
  line-height: 1.3;
  max-width: 340px;
}

[data-color-scheme="dark"] .dash-chatHero__tagline {
  color: #e2e8f0;
  opacity: 0.6;
}

/* ==========================================================================
   Composer card
   ========================================================================== */

.dash-composer {
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.dash-composer--hidden {
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
}

.dash-composer__textarea {
  width: 100%;
  min-height: 16rem;
  padding: 0.75rem 0.875rem 5.25rem 0.875rem;
  font-size: 0.9375rem;
  line-height: 1.5;
  font-family: inherit;
  border: var(--dash-border);
  border-radius: var(--dash-radius);
  background: #fafafa;
  resize: none;
  display: block;
  margin-bottom: 0.25rem;
  transition: border-color 0.15s, box-shadow 0.15s;
}

/* Contenteditable variant of the textarea */
.dash-composer__textarea--editable {
  overflow-y: auto;
  white-space: pre-wrap;
  word-wrap: break-word;
  cursor: text;
}

.dash-composer__textarea--editable.is-empty::before {
  content: attr(data-placeholder);
  color: #999;
  pointer-events: none;
  display: block;
}

.dash-composer__textarea--editable.is-empty:focus::before {
  color: transparent;
}

/* Inline company pills inside the contenteditable composer */
.dash-composer__textarea--editable .dash-greetingPill {
  user-select: none;
  cursor: pointer;
  vertical-align: baseline;
  position: relative;
  margin: 0 1px;
}

.dash-composer__textarea--editable .dash-greetingPill__remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 0.1em;
  padding: 0;
  border: none;
  background: none;
  color: #94a3b8;
  font-size: 0.85em;
  line-height: 1;
  cursor: pointer;
  vertical-align: middle;
}

.dash-composer__textarea--editable .dash-greetingPill__remove:hover {
  color: #475569;
}

/* ── Source pill (inline in contenteditable) ── */
.dash-sourcePill {
  display: inline-flex;
  align-items: center;
  gap: 0.3em;
  font-size: 0.75rem;
  font-weight: 600;
  color: #4b5563;
  padding: 0.15em 0.55em 0.15em 0.45em;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  vertical-align: baseline;
  user-select: none;
  cursor: pointer;
  white-space: nowrap;
  line-height: 1.6;
  letter-spacing: 0.01em;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  position: relative;
  margin: 0 1px;
}

.dash-sourcePill:hover {
  background: #eef0f3;
  border-color: #d1d5db;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.dash-sourcePill__icon {
  display: inline-flex;
  align-items: center;
  color: #94a3b8;
  flex-shrink: 0;
  line-height: 0;
}

.dash-sourcePill__name {
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}

.dash-sourcePill__remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 0.1em;
  padding: 0;
  border: none;
  background: none;
  color: #94a3b8;
  font-size: 0.85em;
  line-height: 1;
  cursor: pointer;
  vertical-align: middle;
}

.dash-sourcePill__remove:hover {
  color: #475569;
}

/* ── Popover key-points list ── */
.dash-pillPopover__points {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
}

.dash-pillPopover__points li {
  position: relative;
  font-size: 0.75rem;
  color: #475569;
  line-height: 1.5;
  padding: 0.25rem 0 0.25rem 1em;
}

.dash-pillPopover__points li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #94a3b8;
}

.dash-pillPopover__points li + li {
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

/* ── Template slot (interactive placeholder inside contenteditable) ── */
.dash-templateSlot {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 10px;
  margin: 0 2px;
  border: 1.5px dashed #94a3b8;
  border-radius: 14px;
  background: rgba(148, 163, 184, 0.08);
  color: #64748b;
  font-size: 0.85em;
  line-height: 1.5;
  vertical-align: baseline;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}

.dash-templateSlot:hover {
  border-color: var(--color-accent, #0ea5e9);
  background: rgba(14, 165, 233, 0.06);
  color: var(--color-accent, #0ea5e9);
}

.dash-templateSlot--dropHover {
  border-color: var(--color-accent, #0ea5e9);
  border-style: solid;
  background: rgba(14, 165, 233, 0.10);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
}

.dash-templateSlot__label {
  pointer-events: none;
}

.dash-templateSlot--filled {
  border-style: solid;
  border-color: rgba(14, 165, 233, 0.3);
  background: rgba(14, 165, 233, 0.06);
  color: #1e293b;
  padding: 2px 6px 2px 4px;
  gap: 5px;
}

.dash-templateSlot--filled .dash-templateSlot__label {
  display: none;
}

.dash-templateSlot--filled .dash-templateSlot__logo {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  flex-shrink: 0;
  object-fit: contain;
}

.dash-templateSlot--filled .dash-templateSlot__initials {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  font-weight: 700;
  background: #e2e8f0;
  color: #475569;
  line-height: 1;
}

.dash-templateSlot--filled .dash-templateSlot__name {
  font-weight: 500;
  font-size: 0.85em;
}

.dash-templateSlot--filled .dash-templateSlot__remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  border: none;
  background: none;
  color: #94a3b8;
  font-size: 14px;
  line-height: 1;
  padding: 0;
  cursor: pointer;
  border-radius: 50%;
  flex-shrink: 0;
}

.dash-templateSlot--filled .dash-templateSlot__remove:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.08);
}

/* ── Dark mode overrides for template slots ── */
[data-color-scheme="dark"] .dash-templateSlot {
  border-color: #475569;
  background: rgba(71, 85, 105, 0.15);
  color: #94a3b8;
}
[data-color-scheme="dark"] .dash-templateSlot:hover {
  border-color: var(--color-accent, #38bdf8);
  background: rgba(56, 189, 248, 0.08);
  color: var(--color-accent, #38bdf8);
}
[data-color-scheme="dark"] .dash-templateSlot--filled {
  border-color: rgba(56, 189, 248, 0.25);
  background: rgba(56, 189, 248, 0.06);
  color: #e2e8f0;
}
[data-color-scheme="dark"] .dash-templateSlot--filled .dash-templateSlot__initials {
  background: #334155;
  color: #94a3b8;
}
[data-color-scheme="dark"] .dash-templateSlot--filled .dash-templateSlot__remove {
  color: #64748b;
}
[data-color-scheme="dark"] .dash-templateSlot--filled .dash-templateSlot__remove:hover {
  color: #f87171;
  background: rgba(248, 113, 113, 0.1);
}

/* Slot search input (floating above slot) */
.dash-templateSlot__searchInput {
  width: 220px;
  padding: 6px 10px;
  border: 1.5px solid var(--color-accent, #0ea5e9);
  border-radius: 8px;
  background: #fff;
  color: #1e293b;
  font-size: 13px;
  outline: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.dash-templateSlot__searchInput::placeholder {
  color: #94a3b8;
}
[data-color-scheme="dark"] .dash-templateSlot__searchInput {
  background: #1e293b;
  color: #e2e8f0;
  border-color: var(--color-accent, #38bdf8);
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
[data-color-scheme="dark"] .dash-templateSlot__searchInput::placeholder {
  color: #64748b;
}

/* Send button (inside toolbar) */
.dash-composer__send {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--color-accent, #0ea5e9);
  color: #fff;
  cursor: pointer;
  transition: background 0.15s ease;
}

.dash-composer__send:hover {
  background: var(--color-accent-hover, #0284c7);
}

.dash-composer__send svg {
  display: block;
  transition: transform 0.3s ease;
}

.dash-composer__send.has-exports svg {
  animation: dashSendRotateIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.dash-composer__send.exports-cleared svg {
  animation: dashSendRotateOut 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes dashSendRotateIn {
  0%   { transform: rotate(0deg) scale(1); }
  30%  { transform: rotate(-110deg) scale(1.15); }
  55%  { transform: rotate(-80deg) scale(1.05); }
  75%  { transform: rotate(-95deg) scale(1); }
  100% { transform: rotate(-90deg) scale(1); }
}

@keyframes dashSendRotateOut {
  0%   { transform: rotate(-90deg) scale(1); }
  40%  { transform: rotate(15deg) scale(1.1); }
  70%  { transform: rotate(-5deg) scale(1); }
  100% { transform: rotate(0deg) scale(1); }
}

/* Stop mode – send button becomes a rounded-square stop button */
.dash-composer__send--stop,
.dash-replyBar__send--stop {
  border-radius: 8px;
  background: var(--color-accent, #0ea5e9);
  transition: border-radius 0.2s ease, background 0.15s ease;
}

.dash-composer__send--stop:hover,
.dash-replyBar__send--stop:hover {
  background: var(--color-accent-hover, #0284c7);
}

/* Export button wrapper (replaces old attach/paperclip button) */
.dash-composer__exportWrap {
  position: relative;
}

.dash-composer__export {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: #999;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.dash-composer__export:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #555;
}

.dash-composer__export svg {
  display: block;
}

/* Export dropdown (opens upward) */
.dash-composer__exportDropdown {
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  min-width: 200px;
  padding: 6px 0;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 2px 8px rgba(0, 0, 0, 0.06);
  z-index: 20;
  animation: dashExportDropIn 150ms ease;
}

@keyframes dashExportDropIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dash-composer__exportDropdown.is-hidden {
  display: none;
}

.dash-composer__exportDropdown button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 14px;
  border: none;
  background: transparent;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #334155;
  cursor: pointer;
  transition: background 0.12s;
  text-align: left;
  white-space: nowrap;
}

.dash-composer__exportDropdown button:hover {
  background: #f1f5f9;
}

.dash-composer__exportDropdown button svg {
  flex-shrink: 0;
  display: block;
}

/* Export-format pills container (holds multiple pills) */
.dash-composer__exportPills {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  align-items: center;
  margin-left: auto;
}

.dash-composer__exportPill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px 2px 8px;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
  white-space: nowrap;
  animation: dashPillIn 220ms cubic-bezier(0.34, 1.56, 0.64, 1);
  background: #e2e8f0;
  color: #334155;
}

.dash-composer__exportPill[data-format="pdf"] {
  background: #fee2e2;
  color: #b91c1c;
}

.dash-composer__exportPill[data-format="xlsx"] {
  background: #d1fae5;
  color: #047857;
}

.dash-composer__exportPill[data-format="pptx"] {
  background: #fef3c7;
  color: #b45309;
}

.dash-composer__exportPill svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  display: block;
}

.dash-composer__exportPill-label {
  pointer-events: none;
}

.dash-composer__exportPill-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.08);
  color: inherit;
  font-size: 0.75rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.12s;
}

.dash-composer__exportPill-close:hover {
  background: rgba(0, 0, 0, 0.16);
}

@keyframes dashPillIn {
  from { opacity: 0; transform: scale(0.7); }
  to   { opacity: 1; transform: scale(1); }
}

/* Grid-template pill (same shape as export pills, distinct colour) */
.dash-composer__gridPill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px 2px 8px;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
  white-space: nowrap;
  animation: dashPillIn 220ms cubic-bezier(0.34, 1.56, 0.64, 1);
  background: #e0e7ff;
  color: #3730a3;
}

.dash-composer__gridPill svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  display: block;
}

.dash-composer__gridPill-label {
  pointer-events: none;
}

.dash-composer__gridPill-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.08);
  color: inherit;
  font-size: 0.75rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.12s;
}

.dash-composer__gridPill-close:hover {
  background: rgba(0, 0, 0, 0.16);
}

/* Compose / Templates button (inside composer toolbar, next to Export) */
.dash-composer__composeWrap {
  position: relative;
}

.dash-composer__composeBtn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: #999;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.dash-composer__composeBtn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #555;
}

.dash-composer__composeBtn.is-active {
  background: rgba(0, 0, 0, 0.08);
  color: #333;
}

.dash-composer__composeBtn svg {
  display: block;
}

.dash-composer__composeDropdown {
  position: absolute;
  bottom: calc(100% + 10px);
  right: 0;
  min-width: 320px;
  max-height: 420px;
  overflow-y: auto;
  padding: 6px 0;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 12px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.13), 0 2px 8px rgba(0, 0, 0, 0.06);
  z-index: 25;
  animation: dashComposeDropIn 160ms ease;
}

@keyframes dashComposeDropIn {
  from { opacity: 0; transform: translateY(8px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.dash-composer__composeDropdown.is-hidden {
  display: none;
}

.dash-composer__composeDropdown-header {
  padding: 8px 14px 6px;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #94a3b8;
  pointer-events: none;
}

.dash-composer__composeDropdown .dash-promptBtn {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 9px 14px;
  border: none;
  border-radius: 0;
  background: transparent;
  font-size: 0.8125rem;
  font-weight: 500;
  font-family: inherit;
  color: #334155;
  cursor: pointer;
  text-align: left;
  white-space: nowrap;
  transition: background 0.12s, color 0.12s;
  line-height: 1.4;
}

.dash-composer__composeDropdown .dash-promptBtn:hover {
  background: #f1f5f9;
  color: #1e293b;
}

.dash-composer__composeDropdown .dash-promptBtn:active {
  background: #e2e8f0;
}

/* Scrollbar styling for compose dropdown */
.dash-composer__composeDropdown::-webkit-scrollbar {
  width: 5px;
}

.dash-composer__composeDropdown::-webkit-scrollbar-track {
  background: transparent;
}

.dash-composer__composeDropdown::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.12);
  border-radius: 999px;
}

/* Prompt template tab switcher */
.dash-promptTabs {
  display: flex;
  gap: 2px;
  padding: 6px 10px 4px;
  background: #f8fafc;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 12px 12px 0 0;
}

.dash-promptTab {
  flex: 1;
  padding: 5px 0;
  border: none;
  border-radius: 6px;
  background: transparent;
  font-size: 0.75rem;
  font-weight: 600;
  font-family: inherit;
  color: #94a3b8;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  text-align: center;
}

.dash-promptTab:hover {
  color: #64748b;
  background: rgba(0, 0, 0, 0.04);
}

.dash-promptTab.is-active {
  background: #fff;
  color: #1e293b;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* Prompt group containers (default / shared) */
.dash-promptGroup {
  padding: 2px 0;
}

.dash-promptGroup.is-hidden {
  display: none;
}

/* Shared template button layout adjustments */
.dash-composer__composeDropdown .dash-promptBtn {
  gap: 8px;
  justify-content: space-between;
}

.dash-promptBtn__label {
  flex: 1;
  min-width: 0;
}

/* Source badges (Onyx diamond / Community globe) */
.dash-promptBtn__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 5px;
  transition: background 0.15s;
}

.dash-promptBtn__badge svg {
  display: block;
}

[data-source="onyx"] .dash-promptBtn__badge {
  background: rgba(99, 102, 241, 0.08);
}

[data-source="onyx"] .dash-promptBtn__badge:hover {
  background: rgba(99, 102, 241, 0.16);
}

[data-source="onyx"] .dash-promptBtn__badge img {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

[data-source="community"] .dash-promptBtn__badge {
  color: #0ea5e9;
  background: rgba(14, 165, 233, 0.08);
}

[data-source="community"] .dash-promptBtn__badge:hover {
  background: rgba(14, 165, 233, 0.16);
}

/* Star toggle on template buttons */
.dash-promptBtn__star {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 5px;
  color: #cbd5e1;
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}

.dash-promptBtn__star:hover {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.08);
}

.dash-promptBtn__star.is-starred {
  color: #f59e0b;
}

.dash-promptBtn__star.is-starred svg {
  fill: #f59e0b;
}

.dash-promptBtn__star.is-starred:hover {
  color: #d97706;
  background: rgba(245, 158, 11, 0.10);
}

.dash-promptBtn__star.is-starred:hover svg {
  fill: #d97706;
}

/* Prompt template hover preview popover */
.dash-promptPreview {
  position: fixed;
  z-index: 200;
  width: 340px;
  max-width: calc(100vw - 2rem);
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
  padding: 0.875rem;
  pointer-events: none;
  animation: dashPromptPreviewIn 140ms ease;
}

.dash-promptPreview.is-hidden {
  display: none;
}

@keyframes dashPromptPreviewIn {
  from { opacity: 0; transform: translateX(6px) scale(0.97); }
  to   { opacity: 1; transform: translateX(0) scale(1); }
}

.dash-promptPreview__title {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 2px;
}

.dash-promptPreview__summary {
  font-size: 0.75rem;
  font-style: italic;
  color: #64748b;
  margin-bottom: 8px;
  line-height: 1.4;
}

.dash-promptPreview__text {
  font-size: 0.75rem;
  font-family: inherit;
  line-height: 1.55;
  color: #475569;
  background: #f8fafc;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 8px;
  padding: 10px 12px;
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 140px;
  overflow-y: auto;
}

.dash-promptPreview__text::-webkit-scrollbar {
  width: 4px;
}

.dash-promptPreview__text::-webkit-scrollbar-track {
  background: transparent;
}

.dash-promptPreview__text::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 999px;
}

/* Grid create button (inside composer toolbar) */
.dash-composer__gridWrap {
  position: relative;
}

.dash-composer__gridBtn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: #999;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.dash-composer__gridBtn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #555;
}

.dash-composer__gridBtn svg {
  display: block;
}

/* Row below input: Sources */
.dash-composer__belowHint {
  display: flex;
  align-items: center;
  margin-top: var(--dash-space-1);
}

.dash-composer__textarea::placeholder {
  color: #999;
}

.dash-composer__textarea:focus::placeholder {
  color: transparent;
}

.dash-composer__textarea:focus {
  outline: none;
  border-color: var(--color-accent, #0ea5e9);
  background: #fff;
  box-shadow: 0 0 0 1.5px rgba(14, 165, 233, 0.18);
}

.dash-composer__hint {
  margin: 0 0 var(--dash-space-1);
  font-size: 0.625rem;
  color: #ccc;
}

.dash-composer__sources {
  margin: 0;
  font-size: 0.6875rem;
  color: #a8a8a8;
  opacity: 1;
  transition: opacity 0.2s ease;
}

/* Composer input wrap */
.dash-composer__inputWrap {
  position: relative;
}

/* Toolbar row: toggle + paperclip + send, pinned to bottom of input */
.dash-composer__toolbar {
  position: absolute;
  bottom: 0.5rem;
  left: 0.875rem;
  right: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.dash-composer__staticHint {
  position: absolute;
  top: 6.5rem;
  bottom: 5.5rem;
  overflow: hidden;
  left: 0.875rem;
  right: 0.875rem;
  font-size: 0.9375rem;
  line-height: 1.5;
  font-family: inherit;
  color: #999;
  pointer-events: none;
}

/* Slash autocomplete popup – positioned by JS at caret coordinates */
.dash-slashPopup {
  position: absolute;
  z-index: 30;
  margin-top: 4px;
  width: 380px;
  max-height: 360px;
  overflow-y: auto;
  background: #fff;
  border: var(--dash-border);
  border-radius: var(--dash-radius);
  box-shadow: var(--dash-shadow-card);
}

.dash-slashPopup.is-hidden { display: none; }

.dash-slashPopup__item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: none;
  background: transparent;
  font-size: 0.8125rem;
  font-family: inherit;
  cursor: pointer;
  text-align: left;
}

.dash-slashPopup__item:hover,
.dash-slashPopup__item.is-active {
  background: #f1f5f9;
}

.dash-slashPopup__logo {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}

.dash-slashPopup__initials {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #64748b;
  font-size: 0.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dash-slashPopup__text {
  display: flex;
  align-items: baseline;
  gap: 0.375rem;
  min-width: 0;
  flex: 1;
}

.dash-slashPopup__name {
  font-weight: 600;
  color: #111;
}

.dash-slashPopup__ticker {
  font-size: 0.6875rem;
  color: #888;
  margin-left: auto;
}

.dash-slashPopup__chevron {
  flex-shrink: 0;
  margin-left: auto;
  font-size: 0.875rem;
  color: #94a3b8;
  line-height: 1;
}

.dash-slashPopup__back {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  width: 100%;
  padding: 0.45rem 0.75rem;
  border: none;
  border-bottom: 1px solid #e2e8f0;
  background: transparent;
  font-size: 0.75rem;
  font-weight: 700;
  color: #475569;
  font-family: inherit;
  cursor: pointer;
  text-align: left;
}

.dash-slashPopup__back:hover {
  background: #f8fafc;
}

.dash-slashPopup__backArrow {
  font-size: 0.75rem;
  color: #94a3b8;
}

.dash-slashPopup__back--compact {
  width: auto;
  padding: 0.35rem 0.6rem;
  border-bottom: none;
  font-size: 0.8125rem;
}

.dash-slashPopup__item--action {
  border-bottom: 1px solid #e2e8f0;
}

.dash-slashPopup__item--action:hover,
.dash-slashPopup__item--action.is-active {
  background: #f0fdfa;
}

.dash-slashPopup__newsIcon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: #0d9488;
}

.dash-slashPopup__indication {
  font-size: 0.6875rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}

.dash-slashPopup__stage {
  flex-shrink: 0;
  margin-left: auto;
  font-size: 0.5625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.125rem 0.4rem;
  border-radius: 999px;
  background: #e2e8f0;
  color: #475569;
  white-space: nowrap;
}

/* Group header labels inside slash popup */
.dash-slashPopup__groupLabel {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem 0.25rem;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #94a3b8;
  border-top: 1px solid #f1f5f9;
  user-select: none;
}

.dash-slashPopup__groupLabel:first-child {
  border-top: none;
  padding-top: 0.35rem;
}

.dash-slashPopup__groupLabel svg {
  flex-shrink: 0;
  opacity: 0.7;
}

/* Category icon next to non-company items */
.dash-slashPopup__categoryIcon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dash-slashPopup__categoryIcon--condition-eye {
  color: #0d9488;
  background: #ccfbf1;
}
.dash-slashPopup__categoryIcon--condition-brain {
  color: #7c3aed;
  background: #ede9fe;
}
.dash-slashPopup__categoryIcon--condition-liver {
  color: #d97706;
  background: #fef3c7;
}
.dash-slashPopup__categoryIcon--condition-heart {
  color: #e11d48;
  background: #ffe4e6;
}

.dash-slashPopup__categoryIcon--target {
  color: #7c3aed;
  background: #f5f3ff;
}

.dash-slashPopup__categoryIcon--asset {
  color: #0891b2;
  background: #ecfeff;
}

/* Right-side tag for conditions and targets */
.dash-slashPopup__tag {
  flex-shrink: 0;
  margin-left: auto;
  font-size: 0.5625rem;
  font-weight: 600;
  padding: 0.1rem 0.375rem;
  border-radius: 999px;
  white-space: nowrap;
}

.dash-slashPopup__tag--condition {
  background: #fff1f2;
  color: #be123c;
}
.dash-slashPopup__tag--ophthalmology {
  background: #ccfbf1;
  color: #0d9488;
}
.dash-slashPopup__tag--neurology {
  background: #ede9fe;
  color: #7c3aed;
}
.dash-slashPopup__tag--hepatology {
  background: #fef3c7;
  color: #d97706;
}
.dash-slashPopup__tag--hematology {
  background: #ffe4e6;
  color: #be123c;
}

.dash-slashPopup__tag--target {
  background: #f5f3ff;
  color: #6d28d9;
}

/* Asset company name (smaller, muted) */
.dash-slashPopup__assetCompany {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.6875rem;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 120px;
}

.dash-slashPopup__assetCompany .dash-companyPill__logo {
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

/* ── Slash-search hover popover (right-side detail card) ── */
.dash-slashHoverPopover {
  position: fixed;
  z-index: 31;
  width: 280px;
  background: #fff;
  border: 1px solid var(--dash-border);
  border-radius: var(--dash-radius);
  box-shadow: var(--dash-shadow-card);
  padding: 0.75rem;
  pointer-events: none;
  border-left: 3px solid #94a3b8;
  animation: dashSlashHoverIn 140ms ease;
}

.dash-slashHoverPopover.is-hidden {
  display: none;
}

@keyframes dashSlashHoverIn {
  from { opacity: 0; transform: translateX(6px) scale(0.97); }
  to   { opacity: 1; transform: translateX(0) scale(1); }
}

.dash-slashHoverPopover--company        { border-left-color: #2563eb; }
.dash-slashHoverPopover--condition      { border-left-color: #e11d48; }
.dash-slashHoverPopover--condition-eye  { border-left-color: #0d9488; }
.dash-slashHoverPopover--condition-brain { border-left-color: #7c3aed; }
.dash-slashHoverPopover--condition-liver { border-left-color: #d97706; }
.dash-slashHoverPopover--condition-heart { border-left-color: #e11d48; }
.dash-slashHoverPopover--asset         { border-left-color: #0891b2; }

.dash-slashHoverPopover__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.375rem;
}

.dash-slashHoverPopover__logo {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: contain;
  border: 1px solid rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.dash-slashHoverPopover__initials {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #475569;
  font-size: 0.625rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dash-slashHoverPopover__typeIcon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dash-slashHoverPopover__typeIcon--condition-eye {
  color: #0d9488;
  background: #ccfbf1;
}
.dash-slashHoverPopover__typeIcon--condition-brain {
  color: #7c3aed;
  background: #ede9fe;
}
.dash-slashHoverPopover__typeIcon--condition-liver {
  color: #d97706;
  background: #fef3c7;
}
.dash-slashHoverPopover__typeIcon--condition-heart {
  color: #e11d48;
  background: #fff1f2;
}

.dash-slashHoverPopover__typeIcon--asset {
  color: #0891b2;
  background: #ecfeff;
}

.dash-slashHoverPopover__badge {
  font-size: 0.5625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.375rem;
  border-radius: 3px;
  flex-shrink: 0;
  line-height: 1.5;
}

.dash-slashHoverPopover--company .dash-slashHoverPopover__badge {
  background: #eff6ff;
  color: #2563eb;
}

.dash-slashHoverPopover--condition-eye .dash-slashHoverPopover__badge {
  background: #ccfbf1;
  color: #0d9488;
}
.dash-slashHoverPopover--condition-brain .dash-slashHoverPopover__badge {
  background: #ede9fe;
  color: #7c3aed;
}
.dash-slashHoverPopover--condition-liver .dash-slashHoverPopover__badge {
  background: #fef3c7;
  color: #d97706;
}
.dash-slashHoverPopover--condition-heart .dash-slashHoverPopover__badge {
  background: #fff1f2;
  color: #be123c;
}

.dash-slashHoverPopover--asset .dash-slashHoverPopover__badge {
  background: #ecfeff;
  color: #0891b2;
}

.dash-slashHoverPopover__name {
  font-weight: 600;
  font-size: 0.8125rem;
  color: #1e293b;
  line-height: 1.3;
}

.dash-slashHoverPopover__ticker {
  font-weight: 400;
  color: #94a3b8;
  margin-left: 0.25rem;
}

.dash-slashHoverPopover__blurb {
  font-size: 0.75rem;
  color: #555;
  margin-top: 0.375rem;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dash-slashHoverPopover__meta {
  font-size: 0.6875rem;
  color: #888;
  margin-top: 0.375rem;
  line-height: 1.3;
}

.dash-slashHoverPopover__tag {
  display: inline-block;
  font-size: 0.5625rem;
  font-weight: 600;
  padding: 0.1rem 0.375rem;
  border-radius: 999px;
  white-space: nowrap;
  margin-left: 0.35rem;
  vertical-align: baseline;
}

.dash-slashHoverPopover__tag--condition {
  background: #fff1f2;
  color: #be123c;
}

.dash-slashHoverPopover__tag--stage {
  background: #e2e8f0;
  color: #475569;
}

.dash-slashHoverPopover__detail {
  font-size: 0.6875rem;
  color: #64748b;
  margin-top: 0.25rem;
  line-height: 1.4;
}

.dash-slashHoverPopover__detail strong {
  color: #475569;
  font-weight: 600;
}

/* Pill color variants for non-company items */
.dash-greetingPill--condition {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #be123c;
}

.dash-greetingPill--target {
  background: #f5f3ff;
  border-color: #ddd6fe;
  color: #6d28d9;
}

.dash-greetingPill--asset {
  background: #ecfeff;
  border-color: #a5f3fc;
  color: #0e7490;
}

.dash-trialPill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.5rem 0.15rem 0.25rem;
  background: #e0ecff;
  border: 1px solid #bdd3f0;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #1e3a5f;
  line-height: 1.3;
  white-space: nowrap;
  cursor: pointer;
}

.dash-trialPill__remove {
  margin-left: 0.15rem;
  padding: 0;
  border: none;
  background: none;
  color: #7ea6cf;
  font-size: 0.8125rem;
  line-height: 1;
  cursor: pointer;
}

.dash-trialPill__remove:hover { color: #2b5f8a; }

/* Company pill tags below textarea */
.dash-companyPills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  padding: 0.25rem 0;
  min-height: 0;
}

.dash-companyPills:empty { display: none; }

.dash-companyPill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.5rem 0.15rem 0.25rem;
  background: #e9eef5;
  border: 1px solid #d5dce6;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #334155;
  line-height: 1.3;
  white-space: nowrap;
  cursor: pointer;
}

.dash-companyPill__logo {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}

.dash-companyPill__initials {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #d5dce6;
  color: #64748b;
  font-size: 0.45rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dash-companyPill__remove {
  margin-left: 0.15rem;
  padding: 0;
  border: none;
  background: none;
  color: #94a3b8;
  font-size: 0.8125rem;
  line-height: 1;
  cursor: pointer;
}

.dash-companyPill__remove:hover { color: #475569; }

/* ── Company pill popover ── */
.dash-pillPopover {
  position: fixed;
  width: 280px;
  background: #fff;
  border: 1px solid var(--dash-border);
  border-radius: var(--dash-radius);
  box-shadow: var(--dash-shadow-card);
  padding: 0.75rem;
  z-index: 40;
  pointer-events: auto;
}

.dash-pillPopover.is-hidden {
  display: none;
}

.dash-pillPopover__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.dash-pillPopover__logo {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: contain;
  border: 1px solid rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.dash-pillPopover__initials {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #475569;
  font-size: 0.625rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dash-pillPopover__name {
  font-weight: 600;
  font-size: 0.8125rem;
  color: #1e293b;
  line-height: 1.3;
}

.dash-pillPopover__ticker {
  font-weight: 400;
  color: #94a3b8;
  margin-left: 0.25rem;
}

.dash-pillPopover__blurb {
  font-size: 0.75rem;
  color: #555;
  margin-top: 0.375rem;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dash-pillPopover__meta {
  font-size: 0.6875rem;
  color: #888;
  margin-top: 0.375rem;
  line-height: 1.3;
}

/* ── Large popover variant (greeting pills) ── */
.dash-pillPopover--lg {
  width: 340px;
  padding: 1rem;
}

.dash-pillPopover--lg .dash-pillPopover__logo {
  width: 32px;
  height: 32px;
}

.dash-pillPopover--lg .dash-pillPopover__initials {
  width: 32px;
  height: 32px;
  font-size: 0.75rem;
}

.dash-pillPopover--lg .dash-pillPopover__name {
  font-size: 0.9375rem;
}

.dash-pillPopover--lg .dash-pillPopover__blurb {
  font-size: 0.8125rem;
  margin-top: 0.5rem;
}

.dash-pillPopover--lg .dash-pillPopover__meta {
  font-size: 0.75rem;
  margin-top: 0.5rem;
}

.dash-pillPopover__footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.5rem;
  padding-top: 0.4rem;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
}

.dash-pillPopover__readMore {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #0056b3;
  cursor: pointer;
  text-decoration: none;
  transition: color 0.15s ease;
}

.dash-pillPopover__readMore:hover {
  color: #003d80;
  text-decoration: underline;
}

.dash-greetingPill {
  cursor: pointer;
}

/* ── Inline entity highlights ── */
.dash-entity {
  cursor: pointer;
  border-radius: 3px;
  padding: 0.05em 0.15em;
  border-bottom: 1.5px solid transparent;
  transition: background 0.15s ease, border-color 0.15s ease;
  text-decoration: none;
}

.dash-entity--company {
  background: #eff6ff;
  border-bottom-color: #2563eb;
  color: inherit;
}
.dash-entity--company:hover {
  background: #dbeafe;
}

.dash-entity--drug {
  background: #f5f3ff;
  border-bottom-color: #7c3aed;
  color: inherit;
}
.dash-entity--drug:hover {
  background: #ede9fe;
}

.dash-entity--condition {
  background: #fffbeb;
  border-bottom-color: #d97706;
  color: inherit;
}
.dash-entity--condition:hover {
  background: #fef3c7;
}

.dash-entity--target {
  background: #f0fdfa;
  border-bottom-color: #0d9488;
  color: inherit;
}
.dash-entity--target:hover {
  background: #ccfbf1;
}

/* ── Query entity pills (shown instantly on chat submit) ── */
.dash-queryPills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 8px 0 4px;
  margin-left: 2px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.dash-queryPills--visible {
  opacity: 1;
  transform: translateY(0);
}

.dash-queryPill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: 16px;
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  border-bottom: none !important;
  line-height: 1.3;
  user-select: none;
}
.dash-queryPill:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}
.dash-queryPill:active {
  transform: translateY(0);
}

.dash-queryPill__name {
  white-space: nowrap;
}
.dash-queryPill__badge {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.06);
  color: inherit;
  opacity: 0.7;
  white-space: nowrap;
}
.dash-queryPill__sub {
  font-size: 0.65rem;
  opacity: 0.55;
  white-space: nowrap;
}
.dash-queryPill__sub::before {
  content: '\00b7';
  margin-right: 2px;
}

.dash-queryPill .dash-companyPill__logo {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  flex-shrink: 0;
}
.dash-queryPill .dash-companyPill__initials {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  font-size: 0.55rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

/* ── Inline query pills (embedded in user bubble text) ── */
.dash-queryPill--inline {
  display: inline-flex;
  vertical-align: baseline;
  padding: 2px 8px;
  margin: -1px 1px;
  font-size: 0.82em;
  border-radius: 14px;
  line-height: 1.4;
}
.dash-queryPill--inline .dash-queryPill__badge {
  font-size: 0.62em;
  padding: 0 4px;
}
.dash-queryPill--inline .dash-queryPill__sub {
  font-size: 0.62em;
}
.dash-queryPill--inline .dash-companyPill__logo,
.dash-queryPill--inline .dash-companyPill__initials {
  width: 14px;
  height: 14px;
}

/* ── "Identifying entities…" shimmer indicator ── */
.dash-entity__analyzing {
  font-size: 0.7rem;
  color: #94a3b8;
  margin-top: 0.5rem;
  padding: 0.25rem 0;
  animation: dashEntityPulse 1.5s ease-in-out infinite;
}
@keyframes dashEntityPulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* ── Entity popover ── */
.dash-entityPopover {
  position: fixed;
  width: 300px;
  background: #fff;
  border: 1px solid var(--dash-border);
  border-radius: var(--dash-radius);
  box-shadow: var(--dash-shadow-card);
  padding: 0.75rem;
  z-index: 41;
  pointer-events: auto;
  border-left: 3px solid #94a3b8;
}
.dash-entityPopover.is-hidden {
  display: none;
}

.dash-entityPopover--drug    { border-left-color: #7c3aed; }
.dash-entityPopover--condition { border-left-color: #d97706; }
.dash-entityPopover--target  { border-left-color: #0d9488; }

/* Company-type entity popover: rich card matching the pill popover */
.dash-entityPopover--company {
  width: 320px;
  border-left: none;
}

.dash-entityPopover__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.375rem;
}

.dash-entityPopover__badge {
  font-size: 0.625rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  flex-shrink: 0;
  line-height: 1.5;
}
.dash-entityPopover--company .dash-entityPopover__badge {
  background: #eff6ff;
  color: #2563eb;
}
.dash-entityPopover--drug .dash-entityPopover__badge {
  background: #f5f3ff;
  color: #7c3aed;
}
.dash-entityPopover--condition .dash-entityPopover__badge {
  background: #fffbeb;
  color: #d97706;
}
.dash-entityPopover--target .dash-entityPopover__badge {
  background: #f0fdfa;
  color: #0d9488;
}

.dash-entityPopover__name {
  font-weight: 600;
  font-size: 0.8125rem;
  color: #1e293b;
  line-height: 1.3;
}

.dash-entityPopover__desc {
  font-size: 0.75rem;
  color: #555;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── Rich company entity popover elements ── */
.dash-entityPopover__logo {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: contain;
  border: 1px solid rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.dash-entityPopover__initials {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #475569;
  font-size: 0.65rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dash-entityPopover__ticker {
  font-weight: 400;
  color: #94a3b8;
  margin-left: 0.25rem;
}

.dash-entityPopover__blurb {
  font-size: 0.75rem;
  color: #555;
  margin-top: 0.375rem;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dash-entityPopover__meta {
  font-size: 0.6875rem;
  color: #888;
  margin-top: 0.375rem;
  line-height: 1.3;
}

.dash-entityPopover__footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.5rem;
  padding-top: 0.4rem;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
}

.dash-entityPopover__readMore {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #0056b3;
  cursor: pointer;
  transition: color 0.15s ease;
}

.dash-entityPopover__readMore:hover {
  color: #003d80;
  text-decoration: underline;
}

.dash-entityPopover__graphLink {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #6366f1;
  cursor: pointer;
}

.dash-entityPopover__graphLink:hover {
  color: #4f46e5;
  text-decoration: underline;
}

.dash-entity--resolved {
  border-bottom: 1px dotted currentColor;
}

/* ── Knowledge Graph inline view ── */
.dash-graphView {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
}
.dash-graphView.is-hidden {
  display: none;
}
.dash-main--graphActive {
  justify-content: flex-start;
  padding-top: 0;
  max-width: none;
  justify-self: stretch;
}
.dash-main--graphActive .dash-chatTopbar {
  display: none;
}
.dash-main--graphActive .dash-main__inner {
  display: none;
}
.dash-graphView__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #e2e8f0;
}
.dash-graphView__back {
  background: none;
  border: none;
  color: #475569;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
}
.dash-graphView__back:hover {
  background: #f1f5f9;
  color: #1e293b;
}
.dash-graphView__title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #1e293b;
  margin: 0;
}
.dash-graphView__body {
  flex: 1;
  position: relative;
  overflow: hidden;
  background: #fff;
}
.dash-graphView__loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  font-size: 0.875rem;
}
.dash-graphView__svg {
  width: 100%;
  height: 100%;
}
.dash-graphView__legend {
  display: none;
}
.dash-graphView__legendBtn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.55rem;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #fff;
  font-size: 0.6875rem;
  font-family: inherit;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1.4;
  white-space: nowrap;
  opacity: 0.5;
  text-decoration: line-through;
}
.dash-graphView__legendBtn.is-active {
  color: #1e293b;
  border-color: #cbd5e1;
  opacity: 1;
  text-decoration: none;
}
.dash-graphView__legendBtn:hover {
  background: #f8fafc;
  border-color: #94a3b8;
}
.dash-graphView__legendBtn.is-active:hover {
  background: #f1f5f9;
}
.dash-graphView__legendBtn svg {
  flex-shrink: 0;
  transition: opacity 0.2s ease;
}
.dash-graphView__legendBtn:not(.is-active) svg {
  opacity: 0.35;
}

/* Filter toggle button in graph header */
.dash-graphView__filterBtn {
  background: none;
  border: 1px solid #e2e8f0;
  color: #475569;
  cursor: pointer;
  padding: 0.3rem 0.5rem;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  margin-left: auto;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.dash-graphView__filterBtn:hover {
  background: #f1f5f9;
  color: #1e293b;
  border-color: #cbd5e1;
}

/* Filter sidebar overlay */
.dash-graphView__sidebar {
  position: absolute;
  top: 0;
  right: 0;
  width: 210px;
  height: 100%;
  background: #fff;
  border-left: 1px solid #e2e8f0;
  box-shadow: -4px 0 12px rgba(0, 0, 0, 0.06);
  overflow-y: auto;
  z-index: 10;
  padding: 0.75rem 0;
}
.dash-graphView__sidebar.is-hidden {
  display: none;
}
.dash-graphView__sidebarSection {
  padding: 0 0.75rem 0.5rem;
}
.dash-graphView__sidebarSection + .dash-graphView__sidebarSection {
  border-top: 1px solid #f1f5f9;
  padding-top: 0.5rem;
}
.dash-graphView__sidebarTitle {
  font-size: 0.6875rem;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.4rem;
}
.dash-graphView__sidebarBtns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

/* ==========================================================================
   Graph node selection & comparison
   ========================================================================== */

/* Rubber-band selection rectangle */
.dash-graphSelect__rect {
  fill: rgba(37, 99, 235, 0.08);
  stroke: #2563eb;
  stroke-width: 1.5;
  stroke-dasharray: 5 3;
  pointer-events: none;
}

/* Pulsing glow ring for same-type nodes */
@keyframes dashNodeGlow {
  0%, 100% { opacity: 0.25; }
  50% { opacity: 0.55; }
}
.dash-graphNode__glow {
  pointer-events: none;
  animation: dashNodeGlow 1.8s ease-in-out infinite;
}

/* Dimmed state for non-matching nodes/links */
.dash-graphNode--dimmed {
  opacity: 0.2;
  transition: opacity 0.25s ease;
}
.dash-graphLink--dimmed {
  opacity: 0.08;
  transition: opacity 0.25s ease;
}

/* Pinned info card (foreignObject inside SVG) */
.dash-graphNode__infoCard {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 6px 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.10);
  font-family: inherit;
  font-size: 0.6875rem;
  line-height: 1.4;
  min-width: 120px;
  max-width: 200px;
  pointer-events: none;
}
.dash-graphNode__infoCard-badge {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.5625rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 2px;
}
.dash-graphNode__infoCard-name {
  font-weight: 600;
  color: #1e293b;
  display: block;
  margin-bottom: 2px;
}
.dash-graphNode__infoCard-prop {
  color: #64748b;
  font-size: 0.625rem;
}

/* Floating comparison CTA bar */
.dash-graphCompare__cta {
  position: absolute;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 1.25rem;
  background: #1e293b;
  color: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.18);
  z-index: 10;
  font-size: 0.8125rem;
  font-weight: 500;
  white-space: nowrap;
  animation: dashCtaSlideUp 0.3s ease both;
}
@keyframes dashCtaSlideUp {
  from { opacity: 0; transform: translateX(-50%) translateY(12px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}
.dash-graphCompare__cta.is-hidden {
  display: none;
}
.dash-graphCompare__ctaLabel {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.dash-graphCompare__ctaCount {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  padding: 0 5px;
  background: #2563eb;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.75rem;
}
.dash-graphCompare__ctaBtn {
  padding: 0.4rem 1rem !important;
  font-size: 0.8125rem !important;
  border-radius: 8px !important;
}
.dash-graphCompare__ctaClear {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 1.125rem;
  cursor: pointer;
  padding: 0 0.25rem;
  line-height: 1;
  transition: color 0.15s;
}
.dash-graphCompare__ctaClear:hover {
  color: #fff;
}

/* Zoom / Pan controls (bottom-right) */
.dash-graphView__controls {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}
.dash-graphView__controlGroup {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  overflow: hidden;
}
.dash-graphView__controlBtn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: #fff;
  border: none;
  color: #475569;
  cursor: pointer;
  padding: 0;
  transition: background 0.15s, color 0.15s;
}
.dash-graphView__controlBtn:hover {
  background: #f1f5f9;
  color: #1e293b;
}
.dash-graphView__controlBtn.is-active {
  background: #e0e7ff;
  color: #4338ca;
}
.dash-graphView__controlBtn + .dash-graphView__controlBtn {
  border-top: 1px solid #e2e8f0;
}
.dash-graphView__controlBtn svg {
  flex-shrink: 0;
}
.dash-graphView__sidebar:not(.is-hidden) ~ .dash-graphView__controls {
  right: 222px;
}

/* ==========================================================================
   Comparison configuration modal
   ========================================================================== */

.dash-compareModal__overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(4px);
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dash-compareModal__overlay.is-hidden {
  display: none;
}
.dash-compareModal {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.18);
  width: 540px;
  max-width: 94vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  animation: dashModalFadeIn 0.2s ease both;
}
@keyframes dashModalFadeIn {
  from { opacity: 0; transform: translateY(8px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.dash-compareModal__header {
  padding: 1.25rem 1.5rem 0.75rem;
  position: relative;
}
.dash-compareModal__title {
  font-size: 1.125rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0;
}
.dash-compareModal__subtitle {
  font-size: 0.8125rem;
  color: #64748b;
  margin: 0.25rem 0 0;
}
.dash-compareModal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #94a3b8;
  cursor: pointer;
  line-height: 1;
  padding: 0.25rem;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}
.dash-compareModal__close:hover {
  background: #f1f5f9;
  color: #1e293b;
}
.dash-compareModal__body {
  flex: 1;
  overflow-y: auto;
  padding: 0 1.5rem 1rem;
}
.dash-compareModal__section {
  margin-bottom: 1.5rem;
}
.dash-compareModal__sectionTitle {
  font-size: 0.875rem;
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 0.625rem;
}
.dash-compareModal__options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.dash-compareModal__chip {
  cursor: pointer;
}
.dash-compareModal__chip input {
  display: none;
}
.dash-compareModal__chip span {
  display: inline-block;
  padding: 0.375rem 0.875rem;
  border: 1.5px solid #e2e8f0;
  border-radius: 20px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #475569;
  transition: all 0.15s;
  user-select: none;
}
.dash-compareModal__chip:hover span {
  border-color: #cbd5e1;
  background: #f8fafc;
}
.dash-compareModal__chip input:checked + span {
  border-color: #2563eb;
  background: #eff6ff;
  color: #2563eb;
  font-weight: 600;
}
.dash-compareModal__otherInput {
  display: block;
  width: 100%;
  margin-top: 0.5rem;
  padding: 0.5rem 0.75rem;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  font-size: 0.8125rem;
  font-family: inherit;
  color: #1e293b;
  outline: none;
  transition: border-color 0.15s;
}
.dash-compareModal__otherInput:focus {
  border-color: #2563eb;
}
.dash-compareModal__otherInput.is-hidden {
  display: none;
}

/* Q3 dimension rows */
.dash-compareModal__dimensions {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.dash-compareModal__dim {
  border: 1.5px solid #f1f5f9;
  border-radius: 10px;
  transition: border-color 0.15s, background 0.15s;
}
.dash-compareModal__dim:hover {
  border-color: #e2e8f0;
}
.dash-compareModal__dim.is-checked {
  border-color: #2563eb;
  background: #f8faff;
}
.dash-compareModal__dimHeader {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 0.75rem;
  cursor: pointer;
  user-select: none;
}
.dash-compareModal__dimHeader input[type="checkbox"] {
  accent-color: #2563eb;
  width: 16px;
  height: 16px;
  cursor: pointer;
  flex-shrink: 0;
}
.dash-compareModal__dimName {
  flex: 1;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #1e293b;
}
.dash-compareModal__dimInfo {
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 2px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s, background 0.15s;
  flex-shrink: 0;
}
.dash-compareModal__dimInfo:hover {
  color: #2563eb;
  background: #eff6ff;
}
.dash-compareModal__dimDesc {
  margin: 0;
  padding: 0 0.75rem 0.625rem 2.4rem;
  font-size: 0.75rem;
  line-height: 1.55;
  color: #64748b;
  max-height: 200px;
  overflow: hidden;
  transition: max-height 0.25s ease, padding 0.25s ease, opacity 0.25s ease;
  opacity: 1;
}
.dash-compareModal__dimDesc.is-hidden {
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  opacity: 0;
}

/* Modal footer */
.dash-compareModal__footer {
  padding: 0.75rem 1.5rem 1.25rem;
  display: flex;
  justify-content: flex-end;
  border-top: 1px solid #f1f5f9;
}
.dash-compareModal__generate {
  padding: 0.5rem 1.5rem !important;
  font-size: 0.875rem !important;
  border-radius: 10px !important;
}
.dash-compareModal__generate:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ── Grid entity highlights – tighter padding in table cells ── */
.dash-gridTable .dash-entity {
  padding: 0 0.1em;
}

.dash-faReport .dash-entity {
  padding: 0.05em 0.2em;
}

/* ── Entity drag feedback ── */
.dash-entity[draggable="true"] {
  cursor: grab;
}
.dash-entity--dragging {
  opacity: 0.45;
  transform: scale(0.96);
}

/* ── Watchlist drop-target highlight ── */
.dash-watchlist--dropTarget {
  outline: 2px dashed #2563eb;
  outline-offset: -2px;
  background: rgba(37, 99, 235, 0.04);
  border-radius: var(--dash-radius);
  transition: outline-color 0.15s, background 0.15s;
}

/* ── Watchlist row drop-in animation ── */
.dash-watchlist__row--dropping {
  animation: dashWatchlistDropIn 0.45s ease both;
}
@keyframes dashWatchlistDropIn {
  0%   { opacity: 0; transform: translateX(-12px); background: #dbeafe; }
  60%  { opacity: 1; transform: translateX(2px); background: #eff6ff; }
  100% { opacity: 1; transform: translateX(0); background: transparent; }
}

/* ── Watchlist row dragging state ── */
.dash-watchlist__row--dragging {
  opacity: 0.5;
}
.dash-watchlist__row[draggable="true"] {
  cursor: grab;
}
.dash-watchlist__row[draggable="true"]:active {
  cursor: grabbing;
}

/* ── Watchlist row removal animation ── */
.dash-watchlist__row--removing {
  animation: dashWatchlistRemove 0.25s ease forwards;
  pointer-events: none;
}
@keyframes dashWatchlistRemove {
  to { opacity: 0; transform: translateX(20px); height: 0; padding: 0; margin: 0; overflow: hidden; }
}

/* ── Watchlist right-click context menu ── */
.dash-watchlist__contextMenu {
  position: fixed;
  z-index: 60;
  min-width: 190px;
  padding: 4px 0;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 2px 6px rgba(0, 0, 0, 0.06);
}
.dash-watchlist__contextMenu.is-hidden {
  display: none;
}
.dash-watchlist__contextMenuItem {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 14px;
  border: none;
  background: none;
  font-size: 0.8125rem;
  color: #dc2626;
  cursor: pointer;
  transition: background 0.1s;
  text-align: left;
  font-family: inherit;
}
.dash-watchlist__contextMenuItem:hover {
  background: #fef2f2;
}
.dash-watchlist__contextMenuItem svg {
  flex-shrink: 0;
  color: #dc2626;
}

/* Icon-only button (attach, etc.) */
.dash-btn--icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  padding: 0.6rem 0;
  border: 1.5px solid rgba(0, 0, 0, 0.15);
  border-radius: var(--dash-radius);
  background: transparent;
  color: #666;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.dash-btn--icon:hover {
  background: #f1f5f9;
  border-color: rgba(0, 0, 0, 0.25);
  color: #333;
}

/* Attachments bar (legacy -- replaced by dash-attachCard UI) */

/* ==========================================================================
   Attached file cards  (Gemini / ChatGPT style)
   ========================================================================== */

.dash-composer__attachCards {
  position: absolute;
  bottom: 2.75rem;
  left: 0.75rem;
  right: 0.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.5rem 0;
  z-index: 2;
}

.dash-composer__attachCards.is-hidden {
  display: none;
}

.dash-composer__inputWrap.has-attachments .dash-composer__textarea {
  padding-bottom: 7.5rem;
}

.dash-composer__inputWrap.has-attachments .dash-composer__dropHint {
  display: none;
}

.dash-composer__inputWrap.has-attachments .dash-composer__staticHint {
  display: none;
}

.dash-attachCard {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 140px;
  max-width: 200px;
  padding: 0.5rem 2rem 0.5rem 0.5rem;
  background: #e8edf2;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 10px;
  cursor: default;
  transition: background 0.15s ease, box-shadow 0.15s ease;
  animation: dashAttachCardIn 200ms ease;
}

@keyframes dashAttachCardIn {
  from { opacity: 0; transform: scale(0.92); }
  to   { opacity: 1; transform: scale(1); }
}

.dash-attachCard:hover {
  background: #dce3ea;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.dash-attachCard__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 8px;
}

.dash-attachCard__icon svg {
  display: block;
}

.dash-attachCard__icon--pdf {
  background: #fde8e8;
  color: #dc2626;
}

.dash-attachCard__icon--doc {
  background: #dbeafe;
  color: #2563eb;
}

.dash-attachCard__icon--ppt {
  background: #fef3c7;
  color: #d97706;
}

.dash-attachCard__icon--xls {
  background: #d1fae5;
  color: #059669;
}

.dash-attachCard__icon--img {
  background: #ede9fe;
  color: #7c3aed;
}

.dash-attachCard__icon--default {
  background: #f1f5f9;
  color: #64748b;
}

.dash-attachCard__icon--workspace {
  background: #e0e7ff;
  color: #4338ca;
}

.dash-attachCard__icon--grid {
  background: #dcfce7;
  color: #16a34a;
}

.dash-attachCard__icon--chat {
  background: #dbeafe;
  color: #2563eb;
}

/* Dragging state for workspace history rows */
.dash-analyses__row--dragging {
  opacity: 0.45;
}

.dash-attachCard__info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  overflow: hidden;
  min-width: 0;
}

.dash-attachCard__name {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1e293b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.dash-attachCard__template {
  font-size: 0.5625rem;
  font-weight: 600;
  color: #0ea5e9;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  line-height: 1.3;
}

.dash-attachCard__type {
  font-size: 0.6875rem;
  font-weight: 500;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.3;
}

.dash-attachCard__remove {
  position: absolute;
  top: 4px;
  right: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.06);
  color: #64748b;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.dash-attachCard__remove svg {
  display: block;
}

.dash-attachCard:hover .dash-attachCard__remove {
  opacity: 1;
}

.dash-attachCard__remove:hover {
  background: rgba(0, 0, 0, 0.12);
  color: #1e293b;
}

.dash-attachCard__remove:focus-visible {
  opacity: 1;
  outline: 2px solid var(--color-accent, #0ea5e9);
  outline-offset: 1px;
}

.dash-composer__modes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: var(--dash-space-1);
}

.dash-mode-pill {
  padding: 0.3rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 500;
  border: var(--dash-border);
  border-radius: 999px;
  background: #fff;
  color: #555;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s;
}

.dash-mode-pill:hover {
  background: #f8fafc;
  border-color: rgba(0, 0, 0, 0.12);
}

.dash-mode-pill--active {
  background: var(--color-accent, #0ea5e9);
  color: #fff;
  border-color: var(--color-accent, #0ea5e9);
}


.dash-composer__micro {
  margin: 0;
  font-size: 0.75rem;
  color: #888;
  line-height: 1.4;
}

.dash-composer__validation {
  margin: 0.5rem 0 0;
  font-size: 0.8125rem;
  color: #b91c1c;
}

/* Deep Research toggle */
.dash-controls {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dash-modeLabel {
  font-size: 0.75rem;
  font-weight: 600;
  color: #666;
}

.dash-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  width: 34px;
  height: 20px;
  cursor: pointer;
}

.dash-switch__input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.dash-switch__slider {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 999px;
  background: #d1d5db;
  transition: background-color 0.15s ease;
}

.dash-switch__slider::before {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
  transition: transform 0.15s ease;
}

.dash-switch__input:checked + .dash-switch__slider {
  background: var(--color-accent, #0ea5e9);
}

.dash-switch__input:checked + .dash-switch__slider::before {
  transform: translateX(14px);
}

.dash-switch__input:focus-visible + .dash-switch__slider {
  box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.25);
}

/* Hidden utility */
.is-hidden {
  display: none !important;
}

.dash-composer__validation--hidden {
  display: none;
}

/* ==========================================================================
   Starter prompt pill buttons (below composer input, above Sources)
   ========================================================================== */

.dash-promptBtns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  padding: 0.4rem 0 0.15rem;
}

.dash-promptBtn {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.7rem;
  font-size: 0.75rem;
  font-weight: 500;
  font-family: inherit;
  line-height: 1.4;
  color: #555;
  background: #f8fafc;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.dash-promptBtn:hover {
  background: #eef2f7;
  border-color: rgba(0, 0, 0, 0.18);
  color: #333;
}

.dash-promptBtn:active {
  background: #e2e8f0;
}

/* ==========================================================================
   Reply bar (compact follow-up input, shown after first submission)
   ========================================================================== */

.dash-replyBar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.5rem 0.4rem 0.75rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.04);
  margin-bottom: 0.75rem;
  transition: background 0.2s ease;
}

.dash-replyBar:focus-within {
  background: #fff;
}

.dash-replyBar__input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 0.9375rem;
  font-family: inherit;
  outline: none;
  padding: 0.3rem 0.5rem 0.3rem 0.25rem;
  color: inherit;
}

.dash-replyBar__input::placeholder {
  color: #aaa;
}

.dash-replyBar__send {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(14, 165, 233, 0.15);
  color: var(--color-accent, #0ea5e9);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.dash-replyBar__send:hover {
  background: var(--color-accent, #0ea5e9);
  color: #fff;
}

.dash-replyBar__send svg {
  display: block;
}

/* ==========================================================================
   Watchlist (compact in sidebar)
   ========================================================================== */

.dash-watchlist__list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.dash-watchlist__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.2rem 0.4rem;
  padding: 0.4rem 0.5rem;
  margin: 0 -0.5rem;
  border-bottom: var(--dash-border);
  border-radius: 4px;
  text-decoration: none;
  color: inherit;
  min-width: 0;
  cursor: pointer;
  transition: background 0.12s;
}

.dash-watchlist__row:last-child {
  border-bottom: none;
}

.dash-watchlist__row:hover {
  background: #f8fafc;
}

.dash-watchlist__info {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
  flex: 1 1 auto;
  min-width: 0;
}

.dash-watchlist__name {
  font-weight: 600;
  font-size: 0.8125rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dash-watchlist__row[data-condition] .dash-watchlist__name {
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}

.dash-watchlist__ticker {
  font-size: 0.625rem;
  color: #888;
}

.dash-watchlist__status {
  font-size: 0.6875rem;
  color: #888;
  flex: 1 1 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
}

.dash-watchlist__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.625rem;
  font-weight: 500;
  color: #888;
}

.dash-watchlist__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dash-watchlist__dot--high { background: #0ea5e9; }
.dash-watchlist__dot--watch { background: #f59e0b; }
.dash-watchlist__dot--new { background: #22c55e; }

.dash-watchlist__chevron {
  flex-shrink: 0;
  margin-left: auto;
  color: #bbb;
}

.dash-watchlist__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  flex: 1 1 100%;
  min-width: 0;
}

.dash-watchlist__tag {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  font-size: 0.575rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  border-radius: 3px;
  white-space: nowrap;
}

.dash-watchlist__tag--type {
  background-color: #e0f2fe;
  color: #0369a1;
}

.dash-watchlist__tag--stage {
  background-color: #fce7f3;
  color: #be185d;
}

/* Collapsible watchlist groups */
.dash-watchlist__group {
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.dash-watchlist__group:last-child {
  border-bottom: none;
}

.dash-watchlist__groupHeader {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  padding: 8px 10px 6px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  user-select: none;
}

.dash-watchlist__groupLabel {
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6b7280;
}

.dash-watchlist__groupCount {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  font-size: 0.5625rem;
  font-weight: 700;
  color: #6b7280;
  background: rgba(0,0,0,0.05);
  border-radius: 8px;
}

.dash-watchlist__groupChevron {
  margin-left: auto;
  color: #9ca3af;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.dash-watchlist__group.is-open .dash-watchlist__groupChevron {
  transform: rotate(0deg);
}
.dash-watchlist__group:not(.is-open) .dash-watchlist__groupChevron {
  transform: rotate(-90deg);
}

.dash-watchlist__groupBody {
  overflow: hidden;
  transition: max-height 0.25s ease;
}
.dash-watchlist__group.is-open .dash-watchlist__groupBody {
  max-height: 2000px;
}
.dash-watchlist__group:not(.is-open) .dash-watchlist__groupBody {
  max-height: 0;
}

.dash-watchlist__ticker--public {
  color: #3b82f6;
  font-weight: 600;
}
.dash-watchlist__ticker--private {
  color: #7c3aed;
  font-weight: 600;
}
.dash-watchlist__ticker--pipeline {
  color: #0d9488;
  font-weight: 600;
}
.dash-watchlist__ticker--condition {
  color: #f87171;
  font-weight: 600;
}
.dash-watchlist__ticker--target {
  color: #0d9488;
  font-weight: 600;
}

/* Private company label in modal */
.dash-companyModal__ticker--private {
  color: #7c3aed;
  font-weight: 600;
}

/* Collapsed sidebar: hide group headers, show only logos */
.dash--collapsed .dash-watchlist__groupHeader {
  padding: 4px 0;
  justify-content: center;
}
.dash--collapsed .dash-watchlist__groupLabel {
  font-size: 0.5rem;
}
.dash--collapsed .dash-watchlist__groupCount,
.dash--collapsed .dash-watchlist__groupChevron {
  display: none;
}


/* ==========================================================================
   Sidebar Recents panel
   ========================================================================== */

.dash-recents {
  margin-bottom: 1rem;
}

.dash-recents__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
}

.dash-recents__toggle .dash-panel__title {
  margin: 0;
}

.dash-recents__chevron {
  transition: transform 0.25s ease;
  color: #999;
}

.dash-recents--collapsed .dash-recents__chevron {
  transform: rotate(-90deg);
}

.dash-recents__body {
  overflow: hidden;
  max-height: 280px;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 1;
  overflow-y: auto;
}

.dash-recents--collapsed .dash-recents__body {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
}

.dash-recents__list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.dash-recents__row {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  width: 100%;
  background: none;
  border: none;
  border-bottom: var(--dash-border, 1px solid #e8eaed);
  padding: 0.4rem 0.5rem;
  margin: 0 -0.5rem;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  border-radius: 4px;
  transition: background 0.12s;
  min-width: 0;
}

.dash-recents__row:hover {
  background: var(--dash-hover, rgba(0,0,0,0.04));
}

.dash-recents__icon {
  flex-shrink: 0;
  opacity: 0.5;
}

.dash-recents__icon--chat { color: #6366f1; opacity: 0.85; }
.dash-recents__icon--grid { color: #0ea5e9; opacity: 0.85; }

.dash-recents__title {
  flex: 1;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.3;
  color: var(--color-text, #1a1a1a);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.dash-recents__time {
  flex-shrink: 0;
  font-size: 0.6563rem;
  color: var(--color-text-secondary, #888);
  white-space: nowrap;
}

.dash-recents__empty {
  font-size: 0.8rem;
  color: var(--color-text-secondary, #888);
  margin: 0.5rem 0;
}

[data-color-scheme="dark"] .dash-recents__title { color: #e2e8f0; }
[data-color-scheme="dark"] .dash-recents__row:hover { background: rgba(255,255,255,0.06); }
[data-color-scheme="dark"] .dash-recents__row { border-color: rgba(255,255,255,0.07); }
.dash-recents__row[draggable="true"] { cursor: grab; }
.dash-recents__row[draggable="true"]:active { cursor: grabbing; }
.dash-recents__row--dragging { opacity: 0.5; }

.dash--collapsed .dash-recents__body {
  max-height: 0 !important;
  opacity: 0 !important;
  overflow: hidden !important;
}

/* ==========================================================================
   Onyx Signals nav (sidebar)
   ========================================================================== */

.dash-signals {
  margin-bottom: 1rem;
}

.dash-signals .dash-panel__title {
  margin-bottom: 0.5rem;
}

.dash-signals__list {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.dash-signals__item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.4rem 0.5rem;
  margin: 0 -0.25rem;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #4b5563;
  transition: background 0.12s, color 0.12s;
  text-align: left;
}

.dash-signals__item:hover {
  background: #f1f5f9;
  color: #1e293b;
}

.dash-signals__item.is-active {
  background: #eff6ff;
  color: #2563eb;
}

.dash-signals__item.is-active .dash-signals__icon {
  color: #2563eb;
}

.dash-signals__icon {
  flex-shrink: 0;
  color: #9ca3af;
  transition: color 0.12s;
}

.dash-signals__item:hover .dash-signals__icon {
  color: #6b7280;
}

.dash-signals__label {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Chevron on items that have a submenu */
.dash-signals__chevron {
  flex-shrink: 0;
  color: #c0c9d6;
  transition: color 0.12s, transform 0.2s;
  margin-left: auto;
}

.dash-signals__item:hover .dash-signals__chevron {
  color: #94a3b8;
}

/* ==========================================================================
   Nav groups with hover submenus
   ========================================================================== */

.dash-signals__group {
  position: relative;
}

/* The flyout submenu panel — fixed so it escapes sidebar overflow-x:hidden */
.dash-signals__submenu {
  position: fixed;
  /* top/left set dynamically by JS */
  min-width: 230px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  box-shadow: 0 8px 28px rgba(0,0,0,0.12);
  padding: 0.4rem 0.4rem 0.5rem;
  z-index: 9999;
  /* hidden by default */
  opacity: 0;
  pointer-events: none;
  transform: translateX(-6px);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

/* JS adds .is-open to show the submenu */
.dash-signals__submenu.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

/* Chevron rotates when group has open submenu */
.dash-signals__group.is-open .dash-signals__chevron {
  transform: rotate(90deg);
  color: #2563eb;
}

/* Section label inside submenu */
.dash-signals__submenuLabel {
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #94a3b8;
  margin: 0.35rem 0.6rem 0.3rem;
}

/* Individual submenu buttons */
.dash-signals__subitem {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.45rem 0.6rem;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 500;
  color: #374151;
  text-align: left;
  transition: background 0.1s, color 0.1s;
}

.dash-signals__subitem:hover {
  background: #eff6ff;
  color: #2563eb;
}

.dash-signals__subitem svg {
  flex-shrink: 0;
  color: #9ca3af;
  transition: color 0.1s;
}

.dash-signals__subitem:hover svg {
  color: #2563eb;
}

/* Dark mode */
[data-color-scheme="dark"] .dash-signals__submenu {
  background: #1e2535;
  border-color: rgba(255,255,255,0.1);
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
}

[data-color-scheme="dark"] .dash-signals__subitem {
  color: #cbd5e1;
}

[data-color-scheme="dark"] .dash-signals__subitem:hover {
  background: rgba(37,99,235,0.15);
  color: #93c5fd;
}

/* ==========================================================================
   Stub panel (Coming Soon placeholder)
   ========================================================================== */

.dash-stub {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  min-height: 0;
  padding: 2rem;
}

.dash-stub.is-hidden {
  display: none;
}

.dash-stub__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 360px;
  gap: 0.75rem;
}

.dash-stub__icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #3b82f6;
  margin-bottom: 0.25rem;
}

.dash-stub__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  line-height: 1.3;
}

.dash-stub__desc {
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.6;
  margin: 0;
}

.dash-stub__badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  background: #fef3c7;
  color: #92400e;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

[data-color-scheme="dark"] .dash-stub__icon {
  background: rgba(59,130,246,0.12);
  border-color: rgba(59,130,246,0.25);
}

[data-color-scheme="dark"] .dash-stub__title {
  color: #f1f5f9;
}

[data-color-scheme="dark"] .dash-stub__desc {
  color: #94a3b8;
}

/* ==========================================================================
   Drug Compare Panel
   ========================================================================== */

.dash-drugCompare {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 120px);
  padding: 2rem 1.5rem 3rem;
}

.dash-drugCompare.is-hidden {
  display: none;
}

.dash-drugCompare__header {
  text-align: center;
  margin-bottom: 2.5rem;
  max-width: 560px;
}

.dash-drugCompare__title {
  font-size: 1.4rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
}

.dash-drugCompare__subtitle {
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.5;
  margin: 0;
}

/* Track — horizontal row of slots */
.dash-drugCompare__track {
  display: flex;
  align-items: stretch;
  gap: 0;
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
  max-width: 900px;
}

/* "vs" divider between slots */
.dash-drugCompare__vs {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #94a3b8;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  flex-shrink: 0;
  padding-top: 1.75rem; /* align with slot body (below label) */
}

/* Individual drug slot card */
.dash-drugCompare__slot {
  background: #fff;
  border: 1px solid rgba(0,0,0,0.09);
  border-radius: 14px;
  padding: 1.25rem 1.25rem 1.5rem;
  width: 220px;
  min-width: 180px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
  transition: border-color 0.15s, box-shadow 0.15s;
  position: relative;
}

.dash-drugCompare__slot--filled {
  border-color: rgba(59,130,246,0.35);
  box-shadow: 0 2px 14px rgba(59,130,246,0.10);
}

.dash-drugCompare__slot--industry {
  border-color: rgba(16,185,129,0.35);
  box-shadow: 0 2px 14px rgba(16,185,129,0.10);
  padding-bottom: 1rem;
}

.dash-drugCompare__slotLabel {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
}

.dash-drugCompare__slot--filled .dash-drugCompare__slotLabel {
  color: #3b82f6;
}

.dash-drugCompare__slot--industry .dash-drugCompare__slotLabel {
  color: #10b981;
}

.dash-drugCompare__slotBody {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Search input */
.dash-drugCompare__searchWrap {
  position: relative;
  display: flex;
  align-items: center;
}

.dash-drugCompare__input {
  width: 100%;
  padding: 0.55rem 0.75rem;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 8px;
  font-size: 0.82rem;
  color: #0f172a;
  background: #f8fafc;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.dash-drugCompare__input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59,130,246,0.12);
  background: #fff;
}

/* Dropdown suggestions */
.dash-drugCompare__dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  z-index: 200;
  overflow: hidden;
}

.dash-drugCompare__dropdown.is-hidden {
  display: none;
}

.dash-drugCompare__dropItem {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem 0.75rem;
  text-align: left;
  font-size: 0.82rem;
  color: #0f172a;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background 0.1s;
}

.dash-drugCompare__dropItem:hover {
  background: #f1f5f9;
}

/* Selected state (replaces input) */
.dash-drugCompare__selected {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  background: #eff6ff;
  border-radius: 8px;
  padding: 0.5rem 0.65rem;
}

.dash-drugCompare__selected.is-hidden {
  display: none;
}

.dash-drugCompare__slot--industry .dash-drugCompare__selected {
  background: #ecfdf5;
}

.dash-drugCompare__selectedName {
  font-size: 0.85rem;
  font-weight: 600;
  color: #1e40af;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-drugCompare__slot--industry .dash-drugCompare__selectedName {
  color: #065f46;
}

.dash-drugCompare__clearBtn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 2px;
  flex-shrink: 0;
  transition: color 0.15s;
}

.dash-drugCompare__clearBtn:hover {
  color: #ef4444;
}

/* Dropdown suggestion badges (node type label) */
.dash-drugCompare__dropName {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-drugCompare__dropBadge {
  flex-shrink: 0;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  background: #e2e8f0;
  color: #475569;
}

.dash-drugCompare__dropBadge--drug     { background: #ede9fe; color: #6d28d9; }
.dash-drugCompare__dropBadge--asset    { background: #dbeafe; color: #1d4ed8; }
.dash-drugCompare__dropBadge--target   { background: #ccfbf1; color: #0f766e; }
.dash-drugCompare__dropBadge--indication { background: #fef3c7; color: #92400e; }
.dash-drugCompare__dropBadge--company  { background: #fce7f3; color: #9d174d; }
.dash-drugCompare__dropBadge--plain    { background: #f1f5f9; color: #94a3b8; }

/* Selected name as knowledge-box link */
.dash-drugCompare__kbLink {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: #1e40af;
  cursor: pointer;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-drugCompare__kbLink:hover {
  color: #2563eb;
}

/* Add slot — dashed border card */
.dash-drugCompare__addSlot {
  width: 180px;
  min-width: 160px;
  border: 2px dashed rgba(0,0,0,0.13);
  border-radius: 14px;
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin-left: 36px; /* same as vs width */
  transition: border-color 0.15s;
}

.dash-drugCompare__addSlot:hover {
  border-color: rgba(59,130,246,0.35);
}

.dash-drugCompare__addDivider {
  font-size: 0.65rem;
  font-weight: 600;
  color: #cbd5e1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.dash-drugCompare__addOpt {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 500;
  color: #475569;
  line-height: 1.3;
  text-align: center;
  padding: 0.5rem 0.25rem;
  border-radius: 8px;
  transition: background 0.12s, color 0.12s;
}

.dash-drugCompare__addOpt svg {
  color: #94a3b8;
  transition: color 0.12s;
}

.dash-drugCompare__addOpt:hover {
  background: #f1f5f9;
  color: #1e40af;
}

.dash-drugCompare__addOpt:hover svg {
  color: #3b82f6;
}

.dash-drugCompare__addOpt--industry:hover {
  background: #f0fdf4;
  color: #065f46;
}

.dash-drugCompare__addOpt--industry:hover svg {
  color: #10b981;
}

.dash-drugCompare__addOpt--disabled,
.dash-drugCompare__addOpt:disabled {
  opacity: 0.38;
  cursor: default;
  pointer-events: none;
}

/* Footer */
.dash-drugCompare__footer {
  margin-top: 2rem;
}

.dash-drugCompare__footer .dash-btn--primary:disabled {
  opacity: 0.45;
  cursor: default;
}

/* Dark mode */
[data-color-scheme="dark"] .dash-drugCompare__title {
  color: #f1f5f9;
}

[data-color-scheme="dark"] .dash-drugCompare__subtitle {
  color: #94a3b8;
}

[data-color-scheme="dark"] .dash-drugCompare__slot {
  background: #1e293b;
  border-color: rgba(255,255,255,0.08);
}

[data-color-scheme="dark"] .dash-drugCompare__slot--filled {
  border-color: rgba(59,130,246,0.4);
}

[data-color-scheme="dark"] .dash-drugCompare__slot--industry {
  border-color: rgba(16,185,129,0.4);
}

[data-color-scheme="dark"] .dash-drugCompare__input {
  background: #0f172a;
  border-color: rgba(255,255,255,0.1);
  color: #f1f5f9;
}

[data-color-scheme="dark"] .dash-drugCompare__input:focus {
  background: #0f172a;
}

[data-color-scheme="dark"] .dash-drugCompare__dropdown {
  background: #1e293b;
  border-color: rgba(255,255,255,0.1);
}

[data-color-scheme="dark"] .dash-drugCompare__dropItem {
  color: #f1f5f9;
}

[data-color-scheme="dark"] .dash-drugCompare__dropItem:hover {
  background: #334155;
}

[data-color-scheme="dark"] .dash-drugCompare__selected {
  background: rgba(59,130,246,0.15);
}

[data-color-scheme="dark"] .dash-drugCompare__selectedName {
  color: #93c5fd;
}

[data-color-scheme="dark"] .dash-drugCompare__slot--industry .dash-drugCompare__selected {
  background: rgba(16,185,129,0.15);
}

[data-color-scheme="dark"] .dash-drugCompare__slot--industry .dash-drugCompare__selectedName {
  color: #6ee7b7;
}

[data-color-scheme="dark"] .dash-drugCompare__addSlot {
  border-color: rgba(255,255,255,0.12);
}

[data-color-scheme="dark"] .dash-drugCompare__addOpt {
  color: #94a3b8;
}

[data-color-scheme="dark"] .dash-drugCompare__addOpt:hover {
  background: #334155;
  color: #93c5fd;
}

/* Responsive — stack vertically on narrow screens */
@media (max-width: 700px) {
  .dash-drugCompare__track {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }
  .dash-drugCompare__vs {
    width: auto;
    padding: 0;
    height: 28px;
  }
  .dash-drugCompare__slot,
  .dash-drugCompare__addSlot {
    width: 100%;
    max-width: 340px;
    margin-left: 0;
  }
}

/* ── Section headers (shared by Metrics and Plan sections) ── */
.dash-drugCompare__sectionHeader {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.dash-drugCompare__sectionTitle {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #64748b;
  margin: 0;
}

.dash-drugCompare__sectionNote {
  font-size: 0.775rem;
  color: #94a3b8;
  margin: 0;
}

.dash-drugCompare__sectionBadge {
  display: inline-flex;
  align-items: center;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #d97706;
  background: #fef3c7;
  border-radius: 4px;
  padding: 1px 6px;
}

/* ── Similarity Metrics section ── */
.dash-drugCompare__metrics {
  width: 100%;
  max-width: 820px;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 16px;
  padding: 1.5rem;
  margin-top: 2rem;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.dash-drugCompare__metrics.is-hidden {
  display: none;
}

.dash-drugCompare__metricsBody {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
}

/* Overall arc gauge */
.dash-drugCompare__metricOverall {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 140px;
}

.dash-drugCompare__gaugeWrap {
  position: relative;
  width: 120px;
  height: 72px;
}

.dash-drugCompare__gaugeSvg {
  width: 120px;
  height: 72px;
  display: block;
}

.dash-drugCompare__gaugeTrack {
  stroke: #e2e8f0;
}

.dash-drugCompare__gaugeFill {
  stroke: #3b82f6;
  transition: stroke-dashoffset 0.6s ease;
}

.dash-drugCompare__gaugeScore {
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.1rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.dash-drugCompare__metricMeta {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.5rem;
}

/* 4-metric bar list */
.dash-drugCompare__metricsList {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 0;
}

.dash-drugCompare__metricRow {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.dash-drugCompare__metricRowTop {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.dash-drugCompare__metricRowRight {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  flex-shrink: 0;
}

.dash-drugCompare__metricName {
  font-size: 0.775rem;
  font-weight: 500;
  color: #475569;
}

.dash-drugCompare__metricScore {
  font-size: 0.775rem;
  font-weight: 700;
  color: #1e293b;
  font-variant-numeric: tabular-nums;
}

.dash-drugCompare__metricInfoBtn {
  background: none;
  border: none;
  padding: 2px;
  cursor: pointer;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: color 0.12s, background 0.12s;
  flex-shrink: 0;
}

.dash-drugCompare__metricInfoBtn:hover {
  color: #3b82f6;
  background: #eff6ff;
}

.dash-drugCompare__metricBar {
  height: 5px;
  background: #f1f5f9;
  border-radius: 99px;
  overflow: hidden;
}

.dash-drugCompare__metricBarFill {
  height: 100%;
  background: #3b82f6;
  border-radius: 99px;
  transition: width 0.5s ease;
}

.dash-drugCompare__metricBarFill--high {
  background: #10b981;
}

.dash-drugCompare__metricBarFill--low {
  background: #f59e0b;
}

/* ── Comparison Plan section ── */
.dash-drugCompare__plan {
  width: 100%;
  max-width: 820px;
  margin-top: 1.75rem;
}

.dash-drugCompare__dims {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

@media (max-width: 780px) {
  .dash-drugCompare__dims {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 500px) {
  .dash-drugCompare__dims {
    grid-template-columns: 1fr;
  }
}

.dash-drugCompare__dim {
  border: 1.5px solid #f1f5f9;
  border-radius: 10px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
  user-select: none;
}

.dash-drugCompare__dim:hover {
  border-color: #e2e8f0;
  background: #fafafa;
}

.dash-drugCompare__dim.is-checked {
  border-color: #2563eb;
  background: #f8faff;
  box-shadow: 0 0 0 3px rgba(59,130,246,0.08);
}

.dash-drugCompare__dimCheck {
  display: none;
}

.dash-drugCompare__dimInner {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.75rem;
}

.dash-drugCompare__dimIcon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  border-radius: 7px;
  color: #94a3b8;
  transition: background 0.15s, color 0.15s;
}

.dash-drugCompare__dim.is-checked .dash-drugCompare__dimIcon {
  background: #eff6ff;
  color: #2563eb;
}

.dash-drugCompare__dimText {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.dash-drugCompare__dimTitle {
  font-size: 0.8rem;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.3;
}

.dash-drugCompare__dim.is-checked .dash-drugCompare__dimTitle {
  color: #1d4ed8;
}

.dash-drugCompare__dimDesc {
  font-size: 0.72rem;
  color: #94a3b8;
  line-height: 1.4;
}

/* ── Metric Info Overlay ── */
.dash-drugCompare__infoOverlay {
  position: fixed;
  inset: 0;
  z-index: 400;
  background: rgba(15,23,42,0.35);
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
}

.dash-drugCompare__infoOverlay.is-hidden {
  display: none;
}

.dash-drugCompare__infoPanel {
  width: 380px;
  max-width: calc(100vw - 2rem);
  height: 100vh;
  background: #fff;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 24px rgba(0,0,0,0.12);
  overflow: hidden;
}

.dash-drugCompare__infoPanelHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.25rem 1rem;
  border-bottom: 1px solid #f1f5f9;
  flex-shrink: 0;
}

.dash-drugCompare__infoPanelTitle {
  font-size: 0.9rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  line-height: 1.3;
}

.dash-drugCompare__infoPanelClose {
  background: none;
  border: none;
  font-size: 1.4rem;
  line-height: 1;
  color: #94a3b8;
  cursor: pointer;
  padding: 2px 4px;
  flex-shrink: 0;
  transition: color 0.12s;
}

.dash-drugCompare__infoPanelClose:hover {
  color: #ef4444;
}

.dash-drugCompare__infoPanelBody {
  flex: 1;
  overflow-y: auto;
  padding: 1.25rem;
  font-size: 0.825rem;
  line-height: 1.65;
  color: #475569;
}

.dash-drugCompare__infoPanelBody p {
  margin: 0 0 0.85rem;
}

.dash-drugCompare__infoPanelBody ul {
  margin: 0 0 0.85rem;
  padding-left: 1.2rem;
}

.dash-drugCompare__infoPanelBody li {
  margin-bottom: 0.45rem;
}

.dash-drugCompare__infoPanelBody strong {
  color: #1e293b;
  font-weight: 600;
}

.dash-drugCompare__infoFormula {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.6rem 0.85rem;
  font-size: 0.775rem;
  font-family: 'Courier New', monospace;
  color: #1e293b;
  margin-bottom: 0.85rem;
  line-height: 1.5;
}

.dash-drugCompare__infoNote {
  background: #fef9ec;
  border: 1px solid #fde68a;
  border-radius: 8px;
  padding: 0.6rem 0.85rem;
  font-size: 0.75rem;
  color: #92400e;
}

/* Dark mode — metrics & plan */
[data-color-scheme="dark"] .dash-drugCompare__metrics {
  background: #1e293b;
  border-color: rgba(255,255,255,0.07);
}

[data-color-scheme="dark"] .dash-drugCompare__gaugeTrack {
  stroke: #334155;
}

[data-color-scheme="dark"] .dash-drugCompare__gaugeScore {
  color: #f1f5f9;
}

[data-color-scheme="dark"] .dash-drugCompare__metricName {
  color: #94a3b8;
}

[data-color-scheme="dark"] .dash-drugCompare__metricScore {
  color: #e2e8f0;
}

[data-color-scheme="dark"] .dash-drugCompare__metricBar {
  background: #334155;
}

[data-color-scheme="dark"] .dash-drugCompare__dim {
  border-color: rgba(255,255,255,0.07);
}

[data-color-scheme="dark"] .dash-drugCompare__dim.is-checked {
  background: rgba(59,130,246,0.1);
  border-color: rgba(59,130,246,0.4);
}

[data-color-scheme="dark"] .dash-drugCompare__dimTitle {
  color: #e2e8f0;
}

[data-color-scheme="dark"] .dash-drugCompare__dim.is-checked .dash-drugCompare__dimTitle {
  color: #93c5fd;
}

[data-color-scheme="dark"] .dash-drugCompare__dimIcon {
  background: #334155;
  color: #64748b;
}

[data-color-scheme="dark"] .dash-drugCompare__dim.is-checked .dash-drugCompare__dimIcon {
  background: rgba(59,130,246,0.15);
  color: #60a5fa;
}

[data-color-scheme="dark"] .dash-drugCompare__sectionTitle {
  color: #94a3b8;
}

[data-color-scheme="dark"] .dash-drugCompare__infoPanel {
  background: #1e293b;
}

[data-color-scheme="dark"] .dash-drugCompare__infoPanelHead {
  border-color: rgba(255,255,255,0.08);
}

[data-color-scheme="dark"] .dash-drugCompare__infoPanelTitle {
  color: #f1f5f9;
}

[data-color-scheme="dark"] .dash-drugCompare__infoPanelBody {
  color: #94a3b8;
}

[data-color-scheme="dark"] .dash-drugCompare__infoPanelBody strong {
  color: #e2e8f0;
}

[data-color-scheme="dark"] .dash-drugCompare__infoFormula {
  background: #0f172a;
  border-color: rgba(255,255,255,0.1);
  color: #e2e8f0;
}

/* ==========================================================================
   Saved (formerly Recent Analyses)
   ========================================================================== */

.dash-analyses {
  margin-bottom: 1rem;
}

.dash-analyses__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
}

.dash-analyses__toggle .dash-panel__title {
  margin: 0;
}

.dash-analyses__chevron {
  transition: transform 0.25s ease;
  color: #999;
}

.dash-analyses--collapsed .dash-analyses__chevron {
  transform: rotate(-90deg);
}

.dash-analyses__body {
  overflow: hidden;
  max-height: 400px;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 1;
}

.dash-analyses--collapsed .dash-analyses__body {
  max-height: 0;
  opacity: 0;
}

.dash-analyses__list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.dash-analyses__pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.5rem 0;
  margin-top: 0.25rem;
}

.dash-analyses__pageInfo {
  font-size: 0.75rem;
  color: #888;
  min-width: 5rem;
  text-align: center;
}

.dash-analyses__pagination .dash-btn--small:disabled {
  opacity: 0.35;
  cursor: default;
}

.dash-analyses__row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--dash-space-1);
  padding: 0.5rem 0.5rem;
  margin: 0 -0.5rem;
  border-bottom: var(--dash-border);
  border-radius: 4px;
  position: relative;
  cursor: pointer;
  transition: background 0.12s;
}

.dash-analyses__row:last-child {
  border-bottom: none;
}

.dash-analyses__row:hover {
  background: #f8fafc;
}

.dash-analyses__row-main {
  display: flex;
  flex-direction: column;
  gap: 0;
  min-width: 0;
  flex: 1;
}

.dash-analyses__title {
  font-size: 0.875rem;
  font-weight: 500;
  flex: 1 1 0%;
  min-width: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-analyses__type {
  font-size: 0.625rem;
  color: #888;
  padding: 0.1rem 0.35rem;
  background: #f8fafc;
  border-radius: 3px;
}

.dash-analyses__tag {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #0369a1;
  padding: 0.15rem 0.4rem;
  background: #e0f2fe;
  border-radius: 3px;
}

.dash-analyses__entityTag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #334155;
  padding: 0.15rem 0.5rem 0.15rem 0.25rem;
  border: 1px solid transparent;
  border-radius: 999px;
  line-height: 1.3;
  cursor: grab;
  white-space: nowrap;
  transition: box-shadow 150ms ease, transform 150ms ease;
  user-select: none;
  -webkit-user-select: none;
}

.dash-analyses__entityTag:hover {
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
  transform: translateY(-1px);
}

.dash-analyses__entityTag:active {
  cursor: grabbing;
}

.dash-analyses__entityTag.dash-entity--company {
  border-color: #bfdbfe;
}
.dash-analyses__entityTag.dash-entity--target {
  border-color: #99f6e4;
}
.dash-analyses__entityTag.dash-entity--condition {
  border-color: #fde68a;
}
.dash-analyses__entityTag.dash-entity--drug {
  border-color: #ddd6fe;
}

/* ---- Inline entity pills (replaces Sankey) ---- */

.dash-analyses__entityPills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-top: 0.35rem;
  align-items: center;
}

.dash-analyses__catBadge {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  cursor: pointer;
  line-height: 1.3;
  transition: opacity 150ms ease, box-shadow 150ms ease;
  user-select: none;
  -webkit-user-select: none;
}

.dash-analyses__catBadge:hover {
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.dash-analyses__catBadge svg {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
}

.dash-analyses__catBadge--company  { background: #dbeafe; color: #1d4ed8; }
.dash-analyses__catBadge--condition { background: #fef3c7; color: #92400e; }
.dash-analyses__catBadge--target   { background: #ccfbf1; color: #0f766e; }
.dash-analyses__catBadge--drug     { background: #ede9fe; color: #6d28d9; }

.dash-analyses__catExpand {
  display: none;
  flex-basis: 100%;
  flex-wrap: wrap;
  gap: 0.25rem;
  padding-top: 0.2rem;
}

.dash-analyses__catBadge--expanded + .dash-analyses__catExpand {
  display: flex;
}

/* ---- Saved-item categorized tag rows ---- */

.dash-analyses__row-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.2rem 0.35rem;
  width: 100%;
  padding-right: 0.5rem;
}

.dash-analyses__row-header .dash-analyses__title {
  flex-basis: 100%;
}

.dash-analyses__row--dropTarget {
  background: #f0fdf4;
  outline: 2px dashed #86efac;
  outline-offset: -2px;
}

.dash-analyses__itemBadges {
  display: flex;
  gap: 0.35rem;
  margin-top: 0.2rem;
  flex-wrap: wrap;
}

.dash-analyses__itemBadge {
  font-size: 0.5625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.35rem;
  border-radius: 3px;
  line-height: 1.4;
}

.dash-analyses__itemBadge--chat {
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
}

.dash-analyses__itemBadge--grid {
  background: rgba(14, 165, 233, 0.1);
  color: #0ea5e9;
}

/* Legacy flat rows (kept for shimmer fallback) */
.dash-analyses__tagRows {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  width: 100%;
  margin-top: 0.35rem;
}

.dash-analyses__tagRow {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.dash-analyses__tagLabel {
  display: none;
}

.dash-analyses__tagScroll {
  display: flex;
  gap: 0.3rem;
  overflow-x: auto;
  flex: 1;
  min-width: 0;
  padding-bottom: 2px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.dash-analyses__tagScroll::-webkit-scrollbar {
  display: none;
}

/* Loading shimmer for tags */
.dash-analyses__tagRows--loading {
  min-height: 1.2rem;
}

.dash-analyses__tagShimmer {
  height: 0.85rem;
  width: 60%;
  border-radius: 999px;
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: savedTagShimmer 1.5s ease-in-out infinite;
}

@keyframes savedTagShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ---- Sankey node graph for entity tags ---- */

.dash-sankey {
  display: flex;
  flex-direction: column;
  gap: 0;
  width: 100%;
  margin-top: 0.4rem;
  padding-left: 0.15rem;
  position: relative;
}

.dash-sankey::before {
  content: '';
  position: absolute;
  top: 0.5rem;
  bottom: 0.5rem;
  left: 0;
  width: 2px;
  background: #e2e8f0;
  border-radius: 1px;
}

.dash-sankeyNode {
  display: flex;
  flex-direction: column;
  position: relative;
  padding-left: 0.85rem;
}

.dash-sankeyNode__header {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.2rem 0;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  border-radius: 4px;
  transition: background 0.1s;
}

.dash-sankeyNode__header:hover {
  background: rgba(0, 0, 0, 0.025);
}

.dash-sankeyNode--empty .dash-sankeyNode__header {
  cursor: default;
  opacity: 0.38;
}

.dash-sankeyNode__connector {
  position: absolute;
  left: 0;
  top: 0.65rem;
  width: 0.55rem;
  height: 2px;
  pointer-events: none;
}

.dash-sankeyNode__connector::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 0 2px 2px 0;
}

.dash-sankeyNode--company .dash-sankeyNode__connector::before { background: #3b82f6; }
.dash-sankeyNode--condition .dash-sankeyNode__connector::before { background: #f59e0b; }
.dash-sankeyNode--target .dash-sankeyNode__connector::before { background: #14b8a6; }
.dash-sankeyNode--drug .dash-sankeyNode__connector::before { background: #8b5cf6; }

.dash-sankeyNode__label {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #64748b;
  letter-spacing: 0.01em;
}

.dash-sankeyNode--company .dash-sankeyNode__label,
.dash-sankeyNode--condition .dash-sankeyNode__label,
.dash-sankeyNode--target .dash-sankeyNode__label,
.dash-sankeyNode--drug .dash-sankeyNode__label { color: #4b5563; }

.dash-sankeyNode__count {
  font-size: 0.625rem;
  font-weight: 700;
  min-width: 1.15rem;
  height: 1.15rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  line-height: 1;
}

.dash-sankeyNode--company .dash-sankeyNode__count { background: #dbeafe; color: #1d4ed8; }
.dash-sankeyNode--condition .dash-sankeyNode__count { background: #fef3c7; color: #92400e; }
.dash-sankeyNode--target .dash-sankeyNode__count { background: #ccfbf1; color: #0f766e; }
.dash-sankeyNode--drug .dash-sankeyNode__count { background: #ede9fe; color: #6d28d9; }

.dash-sankeyNode__chevron {
  width: 10px;
  height: 10px;
  color: #94a3b8;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.dash-sankeyNode--expanded .dash-sankeyNode__chevron {
  transform: rotate(90deg);
}

.dash-sankeyNode--empty .dash-sankeyNode__chevron {
  visibility: hidden;
}

.dash-sankeyNode__children {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  padding: 0.15rem 0 0.25rem 0.2rem;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.25s ease, opacity 0.2s ease, padding 0.25s ease;
}

.dash-sankeyNode--expanded .dash-sankeyNode__children {
  max-height: 12rem;
  opacity: 1;
  padding-top: 0.15rem;
  padding-bottom: 0.25rem;
}

.dash-sankeyNode__band {
  position: absolute;
  left: 0.55rem;
  top: 1.1rem;
  width: 0.5rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.dash-sankeyNode--expanded .dash-sankeyNode__band {
  opacity: 1;
}

.dash-sankeyNode__band::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-left: 2px solid;
  border-bottom: 2px solid;
  border-radius: 0 0 0 6px;
  opacity: 0.3;
}

.dash-sankeyNode--company .dash-sankeyNode__band::before { border-color: #3b82f6; }
.dash-sankeyNode--condition .dash-sankeyNode__band::before { border-color: #f59e0b; }
.dash-sankeyNode--target .dash-sankeyNode__band::before { border-color: #14b8a6; }
.dash-sankeyNode--drug .dash-sankeyNode__band::before { border-color: #8b5cf6; }

/* ---- Sources Sankey (blue doc icon) ---- */

.dash-analyses__sourcesBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35rem;
  height: 1.35rem;
  border: none;
  background: none;
  color: #64748b;
  cursor: pointer;
  border-radius: 4px;
  padding: 0;
  flex-shrink: 0;
  transition: background 0.12s, color 0.12s;
  position: relative;
}

.dash-analyses__sourcesBtn:hover {
  background: #f1f5f9;
  color: #334155;
}

.dash-analyses__sourcesBtn svg {
  width: 13px;
  height: 13px;
}

.dash-analyses__sourcesBtn--active {
  background: #f1f5f9;
  color: #334155;
}

.dash-sourcesSankey {
  display: flex;
  flex-direction: column;
  gap: 0;
  width: 100%;
  margin-top: 0.3rem;
  padding: 0.35rem 0.4rem;
  background: #f0f7ff;
  border-radius: 6px;
  border: 1px solid #dbeafe;
  position: relative;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  padding-top: 0;
  padding-bottom: 0;
  margin-top: 0;
  border-width: 0;
  transition: max-height 0.3s ease, opacity 0.2s ease, padding 0.3s ease,
              margin-top 0.3s ease, border-width 0.3s ease;
}

.dash-sourcesSankey--open {
  max-height: 20rem;
  opacity: 1;
  padding: 0.35rem 0.4rem;
  margin-top: 0.3rem;
  border-width: 1px;
}

.dash-sourcesSankey__title {
  font-size: 0.6875rem;
  font-weight: 700;
  color: #1e40af;
  margin-bottom: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.dash-sourcesSankey__title svg {
  width: 12px;
  height: 12px;
  opacity: 0.7;
}

.dash-sourcesSankey__trunk {
  position: relative;
  padding-left: 0.7rem;
}

.dash-sourcesSankey__trunk::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0.4rem;
  left: 0;
  width: 2px;
  background: #93c5fd;
  border-radius: 1px;
}

.dash-sourceGroup {
  position: relative;
  padding-left: 0.75rem;
  margin-bottom: 0.15rem;
}

.dash-sourceGroup__connector {
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 0.5rem;
  height: 2px;
  background: #93c5fd;
  border-radius: 0 2px 2px 0;
}

.dash-sourceGroup__header {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  border-radius: 3px;
  transition: background 0.1s;
}

.dash-sourceGroup__header:hover {
  background: rgba(59, 130, 246, 0.06);
}

.dash-sourceGroup__label {
  font-size: 0.625rem;
  font-weight: 600;
  color: #2563eb;
}

.dash-sourceGroup__count {
  font-size: 0.5625rem;
  font-weight: 700;
  min-width: 0.95rem;
  height: 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #dbeafe;
  color: #1d4ed8;
  line-height: 1;
}

.dash-sourceGroup__chevron {
  width: 9px;
  height: 9px;
  color: #93c5fd;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.dash-sourceGroup--expanded .dash-sourceGroup__chevron {
  transform: rotate(90deg);
}

.dash-sourceGroup__children {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding-left: 0.15rem;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.2s ease, opacity 0.15s ease;
}

.dash-sourceGroup--expanded .dash-sourceGroup__children {
  max-height: 10rem;
  opacity: 1;
  padding-top: 0.1rem;
  padding-bottom: 0.15rem;
}

.dash-sourcePill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.6875rem;
  font-weight: 500;
  color: #1e40af;
  padding: 0.15rem 0.45rem;
  background: #fff;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  white-space: nowrap;
  cursor: default;
  transition: box-shadow 0.12s, background 0.12s;
  position: relative;
}

.dash-sourcePill:hover {
  box-shadow: 0 1px 4px rgba(59, 130, 246, 0.15);
  background: #eff6ff;
}

.dash-sourcePill__icon {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
  opacity: 0.6;
}

.dash-sourcePill__tags {
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  display: none;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.3rem 0.45rem;
  background: #1e293b;
  color: #e2e8f0;
  border-radius: 5px;
  font-size: 0.5625rem;
  font-weight: 600;
  white-space: nowrap;
  z-index: 100;
  pointer-events: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.dash-sourcePill__tags::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 4px solid transparent;
  border-top-color: #1e293b;
}

.dash-sourcePill:hover .dash-sourcePill__tags {
  display: flex;
}

.dash-sourcePill__tagBadge {
  display: inline-block;
  padding: 0.05rem 0.3rem;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 3px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.dash-analyses__time {
  font-size: 0.6875rem;
  color: #aaa;
}

.dash-analyses__status {
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 0.15rem 0.4rem;
  border-radius: 3px;
}

.dash-analyses__status--draft {
  background: #fef3c7;
  color: #92400e;
}

.dash-analyses__status--complete {
  background: #d1fae5;
  color: #065f46;
}

/* Pin icon (visible on hover) */
.dash-analyses__pin {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem;
  color: #bbb;
  opacity: 0;
  transition: opacity 0.12s;
  cursor: pointer;
  flex-shrink: 0;
}

.dash-analyses__row:hover .dash-analyses__pin {
  opacity: 0.5;
}

.dash-analyses__pin:hover {
  opacity: 1 !important;
  color: #666;
}


/* ==========================================================================
   Attachments modal
   ========================================================================== */

.dash-modal__overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dash-modal {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  overflow-y: auto;
}

.dash-modal__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  border-bottom: var(--dash-border);
}

.dash-modal__title {
  font-size: 1rem;
  font-weight: 700;
  margin: 0;
}

.dash-modal__close {
  background: none;
  border: none;
  font-size: 1.25rem;
  cursor: pointer;
  color: #666;
  padding: 0.25rem;
  line-height: 1;
}

.dash-modal__close:hover {
  color: #111;
}

.dash-modal__body {
  padding: 1rem 1.25rem;
}

.dash-modal__section {
  margin-bottom: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dash-modal__section:last-child {
  margin-bottom: 0;
}

.dash-modal__subtitle {
  font-size: 0.8125rem;
  font-weight: 600;
  width: 100%;
  margin: 0 0 0.5rem;
}

.dash-modal__stub {
  font-size: 0.75rem;
  color: #888;
  width: 100%;
  margin: 0.25rem 0 0;
}

.dash-modal__fileRow {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0;
  border-bottom: var(--dash-border);
  font-size: 0.75rem;
  width: 100%;
}

.dash-modal__fileRow:last-child {
  border-bottom: none;
}

.dash-modal__fileName {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-modal__fileSize {
  color: #888;
  flex-shrink: 0;
}

.dash-modal__fileRemove {
  background: none;
  border: none;
  cursor: pointer;
  color: #b91c1c;
  font-size: 0.75rem;
  padding: 0.15rem 0.3rem;
  border-radius: 3px;
  flex-shrink: 0;
}

.dash-modal__fileRemove:hover {
  background: #fef2f2;
}

/* ==========================================================================
   Export progress modal
   ========================================================================== */

.dash-exportModal__overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: dashExportOverlayIn 200ms ease;
}

@keyframes dashExportOverlayIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.dash-exportModal__overlay.is-hidden {
  display: none;
}

.dash-exportModal {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18), 0 2px 10px rgba(0, 0, 0, 0.08);
  width: 100%;
  max-width: 400px;
  animation: dashExportModalIn 300ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes dashExportModalIn {
  from { opacity: 0; transform: translateY(12px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.dash-exportModal__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem 0.75rem;
}

.dash-exportModal__titleWrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.dash-exportModal__titleIcon {
  color: var(--color-accent, #0ea5e9);
  flex-shrink: 0;
}

.dash-exportModal__title {
  font-size: 0.9375rem;
  font-weight: 700;
  margin: 0;
  color: #1e293b;
}

.dash-exportModal__close {
  background: none;
  border: none;
  font-size: 1.35rem;
  cursor: pointer;
  color: #94a3b8;
  padding: 0.2rem;
  line-height: 1;
  border-radius: 6px;
  transition: background 0.12s, color 0.12s;
}

.dash-exportModal__close:hover {
  background: #f1f5f9;
  color: #334155;
}

.dash-exportModal__body {
  padding: 0.25rem 1.25rem 1rem;
}

.dash-exportModal__row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.6rem 0;
}

.dash-exportModal__row + .dash-exportModal__row {
  border-top: 1px solid #f1f5f9;
}

.dash-exportModal__rowIcon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: #f8fafc;
}

.dash-exportModal__rowIcon svg {
  width: 16px;
  height: 16px;
  display: block;
}

.dash-exportModal__rowIcon--pptx { background: #fffbeb; }
.dash-exportModal__rowIcon--pdf  { background: #fef2f2; }
.dash-exportModal__rowIcon--xlsx { background: #ecfdf5; }

.dash-exportModal__rowInfo {
  flex: 1;
  min-width: 0;
}

.dash-exportModal__rowLabel {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 5px;
}

.dash-exportModal__barTrack {
  width: 100%;
  height: 5px;
  background: #f1f5f9;
  border-radius: 999px;
  overflow: hidden;
}

.dash-exportModal__barFill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  transition: width 0.3s ease;
}

.dash-exportModal__barFill--pptx { background: linear-gradient(90deg, #f59e0b, #d97706); }
.dash-exportModal__barFill--pdf  { background: linear-gradient(90deg, #f87171, #dc2626); }
.dash-exportModal__barFill--xlsx { background: linear-gradient(90deg, #34d399, #059669); }

.dash-exportModal__rowPct {
  flex-shrink: 0;
  font-size: 0.75rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #94a3b8;
  min-width: 36px;
  text-align: right;
  transition: color 0.3s;
}

.dash-exportModal__rowPct.is-done {
  color: #059669;
}

.dash-exportModal__rowCheck {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  color: #059669;
  opacity: 0;
  transform: scale(0.5);
  transition: opacity 0.25s, transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dash-exportModal__rowCheck.is-visible {
  opacity: 1;
  transform: scale(1);
}

.dash-exportModal__footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0.65rem 1.25rem;
  border-top: 1px solid #f1f5f9;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #059669;
  animation: dashExportFooterIn 300ms ease;
}

.dash-exportModal__footer.is-hidden {
  display: none;
}

@keyframes dashExportFooterIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dash-analyses__menu {
  position: absolute;
  top: 0.35rem;
  right: 0.35rem;
  z-index: 5;
  flex-shrink: 0;
}

.dash-analyses__menuBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.08em;
  color: #999;
  background: none;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}

.dash-analyses__menuBtn:hover {
  background: #f1f5f9;
  color: #333;
}

.dash-analyses__dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 2px);
  background: #fff;
  border: var(--dash-border);
  border-radius: var(--dash-radius);
  box-shadow: var(--dash-shadow-card);
  z-index: 20;
  min-width: 130px;
  padding: 0.25rem 0;
}

.dash-analyses__dropdown button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.4rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #333;
  background: none;
  border: none;
  cursor: pointer;
  transition: background 0.1s;
}

.dash-analyses__dropdown button:hover {
  background: #f8fafc;
}

.dash-analyses__dropdown button[data-action="delete"] {
  color: #b91c1c;
}

.dash-analyses__dropdown button[data-action="delete"]:hover {
  background: #fef2f2;
}

.dash-analyses__empty {
  font-size: 0.8125rem;
  color: #888;
  text-align: center;
  padding: 1.5rem 0;
  margin: 0;
}

/* ==========================================================================
   Toast
   ========================================================================== */

.dash-toast {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}

.dash-toast__item {
  padding: 0.6rem 1rem;
  font-size: 0.8125rem;
  font-weight: 500;
  background: #1e293b;
  color: #fff;
  border-radius: var(--dash-radius);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  opacity: 0;
  transform: translateY(8px);
  animation: dashToastIn 0.2s ease forwards;
  pointer-events: auto;
}

.dash-toast__item--out {
  animation: dashToastOut 0.2s ease forwards;
}

@keyframes dashToastIn {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes dashToastOut {
  to { opacity: 0; transform: translateY(8px); }
}

/* ==========================================================================
   Centered Toast (bottom-center, used for workspace creation)
   ========================================================================== */

.dash-centeredToast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  pointer-events: none;
}

.dash-centeredToast__item {
  padding: 0.7rem 1.4rem;
  font-size: 0.8125rem;
  font-weight: 500;
  background: #1e293b;
  color: #fff;
  border-radius: var(--dash-radius);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: translateY(10px);
  animation: dashCenteredToastIn 0.3s ease forwards;
  pointer-events: auto;
  white-space: nowrap;
}

.dash-centeredToast__item--out {
  animation: dashCenteredToastOut 0.3s ease forwards;
}

@keyframes dashCenteredToastIn {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes dashCenteredToastOut {
  to { opacity: 0; transform: translateY(10px); }
}

/* ==========================================================================
   Saved panel shimmer (indicates saved workspace)
   ========================================================================== */

@keyframes dashAnalysesShimmer {
  0%   { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4); }
  40%  { box-shadow: 0 0 14px 4px rgba(99, 102, 241, 0.3); }
  70%  { box-shadow: 0 0 8px 2px rgba(99, 102, 241, 0.15); }
  100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0); }
}

.dash-analyses--shimmer {
  animation: dashAnalysesShimmer 1.2s ease;
  border-radius: var(--dash-radius);
}

/* ── Saved panel drop-target highlight ── */
.dash-analyses--dropTarget {
  outline: 2px dashed #6366f1;
  outline-offset: -2px;
  background: rgba(99, 102, 241, 0.06);
  border-radius: var(--dash-radius);
  transition: outline-color 0.15s, background 0.15s;
}

/* ── Draggable assistant bubble hint ── */
.dash-chat__bubble--draggable {
  cursor: grab;
  position: relative;
}
.dash-chat__bubble--draggable:active {
  cursor: grabbing;
}

.dash-chat__dragHint {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 0.625rem;
  padding: 3px 10px;
  font-size: 0.6875rem;
  color: #94a3b8;
  background: rgba(148, 163, 184, 0.08);
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 999px;
  letter-spacing: 0.02em;
  line-height: 1;
  transition: color 0.15s, background 0.15s;
  user-select: none;
}
.dash-chat__bubble--draggable:hover .dash-chat__dragHint {
  color: #6366f1;
  background: rgba(99, 102, 241, 0.08);
  border-color: rgba(99, 102, 241, 0.2);
}

/* ── Dragging state for assistant bubble ── */
.dash-chat__bubble--dragging {
  opacity: 0.45;
  transform: scale(0.97);
  transition: opacity 0.15s, transform 0.15s;
}

/* ── Chat fade-out after drag-to-save ── */
.dash-chat--fadeOut {
  animation: dashChatFadeOut 0.4s ease forwards;
  pointer-events: none;
}
@keyframes dashChatFadeOut {
  0%   { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-12px); }
}


/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 767px) {
  .dash-shell {
    grid-template-columns: 1fr;
    grid-template-areas:
      "main"
      "sidebar";
  }

  .dash--collapsed .dash-shell {
    grid-template-columns: 1fr;
  }

  .dash-sidebar {
    position: static;
    width: auto;
    height: auto;
    max-height: none;
    overflow-y: visible;
    z-index: auto;
  }

  .dash-sidebar__toggle {
    display: none;
  }
}


@media (max-width: 600px) {
  .dash-greeting {
    font-size: 1.1rem;
  }

  .dash-greeting__welcome {
    font-size: 1.75rem;
  }

  .dash-greetingRow {
    min-height: 4rem;
  }

  .dash-greetingPrev {
    display: none !important;
  }

  .dash-catalysts__row {
    flex-wrap: wrap;
  }

  .dash-catalysts__row .dash-btn {
    width: 100%;
    margin-left: 0;
  }

  .dash-analyses__row {
    flex-direction: column;
    align-items: flex-start;
  }

}

/* Sidebar top spacing */
@media (min-width: 768px) {
  .dash-sidebar {
    padding-top: 1rem;
  }
}

.dash-showMore {
  display: block;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-accent, #0ea5e9);
  text-decoration: none;
  padding: 6px 0 2px;
  margin-top: 0.25rem;
}

.dash-showMore:hover {
  text-decoration: underline;
}

.dash-skelRow {
  height: 42px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.05);
  margin-bottom: 8px;
  animation: skelPulse 1.4s ease-in-out infinite;
}

@keyframes skelPulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.4; }
}


/* ==========================================================================
   NeverFail Sources modal
   ========================================================================== */

.dash-nfOverlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 1100;
  backdrop-filter: blur(2px);
}

.dash-nfModal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1101;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.06);
  width: 94vw;
  max-width: 520px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dash-nfModal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.dash-nfModal__brand {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}

.dash-nfModal__icon {
  color: #6366f1;
  flex-shrink: 0;
}

.dash-nfModal__title {
  font-size: 0.9375rem;
  font-weight: 700;
  margin: 0;
  line-height: 1.2;
  color: #111;
}

.dash-nfModal__close {
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  color: #999;
  padding: 0.25rem;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}

.dash-nfModal__close:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.dash-nfModal__body {
  flex: 1;
  overflow-y: auto;
  padding: 0.5rem 0;
}

.dash-nfModal__footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  padding: 0.625rem 1.25rem;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  font-size: 0.6875rem;
  color: #aaa;
  flex-shrink: 0;
}

.dash-nfModal__footer svg {
  color: #6366f1;
  opacity: 0.6;
}

.dash-nfModal__footer strong {
  color: #6366f1;
  font-weight: 600;
}

/* --- Row items --- */

.dash-nfRow {
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.dash-nfRow:last-child {
  border-bottom: none;
}

.dash-nfRow__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.625rem 1.25rem;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: background 0.12s;
}

.dash-nfRow__header:hover {
  background: rgba(99, 102, 241, 0.04);
}

.dash-nfRow__ident {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.dash-nfRow__company {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1a1a1a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-nfRow__drug {
  font-size: 0.6875rem;
  color: #888;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-nfRow__count {
  flex-shrink: 0;
  font-size: 0.6875rem;
  font-weight: 600;
  color: #16a34a;
  background: rgba(22, 163, 74, 0.08);
  padding: 0.2rem 0.5rem;
  border-radius: 100px;
  white-space: nowrap;
}

.dash-nfRow__count--none {
  color: #999;
  background: rgba(0, 0, 0, 0.04);
  font-weight: 500;
}

.dash-nfRow__chevron {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  color: #bbb;
  transition: transform 0.2s ease;
}

.dash-nfRow__chevron.is-open {
  transform: rotate(180deg);
}

/* --- Source detail --- */

.dash-nfRow__detail {
  padding: 0 1.25rem 0.625rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.dash-nfSource {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.625rem;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.025);
  transition: background 0.12s;
}

.dash-nfSource:hover {
  background: rgba(0, 0, 0, 0.05);
}

.dash-nfSource__icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  color: #999;
}

.dash-nfSource__badge {
  flex-shrink: 0;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.125rem 0.375rem;
  border-radius: 4px;
  line-height: 1.3;
}

.dash-nfSource__badge--pdf {
  color: #dc2626;
  background: rgba(220, 38, 38, 0.08);
}

.dash-nfSource__badge--web {
  color: #2563eb;
  background: rgba(37, 99, 235, 0.08);
}

.dash-nfSource__badge--db {
  color: #059669;
  background: rgba(5, 150, 105, 0.08);
}

.dash-nfSource__badge--journal {
  color: #7c3aed;
  background: rgba(124, 58, 237, 0.08);
}

.dash-nfSource__info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.dash-nfSource__label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-nfSource__file {
  font-size: 0.6575rem;
  color: #999;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: 'SF Mono', 'Fira Code', monospace;
}

.dash-nfSource__tags {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: auto;
}

.dash-nfSource__tag {
  font-size: 0.5625rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.35rem;
  border-radius: 3px;
  line-height: 1.3;
  white-space: nowrap;
  color: #666;
  background: rgba(0, 0, 0, 0.06);
}

/* ==========================================================================
   Report modal
   ========================================================================== */

.dash-reportOverlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 900;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.dash-reportModal {
  position: fixed;
  top: 3vh;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 2rem);
  max-width: 980px;
  height: 94vh;
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
  z-index: 910;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dash-reportTopbar {
  position: sticky;
  top: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.75rem 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  background: #fff;
  z-index: 1;
  flex-shrink: 0;
}

.dash-reportTitleWrap {
  min-width: 0;
  flex: 1;
}

.dash-reportTitle {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
  color: #111;
}

.dash-reportMeta {
  margin-top: 0.3rem;
  font-size: 0.8125rem;
  color: #888;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.dash-reportBadge {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.dash-reportBadge--low {
  background: #fee2e2;
  color: #991b1b;
}

.dash-reportBadge--med {
  background: #fef3c7;
  color: #92400e;
}

.dash-reportBadge--high {
  background: #d1fae5;
  color: #065f46;
}

.dash-reportTopbarActions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.dash-reportClose {
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  font-size: 1.5rem;
  color: #888;
  cursor: pointer;
  border-radius: 0.375rem;
  line-height: 1;
}

.dash-reportClose:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.dash-reportBody {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem 1.75rem 2rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(0,0,0,0.12) transparent;
}

.dash-reportBody::-webkit-scrollbar {
  width: 6px;
}

.dash-reportBody::-webkit-scrollbar-track {
  background: transparent;
}

.dash-reportBody::-webkit-scrollbar-thumb {
  background: rgba(0,0,0,0.12);
  border-radius: 4px;
}

.dash-reportFinancials {
  font-size: 0.8125rem;
  color: rgba(34, 34, 34, 0.45);
  letter-spacing: 0.02em;
  padding-bottom: 1rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.dash-reportFinancials__sep {
  margin: 0 0.15em;
}

.dash-reportSection {
  margin-bottom: 1.75rem;
}

.dash-reportSection:last-child {
  margin-bottom: 0;
}

.dash-reportSection h3 {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #222;
  margin: 0 0 0.625rem;
  letter-spacing: -0.01em;
  padding-bottom: 0.375rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.dash-reportSection p {
  font-size: 0.875rem;
  line-height: 1.65;
  color: #444;
  margin: 0;
}

.dash-reportBullets {
  margin: 0;
  padding-left: 1.25rem;
  list-style-type: disc;
}

.dash-reportBullets li {
  font-size: 0.875rem;
  line-height: 1.6;
  color: #444;
  margin-bottom: 0.5rem;
}

.dash-reportBullets li:last-child {
  margin-bottom: 0;
}

.dash-reportTable {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
  line-height: 1.45;
}

.dash-reportTable th {
  text-align: left;
  font-weight: 700;
  color: #333;
  padding: 0.5rem 0.625rem;
  border-bottom: 2px solid rgba(0, 0, 0, 0.1);
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.dash-reportTable td {
  padding: 0.5rem 0.625rem;
  color: #555;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  vertical-align: top;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.dash-reportTable tr:last-child td {
  border-bottom: none;
}

.dash-reportTable tr:hover td {
  background: rgba(0, 0, 0, 0.02);
}

.dash-reportTableWrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -0.25rem;
  padding: 0 0.25rem;
}

@media (max-width: 600px) {
  .dash-reportModal {
    top: 0;
    height: 100vh;
    width: 100%;
    border-radius: 0;
  }

  .dash-reportTopbar {
    padding: 1rem;
  }

  .dash-reportBody {
    padding: 1rem;
  }

  .dash-reportTitle {
    font-size: 1.05rem;
  }
}

/* ==========================================================================
   Grid — AlphaSense-style AI-populated tables
   ========================================================================== */

.dash-grid {
  margin-bottom: 1.25rem;
}

.dash-grid__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.dash-grid__header .dash-panel__title {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dash-grid__actions {
  position: relative;
}

.dash-grid__createBtn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  white-space: nowrap;
}

.dash-grid__templatePicker {
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  z-index: 50;
  min-width: 200px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  padding: 0.35rem;
  animation: dashGridPickerIn 150ms ease;
}

@keyframes dashGridPickerIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dash-grid__templateOption {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.55rem 0.75rem;
  border: none;
  background: none;
  border-radius: 7px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #333;
  cursor: pointer;
  text-align: left;
  transition: background 120ms ease;
}

.dash-grid__templateOption:hover {
  background: rgba(0, 0, 0, 0.05);
}

.dash-grid__templateOption svg {
  flex-shrink: 0;
  color: #888;
}

.dash-grid__body {
  min-height: 0;
}

.dash-grid__skeleton {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem 0;
}

.dash-grid__titleBar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.125rem 0.625rem;
}

.dash-grid__titleText {
  font-size: 0.875rem;
  font-weight: 700;
  color: #222;
}

.dash-grid__queryTag {
  order: -1;
  width: 100%;
  font-size: 0.75rem;
  font-weight: 500;
  color: #666;
  background: rgba(0, 0, 0, 0.05);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  margin-bottom: 0.25rem;
}

.dash-grid__summary {
  order: -1;
  width: 100%;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: #444;
  margin: 0.25rem 0 0.375rem;
  padding: 0;
  min-height: 1.25em;
}
.dash-grid__summary.is-hidden {
  display: none;
}

.dash-grid__closeBtn {
  border: none;
  background: none;
  font-size: 1.25rem;
  margin-left: auto;
  line-height: 1;
  color: #999;
  cursor: pointer;
  padding: 0.125rem 0.35rem;
  border-radius: 4px;
  transition: background 120ms ease, color 120ms ease;
}

.dash-grid__closeBtn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.dash-grid__fullscreenBtn {
  border: none;
  background: none;
  line-height: 1;
  color: #999;
  cursor: pointer;
  padding: 0.25rem 0.35rem;
  border-radius: 4px;
  margin-left: 0.4rem;
  transition: background 120ms ease, color 120ms ease;
}

.dash-grid__fullscreenBtn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.dash-grid__fullscreenBtn svg {
  display: block;
}

.dash-grid__inner {
  display: contents;
}

.dash-grid__tableWrap.is-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 3vh 2rem;
  overflow-y: auto;
}

.dash-grid__tableWrap.is-fullscreen .dash-grid__inner {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 1rem;
  padding: 1rem 1.25rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
  width: 100%;
  max-width: calc(100vw - 4rem);
  max-height: calc(100vh - 6vh);
  overflow: hidden;
}

.dash-grid__tableWrap.is-fullscreen .dash-grid__titleBar {
  padding: 0.25rem 0.5rem 0.75rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  margin-bottom: 1rem;
  flex-shrink: 0;
}

.dash-grid__tableWrap.is-fullscreen .dash-gridTable__scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  border-radius: 8px;
}

.dash-grid__tableWrap.is-fullscreen .dash-gridTable {
  font-size: 0.875rem;
}

.dash-grid__tableWrap.is-fullscreen .dash-gridTable th {
  padding: 0.75rem 1rem;
  font-size: 0.8125rem;
}

.dash-grid__tableWrap.is-fullscreen .dash-gridTable td {
  padding: 0.7rem 1rem;
}

.dash-grid__tableWrap.is-fullscreen .dash-gridTable tbody tr:nth-child(even) td {
  background: rgba(0, 0, 0, 0.015);
}

.dash-grid__tableWrap.is-fullscreen .dash-gridTable tbody tr:nth-child(even) td.dash-gridTable__sticky--0,
.dash-grid__tableWrap.is-fullscreen .dash-gridTable tbody tr:nth-child(even) td.dash-gridTable__sticky--1,
.dash-grid__tableWrap.is-fullscreen .dash-gridTable tbody tr:nth-child(even) td.dash-gridTable__sticky--2 {
  background: #fafafa;
}

.dash-grid__tableWrap.is-fullscreen .dash-gridTable tr:hover td.dash-gridTable__sticky--0,
.dash-grid__tableWrap.is-fullscreen .dash-gridTable tr:hover td.dash-gridTable__sticky--1,
.dash-grid__tableWrap.is-fullscreen .dash-gridTable tr:hover td.dash-gridTable__sticky--2 {
  background: #f5f5f5;
}

.dash-grid__searchMore {
  display: flex;
  justify-content: flex-start;
  padding: 1rem 0 0.5rem;
  flex-shrink: 0;
}

.dash-grid__searchMoreBtn {
  padding: 0.5rem 1.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #555;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
}

.dash-grid__searchMoreBtn:hover {
  background: #f5f5f5;
  border-color: rgba(0, 0, 0, 0.25);
  color: #333;
}

.dash-gridTable__scroll {
  overflow-x: auto;
  overflow-y: auto;
  max-height: 70vh;
  -webkit-overflow-scrolling: touch;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
}

.dash-gridTable {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
  line-height: 1.5;
}

.dash-gridTable thead {
  position: sticky;
  top: 0;
  z-index: 2;
}

.dash-gridTable th {
  text-align: left;
  font-weight: 700;
  color: #333;
  padding: 0.6rem 0.75rem;
  border-bottom: 2px solid rgba(0, 0, 0, 0.1);
  background: #fafafa;
  white-space: normal;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  max-width: 60ch;
}

.dash-gridTable td {
  padding: 0.55rem 0.75rem;
  color: #444;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  vertical-align: top;
  min-width: 160px;
  max-width: 60ch;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: break-word;
}

.dash-gridTable tr:last-child td {
  border-bottom: none;
}

.dash-gridTable tr:hover td {
  background: rgba(0, 0, 0, 0.02);
}

/* NeverFail branded column */
.dash-gridTable__nfTh {
  background: rgba(5, 150, 105, 0.07) !important;
  color: #059669 !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  font-weight: 700;
  white-space: nowrap;
}

.dash-gridTable__nfThInner {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: #059669;
}

.dash-gridTable__nfThInner svg {
  flex-shrink: 0;
}

.dash-gridTable__nfTd {
  background: rgba(5, 150, 105, 0.03);
  cursor: pointer;
  min-width: 120px !important;
  transition: background 0.12s;
}

.dash-gridTable__nfTd:hover {
  background: rgba(5, 150, 105, 0.09) !important;
}

.dash-gridTable__nfBadge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.7rem;
  font-weight: 600;
  color: #059669;
  background: rgba(5, 150, 105, 0.1);
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  white-space: nowrap;
  line-height: 1.4;
}

.dash-gridTable__nfBadge svg {
  flex-shrink: 0;
}

.dash-gridTable__nfBadge--none {
  color: #999;
  background: rgba(0, 0, 0, 0.04);
}

.dash-gridTable__nfBadge--none svg {
  stroke: #999;
}

/* Status column — single-select badge */

.dash-gridTable__statusTh {
  text-align: center !important;
  min-width: 100px;
  max-width: 180px;
}

.dash-gridTable__statusTd {
  text-align: center;
  vertical-align: middle;
  min-width: 100px !important;
  max-width: 180px;
}

.dash-gridTable__statusBadge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.18rem 0.6rem;
  border-radius: 999px;
  white-space: nowrap;
  line-height: 1.4;
  letter-spacing: 0.01em;
}

.dash-gridTable__statusBadge--active {
  background: #d1fae5;
  color: #065f46;
}

.dash-gridTable__statusBadge--failed {
  background: #fee2e2;
  color: #991b1b;
}

.dash-gridTable__statusBadge--discontinued {
  background: #f3f4f6;
  color: #374151;
}

.dash-gridTable__statusBadge--onhold {
  background: #fef3c7;
  color: #92400e;
}

.dash-gridTable__statusBadge--awaiting {
  background: #dbeafe;
  color: #1e40af;
}

.dash-gridTable__statusBadge--approved {
  background: #ccfbf1;
  color: #0f766e;
}

.dash-gridTable__statusBadge--withdrawn {
  background: #fce7f3;
  color: #be185d;
}

.dash-gridTable__statusBadge--unknown {
  background: #e2e8f0;
  color: #475569;
}

.dash-gridCell__sources {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 3px;
  margin-top: 0.3rem;
}

.dash-gridCell__source {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 1px 6px;
  font-size: 0.625rem;
  font-weight: 500;
  color: var(--color-accent, #0ea5e9);
  background: rgba(14, 165, 233, 0.08);
  border-radius: 3px;
  text-decoration: none;
  white-space: nowrap;
  line-height: 1.6;
  transition: background 120ms ease;
}

.dash-gridCell__source:hover {
  background: rgba(14, 165, 233, 0.16);
  text-decoration: underline;
}

.dash-gridCell__source svg {
  flex-shrink: 0;
  opacity: 0.6;
}

/* Progressive loading: shimmer cells */

@keyframes dashCellShimmer {
  0%   { background-position: -200px 0; }
  100% { background-position: 200px 0; }
}

.dash-gridTable__cell--loading {
  position: relative;
}

.dash-gridCell__shimmer {
  display: block;
  height: 14px;
  border-radius: 4px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 400px 100%;
  animation: dashCellShimmer 1.4s ease infinite;
}

.dash-gridTable__cell--loaded {
  animation: dashCellFadeIn 350ms ease both;
}

@keyframes dashCellFadeIn {
  from { opacity: 0; transform: translateY(3px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Column header loading indicator */

.dash-gridTable__th--loading {
  position: relative;
}

.dash-gridTable__th--loading::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-accent, #0ea5e9), transparent);
  background-size: 200% 100%;
  animation: dashThLoading 1.2s ease infinite;
}

@keyframes dashThLoading {
  0%   { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

.dash-gridTable__th--loaded {
  transition: background 300ms ease;
}

/* Column error state */

.dash-gridTable__th--error {
  color: #b91c1c !important;
}

.dash-gridTable__retryBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  margin-left: 4px;
  vertical-align: middle;
  padding: 0;
  border: 1px solid rgba(185, 28, 28, 0.3);
  border-radius: 4px;
  background: rgba(185, 28, 28, 0.06);
  color: #b91c1c;
  cursor: pointer;
  transition: background 120ms ease;
}

.dash-gridTable__retryBtn:hover {
  background: rgba(185, 28, 28, 0.14);
}

.dash-gridTable__cell--error {
  background: rgba(185, 28, 28, 0.03) !important;
}

.dash-gridCell__errorText {
  font-size: 0.6875rem;
  color: #b91c1c;
  font-style: italic;
  opacity: 0.7;
}

.dash-gridTable__sticky {
  position: sticky;
  z-index: 1;
  background: #fff;
  font-weight: 600;
  color: #222;
}

.dash-gridTable__sticky--0 {
  left: 0;
  min-width: 140px;
  max-width: 180px;
}

.dash-gridTable__sticky--1 {
  left: 140px;
  min-width: 140px;
  max-width: 180px;
}

.dash-gridTable__sticky--2 {
  left: 280px;
  min-width: 100px;
  max-width: 180px;
  box-shadow: 2px 0 6px rgba(0, 0, 0, 0.06);
  clip-path: inset(0 -8px 0 0);
}

.dash-gridTable tr:hover .dash-gridTable__sticky {
  background: #f9f9f9;
}

.dash-gridTable thead th.dash-gridTable__sticky {
  z-index: 3;
}

.dash-grid__error {
  padding: 1rem 0;
}

.dash-grid__error p {
  font-size: 0.8125rem;
  color: #b91c1c;
  margin: 0;
}

/* Grid query input */

.dash-grid__queryForm {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  padding: 0.75rem 0;
}

.dash-grid__queryInput {
  flex: 1;
  min-width: 0;
  padding: 0.55rem 0.75rem;
  font-size: 0.8125rem;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  background: #fff;
  color: #222;
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.dash-grid__queryInput:focus {
  border-color: var(--color-accent, #0ea5e9);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.12);
}

.dash-grid__queryInput::placeholder {
  color: #aaa;
}

.dash-grid__queryLabel {
  font-size: 0.75rem;
  font-weight: 600;
  color: #555;
  margin-bottom: 0.25rem;
  display: block;
}

.dash-grid__generateBtn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

@media (max-width: 600px) {
  .dash-grid__queryForm {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Column customizer (pre-generation editor) */

.dash-colEditor {
  margin-top: 0.625rem;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding-top: 0.5rem;
}

.dash-colEditor:empty {
  display: none;
}

.dash-colEditor__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.25rem;
}

.dash-colEditor__title {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #888;
}

.dash-colEditor__row {
  display: flex;
  align-items: flex-start;
  gap: 0.375rem;
  padding: 0.375rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.dash-colEditor__row:last-of-type {
  border-bottom: none;
}

.dash-colEditor__arrows {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex-shrink: 0;
  padding-top: 0.125rem;
}

.dash-colEditor__arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 16px;
  padding: 0;
  border: none;
  border-radius: 3px;
  background: transparent;
  color: #999;
  cursor: pointer;
  transition: background 120ms ease, color 120ms ease;
}

.dash-colEditor__arrow:hover:not(:disabled) {
  background: rgba(0, 0, 0, 0.06);
  color: #444;
}

.dash-colEditor__arrow:disabled {
  opacity: 0.25;
  cursor: default;
}

.dash-colEditor__main {
  flex: 1;
  min-width: 0;
}

.dash-colEditor__nameRow {
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.dash-colEditor__nameInput {
  flex: 1;
  min-width: 0;
  border: none;
  border-bottom: 1px solid transparent;
  background: transparent;
  font-size: 0.8125rem;
  font-weight: 600;
  font-family: inherit;
  color: #333;
  padding: 0.125rem 0;
  outline: none;
  transition: border-color 150ms ease;
}

.dash-colEditor__nameInput:hover {
  border-bottom-color: rgba(0, 0, 0, 0.12);
}

.dash-colEditor__nameInput:focus {
  border-bottom-color: var(--color-accent, #0ea5e9);
}

.dash-colEditor__togglePrompt {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 5px;
  background: transparent;
  color: #aaa;
  cursor: pointer;
  transition: background 120ms ease, color 120ms ease, border-color 120ms ease;
}

.dash-colEditor__togglePrompt:hover {
  background: rgba(0, 0, 0, 0.04);
  color: #555;
  border-color: rgba(0, 0, 0, 0.15);
}

.dash-colEditor__togglePrompt--open {
  background: rgba(14, 165, 233, 0.08);
  color: var(--color-accent, #0ea5e9);
  border-color: rgba(14, 165, 233, 0.25);
}

.dash-colEditor__promptWrap {
  overflow: hidden;
  transition: max-height 250ms ease, opacity 200ms ease;
  max-height: 200px;
  opacity: 1;
  margin-top: 0.375rem;
}

.dash-colEditor__promptWrap.is-hidden {
  max-height: 0;
  opacity: 0;
  margin-top: 0;
}

.dash-colEditor__promptTextarea {
  width: 100%;
  min-height: 60px;
  padding: 0.4rem 0.5rem;
  font-size: 0.75rem;
  line-height: 1.5;
  font-family: inherit;
  color: #444;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 6px;
  background: #fafafa;
  resize: vertical;
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.dash-colEditor__promptTextarea:focus {
  border-color: var(--color-accent, #0ea5e9);
  box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.1);
  background: #fff;
}

.dash-colEditor__note {
  font-size: 0.6875rem;
  color: #aaa;
  margin: 0.5rem 0 0;
  font-style: italic;
}

/* Column prompt editor popover */

.dash-grid__promptPopover {
  position: fixed;
  z-index: 200;
  width: 340px;
  max-width: calc(100vw - 2rem);
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
  padding: 0.875rem;
  animation: dashPromptPopIn 150ms ease;
}

@keyframes dashPromptPopIn {
  from { opacity: 0; transform: translateY(-6px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.dash-grid__promptHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.dash-grid__promptColName {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #222;
}

.dash-grid__promptClose {
  border: none;
  background: none;
  font-size: 1.25rem;
  line-height: 1;
  color: #999;
  cursor: pointer;
  padding: 0.125rem 0.3rem;
  border-radius: 4px;
  transition: background 120ms ease, color 120ms ease;
}

.dash-grid__promptClose:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.dash-grid__promptTextarea {
  width: 100%;
  min-height: 80px;
  padding: 0.5rem 0.625rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  font-family: inherit;
  color: #333;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  background: #fafafa;
  resize: vertical;
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.dash-grid__promptTextarea:focus {
  border-color: var(--color-accent, #0ea5e9);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.12);
  background: #fff;
}

.dash-grid__promptActions {
  display: flex;
  justify-content: flex-end;
  gap: 0.4rem;
  margin-top: 0.5rem;
}

.dash-gridTable th {
  cursor: pointer;
  user-select: none;
  position: relative;
}

.dash-gridTable th[draggable="true"] {
  cursor: grab;
}

.dash-gridTable th[draggable="true"]:active {
  cursor: grabbing;
}

.dash-gridTable__th--dragging {
  opacity: 0.35;
  outline: 2px dashed var(--color-accent, #0ea5e9);
  outline-offset: -2px;
}

.dash-gridTable__th--dragover {
  box-shadow: inset 3px 0 0 var(--color-accent, #0ea5e9);
}

/* Inline rename input inside th */
.dash-gridTable__renameInput {
  width: 100%;
  min-width: 60px;
  padding: 0.125rem 0.25rem;
  font: inherit;
  font-weight: 700;
  font-size: inherit;
  color: #222;
  background: #fff;
  border: 1.5px solid var(--color-accent, #0ea5e9);
  border-radius: 4px;
  outline: none;
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
}

/* Column header context menu */
.dash-grid__colMenu {
  position: fixed;
  z-index: 210;
  min-width: 170px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.13);
  padding: 0.3rem;
  animation: dashColMenuIn 120ms ease;
}

@keyframes dashColMenuIn {
  from { opacity: 0; transform: translateY(-4px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.dash-grid__colMenuItem {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem 0.625rem;
  border: none;
  background: none;
  font-size: 0.8125rem;
  font-family: inherit;
  color: #333;
  cursor: pointer;
  border-radius: 7px;
  text-align: left;
  transition: background 100ms ease, color 100ms ease;
  line-height: 1.3;
}

.dash-grid__colMenuItem:hover {
  background: rgba(14, 165, 233, 0.08);
  color: #0284c7;
}

.dash-grid__colMenuItem svg {
  flex-shrink: 0;
  opacity: 0.6;
}

.dash-grid__colMenuItem:hover svg {
  opacity: 1;
}

/* ---- Cell deep-dive popover ---- */

.dash-cellDive {
  position: fixed;
  z-index: 220;
  width: 340px;
  max-width: calc(100vw - 2rem);
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.16);
  padding: 0.75rem 0.875rem;
  animation: dashCellDiveIn 140ms ease;
}

@keyframes dashCellDiveIn {
  from { opacity: 0; transform: translateY(-5px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.dash-cellDive__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.dash-cellDive__context {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  min-width: 0;
  overflow: hidden;
}

.dash-cellDive__entity {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #222;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 130px;
}

.dash-cellDive__sep {
  color: #bbb;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.dash-cellDive__col {
  font-size: 0.75rem;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}

.dash-cellDive__close {
  border: none;
  background: none;
  font-size: 1.25rem;
  line-height: 1;
  color: #999;
  cursor: pointer;
  padding: 0.125rem 0.3rem;
  border-radius: 4px;
  transition: background 120ms ease, color 120ms ease;
  flex-shrink: 0;
}

.dash-cellDive__close:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.dash-cellDive__textarea {
  width: 100%;
  min-height: 60px;
  padding: 0.5rem 0.625rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  font-family: inherit;
  color: #333;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  background: #fafafa;
  resize: vertical;
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.dash-cellDive__textarea:focus {
  border-color: var(--color-accent, #0ea5e9);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.12);
  background: #fff;
}

.dash-cellDive__footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.5rem;
}

.dash-cellDive__submit {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.85rem;
  font-size: 0.8125rem;
  font-weight: 600;
  font-family: inherit;
  color: #fff;
  background: var(--color-accent, #0ea5e9);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 120ms ease, transform 80ms ease;
}

.dash-cellDive__submit:hover {
  background: #0284c7;
}

.dash-cellDive__submit:active {
  transform: scale(0.97);
}

/* Deep-dive indicator on cells */

.dash-gridTable__cell--deepDive {
  position: relative;
  box-shadow: inset 0 0 0 2px var(--color-accent, #0ea5e9);
  border-radius: 2px;
}

.dash-gridTable__cell--deepDive::after {
  content: '';
  position: absolute;
  top: 3px;
  right: 3px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--color-accent, #0ea5e9);
  pointer-events: none;
}

/* Column editor drag handle */
.dash-colEditor__dragHandle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  flex-shrink: 0;
  cursor: grab;
  color: #bbb;
  margin-right: 2px;
  border-radius: 3px;
  transition: color 120ms ease, background 120ms ease;
}

.dash-colEditor__dragHandle:hover {
  color: #777;
  background: rgba(0, 0, 0, 0.04);
}

.dash-colEditor__dragHandle:active {
  cursor: grabbing;
}

.dash-colEditor__row--dragging {
  opacity: 0.35;
  outline: 1.5px dashed var(--color-accent, #0ea5e9);
  outline-offset: -1px;
  border-radius: 6px;
}

.dash-colEditor__row--dragover {
  border-top: 2.5px solid var(--color-accent, #0ea5e9) !important;
}

/* Recent items (was "Saved grids") */

.dash-grid__saved {
  margin-top: 0.375rem;
  padding-top: 0;
}

.dash-grid__savedBadge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  padding: 3px;
  border-radius: 4px;
  vertical-align: middle;
  flex-shrink: 0;
}

.dash-grid__savedBadge svg {
  display: block;
  width: 12px;
  height: 12px;
}

.dash-grid__savedBadge--chat {
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
}

.dash-grid__savedBadge--grid {
  background: rgba(14, 165, 233, 0.1);
  color: #0ea5e9;
}

.dash-grid__savedToggle {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  border: none;
  background: none;
  padding: 0.3rem 0;
  cursor: pointer;
  width: 100%;
  text-align: left;
}

.dash-grid__savedLabel {
  font-size: 0.75rem;
  font-weight: 600;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dash-grid__savedChevron {
  color: #999;
  transition: transform 200ms ease;
}

.dash-grid__savedToggle--open .dash-grid__savedChevron {
  transform: rotate(180deg);
}

.dash-grid__savedBody {
  padding-top: 0.35rem;
  max-height: 40vh;
  overflow-y: auto;
}

.dash-grid__savedList {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dash-grid__savedRow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  width: 100%;
  border: none;
  background: none;
  padding: 0.45rem 0.5rem;
  border-radius: 7px;
  cursor: grab;
  text-align: left;
  transition: background 120ms ease;
}

.dash-grid__savedRow:hover {
  background: rgba(0, 0, 0, 0.04);
}

.dash-grid__savedInfo {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 1;
}

.dash-grid__savedName {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-grid__savedMeta {
  font-size: 0.6875rem;
  color: #999;
}

.dash-grid__savedDelete {
  flex-shrink: 0;
  font-size: 1.1rem;
  line-height: 1;
  color: #ccc;
  cursor: pointer;
  padding: 0.125rem 0.25rem;
  border-radius: 4px;
  transition: color 120ms ease, background 120ms ease;
}

.dash-grid__savedDelete:hover {
  color: #b91c1c;
  background: rgba(185, 28, 28, 0.06);
}

.dash-grid__savedRow--dragging {
  opacity: 0.45;
}

.dash-grid__savedEmpty {
  font-size: 0.8125rem;
  color: #999;
  margin: 0.25rem 0 0;
}

@media (max-width: 600px) {
  .dash-grid__header {
    flex-direction: column;
    align-items: flex-start;
  }

  .dash-grid__templatePicker {
    right: auto;
    left: 0;
  }

  .dash-gridTable {
    min-width: 1000px;
  }

  .dash-gridTable td {
    min-width: 120px;
    font-size: 0.75rem;
    padding: 0.45rem 0.5rem;
  }

  .dash-gridTable th {
    font-size: 0.6875rem;
    padding: 0.5rem 0.5rem;
  }

  .dash-gridTable__scroll {
    max-height: 50vh;
  }
}

/* ==========================================================================
   Chat top bar — sticky title + fade gradient (Claude-inspired)
   ========================================================================== */

.dash-chatTopbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  padding: 0.625rem 0.25rem;
  background: #fff;
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity 250ms ease, transform 250ms ease;
}

.dash-chatTopbar--visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.dash-chatTopbar::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  height: 60px;
  background: linear-gradient(to bottom, #fff 0%, transparent 100%);
  pointer-events: none;
}

.dash-chatTopbar__homeBtn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  margin-right: 4px;
  padding: 0;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: #666;
  cursor: pointer;
  transition: background 150ms ease, color 150ms ease;
}

.dash-chatTopbar__homeBtn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.dash-chatTopbar__homeBtn:active {
  background: rgba(0, 0, 0, 0.1);
}

.dash-chatTopbar__title {
  display: block;
  min-width: 0;
  flex: 1 1 auto;
  font-size: 0.875rem;
  font-weight: 600;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.01em;
}

/* ==========================================================================
   Chat thread — Claude-style (clean typography, full-width assistant)
   ========================================================================== */

.dash-chat {
  margin: 0 0 var(--dash-space-2);
}

.dash-chat__messages {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  max-height: 78vh;
  overflow-y: auto;
  scroll-behavior: smooth;
  padding: 0.5rem 0.125rem 0.5rem 0;
}

.dash-chat__messages--active {
  min-height: 20vh;
}

.dash-chat__messages--active::before {
  content: '';
  min-height: 0;
  flex-shrink: 0;
}

.dash-chat__messages--active > :first-child {
  margin-top: 0;
}

/* ---------- Bubble base ---------- */

.dash-chat__bubble {
  font-size: 0.9rem;
  line-height: 1.65;
  transform: translateY(10px);
  opacity: 0;
  transition: transform 200ms ease-out, opacity 200ms ease-out;
}

.dash-chat__bubble--visible {
  transform: translateY(0);
  opacity: 1;
}

/* ---------- User bubble ---------- */

.dash-chat__bubble--user {
  align-self: flex-end;
  max-width: 70%;
  padding: 0.55rem 0.85rem;
  border-radius: 1.15rem 1.15rem 0.25rem 1.15rem;
  background: #f0f0f0;
  color: #2d2d2d;
  font-weight: 400;
}

/* ---------- Assistant response (Claude-style: full-width, no bg) ---------- */

.dash-chat__bubble--assistant {
  align-self: stretch;
  max-width: 100%;
  padding: 0;
  border-radius: 0;
  background: none;
  color: #333;
}

/* ---------- Markdown content wrapper ---------- */

.dash-chat__content {
  font-size: 0.9rem;
  line-height: 1.7;
  color: #333;
}

/* ---------- Streaming shimmer overlay ---------- */

.dash-chat__content--streaming {
  position: relative;
}

.dash-chat__content--streaming::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.45) 40%,
    rgba(255, 255, 255, 0.45) 60%,
    transparent 100%
  );
  background-size: 250% 100%;
  animation: dashChatShimmer 2s ease-in-out infinite;
  border-radius: 6px;
  opacity: 1;
  transition: opacity 0.5s ease-out;
}

.dash-chat__content--shimmer-out::before {
  opacity: 0;
}

@keyframes dashChatShimmer {
  0%   { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

/* Headings */
.dash-chat__content h1,
.dash-chat__content h2 {
  font-size: 1.1rem;
  font-weight: 650;
  margin: 1.35rem 0 0.45rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  color: #1a1a1a;
}

.dash-chat__content h3 {
  font-size: 1rem;
  font-weight: 600;
  margin: 1.1rem 0 0.35rem;
  color: #1a1a1a;
}

.dash-chat__content h4,
.dash-chat__content h5,
.dash-chat__content h6 {
  font-size: 0.925rem;
  font-weight: 600;
  margin: 0.9rem 0 0.3rem;
  color: #1a1a1a;
}

.dash-chat__content h1:first-child,
.dash-chat__content h2:first-child,
.dash-chat__content h3:first-child {
  margin-top: 0;
}

/* Paragraphs */
.dash-chat__content p {
  margin: 0.45rem 0;
}

.dash-chat__content p:first-child {
  margin-top: 0;
}

/* Bold / italic */
.dash-chat__content strong,
.dash-chat__content b {
  font-weight: 600;
  color: #1a1a1a;
}

/* Lists */
.dash-chat__content ul,
.dash-chat__content ol {
  margin: 0.5rem 0;
  padding-left: 1.4rem;
}

.dash-chat__content li {
  margin: 0.25rem 0;
}

.dash-chat__content li > p {
  margin: 0.15rem 0;
}

/* Links */
.dash-chat__content a {
  color: var(--color-accent, #0ea5e9);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 150ms ease;
}

.dash-chat__content a:hover {
  border-bottom-color: currentColor;
}

/* Horizontal rule */
.dash-chat__content hr {
  border: none;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  margin: 1rem 0;
}

/* Inline code */
.dash-chat__content code {
  font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 0.82em;
  background: rgba(0, 0, 0, 0.055);
  padding: 0.15em 0.35em;
  border-radius: 4px;
  color: #d6336c;
}

/* Code blocks */
.dash-chat__content pre {
  background: #1e1e2e;
  color: #cdd6f4;
  border-radius: 8px;
  padding: 0.85rem 1rem;
  margin: 0.7rem 0;
  overflow-x: auto;
  font-size: 0.82rem;
  line-height: 1.55;
}

.dash-chat__content pre code {
  background: none;
  padding: 0;
  border-radius: 0;
  color: inherit;
  font-size: inherit;
}

/* Blockquote */
.dash-chat__content blockquote {
  border-left: 3px solid var(--color-accent, #0ea5e9);
  margin: 0.7rem 0;
  padding: 0.4rem 0 0.4rem 0.9rem;
  color: #666;
  font-style: italic;
}

.dash-chat__content blockquote p {
  margin: 0.25rem 0;
}

/* Tables */
.dash-chat__content table {
  border-collapse: collapse;
  width: 100%;
  margin: 0.7rem 0;
  font-size: 0.84rem;
}

.dash-chat__content th,
.dash-chat__content td {
  text-align: left;
  padding: 0.45rem 0.6rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.dash-chat__content th {
  font-weight: 600;
  color: #1a1a1a;
  border-bottom-width: 2px;
}

/* ---------- Typing indicator ---------- */

.dash-chat__typing {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 0;
}

.dash-chat__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #999;
  opacity: 0.3;
  animation: dash-chat-dot 0.9s ease-in-out infinite;
}

.dash-chat__dot:nth-child(1) { animation-delay: 0ms; }
.dash-chat__dot:nth-child(2) { animation-delay: 150ms; }
.dash-chat__dot:nth-child(3) { animation-delay: 300ms; }

@keyframes dash-chat-dot {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

/* ---------- Blinking caret ---------- */

.dash-chat__caret {
  display: inline;
  font-weight: 300;
  color: #999;
  animation: dash-chat-blink 530ms step-end infinite;
}

.dash-chat__caret--fade-out {
  animation: none;
  opacity: 0;
  transition: opacity 300ms ease-out;
}

@keyframes dash-chat-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* ---------- Sources — horizontal scrolling pills ---------- */

.dash-chat__sources {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 220ms ease-out, transform 220ms ease-out;
}

.dash-chat__sources--visible {
  opacity: 1;
  transform: translateY(0);
}

.dash-chat__sources-title {
  width: 100%;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #888;
  margin-bottom: 0.15rem;
}

.dash-chat__source {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.65rem 0.3rem 0.45rem;
  border-radius: 100px;
  background: #f5f5f5;
  border: 1px solid rgba(0, 0, 0, 0.06);
  text-decoration: none;
  color: inherit;
  font-size: 0.78rem;
  transition: background 150ms ease-out, border-color 150ms ease-out, box-shadow 150ms ease-out;
}

.dash-chat__source:hover {
  background: #ebebeb;
  border-color: rgba(0, 0, 0, 0.12);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.dash-chat__source-favicon {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  flex-shrink: 0;
}

.dash-chat__source-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.dash-chat__source-title {
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.3;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.dash-chat__source-domain {
  font-size: 0.65rem;
  color: #999;
  line-height: 1.3;
}

/* ══════════════════════════════════════════════════════════════
   Company profile modal
   ══════════════════════════════════════════════════════════════ */

.dash-companyOverlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 900;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.dash-companyOverlay.is-hidden,
.dash-companyModal.is-hidden {
  display: none;
}

.dash-companyModal {
  position: fixed;
  top: 3vh;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 2rem);
  max-width: 900px;
  max-height: 94vh;
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
  z-index: 910;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ── Back-layer card (visible behind when stacked) ── */

.dash-companyModal__backLayer {
  position: fixed;
  top: 3vh;
  left: 50%;
  transform: translateX(-50%) scale(0.96);
  width: calc(100% - 2rem);
  max-width: 900px;
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.10);
  z-index: 905;
  padding: 1.25rem 1.5rem;
  opacity: 0.55;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.dash-companyModal__backLayer.is-hidden {
  display: none;
}

.dash-companyModal.is-stacked {
  top: 5vh;
  max-height: 90vh;
  animation: stackSlideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes stackSlideIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
  }
}

@media (max-width: 640px) {
  .dash-companyModal__backLayer {
    top: 0;
    border-radius: 0;
    width: 100%;
    max-width: 100%;
  }

  .dash-companyModal.is-stacked {
    top: 2vh;
    max-height: 98vh;
  }
}

/* ── Back button ── */

.dash-companyModal__back {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 5;
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dash-companyModal__back:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.dash-companyModal__back.is-hidden {
  display: none;
}

/* ── Actions bar (bell + close) ── */

.dash-companyModal__actions {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dash-companyModal__close {
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dash-companyModal__close:hover {
  background: #f1f5f9;
  color: #0f172a;
}

/* ── Bell button ── */

.dash-companyModal__bell {
  position: relative;
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #94a3b8;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dash-companyModal__bell:hover {
  background: #f1f5f9;
  color: #64748b;
}

/* ── Attach-to-composer button ── */

.dash-companyModal__attach {
  position: relative;
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #94a3b8;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dash-companyModal__attach:hover {
  background: #f1f5f9;
  color: #2563eb;
}

.dash-companyModal__bell .dash-bellIcon { display: none; }
.dash-companyModal__bell .dash-bellIcon--off { display: block; }

.dash-companyModal__bell.is-active {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 2px 12px rgba(37, 99, 235, 0.35);
}
.dash-companyModal__bell.is-active:hover {
  background: #1d4ed8;
  color: #fff;
}
.dash-companyModal__bell.is-active .dash-bellIcon--off { display: none; }
.dash-companyModal__bell.is-active .dash-bellIcon--on { display: block; }

.dash-companyModal__bell.is-scheduled {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 2px 12px rgba(37, 99, 235, 0.35);
}
.dash-companyModal__bell.is-scheduled:hover {
  background: #1d4ed8;
  color: #fff;
}
.dash-companyModal__bell.is-scheduled .dash-bellIcon--off { display: none; }
.dash-companyModal__bell.is-scheduled .dash-bellIcon--scheduled { display: block; }

/* ── Bell dropdown ── */

.dash-companyModal__bellDropdown {
  position: absolute;
  top: calc(100% + 0.35rem);
  right: 36px;
  min-width: 220px;
  background: #fff;
  border-radius: 0.65rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.14), 0 1px 3px rgba(0, 0, 0, 0.06);
  padding: 0.35rem 0;
  z-index: 20;
  overflow: hidden;
}

.dash-companyModal__bellDropdown.is-hidden {
  display: none;
}

.dash-companyModal__bellDropItem {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.6rem 0.85rem;
  border: 0;
  background: transparent;
  font-size: 0.82rem;
  color: #334155;
  cursor: pointer;
  text-align: left;
  transition: background 0.12s ease;
  white-space: nowrap;
}

.dash-companyModal__bellDropItem:hover {
  background: #f1f5f9;
}

.dash-companyModal__bellDropItem svg {
  flex-shrink: 0;
  color: #64748b;
}

.dash-companyModal__bellDropItem.is-on span {
  font-weight: 600;
  color: #2563eb;
}

/* ── Schedule panel ── */

@keyframes scheduleOverlayFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.dash-companyModal__schedulePanel {
  position: absolute;
  inset: 0;
  z-index: 15;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(2px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 2rem 1.25rem;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  animation: scheduleOverlayFadeIn 0.2s ease;
}

.dash-companyModal__schedulePanel.is-hidden {
  display: none;
}

.dash-schedulePanel__inner {
  width: 100%;
  max-width: 440px;
  max-height: calc(100% - 4rem);
  overflow-y: auto;
  margin: auto;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.85rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.10);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
}

.dash-schedulePanel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.dash-schedulePanel__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
}

.dash-schedulePanel__close {
  appearance: none;
  border: 0;
  background: transparent;
  font-size: 1.3rem;
  color: #94a3b8;
  cursor: pointer;
  padding: 0.1rem 0.3rem;
  line-height: 1;
  border-radius: 4px;
  transition: color 0.12s ease;
}

.dash-schedulePanel__close:hover {
  color: #0f172a;
}

.dash-schedulePanel__section {
  margin-bottom: 1.1rem;
}

.dash-schedulePanel__label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748b;
  margin-bottom: 0.45rem;
}

.dash-schedulePanel__freqGroup {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.dash-schedulePanel__radio {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.82rem;
  color: #334155;
  cursor: pointer;
  padding: 0.35rem 0.7rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  transition: border-color 0.12s ease, background 0.12s ease;
}

.dash-schedulePanel__radio:hover {
  border-color: #cbd5e1;
  background: #f8fafc;
}

.dash-schedulePanel__radio input {
  accent-color: #2563eb;
}

.dash-schedulePanel__radio:has(input:checked) {
  border-color: #2563eb;
  background: #eff6ff;
  color: #1e40af;
  font-weight: 600;
}

.dash-schedulePanel__select {
  display: block;
  width: 100%;
  max-width: 180px;
  padding: 0.45rem 0.6rem;
  font-size: 0.82rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  color: #334155;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.12s ease;
}

.dash-schedulePanel__select:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.dash-schedulePanel__checkGroup {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  max-height: 160px;
  overflow-y: auto;
}

.dash-schedulePanel__check {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: #334155;
  cursor: pointer;
  padding: 0.3rem 0.45rem;
  border-radius: 0.35rem;
  transition: background 0.1s ease;
}

.dash-schedulePanel__check:hover {
  background: #f8fafc;
}

.dash-schedulePanel__check input {
  accent-color: #2563eb;
  flex-shrink: 0;
}

.dash-schedulePanel__footer {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid #f1f5f9;
}

.dash-schedulePanel__btn {
  appearance: none;
  border: 0;
  border-radius: 0.5rem;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: background 0.12s ease, color 0.12s ease;
}

.dash-schedulePanel__btn--cancel {
  background: #f1f5f9;
  color: #475569;
}

.dash-schedulePanel__btn--cancel:hover {
  background: #e2e8f0;
}

.dash-schedulePanel__btn--confirm {
  background: #2563eb;
  color: #fff;
}

.dash-schedulePanel__btn--confirm:hover {
  background: #1d4ed8;
}

.dash-companyModal__scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* ── Identity header ── */

.dash-companyModal__identity {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: #fff;
  border-bottom: 1px solid #e0e0e0;
}

.dash-companyModal__logo {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #fff;
  flex-shrink: 0;
}

.dash-companyModal__logo img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.dash-companyModal__logoFallback {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  background: #f1f5f9;
  color: #475569;
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dash-companyModal__identityText {
  min-width: 0;
}

.dash-companyModal__identityHead {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
}

.dash-companyModal__name {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  color: #111;
  line-height: 1.25;
}

.dash-companyModal__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  align-items: center;
}

.dash-companyModal__tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 6px;
}

.dash-companyModal__tag--type {
  background-color: #e0f2fe;
  color: #0369a1;
}

.dash-companyModal__tag--stage {
  background-color: #fce7f3;
  color: #be185d;
}

.dash-companyModal__ticker {
  margin: 0.25rem 0 0;
  font-size: 0.9rem;
  color: #5f6368;
  font-weight: 600;
}

.dash-companyModal__founded {
  margin: 0.125rem 0 0;
  font-size: 0.84rem;
  color: #64748b;
  font-weight: 500;
}

/* ── Tabs layout ── */

.dash-companyModal__tabs {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.dash-companyModal__nav {
  display: flex;
  flex-direction: row;
  width: 100%;
  overflow-x: auto;
  border-bottom: 1px solid #e0e0e0;
  background-color: #f7f9fa;
  flex-shrink: 0;
}

.dash-companyModal__tab {
  background: none;
  border: none;
  padding: 14px 20px;
  text-align: left;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: #5f6368;
  transition: all 0.2s ease;
  border-bottom: 3px solid transparent;
  outline: none;
  white-space: nowrap;
}

.dash-companyModal__tab:hover {
  background-color: #eef2f5;
  color: #202124;
}

.dash-companyModal__tab.active {
  background-color: #fff;
  color: #0056b3;
  border-bottom-color: #0056b3;
}

/* ── Tab panels ── */

.dash-companyModal__panels {
  flex-grow: 1;
  padding: 2rem 2rem 2.5rem;
  background-color: #fff;
}

.dash-companyModal__panel {
  display: none !important;
  animation: dashCompanyFadeIn 0.3s ease;
}

.dash-companyModal__panel.active {
  display: block !important;
}

@keyframes dashCompanyFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dash-companyModal__kicker {
  text-transform: uppercase;
  font-size: 0.6875rem;
  letter-spacing: 1px;
  color: #888;
  margin: 0 0 0.5rem;
  font-weight: 700;
}

.dash-companyModal__panelTitle {
  font-size: 1.35rem;
  margin: 0 0 1.15rem;
  color: #111;
  font-weight: 700;
  line-height: 1.3;
}

.dash-companyModal__text {
  font-size: 0.9375rem;
  line-height: 1.65;
  color: #444;
  margin-bottom: 1.15rem;
}

.dash-companyModal__links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.dash-companyModal__links a {
  color: #0056b3;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  border-bottom: 1px solid transparent;
}

.dash-companyModal__links a:hover {
  border-bottom-color: #0056b3;
}

.dash-companyModal__emailBtn {
  display: inline-block;
  margin-top: 0.75rem;
  padding: 0.65rem 1.15rem;
  background-color: #0056b3;
  color: #fff !important;
  border-radius: 6px;
  text-decoration: none !important;
  font-weight: 600;
  font-size: 0.875rem;
  border: none;
  border-bottom: none !important;
  transition: background-color 0.15s ease;
}

.dash-companyModal__emailBtn:hover {
  background-color: #004494;
}

/* ── Management panel ── */

.dash-companyModal__mgmt {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.75rem;
}

.dash-companyModal__ceoFallback {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #f1f5f9;
  color: #475569;
  font-size: 0.875rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dash-companyModal__ceoPhoto {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  flex-shrink: 0;
  object-fit: cover;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.dash-companyModal__mgmtText {
  flex: 1;
  min-width: 0;
}

.dash-companyModal__ceoTitle {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  font-weight: 700;
  color: #111;
}

.dash-companyModal__mgmtText .dash-companyModal__text {
  margin-bottom: 0;
}

.dash-companyModal__mgmtSeparator {
  margin: 1.75rem 0 1.25rem;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
}

/* ── Interview quotes ── */

.dash-companyModal__quotes {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
}

.dash-companyModal__quotesHeading {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748b;
}

.dash-companyModal__quotesSource {
  display: inline-block;
  margin-bottom: 0.85rem;
  font-size: 0.8rem;
  font-style: italic;
  font-weight: 400;
  color: #64748b;
  text-decoration: none;
  transition: color 0.15s ease;
}

.dash-companyModal__quotesSource:hover {
  color: #ca8a04;
  text-decoration: underline;
}

/* ── Video interview quotes ── */

.dash-companyModal__videoQuotes {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
}

.dash-companyModal__videoEmbed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  margin-bottom: 0.75rem;
  border-radius: 8px;
  overflow: hidden;
  background: #0f172a;
}

.dash-companyModal__videoEmbed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.dash-companyModal__tsLabel {
  display: inline-block;
  margin-right: 0.45em;
  padding: 0.15em 0.45em;
  font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 600;
  line-height: 1.4;
  color: #64748b;
  background: rgba(148, 163, 184, 0.15);
  border-radius: 4px;
  text-decoration: none;
  vertical-align: middle;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.dash-companyModal__tsLabel:hover {
  background: #fef08a;
  color: #92400e;
}

.dash-companyModal__quote {
  margin: 0 0 0.85rem;
  padding: 0;
  border: none;
  font-size: 0.9rem;
  line-height: 1.65;
  color: #475569;
  font-style: italic;
}

.dash-companyModal__quote:last-child {
  margin-bottom: 0;
}

.dash-companyModal__quoteGroup {
  border-left: 3px solid rgba(202, 138, 4, 0.35);
  background: rgba(254, 249, 195, 0.12);
  border-radius: 0 6px 6px 0;
  padding: 0.6rem 0.75rem;
  margin: 0 0 0.85rem;
}

.dash-companyModal__quoteGroup .dash-companyModal__quote {
  margin-bottom: 0.4rem;
}

.dash-companyModal__quoteGroup .dash-companyModal__quote:last-child {
  margin-bottom: 0;
}

.dash-companyModal__quoteEllipsis {
  color: #94a3b8;
  font-style: normal;
}

.dash-companyModal__quoteContext {
  color: #475569;
}

.dash-companyModal__quoteHighlight {
  background: #fef9c3;
  color: #1e293b;
  text-decoration: none;
  padding: 0.1em 0.2em;
  border-radius: 3px;
  font-style: italic;
  border-bottom: 1.5px solid transparent;
  transition: background 0.15s ease, border-color 0.15s ease;
  cursor: pointer;
}

.dash-companyModal__quoteHighlight:hover {
  background: #fef08a;
  border-bottom-color: #ca8a04;
  color: #1e293b;
}

/* ── Conditions panel ── */

.dash-companyModal__conditionsList {
  margin: 0;
  padding-left: 1.2rem;
}

.dash-companyModal__conditionItem {
  margin: 0.35rem 0;
  line-height: 1.5;
  font-size: 0.9375rem;
  color: #333;
}

.dash-companyModal__conditionName {
  margin-right: 0.2rem;
}

.dash-companyModal__infoWrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-left: 0.15rem;
}

.dash-companyModal__infoBtn {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1px solid rgba(148, 163, 184, 0.65);
  background: #fff;
  color: #475569;
  font-size: 0.625rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.dash-companyModal__infoBtn:hover,
.dash-companyModal__infoBtn:focus-visible {
  border-color: #0056b3;
  color: #0056b3;
  outline: none;
}

.dash-companyModal__infoTip {
  position: absolute;
  left: calc(100% + 8px);
  top: 50%;
  transform: translateY(-50%);
  min-width: 200px;
  max-width: 300px;
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.55rem 0.65rem;
  font-size: 0.75rem;
  line-height: 1.45;
  box-shadow: 0 8px 24px rgba(2, 6, 23, 0.28);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: 30;
}

.dash-companyModal__infoWrap:hover .dash-companyModal__infoTip,
.dash-companyModal__infoWrap.is-open .dash-companyModal__infoTip {
  opacity: 1;
  visibility: visible;
}

/* ── Responsive ── */

@media (min-width: 768px) {
  .dash-companyModal__tabs {
    flex-direction: row;
  }

  .dash-companyModal__nav {
    flex-direction: column;
    width: 220px;
    overflow-x: visible;
    border-bottom: none;
    border-right: 1px solid #e0e0e0;
  }

  .dash-companyModal__tab {
    border-bottom: none;
    border-left: 3px solid transparent;
    padding: 14px 20px;
  }

  .dash-companyModal__tab.active {
    border-bottom: none;
    border-left-color: #0056b3;
    position: relative;
    z-index: 2;
    margin-right: -1px;
    border-right: 1px solid transparent;
  }

  .dash-companyModal__panels {
    padding: 2rem 2.5rem 2.5rem;
  }
}

@media (max-width: 640px) {
  .dash-companyModal {
    top: 0;
    max-height: 100vh;
    border-radius: 0;
    width: 100%;
    max-width: 100%;
  }

  .dash-companyModal__identity {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
  }

  .dash-companyModal__logo {
    width: 48px;
    height: 48px;
  }

  .dash-companyModal__logo img {
    width: 36px;
    height: 36px;
  }

  .dash-companyModal__logoFallback {
    width: 48px;
    height: 48px;
    font-size: 0.875rem;
  }

  .dash-companyModal__name {
    font-size: 1.1rem;
  }

  .dash-companyModal__panels {
    padding: 1.25rem;
  }

  .dash-companyModal__panelTitle {
    font-size: 1.1rem;
  }

  .dash-companyModal__infoTip {
    left: auto;
    right: 0;
    top: calc(100% + 8px);
    transform: none;
    min-width: 200px;
    max-width: 260px;
  }
}

/* ─────────────────────── Latest Posts cards (modal) ─────────────────────── */

.dash-companyModal__latestPosts {
  margin-top: 1.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
}

.dash-companyModal__postsHeading {
  margin: 0 0 1rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #64748b;
}

.dash-postCard {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1rem;
  padding: 0.85rem;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 0.75rem;
  background: #ffffff;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  margin-bottom: 0.75rem;
}

.dash-postCard:hover {
  border-color: rgba(75, 137, 185, 0.35);
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
  transform: translateY(-1px);
}

.dash-postCard__image {
  border-radius: 0.5rem;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
}

.dash-postCard__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.dash-postCard__image--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.dash-postCard__image--empty span {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.dash-postCard__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.dash-postCard__title {
  margin: 0 0 0.35rem;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.3;
  color: #0f172a;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dash-postCard:hover .dash-postCard__title {
  color: #2563eb;
}

.dash-postCard__excerpt {
  margin: 0 0 0.45rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: #475569;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dash-postCard__meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.68rem;
  color: #94a3b8;
}

.dash-postCard__author {
  font-weight: 600;
  color: #64748b;
}

.dash-postCard__date {
  position: relative;
}

.dash-postCard__author + .dash-postCard__date::before {
  content: '\00b7';
  margin-right: 0.5rem;
}

.dash-postCard__readTime {
  position: relative;
}

.dash-postCard__readTime::before {
  content: '\00b7';
  margin-right: 0.5rem;
}

.dash-postCard__videoEmbed {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  margin-top: 0.5rem;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
}

.dash-postCard__videoEmbed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ── Video embed collapse / expand ── */

.dash-postCard__videoWrapper {
  display: contents;
}

.dash-postCard__videoEmbed.is-collapsed {
  display: none;
}

.dash-postCard__videoToggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.55rem;
  padding: 0.3rem 0.7rem;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.07);
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.dash-postCard__videoToggle:hover {
  background: rgba(37, 99, 235, 0.14);
  border-color: rgba(37, 99, 235, 0.32);
}

.dash-postCard__videoToggleIcon {
  display: inline-block;
  font-size: 0.6rem;
  transition: transform 0.2s ease;
}

.dash-postCard__videoWrapper.is-expanded .dash-postCard__videoToggleIcon {
  transform: rotate(90deg);
}

@media (max-width: 640px) {
  .dash-postCard {
    grid-template-columns: 100px 1fr;
    gap: 0.65rem;
    padding: 0.65rem;
  }

  .dash-postCard__title {
    font-size: 0.82rem;
  }

  .dash-postCard__excerpt {
    -webkit-line-clamp: 1;
    font-size: 0.74rem;
  }
}

@media (max-width: 420px) {
  .dash-postCard {
    grid-template-columns: 1fr;
  }

  .dash-postCard__image {
    aspect-ratio: 16 / 8;
  }
}

/* ──────────────────────────── Stock Chart (modal) ──────────────────────────── */

.dash-companyModal__stockChart {
  margin-top: 12px;
  border: 1px solid rgba(15, 23, 42, 0.18);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.18);
  background:
    radial-gradient(900px 480px at 18% 12%, rgba(0, 217, 255, 0.22), rgba(0, 0, 0, 0) 60%),
    radial-gradient(720px 420px at 82% 18%, rgba(0, 255, 170, 0.14), rgba(0, 0, 0, 0) 62%),
    linear-gradient(180deg, #070a1a 0%, #0a0e27 55%, #060814 100%);
  position: relative;
}

.dash-companyModal__stockInner {
  position: relative;
}

.dash-companyModal__stockPattern {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='100' height='86.6' viewBox='0 0 100 86.6'><path d='M50 0 L93.3 21.65 L93.3 64.95 L50 86.6 L6.7 64.95 L6.7 21.65 Z' fill='none' stroke='%2300d9ff' stroke-width='1' opacity='0.18'/></svg>");
  background-size: 100px 86.6px;
  opacity: 1;
  pointer-events: none;
  mix-blend-mode: screen;
}

.dash-companyModal__stockContent {
  position: relative;
}

.dash-companyModal__stockHeader {
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.04));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.dash-companyModal__stockName {
  font-weight: 700;
  letter-spacing: -0.01em;
  color: rgba(255, 255, 255, 0.92);
}

.dash-companyModal__stockTicker {
  font-size: 12px;
  opacity: 0.75;
  color: rgba(255, 255, 255, 0.82);
}

.dash-companyModal__stockBody {
  background: linear-gradient(180deg, #f7fbff 0%, #ffffff 55%);
}

.dash-companyModal__stockIframe {
  height: 380px;
}

.dash-companyModal__stockIframe iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.dash-companyModal__stockCredit {
  margin: 0;
  padding: 10px 14px;
  font-size: 12px;
  opacity: 0.7;
  color: rgba(15, 23, 42, 0.75);
}

/* ────────────────────────── Signal toast (modal) ────────────────────────── */

.dash-companyModal__signalToast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 0.85rem;
  box-shadow: 0 14px 40px rgba(2, 6, 23, 0.38);
  padding: 1rem 1.25rem;
  z-index: 10002;
  min-width: 280px;
  max-width: 420px;
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.dash-companyModal__signalToast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.dash-companyModal__signalEyebrow {
  margin: 0;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.62rem;
  font-weight: 700;
}

.dash-companyModal__signalTitle {
  margin: 0.3rem 0 0.15rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.dash-companyModal__signalHint {
  margin: 0;
  color: #94a3b8;
  font-size: 0.78rem;
}

.dash-companyModal__signalClose {
  position: absolute;
  top: 0.6rem;
  right: 0.7rem;
  appearance: none;
  border: 0;
  background: transparent;
  color: #94a3b8;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.15rem 0.35rem;
}

.dash-companyModal__signalClose:hover {
  color: #fff;
}

/* ──────────────────────── Pipeline (modal) ──────────────────────── */

.dash-companyModal .c-company-page__pipeline {
  margin-top: 0;
  color: #0f172a;
  padding: 0;
}

.dash-companyModal .c-company-pipeline__hero {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.dash-companyModal .c-company-pipeline__hero .c-section-heading__title {
  color: #0f172a;
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  font-family: var(--font-family-sansSerif, -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif);
}

.dash-companyModal .c-company-pipeline__subtitle {
  margin: 0.4rem 0 0;
  color: #64748b;
  font-size: 0.85rem;
  line-height: 1.55;
}

.dash-companyModal .c-company-pipeline__phase-header {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 1rem;
  margin: 0 0 1.25rem;
  padding: 0.6rem 0.75rem;
  background: #f8fafc;
  border-radius: 0.6rem;
}

.dash-companyModal .c-company-pipeline__phases {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.35rem;
}

.dash-companyModal .c-company-pipeline__phases span {
  text-align: center;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid rgba(148, 163, 184, 0.2);
}

.dash-companyModal .c-company-pipeline__focus {
  margin-top: 0;
}

.dash-companyModal .c-company-pipeline__focus + .c-company-pipeline__focus {
  margin-top: 0.5rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(148, 163, 184, 0.15);
}

.dash-companyModal .c-company-pipeline__focus-trigger {
  display: flex;
  align-items: center;
  width: 100%;
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0.45rem 0 0.55rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #475569;
  cursor: pointer;
  text-align: left;
  transition: color 0.15s ease;
}

.dash-companyModal .c-company-pipeline__focus-trigger:hover {
  color: #0f172a;
}

.dash-companyModal .c-company-pipeline__focus-chevron {
  display: inline-block;
  margin-left: 0.4rem;
  font-size: 0.7em;
  transition: transform 0.25s ease;
}

.dash-companyModal .c-company-pipeline__focus.is-open .c-company-pipeline__focus-chevron {
  transform: rotate(180deg);
}

.dash-companyModal .c-company-pipeline__focus-content {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              opacity 0.3s ease,
              visibility 0.3s ease;
}

.dash-companyModal .c-company-pipeline__focus.is-open .c-company-pipeline__focus-content {
  max-height: 3000px;
  overflow: visible;
  opacity: 1;
  visibility: visible;
}

.dash-companyModal .c-pipeline-card {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 0.75rem;
  overflow: visible;
  background: #fff;
  margin-bottom: 0.75rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.dash-companyModal .c-pipeline-card:hover {
  border-color: rgba(148, 163, 184, 0.35);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.07);
}

.dash-companyModal .c-pipeline-card__trigger {
  appearance: none;
  border: 0;
  background: transparent;
  width: 100%;
  color: inherit;
  text-align: left;
  padding: 0;
  cursor: pointer;
}

.dash-companyModal .c-pipeline-card__main {
  display: grid;
  grid-template-columns: 200px 1fr auto;
  gap: 1rem;
  align-items: start;
  padding: 1rem 1.1rem 0.9rem;
  border-left: 3px solid transparent;
  border-radius: 0.75rem 0.75rem 0 0;
}

.dash-companyModal .c-pipeline-card--eye .c-pipeline-card__main { border-left-color: #4b89b9; }
.dash-companyModal .c-pipeline-card--vax .c-pipeline-card__main { border-left-color: #5c8f74; }
.dash-companyModal .c-pipeline-card--bio .c-pipeline-card__main { border-left-color: #9c6f86; }

.dash-companyModal .c-pipeline-card__asset h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.005em;
}

.dash-companyModal .c-pipeline-card__asset p {
  margin: 0.2rem 0 0;
  color: #94a3b8;
  font-size: 0.72rem;
  line-height: 1.35;
  font-weight: 500;
}

.dash-companyModal .c-pipeline-card__indication {
  margin: 0 0 0.3rem;
  font-size: 0.8rem;
  color: #1e293b;
  font-weight: 500;
}

.dash-companyModal .c-pipeline-card__therapy {
  margin: 0 0 0.5rem;
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #94a3b8;
  font-weight: 600;
}

.dash-companyModal .c-pipeline-card__track {
  height: 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.15);
  overflow: hidden;
}

.dash-companyModal .c-pipeline-card__fill {
  height: 100%;
  border-radius: inherit;
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.dash-companyModal .c-pipeline-card__fill--eye { background: linear-gradient(90deg, rgba(75, 137, 185, 0.25), #4b89b9); }
.dash-companyModal .c-pipeline-card__fill--vax { background: linear-gradient(90deg, rgba(92, 143, 116, 0.25), #5c8f74); }
.dash-companyModal .c-pipeline-card__fill--bio { background: linear-gradient(90deg, rgba(156, 111, 134, 0.25), #9c6f86); }

.dash-companyModal .c-pipeline-card__stage {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.35rem;
}

.dash-companyModal .c-pipeline-card__badge {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 0.35rem;
}

.dash-companyModal .c-pipeline-card__badge--eye { color: #355f7d; background: rgba(75, 137, 185, 0.12); }
.dash-companyModal .c-pipeline-card__badge--vax { color: #3f634f; background: rgba(92, 143, 116, 0.12); }
.dash-companyModal .c-pipeline-card__badge--bio { color: #6f4e61; background: rgba(156, 111, 134, 0.12); }

.dash-companyModal .c-pipeline-card__chevron {
  color: #cbd5e1;
  font-size: 0.85rem;
  margin-top: 0.15rem;
  transition: transform 0.25s ease, color 0.15s ease;
}

.dash-companyModal .c-pipeline-card:hover .c-pipeline-card__chevron {
  color: #94a3b8;
}

.dash-companyModal .c-pipeline-card.is-open .c-pipeline-card__chevron {
  transform: rotate(180deg);
  color: #64748b;
}

.dash-companyModal .c-pipeline-card__meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  background: #fafbfc;
  border-radius: 0 0 0.75rem 0.75rem;
}

.dash-companyModal .c-pipeline-card__meta > div {
  padding: 0.65rem 0.85rem;
  border-right: 1px solid rgba(148, 163, 184, 0.12);
}

.dash-companyModal .c-pipeline-card__meta > div:last-child {
  border-right: 0;
}

.dash-companyModal .c-pipeline-card__meta span {
  display: block;
  font-size: 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94a3b8;
  margin-bottom: 0.2rem;
  font-weight: 600;
}

.dash-companyModal .c-pipeline-card__meta strong {
  display: block;
  font-size: 0.75rem;
  color: #334155;
  line-height: 1.4;
  font-weight: 500;
}

.c-pipeline-card__partnerPill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.45rem 0.15rem 0.3rem;
  border-radius: 999px;
  background: rgba(75, 137, 185, 0.08);
  border: 1px solid rgba(75, 137, 185, 0.18);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
  vertical-align: middle;
  line-height: 1;
}

.c-pipeline-card__partnerPill:hover {
  background: rgba(75, 137, 185, 0.15);
  border-color: rgba(75, 137, 185, 0.35);
}

.c-pipeline-card__partnerLogo {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  object-fit: contain;
  flex-shrink: 0;
}

.c-pipeline-card__partnerInitials {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  background: rgba(75, 137, 185, 0.18);
  color: #355f7d;
  font-size: 0.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.c-pipeline-card__partnerName {
  font-size: 0.65rem;
  font-weight: 600;
  color: #355f7d;
  white-space: nowrap;
}

.c-pipeline-card__ownershipText {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.7rem;
  color: #64748b;
  font-weight: 400;
}

.dash-companyModal .c-meta-info-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-left: 0.25rem;
}

.dash-companyModal .c-meta-info-wrap--text {
  margin-left: 0;
  cursor: help;
  border-bottom: 1px dotted rgba(75, 137, 185, 0.5);
}

.dash-companyModal .c-meta-info-wrap--text:hover {
  border-bottom-color: #4b89b9;
}

.dash-companyModal .c-meta-info {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: #fff;
  color: #94a3b8;
  font-size: 0.6rem;
  font-style: italic;
  font-weight: 600;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.dash-companyModal .c-meta-info:hover,
.dash-companyModal .c-meta-info:focus-visible {
  border-color: #4b89b9;
  color: #4b89b9;
  outline: none;
}

.dash-companyModal .c-meta-tooltip {
  position: absolute;
  left: calc(100% + 8px);
  top: 50%;
  transform: translateY(-50%);
  min-width: 220px;
  max-width: 300px;
  background: #1e293b;
  color: #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.6rem 0.75rem;
  font-size: 0.72rem;
  line-height: 1.5;
  box-shadow: 0 8px 24px rgba(2, 6, 23, 0.22);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: 30;
  transition: opacity 0.15s ease, visibility 0.15s ease;
}

.dash-companyModal .c-meta-info-wrap:hover .c-meta-tooltip,
.dash-companyModal .c-meta-info-wrap:focus-within .c-meta-tooltip,
.dash-companyModal .c-meta-info-wrap.is-open .c-meta-tooltip {
  opacity: 1;
  visibility: visible;
}

.dash-companyModal .c-next-signal-btn {
  appearance: none;
  border: 1px solid rgba(75, 137, 185, 0.35);
  background: rgba(75, 137, 185, 0.06);
  color: #3b7aaf;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  border-radius: 999px;
  padding: 0.3rem 0.65rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.dash-companyModal .c-next-signal-btn:hover,
.dash-companyModal .c-next-signal-btn:focus-visible {
  background: #4b89b9;
  border-color: #4b89b9;
  color: #fff;
  outline: none;
}

.dash-companyModal .c-pipeline-card__detail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  padding: 0 1.1rem;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  border-top: 1px solid transparent;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              opacity 0.3s ease,
              padding 0.3s ease;
}

.dash-companyModal .c-pipeline-card.is-open .c-pipeline-card__detail {
  max-height: 300px;
  opacity: 1;
  padding: 0.9rem 1.1rem 1.1rem;
  border-top-color: rgba(148, 163, 184, 0.12);
}

.dash-companyModal .c-pipeline-card__detail p {
  margin: 0 0 0.3rem;
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
  font-weight: 700;
}

.dash-companyModal .c-pipeline-card__detail div {
  color: #334155;
  font-size: 0.8rem;
  line-height: 1.55;
}

.dash-companyModal .c-pipeline-card--flag {
  border-color: rgba(92, 143, 116, 0.3);
  box-shadow: 0 1px 3px rgba(92, 143, 116, 0.08);
}

.dash-companyModal .c-pipeline-card--flag:hover {
  border-color: rgba(92, 143, 116, 0.45);
  box-shadow: 0 2px 8px rgba(92, 143, 116, 0.12);
}

/* Pipeline & stock responsive (modal) */

@media (max-width: 980px) {
  .dash-companyModal .c-company-pipeline__phase-header {
    display: none;
  }
}

@media (max-width: 840px) {
  .dash-companyModal .c-pipeline-card__main {
    grid-template-columns: 1fr auto;
    padding: 0.85rem 0.9rem 0.75rem;
  }

  .dash-companyModal .c-pipeline-card__progress {
    grid-column: 1 / -1;
  }

  .dash-companyModal .c-pipeline-card__asset {
    margin-bottom: 0.15rem;
  }

  .dash-companyModal .c-pipeline-card__meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dash-companyModal .c-pipeline-card__meta > div:nth-child(2n) {
    border-right: 0;
  }

  .dash-companyModal .c-pipeline-card__meta > div:nth-child(n + 3) {
    border-top: 1px solid rgba(148, 163, 184, 0.12);
  }

  .dash-companyModal .c-pipeline-card__detail {
    grid-template-columns: 1fr;
    padding-left: 0.9rem;
    padding-right: 0.9rem;
  }

  .dash-companyModal .c-meta-tooltip {
    left: auto;
    right: 0;
    top: calc(100% + 8px);
    transform: none;
    min-width: 200px;
    max-width: 260px;
  }
}

/* ==========================================================================
   Entity info modal (targets, conditions, pipeline assets)
   ========================================================================== */

.dash-entityOverlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 900;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.dash-entityOverlay.is-hidden,
.dash-entityModal.is-hidden {
  display: none;
}

.dash-entityModal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: calc(100% - 2rem);
  max-width: 580px;
  max-height: 85vh;
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
  z-index: 910;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: dashEntitySlideIn 0.25s ease-out;
}

@keyframes dashEntitySlideIn {
  from { opacity: 0; transform: translate(-50%, -46%); }
  to   { opacity: 1; transform: translate(-50%, -50%); }
}

/* ── Entity modal actions bar ── */

.dash-entityModal__actions {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dash-entityModal__attach {
  position: relative;
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #94a3b8;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dash-entityModal__attach:hover {
  background: #f1f5f9;
  color: #2563eb;
}

.dash-entityModal__bell {
  position: relative;
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #94a3b8;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dash-entityModal__bell:hover {
  background: #f1f5f9;
  color: #64748b;
}

.dash-entityModal__bell .dash-bellIcon { display: none; }
.dash-entityModal__bell .dash-bellIcon--off { display: block; }

.dash-entityModal__bell.is-active {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 2px 12px rgba(37, 99, 235, 0.35);
}
.dash-entityModal__bell.is-active:hover {
  background: #1d4ed8;
  color: #fff;
}
.dash-entityModal__bell.is-active .dash-bellIcon--off { display: none; }
.dash-entityModal__bell.is-active .dash-bellIcon--on { display: block; }

.dash-entityModal__bell.is-scheduled {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 2px 12px rgba(37, 99, 235, 0.35);
}
.dash-entityModal__bell.is-scheduled:hover {
  background: #1d4ed8;
  color: #fff;
}
.dash-entityModal__bell.is-scheduled .dash-bellIcon--off { display: none; }
.dash-entityModal__bell.is-scheduled .dash-bellIcon--scheduled { display: block; }

/* ── Entity bell dropdown ── */

.dash-entityModal__bellDropdown {
  position: absolute;
  top: calc(100% + 0.35rem);
  right: 36px;
  min-width: 220px;
  background: #fff;
  border-radius: 0.65rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.14), 0 1px 3px rgba(0, 0, 0, 0.06);
  padding: 0.35rem 0;
  z-index: 20;
  overflow: hidden;
}

.dash-entityModal__bellDropdown.is-hidden {
  display: none;
}

.dash-entityModal__bellDropItem {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.6rem 0.85rem;
  border: 0;
  background: transparent;
  font-size: 0.82rem;
  color: #334155;
  cursor: pointer;
  text-align: left;
  transition: background 0.12s ease;
  white-space: nowrap;
}

.dash-entityModal__bellDropItem:hover {
  background: #f1f5f9;
}

.dash-entityModal__bellDropItem svg {
  flex-shrink: 0;
  color: #64748b;
}

.dash-entityModal__bellDropItem.is-on span {
  font-weight: 600;
  color: #2563eb;
}

/* ── Entity schedule panel ── */

.dash-entityModal__schedulePanel {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid #e2e8f0;
  animation: scheduleOverlayFadeIn 0.2s ease-out;
}

.dash-entityModal__schedulePanel.is-hidden {
  display: none;
}

.dash-entityModal__close {
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dash-entityModal__close:hover {
  background: #f1f5f9;
  color: #0f172a;
}

/* ── Knowledge box modal (graph node details, e.g. Drug) ── */

.dash-knowledgeBox {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: calc(100% - 2rem);
  max-width: 680px;
  max-height: 85vh;
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
  z-index: 910;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dash-knowledgeBox.is-hidden {
  display: none;
}

.dash-knowledgeBox__actions {
  flex-shrink: 0;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 0.5rem 0.5rem 0 0;
}

.dash-knowledgeBox__close {
  border: 0;
  background: transparent;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease;
}

.dash-knowledgeBox__close:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.dash-knowledgeBox__watchBtn {
  border: 0;
  background: transparent;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.15s ease, color 0.15s ease;
}

.dash-knowledgeBox__watchBtn:hover {
  background: #f1f5f9;
  color: #0ea5e9;
}

.dash-knowledgeBox__watchBtn.is-watching {
  color: #0ea5e9;
}

.dash-knowledgeBox__watchBtn.is-watching:hover {
  background: #e0f2fe;
  color: #0284c7;
}

.dash-knowledgeBox__watchIcon {
  width: 18px;
  height: 18px;
  display: block;
}

.dash-knowledgeBox__watchIcon--on {
  display: none;
}

.dash-knowledgeBox__watchBtn.is-watching .dash-knowledgeBox__watchIcon--off {
  display: none;
}

.dash-knowledgeBox__watchBtn.is-watching .dash-knowledgeBox__watchIcon--on {
  display: block;
}

[data-color-scheme="dark"] .dash-knowledgeBox__watchBtn:hover {
  background: rgba(255,255,255,0.08);
}

[data-color-scheme="dark"] .dash-knowledgeBox__watchBtn.is-watching:hover {
  background: rgba(14,165,233,0.15);
}

.dash-knowledgeBox__scroll {
  overflow-y: auto;
  padding: 1rem 1.5rem 1.5rem;
}

.dash-knowledgeBox__header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #e2e8f0;
}

.dash-knowledgeBox__name {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0f172a;
}

.dash-knowledgeBox__typeBadge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
}

.dash-knowledgeBox__section {
  margin-bottom: 1.25rem;
}

.dash-knowledgeBox__section:last-child {
  margin-bottom: 0;
}

.dash-knowledgeBox__sectionTitle {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #475569;
  margin: 0 0 0.35rem 0;
  padding-bottom: 0.2rem;
  border-bottom: 1px solid #f1f5f9;
}

.dash-knowledgeBox__sectionContent {
  font-size: 0.85rem;
  line-height: 1.5;
  color: #334155;
}

.dash-knowledgeBox__loading,
.dash-knowledgeBox__error {
  color: #64748b;
  font-size: 0.9rem;
  margin: 0;
}

.dash-knowledgeBox__error {
  color: #dc2626;
}

/* Clickable link */
.dash-knowledgeBox__link { color: #6366f1; text-decoration: underline; text-decoration-thickness: 1px; word-break: break-all; }
.dash-knowledgeBox__link:hover { color: #4338ca; }

/* Pills (associations, indications, AE names, targets) */
.dash-knowledgeBox__pills { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.dash-knowledgeBox__pill { display: inline-flex; align-items: center; padding: 0.15rem 0.55rem; border-radius: 999px; font-size: 0.68rem; font-weight: 600; background: #f1f5f9; color: #475569; }

/* Trial status variants */
.dash-knowledgeBox__pill--active   { background: #dcfce7; color: #15803d; }
.dash-knowledgeBox__pill--inactive { background: #f1f5f9; color: #64748b; }
.dash-knowledgeBox__pill--failed   { background: #fee2e2; color: #b91c1c; }

/* Drug grid inside knowledge box */
.dash-knowledgeBox__drugGrid { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.dash-knowledgeBox__drugChip { padding: 0.2rem 0.55rem; background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 0.4rem; font-size: 0.78rem; color: #334155; cursor: pointer; transition: border-color 0.15s; }
.dash-knowledgeBox__drugChip:hover { border-color: #6366f1; color: #6366f1; }

/* Research paper card */
.dash-knowledgeBox__paperCard { display: flex; flex-direction: column; gap: 0.25rem; padding: 0.65rem 0.75rem; background: #f8fafc; border: 1px solid #f1f5f9; border-radius: 0.6rem; margin-bottom: 0.5rem; transition: border-color 0.15s; }
.dash-knowledgeBox__paperCard:hover { border-color: #e2e8f0; }
.dash-knowledgeBox__paperTitle { font-size: 0.8rem; font-weight: 600; color: #0f172a; }
.dash-knowledgeBox__paperSummary { font-size: 0.75rem; color: #64748b; line-height: 1.45; }
.dash-knowledgeBox__paperLink { align-self: flex-start; font-size: 0.7rem; color: #6366f1; text-decoration: underline; }

/* Key themes bullet list */
.dash-knowledgeBox__themeList { margin: 0; padding-left: 1.1rem; display: flex; flex-direction: column; gap: 0.35rem; }
.dash-knowledgeBox__themeList li { font-size: 0.82rem; color: #334155; line-height: 1.45; }

/* Metadata stat row */
.dash-knowledgeBox__stat { font-size: 0.72rem; color: #94a3b8; font-style: italic; }

/* Loading spinner */
.dash-knowledgeBox__spinner { display: flex; align-items: center; justify-content: center; padding: 2rem; color: #94a3b8; font-size: 0.85rem; }

/* Star (watchlist) button in header */
.dash-knowledgeBox__starBtn {
  border: 0;
  background: transparent;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: #94a3b8;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex-shrink: 0;
  transition: background 0.15s ease, color 0.15s ease;
}
.dash-knowledgeBox__starBtn:hover { background: #fef3c7; color: #f59e0b; }
.dash-knowledgeBox__starBtn.is-starred { color: #f59e0b; }
.dash-knowledgeBox__starBtn.is-starred:hover { background: #fef3c7; color: #d97706; }
.dash-knowledgeBox__starIcon { display: flex; align-items: center; }
.dash-knowledgeBox__starIcon--filled { display: none; }
.dash-knowledgeBox__starBtn.is-starred .dash-knowledgeBox__starIcon--empty { display: none; }
.dash-knowledgeBox__starBtn.is-starred .dash-knowledgeBox__starIcon--filled { display: flex; }

/* Enhance button + dropdown */
.dash-knowledgeBox__enhanceWrap {
  position: relative;
  display: inline-flex;
  margin-left: auto;
}
.dash-knowledgeBox__enhanceBtn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.7rem;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #f8fafc;
  color: #475569;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.dash-knowledgeBox__enhanceBtn:hover {
  background: #eef2ff;
  border-color: #a5b4fc;
  color: #4338ca;
}
.dash-knowledgeBox__enhanceDropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 200px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.65rem;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  z-index: 920;
  padding: 0.35rem 0;
  overflow: hidden;
}
.dash-knowledgeBox__enhanceDropdown.is-hidden { display: none; }
.dash-knowledgeBox__enhanceRow {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  transition: background 0.12s ease;
  font-size: 0.8rem;
  color: #334155;
}
.dash-knowledgeBox__enhanceRow:hover { background: #f1f5f9; }
.dash-knowledgeBox__enhanceLogo {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  flex-shrink: 0;
  object-fit: contain;
}
.dash-knowledgeBox__enhanceLabel {
  flex: 1;
  font-weight: 600;
  font-size: 0.78rem;
}
.dash-knowledgeBox__enhanceCoins {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: #92400e;
  white-space: nowrap;
}
.dash-knowledgeBox__coinIcon { flex-shrink: 0; }

/* Dark mode overrides for star + enhance */
[data-color-scheme="dark"] .dash-knowledgeBox__starBtn { color: #64748b; }
[data-color-scheme="dark"] .dash-knowledgeBox__starBtn:hover { background: rgba(245,158,11,0.15); color: #f59e0b; }
[data-color-scheme="dark"] .dash-knowledgeBox__starBtn.is-starred { color: #f59e0b; }
[data-color-scheme="dark"] .dash-knowledgeBox__enhanceBtn { background: #1e293b; border-color: #334155; color: #94a3b8; }
[data-color-scheme="dark"] .dash-knowledgeBox__enhanceBtn:hover { background: #312e81; border-color: #6366f1; color: #a5b4fc; }
[data-color-scheme="dark"] .dash-knowledgeBox__enhanceDropdown { background: #1e293b; border-color: #334155; box-shadow: 0 8px 24px rgba(0,0,0,0.35); }
[data-color-scheme="dark"] .dash-knowledgeBox__enhanceRow { color: #cbd5e1; }
[data-color-scheme="dark"] .dash-knowledgeBox__enhanceRow:hover { background: #334155; }
[data-color-scheme="dark"] .dash-knowledgeBox__enhanceCoins { color: #fbbf24; }

.dash-graphNode__infoCard-link {
  display: inline-block;
  margin-top: 0.35rem;
  font-size: 0.7rem;
  font-weight: 600;
  color: #6366f1;
  text-decoration: none;
}

.dash-graphNode__infoCard-link:hover {
  text-decoration: underline;
}

/* Drug node: company logo in circle + small pill badge bottom-right */
.dash-graphNode__logoWrap {
  pointer-events: none;
}

.dash-graphNode__logoImage {
  display: block;
}

.dash-graphNode__logoInitials {
  font-family: inherit;
  pointer-events: none;
}

.dash-graphNode__drugBadge {
  stroke: #fff;
  stroke-width: 1.2;
}

.dash-graphNode__drugBadgeIcon {
  opacity: 0.95;
}

/* ── Radial hover menu on graph nodes ── */

.dash-graphNode__radialHitArea {
  cursor: default;
}

.dash-graphNode__radialBtn {
  cursor: pointer;
  transition: transform 0.15s ease;
}

.dash-graphNode__radialBtn:hover {
  transform: scale(1.15);
}

.dash-graphNode__radialBtn:hover circle {
  filter: brightness(1.15);
}

.dash-graphNode__radialBtn circle {
  transition: filter 0.15s ease;
}

/* ── Toast notification ── */

.dash-toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: #1e293b;
  color: #fff;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 0.55rem 1.2rem;
  border-radius: 8px;
  box-shadow: 0 4px 18px rgba(0,0,0,0.18);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 10000;
  white-space: nowrap;
}

.dash-toast--visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.dash-entityModal__scroll {
  overflow-y: auto;
  padding: 1.75rem 1.5rem 1.5rem;
}

/* ── Header (icon + name + badge) ── */

.dash-entityModal__header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.dash-entityModal__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dash-entityModal__icon svg {
  width: 24px;
  height: 24px;
}

.dash-entityModal__icon--target {
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
}

.dash-entityModal__icon--condition {
  background: rgba(236, 72, 153, 0.1);
  color: #ec4899;
}
.dash-entityModal__icon--condition-eye {
  background: #ccfbf1;
  color: #0d9488;
}
.dash-entityModal__icon--condition-brain {
  background: #ede9fe;
  color: #7c3aed;
}
.dash-entityModal__icon--condition-liver {
  background: #fef3c7;
  color: #d97706;
}
.dash-entityModal__icon--condition-heart {
  background: #ffe4e6;
  color: #e11d48;
}

.dash-entityModal__icon--pipeline {
  background: rgba(14, 165, 233, 0.1);
  color: #0ea5e9;
}

.dash-entityModal__name {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.dash-entityModal__badge {
  display: inline-block;
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dash-entityModal__badge--target {
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
}

.dash-entityModal__badge--condition {
  background: rgba(236, 72, 153, 0.1);
  color: #ec4899;
}

.dash-entityModal__badge--pipeline {
  background: rgba(14, 165, 233, 0.1);
  color: #0ea5e9;
}

/* ── Body ── */

.dash-entityModal__body {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.dash-entityModal__desc {
  font-size: 0.9rem;
  line-height: 1.65;
  color: #334155;
  text-align: center;
}

/* ── Metadata grid ── */

.dash-entityModal__meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  background: #f8fafc;
  border-radius: 0.75rem;
  padding: 1rem;
}

.dash-entityModal__metaItem {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.dash-entityModal__metaItem--full {
  grid-column: 1 / -1;
}

.dash-entityModal__metaLabel {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #94a3b8;
}

.dash-entityModal__metaValue {
  font-size: 0.82rem;
  color: #0f172a;
  font-weight: 500;
  line-height: 1.4;
}

/* ── Pipeline stage bar ── */

.dash-entityModal__stageBar {
  height: 6px;
  background: #e2e8f0;
  border-radius: 3px;
  overflow: hidden;
  margin-top: 0.25rem;
}

.dash-entityModal__stageFill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.4s ease;
}

.dash-entityModal__stageFill--pipeline {
  background: linear-gradient(90deg, #0ea5e9, #38bdf8);
}

/* ── Related entities list ── */

.dash-entityModal__related {
  background: #f8fafc;
  border-radius: 0.75rem;
  padding: 0.85rem 1rem;
}

.dash-entityModal__relatedTitle {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  margin-bottom: 0.5rem;
}

.dash-entityModal__relatedList {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.dash-entityModal__relatedItem {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.82rem;
  color: #334155;
  line-height: 1.45;
  padding: 0.45rem 0.5rem;
  border-radius: 0.5rem;
  transition: background 0.15s;
}

.dash-entityModal__relatedItem:hover {
  background: rgba(148, 163, 184, 0.08);
}

.dash-entityModal__relatedItemLogo {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  object-fit: contain;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.dash-entityModal__relatedItemInitials {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
  font-size: 0.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.dash-entityModal__relatedItemText {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.dash-entityModal__relatedItemName {
  font-weight: 600;
  color: #0f172a;
}

.dash-entityModal__relatedItemDetail {
  color: #64748b;
  font-size: 0.75rem;
  line-height: 1.4;
}

/* ── Pipeline icon with company logo ── */

.dash-entityModal__icon--pipeline img {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  object-fit: contain;
}

/* ── Responsive ── */

@media (max-width: 540px) {
  .dash-entityModal {
    max-width: 100%;
    max-height: 100vh;
    border-radius: 0;
    top: 0;
    left: 0;
    transform: none;
    width: 100%;
    height: 100%;
  }

  @keyframes dashEntitySlideIn {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  .dash-entityModal__meta {
    grid-template-columns: 1fr;
  }
}

/* ── Target modal full-name subtitle ── */

.dash-entityModal__fullName {
  font-size: 0.78rem;
  color: #64748b;
  font-weight: 500;
  letter-spacing: 0.01em;
  margin-top: -0.15rem;
}

/* ── Target quick stats ── */

.dash-entityModal__targetStats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  background: #f8fafc;
  border-radius: 0.75rem;
  padding: 0.85rem 1rem;
}

.dash-entityModal__targetStat {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.dash-entityModal__targetStat--full {
  grid-column: 1 / -1;
}

.dash-entityModal__targetStatLabel {
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #94a3b8;
}

.dash-entityModal__targetStatValue {
  font-size: 0.8rem;
  font-weight: 500;
  color: #0f172a;
  line-height: 1.35;
}

.dash-entityModal__targetStatValue--accent {
  color: #6366f1;
  font-weight: 700;
}

/* ── Target sections (approved drugs, pipeline, companies, research) ── */

.dash-entityModal__targetSection {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.dash-entityModal__targetSectionTitle {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #475569;
  padding-bottom: 0.25rem;
  border-bottom: 1px solid #e2e8f0;
}

.dash-entityModal__targetSectionTitle svg {
  flex-shrink: 0;
  color: #94a3b8;
}

/* ── Drug card (used by both approved and pipeline sections) ── */

.dash-entityModal__drugCard {
  background: #f8fafc;
  border-radius: 0.6rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid #f1f5f9;
  transition: border-color 0.15s;
}

.dash-entityModal__drugCard:hover {
  border-color: #e2e8f0;
}

.dash-entityModal__drugCard--pipeline {
  background: #fafbff;
  border-color: rgba(99, 102, 241, 0.06);
}

.dash-entityModal__drugCardMain {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}

.dash-entityModal__drugBrand {
  font-size: 0.85rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.3;
}

.dash-entityModal__drugGeneric {
  font-size: 0.72rem;
  color: #64748b;
  font-style: italic;
  margin-bottom: 0.3rem;
}

.dash-entityModal__drugMeta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.5rem;
  font-size: 0.72rem;
  line-height: 1.4;
}

.dash-entityModal__drugCompany {
  color: #6366f1;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.1rem;
  flex-wrap: wrap;
}

.dash-entityModal__drugCompanyPill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  cursor: pointer;
  border-radius: 4px;
  padding: 0.05rem 0.2rem 0.05rem 0.1rem;
  transition: background 0.15s;
}

.dash-entityModal__drugCompanyPill:hover {
  background: rgba(99, 102, 241, 0.08);
}

.dash-entityModal__drugCompanyLogo {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  object-fit: cover;
  flex-shrink: 0;
}

.dash-entityModal__drugCompanyInitials {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  background: linear-gradient(135deg, #6366f1 0%, #818cf8 100%);
  color: #fff;
  font-size: 0.45rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.01em;
}

.dash-entityModal__drugCompanyName {
  color: #6366f1;
  font-weight: 600;
  font-size: inherit;
  line-height: inherit;
}

.dash-entityModal__drugCompanySep {
  color: #94a3b8;
  font-weight: 400;
  margin: 0 0.05rem;
}

.dash-entityModal__drugIndication {
  color: #64748b;
}

/* ── Phase badges ── */

.dash-entityModal__phaseBadge {
  display: inline-flex;
  align-items: center;
  padding: 0.12rem 0.5rem;
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}

.dash-entityModal__phaseBadge--approved {
  background: rgba(16, 185, 129, 0.1);
  color: #059669;
}

.dash-entityModal__phaseBadge--phase3 {
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
}

.dash-entityModal__phaseBadge--phase2 {
  background: rgba(14, 165, 233, 0.1);
  color: #0284c7;
}

.dash-entityModal__phaseBadge--phase1 {
  background: rgba(245, 158, 11, 0.1);
  color: #d97706;
}

.dash-entityModal__phaseBadge--preclinical {
  background: rgba(100, 116, 139, 0.1);
  color: #64748b;
}

/* ── Company chips ── */

.dash-entityModal__companyChips {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
}

.dash-entityModal__companyChip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #f8fafc;
  border-radius: 0.6rem;
  padding: 0.5rem 0.6rem;
  border: 1px solid #f1f5f9;
  transition: border-color 0.15s, background 0.15s;
  cursor: pointer;
}

.dash-entityModal__companyChip:hover {
  border-color: #c7d2fe;
  background: #f0f0ff;
}

.dash-entityModal__companyChipAvatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.dash-entityModal__companyChipLogo {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
}

.dash-entityModal__companyChipInitials {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1 0%, #818cf8 100%);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.02em;
}

.dash-entityModal__companyChipText {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  min-width: 0;
}

.dash-entityModal__companyChipName {
  font-size: 0.78rem;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-entityModal__companyChipFocus {
  font-size: 0.65rem;
  color: #64748b;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── Research list ── */

.dash-entityModal__researchList {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.dash-entityModal__researchList li {
  position: relative;
  padding-left: 1rem;
  font-size: 0.78rem;
  line-height: 1.55;
  color: #334155;
}

.dash-entityModal__researchList li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #6366f1;
  opacity: 0.5;
}

/* ── Target modal responsive override ── */

@media (max-width: 540px) {
  .dash-entityModal__companyChips {
    grid-template-columns: 1fr;
  }

  .dash-entityModal__targetStats {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Drag-and-drop file upload – persistent hint + overlay
   ========================================================================== */

/* ── Persistent hint strip (always visible, positioned above the toolbar) ── */

.dash-composer__dropHint {
  position: absolute;
  bottom: 3rem;
  left: 0.875rem;
  right: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0;
  pointer-events: auto;
  user-select: none;
  z-index: 1;
}

.dash-composer__dropHint-icon {
  flex-shrink: 0;
  color: #b0b8c4;
  transition: color 0.15s ease;
}

.dash-composer__dropHint-text {
  font-size: 0.75rem;
  font-weight: 500;
  color: #a0a8b4;
  letter-spacing: -0.005em;
  white-space: nowrap;
}

.dash-composer__dropHint-sep {
  color: #c8cdd4;
  font-size: 0.75rem;
  line-height: 1;
}

.dash-composer__dropHint-browse {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-accent, #0ea5e9);
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.dash-composer__dropHint-browse:hover {
  color: var(--color-accent-hover, #0284c7);
  text-decoration: underline;
}

.dash-composer__dropHint:hover .dash-composer__dropHint-icon {
  color: #8891a0;
}

/* ── Full drop overlay (shown only during drag-over) ── */

.dash-composer__dropOverlay {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: rgba(240, 249, 255, 0.92);
  border: 2px dashed var(--color-accent, #0ea5e9);
  border-radius: var(--dash-radius);
  pointer-events: none;
  animation: dashDropOverlayIn 150ms ease;
}

@keyframes dashDropOverlayIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.dash-composer__dropOverlay-icon {
  color: var(--color-accent, #0ea5e9);
  opacity: 0.7;
}

.dash-composer__dropOverlay-title {
  font-size: 1rem;
  font-weight: 700;
  color: #0c4a6e;
  letter-spacing: -0.01em;
}

.dash-composer__dropOverlay-sub {
  font-size: 0.8125rem;
  color: #64748b;
  font-weight: 400;
}

/* Show overlay when dragover class is active */
.dash-composer__inputWrap.dash-composer--dragover .dash-composer__dropOverlay {
  display: flex;
}

.dash-composer__inputWrap.dash-composer--dragover .dash-composer__textarea {
  border-color: var(--color-accent, #0ea5e9);
  background: transparent;
}

.dash-composer__inputWrap.dash-composer--dragover .dash-composer__dropHint,
.dash-composer__inputWrap.dash-composer--dragover .dash-composer__staticHint,
.dash-composer__inputWrap.dash-composer--dragover .dash-composer__toolbar {
  opacity: 0;
  pointer-events: none;
}

/* ================================================================
   FA PROGRESS BAR (shown during full report generation)
   ================================================================ */

.dash-faProgress {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 3rem 2rem;
  min-height: 200px;
}

.dash-faProgress__label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #475569;
  letter-spacing: 0.01em;
  text-align: center;
}

.dash-faProgress__track {
  width: 100%;
  max-width: 420px;
  height: 6px;
  background: #e2e8f0;
  border-radius: 3px;
  overflow: hidden;
}

.dash-faProgress__fill {
  height: 100%;
  width: 0%;
  border-radius: 3px;
  background: linear-gradient(90deg, #6366f1, #818cf8);
  transition: width 400ms cubic-bezier(0.4, 0, 0.2, 1);
}

.dash-faProgress__pct {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

/* ================================================================
   FAILURE ANALYSIS REPORT
   ================================================================ */

.dash-faLoading {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1.25rem 1.5rem;
  font-size: 0.875rem;
  color: #64748b;
}

.dash-faLoading__spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid #e2e8f0;
  border-top-color: #64748b;
  border-radius: 50%;
  animation: dashFaSpin 0.6s linear infinite;
}

@keyframes dashFaSpin {
  to { transform: rotate(360deg); }
}

.dash-faReport {
  padding: 1.5rem;
  font-size: 0.875rem;
  line-height: 1.6;
  color: #1e293b;
}

.dash-faReport h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem;
  letter-spacing: -0.01em;
}

.dash-faReport h4 {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #334155;
  margin: 1rem 0 0.375rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dash-faReport p {
  margin: 0 0 0.75rem;
  color: #334155;
}

.dash-faReport__summary {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
}

.dash-faReport__bottomLine {
  font-size: 0.9375rem;
  line-height: 1.65;
}

.dash-faReport__confRow {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid #e2e8f0;
}

.dash-faReport__confLabel {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
}

.dash-faReport__conf {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.125rem 0.625rem;
  border-radius: 6px;
  letter-spacing: 0.02em;
}

.dash-faReport__conf--high {
  background: #dcfce7;
  color: #166534;
}

.dash-faReport__conf--medium {
  background: #fef9c3;
  color: #854d0e;
}

.dash-faReport__conf--low {
  background: #fee2e2;
  color: #991b1b;
}

.dash-faReport__list {
  margin: 0 0 0.5rem;
  padding-left: 1.25rem;
  list-style: disc;
}

.dash-faReport__list li {
  margin-bottom: 0.25rem;
  color: #334155;
}

.dash-faReport__section {
  border-top: 1px solid #f1f5f9;
  padding-top: 1.25rem;
  margin-top: 1.25rem;
}

.dash-faReport__dq {
  margin-top: 0.75rem;
  padding: 0.625rem 0.875rem;
  background: #f1f5f9;
  border-radius: 8px;
}

.dash-faReport__dqLabel {
  display: block;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #94a3b8;
  margin-bottom: 0.375rem;
}

.dash-faReport__dqList {
  margin: 0;
  padding-left: 1rem;
  list-style: decimal;
}

.dash-faReport__dqList li {
  font-size: 0.8125rem;
  color: #475569;
  margin-bottom: 0.2rem;
}

/* ── Evidence Appendix Accordion ── */

.dash-faAccordion {
  margin-top: 2rem;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
}

.dash-faAccordion__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.875rem 1.25rem;
  background: #f8fafc;
  border: none;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 700;
  color: #0f172a;
  text-align: left;
  transition: background 150ms ease;
}

.dash-faAccordion__header:hover {
  background: #f1f5f9;
}

.dash-faAccordion__chevron {
  display: inline-flex;
  transition: transform 200ms ease;
  color: #64748b;
}

.dash-faAccordion__chevron.is-open {
  transform: rotate(180deg);
}

.dash-faAccordion__body {
  padding: 1rem 1.25rem 1.25rem;
}

.dash-faAccordion__subhead {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #334155;
  margin: 1.25rem 0 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dash-faAccordion__subhead:first-child {
  margin-top: 0;
}

.dash-faTable__wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-bottom: 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.dash-faTable {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.75rem;
  line-height: 1.5;
}

.dash-faReport .dash-faTable {
  table-layout: fixed;
}

.dash-faTable th {
  background: #f8fafc;
  font-weight: 600;
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #e2e8f0;
  white-space: nowrap;
  color: #475569;
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dash-faTable td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
  vertical-align: top;
  max-width: 260px;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.dash-faReport .dash-faTable th {
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.dash-faTable tbody tr:last-child td {
  border-bottom: none;
}

.dash-faTable tbody tr:hover {
  background: #f8fafc;
}

/* ── Evidence Snapshot ── */

.dash-faEvidence {
  padding: 1.25rem 1.5rem 1rem;
  margin-bottom: 1.25rem;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fafbfc;
}

.dash-faEvidence h3 {
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #475569;
  margin: 0 0 0.5rem;
}

.dash-faEvidence__headline {
  font-size: 1.125rem;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.5;
  margin: 0 0 1rem;
}

.dash-faEvidence__hidden {
  display: inline-block;
  background: #eef2ff;
  color: #4f46e5;
  font-weight: 700;
  padding: 1px 8px;
  border-radius: 9999px;
  font-size: 0.9375rem;
  cursor: help;
  border-bottom: 1px dotted #6366f1;
}

.dash-faEvidence__map {
  position: relative;
  max-height: 260px;
  overflow: hidden;
  border-radius: 8px;
  background: transparent;
  border: 1px solid transparent;
}

.dash-faMap__svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 260px;
}

.dash-faMap--bg {
  fill: transparent;
}

.dash-faEvidence__assets {
  margin-top: 1rem;
}

.dash-faEvidence__assetsTitle {
  margin: 0 0 0.5rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
}

.dash-faEvidence__assetsList {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.5rem;
}

.dash-faEvidence__assetItem {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.45rem 0.6rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.55);
}

.dash-faEvidence__assetName {
  font-size: 0.8125rem;
  color: #0f172a;
  font-weight: 600;
  min-width: 0;
  overflow-wrap: anywhere;
}

.dash-faMap__land {
  fill: #e8ecf0;
  stroke: none;
}

.dash-faMap__country {
  stroke: #cbd5e1;
  stroke-width: 0.35;
  cursor: default;
  transition: fill 150ms ease;
}

.dash-faMap--lvl0 {
  fill: #e2e8f0;
}

.dash-faMap--lvl1 {
  fill: #bfdbfe;
}

.dash-faMap--lvl2 {
  fill: #60a5fa;
}

.dash-faMap--lvl3 {
  fill: #2563eb;
}

.dash-faMap__country[data-tooltip]:hover {
  filter: brightness(0.88);
  cursor: pointer;
}

.dash-faMap__tooltip {
  position: absolute;
  z-index: 50;
  background: #1e293b;
  color: #f8fafc;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.4;
  padding: 4px 10px;
  border-radius: 6px;
  white-space: nowrap;
  pointer-events: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
}

/* ── Hidden study row pill ── */

.dash-faTable__row--hidden {
  background: #faf5ff;
}

.dash-faTable__row--hidden:hover {
  background: #f3e8ff;
}

.dash-faTable__hiddenPill {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 7px;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #4f46e5;
  background: #eef2ff;
  border-radius: 9999px;
  vertical-align: middle;
}

@media (max-width: 640px) {
  .dash-faEvidence {
    padding: 1rem;
  }
  .dash-faEvidence__headline {
    font-size: 1rem;
  }
  .dash-faEvidence__map {
    max-height: 180px;
  }
}

/* ================================================================
   TABLES: Conversational table builder
   ================================================================ */

.dash-tables-viewHidden {
  display: none !important;
}

.dash-tables {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  padding: 0;
}

.dash-tables__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem 0.75rem;
  flex-shrink: 0;
}

.dash-tables__title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dash-text);
  margin: 0;
}

.dash-tables__newBtn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--dash-accent, #6366f1);
  background: transparent;
  border: 1px solid var(--dash-accent, #6366f1);
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.dash-tables__newBtn:hover {
  background: var(--dash-accent, #6366f1);
  color: #fff;
}

/* Messages / conversation thread */

.dash-tables__messages {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 0 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 60px;
}

.dash-tables__bubble {
  max-width: 88%;
  padding: 0.75rem 1rem;
  border-radius: 14px;
  font-size: 0.875rem;
  line-height: 1.5;
  word-wrap: break-word;
  animation: dashTablesFadeIn 0.2s ease;
}

@keyframes dashTablesFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.dash-tables__bubble--user {
  align-self: flex-end;
  background: var(--dash-accent, #6366f1);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.dash-tables__bubble--assistant {
  align-self: flex-start;
  background: var(--dash-surface, #f4f4f5);
  color: var(--dash-text, #18181b);
  border-bottom-left-radius: 4px;
}

.dash-tables__errorText {
  color: #dc2626;
}

/* Typing indicator */

.dash-tables__typing {
  display: inline-flex;
  gap: 4px;
  align-items: center;
  padding: 2px 0;
}

.dash-tables__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--dash-muted, #a1a1aa);
  animation: dashTablesDotPulse 1.2s ease-in-out infinite;
}

.dash-tables__dot:nth-child(2) { animation-delay: 0.15s; }
.dash-tables__dot:nth-child(3) { animation-delay: 0.3s; }

@keyframes dashTablesDotPulse {
  0%, 80%, 100% { opacity: 0.3; transform: scale(0.85); }
  40% { opacity: 1; transform: scale(1.1); }
}

/* Question options */

.dash-tables__question {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dash-tables__questionText {
  margin: 0;
  font-weight: 500;
}

.dash-tables__questionOptions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dash-tables__optionBtn {
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--dash-text, #18181b);
  background: var(--dash-bg, #fff);
  border: 1px solid var(--dash-border, #e4e4e7);
  border-radius: 9999px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.dash-tables__optionBtn:hover {
  border-color: var(--dash-accent, #6366f1);
  color: var(--dash-accent, #6366f1);
}

.dash-tables__optionBtn.is-selected {
  background: var(--dash-accent, #6366f1);
  color: #fff;
  border-color: var(--dash-accent, #6366f1);
}

.dash-tables__optionConfirm {
  padding: 6px 18px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #fff;
  background: var(--dash-accent, #6366f1);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: opacity 0.15s;
}

.dash-tables__optionConfirm:hover {
  opacity: 0.85;
}

/* Input bar */

.dash-tables__inputBar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0.75rem 1.25rem;
  flex-shrink: 0;
  border-top: 1px solid var(--dash-border, #e4e4e7);
}

.dash-tables__input {
  flex: 1;
  padding: 10px 14px;
  font-size: 0.875rem;
  color: var(--dash-text, #18181b);
  background: var(--dash-surface, #f4f4f5);
  border: 1px solid var(--dash-border, #e4e4e7);
  border-radius: 10px;
  outline: none;
  transition: border-color 0.15s;
}

.dash-tables__input:focus {
  border-color: var(--dash-accent, #6366f1);
}

.dash-tables__input:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.dash-tables__sendBtn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: var(--dash-accent, #6366f1);
  color: #fff;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: opacity 0.15s;
  flex-shrink: 0;
}

.dash-tables__sendBtn:hover { opacity: 0.85; }
.dash-tables__sendBtn:disabled { opacity: 0.4; cursor: not-allowed; }

/* Query editor */

.dash-tables__queryEditor {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 0 1.25rem;
}

.dash-tables__queryEditorHeader {
  padding: 0.5rem 0;
  flex-shrink: 0;
}

.dash-tables__queryEditorTitle {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--dash-text);
  margin: 0 0 4px;
}

.dash-tables__queryEditorHint {
  font-size: 0.8rem;
  color: var(--dash-muted, #71717a);
  margin: 0;
}

.dash-tables__queryEditorScroll {
  flex: 1 1 auto;
  overflow: auto;
  border: 1px solid var(--dash-border, #e4e4e7);
  border-radius: 10px;
  margin: 0.5rem 0;
}

.dash-tables__editTable {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.dash-tables__editTh {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--dash-surface, #f4f4f5);
  padding: 0;
  border-bottom: 2px solid var(--dash-border, #e4e4e7);
}

.dash-tables__editColInput {
  width: 100%;
  padding: 8px 10px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--dash-text);
  background: transparent;
  border: none;
  outline: none;
  box-sizing: border-box;
}

.dash-tables__editColInput:focus {
  background: var(--dash-bg, #fff);
  box-shadow: inset 0 0 0 2px var(--dash-accent, #6366f1);
}

.dash-tables__editTd {
  padding: 0;
  border-bottom: 1px solid var(--dash-border, #e4e4e7);
  border-right: 1px solid var(--dash-border, #e4e4e7);
  vertical-align: top;
}

.dash-tables__editTd--fixed {
  padding: 8px 10px;
  font-weight: 600;
  color: var(--dash-text);
  background: var(--dash-surface, #f4f4f5);
  position: sticky;
  left: 0;
  z-index: 1;
  min-width: 120px;
}

.dash-tables__editPrompt {
  width: 100%;
  min-width: 200px;
  padding: 8px 10px;
  font-size: 0.78rem;
  color: var(--dash-text);
  background: transparent;
  border: none;
  outline: none;
  resize: vertical;
  font-family: inherit;
  line-height: 1.4;
  box-sizing: border-box;
}

.dash-tables__editPrompt:focus {
  background: #eff6ff;
}

.dash-tables__queryEditorActions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 0.5rem 0;
  flex-shrink: 0;
}

/* Progress bar */

.dash-tables__progress {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0.5rem 1.25rem;
  flex-shrink: 0;
}

.dash-tables__progressLabel {
  font-size: 0.8rem;
  color: var(--dash-muted, #71717a);
  flex-shrink: 0;
}

.dash-tables__progressTrack {
  flex: 1;
  height: 6px;
  background: var(--dash-border, #e4e4e7);
  border-radius: 999px;
  overflow: hidden;
}

.dash-tables__progressFill {
  height: 100%;
  width: 0%;
  background: var(--dash-accent, #6366f1);
  border-radius: 999px;
  transition: width 0.3s ease;
}

.dash-tables__progressPct {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--dash-accent, #6366f1);
  min-width: 36px;
  text-align: right;
}

/* Table display */

.dash-tables__tableWrap {
  flex: 1 1 auto;
  overflow: auto;
  padding: 0 1.25rem;
  min-height: 0;
}

.dash-tables__cellError {
  background: #fef2f2 !important;
}

/* Recent tables dropdown */

.dash-tables__recent {
  flex-shrink: 0;
  padding: 0 1.25rem 0.75rem;
}

.dash-tables__recentToggle {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 0;
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--dash-muted, #71717a);
}

.dash-tables__recentToggle:hover {
  color: var(--dash-text, #18181b);
}

.dash-tables__recentChevron {
  transition: transform 0.2s;
}

.dash-tables__recentBody:not(.is-hidden) ~ .dash-tables__recentToggle .dash-tables__recentChevron,
.dash-tables__recentToggle[aria-expanded="true"] .dash-tables__recentChevron {
  transform: rotate(180deg);
}

.dash-tables__recentBody {
  max-height: 200px;
  overflow-y: auto;
}

.dash-tables__recentList {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dash-tables__recentRow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  background: none;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: background 0.12s;
}

.dash-tables__recentRow:hover {
  background: var(--dash-surface, #f4f4f5);
}

.dash-tables__recentInfo {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.dash-tables__recentName {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--dash-text, #18181b);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-tables__recentMeta {
  font-size: 0.72rem;
  color: var(--dash-muted, #a1a1aa);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-tables__recentDelete {
  font-size: 1.1rem;
  line-height: 1;
  color: var(--dash-muted, #a1a1aa);
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  flex-shrink: 0;
  opacity: 0;
  transition: opacity 0.12s, color 0.12s;
}

.dash-tables__recentRow:hover .dash-tables__recentDelete {
  opacity: 1;
}

.dash-tables__recentDelete:hover {
  color: #dc2626;
}

.dash-tables__recentEmpty {
  font-size: 0.78rem;
  color: var(--dash-muted, #a1a1aa);
  text-align: center;
  padding: 12px 0;
  margin: 0;
}

/* ==========================================================================
   Project Detail View
   ========================================================================== */

.dash-project {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}

.dash-project__header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-bottom: var(--dash-border);
  flex-shrink: 0;
  background: inherit;
  position: sticky;
  top: 0;
  z-index: 5;
}

.dash-project__back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: transparent;
  cursor: pointer;
  color: inherit;
  transition: background 0.15s;
  flex-shrink: 0;
}
.dash-project__back:hover {
  background: rgba(0,0,0,0.06);
}

.dash-project__headerInfo {
  min-width: 0;
  flex: 1;
}

.dash-project__title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-project__meta {
  font-size: 0.78rem;
  color: var(--dash-muted, #a1a1aa);
  margin-top: 2px;
  display: block;
}

.dash-project__body {
  flex: 1;
  overflow-y: auto;
  padding: 1.25rem;
  padding-bottom: 0;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Network graph hero banner */
.dash-project__networkBanner {
  width: 100%;
  height: 140px;
  flex-shrink: 0;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f7ff 0%, #f5f3ff 50%, #f0fdfa 100%);
}
.dash-project__networkBanner svg {
  display: block;
  width: 100%;
  height: 100%;
}

/* Real node pulse animation */
@keyframes dashProjectNodePulse {
  0%, 100% { opacity: 0.8; filter: drop-shadow(0 0 0px transparent); }
  50%       { opacity: 1;   filter: drop-shadow(0 0 6px currentColor); }
}
.dash-project__networkBanner .pn-real {
  animation: dashProjectNodePulse 3s ease-in-out infinite;
}

/* Dark mode */
[data-color-scheme="dark"] .dash-project__networkBanner {
  background: linear-gradient(135deg, #0f1729 0%, #15103a 50%, #04201e 100%);
}
[data-color-scheme="dark"] .dash-project__networkBanner .pn-edge {
  stroke: rgba(255,255,255,0.07) !important;
}
[data-color-scheme="dark"] .dash-project__networkBanner .pn-dummy circle {
  fill: #1e293b;
  stroke: #334155;
}

.dash-project__section {
  display: none;
}
.dash-project__section.has-items {
  display: block;
}

.dash-project__sectionTitle {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--dash-muted, #a1a1aa);
  margin: 0 0 0.75rem;
}
.dash-project__sectionTitle svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  opacity: 0.65;
}

/* Entity cards */
.dash-project__entities {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.dash-project__entityCard {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.08);
  background: #fff;
  box-shadow: var(--dash-shadow);
  transition: box-shadow 0.15s, border-color 0.15s;
  cursor: default;
  min-width: 0;
}
.dash-project__entityCard:hover {
  box-shadow: var(--dash-shadow-card);
  border-color: rgba(0,0,0,0.14);
}

.dash-project__entityLogo {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  object-fit: contain;
  flex-shrink: 0;
  background: #f4f4f5;
}

.dash-project__entityIcon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.dash-project__entityIcon svg {
  width: 16px;
  height: 16px;
}

.dash-project__entityIcon--company { background: #eff6ff; color: #2563eb; }
.dash-project__entityIcon--drug { background: #f5f3ff; color: #7c3aed; }
.dash-project__entityIcon--condition { background: #fffbeb; color: #d97706; }
.dash-project__entityIcon--target { background: #f0fdfa; color: #0d9488; }

.dash-project__entityName {
  font-size: 0.85rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-project__entityType {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 2px 6px;
  border-radius: 4px;
  flex-shrink: 0;
}
.dash-project__entityType--company { background: #dbeafe; color: #1d4ed8; }
.dash-project__entityType--drug { background: #ede9fe; color: #6d28d9; }
.dash-project__entityType--condition { background: #fef3c7; color: #b45309; }
.dash-project__entityType--target { background: #ccfbf1; color: #0f766e; }
.dash-project__entityType--web { background: #e0e7ff; color: #4338ca; }

.dash-project__entityIcon--web { background: #eef2ff; color: #4f46e5; }

/* Entity subgroups */
.dash-project__entitiesWrap {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.dash-project__entityGroup {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dash-project__entityGroupTitle {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--dash-muted, #a1a1aa);
  margin: 0;
}

.dash-project__entityGroupIcon {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.dash-project__entityGroupIcon svg {
  width: 12px;
  height: 12px;
}
.dash-project__entityGroupIcon--company { background: #eff6ff; color: #2563eb; }
.dash-project__entityGroupIcon--drug { background: #f5f3ff; color: #7c3aed; }
.dash-project__entityGroupIcon--condition { background: #fffbeb; color: #d97706; }
.dash-project__entityGroupIcon--target { background: #f0fdfa; color: #0d9488; }
.dash-project__entityGroupIcon--web { background: #eef2ff; color: #4f46e5; }

/* Entity pill cards (grouped by type) */
.dash-project__entityCards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.dash-project__entityPill {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  width: 88px;
  padding: 0.75rem 0.5rem 0.625rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  cursor: pointer;
  font-family: inherit;
  flex-shrink: 0;
  transition: background 0.12s, border-color 0.12s, box-shadow 0.12s;
}
.dash-project__entityPill:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.dash-project__pillLogoWrap {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.dash-project__pillLogo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}
.dash-project__pillAvatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #64748b;
  font-size: 0.72rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.03em;
}

.dash-project__pillIconWrap {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.dash-project__pillIconWrap svg { width: 18px; height: 18px; }
.dash-project__pillIconWrap--condition { background: #fffbeb; color: #d97706; }
.dash-project__pillIconWrap--target    { background: #f0fdfa; color: #0d9488; }
.dash-project__pillIconWrap--drug      { background: #f5f3ff; color: #7c3aed; }

.dash-project__pillName {
  font-size: 0.69rem;
  font-weight: 600;
  color: #0f172a;
  text-align: center;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.3;
}

[data-color-scheme="dark"] .dash-project__entityPill { background: rgba(255,255,255,0.05); border-color: rgba(255,255,255,0.1); }
[data-color-scheme="dark"] .dash-project__entityPill:hover { background: rgba(255,255,255,0.09); border-color: rgba(255,255,255,0.2); box-shadow: 0 2px 8px rgba(0,0,0,0.3); }
[data-color-scheme="dark"] .dash-project__pillAvatar { background: rgba(255,255,255,0.1); color: #94a3b8; }
[data-color-scheme="dark"] .dash-project__pillName { color: #e2e8f0; }

/* Sources section */
.dash-project__sources {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

/* URL source cards row */
.dash-project__sourceCards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.dash-project__sourceCards.is-hidden { display: none; }

/* URL source card — mirrors dash-attachCard style */
.dash-project__sourceCard {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 130px;
  max-width: 210px;
  padding: 0.45rem 1.75rem 0.45rem 0.45rem;
  background: #e8edf2;
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 10px;
  cursor: default;
  transition: background 0.15s, box-shadow 0.15s;
  animation: dashAttachCardIn 200ms ease;
}
.dash-project__sourceCard:hover {
  background: #dce3ea;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.dash-project__sourceCard__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  border-radius: 7px;
  background: #e0f2fe;
  color: #0284c7;
}

.dash-project__sourceCard__info {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.dash-project__sourceCard__name {
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #1e293b;
}

.dash-project__sourceCard__type {
  font-size: 0.6875rem;
  font-weight: 500;
  color: #64748b;
}

.dash-project__sourceCard__remove {
  position: absolute;
  top: 4px;
  right: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border: none;
  border-radius: 50%;
  background: rgba(0,0,0,0.08);
  color: #64748b;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s, background 0.15s, color 0.15s;
}
.dash-project__sourceCard:hover .dash-project__sourceCard__remove { opacity: 1; }
.dash-project__sourceCard__remove:hover {
  background: rgba(0,0,0,0.16);
  color: #1e293b;
}

/* Dropzone */
.dash-project__dropzone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 1.5rem 1rem 1.25rem;
  border: 2px dashed rgba(0,0,0,0.12);
  border-radius: 12px;
  background: rgba(0,0,0,0.015);
  color: var(--dash-muted, #a1a1aa);
  cursor: default;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
  text-align: center;
}
.dash-project__dropzone > svg {
  opacity: 0.4;
  transition: opacity 0.2s;
}
.dash-project__dropzone.is-dragover {
  border-color: var(--color-accent, #0ea5e9);
  background: rgba(14,165,233,0.04);
  color: var(--color-accent, #0ea5e9);
}
.dash-project__dropzone.is-dragover > svg { opacity: 0.75; }

/* URL icon button — top-right corner of dropzone */
.dash-project__urlIconBtn {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 7px;
  background: #fff;
  color: var(--color-accent, #0ea5e9);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
  z-index: 1;
}
.dash-project__urlIconBtn:hover {
  background: #e0f2fe;
  border-color: var(--color-accent, #0ea5e9);
  box-shadow: 0 0 0 3px rgba(14,165,233,0.12);
}
.dash-project__urlIconBtn.is-active {
  background: #e0f2fe;
  border-color: var(--color-accent, #0ea5e9);
}

.dash-project__dropzoneTitle {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-text-primary, #1e293b);
  opacity: 0.75;
  margin-bottom: 0.1rem;
}

.dash-project__dropzoneText {
  font-size: 0.8rem;
  font-weight: 500;
}

.dash-project__dropzoneHint {
  font-size: 0.7rem;
  opacity: 0.55;
  transition: color 0.2s, opacity 0.2s;
}
.dash-project__dropzoneHint.is-success {
  color: #16a34a;
  opacity: 1;
  font-weight: 500;
}

/* ── Project body: universal drop target ── */
.dash-project__body--dropTarget {
  outline: 2px dashed var(--color-accent, #0ea5e9);
  outline-offset: -6px;
  border-radius: 8px;
  background: rgba(14,165,233,0.03);
  transition: outline-color 0.15s, background 0.15s;
}
[data-color-scheme="dark"] .dash-project__body--dropTarget {
  background: rgba(14,165,233,0.06);
}

/* ── Chat content chunk wrappers ── */
.dash-chat__chunk {
  position: relative;
  border-radius: 8px;
  padding: 0.15rem 0.25rem;
  margin: 0 -0.25rem;
  transition: background 0.15s;
}
.dash-chat__chunk:hover {
  background: rgba(0,0,0,0.028);
}
[data-color-scheme="dark"] .dash-chat__chunk:hover {
  background: rgba(255,255,255,0.04);
}
.dash-chat__chunk--dragging {
  opacity: 0.45;
}

.dash-chat__chunkHandle {
  position: absolute;
  top: 0.35rem;
  right: 0.35rem;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0.2rem 0.5rem;
  border: none;
  border-radius: 6px;
  background: #e2e8f0;
  color: #475569;
  font-size: 0.7rem;
  font-weight: 600;
  cursor: grab;
  opacity: 0;
  transition: opacity 0.15s, background 0.15s;
  white-space: nowrap;
  pointer-events: auto;
  z-index: 2;
}
.dash-chat__chunkHandle:active { cursor: grabbing; }
.dash-chat__chunk:hover .dash-chat__chunkHandle { opacity: 1; }
[data-color-scheme="dark"] .dash-chat__chunkHandle {
  background: #334155;
  color: #94a3b8;
}

/* ── Watchlist row: grab cursor when draggable ── */
.dash-watchlist__row[draggable="true"] { cursor: grab; }
.dash-watchlist__row[draggable="true"]:active { cursor: grabbing; }
.dash-watchlist__row--project-dragging { opacity: 0.55; }

/* ── Entity pills: draggable ── */
.dash-queryPill[draggable="true"] { cursor: grab; }
.dash-queryPill--dragging { opacity: 0.5; }

/* ── Drop toast ── */
.dash-project__dropToast {
  position: fixed;
  bottom: 1.75rem;
  left: 50%;
  transform: translateX(-50%) translateY(1.5rem);
  background: #1e293b;
  color: #fff;
  padding: 0.55rem 1.1rem;
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 500;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 9999;
  white-space: nowrap;
}
.dash-project__dropToast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
[data-color-scheme="dark"] .dash-project__dropToast {
  background: #e2e8f0;
  color: #1e293b;
}

/* ── Chunk card remove button ── */
.dash-project__chatCardRemove {
  margin-left: auto;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border: none;
  border-radius: 4px;
  background: transparent;
  color: var(--dash-muted, #a1a1aa);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.15s, background 0.15s, color 0.15s;
}
.dash-project__chatCard:hover .dash-project__chatCardRemove { opacity: 1; }
.dash-project__chatCardRemove:hover { background: rgba(239,68,68,0.1); color: #ef4444; }

/* URL input row (below the dropzone) */
.dash-project__addUrlInput {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid rgba(0,0,0,0.12);
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.dash-project__addUrlInput:focus-within {
  border-color: var(--color-accent, #0ea5e9);
  box-shadow: 0 0 0 3px rgba(14,165,233,0.1);
}
.dash-project__addUrlInput.is-hidden { display: none; }

.dash-project__addUrlInput-icon {
  flex-shrink: 0;
  margin-left: 0.65rem;
  color: var(--color-accent, #0ea5e9);
  opacity: 0.7;
}

.dash-project__urlField {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  padding: 0.5rem 0.6rem;
  font-size: 0.82rem;
  font-family: inherit;
  color: inherit;
}
.dash-project__urlField::placeholder { color: #aaa; }

.dash-project__urlConfirm {
  padding: 0.5rem 0.8rem;
  border: none;
  border-left: 1px solid rgba(0,0,0,0.08);
  border-radius: 0;
  background: var(--color-accent, #0ea5e9);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: opacity 0.15s;
  white-space: nowrap;
}
.dash-project__urlConfirm:hover { opacity: 0.88; }

.dash-project__urlCancel {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border: none;
  background: transparent;
  color: var(--dash-muted, #a1a1aa);
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}
.dash-project__urlCancel:hover {
  background: rgba(0,0,0,0.04);
  color: #1e293b;
}

/* Dark mode — sources */
[data-color-scheme="dark"] .dash-project__sourceCard {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.08);
}
[data-color-scheme="dark"] .dash-project__sourceCard:hover {
  background: rgba(255,255,255,0.1);
}
[data-color-scheme="dark"] .dash-project__sourceCard__name { color: #e2e8f0; }
[data-color-scheme="dark"] .dash-project__sourceCard__icon {
  background: rgba(14,165,233,0.18);
  color: #38bdf8;
}
[data-color-scheme="dark"] .dash-project__urlIconBtn {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.12);
}
[data-color-scheme="dark"] .dash-project__urlIconBtn:hover,
[data-color-scheme="dark"] .dash-project__urlIconBtn.is-active {
  background: rgba(14,165,233,0.18);
  border-color: #38bdf8;
}
[data-color-scheme="dark"] .dash-project__addUrlInput {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.1);
}
[data-color-scheme="dark"] .dash-project__dropzoneTitle { color: #e2e8f0; }

/* Chat cards */
.dash-project__chats {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dash-project__chatCard {
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.08);
  background: #fff;
  box-shadow: var(--dash-shadow);
  overflow: hidden;
  transition: box-shadow 0.15s;
}
.dash-project__chatCard:hover {
  box-shadow: var(--dash-shadow-card);
}

.dash-project__chatCardHeader {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 0.75rem;
  cursor: pointer;
  user-select: none;
}
.dash-project__chatCardHeader:hover {
  background: rgba(0,0,0,0.02);
}

.dash-project__chatCardChevron {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  transition: transform 0.2s;
  color: var(--dash-muted, #a1a1aa);
}
.dash-project__chatCard.is-expanded .dash-project__chatCardChevron {
  transform: rotate(90deg);
}

.dash-project__chatCardTitle {
  flex: 1;
  font-size: 0.85rem;
  font-weight: 500;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-project__chatCardBody {
  display: none;
  padding: 0 0.75rem 0.75rem;
  font-size: 0.84rem;
  line-height: 1.6;
  color: #374151;
  max-height: 300px;
  overflow-y: auto;
}
.dash-project__chatCard.is-expanded .dash-project__chatCardBody {
  display: block;
}
.dash-project__chatCardBody p { margin: 0 0 0.5em; }
.dash-project__chatCardBody h1,
.dash-project__chatCardBody h2,
.dash-project__chatCardBody h3,
.dash-project__chatCardBody h4 { margin: 0.8em 0 0.3em; font-size: 0.92rem; }
.dash-project__chatCardBody ul,
.dash-project__chatCardBody ol { margin: 0.3em 0; padding-left: 1.4em; }
.dash-project__chatCardBody code {
  font-size: 0.82em;
  background: #f4f4f5;
  padding: 1px 4px;
  border-radius: 3px;
}

/* Grid cards */
.dash-project__grids {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dash-project__gridCard {
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.08);
  background: #fff;
  box-shadow: var(--dash-shadow);
  overflow: hidden;
  transition: box-shadow 0.15s;
}
.dash-project__gridCard:hover {
  box-shadow: var(--dash-shadow-card);
}

.dash-project__gridCardHeader {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 0.75rem;
  cursor: pointer;
  user-select: none;
}
.dash-project__gridCardHeader:hover {
  background: rgba(0,0,0,0.02);
}

.dash-project__gridCardChevron {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  transition: transform 0.2s;
  color: var(--dash-muted, #a1a1aa);
}
.dash-project__gridCard.is-expanded .dash-project__gridCardChevron {
  transform: rotate(90deg);
}

.dash-project__gridCardTitle {
  flex: 1;
  font-size: 0.85rem;
  font-weight: 500;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-project__gridCardBody {
  display: none;
  padding: 0 0.75rem 0.75rem;
  overflow-x: auto;
}
.dash-project__gridCard.is-expanded .dash-project__gridCardBody {
  display: block;
}

.dash-project__gridTable {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}
.dash-project__gridTable th {
  text-align: left;
  padding: 0.35rem 0.5rem;
  font-weight: 600;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  border-bottom: 2px solid rgba(0,0,0,0.08);
  color: var(--dash-muted, #a1a1aa);
  white-space: nowrap;
}
.dash-project__gridTable td {
  padding: 0.35rem 0.5rem;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  vertical-align: top;
  line-height: 1.45;
}

/* Project chatbox */
.dash-project__chatbox {
  flex-shrink: 0;
  border-top: var(--dash-border);
  display: flex;
  flex-direction: column;
  max-height: 45%;
}

.dash-project__chatMessages {
  flex: 1;
  overflow-y: auto;
  padding: 0.75rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 0;
}
.dash-project__chatMessages:empty {
  display: none;
}
.dash-project__chatMessages:not(:empty) + .dash-project__chatInputWrap {
  border-top: 1px solid rgba(0,0,0,0.06);
}

.dash-project__chatBubble {
  max-width: 85%;
  font-size: 0.84rem;
  line-height: 1.55;
  padding: 0.5rem 0.75rem;
  border-radius: 12px;
  word-wrap: break-word;
}
.dash-project__chatBubble--user {
  align-self: flex-end;
  background: var(--color-accent, #0ea5e9);
  color: #fff;
  border-bottom-right-radius: 4px;
}
.dash-project__chatBubble--assistant {
  align-self: flex-start;
  background: #f4f4f5;
  color: #1f2937;
  border-bottom-left-radius: 4px;
}
.dash-project__chatBubble--assistant p { margin: 0 0 0.4em; }
.dash-project__chatBubble--assistant p:last-child { margin-bottom: 0; }
.dash-project__chatBubble--assistant h1,
.dash-project__chatBubble--assistant h2,
.dash-project__chatBubble--assistant h3,
.dash-project__chatBubble--assistant h4 { margin: 0.5em 0 0.2em; font-size: 0.9rem; }
.dash-project__chatBubble--assistant ul,
.dash-project__chatBubble--assistant ol { margin: 0.2em 0; padding-left: 1.3em; }
.dash-project__chatBubble--assistant code {
  font-size: 0.82em;
  background: rgba(0,0,0,0.06);
  padding: 1px 4px;
  border-radius: 3px;
}

.dash-project__chatBubble--streaming::after {
  content: '\25CF';
  animation: dashProjectBlink 1s infinite;
  margin-left: 2px;
}
@keyframes dashProjectBlink {
  0%, 100% { opacity: 0.2; }
  50% { opacity: 1; }
}

.dash-project__chatInputWrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
}

.dash-project__chatInput {
  flex: 1;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  font-size: 0.875rem;
  font-family: inherit;
  background: #fff;
  outline: none;
  transition: border-color 0.15s;
}
.dash-project__chatInput:focus {
  border-color: var(--color-accent, #0ea5e9);
}
.dash-project__chatInput::placeholder {
  color: #aaa;
}

.dash-project__chatSend {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--dash-muted, #a1a1aa);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}
.dash-project__chatSend:hover {
  background: var(--color-accent, #0ea5e9);
  color: #fff;
}
.dash-project__chatSend svg { display: block; }

/* Empty state for project sections */
.dash-project__empty {
  font-size: 0.82rem;
  color: var(--dash-muted, #a1a1aa);
  font-style: italic;
  padding: 0.75rem 0;
  margin: 0;
}

/* Dark mode overrides */
[data-color-scheme="dark"] .dash-project__entityCard,
[data-color-scheme="dark"] .dash-project__chatCard,
[data-color-scheme="dark"] .dash-project__gridCard {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.08);
}
[data-color-scheme="dark"] .dash-project__chatCardBody {
  color: #d1d5db;
}
[data-color-scheme="dark"] .dash-project__chatBubble--assistant {
  background: rgba(255,255,255,0.08);
  color: #e5e7eb;
}
[data-color-scheme="dark"] .dash-project__chatInput {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.1);
  color: inherit;
}
[data-color-scheme="dark"] .dash-project__entityIcon--company { background: rgba(37,99,235,0.15); }
[data-color-scheme="dark"] .dash-project__entityIcon--drug { background: rgba(124,58,237,0.15); }
[data-color-scheme="dark"] .dash-project__entityIcon--condition { background: rgba(217,119,6,0.15); }
[data-color-scheme="dark"] .dash-project__entityIcon--target { background: rgba(13,148,136,0.15); }
[data-color-scheme="dark"] .dash-project__entityType--company { background: rgba(37,99,235,0.2); color: #93c5fd; }
[data-color-scheme="dark"] .dash-project__entityType--drug { background: rgba(124,58,237,0.2); color: #c4b5fd; }
[data-color-scheme="dark"] .dash-project__entityType--condition { background: rgba(217,119,6,0.2); color: #fcd34d; }
[data-color-scheme="dark"] .dash-project__entityType--target { background: rgba(13,148,136,0.2); color: #5eead4; }


/* ── Endpoint cards (knowledge box) ───────────────────────────────────────── */
.dash-knowledgeBox__endpointCard { display:flex; flex-direction:column; gap:0.3rem; padding:0.6rem 0.75rem; background:#f8fafc; border:1px solid #e2e8f0; border-radius:0.5rem; margin-bottom:0.5rem; }
.dash-knowledgeBox__endpointMet--true  { color:#15803d; font-weight:700; font-size:0.82rem; }
.dash-knowledgeBox__endpointMet--false { color:#b91c1c; font-weight:700; font-size:0.82rem; }
.dash-knowledgeBox__endpointMet--null  { color:#94a3b8; font-size:0.82rem; }
.dash-knowledgeBox__endpointMetric { font-size:0.82rem; color:#0f172a; font-weight:500; }
.dash-knowledgeBox__endpointResult { font-size:0.78rem; color:#475569; }
[data-color-scheme="dark"] .dash-knowledgeBox__endpointCard { background:rgba(255,255,255,0.04); border-color:rgba(255,255,255,0.08); }
[data-color-scheme="dark"] .dash-knowledgeBox__endpointMetric { color:#e2e8f0; }
[data-color-scheme="dark"] .dash-knowledgeBox__endpointResult { color:#94a3b8; }

/* ── Competition View analytics dashboard ───────────────────────────────── */
.dash-compView { position:fixed; left:var(--dash-sidebar-width); top:0; right:0; bottom:0; z-index:5; background:#fff; display:flex; flex-direction:column; gap:1.25rem; padding:1.5rem 1.75rem; overflow-y:auto; }
.dash--collapsed .dash-compView { left:var(--dash-sidebar-collapsed); }
.dash-compView__header { display:flex; align-items:flex-start; justify-content:space-between; gap:1rem; flex-wrap:wrap; }
.dash-compView__title { font-size:1.15rem; font-weight:700; color:#0f172a; margin:0 0 0.2rem; }
.dash-compView__subtitle { font-size:0.82rem; color:#64748b; margin:0; }
.dash-compView__saveBtn { flex-shrink:0; padding:0.45rem 1rem; background:#6366f1; color:#fff; font-size:0.8rem; font-weight:600; border:none; border-radius:0.5rem; cursor:pointer; transition:background 0.15s; }
.dash-compView__saveBtn:hover { background:#4f46e5; }

/* Criteria bar */
.dash-compView__criteriaBar { display:flex; flex-wrap:wrap; align-items:center; gap:0.5rem; padding:0.75rem 1rem; background:#f8fafc; border:1px solid #e2e8f0; border-radius:0.75rem; }
.dash-compView__criteriaLabel { font-size:0.75rem; font-weight:600; color:#94a3b8; text-transform:uppercase; letter-spacing:0.04em; margin-right:0.25rem; }
.dash-compView__criteriaGroup { display:flex; gap:0.3rem; flex-wrap:wrap; }
.dash-compView__criteriaDivider { width:1px; height:1.25rem; background:#e2e8f0; align-self:center; }
.dash-compView__criteriaPill { padding:0.3rem 0.75rem; font-size:0.78rem; font-weight:500; color:#475569; background:#fff; border:1px solid #e2e8f0; border-radius:999px; cursor:pointer; transition:all 0.12s; }
.dash-compView__criteriaPill:hover { border-color:#6366f1; color:#6366f1; }
.dash-compView__criteriaPill.is-active { background:#6366f1; color:#fff; border-color:#6366f1; }

/* Chart grid */
.dash-compView__grid { display:grid; grid-template-columns:repeat(2, 1fr); gap:1rem; }
.dash-compView__chartCard { background:#fff; border:1px solid #e2e8f0; border-radius:0.75rem; overflow:hidden; transition:box-shadow 0.15s; }
.dash-compView__chartCard:hover { box-shadow:0 4px 16px rgba(0,0,0,0.07); }
.dash-compView__chartCard--wide { grid-column:1 / -1; }
.dash-compView__chartTitle { padding:0.75rem 1rem 0.4rem; font-size:0.78rem; font-weight:600; color:#475569; text-transform:uppercase; letter-spacing:0.04em; border-bottom:1px solid #f1f5f9; }
.dash-compView__chartBody { padding:0.5rem 0.75rem 0.75rem; }
.dash-compView__chartBody svg { display:block; width:100%; height:220px; overflow:visible; }
.dash-compView__chartCard--wide .dash-compView__chartBody svg { height:280px; }

/* Dark mode */
[data-color-scheme="dark"] .dash-compView { background:#0f172a; }
[data-color-scheme="dark"] .dash-compView__title { color:#f1f5f9; }
[data-color-scheme="dark"] .dash-compView__subtitle { color:#94a3b8; }
[data-color-scheme="dark"] .dash-compView__criteriaBar { background:rgba(255,255,255,0.04); border-color:rgba(255,255,255,0.08); }
[data-color-scheme="dark"] .dash-compView__criteriaDivider { background:rgba(255,255,255,0.1); }
[data-color-scheme="dark"] .dash-compView__criteriaPill { background:rgba(255,255,255,0.06); border-color:rgba(255,255,255,0.1); color:#cbd5e1; }
[data-color-scheme="dark"] .dash-compView__criteriaPill:hover { border-color:#818cf8; color:#818cf8; }
[data-color-scheme="dark"] .dash-compView__criteriaPill.is-active { background:#6366f1; color:#fff; border-color:#6366f1; }
[data-color-scheme="dark"] .dash-compView__chartCard { background:rgba(255,255,255,0.04); border-color:rgba(255,255,255,0.08); }
[data-color-scheme="dark"] .dash-compView__chartCard:hover { box-shadow:0 4px 16px rgba(0,0,0,0.25); }
[data-color-scheme="dark"] .dash-compView__chartTitle { color:#94a3b8; border-bottom-color:rgba(255,255,255,0.06); }

/* ── Network tooltip ── */
.dash-networkTooltip {
  position: fixed;
  z-index: 9999;
  background: #1e293b;
  color: #f1f5f9;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 0.75rem;
  max-width: 240px;
  pointer-events: none;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}
.dash-networkTooltip.is-visible { opacity: 1; transform: translateY(0); }
.dash-networkTooltip__kind { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.05em; color: #94a3b8; margin-bottom: 3px; }
.dash-networkTooltip__label { font-weight: 600; color: #f8fafc; margin-bottom: 4px; }
.dash-networkTooltip__preview { color: #cbd5e1; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }

/* PDF / real network node cursor */
.pn-real { cursor: pointer; }

/* Dropzone active state (native file drag-over) */
.dash-project__dropzone--active { border-color: #ef4444 !important; background: #fff1f2 !important; }

/* Browse files button in dropzone */
.dash-project__uploadBtn { display: inline-flex; align-items: center; gap: 0.3rem; margin-top: 0.25rem; padding: 0.3rem 0.85rem; font-size: 0.78rem; font-weight: 500; color: #4f46e5; background: #ede9fe; border: 1px solid #c4b5fd; border-radius: 6px; cursor: pointer; transition: background 0.12s, border-color 0.12s; }
.dash-project__uploadBtn:hover { background: #ddd6fe; border-color: #a78bfa; }

/* PDF doc cards container */
.dash-project__docCards { display: flex; flex-direction: column; gap: 0.5rem; }
.dash-project__sourceCard__meta { font-size: 0.7rem; color: #94a3b8; }

/* Demo button (sidebar brand area) */
.dash-demo-btn { display: inline-flex; align-items: center; gap: 0.25rem; margin-left: 0.5rem; padding: 0.2rem 0.6rem; font-size: 0.65rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: #fff; background: var(--color-accent, #0ea5e9); border: none; border-radius: 10px; cursor: pointer; transition: background 0.15s, transform 0.1s; flex-shrink: 0; width: fit-content; }
.dash-demo-btn:hover { background: var(--color-accent-hover, #0284c7); transform: scale(1.04); }
.dash-demo-btn:active { transform: scale(0.97); }

/* ── Demo response cards ── */

/* Header */
.demo-header { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1rem; padding-bottom: 0.75rem; border-bottom: 1px solid rgba(0,0,0,0.08); }
.demo-header__logo { width: 48px; height: 48px; border-radius: 50%; border: 1px solid #e2e8f0; background: #f1f5f9; object-fit: cover; flex-shrink: 0; }
.demo-header__text { display: flex; flex-direction: column; gap: 0.15rem; flex: 1; min-width: 0; }
.demo-header__title { margin: 0; font-size: 1.1rem; font-weight: 700; color: #111; letter-spacing: -0.01em; }
.demo-header__meta { font-size: 0.72rem; color: #64748b; letter-spacing: 0.01em; }

/* Star + Enhance actions in company card headers */
.demo-header__actions { display: flex; align-items: center; gap: 0.35rem; flex-shrink: 0; }
.demo-header__starBtn {
  border: 0; background: transparent; width: 32px; height: 32px; border-radius: 50%;
  color: #94a3b8; cursor: pointer; display: flex; align-items: center; justify-content: center;
  padding: 0; transition: background 0.15s ease, color 0.15s ease;
}
.demo-header__starBtn:hover { background: #fef3c7; color: #f59e0b; }
.demo-header__starBtn.is-starred { color: #f59e0b; }
.demo-header__starBtn.is-starred svg { fill: currentColor; }
.demo-header__starBtn.is-starred:hover { background: #fef3c7; color: #d97706; }
.demo-header__enhanceWrap { position: relative; }
.demo-header__enhanceBtn {
  display: inline-flex; align-items: center; gap: 0.3rem; padding: 0.3rem 0.7rem;
  border: 1px solid #e2e8f0; border-radius: 999px; background: #f8fafc; color: #475569;
  font-size: 0.72rem; font-weight: 600; cursor: pointer; white-space: nowrap;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.demo-header__enhanceBtn:hover { background: #eef2ff; border-color: #a5b4fc; color: #4338ca; }
.demo-header__enhanceDropdown {
  position: absolute; top: calc(100% + 6px); right: 0; min-width: 200px;
  background: #fff; border: 1px solid #e2e8f0; border-radius: 0.65rem;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12); z-index: 50; padding: 0.35rem 0; overflow: hidden;
}
.demo-header__enhanceDropdown.is-hidden { display: none; }
.demo-header__enhanceRow {
  display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem 0.75rem;
  cursor: pointer; transition: background 0.12s ease; font-size: 0.8rem; color: #334155;
}
.demo-header__enhanceRow:hover { background: #f1f5f9; }
.demo-header__enhanceLogo { width: 20px; height: 20px; border-radius: 4px; flex-shrink: 0; object-fit: contain; }
.demo-header__enhanceLabel { flex: 1; font-weight: 600; font-size: 0.78rem; }
.demo-header__enhanceCoins { display: inline-flex; align-items: center; gap: 0.25rem; font-size: 0.72rem; font-weight: 600; color: #92400e; white-space: nowrap; }
.demo-header__coinIcon { flex-shrink: 0; }

/* Verdict / investment summary */
.demo-section--verdict { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 8px; padding: 0.75rem 0.875rem; margin-bottom: 0.75rem; }
.demo-verdict { margin: 0; font-size: 0.85rem; line-height: 1.65; color: #334155; }

/* Expand pill */
.demo-expand-pill { display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.35rem 0.75rem 0.35rem 0.45rem; margin-bottom: 0.75rem; border: 1px solid #e2e8f0; border-radius: 999px; background: #fff; cursor: pointer; font-family: inherit; transition: border-color 0.2s, box-shadow 0.2s; }
.demo-expand-pill:hover { border-color: #cbd5e1; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.demo-expand-pill__logo { width: 20px; height: 20px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.demo-expand-pill__name { font-size: 0.78rem; font-weight: 600; color: #1e293b; white-space: nowrap; }
.demo-expand-pill__cta { font-size: 0.72rem; font-weight: 500; color: #6366f1; white-space: nowrap; display: inline-flex; align-items: center; gap: 0.15rem; margin-left: 0.25rem; }
.demo-expand-pill__chevron { transition: transform 0.25s ease; }
.demo-expand-pill--open .demo-expand-pill__chevron { transform: rotate(180deg); }

/* Entity pills container */
.demo-entity-pills { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 0.75rem; }
.demo-entity-pills .demo-expand-pill { margin-bottom: 0; }

/* Entity pill badge */
.demo-expand-pill__badge { font-size: 0.6rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; padding: 0.1rem 0.4rem; border-radius: 4px; white-space: nowrap; line-height: 1.4; }
.demo-expand-pill__badge--mechanism { background: #ede9fe; color: #7c3aed; }
.demo-expand-pill__badge--target { background: #e0f2fe; color: #0284c7; }
.demo-expand-pill__badge--modality { background: #fce7f3; color: #be185d; }
.demo-expand-pill__flag { font-size: 1.1em; line-height: 1; flex-shrink: 0; }

/* Entity detail collapse sections */
.demo-entity-detail__inner { padding: 1rem 1.25rem; background: #fafbfc; border: 1px solid #e2e8f0; border-radius: 12px; margin-bottom: 0.5rem; }
.demo-entity-detail__title { margin: 0 0 0.75rem; font-size: 1rem; font-weight: 700; color: #1e293b; display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.demo-entity-detail__badge { font-size: 0.6rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; padding: 0.15rem 0.45rem; border-radius: 4px; }
.demo-entity-detail__badge--mechanism { background: #ede9fe; color: #7c3aed; }
.demo-entity-detail__badge--target { background: #e0f2fe; color: #0284c7; }
.demo-entity-detail__badge--modality { background: #fce7f3; color: #be185d; }
.demo-entity-detail__subtitle { margin: 0.75rem 0 0.35rem; font-size: 0.82rem; font-weight: 600; color: #475569; }
.demo-entity-detail__text { margin: 0 0 0.25rem; font-size: 0.85rem; line-height: 1.6; color: #334155; }
.demo-entity-detail__list { margin: 0 0 0.25rem; padding-left: 1.25rem; font-size: 0.85rem; line-height: 1.7; color: #334155; }
.demo-entity-detail__list li { margin-bottom: 0.15rem; }
.demo-entity-detail__chips { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-bottom: 0.25rem; }
.demo-entity-chip { display: inline-flex; align-items: center; padding: 0.2rem 0.55rem; border-radius: 999px; font-size: 0.75rem; font-weight: 500; background: #f1f5f9; color: #475569; border: 1px solid #e2e8f0; }
.demo-entity-chip[data-kb-label] { cursor: pointer; transition: background 0.15s, border-color 0.15s; }
.demo-entity-chip[data-kb-label]:hover { background: #e0f2fe; border-color: #7dd3fc; color: #0369a1; }

/* Collapsible detail wrapper */
.demo-detail-collapse { max-height: 0; overflow: hidden; opacity: 0; transition: max-height 0.4s ease, opacity 0.3s ease; }
.demo-detail-collapse--open { max-height: 5000px; opacity: 1; }

/* Sections */
.demo-section { margin-bottom: 1rem; }
.demo-section__title { display: flex; align-items: center; gap: 0.4rem; margin: 0 0 0.5rem; font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: #6b7280; }
.demo-section__icon { flex-shrink: 0; color: #94a3b8; }

/* Collapsible section toggle */
.demo-section__toggle { cursor: pointer; user-select: none; }
.demo-section__toggle:hover { color: #374151; }
/* Graph button next to section headers */
.demo-section__graphBtn { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; margin-left: auto; margin-right: 2px; padding: 0; border: 1px solid rgba(99,102,241,0.18); border-radius: 6px; background: rgba(99,102,241,0.07); color: #6366f1; cursor: pointer; flex-shrink: 0; transition: background 0.15s, border-color 0.15s, color 0.15s; }
.demo-section__graphBtn:hover { background: rgba(99,102,241,0.18); border-color: #6366f1; color: #4f46e5; }
.demo-section__graphBtn svg { pointer-events: none; }

.demo-section__chevron { flex-shrink: 0; color: #94a3b8; transition: transform 0.25s ease; }
.demo-section--collapsible .demo-section__body--open ~ .demo-section__toggle .demo-section__chevron,
.demo-section__toggle.demo-section__toggle--open .demo-section__chevron { transform: rotate(180deg); }
.demo-section__body { max-height: 0; overflow: hidden; opacity: 0; transition: max-height 0.35s ease, opacity 0.25s ease; }
.demo-section__body--open { max-height: 3000px; overflow: visible; opacity: 1; }

/* Nested condition cards within Assets */
.demo-asset-conditions { margin: 0 0 0.5rem 1.25rem; padding-left: 0.75rem; border-left: 2px solid #e2e8f0; display: flex; flex-direction: column; gap: 0.25rem; }
.demo-card--nested { padding: 0.3rem 0.5rem; font-size: 0.82rem; background: #f8fafc; border-color: #f1f5f9; }
.demo-card--nested .demo-card__name { font-size: 0.78rem; }
.demo-card--nested .demo-card__sub { font-size: 0.7rem; }

/* Card grid */
.demo-cards { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.demo-cards--leadership { gap: 0.35rem; }

/* Individual card — watchlist-row style */
.demo-card { display: flex; align-items: flex-start; gap: 0.5rem; padding: 0.5rem 0.65rem; border: 1px solid rgba(0,0,0,0.07); border-radius: 8px; background: #fff; transition: background 0.12s, border-color 0.12s, box-shadow 0.12s; min-width: 0; flex: 1 1 calc(50% - 0.2rem); cursor: pointer; }
.demo-card:hover { background: #f8fafc; border-color: #94a3b8; box-shadow: 0 2px 8px rgba(0,0,0,0.05); }

/* Card icon circles — category-colored like watchlist */
.demo-card__icon { display: flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0; margin-top: 1px; }
.demo-card__icon--condition { background: #fef3c7; color: #d97706; }
.demo-card__icon--bladder { background: #fef9c3; color: #ca8a04; }
.demo-card__icon--pancreas { background: #ecfccb; color: #65a30d; }
.demo-card__icon--breast { background: #fce7f3; color: #db2777; }
.demo-card__icon--tumor { background: #f1f5f9; color: #475569; }
.demo-card__icon--target { background: #ccfbf1; color: #0d9488; }
.demo-card__icon--mechanism { background: #dbeafe; color: #2563eb; }
.demo-card__icon--modality { background: #ede9fe; color: #7c3aed; }
.demo-card__icon--asset { background: #ecfeff; color: #0e7490; }

/* Card body */
.demo-card__body { display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.demo-card__name { font-size: 0.8rem; font-weight: 600; color: #111; line-height: 1.3; }
.demo-card__sub { font-size: 0.7rem; color: #64748b; line-height: 1.4; }

/* Lead indication shimmer badge */
.demo-lead-badge {
  display: inline-block;
  padding: 1px 7px;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #1d4ed8;
  background: linear-gradient(135deg, #dbeafe 0%, #eff6ff 50%, #dbeafe 100%);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 4px;
  position: relative;
  overflow: hidden;
}
.demo-lead-badge::after {
  content: '';
  position: absolute;
  top: 0; left: -100%; width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent 0%, rgba(59, 130, 246, 0.18) 40%, rgba(255, 255, 255, 0.35) 50%, rgba(59, 130, 246, 0.18) 60%, transparent 100%);
  animation: lead-shimmer 3s ease-in-out infinite;
}
@keyframes lead-shimmer {
  0%   { left: -100%; }
  50%  { left: 100%; }
  100% { left: 100%; }
}

/* Stage tags on asset cards */
.demo-card__tag { display: inline-flex; align-self: flex-start; padding: 1px 6px; font-size: 0.575rem; font-weight: 600; letter-spacing: 0.02em; text-transform: uppercase; border-radius: 3px; white-space: nowrap; margin-top: 0.15rem; }
.demo-card__tag--stage { background: #fce7f3; color: #be185d; }
.demo-card__tag--pre { background: #fef3c7; color: #92400e; }

/* Phase progress bars (replaces phase tag badges on demo cards) */
.demo-phase-bar { display:inline-flex; align-items:center; align-self:flex-start; width:64px; height:13px; background:#e2e8f0; border-radius:6px; overflow:hidden; margin-top:0.15rem; position:relative; }
.demo-phase-bar__fill { height:100%; border-radius:6px; display:flex; align-items:center; justify-content:center; min-width:16px; }
.demo-phase-bar__label { font-size:0.5rem; font-weight:700; color:#fff; line-height:1; white-space:nowrap; letter-spacing:0.02em; }
.demo-phase-bar--p1 .demo-phase-bar__fill   { width:33%; background:#60a5fa; }
.demo-phase-bar--p1h .demo-phase-bar__fill  { width:50%; background:#60a5fa; }
.demo-phase-bar--p2 .demo-phase-bar__fill   { width:67%; background:#60a5fa; }
.demo-phase-bar--p2h .demo-phase-bar__fill  { width:83%; background:#60a5fa; }
.demo-phase-bar--p3 .demo-phase-bar__fill   { width:95%; background:#60a5fa; }
.demo-phase-bar--approved .demo-phase-bar__fill { width:100%; background:#16a34a; }

/* Leadership avatar circles */
.demo-card__avatar { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: #0f172a; color: #fff; font-size: 0.6rem; font-weight: 700; letter-spacing: 0.02em; flex-shrink: 0; margin-top: 1px; }
.demo-card--leader { flex: 1 1 calc(50% - 0.2rem); }

/* Vertical layout for Key People cards */
.demo-cards--vertical { flex-direction: column; }
.demo-cards--vertical .demo-card--leader { flex: 0 0 auto; }

/* "more…" scroll link */
.demo-more-link { display: inline-block; margin-top: 0.2rem; font-size: 0.78rem; color: #6b7280; cursor: pointer; transition: color 0.15s; }
.demo-more-link:hover { color: #1e293b; }

/* ── Assets: Cards/Pipeline view toggle ── */
.demo-assets-view-toggle {
  display: inline-flex;
  margin-left: auto;
  border: 1px solid #e2e8f0;
  border-radius: 5px;
  overflow: hidden;
  flex-shrink: 0;
}
.demo-assets-view-btn {
  appearance: none;
  border: none;
  background: #f8fafc;
  padding: 2px 9px;
  font-size: 0.55rem;
  font-weight: 600;
  color: #94a3b8;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1.6;
  transition: background 0.15s, color 0.15s;
}
.demo-assets-view-btn:hover { background: #f1f5f9; color: #64748b; }
.demo-assets-view-btn--active { background: #0f172a; color: #fff; }
.demo-assets-view-btn--active:hover { background: #1e293b; color: #fff; }
.demo-assets-view-btn + .demo-assets-view-btn { border-left: 1px solid #e2e8f0; }

/* ── Assets: Pipeline view ── */
.demo-pipeline-view {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.demo-pipeline-phases {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 0.75rem;
  padding: 0.5rem 0.65rem;
  background: #f8fafc;
  border-radius: 0.5rem 0.5rem 0 0;
  border-bottom: 1px solid #e2e8f0;
}
.demo-pipeline-phases__cols {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.25rem;
}
.demo-pipeline-phases__cols span {
  text-align: center;
  font-size: 0.55rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #94a3b8;
}

.demo-pipeline-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 0.75rem;
  padding: 0.6rem 0.65rem;
  border-bottom: 1px solid rgba(226, 232, 240, 0.6);
  cursor: pointer;
  transition: background 0.15s;
}
.demo-pipeline-row:hover { background: #f8fafc; }
.demo-pipeline-row:last-child { border-bottom: none; border-radius: 0 0 0.5rem 0.5rem; }

.demo-pipeline-row__info {
  display: flex;
  flex-direction: column;
  gap: 0;
  min-width: 0;
}
.demo-pipeline-row__name {
  font-size: 0.78rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.demo-pipeline-row__sub {
  font-size: 0.6rem;
  color: #64748b;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.demo-pipeline-row__mech {
  font-size: 0.55rem;
  color: #94a3b8;
  line-height: 1.3;
  margin-top: 1px;
}

.demo-pipeline-row__track-wrap {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.2rem;
}
.demo-pipeline-row__track {
  height: 7px;
  border-radius: 999px;
  background: #f1f5f9;
  overflow: hidden;
}
.demo-pipeline-row__fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(14, 116, 144, 0.2), #0e7490);
  transition: width 0.6s ease;
}
.demo-pipeline-row__fill--lead {
  background: linear-gradient(90deg, rgba(29, 78, 216, 0.2), #1d4ed8);
}
.demo-pipeline-row__fill--pre {
  background: linear-gradient(90deg, rgba(146, 64, 14, 0.2), #92400e);
}

.demo-pipeline-row__stage {
  display: flex;
  justify-content: flex-end;
}
.demo-pipeline-row__badge {
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 1px 6px;
  border-radius: 3px;
  background: rgba(14, 116, 144, 0.1);
  color: #0e7490;
}
.demo-pipeline-row__badge--lead {
  background: rgba(29, 78, 216, 0.1);
  color: #1d4ed8;
}
.demo-pipeline-row__badge--pre {
  background: #fef3c7;
  color: #92400e;
}

.demo-pipeline-row__indications {
  font-size: 0.55rem;
  color: #94a3b8;
  line-height: 1.3;
}

/* Pipeline view responsive */
@media (max-width: 600px) {
  .demo-pipeline-phases,
  .demo-pipeline-row {
    grid-template-columns: 1fr;
    gap: 0.3rem;
  }
  .demo-pipeline-phases__cols { display: none; }
  .demo-pipeline-row__info { flex-direction: row; align-items: baseline; gap: 0.4rem; flex-wrap: wrap; }
}

/* Investor cards */
.demo-cards--investors { gap: 0.35rem; }
.demo-cards--investors .demo-card--investor { flex: 0 0 auto; }
.demo-card--investor-hidden { display: none; }
.demo-card__logo { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 6px; background: #f1f5f9; flex-shrink: 0; overflow: hidden; margin-top: 1px; }
.demo-card__logo img { width: 24px; height: 24px; object-fit: contain; border-radius: 3px; }
.demo-card__logo-fallback { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 6px; background: #0f172a; color: #fff; font-size: 0.6rem; font-weight: 700; letter-spacing: 0.02em; }

/* ── Company Timeline ── */
.demo-timeline { position: relative; padding: 0 0 0 1.5rem; }
.demo-timeline::before { content: ''; position: absolute; left: 5px; top: 6px; bottom: 6px; width: 1.5px; background: linear-gradient(to bottom, #cbd5e1, #e2e8f0); }
.demo-timeline__item { position: relative; padding-bottom: 1.15rem; }
.demo-timeline__item--last { padding-bottom: 0; }
.demo-timeline__dot { position: absolute; left: -1.5rem; top: 3px; width: 11px; height: 11px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1.5px #cbd5e1; z-index: 1; }
.demo-timeline__dot--founding { background: #0f172a; box-shadow: 0 0 0 1.5px #0f172a; }
.demo-timeline__dot--milestone { background: #2563eb; box-shadow: 0 0 0 1.5px #2563eb; }
.demo-timeline__dot--partnership { background: #7c3aed; box-shadow: 0 0 0 1.5px #7c3aed; }
.demo-timeline__dot--clinical { background: #0d9488; box-shadow: 0 0 0 1.5px #0d9488; }
.demo-timeline__dot--financing { background: #d97706; box-shadow: 0 0 0 1.5px #d97706; }
.demo-timeline__dot--current { background: #dc2626; box-shadow: 0 0 0 1.5px #dc2626; }
.demo-timeline__content { display: flex; flex-direction: column; gap: 0.1rem; }
.demo-timeline__date { font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: #94a3b8; line-height: 1.2; }
.demo-timeline__title { font-size: 0.82rem; font-weight: 650; color: #111827; line-height: 1.35; }
.demo-timeline__desc { font-size: 0.74rem; color: #4b5563; line-height: 1.55; margin-top: 0.05rem; }
.demo-timeline__desc a { color: #2563eb; text-decoration: none; font-weight: 500; }
.demo-timeline__desc a:hover { text-decoration: underline; }

/* Key-value rows (company info / financials) */
.demo-kv { display: flex; gap: 0.5rem; padding: 0.3rem 0; border-bottom: 1px solid rgba(0,0,0,0.05); font-size: 0.82rem; line-height: 1.5; }
.demo-kv:last-child { border-bottom: none; }
.demo-kv__label { flex-shrink: 0; width: 120px; font-weight: 600; color: #374151; font-size: 0.78rem; }
.demo-kv__value { color: #4b5563; }

/* Publication rows */
.demo-pubs { display: flex; flex-direction: column; gap: 0.35rem; }
.demo-pub { display: flex; flex-direction: row; align-items: flex-start; gap: 0.5rem; padding: 0.4rem 0.6rem; border: 1px solid rgba(0,0,0,0.06); border-radius: 6px; background: #fafafa; }
.demo-pub__icon { flex-shrink: 0; display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 5px; background: rgba(124,58,237,0.08); margin-top: 0.1rem; }
.demo-pub__body { display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.demo-pub__journal { font-size: 0.65rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: #7c3aed; }
.demo-pub__title { font-size: 0.8rem; color: #334155; line-height: 1.45; }
a.demo-pub--link { text-decoration: none; cursor: pointer; transition: border-color 0.15s, background 0.15s; }
a.demo-pub--link:hover { border-color: rgba(124,58,237,0.25); background: rgba(124,58,237,0.04); }

/* Built-in PDF reader — right-side slide-out panel */
.demo-pdf-overlay { position: fixed; inset: 0; z-index: 10000; background: rgba(0,0,0,0.35); opacity: 0; transition: opacity 0.25s; pointer-events: none; }
.demo-pdf-overlay.is-active { opacity: 1; pointer-events: auto; }
.demo-pdf-reader { position: fixed; top: 0; right: 0; z-index: 10001; width: 46vw; max-width: 720px; height: 100vh; background: #fff; box-shadow: -8px 0 30px rgba(0,0,0,0.25); display: flex; flex-direction: column; transform: translateX(100%); transition: transform 0.3s cubic-bezier(0.22,1,0.36,1); border-left: 1px solid rgba(0,0,0,0.08); }
.demo-pdf-overlay.is-active .demo-pdf-reader { transform: translateX(0); }
.demo-pdf-reader__bar { display: flex; align-items: center; gap: 0.75rem; padding: 0.55rem 0.85rem; background: #1e1b4b; color: #fff; font-size: 0.78rem; font-weight: 600; flex-shrink: 0; }
.demo-pdf-reader__bar span { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.demo-pdf-reader__tabs { display: flex; gap: 2px; margin-left: auto; flex-shrink: 0; }
.demo-pdf-reader__tab { padding: 0.25rem 0.65rem; font-size: 0.7rem; font-weight: 600; color: rgba(255,255,255,0.55); background: none; border: none; border-radius: 4px; cursor: pointer; transition: color 0.15s, background 0.15s; }
.demo-pdf-reader__tab:hover { color: #fff; background: rgba(255,255,255,0.1); }
.demo-pdf-reader__tab.is-active { color: #fff; background: rgba(255,255,255,0.18); }
.demo-pdf-reader__close { background: none; border: none; color: rgba(255,255,255,0.7); cursor: pointer; padding: 4px; border-radius: 4px; display: flex; align-items: center; justify-content: center; transition: color 0.15s, background 0.15s; flex-shrink: 0; }
.demo-pdf-reader__close:hover { color: #fff; background: rgba(255,255,255,0.15); }
.demo-pdf-reader iframe { flex: 1; border: none; width: 100%; height: 100%; }
@media (max-width: 900px) { .demo-pdf-reader { width: 80vw; max-width: none; } }
@media (max-width: 600px) { .demo-pdf-reader { width: 100vw; } }

/* ── Knowledge overlay (inline hover tooltips in verdict) ── */
.demo-knowledge-term {
  position: relative;
  color: #4f46e5;
  border-bottom: 1px dashed #a5b4fc;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
  font-weight: 600;
}
.demo-knowledge-term:hover {
  color: #3730a3;
  border-bottom-color: #6366f1;
}

/* Tooltip card — positioned by JS via .demo-knowledge-tip--above / --below */
.demo-knowledge-tip {
  position: absolute;
  left: 50%;
  width: 260px;
  padding: 0.65rem 0.75rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12), 0 2px 6px rgba(0,0,0,0.06);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.18s ease, visibility 0.18s ease;
  z-index: 800;
}
/* Above (default) */
.demo-knowledge-tip--above { bottom: calc(100% + 8px); top: auto; transform: translateX(-50%); }
/* Below (flipped) */
.demo-knowledge-tip--below { top: calc(100% + 8px); bottom: auto; transform: translateX(-50%); }

.demo-knowledge-term:hover .demo-knowledge-tip {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Arrow — above position (arrow points down) */
.demo-knowledge-tip--above::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #fff;
}
.demo-knowledge-tip--above::before {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 7px solid transparent;
  border-top-color: #e2e8f0;
}
/* Arrow — below position (arrow points up) */
.demo-knowledge-tip--below::after {
  content: '';
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-bottom-color: #fff;
}
.demo-knowledge-tip--below::before {
  content: '';
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 7px solid transparent;
  border-bottom-color: #e2e8f0;
}

/* Tooltip header */
.demo-knowledge-tip__label {
  display: inline-block;
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  background: #6366f1;
  padding: 1px 6px;
  border-radius: 3px;
  margin-bottom: 0.3rem;
}
.demo-knowledge-tip__name {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 0.25rem;
  line-height: 1.3;
}
.demo-knowledge-tip__desc {
  display: block;
  font-size: 0.72rem;
  color: #64748b;
  line-height: 1.5;
  margin-bottom: 0.4rem;
  font-weight: 400;
}
.demo-knowledge-tip__more {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.68rem;
  font-weight: 600;
  color: #6366f1;
  cursor: pointer;
  transition: color 0.15s;
}
.demo-knowledge-tip__more:hover {
  color: #4338ca;
}
.demo-knowledge-tip__more svg {
  flex-shrink: 0;
}

/* Responsive: stack cards on narrow chat */
@media (max-width: 640px) {
  .demo-card { flex: 1 1 100%; }
  .demo-card--leader { flex: 1 1 100%; }
  .demo-kv { flex-direction: column; gap: 0.1rem; }
  .demo-kv__label { width: auto; }
  .demo-knowledge-tip { width: 220px; }
}

/* ── Onyx Interviews toggle section (Demo 3 company cards) ── */
.demo-interviews { margin-top: 0.25rem; }
.demo-interviews__cards { display: flex; flex-direction: column; gap: 0.85rem; }

.demo-interviews__card {
  display: flex;
  flex-direction: row;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  background: #fff;
  border: 1px solid rgba(148,163,184,0.22);
}
.demo-interviews__card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(14,116,144,0.13);
}

.demo-interviews__img-wrap {
  width: 140px;
  min-height: 96px;
  flex-shrink: 0;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
}
.demo-interviews__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.demo-interviews__card:hover .demo-interviews__img { transform: scale(1.04); }

.demo-interviews__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 600;
  color: #94a3b8;
  letter-spacing: 0.03em;
}

.demo-interviews__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0.75rem 1rem;
  flex: 1;
  min-width: 0;
  gap: 0.3rem;
}
.demo-interviews__headline {
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.4;
  color: #1e293b;
  margin: 0;
}
.demo-interviews__excerpt {
  font-size: 0.74rem;
  line-height: 1.55;
  color: #64748b;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.demo-interviews__cta {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: #0369a1;
  transition: color 0.2s ease;
}
.demo-interviews__card:hover .demo-interviews__cta { color: #0284c7; }

.demo-interviews__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.68rem;
  font-weight: 600;
  color: #0e7490;
  background: rgba(14,116,144,0.08);
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  margin-bottom: 0.15rem;
  width: fit-content;
}
.demo-interviews__badge svg { flex-shrink: 0; }

@media (max-width: 640px) {
  .demo-interviews__img-wrap { width: 100px; min-height: 80px; }
  .demo-interviews__headline { font-size: 0.78rem; }
  .demo-interviews__excerpt { display: none; }
}

/* ══════════════════════════════════════════════════════════════════
   Demo 3 — View Charts
   ══════════════════════════════════════════════════════════════════ */
.demo3-charts-wrap { margin: 0.75rem 0; }

.demo3-charts-toggle {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.4rem 0.85rem; border: 1px solid #e2e8f0; border-radius: 999px;
  background: #fff; color: #6366f1; font-size: 0.78rem; font-weight: 600;
  font-family: inherit; cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.demo3-charts-toggle:hover { border-color: #6366f1; box-shadow: 0 1px 6px rgba(99,102,241,0.12); }
.demo3-charts-toggle__chevron { transition: transform 0.25s ease; }
.demo3-charts-toggle--open .demo3-charts-toggle__chevron { transform: rotate(180deg); }

.demo3-charts { margin-top: 0.75rem; }
.demo3-charts__grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem;
}
.demo3-charts__card {
  background: #fff; border: 1px solid #e2e8f0; border-radius: 0.75rem;
  overflow: hidden; transition: box-shadow 0.15s;
}
.demo3-charts__card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.07); }
.demo3-charts__card--wide { grid-column: 1 / -1; }

.demo3-charts__title {
  padding: 0.75rem 1rem 0.4rem; font-size: 0.78rem; font-weight: 600;
  color: #475569; text-transform: uppercase; letter-spacing: 0.04em;
  border-bottom: 1px solid #f1f5f9;
}
.demo3-charts__body { padding: 0.5rem 0.75rem 0.25rem; min-height: 100px; }
.demo3-charts__body svg { display: block; width: 100%; overflow: visible; }

.demo3-charts__source {
  padding: 0.25rem 1rem 0.5rem; font-size: 0.65rem; color: #94a3b8;
  line-height: 1.5; border-top: 1px solid #f8fafc;
}
.demo3-charts__source a { color: #6366f1; text-decoration: none; }
.demo3-charts__source a:hover { text-decoration: underline; }

/* Dark mode */
[data-color-scheme="dark"] .demo3-charts-toggle {
  background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.08); color: #818cf8;
}
[data-color-scheme="dark"] .demo3-charts__card {
  background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.08);
}
[data-color-scheme="dark"] .demo3-charts__card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.25); }
[data-color-scheme="dark"] .demo3-charts__title { color: #94a3b8; border-bottom-color: rgba(255,255,255,0.06); }
[data-color-scheme="dark"] .demo3-charts__source { color: #64748b; border-top-color: rgba(255,255,255,0.04); }

/* Mobile */
@media (max-width: 640px) {
  .demo3-charts__grid { grid-template-columns: 1fr; }
}
