* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  background-color: #212121;
  color: aliceblue;
  font-size: 16px;
  font-family: "Poppins", sans-serif;
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  scrollbar-width: thin;
  scrollbar-color: green #363636;
}

.navbar-links a,
.navbar-links li,
.logo a {
  text-decoration: none;
  list-style: none;
  color: aliceblue;
  font-size: 1rem;
}
.navbar-links a.active {
  border-bottom: 4px solid green;
  padding-bottom: 4px;
  font-weight: bold;
}
.navbar-links a:hover {
  border-bottom: 4px solid green;
  padding-bottom: 4px;
  font-weight: bold;
}

.logo {
  font-size: 2rem;
  font-weight: 600;
}
header {
  background-color: #363636;
  height: auto;
}

nav {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  height: 70px;
  padding: 1.5rem;
}

nav.sticky {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: #363636;

  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  z-index: 100;
}

.navbar-links {
  display: flex;
  align-items: center;
  gap: 15px;
}
.logo {
  display: flex;
  gap: 5px;
}

/* hamburger menu */

#hamburger-nav {
  display: none;
}

.hamburger-menu {
  position: relative;
  display: inline-block;
}

.hamburger-icon {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 24px;
  cursor: pointer;
  width: 30px;
}

.hamburger-icon span {
  width: 100%;
  height: 2px;
  background-color: white;
  transition: all 0.3 ease-in-out;
}

.menu-links {
  position: fixed;
  top: 70px;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #363636;
  width: 100%;
  max-height: 0;
  overflow: hidden;
  z-index: 99;
  transition: all 0.3s ease-in-out;
}

.menu-links.open {
  display: flex;
  flex-direction: column;
  max-height: 100vh;
  width: 100%;
}

.menu-links a {
  display: block;
  padding: 10px;
  text-align: center;
  font-size: 1.5rem;
  color: white;
  text-decoration: none;
  transition: all 0.3 ease-in-out;
}

.menu-links a:hover {
  border-bottom: 4px solid green;
  padding-bottom: 4px;
  font-weight: bold;
  transition: all 0.3 ease-in-out;
}

.menu-links li {
  list-style: none;
  margin-bottom: 20px;
}



.hamburger-icon.open span:first-child {
  transform: rotate(45deg) translate(10px, 5px);
}

.hamburger-icon.open span:nth-child(2) {
  opacity: 0;
}

.hamburger-icon.open span:last-child {
  transform: rotate(-45deg) translate(10px, -5px);
}

.hamburger-icon span:first-child {
  transform: none;
}

.hamburger-icon span:nth-child(2) {
  opacity: 1;
}

.hamburger-icon span:last-child {
  transform: none;
}

.hero {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  padding: 150px 0 100px 0;
}

.hero img {
  width: 400px;
  height: 400px;
  border: 10px solid green;
  box-shadow: 0 0 15px rgba(0, 255, 0, 0.5);
  object-position: 50% 50%;
  border-radius: 50%;
  object-fit: cover;
}
.btn {
  display: inline-block;
  text-decoration: none;
  padding: 10px 24px;
  margin-top: 50px;
  margin-left: 10px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-primary {
  color: white;
  background-color: transparent;
  border: 2px solid green;
  box-shadow: 0 0 5px rgba(0, 255, 0, 0.502);
}

.btn-primary:hover {
  background-color: green;
  color: #121212;
}
.btn-secondary {
  color: white;
  background-color: transparent;
  border: 2px solid white;
}

.btn-secondary:hover {
  background-color: white;
  color: #121212;
}
.section-container {
  text-align: left;
  padding: 40px;
  min-height: fit-content;
  box-sizing: border-box;
}
.about_me_container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  padding-top: 100px;
}

.about_me_img {
  height: 500px;
  width: 400px;
  border-radius: 5px;
}
.about_me_img img {
  width: inherit;
  height: inherit;
  object-fit: cover;
  border: 10px solid green;
  box-shadow: 0 0 15px rgba(0, 255, 0, 0.5);
}
.about_me_card {
  display: flex;
  flex-direction: column;
  padding: 20px;
  border-radius: 8px;
  gap: 20px;
  line-height: 1.3;
  max-width: 900px;
  align-self: flex-start;
  align-items: center;
}
.about_me_text {
  font-size: 1.2rem;
  padding: 0 30px;
  text-align: justify;
  line-height: 1.6;
}

.about_me_details_container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 40px;
}

.about_me_details {
  border: 2px solid rgba(0, 128, 0, 0.499);
  border-radius: 2rem;
  padding: 1.5rem;
  text-align: center;
}

.section-head {
  position: relative;
  display: inline-block;
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 20px;
}

.section-head::after {
  content: "";
  display: block;
  width: 50px;
  height: 4px;
  background-color: #008000;
  margin-top: 8px;
  transition: width 0.4s ease;
}
.section-head:hover::after {
  box-shadow: 0 0 10px rgba(0, 255, 0, 0.5);
}

