/* public/table.css — the gilt table page styles, moved out of table.html (Oct 2026) so browsers cache them.
   Linked at the same position in <head> as the old inline block, so the cascade order is unchanged. */
body{font-family:'Inter',sans-serif;background:var(--color-bg);color:var(--color-text);min-height:100vh;padding:60px 16px 80px;font-size:14px;line-height:1.5}
.container{max-width:1400px;margin:0 auto;padding:0 8px}

/* Top bar */
.top-bar{background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius);padding:12px 18px;margin-bottom:14px;display:flex;align-items:center;gap:16px;flex-wrap:wrap}
.tb-label{font-size:10px;font-weight:500;letter-spacing:.06em;text-transform:uppercase;color:var(--color-text-muted);white-space:nowrap}
.tax-options{display:flex;gap:5px;flex-wrap:wrap}
.tax-opt{position:relative}
.tax-select{display:none}
.tax-opt input{position:absolute;opacity:0;width:100%;height:100%;cursor:pointer;margin:0}
.tax-opt label{display:flex;align-items:center;gap:4px;padding:5px 11px;border:1.5px solid var(--color-border);border-radius:8px;cursor:pointer;transition:all .12s;font-size:11px;color:var(--color-text-muted);background:var(--color-surface)}
.tax-opt label .rate{font-size:13px;font-weight:500;font-family:'Inter',sans-serif;color:var(--color-text)}
.tax-opt input:checked+label{border-color:var(--color-accent);background:var(--color-accent-light);color:var(--color-accent-text)}
.tax-opt input:checked+label .rate{color:var(--color-accent-text)}
.invest-wrap{display:flex;align-items:center;gap:8px;margin-left:auto}
.invest-input{background:var(--color-surface);border:1.5px solid var(--color-border);border-radius:8px;padding:5px 11px;font-family:'Inter',sans-serif;font-size:16px;color:var(--color-text);outline:none;width:115px;transition:border-color .15s}
.invest-input:focus{border-color:var(--color-accent)}

/* Price info bar */
.ctl-summary{display:none}
.price-bar{background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius);padding:10px 16px;margin-bottom:14px;display:flex;align-items:center;gap:12px;box-shadow:var(--shadow)}
.price-bar-text{font-size:12px;color:var(--color-text-muted);flex:1}
.price-bar-text strong{color:var(--color-text)}
.price-bar-ts{font-size:11px;color:var(--color-text-muted);margin-left:auto;white-space:nowrap}
/* ≤560px: the close label + next-update sublabel + Refresh don't fit one row (natural width ~470px), so
   the sublabel drops to its own full-width line — label + Refresh on line 1, sublabel on line 2 (two lines,
   no squeezed column). Above 560 the compact single row is kept. */
@media(max-width:560px){
  .price-bar{flex-wrap:wrap}
  .price-bar-ts{margin-left:0;white-space:normal;flex-basis:100%;order:3}
}


/* Filter */
.filter-row{display:flex;gap:5px;margin-bottom:10px;flex-wrap:wrap;align-items:center}
.wstar{background:none;border:none;cursor:pointer;font-size:16px;line-height:1;padding:6px 8px;min-width:32px;min-height:32px;border-radius:8px;font-family:inherit}
.wstar:focus-visible,#giltBody tr:focus-visible{outline:2px solid var(--color-accent-hover);outline-offset:-2px}
@media(max-width:680px){.chip{min-height:32px}}
.chip{background:var(--color-surface);border:1.5px solid var(--color-border);border-radius:100px;padding:3px 11px;font-size:11px;cursor:pointer;transition:all .12s;color:var(--color-text-muted);font-family:'Inter',sans-serif}
.chip:hover,.chip.active{background:var(--color-accent-light);border-color:var(--color-accent-hover);color:var(--color-accent-hover)}
/* Filter zones: Type + Maturity are single-select segmented groups (one active each); a small muted
   label names each so the row reads as grouped, not one long undifferentiated chip strip. The spacer
   pushes the not-filters (watchlist, search, compare) to the right on wide screens; it collapses when
   the row wraps on mobile. */
.fseg{display:inline-flex;align-items:center;gap:4px}
.fseg-lbl{font-size:10px;font-weight:600;color:var(--color-text-muted);text-transform:uppercase;letter-spacing:.04em}
.filter-spacer{flex:1 1 12px;min-width:0}
/* Mobile (≤560px, the compact-grid default): drop the zone labels and swap segment labels for short
   forms so the filter block loses a wrapped line — a visible gilt row is worth more than the long text. */
