/*=============== GOOGLE FONTS ===============*/
@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap");

/*=============== VARIABLES CSS ===============*/
:root {
  --header-height: 3.5rem;

  /*========== Colors ==========*/
  /*Color mode HSL(hue, saturation, lightness)*/
  /* 
      Change favorite color
      Default: hsl(162, 100%, 40%)
      Orange: hsl(14, 100%, 65%) - Blue: hsl(210, 100%, 70%)
      Pink: hsl(356, 100%, 75%) - Purple: hsl(250, 100%, 75%)

      For more colors visit: https://colors.dopely.top/color-pedia
      -> Choose any color 
      -> click on tab (Color Conversion)
      -> Copy the color mode (HSL)
  */

  --hue: 162;
  --first-color: hsl(var(--hue), 100%, 80%);
  --first-color-alt: hsl(var(--hue), 56%, 35%);
  --title-color: hsl(228, 8%, 95%);
  --text-color: hsl(228, 8%, 65%);
  --body-color: hsl(228, 15%, 20%);
  --container-color: hsl(228, 15%, 15%);

  /*========== Font and typography ==========*/
  /*.5rem = 8px | 1rem = 16px ...*/
  --body-font: "Poppins", sans-serif;
  --biggest-font-size: 2rem;
  --bigger-font-size: 1.25rem;
  --h1-font-size: 1.5rem;
  --h2-font-size: 1.25rem;
  --h3-font-size: 1rem;
  --normal-font-size: 0.938rem;
  --small-font-size: 0.813rem;
  --smaller-font-size: 0.75rem;

  /*========== Font weight ==========*/
  --font-regular: 400;
  --font-medium: 500;
  --font-semi-bold: 600;

  /*========== z index ==========*/
  --z-tooltip: 10;
  --z-fixed: 100;
}

/*========== Responsive typography ==========*/
@media screen and (min-width: 1152px) {
  :root {
    --biggest-font-size: 4rem;
    --bigger-font-size: 2rem;
    --h1-font-size: 2.25rem;
    --h2-font-size: 1.5rem;
    --h3-font-size: 1.25rem;
    --normal-font-size: 1rem;
    --small-font-size: 0.875rem;
    --smaller-font-size: 0.813rem;
  }
}

/*=============== BASE ===============*/
* {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

html {
  scroll-behavior:smooth;
}

input,
textarea,
button,
body {
  font-family: var(--body-font);
  font-size: var(--normal-font-size);
}

body {
  background-color: var(--body-color);
  color: var(--text-color);
}

input,
textarea,
button {
  outline: none;
  border: none;
}

h1,
h2,
h3,
h4 {
  color: var(--title-color);
  font-weight: var(--font-medium);
}

ul {
  list-style: none;
}

a {
  text-decoration: none;
}

img,
svg {
  max-width: 100%;
  height: auto;
}

/*=============== REUSABLE CSS CLASSES ===============*/
.container {
  max-width: 1920px;
  margin-inline: 1.5rem;
}

.grid {
  display: grid;
  gap: 1.5rem;
}

.section {
  padding: 4rem 1rem; /* top/bottom spacing for each section */
}

.section__title {
  font-size: var(--h2-font-size);
  margin-bottom: 0.5rem;
  text-align: center;
}

.section__subtitle {
  display: block;
  font-size: var(--small-font-size);
  margin-bottom: 2rem;
  text-align: center;
  color: var(--text-color-light);
}

.section__subtitle span {
  color: var(--first-color);
}

.main {
  overflow: hidden; /* For animation ScrollReveal */
}

/*=============== HEADER & NAV ===============*/
.header {
  position: fixed;
  width: 100%;
  background-color: var(--container-color);
  top: 0;
  left: 0;
  z-index: var(--z-fixed);
}

.nav {
  height: var(--header-height);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav__logo {
  color: var(--title-color);
  font-weight: var(--font-medium);
}

.nav__logo span {
  color: var(--first-color);
}

.nav__toggle,
.nav__close {
  display: flex;
  font-size: 1.25rem;
  color: var(--title-color);
  cursor: pointer;
}

/* Navigation for mobile devices */
@media screen and (max-width: 1920px) {
  .nav__menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    height: 100%;
    padding: 5rem 2rem;
    background-color: hsla(0, 0%, 10%, 0.3);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    transition: right 0.4s;
    z-index: 100;
  }

  .nav__list {
    display: flex;
    flex-direction: column;
    row-gap: 2.5rem;
  }
  .nav__link:hover {
    color: var(--first-color);
  }
  .nav__close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
  }
  .nav__link {
    color: var(--title-color);
    font-weight: var(--font-medium);
    transition: color 0.4s;
  }
}

/* Show menu */
.show-menu {
  right: 0;
}

/* Add blur to header */
.blur-header {
  background-color: transparent;
}

