/* Route-specific styles for /tournaments/ and /tournaments/{tournament}/.
 * Extracted from pages-teams.css in original source order.
 */

.sp-teams-page {
    display: grid;
    gap: clamp(28px, 4vw, 48px);
    padding-bottom: 40px;
}

.sp-teams-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(28px, 5vw, 56px);
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-lg);
    background: var(--sp-gradient-teams-hero);
    box-shadow: var(--sp-shadow-soft);
}

.sp-teams-hero::after {
    content: "";
    position: absolute;
    inset: auto -80px -120px auto;
    width: 320px;
    height: 320px;
    border-radius: var(--sp-radius-pill);
    background: var(--sp-white-04);
    pointer-events: none;
}

.sp-teams-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    width: max-content;
    margin-bottom: 14px;
    padding: 8px 12px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-accent-alpha-08);
    color: var(--sp-accent-text);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-button);
}

.sp-teams-hero h1 {
    max-width: 780px;
    margin: 0;
    font-size: var(--sp-fs-teams-title);
    line-height: .95;
    letter-spacing: -.065em;
}

.sp-teams-hero p {
    max-width: 760px;
    margin: 18px 0 0;
    color: var(--sp-text-soft);
    font-size: var(--sp-fs-body);
}

.sp-teams-league {
    display: grid;
    gap: 18px;
}

.sp-teams-league[hidden] {
    display: none !important;
}

.sp-teams-league__head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--sp-card-border);
}

.sp-teams-league__label {
    display: inline-flex;
    margin-bottom: 8px;
    color: var(--sp-accent);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-black);
    letter-spacing: .08em;
    text-transform: uppercase;
}

.sp-teams-league h2 {
    margin: 0;
    font-size: var(--sp-fs-teams-section-title);
    line-height: 1.05;
    letter-spacing: -.045em;
}

.sp-teams-league__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    height: 48px;
    padding: 0 14px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-white-045);
    color: var(--sp-muted);
    font-weight: var(--sp-fw-black);
}

@media (max-width: 767px) {
    .sp-teams-page {
        gap: 24px;
    }

    .sp-teams-hero {
        padding: 26px 20px;
    }

    .sp-teams-league__head {
        align-items: start;
    }}

/* Когда нажата кнопка Карта */

.sp-teams-page.is-map-only .sp-teams-map-section {
    margin-top: 0;
}


/* Ссылки на автоматические страницы лиг */
.sp-teams-hero__eyebrow a,
.sp-teams-league__label--link,
.sp-teams-league__title-link {
    color: inherit;
    text-decoration: none;
}

.sp-teams-hero__eyebrow a:hover,
.sp-teams-league__label--link:hover,
.sp-teams-league__title-link:hover {
    color: var(--sp-accent);
}

.sp-teams-page--league .sp-teams-hero__eyebrow,
.sp-matches-page--league .sp-teams-hero__eyebrow {
    gap: 8px;
}

.sp-season-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    margin: 14px 0 24px;
    padding: 12px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-md);
    background: var(--sp-white-035);
}

.sp-season-filter__label {
    color: var(--sp-muted);
    font-size: var(--sp-fs-sm);
    font-weight: var(--sp-fw-bold);
}

.sp-season-filter__select {
    min-height: 44px;
    min-width: min(320px, 100%);
    padding: 0 42px 0 14px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-bg-soft);
    color: var(--sp-text);
    font: inherit;
    font-weight: var(--sp-fw-bold);
    outline: none;
}

.sp-season-filter__select:focus {
    border-color: var(--sp-card-border-hover);
    box-shadow: 0 0 0 3px var(--sp-accent-alpha-14);
}


.sp-matches-filter-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 14px 0 24px;
}

.sp-matches-filter-form .sp-season-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    margin: 0;
    padding: 12px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-md);
    background: var(--sp-white-035);
}

.sp-matches-filter-form .sp-season-filter__label {
    flex: 0 0 auto;
    color: var(--sp-muted);
    font-size: var(--sp-fs-sm);
    font-weight: var(--sp-fw-norm);
}

.sp-matches-filter-form .sp-season-filter__select {
    flex: 1 1 220px;
    width: 100%;
    min-width: 0;
    min-height: 44px;
    padding: 0 42px 0 14px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-bg-soft);
    color: var(--sp-text);
    font: inherit;
    font-weight: var(--sp-fw-norm);
    outline: none;
}

.sp-matches-filter-form .sp-season-filter__select:focus {
    border-color: var(--sp-card-border-hover);
    box-shadow: 0 0 0 3px var(--sp-accent-alpha-14);
}

.sp-matches-filter-form noscript {
    grid-column: 1 / -1;
}

