:root {
  --hub-black: #080b0c;
  --hub-ink: #101719;
  --hub-panel: #172124;
  --hub-panel-2: #202b2e;
  --hub-text: #f7f8f2;
  --hub-muted: #aeb9bb;
  --hub-line: rgba(255, 255, 255, 0.14);
  --hub-yellow: #ffd447;
  --hub-coral: #ff704f;
  --hub-cyan: #4fd5e8;
  --hub-green: #65d69a;
  --hub-library-height: 264px;
}

html:has(.game-hub-page) {
  overflow: hidden;
}

body.game-hub-page {
  display: grid;
  grid-template-rows: 12.5svh 75svh 12.5svh;
  width: 100%;
  min-height: 100svh;
  overflow: hidden;
  background: var(--hub-black);
  color: var(--hub-text);
}

body.game-hub-page::before {
  z-index: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.022) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: none;
}

.game-hub-page * {
  letter-spacing: 0;
}

.game-hub-page button,
.game-hub-page input,
.game-hub-page select {
  letter-spacing: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hub-skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 0.65rem 0.8rem;
  transform: translateY(-150%);
  border-radius: 4px;
  background: var(--hub-yellow);
  color: #111;
  font-weight: 800;
}

.hub-skip-link:focus {
  transform: none;
}

.hub-topbar {
  position: relative;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(145px, 0.7fr) minmax(440px, 2fr) minmax(380px, 1.35fr);
  align-items: center;
  gap: 1.25rem;
  min-width: 0;
  height: 12.5svh;
  padding: 0 2.1vw;
  border-bottom: 1px solid var(--hub-line);
  background: rgba(8, 11, 12, 0.96);
  backdrop-filter: blur(18px);
}

.hub-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.72rem;
  min-width: 0;
  text-decoration: none;
}

.hub-brand-mark {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 2px solid var(--hub-yellow);
  border-radius: 3px;
  box-shadow: inset 0 -9px 0 rgba(255, 112, 79, 0.3);
  color: var(--hub-text);
  font-weight: 950;
}

.hub-brand-copy {
  min-width: 0;
}

.hub-brand-copy strong,
.hub-brand-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-brand-copy strong {
  font-size: 1.05rem;
}

.hub-brand-copy small {
  margin-top: 0.12rem;
  color: var(--hub-muted);
  font-size: 0.69rem;
  text-transform: uppercase;
}

.hub-navigation {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.18rem;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.hub-navigation::-webkit-scrollbar {
  display: none;
}

.hub-nav-button {
  position: relative;
  min-height: 38px;
  padding: 0.55rem 0.72rem;
  border: 0;
  background: transparent;
  color: var(--hub-muted);
  cursor: pointer;
  white-space: nowrap;
}

.hub-nav-button::after {
  content: "";
  position: absolute;
  right: 0.7rem;
  bottom: 0;
  left: 0.7rem;
  height: 2px;
  transform: scaleX(0);
  background: var(--hub-yellow);
  transition: transform 160ms ease;
}

.hub-nav-button:hover,
.hub-nav-button:focus-visible,
.hub-nav-button.is-active {
  color: var(--hub-text);
}

.hub-nav-button.is-active::after {
  transform: scaleX(1);
}

.hub-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.42rem;
  min-width: 0;
}

.hub-search {
  display: flex;
  align-items: center;
  gap: 0.42rem;
  width: min(170px, 14vw);
  min-width: 102px;
  height: 38px;
  padding: 0 0.7rem;
  border: 1px solid var(--hub-line);
  border-radius: 5px;
  background: #12191b;
  color: var(--hub-cyan);
}

.hub-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--hub-text);
}

.hub-search input::placeholder {
  color: #839093;
}

.hub-tool-button,
.hub-icon-button,
.hub-icon-command {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  height: 38px;
  border: 1px solid var(--hub-line);
  border-radius: 5px;
  background: #12191b;
  color: var(--hub-text);
  text-decoration: none;
  cursor: pointer;
}

.hub-tool-button {
  gap: 0.36rem;
  max-width: 118px;
  padding: 0 0.7rem;
  overflow: hidden;
}

