@font-face {
  font-family: 'Barlow Condensed';
  src: url('./assets/barlow-condensed-800.ttf') format('truetype');
  font-weight: 800;
  font-display: swap;
}

@font-face {
  font-family: 'Space Grotesk';
  src: url('./assets/space-grotesk-500.ttf') format('truetype');
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: 'Space Grotesk';
  src: url('./assets/space-grotesk-600.ttf') format('truetype');
  font-weight: 600;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --ink: #05090f;
  --paper: #f8f3e5;
  --muted: #bfc8d3;
  --aqua: #00fdff;
  --line: #ffffff2b;
  --display: 'Barlow Condensed', Impact, sans-serif;
  --body: 'Space Grotesk', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; color: var(--paper); background: var(--ink); font: 500 1rem/1.5 var(--body); }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--aqua); outline-offset: 4px; }
.wrap { width: min(100% - 9vw, 1250px); margin-inline: auto; }

.profile-header { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 78px; border-bottom: 1px solid var(--line); }
.profile-lockup { display: block; width: clamp(140px, 20vw, 226px); height: auto; }
.profile-nav { display: flex; align-items: center; gap: clamp(.35rem, 2vw, .9rem); }
.profile-nav .sound-button { flex: none; width: 44px; min-height: 44px; justify-content: center; padding: 0; }
.sound-button[aria-pressed="false"] .sound-on, .sound-button[aria-pressed="true"] .sound-off { display: none; }
.back-link, .other-fighters a { color: var(--muted); font-size: .84rem; font-weight: 600; }
.back-link:hover, .other-fighters a:hover { color: var(--aqua); }

.profile-hero { position: relative; isolation: isolate; overflow: hidden; border-bottom: 1px solid var(--line); background: #0b121d; }
.profile-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -2;
  background: radial-gradient(ellipse at 78% 34%, var(--profile-glow), transparent 60%), var(--ink);
}
.profile-portrait {
  position: absolute;
  z-index: -1;
  inset: 0 0 0 44%;
  min-height: 100%;
  width: 56%;
  height: 100%;
  object-fit: cover;
  object-position: 50% var(--portrait-y, 28%);
  mask-image: linear-gradient(90deg, transparent, black 28%);
}
.profile-hero::after {
  content: '';
  position: absolute;
  z-index: -1;
  inset: 0;
  background: linear-gradient(90deg, #05090f 0%, #05090feb 34%, #05090f60 52%, transparent 69%), linear-gradient(0deg, #05090f88, transparent 42%);
  pointer-events: none;
}
.profile-details { padding-block: clamp(3rem, 6.5vw, 7rem) clamp(3.4rem, 6vw, 6rem); }
.fighter-intro { max-width: min(54%, 550px); }
.fighter-type, .section-label { margin: 0; color: var(--fighter-color); font: 600 .71rem/1.2 var(--body); letter-spacing: .17em; text-transform: uppercase; }
.fighter-type::before { content: ''; display: inline-block; vertical-align: middle; width: 19px; height: 2px; margin-right: 10px; background: currentColor; }
h1 { margin: .3rem 0 1rem; font: 800 clamp(4.75rem, 9.6vw, 9.25rem)/.83 var(--display); letter-spacing: -.025em; text-transform: uppercase; }
.fighter-description { max-width: 38ch; margin: 1.4rem 0 0; color: var(--muted); font-size: clamp(.91rem, 1.4vw, 1.08rem); }
.move { max-width: 390px; margin-top: clamp(1.4rem, 3vw, 2.7rem); padding-top: 1rem; border-top: 1px solid var(--line); }
.move h2 { margin: .25rem 0 .28rem; font: 800 2rem/1 var(--display); text-transform: uppercase; }
.move p:last-child { margin: 0; color: var(--muted); font-size: .83rem; }
.profile-actions { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1.55rem; }
.profile-button {
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: .62rem .85rem;
  background: #0e1824df;
  color: var(--paper);
  font: 600 .87rem/1.2 var(--body);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  cursor: pointer;
  transition: background-color 160ms, border-color 160ms;
}
.profile-button:hover { background: #1f2d3d; border-color: var(--muted); }
.profile-button--play { color: var(--ink); background: var(--aqua); border-color: var(--aqua); font-weight: 600; }
.profile-button--play:hover { background: #84fdff; }
.profile-button svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.share-status { min-height: 1.25rem; margin: .45rem 0 0; color: var(--aqua); font-size: .78rem; }
.share-link { width: min(100%, 410px); margin-top: .4rem; padding: .52rem .6rem; border: 1px solid var(--line); border-radius: 3px; background: #101d2d; color: var(--paper); font: 500 .78rem/1.2 var(--body); }
.other-fighters { padding-block: 1.15rem 1.8rem; display: flex; flex-wrap: wrap; align-items: baseline; gap: .5rem 1.8rem; }
.other-fighters .section-label { color: var(--paper); }
.other-fighters ul { display: flex; flex-wrap: wrap; gap: .45rem 1.35rem; margin: 0; padding: 0; list-style: none; }

@media (max-width: 670px) {
  .profile-header { min-height: 62px; gap: .5rem; }
  .profile-lockup { width: clamp(124px, 32vw, 185px); }
  .profile-nav .back-link { white-space: nowrap; }
  .profile-portrait { inset: 0 0 auto; width: 100%; min-height: 0; height: clamp(260px, 43svh, 430px); mask-image: none; }
  .profile-hero::before { background: var(--ink); }
  .profile-hero::after { inset: 0 0 auto; height: clamp(260px, 43svh, 430px); background: linear-gradient(0deg, var(--ink), #05090fa1 22%, #05090f00 61%); }
  .profile-details { padding-top: clamp(210px, 32svh, 340px); padding-bottom: 1.55rem; }
  .fighter-intro { max-width: 100%; }
  h1 { font-size: clamp(4.6rem, 15vw, 6.35rem); }
  .fighter-description { margin-top: .85rem; }
  .move { margin-top: 1.3rem; }
  .profile-actions { margin-top: 1.1rem; }
}

@media (prefers-reduced-motion: reduce) {
  .profile-button { transition: none; }
}
