/* =========================================================
   荒野乱斗友谊赛随机选角助手 · 基础
   ========================================================= */
:root {
  color-scheme: light;
  --font-sans: "Inter", "SF Pro Text", -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-display: "Inter", "SF Pro Display", -apple-system, BlinkMacSystemFont,
    "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --bg: #f5f6f8;
  --surface: #ffffff;
  --surface-soft: #fafbfc;
  --ink: #111318;
  --ink-soft: #353a44;
  --muted: #697181;
  --muted-light: #98a0ad;
  --line: rgba(17, 19, 24, 0.09);
  --line-strong: rgba(17, 19, 24, 0.16);
  --blue: #2f6bff;
  --blue-deep: #1546ce;
  --blue-soft: #edf2ff;
  --red: #ee5b4d;
  --red-deep: #c9372b;
  --red-soft: #fff1ee;
  --yellow: #f5cc4f;
  --yellow-soft: #fff7d9;
  --green: #18a06a;
  --green-soft: #eaf8f2;
  --radius-2xl: 32px;
  --radius-xl: 26px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --shadow-sm: 0 1px 2px rgba(14, 20, 32, 0.04);
  --shadow-md: 0 16px 50px rgba(14, 20, 32, 0.08);
  --shadow-lg: 0 30px 90px rgba(14, 20, 32, 0.16);
  --header-height: 72px;
  --page-width: 1200px;
  --ease-out: cubic-bezier(0.2, 0.75, 0.25, 1);
  --ease-spring: cubic-bezier(0.22, 1.2, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 18px + env(safe-area-inset-top));
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.is-drawing,
body.has-dialog {
  overflow: hidden;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  border: 0;
  background: none;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
}

img {
  max-width: 100%;
}

h1,
h2,
h3,
p {
  margin: 0;
}

::selection {
  background: var(--yellow);
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}

.icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 300;
  transform: translateY(-160%);
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
  padding: 10px 16px;
  font-size: 13px;
  transition: transform 0.2s var(--ease-out);
}

.skip-link:focus {
  transform: translateY(0);
}

[hidden] {
  display: none !important;
}

/* =========================================================
   背景与页头
   ========================================================= */
.page-ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.ambient-orb {
  position: absolute;
  display: block;
  border-radius: 50%;
  filter: blur(10px);
}

.ambient-orb-a {
  width: 54vw;
  height: 54vw;
  max-width: 760px;
  max-height: 760px;
  top: -28vw;
  right: -12vw;
  background: radial-gradient(circle, rgba(47, 107, 255, 0.12), transparent 65%);
}

.ambient-orb-b {
  width: 42vw;
  height: 42vw;
  max-width: 620px;
  max-height: 620px;
  top: 30vh;
  left: -26vw;
  background: radial-gradient(circle, rgba(245, 204, 79, 0.16), transparent 66%);
}

.ambient-grid {
  position: absolute;
  inset: 0;
  opacity: 0.36;
  background-image: linear-gradient(rgba(17, 19, 24, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(17, 19, 24, 0.035) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(to bottom, black, transparent 72%);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  padding-top: env(safe-area-inset-top);
  border-bottom: 1px solid rgba(17, 19, 24, 0.06);
  background: rgba(245, 246, 248, 0.82);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
}

.topbar-inner {
  width: 100%;
  max-width: var(--page-width);
  height: var(--header-height);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 32px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  flex: none;
  border-radius: 14px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: none;
  overflow: hidden;
  border-radius: 12px;
  display: grid;
  place-items: center;
  box-shadow: 0 5px 15px rgba(17, 19, 24, 0.18);
}

.brand-mark img {
  width: 100%;
  height: 100%;
  display: block;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-copy strong {
  font-size: 17px;
  font-weight: 780;
  letter-spacing: -0.04em;
  white-space: nowrap;
}

.brand-copy small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.11em;
  white-space: nowrap;
}

.topnav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: 6px;
}

.topnav a {
  border-radius: 10px;
  padding: 8px 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  transition: color 0.2s, background 0.2s;
}

.topnav a:hover {
  color: var(--ink);
  background: rgba(17, 19, 24, 0.045);
}

.maintainer-link {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.66);
  padding: 8px 14px;
  color: var(--ink-soft);
  font-size: 12.5px;
  font-weight: 600;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}

.maintainer-link:hover {
  border-color: var(--line-strong);
  background: #fff;
  transform: translateY(-1px);
}

.maintainer-link .icon {
  width: 14px;
  height: 14px;
}

/* =========================================================
   首屏主视觉
   ========================================================= */
main {
  width: 100%;
}

.hero-section {
  width: 100%;
  max-width: var(--page-width);
  min-height: 486px;
  margin: 0 auto;
  padding: 64px 24px 58px;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(360px, 0.98fr);
  align-items: center;
  gap: 48px;
}

.eyebrow {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  line-height: 1.4;
}

.eyebrow-light {
  color: rgba(255, 255, 255, 0.56);
}

.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(24, 160, 106, 0.12);
  vertical-align: 1px;
}

.hero-copy .eyebrow {
  display: flex;
  align-items: center;
  gap: 2px;
  animation: reveal-up 0.7s var(--ease-out) both;
}

.hero-section h1 {
  max-width: 660px;
  margin-top: 23px;
  font-family: var(--font-display);
  font-size: clamp(52px, 6.5vw, 84px);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.065em;
  animation: reveal-up 0.75s 0.05s var(--ease-out) both;
}

.hero-section h1 span {
  position: relative;
  display: inline-block;
  z-index: 0;
  color: var(--blue);
}

.hero-section h1 span::after {
  content: "";
  position: absolute;
  z-index: -1;
  left: -0.03em;
  right: -0.06em;
  bottom: 0.06em;
  height: 0.25em;
  border-radius: 4px;
  background: var(--yellow);
  transform: rotate(-1.1deg);
  transform-origin: left center;
  animation: marker-in 0.65s 0.55s var(--ease-out) both;
}

.hero-lead {
  max-width: 510px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.85;
  text-wrap: balance;
  animation: reveal-up 0.75s 0.12s var(--ease-out) both;
}

.hero-metrics {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-top: 36px;
  animation: reveal-up 0.75s 0.18s var(--ease-out) both;
}

.metric {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.metric strong {
  font-family: var(--font-display);
  font-size: 29px;
  font-weight: 750;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

.metric span {
  color: var(--muted);
  font-size: 11.5px;
  white-space: nowrap;
}

.metric-divider {
  width: 1px;
  height: 25px;
  background: var(--line);
}

.hero-visual {
  position: relative;
  width: 100%;
  min-height: 390px;
  animation: reveal-scale 0.9s 0.16s var(--ease-out) both;
}

.card-fan {
  position: absolute;
  top: 26px;
  left: 50%;
  width: 370px;
  height: 336px;
  transform: translateX(-50%);
}

.fan-card {
  position: absolute;
  top: 20px;
  left: 50%;
  width: 210px;
  height: 276px;
  margin-left: -105px;
  overflow: hidden;
  border: 1px solid rgba(17, 19, 24, 0.09);
  border-radius: 27px;
  background:
    radial-gradient(circle at 50% 28%, rgba(255, 255, 255, 0.94), transparent 55%),
    linear-gradient(150deg, #f2f5fa, #e8edf6 52%, #dce3ef);
  box-shadow:
    0 2px 1px rgba(255, 255, 255, 0.8) inset,
    0 24px 55px rgba(19, 29, 48, 0.14);
  transition: transform 0.5s var(--ease-out);
  will-change: transform;
}

.fan-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.62);
  pointer-events: none;
}

.fan-card img {
  width: 100%;
  height: 100%;
  padding: 13px;
  object-fit: contain;
  transform: translateY(-3%);
}

.fan-card-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(17, 19, 24, 0.14);
  font-family: var(--font-display);
  font-size: 112px;
  font-weight: 800;
}

.fan-card-back {
  transform: translate(-78px, 28px) rotate(-11deg);
  z-index: 1;
  opacity: 0.84;
}

.fan-card-mid {
  transform: translate(78px, 18px) rotate(9deg);
  z-index: 2;
  opacity: 0.92;
}

.fan-card-front {
  transform: translateY(0) rotate(-2deg);
  z-index: 3;
}

.hero-visual:hover .fan-card-back {
  transform: translate(-90px, 26px) rotate(-14deg);
}

.hero-visual:hover .fan-card-mid {
  transform: translate(90px, 16px) rotate(12deg);
}

.hero-visual:hover .fan-card-front {
  transform: translateY(-5px) rotate(-1deg);
}

.fan-spark {
  position: absolute;
  z-index: 5;
  width: 12px;
  height: 12px;
  background: var(--yellow);
  clip-path: polygon(50% 0, 61% 38%, 100% 50%, 61% 62%, 50% 100%, 39% 62%, 0 50%, 39% 38%);
  animation: sparkle 3.8s ease-in-out infinite;
}

.fan-spark-a {
  top: 20px;
  right: 24px;
}

.fan-spark-b {
  bottom: 18px;
  left: 30px;
  width: 8px;
  height: 8px;
  background: var(--blue);
  animation-delay: -1.8s;
}

