@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
    scroll-behavior: smooth;
}

:root {
    --primary: #FF5A8E;
    --secondary: #0D1B40;
    --accent: #41C9E2;
    --dark: #081029;
    --light: #FFF5F8;
    --text: #0D1B40;
    --text-light: #6C7A9C;
    --light-gray: #f5f5f5;
    --gray: #e0e0e0;
}

/* Header styling */
header {
    height: 100vh;
    width: 300px;
    padding: 15px 30px;
    background-color: var(--secondary);
    overflow: auto;
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    transition: 0.4s;
    z-index: 99;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
}

header .profile {
    text-align: center;
    margin: 30px 0;
}

header .profile img {
    width: 150px;
    border-radius: 50%;
    border: 5px solid var(--accent);
    box-shadow: 0 10px 20px rgba(65, 201, 226, 0.3);
}

header .profile h1 {
    color: var(--light);
    font-weight: 600;
    margin-top: 15px;
}

header .profile .social-icons a {
    display: inline-block;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    text-align: center;
    line-height: 37px;
    background-color: var(--dark);
    color: var(--light);
    font-size: 18px;
    margin: 1.5px;
    transition: 0.3s;
    margin-top: 10px;
}

header .profile .social-icons a:hover {
    background-color: var(--primary);
    transform: translateY(-3px);
}

header nav {
    margin-top: 40px;
}

header nav ul li {
    list-style: none;
}

header nav ul li a {
    display: flex;
    align-items: center;
    text-decoration: none;
    padding: 10px;
    margin: 7px 0;
    color: var(--text-light);
    font-size: 15px;
    letter-spacing: 0.6px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

header nav ul li a i {
    margin-right: 10px;
    font-size: 20px;
    transition: 0.3s;
}

header nav ul li a:hover {
    color: var(--light);
    background: rgba(255, 90, 142, 0.1);
    transform: translateX(5px);
}

header nav ul li a:hover i {
    color: var(--primary);
}

header nav ul li .active {
    color: var(--light);
    background: rgba(255, 90, 142, 0.1);
}

header nav ul li .active i {
    color: var(--primary);
}

hr {
    border: none;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 5px 0;
}

header .footer {
    text-align: center;
    background-color: var(--secondary);
    width: 300px;
    color: var(--text-light);
    font-size: 14px;
    letter-spacing: 0.6px;
    padding: 15px;
    position: fixed;
    bottom: 0;
    left: 0;
    transition: 0.4s;
}

header .footer p a {
    color: var(--primary);
    text-decoration: none;
}

#MenuBtn {
    position: fixed;
    bottom: 25px;
    right: 25px;
    font-size: 20px;
    width: 45px;
    height: 45px;
    color: var(--light);
    background-color: var(--primary);
    text-align: center;
    line-height: 45px;
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(255, 90, 142, 0.4);
    display: none;
    z-index: 999;
    transition: all 0.3s ease;
}

#MenuBtn:hover {
    background-color: var(--dark);
    transform: translateY(-5px);
}

@media only screen and (max-width: 1050px) {
    header {
        left: -300px;
    }
    header .footer {
        left: -300px;
    }
    #MenuBtn {
        display: block;
    }
}

/* Header Toggle */
.mobile-nav-active header {
    left: 0;
}

.mobile-nav-active .footer {
    left: 0;
}

main {
    margin-left: 300px;
    background-color: var(--light);
    transition: 0.3s;
}

@media only screen and (max-width: 1050px) {
    main {
        margin-left: 0;
    }
}

/* Home section */
#home {
    height: 100vh;
    width: 100%;
    background-image: url(image/Andile.png);
    background-size: cover;
    background-attachment: fixed;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10px;
    position: relative;
}

#home::before {
    content: '';
    width: 100%;
    height: 100%;
    background-color: rgba(8, 16, 41, 0.7);
    position: absolute;
    top: 0;
    left: 0;
}

#home .home-row {
    z-index: 1;
    padding-left: 50px;
}

#home .home-row h1 {
    font-size: 60px;
    color: var(--light);
    font-weight: 700;
    letter-spacing: -1px;
    margin-bottom: 20px;
    line-height: 1.2;
}

#home .home-row p {
    color: var(--light);
    font-size: 30px;
    font-weight: 500;
    margin-bottom: 30px;
}

#home .home-row p span {
    color: var(--primary);
    font-weight: 700;
}

.btn {
    display: inline-block;
    font-weight: 600;
    margin: 10px 5px;
    padding: 14px 35px;
    border-radius: 30px;
    text-decoration: none;
    color: var(--light);
    transition: 0.4s;
    background-color: var(--primary);
    box-shadow: 0 5px 15px rgba(255, 90, 142, 0.4);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 14px;
}

.btn:hover {
    background: var(--secondary);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(13, 27, 64, 0.3);
}

