/* ===== Green版 スタイル ===== */
/* 色を変えたいときは下の --main-color などをいじってみよう！ */
:root {
  --main-color: #43a047;
  --dark-color: #1b5e20;
  --accent-color: #ffeb3b;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: "Hiragino Kaku Gothic ProN", "Meiryo", sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--main-color), var(--dark-color));
  color: #fff;
  padding: 20px;
}

.container {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 24px;
  padding: 40px 30px;
  width: 100%;
  max-width: 640px;
  text-align: center;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

h1 { font-size: 1.8rem; margin-bottom: 24px; }

.badge {
  font-size: 0.9rem;
  background: var(--accent-color);
  color: #333;
  padding: 4px 10px;
  border-radius: 999px;
  vertical-align: middle;
}

/* スコア・時間・ミスの表示 */
.status {
  display: flex;
  justify-content: space-around;
  margin-bottom: 28px;
}
.status-item { display: flex; flex-direction: column; }
.status-item .label { font-size: 0.8rem; opacity: 0.85; }
.status-item .value { font-size: 2rem; font-weight: bold; }

/* お題の単語 */
.word {
  font-size: 2.4rem;
  font-weight: bold;
  letter-spacing: 2px;
  margin-bottom: 14px;
  min-height: 3rem;
  word-break: break-all;
}
/* 正しく打てた文字の色 */
.word .done { color: var(--accent-color); }

/* 入力中の文字 */
.typed {
  font-size: 1.3rem;
  min-height: 1.6rem;
  margin-bottom: 24px;
  opacity: 0.9;
}

/* キー入力を受け取るための入力欄（見えないように） */
.hidden-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

/* スタートボタン */
.start-btn {
  font-size: 1.2rem;
  font-weight: bold;
  padding: 14px 40px;
  border: none;
  border-radius: 999px;
  background: var(--accent-color);
  color: #333;
  cursor: pointer;
  transition: transform 0.15s;
}
.start-btn:hover { transform: scale(1.05); }
.start-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

/* 結果表示 */
.result {
  font-size: 1.3rem;
  margin-top: 24px;
  min-height: 1.6rem;
  font-weight: bold;
}

.hint {
  margin-top: 30px;
  font-size: 0.8rem;
  opacity: 0.8;
}
.hint code {
  background: rgba(255, 255, 255, 0.2);
  padding: 2px 6px;
  border-radius: 4px;
}

.back { margin-top: 16px; font-size: 0.9rem; }
.back a { color: #fff; }
