/* Light Theme */
:root {
    --color-background: #f8fafc;
    --color-surface: #ffffff;
    --color-text-main: #1e293b;
    --color-text-subtle: #64748b;
    --color-primary: #3b82f6;
    --color-primary-hover: #1d4ed8;
    --color-border: #dbeafe;
    --box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
    --title-font-size: 72px;
}

/* Dark Theme */
:root {
    --color-background: #202124;
    --color-surface: #292a2d;
    --color-text-main: #e8eaed;
    --color-text-subtle: #9aa0a6;
    --color-primary: #3b82f6;
    --color-primary-hover: #1d4ed8;
    --color-border: #3c4043;
    --box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    --title-font-size: 72px;
}


::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--color-text-subtle);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: var(--color-text-main);
    border-radius: 5px;
}


* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Nunito", sans-serif;
    font-size: 18px;
    font-weight: 500;
    font-optical-sizing: auto;
    font-style: normal;
    color: var(--color-text-main);
    scroll-behavior: smooth;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    transition: all 0.3s ease;
}

body {
    background: var(--color-background);
}


header {
    position: fixed;
    top: 0;
    width: 100%;
    height: 50px;
    background: var(--color-surface);
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    box-shadow: var(--box-shadow);
    z-index: 1000;
}

header div {
    display: flex;
    align-items: center;
}

header div span a {
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
}

header nav {
    display: flex;
    align-items: center;
    transition: all 3s ease;
}

header nav ul {
    display: flex;
    list-style: none;
}

header nav ul li a {
    font-size: 18px;
    font-weight: 700;
    margin: 0 10px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

header nav ul li a.active {
    color: var(--color-primary);
    text-decoration: underline;
}

header nav #lang {
    width: 50px;
    height: 24px;
    margin-left: 10px;
    display: flex;
    justify-content: space-between;
    position: relative;
    border-radius: 12px;
    background: var(--color-border);
    cursor: pointer;
}

header nav #lang p {
    width: 25px;
    text-align: center;
    margin: 0;
    font-size: 13px;
    font-weight: 700;
    transition: all 0.3s ease;
    z-index: 2;
}

header nav #lang #circle {
    width: 24px;
    height: 24px;
    position: absolute;
    top: 0px;
    left: 50%;
    background: var(--color-primary);
    border-radius: 50%;
    transition: all 0.3s ease;
    z-index: 1;
}

header #open-menu {
    display: none;
    cursor: pointer;
    transition: all 0.3s ease;
    user-select: none;
}

header #open-menu p {
    font-size: 18px;
    font-weight: 700;
}


section {
    display: flex;
    width: 100%;
    min-height: 100vh;
    padding: 30px 10vw;
    align-content: center;
    overflow: hidden;

    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

section.show {
    opacity: 1;
    transform: translateY(0);
}


#home {
    position: relative;
}

#home::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50px;
    background: linear-gradient(to top, var(--color-background), transparent);
    z-index: -1;
    pointer-events: none;
}

#home #background {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(315deg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: -1;
}

#home #background p {
    font-size: 46px;
    white-space: nowrap;
    color: var(--color-background);
    text-shadow:
        0 -1px 0 var(--color-text-subtle),
        1px 0 0 var(--color-text-subtle),
        0 1px 0 var(--color-text-subtle),
        -1px 0 0 var(--color-text-subtle);
    opacity: 0.2;
}

#home #background p:nth-child(odd) {
    animation: pOdd 30s linear infinite;
}

@keyframes pOdd {
    0% {
        transform: translateX(-25%);
    }

    100% {
        transform: translateX(0%);
    }

}

#home #background p:nth-child(even) {
    animation: pEven 30s linear infinite;
}

@keyframes pEven {
    0% {
        transform: translateX(0%);
    }

    100% {
        transform: translateX(-25%);
    }
}

#home #avatar {
    display: flex;
    justify-content: center;
    margin: auto;
}

#home #avatar img {
    width: 250px;
    height: 250px;
    border: var(--color-primary) 5px solid;
    border-radius: 50%;
}

#home #avatar img:hover {
    transform: scale(1.05);
}

#home #content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin: auto auto auto auto;
}

#home #content h1 {
    font-size: var(--title-font-size);
    font-weight: 700;
}

#home #content h1:nth-child(2) {
    min-width: 442px;
}

#home #content h1 span {
    font-size: var(--title-font-size);
    font-weight: 700;
}

#home #content h1 span:nth-child(2) {
    color: var(--color-primary);
}

#home #content p {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-text-subtle);
}

#home #content button {
    width: 150px;
    height: 40px;
    margin-top: 20px;
    color: #e8eaed;
    background: var(--color-primary);
    border: none;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

#home #to-about {
    position: absolute;
    top: 93%;
    left: 50%;
    animation: to-about 2s ease-in-out infinite;
}

@keyframes to-about {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0px);
    }
}

#home #to-about p a {
    text-decoration: none;
    font-size: 24px;
    color: var(--color-primary);
}


#about {
    justify-content: space-between;
    overflow: hidden;
}

#about #about-content {
    width: 45vw;
    display: flex;
    flex-direction: column;
    margin: auto 0 auto 0;
}