@media (max-width: 767px) {
    .sp-matches-filter-form {
        grid-template-columns: 1fr;
    }

    .sp-matches-filter-form .sp-season-filter {
        align-items: stretch;
        flex-direction: column;
    }

    .sp-matches-filter-form .sp-season-filter__select {
        flex-basis: auto;
        width: 100%;
    }}


.sp-tournaments-filter-form {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.sp-tournaments-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.sp-tournament-card {
    min-width: 0;
}

.sp-tournament-card__link {
    display: flex;
    flex-direction: column;
    gap: 12px;
    height: 100%;
    padding: 18px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-lg);
    background:
        radial-gradient(circle at 20% 0%, var(--sp-accent-alpha-14), transparent 34%),
        var(--sp-white-035);
    color: var(--sp-text);
    text-decoration: none;
    transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.sp-tournament-card__link:hover {
    transform: translateY(-2px);
    border-color: var(--sp-card-border-hover);
    background:
        radial-gradient(circle at 20% 0%, var(--sp-accent-alpha-18), transparent 38%),
        var(--sp-white-05);
}

.sp-tournament-card__top {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--sp-muted);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-bold);
    text-transform: uppercase;
    letter-spacing: .04em;
}

.sp-tournament-card h2 {
    margin: 0;
    font-size: clamp(20px, 2vw, 26px);
    line-height: 1.08;
}

.sp-tournament-card__meta {
    color: var(--sp-accent);
    font-size: var(--sp-fs-sm);
    font-weight: var(--sp-fw-bold);
}

.sp-tournament-card__text {
    color: var(--sp-muted);
    font-size: var(--sp-fs-sm);
    line-height: 1.55;
}

.sp-tournament-card__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-top: auto;
}

.sp-tournament-card__stats span {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 10px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-md);
    background: var(--sp-bg-soft);
    color: var(--sp-muted);
    font-size: var(--sp-fs-xs);
}

.sp-tournament-card__stats strong {
    color: var(--sp-text);
    font-size: 20px;
    line-height: 1;
}

.sp-tournament-card__more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    margin-top: 2px;
    border-radius: var(--sp-radius-pill);
    background: var(--sp-accent);
    color: var(--sp-on-accent);
    font-weight: var(--sp-fw-bold);
}

.sp-tournament-summary {
    display: grid;
    gap: 16px;
    margin: 22px 0;
}

.sp-tournament-summary__main {
    display: block;
    padding: 18px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-lg);
    background: var(--sp-white-035);
}

.sp-tournament-summary__image img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--sp-radius-md);
}

.sp-tournament-description {
    color: var(--sp-muted);
    line-height: 1.65;
}

.sp-tournament-description p:first-child {
    margin-top: 0;
}

.sp-tournament-description p:last-child {
    margin-bottom: 0;
}

.sp-tournament-facts {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin: 18px 0 0;
}

.sp-tournament-facts div,
.sp-tournament-stats div {
    padding: 12px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-md);
    background: var(--sp-bg-soft);
}

.sp-tournament-facts dt {
    margin: 0 0 4px;
    color: var(--sp-muted);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-norm);
    text-transform: uppercase;
    letter-spacing: .04em;
}

.sp-tournament-facts dd {
    margin: 0;
    color: var(--sp-text);
    font-weight: var(--sp-fw-norm);
}

.sp-tournament-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.sp-tournament-stats strong {
    display: block;
    color: var(--sp-text);
    font-size: clamp(26px, 3vw, 42px);
    line-height: 1;
}

.sp-tournament-stats span {
    display: block;
    margin-top: 5px;
    color: var(--sp-muted);
    font-size: var(--sp-fs-sm);
    font-weight: var(--sp-fw-norm);
}

.sp-tournament-teams,
.sp-tournament-matches {
    margin-top: 22px;
}

.sp-tournament-teams__grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}


@media (max-width: 1100px) {
    .sp-tournaments-filter-form {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sp-tournaments-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sp-tournament-summary__main {
        grid-template-columns: 1fr;
    }

    .sp-tournament-facts,
    .sp-tournament-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sp-tournament-teams__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }}

@media (max-width: 767px) {
    .sp-tournaments-filter-form,
    .sp-tournaments-grid,
    .sp-tournament-facts,
    .sp-tournament-stats,
    .sp-tournament-teams__grid {
        grid-template-columns: 1fr;
    }

    .sp-tournament-card__stats {
        grid-template-columns: 1fr;
    }

    .sp-tournament-summary__main {
        padding: 14px;
    }}


@media (max-width: 1100px) {
    .sp-tournament-facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }}

@media (max-width: 767px) {
    .sp-tournament-facts {
        grid-template-columns: 1fr;
    }}


/* Турниры: приводим карточки к общему стилю сайта */
.sp-tournament-card__link {
    border-color: var(--sp-card-border);
    background:
        radial-gradient(320px 150px at 10% 0%, var(--sp-accent-2-alpha-09), transparent 62%),
        var(--sp-gradient-card);
    box-shadow: var(--sp-shadow-soft);
}

