/* Owner: profile. Component states and responsive rules live here. See AGENTS.md. */

.archetype-tab {
  position: relative;
  display: grid;
  gap: 8px;
  place-items: center;
  cursor: pointer;
  color: var(--text);
}

.archetype-tab::after {
  position: absolute;
  background: transparent;
  content: "";
}

.archetype-tab.active::after {
  background: var(--green);
}

.archetype-icon {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border: 3px solid rgba(255, 255, 255, 0.86);
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.9);
}

.archetype-tab.active .archetype-icon {
  border-color: var(--text);
  color: var(--text);
}

.archetype-icon.image-icon {
  border: 0;
  border-radius: 0;
}

.archetype-icon svg {
  width: 32px;
  height: 32px;
}

.archetype-icon img {
  display: block;
  width: 58px;
  height: 58px;
  object-fit: contain;
}

.archetype-name {
  min-height: 28px;
  font-size: 0.7rem;
  font-weight: 900;
  line-height: 1.05;
  text-align: center;
}

.radar-panel {
  display: grid;
}

.ovr-summary {
  display: grid;
  width: 100%;
}

.ovr-score {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 0;
}

.ovr-score span,
.ovr-position-field > span {
  font-weight: 900;
  text-transform: uppercase;
}

.ovr-score output {
  font-weight: 950;
  line-height: 1;
}

.ovr-position-field {
  display: grid;
  align-content: center;
  gap: 6px;
}

.ovr-position-field select {
  width: 100%;
  min-width: 0;
  border: 0;
  border-bottom: 1px solid #3a485a;
  outline: 0;
  background: transparent;
  font: inherit;
  font-weight: 900;
}

.ovr-position-field select:focus-visible {
  border-color: var(--green);
}

.ovr-position-field option {
  background: #101318;
  color: #f6f8fb;
}

.accelerate-pill {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 10px;
}

.accelerate-pill span {
  color: #a9b2c1;
  font-size: 0.72rem;
  font-weight: 700;
}

.accelerate-pill strong {
  font-weight: 900;
}

.level-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.82rem;
}

.level-row output {
  display: inline-grid;
  place-items: center;
  font-weight: 900;
}

.stat-list {
  display: grid;
  margin: 18px 0 0;
}

.stat-list div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.stat-list dd {
  margin: 0;
  font-weight: 900;
}

.stat-list dd::before {
  color: var(--gold);
}

.body-control {
  margin-top: 18px;
}

.body-control output {
  background: transparent;
  font-size: 1.55rem;
}

.suggested-positions-panel {
  overflow: hidden;
}

.suggested-positions {
  place-items: center;
}

.suggested-positions-empty {
  margin: 0;
  color: var(--subtle);
  font-size: 0.78rem;
  text-align: center;
}

.scale-row {
  display: flex;
  justify-content: space-between;
  padding: 0 2px;
}

.pace-control-row {
  margin: 0;
}

.pace-control-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.pace-control-label {
  min-width: 0;
  font-weight: 900;
}

.profile-body-panel {
  display: grid;
  gap: 10px;
}

.profile-body-panel .profile-body-heading {
  margin-bottom: 0;
}

.profile-body-heading h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.profile-body-heading h2 svg {
  width: 17px;
  height: 17px;
  color: var(--green);
}

.pace-range-control {
  display: grid;
  gap: 2px;
  margin-top: 7px;
}

.pace-range-control .range {
  margin: 0;
}

.pace-range-control .scale-row {
  color: #8b9691;
  font-size: 0.78rem;
  font-weight: 700;
}

@media (max-width: 860px) {
  .suggested-positions {
    min-height: 230px;
  }

  .archetype-tabs {
    gap: 10px;
  }
}

html:is([data-theme="light"],[data-theme="dark"]) .archetype-strip,
html:is([data-theme="light"],[data-theme="dark"]) .archetype-position-group .archetype-tab {
  background: var(--custom-tab-bg);
}

html:root #level-profile-button {
  gap: 0;
  padding-inline: 12px;
  white-space: nowrap;
}

