@keyframes fadeInUp {
  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 fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

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

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

@keyframes bounceIn {
  0% {
    opacity: 0;
    transform: scale(0.3);
  }
  50% {
    opacity: 1;
    transform: scale(1.05);
  }
  70% {
    transform: scale(0.9);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.4);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(220, 38, 38, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(220, 38, 38, 0);
  }
}

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

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

@keyframes fadeInChar {
  to {
    opacity: 1;
  }
}

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

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

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

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

/* Animation classes */
.animate-in {
  animation: fadeInUp 0.6s ease-out forwards;
}

.animate-in-left {
  animation: fadeInLeft 0.6s ease-out forwards;
}

.animate-in-right {
  animation: fadeInRight 0.6s ease-out forwards;
}

.animate-in-scale {
  animation: fadeInScale 0.6s ease-out forwards;
}

.animate-bounce {
  animation: bounceIn 0.8s ease-out forwards;
}

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

.animate-float {
  animation: float 3s ease-in-out infinite;
}

.animate-rotate {
  animation: rotate 2s linear infinite;
}

.animate-glow {
  animation: glow 2s ease-in-out infinite;
}

.animate-shimmer {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  background-size: 1000px 100%;
  animation: shimmer 2s infinite;
}

/* Stagger animations */
.stagger-item {
  opacity: 0;
  transform: translateY(30px);
}

.stagger-item.animate-in {
  opacity: 1;
  transform: translateY(0);
  transition: all 0.3s ease-out;
}

/* Fallback to ensure elements are visible after a delay */
.stagger-item {
  animation: fadeInFallback 0.3s ease-out 0.5s forwards;
}

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

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

.hover-lift:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.hover-scale {
  transition: transform 0.3s ease;
}

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

.hover-rotate {
  transition: transform 0.3s ease;
}

.hover-rotate:hover {
  transform: rotate(5deg);
}

.hover-glow {
  transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
  box-shadow: 0 0 20px rgba(220, 38, 38, 0.5);
}

/* Custom cursor */
.custom-cursor {
  position: fixed;
  width: 8px;
  height: 8px;
  background: var(--primary);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transition: transform 0.1s ease;
}

.cursor-follower {
  position: fixed;
  width: 30px;
  height: 30px;
  border: 1px solid var(--primary);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transition: transform 0.3s ease;
}

.custom-cursor.cursor-hover {
  transform: scale(2);
}

.cursor-follower.cursor-hover {
  transform: scale(1.5);
  background: rgba(220, 38, 38, 0.1);
}

/* Page transitions */
.page-transition {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease-out;
}

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

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border);
  border-top: 3px solid var(--primary);
  border-radius: 50%;
  animation: rotate 1s linear infinite;
}

/* Progress bars */
.progress-bar {
  height: 4px;
  background: var(--gradient-primary);
  border-radius: 2px;
  transition: width 2s ease-out;
}

.progress-container {
  width: 100%;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

/* Text effects */
.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-shadow {
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.text-glow {
  text-shadow: 0 0 10px rgba(220, 38, 38, 0.5);
}

/* Interactive elements */
.interactive-card {
  transition: all 0.3s ease;
  cursor: pointer;
}

.interactive-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.interactive-button {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.interactive-button::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transition: left 0.5s ease;
}

.interactive-button:hover::before {
  left: 100%;
}

/* Particle effects */
.particle-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
}

.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: var(--primary);
  border-radius: 50%;
  opacity: 0.3;
  animation: float 6s ease-in-out infinite;
}

/* Scroll indicators */
.scroll-indicator {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--border);
  z-index: 1000;
}

.scroll-progress {
  height: 100%;
  background: var(--gradient-primary);
  width: 0%;
  transition: width 0.1s ease;
}

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

@media (max-width: 768px) {
  .custom-cursor,
  .cursor-follower {
    display: none;
  }

  .hover-lift:hover {
    transform: translateY(-4px);
  }

  .interactive-card:hover {
    transform: translateY(-2px) scale(1.01);
  }
}

/* Performance optimizations */
.will-change-transform {
  will-change: transform;
}

.will-change-opacity {
  will-change: opacity;
}

.gpu-accelerated {
  transform: translateZ(0);
  backface-visibility: hidden;
  perspective: 1000px;
}

/* Special effects */
.neon-glow {
  box-shadow: 0 0 5px var(--primary), 0 0 10px var(--primary), 0 0 15px var(--primary), 0 0 20px var(--primary);
}

.glass-effect {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.holographic {
  background: linear-gradient(
    45deg,
    rgba(220, 38, 38, 0.1) 0%,
    rgba(239, 68, 68, 0.1) 25%,
    rgba(220, 38, 38, 0.1) 50%,
    rgba(239, 68, 68, 0.1) 75%,
    rgba(220, 38, 38, 0.1) 100%
  );
  background-size: 400% 400%;
  animation: holographic 4s ease-in-out infinite;
}

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