/* ============================================
   Krishna Digital Marketing - Animations CSS
   ============================================ */

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

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-30px); }
  to { opacity: 1; transform: translateY(0); }
}

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

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

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

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

@keyframes floatUpDown {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-15px); }
}

@keyframes rotateSlow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

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

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

@keyframes loaderBounce {
  from { transform: translateY(0); }
  to { transform: translateY(-10px); }
}

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

@keyframes blink {
  0%, 100% { border-color: var(--primary); }
  50% { border-color: transparent; }
}

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

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

@keyframes morphBg {
  0%, 100% { border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%; }
  50% { border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%; }
}

/* --- Utility Animation Classes --- */
.anim-fade-in { animation: fadeIn 0.6s ease both; }
.anim-fade-up { animation: fadeInUp 0.6s ease both; }
.anim-fade-down { animation: fadeInDown 0.6s ease both; }
.anim-fade-left { animation: fadeInLeft 0.6s ease both; }
.anim-fade-right { animation: fadeInRight 0.6s ease both; }
.anim-scale-in { animation: scaleIn 0.6s ease both; }
.anim-float { animation: floatUpDown 6s ease-in-out infinite; }
.anim-pulse { animation: pulse 2s ease-in-out infinite; }
.anim-morph { animation: morphBg 8s ease-in-out infinite; }

/* Stagger delays */
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.5s; }
.delay-6 { animation-delay: 0.6s; }

/* Scroll Progress */
.scroll-progress { will-change: width; }

/* Smooth transitions for interactive elements */
.service-card,
.industry-card,
.portfolio-card,
.blog-card,
.highlight-card,
.stat-card,
.testimonial-card,
.faq-item {
  will-change: transform, box-shadow;
}

/* Parallax helper */
.parallax-bg {
  will-change: transform;
}

/* Hover lift */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-xl);
}

/* Image zoom on hover */
.img-zoom {
  overflow: hidden;
}

.img-zoom img,
.img-zoom .placeholder {
  transition: transform 0.5s ease;
}

.img-zoom:hover img,
.img-zoom:hover .placeholder {
  transform: scale(1.08);
}

/* Button ripple effect */
.btn-ripple {
  position: relative;
  overflow: hidden;
}

.btn-ripple .ripple-circle {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.35);
  transform: scale(0);
  animation: ripple 0.6s linear;
  pointer-events: none;
}

/* Typing effect cursor */
.typing-cursor::after {
  content: '|';
  animation: blink 0.8s step-end infinite;
  color: var(--primary);
  font-weight: 300;
}

/* Parallax sections */
.parallax-section {
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
