﻿/* AgriPlan Global Custom Agricultural Styles & Animations */

/* 1. Fluid Multi-Axis Floating Animations */
@keyframes float1 {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-8px) rotate(0.5deg); }
}

@keyframes float2 {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(10px) rotate(-0.5deg); }
}

@keyframes float3 {
  0%, 100% { transform: translate(0px, 0px); }
  50% { transform: translate(-6px, -8px); }
}

@keyframes float4 {
  0%, 100% { transform: translate(0px, 0px); }
  50% { transform: translate(6px, -10px); }
}

.animate-float-1 {
  animation: float1 4.5s ease-in-out infinite;
}

.animate-float-2 {
  animation: float2 5.5s ease-in-out infinite 0.8s;
}

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

.animate-float-4 {
  animation: float4 5s ease-in-out infinite 2.2s;
}

/* 2. Aurora Ambient Background Glow */
@keyframes auroraGlow {
  0%, 100% {
    opacity: 0.4;
    transform: scale(1) translate(0px, 0px);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.15) translate(20px, -15px);
  }
}

.animate-aurora {
  animation: auroraGlow 8s ease-in-out infinite alternate;
}

.animate-aurora-delayed {
  animation: auroraGlow 10s ease-in-out infinite 3s alternate;
}

/* 3. Button Shimmer Light Sweep */
@keyframes shimmer {
  0% { transform: translateX(-150%); }
  100% { transform: translateX(150%); }
}

.btn-shimmer {
  position: relative;
  overflow: hidden;
}

.btn-shimmer::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    60deg,
    transparent 35%,
    rgba(255, 255, 255, 0.3) 50%,
    transparent 65%
  );
  transform: translateX(-150%);
  animation: shimmer 4s infinite 1.5s;
}

/* 4. Radar & Pulse Beacon */
@keyframes radarPulse {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

.radar-beacon {
  animation: radarPulse 2s infinite;
}

/* 5. Glassmorphism Card Hover Elevation */
.glass-telemetry-card {
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(16, 185, 129, 0.3);
  box-shadow: 0 12px 32px 0 rgba(0, 0, 0, 0.37), inset 0 1px 1px 0 rgba(255, 255, 255, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-telemetry-card:hover {
  border-color: rgba(52, 211, 153, 0.7);
  box-shadow: 0 20px 40px 0 rgba(16, 185, 129, 0.25), inset 0 1px 1px 0 rgba(255, 255, 255, 0.2);
  transform: translateY(-4px) scale(1.02);
}

/* Accessibility: Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .animate-float-1,
  .animate-float-2,
  .animate-float-3,
  .animate-float-4,
  .animate-aurora,
  .animate-aurora-delayed,
  .btn-shimmer::after,
  .radar-beacon {
    animation: none !important;
  }
  * {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Accessible focus ring */
:focus-visible {
  outline: 2px solid #059669;
  outline-offset: 2px;
}
