/* Scoped member profiles: inline references retain the surrounding typography. */
button.member-profile-trigger {
  display: inline;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--green);
  font: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  text-align: inherit;
  text-transform: inherit;
  text-decoration-line: underline;
  text-decoration-style: dotted;
  text-decoration-color: rgba(87, 227, 41, 0.6);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.16em;
  cursor: pointer;
}
button.member-profile-trigger:hover {
  color: var(--text);
  text-decoration-style: solid;
}
button.member-profile-trigger:focus-visible,
.member-profile-dialog :focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 4px;
  border-radius: 3px;
}

/* A card or standings row with one documented owner uses one generous target,
   rather than competing inline links for its team and manager text. */
.member-profile-container-trigger {
  cursor: pointer;
}
.card.member-profile-container-trigger:hover {
  border-color: var(--green);
}
.member-profile-container-trigger:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
}
tr.member-profile-container-trigger > * {
  cursor: pointer;
}
tr.member-profile-container-trigger:hover > * {
  background: rgba(87, 227, 41, 0.055);
}
tr.member-profile-container-trigger:focus-visible > * {
  box-shadow: inset 0 2px 0 var(--green), inset 0 -2px 0 var(--green);
}
.record-line.member-profile-container-trigger {
  margin-inline: -10px;
  padding-inline: 10px;
  border-radius: 7px;
}
.record-line.member-profile-container-trigger:hover {
  background: rgba(87, 227, 41, 0.075);
  box-shadow: inset 3px 0 0 var(--green);
}
.record-line.member-profile-container-trigger:focus-visible {
  background: rgba(87, 227, 41, 0.075);
  box-shadow: inset 3px 0 0 var(--green);
}
.member-profile-dialog {
  width: min(960px, calc(100% - 40px));
  max-width: none;
  max-height: calc(100vh - 48px);
  max-height: calc(100dvh - 48px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-top: 3px solid var(--green);
  border-radius: 18px;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, Arial, sans-serif;
  line-height: 1.55;
  box-shadow: 0 24px 100px rgba(0, 0, 0, 0.55);
}
.member-profile-dialog[open] {
  display: flex;
  flex-direction: column;
}
.member-profile-dialog::backdrop {
  background: rgba(2, 6, 3, 0.83);
}
.member-profile-toolbar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 66px;
  padding: 10px 24px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.member-profile-kicker {
  display: block;
  color: var(--green);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.member-profile-close {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface2);
  color: var(--text);
  font: 600 0.82rem Inter, Arial, sans-serif;
  cursor: pointer;
}
.member-profile-close > span:first-child {
  font-size: 1.5rem;
  line-height: 1;
}
.member-profile-close:hover {
  border-color: var(--green);
}
.member-profile-scroll {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-color: var(--line) var(--bg);
}
.member-profile-header {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  padding: 36px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.member-profile-monogram {
  display: grid;
  place-items: center;
  width: 92px;
  height: 106px;
  border: 1px solid var(--line);
  border-top: 3px solid var(--green);
  border-radius: 10px;
  background: var(--surface2);
  color: var(--green);
  font: 800 3rem/1 "Barlow Condensed", sans-serif;
  letter-spacing: -0.03em;
}
.member-profile-status {
  color: var(--muted);
  font-size: 0.69rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.member-profile-status.is-active {
  color: var(--green);
}
.member-profile-header h2 {
  margin: 8px 0;
  font-family: "Barlow Condensed", sans-serif;
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  font-weight: 800;
  line-height: 0.95;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.member-profile-header p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.81rem;
}
.member-profile-header .member-profile-header-team {
  margin-top: 14px;
  color: var(--text);
  font-size: 1.15rem;
  font-weight: 600;
}
.member-profile-content {
  padding: 30px 36px 24px;
}
.member-profile-section + .member-profile-section {
  margin-top: 34px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}
.member-profile-section h3 {
  margin: 0 0 18px;
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.1;
}
.member-profile-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.member-profile-stat {
  min-width: 0;
  padding: 17px 15px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}
.member-profile-stat > span {
  display: block;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.member-profile-stat > strong {
  display: block;
  margin: 6px 0;
  color: var(--green);
  font: 800 clamp(1.65rem, 3.8vw, 2.6rem)/1.1 "Barlow Condensed", sans-serif;
  overflow-wrap: anywhere;
}
.member-profile-stat > small {
  display: block;
  color: var(--muted);
  font-size: 0.68rem;
}
.member-profile-note {
  margin: 12px 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.65;
}
.member-profile-points {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 36px;
  margin: 18px 0 0;
}
.member-profile-points dt {
  color: var(--muted);
  font-size: 0.74rem;
}
.member-profile-points dd {
  margin: 3px 0 0;
  font-size: 1.2rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.member-profile-team {
  margin: -5px 0 16px;
  font-size: 1.18rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.member-profile-ranks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.member-profile-ranks .member-profile-stat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.member-profile-ranks .member-profile-stat strong {
  margin: 0;
}
.member-profile-first-pick {
  margin: 24px 0 16px;
}
.member-profile-first-pick > strong {
  display: block;
  margin: 4px 0;
  font: 700 2rem/1.1 "Barlow Condensed", sans-serif;
  text-transform: uppercase;
}
.member-profile-first-pick > span:last-child {
  color: var(--muted);
  font-size: 0.77rem;
}
.member-profile-positions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.member-profile-positions li {
  padding: 6px 11px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--muted);
  background: var(--surface);
  font-size: 0.73rem;
}
.member-profile-positions strong {
  padding-right: 4px;
  color: var(--text);
}
.member-profile-draft summary,
.member-profile-source-notes summary {
  width: fit-content;
  padding: 9px 0;
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}
.member-profile-draft[open] summary {
  margin-bottom: 8px;
}
.member-profile-honors,
.member-profile-team-history {
  margin: 0;
  padding: 0;
  list-style: none;
}
.member-profile-honors li,
.member-profile-team-history li {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px 24px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.84rem;
}
.member-profile-honors li:last-child,
.member-profile-team-history li:last-child {
  border-bottom: 0;
}
.member-profile-honors strong,
.member-profile-team-history strong {
  font-weight: 600;
}
.member-profile-honors li > span,
.member-profile-team-history span {
  color: var(--muted);
  text-align: right;
}
.member-profile-honors li > div > *,
.member-profile-honors small {
  display: block;
}
.member-profile-honors small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 400;
}
.member-profile-honors li > .member-profile-achievement-value {
  color: var(--gold);
  font-size: 1rem;
  font-weight: 700;
  white-space: nowrap;
}
.member-profile-table-wrap {
  max-width: 100%;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  scrollbar-color: var(--line) var(--bg);
}
.member-profile-table {
  width: 100%;
  min-width: 660px;
  border-collapse: collapse;
  font-size: 0.78rem;
}
.member-profile-table th,
.member-profile-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.member-profile-table thead th {
  background: var(--surface2);
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 600;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}
.member-profile-table tbody th {
  color: var(--text);
  font-weight: 700;
}
.member-profile-table td strong {
  font-weight: 500;
}
.member-profile-table td:nth-child(2) {
  min-width: 150px;
  white-space: normal;
}
.member-profile-table td small {
  display: block;
  max-width: 230px;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.5;
}
.member-profile-table tr:last-child > * {
  border-bottom: 0;
}
.member-profile-table .member-profile-champion-row {
  background: rgba(242, 201, 76, 0.035);
}
.member-profile-champion-row > :last-child {
  color: var(--gold);
  font-weight: 600;
}
.member-profile-record-flag {
  color: var(--gold);
  padding-left: 3px;
}
.member-profile-draft .member-profile-table {
  min-width: 420px;
}
.member-profile-draft .member-profile-table td:nth-child(2) {
  min-width: auto;
}
.member-profile-source-notes {
  margin-top: 28px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}
.member-profile-source-notes ul {
  margin: 10px 0;
  padding-left: 20px;
  color: var(--muted);
  font-size: 0.76rem;
}
.member-profile-source-notes li + li {
  margin-top: 8px;
}
.member-profile-provenance {
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 0.68rem;
}
@media (max-width: 900px) {
  .member-profile-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .member-profile-stat > strong {
    font-size: 2.25rem;
  }
  .member-profile-header {
    padding: 28px;
  }
  .member-profile-content {
    padding: 26px 28px;
  }
}
@media (max-width: 600px) {
  .member-profile-dialog {
    width: calc(100% - 16px);
    max-height: calc(100vh - 20px);
    max-height: calc(100dvh - 20px);
    border-radius: 12px;
  }
  .member-profile-toolbar {
    min-height: 60px;
    padding: 8px 15px;
  }
  .member-profile-header {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    padding: 24px 20px;
  }
  .member-profile-monogram {
    width: 56px;
    height: 60px;
    font-size: 2rem;
  }
  .member-profile-header h2 {
    font-size: 2.7rem;
  }
  .member-profile-content {
    padding: 24px 18px;
  }
  .member-profile-stats,
  .member-profile-ranks {
    gap: 9px;
  }
  .member-profile-stat {
    padding: 14px 11px;
  }
  .member-profile-stat > strong {
    font-size: 1.95rem;
  }
  .member-profile-stat > span {
    font-size: 0.61rem;
  }
  .member-profile-ranks .member-profile-stat {
    display: block;
  }
  .member-profile-ranks .member-profile-stat strong {
    margin-top: 8px;
  }
  .member-profile-honors li,
  .member-profile-team-history li {
    gap: 10px;
    font-size: 0.78rem;
  }
  .member-profile-team-history li {
    flex-direction: column;
    gap: 3px;
  }
  .member-profile-team-history span {
    text-align: left;
  }
}
