/* ==================== TABLET RESPONSIVE ==================== */
@media (max-width: 768px) {
    /* Home Section */
    .home {
        margin: 100px 0 0;
    }
    .home .container {
        width: 95%;
        margin: 0 auto;
    }

    .home .main-cont {
        width: 80%;
        height: 450px;
        flex-basis: auto;
    }

    .home .main-cont .myname {
        padding: 18px;
    }

    .home .myname h1 {
        font-size: 2rem;
        line-height: 1.2;
    }

    .home .myname a {
        padding: 10px 35px;
        font-size: 13px;
    }

    #backToTopBtn i {
        font-size: 16px;
    }
    /* Navbar */
    header {
        margin: 10px 10px;
    }

    nav {
        width: 95%;
        justify-content: space-between;
    }

    nav button {
        padding: 12px 20px;
    }

    #navlinks {
        position: fixed;
        top: 0;
        right: 0;
        width: 40%;
        height: 100vh;
        transform: translateX(105%);
        opacity: 0;
    }

    /* Service Section */
    .service .container {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        padding: 30px 20px;
    }

    .moreservice {
        width: 90%;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: space-around;
        padding: 15px;
    }

    .moreservice .srv-list ul {
        margin: 0 20px;
    }

    /* About Section */
    .about {
        padding: 30px;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .about .aboutme {
        text-align: left;
        margin-bottom: 20px;
    }

    .about .aboutme h1 {
        font-size: 2.5rem;
        margin-left: 0;
        font-weight: 400;
    }

    .about .aboutme p {
        width: 100%;
        font-size: 13px;
        margin-left: 0;
    }

    .about .aboutme-image {
        width: 300px;
        height: 300px;
        margin: 0 20px;
    }

    /* Projects Section */
    .projects h1 {
        font-size: 2.5rem;
    }

    .projects .container {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
        padding: 20px;
    }

    .projects .container .box {
        margin: 15px;
    }

    /* Contact Section */
    .contact h1 {
        font-size: 4rem;
    }

    .cont-prag {
        width: 80%;
        font-size: 13px;
        margin: 0 auto 20px auto;
        text-align: center;
    }

    .contact-container {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        align-items: flex-start;
    }

    .contact-container .info {
        width: 45%;
        margin: 10px;
    }

    .contact .info-p {
        width: 100%;
        font-size: 13px;
    }

    .contact-image {
        width: 320px;
        height: 320px;
        margin: 20px;
    }

    /* Footer */
    footer {
        padding: 40px 20px;
    }

    footer .end {
        margin: 10px;
        padding: 15px;
    }

    footer .end p {
        width: 100%;
        font-size: 13px;
    }
}



/* ==================== MOBILE RESPONSIVE ==================== */
@media (max-width: 500px) {
    /* Home Section */
    .home .box-cont .img {
        height: 250px;
    }

    .home .container {
        width: 90%;
        margin: 0 auto;
    }

    .home .main-cont {
        width: 90%;
        height: 400px;
        flex-basis: auto;
    }

    .home .main-cont .myname {
        padding: 18px;
    }

    .home .myname h1 {
        font-size: 1.5rem;
        line-height: 1.2;
    }

    .home .myname a {
        padding: 10px 25px;
        font-size: 12px;
    }

    /* Navbar */
    header {
        margin: 10px 5px;
    }

    nav {
        width: 90%;
        height: 70px;
        justify-content: space-between;
    }

    nav button {
        display: none;
    }

    nav #menu {
        display: block;
        cursor: pointer;
    }

    #navlinks {
        margin: -10px;
        position: fixed;
        top: 0;
        right: 0;
        width: 60%;
        height: 100vh;
        background-color: rgb(110, 4, 57);
        transform: translateX(100%);
        backdrop-filter: blur(20px);
        opacity: 0;
        transition: transform 0.5s ease, opacity 0.5s ease;
        display: flex;
        flex-direction: column;
        z-index: 10;
        border-radius: 20px 0 0 20px;
    }

    #navlinks.show {
        transform: translateX(0);
        opacity: 1;
    }

    #navlinks li {
        font-size: 14px;
        padding: 40px 30px 0px;
    }

    #close {
        display: block;
        position: absolute;
        top: 15px;
        right: 15px;
        z-index: 11;
    }

    #close i {
        font-size: 2rem;
        cursor: pointer;
    }

    /* Service Section */
    .service .container {
        padding: 20px 10px;
        grid-template-columns: 1fr;
    }

    .moreservice {
        width: 80%;
        padding: 15px;
        flex-direction: column;
        align-items: flex-start;
    }

    .moreservice .srv-list ul {
        margin: 0 10px 10px 0;
    }

    /* About Section */
    .about {
        padding: 20px;
        flex-direction: column;
        align-items: center;
    }

    .about .aboutme {
        width: 90%;
    }

    .about .aboutme h1 {
        font-size: 2rem;
        margin-left: 0;
    }

    .about .aboutme p {
        width: 100%;
        font-size: 12px;
        margin-left: 0;
    }

    .about .aboutme a {
        padding: 10px 50px;
        margin-left: 0;
    }

    .about .aboutme-image {
        width: 260px;
        height: 260px;
        margin-left: 0;
        margin-top: 20px;
    }

    /* Projects Section */
    .projects h1 {
        font-size: 2rem;
    }

    .projects .container {
        grid-template-columns: 1fr;
        padding: 10px;
    }

    .projects .container .box {
        margin: 15px 0;
    }

    /* Contact Section */
    .contact h1 {
        font-size: 3rem;
        text-align: center;
    }

    .cont-prag {
        width: 90%;
        font-size: 12px;
        margin: 15px auto;
        text-align: center;
    }

    .contact-container {
        flex-direction: column;
        align-items: center;
    }

    .contact-container .info {
        width: 90%;
        margin: 10px 0;
    }

    .contact .info-p {
        width: 100%;
        margin: 0 0 15px 0;
    }

    .contact-info{
        margin: 0 10px;
    }

    .contact-image {
        width: 280px;
        height: 280px;
    }

    /* Footer */
    footer {
        padding: 30px 10px;
        border-radius: 40px 0 0 0;
    }

    footer .end {
        margin: 10px;
        padding: 10px;
    }

    footer .end p {
        width: 100%;
        font-size: 12px;
    }
}