#about #about-content h1 {
    font-size: var(--title-font-size);
    font-weight: 700;
    height: fit-content;
    margin: 20px 0;
}

#about #about-content p {
    text-align: justify;
}

#about #about-content ul {
    margin-left: 50px;
}

#about #about-image {
    display: flex;
    justify-content: center;
    margin: auto 0 auto 0;
}

#about #about-image img {
    width: 350px;
    margin-top: 100px;
    border-radius: 10px;
}


#skills {
    flex-wrap: wrap;
}

#skills>h1,
#projects>h1,
#experience>h1 {
    font-size: var(--title-font-size);
    font-weight: 700;
    margin: 20px auto;
    height: fit-content;
    text-align: center;
}

#skills #skill-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

#skills #skill-list .skill-card {
    background-color: var(--color-surface);
    margin: 20px;
    padding: 10px;
    width: 270px;
    height: 200px;
    border-radius: 10px;
    box-shadow: var(--box-shadow);
    text-align: center;
    border: var(--color-surface) 5px solid;
    transition: all 0.3s ease-in-out;
    opacity: 0;
}

#skills #skill-list .skill-card:hover {
    border: var(--color-primary-hover) 5px solid;
}

#skills #skill-list .skill-card:nth-child(1).show {
    animation: fadeIn 0.5s linear 0.1s forwards, highLight 0.8s linear 0.1s forwards;
}

#skills #skill-list .skill-card:nth-child(2).show {
    animation: fadeIn 0.5s linear 0.2s forwards, highLight 0.8s linear 0.2s forwards;
}

#skills #skill-list .skill-card:nth-child(3).show {
    animation: fadeIn 0.5s linear 0.3s forwards, highLight 0.8s linear 0.3s forwards;
}

#skills #skill-list .skill-card:nth-child(4).show {
    animation: fadeIn 0.5s linear 0.4s forwards, highLight 0.8s linear 0.4s forwards;
}

#skills #skill-list .skill-card:nth-child(5).show {
    animation: fadeIn 0.5s linear 0.5s forwards, highLight 0.8s linear 0.5s forwards;
}

#skills #skill-list .skill-card:nth-child(6).show {
    animation: fadeIn 0.5s linear 0.6s forwards, highLight 0.8s linear 0.6s forwards;
}

#skills #skill-list .skill-card span {
    font-size: 54px;
    color: var(--color-text-main);
}

#skills #skill-list .skill-card h1 {
    font-size: 24px;
    font-weight: 700;
}

#skills #skill-list .skill-card p {
    color: var(--color-text-subtle);
}


#projects {
    flex-wrap: wrap;
}

#projects #project-wrapper {
    width: 100%;
    margin: auto;
    gap: 20px;
    display: flex;
    justify-content: center;
    align-items: center;

}

#projects #project-wrapper .arrow {
    font-size: 36px;
    border: none;
    background: var(--color-background);
    border: var(--color-background) 2px solid;
    border-radius: 50%;
    cursor: pointer;
}

#projects #project-wrapper #project-list {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    overflow: hidden;
}

#projects #project-wrapper #project-list .project-card {
    width: 400px;
    height: 500px;
    flex: 0 0 auto;
    background: var(--color-surface);
    border-radius: 10px;
    box-shadow: var(--box-shadow);
    border: var(--color-surface) 5px solid;
    transition: all 0.3s ease-in-out;
    overflow: hidden;
}

#projects #project-wrapper #project-list .project-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 200px;
    background: linear-gradient(to bottom, #202124bf, #202124bf, transparent);
    z-index: -1;
    pointer-events: none;
}

#projects #project-wrapper #project-list .project-card:hover {
    border: var(--color-primary-hover) 5px solid;
}

#projects #project-wrapper #project-list .project-card:hover img {
    filter: brightness(0.25);
}

#projects #project-wrapper #project-list .project-card:hover .description {
    opacity: 1;
    transform: translateY(0);
}

#projects #project-wrapper #project-list .project-card img {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0px;
    left: 0px;
    object-fit: cover;
    filter: brightness(1);
    z-index: -1;
}

#projects #project-wrapper #project-list .project-card>h1 {
    padding: 10px;
    font-size: 24px;
    font-weight: 700;
    text-align: justify;
}

#projects #project-wrapper #project-list .project-card>h1:nth-of-type(1) {
    width: fit-content;
    margin: 10px auto 0 10px;
    padding: 1px 8px;
    background: var(--color-primary);
    border-radius: 10px;
}

#projects #project-wrapper #project-list .project-card .description {
    width: 100%;
    position: absolute;
    bottom: 10px;
    padding: 10px;
    text-align: justify;
    transform: translateY(10px);
    transition: all 0.3s ease;
    opacity: 0;
}

#projects #project-wrapper #project-list .project-card .description h1 {
    margin-bottom: 10px;
    font-size: 24px;
    font-weight: 700;
    text-decoration: underline;
    color: var(--color-primary);
}

#projects #project-wrapper #project-list .project-card .description p {
    margin-bottom: 20px;
}

