:root {
  color-scheme: light;
  font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-interface: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-editorial: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  --font-metric: "Bahnschrift", "DIN Alternate", "Arial Narrow", "Microsoft YaHei", sans-serif;
  --ink: #263348;
  --muted: #718097;
  --panel: #f5f8fc;
  --line: #ffffffb5;
  --accent: #4c8ed8;
  --accent-dark: #2c4d83;
  --particle: #9de1ff;
  --active-background: none;
  --model-surface: #e7f2ff;
  --model-ink: #274764;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body { margin: 0; min-height: 100dvh; display: grid; place-items: center; overflow: hidden; background: #111826; }
button { border: 0; font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, a:focus-visible, canvas:focus-visible, [role="dialog"]:focus-visible { outline: 3px solid #34d59a; outline-offset: 3px; }
svg { display: block; width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

#app {
  position: relative;
  width: min(100vw, 460px);
  height: min(100dvh, 920px);
  aspect-ratio: 430 / 860;
  overflow: hidden;
  isolation: isolate;
  background: #dbe3ef;
  color: var(--ink);
  user-select: none;
  box-shadow: 0 28px 80px #02071180;
}
#game { width: 100%; height: 100%; display: block; touch-action: none; }
.screen, .panel-screen, .hud { position: absolute; inset: 0; }
.hidden { display: none !important; }
[hidden] { display: none !important; }
.sr-only { position: fixed; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* Character music director */
.music-toggle {
  position: absolute;
  z-index: 18;
  top: max(25px, env(safe-area-inset-top));
  right: 22px;
  display: flex;
  width: 143px;
  min-height: 46px;
  align-items: center;
  gap: 10px;
  padding: 7px 12px 7px 10px;
  border: 1px solid #ffffffcf;
  border-radius: 13px;
  color: #314863;
  background: #eff5fbdc;
  box-shadow: 0 8px 22px #2d405b26, inset 0 1px 0 #fff;
  text-align: left;
  backdrop-filter: blur(10px);
  transition: opacity .18s ease, transform .18s ease, background .18s ease;
}
.music-toggle:active { transform: translateY(1px) scale(.98); }
.music-toggle:disabled { opacity: .45; cursor: not-allowed; }
.music-eq { position: relative; display: flex; width: 26px; height: 26px; flex: 0 0 26px; align-items: center; justify-content: center; gap: 2px; border: 1px solid color-mix(in srgb, var(--accent) 46%, #8293a8); border-radius: 8px; background: #fff9; }
.music-eq i { width: 2px; height: 6px; border-radius: 2px; background: var(--accent); transform-origin: 50% 100%; animation: music-level .72s ease-in-out infinite alternate; animation-play-state: paused; }
.music-eq i:nth-child(2) { height: 12px; animation-delay: -.32s; }
.music-eq i:nth-child(3) { height: 9px; animation-delay: -.14s; }
.music-eq i:nth-child(4) { height: 15px; animation-delay: -.47s; }
.music-toggle.is-playing .music-eq i { animation-play-state: running; }
.music-toggle.is-playing .music-eq { border-color: color-mix(in srgb, var(--accent) 72%, #fff); box-shadow: 0 0 0 3px color-mix(in srgb, var(--particle) 22%, transparent); }
.music-toggle.is-muted .music-eq i { height: 3px; opacity: .46; animation: none; }
.music-toggle.is-muted .music-eq::after { content: ""; position: absolute; width: 18px; height: 1px; background: #7d8999; transform: rotate(-45deg); box-shadow: 0 1px 0 #fff; }
.music-toggle-copy { display: grid; min-width: 0; gap: 1px; }
.music-toggle-copy small { overflow: hidden; color: #5f7189; font-family: var(--font-metric); font-size: 10px; font-weight: 900; letter-spacing: .04em; text-overflow: ellipsis; white-space: nowrap; }
.music-toggle-copy strong { overflow: hidden; color: #263e5b; font-size: 11px; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
#app[data-mode="playing"] .music-toggle { right: 80px; width: 46px; min-height: 46px; padding: 8px; justify-content: center; }
#app[data-mode="playing"] .music-toggle-copy { display: none; }
#app[data-mode="result"] .music-toggle { width: 46px; padding: 8px; justify-content: center; }
#app[data-mode="result"] .music-toggle-copy { display: none; }
#app:has(.panel-screen:not(.hidden)) .music-toggle,
#app:has(.model-intro-dialog:not(.hidden)) .music-toggle { opacity: 0; transform: translateY(-7px); pointer-events: none; }

/* Home */
.home-screen {
  z-index: 2;
  display: block;
  padding: max(34px, env(safe-area-inset-top)) 24px max(20px, env(safe-area-inset-bottom));
  pointer-events: none;
  isolation: isolate;
}
.home-screen::before {
  content: "";
  position: absolute;
  z-index: -2;
  inset: 0;
  background-image: linear-gradient(180deg, #e9f2fcbd 0%, #dce7f3b8 57%, #d4deebf2 100%), var(--active-background);
  background-position: center;
  background-size: cover;
  filter: saturate(.9);
  transform: scale(1.04);
  animation: background-drift 18s ease-in-out infinite alternate;
}
.home-screen::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 50% 50%, #ffffff0a 0 20%, #eaf3fc99 55%, #d8e2efde 100%);
}
.home-heading { position: absolute; top: 18.5%; left: 0; right: 0; text-align: center; filter: drop-shadow(0 2px 0 #ffffffd9); }
.edition-mark { display: inline-flex; align-items: center; gap: 7px; color: #65758c; }
.edition-mark span {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid #8394ac;
  border-radius: 7px;
  background: #f8fbffb8;
  font-size: 11px;
  font-weight: 950;
}
.edition-mark i { width: 20px; height: 1px; background: #9eacbe; }
.edition-mark b { font-size: 10px; letter-spacing: .19em; }
.home-heading h1 {
  margin: 8px 0 5px;
  color: #27344a;
  font-size: 51px;
  line-height: .98;
  letter-spacing: .13em;
  text-indent: .13em;
  font-family: var(--font-editorial);
  font-weight: 900;
}
.home-heading p { margin: 0; color: #62738c; font-size: 12px; font-weight: 750; letter-spacing: .055em; }
.home-character {
  position: absolute;
  top: 34%;
  left: 0;
  display: flex;
  width: 100%;
  height: 30%;
  min-height: 0;
  align-items: center;
  justify-content: center;
  padding-top: 0;
}
.character-aura {
  position: absolute;
  width: 212px;
  height: 212px;
  border: 1px solid #ffffffb8;
  border-radius: 50%;
  background: radial-gradient(circle, #ffffffba 0 20%, #cde8ff5e 47%, transparent 68%);
  box-shadow: 0 0 70px #eaf5ffcc, inset 0 0 0 18px #ffffff12;
  animation: aura-breathe 3.4s ease-in-out infinite;
}
.character-aura::before, .character-aura::after {
  content: "";
  position: absolute;
  inset: 21px;
  border: 1px dashed #7da7cd54;
  border-radius: 50%;
  animation: orbit 15s linear infinite;
}
.character-aura::after { inset: 46px; border-style: solid; animation-direction: reverse; animation-duration: 10s; }
.avatar-sprite {
  position: relative;
  z-index: 1;
  width: 104px;
  height: 260px;
  background-repeat: no-repeat;
  background-size: 500% 100%;
  filter: drop-shadow(0 18px 12px #27364c48);
  transform-origin: 50% 92%;
  animation: avatar-float 3.2s ease-in-out infinite;
}
.character-nameplate {
  position: absolute;
  z-index: 2;
  bottom: -6px;
  left: 50%;
  display: grid;
  min-width: 150px;
  padding: 8px 16px 9px;
  transform: translateX(-50%);
  border: 1px solid #ffffffc7;
  border-radius: 12px;
  background: #edf4fbd9;
  box-shadow: 0 8px 24px #50647b22;
  text-align: center;
  backdrop-filter: blur(8px);
}
.character-nameplate small { color: #5e718a; font-size: 10px; font-weight: 850; letter-spacing: .08em; }
.character-nameplate strong { margin-top: 1px; font-family: var(--font-metric); font-size: 15px; letter-spacing: -.015em; }
.home-actions { position: absolute; top: 67%; left: 0; display: grid; justify-items: center; width: 100%; }
.primary-button {
  pointer-events: auto;
  display: inline-flex;
  min-width: 222px;
  min-height: 60px;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 13px 30px;
  border: 1px solid #fff;
  border-radius: 16px;
  color: #1e2b40;
  background: linear-gradient(180deg, #fff, #f0f5fb);
  box-shadow: 0 13px 28px #40536e35, inset 0 -3px 0 #ccd8e8;
  font-size: 21px;
  font-weight: 950;
  transition: transform .14s ease, box-shadow .14s ease;
}
.primary-button svg { width: 29px; height: 29px; color: #20bf81; fill: currentColor; stroke: none; }
.primary-button:active { transform: translateY(2px) scale(.985); box-shadow: 0 7px 15px #40536e32, inset 0 -2px 0 #ccd8e8; }
.home-actions p { margin: 11px 0 5px; color: #596d88; font-size: 11px; font-weight: 850; letter-spacing: .035em; }
.model-tour-button {
  pointer-events: auto;
  display: flex;
  min-height: 42px;
  margin-top: 4px;
  align-items: center;
  gap: 10px;
  padding: 6px 12px 6px 8px;
  border: 1px solid #ffffffc4;
  border-radius: 12px;
  color: #435974;
  background: #eef5fbd9;
  box-shadow: 0 7px 18px #40536e1f;
  text-align: left;
  backdrop-filter: blur(9px);
  transition: transform .18s cubic-bezier(.22, 1, .36, 1), box-shadow .18s ease;
}
.model-tour-button:active { transform: translateY(1px) scale(.985); box-shadow: 0 3px 10px #40536e1e; }
.model-tour-button > span:last-child { display: grid; gap: 1px; }
.model-tour-button strong { font-size: 11px; line-height: 1.1; }
.model-tour-button small { color: #5b6f88; font-size: 10px; font-weight: 750; }
.model-tour-mark {
  position: relative;
  display: block;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  border: 1px solid #7ea2c4;
  border-radius: 9px;
  background: #f8fbff;
}
.model-tour-mark::before, .model-tour-mark::after, .model-tour-mark i {
  content: "";
  position: absolute;
  border: 1px solid #5c86ae;
  border-radius: 3px;
}
.model-tour-mark::before { inset: 6px 13px 6px 6px; border-right: 0; border-radius: 3px 0 0 3px; }
.model-tour-mark::after { inset: 6px 6px 6px 13px; border-left: 0; border-radius: 0 3px 3px 0; }
.model-tour-mark i { left: 13px; top: 6px; width: 1px; height: 16px; border-width: 0 0 0 1px; border-radius: 0; }
.home-nav {
  position: absolute;
  left: 0;
  bottom: 0;
  display: grid;
  grid-template-columns: 1fr 1px 1fr;
  width: 100%;
  min-height: 102px;
  margin: 0;
  padding: 15px 54px max(16px, env(safe-area-inset-bottom));
  align-items: center;
  pointer-events: auto;
  border-top: 1px solid #ffffffa6;
  background: linear-gradient(180deg, #e5ecf5cc, #d4deebeb);
  box-shadow: 0 -12px 28px #7a8ba31a;
  backdrop-filter: blur(12px);
}
.nav-divider { width: 1px; height: 38px; background: #aab7c74f; }
.nav-item { display: grid; justify-items: center; gap: 4px; color: #4d6078; background: transparent; font-size: 11px; font-weight: 800; }
.nav-icon { width: 31px; height: 31px; color: #6c819c; }
.nav-item:active .nav-icon { transform: translateY(1px) scale(.94); }

/* Gameplay HUD */
.hud { z-index: 3; display: flex; justify-content: space-between; align-items: flex-start; padding: max(25px, env(safe-area-inset-top)) 22px 0; pointer-events: none; }
.hud-metrics { display: flex; min-width: 160px; align-items: flex-start; gap: 15px; color: #303a4a; text-shadow: 0 2px 0 #fff; }
.height-panel, .score-panel { display: grid; min-width: 0; }
.height-panel small, .score-panel small { color: #455b77; font-size: 10px; line-height: 1; font-weight: 950; letter-spacing: .075em; white-space: nowrap; }
.height-panel b, .score-panel b { font-family: var(--font-metric); line-height: .9; font-weight: 900; letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.height-panel b { margin-top: 4px; font-size: 49px; }
.score-panel { margin-top: 4px; padding-left: 14px; border-left: 1px solid #71809645; }
.score-panel b { margin-top: 5px; font-size: 25px; }
.hud > .glass-button { flex: 0 0 auto; }
.hud-status {
  position: absolute;
  top: max(91px, calc(env(safe-area-inset-top) + 74px));
  left: 22px;
  display: grid;
  width: min(250px, calc(100% - 92px));
  gap: 5px;
}
.skill-status {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 1px 8px;
  width: fit-content;
  max-width: 100%;
  padding: 7px 10px 8px;
  border: 1px solid #ffffffb8;
  border-radius: 11px;
  color: #334861;
  background: #eef5fbd8;
  box-shadow: 0 7px 18px #33465e1d;
  backdrop-filter: blur(9px);
}
.skill-status > span { grid-row: 1 / 3; align-self: center; padding-right: 8px; border-right: 1px solid #768ba43b; color: #526882; font-family: var(--font-metric); font-size: 9px; font-weight: 900; letter-spacing: .035em; }
.skill-status strong { overflow: hidden; color: #263d59; font-size: 12px; line-height: 1.15; text-overflow: ellipsis; white-space: nowrap; }
.skill-status small { overflow: hidden; color: #475f7a; font-size: 10px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.platform-challenge {
  width: fit-content;
  max-width: 100%;
  margin: 0;
  padding: 5px 9px;
  overflow: hidden;
  border-radius: 8px;
  color: #314b6c;
  background: #e7eff8bd;
  box-shadow: 0 4px 11px #34455b14;
  font-size: 10px;
  font-weight: 850;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
  backdrop-filter: blur(7px);
}
#app[data-voice="editorial"] .platform-challenge,
#app[data-voice="editorial"] .result-message,
#app[data-voice="editorial"] .profile-voice { font-family: var(--font-editorial); font-weight: 800; letter-spacing: .015em; }
#app[data-voice="digital"] .platform-challenge,
#app[data-voice="digital"] .skill-status { letter-spacing: .035em; }
#app[data-voice="soft"] .platform-challenge { letter-spacing: .025em; }
.glass-button {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  pointer-events: auto;
  border: 1px solid #ffffffb5;
  border-radius: 14px;
  color: #4f6076;
  background: #eff4f9b8;
  box-shadow: 0 8px 20px #46556b24, inset 0 1px 0 #fff;
  backdrop-filter: blur(10px);
}
.glass-button svg { width: 22px; height: 22px; }
.power-meter {
  position: absolute;
  right: 24px;
  bottom: max(26px, env(safe-area-inset-bottom));
  display: grid;
  width: 7px;
  height: 148px;
  align-items: end;
  overflow: visible;
  border-radius: 5px;
  background: #ffffff7a;
  box-shadow: 0 2px 9px #34465d22, inset 0 0 0 1px #ffffff99;
  opacity: 0;
  transform: translateX(10px);
  transition: opacity .18s ease, transform .18s ease;
}
.power-meter.active { opacity: 1; transform: translateX(0); }
.power-meter span { width: 100%; height: var(--charge, 0%); border-radius: inherit; background: linear-gradient(#ff5f67, #f3bf4d 43%, #32d296); }
.power-meter i { position: absolute; left: -4px; bottom: calc(var(--charge, 0%) - 1px); width: 15px; height: 2px; border-radius: 2px; background: #23344c; }
.power-meter small { position: absolute; right: 13px; bottom: -1px; width: 32px; color: #59697e; font-size: 9px; font-style: normal; font-weight: 900; letter-spacing: .1em; }
.guide {
  position: absolute;
  z-index: 4;
  top: 24%;
  left: 50%;
  display: flex;
  width: 244px;
  min-height: 68px;
  align-items: center;
  gap: 13px;
  padding: 12px 16px;
  transform: translateX(-50%);
  border: 1px solid #ffffffc7;
  border-radius: 13px;
  color: #344257;
  background: #f4f7fbd8;
  box-shadow: 0 12px 30px #3d4b5e2e;
  pointer-events: none;
  backdrop-filter: blur(10px);
}
.guide > div { display: grid; gap: 2px; }
.guide b { font-size: 14px; }
.guide span { color: #738096; font-size: 10px; font-weight: 700; }
.guide-press { position: relative; flex: 0 0 38px; width: 38px; height: 38px; border: 1px solid #93a4b9; border-radius: 50%; }
.guide-press::before, .guide-press::after { content: ""; position: absolute; inset: 8px; border: 1px solid #5d91bd; border-radius: 50%; animation: press-wave 1.55s ease-out infinite; }
.guide-press::after { animation-delay: .4s; }
.guide-press i { position: absolute; left: 16px; top: 9px; width: 6px; height: 21px; border-radius: 5px; background: #4c7fa9; box-shadow: 0 5px 0 3px #dcebf6; }

/* Landing reward packets */
.score-fx-layer {
  position: absolute;
  z-index: 8;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.score-burst {
  position: absolute;
  left: var(--fx-x);
  top: var(--fx-y);
  width: 186px;
  transform: translate(-50%, calc(-100% - 18px));
  color: #173451;
  filter: drop-shadow(0 9px 9px #1b2b3a28);
  animation: score-packet-life 1.2s cubic-bezier(.16, 1, .3, 1) both;
}
.score-burst::before {
  content: "";
  position: absolute;
  top: 19px;
  bottom: 2px;
  left: -7px;
  width: 1px;
  background: linear-gradient(var(--fx-glow), var(--fx-accent), transparent);
  transform-origin: 50% 100%;
  animation: score-rail 1s cubic-bezier(.16, 1, .3, 1) both;
}
.score-burst-head {
  display: flex;
  height: 20px;
  align-items: center;
  justify-content: space-between;
  padding: 0 7px 0 9px;
  color: #fff;
  background: color-mix(in srgb, var(--fx-accent) 88%, #18324d);
  box-shadow: 3px 4px 0 color-mix(in srgb, var(--fx-accent) 23%, transparent);
  font-family: var(--font-metric);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: .08em;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 50%, calc(100% - 10px) 100%, 0 100%);
}
.score-burst-head b { color: var(--fx-glow); font-size: 9px; letter-spacing: .04em; }
.score-burst-rows { display: grid; gap: 3px; margin-top: 4px; }
.score-reward {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  min-height: 34px;
  padding: 5px 8px 5px 10px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--fx-accent) 35%, #fff);
  color: #18324c;
  background: color-mix(in srgb, #f8fbff 88%, var(--fx-glow));
  box-shadow: 3px 4px 0 color-mix(in srgb, var(--fx-accent) 21%, transparent);
  clip-path: inset(0 100% 0 0);
  animation: score-row-scan .72s cubic-bezier(.16, 1, .3, 1) var(--reward-delay) forwards;
}
.score-reward::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -22px;
  width: 18px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--fx-glow) 75%, white), transparent);
  transform: skewX(-16deg);
  animation: score-scan-glint .52s ease-out calc(var(--reward-delay) + 120ms) forwards;
}
.score-reward-code { overflow: hidden; color: color-mix(in srgb, var(--fx-accent) 72%, #18324d); font-family: var(--font-metric); font-size: 9px; font-weight: 900; letter-spacing: .055em; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }
.score-reward strong { grid-row: 1 / 3; grid-column: 2; align-self: center; padding-left: 7px; color: var(--fx-accent); font-family: var(--font-metric); font-size: 25px; line-height: .85; letter-spacing: -.035em; font-variant-numeric: tabular-nums; text-shadow: 1px 1px 0 #fff; }
.score-reward small { overflow: hidden; margin-top: 1px; color: #2e4964; font-size: 10px; font-weight: 850; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
.score-reward--platform { margin-left: 9px; border-style: dashed; animation-name: score-row-slide; }
.score-reward--platform strong { color: #e18b3b; }
.score-reward--skill { margin-left: 18px; color: #fff; border-color: color-mix(in srgb, var(--fx-glow) 64%, #fff); background: color-mix(in srgb, var(--fx-accent) 84%, #1a2c45); box-shadow: 3px 4px 0 color-mix(in srgb, var(--fx-accent) 31%, transparent); animation-name: score-row-skill; }
.score-reward--skill .score-reward-code,
.score-reward--skill small { color: color-mix(in srgb, var(--fx-glow) 82%, #fff); }
.score-reward--skill strong { color: #fff; text-shadow: 0 1px 0 var(--fx-accent), 0 0 9px color-mix(in srgb, var(--fx-glow) 65%, transparent); }
.score-capture-trace { position: absolute; top: -1px; right: -3px; display: block; width: 5px; height: 5px; border: 1px solid var(--fx-glow); transform: rotate(45deg); opacity: 0; animation: score-trace 1.05s cubic-bezier(.3, 0, .3, 1) .16s both; }
.score-burst.is-precision .score-burst-head { box-shadow: 3px 4px 0 color-mix(in srgb, var(--fx-accent) 23%, transparent), 0 0 0 1px var(--fx-glow); }
.score-burst.is-precision::after { content: ""; position: absolute; inset: -8px -9px -7px -14px; border: 1px solid color-mix(in srgb, var(--fx-accent) 65%, transparent); animation: precision-bracket .72s cubic-bezier(.16, 1, .3, 1) both; }

/* Result */
.result-screen {
  z-index: 6;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 48px 28px 28px;
  background: linear-gradient(180deg, #1722385c, #0d1525a6);
  backdrop-filter: blur(5px);
}
.result-card {
  position: relative;
  width: 100%;
  max-width: 342px;
  min-height: 352px;
  padding: 42px 28px 24px;
  overflow: hidden;
  border: 1px solid #8399ba6b;
  border-radius: 18px;
  color: #eef5ff;
  background: linear-gradient(150deg, #263955f2, #121b2cf7);
  box-shadow: 0 25px 60px #050b16a6, inset 0 1px 0 #ffffff25;
  text-align: center;
}
.result-card::before { content: ""; position: absolute; top: -80px; left: 50%; width: 260px; height: 180px; transform: translateX(-50%); border-radius: 50%; background: #4e94d751; filter: blur(34px); }
.result-title { position: relative; margin: 0 0 27px; color: #f0f5fc; font-family: var(--font-editorial); font-size: 24px; line-height: 1.2; letter-spacing: .04em; }
.result-metrics { position: relative; display: grid; grid-template-columns: 1.25fr .75fr; margin: 0 auto 18px; align-items: end; }
.result-metrics p { margin: 0 0 4px; color: #aebdd1; font-size: 10px; font-weight: 800; }
.result-primary-metric { padding-right: 18px; border-right: 1px solid #8295af45; text-align: right; }
.result-primary-metric b { display: flex; justify-content: flex-end; align-items: baseline; gap: 6px; color: #43dfa2; font-family: var(--font-metric); font-size: 76px; line-height: .88; letter-spacing: -.035em; }
.result-primary-metric b small { color: #9fd8c4; font-family: "Microsoft YaHei", sans-serif; font-size: 11px; letter-spacing: 0; }
.result-secondary-metric { padding-left: 17px; text-align: left; }
.result-secondary-metric strong { display: block; overflow-wrap: anywhere; color: #f0f5fc; font-family: var(--font-metric); font-size: 29px; line-height: 1; }
.result-rule { position: relative; width: 82%; height: 1px; margin: 0 auto 18px; background: linear-gradient(90deg, transparent, #93a7c250, transparent); }
.result-card .result-message { position: relative; min-height: 42px; margin: 0 auto; max-width: 24em; color: #e0e8f2; font-size: 13px; font-weight: 750; line-height: 1.65; text-wrap: balance; }
.result-best { position: relative; display: flex; margin-top: 20px; padding: 12px 2px 2px; align-items: center; justify-content: space-between; border-top: 1px solid #8397b02f; color: #9fadc1; font-size: 11px; }
.result-best strong { color: #f0f5fc; font-size: 20px; }
.record-badge { position: absolute; z-index: 2; top: 17px; right: 17px; padding: 5px 8px; border: 1px solid #ffd58e; border-radius: 6px; color: #ffe2a9; background: #d8933033; font-family: var(--font-metric); font-size: 9px; font-weight: 950; letter-spacing: .1em; }
.result-actions { display: flex; align-items: center; gap: 14px; }
.result-home { width: 58px; height: 58px; color: #e6eef8; background: #dce8f026; }
.retry-button { min-width: 214px; }
.retry-button svg { fill: none; stroke: currentColor; color: #2d9876; stroke-width: 2; }

/* Panels */
.panel-screen {
  z-index: 8;
  overflow-y: auto;
  padding: max(24px, env(safe-area-inset-top)) 18px 30px;
  color: var(--ink);
  background: linear-gradient(180deg, #eef3fa, #dce5f0);
  scrollbar-width: none;
}
.panel-screen::-webkit-scrollbar { display: none; }
.panel-header { position: relative; z-index: 2; display: flex; min-height: 52px; align-items: center; gap: 12px; }
.panel-header > div { display: grid; flex: 1; }
.panel-header > div > span, .panel-header h2 { margin: 0; font-size: 20px; line-height: 1.1; font-weight: 950; }
.panel-header > div > small, .panel-header > div > p { margin: 3px 0 0; color: var(--muted); font-size: 10px; font-weight: 700; }
.back-button { display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid #fff; border-radius: 12px; color: #53657c; background: #f9fbfdda; box-shadow: 0 6px 16px #4b607a20; }
.back-button svg { width: 21px; height: 21px; }
.best-chip { display: grid; min-width: 52px; padding: 5px 9px; border: 1px solid #fff; border-radius: 10px; background: #f8fbffb8; text-align: right; }
.best-chip small { color: #718197; font-size: 8px; font-weight: 900; letter-spacing: .11em; }
.best-chip b { font-size: 17px; line-height: 1; }
.roster-screen { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; overflow: hidden; padding-bottom: 0; }
.character-profile { min-height: 0; margin: 16px -18px 0; overflow-y: auto; scrollbar-width: none; background: #edf3f9; }
.character-profile::-webkit-scrollbar { display: none; }
.profile-stage { position: relative; display: grid; height: clamp(270px, 36dvh, 330px); place-items: end center; overflow: hidden; color: #fff; background-image: linear-gradient(145deg, color-mix(in srgb, var(--accent) 72%, transparent), color-mix(in srgb, var(--accent-dark) 82%, #101827)), var(--active-background); background-position: center; background-size: cover; isolation: isolate; }
.profile-stage::before { content: ""; position: absolute; z-index: -1; width: 270px; height: 270px; bottom: -66px; border: 1px solid #ffffff2b; border-radius: 50%; box-shadow: inset 0 0 0 34px #ffffff0a, inset 0 0 0 72px #ffffff08; }
.profile-stage::after { content: ""; position: absolute; z-index: -1; inset: 0; background: radial-gradient(circle at 50% 74%, #ffffff3d, transparent 43%), linear-gradient(180deg, #0e192526, #0b14265f); }
.profile-art { width: 142px; height: 355px; background-repeat: no-repeat; background-size: 500% 100%; filter: drop-shadow(0 20px 14px #17223566); transform-origin: 50% 92%; animation: profile-breathe 3.2s ease-in-out infinite; }
.profile-index { position: absolute; right: 17px; top: 16px; color: #ffffffb8; font-size: 11px; font-weight: 850; letter-spacing: .08em; }
.profile-copy { padding: 18px 20px 24px; color: var(--ink); }
.profile-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.profile-title-row > div { min-width: 0; }
.profile-role { margin: 0; color: var(--accent-dark); font-size: 11px; font-weight: 800; }
.profile-title-row h3 { margin: 3px 0 0; overflow-wrap: anywhere; font-size: 30px; line-height: 1; letter-spacing: -.02em; }
.variant-label { flex: 0 0 auto; max-width: 116px; padding: 5px 8px; border: 1px solid #9aa9bb69; border-radius: 7px; color: #53657d; background: #f8fbfebd; font-size: 10px; font-weight: 800; text-align: center; }
.profile-section { margin-top: 19px; padding-top: 18px; border-top: 1px solid #aebccc69; }
.profile-section-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; }
.profile-section-heading h4 { margin: 0; color: #344861; font-size: 15px; line-height: 1.2; }
.profile-section-heading span { color: #718197; font-size: 8px; font-weight: 900; letter-spacing: .1em; }
.profile-real-section { position: relative; }
.profile-real-intro { margin: 12px 0 11px; color: #4e6179; font-size: 13px; line-height: 1.7; }
.capability-tags, .intro-capability-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.capability-tags:empty, .intro-capability-tags:empty { display: none; }
.capability-tags li, .intro-capability-tags li { padding: 4px 7px; border: 1px solid color-mix(in srgb, var(--accent) 38%, #b8c5d5); border-radius: 7px; color: var(--accent-dark); background: color-mix(in srgb, var(--model-surface) 68%, #fff); font-size: 9px; font-weight: 850; }
.profile-use-cases { margin-top: 12px; padding: 10px 12px; border-radius: 10px; color: #425670; background: #e3ebf4; }
.profile-use-cases strong { display: block; margin-bottom: 3px; color: #5b7089; font-size: 9px; letter-spacing: .045em; }
.profile-use-cases p { margin: 0; font-size: 11px; line-height: 1.55; }
.profile-model-quote { margin: 12px 0 0; padding: 0 2px; border: 0; color: #3d516b; font-size: 12px; font-weight: 850; line-height: 1.55; }
.profile-source, .intro-source { display: inline-flex; margin-top: 10px; align-items: center; gap: 6px; color: var(--accent-dark); font-size: 10px; font-weight: 850; text-underline-offset: 3px; }
.profile-source::after, .intro-source::after {
  content: "";
  width: 7px;
  height: 7px;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
  box-shadow: 2px -2px 0 -1px currentColor;
  transform: translateY(-1px);
}
.profile-bio { max-width: 35em; margin: 12px 0 11px; color: #5c6c82; font-size: 13px; line-height: 1.7; }
.profile-tags { display: flex; flex-wrap: wrap; margin: 0; padding: 0; color: #42536a; list-style: none; font-size: 12px; font-weight: 800; }
.profile-tags li + li::before { content: "·"; margin: 0 8px; color: var(--accent); }
.profile-voice { margin: 14px 0 0; padding: 11px 13px; border: 0; border-radius: 9px; color: #2f4866; background: #dfe9f3; font-family: var(--font-editorial); font-size: 13px; font-weight: 800; line-height: 1.6; }
.profile-soundtrack { display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: 11px; margin-top: 10px; padding: 10px 12px; align-items: center; border: 1px solid color-mix(in srgb, var(--accent) 22%, #fff); border-radius: 12px; color: #304966; background: color-mix(in srgb, var(--accent) 8%, #edf3f9); box-shadow: 0 5px 13px #31465f12; }
.profile-soundtrack > div { display: grid; min-width: 0; gap: 1px; }
.profile-soundtrack small { color: #677b93; font-family: var(--font-metric); font-size: 9px; font-weight: 900; letter-spacing: .04em; }
.profile-soundtrack strong { overflow: hidden; color: var(--accent-dark); font-size: 14px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.profile-soundtrack div > span { overflow: hidden; color: #5c7088; font-size: 9px; font-weight: 750; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.sound-orbit { position: relative; display: grid; width: 36px; height: 36px; place-items: center; border: 1px solid color-mix(in srgb, var(--accent) 48%, #9ba9ba); border-radius: 50%; }
.sound-orbit::before, .sound-orbit::after { content: ""; position: absolute; border: 1px solid color-mix(in srgb, var(--accent) 38%, transparent); border-radius: 50%; }
.sound-orbit::before { inset: 5px; border-style: dashed; animation: orbit 9s linear infinite; }
.sound-orbit::after { inset: 10px; }
.sound-orbit i { position: absolute; bottom: 12px; width: 2px; height: 7px; border-radius: 2px; background: var(--accent); animation: music-profile-level 1s ease-in-out infinite alternate; }
.sound-orbit i:first-child { left: 13px; height: 5px; animation-delay: -.45s; }
.sound-orbit i:nth-child(2) { left: 17px; height: 10px; animation-delay: -.2s; }
.sound-orbit i:last-child { left: 21px; height: 7px; animation-delay: -.7s; }
.profile-skill { margin-top: 13px; padding: 13px 14px; border-radius: 13px; color: #eef5ff; background: linear-gradient(145deg, color-mix(in srgb, var(--accent-dark) 86%, #172335), #18273d); box-shadow: 0 10px 24px #24364b29; }
.profile-skill-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.profile-skill-title span { color: #bed0e4; font-size: 9px; font-weight: 900; letter-spacing: .06em; }
.profile-skill-title strong { font-size: 15px; }
.profile-skill > p { margin: 8px 0 11px; color: #cfdae8; font-size: 10px; line-height: 1.55; }
.profile-skill dl { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0; }
.profile-skill dl > div { display: grid; gap: 2px; padding: 8px 9px; border-radius: 8px; background: #ffffff0f; }
.profile-skill dt { color: #a9bed5; font-size: 8px; font-weight: 850; }
.profile-skill dd { margin: 0; color: #f1f6fd; font-size: 9px; font-weight: 800; line-height: 1.35; }
.profile-skill-progress { display: flex; margin-top: 9px; padding-top: 9px; align-items: center; justify-content: space-between; border-top: 1px solid #ffffff1a; }
.profile-skill-progress span { color: #b5c7db; font-size: 9px; font-weight: 800; }
.profile-skill-progress strong { color: #5ee0ad; font-family: "Bahnschrift", "Microsoft YaHei", sans-serif; font-size: 13px; }
.unlock-section { display: grid; grid-template-columns: 1fr auto; gap: 10px 14px; margin-top: 16px; padding-top: 15px; border-top: 1px solid #afbdcd6b; }
.unlock-copy { display: grid; align-content: center; }
.unlock-copy strong { font-size: 13px; }
.unlock-copy span { margin-top: 2px; color: #748399; font-size: 11px; }
.skin-action { min-width: 112px; min-height: 44px; padding: 9px 14px; border-radius: 11px; color: #fff; background: var(--accent-dark); font-size: 13px; font-weight: 900; box-shadow: 0 7px 16px #24364b2d; }
.skin-action:active:not(:disabled) { transform: translateY(1px); }
.skin-action:disabled { color: #8491a3; background: #d5dee9; box-shadow: none; cursor: not-allowed; }
.unlock-section progress { grid-column: 1 / -1; width: 100%; height: 7px; overflow: hidden; border: 0; border-radius: 4px; appearance: none; background: #cdd8e4; }
.unlock-section progress::-webkit-progress-bar { background: #cdd8e4; }
.unlock-section progress::-webkit-progress-value { border-radius: 4px; background: var(--accent); }
.unlock-section progress::-moz-progress-bar { border-radius: 4px; background: var(--accent); }
.character-rail { display: flex; gap: 4px; margin: 0 -18px; padding: 8px 14px max(10px, env(safe-area-inset-bottom)); overflow-x: auto; border-top: 1px solid #ffffffb5; background: #e4ecf5f2; box-shadow: 0 -8px 22px #40547018; scroll-snap-type: x mandatory; scrollbar-width: none; }
.character-rail::-webkit-scrollbar { display: none; }
.character-tab { position: relative; display: grid; flex: 0 0 70px; min-height: 80px; justify-items: center; align-content: end; padding: 3px 4px 7px; color: #55667d; background: transparent; scroll-snap-align: center; }
.character-tab::before { content: ""; position: absolute; right: 6px; bottom: 0; left: 6px; height: 3px; border-radius: 3px; background: var(--accent); opacity: 0; transform: scaleX(.35); transition: opacity .18s ease, transform .24s cubic-bezier(.16, 1, .3, 1); }
.character-tab[aria-pressed="true"] { color: #26374e; }
.character-tab[aria-pressed="true"]::before { opacity: 1; transform: scaleX(1); }
.character-tab.current::after { content: "出战"; position: absolute; top: 1px; right: 0; padding: 2px 4px; border-radius: 5px; color: #fff; background: #24364bcc; font-size: 8px; font-weight: 900; }
.character-tab-art { width: 22px; height: 55px; background-image: var(--sheet); background-repeat: no-repeat; background-size: 500% 100%; background-position: var(--pos); filter: drop-shadow(0 5px 4px #21314742); }
.character-tab strong { width: 100%; overflow: hidden; font-size: 10px; line-height: 1.2; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.character-tab small { position: absolute; top: 3px; left: 3px; color: #68788e; font-size: 8px; font-weight: 850; }

.rank-summary { display: grid; grid-template-columns: 58px 1fr auto; margin: 24px 1px 16px; padding: 18px; align-items: center; border: 1px solid #ffffffc2; border-radius: 16px; color: #f0f6ff; background: linear-gradient(135deg, #516d9b, #2c3d5d); box-shadow: 0 13px 28px #31445f2d; }
.rank-crown { display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid #ffffff36; border-radius: 12px; color: #ffdb88; background: #ffffff11; }
.rank-crown svg { width: 27px; height: 27px; }
.rank-summary > div { display: grid; }
.rank-summary small { color: #c1cee0; font-size: 9px; font-weight: 750; }
.rank-summary strong { font-family: "Bahnschrift", "Microsoft YaHei", sans-serif; font-size: 38px; line-height: 1; }
.rank-summary p { max-width: 78px; margin: 0; color: #c0cce0; font-size: 9px; line-height: 1.45; text-align: right; }
.rank-list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.rank-list li { display: flex; min-height: 57px; align-items: center; gap: 12px; padding: 8px 12px; border: 1px solid #ffffffc2; border-radius: 13px; color: #40516a; background: #f7faffb8; box-shadow: 0 5px 13px #4c62791a; font-size: 11px; font-weight: 800; }
.rank-number { width: 22px; color: #8290a4; font-family: "Bahnschrift", "Microsoft YaHei", sans-serif; font-size: 15px; text-align: center; }
.rank-avatar { width: 18px; height: 45px; flex: 0 0 auto; background-image: var(--sheet); background-size: 500% 100%; background-position: var(--pos); background-repeat: no-repeat; filter: drop-shadow(0 4px 3px #2230473d); }
.score-panel b.score-pop, .height-panel b.score-pop { animation: score-pop .32s cubic-bezier(.22,1,.36,1); }
.score-panel b.score-capture { animation: score-capture .56s cubic-bezier(.16,1,.3,1); }
.height-panel b.height-sync { animation: height-sync .48s cubic-bezier(.16,1,.3,1); }
.rank-list li b { margin-left: auto; color: #273954; font-family: "Bahnschrift", "Microsoft YaHei", sans-serif; font-size: 21px; }
.rank-note { margin: 17px 12px 0; color: #748399; font-size: 10px; line-height: 1.55; text-align: center; }

/* Progressive model introductions */
.model-intro-dialog {
  position: absolute;
  z-index: 30;
  inset: 0;
  display: grid;
  place-items: center;
  padding: max(18px, env(safe-area-inset-top)) 15px max(18px, env(safe-area-inset-bottom));
  color: #25374e;
  background: #0a1220a6;
  backdrop-filter: blur(8px);
}
.model-intro-card {
  display: flex;
  width: min(100%, 392px);
  height: min(88dvh, 792px);
  min-height: 560px;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #ffffffa8;
  border-radius: 18px;
  background: #eff4f9;
  box-shadow: 0 28px 72px #030912b5;
  animation: intro-reveal .46s cubic-bezier(.22, 1, .36, 1) both;
}
.intro-stage {
  position: relative;
  display: grid;
  height: clamp(215px, 31dvh, 285px);
  flex: 0 0 auto;
  place-items: end center;
  overflow: hidden;
  background-image: linear-gradient(180deg, #dceaf63d, #1728408a), var(--active-background);
  background-position: center;
  background-size: cover;
  isolation: isolate;
}
.intro-stage::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: radial-gradient(circle at 50% 68%, #ffffff52 0 18%, transparent 49%), linear-gradient(180deg, transparent 48%, #101c2c80 100%);
}
.intro-stage-light {
  position: absolute;
  z-index: -1;
  bottom: -86px;
  left: 50%;
  width: 280px;
  height: 180px;
  transform: translateX(-50%);
  border: 1px solid #ffffff4a;
  border-radius: 50%;
  box-shadow: inset 0 0 0 28px #ffffff0d, 0 0 56px #e8f5ff42;
}
.intro-avatar {
  position: relative;
  width: 108px;
  height: 270px;
  background-repeat: no-repeat;
  background-size: 500% 100%;
  filter: drop-shadow(0 18px 14px #07101e7d);
  transform-origin: 50% 93%;
  animation: intro-avatar-breathe 3.2s ease-in-out infinite;
}
.intro-skip {
  position: absolute;
  z-index: 3;
  top: 13px;
  right: 13px;
  min-height: 34px;
  padding: 7px 11px;
  border: 1px solid #ffffff6b;
  border-radius: 9px;
  color: #eff6ff;
  background: #142137ad;
  box-shadow: 0 6px 14px #0c14245e;
  font-size: 9px;
  font-weight: 850;
  backdrop-filter: blur(8px);
}
.intro-nameplate {
  position: absolute;
  bottom: 12px;
  left: 50%;
  display: flex;
  width: 86%;
  align-items: center;
  gap: 9px;
  transform: translateX(-50%);
  color: #dbe9fa;
}
.intro-nameplate i { height: 1px; flex: 1; background: #dbe9fa6e; }
.intro-nameplate span { font-size: 8px; font-weight: 900; letter-spacing: .11em; }
.intro-scroll { min-height: 0; flex: 1; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #aebed0 transparent; }
.intro-copy { padding: 20px 22px 24px; }
.intro-heading-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.intro-step-label { color: #718399; font-size: 9px; font-weight: 900; letter-spacing: .05em; }
.intro-context-label { padding: 4px 7px; border: 1px solid #9cb2c970; border-radius: 7px; color: var(--model-ink); background: var(--model-surface); font-size: 9px; font-weight: 900; }
.intro-copy h2 { max-width: 14em; margin: 13px 0 8px; color: #25384f; font-family: var(--font-editorial); font-size: 25px; line-height: 1.18; letter-spacing: -.015em; text-wrap: balance; }
.intro-self-intro { max-width: 38em; margin: 0; color: #53667d; font-size: 12px; line-height: 1.72; }
.intro-capability-tags { margin-top: 12px; }
.intro-use-cases { margin-top: 14px; padding: 11px 12px; border-radius: 11px; color: #40546e; background: #dfe8f2; }
.intro-use-cases strong { display: block; margin-bottom: 4px; color: #60748d; font-size: 9px; letter-spacing: .045em; }
.intro-use-cases p { margin: 0; font-size: 11px; line-height: 1.55; }
.intro-quote { margin: 14px 0 0; padding: 0; border: 0; color: #354c67; font-size: 12px; font-weight: 900; line-height: 1.55; }
.intro-actions {
  display: flex;
  min-height: 70px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 11px 16px max(11px, env(safe-area-inset-bottom));
  border-top: 1px solid #afbdcd75;
  background: #e8eff6f5;
  box-shadow: 0 -10px 24px #31465e16;
}
.intro-dots { display: flex; min-width: 50px; align-items: center; gap: 6px; }
.intro-dots > * { position: relative; width: 16px; height: 6px; padding: 0; border: 0; background: transparent; }
.intro-dots > *::before { content: ""; position: absolute; top: 0; left: 0; width: 6px; height: 6px; border-radius: 50%; background: #aebaca; transform-origin: 0 50%; transition: transform .24s cubic-bezier(.22, 1, .36, 1), border-radius .24s ease, background .24s ease; }
.intro-dots > .active::before, .intro-dots > [aria-current="step"]::before { border-radius: 4px; background: var(--accent-dark); transform: scaleX(2.6667); }
.intro-next {
  min-width: 154px;
  min-height: 46px;
  padding: 11px 18px;
  border-radius: 12px;
  color: #fff;
  background: var(--accent-dark);
  box-shadow: 0 9px 20px color-mix(in srgb, var(--accent-dark) 32%, transparent);
  font-size: 13px;
  font-weight: 900;
  transition: transform .16s ease, box-shadow .16s ease;
}
.intro-next:active { transform: translateY(1px) scale(.985); box-shadow: 0 5px 12px color-mix(in srgb, var(--accent-dark) 25%, transparent); }
.intro-next:disabled { color: #748297; background: #ced8e3; box-shadow: none; cursor: wait; }
.model-intro-dialog[data-context="game"] .intro-context-label { color: #745318; border-color: #c9a65766; background: #fff3cf; }
.model-intro-dialog[data-context="game"] .intro-use-cases { color: #554c3a; background: #eee9df; }

.toast { position: absolute; z-index: 20; left: 50%; bottom: 78px; max-width: 86%; padding: 9px 14px; transform: translate(-50%, 14px); border: 1px solid #ffffff30; border-radius: 10px; color: #fff; background: #17243be6; box-shadow: 0 8px 24px #1017265c; opacity: 0; pointer-events: none; transition: opacity .2s ease, transform .2s ease; font-size: 11px; font-weight: 800; text-align: center; backdrop-filter: blur(8px); }
.toast.visible { opacity: 1; transform: translate(-50%, 0); }

@keyframes aura-breathe { 50% { transform: scale(1.06); opacity: .78; } }
@keyframes music-level { from { transform: scaleY(.38); opacity: .6; } to { transform: scaleY(1); opacity: 1; } }
@keyframes music-profile-level { from { transform: scaleY(.45); } to { transform: scaleY(1.15); } }
@keyframes orbit { to { transform: rotate(360deg); } }
@keyframes avatar-float { 50% { transform: translateY(-6px); } }
@keyframes press-wave { from { transform: scale(.55); opacity: .8; } to { transform: scale(1.7); opacity: 0; } }
@keyframes score-pop { 45% { transform: translateY(-2px) scale(1.34); color: var(--accent); } }
@keyframes score-capture { 42% { color: var(--accent); text-shadow: 0 0 12px var(--particle), 0 2px 0 #fff; transform: translateY(-2px) scale(1.2); } }
@keyframes height-sync { 45% { color: var(--accent-dark); text-shadow: 0 0 10px var(--particle), 0 2px 0 #fff; transform: translateY(-2px); } }
@keyframes score-packet-life { 0% { opacity: 0; transform: translate(-50%, calc(-100% - 3px)) scale(.97); } 10%, 74% { opacity: 1; transform: translate(-50%, calc(-100% - 18px)) scale(1); } 100% { opacity: 0; transform: translate(-50%, calc(-100% - 42px)) scale(.985); } }
@keyframes score-rail { from { transform: scaleY(.12); opacity: 0; } 28%, 74% { transform: scaleY(1); opacity: 1; } to { transform: scaleY(.4); opacity: 0; } }
@keyframes score-row-scan { 0% { opacity: .35; clip-path: inset(0 100% 0 0); transform: translateY(8px); } 55%, 100% { opacity: 1; clip-path: inset(0); transform: translateY(0); } }
@keyframes score-row-slide { 0% { opacity: 0; clip-path: inset(0 0 0 100%); transform: translateX(14px); } 60%, 100% { opacity: 1; clip-path: inset(0); transform: translateX(0); } }
@keyframes score-row-skill { 0% { opacity: 0; clip-path: inset(45% 0 45% 0); transform: translateY(8px) scale(.97); } 48% { opacity: 1; clip-path: inset(0); transform: translateY(-2px) scale(1.02); } 100% { opacity: 1; clip-path: inset(0); transform: translateY(0) scale(1); } }
@keyframes score-scan-glint { from { left: -22px; opacity: 0; } 28% { opacity: .85; } to { left: calc(100% + 12px); opacity: 0; } }
@keyframes score-trace { 0% { opacity: 0; transform: translate(0, 28px) rotate(45deg) scale(.6); } 18%, 48% { opacity: 1; } 100% { opacity: 0; transform: translate(48px, -116px) rotate(45deg) scale(.2); } }
@keyframes precision-bracket { from { opacity: 0; clip-path: inset(48% 48% 48% 48%); } 38% { opacity: .8; clip-path: inset(0); } to { opacity: 0; clip-path: inset(0); transform: scale(1.05); } }
@keyframes profile-breathe { 50% { transform: translateY(-4px); } }
@keyframes background-drift { from { transform: scale(1.04) translate3d(0, -5px, 0); } to { transform: scale(1.09) translate3d(0, 7px, 0); } }
@keyframes intro-reveal { from { opacity: .88; transform: translateY(10px) scale(.988); box-shadow: 0 18px 48px #03091285; } to { opacity: 1; transform: translateY(0) scale(1); box-shadow: 0 28px 72px #030912b5; } }
@keyframes intro-avatar-breathe { 50% { transform: translateY(-5px) scale(1.01); } }

@media (max-height: 700px) {
  .home-screen { padding-top: max(21px, env(safe-area-inset-top)); }
  .home-heading h1 { font-size: 42px; }
  .home-character { top: 32%; height: 31%; padding-top: 0; }
  .avatar-sprite { width: 86px; height: 215px; }
  .character-aura { width: 176px; height: 176px; }
  .home-actions { top: 66%; }
  .home-nav { min-height: 83px; padding-top: 9px; padding-bottom: 10px; }
  .primary-button { min-height: 54px; }
  .model-tour-button { min-height: 44px; padding-top: 6px; padding-bottom: 6px; }
  .model-tour-mark { width: 25px; height: 25px; }
  .hud-status { top: max(82px, calc(env(safe-area-inset-top) + 65px)); }
  .model-intro-card { height: calc(100dvh - 24px); min-height: 0; }
  .intro-stage { height: 205px; }
  .intro-avatar { width: 84px; height: 210px; }
  .intro-copy { padding: 16px 19px 20px; }
  .intro-copy h2 { margin-top: 10px; font-size: 22px; }
  .intro-self-intro { line-height: 1.6; }
  .intro-actions { min-height: 62px; }
}

@media (prefers-reduced-motion: reduce) {
  .home-screen::before, .character-aura, .character-aura::before, .character-aura::after, .avatar-sprite, .profile-art, .intro-avatar, .model-intro-card, .music-eq i, .sound-orbit::before, .sound-orbit i { animation: none !important; }
  .score-panel b.score-pop, .score-panel b.score-capture, .height-panel b.score-pop, .height-panel b.height-sync { animation: none !important; }
  .score-burst, .score-burst::before, .score-burst::after, .score-reward, .score-reward::after, .score-capture-trace { animation-duration: .18s !important; animation-delay: 0ms !important; }
}