.hero-emote {
  position: absolute;
  z-index: 8;
  top: -7px;
  right: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: bob 4.2s ease-in-out infinite;
}

.hero-emote img {
  width: 112px;
  height: 112px;
  object-fit: contain;
  filter: drop-shadow(0 16px 22px rgba(17, 19, 24, 0.14));
}

.emote-bubble {
  position: relative;
  margin-bottom: -8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
  padding: 6px 11px;
  color: var(--ink-soft);
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
  backdrop-filter: blur(8px);
}

.emote-bubble::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -4px;
  width: 7px;
  height: 7px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
  transform: translateX(-50%) rotate(45deg);
}

.hero-visual-caption {
  position: absolute;
  right: 16px;
  bottom: 6px;
  color: var(--muted-light);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.12em;
}

/* =========================================================
   两个主操作面板
   ========================================================= */
.control-grid {
  width: 100%;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 0 24px 26px;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 18px;
}

.panel {
  position: relative;
  min-height: 350px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius-2xl);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-sm);
  text-align: left;
  transition:
    transform 0.35s var(--ease-out),
    box-shadow 0.35s var(--ease-out),
    border-color 0.35s;
}

.pool-panel {
  display: flex;
  flex-direction: column;
  cursor: pointer;
  overflow: hidden;
}

.pool-panel::before {
  content: "";
  position: absolute;
  width: 250px;
  height: 250px;
  right: -75px;
  bottom: -105px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(47, 107, 255, 0.1), transparent 68%);
  transition: transform 0.5s var(--ease-out);
}

.pool-panel:hover {
  transform: translateY(-4px);
  border-color: rgba(47, 107, 255, 0.22);
  box-shadow: var(--shadow-md);
}

.pool-panel:hover::before {
  transform: scale(1.18);
}

.pool-panel:active {
  transform: translateY(-1px) scale(0.995);
}

.draw-panel {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(248, 249, 252, 0.94)),
    var(--surface);
}

.panel-head,
.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.panel-title-row {
  margin-top: 13px;
}

.panel h2 {
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 760;
  line-height: 1.2;
  letter-spacing: -0.035em;
}

.panel-arrow {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink);
  transition: background 0.25s, color 0.25s, transform 0.25s;
}

.panel-arrow svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pool-panel:hover .panel-arrow {
  transform: translateX(3px);
  background: var(--ink);
  color: #fff;
}

.count-pill,
.mode-current {
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.count-pill {
  background: var(--ink);
  color: #fff;
}

.mode-current {
  background: var(--blue-soft);
  color: var(--blue-deep);
}

.panel-desc {
  max-width: 380px;
  margin-top: 9px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.7;
}

.pool-preview {
  display: flex;
  align-items: center;
  min-height: 60px;
  margin-top: auto;
  padding-top: 30px;
}

.pool-preview-face {
  position: relative;
  width: 54px;
  height: 54px;
  margin-left: -10px;
  overflow: hidden;
  border: 3px solid #fff;
  border-radius: 50%;
  background: #edf0f5;
  box-shadow: 0 4px 12px rgba(17, 19, 24, 0.08);
}

.pool-preview-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted-light);
  font-size: 16px;
  font-weight: 800;
}

.pool-preview-more {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin-left: -10px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(17, 19, 24, 0.08);
}

.pool-preview-face:first-child {
  margin-left: 0;
}

.pool-preview-face img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 3px;
}

.pool-preview-empty {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted-light);
  font-size: 11.5px;
}

.pool-preview-empty::before {
  content: "";
  width: 34px;
  height: 34px;
  border: 1px dashed var(--line-strong);
  border-radius: 50%;
}

.panel-foot {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 16px;
  color: var(--muted-light);
  font-size: 10.5px;
  font-weight: 550;
}

.panel-foot .icon {
  width: 14px;
  height: 14px;
}

.mode-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  margin-top: 18px;
}

.mode-option {
  min-height: 53px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.65);
  padding: 9px 10px;
  text-align: left;
  transition:
    border-color 0.2s,
    background 0.2s,
    color 0.2s,
    transform 0.2s var(--ease-out);
}

.mode-option strong {
  display: block;
  font-size: 15px;
  font-weight: 760;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.mode-option span {
  display: block;
  margin-top: 3px;
  color: var(--muted-light);
  font-size: 9.5px;
  line-height: 1.3;
  white-space: nowrap;
}

.mode-option:hover {
  border-color: var(--line-strong);
  background: #fff;
  transform: translateY(-1px);
}

.mode-option[aria-checked="true"] {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
  box-shadow: 0 8px 18px rgba(17, 19, 24, 0.13);
}

.mode-option[aria-checked="true"] span {
  color: rgba(255, 255, 255, 0.55);
}

.draw-button {
  width: 100%;
  min-height: 66px;
  margin-top: 14px;
  padding: 10px 17px;
  gap: 12px;
  justify-content: flex-start;
  text-align: left;
}

.draw-button-icon {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.11);
  color: var(--yellow);
  flex: none;
}

.draw-button-icon svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
}

.draw-button-copy {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1;
}

.draw-button-copy strong {
  font-size: 14.5px;
  font-weight: 700;
}

.draw-button-copy small {
  color: rgba(255, 255, 255, 0.52);
  font-size: 10px;
}

.draw-button-arrow {
  opacity: 0.58;
}

.draw-button-arrow svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* =========================================================
   通用按钮
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 9px 16px;
  font-size: 12.5px;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  transition:
    transform 0.2s var(--ease-out),
    box-shadow 0.2s,
    background 0.2s,
    border-color 0.2s,
    color 0.2s,
    opacity 0.2s;
}

.btn:hover:not(:disabled) {
  transform: translateY(-1px);
}

.btn:active:not(:disabled) {
  transform: translateY(0) scale(0.985);
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.btn .icon {
  width: 15px;
  height: 15px;
}

.btn-primary {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
  box-shadow: 0 6px 14px rgba(17, 19, 24, 0.13);
}

.btn-primary:hover:not(:disabled) {
  background: #242833;
  box-shadow: 0 10px 24px rgba(17, 19, 24, 0.19);
}

.btn-dark {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

.btn-dark:hover:not(:disabled) {
  background: #292e39;
}

.btn-ghost {
  border-color: var(--line);
  background: transparent;
  color: var(--ink-soft);
}

.btn-ghost:hover:not(:disabled) {
  border-color: var(--line-strong);
  background: rgba(17, 19, 24, 0.035);
}

.btn-full {
  width: 100%;
}

.btn-danger-ghost {
  color: var(--red-deep);
}

.btn-danger-ghost:hover:not(:disabled) {
  border-color: rgba(238, 91, 77, 0.28);
  background: var(--red-soft);
}

.btn.is-loading {
  pointer-events: none;
  opacity: 0.7;
}

.btn.is-loading::after {
  content: "";
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

/* =========================================================
   结果区
   ========================================================= */
.result-shell {
  width: 100%;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 12px 24px 28px;
}

.result-empty {
  position: relative;
  min-height: 252px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-2xl);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.72)),
    var(--surface);
  padding: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.result-empty-copy {
  position: relative;
  z-index: 2;
  max-width: 450px;
}

.result-empty h2 {
  margin-top: 9px;
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 760;
  line-height: 1.25;
  letter-spacing: -0.045em;
}

.result-empty p:last-child {
  margin-top: 9px;
  color: var(--muted);
  font-size: 12.5px;
}

.portrait-marquee {
  position: absolute;
  right: -20px;
  bottom: -8px;
  left: 38%;
  display: flex;
  gap: 10px;
  opacity: 0.33;
  mask-image: linear-gradient(90deg, transparent, black 22%, black 78%, transparent);
  pointer-events: none;
}

.portrait-marquee-track {
  display: flex;
  gap: 10px;
  flex: none;
  animation: marquee 32s linear infinite;
}

.portrait-marquee-face {
  position: relative;
  width: 74px;
  height: 74px;
  flex: none;
  overflow: hidden;
  border: 1px solid rgba(17, 19, 24, 0.06);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(17, 19, 24, 0.05);
}

.portrait-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted-light);
  font-size: 20px;
  font-weight: 800;
}

.portrait-marquee-face img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 5px;
}

.empty-emote {
  position: absolute;
  z-index: 1;
  right: 36px;
  bottom: 22px;
  opacity: 0.88;
  animation: bob 4.6s ease-in-out infinite;
}

.empty-emote img {
  width: 92px;
  height: 92px;
  object-fit: contain;
  filter: drop-shadow(0 12px 18px rgba(17, 19, 24, 0.12));
}

.result-content {
  border: 1px solid var(--line);
  border-radius: var(--radius-2xl);
  background: rgba(255, 255, 255, 0.92);
  padding: 30px;
  box-shadow: var(--shadow-md);
  animation: result-in 0.6s var(--ease-out) both;
}

.result-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
}

.result-header h2 {
  margin-top: 7px;
  font-family: var(--font-display);
  font-size: clamp(28px, 3.5vw, 40px);
  font-weight: 780;
  line-height: 1.15;
  letter-spacing: -0.05em;
}

.result-header h2:focus {
  outline: none;
}