html:root #level-profile-button .profile-button-summary {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  min-width: 0;
  font-variant-numeric: tabular-nums;
}

html:root #level-profile-button .profile-button-item {
  display: inline-flex;
  align-items: baseline;
  gap: 2px;
}

html:root #level-profile-button .profile-button-item strong {
  font-size: 14px;
  font-weight: 850;
  letter-spacing: -.035em;
}

html:root #level-profile-button .profile-button-item small {
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .06em;
}

html:root #level-profile-button .profile-button-separator {
  color: var(--subtle);
  font-size: 11px;
  font-weight: 500;
}

html:root #level-profile-button .profile-button-type {
  color: var(--brand-green-dark);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: -.02em;
}

html:root .archetype-strip {
  display: grid;
  grid-template-columns: minmax(0,1fr) 32px;
  align-items: start;
  gap: 8px;
  margin: 0 0 20px;
  padding: 8px;
  border: 1px solid var(--pencil-soft);
  border-radius: var(--radius-sm);
  background: var(--surface-card);
  box-shadow: var(--shadow-paper);
}

html:root .archetype-scroll {
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}

html:root .archetype-strip-toggle {
  display: grid;
  place-items: center;
  width: 32px;
  min-width: 32px;
  height: 32px;
  min-height: 32px;
  padding: 6px;
  border: 0;
  background: transparent;
  color: var(--text);
  box-shadow: none;
}

html:root .archetype-strip-toggle svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

html:root .archetype-strip-toggle:hover {
  color: var(--green);
}

html:root .archetype-strip-toggle:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

html:root .archetype-strip.archetype-strip-collapsed {
  padding-block: 2px;
}

html:root .archetype-strip-collapsed .archetype-position-label,
html:root .archetype-strip-collapsed .archetype-icon,
html:root .archetype-strip-collapsed .archetype-pencil-ring {
  display: none;
}

html:root .archetype-strip-collapsed .archetype-position-group {
  grid-template-rows: minmax(0,1fr);
}

html:root .archetype-strip-collapsed #archetype-list .archetype-tab {
  min-height: 24px;
  padding-block: 4px;
  gap: 0;
}

html:root .archetype-strip-collapsed .archetype-name {
  min-height: 0;
}

html:root .archetype-strip-collapsed #archetype-list .archetype-tab.active .archetype-name {
  color: #DF2027;
}

html:root .archetype-strip-collapsed #archetype-list .archetype-tab::before {
  inset-block: 4px;
}

html:root .archetype-strip-collapsed .archetype-strip-toggle {
  height: 24px;
  min-height: 24px;
  padding: 2px;
}

html:root .archetype-strip-collapsed .archetype-strip-toggle svg {
  transform: rotate(180deg);
}

@media (pointer: coarse) {
  html:root .archetype-strip {
    grid-template-columns: minmax(0,1fr) 44px;
  }

  html:root .archetype-strip-toggle,
  html:root .archetype-strip-collapsed .archetype-strip-toggle {
    width: 44px;
    min-width: 44px;
    height: 44px;
    min-height: 44px;
  }

  html:root .archetype-strip-collapsed #archetype-list .archetype-tab {
    min-height: 44px;
  }
}

html:root #archetype-list {
  display: grid;
  grid-template-columns: repeat(13,minmax(0,1fr));
  width: max(100%,1160px);
  min-width: 1160px;
  gap: 12px;
  padding: 0;
  overflow: visible;
}

html:root .archetype-position-group {
  display: grid;
  grid-column: span var(--archetype-group-size);
  grid-template-rows: auto 1fr;
  padding: 0;
  border: 0;
  min-width: 0;
}

html:root .archetype-position-label {
  min-height: 25px;
  margin: 0 0 6px;
  padding: 2px 7px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: 600 11px/1.5 'Inter','Noto Sans KR',sans-serif;
  letter-spacing: .06em;
}

html:root .archetype-position-label::before {
  display: none;
}

html:root .archetype-position-items {
  display: grid;
  grid-template-columns: repeat(var(--archetype-group-size),minmax(0,1fr));
  gap: 5px;
}

