/* Google Font - Modern sans-serif combination */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700&family=Raleway:wght@300;400;600;700&display=swap');

/* CSS Reset & General Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --primary: #4361ee;
  --secondary: #3a0ca3;
  --accent: #4cc9f0;
  --dark: #111827;  
  --light: #f8fafc;   
  --gray: #94a3b8;
  --gradient: linear-gradient(135deg, var(--primary), var(--secondary));
}

body {
  font-family: 'Raleway', sans-serif;
  background-color: var(--dark);  /* Keeping dark background */
  color: var(--light);  /* Light text for dark background */
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
}

/* Smooth scrolling for anchor links */
html {
  scroll-behavior: smooth;
}

/* Container for content */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header Styles */
header {
  background: var(--gradient);
  padding: 120px 20px 80px;
  position: relative;
  overflow: hidden;
  clip-path: polygon(0 0, 100% 0, 100% 85%, 0 100%);
			transition: top 0.4s ease-in-out; 

}

header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('https://via.placeholder.com/1920x1080');
  background-size: cover;
  opacity: 0.1;
  z-index: 0;
}

header .container {
  position: relative;
  z-index: 1;
  text-align: center;
}

header h1 {
  font-size: 56px;
  margin-bottom: 16px;
  color: white;  /* White text on gradient background */
  text-transform: none;
  letter-spacing: -1px;
  line-height: 1.1;
}

header p {
  font-size: 20px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 300;
  max-width: 600px;
  margin: 0 auto;
}

/* Navigation */
nav {
  background-color: rgba(17, 24, 39, 0.95);  /* Dark nav background */
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
transition: top 0.3s ease-in-out;
}

nav.scrolled {
  background-color: rgba(17, 24, 39, 0.85); /* Slightly darker when scrolled */
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}


nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}

nav ul li {
  margin: 0 5px;
}

nav ul li a {
  color: var(--light);  /* Light text on dark nav */
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 8px;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}

nav ul li a i {
  font-size: 16px;
  color: var(--primary);
}

nav ul li a:hover {
  background-color: rgba(67, 97, 238, 0.2);  /* Slightly more visible hover state */
  color: var(--accent);
}


nav:hover {
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
}

/* Active navigation item */
nav ul li a.active {
  background-color: var(--primary);
   color: #00f7ff;
  border-bottom: 2px solid #00f7ff;
}

nav ul li a.active i {
  color: white;
}

/* Section Styles */
section {
  margin: 80px auto;
  padding: 50px 40px;
  background: var(--dark);  /* Dark section backgrounds */
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  border: 1px solid #1e293b;  /* Subtle border for definition */
}

section h2 {
  font-size: 36px;
  color: var(--light);  /* Light headings */
  margin-bottom: 30px;
  position: relative;
  display: inline-block;
}

section h2::after {
  content: '';
  position: absolute;
  width: 50%;
  height: 4px;
  background-color: var(--primary);
  bottom: -10px;
  left: 0;
  border-radius: 2px;
}

/* Profile Image and About Layout */
.profile-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 40px;
}

.profile-image {
  flex: 0 0 250px;
}

.profile-image img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  transition: transform 0.5s ease, box-shadow 0.5s ease;
}

.profile-image img:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 35px rgba(67, 97, 238, 0.25);
}

.profile-content {
  flex: 1;
  min-width: 300px;
}

.profile-content h2 {
  text-align: left;
}

.profile-content p {
  font-size: 17px;
  line-height: 1.7;
  margin-bottom: 20px;
  color: #e2e8f0;  /* Light paragraph text */
}

/* Skills Section */
#skills ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  list-style: none;
  margin-top: 30px;
}

#skills ul li {
  background-color: #1e293b;  /* Slightly lighter dark for contrast */
  color: var(--light);
  padding: 12px 22px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  border: 1px solid #334155;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

#skills ul li i {
  color: var(--primary);
  font-size: 18px;
}

#skills ul li:hover {
  background-color: var(--primary);
  color: white;
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(67, 97, 238, 0.3);
  border-color: var(--primary);
}

#skills ul li:hover i {
  color: white;
}

/* Achievements Section */
#achievements {
    text-align: left;
}

.achievements-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

/* Make entire card clickable */
.achievement-card {
    text-decoration: none;
    color: inherit;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    display: block;
}

.achievement-card:hover {
    transform: translateY(-8px);
}

/* Inner box */
.achievement {
    background: #1e293b;
    padding: 25px;
    border-radius: 16px;
    display: flex;
    align-items: flex-start;
    gap: 20px;
    border: 1px solid #334155;
    position: relative;
}

.achievement::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #4f46e5, #3b82f6);
    border-radius: 4px 0 0 4px;
}

.achievement:hover {
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
}

