* {
    padding: 0;
    margin: 0;
    border: none;
    outline: none;
    box-sizing: border-box;
    font-family: 'poppins', sans-serif;
    list-style: none;
    text-decoration: none;
    scroll-behavior: smooth;
}

:root {
    --bg-color: #1f242d;
    --second-color: #323946;
    --main-color: #22c55e;
    --white-color: #fff;
    --disabled-color: #fff3;
}

body {
    color: var(--white-color);
}

header {
    position: fixed;
    right: 0;
    top: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    visibility: hidden;
    opacity: 0;
    background: var(--bg-color);
    padding: 2rem 9%;
    border-bottom: 1px solid transparent;
    transition: all .40s ease;
}

header.active {
    animation: show-header 1.5s linear forwards;
    animation-delay: .5s;
}

@keyframes show-header {
    100% {
        visibility: visible;
        opacity: 1;
    }
}

.logo {
    font-size: 2rem;
    color: var(--white-color);
    font-weight: 700;
}

nav a {
    font-size: 1rem;
    color: var(--white-color);
    font-weight: 500;
    margin-left: 3.5rem;
    transition: .5s all;
}

nav a:hover,
nav a.active {
    color: var(--main-color);
    /* border-bottom: 2px solid var(--main-color); */
}

#menu-icon {
    font-size: 3rem;
    display: none;
}

section {
    width: 100%;
    height: 100%;
    padding: 8rem 9% 2rem;
    background-color: var(--bg-color);
}

.home {
    display: flex;
    gap: .5rem;
    height: inherit;
}

.home-img {
    width: 35%;
    align-self: self-end;
    animation: zoom-in 1.5s ease-in-out forwards;
}

.home-img img {
    width: 160%;
    margin-left: -8rem;
    margin-top: -2rem;
}

.home-l {
    width: 30%;
    animation: slide-from-bottom 1.5s ease-in-out forwards;
}

.home-l h1 {
    font-size: 6rem;
    font-weight: 800;
    transition: .3s;
}

.home-r {
    width: 40%;
    align-self: self-end;
    margin-bottom: 1.5rem;
    animation: slide-from-top 1.5s ease-in-out forwards;
}

.home-r h5 {
    font-size: 1rem;
    margin-bottom: .5rem;
    color: var(--main-color);
}

.home-r h3 {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--white-color);
    margin-bottom: 1rem;
    line-height: 2.7rem;
}

.home-r h4 {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--disabled-color);
    margin-bottom: 1rem;
    line-height: 2rem;
}

@keyframes fade-out {
    100% {
        visibility: visible;
        opacity: 1;
    }
}

