:root {
  --cyan: #00d4ff;
  --coral: #ff1a5c;
  --gold: #ffd60a;
  --ink: #e8f4ff;
  --muted: #8e9aaf;
  --bg: #0a0a0c;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  touch-action: none;
}

html,
body {
  margin: 0;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  font-family: "Jua", system-ui, sans-serif;
  background: #050608;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
}

.stage {
  position: relative;
  width: min(100vw, calc(100dvh * 0.557));
  height: min(100dvh, calc(100vw / 0.557));
  max-width: 420px;
  border-radius: 18px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(142, 154, 175, 0.28),
    0 22px 60px rgba(0, 0, 0, 0.75),
    -6px 0 28px rgba(255, 26, 92, 0.18),
    6px 0 28px rgba(0, 212, 255, 0.18);
  background: var(--bg);
}

canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.hud {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  pointer-events: none;
  z-index: 3;
}

.panel {
  background: rgba(8, 10, 14, 0.78);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(142, 154, 175, 0.32);
  border-radius: 12px;
  padding: 8px 12px;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 13px;
  min-width: 96px;
  box-shadow: 0 0 18px rgba(0, 212, 255, 0.08);
}

.panel.right {
  align-items: flex-end;
}

.panel b {
  font-size: 16px;
  color: var(--cyan);
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.45);
}

.goal-meter {
  position: absolute;
  top: 72px;
  left: 12px;
  right: 12px;
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  pointer-events: none;
  z-index: 3;
  border: 1px solid rgba(142, 154, 175, 0.28);
}

.goal-meter > i {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--coral), #ff4d88, var(--cyan));
  border-radius: inherit;
  transition: width 0.2s ease;
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.45);
}

.goal-label {
  position: absolute;
  top: 84px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 12px;
  color: rgba(142, 154, 175, 0.9);
  pointer-events: none;
  z-index: 3;
  text-shadow: 0 0 8px rgba(0, 212, 255, 0.25);
}

.pick-bar {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 16px;
  display: flex;
  gap: 12px;
  z-index: 4;
  pointer-events: none;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.pick-bar.on {
  pointer-events: auto;
  opacity: 1;
  transform: translateY(0);
}

.pick {
  flex: 1;
  appearance: none;
  border-radius: 14px;
  padding: 14px 8px 12px;
  font: inherit;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(28, 32, 40, 0.95), rgba(8, 10, 14, 0.96));
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.pick:active {
  transform: translateY(2px);
}

.pick.odd {
  border: 1px solid rgba(255, 26, 92, 0.7);
  box-shadow:
    0 0 24px rgba(255, 26, 92, 0.32),
    inset 0 0 18px rgba(255, 26, 92, 0.08);
}

.pick.even {
  border: 1px solid rgba(0, 212, 255, 0.7);
  box-shadow:
    0 0 24px rgba(0, 212, 255, 0.32),
    inset 0 0 18px rgba(0, 212, 255, 0.08);
}

.pick-big {
  font-family: "Bagel Fat One", "Jua", cursive;
  font-size: 28px;
  line-height: 1;
}

.pick.odd .pick-big {
  color: var(--coral);
  text-shadow: 0 0 14px rgba(255, 26, 92, 0.65);
}

.pick.even .pick-big {
  color: var(--cyan);
  text-shadow: 0 0 14px rgba(0, 212, 255, 0.65);
}

.pick-sub {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.06em;
}

.overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(255, 26, 92, 0.16), transparent 45%),
    radial-gradient(ellipse at 70% 22%, rgba(0, 212, 255, 0.16), transparent 45%),
    linear-gradient(180deg, rgba(6, 7, 10, 0.96), rgba(10, 10, 12, 0.98));
}

.overlay.hidden {
  display: none;
}

.hero-art {
  width: min(42vw, 168px);
  height: min(42vw, 168px);
  object-fit: cover;
  border-radius: 22px;
  margin-bottom: 10px;
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.55),
    -4px 0 18px rgba(255, 26, 92, 0.35),
    4px 0 18px rgba(0, 212, 255, 0.35),
    0 0 0 1px rgba(142, 154, 175, 0.4);
}

.badge {
  display: inline-block;
  background: transparent;
  color: var(--cyan);
  border: 1px solid rgba(0, 212, 255, 0.55);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  margin-bottom: 8px;
  letter-spacing: 0.08em;
  box-shadow: 0 0 14px rgba(0, 212, 255, 0.2);
}

.badge.soft {
  color: var(--gold);
  border-color: rgba(255, 214, 10, 0.55);
  box-shadow: 0 0 14px rgba(255, 214, 10, 0.2);
}

h1 {
  margin: 0;
  font-family: "Bagel Fat One", "Jua", cursive;
  font-weight: 400;
  font-size: clamp(34px, 9vw, 46px);
  color: #e8f4ff;
  text-shadow:
    -2px 0 16px rgba(255, 26, 92, 0.35),
    2px 0 16px rgba(0, 212, 255, 0.4),
    0 3px 0 rgba(0, 0, 0, 0.45);
}

.overlay p {
  margin: 8px 0 14px;
  color: var(--muted);
  line-height: 1.45;
}

.icons {
  font-size: 14px;
  margin-bottom: 14px;
  color: var(--muted);
}

.btn {
  appearance: none;
  border: none;
  border-radius: 12px;
  padding: 13px 32px;
  font: inherit;
  font-size: 18px;
  color: #061018;
  background: linear-gradient(180deg, #7adfff, #00d4ff);
  box-shadow:
    0 7px 0 #087a8a,
    0 0 22px rgba(0, 212, 255, 0.4),
    -4px 0 16px rgba(255, 26, 92, 0.2);
  cursor: pointer;
}

.btn:active {
  transform: translateY(3px);
  box-shadow:
    0 4px 0 #087a8a,
    0 0 16px rgba(0, 212, 255, 0.3);
}

a {
  margin-top: 12px;
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
}
