/* Подстраницы команды: расписание, результаты, статистика по типам ставок.
   Подключается через @push('head') на странице команды и её подстраницах;
   общие токены и классы (.panel, .tbl, .chip, .match) берутся из app.css. */

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Вторая полоса вкладок — типы статистики. Их много, поэтому чипы мельче. */
.chips--stat { margin: 12px 0 0; }
/* Figma #12: рынки свёрнуты под табами */
.chips-fold { margin: -8px 0 24px; }
.chips-fold summary { display: inline-flex; align-items: center; gap: 8px; list-style: none; cursor: pointer; user-select: none; font-size: 13px; font-weight: 600; color: var(--c-muted); }
.chips-fold summary::-webkit-details-marker { display: none; }
.chips-fold summary:hover { color: var(--c-text); }
.chips-fold summary i { font-style: normal; font-size: 11px; color: var(--c-faint); background: var(--c-bg); border-radius: 4px; padding: 2px 6px; }
.chips-fold .ico--chev { width: 12px; height: 12px; transition: transform .15s; }
.chips-fold[open] .ico--chev { transform: rotate(180deg); }
.chips--anchors { margin-bottom: 16px; }
.chip--sm { height: 30px; padding: 0 12px; font-size: 12px; }

.tstat__intro { color: var(--c-muted); font-size: 14px; line-height: 1.55; margin-bottom: 24px; }
.tstat__note { color: var(--c-faint); font-size: 13px; line-height: 1.5; margin-top: 24px; }

/* Полоса распределения: сколько процентов матчей в плюс, в минус и вровень. */
.tstat__bar { display: flex; overflow: hidden; border-radius: var(--r-sm); margin-bottom: 20px; height: 26px; }
.tstat__bar__part { display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; color: #fff; min-width: 0; }
.tstat__bar__part--good { background: var(--c-accent); }
.tstat__bar__part--bad { background: #e8544d; }
.tstat__bar__part--even { background: #b6b6b6; }

.tstat .tbl-wrap { margin-bottom: 20px; }
.tstat__tbl { font-size: 13px; }
.tstat__tbl td, .tstat__tbl th { padding: 10px 8px; }

/* Дата матча со ссылкой на страницу матча и подписью турнира. */
.tstat__when a { display: flex; flex-direction: column; gap: 2px; }
.tstat__when b { font-weight: 600; }
.tstat__when i { font-style: normal; font-size: 11px; color: var(--c-faint); }
.tbl td.tstat__when, .tbl th.tbl__name { text-align: left; }

.tstat__side { text-align: left !important; max-width: 220px; }
.tstat__team { display: flex; align-items: center; gap: 8px; min-width: 0; }
.tstat__team .logo-sm { width: 22px; height: 22px; flex: none; }

.tstat__val { font-weight: 700; width: 46px; }
.tstat__minute { font-weight: 600; width: 70px; }
.tstat__minute i { font-style: normal; font-weight: 400; color: var(--c-faint); }
.tstat__nodata { color: var(--c-faint); font-style: italic; }

/* Раскраска: зелёный — показатель в пользу команды страницы, красный — против, серый — поровну. */
.is-good { background: rgba(12, 193, 148, .16); }
.is-bad { background: rgba(232, 84, 77, .14); }
.is-even { background: rgba(150, 150, 150, .14); }
.tstat__val.is-good { color: var(--c-accent-dark); }
.tstat__val.is-bad { color: #c53b34; }
/* position:relative обязателен: иначе абсолютная подпись .sr считается от корня страницы,
   не обрезается прокруткой таблицы и растягивает документ по горизонтали на мобильном. */
.tstat__cell { width: 42px; position: relative; border-left: 2px solid var(--c-card); }
.tstat__cell:first-of-type { border-left: 0; }
.tstat__cell.is-good { background: var(--c-accent); }
.tstat__cell.is-bad { background: #e8544d; }
.tstat__cell.is-even { background: #cfcfcf; }

/* Таблицы вероятностей под основной таблицей (тоталы, форы, интервалы). */
.tstat__probs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.tstat__prob { background: var(--c-card); border-radius: var(--r-md); overflow-x: auto; }
.tstat__prob--wide { grid-column: 1 / -1; max-width: 560px; } /* 4 колонки на 724 px растянуты — аудит плотности 23.09 */
.tstat__prob--wide .tbl th.tbl__name { width: 34%; }
.tstat__prob .tbl { font-size: 13px; }
.tstat__prob .tbl td, .tstat__prob .tbl th { padding: 9px 10px; }

.tstat__about { color: var(--c-muted); font-size: 14px; line-height: 1.55; }
.tstat__about p + p { margin-top: 12px; }

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

@media (max-width: 640px) {
    .tstat__side { max-width: 140px; }
    .tstat__team { font-size: 12px; }
    .tstat__team .logo-sm { width: 18px; height: 18px; }
    .tstat__tbl td, .tstat__tbl th { padding: 8px 5px; }
    .tstat__bar { height: 22px; }
}
