/**
 * Root Variables for Theme Consistency
 *
 * @format
 */

:root {
  --background-color: #fafafa;
  --card-color: #ffffff;
  --primary-text-color: #2e2e2e;
  --secondary-text-color: #6b6b6b;
  --border-color: #dcdcdc;
  --accent-color: #28cd86;
  --shadow-color: rgba(0, 0, 0, 0.08);
  --font-family: "Inter", sans-serif;
  --hover-color: #f0f0f0;
}

html {
  scroll-behavior: smooth;
}

/* Global Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: var(--font-family);
  color: var(--primary-text-color);
}

body {
  background-color: var(--background-color);
  font-family: "Poppins", sans-serif;
  line-height: 1.6;
}

/* Navbar */
.NavContainer {
  position: fixed; /* Keep navbar fixed at the top */
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--card-color);
  box-shadow: 0 1px 5px var(--shadow-color);
  padding: 0 20px;
  transition: transform 0.3s ease, opacity 0.3s ease;
  z-index: 1000; /* Make sure navbar is on top */
}

.NavContainer.hidden {
  transform: translateY(-100%); /* Move navbar out of view */
  opacity: 0; /* Optional: add opacity transition */
}

.NavBar {
  display: flex;
  width: 100%;
  max-width: 1200px;
  justify-content: space-between;
  align-items: center;
  animation: fade_down 1.5s 500ms ease-in-out;
}

.LogoContainer {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--primary-text-color);
}

.LogoContainer span {
  background-color: var(--accent-color);
  color: var(--card-color);
  padding: 5px 10px;
  border-radius: 20px;
}

.LinkContainer a {
  text-decoration: none;
  font-size: 1rem;
  color: var(--secondary-text-color);
  padding: 5px 15px;
  border-radius: 5px;
  transition: background-color 0.2s ease;
}

.LinkContainer a:hover {
  background-color: var(--hover-color);
}

.HamburgerIcon {
  display: none;
  font-size: 24px;
  cursor: pointer;
}

/* Hero Section */
.HeroSectionContainer {
  display: flex;
  width: 100%;
  height: 90vh;
  align-items: center;
  justify-content: center;
  background-color: var(--card-color);
  box-shadow: 0px 1px 5px var(--shadow-color);
  margin-bottom: 40px;
  margin-top: 50px;
}

.HeroSectionGrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  width: 80%;
  width: 1200px;
  place-items: center;
}

.HeroText {
  display: flex;
  flex-direction: column;
  gap: 15px;
  animation: fade-left 2s 300ms ease-in-out;
}

.HeroTitleText {
  margin-left: 5px;
}

.HeroHeader {
  font-size: 2.5rem;
  font-weight: 700;
  margin-right: 5px;
}

.SocialContainer img {
  width: auto;
  height: 24px;
  cursor: pointer;
  transition: opacity 0.2s ease;
  margin-left: 10px;
}

.SocialContainer img:hover {
  opacity: 0.7;
}

.HeroButton button {
  margin-top: 15px;
  padding: 10px 20px;
  border: none;
  background-color: var(--primary-text-color);
  color: var(--card-color);
  border-radius: 8px;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.2s ease;
}

.HeroButton button:hover {
  background-color: var(--hover-color);
  color: var(--primary-text-color);
}

.HeroImage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  animation: fade-right 2s 300ms ease-in-out;
}

/* About Me Section */
.AboutMeContainer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 50px 20px;
}

.AboutMeHeading p {
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 5px;
}

.AboutMeGridContainer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  width: 80%;
  max-width: 1200px;
  place-items: center;
}

.AboutMeImageContainer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
}