/* Section styling (common) */
section {
    padding: 90px 40px;
}

section:nth-child(odd) {
    background: var(--light);
}

section:nth-child(even) {
    background: var(--light-gray);
}

.sub-heading {
    color: var(--text);
    font-size: 36px;
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.sub-heading::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -10px;
    width: 50px;
    height: 4px;
    background-color: var(--primary);
    border-radius: 2px;
}

.divider {
    width: 80px;
    height: 4px;
    background-color: var(--primary);
    border-radius: 2px;
    margin-bottom: 20px;
    display: none; /* Hide since we're using ::after instead */
}

.sub-para {
    color: var(--text-light);
    font-size: 18px;
    letter-spacing: 0.4px;
    font-weight: 400;
    margin-top: 25px;
    margin-bottom: 50px;
    max-width: 800px;
}

/* About section */
#about {
    background: var(--light);
}

#about .about-col {
    display: flex;
    gap: 50px;
    margin-top: 40px;
}

#about .about-col .info-col {
    flex: 1;
}

#about .about-col .info-col h2 {
    color: var(--primary);
    font-weight: 700;
    font-size: 32px;
    margin-bottom: 15px;
}

#about .about-col .info-col p {
    color: var(--text-light);
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 25px;
}

#about .about-col .info-col .icon-list-col {
    display: flex;
    gap: 40px;
    margin-top: 30px;
}

#about .about-col .info-col .icon-list-col .icon-list ul li {
    list-style: none;
    margin: 15px 0;
    color: var(--text);
}

#about .about-col .info-col .icon-list-col .icon-list ul li i {
    color: var(--primary);
    margin-right: 10px;
}

#about .about-col .info-col .icon-list-col .icon-list ul li strong {
    color: var(--text);
    font-weight: 600;
    margin-right: 5px;
}

#about .about-col .info-col .icon-list-col .icon-list ul li span,
#about .about-col .info-col .icon-list-col .icon-list ul li span a {
    color: var(--text-light);
    font-weight: 400;
    text-decoration: none;
}

#about .about-col .info-col .icon-list-col .icon-list ul li span a:hover {
    color: var(--primary);
}

/* Education section */
#education {
    background: var(--light-gray);
}

#education .edu-row {
    display: flex;
    justify-content: space-between;
    gap: 50px;
    margin-top: 50px;
}

#education .edu-row .edu-cols {
    flex-basis: 48%;
}

#education .edu-row .edu-cols h2 {
    color: var(--text);
    font-weight: 600;
    font-size: 24px;
    margin-bottom: 30px;
    position: relative;
    display: inline-block;
}

#education .edu-row .edu-cols h2::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -10px;
    width: 40px;
    height: 3px;
    background-color: var(--primary);
    border-radius: 2px;
}

#education .edu-row .edu-cols .my-info,
#education .edu-row .edu-cols .my-edu,
#education .edu-row .edu-cols .pro-exp {
    padding: 0 20px 0 30px;
    margin: 30px 0;
    border-left: 2px solid var(--primary);
    position: relative;
}

#education .edu-row .edu-cols .my-info::before,
#education .edu-row .edu-cols .my-edu::before,
#education .edu-row .edu-cols .pro-exp::before {
    content: '';
    position: absolute;
    top: 0px;
    left: -11px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    background-color: var(--light);
}

#education .edu-row .edu-cols h3 {
    color: var(--text);
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 15px;
}

#education .edu-row .edu-cols .my-info p,
#education .edu-row .edu-cols .my-edu p,
#education .edu-row .edu-cols .pro-exp p {
    color: var(--text-light);
    font-size: 16px;
    margin-bottom: 10px;
    line-height: 1.6;
}

#education .edu-row .edu-cols .my-info ul li,
#education .edu-row .edu-cols .pro-exp ul li {
    margin: 10px 0;
    color: var(--text-light);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.6;
}

#education .edu-row .edu-cols .sp-box {
    padding: 5px 15px;
    background-color: var(--accent);
    color: var(--light);
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    margin: 15px 0;
    display: inline-block;
}

/* Skills section */
#Skills {
    background: var(--light);
}

#Skills .Skills-row {
    margin-top: 50px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-gap: 30px;
}

#Skills .Skills-box {
    display: flex;
    gap: 20px;
    background-color: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

#Skills .Skills-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-bottom: 3px solid var(--primary);
}

#Skills .Skills-box .icon i {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    text-align: center;
    line-height: 50px;
    font-size: 22px;
    color: var(--light);
    transition: 0.3s;
    background-color: var(--primary);
}

#Skills .Skills-box .icon .pal {
    background-color: var(--primary);
}

#Skills .Skills-box .icon .js {
    background-color: var(--secondary);
}

#Skills .Skills-box .icon .and {
    background-color: var(--accent);
}

#Skills .Skills-box .icon .node {
    background-color: var(--secondary);
}

