/* ─────────────────────────────────────────────────────────────────────────
   UNIFORM TOOLTIP SKIN — the site's single tooltip design.

   The design is the Highcharts 11 default tooltip box exactly as it renders
   on the Projected Price cone (/forecast/52-week-range/), read off the live
   DOM rather than copied from the docs:

     fill            #ffffff
     border          none  (v11 defaults tooltip.borderWidth to undefined, and
                            getLabel() resolves `borderWidth || 0` -> stroke 0)
     corners         r: 3
     padding         8
     shadow          <feDropShadow dx="1" dy="1" flood-opacity="0.75"
                                   stdDeviation="2.5" flood-color="#000000">
                     which is `1px 1px 5px rgba(0,0,0,0.75)` in CSS.
                     NOT 2.5px: SVG stdDeviation IS the Gaussian sigma, while
                     CSS blur-radius is defined as TWICE the sigma, so copying
                     the number across gives half the blur and a visibly harder
                     shadow. `.chart-tooltip` on /charts/ carried that same
                     mistranslation, which is where it was inherited from.
     text            DM Sans / 0.72rem / line-height 1.5

   THIS RULE PAINTS ONLY. Position, z-index, and the show/hide mechanism stay
   in each tooltip's own rule, because the JS driving them depends on those
   contracts and they are not interchangeable:

     .result-help-tooltip   opacity/visibility, toggled by .show
     .help-tooltip          display:none, toggled by .is-open
     .stat-tip              opacity/visibility, toggled by .tip-active/.tip-hover
                            on the PARENT .stat-card
     .bk-tv-tooltip         display:none, JS writes display:block
     .hm-tooltip            display:none, revealed by CSS :hover on .hm-cell
     .chart-tooltip         opacity, JS writes opacity
     ...and so on.

   Flattening those into one rule here would silently break the tooltips whose
   JS sets the other property. Keep the split.

   CHANGING THE SITE'S TOOLTIP LOOK MEANS CHANGING THIS FILE AND NOTHING ELSE.
   Per-page rules must not redeclare any painted property below — that is what
   scripts/check-tooltip-uniform.mjs enforces.
   ───────────────────────────────────────────────────────────────────────── */

.result-help-tooltip,
.panel-section-tooltip,
.help-tooltip,
.section-help-tooltip,
.run-btn-tooltip,
.stat-card .stat-tip,
.stat-card-tip,
.fwd-help-tip,
.chart-tip,
.chart-tooltip,
.pnl-tip,
.bk-tv-tooltip,
.hm-tooltip,
.ib-tip,
.mv-tip,
.stat-card .stat-tip-wrap,
.bounce-help .bounce-tip {
  background: #ffffff;
  background-image: none;
  border: 0;
  border-radius: 3px;
  padding: 8px;
  box-shadow: 1px 1px 5px rgba(0, 0, 0, 0.75);
  color: #1A1714;
  font-family: var(--sans, 'DM Sans', -apple-system, sans-serif);
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.5;
  text-align: left;
  text-transform: none;
  letter-spacing: 0;
  /* The cone auto-sizes because its content is short label/value rows. Prose
     tooltips would render as one enormous line without a bound, so cap the
     width and let short content size itself under the cap. */
  max-width: 280px;
  white-space: normal;
}

/* ── Accents, retuned for a white box ──────────────────────────────────────
   #F5A45C was chosen to sit on #1A1714 and washes out on white. The cone's
   own formatter already uses brand orange for the same job (prices), so the
   accent follows it rather than inventing a third orange. */
.result-help-tooltip strong,
.panel-section-tooltip strong,
.help-tooltip strong,
.section-help-tooltip strong,
.run-btn-tooltip strong,
.stat-card .stat-tip strong,
.stat-card-tip strong,
.fwd-help-tip strong,
.chart-tip strong,
.chart-tooltip strong,
.pnl-tip strong,
.bk-tv-tooltip strong,
.hm-tooltip strong,
.ib-tip strong,
.mv-tip strong,
.stat-card .stat-tip-wrap strong,
.bounce-help .bounce-tip strong {
  color: var(--brand, #B85C1E);
  font-weight: 700;
}

/* .tip-label is the green "what this measures" lead-in. Teal reads on white,
   so it keeps its colour. */
.result-help-tooltip strong.tip-label,
.panel-section-tooltip strong.tip-label,
.help-tooltip strong.tip-label,
.section-help-tooltip strong.tip-label,
.run-btn-tooltip strong.tip-label,
.stat-card .stat-tip strong.tip-label,
.stat-card-tip strong.tip-label,
.fwd-help-tip strong.tip-label {
  color: var(--green, #1a8a7f);
}

/* ── Paragraph rhythm ─────────────────────────────────────────────────────
   Prose tooltips stack sentences as <p>. Kept here so the spacing travels
   with the skin instead of being re-declared per page. */
.result-help-tooltip p,
.panel-section-tooltip p,
.help-tooltip p,
.section-help-tooltip p,
.run-btn-tooltip p,
.stat-card .stat-tip p,
.stat-card-tip p,
.fwd-help-tip p,
.hm-tooltip p,
.stat-card .stat-tip-wrap p,
.bounce-help .bounce-tip p {
  margin: 0 0 0.6rem;
}
.result-help-tooltip p:last-child,
.panel-section-tooltip p:last-child,
.help-tooltip p:last-child,
.section-help-tooltip p:last-child,
.run-btn-tooltip p:last-child,
.stat-card .stat-tip p:last-child,
.stat-card-tip p:last-child,
.fwd-help-tip p:last-child,
.hm-tooltip p:last-child,
.stat-card .stat-tip-wrap p:last-child,
.bounce-help .bounce-tip p:last-child {
  margin-bottom: 0;
}

/* The default box renders no pointer arrow at the anchors we use, so the one
   hand-drawn CSS triangle on the site is retired rather than recoloured. */
.bounce-help .bounce-tip::before {
  display: none;
}