.hub-tool-button span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-icon-button,
.hub-icon-command {
  width: 38px;
  padding: 0;
  font-size: 1.05rem;
}

.hub-icon-button[data-sound-toggle] {
  width: 48px;
  overflow: hidden;
  color: transparent;
  font-size: 0;
}

.hub-icon-button[data-sound-toggle]::before {
  content: "♪";
  color: var(--hub-text);
  font-size: 1rem;
}

.hub-icon-button[data-sound-toggle][aria-pressed="true"] {
  border-color: rgba(101, 214, 154, 0.7);
  color: transparent;
}

.hub-icon-button[data-sound-toggle][aria-pressed="true"]::before {
  color: var(--hub-green);
}

.hub-tool-button:hover,
.hub-icon-button:hover,
.hub-icon-command:hover,
.hub-tool-button:focus-visible,
.hub-icon-button:focus-visible,
.hub-icon-command:focus-visible {
  border-color: var(--hub-cyan);
  background: #1b282b;
}

.game-hub-page .hub-main {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 75svh;
  margin: 0;
}

.hub-stage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  isolation: isolate;
  background: var(--hub-ink);
}

.hub-key-art {
  position: absolute;
  z-index: -3;
  inset: 0 0 var(--hub-library-height) 36%;
  overflow: hidden;
  background: #162124;
}

.hub-key-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transform: scale(1.025);
  transition: opacity 240ms ease, transform 620ms ease;
}

.hub-key-art img.is-loaded {
  opacity: 0.9;
  transform: scale(1);
}