html:root #archetype-list .archetype-tab {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 86px;
  padding: 8px 4px 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-xs);
  background: transparent;
  box-shadow: none;
  transform: none;
  color: var(--text);
}

html:root #archetype-list .archetype-tab::before {
  content: '';
  position: absolute;
  inset: 12px -4px 12px auto;
  width: 1px;
  background: var(--pencil-soft);
  pointer-events: none;
  z-index: -1;
}

html:root #archetype-list .archetype-tab:last-child::before,
html:root #archetype-list .archetype-tab::after {
  content: none;
}

html:root #archetype-list .archetype-tab:hover,
html:root #archetype-list .archetype-tab.active:hover {
  border-color: transparent;
  background: color-mix(in srgb, var(--surface-raised) 45%, var(--paper-muted));
}

html:root #archetype-list .archetype-tab:active:not(:disabled) {
  border-color: transparent !important;
  background: transparent !important;
  color: var(--text) !important;
  box-shadow: none !important;
}

html:root #archetype-list .archetype-tab.active {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

html:root #archetype-list .archetype-tab.active::after {
  content: none;
}

html:root .archetype-pencil-ring {
  position: absolute;
  z-index: 0;
  inset: 0 1px -2px;
  width: calc(100% - 2px);
  height: calc(100% + 2px);
  overflow: visible;
  pointer-events: none;
  transform: translateY(-2px) rotate(-.8deg);
}

html:root .archetype-pencil-ring path {
  fill: none;
  stroke: #DF2027;
  stroke-width: 2.55;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 400 400;
  stroke-dashoffset: 400;
  vector-effect: non-scaling-stroke;
  opacity: 0;
}

html:root #archetype-list .archetype-tab.active .archetype-pencil-ring path {
  opacity: .9;
  animation: archetype-pencil-draw 540ms cubic-bezier(.24,.72,.28,1) forwards;
}

html:root #archetype-list .archetype-tab > :not(.archetype-pencil-ring) {
  position: relative;
  z-index: 1;
}

html:root .archetype-position-group .archetype-icon,
html:root .archetype-position-group .archetype-icon img {
  width: 35px;
  height: 35px;
}

html:root #archetype-list .archetype-icon {
  color: var(--archetype-icon-contrast);
}

html:root #archetype-list .archetype-icon img {
  filter: var(--archetype-icon-filter);
  opacity: .82;
}

html:root .archetype-position-group .archetype-name {
  font-size: 12px;
  font-weight: 650;
  color: var(--text);
  letter-spacing: -.04em;
}

html:root #archetype-list .archetype-tab.active .archetype-name {
  color: var(--text);
  font-weight: 800;
}

html:root .profile-dialog {
  border: 1px solid var(--line-strong);
  font-size: 14px;
}

html:root .profile-dialog {
  position: fixed;
  inset: 0;
  width: min(560px,calc(100% - 28px));
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 22px;
  overflow: auto;
  overscroll-behavior: contain;
}

html:root #level-profile-dialog {
  width: min(1120px,calc(100% - 28px));
}

html:root #level-profile-dialog .player-profile-layout {
  display: grid;
  grid-template-columns: minmax(0,.9fr) minmax(430px,1.1fr);
  align-items: start;
  gap: 32px;
}

html:root #level-profile-dialog .profile-body-panel {
  min-width: 0;
  padding-left: 32px;
  row-gap: 10px;
  border-left: 1px solid var(--pencil-soft);
}

html:root #level-profile-dialog .profile-body-heading {
  padding-bottom: 2px;
}

html:root .profile-dialog .panel {
  width: 100%;
  min-width: 0;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

html:root .profile-dialog .stat-list {
  margin: 20px 0 0;
  gap: 0;
}

html:root .profile-dialog .stat-list > div {
  min-height: 48px;
  padding: 13px 0;
  border-color: var(--line);
}

html:root .profile-dialog .stat-list dt {
  font-size: 13px;
  color: var(--muted);
}

html:root .profile-dialog .stat-list dd {
  font-size: 16px;
  color: var(--number);
  font-variant-numeric: tabular-nums;
}

html:root .profile-dialog .level-row {
  margin: 0 0 18px;
  color: var(--muted);
}

html:root .profile-dialog .level-row output {
  font: 850 46px/1 'Inter',sans-serif;
  color: var(--number);
}

html:root #level-slider {
  height: 32px;
  margin: 0;
  cursor: pointer;
}

