:root {
  --bg: #09070f;
  --bg-2: #120e1c;
  --card: #171322;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f6f3ff;
  --muted: #9b93b3;
  --accent: #8b78ff;
  --accent-2: #d4ff3f;
  --danger: #ff6b8a;
  --ok: #7dffb3;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --radius: 22px;
  --sans: "Sora", "Noto Sans SC", "PingFang SC", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--sans);
  background:
    radial-gradient(1000px 500px at 10% -10%, rgba(139, 120, 255, 0.22), transparent 55%),
    radial-gradient(800px 500px at 100% 0%, rgba(212, 255, 63, 0.08), transparent 40%),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
}

a { color: var(--accent-2); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0 8px;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.brand strong {
  font-size: 20px;
  letter-spacing: 0.04em;
}
.brand span { color: var(--muted); font-size: 12px; }

.wallet { display: flex; align-items: center; gap: 12px; }
.wallet .meta { color: var(--muted); font-size: 12px; text-align: right; }

button {
  font-family: inherit;
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  padding: 11px 18px;
  font-weight: 600;
  font-size: 14px;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
}
button:hover { transform: translateY(-1px); }
button:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--accent-2); color: #15120a; }
.btn-accent { background: var(--accent); color: white; }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }

.hero { padding: 36px 0 10px; }
.eyebrow {
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 12px;
  margin: 0 0 14px;
}
.hero h1 {
  font-size: clamp(36px, 6vw, 72px);
  line-height: 0.95;
  letter-spacing: -0.04em;
  margin: 0 0 18px;
  max-width: 14ch;
}
.lead {
  max-width: 42em;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.65;
  margin: 0;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  list-style: none;
  padding: 28px 0;
  margin: 0;
}
.steps li {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px 18px;
}
.steps b { display: block; font-size: 12px; color: var(--accent-2); margin-bottom: 6px; }
.steps p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }

.stage {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr;
  gap: 22px;
  align-items: start;
  padding-bottom: 48px;
}

.player, .panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.screen {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius) var(--radius) 0 0;
  overflow: hidden;
  background:
    linear-gradient(160deg, #2a1f4d 0%, #0d0a14 55%, #1a2a12 100%);
}
.screen video, .screen .visual {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.screen video[hidden],
.screen .visual[hidden] {
  display: none;
}
.player-credit {
  margin: 10px 4px 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}
.visual {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  gap: 12px;
}
.visual .kicker { font-size: 12px; color: var(--accent-2); letter-spacing: 0.08em; }
.visual .line {
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.25;
  max-width: 18ch;
  min-height: 2.5em;
}
.wave {
  display: flex;
  gap: 3px;
  align-items: flex-end;
  height: 28px;
  opacity: 0.85;
}
.wave i {
  width: 4px;
  background: var(--accent-2);
  border-radius: 4px;
  height: 6px;
  animation: none;
}
.wave.playing i { animation: pulse 1s ease-in-out infinite; }
.wave i:nth-child(2) { animation-delay: 0.1s; }
.wave i:nth-child(3) { animation-delay: 0.2s; }
.wave i:nth-child(4) { animation-delay: 0.3s; }
.wave i:nth-child(5) { animation-delay: 0.15s; }
.wave i:nth-child(6) { animation-delay: 0.25s; }
.wave i:nth-child(7) { animation-delay: 0.05s; }
@keyframes pulse {
  0%, 100% { height: 6px; }
  50% { height: 26px; }
}

.player-bar {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  padding: 14px 16px 16px;
}
.tabs { display: flex; gap: 8px; }
.tabs button[aria-pressed="true"] {
  background: var(--accent);
  color: white;
  border-color: transparent;
}

.panel { padding: 22px; }
.panel h2 { margin: 0 0 8px; font-size: 22px; }
.panel .hint { color: var(--muted); font-size: 13px; line-height: 1.55; margin: 0 0 18px; }
label { display: block; font-size: 12px; color: var(--muted); margin: 0 0 6px; }
input, select {
  width: 100%;
  background: #100d18;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 12px;
  font: inherit;
  margin-bottom: 14px;
}
.status {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 14px;
  background: #100d18;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  min-height: 3.2em;
  word-break: break-all;
}
.status.ok { color: var(--ok); border-color: rgba(125, 255, 179, 0.25); }
.status.err { color: var(--danger); border-color: rgba(255, 107, 138, 0.3); }

.facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  padding: 10px 0 56px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.facts h3 { margin: 0 0 6px; color: var(--text); font-size: 14px; }
.facts code, .mono { font-family: "IBM Plex Mono", ui-monospace, monospace; font-size: 12px; color: var(--text); }

footer {
  border-top: 1px solid var(--line);
  padding: 20px 0 36px;
  color: var(--muted);
  font-size: 12px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

@media (max-width: 860px) {
  .steps, .stage, .facts { grid-template-columns: 1fr; }
  .hero h1 { max-width: none; }
}
