/* ─── Micro-interactions ─────────────────────────────────────── */

/* ── Ripple effect ── */
.btn, .btn-primary, .btn-secondary, .btn-gold, .btn-success, .btn-danger, .btn-outline {
  position: relative;
  overflow: hidden;
}

.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  transform: scale(0);
  animation: rippleAnim 0.6s ease-out;
  pointer-events: none;
}

@keyframes rippleAnim {
  to { transform: scale(3); opacity: 0; }
}

/* ── Stagger entrance for cards ── */
.stagger-item {
  opacity: 0;
  animation: slideUp 0.4s ease forwards;
}
.stagger-item:nth-child(1) { animation-delay: 0ms; }
.stagger-item:nth-child(2) { animation-delay: 80ms; }
.stagger-item:nth-child(3) { animation-delay: 160ms; }
.stagger-item:nth-child(4) { animation-delay: 240ms; }
.stagger-item:nth-child(5) { animation-delay: 320ms; }
.stagger-item:nth-child(6) { animation-delay: 400ms; }
.stagger-item:nth-child(n+7) { animation-delay: 480ms; }

/* ── Empty states ── */
.empty-state {
  text-align: center;
  padding: 64px 24px;
  animation: fadeIn 0.4s ease;
}

.empty-icon {
  font-size: 4rem;
  margin-bottom: 16px;
  opacity: 0.8;
}

.empty-state h3 {
  font-family: var(--font-display);
  color: var(--dark);
  margin-bottom: 8px;
  font-size: var(--text-lg);
}

.empty-state p {
  color: var(--gray);
  margin-bottom: 24px;
}

/* Compact empty state for sidebar */
.sidebar-empty {
  font-size: var(--text-xs);
  color: var(--gray);
  padding: var(--space-sm) var(--space-sm);
}

.sidebar-empty a {
  color: var(--primary);
  font-weight: var(--fw-semibold);
  cursor: pointer;
}

/* ── Accessibility: respect reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── Lesson screen UX (Sprint 2.1) ── */
.breadcrumb {
  display: flex; align-items: center; gap: 8px;
  font-size: var(--text-sm); color: var(--gray);
  margin-bottom: var(--space-md);
}
.breadcrumb a { color: var(--primary); cursor: pointer; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb-current { color: var(--gray-dark); font-weight: 600; }

.lesson-stepper {
  display: flex; align-items: center;
  margin: var(--space-md) 0 var(--space-lg);
}
.lesson-dot {
  width: 32px; height: 32px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: var(--text-sm); font-weight: 700;
  background: var(--gray-light); color: var(--gray-dark);
  flex-shrink: 0;
}
.lesson-dot.done { background: var(--success, #27ae60); color: var(--white); }
.lesson-dot.current {
  background: var(--primary); color: var(--white);
  box-shadow: 0 0 0 4px rgba(0,142,168,0.18);
}
.lesson-dot.locked { font-size: 0.8rem; }
.lesson-line {
  height: 3px; flex: 1; max-width: 48px;
  background: var(--gray-light);
}
.lesson-line.done { background: var(--success, #27ae60); }

.course-progress-label { font-size: var(--text-sm); color: var(--gray-dark); }
.course-progress-label strong { color: var(--primary); }

.material-reward-hint {
  text-align: center; font-size: var(--text-sm);
  color: var(--gray-dark); margin-top: 8px;
}
.material-done-badge {
  display: flex; align-items: center; justify-content: center;
  gap: 8px; padding: 14px;
  background: rgba(39,174,96,0.1);
  border: 1px solid rgba(39,174,96,0.35);
  border-radius: var(--radius-md);
  color: #1e8449; font-weight: 700;
}

.locked-exercise-hint { text-align: center; padding: 24px; color: var(--gray-dark); }
.locked-exercise-hint .locked-icon { font-size: 2rem; display: block; margin-bottom: 8px; }
.locked-reward { font-size: var(--text-sm); color: #b8860b; margin-top: 6px; }
