/* ============================================
   TIFESS - Animations & Effects
   Animasi-animasi indah dan dinamis untuk UI
   ============================================ */

/* Fade In Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Slide In From Left */
@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Slide In From Right */
@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Scale Up Animation */
@keyframes scaleUp {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Float Animation */
@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Heartbeat Animation */
@keyframes heartbeat {
  0%, 100% {
    transform: scale(1);
  }
  25% {
    transform: scale(1.1);
  }
  50% {
    transform: scale(1.2);
  }
  75% {
    transform: scale(1.1);
  }
}

/* Pulse Animation */
@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}

/* Glow Animation */
@keyframes glow {
  0%, 100% {
    box-shadow: 0 0 5px rgba(255, 79, 157, 0.3), inset 0 0 5px rgba(255, 79, 157, 0.1);
  }
  50% {
    box-shadow: 0 0 20px rgba(255, 79, 157, 0.6), inset 0 0 10px rgba(255, 79, 157, 0.2);
  }
}

/* Bounce Animation */
@keyframes bounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

/* Shimmer Animation */
@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

/* Heart Icon Animation */
@keyframes heartPulse {
  0%, 100% {
    transform: scale(1);
    color: #FF4F9D;
  }
  50% {
    transform: scale(1.2);
    color: #FF2F88;
  }
}

/* Rotate In */
@keyframes rotateIn {
  from {
    opacity: 0;
    transform: rotate(-10deg) scale(0.9);
  }
  to {
    opacity: 1;
    transform: rotate(0) scale(1);
  }
}

/* Swing Animation */
@keyframes swing {
  0%, 100% {
    transform: rotate(0deg);
  }
  25% {
    transform: rotate(5deg);
  }
  75% {
    transform: rotate(-5deg);
  }
}

/* Wiggle Animation */
@keyframes wiggle {
  0%, 100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-5px);
  }
  75% {
    transform: translateX(5px);
  }
}

/* Rainbow Gradient Animation */
@keyframes rainbowGradient {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* Smooth Transitions */
.fade-in {
  animation: fadeIn 0.6s ease-out;
}

.slide-in-left {
  animation: slideInLeft 0.6s ease-out;
}

.slide-in-right {
  animation: slideInRight 0.6s ease-out;
}

.scale-up {
  animation: scaleUp 0.6s ease-out;
}

.floating {
  animation: float 3s ease-in-out infinite;
}

.heartbeat {
  animation: heartbeat 0.8s ease-in-out infinite;
}

.pulse {
  animation: pulse 2s ease-in-out infinite;
}

.glowing {
  animation: glow 3s ease-in-out infinite;
}

.bounce-element {
  animation: bounce 1.5s ease-in-out infinite;
}

.shimmer-element {
  animation: shimmer 3s infinite;
  background-size: 1000px 100%;
}

.heart-pulse {
  animation: heartPulse 0.8s ease-in-out infinite;
}

.rotate-in {
  animation: rotateIn 0.6s ease-out;
}

.swing-element {
  animation: swing 1.5s ease-in-out infinite;
}

.wiggle-element {
  animation: wiggle 0.5s ease-in-out infinite;
}

/* Smooth Hover Effects */
.hover-lift {
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform, box-shadow;
}

.hover-lift:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 35px rgba(255, 79, 157, 0.35);
}

.hover-scale {
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform;
}

.hover-scale:hover {
  transform: scale(1.06);
}

.hover-glow {
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: box-shadow;
}

.hover-glow:hover {
  box-shadow: 0 0 25px rgba(255, 79, 157, 0.7);
}

.hover-pink {
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hover-pink:hover {
  color: #FF4F9D;
}

/* Stagger Animation for Lists */
.stagger-item {
  animation: fadeIn 0.6s ease-out;
}

.stagger-item:nth-child(1) { animation-delay: 0.1s; }
.stagger-item:nth-child(2) { animation-delay: 0.2s; }
.stagger-item:nth-child(3) { animation-delay: 0.3s; }
.stagger-item:nth-child(4) { animation-delay: 0.4s; }
.stagger-item:nth-child(5) { animation-delay: 0.5s; }
.stagger-item:nth-child(6) { animation-delay: 0.6s; }
.stagger-item:nth-child(n+7) { animation-delay: 0.7s; }

/* Smooth Transitions */
* {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Button Animations */
.btn {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
  width: 300px;
  height: 300px;
}

/* Form Input Animations */
.form-control {
  transition: all 0.3s ease;
  border-radius: 10px;
}

.form-control:focus {
  border-color: #FF4F9D !important;
  box-shadow: 0 0 0 0.2rem rgba(255, 79, 157, 0.25);
}

/* Navbar Animation */
.navbar {
  animation: slideInDown 0.6s ease-out;
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Card Animations */
.card {
  animation: fadeIn 0.6s ease-out;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform, box-shadow;
}

.card:hover {
  transform: translateY(-12px);
  box-shadow: 0 20px 40px rgba(255, 79, 157, 0.3);
}

/* Love Icon Animation */
.love-icon {
  animation: heartPulse 1s ease-in-out infinite;
}

/* Responsive Design */
@media (max-width: 768px) {
  .stagger-item:nth-child(n+3) { animation-delay: 0.3s; }
  
  .floating {
    animation: float 2s ease-in-out infinite;
  }
}
