#wrapper {
  width: min(500px, 90vw);
  height: 120px;
  overflow: hidden;
  position: relative;
}

#content {
  line-height: 1.8;
  font-size: 16px;
  outline: none;
  user-select: none;
  white-space: pre-wrap;
  position: absolute;
  top: 0;
  left: 0;
  transition: transform 0.1s linear;
}

#restart {
  margin-top: 20px;
  padding: 10px 20px;
  background: #22c55e;
  border: none;
  border-radius: 8px;
  cursor: pointer;
}

span {
  color: #6b7280;
}

.correct {
  color: #53e448;
}

.wrong {
  color: #ff4d6d;
}

.current {
  position: relative;
  background: rgba(0, 245, 255, 0.15);
}

.current::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: #00f5ff;
  animation: blink 0.9s infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

#stats {
  display: flex;
  gap: 20px;
  margin-bottom: 14px;
  font-size: 18px;
}

#wpm-graph {
  display: block;
  width: min(500px, 90vw);
  height: 150px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  margin-bottom: 16px;
  opacity: 0;
  transition: opacity 0.4s ease;
}

#wpm-graph.active {
  opacity: 1;
}

span.wrong {
  text-decoration: underline;
  text-decoration-color: #ff4d6d;
  text-underline-offset: 2px;
}

body {
    height: 100vh;
}