#projects #project-wrapper #project-list .project-card .description a {
    margin-right: 20px;
    padding: 8px;
    background: var(--color-primary);
    border-radius: 5px;
    text-decoration: none;
}

#experience {
    flex-direction: column;
}

#experience>h1 {
    margin-top: 40px;
}

#experience #experience-container {
    width: 100%;
    max-width: 1000px;
    margin: auto;
    position: relative;
    opacity: 0;
}

#experience #experience-container.show {
    opacity: 1;
}

#experience #experience-container svg {
    margin: auto;
    position: absolute;
}

#experience #experience-container svg path.show {
    stroke-dasharray: 2000;
    stroke-dashoffset: 2000;
    animation: drawPath 2s linear forwards;
}

@keyframes drawPath {
    from {
        stroke-dashoffset: 2000;
    }

    to {
        stroke-dashoffset: 0;
    }
}

#experience #experience-container svg circle,
#experience #experience-container svg text {
    opacity: 0;
}

#experience #experience-container svg .dot-1.show,
#experience #experience-container svg .text-1.show {
    animation: fadeIn 0.1s linear 1.2s forwards;
}

#experience #experience-container svg .dot-2.show,
#experience #experience-container svg .text-2.show {
    animation: fadeIn 0.1s linear 1.7s forwards;
}

#experience #experience-container svg defs marker path {
    opacity: 0;
}

#experience #experience-container #timeline-desktop defs marker path.show {
    animation: fadeIn 0.1s linear 1.3s forwards;
}

#experience #experience-container #timeline-mobile defs marker path.show {
    animation: fadeIn 0.1s linear 0.9s forwards;
}

#experience #experience-container .company {
    position: absolute;
    text-align: justify;
    padding: 10px;
    border: var(--color-border) 5px solid;
    border-radius: 20px;
    opacity: 0;
}

#experience #experience-container #company1.show {
    animation: fadeIn 0.8s linear 1.2s forwards;
}

#experience #experience-container #company2.show {
    animation: fadeIn 0.8s linear 1.7s forwards;
}

#experience #experience-container .company p {
    color: var(--color-text-subtle);
}


#contact {
    justify-content: space-between;
}

#contact #info {
    width: 45vw;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#contact #info h1 {
    font-size: var(--title-font-size);
    font-weight: 700;
    margin: 20px 0;
    height: fit-content;
}

#contact #info p {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    opacity: 0;
}

#contact #info p:nth-of-type(1).show {
    animation: fadeIn 0.5s linear 0.1s forwards;
}

#contact #info p:nth-of-type(2).show {
    animation: fadeIn 0.5s linear 0.2s forwards;
}

#contact #info p:nth-of-type(3).show {
    animation: fadeIn 0.5s linear 0.3s forwards;
}

#contact #info p:nth-of-type(4).show {
    animation: fadeIn 0.5s linear 0.4s forwards;
}

#contact #info p:nth-of-type(5).show {
    animation: fadeIn 0.5s linear 0.5s forwards;
}

#contact #info p:nth-of-type(6).show {
    animation: fadeIn 0.5s linear 0.6s forwards;
}

#contact #info p a {
    color: var(--color-primary);
    text-decoration: none;
    transition: all 0.3s ease;
}

#contact #contact-form {
    max-width: 350px;
    width: 30vw;
    height: fit-content;
    display: flex;
    padding: 20px;
    flex-direction: column;
    margin: auto 0 auto 0;
    background: var(--color-surface);
    border-radius: 10px;
    box-shadow: var(--box-shadow);
    opacity: 0;
}

#contact #contact-form.show {
    animation: fadeIn 0.5s linear 0.5s forwards;
}

#contact #contact-form input,
#contact #contact-form textarea {
    max-width: 100%;
    padding: 5px;
    margin: 0 0 20px 0;
    border: none;
    border-bottom: var(--color-text-main) 2px solid;
    background: var(--color-surface);
    overflow: hidden;
    resize: none;
}

#contact #contact-form input:focus,
#contact #contact-form textarea:focus {
    outline: none;
}

#contact #contact-form button {
    width: 100px;
    height: 40px;
    margin: auto;
    color: #e8eaed;
    background: var(--color-primary);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}


footer {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 50px;
    background: var(--color-surface);
    box-shadow: var(--box-shadow);
}


@media (hover: hover) {
    ::-webkit-scrollbar-thumb:hover {
        background: var(--color-text-main);
        cursor: pointer;
    }

    header nav ul li a:hover {
        color: var(--color-primary-hover);
    }

    header nav #lang p:hover {
        color: var(--color-primary-hover);
    }

    #home #content button:hover {
        background: var(--color-primary-hover);
    }

    #projects #project-wrapper .arrow:hover {
        color: var(--color-primary-hover);
    }



    #contact #info p a:hover {
        color: var(--color-primary-hover);
    }

    #contact #contact-form button:hover {
        background: var(--color-primary-hover);
    }
}


@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes highLight {
    from {
        border: var(--color-surface) 5px solid;
    }

    20% {
        border: var(--color-primary-hover) 5px solid;
    }

    to {
        border: var(--color-surface) 5px solid;
    }
}