/* Shared frame treatment; deliberately does not resize seats, cards or abacus digits. */
.player-profile-avatar { position: relative; isolation: isolate; }
.player-profile-portrait { position: absolute; inset: 12%; width: 76%; height: 76%; object-fit: cover; border-radius: 4px; pointer-events: none; user-select: none; }
html .huxi-abacus .abacus-name.avatar {
  flex: 0 0 32px; width: 32px; min-width: 32px; height: 32px; padding: 0;
  border-radius: 6px; font-family: inherit; font-size: 18px; line-height: 1;
  border-color: var(--theme-metal, rgba(255,255,255,.68));
  background-image: var(--theme-avatar-frame, linear-gradient(transparent,transparent)), linear-gradient(145deg,#1f527d,#8ec6dd);
  background-size: 100% 100%;
}
html .huxi-abacus .abacus-name.me-avatar { background-image: var(--theme-avatar-frame, linear-gradient(transparent,transparent)), linear-gradient(145deg,#17745a,#80d9bd); }
html .huxi-abacus .abacus-name.avatar-gold { background-image: var(--theme-avatar-frame, linear-gradient(transparent,transparent)), linear-gradient(145deg,#76501d,#e9ce73); }
.player-profile-panel { padding: 0 20px 24px; color: var(--theme-light, #fff1d0); }
.player-profile-panel.hidden { display: none; }
.player-profile-form { display: grid; grid-template-columns: 140px minmax(0,1fr); gap: 24px; }
.player-profile-preview-wrap { text-align: center; padding: 20px 12px; background: rgba(0,0,0,.16); border: 1px solid var(--theme-metal,#bfa168); border-radius: 14px; align-self: start; }
#player-profile-preview { width: 88px; height: 88px; margin: 0 auto 14px; font-size: 34px; }
.player-profile-fields { display: grid; gap: 14px; min-width: 0; }
.player-profile-fields label { display: grid; gap: 8px; font-weight: 700; }
.player-profile-fields input[type=text] { box-sizing: border-box; width: 100%; min-height: 44px; padding: 10px 12px; background: rgba(0,0,0,.22); border: 1px solid var(--theme-metal,#bfa168); border-radius: 8px; color: inherit; font: inherit; }
.player-profile-fields fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.player-profile-fields legend { margin-bottom: 10px; }
#player-profile-choices { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }
#game-function-profile-panel button { min-height: 44px; background: rgba(0,0,0,.22); color: inherit; border: 1px solid var(--theme-metal,#bfa168); border-radius: 10px; padding: 8px 10px; font: inherit; cursor: pointer; }
#player-profile-choices button { display: grid; justify-items: center; gap: 7px; font-size: 13px; }
#player-profile-choices .avatar { width: 48px; height: 48px; }
#player-profile-choices button[aria-pressed=true] { outline: 2px solid var(--theme-metal,#ffe29a); outline-offset: 2px; background: var(--theme-mid,#5b4531); }
#game-function-profile-panel [type=submit] { background: var(--theme-mid,#217568); font-weight: 800; }
#player-profile-status { min-height: 2.5em; margin: 0; line-height: 1.5; }
.player-profile-hint { font-size: 13px; line-height: 1.5; opacity: .85; margin: 0; }
.player-profile-fields input[type=file] { max-width: 100%; font: inherit; font-size: 13px; }
#game-function-profile-panel :focus-visible { outline: 3px solid var(--theme-metal,#ffe29a); outline-offset: 3px; }
@media (max-width:600px) { .player-profile-form { grid-template-columns: 1fr; gap: 14px; } .player-profile-preview-wrap { display: flex; align-items: center; gap: 14px; padding: 10px; } #player-profile-preview { width: 60px; height: 60px; margin: 0; } #player-profile-choices { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (max-height:450px) and (min-width:601px) { .player-profile-panel { padding: 0 14px 16px; } .player-profile-form { grid-template-columns: 110px minmax(0,1fr); gap: 16px; } .player-profile-fields { gap: 10px; } #player-profile-preview { width: 68px; height: 68px; } }