html:root .profile-dialog .ovr-summary {
  display: grid;
  grid-template-columns: 138px minmax(0,1fr);
  gap: 22px;
  align-items: center;
}

html:root .profile-dialog .ovr-score {
  border: 0;
  align-items: start;
  padding: 0;
}

html:root .profile-dialog .ovr-score output {
  font: 850 76px/1 'Inter',sans-serif;
  color: var(--number);
  letter-spacing: -.06em;
}

html:root .profile-dialog .ovr-score span {
  font-size: 12px;
  color: var(--muted);
}

html:root .profile-dialog .ovr-position-field {
  width: 100%;
  gap: 10px;
}

html:root .profile-dialog .ovr-position-field select {
  min-height: 42px;
  padding: 6px 10px;
  font-size: 16px;
}

html:root .profile-dialog .accelerate-pill {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  margin-top: 22px;
  padding: 14px;
  gap: 12px;
  background: var(--surface-card);
  border: 1px solid var(--line);
  border-radius: 4px;
}

html:root .profile-dialog .accelerate-pill strong {
  font-size: 17px;
  color: var(--green);
}

html:root .profile-dialog .profile-level-panel {
  margin-top: 22px;
}

html:root .profile-dialog .suggested-positions-panel {
  margin-top: 22px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
}

html:root .profile-dialog .suggested-positions-panel h2 {
  font-size: 14px;
}

html:root .profile-dialog .position-code-list {
  display: block;
  margin-top: 12px;
  color: var(--text);
  font-size: 15px;
  line-height: 2;
}

html:root .position-code:not(:last-child)::after {
  content: '·';
  margin: 0 10px;
  color: var(--subtle);
}

html:root .profile-dialog .profile-body-panel {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 16px 24px;
}

html:root .profile-dialog .body-control {
  margin: 0;
  padding: 0;
  border: 0;
}

html:root .profile-dialog .pace-control-label {
  font-size: 13px;
  color: var(--muted);
}

html:root .profile-dialog .pace-range-control {
  overflow: visible;
}

html:root .profile-dialog .profile-body-panel .range {
  height: 32px;
  min-height: 32px;
  margin: 0;
  cursor: pointer;
}

html:root .scale-row {
  font-size: 11px;
  color: var(--muted);
}

.body-pad-readout {
  grid-column: 1/-1;
  text-align: center;
  color: var(--green);
  font-size: 28px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.body-pad-frame {
  grid-column: 1/-1;
  display: grid;
  grid-template-columns: 42px minmax(0,1fr) 42px;
  grid-template-rows: 20px auto 20px;
  gap: 8px;
  width: 100%;
  max-width: 440px;
  margin: auto;
  align-items: center;
  justify-items: center;
}

.body-pad-frame > span {
  font-size: 10px;
  color: var(--muted);
  text-align: center;
  white-space: nowrap;
}

.body-axis-top {
  grid-column: 2;
  grid-row: 1;
}

.body-axis-bottom {
  grid-column: 2;
  grid-row: 3;
}

.body-axis-left {
  grid-column: 1;
  grid-row: 2;
}

.body-axis-right {
  grid-column: 3;
  grid-row: 2;
}

.body-pad {
  position: relative;
  grid-column: 2;
  grid-row: 2;
  width: 100%;
  aspect-ratio: 1;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background-color: var(--surface-card);
  background-image: linear-gradient(to right,transparent calc(50% - .5px),var(--green) calc(50% - .5px),var(--green) calc(50% + .5px),transparent calc(50% + .5px)),linear-gradient(to bottom,transparent calc(50% - .5px),var(--green) calc(50% - .5px),var(--green) calc(50% + .5px),transparent calc(50% + .5px));
  cursor: crosshair;
  touch-action: none;
  user-select: none;
}

.body-pad-dot {
  position: absolute;
  width: 18px;
  height: 18px;
  border: 3px solid var(--text);
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 5px color-mix(in srgb,var(--green) 18%,transparent),0 2px 9px #0009;
  transform: translate(-50%,-50%);
  pointer-events: none;
}

@media (max-width: 1200px) and (min-width: 801px) {
  html:root #level-profile-button .profile-button-summary {
    gap: 4px;
  }

  html:root #level-profile-button .profile-button-item strong {
    font-size: 12px;
  }
}