.result-meta {
  margin-top: 8px;
  color: var(--muted);
  font-size: 11.5px;
}

.result-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
}

.result-arena {
  position: relative;
  margin-top: 24px;
  overflow: hidden;
  border: 1px solid rgba(17, 19, 24, 0.075);
  border-radius: 25px;
  background:
    radial-gradient(circle at 12% 32%, rgba(47, 107, 255, 0.09), transparent 33%),
    radial-gradient(circle at 88% 68%, rgba(238, 91, 77, 0.075), transparent 32%),
    linear-gradient(180deg, #f8faff, #f5f6f9);
  padding: 28px;
}

.result-arena::before {
  content: "";
  position: absolute;
  top: 12%;
  bottom: 12%;
  left: 50%;
  width: 1px;
  background: linear-gradient(transparent, rgba(17, 19, 24, 0.09), transparent);
  pointer-events: none;
}

.result-arena::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 240px;
  height: 240px;
  border: 1px solid rgba(17, 19, 24, 0.055);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.result-arena[data-layout="team"] {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 76px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.team {
  position: relative;
  z-index: 2;
  min-width: 0;
}

.team-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 15px;
  padding: 0 2px;
}

.team-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex: none;
}

.team-blue .team-dot {
  background: var(--blue);
  box-shadow: 0 0 0 4px rgba(47, 107, 255, 0.12);
}

.team-red .team-dot {
  background: var(--red);
  box-shadow: 0 0 0 4px rgba(238, 91, 77, 0.12);
}

.team-name {
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.02em;
}

.team-size {
  margin-left: auto;
  color: var(--muted-light);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.team-red .team-head {
  flex-direction: row-reverse;
}

.team-red .team-size {
  margin-left: 0;
  margin-right: auto;
}

.team-red .roster {
  justify-content: center;
}

.roster {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: center;
  gap: 9px;
}

.versus {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  width: 60px;
  height: 60px;
  margin: 0 auto;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  box-shadow: 0 12px 26px rgba(17, 19, 24, 0.22);
}

.versus strong {
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}

.versus span {
  color: rgba(255, 255, 255, 0.54);
  font-size: 8px;
  font-weight: 650;
  letter-spacing: 0.05em;
}

.hero-card {
  position: relative;
  width: 100%;
  overflow: hidden;
  border: 1px solid rgba(17, 19, 24, 0.085);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 7px 18px rgba(17, 19, 24, 0.06);
  animation: card-in 0.55s var(--ease-spring) both;
  animation-delay: var(--delay, 0ms);
}

.team-blue .hero-card {
  border-top-color: rgba(47, 107, 255, 0.3);
}

.team-red .hero-card {
  border-top-color: rgba(238, 91, 77, 0.3);
}

.hero-card-visual {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 30%, #fff, transparent 50%),
    linear-gradient(150deg, #eef2f8, #e2e8f1);
}

.team-red .hero-card-visual {
  background:
    radial-gradient(circle at 50% 30%, #fff, transparent 50%),
    linear-gradient(150deg, #fbf0ed, #f2e4e0);
}

.hero-card-visual img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 5%;
  transition: transform 0.35s var(--ease-out), filter 0.25s;
}

.hero-card:hover .hero-card-visual img {
  transform: scale(1.04);
}

.hero-card-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(17, 19, 24, 0.12);
  font-family: var(--font-display);
  font-size: 50px;
  font-weight: 800;
}

.hero-card-tag {
  position: absolute;
  top: 7px;
  left: 7px;
  z-index: 2;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  padding: 2px 6px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.04em;
  backdrop-filter: blur(5px);
}

.team-blue .hero-card-tag {
  color: var(--blue-deep);
}

.team-red .hero-card-tag {
  color: var(--red-deep);
}

.hero-card-body {
  padding: 6px 8px 8px;
  text-align: center;
}

.hero-card-name {
  min-height: 2.1em;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.15;
  letter-spacing: -0.015em;
  word-break: break-word;
}

.reselect-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 100%;
  min-height: 24px;
  margin-top: 4px;
  border-top: 1px solid rgba(17, 19, 24, 0.06);
  padding-top: 5px;
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 600;
  transition: color 0.2s, background 0.2s;
}

.reselect-button:hover {
  color: var(--blue-deep);
}

.reselect-button .icon {
  width: 10px;
  height: 10px;
}

.hero-card.is-reselecting .hero-card-visual img {
  animation: reselect-blur 0.58s linear;
}

.hero-card.is-reselecting::after {
  content: "";
  position: absolute;
  z-index: 5;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(
    105deg,
    transparent 30%,
    rgba(255, 255, 255, 0.62) 47%,
    transparent 65%
  );
  transform: translateX(-120%);
  animation: sweep 0.58s ease-in-out;
  pointer-events: none;
}

.hero-card.is-reselecting {
  border-color: rgba(47, 107, 255, 0.3);
}

.hero-card.is-settled {
  animation: card-settle 0.45s var(--ease-spring);
}

/* 每种模式单独控制牌面尺寸 */
.result-arena[data-mode="1v1"] .roster {
  min-height: 285px;
  align-items: center;
}

.result-arena[data-mode="1v1"] .hero-card {
  width: min(100%, 238px);
}

.result-arena[data-mode="1v1"] .hero-card-name {
  font-size: 17px;
  min-height: auto;
  padding: 2px 0;
}

.result-arena[data-mode="1v1"] .hero-card-body {
  padding: 9px 12px 11px;
}

.result-arena[data-mode="1v1"] .reselect-button {
  font-size: 10.5px;
  min-height: 28px;
}

.result-arena[data-mode="2v2"] .hero-card {
  width: calc(50% - 5px);
}

.result-arena[data-mode="2v2"] .hero-card-name {
  font-size: 13px;
}

.result-arena[data-mode="3v3"] .hero-card {
  width: calc(33.333% - 6px);
}

.result-arena[data-mode="3v3"] .hero-card-name {
  font-size: 11.5px;
}

.result-arena[data-mode="4v4"] .hero-card {
  width: calc(25% - 7px);
}

.result-arena[data-mode="4v4"] .hero-card-name {
  min-height: 2.4em;
  font-size: 10px;
}

.result-arena[data-mode="4v4"] .reselect-button {
  font-size: 8.5px;
}

.result-arena[data-mode="5v5"] .hero-card {
  width: calc(20% - 7.2px);
}

.result-arena[data-mode="5v5"] .hero-card-tag {
  display: none;
}

.result-arena[data-mode="5v5"] .hero-card-name {
  min-height: 2.5em;
  font-size: 9.5px;
}

.result-arena[data-mode="5v5"] .hero-card-body {
  padding: 4px 4px 5px;
}

.result-arena[data-mode="5v5"] .reselect-button {
  font-size: 8px;
  min-height: 20px;
}

.result-arena[data-mode="5v5"] .team-head {
  margin-bottom: 10px;
}

/* 单抽结果 */
.result-arena[data-layout="single"] {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  padding: 38px;
  background:
    radial-gradient(circle at 50% 44%, rgba(47, 107, 255, 0.12), transparent 28%),
    radial-gradient(circle at 70% 80%, rgba(245, 204, 79, 0.16), transparent 24%),
    linear-gradient(180deg, #f9fbff, #f3f5f9);
}

.result-arena[data-layout="single"]::before,
.result-arena[data-layout="single"]::after {
  display: none;
}

.single-wrap {
  position: relative;
  z-index: 2;
  width: min(100%, 310px);
  text-align: center;
}

.single-kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  padding: 5px 11px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 650;
  backdrop-filter: blur(6px);
}

.single-kicker::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}

.result-arena[data-layout="single"] .hero-card {
  width: 100%;
  border-radius: 26px;
  box-shadow: 0 20px 50px rgba(17, 19, 24, 0.13);
}

.result-arena[data-layout="single"] .hero-card-tag {
  display: none;
}

.result-arena[data-layout="single"] .hero-card-visual {
  aspect-ratio: 1 / 1.04;
}

.result-arena[data-layout="single"] .hero-card-body {
  padding: 12px 16px 14px;
}

.result-arena[data-layout="single"] .hero-card-name {
  min-height: auto;
  padding: 2px 0 4px;
  font-size: 23px;
}

.result-arena[data-layout="single"] .reselect-button {
  min-height: 30px;
  font-size: 11px;
}

.single-orbit {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 520px;
  height: 520px;
  border: 1px solid rgba(47, 107, 255, 0.11);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.single-orbit::before,
.single-orbit::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: var(--yellow);
}

.single-orbit::before {
  top: 44px;
  right: 67px;
  width: 10px;
  height: 10px;
  box-shadow: 0 0 0 7px rgba(245, 204, 79, 0.14);
}

.single-orbit::after {
  left: 58px;
  bottom: 82px;
  width: 6px;
  height: 6px;
  background: var(--blue);
  box-shadow: 0 0 0 6px rgba(47, 107, 255, 0.1);
}

.result-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 18px;
  padding: 0 3px;
}

.result-footer-copy {
  display: flex;
  align-items: center;
  gap: 12px;
}

.result-footer-copy img {
  width: 54px;
  height: 54px;
  object-fit: contain;
  filter: drop-shadow(0 6px 8px rgba(17, 19, 24, 0.1));
}