#Skills .Skills-box .icon .rct {
    background-color: var(--accent);
}

#Skills .Skills-box .icon .jav {
    background-color: var(--primary);
}

#Skills .Skills-box .icon .lcode {
    background-color: var(--secondary);
}

#Skills .Skills-box .icon .code {
    background-color: var(--accent);
}

#Skills .Skills-box .ser-info h4 {
    color: var(--text);
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}

#Skills .Skills-box .ser-info p {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.6;
}

/* Portfolio section */
#portfolio {
    background: var(--light-gray);
}

#portfolio .port-row {
    margin-top: 50px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-gap: 30px;
}

#portfolio .port-row .port-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

#portfolio .port-row .port-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

#portfolio .port-row .port-item .port-img img {
    width: 100%;
    height: 240px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

#portfolio .port-row .port-item:hover .port-img img {
    transform: scale(1.1);
}

#portfolio .port-row .port-item .port-info {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 90, 142, 0.9);
    padding: 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 15px;
    transform: scale(0);
    transition: 0.4s;
    border-radius: 10px;
    visibility: hidden;
}

#portfolio .port-row .port-item:hover .port-info {
    transform: scale(1);
    visibility: visible;
}

#portfolio .port-row .port-item .port-info h4 {
    color: var(--light);
    font-size: 24px;
    font-weight: 600;
}

#portfolio .port-row .port-item .port-info h4 + p {
    color: var(--light);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.6;
}

#portfolio .port-row .port-item .port-info a {
    text-decoration: none;
    display: inline-block;
    font-size: 20px;
    width: 45px;
    height: 45px;
    background-color: var(--light);
    border-radius: 50%;
    color: var(--primary);
    line-height: 46px;
    transition: 0.3s;
    margin-top: 10px;
}

#portfolio .port-row .port-item .port-info a:hover {
    background-color: var(--secondary);
    color: var(--light);
    transform: translateY(-5px);
}

/* Services section */
#services {
    background: var(--light);
}

#services .service-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin-top: 50px;
    grid-gap: 30px;
}

#services .service-row .service-box {
    background-color: white;
    color: var(--text);
    padding: 50px 30px 30px;
    text-align: center;
    border-radius: 10px;
    position: relative;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

#services .service-row .service-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

#services .service-row .service-box .icon {
    width: 70px;
    height: 70px;
    background-color: var(--primary);
    color: var(--light);
    font-size: 30px;
    border-radius: 50%;
    position: absolute;
    top: -35px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(255, 90, 142, 0.4);
}

#services .service-row .service-box:hover .icon {
    background-color: var(--secondary);
}

#services .service-row .service-box .ser-info h4 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 15px;
    margin-top: 20px;
    color: var(--text);
}

#services .service-row .service-box .ser-info p {
    color: var(--text-light);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.6;
}

/* Contact section */
#contact {
    background: var(--light-gray);
}

#contact .contact-row {
    margin-top: 50px;
    display: flex;
    gap: 30px;
    width: 100%;
}

#contact .contact-row .contact-left {
    flex-basis: 40%;
    min-width: 40%;
    background-color: white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border-radius: 10px;
    padding: 30px;
}

#contact .contact-row .contact-left .icon-box {
    display: flex;
    gap: 20px;
    align-items: center;
    margin: 30px 0;
}

#contact .contact-row .contact-left .icon-box .icon i {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary);
    text-align: center;
    line-height: 50px;
    font-size: 20px;
    color: var(--light);
    transition: 0.3s;
}

#contact .contact-row .contact-left .icon-box:hover .icon i {
    background-color: var(--secondary);
    transform: scale(1.1);
}

#contact .contact-row .contact-left .icon-box .info h4 {
    font-size: 18px;
    color: var(--text);
    font-weight: 600;
    margin-bottom: 5px;
}

#contact .contact-row .contact-left .icon-box .info p {
    font-size: 16px;
    color: var(--text-light);
    font-weight: 400;
}

#contact .contact-row .contact-left .map {
    margin-top: 30px;
    border-radius: 10px;
    overflow: hidden;
}

#contact .contact-row .contact-right {
    flex-basis: 60%;
    min-width: 60%;
    background-color: white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border-radius: 10px;
    padding: 40px;
}

#contact .contact-row .contact-right form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

#contact .contact-row .contact-right form input,
#contact .contact-row .contact-right form textarea {
    width: 100%;
    padding: 15px;
    font-size: 15px;
    color: var(--text);
    border: 1px solid var(--gray);
    border-radius: 5px;
    outline: none;
    resize: none;
    transition: 0.3s;
}

#contact .contact-row .contact-right form input:focus,
#contact .contact-row .contact-right form textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255, 90, 142, 0.2);
}

