/* Enterprise-Grade CSS for Nuvrise IT Solutions */

/* ===== RESET & BASE STYLES ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  line-height: 1.6;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
img {
  max-width: 100%;
  height: auto;
  display: block;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  opacity: 1;
}

/* Hardware acceleration for smooth animations */
.will-change-transform {
  will-change: transform;
  transform: translateZ(0);
}

/* ===== ADVANCED ANIMATIONS ===== */
@keyframes float {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  33% {
    transform: translateY(-20px) rotate(1deg);
  }
  66% {
    transform: translateY(-10px) rotate(-1deg);
  }
}

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

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

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

@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

@keyframes gradient-shift {
  0%, 100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@keyframes buttonRipple {
  0% {
    transform: scale(0);
    opacity: 1;
  }
  100% {
    transform: scale(4);
    opacity: 0;
  }
}

@keyframes glow {
  0%, 100% {
    box-shadow: 0 0 5px rgba(30, 64, 175, 0.5);
  }
  50% {
    box-shadow: 0 0 20px rgba(30, 64, 175, 0.8);
  }
}

/* ===== SCROLL ANIMATION CLASSES ===== */
.fade-in-up {
  opacity: 1 !important;
  transform: translateY(0px) !important;
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-left {
  opacity: 1 !important;
  transform: translateX(0px) !important;
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-right {
  opacity: 1 !important;
  transform: translateX(0px) !important;
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.scale-in {
  opacity: 0.1;
  transform: scale(0.95);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-up.visible,
.fade-in-left.visible,
.fade-in-right.visible,
.scale-in.visible {
  opacity: 1;
  transform: translate(0) scale(1);
}

/* Fallback - show content after 2 seconds if JS fails */
.fade-in-up,
.fade-in-left,
.fade-in-right,
.scale-in {
  animation: showContent 0.1s ease 2s forwards;
}

@keyframes showContent {
  to {
    opacity: 1;
    transform: translate(0) scale(1);
  }
}

/* Staggered animations */
.stagger-animation > * {
  opacity: 0.2;
  transform: translateY(20px);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.stagger-animation.visible > *:nth-child(1) { transition-delay: 0.05s; }
.stagger-animation.visible > *:nth-child(2) { transition-delay: 0.1s; }
.stagger-animation.visible > *:nth-child(3) { transition-delay: 0.15s; }
.stagger-animation.visible > *:nth-child(4) { transition-delay: 0.2s; }
.stagger-animation.visible > *:nth-child(5) { transition-delay: 0.25s; }
.stagger-animation.visible > *:nth-child(6) { transition-delay: 0.3s; }

.stagger-animation.visible > * {
  opacity: 1;
  transform: translateY(0);
}

/* Fallback for stagger animation */
.stagger-animation > * {
  animation: showStaggerContent 0.1s ease 1.5s forwards;
}

@keyframes showStaggerContent {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== NAVIGATION ENHANCEMENTS ===== */
header {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.3);
}

header.scrolled {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* Navigation link hover effects */
nav a {
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #1e40af, #3b82f6);
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

nav a:hover::after {
  width: 100%;
}

/* ===== HERO SECTION ENHANCEMENTS ===== */
#home {
  position: relative;
  background: linear-gradient(135deg, #f8fafc 0%, #ffffff 25%, #eff6ff 100%);
  background-size: 400% 400%;
  animation: gradient-shift 15s ease infinite;
}

/* Parallax background elements */
.parallax-element {
  transform: translateZ(0);
  will-change: transform;
}

/* Advanced gradient text effect */
.gradient-text {
  background: linear-gradient(135deg, #1e40af 0%, #3b82f6 50%, #06b6d4 100%);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 8s ease infinite;
}

/* ===== BUTTON ENHANCEMENTS ===== */
.btn-primary {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
  background-size: 200% 200%;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px rgba(30, 64, 175, 0.3);
}

.btn-primary::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-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.4);
  background-position: 100% 0;
}

/* Secondary button with glass morphism */
.btn-secondary {
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* ===== CARD ENHANCEMENTS ===== */
.service-card {
  position: relative;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 20px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(30, 64, 175, 0.02) 0%, rgba(59, 130, 246, 0.02) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.service-card:hover::before {
  opacity: 1;
}

.service-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  border-color: rgba(30, 64, 175, 0.2);
}

/* Icon container animations */
.icon-container {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.icon-container::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover .icon-container::after {
  width: 100%;
  height: 100%;
}

/* ===== STATISTICS SECTION ===== */
.stats-section {
  background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 50%, #3b82f6 100%);
  position: relative;
  overflow: hidden;
}

.stats-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
  opacity: 0.3;
}

.counter {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-variant-numeric: tabular-nums;
}

.counter:hover {
  transform: scale(1.1);
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
}

/* ===== FORM ENHANCEMENTS ===== */
.form-input {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(229, 231, 235, 0.5);
}

.form-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
  background: rgba(255, 255, 255, 0.95);
  transform: translateY(-1px);
}

.form-input:focus + label {
  color: #1e40af;
  transform: translateY(-2px);
}

/* ===== TESTIMONIAL CARDS ===== */
.testimonial-card {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.testimonial-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #1e40af, #3b82f6, #06b6d4);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

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

.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

/* ===== PORTFOLIO GRID ===== */
.portfolio-item {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(30, 64, 175, 0.8), rgba(59, 130, 246, 0.6));
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 2;
}

.portfolio-item:hover::before {
  opacity: 1;
}

.portfolio-item:hover {
  transform: scale(1.05);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

.portfolio-item img {
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-item:hover img {
  transform: scale(1.1);
}

/* ===== LOADING STATES ===== */
.loading {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 2s infinite;
}

.btn-loading {
  position: relative;
  pointer-events: none;
}

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

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

/* ===== RIPPLE EFFECT ===== */
.ripple {
  position: relative;
  overflow: hidden;
}

.ripple::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.6);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.ripple:active::before {
  width: 300px;
  height: 300px;
  transition: 0s;
}

/* ===== TEXT ANIMATIONS ===== */
.typewriter {
  overflow: hidden;
  border-right: 3px solid #1e40af;
  white-space: nowrap;
  animation: typewriter 3s steps(30) 1s 1 normal both,
             blinkCursor 500ms steps(30) infinite normal;
}

@keyframes typewriter {
  from { width: 0; }
  to { width: 100%; }
}

@keyframes blinkCursor {
  from { border-right-color: #1e40af; }
  to { border-right-color: transparent; }
}

/* ===== RIPPLE EFFECT CSS ===== */
.ripple-effect {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.6);
  transform: scale(0);
  animation: ripple 0.6s linear;
  pointer-events: none;
}

@keyframes ripple {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

/* ===== SCROLL INDICATORS ===== */
.scroll-indicator {
  animation: bounce 2s infinite;
}

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

@keyframes wiggle {
  0%, 7% {
    transform: rotateZ(0);
  }
  15% {
    transform: rotateZ(-15deg);
  }
  20% {
    transform: rotateZ(10deg);
  }
  25% {
    transform: rotateZ(-10deg);
  }
  30% {
    transform: rotateZ(6deg);
  }
  35% {
    transform: rotateZ(-4deg);
  }
  40%, 100% {
    transform: rotateZ(0);
  }
}

.animate-wiggle:hover {
  animation: wiggle 0.8s ease-in-out;
}

/* ===== ENHANCED BUTTON STYLES ===== */
.btn-primary {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1e40af, #3b82f6);
  border: none;
  border-radius: 12px;
  padding: 16px 32px;
  font-weight: 600;
  font-size: 16px;
  color: white;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateY(0);
  box-shadow: 0 4px 15px rgba(30, 64, 175, 0.3);
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.4);
  background: linear-gradient(135deg, #1d4ed8, #2563eb);
}

.btn-primary:hover::before {
  width: 300px;
  height: 300px;
}

.btn-primary:active {
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(30, 64, 175, 0.6);
}

.btn-secondary {
  position: relative;
  background: transparent;
  border: 2px solid #1e40af;
  color: #1e40af;
  padding: 14px 30px;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.btn-secondary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #1e40af, #3b82f6);
  transition: left 0.3s ease;
  z-index: -1;
}

.btn-secondary:hover {
  color: white;
  border-color: #1e40af;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(30, 64, 175, 0.3);
}

.btn-secondary:hover::before {
  left: 0;
}

/* ===== BACK TO TOP BUTTON ===== */
#back-to-top {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: linear-gradient(135deg, #1e40af, #3b82f6);
  box-shadow: 0 4px 15px rgba(30, 64, 175, 0.3);
  border-radius: 50%;
  position: relative;
  overflow: hidden;
}

#back-to-top::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.4s, height 0.4s;
}

#back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  animation: fadeIn 0.5s ease;
}

#back-to-top:hover {
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.4);
  animation: glow 2s infinite;
}

#back-to-top:hover::before {
  width: 60px;
  height: 60px;
}

/* ===== SERVICE CARD ANIMATIONS ===== */
.service-card:hover {
  animation: pulse 0.6s ease-in-out;
}

/* ===== FLOATING ELEMENTS ===== */
.animate-float {
  animation: float 6s ease-in-out infinite;
}

.animate-float:nth-child(2) {
  animation-delay: -2s;
}

.animate-float:nth-child(3) {
  animation-delay: -4s;
}

/* ===== MOBILE MENU ANIMATIONS ===== */
#mobile-menu {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(229, 231, 235, 0.3);
  border-bottom: 1px solid rgba(229, 231, 235, 0.3);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

#mobile-menu.hidden {
  opacity: 0;
  transform: translateY(-20px);
  pointer-events: none;
  display: none !important;
}

#mobile-menu:not(.hidden) {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  display: block !important;
}

/* ===== FOOTER ENHANCEMENTS ===== */
footer {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  position: relative;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="dots" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="rgba(59,130,246,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23dots)"/></svg>');
  opacity: 0.5;
}

/* ===== ENHANCED SOCIAL ICONS ===== */
.social-icon {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.social-icon::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, #1e40af, #3b82f6);
  transform: scale(0) rotate(180deg);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: inherit;
}

.social-icon:hover {
  transform: translateY(-3px) rotate(5deg);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.4);
}