.AboutMeContentContainer {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.AboutMeHeader {
  font-size: 1.8rem;
  font-weight: 700;
}

.AboutSubText {
  font-size: 1.2rem;
  color: var(--secondary-text-color);
}

.AboutButton button {
  margin-top: 10px;
  padding: 10px 20px;
  border: none;
  background-color: var(--primary-text-color);
  color: var(--card-color);
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.AboutButton button:hover {
  background-color: var(--hover-color);
  color: var(--primary-text-color);
}

/* Project Section */
.ProjectContainer {
  max-width: 1200px;
  margin: 40px auto;
  padding: 20px;
  background-color: var(--card-color);
  box-shadow: 0px 4px 10px var(--shadow-color);
  border-radius: 8px;
}

.ProjectHeading p {
  font-size: 2.5em;
}

.ProjectHeading,
.ProjectSubText {
  margin-bottom: 20px;
}

.FilterContainer {
  margin-bottom: 20px;
}

.filter-btn {
  padding: 10px 20px;
  margin: 5px;
  cursor: pointer;
  border: none;
  background-color: var(--accent-color);
  border-radius: 5px;
}

.filter-btn:hover {
  background-color: #ddd;
}

.filter-btn.active {
  background-color: #118d57;
  color: white;
}

.ProjectGridContainer {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 20px;
  place-items: center;
}

.ProjectCard {
  background-color: transparent;
  width: 520px;
  height: 370px;
  perspective: 1000px;
  font-family: sans-serif;
}

.ProjectCard img {
  width: 520px;
  height: 320px;
  object-fit: cover;
  border-radius: 15px;
}

.title {
  font-size: 1.5em;
  font-weight: 900;
  text-align: center;
  margin: 0;
}

.ProjectCardInner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.8s;
  transform-style: preserve-3d;
}

.ProjectCard:hover .ProjectCardInner {
  transform: rotateY(180deg);
}

.ProjectCardFront,
.ProjectCardBack {
  box-shadow: var(--shadow-color);
  position: absolute;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border: 1px solid var(--border-color);
  border-radius: 1rem;
}

.ProjectCardFront {
  background: var(--background-color);
  color: black;
}

.ProjectCardBack {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  background: var(--background-color);
  color: black;
  transform: rotateY(180deg);
  padding: 3px;
}

.description {
  width: 390px;
  text-align: start;
}

.ProjectCard .category {
  display: flex;
  justify-content: center;
  align-items: center;
  width: fit-content;
  font-size: 0.9rem;
  background-color: var(--accent-color);
  color: white;
  margin-left: 5px;
  margin-bottom: 10px;
  padding-top: 2px;
  padding-bottom: 2px;
  padding-right: 5px;
  padding-left: 5px;
  border-radius: 10px;
}

.github-link {
  display: inline-block;
  margin: 10px 0;
  transition: transform 0.3s;
}

.github-link img {
  width: 30px;
  height: auto;
}

.github-link:hover {
  transform: scale(1.1);
}

/* EXPERIENCE  */
.ExperienceContainer {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  font-family: Arial, sans-serif;
}

.ExperienceHeading p {
  text-align: center;
  font-size: 2.5em;
}

.ExperienceSubText p {
  text-align: center;
  font-size: 1.5em;
  margin: 10px 0;
}

/* Timeline Styling */
.ExperienceTimeline {
  position: relative;
  margin: 20px 0;
  padding-left: 30px;
  border-left: 3px solid var(--accent-color);
}

.ExperienceCard {
  position: relative;
  margin: 20px 0;
  padding: 10px 20px;
  background: #f9f9f9;
  border-radius: 8px;
  box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

.ExperienceCard::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 20px;
  width: 16px;
  height: 16px;
  background-color: var(--accent-color);
  border-radius: 50%;
}

.ExperienceContent p {
  margin: 5px 0;
  font-size: 1em;
  color: #333;
}

.ExperienceRole p {
  font-weight: bold;
  font-size: 1.2em;
}

.ExperienceCompany p {
  font-style: italic;
  color: #666;
}

.ExperienceDuration p {
  color: #999;
}

.ExperienceDescription p {
  color: #555;
}

/* Certificate Section */
.CertificateContainer {
  max-width: 1200px;
  margin: 40px auto;
  padding: 20px;
  background-color: var(--card-color);
  box-shadow: 0px 4px 10px var(--shadow-color);
  border-radius: 8px;
}

.CertificateHeading p {
  font-size: 2.5em;
}

.CertificateHeading,
.CertificateSubText {
  margin-bottom: 20px;
}

.CertificateGridContainer {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 20px;
  place-items: center;
}

.CertificateCard {
  background-color: transparent;
  width: 520px;
  height: 370px;
  perspective: 1000px;
  font-family: sans-serif;
}

.CertificateCard img {
  width: 520px;
  height: 370px;
  object-fit: cover;
  border-radius: 15px;
}

.title {
  font-size: 1.5em;
  font-weight: 900;
  text-align: center;
  margin: 0;
}

.CertificateCardInner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.8s;
  transform-style: preserve-3d;
}

.CertificateCard:hover .CertificateCardInner {
  transform: rotateY(180deg);
}

