/* "Coming off": the filter bar's pill and pop-out panel
   (matchup/includes/bet-coming-off.php; printed for one viewer). The bar
   gains one pill; the controls are in a panel that opens over the page.
   Loaded by /matchup/ and /my-dashboards/. */
.co-bar { position: relative; padding: 0 0 10px; grid-column: 1 / -1; }
.co-pill span { max-width: 60vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.co-panel[hidden] { display: none; }
.co-panel {
    position: absolute; top: calc(100% - 4px); left: 0; z-index: 60;
    width: min(700px, calc(100vw - 32px));
    padding: 12px 14px;
    background: var(--tmb-surface);
    border: 1px solid var(--tmb-gray-300); border-radius: 8px;
    box-shadow: 0 8px 24px var(--tmb-black-15);
}
.co-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; }
.co-team { font-size: 13px; font-weight: 600; color: var(--tmb-gray-900); }
.co-actual { font-size: 11px; color: var(--tmb-gray-600); margin-bottom: 8px; min-height: 16px; }
.co-line { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.co-lbl { flex: 0 0 88px; font-size: 12px; color: var(--tmb-gray-700); }
.co-field {
    height: 26px; padding: 0 4px; font-size: 12px;
    color: var(--tmb-gray-900); background: var(--tmb-surface);
    border: 1px solid var(--tmb-gray-400); border-radius: 4px;
}
.co-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 6px; padding-top: 10px; border-top: 1px solid var(--tmb-gray-300); }
.co-hint { flex: 1 1 200px; font-size: 11px; color: var(--tmb-gray-600); }
@media (max-width: 767px) {
    .co-item { grid-column: 1 / -1; }
    /* In the flow on a phone: the bar's own width, never past the screen. */
    .co-panel { position: static; width: auto; margin-top: 6px; }
    .co-cols { grid-template-columns: 1fr; }
    .co-lbl { flex-basis: 100%; }
}

/* In a slot of a filter bar's grid (.co-item, tmbComingOffItem()): a pill
   the size of the bar's own dropdowns (All games, Full Game: .filter-dropdown,
   layout-matchup.css), and the panel under the WHOLE bar (the bar holds it
   by :has(), so a slot in the third or fourth column does not push the panel
   past the window's edge). */
.stats-filters:has(.co-item), .nhl-stats-filters:has(.co-item), .mlb-stats-filters:has(.co-item) { position: relative; }
.co-item .co-bar { position: static; padding: 0; grid-column: auto; min-width: 0; max-width: 100%; }
.co-item .co-pill.tmb-pill {
    height: auto; max-width: 100%;
    padding: 5px 14px;
    font-size: 0.82rem; font-weight: 600; line-height: 1.4;
    border-radius: 20px;
}
.co-item .co-pill i { font-size: 0.75rem; }
/* MLB's bar styles its dropdowns its own way (bet-mlb-stats-filters.php): match those */
.mlb-stats-filters .co-item .co-pill.tmb-pill { padding: 6px 14px; font-size: 14px; font-weight: 500; }
.co-item .co-pill span { min-width: 0; }
.co-item .co-panel { top: calc(100% - 6px); left: 15px; }