.achievement-icon {
    flex: 0 0 60px;
    height: 60px;
    background: rgba(67, 97, 238, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.achievement-icon i {
    font-size: 28px;
    color: #4f46e5; /* Updated gradient tone */
}

.achievement-content {
    flex: 1;
}

.achievement-content h3 {
    font-size: 22px;
    margin-bottom: 10px;
    color: #f8fafc;
}

.achievement-content p {
    margin: 0;
    color: #e2e8f0;
    line-height: 1.6;
    font-size: 16px;
}

/* Projects Section */
#projects {
  text-align: left;
}

.project {
  background: #1e293b;  /* Slightly lighter dark for projects */
  padding: 30px;
  margin: 40px 0;
  border-radius: 16px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  border: 1px solid #334155;
  position: relative;
  overflow: hidden;
}

.project::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--gradient);
  border-radius: 4px 0 0 4px;
}

.project:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
}

.project h3 {
  font-size: 24px;
  color: var(--light);
  margin-bottom: 15px;
}

.project p {
  margin-bottom: 25px;
  font-size: 16px;
  line-height: 1.7;
  color: #e2e8f0;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-top: 25px;
}

.project-btn, .download-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.3s ease;
  text-align: center;
}

.project-btn {
  background-color: var(--primary);
  color: white;
  border: 2px solid var(--primary);
}

.project-btn:hover {
  background-color: var(--secondary);
  border-color: var(--secondary);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(67, 97, 238, 0.25);
}

.download-btn {
  background-color: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.download-btn:hover {
  background-color: rgba(67, 97, 238, 0.1);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(67, 97, 238, 0.15);
}

/* Resume Section */
#resume {
  text-align: center;
  background: var(--gradient);
  color: white;
}

#resume h2 {
  color: white;
}

#resume h2::after {
  background-color: white;
  left: 25%;
}

#resume p {
  margin-bottom: 25px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.resume-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 30px;
  background: white;
  color: var(--primary);
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.3s ease;
  margin-top: 20px;
  border: 2px solid white;
}

.resume-btn:hover {
  background: transparent;
  color: white;
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(255, 255, 255, 0.2);
}

/* Contact Section */
#contact {
  text-align: left;
}

#contact p {
  margin: 20px 0;
  font-size: 17px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--light);
}

#contact p i {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(67, 97, 238, 0.1);
  color: var(--primary);
  border-radius: 50%;
  font-size: 18px;
  transition: all 0.3s ease;
}

#contact p:hover i {
  background-color: var(--primary);
  color: white;
  transform: scale(1.1);
}

#contact p a {
  color: var(--accent);  /* More visible link color */
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 500;
}

#contact p a:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* Footer */
footer {
  background-color: #0f172a;  /* Darker footer */
  color: var(--light);
  padding: 25px;
  text-align: center;
}

footer p {
  font-size: 15px;
  font-weight: 300;
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background-color: var(--primary);
  color: white;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  font-size: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(67, 97, 238, 0.3);
  z-index: 999;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background-color: var(--secondary);
  transform: translateY(-5px);
}

/* Animation for elements */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

section {
  animation: fadeInUp 0.8s ease-out forwards;
}

/* Responsive Design Improvements */
@media (max-width: 768px) {
  header {
    padding: 80px 20px 60px;
  }
  
  header h1 {
    font-size: 38px;
  }
  
  header p {
    font-size: 18px;
  }
  
  nav ul {
    flex-direction: column;
    align-items: center;
  }
  
  nav ul li {
    width: 100%;
    text-align: center;
    margin: 5px 0;
  }
  
  section {
    margin: 40px 15px;
    padding: 30px 20px;
  }
  
  .profile-container {
    flex-direction: column;
    text-align: center;
  }
  
  .profile-image {
    margin: 0 auto 30px;
    max-width: 200px;
  }
  
  .profile-content h2 {
    text-align: center;
  }
  
  .profile-content h2::after {
    left: 25%;
  }
  
  .project {
    padding: 25px;
  }
  
  .project-links {
    flex-direction: column;
  }
  
  .project-btn, .download-btn {
    width: 100%;
    justify-content: center;
  }
  
  #contact p {
    flex-direction: column;
    text-align: center;
    margin: 30px 0;
  }
  
  .achievements-container {
    grid-template-columns: 1fr;
  }
  
  .achievement {
    padding: 20px;
  }
}

/* Medium screens */
@media (min-width: 769px) and (max-width: 1024px) {
  header h1 {
    font-size: 48px;
  }
  
  .profile-container {
    gap: 30px;
  }
  
  .profile-image {
    flex: 0 0 200px;
  }
}

/* Larger screens */
@media (min-width: 1200px) {
  .container {
    padding: 0 40px;
  }
  
  section {
    padding: 60px 70px;
  }
  
  header {
    padding: 160px 20px 120px;
  }
}

.menu-toggle {
  display: none;
  font-size: 24px;
  cursor: pointer;
  color: white;
  padding: 10px 20px;
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

 #nav-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

#nav-menu.active {
  max-height: 300px; /* enough to show all items */
}

}