.CertificateCardFront,
.CertificateCardBack {
  box-shadow: var(--shadow-color);
  position: absolute;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border: 1px solid var(--border-color);
  border-radius: 1rem;
}

.CertificateCardFront {
  background: var(--background-color);
  color: black;
}

.CertificateCardBack {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  background: var(--background-color);
  color: black;
  transform: rotateY(180deg);
  padding: 3px;
}

.description {
  width: 390px;
  text-align: start;
}

/* Contact Me Section */
.ContactSection {
  padding: 60px 20px;
  background-color: #f9f9f9;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}

.ContactContent h2 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 10px;
  color: #333;
  text-align: center;
}

.ContactContent p {
  font-size: 18px;
  color: #666;
  text-align: center;
  max-width: 600px;
}

.ContactFormContainer {
  width: 100%;
  max-width: 800px;
}

.ContactForm {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.FormRow {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.FormRow label,
.FormRow input,
.FormRow textarea {
  width: 100%;
  padding: 15px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 16px;
  background-color: #fff;
  color: #333;
  transition: border 0.3s;
}

.FormRow input:focus,
.FormRow textarea:focus {
  border-color: var(--accent-color);
  outline: none;
}

textarea {
  resize: none;
  max-width: 100%;
  /* Ensures textarea doesn't shrink */
}

button {
  align-self: center;
  padding: 15px 30px;
  background-color: #5ae4a8;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 18px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: #0dd07c;
}

/* Footer Section */
.Footer {
  background-color: #333;
  color: #f9f9f9;
  padding: 40px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.FooterContent {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  width: 100%;
  max-width: 800px;
  text-align: center;
}

.FooterLogo p {
  font-size: 24px;
  font-weight: 700;
  margin: 0;
  color: #fff;
}

.FooterLogo span {
  color: var(--accent-color);
}

.FooterLinks {
  display: flex;
  gap: 15px;
}

.FooterLinks a {
  color: #ddd;
  text-decoration: none;
  font-size: 16px;
  transition: color 0.3s;
}

.FooterLinks a:hover {
  color: var(--accent-color);
}

.FooterSocials a {
  margin: 0 10px;
}

.FooterSocials img {
  width: 30px;
  height: 30px;
  filter: brightness(0) invert(1);
  transition: transform 0.3s;
}

.FooterSocials a:hover img {
  transform: scale(1.2);
}

.FooterCopyright p {
  border-top: 1px solid #444;
  padding-top: 15px;
  width: 100%;
  text-align: center;
  font-size: 14px;
  color: #bbb;
}

/* Animations */

@keyframes fade_down {
  0% {
    opacity: 0;
    transform: translateY(-100px);
  }

  100% {
    opacity: 1;
    transform: translateY(0px);
  }
}

@keyframes fade-left {
  0% {
    opacity: 0;
    transform: translateX(-150px);
  }

  100% {
    opacity: 1;
    transform: translateX(0px);
  }
}

@keyframes fade-right {
  0% {
    opacity: 0;
    transform: translateX(150px);
  }

  100% {
    opacity: 1;
    transform: translateX(0px);
  }
}

/* Responsive */

@media only screen and (max-width: 1024px) {
  body {
    overflow-x: hidden;
  }

  .NavContainer {
    width: 100%;
  }

  .NavBar {
    width: 100%;
  }

  .HeroSectionContainer {
    width: 100%;
  }

  .HeroSectionGrid {
    width: 100%;
  }

  .HeroTitleText h2 {
    font-size: 16px;
    color: var(--secondary-text-color);
  }

  .HeroHeader h1 {
    font-size: larger;
  }

  .HeroImage {
    width: 350px;
    height: 350px;
  }

  .AboutMeContainer {
    width: 100%;
  }

  .AboutMeGridContainer {
    width: 100%;
  }

  .AboutMeImageContainer {
    width: 350px;
    height: 350px;
  }

  .AboutMeTitleText {
    font-size: 16px;
    color: var(--secondary-text-color);
  }

  .AboutMeHeader {
    font-size: larger;
  }

  .AboutSubText {
    font-size: medium;
  }

  .ProjectContainer {
    width: 100%;
  }

  .ProjectGridContainer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    place-items: center;
  }

  .CertificateContainer {
    width: 100%;
  }

  .CertificateGridContainer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    place-items: center;
  }
}

@media only screen and (max-width: 768px) {
  .LinkContainer {
    max-height: 0;
    overflow: hidden;
    flex-direction: column;
    position: absolute;
    top: 60px;
    right: 0;
    background-color: #fff;
    padding: 0;
    width: 200px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: max-height 0.3s ease-in-out;
  }
  .LinkContainer a {
    padding: 10px 0;
    display: block;
    text-align: center;
  }
  .HamburgerIcon {
    display: block;
  }
  .HamburgerIcon img {
    width: 25px;
    height: 25px;
  }
  .LinkContainer.show {
    max-height: 300px;
    padding: 10px;
  }
  .LogoContainer p {
    font-size: 16px;
  }
  .LinkContainer a {
    font-size: 16px;
    padding: 5px 8px;
  }

  .HeroSectionContainer {
    width: 100%;
  }

  .HeroSectionGrid {
    width: 100%;
  }

  .HeroTitleText h2 {
    font-size: 16px;
    color: var(--secondary-text-color);
  }

  .HeroHeader h1 {
    font-size: 36px;
  }

  .HeroImage {
    width: 320px;
    height: 320px;
  }

  .AboutMeContainer {
    width: 100%;
  }

  .AboutMeGridContainer {
    width: 100%;
  }

  .AboutMeImageContainer {
    width: 320px;
    height: 320px;
  }

  .AboutMeTitleText {
    font-size: 16px;
    color: var(--secondary-text-color);
  }

  .AboutMeHeader {
    font-size: large;
  }

  .AboutSubText {
    font-size: medium;
  }

  .ProjectContainer {
    width: 100%;
  }

  .ProjectGridContainer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    place-items: center;
  }

  .CertificateContainer {
    width: 100%;
  }

  .CertificateGridContainer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    place-items: center;
  }
}

