/* Modern AI Company Styling for Machina.coach */

:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --secondary: #8b5cf6;
  --accent: #06b6d4;
  --success: #10b981;
  --warning: #f59e0b;
  --warning-dark: #d97706;
  --error: #ef4444;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
}

/* Custom animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200px 0;
  }
  100% {
    background-position: calc(200px + 100%) 0;
  }
}

.animate-fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

.animate-pulse-gentle {
  animation: pulse 2s infinite;
}

.shimmer {
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
  background-size: 200px 100%;
  animation: shimmer 1.5s infinite;
}

/* Navigation */
.nav-link {
  position: relative;
  transition: all 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Buttons */
.btn-primary {
  background: var(--warning);
  border: none;
  color: var(--gray-900);
  font-weight: 600;
  padding: 12px 24px;
  border-radius: 8px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary:hover {
  background: var(--warning-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(245, 158, 11, 0.3);
}

.btn-secondary {
  background: white;
  border: 2px solid var(--primary);
  color: var(--primary);
  font-weight: 600;
  padding: 10px 22px;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: var(--primary);
  color: white;
  transform: translateY(-2px);
}

/* Cards */
.card {
  background: white;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  border: 1px solid var(--gray-200);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.card-feature {
  position: relative;
  overflow: hidden;
}

.card-feature::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent));
}

/* Stats */
.stat-number {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
}

/* Lifestyle cards */
.lifestyle-card {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 16px;
  padding: 24px;
  margin: 16px 0;
  transform: scale(0.95);
  opacity: 0.8;
  transition: all 0.4s ease;
}

.lifestyle-card.active {
  transform: scale(1);
  opacity: 1;
  box-shadow: 0 20px 40px rgba(102, 126, 234, 0.3);
}

.lifestyle-card h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.lifestyle-item {
  display: flex;
  align-items: center;
  margin: 8px 0;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  backdrop-filter: blur(10px);
}

.lifestyle-item::before {
  content: '✨';
  margin-right: 8px;
  font-size: 1.1em;
}

/* Form styling */
.form-input {
  border: 2px solid var(--gray-200);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 16px;
  transition: all 0.3s ease;
  background: white;
}

.form-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* Slider styling */
.slider {
  -webkit-appearance: none;
  appearance: none;
  height: 8px;
  border-radius: 4px;
  background: var(--gray-200);
  outline: none;
  transition: all 0.3s ease;
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(99, 102, 241, 0.3);
  transition: all 0.3s ease;
}

.slider::-webkit-slider-thumb:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 12px rgba(99, 102, 241, 0.4);
}

.slider::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 8px rgba(99, 102, 241, 0.3);
}

/* Trust signals */
.trust-badge {
  display: inline-flex;
  align-items: center;
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: 20px;
  padding: 6px 12px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-700);
  margin: 4px;
}

.trust-badge::before {
  content: '🔒';
  margin-right: 6px;
}

/* Mobile Navigation */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--gray-700);
  cursor: pointer;
  padding: 8px;
}

/* Responsive design */
@media (max-width: 768px) {
  /* Navigation */
  .mobile-menu-toggle {
    display: block;
  }
  
  /* Typography */
  h1 {
    font-size: 2rem !important;
    line-height: 1.2;
  }
  
  h2 {
    font-size: 1.75rem !important;
    line-height: 1.3;
  }
  
  h3 {
    font-size: 1.5rem !important;
  }
  
  .text-4xl {
    font-size: 2rem !important;
  }
  
  .text-3xl {
    font-size: 1.75rem !important;
  }
  
  .text-2xl {
    font-size: 1.5rem !important;
  }
  
  .text-xl {
    font-size: 1.125rem !important;
  }
  
  /* Spacing */
  .py-20 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
  
  .py-16 {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
  }
  
  .py-12 {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
  }
  
  .mb-8 {
    margin-bottom: 1.5rem !important;
  }
  
  .mb-6 {
    margin-bottom: 1rem !important;
  }
  
  /* Cards */
  .card {
    padding: 16px;
    margin-bottom: 16px;
  }
  
  .lifestyle-card {
    padding: 16px;
    margin: 12px 0;
  }
  
  .lifestyle-item {
    padding: 6px 10px;
    margin: 6px 0;
    font-size: 0.9rem;
  }
  
  /* Buttons */
  .btn-primary,
  .btn-secondary {
    padding: 12px 24px;
    font-size: 16px;
    width: 100%;
    text-align: center;
  }
  
  /* Forms */
  .form-input {
    padding: 14px 16px;
    font-size: 16px;
    width: 100%;
  }
  
  /* Flex layouts */
  .sm\:flex-row {
    flex-direction: column !important;
    gap: 12px !important;
  }
  
  .md\:grid-cols-2,
  .md\:grid-cols-3,
  .md\:grid-cols-4 {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  
  /* Calculator specific */
  .calculator-section {
    padding: 16px;
  }
  
  .slider-container {
    margin: 16px 0;
  }
  
  .slider {
    height: 10px;
    margin: 12px 0;
  }
  
  .slider::-webkit-slider-thumb {
    width: 28px;
    height: 28px;
  }
  
  /* Income display */
  #income {
    font-size: 2.5rem !important;
  }
  
  /* Lifestyle cards mobile optimization */
  .lifestyle-card h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
  }
  
  .lifestyle-card .text-sm {
    font-size: 0.875rem;
  }
  
  /* Grid layouts */
  .grid {
    gap: 16px !important;
  }
  
  /* Container padding */
  .container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  /* Max width adjustments */
  .max-w-4xl,
  .max-w-6xl {
    max-width: 100% !important;
  }
  
  /* Footer */
  footer .grid {
    grid-template-columns: 1fr !important;
    text-align: center;
    gap: 24px !important;
  }
  
  /* Trust badges */
  .trust-badge {
    font-size: 0.75rem;
    padding: 4px 8px;
    margin: 2px;
  }
  
  /* Navigation links */
  .nav-link {
    padding: 8px 12px;
    font-size: 0.9rem;
  }
}

/* Extra small screens */
@media (max-width: 480px) {
  h1 {
    font-size: 1.75rem !important;
  }
  
  .text-4xl {
    font-size: 1.75rem !important;
  }
  
  .py-20 {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
  }
  
  .card {
    padding: 12px;
  }
  
  .lifestyle-card {
    padding: 12px;
  }
  
  .btn-primary,
  .btn-secondary {
    padding: 10px 20px;
    font-size: 14px;
  }
  
  #income {
    font-size: 2rem !important;
  }
  
  .container {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }
}

/* Loading states */
.loading {
  position: relative;
  color: transparent;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid var(--gray-300);
  border-top: 2px solid var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
