:root {
  --club-night: #171e35;
  --club-paper: #fffaf0;
  --club-lime: #c8f46a;
  --club-muted: #b8c4d9;
  --club-stroke: #ffffff20;
}
body.club-home {
  margin: 0;
  background: var(--club-night);
  color: var(--club-paper);
  font:
    15px system-ui,
    -apple-system,
    sans-serif;
}
.club-shell,
.club-shell * {
  box-sizing: border-box;
}
.club-shell {
  max-width: 1180px;
  margin: auto;
  padding: 32px 40px;
}
.club-shell :is(a, button, summary) {
  -webkit-tap-highlight-color: transparent;
}
.club-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 32px;
}
.club-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--club-paper);
  line-height: 0.94;
  letter-spacing: -0.06em;
  font-size: 21px;
}
.club-brand > span {
  display: block;
  width: 43px;
  height: 49px;
  padding: 4px 6px;
  border: 2px solid var(--club-lime);
  border-radius: 9px;
  font-size: 9px;
  line-height: 1;
  color: var(--club-lime);
  letter-spacing: 0;
}
.club-brand big {
  display: block;
  font-size: 26px;
  font-weight: 800;
  margin-top: 2px;
}
#home-account {
  position: relative;
}
#home-account button {
  min-height: 44px;
  border: 1px solid #68778f;
  border-radius: 10px;
  padding: 10px 14px;
  background: transparent;
  color: white;
  font: 600 12px system-ui;
  cursor: pointer;
}
#home-account button:disabled {
  opacity: 0.65;
  cursor: wait;
}
#home-account-content {
  position: absolute;
  z-index: 5;
  top: calc(100% + 8px);
  right: 0;
  width: min(280px, calc(100vw - 32px));
  padding: 16px;
  background: #243149;
  border: 1px solid #63738a;
  border-radius: 14px;
  box-shadow: 0 14px 40px #06152660;
}
#home-account-content button {
  width: 100%;
  text-align: left;
}
#home-account-content .account {
  border: 0;
  padding: 0;
  margin-top: 12px;
}
#home-account-content .account > p {
  font-size: 12px;
  color: var(--club-muted);
}
#home-account-status:not(:empty) {
  position: absolute;
  z-index: 6;
  top: calc(100% + 20px);
  right: 12px;
  width: 250px;
  font-size: 12px;
  color: var(--club-muted);
}
.club-home [hidden] {
  display: none !important;
}
.club-main {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(0, 1.2fr);
  gap: 24px;
}
.mode-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--club-paper);
  color: #1c2b40;
  border-radius: 24px;
  padding: 36px;
}
.eyebrow {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
}
.section-heading .eyebrow {
  color: #526079;
}
.section-heading h1 {
  font-size: clamp(34px, 4vw, 48px);
  line-height: 1.08;
  margin: 12px 0;
  letter-spacing: -0.045em;
}
.section-heading p {
  font-size: 14px;
  color: #526079;
  line-height: 1.5;
  margin: 0 0 28px;
}
.mode-grid {
  display: grid;
  gap: 12px;
}
.mode-card {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #26344b;
  min-height: 88px;
  padding: 18px 16px;
  border: 1px solid #d8dbe3;
  border-radius: 13px;
  background: #f2f2ec;
  transition: border-color 0.16s;
}
.mode-card:hover {
  border-color: #64768a;
}
.mode-card .mode-icon {
  font-size: 24px;
  width: 28px;
  flex-shrink: 0;
  text-align: center;
}
.mode-card strong {
  font-size: 18px;
  letter-spacing: -0.025em;
}
.mode-card small {
  display: block;
  font-size: 12px;
  line-height: 1.45;
  margin-top: 5px;
  color: #536278;
}
.mode-card > b {
  margin-left: auto;
  font-size: 22px;
}
.mode-card.mode-online {
  background: var(--club-lime);
  border-color: #b2d967;
}
.mode-online small {
  color: #304c27;
}
.guest-note {
  font-size: 12px;
  color: #5d6a7b;
  text-align: center;
  margin: 22px 0 0;
}
.club-hero {
  position: relative;
  min-height: 430px;
  border-radius: 24px;
  overflow: hidden;
  background: #4f8298;
}
.club-hero img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 52% center;
}
.club-hero::after {
  content: '';
  position: absolute;
  inset: 45% 0 0;
  background: linear-gradient(transparent, #12263afa);
}
.hero-copy {
  position: absolute;
  z-index: 1;
  bottom: 28px;
  left: 28px;
  right: 22px;
}
.hero-copy .eyebrow {
  color: #d5fcac;
}
.hero-copy p {
  font-size: clamp(24px, 2.6vw, 34px);
  font-weight: 750;
  line-height: 1.12;
  letter-spacing: -0.035em;
  margin: 12px 0 0;
}
.home-extras {
  margin-top: 24px;
  border: 1px solid var(--club-stroke);
  border-radius: 16px;
  background: #1d2940;
}
.home-extras > summary {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 18px 22px;
  font-size: 14px;
  font-weight: 650;
  cursor: pointer;
}
.home-extras > summary::-webkit-details-marker {
  display: none;
}
.home-extras > summary::after {
  content: '+';
  margin-left: auto;
  font-size: 20px;
  color: var(--club-muted);
}
.home-extras[open] > summary::after {
  content: '−';
}
.home-extras > summary span {
  color: var(--club-muted);
  font-size: 12px;
  font-weight: 400;
}
.secondary-modes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 0 16px 16px;
}
.secondary-modes a {
  position: relative;
  display: grid;
  align-content: center;
  gap: 4px;
  min-height: 86px;
  padding: 16px 42px 16px 16px;
  color: white;
  text-decoration: none;
  border-radius: 10px;
  background: #28354d;
}
.secondary-modes a:hover {
  background: #304159;
}
.secondary-modes strong {
  font-size: 14px;
  font-weight: 650;
}
.secondary-modes small {
  font-size: 12px;
  color: var(--club-muted);
  line-height: 1.4;
}
.secondary-modes a > span {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
}
.secondary-modes .home-wardrobe {
  padding-left: 86px;
}
.home-wardrobe img {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 64px;
  height: 64px;
  object-fit: contain;
}
.club-footer {
  color: #a9b8ce;
  font-size: 11px;
  line-height: 1.5;
  padding: 24px 3px 0;
}
.club-shell :is(a, button, input, summary):focus-visible {
  outline: 3px solid #ffc46b;
  outline-offset: 4px;
}
@media (max-width: 900px) {
  .club-shell {
    padding: 24px;
  }
  .club-main {
    gap: 16px;
    grid-template-columns: minmax(300px, 1fr) minmax(0, 1fr);
  }
  .mode-panel {
    padding: 28px;
  }
}
@media (max-width: 700px) {
  .club-shell {
    padding: max(20px, env(safe-area-inset-top)) 16px max(24px, env(safe-area-inset-bottom));
  }
  .club-header {
    margin-bottom: 28px;
  }
  .club-brand {
    font-size: 17px;
  }
  .club-brand > span {
    width: 38px;
    height: 44px;
  }
  .club-brand big {
    font-size: 23px;
  }
  #home-account button {
    font-size: 12px;
    padding-inline: 12px;
  }
  .club-main {
    display: block;
  }
  .club-hero {
    display: none;
  }
  .mode-panel {
    padding: 28px 22px 24px;
    border-radius: 20px;
  }
  .section-heading h1 {
    font-size: 38px;
  }
  .section-heading p {
    margin-bottom: 24px;
  }
  .mode-card {
    min-height: 88px;
    padding: 16px 13px;
    gap: 10px;
  }
  .mode-card small {
    font-size: 11px;
  }
  .mode-card strong {
    font-size: 17px;
  }
  .guest-note {
    margin-top: 20px;
  }
  .home-extras {
    margin-top: 16px;
  }
  .home-extras > summary {
    padding: 18px;
    flex-wrap: wrap;
    column-gap: 10px;
  }
  .home-extras > summary span {
    font-size: 11px;
  }
  .secondary-modes {
    grid-template-columns: 1fr;
    padding: 0 10px 10px;
  }
  .club-footer {
    padding: 24px 2px 0;
    font-size: 10px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .mode-card {
    transition: none;
  }
}
/* Shared wardrobe and room controls. */
#character-dialog {
  background: #1d2940 !important;
  border-color: #8093ac50 !important;
  border-radius: 22px !important;
}
#character-dialog .character-heading h2 {
  letter-spacing: -0.04em;
}
#character-dialog .character-stage {
  background: radial-gradient(ellipse at center, #486374, #17263e 75%) !important;
}
#character-dialog #net-accessories {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  max-height: 260px;
  overflow: auto;
  padding: 3px;
}
#character-dialog #net-accessories button {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  min-height: 64px;
  background: #2e3d54;
  font-size: 11px !important;
}
#net-accessories button img {
  width: 76px;
  height: 76px;
  object-fit: contain;
}
#net-accessories button small {
  font-size: 9px;
  display: block;
  color: #d3deec;
}
#character-dialog button:disabled {
  opacity: 0.65 !important;
  cursor: not-allowed !important;
}
#character-dialog #net-accessories button[aria-pressed='true'] {
  color: #152f32;
  background: #c4edce;
  border-color: #c4edce;
}
#net-accessories button[aria-pressed='true'] small {
  color: #254536;
}
.looks-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 18px 0 10px;
}
.looks-heading h3 {
  margin: 0;
  font-size: 17px;
  letter-spacing: -0.03em;
}
.looks-heading small {
  font-size: 10px;
  color: #b6cadd;
}
.looks-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.look-slot {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 8px;
  border: 1px solid #91a8c244;
  background: #11233a;
  border-radius: 13px;
  padding: 10px;
}
.look-slot > img {
  width: 64px;
  height: 64px;
  grid-row: span 2;
}
.look-slot input {
  width: 100%;
  min-width: 0;
  border: 0;
  border-bottom: 1px solid #7a91a6;
  background: transparent;
  color: white;
  font: 650 12px system-ui;
  padding: 7px 0;
}
.look-slot > div {
  display: flex;
  gap: 6px;
}
.look-slot > div button {
  min-height: 36px !important;
  min-width: 0 !important;
  font-size: 10px !important;
  padding: 6px 8px;
  background: #bdf354 !important;
  color: #183128 !important;
}
.look-slot > div button + button {
  background: #30475e !important;
  color: #e6f0fa !important;
}
.looks-feedback {
  font-size: 11px;
  min-height: 16px;
  color: #cdeba5;
}
/* Navigation is available only after loading, outside active gameplay. */
.hub-nav {
  display: none;
  position: fixed;
  z-index: 31;
  top: max(12px, env(safe-area-inset-top));
  left: max(16px, env(safe-area-inset-left));
  font: 600 13px system-ui;
}
body[data-scene-ready='true']:is(
    [data-race-phase='entry'],
    [data-race-phase='menu'],
    [data-race-phase='results']
  )
  > .hub-nav {
  display: block;
}
body[data-game-state='error'] > .hub-nav {
  display: none;
}
body[data-race-phase='menu'] > .hub-nav {
  top: auto;
  bottom: max(16px, env(safe-area-inset-bottom));
}
.hub-nav summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 10px 14px;
  box-sizing: border-box;
  border: 1px solid #a3bdca44;
  border-radius: 10px;
  background: #16253ef5;
  color: #e4eff5;
  cursor: pointer;
}
.hub-nav summary::after {
  content: '+';
}
.hub-nav details[open] summary::after {
  content: '−';
}
.hub-nav summary::-webkit-details-marker {
  display: none;
}
.hub-menu-items {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  display: grid;
  width: 200px;
  padding: 6px;
  border: 1px solid #a3bdca44;
  border-radius: 12px;
  background: #16253efa;
  box-shadow: 0 10px 30px #06152650;
}
body[data-race-phase='menu'] .hub-menu-items {
  top: auto;
  bottom: calc(100% + 8px);
}
.hub-nav a,
.hub-nav button {
  display: block;
  width: 100%;
  box-sizing: border-box;
  min-height: 44px;
  padding: 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #e4eff5;
  text-align: left;
  text-decoration: none;
  font: inherit;
  cursor: pointer;
}
.hub-nav :is(a, button):hover {
  background: #ffffff0d;
}
.hub-nav :is(a, button, summary):focus-visible {
  outline: 3px solid #c8f46a;
  outline-offset: 2px;
}
#network-probe:not(.connected) {
  background: radial-gradient(ellipse at top, #243b54, #15233b 72%) !important;
  padding-top: 82px !important;
}
#network-probe .net-entry {
  background: #1e304be8 !important;
  border: 1px solid #b1c7d13b !important;
  padding: 26px !important;
  border-radius: 20px !important;
}
#network-probe .net-entry h1 {
  font-size: 30px !important;
  letter-spacing: -0.04em;
}
#network-probe .net-entry label {
  font-size: 12px;
}
#network-probe #net-name {
  background: #f8f5ef;
  border: 0;
  font-size: 15px;
}
#network-probe .net-entry .secondary {
  box-shadow: none;
  background: #344660;
  font-size: 12px !important;
}
#network-probe .net-help {
  font-size: 11px !important;
}
#network-probe #shop-open {
  margin-top: 16px;
}
#lounge-shop {
  background: #c8f46a !important;
  color: #203529 !important;
}
#character-open {
  background: #20354c !important;
}
body[data-outfit-page] #touch-controls,
body[data-outfit-page] #fullscreen {
  display: none !important;
}
@media (max-width: 700px) {
  .looks-slots {
    grid-template-columns: 1fr;
  }
  .look-slot {
    grid-template-columns: 50px minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
  }
  .look-slot > img {
    grid-row: auto;
    width: 50px;
    height: 50px;
  }
  .look-slot > div button {
    min-height: 44px !important;
  }
  #character-dialog #net-accessories {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
body[data-wardrobe-page] {
  background: #171e35;
}
body[data-wardrobe-page] #unity-canvas {
  opacity: 0;
  pointer-events: none;
}
body[data-wardrobe-page] #fullscreen,
body[data-wardrobe-page] #friends {
  display: none !important;
}
#character-dialog #character-shop {
  background: #2d4863;
  color: #e3f4dc;
  font-size: 12px;
  padding: 10px 13px;
}
#character-dialog .character-heading {
  position: sticky;
  top: -22px;
  z-index: 4;
  background: #1d2940;
  padding-block: 8px;
}
#character-dialog .character-footer {
  position: sticky;
  bottom: -22px;
  background: #1d2940;
  padding: 12px 0;
}
/* Match native Unity menus without competing with the play button. */
body #fullscreen,
body #friends {
  background: #25364f;
  color: #fffaf0;
  border: 1px solid #72839766;
  box-shadow: none;
  font-size: 12px;
  border-radius: 12px;
  font-weight: 600;
}

@media (max-height: 450px) {
  body #fullscreen {
    font-size: 0;
  }
}