.hub-stage-shade {
  position: absolute;
  z-index: -2;
  inset: 0 0 var(--hub-library-height);
  background:
    linear-gradient(90deg, #101719 0%, #101719 27%, rgba(16, 23, 25, 0.93) 41%, rgba(16, 23, 25, 0.24) 72%, rgba(16, 23, 25, 0.08) 100%),
    linear-gradient(0deg, #101719 0%, transparent 31%);
}

.hub-selection {
  position: absolute;
  z-index: 2;
  top: 0;
  bottom: var(--hub-library-height);
  left: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(610px, 49vw);
  min-width: 460px;
  padding: 1.45rem 2.4vw 1.4rem 4vw;
}

.hub-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.7rem;
}

.hub-badges span {
  padding: 0.26rem 0.46rem;
  border: 1px solid var(--hub-line);
  border-radius: 3px;
  background: rgba(8, 11, 12, 0.72);
  color: var(--hub-muted);
  font-size: 0.7rem;
  font-weight: 750;
  text-transform: uppercase;
}

.hub-badges span:nth-child(2) {
  border-color: rgba(101, 214, 154, 0.48);
  color: var(--hub-green);
}

.hub-badges span:nth-child(3) {
  border-color: rgba(79, 213, 232, 0.52);
  color: var(--hub-cyan);
}

.hub-overline {
  margin: 0 0 0.38rem;
  color: var(--hub-yellow);
  font-size: 0.74rem;
  font-weight: 850;
  text-transform: uppercase;
}

.hub-selection h1 {
  max-width: 590px;
  margin: 0;
  color: var(--hub-text);
  font-size: 3.25rem;
  line-height: 0.98;
  letter-spacing: 0;
  text-wrap: balance;
}

.hub-summary {
  display: -webkit-box;
  flex-shrink: 0;
  max-width: 570px;
  margin: 0.75rem 0;
  overflow: hidden;
  color: #d5ddde;
  font-size: 0.94rem;
  line-height: 1.48;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

@media (max-height: 800px) and (min-width: 761px) {
  .hub-selection {
    padding-top: 0.7rem;
    padding-bottom: 0.65rem;
  }

  .hub-badges {
    gap: 0.28rem;
    margin-bottom: 0.34rem;
  }

  .hub-badges span {
    padding: 0.18rem 0.34rem;
    font-size: 0.61rem;
  }

  .hub-overline {
    margin-bottom: 0.22rem;
    font-size: 0.66rem;
  }

  .hub-selection h1 {
    font-size: 2.45rem;
  }

  .hub-summary {
    min-height: 2.05em;
    margin: 0.38rem 0;
    font-size: 0.78rem;
    line-height: 1.3;
    -webkit-line-clamp: 2;
  }

  .hub-selection .hub-meta {
    margin-bottom: 0.45rem;
  }

  .hub-selection .hub-actions {
    gap: 0.35rem;
  }

  .hub-selection .hub-launch-note {
    min-height: 1em;
    margin-top: 0.3rem;
    font-size: 0.67rem;
  }
}

.hub-meta {
  display: flex;
  gap: 1.2rem;
  max-width: 590px;
  margin: 0 0 0.85rem;
}

.hub-meta div {
  min-width: 0;
}

.hub-meta dt,
.hub-meta dd {
  margin: 0;
}

.hub-meta dt {
  color: #7f8b8e;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
}

.hub-meta dd {
  max-width: 190px;
  overflow: hidden;
  color: var(--hub-muted);
  font-size: 0.76rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hub-command {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.42rem;
  min-height: 40px;
  padding: 0.62rem 0.82rem;
  border: 1px solid var(--hub-line);
  border-radius: 5px;
  background: #1b2528;
  color: var(--hub-text);
  font-weight: 760;
  text-decoration: none;
  cursor: pointer;
}

.hub-command:hover,
.hub-command:focus-visible {
  border-color: var(--hub-cyan);
  background: #243236;
}

.hub-command-primary {
  border-color: var(--hub-yellow);
  background: var(--hub-yellow);
  color: #17150d;
}

.hub-command-primary:hover,
.hub-command-primary:focus-visible {
  border-color: #ffe88d;
  background: #ffe16c;
}

.hub-command:disabled,
.hub-command[aria-disabled="true"] {
  border-color: var(--hub-line);
  background: #202528;
  color: #7c8789;
  cursor: not-allowed;
}

.hub-launch-note {
  min-height: 1.15em;
  margin: 0.55rem 0 0;
  color: var(--hub-coral);
  font-size: 0.75rem;
}

.hub-library {
  position: absolute;
  z-index: 5;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: 148px minmax(0, 1fr);
  height: var(--hub-library-height);
  border-top: 1px solid var(--hub-line);
  background: #0d1214;
}

.hub-library-heading {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 1rem 0.9rem 0.8rem 1.25rem;
  border-right: 1px solid var(--hub-line);
}

.hub-library-heading strong,
.hub-library-heading span {
  display: block;
}

.hub-library-heading strong {
  font-size: 0.94rem;
}

.hub-library-heading span {
  margin-top: 0.18rem;
  color: var(--hub-muted);
  font-size: 0.72rem;
}

.hub-rail-tools {
  display: flex;
  gap: 0.35rem;
}

.hub-rail-tools .hub-icon-button {
  width: 34px;
  height: 34px;
}

.hub-cover-rail {
  display: block;
  min-width: 0;
  padding: 0.48rem 0.8rem 0.65rem;
  overflow-x: hidden;
  overflow-y: auto;
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
  scrollbar-color: rgba(255, 212, 71, 0.45) transparent;
  scrollbar-width: thin;
}

.hub-cover-rail::-webkit-scrollbar,
.hub-shelf-track::-webkit-scrollbar {
  width: 6px;
  height: 5px;
}

.hub-cover-rail::-webkit-scrollbar-thumb,
.hub-shelf-track::-webkit-scrollbar-thumb {
  border-radius: 3px;
  background: rgba(255, 212, 71, 0.42);
}

.hub-shelf {
  min-width: 0;
  height: 119px;
  scroll-snap-align: start;
}

.hub-shelf + .hub-shelf {
  margin-top: 0.28rem;
}

.hub-shelf-header {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  height: 24px;
  padding: 0 0.2rem;
}

.hub-shelf-header h2 {
  margin: 0;
  color: var(--hub-text);
  font-size: 0.72rem;
  font-weight: 850;
}

.hub-shelf-header span {
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 16px;
  padding: 0 0.25rem;
  border: 1px solid var(--hub-line);
  border-radius: 2px;
  color: var(--hub-muted);
  font-size: 0.57rem;
}

.hub-shelf-track {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  min-width: 0;
  height: 95px;
  padding: 0.18rem 0.2rem 0.42rem;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  scrollbar-color: rgba(255, 212, 71, 0.4) transparent;
  scrollbar-width: thin;
}

.hub-cover-card {
  position: relative;
  display: grid;
  flex: 0 0 128px;
  grid-template-rows: 51px minmax(0, 1fr);
  width: 128px;
  min-width: 128px;
  height: 84px;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--hub-line);
  border-radius: 6px;
  background: #172023;
  color: var(--hub-text);
  text-align: left;
  cursor: pointer;
  transform-origin: center;
  transition: border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.hub-cover-card:hover,
.hub-cover-card:focus-visible,
.hub-cover-card[aria-selected="true"] {
  z-index: 2;
  border-color: var(--hub-yellow);
  outline: none;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.42);
  transform: translateY(-2px) scale(1.025);
}

.hub-cover-card[aria-selected="true"]::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 28px;
  height: 4px;
  background: var(--hub-coral);
}

.hub-cover-image {
  display: grid;
  place-items: center;
  width: 100%;
  height: 51px;
  overflow: hidden;
  background: var(--cover-accent, #243639);
  color: var(--hub-yellow);
  font-size: 1.35rem;
  font-weight: 950;
}

.hub-cover-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hub-cover-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
  padding: 0.25rem 0.42rem 0.3rem;
}

.hub-cover-copy strong {
  display: -webkit-box;
  overflow: hidden;
  font-size: 0.66rem;
  line-height: 1.08;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.hub-cover-copy small {
  margin-top: 0.1rem;
  overflow: hidden;
  color: var(--hub-muted);
  font-size: 0.55rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-cover-state {
  position: absolute;
  top: 0.38rem;
  left: 0.38rem;
  padding: 0.18rem 0.32rem;
  border-radius: 2px;
  background: rgba(8, 11, 12, 0.86);
  color: var(--hub-green);
  font-size: 0.53rem;
  font-weight: 850;
  text-transform: uppercase;
}

.hub-favorite-indicator {
  position: absolute;
  z-index: 2;
  top: 0.32rem;
  right: 0.38rem;
  color: var(--hub-yellow);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.9));
  font-size: 0.82rem;
  line-height: 1;
}

.hub-cover-state.is-server {
  color: var(--hub-coral);
}

.hub-empty {
  align-self: center;
  margin: 0;
  padding: 1rem;
  color: var(--hub-muted);
}

.hub-player {
  position: absolute;
  z-index: 20;
  inset: 0;
  grid-template-rows: 46px minmax(0, 1fr);
  background: #050708;
}

.hub-player:not([hidden]) {
  display: grid;
}

.hub-player-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 0.55rem 0 0.9rem;
  border-bottom: 1px solid var(--hub-line);
  background: #0e1517;
}

