@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700&display=swap');

/* Main color theme */
:root {
    --primary-color: #1f1f1f;
    --secondary-color: #2400c2;
    --secondary-color-hover: #2f00ff;
    --hover-black-color: black;
    --hover-white-color: white;
    --bg-color: #f1f1f1;
    --bg-second-color: #f8f8f8;
  }

/* Dark color theme */
[data-theme="dark"] {
    --primary-color: #f1f1f1;
    --secondary-color: #3776ff;
    --secondary-color-hover: #5d88ff;
    --hover-black-color: white;
    --hover-white-color: white;
    --bg-color: #1f1f1f;
    --bg-second-color: #1d1d1d;
}

/* Global styles */
*{
    font-family: 'Lato', sans-serif;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background-color: var(--bg-color);
}

h1, h2, h3, h4, h5, h6, span {
    color: var(--primary-color);
    text-align: center;
    line-height: 1.25;
}

h1 {
    font-size: 36px;
}

p {
    line-height: 1.5;
    font-size: 16px;
    color: var(--primary-color);
}

li {
    list-style-type: none;
}

a {
    text-decoration: none;
    position: relative;
    transition: all 500ms ease;
}

i {
    transition: all 200ms ease;
}

i:hover {
    opacity: 0.7;
    transform: translateY(-2px);
}

.link__hover-effect:after {
    content: "";
    position: absolute;
    height: 3px;
    width: 0;
    bottom: -3px;
    right: 0;
    transition: all 500ms ease;
}

.link__hover-effect--white:after {
    background-color: var(--hover-white-color);
}

.link__hover-effect--black:after {
    background-color: var(--hover-black-color);
}

.link__hover-effect:hover:after {
    width: 100%;
    left: 0;
}

.flex {
    display: flex;
}

.flex-1 {
    flex: 1;
}

.container {
    padding: 50px 0;
}

.row {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 12px;
}

.text-purple {
    color: var(--secondary-color);
}

section:nth-child(even) {
    background-color: var(--bg-second-color);
}

.section__title {
    margin-bottom: 20px;
}

/* Navigation Bar */
nav {
    height: 100px;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 12px;
}

.nav__link--list {
    display: flex;
}

.nav__link--anchor {
    margin: 0 12px;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
}

.nav__link--anchor-primary {
    background-color: var(--secondary-color);
    padding: 8px 20px;
    border-radius: 50px;
    color: white;
    transition: all 500ms ease;
}

.nav__link--anchor-primary:hover {
    background-color: var(--secondary-color-hover);
}

.personal__logo {
    font-size: 24px;
    color: var(--secondary-color);
    margin: 0 12px;
    font-weight: 700;
}

/* Dark mode button */
.theme-switch-wrapper {
    display: flex;
    align-items: center;
    margin-top: -10px;
    border-style: solid;
    border-radius: 20px;
    color: var(--hover-black-color);
  }

  .theme-switch {
    display: inline-flex;
    height: 34px;
    position: relative;
    width: 60px;
  }
  
  .theme-switch input {
    display:none;
  }
  
  .slider {
    background-color: white;
    bottom: 0;
    cursor: pointer;
    left: 0;
    position: absolute;
    right: 0;
    top: 0;
    transition: .4s;
  }
  
  .slider:before {
    background-color: black;
    bottom: 4px;
    content: "";
    height: 26px;
    left: 4px;
    position: absolute;
    transition: .4s;
    width: 26px;
  }
  
  input:checked + .slider {
    background-color: black;
  }

  input:checked + .slider:before {
    background-color: white;
  }
  
  input:checked + .slider:before {
    transform: translateX(26px);
  }
  
  .slider.round {
    border-radius: 34px;
  }
  
  .slider.round:before {
    border-radius: 50%;
  }

/* About me section */
#about-me {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.about-me__info {
    display: flex;
    flex-direction: column;
}