@keyframes zoom-in {
    from {
        transform: scale(0);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes zoom-out {
    from {
        transform: scale(2);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes slide-from-top {
    0% {
        transform: translateY(-100%);
        opacity: 0;
    }

    50% {
        opacity: 0;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slide-from-bottom {
    0% {
        transform: translateY(100%);
        opacity: 0;
    }

    50% {
        opacity: 0;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fade-in {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}


.services {
    width: 100%;
    height: 100vh;
    background-color: var(--bg-color);
    color: var(--white-color);
    align-items: center;
    justify-content: center;
}

.home-l .btn-sci {
    display: inline-block;
}

.btn {
    display: inline-block;
    padding: .5rem 2rem;
    background: var(--main-color);
    border: .2rem solid var(--main-color);
    border-radius: 4rem;
    box-shadow: 0 0 1rem var(--main-color);
    font-size: 1rem;
    color: var(--bg-color);
    font-weight: 600;
    transition: .5s;
    margin-right: 1rem;
}

.btn:hover {
    background: transparent;
    color: var(--main-color);
    box-shadow: none;
}

.home-l .btn-sci .sci {
    margin-top: 2rem;
}

.home-l .btn-sci .sci a {
    display: inline-flex;
    padding: .5rem;
    border: .2rem solid var(--main-color);
    border-radius: 50%;
    font-size: 1.5rem;
    color: var(--main-color);
    margin: 0 .8rem 0 0;
    transition: .5s;
}

.home-l .btn-sci .sci a:hover {
    background: var(--main-color);
    color: var(--bg-color);
    box-shadow: 0 0 1rem var(--main-color);
}

.heading {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 2rem;
}

.heading span {
    color: var(--main-color);
}

.services {
    height: inherit;
}

.services-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr));
    gap: 2rem;
    transition: all .7s ease-in-out;
    animation: fade-in 1s ease-in-out forwards;
}

.services-container .services-box {
    padding: 2rem 2rem;
    background: var(--second-color);
    border: .2rem solid var(--second-color);
    border-radius: 1rem;
    transition: .5s;
}

.services-container .services-box:hover {
    border-color: var(--main-color);
    transform: scale(1.02);
}

.services-box .icon {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.services-box .icon i {
    font-size: 2.5rem;
    transition: .5s;
}

.services-box:hover .icon :not(a i) {
    color: var(--main-color);
}

.services-box .icon a {
    display: inline-flex;
    background-color: var(--white-color);
    border-radius: 50%;
    padding: .6rem;
    transition: .5s;
}

.services-box:hover .icon a {
    background: var(--main-color);
}

.services-box .icon a i {
    font-size: 2rem;
    color: var(--bg-color);
    transform: rotate(225deg);
    transition: .5s;
}

.services-box .icon a:hover i {
    transform: rotate(180deg);
}

.services-box h3 {
    font-size: 2rem;
    margin: .5rem 0 1rem;
    transition: .5s;
}

.services-box:hover h3 {
    color: var(--main-color);
}

.services-box p {
    font-size: 1rem;
}

.resume-container {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 2rem;
}

.resume-box h2 {
    font-size: 2rem;
}

.resume-box p {
    font-size: 1rem;
}

.resume-box .desc {
    margin: 2rem 0 2.5rem;
}

.resume-box .resume-btn {
    width: 100%;
    height: 4rem;
    background: var(--second-color);
    border: .2rem solid var(--second-color);
    font-size: 1.6rem;
    color: var(--white-color);
    font-weight: 500;
    margin-bottom: 1.6rem;
    border-radius: .8rem;
    cursor: pointer;
}

.resume-box .resume-btn.active {
    border-color: var(--main-color);
    color: var(--main-color);
}

.resume-detail {
    display: none;
}

.resume-detail.active {
    display: block;
}

.resume-box .heading {
    text-align: left;
}

.resume-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr));
    gap: 1.5rem;
    height: 35rem;
    overflow: auto;
}

.resume-list::-webkit-scrollbar {
    width: .5rem;
}

.resume-list::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 1rem;
}

.resume-list:hover::-webkit-scrollbar-thumb {
    background: var(--main-color);
}

.resume-list .resume-item {
    background: var(--second-color);
    border-radius: .8rem;
    padding: 3rem 2.5rem;
    height: calc((45rem - 2rem)/2);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.resume-item .year {
    color: var(--main-color);
}

.resume-item h3 {
    font-size: 2rem;
}

.resume-detail.certificates h3 {
    font-size: 1.3rem;
}

.resume-item .company {
    position: relative;
    margin-left: 2rem;
    margin-bottom: 2rem;
}

.resume-item .company::before {
    content: '';
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    padding: .5rem;
    background: var(--main-color);
    border-radius: 50%;
    margin-left: -2rem;
}

.resume-detail.skills .resume-list {
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
    height: auto;
    overflow: visible;
}

.resume-detail.skills .resume-item {
    position: relative;
    align-items: center;
    height: auto;
}

.resume-detail.skills .resume-item i {
    font-size: 4.5rem;
}

.resume-detail.skills .resume-item:hover i {
    color: var(--main-color);
}

.resume-detail.skills .resume-item span {
    position: absolute;
    top: -20%;
    background: var(--white-color);
    color: var(--bg-color);
    font-size: 1rem;
    padding: .5rem 1rem;
    border-radius: .6rem;
    pointer-events: none;
    opacity: 0;
    transform: scale(.9);
    transition: .2s;
}

.resume-detail.skills .resume-item:hover span {
    top: -25%;
    opacity: 1;
    transform: scale(1);
}

/* achievements section */

/* .resume-detail.achievements {
} */

.scroll-container {
  max-height: 37.5rem; /* 600px */
  overflow-y: auto;
  padding-right: 0.5rem; /* 8px */
}

/* Minimal thin scrollbar */
.scroll-container::-webkit-scrollbar {
  width: 4px;
}
.scroll-container::-webkit-scrollbar-track {
  background: transparent;
}
.scroll-container::-webkit-scrollbar-thumb {
  background-color: #444;
  border-radius: 0.25rem;
}
.scroll-container:hover::-webkit-scrollbar-thumb {
  background-color: #10b981;
}

.masonry-gallery {
  column-count: 3;
  column-gap: 1rem; /* 16px */
}

.masonry-gallery img {
  width: 100%;
  border-radius: 0.375rem; /* 6px */
  margin-bottom: 1rem; /* 16px */
  transition: transform 0.3s ease;
  display: block;
  cursor: pointer;
}

.masonry-gallery img:hover {
  transform: scale(1.05);
  z-index: 1;
}


/* projects section */
.project-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
    gap: 1rem;
}

.project-container .project-box {
    padding: 2rem 2rem;
    background: var(--second-color);
    border: .2rem solid var(--second-color);
    border-radius: 1rem;
    transition: .5s;
}

.project-container .project-box:hover {
    border-color: var(--main-color);
    transform: scale(1.02);
}

.project-container .project-box img {
    width: 100%;
    border-radius: .5rem;
}

.project-box .icon {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.project-box .icon h6 {
    font-size: .8rem;
    font-weight: 500;
}

.project-box h3 {
    font-size: 1.3rem;
    font-weight: 600;
}

.project-box:hover .icon :not(a i) {
    color: var(--main-color);
}

.project-box .icon a {
    display: inline-flex;
    background-color: var(--white-color);
    border-radius: 50%;
    padding: .4rem;
    transition: .5s;
}

.project-box:hover .icon a {
    background: var(--main-color);
}

.project-box .icon i {
    font-size: 1.6rem;
    color: var(--bg-color);
    transform: rotate(225deg);
    transition: .5s;
}

.project-box .icon a:hover i {
    transform: rotate(180deg);
}

.project-box.extra {
    display: none;
}

.projects .btn {
    cursor: pointer;
}

.modal {
    display: none;
    /* keep this as it is */
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 9999;

    justify-content: center;
    align-items: center;
    flex-direction: column;
}


.modal-content {
    max-width: 90%;
    max-height: 80vh;
    border-radius: 12px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}

.close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 35px;
    color: #fff;
    cursor: pointer;
}



.close {
    position: fixed;
    top: 20px;
    right: 30px;
    font-size: 35px;
    color: #fff;
    cursor: pointer;
    z-index: 10000;
}


.show-all .project-box.extra {
    display: block;
}

.see-more-wrapper {
    text-align: center;
    margin-top: 20px;
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 3rem;
}

.contact-container .contact-box:first-child {
    align-self: center;
}

.contact-box h2 {
    font-size: 3rem;
}

.contact-box p {
    font-size: 1rem;
}

.contact-box .desc {
    margin: 1.5rem 0 2.5rem;
}

.contact-box .contact-details {
    display: flex;
    align-items: center;
    margin: 2rem 0;
}

.contact-details i {
    display: inline-flex;
    background: var(--second-color);
    color: var(--main-color);
    font-size: 3rem;
    padding: 1rem;
    border-radius: .6rem;
    margin-right: 1.5rem;
    cursor: pointer;
}

.contact-details .detail p:first-child {
    color: var(--main-color);
}

.contact-box form {
    background: var(--second-color);
    padding: 2.5rem 3.5rem 3.5rem;
    border-radius: 1rem;
    text-align: center;
}

.contact-box .heading {
    font-size: 3rem;
}

.contact-box .field-box {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.contact-box .field-box input,
.contact-box .field-box textarea {
    padding: 1rem;
    background: var(--bg-color);
    border: .15rem solid var(--bg-color);
    border-radius: .6rem;
    font-size: 1rem;
    color: var(--white-color);
}

.contact-box .field-box textarea {
    grid-column: 1 / -1;
    height: 16rem;
    resize: none;
}

.contact-box .field-box input:focus,
.contact-box .field-box textarea:focus {
    border-color: var(--main-color);
}

.contact-box .btn {
    margin-top: 2rem;
    cursor: pointer;
}

.sci {
    margin-top: 2rem;
}

.sci a {
    display: inline-flex;
    padding: .5rem;
    border: .2rem solid var(--main-color);
    border-radius: 50%;
    font-size: 1.5rem;
    color: var(--main-color);
    margin: 0 .8rem 0 0;
    transition: .5s;
}

.sci a:hover {
    background: var(--main-color);
    color: var(--bg-color);
    box-shadow: 0 0 1rem var(--main-color);
}



.footer-container {
    width: 100%;
    display: flex;
    justify-content: center;
}

.footer-container .footer-box a {
    font-size: 1rem;
    margin-left: 1rem;
    color: var(--white-color);
    cursor: pointer;
}

.last-text {
    text-align: center;
    margin-top: 1rem;
}

@media screen and (max-width: 1200px) {
    html {
        font-size: 85%;
    }

    nav a {
        font-size: 1.3rem;
    }

    .logo {
        font-size: 2.2rem;
    }

    .home {
        gap: 3rem;
    }

    .footer {
        padding-top: 2rem;
    }
}

@media screen and (max-width: 990px) {
    header {
        padding: 2rem 4%;
    }

    section {
        padding: 10rem 4% 2rem;
    }
}

@media screen and (max-width: 810px) {
    .contact-box .field-box {
        grid-template-columns: 1fr;
    }
}

@media screen and (max-width: 760px) {
    #menu-icon {
        display: block;
        cursor: pointer;
    }

    nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        padding: 1rem 0;
        background: var(--bg-color);
        border-top: .1rem solid rgba(0, 0, 0, .2);
        box-shadow: 0 .5rem 1rem rgba(0, 0, 0, .2);
        text-align: center;
        display: none;
    }

    nav.active {
        display: block;
    }

    nav a {
        display: block;
        margin: 4rem 0;
    }

    .home {
        flex-direction: column;
        justify-content: center;
    }

    .home-img,
    .home-r,
    .home-l {
        align-self: center;
    }

    .home-r,
    .home-l {
        width: 80%;
    }

    .home-img {
        width: auto;
    }

    .home-img img {
        width: 100%;
        margin-left: 0;
        margin-top: 0;
    }

    .resume-container,
    .contact-container {
        grid-template-columns: 1fr;
    }

    .resume-container {
        gap: 3rem;
    }

    .contact-box .contact-outline {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: .6rem;
    }

    .contact-box .field-box {
        grid-template-columns: repeat(2, 1fr);
    }

}

@media screen and (max-width: 600px) {

    .home-l h1 {
        font-size: 3.6rem;
    }

    .contact-box .contact-outline {
        grid-template-columns: repeat(1, 1fr);
    }

    .contact-box .field-box {
        grid-template-columns: repeat(1, 1fr);
    }

    .contact-box form {
        padding: 0.5rem 1.5rem 1.5rem;
    }

    .project-box .icon :not(a i) {
        color: var(--main-color);
    }
}