/* =========================================================
   Memory Verse Room
   ========================================================= */

.verse-main {
  padding: 24px 20px 96px;
  max-width: 700px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

/* No verse state */
.no-verse {
  text-align: center;
  padding: 80px 24px;
}
.no-verse-icon { font-size: 48px; margin-bottom: 16px; }
.no-verse h2 { font-size: 24px; font-weight: 700; margin-bottom: 8px; }
.no-verse-sub { color: var(--ink-soft); font-size: 15px; margin-bottom: 24px; }

/* Verse hero */
.verse-hero {
  text-align: center;
  padding: 48px 20px 40px;
  animation: rise 0.5s ease-out both;
}
.verse-title {
  font-size: clamp(28px, 6vw, 44px);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 8px 0 24px;
  background: linear-gradient(135deg, var(--ink) 0%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.verse-text-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}
.verse-text-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent) 0%, var(--primary) 100%);
}
.verse-text {
  font-family: var(--font-display);
  font-size: clamp(18px, 3vw, 24px);
  font-weight: 500;
  font-style: italic;
  line-height: 1.6;
  color: var(--ink);
}

/* Family progress board */
.progress-section { margin-top: 48px; }
.family-board {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}
.progress-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 16px;
  padding: 16px 20px;
  text-align: center;
  min-width: 100px;
  box-shadow: var(--shadow-sm);
}
.progress-emoji { font-size: 28px; }
.progress-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  margin: 6px 0 8px;
}
.progress-dots {
  display: flex;
  gap: 4px;
  justify-content: center;
}
.progress-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--rule);
}
.progress-dot.done {
  background: var(--emerald);
}
.progress-star {
  font-size: 16px;
  margin-top: 6px;
}

/* Weekly checklist */
.checklist-section { margin-top: 40px; }
.weekly-checklist {
  max-width: 460px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.checklist-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: var(--surface);
  border: 1.5px solid var(--rule);
  border-radius: 14px;
  transition: all 0.2s ease;
}
.checklist-item.current {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--primary-light);
}
.checklist-item.future {
  opacity: 0.45;
}
.checklist-check {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 2px solid var(--rule);
  background: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.15s ease;
  color: transparent;
  font-family: var(--font-body);
}
.checklist-check:hover { border-color: var(--primary); }
.checklist-check.done {
  background: var(--emerald);
  border-color: var(--emerald);
  color: white;
  cursor: default;
}
.checklist-item.future .checklist-check {
  cursor: default;
  opacity: 0.5;
}
.checklist-week {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary);
  min-width: 52px;
}
.checklist-item.done-row .checklist-week { color: var(--emerald); }
.checklist-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  flex: 1;
}
.checklist-item.done-row .checklist-label {
  color: var(--ink-soft);
  text-decoration: line-through;
}

/* Practice games menu */
.games-section { margin-top: 32px; }
.games-menu {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  max-width: 480px;
  margin: 0 auto;
}
.game-menu-btn {
  background: var(--surface);
  border: 1.5px solid var(--rule);
  border-radius: 16px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-family: var(--font-body);
  text-align: center;
}
.game-menu-btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}
.game-menu-btn:active { transform: translateY(0); }
.game-menu-icon { font-size: 28px; line-height: 1; }
.game-menu-label { font-size: 13px; font-weight: 700; color: var(--ink); }
.game-menu-best {
  font-size: 11px;
  font-weight: 700;
  color: white;
  background: var(--primary);
  padding: 2px 10px;
  border-radius: 99px;
  margin-top: 2px;
}

/* Leaderboard */
.game-leaderboard {
  margin-top: 24px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
}
.lb-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  text-align: center;
  margin-bottom: 16px;
}
.lb-games {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
}
.lb-game-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 8px;
}
.lb-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  padding: 4px 0;
}
.lb-avatar { font-size: 16px; }
.lb-name { flex: 1; color: var(--ink); font-weight: 500; }
.lb-score { font-weight: 700; color: var(--primary); font-variant-numeric: tabular-nums; }

/* Scramble game */
.scramble-pool {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  min-height: 50px;
  padding: 12px;
  background: var(--bg);
  border-radius: 12px;
  margin-bottom: 16px;
}
.scramble-answer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  min-height: 50px;
  padding: 12px;
  border: 2px dashed var(--rule);
  border-radius: 12px;
  margin-bottom: 16px;
}
.scramble-word {
  padding: 8px 14px;
  background: var(--primary);
  color: white;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  border: none;
  font-family: var(--font-body);
}
.scramble-word:hover { opacity: 0.85; transform: scale(1.05); }
.scramble-word.placed {
  background: var(--emerald);
}
.scramble-word.wrong {
  background: var(--rose);
  animation: shake 0.3s ease;
}