@media (max-width: 800px) {
  html:root #level-profile-button {
    grid-column: 1/-1;
    min-height: 40px;
    padding-inline: 6px;
  }

  html:root #level-profile-button .profile-button-summary {
    justify-content: center;
    gap: 4px;
  }

  html:root #level-profile-button .profile-button-item strong {
    font-size: 13px;
  }

  html:root .archetype-strip {
    margin-bottom: 18px;
    padding: 6px;
  }

  html:root #archetype-list {
    width: 1160px;
    min-width: 1160px;
  }

  html:root .profile-dialog {
    padding: 17px;
  }

  html:root .profile-dialog .ovr-summary {
    grid-template-columns: 100px minmax(0,1fr);
    gap: 16px;
  }

  html:root .profile-dialog .ovr-score output {
    font-size: 64px;
  }

  html:root .profile-dialog .profile-body-panel {
    column-gap: 14px;
  }

  .body-pad-frame {
    grid-template-columns: 32px minmax(0,1fr) 32px;
    gap: 5px;
  }

}

@media (max-width: 900px) {
  html:root #level-profile-dialog .player-profile-layout {
    grid-template-columns: minmax(0,1fr);
    gap: 24px;
  }

  html:root #level-profile-dialog .profile-body-panel {
    padding: 24px 0 0;
    border-top: 1px solid var(--pencil-soft);
    border-left: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html:root #archetype-list .archetype-tab.active .archetype-pencil-ring path {
    stroke-dashoffset: 0;
  }
}

html:root .profile-dialog::backdrop {
  background: rgba(42,38,32,.36);
  backdrop-filter: blur(2px);
}

html:root .profile-dialog {
  --text: var(--ink-strong);
  --muted: var(--ink-muted);
  --subtle: var(--ink-subtle);
  --panel: var(--paper-main);
  --surface-card: var(--paper-main);
  --surface-board: var(--paper-main);
  --surface-raised: var(--paper-raised);
  --input-bg: var(--paper-raised);
  --line: var(--pencil-soft);
  --line-strong: var(--pencil-strong);
  background: var(--paper-main);
  color: var(--text);
  border-color: var(--pencil-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-popover);
}

html:root .profile-dialog .body-pad {
  background-color: var(--paper-main);
  background-image: linear-gradient(to right,transparent calc(50% - .5px),var(--pencil-soft) calc(50% - .5px),var(--pencil-soft) calc(50% + .5px),transparent calc(50% + .5px)),linear-gradient(to bottom,transparent calc(50% - .5px),var(--pencil-soft) calc(50% - .5px),var(--pencil-soft) calc(50% + .5px),transparent calc(50% + .5px));
}

html:root .profile-dialog .body-pad-dot {
  box-shadow: var(--shadow-control);
}

html:root .profile-dialog .accelerate-pill span {
  color: var(--ink-muted);
}

html:root .builder-stage > #level-profile-dialog.profile-drawer {
  grid-area: profile;
  position: static;
  display: grid;
  width: 100%;
  max-width: none;
  min-width: 0;
  max-height: none;
  align-content: start;
  gap: 8px;
  margin: 0;
  padding: 10px;
  overflow: visible;
  border: 1px solid var(--pencil-soft);
  border-radius: var(--radius-md);
  background: var(--paper-main);
  box-shadow: var(--shadow-paper);
  color: var(--text);
  transition: padding .28s ease, gap .28s ease;
}

html:root #level-profile-dialog .profile-drawer-heading {
  min-width: 0;
  margin: 0 0 2px;
  padding: 0 0 8px;
  border-bottom: 1px solid var(--pencil-soft);
}