.sp-tournament-card__link:hover {
    transform: translateY(-3px);
    border-color: var(--sp-card-border-hover);
    background:
        radial-gradient(340px 170px at 10% 0%, var(--sp-accent-alpha-12), transparent 64%),
        var(--sp-gradient-card-hover);
}

/* Кнопка "Открыть турнир" — в стиле кнопок на главной в блоке лиг */
.sp-tournament-card__more {
    display: inline-flex;
    width: fit-content;
    min-height: 34px;
    align-items: center;
    justify-content: center;
    margin-top: auto;
    padding: 8px 12px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-white-04);
    color: var(--sp-text-soft);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-bold);
    line-height: 1;
    white-space: nowrap;
    text-decoration: none;
    transition:
        transform var(--sp-transition-fast),
        color var(--sp-transition-fast),
        border-color var(--sp-transition-fast),
        background var(--sp-transition-fast);
}

.sp-tournament-card__link:hover .sp-tournament-card__more {
    transform: translateY(-1px);
    border-color: var(--sp-card-border-hover);
    background: var(--sp-accent-alpha-08);
    color: var(--sp-accent);
}

.sp-league-tournament-card .sp-tournament-card__link h3 {
    margin: 0;
    color: var(--sp-text);
    font-size: clamp(20px, 2vw, 26px);
    line-height: 1.08;
}


.sp-tournament-standings,
.sp-tournament-playoff {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin-top: 22px;
}

.sp-standings-tabs,
.sp-playoff-stage-nav {
    display: flex;
    gap: 8px;
    max-width: 100%;
    margin: 12px 0 16px;
    overflow-x: auto;
    scrollbar-width: none;
}

.sp-standings-tabs::-webkit-scrollbar,
.sp-playoff-stage-nav::-webkit-scrollbar {
    display: none;
}

.sp-standings-tabs__button,
.sp-playoff-stage-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 8px 12px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-white-04);
    color: var(--sp-text-soft);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-bold);
    white-space: nowrap;
    text-decoration: none;
}

.sp-standings-tabs__button:hover,
.sp-standings-tabs__button.is-active,
.sp-playoff-stage-nav a:hover {
    border-color: var(--sp-card-border-hover);
    background: var(--sp-accent-alpha-08);
    color: var(--sp-accent);
}

.sp-playoff-round{
    width: 100%;
    max-width: 100%;
    min-width: 0;
    scroll-margin-top: 96px;
    margin-top: 16px;
    padding: 16px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-lg);
    background: var(--sp-gradient-card);
    box-shadow: var(--sp-shadow-soft);
}

.sp-standings-block__title,
.sp-playoff-round__title {
    margin: 0;
    color: var(--sp-text);
    font-size: clamp(20px, 2vw, 28px);
    line-height: 1.15;
}

.sp-standings-block__hint,
.sp-playoff-intro {
    margin: 8px 0 14px;
    color: var(--sp-muted);
    font-size: var(--sp-fs-sm);
    line-height: 1.5;
}


.sp-playoff-round__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}

.sp-playoff-round__eyebrow {
    display: block;
    margin-bottom: 4px;
    color: var(--sp-accent);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-bold);
    text-transform: uppercase;
    letter-spacing: .06em;
}

.sp-playoff-round__count {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 7px 10px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-white-04);
    color: var(--sp-muted);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-bold);
    white-space: nowrap;
}

.sp-playoff-series-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.sp-playoff-series {
    min-width: 0;
    padding: 14px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-lg);
    background: var(--sp-gradient-card);
    box-shadow: var(--sp-shadow-soft);
}

.sp-playoff-series__head {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--sp-card-border);
}

.sp-playoff-series__teams {
    display: grid;
    gap: 7px;
    min-width: 0;
    flex: 1 1 auto;
}

.sp-playoff-series__team {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: var(--sp-muted);
    font-weight: var(--sp-fw-bold);
}

.sp-playoff-series__team a,
.sp-playoff-series__team span {
    min-width: 0;
    overflow: hidden;
    color: inherit;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sp-playoff-series__team a:hover {
    color: var(--sp-accent);
}

.sp-playoff-series__team.is-winner {
    color: var(--sp-text);
}

.sp-playoff-series__team strong {
    color: var(--sp-text);
}

.sp-playoff-series__score {
    display: grid;
    place-items: center;
    min-width: 70px;
    min-height: 44px;
    padding: 6px 10px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-md);
    background: var(--sp-accent-alpha-08);
    color: var(--sp-accent);
}

.sp-playoff-series__score span {
    color: var(--sp-muted);
    font-size: var(--sp-fs-xxs, 11px);
    font-weight: var(--sp-fw-bold);
    text-transform: uppercase;
    letter-spacing: .04em;
}

