.tutorial-intro {
  color: #666;
  margin-bottom: 2rem;
  text-align: center;
}

.level-grid {
  display: grid;
  gap: 1rem;
  max-width: 600px;
  margin: 0 auto;
}

.level-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  background: #fff;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
  position: relative;
}

.level-card:hover {
  border-color: #8d6e63;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.level-card.completed {
  border-color: #4caf50;
  background: #f1f8e9;
}

.level-card.locked {
  opacity: 0.6;
  cursor: not-allowed;
  background: #f5f5f5;
}

.level-number {
  width: 48px;
  height: 48px;
  background: #8d6e63;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  font-weight: bold;
  flex-shrink: 0;
}

.level-card.completed .level-number {
  background: #4caf50;
}

.level-info {
  flex: 1;
}

.level-info h2 {
  margin: 0 0 0.25rem;
  font-size: 1.1rem;
}

.level-info p {
  margin: 0;
  color: #666;
  font-size: 0.9rem;
}

.level-status {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.status-badge {
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-weight: 500;
}

.status-badge.completed {
  background: #4caf50;
  color: white;
}

.status-badge.in-progress {
  background: #ff9800;
  color: white;
}

.status-badge.not-started {
  background: #e0e0e0;
  color: #666;
}

.status-badge.locked {
  background: #9e9e9e;
  color: white;
}

.alert {
  background: #fff3e0;
  border: 1px solid #ffb74d;
  color: #e65100;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  text-align: center;
}

.level-status .stat {
  font-size: 0.75rem;
  color: #666;
}

.level-status .stat.perfect {
  color: #4caf50;
  font-weight: 500;
}

.ai-badge {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  font-size: 0.7rem;
  padding: 0.15rem 0.4rem;
  background: #5d4037;
  color: white;
  border-radius: 4px;
}

.tutorial-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.back-link {
  color: #8d6e63;
  text-decoration: none;
  font-size: 0.9rem;
}

.back-link:hover {
  text-decoration: underline;
}

.restart-form {
  display: inline;
}

.restart-btn {
  background: transparent;
  border: 1px solid #999;
  color: #666;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s ease;
}

.restart-btn:hover {
  background: #f5f5f5;
  border-color: #666;
}

.tutorial-description {
  color: #666;
  margin-bottom: 1.5rem;
}

.step-message {
  font-size: 1.25rem;
  font-weight: 500;
  padding: 1rem;
  background: #e3f2fd;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  text-align: center;
}

.error-message {
  color: #d32f2f;
  background: #ffebee;
  padding: 0.75rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  text-align: center;
}

.tutorial-board {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  padding: 1.5rem 1rem;
  background: #8d6e63;
  border-radius: 16px;
  margin-bottom: 2rem;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.board-center {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.board-row {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
}

.store {
  width: 80px;
  height: 170px;
  background: #5d4037;
  border-radius: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.opponent-store {
  opacity: 0.7;
}

.store .stone-count {
  color: white;
  font-size: 1.75rem;
  font-weight: bold;
}

.opponent-row .pit {
  cursor: default;
  opacity: 0.7;
}

.opponent-row .pit:hover {
  transform: none;
}

.pit {
  width: 80px;
  height: 80px;
  background: #5d4037;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 3px solid transparent;
}

.pit:hover {
  transform: scale(1.05);
}

.pit.highlighted {
  border-color: #ffeb3b;
  box-shadow: 0 0 20px rgba(255, 235, 59, 0.6);
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0%, 100% {
    box-shadow: 0 0 20px rgba(255, 235, 59, 0.6);
  }
  50% {
    box-shadow: 0 0 30px rgba(255, 235, 59, 0.9);
  }
}

.stone-count {
  color: white;
  font-size: 1.5rem;
  font-weight: bold;
}

.level-complete {
  text-align: center;
  padding: 2rem;
  background: #e8f5e9;
  border-radius: 12px;
  margin-bottom: 1.5rem;
}

.level-complete h2 {
  color: #2e7d32;
  margin-bottom: 0.5rem;
}

.level-complete p {
  color: #555;
  margin-bottom: 1rem;
}

.next-level-btn {
  display: inline-block;
  padding: 0.75rem 2rem;
  background: #4caf50;
  color: white;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 500;
  transition: background 0.2s ease;
}

.next-level-btn:hover {
  background: #388e3c;
}

.progress-stats {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin: 1rem 0;
  padding: 0.75rem;
  background: #f5f5f5;
  border-radius: 8px;
}

.progress-stats .stat {
  color: #666;
  font-size: 0.9rem;
}

.achievements-earned {
  margin: 1.5rem 0;
  padding: 1rem;
  background: linear-gradient(135deg, #fff3e0, #ffe0b2);
  border-radius: 12px;
  border: 2px solid #ffb74d;
}

.achievement {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem;
}

.achievement-name {
  font-weight: bold;
  color: #e65100;
  font-size: 1.1rem;
}

.achievement-description {
  color: #666;
  font-size: 0.85rem;
}

.all-complete {
  font-size: 1.1rem;
  color: #1976d2;
  font-weight: 500;
  margin-top: 1rem;
}

.result-page {
  max-width: 500px;
  margin: 0 auto;
  padding: 1rem;
}

.result-header {
  text-align: center;
  margin-bottom: 2rem;
}

.result-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  background: #4caf50;
  color: white;
  border-radius: 50%;
  font-size: 2rem;
  margin-bottom: 1rem;
}

.result-header h1 {
  margin: 0 0 0.5rem;
}

.result-status {
  color: #4caf50;
  font-weight: 500;
}

.result-stats {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  flex: 1;
  background: #f5f5f5;
  border-radius: 10px;
  padding: 1rem;
  text-align: center;
}

.stat-label {
  display: block;
  font-size: 0.8rem;
  color: #666;
  margin-bottom: 0.25rem;
}

.stat-value {
  display: block;
  font-size: 1.25rem;
  font-weight: bold;
  color: #3e2723;
}

.result-achievements {
  background: linear-gradient(135deg, #fff3e0, #ffe0b2);
  border: 2px solid #ffb74d;
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 2rem;
}

.result-achievements h3 {
  margin: 0 0 0.75rem;
  font-size: 1rem;
  color: #e65100;
}

.result-achievement {
  display: flex;
  flex-direction: column;
  padding: 0.5rem 0;
}

.result-achievement + .result-achievement {
  border-top: 1px solid rgba(230, 81, 0, 0.2);
}

.result-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.inline-form {
  display: inline;
}

.replay-btn {
  padding: 0.75rem 1.5rem;
  background: #8d6e63;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s ease;
}

.replay-btn:hover {
  background: #6d4c41;
}

.next-btn {
  padding: 0.75rem 1.5rem;
  background: #4caf50;
  color: white;
  text-decoration: none;
  border-radius: 8px;
  font-size: 1rem;
  transition: background 0.2s ease;
}

.next-btn:hover {
  background: #388e3c;
}
