[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #83f6b7; outline-offset: 4px; }
button.hamburger { border: 0; background: transparent; color: inherit; padding: 10px; width: 48px; height: 48px; }
button.hamburger span { pointer-events: none; }
.home-section-subtitle, .highlight-small, .country-text, .section-subtitle, .highlight-label { color: #b9c7cc !important; }
.memorable-players { display: grid; gap: 6px; }
.memorable-partials { margin-top: 12px; line-height: 1.6; }
.search-pagination { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding: 20px 0 32px; }
.search-pagination a { color: #83f6b7; padding: 8px 14px; border: 1px solid #52666e; border-radius: 8px; }
.ranking-country { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 13px; }
.profile-sections { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; width: min(1500px, calc(100% - 32px)); max-width: none; padding: 0; margin: 0 auto 24px; }
.profile-sections button { cursor: pointer; font: inherit; color: #e5ede8; background: #18261f; border: 1px solid #41584b; padding: 12px 18px; border-radius: 10px; }
.profile-sections button[aria-pressed="true"] { color: #071b10; background: #39d98a; border-color: #39d98a; font-weight: 700; }
#playerProfile.profile-filtered { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: min(1200px, calc(100% - 32px)); }
#playerProfile.profile-filtered > .column { display: contents; }
#playerProfile.profile-filtered .sticky { position: static; }
#playerProfile.profile-filtered .player-hero { position: relative; grid-row: span 2; }
.recent-player-results { padding: 0; list-style: none; }
.recent-player-results li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; padding: 12px 0; border-bottom: 1px solid #34473b; }
.recent-player-results time { color: #b9c7cc; font-size: 12px; }
.recent-player-results a { color: #b3f4cf; overflow-wrap: anywhere; }
@media (max-width: 760px) {
    #playerProfile.profile-filtered { grid-template-columns: minmax(0, 1fr); }
    #playerProfile.profile-filtered .player-hero { grid-row: auto; }
    .profile-sections button { padding: 10px 12px; }
}
@media (max-width: 900px) {
    header { padding: 60px 12px 24px; }
    button.hamburger { top: 8px; left: 8px; }
}
.match-partials{display:block;margin-top:6px;color:#b9cbd3;font-size:12px;font-weight:400;line-height:1.6;white-space:normal;max-width:340px}.recent-player-results .match-partials{grid-column:2 / -1;margin-top:-4px}.form-tooltip .match-partials{font-size:11px}.game-table .match-partials{min-width:150px}

/* Profile containment applies on desktop as well as mobile. */
#playerProfile{width:min(1500px,calc(100% - 32px));max-width:100%;min-width:0}
#playerProfile .card,#playerProfile .column,#playerProfile .hidden{min-width:0;max-width:100%}
#playerProfile .table-scroll{width:100%;max-width:100%;min-width:0;overflow-x:auto;overscroll-behavior-inline:contain}
#playerProfile .game-table{display:table;min-width:640px;width:100%}
#playerProfile .game-table td{vertical-align:top}
#playerProfile .game-table td:nth-child(2),#playerProfile .game-table td:nth-child(3),#playerProfile .game-table td:nth-child(5){white-space:normal;overflow-wrap:anywhere;max-width:240px}
#playerProfile .history-title>span:first-child{min-width:0;overflow-wrap:anywhere}
#playerProfile .pair-header{flex-wrap:wrap;gap:10px}
#playerProfile .global-toggle{margin:14px 0 12px;min-height:32px}
#playerProfile[data-view=history]{grid-template-columns:minmax(0,1fr)}
#playerProfile.profile-all{display:grid;grid-template-columns:minmax(240px,300px) minmax(0,1fr);width:min(1400px,calc(100% - 32px))}
#playerProfile.profile-all>.column{display:contents}
#playerProfile.profile-all>.column>.card{position:relative;margin:0}
#playerProfile.profile-all .card{grid-column:1/-1}
#playerProfile.profile-all .player-hero{grid-column:1;grid-row:1/span 2}
#playerProfile.profile-all [data-profile-role=recent]{grid-column:2;grid-row:1}
#playerProfile.profile-all [data-profile-role=chart]{grid-column:2;grid-row:2}
#playerProfile .recent-score-link{display:inline-block;padding:3px 7px;border:1px solid #3c6350;border-radius:6px;color:#8af2bd}
@media(max-width:760px){#playerProfile.profile-all{grid-template-columns:minmax(0,1fr)}#playerProfile.profile-all .player-hero,#playerProfile.profile-all [data-profile-role=recent],#playerProfile.profile-all [data-profile-role=chart]{grid-column:1;grid-row:auto}}

/* Keep desktop navigation on a single row; compact screens can scroll the links. */
#mainNav a, #mainNav a:hover, #mainNav a:focus { text-decoration: none; }
@media (min-width: 901px) {
    #mainNav { display: flex; flex-wrap: nowrap; align-items: center; gap: 14px; max-width: 1480px; width: calc(100% - 32px); padding: 12px 16px; box-sizing: border-box; }
    #mainNav .nav-links { display: flex; flex-wrap: nowrap; align-items: center; gap: 6px; flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: thin; }
    #mainNav .nav-links a { flex: 0 0 auto; white-space: nowrap; padding: 8px 9px; font-size: 13px; }
    #mainNav .nav-search { flex: 0 0 200px; width: 200px; margin: 0; }
}

.player-not-found { width: min(640px, calc(100% - 32px)); margin: 48px auto; padding: 32px; box-sizing: border-box; border: 1px solid #344c56; border-radius: 18px; background: #141e23; color: #e7eef1; }
.player-not-found-code { font-size: 12px; font-weight: 700; color: #83f6b7; letter-spacing: 1px; }
.player-not-found h1 { font-size: clamp(25px, 5vw, 34px); margin: 14px 0; }
.player-not-found p { color: #b9c7cc; line-height: 1.7; }
.player-recovery-search { margin: 28px 0; }
.player-recovery-search label { display: block; margin-bottom: 10px; font-size: 14px; }
.player-recovery-search > div { display: flex; gap: 10px; }
.player-recovery-search input { flex: 1; min-width: 0; padding: 12px; border: 1px solid #52666e; border-radius: 8px; background: #0e171b; color: white; font: inherit; }
.player-recovery-search button { border: 0; border-radius: 8px; background: #39d98a; color: #071b10; font-weight: 700; padding: 12px 16px; cursor: pointer; }
.player-recovery-links { display: flex; flex-wrap: wrap; gap: 16px; }
.player-recovery-links a { color: #83f6b7; }
@media(max-width:520px) { .player-not-found { padding: 24px 18px; margin: 24px auto; } .player-recovery-search > div { flex-direction: column; } }

.ranking-record-link { text-decoration: none; cursor: pointer; border: 1px solid #3c6350; border-radius: 7px; padding: 7px 10px; }
.ranking-record-link:hover { text-decoration: none; border-color: #39d98a; }
.ranking-record-link[aria-busy="true"] { opacity: .55; cursor: progress; }
.ranking-games-dialog .win { color: #39d98a; }
.ranking-games-dialog .loss { color: #f87171; }

button.hamburger{background:#e2e8f0;color:#102238;border:1px solid #fff;box-shadow:0 2px 8px #0008}button.hamburger span{background:#102238}button.hamburger:hover{background:#fff}
.search-club-logo{object-fit:contain;vertical-align:middle}
.agenda-competition{min-width:0}.agenda-more summary{cursor:pointer;padding:12px;color:#7dd3fc}

.player-card .search-club-logo{width:20px!important;height:20px!important;max-width:20px;object-fit:contain;display:inline-block;vertical-align:middle;margin:0 4px 0 0;flex:none}
