/* ===================== Reset ===================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}

body {
  background: #efebce;
  color: #373d20;
  line-height: 1.6;
  overflow-x: hidden;
}

/* ===================== Navbar ===================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: #0d3b66;
  padding: 15px 40px;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0px 2px 8px rgba(0,0,0,0.15);
  height: 70px; /* Set a fixed height */
}

.navbar .logo {
  color: #fdf0d5;
  font-size: 22px;
  font-weight: bold;
  letter-spacing: 1px;
}

.navbar ul {
  list-style: none;
  display: flex;
  gap: 30px;
  margin: 0;
  padding: 0;
}

.navbar ul li a {
  text-decoration: none;
  color: white;
  font-weight: 600;
  font-size: 18px;
  transition: 0.3s;
}

.navbar ul li a:hover {
  color: #000;
}

/* Hamburger Menu Styles */
.hamburger {
  display: none;
  cursor: pointer;
}

.bar {
  display: block;
  width: 25px;
  height: 3px;
  margin: 5px auto;
  transition: all 0.3s ease-in-out;
  background-color: white;
}

/* Prevent content overlap */
section {
  scroll-margin-top: 80px; /* Adjusted for navbar height */
  padding: 60px 10%;
}


/* ===================== Hero Section ===================== */
.hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 80px 10%;
  min-height: 100vh;
  padding-top: 100px; /* Ensure content is below fixed navbar */
}

.hero-text {
  flex: 1;
  max-width: 600px;
}

.hero-text h1 {
  font-size: 48px;
  margin-bottom: 15px;
}

.hero-text h1 span {
  color: #0d3b66;
}

.hero-text p {
  margin: 15px 0;
  font-size: 18px;
}

.hero-image {
  flex: 0 0 auto;
  margin-left: 40px;
}

.hero-image img {
  width: 300px;
  height: 300px;
  object-fit: cover;
  border-radius: 50%;
  border: 4px solid #373d20;
  transition: transform 0.3s ease;
}

.hero-image:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.hero .social-links {
  margin-top: 20px;
  display: flex;
  gap: 25px;
}

.hero .social-links a {
  text-decoration: none;
  font-size: 18px;
  font-weight: bold;
  color: #373d20;
  transition: 0.3s;
}

.hero .social-links a:hover {
  color: #0d3b66;
}

/* Common Section Divider */
.section-divider {
  width: 80%;
  margin: 50px auto;
  border: 0;
  border-top: 2px solid #444;
  opacity: 0.7;
}

/* ===================== Buttons ===================== */
.btn {
  display: inline-block;
  padding: 10px 20px;
  background: #0d3b66;
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  border-radius: 5px;
  transition: 0.3s;
  margin: 5px;
}

.hire {
  display: inline-block;
  padding: 10px 20px;
  background: #fff;
  color: #000;
  text-decoration: none;
  font-weight: bold;
  border-radius: 5px;
  transition: 0.3s;
  margin: 5px;
}

.btn:hover {
  background: #000;
}

/* ===================== About Section ===================== */
.about {
  padding: 60px 10%;
}

.about h2 {
  font-size: 32px;
  margin-bottom: 30px;
  color: #0d3b66;
  text-align: center;
  text-transform: capitalize;
  letter-spacing: 2px;
}

.about-card {
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  line-height: 1.8;
  color: #373d20;
  font-size: 16px;
  max-width: 900px;
  margin: 0 auto;
  box-shadow: 0px 4px 15px rgba(0,0,0,0.6);
  border: 1px solid #373d20;
  transition: transform 0.3s, box-shadow 0.3s;
}

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

/* ===================== Generic Sections ===================== */
h2 {
  font-size: 32px;
  margin-bottom: 20px;
  color: #183a37;
}

ul {
  list-style: disc;
  padding-left: 20px;
}

/* Education Section */
.education {
  padding: 60px 10%;
  text-align: center;
}

.education h2 {
  font-size: 2rem;
  margin-bottom: 40px;
  color: #0d3b66;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
}

.education h2::after {
  content: "";
  display: block;
  width: 70px;
  height: 3px;
  margin: 12px auto 0;
  border-radius: 2px;
}

.edu-card {
  margin: 20px auto;
  max-width: 700px;
  text-align: left;
  padding-left: 20px;
  border-left: 3px solid #0d3b66;
  position: relative;
}

.edu-card::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 8px;
  width: 14px;
  height: 14px;
  background: #0d3b66;
  border-radius: 50%;
}

.edu-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 5px;
}