.social-icon:hover::before {
  transform: scale(1) rotate(0deg);
}

.social-icon i {
  position: relative;
  z-index: 2;
  transition: all 0.3s ease;
}

.social-icon:hover i {
  transform: scale(1.2);
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* ===== LINK HOVER EFFECTS ===== */
a:not(.btn-primary):not(.btn-secondary):not(.social-icon) {
  position: relative;
  transition: all 0.3s ease;
}

a:not(.btn-primary):not(.btn-secondary):not(.social-icon):hover {
  transform: translateX(3px);
}

a:not(.btn-primary):not(.btn-secondary):not(.social-icon)::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #1e40af, #3b82f6);
  transition: width 0.3s ease;
}

a:not(.btn-primary):not(.btn-secondary):not(.social-icon):hover::after {
  width: 100%;
}

/* ===== SECTION-BASED ANIMATIONS ===== */
.section-enter {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.section-enter.visible {
  opacity: 1;
  transform: translateY(0);
}

.card-hover {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.card-hover:hover {
  transform: translateY(-5px) scale(1.01);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

/* ===== RESPONSIVE DESIGN ENHANCEMENTS ===== */
/* ===== RESPONSIVE TYPOGRAPHY FIXES ===== */
@media (max-width: 768px) {
  .hero-title {
    font-size: 2.5rem;
    line-height: 1.2;
  }
  
  /* Fix hero heading sizes for mobile */
  .hero-slide h1 {
    font-size: 2rem !important;
    line-height: 1.2 !important;
  }
  
  /* Fix button sizes on mobile */
  .hero-slide .flex.flex-col a,
  .hero-slide .flex.sm\:flex-row a {
    padding: 0.5rem 1rem !important;
    font-size: 0.9rem !important;
    text-align: center;
    width: 100%;
  }
  
  /* Stack buttons vertically on mobile */
  .hero-slide .flex.sm\:flex-row {
    flex-direction: column !important;
    gap: 0.5rem !important;
  }
  
  .service-card {
    margin-bottom: 1rem;
  }
  
  .portfolio-item {
    margin-bottom: 1.5rem;
  }
}

/* ===== MOBILE LAYOUT FIXES ===== */
@media (max-width: 640px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  
  /* Fix hero section padding and spacing */
  .hero-slide .container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  /* Fix grid spacing on mobile */
  .hero-slide .grid {
    gap: 0.5rem !important;
    padding: 0.75rem 0 !important;
  }
  
  /* Fix image height on mobile */
  .hero-slide img {
    height: 250px !important;
    max-height: 250px !important;
  }
  
  /* Fix heading sizes for very small screens */
  .hero-slide h1 {
    font-size: 1.75rem !important;
  }
  
  /* Fix text sizes */
  .hero-slide p {
    font-size: 0.9rem !important;
    line-height: 1.5 !important;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
}

/* ===== ACCESSIBILITY ENHANCEMENTS ===== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  html {
    scroll-behavior: auto;
  }
}

@media (prefers-contrast: high) {
  .service-card {
    border: 2px solid #000;
  }
  
  .btn-primary {
    border: 2px solid #000;
  }
}

/* ===== PRINT STYLES ===== */
@media print {
  .no-print,
  header,
  footer,
  #back-to-top {
    display: none !important;
  }
  
  body {
    background: white !important;
    color: black !important;
  }
  
  .service-card,
  .testimonial-card {
    border: 1px solid #000 !important;
    background: white !important;
  }
}

/* ===== DARK MODE SUPPORT ===== */
@media (prefers-color-scheme: dark) {
  :root {
    --text-primary: #ffffff;
    --text-secondary: #e5e7eb;
    --bg-primary: #111827;
    --bg-secondary: #1f2937;
  }
}

/* ===== ANIMATED BLUR BACKGROUNDS ===== */
.blur-bg-container {
  position: relative;
  overflow: hidden;
}

.blur-bg-element {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.4;
  animation: float 10s ease-in-out infinite;
  z-index: -1;
}

.blur-bg-blue {
  background: linear-gradient(135deg, #3b82f6, #1e40af);
  top: -20%;
  left: -10%;
  width: 300px;
  height: 300px;
  animation-delay: 0s;
}

.blur-bg-green {
  background: linear-gradient(135deg, #22c55e, #15803d);
  top: 20%;
  right: -10%;
  width: 250px;
  height: 250px;
  animation-delay: 2s;
}

.blur-bg-purple {
  background: linear-gradient(135deg, #9333ea, #6b21a8);
  bottom: -20%;
  left: 10%;
  width: 280px;
  height: 280px;
  animation-delay: 4s;
}

.blur-bg-orange {
  background: linear-gradient(135deg, #fb923c, #ea580c);
  bottom: 10%;
  right: 20%;
  width: 200px;
  height: 200px;
  animation-delay: 6s;
}

.blur-bg-yellow {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  top: 60%;
  left: 70%;
  width: 220px;
  height: 220px;
  animation-delay: 8s;
}

.blur-bg-indigo {
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  bottom: 50%;
  right: 5%;
  width: 180px;
  height: 180px;
  animation-delay: 10s;
}

.blur-bg-rose {
  background: linear-gradient(135deg, #f43f5e, #e11d48);
  top: 30%;
  left: 30%;
  width: 240px;
  height: 240px;
  animation-delay: 12s;
}

/* ===== CUSTOM UTILITIES ===== */
.text-shadow {
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.backdrop-blur-custom {
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* ===== GLASSMORPHISM EFFECTS ===== */
.glass-effect {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-blue {
  background: rgba(59, 130, 246, 0.15);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(59, 130, 246, 0.2);
}

.glass-green {
  background: rgba(34, 197, 94, 0.15);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(34, 197, 94, 0.2);
}

.glass-purple {
  background: rgba(147, 51, 234, 0.15);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(147, 51, 234, 0.3);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(147, 51, 234, 0.2);
}

.glass-orange {
  background: rgba(251, 146, 60, 0.15);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(251, 146, 60, 0.3);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(251, 146, 60, 0.2);
}

.glass-pink {
  background: rgba(236, 72, 153, 0.15);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(236, 72, 153, 0.3);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(236, 72, 153, 0.2);
}

.glass-cyan {
  background: rgba(6, 182, 212, 0.15);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(6, 182, 212, 0.2);
}

.gradient-border {
  position: relative;
  background: linear-gradient(45deg, #1e40af, #3b82f6, #06b6d4);
  padding: 2px;
  border-radius: 12px;
}

.gradient-border::before {
  content: '';
  position: absolute;
  inset: 2px;
  background: white;
  border-radius: 10px;
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
.gpu-accelerated {
  transform: translateZ(0);
  will-change: transform;
}

.optimize-animation {
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
  perspective: 1000px;
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(241, 245, 249, 0.5);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, #1e40af, #3b82f6);
  border-radius: 4px;
  transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(135deg, #1d4ed8, #2563eb);
}

/* Firefox scrollbar */
html {
  scrollbar-width: thin;
  scrollbar-color: #1e40af rgba(241, 245, 249, 0.5);
}

/* ===== INTERSECTION OBSERVER ANIMATIONS ===== */
.fade-in-up {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-left {
  opacity: 0;
  transform: translateX(-30px);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.fade-in-right {
  opacity: 0;
  transform: translateX(30px);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

.scale-in {
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.scale-in.visible {
  opacity: 1;
  transform: scale(1);
}

/* ===== HERO IMAGE SLIDER ===== */
.slider-container {
  position: relative;
  width: 100%;
  height: auto;
  overflow: hidden;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateX(100%);
  pointer-events: none;
}

.slide.active {
  opacity: 1;
  transform: translateX(0);
  position: relative;
  pointer-events: auto;
}

.slide img {
  opacity: 1 !important;
}

.slide.prev {
  transform: translateX(-100%);
}

.slide img {
  width: 100%;
  height: auto;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.slide:hover img {
  transform: scale(1.05);
}

/* Slider Navigation Dots */
.slider-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  border: 2px solid rgba(255, 255, 255, 0.6);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.slider-dot::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: #1e40af;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.3s ease;
}

.slider-dot.active {
  background: #1e40af;
  border-color: #1e40af;
  transform: scale(1.2);
}

.slider-dot.active::before {
  width: 100%;
  height: 100%;
}

.slider-dot:hover {
  background: rgba(30, 64, 175, 0.7);
  border-color: #1e40af;
  transform: scale(1.1);
}

/* Slider Navigation Arrows */
.slider-prev,
.slider-next {
  cursor: pointer;
  z-index: 10;
  opacity: 0.8;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.slider-prev:hover,
.slider-next:hover {
  opacity: 1;
  background: white;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.slider-prev:active,
.slider-next:active {
  transform: translateY(-50%) scale(0.95);
}

/* Slide Labels */
.slide .bg-white\/90 {
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.slide:hover .bg-white\/90 {
  background: rgba(255, 255, 255, 0.95);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Auto-slide animation */
@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideOut {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(-100%);
    opacity: 0;
  }
}

.slide.slide-in {
  animation: slideIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.slide.slide-out {
  animation: slideOut 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Responsive slider adjustments */
@media (max-width: 768px) {
  .slider-prev,
  .slider-next {
    width: 40px;
    height: 40px;
  }
  
  .slider-dot {
    width: 10px;
    height: 10px;
  }
  
  .slide .bg-white\/90 {
    bottom: 2px;
    left: 2px;
    font-size: 0.75rem;
    padding: 8px 12px;
  }
}

@media (max-width: 640px) {
  .slider-prev,
  .slider-next {
    width: 35px;
    height: 35px;
  }
  
  .slider-prev {
    left: 2px;
  }
  
  .slider-next {
    right: 2px;
  }
}

/* ===== HERO SLIDER STYLES (PRIORITY) ===== */
.hero-slider {
  position: relative !important;
  width: 100% !important;
  min-height: 100vh !important;
  display: block !important;
  overflow: hidden !important;
}

.hero-slide {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  min-height: 100vh !important;
  display: flex !important;
  align-items: center !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transform: translateX(100%) !important;
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
}

.hero-slide.active {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateX(0) !important;
}

.hero-slide.slide-out-left {
  transform: translateX(-100%) !important;
  opacity: 0 !important;
}

.hero-slide.prev {
  transform: translateX(-100%);
  opacity: 0;
}

.hero-slide.next {
  transform: translateX(100%);
  opacity: 0;
}

.hero-slider-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  backdrop-filter: blur(4px);
}

.hero-slider-dot::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: transparent;
  transition: all 0.3s ease;
}

.hero-slider-dot.active {
  background: rgba(255, 255, 255, 0.8);
}

.hero-slider-dot.active::before {
  background: #1e40af;
}

.hero-slider-dot:hover {
  background: rgba(255, 255, 255, 0.6);
  transform: scale(1.2);
}

.hero-slider-prev,
.hero-slider-next {
  background: rgba(255, 255, 255, 0.9);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.hero-slider-prev:hover,
.hero-slider-next:hover {
  background: rgba(255, 255, 255, 1);
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.hero-slider-prev:active,
.hero-slider-next:active {
  transform: scale(0.95);
}

/* Hero slide transitions */
.hero-slide.slide-in {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
  z-index: 2;
}

.hero-slide.slide-out {
  opacity: 0;
  visibility: hidden;
  transform: translateX(-100%);
  z-index: 1;
}

/* Hero slider responsive styles */
@media (max-width: 768px) {
  .hero-slider {
    height: 100vh !important;
    min-height: 100vh !important;
  }
  
  .hero-slide {
    padding: 0 !important;
    min-height: 100vh !important;
    height: auto !important;
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
    align-items: center !important;
  }
  
  /* Fix mobile navigation */
  #mobile-menu {
    max-height: 70vh;
    overflow-y: auto;
  }
  
  /* Improve mobile button touch targets */
  #mobile-menu a {
    min-height: 44px;
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    margin: 0.25rem 0;
    border-radius: 0.5rem;
    transition: background-color 0.2s ease;
  }
  
  #mobile-menu a:hover {
    background-color: rgba(30, 64, 175, 0.05);
  }
  
  /* Fix mobile menu button */
  #mobile-menu-btn {
    padding: 0.5rem;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
  }
  
  #mobile-menu-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
  }
  
  .hero-slide .container {
    padding: 0 1rem;
    height: 100%;
  }
  
  .hero-slide .grid {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 1.5rem 0;
    min-height: 70vh;
    align-items: center;
  }
  
  .hero-slide .space-y-8 {
    gap: 1rem;
  }
  
  .hero-slide img {
    height: 300px !important;
    object-fit: contain;
    border-radius: 1rem;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }
  
  .hero-slide h1 {
    font-size: 2.25rem;
    line-height: 1.1;
    margin-bottom: 1rem;
  }
  
  .hero-slide p {
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 1.5rem;
  }
  
  .hero-slide .flex.flex-col {
    gap: 0.75rem;
  }
  
  .hero-slide button {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
  }
  
  .hero-slider-prev,
  .hero-slider-next {
    width: 44px;
    height: 44px;
    font-size: 16px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
  }

  .hero-slider-dot {
    width: 12px;
    height: 12px;
  }
  
  /* Navigation positioning */
  .hero-slider-prev {
    left: 8px;
  }
  
  .hero-slider-next {
    right: 8px;
  }
  
  /* Trust indicators responsive */
  .hero-slide .border-t {
    padding-top: 0.75rem;
    margin-top: 0.75rem;
  }
  
  .hero-slide .text-2xl {
    font-size: 1.5rem;
  }
}

@media (max-width: 480px) {
  .hero-slide {
    height: 100vh;
  }
  
  .hero-slide .container {
    padding: 0 0.75rem;
  }
  
  .hero-slide .grid {
    padding: 1rem 0;
    gap: 0.75rem;
    min-height: 60vh;
  }
  
  .hero-slide img {
    height: 250px !important;
    object-fit: contain;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
  }
  
  .hero-slide h1 {
    font-size: 1.875rem;
    line-height: 1.1;
    text-align: center;
  }
  
  .hero-slide p {
    font-size: 0.9rem;
    text-align: center;
    max-width: 100%;
  }
  
  .hero-slide .space-y-8 {
    text-align: center;
    gap: 1rem;
  }
  
  .hero-slide .flex.flex-col {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }
  
  .hero-slide button {
    width: 100%;
    max-width: 280px;
    padding: 0.875rem 1rem;
    font-size: 0.9rem;
  }
  
  .hero-slider-prev {
    left: 4px;
    width: 40px;
    height: 40px;
    font-size: 14px;
  }

  .hero-slider-next {
    right: 4px;
    width: 40px;
    height: 40px;
    font-size: 14px;
  }
  
  .hero-slider-dot {
    width: 10px;
    height: 10px;
  }
  
  /* Adjust text sizes */
  .hero-slide .text-xl {
    font-size: 0.9rem;
  }
  
  .hero-slide .text-sm {
    font-size: 0.8rem;
  }
  
  .hero-slide .text-2xl {
    font-size: 1.25rem;
  }
  
  /* Floating elements responsive */
  .hero-slide .absolute.top-10 {
    display: none;
  }
  
  .hero-slide .absolute.-bottom-6,
  .hero-slide .absolute.top-6 {
    opacity: 0.3;
  }
}

/* ===== EXTRA SMALL SCREEN FIXES ===== */
@media (max-width: 480px) {
  .hero-slide {
    min-height: 100vh !important;
    height: auto !important;
    padding: 1rem 0 !important;
  }
  
  .hero-slide .container {
    padding: 0 0.75rem !important;
    height: auto !important;
  }
  
  /* Ultra-mobile typography */
  .hero-slide h1 {
    font-size: 1.5rem !important;
    line-height: 1.3 !important;
  }
  
  .hero-slide h1 span {
    font-size: 1.5rem !important;
  }
  
  /* Compact buttons for small screens */
  .hero-slide .flex.flex-col a {
    padding: 0.625rem 1rem !important;
    font-size: 0.85rem !important;
  }
  
  /* Adjust trust indicators */
  .hero-slide .border-t {
    padding-top: 1rem !important;
  }
  
  .hero-slide .flex.flex-col.sm\\:flex-row {
    flex-direction: column !important;
    gap: 0.5rem !important;
  }
}
