.ranking-panel { white-space: normal; }
.ranking-tabs, .ranking-modes { display: grid; gap: 6px; }
.ranking-tabs { grid-template-columns: 1fr 1fr; padding: 5px; border-radius: 16px; background: #e9e3cb; margin-bottom: 16px; }
.ranking-tab, .ranking-mode, .ranking-refresh { font: inherit; cursor: pointer; border: 0; color: #4b6958; }
.ranking-tab { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 8px; border-radius: 12px; background: transparent; font-size: 13px; }
.ranking-tab .ui-icon { flex-shrink: 0; width: 18px; height: 18px; }
.ranking-tab[aria-pressed="true"] { background: #fffaf0; color: #225b48; box-shadow: 0 2px 6px #65562b16; }
.ranking-modes { grid-template-columns: repeat(3, minmax(0,1fr)); }
.ranking-mode { min-width: 0; min-height: 42px; border: 1px solid #cbd5b7; border-radius: 11px; background: #f6f4e4; font-size: 12px; padding: 7px 4px; }
.ranking-mode[aria-pressed="true"] { background: #316c5e; border-color: #316c5e; color: white; }
.ranking-explainer { font-size: 11px; line-height: 1.8; color: #667660; margin: 10px 0 14px; text-align: start; }
.ranking-personal { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; background: #e7edda; border: 1px solid #cbd8b7; padding: 12px 14px; border-radius: 12px; font-size: 12px; color: #3b654e; }
.ranking-personal strong { font-size: 16px; }
.ranking-submit { margin: 12px 0; padding: 14px; border-radius: 14px; background: #fffbef; border: 1px solid #e4d7b6; text-align: start; }
.ranking-submit-caption { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; font-size: 12px; color: #6c7158; margin-bottom: 9px; }
.ranking-submit-caption strong { font-size: 22px; color: #316c5e; font-variant-numeric: tabular-nums; }
.ranking-name-label { display: block; font-size: 11px; margin-bottom: 5px; color: #65715b; }
.ranking-submit-fields { display: flex; align-items: stretch; gap: 8px; }
.ranking-name { flex: 1; min-width: 0; width: 100%; min-height: 44px; font: inherit; font-size: 16px; color: #244e40; background: white; border: 1px solid #becbb3; border-radius: 10px; padding: 9px 11px; box-sizing: border-box; }
.ranking-submit .game-btn { min-width: 0; min-height: 44px; padding: 9px 12px; font-size: 12px; border-radius: 11px; }
.ranking-privacy { margin: 8px 0 0; font-size: 10px; line-height: 1.7; color: #7a806b; }
.ranking-status-line { display: flex; align-items: center; gap: 10px; justify-content: space-between; margin: 12px 0; }
.ranking-status { margin: 0; font-size: 11px; color: #557662; line-height: 1.7; text-align: start; }
.ranking-status.ranking-error { color: #a14c35; }
.ranking-refresh { flex-shrink: 0; min-height: 40px; padding: 7px 9px; background: #e6ecd9; border-radius: 10px; font-size: 11px; display: flex; align-items: center; gap: 5px; }
.ranking-refresh .ui-icon { width: 15px; height: 15px; }
.ranking-empty { font-size: 12px; line-height: 1.9; color: #748064; text-align: center; padding: 18px 10px; margin: 0; }
.ranking-list.online-results { max-height: none; overflow: visible; }
.online-results .ranking-score { font-size: 21px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ranking-player { font-size: 14px; overflow-wrap: anywhere; color: #45674f; text-align: start; }
.ranking-row.own-ranking { border-color: #82ae8c; background: #edf4df; }
.ranking-panel button:focus-visible, .ranking-name:focus-visible { outline: 3px solid #d29537; outline-offset: 2px; }
.ranking-panel button:disabled { cursor: default; opacity: .6; }
@media (max-width: 380px) {
  .ranking-submit-fields { flex-direction: column; }
  .ranking-tab { font-size: 11px; padding: 7px 4px; }
  .ranking-tabs { margin-bottom: 12px; }
  .ranking-submit { padding: 11px; }
  .ranking-player { font-size: 12px; }
  .online-results .ranking-score { font-size: 18px; }
}