html:root #level-profile-dialog .profile-drawer-heading h2 {
  width: 100%;
  margin: 0;
  padding: 0;
  background: transparent;
  font-size: inherit;
}

html:root #level-profile-dialog .profile-drawer-toggle {
  display: flex;
  width: 100%;
  min-height: 34px;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  padding: 2px 4px;
  border: 0;
  border-radius: var(--radius-xs);
  background: transparent;
  color: var(--text);
  font: inherit;
  text-align: left;
}

html:root #level-profile-dialog .profile-drawer-toggle > span {
  position: relative;
  isolation: isolate;
  padding: 4px 7px 5px;
  font-size: 19px;
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -.055em;
  white-space: nowrap;
}

html:root #level-profile-dialog .profile-drawer-toggle > span::after {
  content: '';
  position: absolute;
  z-index: -1;
  inset: auto 3px var(--title-marker-bottom);
  height: var(--title-marker-height);
  background: var(--title-marker-color);
  transform: rotate(var(--title-marker-angle));
  pointer-events: none;
}

html:root #level-profile-dialog .profile-drawer-toggle > svg {
  display: block;
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  margin-left: auto;
  color: var(--ink-muted);
  stroke-width: 2.4;
}

html:root #level-profile-dialog .profile-drawer-toggle:hover {
  background: var(--paper-raised);
}

html:root #level-profile-dialog > .player-profile-layout {
  display: grid;
  grid-template-columns: minmax(0,1fr);
  align-items: start;
  gap: 8px;
}

html:root #level-profile-dialog .panel {
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 12px 10px;
  border: 1px solid var(--pencil-soft);
  border-radius: var(--radius-sm);
  background: transparent;
  box-shadow: none;
}

html:root #level-profile-dialog .profile-overview-panel {
  gap: 9px;
}

html:root #level-profile-dialog .ovr-summary {
  display: grid;
  grid-template-columns: 76px minmax(0,1fr);
  align-items: end;
  gap: 10px;
}

html:root #level-profile-dialog .ovr-score {
  display: grid;
  place-items: center;
  align-content: end;
  gap: 1px;
  padding: 0;
  border: 0;
}

html:root #level-profile-dialog .ovr-score span,
html:root #level-profile-dialog .ovr-position-field > span {
  width: 100%;
  color: var(--ink-muted);
  font-size: 10px;
  font-weight: 800;
  text-align: center;
}

html:root #level-profile-dialog .ovr-score output {
  color: var(--green);
  font: 850 44px/1 'Inter',sans-serif;
  letter-spacing: -.06em;
}

html:root #level-profile-dialog .ovr-position-field {
  gap: 5px;
}

html:root #level-profile-dialog .ovr-position-field select {
  min-height: 34px;
  padding: 5px 8px;
  border: 1px solid var(--pencil-soft);
  border-radius: var(--radius-xs);
  background: var(--input-bg);
  color: var(--text);
  font-size: 13px;
}

html:root #level-profile-dialog .accelerate-pill {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0;
  padding: 8px 9px;
  border: 1px solid var(--pencil-soft);
  border-radius: var(--radius-xs);
  background: var(--paper-raised);
}

html:root #level-profile-dialog .accelerate-pill span {
  color: var(--ink-muted);
  font-size: 10px;
}

html:root #level-profile-dialog .accelerate-pill strong {
  overflow: hidden;
  color: var(--green);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html:root #level-profile-dialog .profile-level-panel {
  margin: 0;
}

html:root #level-profile-dialog .level-row {
  margin: 0 0 7px;
  font-size: 11px;
}

html:root #level-profile-dialog .level-row output {
  color: var(--green);
  font: 850 26px/1 'Inter',sans-serif;
}

html:root #level-profile-dialog .profile-level-panel > .range {
  height: 26px;
  min-height: 26px;
  margin: 0;
}

html:root #level-profile-dialog .stat-list {
  display: grid;
  grid-template-columns: minmax(0,1fr);
  gap: 0;
  margin: 8px 0 0;
}

