:root {
    --main-color: #1f3c5c;
    --main-color-alt: #314c6f;
    --second-color: #f4ebde;
    --second-color-alt: #f9f4e8;
    --third-color: #6384a2;
    --text-color: #777;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Montserrat", sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--main-color);
    color: var(--second-color);
}

header {
    width: 100%;
    height: 100vh;
}

.container {
    padding: 10px 10%;
}

header nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    position: relative;
}

header nav img {
    width: 250px;
}

header nav ul li {
    display: inline-block;
    list-style: none;
    margin: 10px 20px;
}

header nav ul li a {
    text-decoration: none;
    color: var(--second-color);
    font-size: 18px;
    position: relative;
}

header nav ul li a::after {
    content: "";
    position: absolute;
    width: 0;
    height: 3px;
    background-color: var(--second-color-alt);
    left: 0;
    bottom: -8px;
    transition: 0.3s;
}

header nav ul li a:hover::after {
    width: 100%;
}

header nav .fa-solid {
    display: none;
}

header .header {
    padding: 50px;
    margin-top: 10%;
    font-size: 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

header .header .text h1 {
    font-size: 60px;
    margin-top: 20px;
}

header .header .text span {
    font-family: "Lumanosimo", cursive;
}

.header img {
    width: 350px;
}

#about {
    padding: 50px 0;
    background-color: var(--second-color-alt);
    color: var(--text-color);
    position: relative;
    overflow: hidden;
}

#about .first-cat {
    position: absolute;
    width: 150px;
    top: 50%;
    transform: translateY(-50%);
    left: -500px;
    animation: cat-moving 5s forwards infinite;
}

#about .second-cat {
    position: absolute;
    width: 150px;
    top: 50%;
    transform: translateY(-50%);
    right: -500px;
    animation: second-cat-moving 5s forwards infinite;
    animation-delay: 2.5s;
}

@keyframes cat-moving {
    0% {
        left: -500px;
    }

    /* Initial position, outside the frame */
    50% {
        left: -90px;
        transform: rotate(40deg);
    }

    /* Move inside the frame */
    100% {
        left: -500px;
    }

    /* Return outside the frame */
}

@keyframes second-cat-moving {
    0% {
        right: -500px;
    }

    /* Initial position, outside the frame */
    50% {
        right: -90px;
        transform: rotate(-40deg);
    }

    /* Move inside the frame */
    100% {
        right: -500px;
    }

    /* Return outside the frame */
}

.about-box {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 50px;
    gap: 20px;
}

.about-box .about-me .partial {
    line-height: 1.7;
    font-family: "Lumanosimo", cursive;
    font-size: 18px;
    font-weight: 400;
    padding: 20px;
    text-align: center;
}

.dots {
    display: none;
}

#see-more {
    display: none;
}

.about-box .more {
    text-align: center;
    padding: 0 50px;
    width: 60%;
}

.tab-titles {
    width: 50%;
    display: flex;
    justify-content: center;
    gap: 50px;
}

.tab-links {
    font-size: 18px;
    font-weight: 500;
    position: relative;
    cursor: pointer;
}

.tab-links::after {
    content: "";
    position: absolute;
    width: 0;
    height: 3px;
    background-color: var(--main-color-alt);
    left: 25%;
    bottom: -8px;
    transition: 0.5s;
}

.tab-links.active-link::after {
    width: 50%;
}

.tab-contents ul li {
    list-style: none;
    margin: 30px 0;
    text-align: left;
}

.tab-contents ul li span {
    font-size: 18px;
    font-weight: 500;
}

.tab-contents {
    display: none;
    margin-top: 10px;
    text-align: center;
}

.tab-contents.active-tab {
    display: block;
}

.skill {
    background-color: var(--second-color);
    height: 10px;
    border-radius: 3px;
}

.skill span {
    display: block;
    background-color: var(--main-color-alt);
    height: 100%;
    position: relative;
    border-radius: 3px;
}