.intro {
  line-height: 1.7;
}

.icon {
  height: 2rem;
}

/* SKILL SECTION */

.skill_container {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 40px;
  padding-top: 100px;
  gap: 30px;
}

.card {
  background-color: #ffffff07;
  border: 2px solid rgba(0, 128, 0, 0.499);
  color: #fff;
  font-family: sans-serif;
  padding: 1rem;
  border-radius: 10px;
}
.card h2 {
  color: rgb(0, 128, 0, 0.8);
  margin-bottom: 15px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 600;
}

.stack {
  display: flex;
  margin-bottom: 10px;
  gap: 5px;
}

.year {
  opacity: 0.5;
}

.tech {
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: space-around;
}

.tech_name {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
}

.tech img {
  width: 25px;
}

.stack .progress_bar {
  height: 8px;

  width: 100%;
  background-color: #475569;
  /* overflow: hidden; */
  border-radius: 4px;
}

.skill-level {
  height: 100%;
  border-radius: 4px;
  transition: width 1s ease-out;
}
/* Level fill widths */
.beginner {
  width: 25%;
  background-color: #ef4444;
}

.intermediate {
  width: 50%;
  background-color: #f59e0b;
}

.proficient {
  width: 75%;
  background-color: #10b981;
}

.advanced {
  width: 95%;
  background-color: #3b82f6;
}

/* Footer */

footer {
  height: 100px;
  background-color: #363636;
}

.footer_details {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 20px;
  font-size: 1.2rem;
}

.fa_icons {
  color: white;
  font-size: 1.5rem;
  margin-right: 10px;
}
.fa_icons:hover {
  color: green;
  transition: color 0.3s ease;
}

/* Contact Form */

.contact_form {
  display: flex;
  justify-content: center;
  align-items: center;
  padding-top: 100px;
}

.contact_form form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  max-width: 600px;
}

.contact_form label {
  font-size: 1.2rem;
  font-weight: bold;
}

.contact_form input,
.contact_form textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  resize: none;
  font-size: 1rem;
  font-family: inherit;

}

.contact_form input:focus,
.contact_form textarea:focus {
  outline: 2px solid rgba(0, 128, 0, 0.499);
  border-color: rgba(0, 128, 0, 0.499);
  box-shadow: 0 0 10px rgba(0, 255, 0, 0.5);
}

#message {
  min-height: 300px;
}

.contact_form_submit {
  padding: 10px 20px;
  background-color: green;
  color: white;
  width: 150px;
  font-size: 1.2rem;
  height: 50px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.contact_form_submit:hover {
  background-color: #0080007f;
  box-shadow: 0 0 10px rgba(0, 255, 0, 0.5);
  transition: all 0.3s ease;
}

/* Project section */

.grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, 300px);
  grid-auto-flow: row;
  gap: 30px;
  padding-top: 100px;
  margin: 0 40px;
}
.container {
  display: flex;
  flex-direction: column;
  border: 2px solid #008000;
  border-radius: 8px;
  /* box-shadow: 8px 6px 15px 1px rgb(50 144 41); */
  font-family: sans-serif;
  overflow-y: hidden;
  line-height: 1.5;
  transition: all 0.3s ease-in-out;
}

.container:hover {
  box-shadow: 8px 6px 25px 5px rgb(50 144 41);
  transform: scale(1.03);
}

.project_img {
  height: 150px;
  width: 100%;
  overflow: hidden;
}