html:root #level-profile-dialog .stat-list > div {
  display: flex;
  min-height: 31px;
  align-items: baseline;
  justify-content: flex-start;
  gap: 7px;
  padding: 5px 0;
  border-top: 1px solid var(--pencil-soft);
}

html:root #level-profile-dialog .stat-list dt {
  flex: 0 0 auto;
  color: var(--ink-muted);
  font-size: 10px;
  font-weight: 650;
  line-height: 1.25;
  white-space: nowrap;
}

html:root #level-profile-dialog .stat-list dd {
  flex: 0 0 auto;
  color: var(--green);
  font-size: 14px;
  font-weight: 850;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}

html:root #level-profile-dialog .profile-body-panel {
  display: grid;
  grid-template-columns: minmax(0,1fr);
  align-content: start;
  gap: 5px;
  margin: 0;
  padding: 12px 10px;
  border: 1px solid var(--pencil-soft);
}

html:root #level-profile-dialog .profile-body-heading {
  display: flex;
  grid-column: auto;
  align-items: baseline;
  justify-content: flex-start;
  gap: 10px;
  margin: 0;
  padding: 0 0 2px;
}

html:root #level-profile-dialog .profile-body-heading h3 {
  margin: 0;
  color: var(--ink-strong);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: -.04em;
}

html:root #level-profile-dialog .body-pad-readout {
  display: inline-block;
  flex: 0 0 auto;
  color: var(--green);
  font: 850 17px/1.2 'Inter','Noto Sans KR',sans-serif;
  text-align: left;
  white-space: nowrap;
}

html:root #level-profile-dialog .body-pad-frame {
  display: grid;
  grid-column: auto;
  grid-template-columns: 24px minmax(0,192px) 24px;
  grid-template-rows: 18px auto 18px;
  gap: 2px;
  width: 100%;
  max-width: 244px;
  margin: 0 auto;
  align-items: center;
  justify-items: center;
}

html:root #level-profile-dialog .body-pad-frame > span {
  color: var(--text);
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
}

html:root #level-profile-dialog .body-axis-left {
  z-index: 2;
  justify-self: end;
  margin-right: 4px;
}

html:root #level-profile-dialog .body-axis-right {
  z-index: 2;
  justify-self: start;
  margin-left: 2px;
}

html:root #level-profile-dialog .body-pad {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  align-self: center;
  justify-self: center;
  border-color: var(--pencil-strong);
  background-color: var(--paper-raised);
  background-image: none;
}

html:root #level-profile-dialog .body-pad::before {
  content: '';
  position: absolute;
  z-index: 0;
  display: block;
  background: var(--green);
  pointer-events: none;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
}

html:root #level-profile-dialog .body-pad::after {
  content: '';
  position: absolute;
  z-index: 0;
  display: block;
  background: var(--green);
  pointer-events: none;
  top: 50%;
  right: 0;
  left: 0;
  height: 1px;
}

html:root #level-profile-dialog .body-pad-dot {
  z-index: 1;
  width: 15px;
  height: 15px;
  border-width: 2px;
  box-shadow: 0 0 0 4px color-mix(in srgb,var(--green) 18%,transparent),var(--shadow-control);
}

html:root #level-profile-dialog .profile-body-panel > .body-control {
  display: none;
}

html:root #level-profile-dialog .suggested-positions-panel {
  margin: 0;
  padding: 10px;
}

html:root #level-profile-dialog .suggested-positions-panel h2 {
  margin: 0 0 7px;
  color: var(--ink-strong);
  font-size: 12px;
  text-align: left;
}

html:root #level-profile-dialog .suggested-positions {
  display: block;
  min-height: 0;
  text-align: left;
}

html:root #level-profile-dialog .position-code-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  width: 100%;
  gap: 4px;
  margin: 0;
  color: var(--text);
  font-size: 10px;
  line-height: 1.4;
  text-align: left;
}

html:root #level-profile-dialog .position-code {
  padding: 2px 6px;
  border: 1px solid var(--pencil-soft);
  border-radius: 999px;
  background: var(--paper-raised);
  font-weight: 800;
}

