body.profile-open > header,
body.profile-open > main,
body.profile-open > footer {
  display: none;
}
#player-page[hidden] {
  display: none;
}
#player-page {
  position: fixed;
  inset: 0;
  z-index: 12;
  overflow: auto;
  background: #11191b;
  color: var(--text);
}
#player-page .player-header {
  height: auto;
  min-height: 110px;
  display: flex;
  gap: 25px;
  align-items: center;
  padding: 20px 30px;
  border-bottom: 1px solid var(--line);
}
.player-header h1 {
  font-size: 26px;
  margin: 0;
  color: var(--gold);
  font-family: Cinzel, Georgia, serif;
}
.player-header p {
  margin: 7px 0;
}
.player-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.player-actions button,
#player-manage {
  border: 1px solid var(--line);
}
.player-layout {
  display: grid;
  grid-template-columns: 235px minmax(0, 1fr);
  gap: 24px;
  padding: 24px;
  max-width: 1700px;
  margin: auto;
}
.player-layout .player-roster {
  margin: 0;
  padding: 14px;
  border: 1px solid var(--line);
  max-height: none;
  align-self: start;
  overflow: visible;
}
.player-roster h2 {
  font-size: 21px;
  margin: 6px 0 15px;
}
.player-roster-card {
  display: block;
  width: 100%;
  padding: 14px;
  text-align: left;
  border: 1px solid #71664b88;
  margin: 10px 0;
}
.player-roster-card strong,
.player-roster-card span {
  display: block;
}
.player-roster-card span {
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
}
.player-roster-card[aria-pressed='true'] {
  border-color: var(--gold);
  background: #c8b17c15;
}
.player-portrait {
  position: relative;
  border: 1px solid var(--line);
  background-size: cover;
  background-position: center;
  border-radius: 5px;
  padding: 75px 12px 10px;
}
.player-portrait canvas {
  display: block;
  width: 100%;
  height: clamp(310px, 55vh, 680px);
  object-fit: contain;
}
.player-portrait-title {
  position: absolute;
  left: 20px;
  top: 14px;
  padding: 10px 16px;
  background: #101719df;
  border-radius: 4px;
}
.player-portrait-title h2 {
  font-size: 25px;
  margin: 0 0 5px;
  color: #e5cd9b;
}
.player-details {
  padding: 25px;
  background: #101719;
  border: 1px solid var(--line);
  margin-top: 20px;
}
.player-details h2 {
  font-size: 25px;
}
.player-details h3 {
  font-size: 21px;
  font-weight: bold;
  color: #dfc897;
  margin-top: 28px;
}
.player-details p {
  font-size: 14px;
  line-height: 1.7;
}
.player-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}
.player-stat-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}
.player-stat-grid > div {
  border: 1px solid #71664b80;
  padding: 12px;
}
.player-stat-grid b {
  display: block;
  font-size: 29px;
  color: var(--gold);
  margin: 8px 0;
}
.player-stat-grid small {
  font-size: 11px;
  line-height: 1.4;
  display: block;
}
.player-build {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 15px;
  font-size: 13px;
  line-height: 1.5;
}
.player-build dt {
  color: var(--muted);
}
.player-build dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.player-build-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 25px;
}
.player-empty {
  padding: 50px;
  border: 1px solid var(--line);
}
#player-render-status {
  position: absolute;
  bottom: 5px;
  left: 20px;
}
#lineage-info-content h3 {
  font-size: 21px;
  font-weight: 700;
  color: var(--gold);
  margin: 23px 0 9px;
}
#lineage-info-content p {
  font-size: 15px;
  line-height: 1.7;
}
#lineage-info-content .signature-move strong {
  font-size: 17px;
  color: #e2cba0;
}
@media (max-width: 850px) {
  #player-page .player-header {
    flex-wrap: wrap;
    padding: 16px;
  }
  .player-layout {
    display: block;
    padding: 12px;
  }
  .player-layout .player-roster {
    margin-bottom: 15px;
  }
  .player-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .player-build-columns {
    grid-template-columns: 1fr;
  }
  .player-portrait canvas {
    height: 350px;
  }
  .player-actions {
    margin: 0;
  }
  .player-details {
    padding: 16px;
  }
}

.player-portrait .portrait-replay {
  position: absolute;
  right: 18px;
  top: 18px;
  z-index: 3;
  padding: 12px 17px;
  border: 2px solid #c7ad72;
  background: #171d1bf0;
  color: #fff0c9;
  font-weight: bold;
  box-shadow: 0 3px 15px #0009;
}
.player-portrait-title {
  max-width: calc(100% - 300px);
}
button.danger {
  border-color: #b36f64;
  color: #ffd1c8;
  background: #442824;
}
#delete-faravar-dialog {
  width: min(540px, calc(100vw - 40px));
  padding: 30px;
  color: #efe5cd;
  background: #1c2423;
  border: 1px solid #a99465;
}
#delete-faravar-dialog::backdrop {
  background: #000b;
}
#delete-faravar-dialog input {
  display: block;
  box-sizing: border-box;
  width: 100%;
  margin: 12px 0;
  padding: 12px;
  background: #101716;
  color: #fff;
  border: 1px solid #a99465;
  font: inherit;
}
.delete-actions {
  display: flex;
  gap: 15px;
  justify-content: flex-end;
  flex-wrap: wrap;
}
#delete-error {
  color: #ffd1c8;
  min-height: 1.4em;
}
@media (max-width: 700px) {
  .player-portrait-title {
    max-width: none;
  }
  .player-portrait .portrait-replay {
    top: 80px;
    right: 12px;
    padding: 9px;
  }
  .player-portrait {
    padding-top: 130px;
  }
}
/* Delete section and the My account dialog (account-settings.js). */
.player-delete-section {
  margin-top: 50px;
  border-top: 1px solid #71524b;
  padding: 28px 0 10px;
}
#my-account-dialog {
  max-width: 600px;
  padding: 32px;
  background: #1c2423;
  color: #efe5cd;
  border: 1px solid #a99465;
}
#my-account-dialog input {
  display: block;
  box-sizing: border-box;
  width: 100%;
  padding: 12px;
  margin: 8px 0 18px;
  background: #101716;
  color: white;
  border: 1px solid #a99465;
}
#my-account-dialog hr {
  margin: 28px 0;
  border-color: #63523b;
}
#account-delete-error {
  color: #ffd1c8;
}
