@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap");
/* Embedded scientific tools share the host page's Cavall light palette. */
:root {
  /* Fluid type unit, as on the host site (static/css/refinement.css). static/js/explore.js
     sets it to the host page's exact value when these apps are embedded there. */
  --u: clamp(1px, calc(0.36px + 0.05vw), 1.4px);
  --ink: #203b60;
  --accent: #152d50;
}
html { font-size: calc(16 * var(--u)); }
body {
  margin: 0;
  padding: 20px 0;
  font-family: "Plus Jakarta Sans", Arial, Helvetica, sans-serif;
  color: var(--ink);
  background: #ffffff;
}
.Select-control, .Select-menu-outer { background: #f1f6ff; border-color: #cbd8eb; border-radius: 4px; }
.Select-value-label { color: #203b60 !important; }
.Select-placeholder { color: #526581; }
/* Minimal range slider: thin rail, ink track, small ring handles. */
#bdfe-range-slider-container { padding: 0 7px; }
/* drop Dash's built-in 25px side padding so handle ends line up with the plot axis */
#bdfe-range-slider { padding: 0 0 calc(26 * var(--u)) !important; }
.dataset-workspace .Select, .dataset-workspace .Select * { font-family: "Plus Jakarta Sans", Arial, sans-serif !important; }
.dataset-workspace .Select-value-label { font-size: calc(15 * var(--u)); font-weight: 500; }
.rc-slider-rail { background-color: #e1e6ed; height: 3px; }
.rc-slider-track { background-color: var(--accent); height: 3px; }
.rc-slider-handle { width: 14px; height: 14px; margin-top: -5.5px; border: 2px solid #152d50; background: #ffffff; opacity: 1; box-shadow: none; }
.rc-slider-handle:hover, .rc-slider-handle:focus-visible, .rc-slider-handle-dragging.rc-slider-handle-dragging.rc-slider-handle-dragging { border-color: #152d50; box-shadow: 0 0 0 5px rgba(53, 93, 160, .14); }
.rc-slider-dot { display: none; }
.rc-slider-mark-text { color: #52617b; font-size: calc(12 * var(--u)); }
.rc-slider-tooltip-inner { min-width: 0; height: auto; padding: 3px 7px; border-radius: 4px; background: #152d50; box-shadow: none; font: 600 calc(12 * var(--u))/1.4 "Plus Jakarta Sans", Arial, sans-serif; font-variant-numeric: tabular-nums; }
.rc-slider-tooltip-placement-bottom .rc-slider-tooltip-arrow { border-bottom-color: #152d50; }
/* Section labels and hints, echoing the site's eyebrow style. */
.dataset-workspace p.dataset-section-label { margin: 0 0 12px; font-size: calc(11 * var(--u)) !important; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: #49658b; }
.dataset-workspace .dataset-hint { margin-top: 6px; font-size: calc(13 * var(--u)) !important; color: #52617b; }
.js-plotly-plot .plotly .modebar { background: transparent !important; }
button { font-family: inherit; }
/* Stack the distributions and filtering controls above the molecular map. */
.dataset-workspace { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
/* 634px = the map's 620px square plus the 7px slider/KDE inset on each side, so the
   KDE axis and slider line up with the map frame */
.dataset-selector, .dataset-distributions { justify-self: center; max-width: 634px; }
.dataset-selector { grid-column: 1 / -1; margin: 0 !important; }
.dataset-selector > p:first-child { font-size: calc(13 * var(--u)); letter-spacing: .02em; margin-top: 0; }
.dataset-distributions { min-width: 0; width: 100%; padding: 0; background: transparent; border: 0; border-radius: 0; }
.dataset-distributions p { font-size: calc(14 * var(--u)) !important; line-height: 1.6; }
.dataset-map { border-top: 2px solid #313e4d; padding-top: 18px; }@media(max-width: 950px) {
  .dataset-workspace { grid-template-columns: minmax(0, 1fr); }
  .dataset-distributions { max-width: none; }
  .dataset-map { width: 100%; }
}
* { box-sizing: border-box; }
.dataset-distributions .dash-graph { width: 100%; }

@media(max-width: 950px) { .dataset-distributions { padding: 0; border: 0; } }
.molecule-map-title { text-align: center; margin: 4px 0 8px; font-size: calc(18 * var(--u)); }
.molecule-map-info { text-align: center; font-size: calc(13 * var(--u)); margin: 0 0 14px; }
.molecule-map-tools { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; color: #627088; font-size: calc(12 * var(--u)); }
.molecule-map-tools button { background: white; border: 1px solid #ccd5e2; border-radius: 4px; padding: 7px 10px; color: #284b80; cursor: pointer; }
.molecule-map-stage { position: relative; height: 660px; overflow: hidden; margin-top: 8px; }
.molecule-map-canvas,.molecule-map-axes { position: absolute; inset: 0; width: 100%; height: 100%; }
.molecule-map-canvas { touch-action: none; cursor: grab; }
.molecule-map-canvas:active { cursor: grabbing; }
.molecule-map-axes { pointer-events: none; }
.molecule-map-tip { position: absolute; width: 210px; padding: 12px; background: white; border: 1px solid #ccd5e2; border-radius: 5px; box-shadow: 0 6px 24px #182e5120; z-index: 3; pointer-events: none; font-size: calc(13 * var(--u)); overflow-wrap: anywhere; }
.molecule-map-tip img { width: 100%; height: 130px; object-fit: contain; }
.molecule-map-tip p { margin: 7px 0 0; max-height: 42px; overflow: hidden; }
.molecule-map-legend { text-align: center; font-size: calc(12 * var(--u)); color: #52617b; margin: 14px 0; white-space: pre; font-variant-numeric: tabular-nums; }
.molecule-map-legend::before { content: ''; display: block; width: 220px; height: 6px; border-radius: 3px; background: var(--molecule-map-gradient); margin: 0 auto 8px; }

/* Landing embed uses the same data, renderer, hover, and navigation as Explore. */
.map-embed, .map-embed body { margin: 0; padding: 0; overflow: hidden; }
.map-embed .dataset-selector, .map-embed .dataset-distributions { display: none; }
.map-embed .dataset-workspace { gap: 0; }
.map-embed .dataset-map { border: 0; padding: 0; }
.map-embed .molecule-map-title, .map-embed .molecule-map-info,
.map-embed .molecule-map-tools, .map-embed .molecule-map-legend,
.map-embed .molecule-map-axes { display: none; }
.map-embed .molecule-map-stage { height: 100vh; margin: 0; }
