/* Onboarding Styles */

/* Replace icon with app favicon - using custom class instead of Rails helper */
.app-favicon-icon {
  background-color: transparent !important;
  position: relative !important;
  overflow: hidden !important;
}

.app-favicon-icon::before {
  content: '' !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  background-image: url("../images/favicon/favicon.svg") !important;
  background-size: contain !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
}

.app-favicon-icon svg {
  display: none !important;
}

/* Fix for the progress bar icon - use actual favicon */
.w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center {
  background-image: url("../images/favicon/favicon.svg") !important;
  background-size: 20px 20px !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-color: #3b82f6 !important;
}

.w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center svg {
  display: none !important;
}

/* Fix for buttons positioning and styling */
.bg-white.border-t {
  display: flex !important;
  flex-direction: column !important;
  padding: 1.5rem 0 !important;
  background: white !important;
  border-top: 1px solid #e5e7eb !important;
  box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1) !important;
}

.max-w-4xl.mx-auto.px-4.py-4.flex.justify-between {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: 1rem !important;
  padding: 0 1rem !important;
}

@media (min-width: 768px) {
  .bg-white.border-t {
    flex-direction: row !important;
    gap: 1rem !important;
    align-items: center !important;
  }
  
  .max-w-4xl.mx-auto.px-4.py-4.flex.justify-between {
    flex-direction: row !important;
  }
}

/* Ensure buttons stack properly on mobile */
@media (max-width: 767px) {
  .max-w-4xl.mx-auto.px-4.py-4.flex.justify-between {
    flex-direction: column !important;
    gap: 1rem !important;
    align-items: stretch !important;
  }
  
  .flex.items-center.space-x-4 {
    flex-direction: column !important;
    gap: 0.75rem !important;
    width: 100% !important;
  }
  
  .flex.items-center.space-x-4 > * {
    width: 100% !important;
    justify-content: center !important;
  }
}

/* Fix progress bar container spacing */
.bg-white.shadow-sm.border-b {
  padding-bottom: 1.5rem !important;
}

.max-w-4xl.mx-auto.px-4.py-4 {
  padding-top: 1rem !important;
}

/* Removed conflicting icon visibility rules */

/* Fix for buttons not right - improve navigation layout */
.bg-white.border-t {
  display: flex !important;
  flex-direction: column !important;
}

.max-w-4xl.mx-auto.px-4.py-4.flex.justify-between {
  flex-direction: column !important;
  gap: 1.5rem !important;
  align-items: stretch !important;
}

@media (min-width: 768px) {
  .bg-white.border-t {
    flex-direction: row !important;
    gap: 1rem !important;
    align-items: center !important;
  }
  
  .max-w-4xl.mx-auto.px-4.py-4.flex.justify-between {
    flex-direction: row !important;
  }
}

/* Ensure buttons stack properly on mobile */
@media (max-width: 767px) {
  .flex.items-center.space-x-4 {
    flex-direction: column !important;
    gap: 0.75rem !important;
    width: 100% !important;
  }
  
  .flex.items-center.space-x-4 > * {
    width: 100% !important;
    justify-content: center !important;
  }
}

/* Fix progress bar container spacing */
.bg-white.shadow-sm.border-b {
  padding-bottom: 1.5rem !important;
}

.max-w-4xl.mx-auto.px-4.py-4 {
  padding-top: 1rem !important;
}

/* Override existing progress bar styles */

/* Custom app icon for progress bar - removed conflicting text icon */

/* Override existing progress bar styles */
.bg-white.shadow-sm.border-b {
  background: white !important;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06) !important;
  border-bottom: 1px solid #e5e7eb !important;
  padding: 1.5rem 0 !important;
}

.max-w-4xl.mx-auto.px-4.py-4 {
  max-width: 64rem !important;
  margin: 0 auto !important;
  padding: 1rem 1rem !important;
}

.flex.items-center.justify-between.mb-2 {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  margin-bottom: 0.5rem !important;
}

.flex.items-center.space-x-3 {
  display: flex !important;
  align-items: center !important;
  gap: 0.75rem !important;
}

.w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center {
  width: 2rem !important;
  height: 2rem !important;
  background: linear-gradient(135deg, #14b8a6, #60a5fa) !important;
  border-radius: 0.5rem !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  position: relative;
  overflow: hidden;
}

.w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.2) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 0.6s;
}

.w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center:hover::before {
  transform: translateX(100%);
}

.text-xl.font-semibold.text-gray-900 {
  font-size: 1.25rem !important;
  font-weight: 600 !important;
  color: #1f2937 !important;
}