html:root #level-profile-dialog .position-code:not(:last-child)::after {
  content: none;
}

html:root #level-profile-dialog .profile-drawer-summary {
  display: none;
  width: 100%;
  min-width: 0;
  min-height: 40px;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  padding: 7px 8px;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius-xs);
  background: transparent;
  color: var(--text);
  box-shadow: none;
  white-space: nowrap;
}

html:root #level-profile-dialog .profile-drawer-summary:hover {
  border-color: var(--pencil-strong);
}

html:root .builder-stage > #level-profile-dialog.profile-drawer.profile-drawer-collapsed {
  display: block;
  gap: 0;
  padding: 0;
}

html:root #level-profile-dialog.profile-drawer-collapsed > .profile-drawer-heading,
html:root #level-profile-dialog.profile-drawer-collapsed > .player-profile-layout {
  display: none;
}

html:root #level-profile-dialog.profile-drawer-collapsed > .profile-drawer-summary {
  display: flex;
}

html:root #level-profile-dialog.profile-drawer-collapsed #level-profile-button .profile-button-summary {
  display: flex;
  width: 100%;
  flex: 1 1 auto;
  justify-content: space-between;
  gap: 4px;
}

html:root #level-profile-dialog.profile-drawer-collapsed #level-profile-button .profile-button-item {
  gap: 2px;
}

html:root #level-profile-dialog.profile-drawer-collapsed #level-profile-button .profile-button-item strong {
  font-size: 15px;
}

html:root #level-profile-dialog.profile-drawer-collapsed #level-profile-button .profile-button-item small {
  font-size: 9px;
}

html:root #level-profile-dialog.profile-drawer-collapsed #level-profile-button .profile-button-separator,
html:root #level-profile-dialog.profile-drawer-collapsed #level-profile-button .profile-button-type {
  font-size: 11px;
}

html:root #level-profile-dialog #level-profile-button :is(.profile-button-item strong,.profile-button-type) {
  color: var(--green);
}

html:root #level-profile-dialog.profile-drawer-collapsed #level-profile-button > svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

@media (min-width: 801px) {
  html:root .builder-stage.profile-drawer-collapsed > #level-profile-dialog.profile-drawer {
    grid-area: profile;
    align-self: stretch;
    height: 100%;
  }

  html:root .builder-stage.profile-drawer-collapsed #level-profile-button {
    height: 100%;
  }
}

@media (min-width: 801px) and (max-width: 1599px) {
  html:root .archetype-strip {
    margin-bottom: 12px;
    padding: 6px;
  }

  html:root .archetype-position-label {
    min-height: 20px;
    margin-bottom: 3px;
  }

  html:root #archetype-list .archetype-tab {
    min-height: 70px;
    gap: 4px;
    padding-block: 5px 7px;
  }

  html:root .archetype-position-group .archetype-icon,
  html:root .archetype-position-group .archetype-icon img {
    width: 30px;
    height: 30px;
  }
}

@media (min-width: 1220px) and (max-width: 1599px) {
  html:root #archetype-list {
    width: 100%;
    min-width: 0;
    gap: 8px;
  }

  html:root #level-profile-dialog .profile-body-heading {
    gap: 5px;
  }

  html:root #level-profile-dialog .profile-body-heading h3 {
    font-size: 11px;
  }

  html:root #level-profile-dialog .body-pad-readout {
    font-size: 14px;
  }
}

@media (max-width: 800px) {
  html:root .builder-stage > #level-profile-dialog.profile-drawer {
    width: 100%;
  }

  html:root #level-profile-dialog > .player-profile-layout {
    grid-template-columns: minmax(0,1fr);
    gap: 8px;
  }

  html:root #level-profile-dialog .profile-body-panel {
    padding: 12px 10px;
    border: 1px solid var(--pencil-soft);
  }
}

@media (prefers-reduced-motion: reduce) {
  html:root #level-profile-dialog.profile-drawer,
html:root #level-profile-dialog .profile-drawer-toggle > svg {
    transition: none;
  }
}
