* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    scroll-behavior: smooth;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

:root {
    --bg-color: #1f242d;
    --second-bg-color: #323946;
    --text-color: #fff;
    --main-color: #0ef;
}

html {
    font-size: 62.5%;
    overflow-x: hidden;
}

body {
    background: var(--bg-color);
    color: var(--text-color);
    overflow-x: hidden;
}

section {
    min-height: 100vh;
    padding: 10rem 9% 2rem;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 2rem 9%;
    background-color: var(--bg-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
}

.header.sticky {
    border-bottom: 0.1rem solid rgba(0, 0, 0, 0.2);
}

.logo {
    font-size: 2.5rem;
    color: var(--text-color);
    font-weight: 600;
    cursor: default;
}

/* Hide menu icon by default */
#menu-icon {
    font-size: 2.5rem;
    color: #fff;
    display: none;
    cursor: pointer;
}

/* Mobile styles */
@media (max-width: 768px) {
    .navbar {
        position: absolute;
        top: 100%;
        right: -100%;
        background: #111;
        width: 100%;
        height: 100vh;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: right 0.3s ease;
    }

    .navbar a {
        display: block;
        font-size: 2rem;
        margin: 1.5rem 0;
    }

    #menu-icon {
        display: block;
    }

    .navbar.active {
        right: 0;
    }
}


.navbar {
    display: flex;
    align-items: center;
}

.navbar a {
    font-size: 1.7rem;
    color: var(--text-color);
    margin-left: 4rem;
    transition: 0.3s;
}

.navbar a:hover,
.navbar a.active {
    color: var(--main-color);
}

/* Home Section */
.home {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.home-img {
    flex: 1 1 40rem;
    text-align: center;
}

.home-img img {
    width: 100%;
    max-width: 350px;
    animation: floatImage 4s ease-in-out infinite;
}

@keyframes floatImage {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-2.4rem);
    }

    100% {
        transform: translateY(0);
    }
}

.home-content {
    flex: 1 1 45rem;
}

.home-content h3 {
    font-size: 3.2rem;
    font-weight: 700;
}

.home-content h3:nth-of-type(2) {
    margin-bottom: 2rem;
}

span {
    color: var(--main-color);
}

.home-content h1 {
    font-size: 5.6rem;
    font-weight: 700;
    line-height: 1.3;
}

.home-content p {
    font-size: 1.6rem;
}

.social-media a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4rem;
    height: 4rem;
    background: transparent;
    border: 0.2rem solid var(--main-color);
    border-radius: 50%;
    font-size: 2rem;
    color: var(--main-color);
    margin: 3rem 1.5rem 3rem 0;
    transition: 0.5s ease;
}

.social-media a:hover {
    background: var(--main-color);
    color: var(--second-bg-color);
    box-shadow: 0 0 1rem var(--main-color);
}

.btn {
    display: inline-block;
    padding: 1rem 2.8rem;
    background: var(--main-color);
    border-radius: 4rem;
    box-shadow: 0 0 1rem var(--main-color);
    font-size: 1.6rem;
    color: var(--second-bg-color);
    font-weight: 600;
    transition: 0.5s ease;
}

.btn:hover {
    box-shadow: none;
}

/* About Section */
.about {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
    background: var(--second-bg-color);
}

.about-img {
    flex: 1 1 40rem;
    text-align: center;
}

.about-img img {
    width: 100%;
    max-width: 350px;
}

.about-content {
    flex: 1 1 45rem;
}

.about-content h2 {
    font-size: 4.5rem;
    line-height: 1.2;
}

.about-content h3 {
    font-size: 3rem;
}

.about-content p {
    font-size: 1.6rem;
    margin: 2rem 0 3rem;
}

.about-content .heading {
    text-align: center;
    font-size: 4.5rem;
    margin-bottom: 50px;
}

.heading {
    text-align: center;
    font-size: 4.5rem;
}


