@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css');
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

/* General Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Poppins', sans-serif;
  line-height: 1.6;
  background: #f2f2f2;
  color: #333;
  overflow-x: hidden;
}

/* Custom Scrollbar (Webkit Browsers) */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #ddd;
}
::-webkit-scrollbar-thumb {
  background: #4b6cb7;
  border-radius: 4px;
}

/* Header */
header {
  background: linear-gradient(90deg, #4b6cb7, #182848);
  color: #fff;
  padding: 40px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
header::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
}
header h1 {
  font-size: 3.5rem;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 2px;
}
header p {
  font-size: 1.2rem;
}

/* Navigation */
nav {
  display: flex;
  justify-content: center;
  padding: 15px;
  background: #333;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}
nav a {
  color: #fff;
  text-decoration: none;
  margin: 0 15px;
  font-weight: 600;
  position: relative;
  transition: color 0.3s;
}
nav a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  background: #4b6cb7;
  left: 0;
  bottom: -5px;
  transition: width 0.3s;
}
nav a:hover::after {
  width: 100%;
}
nav a:hover {
  color: #4b6cb7;
}

/* Section Container & Fade-In Animation */
section {
  padding: 60px 20px;
  max-width: 1200px;
  margin: auto;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
section.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Section Titles */
section h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2.5rem;
  color: #084f6b;
  position: relative;
}
section h2::after {
  content: "";
  position: absolute;
  width: 80px;
  height: 3px;
  background: #4b6cb7;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
}

/* About Section */
.about {
  background: #fff;
  padding: 40px;
  border-radius: 10px;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
  text-align: center;
}
.about img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  margin-bottom: 20px;
  object-fit: cover;
  border: 5px solid #4b6cb7;
  transition: transform 0.3s;
}
.about img:hover {
  transform: scale(1.05);
}
.about .links {
  margin-top: 20px;
}
.about a {
  color: #4b6cb7;
  text-decoration: none;
  font-weight: 600;
  margin: 0 10px;
  transition: color 0.3s;
}
.about a:hover {
  color: #182848;
}

/* Social Section */
.social {
  background: #fff;
  padding: 40px;
  border-radius: 10px;
  box-shadow: 0 6px 12px rgba(0,0,0,0.1);
  text-align: center;
}
.social .links {
  margin-top: 20px;
}
.social a {
  color: #4b6cb7;
  text-decoration: none;
  font-weight: 600;
  margin: 0 10px;
  transition: color 0.3s, transform 0.3s;
}
.social a:hover {
  color: #182848;
  transform: translateY(-3px);
}

/* Skills Section */
.skills {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  text-align: center;
}
.skills div {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: #fff;
  background: linear-gradient(90deg, #4b6cb7, #182848);
  padding: 20px;
  border-radius: 5px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s, box-shadow 0.3s;
}
.skills div i {
  font-size: 1.8rem;
  margin-right: 10px;
}
.skills div:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

/* Projects Section */
.projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  text-align: center;
}
.projects div {
  background: linear-gradient(135deg, #4b6cb7, #182848);
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s, box-shadow 0.3s;
}
.projects div:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}
.projects h3 {
  color: #fff;
  margin-bottom: 10px;
  font-size: 1.8rem;
}
.projects p,
.skills div b {
  color: #e0e0e0;
}
.projects a {
  text-decoration: none;
  font-weight: 600;
  color: #fff;
  background: #4b6cb7;
  padding: 10px 15px;
  border-radius: 5px;
  display: inline-block;
  margin-top: 10px;
  transition: background 0.3s, transform 0.2s;
}
.projects a:hover {
  background: #182848;
  transform: scale(1.05);
}

/* Contact Section */
#contact {
  display: flex;
  flex-direction: column;
  align-items: center; /* Center the content horizontally */
  padding: 60px 20px;
}

.contact-container {
  display: flex;
  justify-content: center; /* Center the card horizontally */
  align-items: center; /* Center the card vertically */
  width: 100%;
  max-width: 1200px; /* Optional: Limit the width of the container */
}

.card {
  background-color: #fff;
  border-radius: 10px;
  padding: 20px;
  width: 100%;
  max-width: 400px; /* Slightly wider */
  border: 2px solid #4b6cb7; /* Matching your "About Me" image border */
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.1); /* Matching your about-section shadow */
  transition: all 0.3s ease; /* For hover effect */
}

.card:hover {
  transform: scale(1.02); /* Subtle hover effect like your projects */
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2); /* Enhanced shadow on hover */
}

.title {
  font-size: 24px;
  font-weight: 600;
  text-align: center;
}

.form {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
}

.group {
  position: relative;
}

.form .group label {
  font-size: 14px;
  color: rgb(99, 102, 102);
  position: absolute;
  top: -10px;
  left: 10px;
  background-color: #fff;
  transition: all .3s ease;
}

.form .group input,
.form .group textarea {
  padding: 10px;
  border-radius: 5px;
  border: 1px solid rgba(0, 0, 0, 0.2);
  margin-bottom: 20px;
  outline: 0;
  width: 100%;
  background-color: transparent;
}

.form .group input:placeholder-shown + label,
.form .group textarea:placeholder-shown + label {
  top: 10px;
  background-color: transparent;
}

.form .group input:focus,
.form .group textarea:focus {
  border-color: #3366cc;
}

.form .group input:focus + label,
.form .group textarea:focus + label {
  top: -10px;
  left: 10px;
  background-color: #fff;
  color: #3366cc;
  font-weight: 600;
  font-size: 14px;
}

.form .group textarea {
  resize: none;
  height: 100px;
}

.form button {
  background-color: #3366cc;
  color: #fff;
  border: none;
  border-radius: 5px;
  padding: 10px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.form button:hover {
  background-color: #27408b;
}



/* Scroll-to-Top Button */
#scrollToTop {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: none;
  padding: 10px 15px;
  background: #4b6cb7;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: background 0.3s;
}
#scrollToTop:hover {
  background: #182848;
}

/* Footer */
footer {
  text-align: center;
  padding: 20px;
  background: #333;
  color: #fff;
}
footer .links a {
  display: inline-block;
  color: #4b6cb7;
  text-decoration: none;
  font-weight: 600;
  margin: 0 10px;
  font-size: 1.1rem;
  transition: color 0.3s;
}
footer .links a i {
  font-size: 1.2rem;
}
footer .links a:hover {
  color: #182848;
}

/* Responsive */
@media (max-width: 768px) {
  header h1 {
    font-size: 2.8rem;
  }
  section h2 {
    font-size: 2rem;
  }
}