.edu-card h3 span {
  font-weight: 400;
  font-size: 0.9rem;
  color: #666;
}

.edu-card p {
  font-size: 0.95rem;
  color: #444;
  margin: 0;
}

/* ===================== Projects Section ===================== */
.projects {
  padding: 60px 10%;
}

.project-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 10px;
}

.projects h2 {
  font-size: 32px;
  margin-bottom: 30px;
  color: #0d3b66;
  text-align: center;
}

.project-card {
  background: #fff;
  padding: 20px;
  margin: 20px 0;
  border-radius: 10px;
  transition: transform 0.3s, background 0.3s;
}

.project-card:hover {
  transform: translateY(-5px);
  background: #fff;
}

.project-card h3 {
  font-size: 20px;
  color: #000;
  margin-bottom: 15px;
}

.project-card p {
  font-size: 15px;
  color: #373d20;
  line-height: 1.5;
  margin-bottom: 15px;
}

.project-card .btn {
  padding: 6px 14px;
  font-size: 14px;
  background: #0d3b66;
  color: #fff;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 500;
  transition: 0.3s;
}

.project-card .btn:hover {
  background: #000;
  color: #fff;
}

/* ===================== Skills Section ===================== */
.skills {
  padding: 70px 8%;
  background: #fdfdfd;
}

.skills h2 {
  font-size: 34px;
  text-align: center;
  margin-bottom: 50px;
  color: #0d3b66;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 700;
  position: relative;
}

.skills h2::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: #0d3b66;
  margin: 12px auto 0;
  border-radius: 2px;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 28px;
  max-width: 1100px;
  margin: 0 auto;
}

.skill-card {
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
}

.skill-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  background: #fff !important;
  border-color: #e5e5e5 !important;
}

.skill-card h3 {
  font-size: 20px;
  margin-bottom: 16px;
  color: #373d20;
  font-weight: 600;
}

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

.skill-card ul li {
  font-size: 15px;
  color: #000;
  padding: 6px 0;
  border-bottom: 1px solid #f0f0f0;
}

.skill-card ul li:last-child {
  border-bottom: none;
}

/* ===================== Certifications Section ===================== */
.certifications {
  padding: 60px 20px;
  text-align: center;
}

.certifications h2 {
  font-size: 2rem;
  margin-bottom: 50px;
  color: #222;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
}

.certifications h2::after {
  content: "";
  display: block;
  width: 100px;
  max-width: 90%;
  height: 3px;
  background: #0d3b66;
  margin: 12px auto 0;
  border-radius: 2px;
}

.cert-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 35px;
  max-width: 1000px;
  margin: 0 auto;
}

.cert-circle {
  background: #fff;
  border-radius: 50%;
  width: 170px;
  height: 170px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.12);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  padding: 20px;
  margin: 0 auto;
}

.cert-circle:hover {
  transform: translateY(-8px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.18);
}

.cert-circle span {
  font-size: 0.95rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 12px;
  text-align: center;
  line-height: 1.3;
}

.cert-circle .btn {
  display: inline-block;
  padding: 6px 14px;
  background: #373d20;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 20px;
  text-decoration: none;
  transition: background 0.3s ease;
}

.cert-circle .btn:hover {
  background: #0d3b66;
}

/* ===================== Contact Section ===================== */
.contact {
  background: #efebce;
  padding: 60px 10%;
  text-align: center;
}

.contact h2 {
  font-size: 32px;
  margin-bottom: 20px;
  color: #0d3b66;
  letter-spacing: 2px;
}

