/* This removes default spacing all browsers add */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Sets the font for the whole page */
body {
  font-family: 'Segoe UI', sans-serif;
  color: #333;
}

/* ========================
   NAVIGATION
======================== */
nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 60px;
  background-color: #0f0f0f;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-logo {
  color: #fff;
  font-size: 22px;
  font-weight: bold;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 30px;
}

.nav-links a {
  color: #ccc;
  text-decoration: none;
  font-size: 15px;
}

.nav-links a:hover {
  color: #a78bfa;
}

/* Hamburger button — hidden on desktop */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
  z-index: 200;
}

.hamburger span {
  display: block;
  width: 26px;
  height: 2px;
  background-color: #ffffff;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Animate hamburger to X when open */
.hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.hamburger.open span:nth-child(2) {
  opacity: 0;
}
.hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ========================
   HERO SECTION
======================== */
#hero {
  min-height: 100vh;
  background-color: #0f0f0f;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
  position: relative;
  overflow: hidden;
}

#particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.hero-content {
  max-width: 700px;
  position: relative;
  z-index: 1;
}

.hero-greeting {
  color: #a78bfa;
  font-size: 18px;
  margin-bottom: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.hero-name {
  font-size: 64px;
  font-weight: bold;
  color: #ffffff;
  margin-bottom: 16px;
}

.hero-role {
  font-size: 22px;
  color: #a78bfa;
  margin-bottom: 12px;
}

.hero-sub {
  font-size: 16px;
  color: #888;
  margin-bottom: 36px;
}

/* Stats row in hero */
.hero-stats {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 10px;
}

.stat-box {
  background-color: rgba(124, 58, 237, 0.15);
  border: 1px solid #7c3aed;
  border-radius: 12px;
  padding: 16px 24px;
  text-align: center;
  min-width: 90px;
  transition: transform 0.3s ease;
}

.stat-box:hover {
  transform: translateY(-4px);
  background-color: rgba(124, 58, 237, 0.25);
}

.stat-num {
  font-size: 26px;
  font-weight: bold;
  color: #a78bfa;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 12px;
  color: #888;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* ========================
   BUTTONS
======================== */
.btn-primary {
  background-color: #7c3aed;
  color: #fff;
  padding: 14px 32px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 15px;
  font-weight: bold;
  display: inline-block;
}

.btn-outline {
  background-color: transparent;
  color: #a78bfa;
  padding: 14px 32px;
  border-radius: 8px;
  border: 2px solid #a78bfa;
  text-decoration: none;
  font-size: 15px;
  font-weight: bold;
  display: inline-block;
}

.btn-primary:hover {
  background-color: #6d28d9;
}

.btn-outline:hover {
  background-color: #a78bfa;
  color: #fff;
}

/* ========================
   REUSABLE STYLES
======================== */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 40px;
}

section {
  padding: 80px 0;
}

.section-title {
  font-size: 36px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 50px;
  color: #ffffff;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background-color: #7c3aed;
  margin: 12px auto 0;
  border-radius: 2px;
}

/* ========================
   ABOUT SECTION
======================== */
#about {
  background-color: #111111;
}

.about-bio {
  max-width: 780px;
  margin: 0 auto 50px;
  text-align: center;
}

.about-bio p {
  color: #aaa;
  font-size: 16px;
  line-height: 1.9;
  margin-bottom: 18px;
}

.highlight {
  color: #a78bfa;
  font-weight: bold;
}

.about-bio .btn-primary {
  display: inline-block;
  margin-top: 10px;
}

.about-bottom {
  display: flex;
  flex-direction: row;
  gap: 40px;
  margin-top: 20px;
  align-items: flex-start;
}

.about-skills {
  background-color: #1e1e2e;
  border: 1px solid #7c3aed;
  border-radius: 12px;
  padding: 24px;
  flex: 1.4;
}

.about-education {
  background-color: #1e1e2e;
  border: 1px solid #7c3aed;
  border-radius: 12px;
  padding: 24px;
  flex: 1;
}

.about-skills h3,
.about-education h3 {
  font-size: 20px;
  color: #a78bfa;
  margin-bottom: 16px;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.skill-tags span {
  background-color: #0f0f0f;
  color: #a78bfa;
  padding: 8px 18px;
  border-radius: 20px;
  font-size: 14px;
  border: 1px solid #7c3aed;
}

.edu-card {
  background-color: transparent;
  border: none;
  padding: 0;
}

.edu-degree {
  color: #ffffff;
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 10px;
}

.edu-college {
  color: #a78bfa;
  font-size: 15px;
  margin-bottom: 10px;
}

.edu-year {
  color: #888;
  font-size: 13px;
}

/* ========================
   PROJECTS SECTION
======================== */
#projects {
  background-color: #0f0f0f;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.project-card {
  background-color: #1e1e2e;
  border: 1px solid #7c3aed;
  border-radius: 12px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform 0.3s ease;
}

.project-card:hover {
  transform: translateY(-6px);
}

.project-card.featured {
  border: 2px solid #a78bfa;
  background-color: #1a1a2e;
}

.project-tag {
  font-size: 12px;
  color: #a78bfa;
  background-color: #0f0f0f;
  border: 1px solid #7c3aed;
  padding: 4px 12px;
  border-radius: 20px;
  width: fit-content;
}

.project-card h3 {
  font-size: 18px;
  color: #ffffff;
  margin: 0;
}

