* {
    padding: 0;
    margin: 0;
    text-decoration: none;
    box-sizing: border-box;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
    font-size: 12px;
}

body {
    background-color: black;
    color: white;
    font-family: "Lato", sans-serif;
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.background {
    position: absolute;
    top: -300px;
    left: 0;
    display: block;
    height: 2882px;
    width: 100%;
    background: url("../assets/background-main.png") center/cover no-repeat;
    z-index: -2;
}

.gradient {
    background: linear-gradient(
        to bottom,
        rgba(195, 0, 195, 0) 0%,       
        rgba(184, 43, 181, 0.2) 50%,   
        rgba(0, 0, 0, 1) 100%
    );
    position: absolute;
    bottom: 0;
    left: 0;
    display: block;
    z-index: -1;
    height: 1486px;
    width: 100%;
}

/* burger styling */ 

.burger {
    display: none;
    flex-direction: column;
    gap: 4px;
    width: 40px;
    height: 40px;
    cursor: pointer;
}

.burger span {
    display: block;
    width: 100%;
    height: 4px;
    border-radius: 5px;
    background-color: #afafaf;
}

.links {
    transition: all 0.3s ease-in;
}

.links.active {
    transition: 0.5s ease-in all;
    right: 0;
}

.menu-close {
    display: none;
}

.menu-close i {
    font-size: 2rem;
}

/* Header styling */

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px;
    width: 100%;
}

header h1 {
    font-family: 'DM Serif Display', serif;
    font-weight: 400;
    font-size: 2rem;
}

header li {
    display: flex;
    gap: 16px;
    align-items: center;
}

header li ul {
    font-size: 1.5rem;
    font-weight: 500;
    cursor: pointer;
    transition: color 0.3s ease-in;
}

header li ul:hover {
    color: #CCCCCC;
}

header li button {
    background-color: transparent;
    border-radius: 16px;
    color: white;
    height: 48px;
    width: 120px;
    font-size: 1.5rem;
    border: 3px solid #208AB7;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: color 0.3s ease-in;
}

header li button:hover {
    color: #27a5db;
}

/* main page styling */

.main {
    width: 80%;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100vh;
}

.main h2 {
    font-size: 6rem;
    max-width: 716px;
    text-align: center;
    margin-top: 128px;
    opacity: 0;
    transform: translateY(32px);
}

.main h2.show {
    transform: translateY(0);
    opacity: 100%;
    transition: 1s all ease-in;
}

.main h2 span {
    color: #AFAFAF;
}

.main p {
    font-size: 2rem;
    margin-top: 36px;
    max-width: 600px;
    text-align: center;
    opacity: 0;
}

.main p.show {
    opacity: 100%;
    transition: 1s all ease-in;
}

.main-show {
    opacity: 0;
}

.main-show.show {
    opacity: 100%;
    transition: 0.6s all ease-in;
}

.scroll-down {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
    cursor: pointer;
    transition: all 0.2s ease-in;
    opacity: 0;
}

.scroll-down.show {
    opacity: 100%;
    transition: opacity 0.6s ease-in;
}

.scroll-down button {
    background-color: transparent;
    border: none;
    color: #AFAFAF;
    font-size: 2rem;
    cursor: pointer;
}

.scroll-down:hover {
    transform: translateX(-50%) scale(1.1);
    transition: all 0.4s ease-in;
}

/* about me styling */

.about-me {
    height: 700px;
    display: flex;
    font-size: 3rem;
    align-items: center;
    font-weight: bold;
    gap: 190px;
}

.about-me p{
    max-width: 500px;
    text-align: center;
}

/* tech stack styling */

.tech-stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: 780px;
}

.tech-stack h2 {
    font-size: 4rem;
    margin-bottom: 100px;
}

.tech-parts {
    display: flex;
    max-width: 70%;
    width: 100%;
    gap: 32px;
}

.tech-part {
    flex: 1;
}

.tech-part p {
    font-size: 1.5rem;
    font-weight: 500;
    margin-bottom: 8px;
}

.tech-part > div:first-of-type {
    display: flex;
    justify-content: space-evenly;
    border: 3px solid white;
    border-radius: 16px;
    padding: 16px 32px;
}