.sp-playoff-series__score strong {
    color: var(--sp-accent);
    font-size: 18px;
    font-weight: var(--sp-fw-black);
}

.sp-playoff-series__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 10px;
}

.sp-playoff-series__meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 8px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-pill);
    background: var(--sp-white-04);
    color: var(--sp-muted);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-bold);
}

.sp-playoff-series__meta strong {
    margin-left: 4px;
    color: var(--sp-text);
}

.sp-playoff-games {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.sp-playoff-game {
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr) 74px auto;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    padding: 8px 10px;
    border: 1px solid var(--sp-card-border);
    border-radius: var(--sp-radius-md);
    background: var(--sp-bg-soft);
    color: var(--sp-text);
    text-decoration: none;
}

.sp-playoff-game:hover {
    border-color: var(--sp-card-border-hover);
    background: var(--sp-accent-alpha-08);
}

.sp-playoff-game--disabled {
    opacity: .65;
}

.sp-playoff-game__num {
    color: var(--sp-muted);
    font-size: var(--sp-fs-xs);
    font-weight: var(--sp-fw-bold);
}

.sp-playoff-game__teams {
    min-width: 0;
    overflow: hidden;
    font-size: var(--sp-fs-sm);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sp-playoff-game__date {
    color: var(--sp-muted);
    font-size: var(--sp-fs-xs);
    text-align: right;
    white-space: nowrap;
}

.sp-playoff-game strong {
    font-weight: var(--sp-fw-black);
    white-space: nowrap;
}

.sp-playoff-game em {
    margin-left: 4px;
    color: var(--sp-accent);
    font-size: var(--sp-fs-xs);
    font-style: normal;
}

@media (max-width: 1100px) {
    .sp-playoff-series-grid {
        grid-template-columns: 1fr;
    }}

@media (max-width: 767px) {

    .sp-playoff-round,
.sp-playoff-series{
        padding: 12px;
    }


    .sp-playoff-round__head {
        align-items: flex-start;
        flex-direction: column;
    }

    .sp-playoff-series__head {
        align-items: stretch;
        flex-direction: column;
    }

    .sp-playoff-series__score {
        width: 100%;
    }

    .sp-playoff-game {
        grid-template-columns: 1fr auto;
        gap: 6px 10px;
    }

    .sp-playoff-game__num {
        grid-column: 1 / 2;
    }

    .sp-playoff-game__date {
        grid-column: 2 / 3;
    }

    .sp-playoff-game__teams {
        grid-column: 1 / -1;
        white-space: normal;
    }

    .sp-playoff-game strong {
        grid-column: 1 / -1;
        justify-self: start;
    }}


/* Компактный блок информации о турнире на мобильных */
@media (max-width: 767px) {
    .sp-tournament-summary {
        gap: 10px;
        margin: 14px 0;
    }

    .sp-tournament-summary__main {
        padding: 12px;
    }

    .sp-tournament-description {
        margin-bottom: 10px;
        font-size: var(--sp-fs-sm);
        line-height: 1.45;
    }

    .sp-tournament-facts {
        display: flex !important;
        grid-template-columns: none !important;
        gap: 8px;
        max-width: 100%;
        margin: 0;
        padding-bottom: 2px;
        overflow-x: auto;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .sp-tournament-facts::-webkit-scrollbar {
        display: none;
    }

    .sp-tournament-facts div {
        display: inline-flex;
        flex: 0 0 auto;
        align-items: center;
        gap: 6px;
        min-height: 34px;
        padding: 7px 10px;
        border-radius: var(--sp-radius-pill);
        white-space: nowrap;
    }

    .sp-tournament-facts dt {
        margin: 0;
        font-size: 10px;
        line-height: 1;
    }

    .sp-tournament-facts dd {
        margin: 0;
        font-size: 12px;
        line-height: 1;
    }

    .sp-tournament-stats {
        display: grid !important;
        grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
        gap: 7px;
    }

    .sp-tournament-stats div {
        padding: 8px 5px;
        text-align: center;
        border-radius: var(--sp-radius-md);
    }

    .sp-tournament-stats strong {
        font-size: 19px;
        line-height: 1;
    }

    .sp-tournament-stats span {
        margin-top: 3px;
        font-size: 10px;
        line-height: 1.15;
    }}
/* =========================================================
   ShaibaPRO: fix mobile overflow on tournament pages
   Added after inspecting theme 0906-2.
   Keeps tournament tables as horizontal-scroll tables on phones,
   without cutting the right edge of the block.
   ========================================================= */
@media (max-width: 767px) {
    .sp-tournament-single-page,
    .sp-tournament-single-page * {
        box-sizing: border-box;
    }

    .sp-tournament-single-page {
        max-width: 100%;
        overflow-x: clip;
    }

    .sp-tournament-summary,
.sp-tournament-summary__main,
.sp-tournament-summary__content,
.sp-tournament-standings,
.sp-tournament-playoff,
.sp-playoff-round,
.sp-playoff-series{
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    .sp-tournament-summary__main,
.sp-playoff-round,
.sp-playoff-series{
        overflow: hidden;
    }

    .sp-tournament-facts,
    .sp-standings-tabs,
    .sp-playoff-stage-nav {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-x: contain;
    }

    .sp-tournament-facts div {
        max-width: 82vw;
    }

    .sp-tournament-facts dd {
        max-width: 62vw;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .sp-tournament-stats {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    .sp-tournament-stats div {
        min-width: 0;
    }


    .sp-playoff-games,
    .sp-playoff-game,
    .sp-playoff-game__teams {
        min-width: 0;
        max-width: 100%;
    }}

/* =========================================================
   ShaibaPRO: финальная очистка визуальных блоков турнира
   ========================================================= */
.sp-tournament-summary__main{
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

.sp-tournament-summary__main {
    margin: 0 !important;
}


.sp-standings-block__title {
    margin: 0 0 12px !important;
}

@media (max-width: 767px) {
    .sp-tournament-summary__main{
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
    }}

/* =========================================================
   ShaibaPRO: фильтры матчей и турниров в одну строку
   ========================================================= */
.sp-matches-filter-form,
.sp-tournaments-filter-form {
    display: grid !important;
    grid-auto-flow: column !important;
    grid-auto-columns: minmax(0, 1fr) !important;
    grid-template-columns: none !important;
    gap: 10px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 14px 0 24px;
}

.sp-matches-filter-form .sp-season-filter,
.sp-tournaments-filter-form .sp-season-filter {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    margin: 0;
}

.sp-matches-filter-form .sp-season-filter__label,
.sp-tournaments-filter-form .sp-season-filter__label {
    flex: 0 0 auto;
    white-space: nowrap;
}

.sp-matches-filter-form .sp-season-filter__select,
.sp-tournaments-filter-form .sp-season-filter__select {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
}

/* =========================================================
   ShaibaPRO: статистика карточки турнира всегда в одну строку
   ========================================================= */
.sp-tournament-card__stats {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px;
}

.sp-tournament-card__stats span {
    min-width: 0;
}

@media (max-width: 767px) {
    .sp-matches-filter-form,
    .sp-tournaments-filter-form {
        display: grid !important;
        grid-auto-flow: column !important;
        grid-auto-columns: minmax(0, 1fr) !important;
        grid-template-columns: none !important;
        gap: 5px;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        margin: 8px 0 14px;
    }

    .sp-matches-filter-form .sp-season-filter,
    .sp-tournaments-filter-form .sp-season-filter {
        display: block !important;
        min-width: 0;
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
    }

    .sp-matches-filter-form .sp-season-filter__label,
    .sp-tournaments-filter-form .sp-season-filter__label {
        display: none !important;
    }

    .sp-matches-filter-form .sp-season-filter__select,
    .sp-tournaments-filter-form .sp-season-filter__select {
        width: 100% !important;
        min-width: 0 !important;
        min-height: 36px;
        padding: 0 24px 0 8px;
        border-radius: var(--sp-radius-pill);
        font-size: 13px;
        line-height: 1.1;
        font-weight: var(--sp-fw-bold);
        white-space: nowrap;
        text-overflow: ellipsis;
    }

    .sp-tournament-card__stats {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        gap: 5px;
    }

    .sp-tournament-card__stats span {
        min-width: 0;
        padding: 7px 4px;
        border-radius: var(--sp-radius-sm);
        text-align: center;
    }

    .sp-tournament-card__stats strong {
        font-size: 17px;
        line-height: 1;
    }

    .sp-tournament-card__stats span {
        font-size: 10px;
        line-height: 1.12;
    }}

/* =========================================================
   Touch devices: prevent sticky hover transforms after tap
   ========================================================= */
@media (hover:none), (pointer:coarse) {
    .sp-teams-filter__button:hover,
    .sp-tournament-card__link:hover,
    .sp-tournament-card__link:hover .sp-tournament-card__more,
    .sp-league-card:hover,
    .sp-league-card__links a:hover,
    .sp-league-quick-links a:hover {
        transform: none;
    }}


/* =========================================================
   ShaibaPRO: подсветка команд в турнирной таблице
   ========================================================= */


/* =========================================================
   Tournament matches: SEO-friendly infinite scroll
   ========================================================= */

.sp-tournament-matches-load {
    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 24px;
    margin-top: 14px;

    color: var(--sp-muted);
    font-size: var(--sp-fs-sm);

    opacity: 0;
    visibility: hidden;
}

.sp-tournament-matches-load.is-loading {
    opacity: 1;
    visibility: visible;
}

.sp-tournament-matches-load.is-loading::before {
    content: "";

    width: 16px;
    height: 16px;

    margin-right: 10px;

    border: 2px solid var(--sp-card-border);
    border-top-color: var(--sp-accent);

    border-radius: 50%;

    animation:
        sp-tournament-matches-spin
        .8s
        linear
        infinite;
}

@keyframes sp-tournament-matches-spin {
    to {
        transform: rotate(360deg);
    }
}


/*
 * Точка, за которой следит IntersectionObserver.
 * Пользователь её не видит.
 */
.sp-tournament-matches-sentinel {
    width: 100%;
    height: 1px;
}


/*
 * Обычная HTML-пагинация.
 * Она нужна поисковикам и как fallback.
 */
.sp-tournament-matches-pagination {
    display: flex;
    flex-wrap: wrap;

    gap: 8px;

    margin-top: 18px;
}


/*
 * Если JavaScript работает,
 * пагинацию визуально прячем.
 *
 * Ссылки при этом остаются в HTML.
 */
html.sp-has-js .sp-tournament-matches-pagination {
    position: absolute;

    width: 1px;
    height: 1px;

    margin: -1px;
    padding: 0;

    overflow: hidden;

    clip: rect(0 0 0 0);
    clip-path: inset(50%);

    white-space: nowrap;
}


/*
 * Если infinite scroll сломался,
 * обычная пагинация автоматически
 * станет видимой.
 */
html.sp-has-js
.sp-tournament-matches-pagination:focus-within,

html.sp-has-js
.sp-tournament-matches-pagination.is-fallback-visible {
    position: static;

    width: auto;
    height: auto;

    margin-top: 18px;

    overflow: visible;

    clip: auto;
    clip-path: none;

    white-space: normal;
}


.sp-tournament-matches-pagination a {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height:
        var(--sp-pagination-min-size);

    padding: 8px 12px;

    border:
        1px solid
        var(--sp-card-border);

    border-radius:
        var(--sp-radius-sm);

    background:
        var(--sp-white-04);

    color:
        var(--sp-text);

    font-size:
        var(--sp-fs-sm);

    text-decoration:
        none;
}


.sp-tournament-matches-pagination a:hover,
.sp-tournament-matches-pagination a:focus-visible {
    border-color:
        var(--sp-card-border-hover);

    color:
        var(--sp-accent-text);
}


/* =========================================================
   ShaibaPRO: финальная версия турнирной таблицы
   ========================================================= */


/*
 * Мобильные сводные колонки на desktop не показываем.
 */


/*
 * Если таблица внутри турнира только одна,
 * дополнительный внутренний отступ и заголовок ей не нужны.
 */


/*
 * На странице турнира оставляем нормальный визуальный
 * отступ между H2 и самой таблицей.
 */
.sp-tournament-standings > .sp-standings-block--single {
    margin-top: 18px !important;
}


/* =========================================================
   Mobile standings
   ========================================================= */


/* =========================================================
   ShaibaPRO: мобильные фильтры матчей — горизонтальный скролл
   ========================================================= */
@media (max-width: 767px) {

    /*
     * Сама строка фильтров.
     *
     * На мобильном:
     * - все фильтры идут слева направо;
     * - не переносятся на новую строку;
     * - строку можно листать пальцем;
     * - scrollbar визуально скрыт.
     */
    .sp-matches-filter-form {
        display: flex !important;
        flex-flow: row nowrap !important;
        align-items: stretch;
        justify-content: flex-start;

        gap: 8px;

        width: 100%;
        max-width: 100%;
        min-width: 0;

        margin: 8px 0 14px;

        overflow-x: auto;
        overflow-y: hidden;

        -webkit-overflow-scrolling: touch;
        overscroll-behavior-x: contain;

        scrollbar-width: none;
        -ms-overflow-style: none;
    }

    /*
     * Скрываем scrollbar в Chrome / Safari / Edge.
     */
    .sp-matches-filter-form::-webkit-scrollbar {
        display: none;
        width: 0;
        height: 0;
    }

    /*
     * Каждый отдельный фильтр:
     *
     * Сезон
     * Клуб
     * Статус
     *
     * НЕ растягивается на одинаковую ширину.
     * Его размер определяется содержимым.
     *
     * Но один фильтр никогда не сможет стать
     * шире 80% экрана.
     */
    .sp-matches-filter-form .sp-season-filter {
        display: block !important;

        flex: 0 0 auto !important;

        width: max-content !important;
        max-width: 80vw !important;
        min-width: 0 !important;

        margin: 0 !important;
        padding: 0 !important;

        border: 0 !important;
        border-radius: 0 !important;

        background: transparent !important;
        box-shadow: none !important;
    }

    /*
     * Названия "Сезон", "Клуб", "Статус"
     * на мобильном оставляем скрытыми.
     */
    .sp-matches-filter-form .sp-season-filter__label {
        display: none !important;
    }

    /*
     * Сам select.
     *
     * field-sizing: content заставляет современные
     * браузеры подбирать ширину под отображаемый текст.
     *
     * width: max-content — fallback.
     *
     * Ограничение 80vw защищает от длинных названий клубов.
     */
    .sp-matches-filter-form .sp-season-filter__select {
        display: block;

        flex: none !important;

        width: max-content !important;
        max-width: 80vw !important;
        min-width: 0 !important;

        field-sizing: content;

        min-height: 40px;

        padding: 0 18px 0 12px;

        border-radius: var(--sp-radius-pill);

        font-size: 13px;
        line-height: 1.1;
        font-weight: var(--sp-fw-bold);

        white-space: nowrap;
        text-overflow: ellipsis;
    }}


/* =========================================================
   ShaibaPRO: hero разделов без внешней карточки
   ========================================================= */

.sp-teams-hero {
    padding: 0 !important;
    margin: 0 !important;

    border: 0 !important;
    border-radius: 0 !important;

    background: transparent !important;
    box-shadow: none !important;

    overflow: visible !important;
}

/* Убираем декоративный круг/пятно */
.sp-teams-hero::after {
    display: none !important;
}

@media (max-width: 767px) {

    /*
     * Небольшой единый верхний воздух у hero.
     * Сама большая hero-карточка по-прежнему отсутствует.
     */
    .sp-teams-page > .sp-teams-hero .sp-teams-hero__eyebrow {
        margin-top: 4px;
    }}


/* =========================================================
   ShaibaPRO: match filters = capsule system
   =========================================================
 *
 * Единый вид фильтров матчей:
 *
 * Desktop:
 * [Сезон] [Лига] [Клуб] [Статус]
 *
 * Mobile:
 * та же система, но с горизонтальным скроллом.
 *
 * Размеры, цвета и состояния приходят
 * из 00-settings.css.
 */


/* ---------------------------------------------------------
   Общая строка фильтров
   --------------------------------------------------------- */

.sp-matches-filter-form {
    display: flex !important;
    flex-flow: row wrap !important;
    align-items: center;
    justify-content: flex-start;

    gap:
        var(--sp-filter-select-gap);

    grid-template-columns:
        none !important;

    grid-auto-flow:
        initial !important;

    grid-auto-columns:
        initial !important;

    width: 100%;
    max-width: 100%;
    min-width: 0;

    margin:
        14px 0 24px;
}


/* ---------------------------------------------------------
   Убираем визуальную карточку вокруг каждого select
   --------------------------------------------------------- */

.sp-matches-filter-form .sp-season-filter {
    display: block !important;

    flex:
        0 0 auto !important;

    width:
        max-content !important;

    max-width:
        100% !important;

    min-width:
        0 !important;

    margin:
        0 !important;

    padding:
        0 !important;

    border:
        0 !important;

    border-radius:
        0 !important;

    background:
        transparent !important;

    box-shadow:
        none !important;
}


/* ---------------------------------------------------------
   Label больше не нужен визуально ни на desktop,
   ни на mobile.
   --------------------------------------------------------- */

.sp-matches-filter-form .sp-season-filter__label {
    display:
        none !important;
}


/* ---------------------------------------------------------
   Сам select = капсула
   --------------------------------------------------------- */

.sp-matches-filter-form .sp-season-filter__select {
    display:
        block;

    flex:
        none !important;

    /*
     * Современные браузеры подбирают ширину
     * под текущее значение select.
     */
    field-sizing:
        content;

    width:
        max-content !important;

    max-width:
        min(360px, 100%) !important;

    min-width:
        0 !important;


    /*
     * Высота берётся непосредственно
     * из общей системы капсул.
     */
    min-height:
        var(--sp-filter-select-min-height)
        !important;


    /*
     * Справа оставляем место
     * под системную стрелку select.
     */
    padding:
        0
        var(--sp-filter-select-padding-right)
        0
        var(--sp-filter-select-padding-left)
        !important;


    /*
     * Одна и та же обводка постоянно.
     */
    border:
        1px solid
        var(--sp-filter-select-border)
        !important;

    border-radius:
        var(--sp-filter-select-radius)
        !important;


    background:
        var(--sp-filter-select-bg)
        !important;

    color:
        var(--sp-filter-select-text)
        !important;


    font-family:
        var(--sp-font-sans);

    font-size:
        var(--sp-filter-select-font-size)
        !important;

    font-weight:
        var(--sp-filter-select-font-weight)
        !important;

    line-height:
        1;


    outline:
        none;

    white-space:
        nowrap;

    text-overflow:
        ellipsis;


    transition:
        background-color
        var(--sp-transition-fast),

        border-color
        var(--sp-transition-fast),

        color
        var(--sp-transition-fast),

        box-shadow
        var(--sp-transition-fast);
}


/* ---------------------------------------------------------
   Hover
   ---------------------------------------------------------
 *
 * Обводка НЕ меняется.
 * Меняется только фон.
 */

.sp-matches-filter-form .sp-season-filter__select:hover {
    background:
        var(--sp-filter-select-hover-bg)
        !important;

    border-color:
        var(--sp-filter-select-hover-border)
        !important;

    color:
        var(--sp-filter-select-hover-text)
        !important;
}


/* ---------------------------------------------------------
   Focus
   ---------------------------------------------------------
 *
 * Border тоже остаётся тем же самым.
 */

.sp-matches-filter-form .sp-season-filter__select:focus,
.sp-matches-filter-form .sp-season-filter__select:focus-visible {
    background:
        var(--sp-filter-select-focus-bg)
        !important;

    border-color:
        var(--sp-filter-select-focus-border)
        !important;

    color:
        var(--sp-filter-select-focus-text)
        !important;

    box-shadow:
        var(--sp-filter-select-focus-shadow)
        !important;

    outline:
        none;
}


/* ---------------------------------------------------------
   Active
   ---------------------------------------------------------
 *
 * Даже во время нажатия цвет обводки
 * остаётся системным цветом капсулы.
 */

.sp-matches-filter-form .sp-season-filter__select:active {
    border-color:
        var(--sp-filter-select-border)
        !important;
}


/* =========================================================
   Mobile
   ========================================================= */

@media (max-width: 767px) {

    /*
     * На телефоне капсулы остаются одной строкой.
     * Если они не помещаются — горизонтальный свайп.
     */
    .sp-matches-filter-form {
        flex-flow:
            row nowrap !important;

        align-items:
            center;

        gap:
            var(--sp-filter-select-gap);

        margin:
            8px 0 14px;

        overflow-x:
            auto;

        overflow-y:
            hidden;

        -webkit-overflow-scrolling:
            touch;

        overscroll-behavior-x:
            contain;

        scrollbar-width:
            none;

        -ms-overflow-style:
            none;
    }


    .sp-matches-filter-form::-webkit-scrollbar {
        display:
            none;

        width:
            0;

        height:
            0;
    }


    /*
     * Один фильтр не переносится
     * и не растягивается.
     */
    .sp-matches-filter-form .sp-season-filter {
        flex:
            0 0 auto !important;

        width:
            max-content !important;

        max-width:
            80vw !important;
    }


    /*
     * Та же самая capsule-система.
     *
     * Здесь НЕ прописываем 30px / 13px вручную.
     *
     * Эти значения уже переключаются
     * в мобильном :root 00-settings.css.
     */
    .sp-matches-filter-form .sp-season-filter__select {
        width:
            max-content !important;

        max-width:
            80vw !important;

        min-height:
            var(--sp-filter-select-min-height)
            !important;

        font-size:
            var(--sp-filter-select-font-size)
            !important;
    }}


/* =========================================================
   ShaibaPRO: второй sticky-уровень для строки фильтров матчей
   =========================================================
 *
 * Первая sticky-строка:
 *   .sp-teams-filter[data-sp-sticky-primary-row]
 *
 * Вторая sticky-строка:
 *   .sp-matches-filter-form[data-sp-sticky-filter-row]
 *
 * JS вычисляет фактический нижний край первой строки и
 * передаёт его в --sp-filter-sticky-secondary-top.
 * Поэтому второй уровень автоматически остаётся вплотную
 * под первым при любых размерах desktop/mobile капсул.
 */

.sp-matches-filter-form[data-sp-sticky-filter-row].is-stuck {
    position:
        sticky !important;

    top:
        var(
            --sp-filter-sticky-secondary-top,
            var(--sp-header-height)
        )
        !important;

    z-index:
        var(--sp-filter-sticky-secondary-row-z-index)
        !important;

    padding-top:
        var(--sp-filter-sticky-secondary-padding-y)
        !important;

    padding-bottom:
        var(--sp-filter-sticky-secondary-padding-y)
        !important;

    padding-left:
        var(--sp-filter-sticky-secondary-padding-x)
        !important;

    padding-right:
        var(--sp-filter-sticky-secondary-padding-x)
        !important;

    /*
     * Сам form остаётся прозрачным и по ширине sp-container.
     * Полноширинный фон рисует отдельный слой .sp-shell::after.
     */
    background:
        transparent !important;

    border:
        0 !important;

    border-radius:
        0 !important;

    -webkit-backdrop-filter:
        none !important;

    backdrop-filter:
        none !important;

    box-shadow:
        none !important;
}