.text-sm.text-gray-500 {
  font-size: 0.875rem !important;
  color: #6b7280 !important;
}

.w-full.bg-gray-200.rounded-full.h-2 {
  width: 100% !important;
  background: #e5e7eb !important;
  border-radius: 9999px !important;
  height: 0.5rem !important;
}

.bg-gradient-to-r.from-blue-500.to-purple-600.h-2.rounded-full.transition-all.duration-300 {
  background: linear-gradient(90deg, #3b82f6, #06b6d4) !important;
  height: 0.5rem !important;
  border-radius: 9999px !important;
  transition: width 0.5s ease-in-out !important;
  position: relative;
  overflow: hidden;
}

.bg-gradient-to-r.from-blue-500.to-purple-600.h-2.rounded-full.transition-all.duration-300::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: shimmer 2s infinite;
}

/* Theme-specific progress bar colors */
.trainer-theme .w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center {
  background-color: #8b5cf6 !important;
  background-image: url("/assets/favicon/favicon.svg") !important;
  background-size: 20px 20px !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
}

.trainer-theme .bg-gradient-to-r.from-blue-500.to-purple-600.h-2.rounded-full.transition-all.duration-300 {
  background: linear-gradient(90deg, #8b5cf6, #ec4899) !important;
}

.trainer-theme .bg-gradient-to-r.from-blue-500.to-purple-600.h-2.rounded-full.transition-all.duration-300::after {
  background: linear-gradient(90deg, transparent, rgba(236, 72, 153, 0.3), transparent);
}

.athlete-theme .w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center {
  background-color: #3b82f6 !important;
  background-image: url("/assets/favicon/favicon.svg") !important;
  background-size: 20px 20px !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
}

.athlete-theme .bg-gradient-to-r.from-blue-500.to-purple-600.h-2.rounded-full.transition-all.duration-300 {
  background: linear-gradient(90deg, #3b82f6, #06b6d4) !important;
}

.athlete-theme .bg-gradient-to-r.from-blue-500.to-purple-600.h-2.rounded-full.transition-all.duration-300::after {
  background: linear-gradient(90deg, transparent, rgba(6, 182, 212, 0.3), transparent);
}

/* App icon replacement - using actual favicon SVG - removed duplicate rules */

/* Override existing navigation button styles */
.bg-white.shadow-sm.border-b {
  background: white !important;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06) !important;
  border-bottom: 1px solid #e5e7eb !important;
  padding: 1.5rem 0 !important;
}

.max-w-4xl.mx-auto.px-4.py-4 {
  max-width: 64rem !important;
  margin: 0 auto !important;
  padding: 1rem 1rem !important;
}

.flex.items-center.justify-between.mb-2 {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  margin-bottom: 0.5rem !important;
}

.flex.items-center.space-x-3 {
  display: flex !important;
  align-items: center !important;
  gap: 0.75rem !important;
}

.w-8.h-8.bg-gradient-to-br.from-blue-500.to-purple-600.rounded-lg.flex.items-center.justify-center {
  width: 2rem !important;
  height: 2rem !important;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6) !important;
  border-radius: 0.5rem !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.text-xl.font-semibold.text-gray-900 {
  font-size: 1.25rem !important;
  font-weight: 600 !important;
  color: #1f2937 !important;
}

.text-sm.text-gray-500 {
  font-size: 0.875rem !important;
  color: #6b7280 !important;
}

.w-full.bg-gray-200.rounded-full.h-2 {
  width: 100% !important;
  background: #e5e7eb !important;
  border-radius: 9999px !important;
  height: 0.5rem !important;
}

.bg-gradient-to-r.from-blue-500.to-purple-600.h-2.rounded-full.transition-all.duration-300 {
  background: linear-gradient(90deg, #3b82f6, #8b5cf6) !important;
  height: 0.5rem !important;
  border-radius: 9999px !important;
  transition: width 0.5s ease-in-out !important;
  position: relative;
  overflow: hidden;
}

/* Override existing navigation button styles with app theme */
.bg-gradient-to-r.from-blue-500.to-blue-600,
input[type="submit"].bg-gradient-to-r.from-blue-500.to-blue-600 {
  background: linear-gradient(135deg, #14b8a6, #60a5fa) !important;
  box-shadow: 0 4px 6px -1px rgba(20, 184, 166, 0.3) !important;
  transition: all 0.2s ease !important;
  position: relative;
  overflow: hidden;
}

.bg-gradient-to-r.from-blue-500.to-blue-600:hover,
input[type="submit"].bg-gradient-to-r.from-blue-500.to-blue-600:hover {
  background: linear-gradient(135deg, #0d9488, #3b82f6) !important;
  box-shadow: 0 10px 15px -3px rgba(20, 184, 166, 0.3) !important;
  transform: translateY(-2px) !important;
}

.bg-gradient-to-r.from-blue-500.to-blue-600::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s;
}

.bg-gradient-to-r.from-blue-500.to-blue-600:hover::before {
  left: 100%;
}

.border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50 {
  border: 1px solid #d1d5db !important;
  border-radius: 0.5rem !important;
  background: white !important;
  color: #374151 !important;
  padding: 0.75rem 1.5rem !important;
  font-weight: 500 !important;
  transition: all 0.2s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 0.875rem !important;
  min-width: 8rem !important;
}

.border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50:hover {
  background: #f9fafb !important;
  color: #1f2937 !important;
  border-color: #9ca3af !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1) !important;
}

.px-4.py-3.text-gray-500.hover\:text-gray-700 {
  padding: 0.75rem 1rem !important;
  color: #6b7280 !important;
  background: transparent !important;
  border: none !important;
  font-weight: 500 !important;
  transition: all 0.2s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 0.875rem !important;
}

.px-4.py-3.text-gray-500.hover\:text-gray-700:hover {
  color: #374151 !important;
  background: #f9fafb !important;
  transform: translateY(-1px) !important;
}

/* Enhanced navigation container with better positioning */
/* Exclude mobile navbar (#mobile-navbar) which should use fixed positioning */
nav.bg-white.border-t:not(#mobile-navbar) {
  background: white !important;
  border-top: 1px solid #e5e7eb !important;
  padding: 1.5rem 0 !important;
  box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1) !important;
  position: sticky !important;
  bottom: 0 !important;
  z-index: 10 !important;
}

.max-w-4xl.mx-auto.px-4.py-4.flex.justify-between {
  max-width: 64rem !important;
  margin: 0 auto !important;
  padding: 0 1rem !important;
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: 1rem !important;
}

/* Enhanced button styling with app theme */
input[type="submit"].bg-gradient-to-r.from-blue-500.to-blue-600,
button.bg-gradient-to-r.from-blue-500.to-blue-600 {
  background: linear-gradient(135deg, #14b8a6, #60a5fa) !important;
  color: white !important;
  border: none !important;
  padding: 0.75rem 1.5rem !important;
  border-radius: 0.5rem !important;
  font-weight: 500 !important;
  font-size: 0.875rem !important;
  box-shadow: 0 4px 6px -1px rgba(20, 184, 166, 0.3) !important;
  transition: all 0.2s ease !important;
  cursor: pointer !important;
  position: relative !important;
  overflow: hidden !important;
  min-width: 8rem !important;
}

input[type="submit"].bg-gradient-to-r.from-blue-500.to-blue-600:hover,
button.bg-gradient-to-r.from-blue-500.to-blue-600:hover {
  background: linear-gradient(135deg, #0d9488, #3b82f6) !important;
  box-shadow: 0 10px 15px -3px rgba(20, 184, 166, 0.3) !important;
  transform: translateY(-2px) !important;
}

input[type="submit"].bg-gradient-to-r.from-blue-500.to-blue-600:active,
button.bg-gradient-to-r.from-blue-500.to-blue-600:active {
  transform: translateY(-1px) scale(0.98) !important;
}

/* Previous button styling */
a.px-6.py-3.border.border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50 {
  background: white !important;
  color: #374151 !important;
  border: 1px solid #d1d5db !important;
  padding: 0.75rem 1.5rem !important;
  border-radius: 0.5rem !important;
  font-weight: 500 !important;
  font-size: 0.875rem !important;
  transition: all 0.2s ease !important;
  min-width: 8rem !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  text-decoration: none !important;
  position: relative !important;
  z-index: 10 !important;
}

a.px-6.py-3.border.border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50:hover {
  background: #f9fafb !important;
  color: #1f2937 !important;
  border-color: #9ca3af !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1) !important;
}

a.px-6.py-3.border.border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50:active {
  transform: translateY(-1px) scale(0.98) !important;
}

/* Ensure previous button is visible and clickable */
.bg-white.border-t a[href*="onboarding"] {
  pointer-events: auto !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* Skip button styling */
a.px-4.py-3.text-gray-500.hover\:text-gray-700 {
  color: #6b7280 !important;
  background: transparent !important;
  border: none !important;
  padding: 0.75rem 1rem !important;
  font-weight: 500 !important;
  font-size: 0.875rem !important;
  transition: all 0.2s ease !important;
}

a.px-4.py-3.text-gray-500.hover\:text-gray-700:hover {
  color: #374151 !important;
  background: #f9fafb !important;
  transform: translateY(-1px) !important;
}

/* Hide continue button on step 2 */
.onboarding-step-2 .flex.justify-end {
  display: none !important;
}

/* Hide continue button on athlete profile step (step 2) */
body[class*="athlete"] .onboarding-card .flex.justify-end {
  display: none !important;
}

/* Alternative approach: Hide continue button when step parameter is 2 */
body[data-step="2"] .onboarding-card .flex.justify-end {
  display: none !important;
}

/* Button active states */
.bg-gradient-to-r.from-blue-500.to-blue-600:active {
  transform: translateY(-1px) scale(0.98) !important;
}

.border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50:active {
  transform: translateY(-1px) scale(0.98) !important;
}

/* Focus states for accessibility */
.focus\:outline-none.focus\:ring-2.focus\:ring-blue-500.focus\:ring-offset-2:focus {
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1) !important;
}

/* Responsive navigation */
@media (max-width: 768px) {
  .max-w-4xl.mx-auto.px-4.py-4.flex.justify-between {
    flex-direction: column !important;
    gap: 1rem !important;
    align-items: stretch !important;
  }
  
  .border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50,
  .bg-gradient-to-r.from-blue-500.to-blue-600 {
    width: 100% !important;
    justify-content: center !important;
  }
}

@media (max-width: 480px) {
  .border-gray-300.rounded-lg.text-gray-700.bg-white.hover\:bg-gray-50,
  .bg-gradient-to-r.from-blue-500.to-blue-600 {
    padding: 0.625rem 1.25rem !important;
    font-size: 0.8125rem !important;
  }
  
  .px-4.py-3.text-gray-500.hover\:text-gray-700 {
    padding: 0.5rem 1rem !important;
    font-size: 0.75rem !important;
  }
}

/* Enhanced Progress Bar */
.enhanced-progress-container {
  background: white;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  padding: 1.5rem 0;
  border-bottom: 1px solid #e5e7eb;
}

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

.progress-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.progress-icon {
  width: 2rem;
  height: 2rem;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.progress-title h1 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #1f2937;
  margin: 0;
}

.progress-step-counter {
  font-size: 0.875rem;
  color: #6b7280;
  font-weight: 500;
}

/* Step Indicators with App Theme Icons */
.step-indicators {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
  position: relative;
}

.step-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 2;
  flex: 1;
}

.step-indicator .step-number {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.875rem;
  transition: all 0.3s ease;
  margin-bottom: 0.5rem;
  position: relative;
  overflow: hidden;
}

.step-indicator .step-label {
  font-size: 0.75rem;
  color: #6b7280;
  text-align: center;
  max-width: 5rem;
  transition: color 0.3s ease;
}

/* Step-specific icons using app theme */
.step-indicator:nth-child(1) .step-number::before {
  content: '👤';
  font-size: 1.25rem;
}

.step-indicator:nth-child(2) .step-number::before {
  content: '📊';
  font-size: 1.25rem;
}

.step-indicator:nth-child(3) .step-number::before {
  content: '📚';
  font-size: 1.25rem;
}

.step-indicator:nth-child(4) .step-number::before {
  content: '💪';
  font-size: 1.25rem;
}

.step-indicator:nth-child(5) .step-number::before {
  content: '🏆';
  font-size: 1.25rem;
}

.step-indicator.completed .step-number {
  background: linear-gradient(135deg, #14b8a6, #10b981);
  color: white;
  box-shadow: 0 4px 6px -1px rgba(20, 184, 166, 0.3);
}

.step-indicator.active .step-number {
  background: linear-gradient(135deg, #14b8a6, #60a5fa);
  color: white;
  box-shadow: 0 4px 6px -1px rgba(20, 184, 166, 0.3);
  transform: scale(1.1);
}

.step-indicator.upcoming .step-number {
  background: #f3f4f6;
  color: #9ca3af;
  border: 2px solid #e5e7eb;
}

.step-indicator.completed .step-label,
.step-indicator.active .step-label {
  color: #374151;
  font-weight: 500;
}

/* Connector Line */
.step-connector {
  position: absolute;
  top: 1.25rem;
  left: 0;
  right: 0;
  height: 2px;
  background: #e5e7eb;
  z-index: 1;
}

.step-connector-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: linear-gradient(90deg, #10b981, #3b82f6);
  transition: width 0.5s ease-in-out;
}

/* Progress Bar */
.onboarding-progress {
  background: linear-gradient(to right, #f3f4f6, #e5e7eb);
  position: relative;
  overflow: hidden;
  height: 0.5rem;
  border-radius: 0.25rem;
}

.onboarding-progress-bar {
  background: linear-gradient(90deg, #3b82f6, #8b5cf6);
  transition: width 0.5s ease-in-out;
  position: relative;
  height: 100%;
  border-radius: 0.25rem;
}

.onboarding-progress-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* Step Indicators */
.step-indicators {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
  position: relative;
}

.step-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 2;
  flex: 1;
}

.step-indicator .step-number {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.875rem;
  transition: all 0.3s ease;
  margin-bottom: 0.5rem;
  position: relative;
}

.step-indicator .step-label {
  font-size: 0.75rem;
  color: #6b7280;
  text-align: center;
  max-width: 5rem;
  transition: color 0.3s ease;
}

.step-indicator.completed .step-number {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  box-shadow: 0 4px 6px -1px rgba(16, 185, 129, 0.3);
}

.step-indicator.active .step-number {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  color: white;
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
  transform: scale(1.1);
}

.step-indicator.upcoming .step-number {
  background: #f3f4f6;
  color: #9ca3af;
  border: 2px solid #e5e7eb;
}

.step-indicator.completed .step-label,
.step-indicator.active .step-label {
  color: #374151;
  font-weight: 500;
}

/* Connector Line */
.step-connector {
  position: absolute;
  top: 1.25rem;
  left: 0;
  right: 0;
  height: 2px;
  background: #e5e7eb;
  z-index: 1;
}

.step-connector-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: linear-gradient(90deg, #10b981, #3b82f6);
  transition: width 0.5s ease-in-out;
}

/* Onboarding Card Improvements */
.onboarding-card {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  padding: 2rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.onboarding-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Feature Cards */
.feature-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1.5rem;
  transition: all 0.3s ease;
  height: 100%;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  border-color: #d1d5db;
}

.feature-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  transition: transform 0.3s ease;
}

.feature-card:hover .feature-icon {
  transform: scale(1.05);
}

/* Enhanced Form Improvements */
.onboarding-form {
  max-width: 100%;
}

.form-group {
  margin-bottom: 1.5rem;
  position: relative;
}

.form-label {
  display: block;
  font-weight: 500;
  color: #374151;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.required-indicator {
  color: #ef4444;
  font-weight: 600;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  transition: all 0.2s ease;
  background-color: white;
  position: relative;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  transform: translateY(-1px);
}

.form-input:hover,
.form-select:hover,
.form-textarea:hover {
  border-color: #9ca3af;
  background-color: #fafafa;
}

.form-input.error,
.form-select.error,
.form-textarea.error {
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-input.success,
.form-select.success,
.form-textarea.success {
  border-color: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.form-hint {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.form-error {
  font-size: 0.75rem;
  color: #ef4444;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.form-success {
  font-size: 0.75rem;
  color: #10b981;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* Form Field Icons */
.form-field-wrapper {
  position: relative;
}

.form-field-icon {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1.25rem;
  height: 1.25rem;
  color: #9ca3af;
  pointer-events: none;
}

.form-field-wrapper.has-icon .form-input,
.form-field-wrapper.has-icon .form-select {
  padding-right: 2.5rem;
}

/* Floating Labels */
.form-floating {
  position: relative;
}

.form-floating .form-input,
.form-floating .form-textarea {
  padding-top: 1.5rem;
  padding-bottom: 0.5rem;
}

.form-floating .form-label {
  position: absolute;
  top: 0.75rem;
  left: 1rem;
  transition: all 0.2s ease;
  pointer-events: none;
  background: white;
  padding: 0 0.25rem;
  color: #9ca3af;
}

.form-floating .form-input:focus ~ .form-label,
.form-floating .form-input:not(:placeholder-shown) ~ .form-label,
.form-floating .form-textarea:focus ~ .form-label,
.form-floating .form-textarea:not(:placeholder-shown) ~ .form-label {
  top: -0.5rem;
  font-size: 0.75rem;
  color: #3b82f6;
}

/* Character Counter */
.character-counter {
  font-size: 0.75rem;
  color: #6b7280;
  text-align: right;
  margin-top: 0.25rem;
}

.character-counter.warning {
  color: #f59e0b;
}

.character-counter.error {
  color: #ef4444;
}

/* Checkbox Group */
.checkbox-group {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.75rem;
}

.checkbox-item {
  display: flex;
  align-items: center;
  padding: 0.75rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
  cursor: pointer;
}

.checkbox-item:hover {
  background-color: #f9fafb;
  border-color: #d1d5db;
}

.checkbox-item input[type="checkbox"] {
  margin-right: 0.5rem;
  width: 1rem;
  height: 1rem;
  color: #3b82f6;
}

.checkbox-item.selected {
  background-color: #eff6ff;
  border-color: #3b82f6;
}

/* Navigation Buttons */
.onboarding-nav {
  background: white;
  border-top: 1px solid #e5e7eb;
  padding: 1.5rem 0;
}

.btn-nav {
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
}

.btn-nav-primary {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  color: white;
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.btn-nav-primary:hover {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.3);
  transform: translateY(-1px);
}

.btn-nav-secondary {
  background: white;
  color: #6b7280;
  border: 1px solid #d1d5db;
}

.btn-nav-secondary:hover {
  background: #f9fafb;
  color: #374151;
  border-color: #9ca3af;
}

.btn-nav-ghost {
  background: transparent;
  color: #6b7280;
}

.btn-nav-ghost:hover {
  color: #374151;
  background: #f9fafb;
}

/* Info Box */
.info-box {
  border-radius: 0.75rem;
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
}

.info-box-blue {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
}

.info-box-purple {
  background: #f3e8ff;
  border: 1px solid #d8b4fe;
  color: #6b21a8;
}

.info-box-green {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

/* Responsive Design */
@media (max-width: 768px) {
  .onboarding-card {
    padding: 1.5rem;
  }
  
  .step-indicators {
    margin-bottom: 0.75rem;
  }
  
  .step-indicator .step-label {
    font-size: 0.625rem;
  }
  
  .checkbox-group {
    grid-template-columns: 1fr;
  }
  
  .onboarding-nav {
    padding: 1rem 0;
  }
  
  .btn-nav {
    padding: 0.625rem 1.25rem;
    font-size: 0.8125rem;
  }
}

@media (max-width: 480px) {
  .onboarding-card {
    padding: 1rem;
  }
  
  .step-indicator .step-number {
    width: 2rem;
    height: 2rem;
    font-size: 0.75rem;
  }
  
  .feature-icon {
    width: 3rem;
    height: 3rem;
  }
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fadeIn 0.5s ease-out;
}

/* Trainer-specific styles */
.trainer-theme .step-indicator.active .step-number {
  background: linear-gradient(135deg, #8b5cf6, #ec4899);
}

.trainer-theme .btn-nav-primary {
  background: linear-gradient(135deg, #8b5cf6, #ec4899);
}

.trainer-theme .btn-nav-primary:hover {
  background: linear-gradient(135deg, #7c3aed, #db2777);
}

.trainer-theme .form-input:focus,
.trainer-theme .form-select:focus,
.trainer-theme .form-textarea:focus {
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.trainer-theme .checkbox-item.selected {
  background-color: #f3e8ff;
  border-color: #8b5cf6;
}

/* Athlete-specific styles */
.athlete-theme .step-indicator.active .step-number {
  background: linear-gradient(135deg, #3b82f6, #06b6d4);
}

.athlete-theme .btn-nav-primary {
  background: linear-gradient(135deg, #3b82f6, #06b6d4);
}

.athlete-theme .btn-nav-primary:hover {
  background: linear-gradient(135deg, #2563eb, #0891b2);
}

.athlete-theme .form-input:focus,
.athlete-theme .form-select:focus,
.athlete-theme .form-textarea:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.athlete-theme .checkbox-item.selected {
  background-color: #eff6ff;
  border-color: #3b82f6;
}

/* Enhanced Onboarding Layout */
.onboarding-container {
  min-height: 100vh;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  display: flex;
  flex-direction: column;
}

.onboarding-content {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.onboarding-card {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  padding: 2.5rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  max-width: 100%;
  width: 100%;
  animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.onboarding-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Card Header */
.card-header {
  text-align: center;
  margin-bottom: 2rem;
}

.card-icon {
  width: 4rem;
  height: 4rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-size: 1.5rem;
  color: white;
  position: relative;
  overflow: hidden;
}

.card-icon::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.2) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 0.6s;
}

.card-header:hover .card-icon::before {
  transform: translateX(100%);
}

.card-title {
  font-size: 2rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.card-description {
  font-size: 1.125rem;
  color: #6b7280;
  max-width: 32rem;
  margin: 0 auto;
  line-height: 1.6;
}

/* Feature Cards Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.feature-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1.5rem;
  transition: all 0.3s ease;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #3b82f6, #8b5cf6);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.feature-card:hover::before {
  transform: scaleX(1);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  border-color: #d1d5db;
}

.feature-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  transition: all 0.3s ease;
  position: relative;
  z-index: 1;
}

.feature-card:hover .feature-icon {
  transform: scale(1.05) rotate(2deg);
}

.feature-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 0.5rem;
  text-align: center;
}

.feature-description {
  font-size: 0.875rem;
  color: #6b7280;
  text-align: center;
  line-height: 1.5;
}

/* Two Column Layout */
.two-column-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin: 2rem 0;
}

@media (max-width: 768px) {
  .two-column-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

/* Content Sections */
.content-section {
  background: #f9fafb;
  border-radius: 0.75rem;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.section-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-icon {
  width: 1.25rem;
  height: 1.25rem;
  color: #3b82f6;
}

/* Enhanced Navigation Buttons */
.nav-container {
  max-width: 64rem;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.btn-nav {
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  position: relative;
  overflow: hidden;
}

.btn-nav::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s;
}

.btn-nav:hover::before {
  left: 100%;
}

.btn-nav:active {
  transform: scale(0.98);
}

.btn-nav-primary {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  color: white;
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
  min-width: 8rem;
}

.btn-nav-primary:hover {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.3);
  transform: translateY(-2px);
}

.btn-nav-primary:active {
  transform: translateY(-1px) scale(0.98);
}

.btn-nav-secondary {
  background: white;
  color: #6b7280;
  border: 1px solid #d1d5db;
  min-width: 8rem;
}

.btn-nav-secondary:hover {
  background: #f9fafb;
  color: #374151;
  border-color: #9ca3af;
  transform: translateY(-1px);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.btn-nav-ghost {
  background: transparent;
  color: #6b7280;
  padding: 0.75rem 1rem;
}

.btn-nav-ghost:hover {
  color: #374151;
  background: #f9fafb;
  transform: translateY(-1px);
}

.btn-nav:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

.btn-nav:disabled:hover {
  transform: none !important;
  box-shadow: none !important;
}

/* Button Loading State */
.btn-nav.loading {
  color: transparent;
  pointer-events: none;
}

.btn-nav.loading::after {
  content: '';
  position: absolute;
  width: 1rem;
  height: 1rem;
  top: 50%;
  left: 50%;
  margin-left: -0.5rem;
  margin-top: -0.5rem;
  border: 2px solid #ffffff;
  border-radius: 50%;
  border-top-color: transparent;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Enhanced Checkbox and Radio Button Groups */
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.radio-item {
  display: flex;
  align-items: center;
  padding: 0.75rem 1rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.checkbox-item::before,
.radio-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(139, 92, 246, 0.05));
  opacity: 0;
  transition: opacity 0.2s ease;
}

.checkbox-item:hover::before,
.radio-item:hover::before {
  opacity: 1;
}

.radio-item:hover {
  background-color: #f9fafb;
  border-color: #d1d5db;
  transform: translateY(-1px);
}

.radio-item input[type="radio"] {
  margin-right: 0.75rem;
  width: 1.125rem;
  height: 1.125rem;
  color: #3b82f6;
  position: relative;
  z-index: 1;
}

.radio-item.selected {
  background-color: #eff6ff;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.radio-item.selected::before {
  opacity: 1;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(139, 92, 246, 0.1));
}

/* Custom Checkbox and Radio Styles */
input[type="checkbox"]:checked,
input[type="radio"]:checked {
  background-color: #3b82f6;
  border-color: #3b82f6;
}

input[type="checkbox"]:focus,
input[type="radio"]:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 3rem;
  height: 1.5rem;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #e5e7eb;
  transition: 0.3s;
  border-radius: 1.5rem;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 1.125rem;
  width: 1.125rem;
  left: 0.1875rem;
  bottom: 0.1875rem;
  background-color: white;
  transition: 0.3s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

input:checked + .toggle-slider {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
}

input:checked + .toggle-slider:before {
  transform: translateX(1.5rem);
}

/* Responsive Design Improvements */
@media (max-width: 1024px) {
  .onboarding-card {
    padding: 2rem;
  }
  
  .features-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.25rem;
  }
  
  .nav-container {
    flex-direction: column;
    gap: 1rem;
    align-items: stretch;
  }
  
  .btn-nav {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .onboarding-content {
    padding: 1rem;
  }
  
  .onboarding-card {
    padding: 1.5rem;
  }
  
  .card-title {
    font-size: 1.75rem;
  }
  
  .card-description {
    font-size: 1rem;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .two-column-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .checkbox-group {
    grid-template-columns: 1fr;
  }
  
  .step-indicators {
    margin-bottom: 0.75rem;
  }
  
  .step-indicator .step-label {
    font-size: 0.625rem;
    max-width: 4rem;
  }
  
  .step-indicator .step-number {
    width: 2rem;
    height: 2rem;
    font-size: 0.75rem;
  }
  
  .nav-container {
    padding: 0 0.5rem;
  }
  
  .btn-nav {
    padding: 0.625rem 1.25rem;
    font-size: 0.8125rem;
  }
}

@media (max-width: 480px) {
  .onboarding-content {
    padding: 0.5rem;
  }
  
  .onboarding-card {
    padding: 1rem;
  }
  
  .card-title {
    font-size: 1.5rem;
  }
  
  .card-description {
    font-size: 0.875rem;
  }
  
  .card-icon {
    width: 3rem;
    height: 3rem;
    font-size: 1.25rem;
  }
  
  .feature-icon {
    width: 3rem;
    height: 3rem;
  }
  
  .feature-card {
    padding: 1rem;
  }
  
  .form-input,
  .form-select,
  .form-textarea {
    padding: 0.625rem 0.875rem;
    font-size: 0.8125rem;
  }
  
  .checkbox-item,
  .radio-item {
    padding: 0.625rem 0.875rem;
  }
  
  .btn-nav {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
  }
  
  .btn-nav-primary {
    min-width: 6rem;
  }
  
  .btn-nav-secondary {
    min-width: 6rem;
  }
}

/* Micro-interactions and Animations */
.pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(59, 130, 246, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
  }
}

.bounce {
  animation: bounce 1s infinite;
}

@keyframes bounce {
  0%, 20%, 53%, 80%, 100% {
    transform: translate3d(0,0,0);
  }
  40%, 43% {
    transform: translate3d(0, -8px, 0);
  }
  70% {
    transform: translate3d(0, -4px, 0);
  }
  90% {
    transform: translate3d(0, -2px, 0);
  }
}

.shake {
  animation: shake 0.5s;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-2px); }
  20%, 40%, 60%, 80% { transform: translateX(2px); }
}

/* Loading Skeleton */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Tooltips */
.tooltip {
  position: relative;
  display: inline-block;
}

.tooltip .tooltip-text {
  visibility: hidden;
  width: 200px;
  background-color: #1f2937;
  color: #f9fafb;
  text-align: center;
  border-radius: 0.375rem;
  padding: 0.5rem 0.75rem;
  position: absolute;
  z-index: 1;
  bottom: 125%;
  left: 50%;
  margin-left: -100px;
  opacity: 0;
  transition: opacity 0.3s;
  font-size: 0.75rem;
  line-height: 1.4;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.tooltip:hover .tooltip-text {
  visibility: visible;
  opacity: 1;
}

.tooltip .tooltip-text::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: #1f2937 transparent transparent transparent;
}

/* Focus Visible for Accessibility */
.focus-visible:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
}

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

/* High Contrast Mode */
@media (prefers-contrast: high) {
  .onboarding-card {
    border: 2px solid #1f2937;
  }
  
  .btn-nav-primary {
    background: #1f2937;
    color: #ffffff;
  }
  
  .form-input,
  .form-select,
  .form-textarea {
    border: 2px solid #1f2937;
  }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
  .onboarding-container {
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
  }
  
  .onboarding-card {
    background: #374151;
    color: #f9fafb;
  }
  
  .card-title {
    color: #f9fafb;
  }
  
  .card-description {
    color: #d1d5db;
  }
  
  .form-input,
  .form-select,
  .form-textarea {
    background-color: #4b5563;
    border-color: #6b7280;
    color: #f9fafb;
  }
  
  .feature-card {
    background: #374151;
    border-color: #4b5563;
  }
  
  .checkbox-item,
  .radio-item {
    background: #4b5563;
    border-color: #6b7280;
  }
  
  .onboarding-nav {
    background: #374151;
    border-color: #4b5563;
  }
}

/* Progress bar width handling with CSS custom properties (CSP-safe) */
.onboarding-progress-bar {
  width: var(--progress, 0%);
}