.result-footer-copy p {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.65;
}

.copy-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 7px 11px;
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 600;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.copy-button:hover {
  border-color: var(--line-strong);
  background: rgba(17, 19, 24, 0.03);
  color: var(--ink);
}

.copy-button .icon {
  width: 13px;
  height: 13px;
}

/* =========================================================
   随机数生成器
   ========================================================= */
.random-card {
  width: calc(100% - 48px);
  max-width: calc(var(--page-width) - 48px);
  margin: 0 auto 42px;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) minmax(260px, 340px) 155px;
  align-items: center;
  gap: 24px;
  overflow: hidden;
  border-radius: 25px;
  background:
    radial-gradient(circle at 18% 20%, rgba(47, 107, 255, 0.18), transparent 35%),
    radial-gradient(circle at 92% 80%, rgba(245, 204, 79, 0.12), transparent 22%),
    var(--ink);
  padding: 23px 26px;
  color: #fff;
  box-shadow: 0 18px 40px rgba(17, 19, 24, 0.16);
}

.random-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--yellow);
}

.random-icon svg {
  width: 31px;
  height: 31px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
}

.random-copy .eyebrow {
  color: rgba(255, 255, 255, 0.4);
}

.random-copy h2 {
  margin-top: 3px;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 720;
  letter-spacing: -0.025em;
}

.random-copy p:last-child {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.42);
  font-size: 10px;
  line-height: 1.6;
}

.random-form {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 5px 9px;
}

.random-form > label {
  color: rgba(255, 255, 255, 0.42);
  font-size: 10px;
  font-weight: 600;
}

.random-input-row {
  display: flex;
  gap: 7px;
}

.random-input-row input {
  width: 100%;
  min-width: 0;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  padding: 0 11px;
  color: #fff;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.random-input-row input:focus {
  border-color: rgba(255, 255, 255, 0.36);
  background: rgba(255, 255, 255, 0.1);
}

.random-submit {
  min-height: 40px;
  background: var(--yellow);
  border-color: var(--yellow);
  color: var(--ink);
  padding: 8px 13px;
  font-size: 11.5px;
}

.random-submit:hover:not(:disabled) {
  background: #ffdb65;
  border-color: #ffdb65;
}

.random-hint {
  grid-column: 2;
  color: rgba(255, 255, 255, 0.3);
  font-size: 9px;
}

.random-result {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 58px;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.random-result-label {
  width: 28px;
  color: rgba(255, 255, 255, 0.34);
  font-size: 9px;
  line-height: 1.35;
}

.random-result strong {
  min-width: 76px;
  color: var(--yellow);
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 780;
  line-height: 1;
  letter-spacing: -0.04em;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.random-result strong.is-rolling {
  animation: number-roll 0.12s linear infinite;
}

.random-result strong.is-settled {
  animation: number-settle 0.4s var(--ease-spring);
}

/* =========================================================
   页脚
   ========================================================= */
.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.46);
}

.footer-inner {
  width: 100%;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 28px 24px 40px;
  display: flex;
  align-items: center;
  gap: 20px;
  color: var(--muted);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  flex: none;
}

.brand-mark-small {
  width: 29px;
  height: 29px;
  border-radius: 9px;
  box-shadow: none;
}

.footer-brand p {
  color: var(--ink-soft);
  font-size: 11.5px;
  font-weight: 650;
}

.footer-note {
  margin-left: auto;
  color: var(--muted-light);
  font-size: 9.5px;
  text-align: right;
}

.footer-admin {
  flex: none;
  border-bottom: 1px solid transparent;
  padding: 2px 0;
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 600;
  transition: color 0.2s, border-color 0.2s;
}

.footer-admin:hover {
  color: var(--ink);
  border-color: var(--line-strong);
}

/* =========================================================
   英雄池弹层
   ========================================================= */
dialog {
  color: var(--ink);
}

dialog::backdrop {
  background: rgba(12, 16, 24, 0.48);
  backdrop-filter: blur(9px);
  -webkit-backdrop-filter: blur(9px);
  animation: backdrop-in 0.25s ease both;
}

.sheet {
  width: min(1020px, calc(100vw - 48px));
  max-width: none;
  max-height: min(880px, calc(100dvh - 48px));
  margin: auto;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: var(--radius-2xl);
  background: transparent;
}

.sheet[open] {
  animation: dialog-in 0.32s var(--ease-out) both;
}

.sheet-inner {
  display: flex;
  flex-direction: column;
  max-height: min(880px, calc(100dvh - 48px));
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: var(--radius-2xl);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}

.sheet-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 28px 18px;
  border-bottom: 1px solid var(--line);
}

.sheet-header h2 {
  margin-top: 5px;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 760;
  line-height: 1.25;
  letter-spacing: -0.04em;
}

.sheet-header h2:focus,
.admin-header h2:focus {
  outline: none;
}

.sheet-header-side {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: none;
}

.sheet-count {
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}

.sheet-count strong {
  color: var(--ink);
  font-size: 19px;
  font-weight: 760;
  font-variant-numeric: tabular-nums;
}

.icon-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--muted);
  transition: border-color 0.2s, background 0.2s, color 0.2s, transform 0.2s;
}

.icon-button:hover {
  border-color: var(--line-strong);
  background: rgba(17, 19, 24, 0.04);
  color: var(--ink);
  transform: rotate(3deg);
}

.icon-button svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.pool-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 28px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.toolbar-actions {
  display: flex;
  gap: 7px;
  flex: none;
}

.chip-button {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 6px 13px;
  color: var(--ink-soft);
  font-size: 10.5px;
  font-weight: 650;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.chip-button:hover {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

.chip-button-quiet {
  color: var(--muted);
}

.chip-button-quiet:hover {
  border-color: rgba(238, 91, 77, 0.28);
  background: var(--red-soft);
  color: var(--red-deep);
}

.search-box {
  position: relative;
  width: min(280px, 100%);
  display: flex;
  align-items: center;
}

.search-box .icon {
  position: absolute;
  left: 11px;
  width: 15px;
  height: 15px;
  color: var(--muted-light);
  pointer-events: none;
}

.search-box input {
  width: 100%;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 0 58px 0 33px;
  font-size: 11.5px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-box input:focus {
  border-color: rgba(47, 107, 255, 0.5);
  box-shadow: 0 0 0 3px rgba(47, 107, 255, 0.08);
}

.search-box input::placeholder {
  color: var(--muted-light);
}

.search-clear {
  position: absolute;
  right: 6px;
  border-radius: 6px;
  padding: 4px 6px;
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 600;
}

.search-clear:hover {
  background: rgba(17, 19, 24, 0.05);
  color: var(--ink);
}

.pool-layout {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  min-height: 0;
  flex: 1;
}

.letter-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  overflow-y: auto;
  border-right: 1px solid var(--line);
  padding: 12px 0;
  scrollbar-width: none;
}

.letter-nav::-webkit-scrollbar {
  display: none;
}

.letter-nav button {
  width: 26px;
  height: 18px;
  border-radius: 5px;
  color: var(--muted-light);
  font-size: 9px;
  font-weight: 700;
  line-height: 1;
  transition: color 0.15s, background 0.15s;
}

.letter-nav button:hover {
  background: rgba(17, 19, 24, 0.05);
  color: var(--ink);
}

.letter-nav button.is-active {
  background: var(--ink);
  color: #fff;
}

.letter-nav button:disabled {
  opacity: 0.25;
  cursor: default;
}

.pool-scroll {
  position: relative;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 8px 22px 28px;
  scrollbar-width: thin;
  scrollbar-color: rgba(17, 19, 24, 0.16) transparent;
}

.pool-scroll::-webkit-scrollbar {
  width: 9px;
}

.pool-scroll::-webkit-scrollbar-thumb {
  border: 3px solid #fff;
  border-radius: 99px;
  background: rgba(17, 19, 24, 0.17);
}

.hero-group {
  padding-top: 7px;
  scroll-margin-top: 8px;
}

.hero-group-head {
  position: sticky;
  top: -8px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 -22px;
  padding: 8px 22px;
  background: rgba(255, 255, 255, 0.91);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.hero-group-letter {
  display: grid;
  place-items: center;
  width: 21px;
  height: 21px;
  border-radius: 6px;
  background: var(--ink);
  color: #fff;
  font-size: 10px;
  font-weight: 750;
  line-height: 1;
}

.hero-group-count {
  color: var(--muted-light);
  font-size: 9px;
  font-weight: 600;
}

.hero-group-line {
  flex: 1;
  height: 1px;
  background: var(--line);
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
  gap: 7px;
  padding-top: 5px;
}

.hero-tile {
  position: relative;
  min-height: 105px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
  padding: 7px 4px 6px;
  text-align: center;
  transition:
    border-color 0.18s,
    background 0.18s,
    transform 0.18s var(--ease-out),
    box-shadow 0.18s;
}

.hero-tile:hover {
  border-color: var(--line-strong);
  background: #fcfdff;
  transform: translateY(-2px);
  box-shadow: 0 7px 14px rgba(17, 19, 24, 0.06);
}

.hero-tile[aria-pressed="true"] {
  border-color: rgba(47, 107, 255, 0.38);
  background: linear-gradient(180deg, #f7f9ff, #eef3ff);
  box-shadow: 0 0 0 1px rgba(47, 107, 255, 0.06) inset;
}

.hero-tile[aria-pressed="false"] .hero-tile-image img {
  filter: grayscale(0.72);
  opacity: 0.55;
}

.hero-tile-image {
  position: relative;
  width: 54px;
  height: 54px;
  margin: 0 auto 3px;
  overflow: hidden;
  border-radius: 50%;
  background: #f1f4f8;
}

.hero-tile-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2px;
  transition: filter 0.2s, opacity 0.2s, transform 0.2s;
}

.hero-tile:hover .hero-tile-image img {
  transform: scale(1.05);
}

.hero-tile-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted-light);
  font-size: 19px;
  font-weight: 800;
}

.hero-tile-name {
  display: block;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 10px;
  font-weight: 650;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-tile-check {
  position: absolute;
  z-index: 4;
  top: 6px;
  right: 6px;
  width: 16px;
  height: 16px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: #fff;
  color: transparent;
  box-shadow: 0 1px 4px rgba(17, 19, 24, 0.12);
  pointer-events: none;
  transition: background 0.18s, border-color 0.18s, color 0.18s;
}

.hero-tile-check svg {
  width: 9px;
  height: 9px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hero-tile[aria-pressed="true"] .hero-tile-check {
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
}

.search-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  text-align: center;
}

.search-empty-mark {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border: 1px dashed var(--line-strong);
  border-radius: 50%;
  color: var(--muted-light);
  font-family: var(--font-display);
  font-size: 27px;
  font-weight: 700;
}

.search-empty h3 {
  margin-top: 16px;
  font-size: 16px;
  font-weight: 700;
}

.search-empty p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
}

.search-empty .btn {
  margin-top: 16px;
}

.sheet-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  background: #fbfcfd;
  padding: 13px 28px;
}