/* Education */
.education {
    background-color: var(--bg-color);
}

.education .heading {
    text-align: center;
    font-size: 5rem;
    margin-bottom: 50px;
    color: var(--main-color);
}

.education-container {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.education-box {
    background: var(--second-bg-color);
    padding: 3rem 2rem;
    border-radius: 2rem;
    text-align: left;
    transition: 0.5s ease;
    border: 0.2rem solid var(--bg-color);
}

.education-box:hover {
    transform: scale(1.02);
    border-color: var(--main-color);
}

.education-box h3 {
    font-size: 2.6rem;
}

.education-box h4 {
    font-size: 1.6rem;
    line-height: 30px;
}

.education-box p {
    line-height: 30px;
    font-size: 1.6rem;
    color: var(--main-color);
}

.education span {
    color: var(--text-color);
}

.education-detail {
    display: flex;
    justify-content: space-between;
}

/* Services + Portfolio Grid */
.services {
    background-color: var(--second-bg-color);
}

.services h2 {
    margin-bottom: 5rem;
    text-align: center;
}

.services-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
    gap: 2.5rem;
}

.services-box {
    background: var(--bg-color);
    padding: 3rem 2rem;
    border-radius: 2rem;
    text-align: left;
    transition: 0.5s ease;
    border: 0.2rem solid var(--bg-color);
}

.services-box:hover {
    transform: scale(1.02);
    border-color: var(--main-color);
}

.services-box i {
    font-size: 7rem;
    color: var(--main-color);
}

.services-box h3 {
    font-size: 2.6rem;
}

.services-box p {
    font-size: 1.6rem;
    margin: 1rem 0 3rem;
}

/* Portfolio Hover Effects */
.portfolio-box {
    position: relative;
    box-shadow: 0 0 1rem var(--bg-color);
}

.portfolio-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
    gap: 2.5rem;
}

.portfolio-box h2 {
    font-size: 2rem;
}

.portfolio-box:hover {
    transform: scale(1.02);
    border-color: var(--main-color);
}

.portfolio-box {
    background: var(--second-bg-color);
    padding: 3rem 2rem;
    border-radius: 2rem;
    text-align: left;
    transition: 0.5s ease;
    border: 0.2rem solid var(--bg-color);
}

.portfolio h2 {
    margin-bottom: 5rem;
    text-align: center;
}

.portfolio-box img {
    width: 100%;
}

.portfolio-layer {
    background: linear-gradient(rgba(0, 0, 0, 0.6), var(--second-bg-color));
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: 0.5s ease;
    text-align: center;
    padding: 2rem;
}

.portfolio-layer h4 {
    font-size: 2rem;
    color: var(--main-color);
}

.portfolio-layer p {
    font-size: 1.5rem;
    margin: 1rem 0;
}

.portfolio-layer a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 5rem;
    height: 5rem;
    background: var(--main-color);
    border-radius: 50%;
}

.portfolio-layer a i {
    font-size: 2rem;
    color: var(--second-bg-color);
}

.tech-icons {
    margin: 1.5rem 0;
    font-size: 2rem;
    color: var(--main-color);
}

.tech-icons i {
    margin-right: 1rem;
}


/* Contact Section */
.contact {
    background-color: var(--second-bg-color);
}

.contact .heading {
    text-align: center;
    margin-bottom: 100px;
}

.contact-info {
    margin-top: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 2rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
    vertical-align: middle;
    align-items: center;

}

.contact-info p,
.contact-info a {
    font-size: 1.6rem;
    word-break: break-word;
    overflow-wrap: break-word;
    word-wrap: break-word;
    display: block;
    margin: 10px;
}


.contact-info p {
    font-size: 2.5rem;
    font-weight: 600;
    display: flex;
}

.contact-info a {
    color: var(--text-color);
}

.contact-info a:hover {
    text-decoration: underline;
}

