/* external-financing - "External financing is large relative to
   government health budgets in many countries": chart card beside an
   insights note, same row/col/card/note layout AND same colors/spacing
   values as mnch/continuum ("Continuum of care" on the MNCH key-theme
   page) - matched property-for-property against continuum.css, with one
   deliberate difference: continuum.css's own .continuum__card/__note
   both declare `border: 1px solid var(--clr-gray-light)`, but the live
   page doesn't show one, so border is 0 here instead (explicit user
   choice, not a copy/paste miss).

   Section header and backdrop come from the master twig - not part of
   this component. Chart chrome (.hf-tools/.hf-seg/.hf-chart/...) is
   ../shared/css/hf-charts.css, loaded alongside this file, and uses its
   own --hf-* tokens (the mockup's own chart-data colors) - unrelated to
   this file, which only covers this component's card/note chrome and
   matches continuum.css's tokens one-for-one:
   --clr-gray-dark #4d4d4d (all body text - continuum doesn't use a
   separate "muted" shade), --clr-gray-light #dbdbdb (borders),
   --clr-blue #21568c (card title + divider), --clr-yellow-orange
   #f8b323 (insight left-border). */
.hf-external-financing {
  --hfext-ink: var(--clr-gray-dark, #4d4d4d);
  --hfext-border: var(--clr-gray-light, #dbdbdb);
  --hfext-teal: var(--clr-blue, #21568c);
  --hfext-yellow: var(--clr-yellow-orange, #f8b323);

  display: flex;
  flex-direction: column;
  gap: 24px;
  font-family: var(--primary-ff, 'Poppins', sans-serif);
  color: var(--hfext-ink);
}

/* ---------- layout (row/col, same as continuum__row/__col) ---------- */
.hf-external-financing__row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: stretch;
}

.hf-external-financing__col {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.hf-external-financing__col--main {
  flex: 3 1 560px;
  gap: 6px;
}

.hf-external-financing__col--side {
  flex: 2 1 380px;
  gap: 24px;
}

/* ---------- chart card (same shape as continuum__card) ---------- */
.hf-external-financing__card {
  flex: 1 1 auto;
  min-width: 0;
  background: var(--clr-white, #fff);
  border: 0;
  border-radius: 0 24px 0 24px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hf-external-financing__card-head {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
}

.hf-external-financing__card-titles {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.hf-external-financing__card-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none;
}

.hf-external-financing__card-actions .visualization-actions-block {
  position: static;
  inset: auto;
}

.hf-external-financing__divider {
  width: 1px;
  height: 30px;
  background: var(--hfext-teal);
}

.hf-external-financing .maximize-popup {
  cursor: pointer;
}

.hf-external-financing__chart-title {
  margin: 0;
  font-size: var(--fs-20, 20px);
  line-height: 1.3;
  font-weight: var(--fw-bold, 700);
  color: var(--clr-teal-dark, #0a544f);
}

.hf-external-financing__chart-sub {
  margin: 0;
  font-size: var(--fs-14, 14px);
  line-height: 1.5;
  color: var(--hfext-ink);
}

.hf-external-financing__source {
  margin: 0;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--hfext-border);
  font-size: var(--fs-13, 13px);
  line-height: 1.55;
  color: var(--hfext-ink);
}

.hf-external-financing__source b {
  color: var(--hfext-ink);
  font-weight: 600;
}

.hf-external-financing__source:empty {
  display: none;
}

/* ---------- insights note (same shape as continuum__note) ---------- */
.hf-external-financing__note {
  min-width: 0;
  flex: none;
  padding: 24px;
  background: var(--clr-white, #fff);
  border: 0;
  border-radius: 24px 0 24px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: var(--hfext-ink);
}

/* Same as continuum.css's own .continuum__note--emoc - missing here
   before, unlike continuum's reference section. */
@media (min-width: 901px) {
  .hf-external-financing__note {
    position: sticky;
    top: 96px;
  }
}

.hf-external-financing__insights-title {
  margin: 0;
  font-size: var(--fs-20, 20px);
  line-height: 1.3;
  font-weight: var(--fw-bold, 700);
  color: var(--hfext-ink);
}

.hf-external-financing__insights {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.hf-external-financing__insight {
  padding: 0 0 0 18px;
  border-left: 3px solid var(--hfext-yellow);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hf-external-financing__stat {
  margin: 0;
  font-size: var(--fs-34, 34px);
  line-height: 1.05;
  font-weight: var(--fw-bold, 700);
  color: var(--hfext-ink);
}

.hf-external-financing__insight-text {
  font-size: var(--fs-15, 15px);
  line-height: 1.55;
  color: var(--hfext-ink);
}

.hf-external-financing__closing {
  margin: 0;
  font-size: var(--fs-15, 15px);
  line-height: 1.65;
  color: var(--hfext-ink);
}

@media (max-width: 559px) {
  .hf-external-financing__card,
  .hf-external-financing__note {
    padding: 20px 16px;
  }

  .hf-external-financing__stat {
    font-size: 30px;
  }
}