.project-card p {
  color: #aaa;
  font-size: 14px;
  line-height: 1.7;
  flex: 1;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.project-tech span {
  background-color: #0f0f0f;
  color: #a78bfa;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  border: 1px solid #7c3aed;
}

.project-links {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 6px;
}

.project-links .btn-primary,
.project-links .btn-outline {
  padding: 10px 20px;
  font-size: 13px;
}

.sih-badge {
  background-color: #7c3aed;
  color: #ffffff;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: bold;
  display: inline-flex;
  align-items: center;
}

/* ========================
   CONTACT SECTION
======================== */
#contact {
  background-color: #111111;
}

.contact-sub {
  text-align: center;
  color: #aaa;
  font-size: 16px;
  margin-top: -30px;
  margin-bottom: 50px;
}

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: stretch;
}

.contact-info,
.contact-form {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact-info-title {
  color: #a78bfa;
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 24px;
}

.social-icons {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.social-icon-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  background-color: #1e1e2e;
  border: 1px solid #7c3aed;
  border-radius: 12px;
  padding: 16px 20px;
  text-decoration: none;
  color: #ffffff;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.social-icon-btn i {
  font-size: 22px;
  min-width: 24px;
  text-align: center;
}

.social-icon-btn span {
  font-size: 15px;
  color: #ffffff;
}

.social-icon-btn:hover {
  transform: translateX(6px);
  background-color: rgba(124, 58, 237, 0.25);
  border-color: #a78bfa;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  background-color: #1e1e2e;
  border: 1px solid #7c3aed;
  border-radius: 8px;
  padding: 14px 18px;
  color: #ffffff;
  font-size: 15px;
  margin-bottom: 16px;
  outline: none;
  font-family: 'Segoe UI', sans-serif;
}

.contact-form textarea {
  min-height: 160px;
  resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: #a78bfa;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #777;
}

.contact-form .btn-primary {
  width: 100%;
  text-align: center;
  padding: 14px;
  font-size: 16px;
  border: none;
  cursor: pointer;
}

.contact-icon {
  font-size: 22px;
  min-width: 24px;
  display: inline-flex;
  justify-content: center;
}

#formMsg {
  margin-top: 12px;
  text-align: center;
  font-size: 14px;
  color: #a78bfa;
}

/* ========================
   FOOTER
======================== */
footer {
  background-color: #0f0f0f;
  text-align: center;
  padding: 24px;
  color: #555;
  font-size: 14px;
}

/* ========================
   SCROLL ANIMATIONS
======================== */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ========================
   MOBILE RESPONSIVE
======================== */
@media (max-width: 768px) {

  /* --- NAV --- */
  nav {
    padding: 16px 20px;
    position: sticky;
    top: 0;
  }

  /* Show hamburger on mobile */
  .hamburger {
    display: flex;
  }

  /* Mobile nav menu — slides down when open */
  .nav-links {
    display: none;
    flex-direction: column;
    gap: 0;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: #0f0f0f;
    padding: 10px 0 20px;
    border-top: 1px solid #2a2a2a;
    z-index: 99;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: 14px 24px;
    font-size: 16px;
    border-bottom: 1px solid #1a1a1a;
    color: #ccc;
  }

  .nav-links a:hover {
    background-color: rgba(124, 58, 237, 0.15);
    color: #a78bfa;
  }

  /* --- HERO --- */
  .hero-name {
    font-size: 38px;
  }

  .hero-role {
    font-size: 18px;
  }

  .hero-greeting {
    font-size: 14px;
  }

  .hero-sub {
    font-size: 14px;
  }

  .hero-stats {
    gap: 12px;
  }

  .stat-box {
    padding: 12px 16px;
    min-width: 80px;
  }

  .stat-num {
    font-size: 22px;
  }

  .btn-primary,
  .btn-outline {
    padding: 12px 22px;
    font-size: 14px;
  }

  /* --- CONTAINER --- */
  .container {
    padding: 0 20px;
  }

  section {
    padding: 60px 0;
  }

  .section-title {
    font-size: 28px;
    margin-bottom: 36px;
  }

  /* --- ABOUT --- */
  .about-bio p {
    font-size: 15px;
  }

  .about-bottom {
    flex-direction: column;
    gap: 20px;
  }

  .about-skills,
  .about-education {
    width: 100%;
    flex: unset;
  }

  .skill-tags span {
    font-size: 13px;
    padding: 6px 14px;
  }

  /* --- PROJECTS --- */
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .project-card {
    padding: 20px;
  }

  .project-links {
    flex-wrap: wrap;
  }

  .project-links .btn-primary,
  .project-links .btn-outline {
    flex: 1;
    text-align: center;
    padding: 10px 14px;
    font-size: 13px;
  }

  /* --- CONTACT --- */
  .contact-wrapper {
    grid-template-columns: 1fr;
    gap: 30px;
  }

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

  .contact-sub {
    font-size: 14px;
    margin-top: -20px;
    margin-bottom: 36px;
    padding: 0 10px;
  }

  .social-icon-btn {
    justify-content: flex-start;
  }

}

/* Extra small phones */
@media (max-width: 400px) {
  .hero-name {
    font-size: 30px;
  }

  .hero-stats {
    flex-direction: column;
    align-items: center;
  }

  .stat-box {
    width: 80%;
  }
}