.sheet-footer-count {
  display: flex;
  align-items: center;
  color: var(--muted);
  font-size: 10.5px;
}

.sheet-footer-count strong {
  color: var(--ink);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.sheet-footer-actions {
  display: flex;
  gap: 8px;
}

.sheet-footer-actions .btn {
  min-width: 88px;
}

/* =========================================================
   维护者面板
   ========================================================= */
.admin-dialog {
  width: min(950px, calc(100vw - 48px));
  max-width: none;
  max-height: min(900px, calc(100dvh - 48px));
  margin: auto;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: var(--radius-2xl);
  background: transparent;
}

.admin-dialog[open] {
  animation: dialog-in 0.32s var(--ease-out) both;
}

.admin-shell {
  max-height: min(900px, calc(100dvh - 48px));
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius-2xl);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  scrollbar-width: thin;
}

.admin-header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.93);
  padding: 22px 28px 17px;
  backdrop-filter: blur(14px);
}

.admin-header h2 {
  margin-top: 4px;
  font-family: var(--font-display);
  font-size: 23px;
  font-weight: 760;
  letter-spacing: -0.04em;
}

.admin-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 330px;
  color: var(--muted);
}

.admin-loading p {
  margin-left: 8px;
  font-size: 11px;
}

.loading-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--ink);
  animation: loading-pulse 1.1s ease-in-out infinite;
}

.loading-dot:nth-child(2) {
  animation-delay: 0.12s;
}

.loading-dot:nth-child(3) {
  animation-delay: 0.24s;
}

.admin-view {
  padding: 26px 28px 30px;
}

.login-view {
  max-width: 430px;
  margin: 0 auto;
  padding-top: 42px;
  padding-bottom: 48px;
  text-align: center;
}

.login-mark {
  width: 62px;
  height: 62px;
  margin: 0 auto 18px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 19px;
  background: var(--surface-soft);
  color: var(--ink);
}

.login-mark svg {
  width: 33px;
  height: 33px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-view h3 {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 750;
  letter-spacing: -0.03em;
}

.login-view > p {
  max-width: 330px;
  margin: 8px auto 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.7;
}

.stack-form {
  margin-top: 22px;
  text-align: left;
}

.stack-form label,
.key-change-form label {
  display: block;
  margin-bottom: 6px;
  color: var(--ink-soft);
  font-size: 10.5px;
  font-weight: 650;
}

.stack-form input,
.key-change-form input {
  width: 100%;
  height: 43px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fff;
  padding: 0 12px;
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.stack-form input:focus,
.key-change-form input:focus {
  border-color: rgba(47, 107, 255, 0.55);
  box-shadow: 0 0 0 3px rgba(47, 107, 255, 0.08);
}

.stack-form .btn {
  margin-top: 12px;
}

.form-error {
  min-height: 17px;
  margin-top: 5px;
  color: var(--red-deep);
  font-size: 10.5px;
}

.form-error:empty {
  min-height: 8px;
}

.security-note {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin-top: 14px !important;
  color: var(--muted-light) !important;
  font-size: 9px !important;
  text-align: left;
}

.security-note .icon {
  width: 14px;
  height: 14px;
  margin-top: 1px;
}

.admin-summary {
  display: flex;
  align-items: center;
  gap: 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
  padding: 16px 20px;
}

.admin-summary > div:not(.admin-summary-note) {
  min-width: 86px;
}

.summary-label {
  display: block;
  color: var(--muted);
  font-size: 9.5px;
}

.admin-summary strong {
  display: block;
  margin-top: 2px;
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 760;
  line-height: 1.1;
  letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
}

.admin-summary-note {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-left: auto;
  color: var(--muted);
  font-size: 10px;
}

.admin-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.94fr);
  gap: 16px;
  margin-top: 16px;
}

.admin-card {
  border: 1px solid var(--line);
  border-radius: 19px;
  background: #fff;
  padding: 19px;
}

.admin-card h3 {
  font-size: 14px;
  font-weight: 720;
  letter-spacing: -0.02em;
}

.admin-card-desc {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

label.upload-field {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 13px 0 0;
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  padding: 8px;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.upload-field:hover,
.upload-field:focus-within {
  border-color: rgba(47, 107, 255, 0.45);
  background: #fafbff;
}

.upload-field.is-loading {
  opacity: 0.55;
  pointer-events: none;
}

.upload-field:focus-within {
  box-shadow: 0 0 0 3px rgba(47, 107, 255, 0.08);
}

.upload-field input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.upload-preview {
  width: 52px;
  height: 52px;
  flex: none;
  overflow: hidden;
  border-radius: 11px;
  background: #f2f4f8;
}

.upload-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.upload-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  color: var(--muted-light);
  font-size: 7.5px;
}

.upload-placeholder .icon {
  width: 16px;
  height: 16px;
}

.upload-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.upload-copy strong {
  color: var(--ink-soft);
  font-size: 10.5px;
  font-weight: 650;
}

.upload-copy small {
  color: var(--muted-light);
  font-size: 8.5px;
  line-height: 1.4;
}

.custom-card {
  display: flex;
  flex-direction: column;
  min-height: 275px;
}

.custom-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.custom-hero-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 250px;
  margin-top: 12px;
  overflow-y: auto;
  padding-right: 2px;
  scrollbar-width: thin;
}

.custom-hero-row {
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 7px;
}

.custom-hero-thumb {
  position: relative;
  width: 36px;
  height: 36px;
  flex: none;
  overflow: hidden;
  border-radius: 9px;
  background: #f2f4f8;
}

.custom-hero-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 800;
}

.custom-hero-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2px;
}

.custom-hero-thumb span {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: var(--muted-light);
  font-size: 12px;
  font-weight: 800;
}

.custom-hero-info {
  min-width: 0;
  flex: 1;
}

.custom-hero-info strong {
  display: block;
  overflow: hidden;
  font-size: 11px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.custom-hero-info small {
  color: var(--muted-light);
  font-size: 8.5px;
}

.custom-hero-delete {
  flex: none;
  border-radius: 7px;
  padding: 4px 6px;
  color: var(--muted);
  font-size: 8.5px;
  font-weight: 600;
  transition: color 0.2s, background 0.2s;
}

.custom-hero-delete:hover {
  background: var(--red-soft);
  color: var(--red-deep);
}

.custom-hero-delete.is-confirming {
  background: var(--red);
  color: #fff;
}

.custom-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 195px;
  color: var(--muted-light);
  text-align: center;
}

.custom-empty-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px dashed var(--line-strong);
  border-radius: 50%;
  font-size: 20px;
}

.custom-empty p {
  margin-top: 9px;
  font-size: 10px;
}

.editor-card {
  margin-top: 16px;
}

.editor-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.admin-hero-search {
  width: min(290px, 100%);
  flex: none;
}

.editor-layout {
  display: grid;
  grid-template-columns: 286px minmax(0, 1fr);
  gap: 14px;
  margin-top: 15px;
}

.editor-picker-column {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
  padding: 9px;
}

.editor-picker-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 4px 8px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
}

.editor-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  max-height: 352px;
  overflow-y: auto;
  padding-right: 2px;
  scrollbar-width: thin;
}

.editor-pick {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 4px;
  text-align: left;
  transition: border-color 0.18s, background 0.18s;
}

