/* Modern AutoFix Styling */
:root {
  --primary-color: #2563eb;
  --secondary-color: #f59e0b;
  --accent-color: #10b981;
  --dark-color: #1f2937;
  --light-color: #f8fafc;
  --gradient-primary: linear-gradient(135deg, #1a365d 0%, #2d4a72 50%, #4a5568 100%);
  --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

html {
  font-size: 14px;
  scroll-behavior: smooth;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  color: #374151;
  margin: 0;
  overflow-x: hidden;
}

/* Navigation Styling */
.bg-gradient-primary {
  background: var(--gradient-primary) !important;
}

.navbar-brand {
  font-weight: 800;
  font-size: 1.75rem !important;
  letter-spacing: -0.025em;
}

.navbar-nav .nav-link {
  font-weight: 500;
  padding: 0.75rem 1rem !important;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover {
  background-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-1px);
}

/* Navbar scroll effects */
.navbar {
  transition: all 0.3s ease;
}

.navbar-scrolled {
    background: linear-gradient(135deg, #1a365d 0%, #2d4a72 50%, #4a5568 100%) !important;
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* Hero Section */
.hero-section {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  background: var(--gradient-primary);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('https://images.unsplash.com/photo-1492144534655-ae79c964c9d7?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
  background-size: cover;
  background-position: center;
  opacity: 0.1;
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-stats .stat-item {
  text-align: center;
}

.hero-image {
  position: relative;
  z-index: 2;
}

.main-hero-img {
  border-radius: 1.5rem !important;
  box-shadow: var(--shadow-xl);
  transform: perspective(1000px) rotateY(-15deg) rotateX(5deg);
  transition: transform 0.3s ease;
}

.main-hero-img:hover {
  transform: perspective(1000px) rotateY(-10deg) rotateX(2deg);
}

.floating-card {
  bottom: 2rem;
  right: 2rem;
  z-index: 3;
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.icon-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
  40% { transform: translateX(-50%) translateY(-10px); }
  60% { transform: translateX(-50%) translateY(-5px); }
}

/* Feature Cards */
.feature-card {
  background: white;
  padding: 2.5rem 2rem;
  border-radius: 1rem;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
  border: 1px solid rgba(0, 0, 0, 0.05);
  text-align: center;
}

.feature-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-xl);
}

.feature-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  color: white;
  font-size: 2rem;
}

/* Service Cards */
.service-card {
  background: white;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-xl);
}

.service-image {
  position: relative;
  height: 250px;
  overflow: hidden;
}

.service-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.service-card:hover .service-image img {
  transform: scale(1.1);
}

.service-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(37, 99, 235, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 3rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.service-card:hover .service-overlay {
  opacity: 1;
}

.service-content {
  padding: 2rem;
}

.service-features {
  list-style: none;
  padding: 0;
  margin: 0;
}

.service-features li {
  padding: 0.25rem 0;
}

/* Process Steps */
.process-step {
  position: relative;
  padding: 2rem 1rem;
}

.step-number {
  position: absolute;
  top: -1rem;
  left: 50%;
  transform: translateX(-50%);
  width: 3rem;
  height: 3rem;
  background: var(--secondary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.25rem;
  color: white;
  z-index: 2;
}

.step-icon {
  width: 100px;
  height: 100px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 2rem auto 1.5rem;
  font-size: 2.5rem;
  color: white;
  border: 3px solid rgba(255, 255, 255, 0.2);
}

/* Testimonials */
.testimonial-card {
  background: white;
  padding: 2rem;
  border-radius: 1rem;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
  height: 100%;
}

.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.testimonial-text {
  font-style: italic;
  margin-bottom: 2rem;
  color: #6b7280;
  line-height: 1.7;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.author-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
}

/* Buttons */
.btn {
  font-weight: 600;
  border-radius: 0.75rem;
  padding: 0.75rem 1.5rem;
  transition: all 0.3s ease;
  text-decoration: none;
  border: 2px solid transparent;
}

.btn-warning {
  background: var(--secondary-color);
  border-color: var(--secondary-color);
  color: white;
}

.btn-warning:hover {
  background: #d97706;
  border-color: #d97706;
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline-light:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* Enhanced dropdown menus */
.dropdown-menu {
  border-radius: 0.75rem;
  border: none;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  margin-top: 0.5rem;
}

.dropdown-item {
  padding: 0.75rem 1.25rem;
  transition: all 0.2s ease;
  border-radius: 0.5rem;
  margin: 0.25rem 0.5rem;
}

.dropdown-item:hover {
  background-color: #f8f9fa;
  transform: translateX(5px);
}

.dropdown-header {
  padding: 1rem 1.25rem 0.5rem;
  font-weight: 600;
  color: #374151;
}

/* Loading animations */
.btn.loading {
  position: relative;
  color: transparent !important;
}

.btn.loading::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  top: 50%;
  left: 50%;
  margin-left: -8px;
  margin-top: -8px;
  border: 2px solid transparent;
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Enhanced focus states */
.btn:focus,
.form-control:focus,
.form-select:focus {
  box-shadow: 0 0 0 0.2rem rgba(245, 158, 11, 0.25);
  border-color: var(--secondary-color);
}

/* Lazy loading placeholder */
img.lazy {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Footer */
footer {
  background: var(--dark-color) !important;
}

.social-links a {
  transition: all 0.3s ease;
}

.social-links a:hover {
  transform: translateY(-3px);
}

/* Back to top button */
#backToTop {
  width: 50px;
  height: 50px;
  border-radius: 50% !important;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

#backToTop:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero-section {
    text-align: center;
    padding: 4rem 0;
  }
  
  .main-hero-img {
    transform: none;
    margin-top: 2rem;
  }
  
  .floating-card {
    position: relative;
    bottom: auto;
    right: auto;
    margin-top: 1rem;
  }
  
  .hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }
  
  .hero-buttons .btn {
    width: 100%;
  }
}

/* Animation Utilities */
.fade-in {
  opacity: 0;
  animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
  to { opacity: 1; }
}

.slide-up {
  transform: translateY(30px);
  opacity: 0;
  animation: slideUp 0.6s ease forwards;
}

@keyframes slideUp {
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: var(--secondary-color);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #d97706;
}

/* Print styles */
@media print {
  .navbar,
  footer,
  #backToTop,
  .hero-section {
    display: none !important;
  }
  
  body {
    font-size: 12pt;
    line-height: 1.4;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  :root {
    --primary-color: #000080;
    --secondary-color: #ff6600;
  }
  
  .hero-section {
    background: #000080 !important;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .scroll-indicator {
    animation: none;
  }
  
  .floating-card {
    animation: none;
  }
}