/* Page-scoped Treasury charts; inherit the Tip Desk's two themes. */
.ty-page { --ty-0: #175aa7; --ty-1: #ad4c22; --ty-2: #087c67; --ty-3: #8258a2; }
[data-theme="bento"] .ty-page { --ty-0: #67dfff; --ty-1: #ffb581; --ty-2: #73e0b7; --ty-3: #d6a5ff; }
.ty-page h1 { margin: 0 0 8px; font: 700 30px var(--serif); }
.ty-source { margin: 0 0 26px; color: var(--ink-secondary); font: 13px var(--sans); }
.ty-source a { color: var(--ink-secondary); }
.ty-panel { border-top: 1px solid var(--line); padding: 19px 0 24px; }
.ty-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.ty-heading h2 { margin: 0; font: 700 20px var(--serif); }
.ty-asof { color: var(--ink-secondary); white-space: nowrap; font: 12px var(--sans); }
.ty-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 9px 18px; margin-bottom: 8px; }
.ty-presets, .ty-zoom, .ty-series-list { display: flex; gap: 4px; }
.ty-series-list { margin-left: auto; }
.ty-page button, .ty-page input { font: 13px var(--sans); color: var(--ink); }
.ty-page button { padding: 6px 10px; min-height: 34px; border: 1px solid var(--line); background: var(--bg); border-radius: 3px; cursor: pointer; }
.ty-page button:hover { border-color: var(--ink-secondary); }
.ty-page button[aria-pressed="true"][data-range] { background: var(--navy); color: var(--bg); border-color: var(--navy); }
.ty-series span { display: inline-block; width: 15px; border-top: 3px solid currentColor; margin-right: 6px; vertical-align: middle; }
.ty-page .ty-series { color: var(--ty-color); }
.ty-series[aria-pressed="false"] { opacity: 0.5; text-decoration: line-through; }
.ty-color-0 { --ty-color: var(--ty-0); }
.ty-color-1 { --ty-color: var(--ty-1); }
.ty-color-2 { --ty-color: var(--ty-2); }
.ty-color-3 { --ty-color: var(--ty-3); }
.ty-chart { position: relative; }
.ty-chart svg { display: block; width: 100%; height: auto; overflow: visible; touch-action: pan-y; user-select: none; }
.ty-chart svg[tabindex] { cursor: crosshair; }
.ty-grid { stroke: var(--line); stroke-width: 1; }
.ty-zero { stroke: var(--ink-secondary); stroke-width: 1; stroke-dasharray: 4 4; }
.ty-axis { fill: var(--ink-secondary); font: 12px var(--sans); }
.ty-line { stroke: var(--ty-color); fill: none; stroke-width: 2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.ty-history-line { stroke-width: 1.25; opacity: 0.82; }
[data-theme="bento"] .ty-history-line { opacity: 0.88; }
.ty-prior-line { stroke-dasharray: 5 4; opacity: 0.85; }
.ty-curve-legend { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 0 0 10px; font: 12px var(--sans); color: var(--ink-secondary); }
.ty-curve-legend i { display: inline-block; width: 20px; border-top: 2px solid var(--ty-color); margin-right: 6px; vertical-align: middle; }
.ty-prior-key i { border-top-style: dashed; }
.ty-curve-values .ty-prior-value { color: var(--ty-1); margin-top: 4px; font-size: 12px; }
.ty-dot { fill: var(--ty-color); stroke: var(--bg); stroke-width: 1.5; }
.ty-cursor { stroke: var(--ink-secondary); stroke-width: 1; stroke-dasharray: 3 3; }
.ty-selection { fill: var(--navy); opacity: 0.15; pointer-events: none; }
.ty-page :focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; }
.ty-dot:focus-visible { stroke: var(--ink); stroke-width: 3; }
.ty-curve-values { display: grid; grid-template-columns: repeat(10, 1fr); gap: 8px; margin: 10px 0 4px; text-align: center; font: 13px var(--sans); }
.ty-curve-values span { display: block; }
.ty-curve-values .ty-term { color: var(--ink-secondary); margin-bottom: 5px; font-size: 12px; }
.ty-readout { min-height: 20px; margin: 6px 0 12px; font: 13px var(--sans); font-variant-numeric: tabular-nums; color: var(--ink); }
.ty-dates { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; font: 12px var(--sans); color: var(--ink-secondary); }
.ty-dates label { display: flex; align-items: center; gap: 6px; }
.ty-dates input { background: var(--bg); border: 1px solid var(--line); border-radius: 3px; padding: 5px; min-height: 32px; color-scheme: light; }
[data-theme="bento"] .ty-dates input { color-scheme: dark; }
.ty-hint { margin-left: auto; }
.ty-sliders { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 8px; }
.ty-sliders input { width: 100%; margin: 0; accent-color: var(--navy); min-height: 28px; cursor: pointer; }
.ty-empty, .ty-error { font: 13px var(--sans); color: var(--ink-secondary); }
.ty-error { margin: 6px 0 0; }
.ty-error:empty { display: none; }
.ty-sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 600px) {
  .ty-page h1 { font-size: 26px; }
  .ty-heading { align-items: flex-start; flex-direction: column; gap: 5px; }
  .ty-heading h2 { font-size: 19px; }
  .ty-series-list { margin-left: 0; width: 100%; }
  .ty-controls { gap: 8px; }
  .ty-page button { min-height: 38px; padding: 6px 10px; }
  .ty-axis { font-size: 11px; }
  .ty-curve-values { grid-template-columns: repeat(5, 1fr); gap: 13px 4px; }
  .ty-hint { width: 100%; margin-left: 0; }
  .ty-readout { line-height: 1.6; }
}