.editor-pick:hover {
  border-color: var(--line);
  background: #fff;
}

.editor-pick.is-active {
  border-color: rgba(47, 107, 255, 0.35);
  background: var(--blue-soft);
}

.editor-pick-thumb {
  position: relative;
  width: 31px;
  height: 31px;
  flex: none;
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
}

.editor-pick-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2px;
}

.editor-pick-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted-light);
  font-size: 11px;
  font-weight: 800;
}

.editor-pick-copy {
  min-width: 0;
}

.editor-pick-name {
  display: block;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 9px;
  font-weight: 650;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.editor-pick-meta {
  display: block;
  color: var(--muted-light);
  font-size: 7.5px;
  line-height: 1.2;
}

.editor-list-empty {
  padding: 24px 6px;
  color: var(--muted);
  font-size: 10px;
  text-align: center;
}

.editor-panel {
  min-width: 0;
  min-height: 360px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
}

.editor-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  text-align: center;
}

.editor-empty-mark {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border: 1px dashed var(--line-strong);
  border-radius: 50%;
  color: var(--muted-light);
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 700;
}

.editor-empty p {
  margin-top: 11px;
  color: var(--muted);
  font-size: 10px;
}

.editor-identity {
  display: flex;
  align-items: center;
  gap: 12px;
}

.editor-avatar {
  position: relative;
  width: 62px;
  height: 62px;
  flex: none;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: #f2f4f8;
}

.editor-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 3px;
}

.editor-avatar-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted-light);
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
}

.editor-identity-copy {
  min-width: 0;
}

.editor-identity-copy h4 {
  overflow: hidden;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 760;
  line-height: 1.2;
  letter-spacing: -0.03em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.editor-identity-copy p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 9.5px;
}

.rename-form {
  margin-top: 16px;
}

.rename-form > label {
  display: block;
  margin-bottom: 5px;
  color: var(--ink-soft);
  font-size: 10px;
  font-weight: 650;
}

.rename-row {
  display: flex;
  gap: 7px;
}

.rename-row input {
  width: 100%;
  min-width: 0;
  height: 39px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: #fff;
  padding: 0 10px;
  font-size: 12px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.rename-row input:focus {
  border-color: rgba(47, 107, 255, 0.55);
  box-shadow: 0 0 0 3px rgba(47, 107, 255, 0.08);
}

.rename-row .btn {
  flex: none;
  min-height: 39px;
}

.avatar-history-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.avatar-history-head h4 {
  font-size: 11px;
  font-weight: 700;
}

.avatar-history-head p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.avatar-history {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 74px;
  margin-top: 10px;
}

.avatar-version {
  position: relative;
  width: 72px;
  height: 72px;
  flex: none;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #f2f4f8;
  transition: border-color 0.18s, transform 0.18s, box-shadow 0.18s;
}

.avatar-version.is-active {
  border-color: var(--blue);
  box-shadow: 0 0 0 2px rgba(47, 107, 255, 0.1);
}

.avatar-version:hover {
  transform: translateY(-1px);
}

.avatar-version-main {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
}

.avatar-version-main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 3px;
}

.avatar-version-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted-light);
  font-size: 20px;
  font-weight: 800;
}

.avatar-current {
  position: absolute;
  left: 3px;
  right: 3px;
  bottom: 3px;
  border-radius: 4px;
  background: rgba(47, 107, 255, 0.9);
  padding: 1px 3px;
  color: #fff;
  font-size: 7px;
  font-weight: 700;
  text-align: center;
  backdrop-filter: blur(3px);
}

.avatar-version:not(.is-active) .avatar-current {
  display: none;
}

.avatar-version-delete {
  position: absolute;
  z-index: 3;
  right: -5px;
  top: -5px;
  width: 19px;
  height: 19px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  background: rgba(17, 19, 24, 0.9);
  color: #fff;
  font-size: 11px;
  line-height: 1;
  opacity: 0.8;
  transition: background 0.18s, opacity 0.18s, transform 0.18s;
}

.avatar-version-delete:hover,
.avatar-version-delete.is-confirming {
  background: var(--red);
  opacity: 1;
  transform: scale(1.06);
}

.avatar-empty {
  flex: 1;
  display: flex;
  align-items: center;
  min-height: 72px;
  color: var(--muted-light);
  font-size: 9.5px;
}

.upload-field.edit-upload {
  margin-top: 10px;
}

.key-change {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface-soft);
}

.key-change summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 13px 17px;
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 650;
  list-style: none;
}

.key-change summary::-webkit-details-marker {
  display: none;
}

.key-change summary .icon {
  width: 14px;
  height: 14px;
  transition: transform 0.2s;
}

.key-change[open] summary .icon {
  transform: rotate(180deg);
}

.key-change-form {
  border-top: 1px solid var(--line);
  padding: 15px 17px 17px;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.key-change-form > label {
  margin-top: 11px;
}

.key-change-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
}

.key-change-actions span {
  color: var(--muted-light);
  font-size: 8.5px;
}

.admin-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
}

.session-note {
  color: var(--muted-light);
  font-size: 9.5px;
}

/* =========================================================
   抽选过渡动画
   ========================================================= */
.draw-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #0c1018;
  color: #fff;
  animation: overlay-in 0.3s ease both;
}

.draw-overlay.is-leaving {
  animation: overlay-out 0.42s var(--ease-out) both;
}

.draw-overlay-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.draw-glow {
  position: absolute;
  width: 50vw;
  height: 50vw;
  max-width: 700px;
  max-height: 700px;
  border-radius: 50%;
  filter: blur(20px);
}

.draw-glow-blue {
  left: -20vw;
  top: 10%;
  background: radial-gradient(circle, rgba(47, 107, 255, 0.34), transparent 65%);
}

.draw-glow-red {
  right: -20vw;
  bottom: -8%;
  background: radial-gradient(circle, rgba(238, 91, 77, 0.24), transparent 65%);
}

.draw-grid {
  position: absolute;
  inset: 0;
  opacity: 0.23;
  background-image: linear-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 58px 58px;
  mask-image: radial-gradient(circle at center, black, transparent 75%);
}

.draw-stage {
  position: relative;
  z-index: 2;
  width: min(860px, calc(100vw - 32px));
  padding: 30px 0;
  text-align: center;
}

.draw-heading h2 {
  margin-top: 8px;
  font-family: var(--font-display);
  font-size: clamp(30px, 4.6vw, 47px);
  font-weight: 780;
  line-height: 1.1;
  letter-spacing: -0.055em;
}

.draw-heading p:last-child {
  margin-top: 7px;
  color: rgba(255, 255, 255, 0.43);
  font-size: 11px;
}

.draw-slots {
  --draw-cols: 3;
  display: grid;
  grid-template-columns: repeat(var(--draw-cols), minmax(0, 1fr));
  gap: clamp(8px, 1.2vw, 15px);
  width: min(100%, calc(var(--draw-cols) * 156px));
  margin: 34px auto 0;
}

.draw-overlay[data-count="1"] .draw-slots {
  width: min(100%, 210px);
}

.draw-slot {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.055);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.16);
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s;
}

.draw-slot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(8, 12, 20, 0.55));
  pointer-events: none;
}

.draw-slot[data-team="blue"].is-locked {
  border-color: rgba(88, 139, 255, 0.6);
  box-shadow: 0 0 0 1px rgba(88, 139, 255, 0.28), 0 14px 36px rgba(47, 107, 255, 0.17);
}

.draw-slot[data-team="red"].is-locked {
  border-color: rgba(255, 124, 108, 0.58);
  box-shadow: 0 0 0 1px rgba(255, 124, 108, 0.25), 0 14px 36px rgba(238, 91, 77, 0.15);
}

.draw-slot[data-team="none"].is-locked {
  border-color: rgba(255, 255, 255, 0.52);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.18), 0 18px 42px rgba(255, 255, 255, 0.08);
}

.draw-slot img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 5%;
  filter: blur(0.3px) saturate(0.72) brightness(0.78);
  transform: scale(1.04);
  transition: filter 0.3s, transform 0.35s var(--ease-spring);
}

.draw-slot.is-locked {
  transform: translateY(-2px);
}

.draw-slot.is-locked img {
  filter: none;
  transform: scale(1);
}

.draw-slot.is-locked::before {
  content: "";
  position: absolute;
  z-index: 3;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5) inset;
  animation: lock-flash 0.45s ease-out both;
}

.draw-slot-initial {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, 0.52);
  font-family: var(--font-display);
  font-size: clamp(18px, 5vw, 34px);
  font-weight: 800;
}

.draw-slot-team {
  position: absolute;
  z-index: 2;
  left: 7px;
  top: 7px;
  border-radius: 999px;
  background: rgba(8, 12, 20, 0.58);
  padding: 2px 6px;
  color: rgba(255, 255, 255, 0.66);
  font-size: 7.5px;
  font-weight: 650;
  backdrop-filter: blur(4px);
}

.draw-slot[data-team="blue"] .draw-slot-team {
  color: #9fbaff;
}

.draw-slot[data-team="red"] .draw-slot-team {
  color: #ffa89e;
}