.s-short{display:none}
.need-pick{position:relative;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap}.need-pick .need-month{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;border:0;padding:0;margin:0;font-size:16px}.need-pick.no-month .need-month{position:static;opacity:1;width:7.5em;height:auto;font-size:12px;background:transparent;color:inherit}.need-pick.no-month #needPickTxt{display:none}
.need-card{border:1.5px solid var(--color-accent-hover);background:var(--color-accent-light,#E8F5EE);border-radius:12px;padding:14px 16px;margin:0 0 12px;font-size:14px;line-height:1.55;color:var(--color-text)}
.need-card .nc-h{font-size:12px;text-transform:uppercase;letter-spacing:.05em;color:var(--color-accent-hover);font-weight:600;margin-bottom:4px}
.need-card .nc-best{font-size:15px}
.need-card .nc-alt{margin-top:6px;font-size:13px;color:var(--color-text-muted)}
.need-card .nc-acts{margin-top:10px;display:flex;gap:8px;flex-wrap:wrap}
.need-card .nc-acts a{font-size:13px;font-weight:600;color:var(--color-accent-hover);border:1px solid var(--color-accent-hover);border-radius:8px;padding:5px 10px;text-decoration:none;background:var(--color-surface)}
.need-card .nc-fine{margin-top:8px;font-size:11.5px;color:var(--color-text-muted)}
.need-card .nc-fine summary{cursor:pointer;color:var(--color-accent-hover);font-weight:600}
.need-tag{display:block;font-size:10px;font-weight:600;margin-top:2px;white-space:nowrap}
.need-tag.nt-ontime{color:var(--color-accent-hover)}
.need-tag.nt-early{color:#8A6D1F}
.need-tag.nt-late{color:#B4532A}
@media(max-width:560px){.fseg-lbl{display:none}.s-full{display:none}.s-short{display:inline}.fseg-lbl.need-lbl{display:block;flex:0 0 100%;font-size:11px;margin:2px 0 0}#needSeg{display:flex;flex-wrap:wrap;width:100%;gap:6px}#needSeg .seg{flex:1 1 0;min-width:0;padding:3px 4px;font-size:12px}#needSeg .need-pick{flex:0 0 100%;font-size:12px;border-style:dashed}#needSeg .need-pick.active{border-style:solid}}
.compare-toggle{display:none;border-style:dashed;border-color:var(--color-accent-hover);color:var(--color-accent-hover);font-weight:600}
.compare-toggle.active{background:var(--color-accent-hover);border-color:var(--color-accent-hover);color:#fff;border-style:solid}
.cmp-year{display:none}
.il-toggle.il-2,.il-toggle.il-2:hover{border-color:var(--color-accent);color:var(--color-accent);background:transparent}
.il-toggle.il-3,.il-toggle.il-3:hover{border-color:var(--color-neutral);color:var(--color-neutral);background:var(--color-surface-alt)}
.search-box{border:1.5px solid var(--color-border);border-radius:8px;padding:4px 9px;font-size:16px;font-family:'Inter',sans-serif;outline:none;color:var(--color-text);background:var(--color-surface);width:150px;margin-left:auto}
.search-box:focus{border-color:var(--color-accent-hover)}

/* Table */
.table-wrap{background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius);overflow-x:auto;overflow-y:auto;box-shadow:var(--shadow);margin-bottom:12px;max-height:520px}
.gilt-table{width:100%;border-collapse:collapse;font-size:12px;table-layout:auto;font-variant-numeric:tabular-nums}
.gilt-table thead{position:sticky;top:0;z-index:2}
.gilt-table th{background:var(--color-surface-alt);color:var(--color-text-muted);font-size:10px;font-weight:600;letter-spacing:.04em;text-transform:uppercase;padding:10px 7px;text-align:right;white-space:nowrap;cursor:pointer;user-select:none;border-bottom:1px solid var(--color-border-strong);min-width:60px}
.gilt-table th:first-child{text-align:left;padding-left:12px;min-width:50px}
.gilt-table th:nth-child(2){text-align:left;min-width:160px}
.gilt-table th:hover{color:var(--color-text)}
.gilt-table th.sort-active{color:var(--color-accent-hover)}
.gilt-table th[data-sortdir]::after{color:var(--color-accent);font-weight:700}
.gilt-table th[data-sortdir="asc"]::after{content:' ▲'}
.gilt-table th[data-sortdir="desc"]::after{content:' ▼'}
.gilt-table th:focus-visible{outline:2px solid var(--color-accent);outline-offset:-2px}
.gilt-table td{padding:8px 7px;text-align:right;border-bottom:1px solid var(--color-border);color:var(--color-text);white-space:nowrap;vertical-align:middle}
.gilt-table td:first-child{text-align:left;padding-left:12px}
.gilt-table td:nth-child(2){text-align:left}
.gilt-table tbody tr{cursor:pointer;transition:background var(--duration-fast) var(--ease-std)}
.gilt-table tbody tr:hover{background:var(--color-accent-light)}
.gilt-table tbody tr:active{background:var(--color-accent-light)}  /* touch/press feedback — makes rows feel tappable */
.gilt-table tbody tr.sel{background:var(--color-accent-light)}
.gilt-table tbody tr.sel td:first-child{box-shadow:inset 3px 0 var(--color-accent)}
.gilt-table tbody tr:nth-child(even):not(:hover):not(.sel){background:rgba(241,243,245,0.55)}
/* Index-linked real yield. A real yield is NOT comparable to a nominal one, so it never shares the
   Gross column. Desktop 'Include IL' (body.il-mixed) shows a dedicated Real column; 'IL only' relabels
   the Gross column to Real yield (no second column). The .real-col column is forced off on mobile (see
   the @media block) — there the IL yield lives in the Gross cell: the number (.il-ynum) in the card
   view, and a "real →" tap signal (.il-ytap) in the compact compare grid. */
.real-col{display:none}
.il-mixed .real-col{display:table-cell}
.il-ynum,.il-ytap{display:none}
.il-ytap{color:var(--color-accent-hover);white-space:nowrap;cursor:pointer}
.compare-mode .il-ytap{display:inline}
.gilt-table tbody tr:last-child td{border-bottom:none}
/* Tappable chevron on mobile cards — hidden on desktop table & in compare mode */
.card-chevron{display:none}
.epic{font-weight:600;font-size:10.5px;color:var(--color-accent-hover)}
.gdesc{font-size:9.5px;color:var(--color-text-muted)}
.price-ts-small{font-size:8.5px;color:var(--color-text-muted);display:block}
.pill{display:inline-block;font-size:9px;padding:1px 5px;border-radius:100px;font-weight:500}
.pill.below{background:var(--color-accent-light);color:var(--color-accent-text)}
.pill.above{background:var(--color-surface-alt);color:var(--color-text-muted)}
.pill.par{background:var(--color-surface-alt);color:var(--color-text-muted)}
.pos{color:var(--color-positive)}.neg{color:var(--color-negative)}.neu{color:var(--color-neutral)}
.empty{text-align:center;padding:40px;color:var(--color-text-muted);font-size:13px}

/* nav, hamburger & mobile menu provided by styles.css */
.strip-grid{display:grid;grid-template-columns:repeat(9,1fr);gap:10px;margin-top:16px}
@media(max-width:900px){.strip-grid{grid-template-columns:repeat(5,1fr)}}
@media(max-width:780px){.strip-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:480px){.strip-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:680px){
  #ilBanner{font-size:11px;padding:10px 12px}
  #giltStrip{padding:14px 12px}
  #giltStrip .strip-val{font-size:15px!important}
  .strip-header-row{flex-direction:column;gap:8px}
  /* Wrap on mobile: the Calculator link (nowrap) + fixed-width Save button gave the
     action row a rigid ~351px min-width that overflowed narrow phones, pushing the
     🔔 and the ✕ close button off the right edge (invisible/untappable ≤~360px).
     Calculator + Price history share the first line; Save / Share / 🔔 / ✕ share the
     next and shrink (min-width:0) so the close button is always on-screen. */
  .strip-buttons{flex-direction:row;flex-wrap:wrap;width:100%;gap:6px!important}
  .strip-buttons a{flex:1 1 calc(50% - 3px);text-align:center;justify-content:center;font-size:12px!important;padding:9px 8px!important}
  .strip-buttons button{flex:1 1 40px;min-width:0;width:auto!important;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;text-align:center;font-size:11px!important;line-height:1.1;padding:8px 2px!important;min-height:54px}
  .strip-buttons button[style*="display:none"]{display:none}
  #giltStrip .sd-act .ic{font-size:17px;line-height:1}
  #giltStrip .sd-act .lb{font-size:11px;font-weight:500;white-space:nowrap}
  #giltStrip .strip-buttons .sd-act .m{display:inline}
  #giltStrip .strip-buttons .x{display:none}
  .strip-buttons a{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
}
@media(max-width:350px){
  /* Narrowest phones (320px): keep all five action tiles on one row. */
  .strip-buttons{gap:4px!important}
  .strip-buttons button{flex:1 1 0!important;min-width:0!important;padding:8px 0!important}
  #giltStrip .sd-act .lb{font-size:10px}
}
/* The rest of the phone layout (≤680px). It was accidentally nested inside the ≤350px block above by the
   detail-buttons change (#175), so on most phones the compact top bar, tax dropdown etc. stopped applying. */
@media(max-width:680px){
  .strip-grid{grid-template-columns:repeat(2,1fr);gap:7px;margin-top:10px}
  .strip-note{display:none}
  body{padding:60px 12px 60px}
  /* Compact top bar on mobile so the table starts higher (was ~253px tall at 390px, ~130 now):
     tax bands as ONE row of four rate-only buttons (the band word "Basic/Higher/…" is dropped — four-across
     can't fit "45% Additional"), and Cash + Unused PSA side by side. Grid areas over the bar's six
     children in source order: tax label, tax options, cash label, cash input, PSA label, PSA input. */
  .top-bar{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr) minmax(0,1fr);grid-template-areas:"tl cl pl" "tx ci pi";column-gap:10px;row-gap:6px;align-items:end;padding:10px 12px;margin-bottom:10px}
  .top-bar>:nth-child(1){grid-area:tl}
  .top-bar>:nth-child(2){grid-area:tx}
  .top-bar>:nth-child(3){grid-area:cl;margin-left:0!important}
  .top-bar>:nth-child(4){grid-area:ci}
  .top-bar>:nth-child(5){grid-area:pl;margin-left:0!important}
  .top-bar>:nth-child(6){grid-area:pi}
  .top-bar>div[style*="inline-flex"]{display:flex!important;width:100%;box-sizing:border-box;height:36px!important}
  .top-bar>div[style*="inline-flex"] input{flex:1;min-width:0;width:auto!important}
  /* Tax band as a dropdown (one row with Cash + PSA); the four radio buttons stay in the DOM, hidden. */
  .tax-opt{display:none}
  .tax-select{display:block;width:100%;box-sizing:border-box;height:36px;padding:0 26px 0 10px;border:1.5px solid var(--color-accent);border-radius:8px;background:var(--color-accent-light) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%230F766E' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat right 10px center;color:var(--color-accent-text);font-family:'Inter',sans-serif;font-size:16px;font-weight:600;-webkit-appearance:none;appearance:none;cursor:pointer;text-overflow:ellipsis}
  .tax-select:focus-visible{outline:2px solid var(--color-accent-hover);outline-offset:2px}
  /* The PSA "i" now sits in the right-hand column — anchor its popover to the right edge, not centred,
     so the (hidden) 230px popover never extends past the viewport (horizontal scroll). */
  .top-bar>:nth-child(5) .info-pop .pop{left:auto;right:-8px;transform:none}
  /* BoE strip on one line: tighter separators (with the short "BoE" credit, ≤560px) */
  .search-box{flex:1 1 110px;width:auto;min-width:0;margin-left:0}
  /* Price status: two tight lines instead of a roomy card */
  .price-bar{padding:6px 12px;margin-bottom:6px;gap:2px 8px;line-height:1.35}
  #rateLine{padding-bottom:8px}
  #rateLine>span[style*="margin:0 6px"]{margin:0 3px!important}

  /* ── Mobile: transform the 13-column gilt table into cards ── */
  .table-wrap{max-height:none;overflow:visible;border:none;background:transparent;box-shadow:none;border-radius:0;margin-bottom:4px}
  .gilt-table{font-size:13px}
  .gilt-table thead{display:none}
  .gilt-table,.gilt-table tbody{display:block}
  .gilt-table tbody tr{display:block;background:var(--color-surface);border:1px solid var(--color-border);border-radius:12px;box-shadow:var(--shadow);padding:11px 14px 7px;margin-bottom:10px}
  .gilt-table tbody tr.sel{border-color:var(--color-accent-hover);background:var(--color-accent-light)}
  .gilt-table tbody tr:hover{background:var(--color-surface)}
  .gilt-table td{display:flex;justify-content:space-between;align-items:baseline;gap:14px;padding:5px 0;border:none!important;text-align:right;white-space:normal}
  .gilt-table td::before{content:attr(data-label);color:var(--color-text-muted);font-size:11px;font-weight:500;text-transform:uppercase;letter-spacing:.03em;text-align:left}
  .gilt-table td:nth-child(1){display:block;text-align:left;padding:0}
  .gilt-table td:nth-child(1) .epic{font-family:'Inter',sans-serif;font-size:17px;font-weight:600;color:var(--color-text)}
  .gilt-table td:nth-child(1) .card-chevron{display:inline;float:right;color:var(--color-border);font-size:20px;line-height:1}
  /* Higher specificity than the show rule above so compare-mode (the mobile default) wins */
  .compare-mode .gilt-table td:nth-child(1) .card-chevron{display:none}
  .gilt-table td:nth-child(2){display:block;text-align:left;padding:1px 0 8px;border-bottom:1px solid var(--color-border)!important;margin-bottom:4px}
  .gilt-table td:nth-child(1)::before,.gilt-table td:nth-child(2)::before{display:none}
  .gilt-table td:nth-child(3)::before{content:"Coupon"}
  .gilt-table td:nth-child(4)::before{content:"Price (clean)"}
  .gilt-table td:nth-child(13)::before{content:"Tax-free gain per £100"}
  .gilt-table td:nth-child(7){font-size:15px;padding:6px 8px;margin:2px -8px;border-radius:6px}
  .gilt-table td:nth-child(10),.gilt-table td:nth-child(11),.gilt-table td:nth-child(12){display:none}  /* col 9 (savings equiv) shown as a card row; col 8 (Real yield) hidden via .real-col */
  .gilt-table td:nth-child(5){font-size:11px}  /* change row in cards — small, with its colour class */
  /* Combined ★/🔔 actions cell: right-aligned at the card's bottom */
  .gilt-table td:nth-child(14){justify-content:flex-end;padding-top:8px;border:none!important}
  .gilt-table td:nth-child(14)::before{display:none}
  /* Mobile: the desktop Real column never shows; the IL yield lives in the Gross cell — the number in
     the card view, the "real →" tap signal in the compact grid. */
  .real-col{display:none!important}
  .il-ynum{display:inline}
  .compare-mode .il-ynum{display:none}

  /* ── Compare mode: compact scrollable mini-table (overrides the card layout) ── */
  .compare-toggle{display:inline-block}
  .compare-mode .table-wrap{max-height:520px;overflow:auto;border:1px solid var(--color-border);border-radius:var(--radius);background:var(--color-surface);box-shadow:var(--shadow);margin-bottom:4px}
  .compare-mode .gilt-table{display:table;width:100%;font-size:12px;table-layout:fixed}
  .compare-mode .gilt-table thead{display:table-header-group}
  .compare-mode .gilt-table thead tr{display:table-row}
  .compare-mode .gilt-table th{display:table-cell;position:sticky;top:0;z-index:2;background:var(--color-surface-alt);color:var(--color-text-muted);font-size:10px;font-weight:500;text-transform:uppercase;letter-spacing:.03em;padding:4px 6px;text-align:right;white-space:nowrap;cursor:pointer}
  .compare-mode .gilt-table tbody{display:table-row-group}
  .compare-mode .gilt-table tbody tr{display:table-row;background:var(--color-surface);border:none;border-radius:0;box-shadow:none;padding:0;margin:0}
  .compare-mode .gilt-table tbody tr.sel{background:var(--color-accent-light)}
  .compare-mode .gilt-table td{display:table-cell;padding:4px 6px;text-align:right;border:none;border-bottom:1px solid var(--color-border)!important;white-space:nowrap;font-size:12px}
  .compare-mode .gilt-table td::before{display:none!important}
  .compare-mode .gilt-table th[data-compare="hide"],
  .compare-mode .gilt-table td[data-compare="hide"]{display:none}
  .compare-mode .gilt-table th:nth-child(1),
  .compare-mode .gilt-table td:nth-child(1){text-align:left;display:table-cell;padding:4px 6px}
  .compare-mode .gilt-table td:nth-child(1) .epic{font-family:'Inter',sans-serif;font-size:13px;font-weight:600;color:var(--color-text)}
  .compare-mode .cmp-year{display:block;font-size:10px;color:var(--color-text-muted);font-weight:500;line-height:1.1}
  .compare-mode .gilt-table td:nth-child(7){background:var(--color-accent-light);font-weight:600;color:var(--color-accent-text);font-size:12px;margin:0;border-radius:0;padding:4px 6px}
  /* Fixed widths (table-layout:fixed) so the 6 visible columns fit a ~375px screen
     with no horizontal scroll. Percentages map the intended px ratios and sum to 100%.
     Visible compare columns are DOM positions 1, 4, 5, 6, 7 and the combined 13. */
  .compare-mode .gilt-table th:nth-child(1),.compare-mode .gilt-table td:nth-child(1){width:22%;white-space:normal}
  .compare-mode .gilt-table th:nth-child(4),.compare-mode .gilt-table td:nth-child(4){width:15%}
  .compare-mode .gilt-table th:nth-child(5),.compare-mode .gilt-table td:nth-child(5){width:13%}
  .compare-mode .gilt-table th:nth-child(6),.compare-mode .gilt-table td:nth-child(6){width:16%}
  .compare-mode .gilt-table th:nth-child(7),.compare-mode .gilt-table td:nth-child(7){width:18%}
  .compare-mode .gilt-table th:nth-child(14),.compare-mode .gilt-table td:nth-child(14){width:16%;padding:3px 2px;text-align:center}
  /* Shrink the ★/🔔 actions content so it fits its 16% column — inline styles need !important. */
  .compare-mode .gilt-table td:nth-child(14) span{font-size:13px!important;padding:2px 3px!important}
  .compare-mode .gilt-table td:nth-child(14) button{padding:1px 4px!important;font-size:11px!important;margin-left:2px!important}
  /* short sticky header labels in compare mode */
  .compare-mode .gilt-table th[data-short]{font-size:0}
  .compare-mode .gilt-table th[data-short]::after{content:attr(data-short);font-size:10px;font-weight:600}
  /* active sort column in compare mode: green text + tint, arrow appended to the short label */
  .compare-mode .gilt-table th.sort-active{color:var(--color-accent-hover);background:rgba(13,148,136,0.3)}
  .compare-mode .gilt-table th[data-short][data-sortdir="asc"]::after{content:attr(data-short) ' ▲';color:var(--color-accent-hover)}
  .compare-mode .gilt-table th[data-short][data-sortdir="desc"]::after{content:attr(data-short) ' ▼';color:var(--color-accent-hover)}
}
@media(max-width:390px){
  /* Tight screens: shrink compare-mode cells so all 6 columns stay legible without overflow. */
  .compare-mode .gilt-table td,
  .compare-mode .gilt-table th{font-size:11px;padding:4px 4px}
}
@media(max-width:360px){
  /* Very small screens: the net-yield header falls back to its shorter label. */
  .compare-mode .gilt-table th[data-short-xs]::after{content:attr(data-short-xs)}
  /* Drop the short-label font 10px -> 9px so "Grs Yld"/"Net (40%)" fit their
     ~39-45px columns at 320px without spilling past the cell. */
  .compare-mode .gilt-table th[data-short]::after{font-size:9px}
}
/* Settings + filters fold into one summary bar on phones — portrait (≤680px wide) AND landscape (a short touch screen,
   where the panel would fill the whole height). Nov 2026. */
@media (max-width:680px), (max-height:500px) and (pointer:coarse){
  .ctl-summary{display:flex;align-items:center;gap:10px;width:100%;box-sizing:border-box;min-height:46px;margin:0 0 8px;padding:8px 12px;background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius);font:inherit;text-align:left;color:var(--color-text);cursor:pointer}
  .ctl-summary:focus-visible{outline:2px solid var(--color-accent-hover);outline-offset:2px}
  .ctl-sum-txt{flex:1;min-width:0;display:flex;flex-direction:column;gap:1px}
  .ctl-sum-l1{font-size:14px;font-weight:600;font-variant-numeric:tabular-nums;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .ctl-sum-l2{font-size:12px;color:var(--color-text-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .ctl-sum-l2:empty{display:none}
  .ctl-sum-act{flex:0 0 auto;font-size:13px;font-weight:600;color:var(--color-accent-hover)}
  .ctl-closed .top-bar{display:none}
  .ctl-closed .filter-row>:not(.search-box):not(#curveLink):not(#compareToggle){display:none!important}
}