.contact-info i {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 5rem;
    height: 5rem;
    background: var(--main-color);
    border-radius: 50%;
    font-size: 2rem;
    color: var(--bg-color);
}


/* Footer */
.footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    padding: 2rem 9%;
    background: var(--bg-color);
}

.footer-text {
    display: flex;
    flex-direction: row;
    font-size: 2.5rem;
    font-weight: 600;
}

.footer-text i {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 5rem;
    height: 5rem;
    background: var(--second-bg-color);
    border-radius: 50%;
    font-size: 2rem;
    color: var(--main-color);
    margin-right: 10px;
}

.footer-iconTop a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 0.8rem;
    background: var(--main-color);
    border-radius: 0.8rem;
    transition: 0.5s ease;
    margin: 5px;
}

.footer-iconTop a:hover {
    box-shadow: 0 0 1rem var(--main-color);
}

.footer-iconTop a i {
    font-size: 2.4rem;
    color: var(--second-bg-color);
}

/* Responsive Design */
@media (max-width: 1024px) {
    html {
        font-size: 55%;
    }

    .header {
        padding: 2rem 5%;
    }

    section {
        padding: 10rem 5% 2rem;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 50%;
    }

    .header {
        flex-direction: column;
        align-items: flex-start;
    }

    .navbar {
        flex-direction: column;
        background: var(--bg-color);
        width: 100%;
        display: none;
    }

    .navbar.active {
        display: flex;
    }

    .navbar a {
        margin: 1rem 0;
    }

    .home,
    .about {
        flex-direction: column;
        text-align: center;
    }

    .home-content,
    .about-content {
        text-align: center;
    }

    .contact-info {
        grid-template-columns: 1fr;
    }

    .footer {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .home-content h1 {
        font-size: 3.6rem;
    }

    .home-content h3 {
        font-size: 2.2rem;
    }

    .btn {
        font-size: 1.4rem;
        padding: 0.8rem 2.4rem;
    }

    .portfolio-container,
    .services-container,
    .education-container {
        grid-template-columns: 1fr;
    }
}

/* ----------- Tablets (max-width: 1024px) ----------- */
@media (max-width: 1024px) {
    .education .heading {
        font-size: 4rem;
        margin-bottom: 4rem;
    }

    .education-box {
        padding: 2.5rem 2rem;
    }

    .education-box h3 {
        font-size: 2.3rem;
    }

    .education-box h4 {
        font-size: 1.5rem;
        line-height: 2.8rem;
    }

    .education-box p {
        font-size: 1.5rem;
        line-height: 2.8rem;
    }
}

/* ----------- Mobile & Small Tablets (max-width: 768px) ----------- */
@media (max-width: 768px) {
    .education .heading {
        font-size: 3.2rem;
        margin-bottom: 3rem;
        text-align: center;
    }

    .education-container {
        gap: 2rem;
        padding: 0 5%;
    }

    .education-box {
        padding: 2rem 1.5rem;
    }

    .education-box h3 {
        font-size: 2rem;
    }

    .education-box h4 {
        font-size: 1.4rem;
        line-height: 2.5rem;
    }

    .education-box p {
        font-size: 1.4rem;
        line-height: 2.5rem;
    }

    .education-detail {
        flex-direction: column;
        gap: 1rem;
    }
}

/* ----------- Mobile Phones (max-width: 480px) ----------- */
@media (max-width: 480px) {
    .education .heading {
        font-size: 2.8rem;
        margin-bottom: 2.5rem;
    }

    .education-container {
        gap: 1.5rem;
        padding: 0 5%;
    }

    .education-box {
        padding: 1.5rem 1rem;
    }

    .education-box h3 {
        font-size: 1.8rem;
    }

    .education-box h4 {
        font-size: 1.2rem;
        line-height: 2.2rem;
    }

    .education-box p {
        font-size: 1.2rem;
        line-height: 2.2rem;
    }
}