.blur-header::after {
  content: "";
  position: absolute;
  width: 100%; /* Changed from 1000% */
  height: 100%;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  background-color: hsla(0, 0%, 10%, 0.3);
  top: 0;
  left: 0;
  z-index: -1;
}

/* Active link */
.active-link {
  color: rgb(255, 0, 0);
}

/*=============== HOME ===============*/
.home {
  background-color: var(--container-color);
}

.home__container {
  padding-top: 2rem;
  row-gap: 2.5rem;
}

.home__content {
  display: grid;
  row-gap: 2rem;
}

.home__data {
  text-align: center;
}

.home__subtitle,
.home__education {
  font-size: var(--bigger-font-size);
}

.home__subtitle span,
.home__education {
  font-size: var(--first-color);
}

.home__title {
  font-size: var(--bigger-font-size);
  font-weight: var(--font-semi-bold);
}

.home__description {
  display: flex;
  justify-content: center;
  column-gap: 1.25rem;
}

.home__social {
  display: flex;
  justify-content: center;
  column-gap: 1.25rem;
  margin-top: 1.5rem;
}

.home__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgb(0, 110, 110);
  width: 2.5rem;
  height: 2.5rem;
  color: var(--title-color);
  font-size: 1.25rem;
  border-radius: 50%;
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  transition: transform 0.3s, background-color 0.4s, box-shadow 0.4s;
}

.home__social-link:hover {
  background-color: var(--first-color);
  transform: translateY(-0.25rem);
  box-shadow: 0 8px 25px rgba(0, 240, 255, 0.7);
}

.home__blob {
  fill: #ff0022;
  filter: drop-shadow(0 12px 12px rgba(50, 238, 255, 0.666));
}

.home__img {
  width: 600px;
  transform: translateY(5%);
}
/*=============== BUTTON ===============*/
.button {
  display: inline-block;
  background-color: rgba(9, 243, 231, 0.792);
  padding: 1rem 1.75rem;
  border-radius: 0.5rem;
  color: rgb(255, 255, 255);
  font-weight: var(--font-medium);
  transition: box-shadow 0.5s;
}
.button:hover {
  box-shadow: 0 8px 25px rgba(0, 240, 255, 0.7);
}

/*=============== ABOUT ===============*/
.about__container {
  row-gap: 2.5rem;
}
.about__description {
  margin-bottom: 2rem;
}

.about__image {
  justify-self: center;
}

.about__blob {
  width: 320px;
}
.about__blob path {
  stroke: var(--first-color);
}

/*=============== SKILLS ===============*/
.skills {
  background-color: var(--container-color);
  padding: 5rem 0;
}

.skill__container {
  padding-bottom: 2rem;
  row-gap: 3.5rem;
}

.skill__data {
  text-align: center;
  margin-bottom: 3rem;
}

.skill__description {
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-color);
  line-height: 1.6;
}

.skill__content {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* Three equal columns */
  gap: 2rem; /* Space between columns */
  justify-content: center;
}

.skill__group {
  display: flex;
  flex-direction: column;
  row-gap: 1rem;
  list-style: decimal-leading-zero;
  padding-left: 1.5rem;
}

.skill__item {
  color: var(--title-color);
  font-weight: var(--font-medium);
  padding: 0.5rem 0;
  transition: all 0.3s ease;
  border-left: 2px solid var(--first-color);
  padding-left: 1rem;
}

.skill__item:hover {
  color: var(--first-color);
  transform: translateX(5px);
}

/* Responsive adjustments */
@media screen and (max-width: 992px) {
  .skill__content {
    grid-template-columns: repeat(2, 1fr); /* Two columns on medium screens */
  }
}

@media screen and (max-width: 576px) {
  .skill__content {
    grid-template-columns: 1fr; /* Single column on mobile */
  }

  .skills {
    padding: 3rem 0;
  }
}

/*=============== SERVICES ===============*/
.service__contain {
  row-gap: 2rem;
  padding-block: 1rem;
}

.service__card {
  text-align: center;
  background-color: var(--container-color);
  padding: 3rem 1.25rem;
  border-radius: 1rem;
  border: 2px solid var(--container-color); /* Added var() */
  transition: border 0.1s;
}

.service__icon {
  display: block;
  font-size: 4rem;
  color: var(--first-color);
  margin-bottom: 0.75rem;
}

.service__title {
  font-size: var(--h2-font-size);
  margin-bottom: 1.5rem;
}

.service__card:hover {
  border: 2px solid var(--first-color);
}
/*=============== PROJECTS ===============*/
/*Working on It*/
.projects__container {
  row-gap: 2rem;
}

.project__card {
  background-color: var(--container-color);
  padding: 1.5rem;
  border-radius: 1rem;
  transition: transform 0.4s;
}

.project__card:hover {
  transform: translateY(-0.5rem);
}

/*=============== CONTACT ===============*/
.container {
  padding-top: 1rem;
}