.hub-player-toolbar > div {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}

.hub-player-toolbar strong,
.hub-player-toolbar span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-player-toolbar > div:first-child > span:last-child {
  color: var(--hub-muted);
  font-size: 0.72rem;
}

.hub-player-toolbar .hub-contract-status {
  padding-left: 0.5rem;
  border-left: 1px solid var(--hub-line);
  color: var(--hub-yellow);
}

.hub-player-toolbar .hub-contract-status.is-ready {
  color: var(--hub-green);
}

.hub-player-toolbar .hub-contract-status.is-limited {
  color: var(--hub-coral);
}

.hub-player-commands {
  flex: 0 0 auto;
}

.hub-player-commands .hub-icon-button[aria-pressed="true"] {
  border-color: var(--hub-cyan);
  background: rgba(79, 213, 232, 0.13);
  color: var(--hub-cyan);
}

.hub-player-toolbar .hub-icon-button {
  width: 34px;
  height: 34px;
}

.hub-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--hub-green);
  box-shadow: 0 0 0 4px rgba(101, 214, 154, 0.12);
}

.hub-player iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #050708;
}

.hub-scorebar {
  position: relative;
  z-index: 25;
  display: grid;
  grid-template-columns: 176px minmax(460px, 1fr) minmax(150px, 210px) 118px;
  align-items: stretch;
  gap: 0;
  min-width: 0;
  height: 12.5svh;
  border-top: 1px solid var(--hub-line);
  background: #0a0e0f;
}

