/* The median-yield chart embedded in the bonds overview (':::app' wraps it in
   .app-embed.dash), on top of /site.css, whose tokens it uses. --bd-bar is the
   one chart hue, SQX Blue, the brand kit's single accent. */
:root { --bd-bar: var(--accent); --bd-label: 112px; --bd-room: 60px; }
/* --bd-label: the rating column; --bd-room: space kept right of the plot for the
   value at the longest bar's tip. In px, so the axis lines up with the bars. */
/* the caption above the panels: a readable measure, not the full column */
.app-embed.dash #yields > p { max-width: 75ch; font-size: 15px; }
.bd-panels { position: relative; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px; }
.bd-panel { margin: 0; padding: 14px 16px 10px; background: var(--panel); border: 1px solid var(--line); border-radius: 6px; }
.bd-panel figcaption { display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 10px; font: 600 15px var(--sans); color: var(--ink); }
.bd-panel figcaption span { font-weight: 400; font-size: 13px; color: var(--label); }
.bd-bars { display: flex; flex-direction: column; gap: 2px; }
.bd-bar-row { display: grid; grid-template-columns: var(--bd-label) minmax(0, 1fr); align-items: center; min-height: 28px; border-radius: 3px; cursor: default; }
.bd-bar-row:hover, .bd-bar-row:focus-visible { background: var(--accent-wash); }
.bd-bar-label { font-size: 13px; color: var(--text); }
.bd-bar-track { display: block; min-width: 0; border-left: 1px solid var(--line-2); height: 28px; }
.bd-bar-area { position: relative; display: block; width: calc(100% - var(--bd-room)); height: 100%; }
.bd-bar { position: absolute; left: 0; top: 5px; display: block; height: 18px; background: var(--bd-bar); border-radius: 0 4px 4px 0; }
.bd-bar-value { position: absolute; top: 5px; margin-left: 6px; font-size: 12.5px; line-height: 18px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.bd-axis { display: flex; justify-content: space-between; margin: 4px var(--bd-room) 0 var(--bd-label); font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.bd-tip { position: absolute; z-index: 2; display: flex; flex-direction: column; min-width: 170px; padding: 6px 10px; background: var(--sqx-white, #FFFFFF); color: var(--sqx-ink, #1A2430); border: 1px solid var(--sqx-hairline, #D3D7DF); border-radius: 6px; box-shadow: 0 4px 16px rgba(26, 36, 48, 0.14); font-size: 13px; pointer-events: none; }
.bd-tip[hidden] { display: none; }
.bd-tip strong { font-size: 15px; }
.bd-tip span { color: var(--sqx-grey, #69727A); }
.bd-details { margin: 12px 0 0; }
.bd-details summary { cursor: pointer; color: var(--accent); font-size: 14px; }

/* site.css makes a table its own scroll box (display: block), which stops it
   filling the column; the wrapper scrolls instead and the table stays a table. */
.bd-scroll { overflow-x: auto; background: var(--panel); }
.app-embed.dash .bd-table { display: table; font-variant-numeric: tabular-nums; }
.app-embed.dash .bd-table :is(th, td).num { text-align: right; white-space: nowrap; }
.app-embed.dash .bd-table td { white-space: nowrap; }

@media (max-width: 760px) {
  .bd-panels { grid-template-columns: minmax(0, 1fr); }
}