#contact .contact-row .contact-right form input[type=submit] {
    background-color: var(--primary);
    color: var(--light);
    border: none;
    font-size: 16px;
    font-weight: 600;
    padding: 15px 30px;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: auto;
    align-self: flex-start;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 15px rgba(255, 90, 142, 0.4);
}

#contact .contact-row .contact-right form input[type=submit]:hover {
    background-color: var(--secondary);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(13, 27, 64, 0.3);
}

/* Facts section */
#fact {
    background: var(--light);
}

#fact .fact-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-gap: 30px;
    margin-top: 50px;
}

#fact .fact-row .fact-box {
    background-color: white;
    padding: 40px 30px;
    text-align: center;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

#fact .fact-row .fact-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

#fact .fact-row .fact-box i {
    color: var(--primary);
    font-size: 40px;
    margin-bottom: 20px;
}

#fact .fact-row .fact-box strong {
    color: var(--secondary);
    font-size: 36px;
    display: block;
    margin-bottom: 10px;
    font-weight: 700;
}

#fact .fact-row .fact-box p {
    color: var(--text-light);
    font-weight: 400;
    font-size: 16px;
}

/* Responsive designs */
@media only screen and (max-width: 1200px) {
    #Skills .Skills-row,
    #services .service-row,
    #portfolio .port-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media only screen and (max-width: 992px) {
    .sub-heading {
        font-size: 30px;
    }
    
    #home .home-row h1 {
        font-size: 48px;
    }
    
    #home .home-row p {
        font-size: 24px;
    }
    
    #about .about-col,
    #education .edu-row,
    #contact .contact-row {
        flex-direction: column;
    }
    
    #fact .fact-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media only screen and (max-width: 768px) {
    section {
        padding: 70px 20px;
    }
    
    #Skills .Skills-row,
    #services .service-row,
    #portfolio .port-row {
        grid-template-columns: 1fr;
    }
    
    #home .home-row {
        padding-left: 20px;
    }
    
    #home .home-row h1 {
        font-size: 36px;
    }
    
    #home .home-row p {
        font-size: 20px;
    }
    
    .btn {
        padding: 12px 25px;
        font-size: 12px;
    }
}

@media only screen and (max-width: 480px) {
    #fact .fact-row {
        grid-template-columns: 1fr;
    }
    
    #about .about-col .info-col .icon-list-col {
        flex-direction: column;
        gap: 5px;
    }
}

/* Animation classes */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.appear {
    opacity: 1;
    transform: translateY(0);
}

/* Animation delay for staggered effect */
.Skills-box:nth-child(2n),
.service-box:nth-child(2n),
.port-item:nth-child(2n),
.fact-box:nth-child(2n) {
    transition-delay: 0.2s;
}

.Skills-box:nth-child(3n),
.service-box:nth-child(3n),
.port-item:nth-child(3n),
.fact-box:nth-child(3n) {
    transition-delay: 0.4s;
}

/* Back to top button */
.back-to-top {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background-color: var(--primary);
    color: var(--light);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    text-decoration: none;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 99;
    box-shadow: 0 5px 15px rgba(255, 90, 142, 0.4);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--secondary);
    transform: translateY(-5px);
}

/* Notification styles for contact form */
#result .notification {
    padding: 12px 15px;
    margin-top: 15px;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 500;
}

#result .notification.success {
    background-color: rgba(39, 174, 96, 0.2);
    color: #27ae60;
    border-left: 4px solid #27ae60;
}

#result .notification.error {
    background-color: rgba(231, 76, 60, 0.2);
    color: #e74c3c;
    border-left: 4px solid #e74c3c;
}

#result .notification.info {
    background-color: rgba(52, 152, 219, 0.2);
    color: #3498db;
    border-left: 4px solid #3498db;
}

/* Loading animation for form submission */
#result .loading {
    display: inline-block;
    font-size: 14px;
    color: var(--text-light);
    position: relative;
    padding-left: 25px;
}

#result .loading::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    border: 2px solid var(--primary);
    border-right-color: transparent;
    border-radius: 50%;
    animation: rotate 1s linear infinite;
}

@keyframes rotate {
    0% { transform: translateY(-50%) rotate(0deg); }
    100% { transform: translateY(-50%) rotate(360deg); }
}

/* Hover effects for skills boxes */
#Skills .Skills-box:hover .icon i {
    transform: scale(1.2);
}

/* Extra animations for home section */
#home .home-row h1 {
    animation: fadeInDown 1s ease-out;
}

#home .home-row p {
    animation: fadeInUp 1s ease-out 0.5s;
    animation-fill-mode: both;
}

#home .home-row .btn {
    animation: fadeInUp 1s ease-out 1s;
    animation-fill-mode: both;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Portfolio hover effect enhancement */
#portfolio .port-row .port-item:hover .port-info {
    animation: fadeInScale 0.4s ease;
}

@keyframes fadeInScale {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}