.draw-progress-wrap {
  width: min(100%, 560px);
  margin: 32px auto 0;
}

.draw-progress {
  height: 2px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.1);
}

.draw-progress span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--yellow), var(--red));
  box-shadow: 0 0 12px rgba(245, 204, 79, 0.5);
  transition: width 0.08s linear;
}

.draw-progress-copy {
  display: flex;
  justify-content: space-between;
  margin-top: 9px;
  color: rgba(255, 255, 255, 0.35);
  font-size: 9px;
  font-variant-numeric: tabular-nums;
}

.draw-emote {
  position: absolute;
  right: 4px;
  bottom: -2px;
  width: 104px;
  height: 104px;
  object-fit: contain;
  opacity: 0.92;
  animation: bob 3.6s ease-in-out infinite;
  filter: drop-shadow(0 16px 20px rgba(0, 0, 0, 0.28));
}

.draw-overlay[data-count="10"] .draw-emote,
.draw-overlay[data-count="8"] .draw-emote {
  display: none;
}

/* =========================================================
   轻提示
   ========================================================= */
.toast-root {
  position: fixed;
  z-index: 220;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 7px;
  max-width: min(90vw, 460px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(17, 19, 24, 0.94);
  box-shadow: 0 12px 32px rgba(17, 19, 24, 0.22);
  padding: 9px 15px;
  color: #fff;
  font-size: 11px;
  font-weight: 500;
  backdrop-filter: blur(10px);
  animation: toast-in 0.32s var(--ease-spring) both;
}

.toast.is-leaving {
  animation: toast-out 0.22s ease both;
}

.toast::before {
  content: "";
  width: 6px;
  height: 6px;
  flex: none;
  border-radius: 50%;
  background: var(--yellow);
}

.toast[data-tone="error"]::before {
  background: var(--red);
}

.toast[data-tone="success"]::before {
  background: #52d99c;
}

.noscript {
  position: fixed;
  inset: auto 16px 16px;
  z-index: 400;
  border-radius: 14px;
  background: var(--ink);
  padding: 14px 18px;
  color: #fff;
  text-align: center;
  font-size: 13px;
}

/* =========================================================
   动画
   ========================================================= */
@keyframes reveal-up {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes reveal-scale {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes marker-in {
  from {
    transform: scaleX(0) rotate(-1.1deg);
    opacity: 0.5;
  }
  to {
    transform: scaleX(1) rotate(-1.1deg);
    opacity: 1;
  }
}

@keyframes bob {
  0%,
  100% {
    transform: translateY(0) rotate(-1deg);
  }
  50% {
    transform: translateY(-8px) rotate(1deg);
  }
}

@keyframes sparkle {
  0%,
  100% {
    transform: scale(0.65) rotate(0deg);
    opacity: 0.45;
  }
  50% {
    transform: scale(1) rotate(24deg);
    opacity: 1;
  }
}

@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@keyframes result-in {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.995);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes card-in {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes card-settle {
  0% {
    transform: scale(1.04);
  }
  60% {
    transform: scale(0.985);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes reselect-blur {
  0% {
    transform: scale(1);
    filter: blur(0);
  }
  35% {
    transform: scale(1.06);
    filter: blur(3px);
  }
  70% {
    transform: scale(0.98);
    filter: blur(1px);
  }
  100% {
    transform: scale(1);
    filter: blur(0);
  }
}

@keyframes sweep {
  from {
    transform: translateX(-120%);
  }
  to {
    transform: translateX(120%);
  }
}

@keyframes number-roll {
  0% {
    opacity: 0.45;
    transform: translateY(-1px);
  }
  100% {
    opacity: 1;
    transform: translateY(1px);
  }
}

@keyframes number-settle {
  0% {
    transform: scale(1.18);
  }
  65% {
    transform: scale(0.96);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes backdrop-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes dialog-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes overlay-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes overlay-out {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(1.025);
  }
}

@keyframes lock-flash {
  0% {
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.8) inset;
    opacity: 1;
  }
  100% {
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0) inset;
    opacity: 0;
  }
}

@keyframes loading-pulse {
  0%,
  100% {
    opacity: 0.25;
    transform: scale(0.8);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes toast-out {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(6px);
  }
}

/* =========================================================
   响应式
   ========================================================= */
@media (max-width: 1080px) {
  .hero-section {
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 24px;
  }

  .hero-section h1 {
    font-size: clamp(48px, 6.2vw, 70px);
  }

  .card-fan {
    transform: translateX(-50%) scale(0.9);
    transform-origin: center top;
  }

  .hero-emote {
    right: -2px;
  }

  .random-card {
    grid-template-columns: 50px minmax(0, 1fr) minmax(240px, 310px) 135px;
    gap: 18px;
  }
}

@media (max-width: 900px) {
  .hero-section {
    grid-template-columns: minmax(0, 1fr) 320px;
    min-height: 420px;
    padding-top: 48px;
  }

  .hero-visual {
    min-height: 330px;
  }

  .card-fan {
    transform: translateX(-50%) scale(0.8);
  }

  .hero-emote img {
    width: 92px;
    height: 92px;
  }

  .emote-bubble {
    font-size: 9px;
  }

  .control-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .panel {
    min-height: 0;
  }

  .pool-panel {
    min-height: 288px;
  }

  .draw-panel {
    padding-bottom: 24px;
  }

  .mode-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .mode-option {
    padding: 9px 8px;
  }

  .mode-option span {
    white-space: normal;
  }

  .result-arena {
    padding: 22px;
  }

  .result-arena[data-layout="team"] {
    grid-template-columns: minmax(0, 1fr) 58px minmax(0, 1fr);
  }

  .versus {
    width: 49px;
    height: 49px;
  }

  .versus strong {
    font-size: 15px;
  }

  .random-card {
    grid-template-columns: 48px minmax(0, 1fr) minmax(220px, 300px) 120px;
    padding: 20px;
  }

  .random-result strong {
    font-size: 32px;
    min-width: 60px;
  }

  .random-result-label {
    display: none;
  }

  .result-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }

  .result-actions {
    width: 100%;
  }

  .result-actions .btn {
    flex: 1;
  }
}

@media (max-width: 760px) {
  :root {
    --header-height: 64px;
  }

  .topbar-inner {
    padding: 0 16px;
    gap: 10px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }

  .brand-copy strong {
    font-size: 14px;
    letter-spacing: -0.035em;
  }

  .brand-copy small {
    display: block;
    margin-top: 2px;
    font-size: 8px;
    letter-spacing: 0.08em;
  }

  .topnav {
    display: none;
  }

  .maintainer-link {
    padding: 7px 11px;
  }

  .maintainer-link span {
    display: none;
  }

  .maintainer-link .icon {
    width: 16px;
    height: 16px;
  }

  .hero-section {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    min-height: 0;
    padding: 38px 16px 24px;
    gap: 11px;
  }

  .hero-copy {
    position: relative;
    z-index: 3;
  }

  .hero-section h1 {
    margin-top: 17px;
    font-size: clamp(43px, 13vw, 58px);
    line-height: 1.06;
  }

  .hero-section h1 span {
    display: block;
  }

  .hero-lead {
    margin-top: 18px;
    font-size: 13.5px;
    line-height: 1.75;
  }

  .hero-metrics {
    gap: 19px;
    margin-top: 24px;
  }

  .metric strong {
    font-size: 24px;
  }

  .metric span {
    font-size: 10px;
  }

  .hero-visual {
    min-height: 272px;
    margin-top: 6px;
  }

  .card-fan {
    top: 0;
    transform: translateX(-50%) scale(0.73);
  }

  .hero-emote {
    top: -22px;
    right: 0;
  }

  .hero-emote img {
    width: 77px;
    height: 77px;
  }

  .emote-bubble {
    font-size: 8px;
    padding: 4px 8px;
  }

  .hero-visual-caption {
    right: 0;
    bottom: 0;
    font-size: 8.5px;
  }

  .control-grid {
    padding: 0 16px 20px;
  }

  .panel {
    border-radius: 25px;
    padding: 20px;
  }

  .panel h2 {
    font-size: 22px;
  }

  .panel-desc {
    font-size: 11.5px;
  }

  .pool-panel {
    min-height: 258px;
  }

  .mode-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .draw-button {
    min-height: 62px;
  }

  .result-shell {
    padding: 7px 16px 20px;
  }

  .result-empty {
    min-height: 218px;
    padding: 24px;
    align-items: flex-start;
  }

  .result-empty-copy {
    max-width: 75%;
  }

  .portrait-marquee {
    left: 16%;
    bottom: -2px;
    opacity: 0.23;
  }

  .portrait-marquee-face {
    width: 58px;
    height: 58px;
    border-radius: 14px;
  }

  .empty-emote {
    right: 18px;
    bottom: 16px;
  }

  .empty-emote img {
    width: 72px;
    height: 72px;
  }

  .result-content {
    border-radius: 25px;
    padding: 20px;
  }

  .result-header h2 {
    font-size: 29px;
  }

  .result-arena {
    margin-top: 18px;
    border-radius: 21px;
    padding: 18px;
  }

  .result-arena[data-layout="team"] {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 15px;
  }

  .result-arena[data-layout="team"]::before {
    display: none;
  }

  .result-arena[data-layout="team"]::after {
    width: 200px;
    height: 200px;
  }

  .team {
    width: 100%;
  }

  .team-head {
    margin-bottom: 9px;
  }

  .team-red .team-head {
    margin-top: 2px;
  }

  .versus {
    width: 38px;
    height: 38px;
    margin: 2px auto;
    box-shadow: 0 8px 18px rgba(17, 19, 24, 0.18);
  }

  .versus strong {
    font-size: 12px;
  }

  .versus span {
    display: none;
  }

  .roster {
    gap: 6px;
  }

  .result-arena[data-mode="2v2"] .hero-card,
  .result-arena[data-mode="4v4"] .hero-card {
    width: calc(50% - 3px);
    max-width: 180px;
  }

  .result-arena[data-mode="3v3"] .hero-card {
    width: calc(33.333% - 4px);
  }

  .result-arena[data-mode="5v5"] .hero-card {
    width: calc(33.333% - 4px);
  }

  .result-arena[data-mode="5v5"] .hero-card:nth-child(4),
  .result-arena[data-mode="5v5"] .hero-card:nth-child(5) {
    max-width: calc(33.333% - 4px);
  }

  .result-arena[data-mode="1v1"] .roster {
    min-height: 0;
  }

  .result-arena[data-mode="1v1"] .hero-card {
    width: min(100%, 210px);
  }

  .result-arena[data-mode="1v1"] .hero-card-name {
    font-size: 16px;
  }

  .hero-card-name {
    font-size: 11px;
  }

  .hero-card-body {
    padding: 5px 6px 6px;
  }

  .hero-card-tag {
    font-size: 7px;
  }

  .result-arena[data-layout="single"] {
    min-height: 330px;
    padding: 28px 18px;
  }

  .single-wrap {
    width: min(100%, 250px);
  }

  .single-orbit {
    width: 340px;
    height: 340px;
  }

  .result-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
    margin-top: 13px;
  }

  .result-footer-copy img {
    width: 44px;
    height: 44px;
  }

  .copy-button {
    align-self: flex-end;
  }

  .random-card {
    width: calc(100% - 32px);
    max-width: calc(var(--page-width) - 32px);
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 13px;
    margin-bottom: 28px;
    border-radius: 22px;
    padding: 18px;
  }

  .random-icon {
    width: 42px;
    height: 42px;
    border-radius: 13px;
  }

  .random-icon svg {
    width: 26px;
    height: 26px;
  }

  .random-form {
    grid-column: 1 / -1;
    margin-top: 3px;
  }

  .random-result {
    grid-column: 1 / -1;
    justify-content: flex-start;
    min-height: 38px;
    border-top: 1px solid rgba(255, 255, 255, 0.09);
    border-left: 0;
    padding-top: 11px;
  }

  .random-result-label {
    display: block;
    width: auto;
  }

  .random-result strong {
    min-width: 0;
    font-size: 30px;
  }

  .footer-inner {
    align-items: flex-start;
    flex-wrap: wrap;
    padding: 23px 16px 30px;
    gap: 12px;
  }

  .footer-note {
    order: 3;
    width: 100%;
    margin-left: 0;
    text-align: left;
  }

  .footer-admin {
    margin-left: auto;
  }

  .sheet {
    position: fixed;
    inset: 0;
    width: 100vw;
    max-width: none;
    height: 100vh;
    height: 100dvh;
    max-height: none;
    margin: 0;
    border-radius: 0;
    animation: sheet-mobile-in 0.3s var(--ease-out) both;
  }

  .sheet-inner {
    width: 100%;
    height: 100%;
    max-height: none;
    border: 0;
    border-radius: 0;
  }

  .sheet-header {
    padding: calc(16px + env(safe-area-inset-top)) 16px 13px;
  }

  .sheet-header h2 {
    font-size: 21px;
  }

  .sheet-count {
    display: none;
  }

  .pool-toolbar {
    padding: 11px 16px;
    gap: 9px;
  }

  .search-box {
    width: min(180px, 52vw);
  }

  .pool-layout {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .letter-nav {
    padding: 8px 0;
  }

  .letter-nav button {
    width: 22px;
    height: 16px;
    font-size: 8px;
  }

  .pool-scroll {
    padding: 5px 12px 20px;
  }

  .hero-group-head {
    margin: 0 -12px;
    padding: 7px 12px;
  }

  .hero-grid {
    grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
    gap: 6px;
  }

  .hero-tile {
    min-height: 98px;
    padding: 6px 3px 5px;
  }

  .hero-tile-image {
    width: 48px;
    height: 48px;
  }

  .hero-tile-name {
    font-size: 9.5px;
  }

  .sheet-footer {
    gap: 10px;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  }

  .sheet-footer-count {
    font-size: 9px;
  }

  .sheet-footer-actions .btn {
    min-width: 0;
    padding-inline: 12px;
    font-size: 11px;
  }

  .sheet-footer-actions .btn-ghost {
    display: none;
  }

  .admin-dialog {
    position: fixed;
    inset: 0;
    width: 100vw;
    max-width: none;
    height: 100vh;
    height: 100dvh;
    max-height: none;
    margin: 0;
    border-radius: 0;
  }

  .admin-shell {
    width: 100%;
    height: 100%;
    max-height: none;
    border: 0;
    border-radius: 0;
  }

  .admin-header {
    padding: calc(15px + env(safe-area-inset-top)) 16px 13px;
  }

  .admin-header h2 {
    font-size: 21px;
  }

  .admin-view {
    padding: 18px 16px calc(26px + env(safe-area-inset-bottom));
  }

  .login-view {
    padding-top: 30px;
  }

  .admin-summary {
    flex-wrap: wrap;
    gap: 12px 20px;
    padding: 14px 16px;
  }

  .admin-summary-note {
    width: 100%;
    margin-left: 0;
  }

  .admin-grid {
    grid-template-columns: 1fr;
  }

  .editor-card-head {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
  }

  .admin-hero-search {
    width: 100%;
  }

  .editor-layout {
    grid-template-columns: 1fr;
  }

  .editor-picker {
    max-height: 210px;
  }

  .editor-panel {
    min-height: 0;
    padding: 14px;
  }

  .editor-empty {
    min-height: 180px;
  }

  .editor-avatar {
    width: 56px;
    height: 56px;
  }

  .avatar-version {
    width: 64px;
    height: 64px;
  }

  .custom-card {
    min-height: 220px;
  }

  .field-row {
    grid-template-columns: 1fr;
  }

  .rename-row {
    flex-direction: column;
  }

  .rename-row .btn {
    width: 100%;
  }

  .key-change-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .draw-stage {
    width: calc(100vw - 24px);
    padding: 18px 0;
  }

  .draw-heading h2 {
    font-size: clamp(28px, 8vw, 36px);
  }

  .draw-slots {
    margin-top: 24px;
    gap: 6px;
  }

  .draw-slot {
    border-radius: 12px;
  }

  .draw-slot-team {
    left: 4px;
    top: 4px;
    padding: 1px 4px;
    font-size: 6px;
  }

  .draw-progress-wrap {
    margin-top: 23px;
  }

  .draw-emote {
    width: 70px;
    height: 70px;
    opacity: 0.78;
  }

  .draw-progress-copy {
    font-size: 8px;
  }

  /* iOS 会为小于 16px 的输入框自动放大页面，移动端统一到 16px。 */
  .search-box input,
  .stack-form input,
  .key-change-form input,
  .random-input-row input,
  .rename-row input {
    font-size: 16px;
  }
}

@media (max-width: 420px) {
  .hero-section {
    padding-top: 31px;
  }

  .hero-section h1 {
    font-size: 42px;
  }

  .hero-metrics {
    gap: 14px;
  }

  .metric strong {
    font-size: 22px;
  }

  .metric span {
    font-size: 9px;
  }

  .card-fan {
    transform: translateX(-50%) scale(0.65);
    transform-origin: center top;
  }

  .hero-visual {
    min-height: 246px;
  }

  .hero-emote {
    top: -12px;
  }

  .hero-emote img {
    width: 68px;
    height: 68px;
  }

  .emote-bubble {
    display: none;
  }

  .mode-option {
    padding-inline: 7px;
  }

  .mode-option strong {
    font-size: 14px;
  }

  .mode-option span {
    font-size: 8.5px;
  }

  .result-empty-copy {
    max-width: 84%;
  }

  .result-empty h2 {
    font-size: 23px;
  }

  .result-empty p:last-child {
    max-width: 220px;
    font-size: 10.5px;
  }

  .empty-emote {
    opacity: 0.4;
  }

  .result-content {
    padding: 16px;
  }

  .result-actions .btn {
    width: 100%;
  }

  .result-arena {
    padding: 12px;
  }

  .result-arena[data-mode="3v3"] .hero-card-name {
    font-size: 10px;
  }

  .result-arena[data-mode="5v5"] .hero-card-name {
    font-size: 8.5px;
  }

  .hero-tile {
    min-height: 94px;
  }

  .hero-tile-image {
    width: 44px;
    height: 44px;
  }
}

@keyframes sheet-mobile-in {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================================
   降低动态效果
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
