.tp-page {
    --tp-main: #171718;
    --tp-inner: #111112;
    --tp-yellow: #ffdf00;
    --tp-border: #303034;
    --tp-muted: #9b9ba5;
    display: grid;
    width: 100%;
    max-width: 1272px;
    margin-right: auto;
    margin-left: auto;
    gap: 20px;
    padding: 28px 0 48px;
    min-width: 0;
    overflow-x: clip;
    color: #f7f7f8;
}

.tp-card {
    min-width: 0;
    max-width: 100%;
    background: var(--tp-main);
    border: 1px solid var(--tp-border);
    border-radius: 18px;
}

.tp-back { width: fit-content; margin-bottom: -4px; }

.tp-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    padding: 30px;
    border-top: 3px solid var(--tp-yellow);
}

.tp-hero h1,
.tp-section h2 {
    margin: 0;
    font-weight: 700;
}

.tp-hero h1 {
    font-size: clamp(1.75rem, 4vw, 2.6rem);
}

.tp-section h2 {
    font-size: 1.3rem;
}

.tp-eyebrow {
    margin: 0 0 6px;
    color: var(--tp-yellow);
    font-size: .76rem;
    font-weight: 700;
    letter-spacing: .11em;
    text-transform: uppercase;
}

.tp-muted {
    margin: 8px 0 0;
    color: var(--tp-muted);
}

.tp-updated {
    display: grid;
    gap: 4px;
    color: var(--tp-muted);
    text-align: right;
    font-size: .82rem;
}

.tp-updated time {
    color: #fff;
    font-weight: 600;
}

.tp-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.tp-summary-item {
    display: grid;
    gap: 5px;
    padding: 18px 20px;
    background: var(--tp-inner);
}

.tp-summary-item span {
    color: var(--tp-muted);
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.tp-summary-item strong {
    color: var(--tp-yellow);
    font-size: 1.7rem;
}

.tp-summary-item.tp-provisional strong {
    color: #ffb347;
}

.tp-review-note {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 13px 16px;
    color: #f3df9c;
    background: #2b2712;
    border: 1px solid #655b0a;
    border-radius: 12px;
}

.tp-section {
    padding: 20px;
}

.tp-section-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 20px;
    margin-bottom: 18px;
}

.tp-section-heading>span {
    color: var(--tp-muted);
    font-size: .82rem;
}

.tp-table-wrap {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
    border: 1px solid #29292d;
    border-radius: 13px;
    background: var(--tp-inner);
}

.tp-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .88rem;
    font-variant-numeric: tabular-nums;
}

.tp-team-table {
    min-width: 560px;
}

.tp-player-table {
    min-width: 940px;
}

.tp-table th,
.tp-table td {
    padding: 9px 10px;
    border-bottom: 1px solid #28282b;
    text-align: right;
    white-space: nowrap;
}

.tp-table th:nth-child(2),
.tp-table td:nth-child(2) {
    text-align: left;
}