@media only screen and (max-width: 425px) {
  .HeroSectionContainer {
    width: 100%;
  }

  .HeroSectionGrid {
    display: flex;
    width: 100%;
    flex-direction: column-reverse;
  }

  .HeroText {
    text-align: center;
  }

  .HeroTitleText h2 {
    font-size: 14px;
    color: var(--secondary-text-color);
  }

  .HeroHeader h1 {
    font-size: larger;
  }

  .HeroImage {
    width: 250px;
    height: 250px;
  }
  .HeroButton {
    display: none;
  }
  .SocialContainer img {
    width: 22px;
    height: 22px;
  }

  .AboutMeContainer {
    width: 100%;
  }

  .AboutMeGridContainer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .AboutMeImageContainer {
    width: 250px;
    height: 250px;
  }

  .AboutMeTitleText {
    font-size: 16px;
    color: var(--secondary-text-color);
  }

  .AboutMeHeader {
    font-size: larger;
  }

  .AboutSubText {
    font-size: medium;
  }

  .ProjectContainer {
    width: 100%;
  }

  .ProjectGridContainer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    place-items: center;
  }

  .ProjectCard {
    width: 350px;
    height: 350px;
  }

  .ProjectCard img {
    width: 350px;
    height: 300px;
  }

  .description {
    width: 290px;
  }

  .ProjectCardBack img {
    width: 25px;
    height: 25px;
    margin-bottom: 10px;
  }

  .CertificateContainer {
    width: 100%;
  }

  .CertificateGridContainer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    place-items: center;
  }

  .CertificateCard {
    width: 350px;
    height: 350px;
  }

  .CertificateCard img {
    width: 100%;
    height: auto;
    object-fit: cover;
    object-position: center center;
  }

  .description {
    width: 290px;
  }

  .Footer {
    display: flex;
    flex-direction: column;
  }

  .FooterLinks {
    display: flex;
    flex-direction: column;
  }
}

@media only screen and (max-width: 320px) {
  .HeroSectionContainer {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: auto;
  }

  .HeroImage {
    margin-top: 50px;
    width: 250px;
    height: 250px;
  }

  .SocialContainer {
    margin-bottom: 10px;
  }

  .ProjectCard,
  .CertificateCard {
    width: 250px;
    height: 250px;
  }

  .category {
    margin-top: 10px;
  }

  .ProjectCard img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
  }

  .ProjectCardBack {
    width: 100%;
    height: 100%;
    padding: 10px;
  }

  .github-link {
    width: 20px;
    height: 20px;
  }

  .title {
    width: 80%;
    font-size: small;
  }

  .description {
    width: 70%;
    font-size: smaller;
  }

  .CertificateCard img {
    width: 100%;
    height: auto;
    object-fit: cover;
    object-position: center center;
  }
}