.hub-score-title {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 0.7rem 1rem 0.7rem 1.25rem;
  border: 0;
  border-right: 1px solid var(--hub-line);
  background: transparent;
  color: var(--hub-text);
  text-align: left;
  cursor: pointer;
}

.hub-score-title span {
  font-size: 0.82rem;
  font-weight: 850;
}

.hub-score-title small {
  margin-top: 0.2rem;
  color: var(--hub-green);
  font-size: 0.64rem;
}

.hub-podium {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  min-width: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hub-podium li {
  display: grid;
  grid-template-columns: 29px minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  padding: 0.55rem 0.75rem;
  border-right: 1px solid var(--hub-line);
}

.hub-podium-rank {
  color: var(--hub-yellow);
  font-size: 0.76rem;
  font-weight: 900;
}

.hub-podium-copy {
  min-width: 0;
}

.hub-podium-copy strong,
.hub-podium-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-podium-copy strong {
  font-size: 0.77rem;
}

.hub-podium-copy small {
  margin-top: 0.16rem;
  color: var(--hub-muted);
  font-size: 0.59rem;
}

.hub-podium-score {
  color: var(--hub-cyan);
  font-size: 0.78rem;
  font-weight: 900;
}

.hub-podium-empty {
  display: flex !important;
  grid-column: 1 / -1;
  justify-content: center;
  color: var(--hub-muted);
  font-size: 0.75rem;
}

.hub-personal-best {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 0.55rem 0.85rem;
  border-right: 1px solid var(--hub-line);
}

.hub-personal-best span,
.hub-personal-best small {
  overflow: hidden;
  color: var(--hub-muted);
  font-size: 0.62rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-personal-best strong {
  margin: 0.08rem 0;
  color: var(--hub-coral);
  font-size: 1rem;
}

.hub-ranking-button {
  align-self: center;
  justify-self: center;
}

.hub-dialog {
  width: min(560px, calc(100% - 32px));
  max-height: min(760px, calc(100svh - 32px));
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--hub-line);
  border-radius: 7px;
  background: var(--hub-panel);
  color: var(--hub-text);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.68);
}

.hub-dialog::backdrop {
  background: rgba(3, 5, 6, 0.78);
  backdrop-filter: blur(5px);
}

.hub-score-dialog {
  width: min(820px, calc(100% - 32px));
}

.hub-dialog-panel {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 1.2rem;
}

.hub-dialog-panel > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--hub-line);
}

.hub-dialog-panel h2 {
  margin: 0;
  font-size: 1.3rem;
  letter-spacing: 0;
}

.hub-dialog-panel p {
  color: var(--hub-muted);
  font-size: 0.84rem;
  line-height: 1.5;
}

.hub-dialog-field,
.hub-score-controls label {
  display: grid;
  gap: 0.38rem;
  margin-top: 1rem;
  color: var(--hub-muted);
  font-size: 0.72rem;
  font-weight: 760;
}

.hub-dialog-field input,
.hub-score-controls select {
  width: 100%;
  min-height: 42px;
  padding: 0.55rem 0.68rem;
  border: 1px solid var(--hub-line);
  border-radius: 5px;
  outline: 0;
  background: #0f1719;
  color: var(--hub-text);
}

.hub-dialog-field input:focus,
.hub-score-controls select:focus {
  border-color: var(--hub-cyan);
}

.hub-dialog-panel menu {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin: 1rem 0 0;
  padding: 0;
}

.hub-score-controls {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.8rem;
}

.hub-score-controls label {
  width: min(300px, 65%);
}

.hub-score-modes {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  min-height: 40px;
  padding: 3px;
  border: 1px solid var(--hub-line);
  border-radius: 5px;
  background: #0b1113;
}

