/* Animation styles for the website */

/* General animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

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

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

/* Apply animations to elements */
.hero-content {
  animation: fadeIn 1.5s ease-out;
}

.hero-text h1 {
  animation: slideInUp 1s ease-out;
  animation-delay: 0.3s;
  animation-fill-mode: both;
}

.hero-text h2 {
  animation: slideInUp 1s ease-out;
  animation-delay: 0.5s;
  animation-fill-mode: both;
}

.hero-text p {
  animation: slideInUp 1s ease-out;
  animation-delay: 0.7s;
  animation-fill-mode: both;
}

.hero-cta {
  animation: slideInUp 1s ease-out;
  animation-delay: 0.9s;
  animation-fill-mode: both;
}

.section-title {
  animation: fadeIn 1s ease-out;
}

.about-text {
  animation: slideInLeft 1s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.about-image {
  animation: slideInRight 1s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.timeline-item {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
}

.timeline-item.animate {
  opacity: 1;
  transform: translateY(0);
}

.skills-category {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
}

.skills-category.animate {
  opacity: 1;
  transform: translateY(0);
}

.skills-image {
  animation: slideInLeft 1s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.skills-categories {
  animation: slideInRight 1s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.education-image {
  animation: slideInLeft 1s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.education-items {
  animation: slideInRight 1s ease-out;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.certification-item {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease-out;
}

.certification-item.animate {
  opacity: 1;
  transform: translateY(0);
}

.contact-content {
  animation: fadeIn 1.5s ease-out;
}

/* Hover animations */
.nav-links li a {
  position: relative;
  transition: color 0.3s ease;
}

.nav-links li a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.nav-links li a:hover::after {
  width: 100%;
}

.btn {
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.5s, height 0.5s;
}

.btn:hover::after {
  width: 300px;
  height: 300px;
}

.skills-list span, .competencies span {
  transition: all 0.3s ease;
}

.skills-list span:hover, .competencies span:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 82, 204, 0.2);
}

/* Animated background for hero section */
.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 82, 204, 0.6) 100%);
  animation: gradientShift 10s infinite alternate;
}

@keyframes gradientShift {
  0% {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 82, 204, 0.6) 100%);
  }
  50% {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 82, 204, 0.7) 100%);
  }
  100% {
    background: linear-gradient(135deg, rgba(0, 82, 204, 0.6) 0%, rgba(0, 0, 0, 0.8) 100%);
  }
}

/* Typing animation for hero subtitle */
.hero-text h2 {
  position: relative;
  display: inline-block;
}

.hero-text h2::after {
  content: '|';
  position: absolute;
  right: -10px;
  animation: blink 1s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* Floating animation for hero image */
.hero-image {
  animation: float 6s ease-in-out infinite;
}

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