:root {
  --primary-color: #4e54c8;
  --secondary-color: #8f94fb;
  --text-color: #333;
  --light-color: #f8f9fa;
  --dark-color: #212529;
}

body {
  font-family: 'Poppins', sans-serif;
  color: var(--text-color);
  overflow-x: hidden;
  background-color: #f9f9f9;
}

/* Animated Background */
.animated-background {
  position: fixed;
  width: 100%;
  height: 100vh;
  top: 0;
  left: 0;
  z-index: -1;
  background: linear-gradient(45deg, var(--secondary-color), var(--primary-color));
  opacity: 0.02;
}

.circles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.circles li {
  position: absolute;
  display: block;
  list-style: none;
  width: 20px;
  height: 20px;
  background: rgba(255, 255, 255, 0.2);
  animation: animate 25s linear infinite;
  bottom: -150px;
  border-radius: 50%;
}

.circles li:nth-child(1) {
  left: 25%;
  width: 80px;
  height: 80px;
  animation-delay: 0s;
}

.circles li:nth-child(2) {
  left: 10%;
  width: 20px;
  height: 20px;
  animation-delay: 2s;
  animation-duration: 12s;
}

.circles li:nth-child(3) {
  left: 70%;
  width: 20px;
  height: 20px;
  animation-delay: 4s;
}

.circles li:nth-child(4) {
  left: 40%;
  width: 60px;
  height: 60px;
  animation-delay: 0s;
  animation-duration: 18s;
}

.circles li:nth-child(5) {
  left: 65%;
  width: 20px;
  height: 20px;
  animation-delay: 0s;
}

@keyframes animate {
  0% {
      transform: translateY(0) rotate(0deg);
      opacity: 1;
      border-radius: 0;
  }
  100% {
      transform: translateY(-1000px) rotate(720deg);
      opacity: 0;
      border-radius: 50%;
  }
}

/* Navigation */
.navbar {
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  padding: 15px 0;
}

.navbar-brand {
  font-weight: 700;
  color: var(--primary-color);
  font-size: 1.8rem;
}

.nav-link {
  font-weight: 500;
  color: var(--text-color);
  margin: 0 10px;
  transition: all 0.3s ease;
  position: relative;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary-color);
}

.nav-link:after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -5px;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.nav-link:hover:after, .nav-link.active:after {
  width: 100%;
}

/* Hero Section */
.hero-section {
  height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-top: 80px;
}

.hero-content {
  z-index: 1;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--dark-color);
  animation: fadeInUp 1s ease;
}

.hero-subtitle {
  font-size: 1.5rem;
  margin-bottom: 30px;
  color: var(--primary-color);
  animation: fadeInUp 1s ease 0.2s;
  animation-fill-mode: both;
}

.hero-text {
  font-size: 1.1rem;
  margin-bottom: 30px;
  max-width: 600px;
  animation: fadeInUp 1s ease 0.4s;
  animation-fill-mode: both;
}

.hero-social {
  animation: fadeInUp 1s ease 0.6s;
  animation-fill-mode: both;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: white;
  color: var(--primary-color);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  text-decoration: none;
}

.social-icon:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-3px);
}

.hero-img {
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
  transition: all 0.5s ease;
  border: 5px solid white;
  animation: floatImage 6s ease-in-out infinite;
}

.hero-img:hover {
  border-radius: 50% 50% 50% 50% / 50% 50% 50% 50%;
}

@keyframes floatImage {
  0% {
      transform: translateY(0);
  }
  50% {
      transform: translateY(-15px);
  }
  100% {
      transform: translateY(0);
  }
}

@keyframes fadeInUp {
  from {
      opacity: 0;
      transform: translateY(20px);
  }
  to {
      opacity: 1;
      transform: translateY(0);
  }
}

.btn-custom {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  border: none;
  color: white;
  padding: 12px 30px;
  border-radius: 50px;
  font-weight: 500;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(78, 84, 200, 0.3);
  animation: fadeInUp 1s ease 0.8s;
  animation-fill-mode: both;
}

.btn-custom:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(78, 84, 200, 0.4);
}

/* Section Styling */
.section {
  padding: 100px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 60px;
  position: relative;
}

.section-title h2 {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--dark-color);
}

.section-title:after {
  content: '';
  position: absolute;
  width: 100px;
  height: 4px;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 2px;
}

/* Skills Section */
.skill-item {
  background-color: white;
  border-radius: 15px;
  padding: 20px;
  margin-bottom: 30px;
  transition: all 0.3s ease;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  height: 100%;
  text-align: center;
}