.tech-part > div:first-of-type div {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.tech-part img {
    width: 48px;
    height: 48px;
}

.tech-part h3 {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 32px;
}

.tech-part.middle {
    margin-top: 64px;
}

/* main projects styling */

.projects {
    display: flex;
    flex-direction: column;
    width: 80%;
    margin-bottom: 100px;
}

.projects h2 {
    font-size: 4rem;
    margin-bottom: 150px;
}

.projects div {
    display: flex;
    justify-content: space-between;
}

.projects div p {
    font-size: 3rem;
    flex: 1;
    max-width: 500px;
}

.projects div div {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.projects div div a {
    font-size: 3rem;
    text-decoration: underline;
    color: white;
}

.projects div div a:hover {
    color: #CCCCCC;
}

/* services styling */

.services {
    width: 100%;
    height: 1000px;
    background: linear-gradient(
    to bottom,
    rgba(195, 0, 195, 0) 0%,
    rgba(142, 45, 191, 0.32) 22%,
    rgba(114, 69, 189, 0.5) 38%,
    rgba(73, 104, 186, 0.75) 54%,
    rgba(32, 138, 183, 0.5) 71%,
    rgba(32, 138, 183, 0.25) 86%,
    rgba(32, 138, 183, 0) 100%
);
}

.services h2 {
    text-align: center;
    font-size: 4rem;
    margin-top: 150px;
    margin-bottom: 140px;
}

.carousel {
  position: relative;
  width: 100%;
  margin: auto;
  overflow: hidden;
}

.track {
  display: flex;
  align-items: center;
  transition: transform 0.8s ease;
}

.card {
  min-width: 430px;
  width: 100%;
  margin: 0 70px;
  padding: 30px;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  border-radius: 16px;
  transform: scale(0.7);
  transition: transform 0.8s ease, opacity 0.8s ease;
  opacity: 0.6;
  aspect-ratio: 1 / 0.9;
}

.card.active {
  transform: scale(1);
  opacity: 1;
}

.card h3 {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 40px;
}

.card p {
    font-size: 2rem;
    text-align: center;
}

.arrow {
    background-color: transparent;
    border: solid 4px #320832;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: left 0.3s, right 0.3s;
}

.arrow:hover i {
    color: #681268;
}

.arrow i {
    transition: color 0.3s ease-in;
    color: #320832;
    font-size: 2rem;
}

/* contact styling */

.contact {
    max-width: 700px;
    width: 80%;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 48px;
}

.contact h2 {
    font-size: 4rem;
    max-width: 700px;
    margin-bottom: 36px;
}

.contact form {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 8px;
}

.contact form label {
    font-size: 2rem;
}

.contact form input {
    height: 60px;
}

.contact form textarea {
    height: 120px;
    resize: none;
}

.contact form input, .contact form textarea {
    width: 100%;
    background-color: transparent;
    color: white;
    border-radius: 16px;
    border: 3px solid #208AB7;
    font-size: 1.5rem;
    padding: 4px 16px;
}

.contact form button {
    background-color: transparent;
    padding: 4px 16px;
    color: white;
    border: 3px solid #208AB7;
    border-radius: 16px;
    width: 180px;
    height: 60px;
    margin-top: 32px;
    font-size: 2rem;
    cursor: pointer;
    transition: 0.3s all ease-in;
    font-weight: bold;
}

.contact form button:hover {
    transform: scale(1.1);
    transition: 0.3s all ease-in;
}

.error {
    color: #E06C75;
    font-size: 1.5rem;
}

.success {
    color: #4FD1C5;
    font-size: 1.5rem;
}

/* footer styling */

.footer-gradient {
    height: 120px;
    width: 100%;
    background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0) 0%,
    rgba(32, 138, 183, 0.5) 50%,
    rgba(0, 0, 0, 0) 100%
    );
}