.skill span::before {
    content: attr(skill-rate);
    position: absolute;
    right: -15px;
    top: -33px;
    background-color: var(--third-color);
    color: var(--second-color);
    padding: 4px 0;
    width: 30px;
    font-size: 12px;
    text-align: center;
    border-radius: 4px;
}

.skill span::after {
    content: "";
    position: absolute;
    border-width: 10px;
    border-color: var(--third-color) transparent transparent;
    border-style: solid;
    top: -15px;
    right: -10px;
}

.education-item h3 {
    color: var(--text-color);
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.education-item p {
    color: #666;
    font-size: 1rem;
    margin-bottom: 5px;
}

#Objective p {
    line-height: 1.7;
}

#Objective p span {
    color: var(--main-color);
    font-weight: 600;
}

#Skills {
    padding: -30px 0;
    background-color: var(--second-color-alt);
    color: var(--text-color);
}

.sub-title {
    font-size: 60px;
    font-weight: 600;
    color: var(--main-color);
    text-align: center;
    position: relative;
}

.sub-title:not(#contact .sub-title)::before {
    content: "\f1b0";
    font-family: "Font Awesome 6 Free";
    font-size: 18px;
    color: var(--main-color-alt);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: -15px;
    z-index: 1;
}

.sub-title:not(#contact .sub-title)::after {
    content: "";
    width: 10%;
    height: 2px;
    background-color: var(--main-color-alt);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: -10px;
}

.skills-box {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    grid-gap: 40px;
    margin-top: 50px;
}

.skills-box div {
    background-color: var(--second-color);
    padding: 40px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 300;
    transition: 0.3s;
}

.skills-box div i {
    font-size: 50px;
    margin-bottom: 30px;
}

.skills-box div h3 {
    font-size: 30px;
    font-weight: 500;
    margin-bottom: 15px;
}

.skills-box div a {
    text-decoration: none;
    color: var(--third-color);
    font-size: 12px;
    margin-top: 30px;
    display: inline-block;
}

.skills-box div:hover {
    background: var(--main-color-alt);
    color: var(--second-color-alt);
    transform: translateY(-10px);
}

.skills-box div:hover a {
    color: var(--second-color);
}

#portfolio {
    padding: 50px 0;
    background: var(--second-color-alt);
    color: var(--text-color);
}

.work-box {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    grid-gap: 40px;
    margin-top: 50px;
}

.work {
    border-radius: 10px;
    position: relative;
    overflow: hidden;
}

.work.hide {
    display: none;
}

.work img {
    width: 100%;
    height: 100%;
    border-radius: 10px;
    display: block;
    transition: 0.3s;
}

.work .layer {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 0%;
    background: linear-gradient(rgb(31, 60, 92, 0.6), rgb(249, 244, 232, 0.8));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    text-align: center;
    padding: 0 40px;
    overflow: hidden;
    font-size: 14px;
    transition: 0.3s;
    color: var(--second-color-alt);
}

.work .layer h3 {
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 20px;
}

.work .layer a {
    margin-top: 20px;
    color: var(--main-color);
    text-decoration: none;
    font-size: 18px;
    line-height: 60px;
    background: var(--second-color);
    width: 60px;
    height: 60px;
    text-align: center;
    border-radius: 50%;
}

.work:hover .layer {
    height: 100%;
}

.work:hover img {
    transform: scale(1.1) rotate(5deg);
}

#portfolio a {
    cursor: pointer;
}

.btn {
    display: block;
    text-decoration: none;
    color: var(--main-color);
    background-color: var(--second-color);
    margin: 50px auto;
    width: fit-content;
    border: 1px solid var(--main-color);
    padding: 14px 40px;
    border-radius: 6px;
    transition: 0.3s;
}

.btn:hover {
    background-color: var(--main-color);
    color: var(--second-color-alt);
}

#contact {
    padding: 50px 0 10px;
}

#contact .row {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    color: var(--main-color);
}

#contact .row h2 {
    text-align: left;
    color: var(--second-color-alt);
}