/* Erase game */
.erase-board {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  line-height: 2;
  padding: 20px;
  background: #2a3a2a;
  border-radius: 12px;
  margin-bottom: 16px;
}
.erase-word {
  padding: 4px 10px;
  color: #e8e0d0;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s ease;
  border: none;
  background: none;
}
.erase-word:hover { background: rgba(255,255,255,0.1); }
.erase-word.erased {
  opacity: 0;
  pointer-events: none;
}

/* Speed game */
.speed-pool {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 16px;
}
.speed-word {
  padding: 10px 16px;
  background: var(--surface);
  border: 2px solid var(--rule);
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.1s ease;
  font-family: var(--font-body);
  color: var(--ink);
}
.speed-word:hover { border-color: var(--primary); background: var(--primary-light); }
.speed-word.correct {
  background: var(--emerald);
  color: white;
  border-color: var(--emerald);
  pointer-events: none;
}
.speed-word.wrong {
  border-color: var(--rose);
  animation: shake 0.3s ease;
}
.speed-timer {
  text-align: center;
  font-size: 32px;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 16px;
  font-variant-numeric: tabular-nums;
}
.speed-result {
  text-align: center;
  font-size: 20px;
  font-weight: 700;
  color: var(--emerald);
  margin-top: 16px;
}

/* Type it game */
.typeit-input {
  width: 100%;
  padding: 16px;
  border: 2px solid var(--rule);
  border-radius: 12px;
  font-family: var(--font-display);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  resize: vertical;
  min-height: 100px;
  transition: border-color 0.15s ease;
  background: var(--bg);
}
.typeit-input:focus {
  outline: none;
  border-color: var(--primary);
  background: white;
}
.typeit-feedback {
  margin-top: 12px;
  padding: 16px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.6;
}
.typeit-feedback.perfect {
  background: rgba(16,185,129,0.1);
  color: var(--emerald);
  font-weight: 600;
}
.typeit-feedback.close {
  background: rgba(245,158,11,0.1);
  color: #b45309;
}
.typeit-match { color: var(--emerald); font-weight: 600; }
.typeit-miss { color: var(--rose); text-decoration: underline; }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

/* Activities list */
.activities-section { margin-top: 48px; }
.activities-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.activity-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
  overflow: hidden;
  transition: all 0.2s ease;
}
.activity-card.current {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--primary-light);
}
.activity-card.completed {
  opacity: 0.7;
}
.activity-card.locked {
  opacity: 0.45;
}
.activity-week {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 800;
  color: var(--primary);
  flex-shrink: 0;
}
.activity-card.completed .activity-week {
  background: var(--emerald);
  color: white;
}
.activity-body { flex: 1; }
.activity-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 2px;
}
.activity-desc {
  font-size: 13px;
  color: var(--ink-soft);
  line-height: 1.4;
}
.activity-action {
  flex-shrink: 0;
}
.activity-check {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 2px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: white;
  cursor: pointer;
  background: none;
  transition: all 0.15s ease;
}
.activity-check:hover { border-color: var(--primary); }
.activity-check.done {
  background: var(--emerald);
  border-color: var(--emerald);
}

/* Game area */
.game-area {
  margin-top: 32px;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius-lg);
  animation: rise 0.3s ease-out both;
}
.game-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
  text-align: center;
}
.game-words {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  line-height: 2;
}
.game-word {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
}
.game-blank {
  display: inline-block;
  min-width: 60px;
  border-bottom: 2px solid var(--primary);
  text-align: center;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  color: var(--primary);
  padding: 2px 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.game-blank:hover { background: var(--primary-light); }
.game-blank.revealed { color: var(--emerald); border-color: var(--emerald); }
.game-hint {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  color: var(--primary);
  letter-spacing: 0.05em;
}
.game-actions {
  text-align: center;
  margin-top: 20px;
}

/* Recordings */
.recordings-section { margin-top: 48px; }
.recordings-sub {
  text-align: center;
  font-size: 14px;
  color: var(--ink-soft);
  margin-bottom: 20px;
}
.recordings-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.recordings-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.recording-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 14px;
  padding: 16px 20px;
}
.recording-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.recording-emoji { font-size: 22px; }
.recording-name { font-weight: 600; font-size: 14px; }
.recording-time { font-size: 12px; color: var(--ink-soft); margin-left: auto; }
.recording-media {
  width: 100%;
  border-radius: 10px;
}

/* Archive */
.archive-section {
  margin-top: 48px;
  text-align: center;
}
.archive-list {
  margin-top: 16px;
  text-align: left;
}
.archive-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 10px;
}
.archive-ref { font-weight: 700; font-size: 15px; color: var(--ink); }
.archive-text { font-size: 14px; color: var(--ink-soft); font-style: italic; margin-top: 4px; }
.archive-month { font-size: 12px; color: var(--ink-soft); margin-top: 4px; }

@media (max-width: 720px) {
  .verse-main { padding: 16px 12px 64px; }
  .verse-hero { padding: 32px 12px 28px; }
  .verse-text-card { padding: 24px 20px; }
  .activity-card { padding: 16px 18px; }
  .game-area { padding: 20px 16px; }
}