.project_img img {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.project_status {
  display: flex;
  padding: 0.5rem 0;
  justify-content: space-between;
  font-size: 0.75rem;
}

.stack_type,
.project_progress {
  background-color: green;
  padding: 0.125rem 0.625rem;
  color: white;
  border-radius: 4px;
  font-weight: 600;
  tab-size: 4;
}

.container:hover .stack_type {
  background-color: #0080007f !important;
}

.project_progress.completed {
  background-color: #0d542b80 !important;
  color: rgb(129, 240, 169);
}

.project_progress.ongoing {
  background-color: #7b330680 !important;
  color: #ffd230;
}

.project_title {
  padding: 0.5rem 0;
  font-weight: 700;
  font-family: sans-serif;
}

.container:hover .project_title {
  color: green;
}

.project {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex-grow: 1;
  padding: 1.5rem;
}

.project_stack {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  padding: 0.5rem 0;
}

.project_stack p {
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  border: 0.2px solid gray;
}

.project_links {
  text-align: center;
  cursor: pointer;
  flex: 1 1 80%;
  border: 0.2px solid gray;
  border-radius: 4px;
}

.project_links a {
  text-decoration: none;
  color: #ccc;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  padding: 0.5rem 1rem;
}

.project_links img {
  margin-left: 5px;
}

.project_links:hover,
.github_icon:hover {
  color: white;
  transform: scale(1.05);
  transition: all 0.3s ease;
}

.github_icon:hover {
  background-color: green;
}

.project_display {
  display: flex;
  gap: 10px;
  padding-top: 0.5rem;
}

.project_display a {
  text-decoration: none;
  color: #ccc;
}

.github_icon {
  background-image: url(../Assets/github-mark-white.png);
  background-size: 50%;
  background-repeat: no-repeat;
  background-position: center;

  flex-basis: 20%;
  border: 0.2px solid gray;
  border-radius: 4px;
}

/* Theme toggle */

.theme-toggle img {
  width: 20px;
  height: 20px;
}

.theme-toggle {
  background: #5f5e5e5a;

  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
}

.theme-toggle:focus {
  outline: 2px solid green;
  outline-offset: 2px;
  box-shadow: 0 0 0 3px rgba(0, 128, 0, 0.3);
}


.theme-toggle:hover {
  background-color: #8f8d8d5a;
}

.light-mode {
  background-color: #f5f5f5;
  color: green;
}

.light-mode header,
.light-mode nav,
.light-mode nav.sticky {
  background-color: #ffffff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.light-mode .navbar-links a,
.light-mode .navbar-links li,
.light-mode .logo a,
.light-mode .menu-links a {
  color: green;
}

/* Keep the green accent on active/hover states */
.light-mode .navbar-links a.active,
.light-mode .navbar-links a:hover,
.light-mode .menu-links a:hover {
  border-bottom: 4px solid green;
}

/* Light mode - Hero section */
.light-mode .hero {
  background-color: #ffffff;
}

/* Light mode - Cards and containers */
.light-mode .card,
.light-mode .container {
  background-color: #ffffff;
  border: 2px solid rgba(0, 128, 0, 0.3);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.light-mode .about_me_details {
  background-color: #ffffff;
  border: 2px solid rgba(0, 128, 0, 0.3);
}

/* Light mode - Form inputs */
.light-mode .contact_form input,
.light-mode .contact_form textarea {
  background-color: #ffffff;
  border: 1px solid #ccc;
  color: #212121;
}

/* Light mode - Footer */
.light-mode footer {
  background-color: #ffffff;
  color: #212121;
}

.light-mode .fa_icons {
  color: #212121;
}

.light-mode .fa_icons:hover {
  color: green;
}

/* Light mode - Project cards */
.light-mode .project_links,
.light-mode .github_icon {
  border: 1px solid #ccc;
}

.light-mode .github_icon {
  background-color: green;
}

.light-mode .github_icon:hover {
  background-color: #0080007f;
}

.light-mode .project_links a {
  color: green;
}

.light-mode .project_stack p {
  border: 1px solid #ccc;
  background-color: #f0f0f0;
}

/* Light mode - Hamburger menu */
.light-mode .hamburger-icon span {
  background-color: #212121;
}

.light-mode .menu-links {
  background-color: #ffffff;
}

/* Light mode - Progress bars */
.light-mode .stack .progress_bar {
  background-color: #e2e8f0;
}

/* Light mode - Button for theme toggle in navbar */
.light-mode .theme-toggle {
  border-color: rgba(0, 128, 0, 0.5);
  color: green;
}

/* Light mode - Section headings remain visible */
.light-mode .section-head {
  color: #212121;
}

/* Light mode - Text remains readable */
.light-mode .intro,
.light-mode .about_me_text,
.light-mode .project_info {
  color: #212121;
}
.light-mode .footer_details p {
  color: green;
}

.light-mode .btn-primary {
  color: green;
  border: 2px solid green;
}

.light-mode .btn-primary:hover {
  background-color: green;
  color: #f5f5f5;
}

.light-mode .btn-secondary {
  color: #fff;
  border: 2px solid green;
  background-color: green;
}

.light-mode .btn-secondary:hover {
  background-color: #f5f5f5;
  color: green;
}

.light-mode .tech_name p {
  color: #212121;
}

.light-mode .project_progress.completed {
  color: #008236;
  background-color: #ddfce7 !important;
  border: solid 1px #e2e8f0;
}

.light-mode .project_progress.ongoing {
  color: #bf4c00;
  background-color: #fff2c7 !important;
  border: solid 1px #e2e8f0;
}

/* Back to top */
.back_to_top {
  position: fixed;
  bottom: 20px;
  right: 20px;
background: green;
box-shadow:0 0 10px rgba(0,255,0,0.5);
color: white;
  height: 3.5rem;
  width: 3.5rem;
  border-radius: 50%;
  text-align: center;
  cursor: pointer;
  font-size: 1rem;
  display: none;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  z-index: 1000;
  animation: pulse 2s infinite;
}

@keyframes pulse{
  50%{
    opacity: .5;
  }
}