.contact-left {
    flex-basis: 35%;
}

.contact-right {
    flex-basis: 60%;
}

.contact-left p {
    margin-top: 30px;
    color: var(--second-color-alt);
    display: flex;
    align-items: center;
}

.contact-left p i {
    margin-right: 15px;
    font-size: 18px;
    width: 26px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--second-color);
    color: var(--main-color-alt);
    border-radius: 6px;
}

.contact-left .social-icons {
    margin-top: 30px;
}

.contact-left .social-icons a {
    font-size: 30px;
    margin-right: 15px;
    display: inline-block;
    transition: 0.3s;
    text-decoration: none;
    color: var(--second-color-alt);
}

.contact-left .social-icons a:hover {
    color: var(--third-color);
    transform: translateY(-5px);
}

.btn2 {
    display: inline-block;
}

#contact .btn:hover {
    background-color: var(--third-color);
}

.contact-right form {
    width: 100%;
}

.contact-right form input,
.contact-right form textarea {
    width: 100%;
    border: 0;
    outline: none;
    padding: 15px;
    margin: 15px 0;
    font-size: 18px;
    border-radius: 6px;
    background-color: var(--third-color);
    color: var(--second-color-alt);
}

.contact-right form input::placeholder,
.contact-right form textarea::placeholder {
    color: var(--main-color);
}

.contact-right form textarea {
    resize: none;
}

.contact-right form button {
    padding: 14px 60px;
    font-size: 18px;
    margin-top: 20px;
    cursor: pointer;
}

.contact-right #result {
    color: var(--third-color);
    margin: -30px 0 20px;
}

.copyright {
    width: 100%;
    text-align: center;
    padding: 15px 0;
    font-weight: 300;
    margin-top: 20px;
    border-top: 1px solid var(--main-color-alt);
}

.copyright span {
    font-weight: 500;
}

@media (min-width: 768px) and (max-width: 991px) {
    nav {
        flex-direction: column;
    }
}

@media (max-width: 767px) {
    .header {
        flex-direction: column;
        padding: 20px !important;
    }

    .header .text {
        font-size: 16px;
        text-align: center;
    }

    .header h1 {
        font-size: 30px !important;
    }

    .header img {
        width: 200px;
    }

    header nav .fa-solid {
        display: block;
        font-size: 25px;
        cursor: pointer;
    }

    header nav ul {
        position: fixed;
        top: 0;
        right: -200px;
        width: 200px;
        height: 100vh;
        background-color: var(--third-color);
        color: var(--second-color);
        padding-top: 50px;
        z-index: 2;
        transition: 0.3s;
    }

    header nav ul li {
        display: block;
        margin: 25px;
    }

    header nav ul li a {
        color: var(--second-color);
    }

    header nav ul i {
        position: absolute;
        top: 25px;
        left: 25px;
    }

    .fa-bars {
        position: absolute;
        top: 25px;
        right: 20px;
    }

    .sub-title {
        font-size: 40px;
    }

    .tab-links {
        font-size: 16px;
    }

    .tab-titles {
        gap: 20px;
    }

    .more {
        width: 300px !important;
    }

    .tab-contents {
        text-align: left;
        font-size: smaller;
    }

    .partial {
        max-height: 120px;
        overflow: hidden;
        font-size: 14px !important;
        text-align: left !important;
    }

    .dots {
        display: inline;
    }

    .full {
        max-height: none;
    }

    .full .dots {
        display: none;
    }

    .about-me>#see-more {
        text-align: left;
        padding: 0 20px;
        margin-bottom: 30px;
        display: block;
        font-size: 12px;
        cursor: pointer;
    }

    .contact-left,
    .contact-right {
        flex-basis: 100%;
    }

    .copyright {
        font-size: smaller;
    }

    .work .layer {
        font-size: smaller;
        gap: 5px;
        padding: 0 20px;
    }

    .work .layer h3 {
        margin-bottom: 10px;
    }

    .work .layer a {
        margin-top: 10px;
    }

}