/* 28.10.2026: /video-online в новом дизайне (templates/tv_online.php, tv_online_board.php; макет
   public/_local_demo/video-online-v2.html). Поверх tv-channel.css (цвета, вкладки, чипы, шторка) и tv-main.css
   (большая карточка #152a4f, карточки справа, заголовки секций, отступы на телефоне) - страница в .tvc .tvm .tvo */

/* большая карточка: логотипы всех каналов эфира крупнее, лига - строкой под названием матча */
.tvo .tvm-hero-ch { flex-wrap: wrap; gap: 10px; }
.tvo .tvm-hero-ch .tvm-tile { width: 64px; height: 64px; border-radius: 14px; }
.tvo .tvm-hero-ch .tvm-tile img { max-width: 52px; max-height: 40px; }
.tvo .tvm-hero-top .tvm-hero-time { color: #bccbe6; font-weight: 600; }
.tvo-hero-league { display: block; margin-top: 6px; font-size: 15px; font-weight: 500; color: #bccbe6; }
.tvo .tvm-hero-pt { margin-bottom: 0; }

/* карточки справа: время, отсчёт, логотипы */
.tvo .tvo-sc { padding: 14px; }
.tvo-sc-rel { font-size: 13px; color: var(--tvc-muted); }
.tvo-sc-rel.is-now { color: var(--tvc-red); font-weight: 700; }
.tvo-sc-logos { display: flex; gap: 6px; margin-left: auto; }
.tvo .tvo-sc-logos .tvm-tile { margin-left: 0; width: 46px; height: 36px; background: #fff; }
.tvo .tvo-sc-logos .tvm-tile img { max-width: 36px; max-height: 26px; }

/* табло дня */
.tvo-board-h { margin-top: 24px; }
.tvo-tz { font-size: 14px; color: var(--tvc-muted); white-space: nowrap; }
.tvo-panels.is-loading { opacity: .5; }
.tvo-empty { padding: 18px 0; font-size: 15px; color: var(--tvc-muted); }
.tvo-toggle-past { font: inherit; display: block; width: 100%; margin: 0 0 4px; padding: 12px 0; border: 0; border-bottom: 1px dashed var(--tvc-border); background: none; color: var(--tvc-muted); font-size: 14px; text-align: left; cursor: pointer; }
.tvo-toggle-past[hidden], .tvo-panel.past-open .tvo-toggle-past { display: none; }

.tvo-row { display: grid; grid-template-columns: 76px minmax(0, 1fr); }
.tvo-row.is-off, .tvo-panel:not(.past-open) .tvo-row.is-past { display: none; }
.tvo-hl { padding-top: 16px; font-size: 22px; font-weight: 800; line-height: 1; color: #c3c7cf; font-variant-numeric: tabular-nums; visibility: hidden; }
.tvo-row.is-first .tvo-hl { visibility: visible; }
.tvo-row.is-now .tvo-hl { color: var(--tvc-text); }
.tvo-ev { position: relative; display: grid; grid-template-columns: 112px minmax(0, 1fr) 230px 104px; gap: 16px; align-items: center; padding: 14px 0 14px 18px; border-left: 2px solid var(--tvc-line); border-bottom: 1px solid var(--tvc-line); }
.tvo-ev::before { content: ''; position: absolute; left: -7px; top: 22px; width: 12px; height: 12px; border-radius: 50%; background: #fff; border: 2px solid var(--tvc-border); box-sizing: border-box; }
.tvo-row.is-now .tvo-ev { background: linear-gradient(90deg, #fdeaea, #fff 70%); }
.tvo-row.is-now .tvo-ev::before { background: var(--tvc-red); border-color: var(--tvc-red); }
.tvo-row.is-past .tvo-ev { color: var(--tvc-muted); }

.tvo-tm { font-size: 18px; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; }
.tvo-tm small { display: block; margin-top: 4px; font-size: 12px; font-weight: 400; color: var(--tvc-muted); white-space: nowrap; }
.tvo-tm .tvm-night { display: inline; margin-top: 0; }
.tvo-row.is-now .tvo-rel { color: var(--tvc-red); font-weight: 700; }
.tvo-what { min-width: 0; }
.tvo-teams { display: flex; flex-direction: column; gap: 2px; }
.tvo-teams b { font-size: 16px; line-height: 1.25; }
.tvo-league { display: block; margin-top: 4px; font-size: 13px; color: var(--tvc-muted); }
.tvo-show { font-size: 15px; line-height: 1.35; color: var(--tvc-muted); }
.tvo-row.is-past .tvo-teams b { font-weight: 600; }

.tvo-where { display: flex; flex-direction: column; gap: 6px; min-width: 0; font-size: 13px; color: var(--tvc-muted); }
.tvo-logos { display: flex; flex-wrap: wrap; gap: 6px; }
.tvo .tvo-logo { display: inline-flex; align-items: center; justify-content: center; width: 58px; height: 44px; border-radius: 10px; background: #f6f7f9; border: 1px solid var(--tvc-line); }
.tvo-logo img { max-width: 46px; max-height: 32px; width: auto; height: auto; object-fit: contain; }
.tvo .tvo-names a { color: var(--tvc-muted); text-decoration: none; }
.tvo .tvo-names a:hover { color: var(--tvc-link); text-decoration: underline; }
.tvo-act { justify-self: end; }
.tvo .tvo-cta { display: inline-block; font-size: 14px; font-weight: 700; color: #fff; background: var(--tvc-green); padding: 9px 14px; border-radius: 10px; text-decoration: none; white-space: nowrap; }
.tvo .tvo-cta:hover { filter: brightness(1.05); }

/* линия «сейчас»: время того же размера, что метки часов */
.tvo-now { display: grid; grid-template-columns: 76px minmax(0, 1fr); align-items: center; margin: 2px 0; }
.tvo-now b { font-size: 22px; line-height: 1; font-weight: 800; color: var(--tvc-red); font-variant-numeric: tabular-nums; }
.tvo-now i { position: relative; display: block; height: 2px; background: var(--tvc-red); }
.tvo-now i::before { content: ''; position: absolute; left: -6px; top: -5px; width: 12px; height: 12px; border-radius: 50%; background: var(--tvc-red); }
.tvo-panel:not([data-today]) .tvo-now { display: none; }

/* ссылка на телепрограмму всех каналов */
.tvo .tvo-tvprog { display: inline-flex; align-items: center; gap: 8px; margin: 22px 0 6px; padding: 12px 18px; border: 1px solid var(--tvc-border); border-radius: 12px; color: var(--tvc-text); font-weight: 700; text-decoration: none; }
.tvo .tvo-tvprog::after { content: ''; width: 8px; height: 8px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg); }
.tvo .tvo-tvprog:hover { border-color: var(--tvc-text); }

.tvo .tvo-cta:focus-visible, .tvo .tvo-names a:focus-visible, .tvo-toggle-past:focus-visible, .tvo .tvo-tvprog:focus-visible { outline: 2px solid var(--tvc-link); outline-offset: 2px; }

@media screen and (max-width: 900px) {
    .tvo-ev { grid-template-columns: 104px minmax(0, 1fr) auto; }
    .tvo-where { grid-column: 2 / 4; flex-direction: row; align-items: center; flex-wrap: wrap; }
    .tvo-act { grid-column: 3; grid-row: 1; }
}
@media screen and (max-width: 767px) {
    .tvo .tvm-hero-ch .tvm-tile { width: 54px; height: 54px; }
    .tvo .tvm-hero-ch .tvm-tile img { max-width: 44px; max-height: 34px; }
    .tvo .tvm-sec-h h2 { text-align: left; } /* общий стиль сайта центрирует h2 на мобильных */
    .tvo-tz { display: none; }
    .tvo-toggle-past { padding-left: 10px; }
    .tvo-row, .tvo-now { grid-template-columns: 52px minmax(0, 1fr); }
    .tvo-hl { padding: 18px 0 0 6px; font-size: 13px; }
    .tvo-now b { padding-left: 6px; font-size: 13px; }
    .tvo-ev { grid-template-columns: 76px minmax(0, 1fr); gap: 8px 10px; padding-left: 12px; padding-right: 8px; }
    .tvo-tm small { white-space: normal; }
    .tvo-tm { font-size: 16px; }
    .tvo-where { grid-column: 2; }
    .tvo .tvo-logo { width: 48px; height: 36px; }
    .tvo-logo img { max-width: 38px; max-height: 26px; }
    .tvo-act { grid-column: 2; grid-row: auto; justify-self: start; }
    .tvo .tvo-cta { padding: 7px 12px; font-size: 13px; }
    .tvo .tvo-tvprog { margin-left: 10px; margin-right: 10px; }
}

/* 28.10.2026: заголовок наборов карточек видов спорта (без H2, вид как у H2 секции) */
.tvo-cards-h { margin: 0; font-size: 20px; line-height: 1.25; font-weight: 800; }
@media screen and (max-width: 767px) { .tvo-cards-h { font-size: 18px; } }

/* 28.10.2026: поиск по табло - при поиске видны и прошедшие (кнопка «Показать прошедшие» не нужна) */
.tvo-board-h { align-items: center; }
.tvo .tvo-search { flex: 0 1 360px; margin: 0; min-height: 42px; }
.tvo .tvo-search input { height: 40px; }
.tvo-panel.is-search .tvo-row.is-past:not(.is-off) { display: grid; }
.tvo-panel.is-search .tvo-toggle-past { display: none; }
.tvo-empty a { text-decoration: underline; }
@media screen and (max-width: 767px) {
    .tvo .tvo-board-h { flex-direction: column; align-items: stretch; gap: 10px; }
    .tvo .tvo-search { flex: none; max-width: none; }
    /* 28.10.2026: под полем поиска до текста было 26px (12 под строкой заголовка + 12 у кнопки «Показать прошедшие»),
       над ним 10 - выравниваем до ~10 */
    .tvo .tvo-board-h { margin-bottom: 4px; }
    .tvo .tvo-toggle-past { padding-top: 4px; }
}

/* 28.10.2026: красная метка «прямой эфир» у H1 (отличие от программы каналов /video-tvprog) */
.tvo-h1-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; }
.tvo-h1-live { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px 5px 9px; border-radius: 8px; background: var(--tvc-red); color: #fff; font-size: 14px; font-weight: 700; line-height: 1.2; white-space: nowrap; }
.tvo-h1-live i { width: 8px; height: 8px; border-radius: 50%; background: #fff; }
@media (prefers-reduced-motion: no-preference) {
    .tvo-h1-live i { animation: tvo-blink 1.6s ease-in-out infinite; }
    @keyframes tvo-blink { 50% { opacity: .35; } }
}
@media screen and (max-width: 767px) {
    /* метка - в строке заголовка после последнего слова, без отдельной строки (экономим экран) */
    .tvo .tvo-h1-row { display: block; padding: 0 10px; }
    .tvo .tvo-h1-row .tvc-h1 { display: inline; padding: 0; }
    .tvo-h1-live { margin-left: 6px; vertical-align: 3px; font-size: 11px; padding: 3px 8px 3px 7px; gap: 5px; }
    .tvo-h1-live i { width: 6px; height: 6px; }
}

/* === 29.10.2026: страница канала /video-online/{канал} (templates/tv_online_channel.php, макет утверждён 29.10,
   public/_local_demo/vo-channel-match-tv.html) - страница в .tvc .tvm .tvo .tvoc === */
.tvoc .tvc-head { margin-bottom: 6px; }
.tvoc .tvoc-h1 { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; }
.tvoc .tvoc-h1 .tvc-h1 { margin: 0; }
.tvoc .tvc-sub { margin-bottom: 18px; }
/* синяя карточка и «Где смотреть» рядом */
.tvoc-top { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 14px; margin-bottom: 8px; }
.tvoc .tvm-hero { justify-content: space-between; }
.tvoc .tvoc-hero-title { margin-top: 14px; }
.tvoc .tvoc-live { margin-left: 10px; vertical-align: 2px; } /* «прямой эфир» у турнира - прямая трансляция, не повтор */
.tvoc-next { display: flex; flex-direction: column; gap: 2px; }
.tvoc-next-h { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: #bccbe6; margin-bottom: 4px; }
.tvoc .tvoc-next-row { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 10px; align-items: baseline; padding: 8px 12px; border-radius: 10px; background: #1c355f; color: #fff; text-decoration: none; font-size: 15px; }
.tvoc .tvoc-next-row:hover { background: #24406f; }
.tvoc-next-row b { font-variant-numeric: tabular-nums; }
.tvoc-next-row span { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tvoc-next-row em { font-style: normal; font-size: 13px; font-weight: 700; color: #6fd39a; }
.tvoc-cur { font-size: 13px; color: #bccbe6; border-top: 1px solid #2f4c7c; padding-top: 12px; }
.tvoc-cur b { color: #fff; font-weight: 600; }
/* «Где смотреть» - главный блок интента страницы */
.tvoc-watch { border: 1px solid var(--tvc-border); border-radius: 18px; padding: 20px 22px; background: #fff; display: flex; flex-direction: column; gap: 14px; scroll-margin-top: 80px; }
.tvoc .tvoc-watch h2 { margin: 0; font-size: 20px; line-height: 1.25; font-weight: 800; text-align: left; }
.tvoc-wl { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 4px 12px; align-items: start; }
.tvoc-wi { grid-row: span 2; width: 40px; height: 40px; border-radius: 12px; background: #eef3fb; color: #152a4f; display: flex; align-items: center; justify-content: center; }
.tvoc-wt { font-weight: 700; font-size: 15px; line-height: 1.3; }
.tvoc-wn { font-size: 13px; color: var(--tvc-muted); line-height: 1.4; }
.tvoc-free { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 5px; background: #e6f4ec; color: #1f7a43; font-size: 12px; font-weight: 700; vertical-align: 1px; }
.tvoc .tvoc-watch-btn { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 16px; border-radius: 12px; background: #152a4f; color: #fff; font-weight: 700; text-decoration: none; }
.tvoc .tvoc-watch-btn:hover { background: #24406f; }
.tvoc-note { font-size: 12px; color: var(--tvc-muted); line-height: 1.45; margin: 0; }
/* 29.10.2026: у канала нет предстоящих прямых эфиров (Первый, НТВ) - синей карточки нет, «Где смотреть» во всю ширину,
   способы просмотра в ряд (раньше блок занимал левые 2/3, справа пусто) */
.tvoc-top > .tvoc-watch:only-child { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px 24px; }
.tvoc-top > .tvoc-watch:only-child h2, .tvoc-top > .tvoc-watch:only-child .tvoc-note { grid-column: 1 / -1; }
.tvoc-top > .tvoc-watch:only-child .tvoc-watch-btn { grid-column: 1 / -1; justify-self: start; padding: 12px 28px; }
/* табло канала: вместо колонки каналов - «также на …» */
.tvoc .tvo-ev { grid-template-columns: 112px minmax(0, 1fr) 190px 104px; }
.tvoc .tvoc-also { display: block; font-size: 13px; color: var(--tvc-muted); }
.tvoc .tvoc-also a { color: var(--tvc-muted); }
.tvoc .tvoc-also a:hover { color: var(--tvc-link); }
.tvoc .tvo-board-h { margin-bottom: 4px; }
.tvoc .tvc-day small { font-weight: 400; opacity: .75; }
/* кнопки «Все прямые трансляции» и «Программа {канала}» - общая пара .tvc-pair (tv-channel.css, 29.10.2026) */
.tvoc .tvoc-next-row:focus-visible, .tvoc .tvoc-watch-btn:focus-visible { outline: 2px solid var(--tvc-link); outline-offset: 2px; }
@media screen and (max-width: 900px) {
    .tvoc-top { grid-template-columns: minmax(0, 1fr); }
    .tvoc .tvo-ev { grid-template-columns: 104px minmax(0, 1fr) auto; }
    .tvoc .tvoc-also { grid-column: 2 / 4; }
}
@media screen and (max-width: 767px) {
    /* шапка: логотип и H1 в строку, подпись - во всю ширину под ними */
    .tvoc .tvc-head { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 8px 12px; padding: 0 10px; }
    .tvoc .tvc-head > div { display: contents; }
    .tvoc .tvc-head .tvc-logo { margin-left: 0; height: 40px; }
    .tvoc .tvc-head .tvc-sub { grid-column: 1 / -1; margin-bottom: 12px; padding: 0; }
    .tvoc .tvoc-h1 .tvc-h1 { font-size: 22px; text-align: left; padding: 0; }
    .tvoc-next { display: none; }
    .tvoc .tvo-ev { grid-template-columns: 76px minmax(0, 1fr); }
    .tvoc .tvoc-also { grid-column: 2; }
    .tvoc-watch { margin: 0 0 4px; padding: 16px; }
    .tvoc .tvoc-watch h2 { font-size: 18px; }
    .tvoc .tvoc-mbar { position: static; margin: 0 10px 8px; }
    .tvoc .tvc-mbar-day { flex: 1; }
}