footer {
    width: 80%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-row {
    display: flex;
    width: 100%;
}

.footer-row div {
    max-width: 33%;
}

.footer-col {
    flex: 1;
}

.footer-col h1 {
    font-family: 'DM Serif Display', serif;
    font-weight: 400;
    font-size: 2rem;
    margin-bottom: 16px;
}

.footer-col.col-1 p {
    font-size: 1.5rem;
}

.footer-col h2 {
    font-size: 2rem;
    margin-bottom: 16px;
    text-align: center;
}

.footer-col.col-1, .footer-col-col-2 {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-col.col-1 ul, .footer-col-col-2 ul {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    list-style-type: none;
}

.footer-col ul li {
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s ease-in;
}

.footer-col ul li:hover {
    color: #CCCCCC;
}

.footer-row.row-2 {
    justify-content: center;
    margin-top: 32px;
    margin-bottom: 32px;
}

.footer-row.row-2 p {
    font-size: 1.5rem;
    opacity: 50%;
}

#footer-mail {
    color: white;
    transition: color 0.3s ease-in;
}

#footer-mail:hover {
    color: #CCCCCC;
}

/* animations */

.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1.5s ease, transform 1.5s ease;
}

.fade-in-second {
    transition-delay: 1s;
}

.fade-in-second-fast {
    transition-delay: 0.3s;
}

.fade-in-third-fast {
    transition-delay: 0.6s;
}

.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

/* mobile styling */

@media (max-width: 1024px) {
    .burger {
        display: flex;
        justify-content: center;
    }

    .links {
        position: fixed;
        height: 100%;
        width: 70%;
        top: 0;
        right: -100%;
        display: flex;
        flex-direction: column;
        gap: 24px;
        padding-top: 36px;
        background-color: black;
        z-index: 2;
    }

    .menu-close {
        display: block;
        position: absolute;
        top: 24px;
        right: 24px;
    }

    header {
        padding: 6px 24px;
        box-sizing: border-box;
    }

    /* main styling */

    .main {
        position: relative;
        height: calc(100vh - 56px);
        box-sizing: border-box;
    }

    .main h2 {
        font-size: clamp(3rem, 5vw, 6rem);
        width: 90%;
        margin-top: 96px;
    }

    .main p.show {
        font-size: clamp(1rem, 5vw, 2rem);

    }

    /* about me styling */

    .about-me {
        display: flex;
        flex-direction: column;
        gap: 64px;
        padding-top: 64px;
        font-size: clamp(2rem, 5vw, 3rem);
        height: auto;
        margin-top: 64px;
        margin-bottom: 248px;
        max-width: 90%;
    }

    /* tech stack */

    .tech-stack {
        height: auto;
        margin-bottom: 128px;
    }

    .tech-stack h2 {
        font-size: clamp(3rem, 5vw, 4rem);
        text-align: center;
        margin-bottom: 64px;
    }

    .tech-parts {
        display: flex;
        flex-direction: column;
    }

    .tech-part > div:first-of-type {
        display: flex;
        flex-wrap: wrap;
    }

    .tech-part h3 {
        font-size: clamp(2rem, 5vw, 3rem);
    }

    .tech-part div {
        gap: 12px;
        align-items: center;
        justify-content: center;
    }

    .tech-part.middle {
        margin-top: 0;
    }

    .tech-part div div {
        flex: 1;
    }

    /* projects styling */

    .projects {
        max-width: 90%;
        align-items: center;
    }

    .projects h2 {
        font-size: clamp(3rem, 5vw, 4rem);
        text-align: center;
        margin-bottom: 64px;
    }

    .projects div {
        display: flex;
        flex-direction: column;
        gap: 36px;
    }

    .projects div p {
        font-size: clamp(2rem, 5vw, 3rem);
        text-align: center;
    }

    .projects div div a {
        font-size: clamp(2rem, 5vw, 3rem);
    }

    /* services styling */

    .services h2 {
        font-size: clamp(3rem, 5vw, 4rem);
        margin-bottom: 64px;
        text-align: center;
    }

    .carousel {
        height: 500px;
    }

    .card {
        min-width: 300px;
    }

    /* contact styling */

    .contact {
        width: 90%;
    }

    .contact h2 {
        font-size: clamp(3rem, 5vw, 4rem);
        text-align: center;
    }

    .contact form label {
        font-size: clamp(1rem, 5vw, 2rem);
    }

    /* footer */

    footer {
        width: 90%;
    }

    .footer-row {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .footer-row div {
        width: 100%;
        max-width: 100%;
    }

    .footer-col {
        margin-bottom: 12px;
    }

    .footer-row.row-2 p {
        font-size: clamp(1rem, 1.5rem, 2rem);
        text-align: center;
    }

}