.hub-score-modes button {
  min-width: 92px;
  padding: 0.45rem 0.65rem;
  border: 0;
  border-radius: 3px;
  background: transparent;
  color: var(--hub-muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 800;
}

.hub-score-modes button:hover,
.hub-score-modes button:focus-visible,
.hub-score-modes button.is-active {
  outline: 0;
  background: #172326;
  color: var(--hub-text);
}

.hub-score-modes button.is-active {
  box-shadow: inset 0 -2px 0 var(--hub-cyan);
}

.hub-season-status {
  min-height: 1.3rem;
  margin: 0 0 0.55rem !important;
  color: var(--hub-green) !important;
  font-size: 0.72rem !important;
}

.hub-score-list {
  min-height: 200px;
  max-height: 52svh;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
  border-top: 1px solid var(--hub-line);
}

.hub-score-list li {
  display: grid;
  grid-template-columns: 52px minmax(120px, 1fr) minmax(120px, 1.2fr) auto;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  padding: 0.72rem 0.5rem;
  border-bottom: 1px solid var(--hub-line);
}

.hub-score-list li > * {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hub-score-list .score-rank {
  color: var(--hub-yellow);
  font-weight: 900;
}

.hub-score-list .score-project {
  color: var(--hub-muted);
  font-size: 0.78rem;
}

.hub-score-list .score-value {
  color: var(--hub-cyan);
  font-weight: 900;
}

.hub-score-empty {
  margin: 1rem 0 0 !important;
  text-align: center;
}

.hub-toast {
  position: fixed;
  z-index: 120;
  right: 1rem;
  bottom: calc(12.5svh + 1rem);
  max-width: min(420px, calc(100% - 32px));
  padding: 0.75rem 0.9rem;
  border: 1px solid rgba(255, 212, 71, 0.6);
  border-radius: 6px;
  background: #161e20;
  color: var(--hub-text);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.52);
  font-size: 0.8rem;
}

@media (max-width: 1240px) {
  .hub-topbar {
    grid-template-columns: 118px minmax(390px, 1fr) minmax(330px, 0.8fr);
    gap: 0.7rem;
  }

  .hub-brand-copy small {
    display: none;
  }

  .hub-selection h1 {
    font-size: 2.6rem;
  }

  .hub-scorebar {
    grid-template-columns: 150px minmax(420px, 1fr) 170px 106px;
  }
}

@media (max-width: 1020px) {
  .hub-topbar {
    grid-template-columns: 54px minmax(360px, 1fr) minmax(250px, 0.72fr);
  }

  .hub-brand-copy {
    display: none;
  }

  .hub-search {
    width: 112px;
  }

  .hub-tools .hub-icon-button:nth-of-type(1) {
    display: none;
  }

  .hub-selection {
    width: 58vw;
    min-width: 440px;
  }

  .hub-scorebar {
    grid-template-columns: 140px minmax(390px, 1fr) 155px 96px;
  }

  .hub-podium li {
    grid-template-columns: 22px minmax(0, 1fr);
  }

  .hub-podium-score {
    grid-column: 2;
  }
}

@media (max-height: 680px) and (min-width: 761px) {
  :root {
    --hub-library-height: 226px;
  }

  .hub-shelf {
    height: 99px;
  }

  .hub-shelf-track {
    height: 75px;
  }

  .hub-cover-card {
    grid-template-rows: 40px minmax(0, 1fr);
    height: 66px;
  }

  .hub-cover-image {
    height: 40px;
  }

  .hub-cover-copy small {
    display: none;
  }

  .hub-selection h1 {
    font-size: 2.2rem;
  }

  .hub-summary {
    margin: 0.45rem 0;
    -webkit-line-clamp: 2;
  }

  .hub-meta {
    margin-bottom: 0.5rem;
  }

  .hub-launch-note {
    display: none;
  }
}

@media (max-width: 760px) {
  :root {
    --hub-library-height: 264px;
  }

  html:has(.game-hub-page) {
    overflow: auto;
  }

  body.game-hub-page {
    display: block;
    min-height: 100svh;
    overflow: auto;
  }

  .hub-topbar {
    position: sticky;
    top: 0;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    height: auto;
    min-height: 118px;
    padding: 0.6rem 0.75rem;
  }

  .hub-brand-copy {
    display: block;
  }

  .hub-brand-copy small {
    display: none;
  }

  .hub-navigation {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    order: 3;
  }

  .hub-tools {
    min-width: 0;
  }

  .hub-search {
    flex: 1 1 auto;
    width: auto;
  }

  .hub-tool-button {
    max-width: 92px;
  }

  .hub-tools > .hub-icon-button,
  .hub-tools > .hub-icon-button[data-sound-toggle] {
    display: none;
  }

  .game-hub-page .hub-main {
    height: 740px;
  }

  .game-hub-page.is-player-open .hub-main {
    z-index: 80;
  }

  .hub-key-art {
    inset: 0 0 var(--hub-library-height) 0;
  }

  .hub-key-art img {
    opacity: 0.28;
  }

  .hub-stage-shade {
    inset: 0 0 var(--hub-library-height);
    background: rgba(16, 23, 25, 0.63);
  }

  .hub-selection {
    top: 0;
    bottom: var(--hub-library-height);
    width: 100%;
    min-width: 0;
    padding: 1.4rem 1rem;
  }

  .hub-selection h1 {
    font-size: 2.15rem;
  }

  .hub-meta {
    gap: 0.7rem;
  }

  .hub-meta div:last-child {
    display: none;
  }

  .hub-library {
    grid-template-columns: 100%;
    height: var(--hub-library-height);
  }

  .hub-library-heading {
    flex-direction: row;
    align-items: center;
    height: 50px;
    padding: 0.55rem 0.75rem;
    border-right: 0;
    border-bottom: 1px solid var(--hub-line);
  }

  .hub-cover-rail {
    height: 214px;
    padding: 0.35rem 0.55rem 0.5rem;
  }

  .hub-shelf {
    height: 99px;
  }

  .hub-shelf-header {
    height: 21px;
  }

  .hub-shelf-track {
    height: 78px;
  }

  .hub-cover-card {
    flex-basis: 114px;
    grid-template-rows: 43px minmax(0, 1fr);
    width: 114px;
    min-width: 114px;
    height: 70px;
  }

  .hub-cover-image {
    height: 43px;
  }

  .hub-cover-copy {
    padding: 0.22rem 0.35rem;
  }

  .hub-cover-copy small {
    display: none;
  }

  .hub-scorebar {
    grid-template-columns: minmax(0, 1fr) auto;
    height: auto;
    min-height: 92px;
  }

  .hub-score-title {
    padding-left: 1rem;
  }

  .hub-podium,
  .hub-personal-best {
    display: none;
  }

  .hub-ranking-button {
    margin: 0 0.75rem;
  }

  .hub-toast {
    bottom: 1rem;
  }

  .hub-player {
    position: fixed;
    z-index: 90;
    grid-template-rows: 86px minmax(0, 1fr);
  }

  .hub-player-toolbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 34px 42px;
    gap: 2px;
    padding: 4px 7px;
  }

  .hub-player-toolbar > div:first-child {
    width: 100%;
    gap: 0.35rem;
  }

  .hub-player-toolbar > div:first-child > #playerRuntime {
    display: none;
  }

  .hub-player-toolbar .hub-contract-status {
    min-width: 0;
    margin-left: auto;
    padding-left: 0.35rem;
    font-size: 0.64rem;
  }

  .hub-player-commands {
    display: grid !important;
    grid-template-columns: repeat(8, 34px);
    justify-content: space-between;
    width: 100%;
    gap: 3px !important;
    overflow-x: auto;
  }

  .hub-player-toolbar .hub-icon-button {
    width: 34px;
    min-width: 34px;
    height: 34px;
  }

  .hub-score-list li {
    grid-template-columns: 38px minmax(90px, 1fr) auto;
  }

  .hub-score-list .score-project {
    display: none;
  }

  .hub-score-controls {
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0.55rem;
  }

  .hub-score-modes,
  .hub-score-controls label {
    width: 100%;
  }

  .hub-score-controls label {
    margin-top: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hub-key-art img,
  .hub-cover-card,
  .hub-nav-button::after,
  .hub-cover-rail,
  .hub-shelf-track {
    scroll-behavior: auto;
    transition: none;
  }
}