.contact__form,
.contact__group {
  display: grid;
  row-gap: 1rem;
}
.contact__form {
  position: relative;
}

.contact__input {
  padding: 1rem 1.25rem;
  border-radius: 0.5rem;
  background-color: var(--container-color);
  color: var(--title-color);
}

.contact__group::placeholder {
  color: var(--text-color);
}

.contact__form textarea {
  height: 11rem;
  resize: none;
  margin-bottom: 2rem;
}

.contact__button {
  justify-self: center;
  cursor: pointer;
}

.contact__message {
  position: absolute;
  left: 0;
  bottom: 4.5rem;
  font-size: var(--small-font-size);
}

/*=============== FOOTER ===============*/
.footer {
  background-color: var(--container-color);
  padding-block: 3.5rem 2rem;
}
.footer__container {
  row-gap: 2rem;
  text-align: center;
}

.footer__title {
  font-size: var(--h1-font-size);
  font-weight: var(--font-semi-bold);
  margin-bottom: 0.25rem;
}

.footer__title span {
  color: var(--first-color);
}
.footer__education {
  font-size: var(--normal-font-size);
}
.footer__social {
  display: flex;
  justify-content: center;
  column-gap: 1.25rem;
}

.footer__social-link {
  display: flex;
  background-color: var(--first-color-alt);
  padding: 0.5rem;
  color: var(--title-color);
  font-size: 1.5rem;
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  transition: transform 0.4s;
}

.footer__social-link:hover {
  transform: translateY(-0.25rem);
}

.footer__copy {
  font-size: var(--small-font-size);
  margin-top: 2rem;
}
/*=============== SCROLL BAR ===============*/
::-webkit-scrollbar {
  width: 0.6rem;
  border-radius: 0.5rem;
  background-color: hsl(228, 12%, 15%);
}
::-webkit-scrollbar-thumb {
  background-color: hsl(228, 8%, 35%);
  border-radius: 0.5rem;
}

::-webkit-scrollbar-thumb:hover {
  background-color: hsl(228, 8%, 50%);
}

/*=============== SCROLL UP ===============*/
.scrollup {
  position: fixed;
  right: 1rem;
  bottom: -50%;
  background-color: var(--body-color);
  padding: 6px;
  display: inline-flex;
  border-radius: 0.25rem;
  color: rgb(0, 223, 89);
  font-size: 1.25rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); /* Added proper shadow */
  z-index: var(--z-tooltip);
  transition: bottom 0.4s, transform 0.4s;
}
.scrollup:hover {
  transform: translateY(-0.25rem);
}

/* Show Scroll Up */
.show-scroll {
  bottom: 3rem;
}
/*=============== BREAKPOINTS ===============*/

/* For small devices */
@media screen and (max-width: 320px) {
  .container {
    margin-inline: 1rem;
  }

  .skill__container {
    grid-template-columns: max-content;
    row-gap: 1rem;
  }

  .service__card {
    padding: 1.5rem;
  }
}

/* For medium devices */
@media screen and (min-width: 576px) {
  .home__container,
  .about__container,
  .skill__container,
  .service__container,
  .project__container,
  .contact__container {
    grid-template-columns: 360px;
    justify-content: center;
  }
}

@media screen and (min-width: 768px) {
  .nav__menu {
    width: 55%;
  }

  .home__container,
  .about__container,
  .skill__container {
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }

  .home__data,
  .about__data,
  .skill__data,
  .section__subtitle,
  .section__title {
    text-align: initial;
  }

  .home__social {
    justify-content: initial;
  }

  .home__blob,
  .about__blob {
    width: 400px;
  }

  .about__data {
    order: 1;
  }

  .service__container,
  .project__container {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ===================== Desktop Styles ===================== */
/* For large devices (1024px and up) */
@media screen and (min-width: 1024px) {
  
  .section {
    padding-block: 7rem 2rem;
  }

  .nav__menu {
    width: 55%;
  }

  .section__subtitle {
    font-size: var(--normal-font-size);
  }

  .nav {
    height: calc(var(--header-height) + 1.5rem);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1.5rem;
  }
  /* Show desktop menu and hide toggle buttons */
  .nav__menu {
    position: static;
    width: initial;
    height: initial;
    padding: 0;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    display: flex;
    justify-content: flex-end;
    width: 55%;
  }

  .nav__list {
    display: flex;
    flex-direction: row;
    row-gap: 2rem;
    flex-direction: row;
    column-gap: 3rem;
  }

  .nav__toggle,
  .nav__close {
    display: block;
    font-size: 1.5rem;
    cursor: pointer;
    display: none;
  }

  /* Active link style */
  .active-link {
    color: var(--first-color);
  }

  /* Show menu on mobile when active */
  .show-menu {
    right: 0;
  }

  .blur-header::after {
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
  }
}
