.mg-onboarding-overlay {
  position: fixed;
  inset: 0;
  z-index: 9998;
  background: rgba(15, 23, 42, .55);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity .3s ease;
}
.mg-onboarding-overlay.active { opacity: 1; }
.mg-onboarding-overlay.closing { opacity: 0; }

.mg-onboarding-modal {
  position: relative;
  width: 95%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 1.25rem;
  box-shadow: 0 25px 60px rgba(0,0,0,.25);
  transform: translateY(20px) scale(.97);
  transition: transform .35s cubic-bezier(.34,1.56,.64,1), opacity .3s ease;
  opacity: 0;
}
.mg-onboarding-overlay.active .mg-onboarding-modal {
  transform: translateY(0) scale(1);
  opacity: 1;
}
.mg-onboarding-overlay.closing .mg-onboarding-modal {
  transform: translateY(20px) scale(.97);
  opacity: 0;
}

.mg-onboarding-header {
  padding: 2rem 2rem 0;
  text-align: center;
}
.mg-onboarding-header .mg-icon-ring {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: .75rem;
}
.mg-onboarding-header h2 {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.3;
  margin: 0 0 .25rem;
}
.mg-onboarding-header p {
  font-size: .8125rem;
  color: #64748b;
  margin: 0;
}

.mg-onboarding-body { padding: 1.5rem 2rem 2rem; }

.mg-pathway-grid {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  margin-top: 1rem;
}
.mg-pathway-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border: 2px solid #e2e8f0;
  border-radius: .875rem;
  cursor: pointer;
  transition: all .2s ease;
  background: #fff;
}
.mg-pathway-card:hover {
  border-color: #38bdf8;
  background: #f0f9ff;
  box-shadow: 0 2px 12px rgba(56,189,248,.12);
}
.mg-pathway-card.selected {
  border-color: #0ea5e9;
  background: #f0f9ff;
  box-shadow: 0 0 0 3px rgba(14,165,233,.15);
}
.mg-pathway-icon {
  width: 36px;
  height: 36px;
  border-radius: .625rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1rem;
}
.mg-pathway-info h4 {
  font-size: .875rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 .125rem;
}
.mg-pathway-info .mg-time {
  font-size: .6875rem;
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.mg-pathway-info p {
  font-size: .75rem;
  color: #64748b;
  margin: .25rem 0 0;
  line-height: 1.4;
}

.mg-onboarding-footer {
  padding: 0 2rem 1.75rem;
  display: flex;
  align-items: center;
  gap: .75rem;
}
.mg-onboarding-footer .mg-btn-primary {
  flex: 1;
  padding: .75rem 1.5rem;
  border: none;
  border-radius: .75rem;
  font-size: .8125rem;
  font-weight: 700;
  color: #fff;
  background: #0ea5e9;
  cursor: pointer;
  transition: background .2s;
  text-align: center;
}
.mg-onboarding-footer .mg-btn-primary:hover { background: #0284c7; }
.mg-onboarding-footer .mg-btn-primary:disabled {
  background: #cbd5e1;
  cursor: not-allowed;
}
.mg-onboarding-footer .mg-btn-skip {
  padding: .75rem 1rem;
  border: none;
  border-radius: .75rem;
  font-size: .8125rem;
  font-weight: 600;
  color: #94a3b8;
  background: transparent;
  cursor: pointer;
  transition: color .2s;
}
.mg-onboarding-footer .mg-btn-skip:hover { color: #475569; }

.mg-step-indicators {
  display: flex;
  justify-content: center;
  gap: .375rem;
  padding: .75rem 2rem;
}
.mg-step-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e2e8f0;
  transition: all .25s ease;
}
.mg-step-dot.active {
  background: #0ea5e9;
  width: 24px;
  border-radius: 4px;
}
.mg-step-dot.done { background: #10b981; }

.mg-step-content { padding: 1.5rem 2rem; }
.mg-step-content h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 .5rem;
}
.mg-step-content p {
  font-size: .8125rem;
  color: #64748b;
  line-height: 1.6;
  margin: 0 0 1rem;
}
.mg-step-content .mg-tip-box {
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  border-radius: .75rem;
  padding: .875rem 1rem;
  font-size: .75rem;
  color: #0369a1;
  line-height: 1.5;
}
.mg-step-content .mg-tip-box strong { color: #075985; }

.mg-completion-screen {
  text-align: center;
  padding: 2.5rem 2rem 2rem;
}
.mg-completion-screen .mg-confetti {
  font-size: 2.5rem;
  margin-bottom: .75rem;
}
.mg-completion-screen h3 {
  font-size: 1.125rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 .5rem;
}
.mg-completion-screen p {
  font-size: .8125rem;
  color: #64748b;
  margin: 0 0 1.5rem;
  line-height: 1.5;
}
.mg-completion-screen .mg-xp-badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .5rem 1rem;
  border-radius: 2rem;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}
