/* Reset & Base */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background-color: #f9fafb;
  color: #333;
  line-height: 1.6;
  scroll-behavior: smooth;
}

a {
  color: #0077b6;
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover,
a:focus {
  color: #023e8a;
  outline: none;
}

/* Container */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.9); /* Slightly transparent white */
  box-shadow: 0 2px 8px rgba(0,0,0,0.05); /* Lighter shadow */
  z-index: 1000;
  transition: background 0.3s ease, box-shadow 0.3s ease; /* Smooth transition */
}

.navbar.scrolled {
  background: #ffffff; /* Solid white when scrolled */
  box-shadow: 0 4px 12px rgba(0,0,0,0.1); /* More prominent shadow when scrolled */
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 60px;
}

.nav-logo {
  font-weight: 700;
  font-size: 1.5rem;
  color: #0077b6;
  letter-spacing: 1.2px;
}

.nav-menu {
  list-style: none;
  display: flex;
  gap: 2rem;
}

.nav-link {
  font-weight: 600;
  font-size: 1rem;
  padding: 0.5rem 0;
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  width: 0%;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: #0077b6;
  transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link:focus::after {
  width: 100%;
}

/* Active Nav Link Indicator */
.nav-link.active {
  color: #0077b6; /* Or a slightly different shade if you prefer */
  font-weight: 700; /* Make it bolder */
}

.nav-link.active::after {
  width: 100%; /* Ensure the underline is always full for active link */
  background-color: #0077b6;
}


/* Hero Section */
.hero-section {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 0 80px; /* account for fixed nav */
  background: linear-gradient(135deg, #0077b6 0%, #023e8a 100%);
  color: #fff;
  min-height: 100vh;
}

.hero-container {
  display: flex;
  gap: 3rem;
  flex-wrap: wrap;
  align-items: center;
  max-width: 1100px;
  width: 100%;
}

.hero-left {
  flex: 1 1 280px;
  text-align: center;
}

.profile-img {
  width: 280px;
  height: 280px;
  border-radius: 50%;
  border: 6px solid #00b4d8;
  object-fit: cover;
  box-shadow: 0 8px 20px rgba(0,180,216,0.5);
  transition: transform 0.3s ease;
}

.profile-img:hover,
.profile-img:focus {
  transform: scale(1.05);
  outline: none;
}

.hero-right {
  flex: 2 1 500px;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
  letter-spacing: 2px;
}

.hero-subtitle {
  font-size: 1.5rem;
  font-weight: 500;
  margin-bottom: 2rem;
  color: #caf0f8;
}

.hero-stats {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.stat {
  background: #00b4d8;
  padding: 1rem 1.5rem;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0,180,216,0.3);
  flex: 1 1 140px;
  text-align: center;
  cursor: default;
  transition: background-color 0.3s ease;
}

.stat:hover,
.stat:focus {
  background-color: #90e0ef;
  outline: none;
}

.stat-number {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}

.stat-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #caf0f8;
}

.hero-socials {
  display: flex;
  gap: 1.5rem;
}

.social-link {
  font-size: 2.2rem;
  color: #caf0f8;
  transition: color 0.3s ease, transform 0.3s ease;
}

.social-link:hover,
.social-link:focus {
  color: #00b4d8;
  transform: translateY(-5px);
  outline: none;
}

/* Sections */
.section {
  padding: 80px 0;
}

.section-light {
  background-color: #f9fafb;
  color: #333;
}

.section-dark {
  background-color: #023e8a;
  color: #caf0f8;
}

.section-title {
  font-size: 2.8rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 1.5rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: #0077b6;
  border-radius: 2px;
}

.section-subtitle {
  text-align: center;
  font-size: 1.1rem;
  max-width: 800px;
  margin: 0 auto 3rem;
  line-height: 1.8;
}

/* About Section */
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.about-card {
  background-color: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.about-card h3 {
  color: #0077b6;
  font-size: 1.8rem;
  margin-top: 0;
  margin-bottom: 1rem;
}

.about-card ul {
  list-style: none;
  padding: 0;
}

.about-card ul li {
  margin-bottom: 0.8rem;
  font-size: 1rem;
  display: flex;
  align-items: flex-start;
}

.about-card ul li::before {
  content: '\f00c'; /* FontAwesome checkmark icon */
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  color: #0077b6;
  margin-right: 0.8rem;
  font-size: 1.1rem;
  line-height: 1.6; /* Align with text */
}

/* Education Section */
.education-list {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.education-item {
  background-color: #023e8a; /* Dark background for dark section */
  border: 1px solid rgba(255,255,255,0.1);
  padding: 1.5rem 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.education-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.education-item h3 {
  color: #00b4d8;
  font-size: 2rem;
  margin-top: 0;
  margin-bottom: 0.5rem;
}

.edu-degree {
  font-size: 1.2rem;
  font-weight: 600;
  color: #caf0f8;
  margin-bottom: 0.8rem;
}

.edu-date {
  font-size: 1rem;
  font-weight: 400;
  color: #90e0ef;
  margin-left: 1rem;
}

.education-item p {
  font-size: 1rem;
  color: #e0f2f7;
}

/* Projects Section */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.project-card {
  background-color: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.project-card h3 {
  color: #0077b6;
  font-size: 1.8rem;
  margin-top: 0;
  margin-bottom: 0.8rem;
}

.project-desc {
  font-size: 1rem;
  color: #555;
  margin-bottom: 1rem;
  flex-grow: 1; /* Allows description to take available space */
}

.project-card strong {
  color: #023e8a;
}

.project-card ul {
  list-style: none;
  padding: 0;
  margin-bottom: 1.5rem;
}

.project-card ul li {
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
  color: #666;
  display: flex;
  align-items: flex-start;
}

.project-card ul li::before {
  content: '\f058'; /* FontAwesome check-circle icon */
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  color: #00b4d8;
  margin-right: 0.6rem;
  font-size: 1rem;
  line-height: 1.5;
}

.btn {
  display: inline-block;
  padding: 0.8rem 1.5rem;
  background-color: #0077b6;
  color: #fff;
  border-radius: 8px;
  text-align: center;
  font-weight: 600;
  transition: background-color 0.3s ease, transform 0.3s ease;
  margin-top: auto; /* Pushes button to the bottom */
}

.btn:hover {
  background-color: #023e8a;
  transform: translateY(-2px);
}

/* Skills Section */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
}

.skill-category {
  background-color: #023e8a; /* Dark background for dark section */
  border: 1px solid rgba(255,255,255,0.1);
  padding: 1.5rem 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.skill-category:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.skill-category h3 {
  color: #00b4d8;
  font-size: 1.8rem;
  margin-top: 0;
  margin-bottom: 1rem;
  text-align: center;
}

.skill-list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.8rem;
}

.skill-list li {
  background-color: #0077b6;
  color: #fff;
  padding: 0.6rem 1.2rem;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.skill-list li:hover {
  background-color: #005f91;
}

/* Contact Section */
.contact-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  margin-top: 3rem;
}

.contact-link {
  font-size: 1.2rem;
  color: #0077b6;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  transition: color 0.3s ease, transform 0.3s ease;
}

.contact-link:hover {
  color: #023e8a;
  transform: translateX(5px);
}

.contact-link i {
  font-size: 1.5rem;
  color: #00b4d8;
}

/* Footer */
.footer {
  background-color: #023e8a;
  color: #caf0f8;
  text-align: center;
  padding: 2rem 0;
  font-size: 0.9rem;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .nav-menu {
    gap: 1rem;
  }

  .hero-container {
    flex-direction: column;
    text-align: center;
  }

  .hero-left, .hero-right {
    flex: none;
    width: 100%;
  }

  .hero-title {
    font-size: 2.8rem;
  }

  .hero-subtitle {
    font-size: 1.2rem;
  }

  .hero-stats {
    justify-content: center;
  }

  .hero-socials {
    justify-content: center;
  }

  .section-title {
    font-size: 2.2rem;
  }

  .about-grid, .projects-grid, .skills-grid {
    grid-template-columns: 1fr;
  }

  .contact-info {
    align-items: flex-start; /* Align contact links to left on small screens */
  }
}

@media (max-width: 480px) {
  .nav-logo {
    font-size: 1.2rem;
  }

  .nav-menu {
    gap: 0.8rem;
  }

  .nav-link {
    font-size: 0.9rem;
  }

  .hero-title {
    font-size: 2.2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .stat {
    padding: 0.8rem 1rem;
    flex: 1 1 100%; /* Stack stats vertically */
  }

  .section-title {
    font-size: 1.8rem;
  }

  .project-card, .about-card, .education-item, .skill-category {
    padding: 1.5rem;
  }

  .contact-link {
    font-size: 1rem;
  }
}
