.match-page { background: #0c1115; color: #edf3ef; }
.match-page .content-page { width: 100%; max-width: 1248px; padding: 44px 28px 60px; }
.match-page [hidden] { display: none !important; }
.match-page-header { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 30px; }
.match-page-intro { min-width: 0; }
.match-game-link { display: inline-block; margin-bottom: 12px; color: #d5f76d; font-size: 12px; font-weight: 600; text-decoration: none; }
.match-game-link:hover { color: #e5ffa1; text-decoration: underline; }
.match-page-header h1 { margin: 0; font-size: 36px; font-weight: 750; letter-spacing: -1.3px; overflow-wrap: anywhere; }
.match-page-intro p { margin: 12px 0 0; color: #a6b9c1; font-size: 14px; line-height: 1.6; }
.match-page-actions { display: flex; flex-shrink: 0; flex-wrap: wrap; gap: 10px; }
.match-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; background: #162027; border: 1px solid #35444b; border-radius: 5px; color: #c6d2d8; font: inherit; font-size: 14px; font-weight: 600; text-align: center; text-decoration: none; cursor: pointer; }
.match-button:hover { color: #edf3ef; background: #1c2a32; border-color: #6e8c78; }
.match-button-primary { background: #d5f76d; border-color: #d5f76d; color: #162016; font-weight: 700; }
.match-button-primary:hover { background: #e5ffa1; border-color: #e5ffa1; color: #162016; }
.match-page-status { margin: 0 0 16px; padding: 28px 22px; background: #151e25; border: 1px solid #2c3a42; border-radius: 10px; color: #a6b9c1; font-size: 14px; line-height: 1.6; }
.match-page-status.is-empty { border-style: dashed; }
.match-page-status.is-error { color: #f28b96; }
.match-history-list { display: grid; gap: 16px; }
.match-history-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "title time" "opponent time" "stats rating"; align-items: start; column-gap: 24px; row-gap: 8px; padding: 22px; background: #151e25; border: 1px solid #2c3a42; border-radius: 10px; }
.match-history-card p { margin: 0; overflow-wrap: anywhere; font-size: 14px; line-height: 1.6; }
.match-history-title { grid-area: title; margin: 0; font-size: 22px; font-weight: 700; letter-spacing: -.5px; overflow-wrap: anywhere; }
.match-history-opponent { grid-area: opponent; color: #a6b9c1; }
.match-history-stats { grid-area: stats; color: #dce7e8; }
.match-history-rating { grid-area: rating; color: #a6b9c1; text-align: right; font-variant-numeric: tabular-nums; }
.match-history-rating.rating-positive { color: #d5f76d; }
.match-history-rating.rating-negative { color: #f28b96; }
.match-history-time { grid-area: time; color: #91a2aa; font-size: 12px; text-align: right; font-variant-numeric: tabular-nums; }
.outcome-win .match-history-stats { color: #d5f76d; }
.outcome-loss .match-history-stats { color: #f28b96; }
.leaderboard-rating { margin: 0 0 22px; padding: 16px 20px; background: #172128; border: 1px solid #35444b; border-radius: 8px; color: #d5f76d; font-size: 14px; font-weight: 600; line-height: 1.6; }
.leaderboard-table-wrap { width: 100%; overflow-x: auto; background: #151e25; border: 1px solid #2c3a42; border-radius: 10px; }
.leaderboard table { width: 100%; border-collapse: collapse; }
.leaderboard th, .leaderboard td { padding: 18px 20px; border-bottom: 1px solid #2c3a42; text-align: left; }
.leaderboard th { background: #172128; color: #a6b9c1; font-size: 12px; font-weight: 600; }
.leaderboard td { color: #dce7e8; font-size: 14px; }
.leaderboard tbody tr:last-child td { border-bottom: 0; }
.leaderboard .rank-number { width: 64px; color: #91a2aa; font-variant-numeric: tabular-nums; }
.leaderboard .is-top-three .rank-number { color: #d5f76d; font-weight: 700; }
.leaderboard .player-name { min-width: 130px; overflow-wrap: anywhere; font-weight: 600; }
.leaderboard .league-name { color: #a6b9c1; }
.leaderboard .numeric { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
@media (max-width: 800px) {
    .match-page-header { align-items: flex-start; flex-direction: column; gap: 20px; }
    .match-history-card { grid-template-columns: minmax(0, 1fr); grid-template-areas: "title" "opponent" "stats" "rating" "time"; }
    .match-history-rating, .match-history-time { text-align: left; }
}
@media (max-width: 740px) {
    .match-page .content-page { padding: 28px 18px 40px; }
    .match-page-header h1 { font-size: 30px; }
    .match-page-header { margin-bottom: 24px; }
    .match-history-card { padding: 20px; }
    .match-history-title { font-size: 20px; }
}
@media (max-width: 480px) {
    .match-page-actions { width: 100%; }
    .match-page-actions .match-button { flex: 1 1 0; padding: 10px 12px; }
    .leaderboard th, .leaderboard td { padding: 14px 8px; }
    .leaderboard .rank-number { width: 32px; }
    .leaderboard .player-name { min-width: 80px; }
    .leaderboard th { font-size: 11px; }
    .leaderboard td { font-size: 13px; }
}