.tp-table thead th {
    color: var(--tp-muted);
    background: #0d0d0e;
    font-size: .72rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.tp-sort-button {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 4px;
    padding: 0;
    color: inherit;
    background: transparent;
    border: 0;
    font: inherit;
    letter-spacing: inherit;
    text-transform: inherit;
    white-space: nowrap;
    cursor: pointer;
}

.tp-table th:nth-child(2) .tp-sort-button,
.tp-player-table .tp-col-team .tp-sort-button { justify-content: flex-start; }
.tp-sort-button::after { content: "↕"; opacity: .35; font-size: .68rem; }
.tp-sort-button.is-active { color: var(--tp-yellow); }
.tp-sort-button[data-sort-direction="desc"]::after { content: "↓"; opacity: 1; }
.tp-sort-button[data-sort-direction="asc"]::after { content: "↑"; opacity: 1; }
.tp-sort-button:hover,
.tp-sort-button:focus-visible { color: var(--tp-yellow); }

.tp-table tbody tr:last-child>* {
    border-bottom: 0;
}

.tp-table tbody tr:hover {
    background: rgba(184, 156, 1, 0.06);
}

.tp-rank {
    width: 36px;
    color: var(--tp-yellow);
    font-weight: 700;
}

.tp-team {
    display: flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
}

.tp-team-logo,
.tp-team-logo-fallback {
    width: 30px;
    height: 30px;
    flex: 0 0 30px;
    border-radius: 7px;
}

.tp-team-logo {
    display: block;
    object-fit: contain;
    background: #0d0d0e;
}

.tp-team-logo-fallback {
    display: grid;
    place-items: center;
    color: var(--tp-yellow);
    background: #26230d;
    font-size: .8rem;
}

.tp-team-name,
.tp-player-name {
    overflow: hidden;
    text-overflow: ellipsis;
}

.tp-player-table .tp-col-team {
    text-align: left;
}

.tp-player-identity,
.tp-player-team {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.tp-player-identity img,
.tp-player-team img,
.tp-player-team-fallback {
    width: 26px;
    height: 26px;
    flex: 0 0 26px;
    border-radius: 7px;
}

.tp-player-identity img {
    object-fit: cover;
}

.tp-player-team img {
    object-fit: contain;
    background: #0d0d0e;
}

.tp-player-team-fallback {
    display: grid;
    place-items: center;
    color: var(--tp-yellow);
    background: #26230d;
    font-size: .7rem;
}

.tp-player-identity span,
.tp-player-team span {
    overflow: hidden;
    text-overflow: ellipsis;
}

.tp-table-link {
    color: inherit;
    text-decoration: none;
}

.tp-table-link:hover,
.tp-table-link:focus-visible {
    color: var(--tp-yellow);
}

.tp-team-cell {
    position: relative;
    cursor: help;
    outline: none;
}

.tp-team-cell:focus-visible {
    box-shadow: inset 0 0 0 2px var(--tp-yellow);
}

.tp-roster-popover {
    position: absolute;
    z-index: 2100;
    top: calc(100% + 8px);
    left: 8px;
    width: max-content;
    max-width: min(650px, 82vw);
    padding: 12px;
    visibility: hidden;
    opacity: 0;
    color: #f7f7f8;
    background: rgba(15, 15, 18, .98);
    border: 1px solid rgba(255, 223, 0, .25);
    border-radius: 11px;
    box-shadow: 0 14px 28px rgba(0, 0, 0, .55);
    transform: translateY(5px);
    transition: opacity .14s ease, transform .14s ease, visibility .14s;
}

.tp-roster-popover::before {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 24px;
    border: 6px solid transparent;
    border-bottom-color: rgba(255, 223, 0, .25);
}

.tp-team-cell:hover .tp-roster-popover,
.tp-team-cell:focus .tp-roster-popover,
.tp-team-cell:focus-within .tp-roster-popover {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

.tp-team-cell.gh-has-tip::before,
.tp-team-cell.gh-has-tip::after {
    display: none;
}

.tp-roster-grid {
    display: flex;
    align-items: start;
    gap: 14px;
    padding: 2px 2px;
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--tp-yellow) #292929;
}

.tp-roster-member {
    display: grid;
    flex: 0 0 78px;
    justify-items: center;
    padding: 0;
    text-align: center;
}

.tp-roster-member img {
    width: 30px;
    height: 30px;
    margin-bottom: 5px;
    border-radius: 7px;
    object-fit: cover;
}

.tp-roster-member strong {
    width: 78px;
    margin-bottom: 3px;
    overflow: hidden;
    color: var(--tp-yellow);
    font-size: .7rem;
    text-overflow: ellipsis;
}

.tp-roster-member span {
    color: #c6c6cd;
    font-size: .62rem;
    font-weight: 600;
    line-height: 1.3;
    white-space: nowrap;
}

.tp-roster-empty {
    color: var(--tp-muted);
    font-size: .75rem;
    font-weight: 400;
}

.tp-positive {
    color: #65d895;
}

.tp-negative {
    color: #ff7070;
}

.tp-empty {
    padding: 42px !important;
    color: var(--tp-muted);
    text-align: center !important;
}

@media (min-width: 992px) {
    .tp-team-section .tp-table-wrap {
        overflow: visible;
    }
}

@media (max-width: 991.98px) {
    .tp-page {
        padding-top: 18px;
        gap: 14px;
    }

    .tp-hero {
        align-items: flex-start;
        flex-direction: column;
        padding: 22px;
    }

    .tp-updated {
        text-align: left;
    }

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

    .tp-section {
        padding: 15px 10px;
    }

    .tp-section-heading {
        align-items: flex-start;
        flex-direction: column;
        padding: 0 6px;
    }

    .tp-table-wrap {
        scrollbar-width: thin;
        scrollbar-color: #5a5200 #111112;
    }

    .tp-table {
        font-size: .78rem;
    }

    .tp-table th,
    .tp-table td {
        padding: 7px 5px;
    }

    .tp-table thead th {
        font-size: .63rem;
        letter-spacing: .035em;
    }

    .tp-rank {
        width: 30px;
    }

    .tp-team-logo,
    .tp-team-logo-fallback {
        width: 26px;
        height: 26px;
        flex-basis: 26px;
        border-radius: 6px;
    }
}

@media (max-width: 575.98px) {
    .tp-page {
        width: 100%;
    }

    .tp-hero h1 {
        overflow-wrap: anywhere;
    }

    .tp-review-note {
        align-items: flex-start;
        font-size: .82rem;
    }

    .tp-summary-item span {
        font-size: .68rem;
    }
}

@media (max-width: 420px) {
    .tp-page {
        gap: 11px;
    }

    .tp-hero {
        padding: 18px;
    }

    .tp-summary {
        gap: 8px;
    }

    .tp-summary-item {
        padding: 12px;
    }

    .tp-summary-item strong {
        font-size: 1.35rem;
    }

    .tp-section {
        padding: 13px 7px;
    }

    .tp-table th,
    .tp-table td {
        padding: 6px 4px;
    }
}

@media (max-width: 340px) {
    .tp-summary {
        grid-template-columns: 1fr;
    }
}
