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

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

  --first-hue: 198;
  --sat: 100%;
  --lig: 40%;
  --second-hue: 219;
  --first-color: hsl(var(--first-hue), var(--sat), var(--lig));
  --first-color-alt: hsl(var(--first-hue), var(--sat), 60%); /* -4% */
  --title-color: hsl(var(--second-hue), 15%, 95%);
  --text-color: hsl(var(--second-hue), 8%, 75%);
  --text-color-light: hsl(var(--second-hue), 4%, 55%);
  --body-color: hsl(var(--second-hue), 48%, 8%);
  --container-color: hsl(var(--second-hue), 32%, 12%);

  /*========== Font and typography ==========*/
  /*.5rem = 8px | 1rem = 16px ...*/
  --body-font: "Poppins", sans-serif;
  --biggest-font-size: 1.75rem;
  --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;
  --tiny-font-size: 0.625rem;

  /*========== Font weight ==========*/
  --font-medium: 500;
  --font-semibold: 600;

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

/* Responsive typography */
@media screen and (min-width: 968px) {
  :root {
    --biggest-font-size: 2.5rem;
    --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;
}

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

body {
  background-color: var(--body-color);
  color: var(--text-color);
  transition: 0.4s; /* for light mode animation */
}

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

ul {
  list-style: none;
}

a {
  text-decoration: none;
}

button {
  cursor: pointer;
  border: none;
  outline: none;
}

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

.container {
  max-width: 968px;
  margin-left: 1rem;
  margin-right: 1rem;
}

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

.main {
  overflow: hidden;
}

.section {
  padding: 1.5rem 0 1rem;
}

.section__title
{
  text-align: center;
}

.section__title {
  font-size: var(--h2-font-size);
  color: var(--first-color);
  margin-bottom: 2rem;
}


/*=============== HEADER & NAV===============*/
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--body-color);
  z-index: var(--z-fixed);
}
.nav {
  height: var(--header-height);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.nav__logo {
  color: var(--first-color);
  font-weight: var(--font-medium);
  transition: 0.4;
}
.nav__logo:hover {
  color: var(--first-color-alt);
}
.nav__menu {
  position: fixed;
  bottom: 1rem;
  background-color: hsl(var(--second-hue), 32%, 16%, 0.8);
  width: 90%;
  padding: 1rem 2.25rem;
  border-radius: 4rem;
  backdrop-filter: blur(10px);
}
.nav__list {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.nav__link {
  color: var(--text-color);
  font-size: 1.25rem;
  padding: 0.4rem;
  display: flex;
  border-radius: 5rem;
}

/* Active link */
.active-link {
  background: linear-gradient(
    180deg,
    hsla(var(--first-hue), var(--sat), var(--lig), 1),
    hsla(var(--first-hue), var(--sat), var(--lig), 0.2)
  );
  box-shadow: 0 0 16px hsla(var(--first-hue), var(--sat), var(--lig), 0.4);
  color: var(--title-color);
}

/* Change background header */
.scroll-header {
  box-shadow: 0 4px 4px hsla(0, 0%, 4%, 0.3);
}

/*=============== THEME ===============*/
.change-theme {
  font-size: 1.25rem;
  cursor: pointer;
  transition: 0.3s;
}
.change-theme:hover {
  color: var(--first-color);
}
/*========== Variables Dark theme ==========*/
body.light-theme {
  --title-color: hsl(var(--second-hue), 15%, 15%);
  --text-color: hsl(var(--second-hue), 8%, 35%);
  --body-color: hsl(var(--second-hue), 100%, 99%);
  --container-color: #fff;
}

/*========== 
    Color changes in some parts of 
    the website, in light theme
==========*/
.light-theme .scroll-header {
  box-shadow: 0 2px 4px hsla(0, 0%, 1%, 0.1);
}
.light-theme .nav__menu {
  background-color: hsla(var(--second-hue), 32%, 90%, 0.8);
}
.light-theme .section__subtitle {
  color: var(--text-color);
}
.light-theme .home__social-link {
  box-shadow: 0 2px 8px hsla(var(--second-hue), 48%, 8%, 0.1);
}
.light-theme .home__social::after,
.light-theme .footer__social-link {
  background-color: var(--title-color);
}
.light-theme .home__social-link,
.light-theme .home__scroll,
.light-theme .button,
.light-theme .button:hover,
.light-theme .active-work,
.light-theme .footer__title,
.light-theme .footer__link,
.light-theme .footer__copy {
  color: var(--title-color);
}
.light-theme .about__box {
  box-shadow: 0 2px 8px hsla(var(--second-hue), 48%, 8%, 0.1);
}
.light-theme .skills__content,
.light-theme .services__card,
.light-theme .work__card,
.light-theme .contact__card {
  box-shadow: 0 2px 16px hsla(var(--second-hue), 48%, 8%, 0.1);
}
.light-theme::-webkit-scrollbar {
  background-color: hsl(var(--second-hue), 8%, 66%);
}
.light-theme::-webkit-scrollbar-thumb {
  background-color: hsl(var(--second-hue), 8%, 54%);
}
.light-theme::-webkit-scrollbar-thumb:hover {
  background-color: hsl(var(--second-hue), 8%, 44%);
}

/*=============== HOME ===============*/
.home__container {
  position: relative;
  row-gap: 4.5rem;
  padding-top: 2rem;
}
.home__data {
  text-align: center;
}

.home__education {
  font-size: var(--small-font-size);
  font-weight: var(--font-medium);
}

.home__education {
  color: var(--text-color);
  margin-bottom: 2.5rem;
}

.home__name {
  font-size: var(--biggest-font-size);
}
.home__img {
  width: auto;
}

.home__handle {
  justify-self: center;
  width: 250px;
  height: 290px;
  background: linear-gradient(
    180deg,
    hsla(var(--first-hue), var(--sat), var(--lig), 1),
    hsla(var(--first-hue), var(--sat), var(--lig), 0.2)
  );
  border-radius: 10rem 10rem 1rem 1rem;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.home__buttons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
}

.home__scroll {
  position: absolute;
}

.social-link {
  width: max-content;
  background-color: var(--container-color);
  color: var(--first-color);
  padding: 0.25rem;
  border-radius: 0.25rem;
  display: flex;
  font: 1rem;
  transition: 0.4s;
}
.social-link:hover {
  background-color: var(--first-color);
  color: #fff;
}

/*=============== BUTTONS ===============*/
.button {
  display: flex;
  background-color: var(--first-color);
  color: var(--body-color);
  padding: 0.75rem;
  justify-content: center;
  border-radius: 0.5rem;
  font-weight: var(--font-medium);
  transition: 0.4s;
}
.button:hover {
  background-color: var(--first-color-alt);
  color: var(--body-color);
}
.button--ghost {
  background-color: transparent;
  border: 2px solid var(--first-color);
  color: var(--first-color);
}

/*=============== ABOUT ===============*/
.about__container {
  row-gap: 2.5rem;
  justify-content: center;
  padding-top: 0rem;
}
.about__img {
  width: 120px;
  border-radius: 1.5rem;
  justify-self: center;
}
.about__data {
  text-align: center;
}
.about__info {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: .5rem;
}
.about__box {
  background-color: var(--container-color);
  border-radius: 0.75rem;
  padding: 0.75rem 0.75rem;
  justify-content: center;
  column-gap: 2.5rem;
}

.about__description{
  text-align: center;
}

.about__icon {
  font-size: 1.5rem;
  color: var(--first-color);
  margin-bottom: 0.5rem;
}
.about__title {
  font-size: var(--small-font-size);
}

/*=============== SKILLS ===============*/
.skills__container {
  row-gap: 2rem;
  padding-top: 1rem;
}
.skills__content {
  background-color: var(--container-color);
  padding: 1.5rem;
  border-radius: 1.25rem;
}
.skills__title {
  font-size: var(--normal-font-size);
  font-weight: var(--font-medium);
  color: var(--first-color);
  text-align: center;
  margin-bottom: 1.5rem;
}
.skills__box {
  display: flex;
  justify-content: center;
  column-gap: 2.5rem;
}
.skills__group {
  display: grid;
  align-content: flex-start;
  row-gap: 1rem;
}
.skills__data {
  display: flex;
  column-gap: 0.5rem;
}
.skills .bx-check-circle {
  font-size: 1rem;
  color: var(--first-color);
}
.skills__name {
  font-size: var(--normal-font-size);
  font-weight: var(--font-medium);
  line-height: 18px;
}
.skills__level {
  font-size: var(--tiny-font-size);
}



/*=============== WORK ===============*/
.work__container {
  padding-top: 1rem;
}
.work__filters {
  display: flex;
  justify-content: center;
  align-items: center;
  column-gap: 0.75rem;
  margin-bottom: 2rem;
}
.work__item {
  cursor: pointer;
  color: var(--title-color);
  padding: 0.25rem 0.75rem;
  font-size: var(--font-medium);
  border-radius: 0.5rem;
}
.work__card {
  background-color: var(--container-color);
  padding: 1rem;
  border-radius: 1rem;
}
.work__img {
  border-radius: 1rem;
  margin-bottom: 0.75rem;
}
.work__title {
  font-size: var(--normal-font-size);
  font-weight: var(--font-medium);
  margin-bottom: 0.25rem;
  justify-content: center;
  text-align: center;
}
.work__button {
  color: var(--first-color);
  font-size: var(--small-font-size);
  display: flex;
  align-items: center;
  justify-content: right;
  column-gap: 0.25rem;
}
.work__button:hover .work__icon {
  transform: translateX(0.25rem);
}
.work__icon {
  font-size: 1rem;
  transition: 0.4s;
}

/* Active item work*/
.active-work {
  background-color: var(--first-color);
  color: var(--body-color);
}

/*=============== CONTACT ===============*/
.contact__container {
  row-gap: 3rem;
  padding-bottom: 3rem;
}
.contact__title {
  text-align: center;
  font-size: var(--h3-font-size);
  margin-bottom: 1.5rem;
}
.contact__info {
  display: grid;
  gap: 1rem;
}
.contact__card {
  background-color: var(--container-color);
  padding: 1rem;
  border-radius: 0.75rem;
  text-align: center;
}
.contact__card-icon {
  font-size: 2rem;
  color: var(--title-color);
  margin-bottom: 0.25rem;
}
.contact__card-title,
.contact__card-data {
  font-size: var(--small-font-size);
}
.contact__card-title {
  font-weight: var(--font-medium);
}
.contact__card-data {
  display: block;
  margin-bottom: 0.75rem;
}
.contact__button {
  color: var(--first-color);
  font-size: var(--small-font-size);
  display: flex;
  align-items: center;
  justify-content: center;
  column-gap: 0.25rem;
}
.contact__button:hover .contact__button-icon {
  transform: translateX(0.25rem);
}
.contact__button-icon {
  font-size: 1rem;
  transition: 0.4s;
}

.form-message {
  font-size: 1rem;
  line-height: 1.6rem;
  padding: 4px 0 0;
  text-align: left;
  display: block;
}
.contact__form-div {
  display: flex;
  flex-direction: column-reverse;
  position: relative;
  margin-bottom: 1.7rem;
  height: 6rem;
  flex: 1;
}
.contact__form-div.invalid .form-message {
  color: #f33a58;
}
.contact__form-div.invalid .contact__form-input {
  border-color: #f33a58;
}
.contact__form-input {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 4rem;
  border: 2px solid var(--text-color-light);
  background: none;
  color: var(--text-color);
  outline: none;
  padding: 1.5rem;
  border-radius: 0.75rem;
  z-index: 1;
}
.contact__form-tag {
  position: absolute;
  top: -0.75rem;
  left: 1.25rem;
  font-size: var(--smaller-font-size);
  padding: 0.25rem;
  z-index: 10;
  background-color: var(--body-color);
}
.contact__form-area {
  height: 15rem;
}
.contact__form-area textarea {
  resize: none;
  height: 12.4rem;
}

.pull-right {
  float: right!important;
}

/*=============== FOOTER ===============*/
.footer {
  background-color: var(--first-color);
}
.footer__container {
  padding: 2rem 0rem 6rem;
}
.footer__title,
.footer__link {
  color: var(--body-color);
}
.footer__title {
  text-align: center;
  margin-bottom: 2rem;
}

.footer__social {
  display: flex;
  justify-content: center;
  column-gap: 1.25rem;
}
.footer__social-link {
  background-color: var(--body-color);
  color: var(--first-color);
  padding: 0.25rem;
  border-radius: 0.25rem;
  font-size: 1rem;
  display: inline-flex;
}
.footer__copy {
  display: block;
  margin-top: 4.5rem;
  color: var(--container-color);
  text-align: center;
  font-size: var(--small-font-size);
}

/*=============== SOCIAL ============= */
.social {
  position: fixed;
  top: 35%;
  right: 0px;
  transform: translateX(-50%);
  border-radius: 25px;
}

.social a {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 50px;
  height: 50px;
  padding: 0px;
  margin: 0px;
  line-height: 0px;
  background-color: rgb(69, 74, 80);
  border: 1px solid #cbcbcb;
  box-shadow: 2px 2px 12px rgba(0,0,0,0.2);
}

/*=============== SCROLL BAR ===============*/
::-webkit-scrollbar {
  width: 0.6rem;
  border-radius: 0.5rem;
  background-color: hsl(var(--second-hue), 8%, 38%);
}
::-webkit-scrollbar-thumb {
  background-color: hsl(var(--second-hue), 8%, 28%);
  border-radius: 0.5rem;
}
::-webkit-scrollbar-thumb:hover {
  background-color: hsl(var(--second-hue), 8%, 20%);
}

/*=============== BREAKPOINTS ===============*/
/* For small devices */
@media screen and (max-width: 320px) {
  .nav__menu {
    padding: 1rem 1.5rem;
  }
  .home__buttons {
    flex-direction: column;
  }
  .home__handle {
    width: 150px;
    height: 253px;
  }
  .home__img {
    width: 130px;
  }
  .about__info {
    grid-template-columns: repeat(2, 1fr);
  }
  .skills__box {
    column-gap: 1rem;
  }
  .skills__name {
    font-size: var(--small-font-size);
  }
  .services__container {
    grid-template-columns: 145px;
    justify-content: center;
  }
  .work__item {
    font-size: var(--small-font-size);
  }
  .work__filters {
    column-gap: 0.25rem;
  }
}

/* For medium devices */
@media screen and (min-width: 326px) {
  .nav__menu {
    width: 328px;
    left: 0;
    right: 0;
    margin: auto;
  }
  .about__info {
    grid-template-columns: repeat(3, 140px);
    justify-content: center;
  }
  .about__description {
    padding: 0 5rem;
  }
  
  .home__img {
    width: 200px;
  }
  
  .skills__container {
    justify-content: center;
  }
  .skills__content {
    padding: 2rem 4rem;
  }

  .work__container {
    justify-content: center;
  }
  .work__img {
    width: 295px;
  }
  .contact__info {
    grid-template-columns: 300px;
    justify-content: center;
  }
  .contact__form {
    width: 360px;
    margin: 0 auto;
  }
}
@media screen and (min-width: 767px) {
  .work__container {
    grid-template-columns: repeat(2, max-content);
  }
  .contact__container {
    grid-template-columns: repeat(2, max-content);
    justify-content: center;
    column-gap: 3rem;
  }
}
/* For large devices */
@media screen and (min-width: 992px) {
  .container {
    margin-left: auto;
    margin-right: auto;
  }
  .section {
    padding: 6.5rem 1rem;
  }
  .section__title {
    margin-bottom: 3.5rem;
  }
  .nav {
    height: calc(var(--header-height) + 1rem);
  }
  .home__handle {
    width: 260px;
    height: 310px;
  }
  .home__img {
    width: 200px;
  }
  .social-link {
    padding: 0.4rem;
    font-size: 1.25rem;
  }
  
  .home__scroll-icon {
    font-size: 2rem;
  }
  .about__container {
    grid-template-columns: repeat(2, 350px);
    align-items: center;
    column-gap: 4rem;
  }
  .about__img {
    width: 200px;
  }
  .about__data {
    text-align: initial;
    justify-content: center;
  }
  .about__info {
    justify-content: center;
  }
  .about__box {
    text-align: center;
    padding: 1rem 1.25rem;
  }
 
  .skills__container {
    grid-template-columns: repeat(2, 350px);
    column-gap: 3rem;
  }
  
  .work__container {
    gap: 3rem;
  }
  .work__card {
    padding: 1.25rem;
  }
  .work__img {
    margin-bottom: 1rem;
  }
  .work__title {
    margin-bottom: 0.5rem;
  }
  .contact__container {
    column-gap: 6rem;
  }
  .contact__form-div {
    margin-bottom: 2.3rem;
  }
  .footer__social-link {
    font-size: 1.25rem;
    padding: 0.4rem;
    border-radius: 0.5rem;
  }
}
/* Toast Messenger */
#toast {
  position: fixed;
  top: calc(var(--header-height) + 32px);
  right: 32px;
  z-index: 9999;
}
.toast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff;
  min-width: 300px;
  max-width: 450px;
  border-radius: 2px;
  border-left: 4px solid;
  box-shadow: 0 5px 8px rgba(0, 0, 0, 0.08);
  padding: 20px 0;
  animation: slideInLeft ease 0.3s, fadeOut linear 1s 3s forwards;
}
@keyframes slideInLeft {
  from {
    transform: translateX(calc(100% + 32px));
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}
@keyframes fadeOut {
  to {
    opacity: 0;
  }
}
.toast + .toast {
  margin-top: 20px;
}
.toast__icon {
  font-size: 24px;
}
.toast__icon,
.toast__close {
  padding: 0 16px;
}
.toast__body {
  flex-grow: 1;
}
.toast__title {
  font-size: 16px;
  font-weight: 600;
  color: #333;
}
.toast__msg {
  font-size: 14px;
  color: #8888;
  line-height: 1.5;
}
.toast__close {
  font-size: 20px;
  color: rgba(0, 0, 0, 1);
  cursor: pointer;
}
.toast--success {
  border-color: #47d864;
}
.toast--success .toast__icon {
  color: #47d864;
}
.toast--error {
  border-color: #ff623d;
}
.toast--error .toast__icon {
  color: #ff623d;
}