.skill-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.skill-icon {
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  color: white;
  border-radius: 50%;
  font-size: 1.8rem;
  margin: 0 auto 20px;
}

.skill-level {
  display: inline-block;
  padding: 5px 15px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 500;
  color: white;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
}

/* Projects Section */
.project-card {
  border-radius: 15px;
  overflow: hidden;
  margin-bottom: 30px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 100%;
  background-color: white;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.project-img {
  height: 200px;
  object-fit: cover;
  width: 100%;
}

.project-content {
  padding: 20px;
}

.project-tech {
  margin: 15px 0;
}

.tech-tag {
  display: inline-block;
  padding: 5px 15px;
  background-color: #e9ecef;
  color: var(--text-color);
  border-radius: 50px;
  font-size: 0.8rem;
  margin-right: 5px;
  margin-bottom: 5px;
}

.project-links a {
  color: var(--primary-color);
  margin-right: 15px;
  transition: all 0.3s ease;
}

.project-links a:hover {
  color: var(--secondary-color);
}

/* Experience Section */
.timeline {
  position: relative;
  margin: 30px 0;
}

.timeline:before {
  content: '';
  position: absolute;
  width: 4px;
  background: linear-gradient(var(--primary-color), var(--secondary-color));
  top: 0;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 2px;
}

.timeline-item {
  padding: 20px 0;
  position: relative;
}

.timeline-item:nth-child(odd) .timeline-content {
  margin-left: auto;
  text-align: right;
}

.timeline-content {
  width: 45%;
  background-color: white;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.timeline-dot {
  width: 20px;
  height: 20px;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  border-radius: 50%;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
}

.timeline-date {
  color: var(--primary-color);
  font-weight: 500;
  margin: 10px 0;
}

/* Contact Section */
.contact-info {
  background-color: white;
  border-radius: 15px;
  padding: 30px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  height: 100%;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 20px;
}

.contact-item .icon {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  color: white;
  border-radius: 50%;
  font-size: 1.2rem;
  margin-right: 20px;
}

.contact-form {
  background-color: white;
  border-radius: 15px;
  padding: 30px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  height: 100%;
}

.form-control {
  border-radius: 50px;
  padding: 12px 20px;
  font-size: 1rem;
  border: 1px solid #e9ecef;
  margin-bottom: 15px;
}

.form-control:focus {
  box-shadow: none;
  border-color: var(--primary-color);
}

textarea.form-control {
  border-radius: 20px;
}

/* Footer */
.footer {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  color: white;
  padding: 30px 0;
}

.footer-social a {
  color: white;
  margin: 0 10px;
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.footer-social a:hover {
  transform: translateY(-3px);
}

/* Responsive */
@media (max-width: 991px) {
  .hero-section {
      height: auto;
      padding: 120px 0 60px;
  }
  
  .hero-content {
      text-align: center;
      margin-bottom: 40px;
  }
  
  .hero-text {
      margin: 0 auto 30px;
  }
  
  .timeline:before {
      left: 20px;
  }
  
  .timeline-content {
      width: calc(100% - 60px);
      margin-left: 60px !important;
      text-align: left !important;
  }
  
  .timeline-dot {
      left: 20px;
  }
  
  .timeline-date {
      position: relative;
      top: auto;
      left: auto;
      transform: none;
  }
}

@media (max-width: 767px) {
  .hero-title {
      font-size: 2.5rem;
  }
  
  .hero-subtitle {
      font-size: 1.2rem;
  }
  
  .section {
      padding: 70px 0;
  }
  
  .section-title h2 {
        font-size: 2rem;
    }
    
  .contact-item {
        flex-direction: column;
    }
    
  .contact-item .icon {
        margin-bottom: 15px;
        margin-right: 0;
    }
    
  .contact-text {
        text-align: center;
    }
}

/* Animation Keyframes */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        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;
    }
}

@keyframes zoomIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Add hover effects */
.project-card .project-img {
    transition: transform 0.5s ease;
}

.project-card:hover .project-img {
    transform: scale(1.05);
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Typing effect for hero subtitle */
.typed-text::after {
    content: '|';
    animation: blink 0.7s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Tooltip styles */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 120px;
    background-color: var(--dark-color);
    color: white;
    text-align: center;
    padding: 5px;
    border-radius: 6px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -60px;
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

/* Back to top button */
.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 99;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-3px);
}
     