.full-contact {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.contact-info {
  flex: 1;
  max-width: 400px;
  font-size: 18px;
  line-height: 1.8;
  text-align: left;
}

.contact-info p {
  margin: 15px 0;
}

.contact-info a {
  color: #0077b6;
  text-decoration: none;
  font-weight: bold;
  transition: 0.3s;
}

.contact-info a:hover {
  color: #03045e;
  text-decoration: underline;
}

.contact-form {
  flex: 1;
  max-width: 600px;
  background: #fff;
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  text-align: left;
}

.form-group {
  margin-bottom: 15px;
}

.form-group label {
  font-weight: bold;
  display: block;
  margin-bottom: 6px;
  color: #0d3b66;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
  transition: border 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: #00acee;
  outline: none;
}

/* ===================== Footer ===================== */
footer {
  text-align: center;
  padding: 20px;
  background: #111;
  margin-top: 20px;
}

footer p {
  color: #fff;
}

/* ===================== RESPONSIVE DESIGN ===================== */

/* Large Desktop (1200px and up) */
@media (min-width: 1200px) {
  .hero {
    padding: 100px 8%;
  }
  
  .hero-text h1 {
    font-size: 52px;
  }
  
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Desktop (992px to 1199px) */
@media (max-width: 1199px) {
  .navbar {
    padding: 15px 20px;
  }
  
  .hero {
    padding: 80px 5%;
  }
  
  .hero-text h1 {
    font-size: 42px;
  }
}

/* Tablet Landscape (768px to 991px) */
@media (max-width: 991px) {
  .navbar {
    padding: 12px 20px;
  }
  
  .navbar ul {
    gap: 20px;
  }
  
  .navbar ul li a {
    font-size: 16px;
  }
  
  .hero {
    flex-direction: column;
    text-align: center;
    padding: 100px 5%;
    min-height: auto;
  }
  
  .hero-image {
    margin-left: 0;
    margin-top: 30px;
  }
  
  .hero-text h1 {
    font-size: 36px;
  }
  
  .hero-text p {
    font-size: 16px;
  }
  
  .hero-image img {
    width: 250px;
    height: 250px;
  }
  
  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  
  .cert-container {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .project-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  /* FIXED: Contact Form responsiveness */
  .full-contact {
    flex-direction: column;
    align-items: center; /* Center items for a cleaner look */
    gap: 30px;
  }
  
  .contact-info, .contact-form {
    max-width: 100%;
    width: 100%; /* Ensure both take full width */
  }

  .contact-info {
    text-align: center;
  }
}

/* Tablet Portrait & Mobile (up to 767px) */
@media (max-width: 767px) {
  /* FIXED: Hamburger menu functionality */
  .hamburger {
    display: block;
  }
  

  .hamburger.active .bar:nth-child(2) {
    opacity: 0;
  }
  .hamburger.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .hamburger.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  .nav-links {
    position: fixed;
    left: -100%;
    top: 70px; /* Position below navbar height */
    gap: 0;
    flex-direction: column;
    background-color: #0d3b66;
    width: 100%;
    text-align: center;
    transition: 0.3s ease-in-out;
    box-shadow: 0px 4px 8px rgba(0,0,0,0.15);
  }

  .nav-links li {
    padding: 15px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .nav-links li:first-child {
      border-top: none;
  }

  .nav-links a {
    font-size: 18px;
  }

  .nav-links.active {
    left: 0;
  }
  
  section {
    padding: 40px 5%;
  }
  
  .hero-text h1 {
    font-size: 28px;
  }
  
  .hero-text p {
    font-size: 14px;
  }
  
  .hero-image img {
    width: 200px;
    height: 200px;
  }
  
  .hero .social-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
  }
  
  .about h2,
  .education h2,
  .projects h2,
  .skills h2,
  .certifications h2,
  .contact h2 {
    font-size: 24px;
  }
  
  .about-card {
    padding: 20px;
  }
  
  .about-card p {
    font-size: 14px;
  }
  
  .edu-card {
    padding-left: 15px;
  }
  
  .edu-card h3 {
    font-size: 1rem;
  }
  
  .skills-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .skill-card {
    padding: 20px;
  }
  
  .cert-container {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 20px;
  }
  
  .cert-circle {
    width: 140px;
    height: 140px;
    padding: 15px;
  }
  
  .cert-circle span {
    font-size: 0.8rem;
  }
  
  .certifications h2::after {
    width: 80px;
  }
  
  .project-card {
    padding: 15px;
  }
  
  .contact-form {
    padding: 20px;
  }
}

/* Mobile Small (up to 480px) */
@media (max-width: 480px) {
  section {
    padding: 30px 4%;
  }

  .hero{
    padding-top: 100px;
  }
  
  .hero-text h1 {
    font-size: 24px;
  }
  
  .hero-text p {
    font-size: 13px;
  }
  
  .hero-image img {
    width: 180px;
    height: 180px;
  }
  
  .btn, .hire {
    padding: 8px 16px;
    font-size: 12px;
  }
  
  .section-divider {
    width: 90%;
    margin: 30px auto;
  }
  
  .about h2,
  .education h2,
  .projects h2,
  .skills h2,
  .certifications h2,
  .contact h2 {
    font-size: 20px;
  }
  
  .cert-container {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  }
  
  .cert-circle {
    width: 120px;
    height: 120px;
    padding: 12px;
  }
  
  .cert-circle span {
    font-size: 0.75rem;
  }
  
  .cert-circle .btn {
    font-size: 0.7rem;
    padding: 4px 10px;
  }
  
  .contact-info {
    font-size: 14px;
  }
}