* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body {
  margin: 0;
  height: 100%;
  background: #000;
  color: #eee;
  font-family: system-ui, sans-serif;
  overflow: hidden;
}

.stage {
  position: fixed;
  inset: 0;
  background: #000;
  overflow: hidden;
}

.stage video,
.stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: scaleX(-1);
  object-fit: cover;
}

.stage canvas { pointer-events: none; }

.start-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  cursor: pointer;
  z-index: 10;
}
.start-overlay.is-loading { cursor: default; }

.start-btn {
  background: #00FF88;
  color: #001b10;
  border: 0;
  border-radius: 999px;
  padding: 1rem 3rem;
  font: 700 1.4rem system-ui, sans-serif;
  letter-spacing: 0.04em;
  cursor: pointer;
  box-shadow: 0 8px 30px rgba(0, 255, 136, 0.25);
}
.start-btn:hover { background: #4dffab; }
.start-btn:disabled { opacity: 0.6; cursor: default; }

.progress {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  width: min(420px, 60%);
  margin: 0 auto;
}
.progress-bar {
  width: 100%;
  height: 10px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  width: 0;
  background: #00FF88;
  transition: width 80ms linear;
}
.progress-text {
  font: 500 1rem system-ui, sans-serif;
  color: rgba(255, 255, 255, 0.85);
  font-variant-numeric: tabular-nums;
}

.corner {
  position: absolute;
  right: 1rem;
  bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  z-index: 10;
}

.hint {
  position: absolute;
  left: 50%;
  bottom: 1.25rem;
  transform: translateX(-50%);
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.9);
  font: 500 0.95rem system-ui, sans-serif;
  backdrop-filter: blur(6px);
  z-index: 9;
  pointer-events: none;
  white-space: nowrap;
}

.pill {
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
  backdrop-filter: blur(6px);
}

.stop {
  background: rgba(220, 40, 60, 0.85);
  color: #fff;
  border: 0;
  border-radius: 999px;
  padding: 0.45rem 1rem;
  font: 600 0.95rem system-ui, sans-serif;
  cursor: pointer;
  backdrop-filter: blur(6px);
}
.stop:hover { background: rgba(240, 60, 80, 0.95); }