.about-me__info--container {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.about-me__picture--mask {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    margin-bottom: 28px;
    animation: animate-pfp 800ms 200ms backwards;
}

@keyframes animate-pfp {
    0% {
        transform: scale(0);
    }

    80% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

.about-me__picture {
    width: 100%;
    transform: scale(1.5);
}

.about-me__info--para {
    font-size: 20px;
    margin-bottom: 28px;
    animation: fade-up 600ms 400ms backwards;
}

.about-me__info--title {
    margin-bottom: 16px;
    animation: fade-up 600ms 400ms backwards;
}

.about-me__links {
    font-size: 24px;
    color: var(--hover-black-color);
    text-decoration: none;
    padding: 0 16px;
    animation: fade-up 600ms 400ms backwards;
}

@keyframes fade-up {
    0% {
      opacity: 0;
      transform: translateY(40px);
    }

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

.about-me__img--container {
    flex: 1;
    display: flex;
    align-items: center;
}

.about-me__img {
    width: 100%;
    animation: animate-img 1200ms 800ms backwards;
}

@keyframes animate-img {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

.wave__emoji {
    display: inline-block;
    animation: waving 800ms infinite ease-in-out;
}

@keyframes waving {
    0% {
        transform: rotate(0);
    }

    50% {
        transform: rotate(30deg);
    }

    100% {
        transform: rotate(0);
    }
}

/* Tech stack */
.language__img {
    width: 100%;
    max-width: 100px;
    transition: all 500ms ease;
}

.language:hover .language__img {
    filter: brightness(80%);
    opacity: 0.86;
    transform: scale(0.9);
}

.language {
    width: 25%;
    display: flex;
    justify-content: center;
    position: relative;
}

.language__img--wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 25px 16px;
}

.language__list {
    display: flex;
    width: 100%;
    flex-wrap: wrap;
}

.language__name {
    position: absolute;
    bottom: 0;
    transform: scale(0);
    transition: all 500ms ease;
    font-size: 20px;
    opacity: 0;
}

.language:hover .language__name{
    transform: scale(1);
    opacity: 1;
}

/* Project section */
.project {
    margin-bottom: 130px;
}

.project:last-child {
    margin-bottom: 40px;
}

.project__list {
    padding-top: 40px;
}

.project__img {
    width: 100%;
    transition: all 500ms ease;
}

.project__wrapper {
    display: flex;
    box-shadow: 0 20px 80px rgba(0, 0, 0, 0.4);
    border-radius: 20px;
    overflow: hidden;
    position: relative;
}

.project__wrapper:before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background-color: #1c1d25;
    opacity: 0;
    transition: all 500ms ease;
    z-index: 2;
}

.project:hover .project__wrapper:before{
    opacity: 0.7;
}

.project:hover .project__img {
    transform: scale(1.07);
    filter: blur(5px);
}

.project__description {
    position: absolute;
    top: 50%;
    transform: translateY(100%);
    left: 90px;
    max-width: 550px;
    z-index: 3;
    opacity: 0;
    transition: all 600ms ease;
}

.project:hover .project__description {
    opacity: 1;
    transform: translateY(-50%);
}

.project__description--title, .project__description--sub-title, .project__description--para, .project__description--link {
    text-align: left;
    color: white;
}

.project__description--title {
    font-size: 40px;
}

.project__description--para {
    margin: 10px 0;
}

.project__description--link {
    font-size: 20px;
    margin-right: 16px;
    text-decoration: none;
}

/* Footer */
footer {
    background-color: #242424;
}

.footer__up--img {
    font-size: 50px;
    color: white;
    transition: all 500ms ease;
}

.footer__up--img:hover {
    transform: translateY(-5px);
    opacity: 0.8;
}

.footer__row {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8% 0;
}

.footer__social--link, .footer__copyright {
    color: white;
}

.footer__logo {
    margin-bottom: 25px;
}

.footer__social--list {
    display: flex;
    max-width: 500px;
    justify-content: space-around;
    width: 100%;
    margin-bottom: 28px;
}

/* Responsive for tablets, phones etc*/
@media (max-width: 768px) {
    nav {
        height: 68px;
    }

    h1 {
        font-size: 28px;
    }

    .about-me__info--para {
        font-size: 18px;
    }

    .project__description--para {
        font-size: 14px;
    }

    .project__description {
        padding-right: 30px;
        left: 30px;
    }
}

/* Small phones */
@media (max-width: 486px) {
    .nav__link:not(:last-child) {
        display: none;
    }

    .project__description {
        padding: 0;
        left: 0;
        width: 100%;
        text-align: center;
    }

    .project__description--title, .project__description--sub-title {
        text-align: center;
    }

    .project__description--para {
        display: none;
    }
}