.lobby-command-bar .ag-player-area {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 10px;
  min-width: 0;
}

.lobby-command-bar .ag-player-chip {
  position: relative;
  z-index: 1;
  display: flex;
  min-width: 300px;
  min-height: 44px;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 6px 8px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 999px;
  background:
    radial-gradient(ellipse at 50% 100%, rgba(255, 226, 166, 0.22) 0%, rgba(255, 186, 86, 0.14) 32%, rgba(184, 84, 22, 0) 78%),
    linear-gradient(180deg, rgba(8, 14, 22, 0.62), rgba(122, 80, 42, 0.34));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.20),
    0 14px 32px rgba(0, 0, 0, 0.26);
  backdrop-filter: blur(18px) saturate(135%);
  -webkit-backdrop-filter: blur(18px) saturate(135%);
}

.lobby-command-bar .ag-player-chip-avatar {
  display: flex;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 238, 207, 0.44);
  border-radius: 999px;
  background: radial-gradient(circle at 32% 8%, rgba(255, 250, 235, 0.98), rgba(255, 179, 87, 0.94) 68%, rgba(143, 83, 27, 0.96));
  color: #2b1909;
  font-size: 12px;
  font-weight: 900;
}

.lobby-command-bar .ag-player-chip-main {
  display: flex;
  min-width: 0;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 2px;
}

.lobby-command-bar .ag-player-chip-name,
.lobby-command-bar .ag-player-chip-sub {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lobby-command-bar .ag-player-chip-name {
  color: #f5f8fd;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.1;
}

.lobby-command-bar .ag-player-chip-sub {
  color: rgba(221, 227, 236, 0.72);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.11em;
  line-height: 1.15;
  text-transform: uppercase;
}

.lobby-command-bar .ag-player-chip-btn {
  flex: 0 0 auto;
  padding: 8px 11px;
  border: 1px solid rgba(255, 201, 124, 0.26);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 201, 124, 0.18), rgba(190, 111, 36, 0.1));
  color: #fff1d8;
  cursor: pointer;
  font-family: inherit;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
}

.lobby-command-bar .ag-logout-btn {
  display: inline-flex;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 238, 207, 0.44);
  border-radius: 999px;
  background: radial-gradient(circle at 32% 8%, rgba(255, 250, 235, 0.98), rgba(255, 179, 87, 0.94) 68%, rgba(143, 83, 27, 0.96));
  color: #3f270e;
  cursor: pointer;
}

.lobby-command-bar .ag-logout-btn[hidden] {
  display: none;
}

.lobby-command-bar .ag-logout-icon {
  display: block;
  width: 58%;
  height: 58%;
  fill: none;
  pointer-events: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.35;
}
.ag-chip-menu-btn {
  display: inline-flex;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  border: 1px solid rgba(255, 201, 124, 0.28);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 201, 124, 0.18), rgba(190, 111, 36, 0.1));
  color: #fff1d8;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.ag-chip-menu-btn span {
  display: block;
  width: 12px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 1px 7px rgba(0, 0, 0, 0.28);
}

.ag-chip-menu-btn:hover,
.ag-chip-menu-btn:focus-visible {
  border-color: rgba(255, 218, 160, 0.58);
  outline: none;
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    0 8px 18px rgba(0, 0, 0, 0.22);
}

.ag-chip-menu-btn:active {
  transform: translateY(0);
}

.ag-player-menu-panel {
  box-sizing: border-box;
  position: fixed;
  top: 88px;
  right: 48px;
  z-index: 80;
  width: 190px;
  padding: 10px 0;
  border: 1px solid rgba(255, 237, 204, 0.28);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(27, 35, 45, 0.96), rgba(12, 17, 25, 0.96));
  color: #f5f8fd;
  box-shadow:
    0 18px 38px rgba(0, 0, 0, 0.36),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px) saturate(135%);
  -webkit-backdrop-filter: blur(18px) saturate(135%);
}

.ag-player-menu-panel[hidden] {
  display: none;
}

.ag-player-menu-profile {
  box-sizing: border-box;
  display: flex;
  width: calc(100% - 32px);
  min-height: 34px;
  margin-right: auto;
  margin-left: auto;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 201, 124, 0.34);
  border-radius: 7px;
  background: linear-gradient(180deg, rgba(255, 201, 124, 0.18), rgba(190, 111, 36, 0.12));
  color: #fff1d8;
  cursor: pointer;
  font-family: inherit;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.1;
  text-transform: uppercase;
}

.ag-player-menu-profile:hover,
.ag-player-menu-profile:focus-visible {
  border-color: rgba(255, 218, 160, 0.58);
  outline: none;
  box-shadow: 0 0 0 2px rgba(255, 201, 124, 0.16);
}

.ag-player-menu-stats {
  box-sizing: border-box;
  display: grid;
  gap: 4px;
  width: calc(100% - 32px);
  margin: 10px auto 0;
  padding: 10px 0;
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.045);
  text-align: center;
}

.ag-player-menu-record {
  color: #ffffff;
  font-size: 16px;
  font-weight: 900;
  line-height: 1.1;
}

.ag-player-menu-winrate {
  color: rgba(221, 227, 236, 0.74);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  text-transform: uppercase;
}

@media (max-width: 720px) {
  .lobby-command-bar .ag-player-area {
    gap: 4px;
  }

  .lobby-command-bar .ag-player-chip {
    min-width: 0;
    max-width: 182px;
    gap: 7px;
    padding: 6px 8px;
  }

  .lobby-command-bar .ag-player-chip-avatar {
    width: 26px;
    height: 28px;
    font-size: 10px;
  }

  .lobby-command-bar .ag-player-chip-main {
    display: none;
  }

  .lobby-command-bar .ag-player-chip-btn {
    padding: 7px 10px;
    font-size: 10px;
  }

  .lobby-command-bar .ag-logout-btn {
    width: 28px;
    height: 28px;
  }

  .ag-chip-menu-btn {
    width: 28px;
    height: 28px;
  }

  .ag-player-menu-panel {
    top: 62px;
    right: 9px;
    width: min(190px, calc(100vw - 18px));
  }
}