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

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

:root {
    --primary-color: #0ef;
    --bg-color: #1f242d;
    --secondary-bg: #2d333f;
    --text-color: #fff;
    --hover-color: #0ef;
    --gradient-primary: linear-gradient(45deg, #0ef, #2cb9ff);
    --gradient-secondary: linear-gradient(45deg, #ff2c8f, #ff9a2c);
    --shadow-color: rgba(14, 255, 255, 0.3);
}

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

/* Loader */
.loader-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loader-content {
    text-align: center;
}

.loader {
    width: 60px;
    height: 60px;
    border: 4px solid transparent;
    border-top-color: var(--primary-color);
    border-radius: 50%;
    margin: 0 auto 20px;
    animation: spin 1s cubic-bezier(0.17, 0.67, 0.83, 0.67) infinite;
}

.loader-content h2 {
    color: var(--primary-color);
    font-size: 1.5rem;
    letter-spacing: 2px;
}

.loader-wrapper.fade-out {
    opacity: 0;
    visibility: hidden;
}

.dots {
    animation: dots 1.5s infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60% { content: '...'; }
    80%, 100% { content: ''; }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Enhance particle display */
#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: -1;
    background-color: var(--bg-color);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 0.8rem 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header.sticky {
    background: rgba(31, 36, 45, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(14, 255, 255, 0.1);
}

.logo {
    font-size: 2rem;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 700;
    position: relative;
    z-index: 1;
}

.logo span {
    color: var(--primary-color);
    position: relative;
}

.logo span::before {
    content: '';
    position: absolute;
    width: 15px;
    height: 15px;
    background: var(--primary-color);
    filter: blur(10px);
    border-radius: 50%;
    z-index: -1;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.8); opacity: 0.7; }
    50% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(0.8); opacity: 0.7; }
}

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

.nav-link {
    position: relative;
    color: var(--text-color);
    text-decoration: none;
    margin-left: 2.5rem;
    padding: 0.5rem 0;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-link i {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.nav-link:hover i {
    transform: translateY(-3px);
    color: var(--primary-color);
}

.nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.nav-link:hover::before,
.nav-link.active::before {
    width: 100%;
}

.nav-link.active {
    color: var(--primary-color);
}

.navbar-toggler {
    border: none;
    background: transparent;
    color: var(--text-color);
    font-size: 2rem;
    cursor: pointer;
    transition: color 0.3s;
}

.navbar-toggler:focus {
    box-shadow: none;
}

.navbar-toggler:hover {
    color: var(--primary-color);
}

/* Enhanced Home Section */
.home {
    position: relative;
    min-height: 100vh;
    padding: 180px 0 100px;
    overflow: hidden;
}

.home::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(14, 255, 255, 0.03), transparent 70%);
    pointer-events: none;
}

.home-content .subtitle {
    color: #aaa;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
    animation: slideRight 1s ease forwards;
}

.glitch-text {
    font-size: 4rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-color);
    position: relative;
    animation: glitch 5s infinite, slideRight 1s ease forwards;
}

.glitch-text::before,
.glitch-text::after {
    content: 'Krish Waghresha';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.8;
}

.glitch-text::before {
    color: var(--primary-color);
    animation: glitch-offset 3s infinite linear;
    clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
}

.glitch-text::after {
    color: #ff6bcb;
    animation: glitch-offset 2s infinite linear reverse;
    clip-path: polygon(0 55%, 100% 55%, 100% 100%, 0 100%);
}

.text-animate {
    margin: 1.5rem 0;
    animation: slideTop 1s ease forwards;
    animation-delay: 0.3s;
    opacity: 0;
}

.text-animate h3 {
    font-size: 2rem;
    font-weight: 700;
    display: inline-flex;
}

.text-animate h3 span {
    margin-left: 8px;
    color: var(--primary-color);
    position: relative;
}

.text-animate h3 span::after {
    content: '|';
    position: absolute;
    right: -5px;
    color: var(--text-color);
    animation: blink 0.7s infinite;
}

.summary {
    font-size: 1rem;
    line-height: 1.8;
    margin: 1.5rem 0;
    padding: 1.5rem;
    border-radius: 15px;
    opacity: 0;
    animation: slideLeft 1s ease forwards;
    animation-delay: 0.7s;
}

.contact-info {
    margin: 1.5rem 0;
}

.contact-info p {
    display: flex;
    align-items: center;
    margin-bottom: 0.8rem;
}

.contact-info i {
    color: var(--primary-color);
    margin-right: 10px;
    font-size: 1.2rem;
}

/* Contact info in footer */
.contact-info-footer {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2rem;
    margin: 1.5rem 0;
}

.contact-info-footer p {
    display: flex;
    align-items: center;
    margin-bottom: 0;
}

.contact-info-footer i {
    color: var(--primary-color);
    margin-right: 10px;
    font-size: 1.2rem;
}

/* Center footer elements */
.footer-info {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.social-media-footer {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 1.5rem 0;
}

@media (max-width: 768px) {
    .contact-info-footer {
        flex-direction: column;
        gap: 0.5rem;
    }
}

.social-media {
    margin: 2rem 0;
    opacity: 0;
    animation: slideLeft 1s ease forwards;
    animation-delay: 1.1s;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    margin-top: 2rem;
    opacity: 0;
    animation: slideTop 1s ease forwards;
    animation-delay: 1.3s;
}

.btn {
    display: inline-block;
    padding: 0.8rem 2.5rem;
    border-radius: 40px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.primary-btn {
    background: var(--gradient-primary);
    color: var(--bg-color);
    box-shadow: 0 5px 15px rgba(14, 255, 255, 0.3);
}

.primary-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(14, 255, 255, 0.4);
    color: var(--bg-color);
}

.secondary-btn {
    background: transparent;
    color: var(--text-color);
    border: 2px solid var(--primary-color);
}

.secondary-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: var(--gradient-primary);
    transition: 0.5s;
    z-index: -1;
}

.secondary-btn:hover {
    color: var(--bg-color);
    box-shadow: 0 10px 20px rgba(14, 255, 255, 0.4);
}

.secondary-btn:hover::before {
    width: 100%;
}

.img-box {
    position: relative;
    width: 400px;
    height: 400px;
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.img-box img {
    width: 90%;
    height: 90%;
    object-fit: cover;
    object-position: center top;
    border-radius: 50%;
    z-index: 2;
    border: 4px solid var(--primary-color);
    padding: 5px;
    background-color: rgba(31, 36, 45, 0.3);
    animation: floatImage 4s ease-in-out infinite, glowingBorder 2s infinite;
}

.img-bg {
    position: absolute;
    width: 80%;
    height: 80%;
    background: var(--gradient-primary);
    border-radius: 50%;
    z-index: 0;
    filter: blur(30px);
    opacity: 0.5;
    animation: pulse 3s infinite alternate;
}

.box-animate {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    z-index: 1;
}

.box-animate div {
    position: absolute;
    display: block;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    animation: animate 10s linear infinite;
}

.box-animate div:nth-child(1) {
    left: 0;
    top: 0;
    animation-delay: 0s;
}

.box-animate div:nth-child(2) {
    left: 50%;
    top: 0;
    animation-delay: 1s;
}

.box-animate div:nth-child(3) {
    right: 0;
    top: 0;
    animation-delay: 2s;
}

.box-animate div:nth-child(4) {
    left: 0;
    top: 50%;
    animation-delay: 3s;
}

.box-animate div:nth-child(5) {
    right: 0;
    top: 50%;
    animation-delay: 4s;
}

.box-animate div:nth-child(6) {
    left: 0;
    bottom: 0;
    animation-delay: 5s;
}

.box-animate div:nth-child(7) {
    left: 50%;
    bottom: 0;
    animation-delay: 6s;
}

.box-animate div:nth-child(8) {
    right: 0;
    bottom: 0;
    animation-delay: 7s;
}

@keyframes animate {
    0% {
        transform: scale(0) translateY(0) rotate(0);
        opacity: 1;
    }
    100% {
        transform: scale(1) translateY(-150px) rotate(360deg);
        opacity: 0;
    }
}

@keyframes glitch {
    0%, 100% { transform: translate(0); }
    10% { transform: translate(-2px, -2px); }
    20% { transform: translate(2px, 2px); }
    30% { transform: translate(-2px, 2px); }
    40% { transform: translate(2px, -2px); }
}

@keyframes glitch-offset {
    0%, 100% { transform: translate(0); }
    10% { transform: translate(-2px, 2px); }
    20% { transform: translate(2px, -2px); }
    30% { transform: translate(-2px, -2px); }
    40% { transform: translate(2px, 2px); }
}

@keyframes slideRight {
    0% {
        transform: translateX(-100px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideLeft {
    0% {
        transform: translateX(100px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideTop {
    0% {
        transform: translateY(100px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.pulse {
    animation: iconPulse 2s infinite;
}

@keyframes iconPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

/* Timeline Section */
.timeline {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 0;
    overflow: hidden;
}

/* Main timeline line */
.timeline::before {
    content: '';
    position: absolute;
    width: 2px;
    height: 100%;
    background: linear-gradient(
        to bottom,
        transparent,
        var(--primary-color),
        var(--primary-color),
        transparent
    );
    left: 50%;
    transform: translateX(-50%);
    top: 0;
}

/* Timeline items */
.timeline-item {
    width: calc(50% - 40px);
    margin-bottom: 60px;
    position: relative;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 2rem;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(14, 255, 255, 0.1);
    transition: all 0.3s ease;
    clear: both;
}

/* Left side items */
.timeline-item:nth-child(odd) {
    float: left;
    clear: right;
}

/* Right side items */
.timeline-item:nth-child(even) {
    float: right;
    clear: left;
}

/* Timeline dots */
.timeline-item::before {
    content: '';
    position: absolute;
    height: 20px;
    width: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    box-shadow: 0 0 10px var(--primary-color);
    z-index: 1;
}

.timeline-item:nth-child(odd)::before {
    right: -50px;
}

.timeline-item:nth-child(even)::before {
    left: -50px;
}

/* Connecting lines */
.timeline-item::after {
    content: '';
    position: absolute;
    width: 30px;
    height: 2px;
    background: var(--primary-color);
    top: 50%;
    z-index: 0;
}

.timeline-item:nth-child(odd)::after {
    right: -30px;
}

.timeline-item:nth-child(even)::after {
    left: -30px;
}

/* Timeline content styling */
.timeline-content {
    position: relative;
    z-index: 1;
}

.timeline-content h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.timeline-content h4 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: #fff;
}

.timeline-content .date {
    font-size: 0.9rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    display: inline-block;
    padding: 5px 15px;
    background: rgba(14, 255, 255, 0.1);
    border-radius: 15px;
}

/* Enhanced hover effects */
.timeline-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 25px rgba(14, 255, 255, 0.2);
}

.timeline-item:hover::before {
    animation: pulseGlow 1.5s infinite;
}

@keyframes pulseGlow {
    0% { box-shadow: 0 0 10px var(--primary-color); }
    50% { box-shadow: 0 0 20px var(--primary-color), 0 0 30px var(--primary-color); }
    100% { box-shadow: 0 0 10px var(--primary-color); }
}

/* Responsive design */
@media screen and (max-width: 768px) {
    .timeline::before {
        left: 30px;
    }

    .timeline-item {
        width: calc(100% - 70px);
        float: right;
        clear: both;
        margin-left: 70px;
    }

    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        float: right;
        clear: both;
    }

    .timeline-item:nth-child(odd)::before,
    .timeline-item:nth-child(even)::before {
        left: -45px;
    }

    .timeline-item:nth-child(odd)::after,
    .timeline-item:nth-child(even)::after {
        left: -30px;
    }
}

/* Timeline animations */
.timeline-item {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.5s ease;
}

.timeline-item.animate {
    opacity: 1;
    transform: translateY(0);
}

.timeline-item:nth-child(odd) {
    animation: slideInLeft 0.5s ease forwards;
}

.timeline-item:nth-child(even) {
    animation: slideInRight 0.5s ease forwards;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Projects Section */
.project-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 2rem;
    transition: 0.3s;
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent,
        rgba(14, 255, 255, 0.1),
        transparent
    );
    transform: rotate(45deg);
    transition: 0.6s;
}

.project-card:hover::before {
    animation: shine 1.5s;
}

@keyframes shine {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 0 30px rgba(14, 255, 255, 0.3);
}

.project-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.project-info {
    padding: 1.5rem;
}

.tech-stack span {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: rgba(14, 255, 255, 0.1);
    border-radius: 20px;
    margin: 0.3rem;
    font-size: 0.9rem;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skill-category {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 2rem;
    transition: 0.3s;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(14, 255, 255, 0.1);
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 20px rgba(14, 255, 255, 0.2);
}

.skill-item {
    display: flex;
    align-items: center;
    margin: 1rem 0;
}

.skill-item img {
    width: 30px;
    margin-right: 1rem;
    transition: transform 0.3s ease;
    filter: grayscale(100%);
}

.skill-item:hover img {
    transform: scale(1.2) rotate(10deg);
    filter: grayscale(0%);
}

/* Education Section */
.education-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.education-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(5px);
    border-radius: 15px;
    padding: 2rem;
    border: 1px solid rgba(14, 255, 255, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.education-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary-color);
    transform: scaleY(0);
    transition: transform 0.3s ease;
    transform-origin: top;
}

.education-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 25px rgba(14, 255, 255, 0.2);
}

.education-card:hover::before {
    transform: scaleY(1);
}

.education-content h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.education-content .institution {
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 0.5rem;
}

.education-content .year {
    font-size: 0.9rem;
    color: #aaa;
    margin-bottom: 1rem;
}

.education-content .grade {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(14, 255, 255, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    width: fit-content;
}

.grade-label {
    color: #fff;
    font-size: 0.9rem;
}

.grade-value {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.1rem;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    .education-grid {
        grid-template-columns: 1fr;
        padding: 1rem 0;
    }

    .education-card {
        padding: 1.5rem;
    }
}

/* Animation for cards */
.education-card {
    animation: fadeInUp 0.5s ease forwards;
    opacity: 0;
    transform: translateY(20px);
}

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

/* Animations */
@keyframes floatImage {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-24px);
    }
    100% {
        transform: translateY(0);
    }
}

@keyframes glowingBorder {
    0% { box-shadow: 0 0 5px var(--primary-color); }
    50% { box-shadow: 0 0 20px var(--primary-color), 0 0 30px var(--primary-color); }
    100% { box-shadow: 0 0 5px var(--primary-color); }
}

@keyframes gradientBg {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes gradientText {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Mobile Responsiveness Improvements */
@media (max-width: 991px) {
    .header {
        padding: 0.8rem 4%;
    }

    section {
        padding: 7rem 4% 2rem;
    }

    .home {
        padding: 150px 4% 100px;
    }
}

@media (max-width: 768px) {
    .home {
        padding-top: 130px;
    }

    .home-content {
        text-align: center;
        margin-bottom: 3rem;
    }

    .home-content h1 {
        font-size: 2.8rem;
    }

    .text-animate h3 {
        font-size: 1.5rem;
    }

    .contact-info {
        justify-content: center;
    }

    .social-media {
        justify-content: center;
    }

    .cta-buttons {
        justify-content: center;
    }

    .img-box {
        width: 280px;
        height: 280px;
    }

    .home-img img {
        border-width: 3px;
    }

    .project-card {
        margin-bottom: 2rem;
    }

    .section-title {
        font-size: 2.5rem;
        margin-bottom: 2rem;
    }

    .skill-category {
        margin-bottom: 1.5rem;
    }

    .education-card {
        padding: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .projects .row {
        margin-bottom: 0;
    }

    .navbar-nav {
        background: rgba(31, 36, 45, 0.95);
        padding: 1rem;
    }

    .nav-link {
        margin: 0.8rem 0;
        padding: 0.5rem 1rem;
        border-radius: 5px;
    }

    .nav-link:hover {
        background: rgba(14, 255, 255, 0.1);
    }

    .footer-content {
        padding: 2rem 0;
    }
}

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

    .text-animate h3 {
        font-size: 1.3rem;
    }

    .home-content .subtitle {
        font-size: 1rem;
    }

    .img-box {
        width: 240px;
        height: 240px;
    }

    .cta-buttons {
        flex-direction: column;
        gap: 1rem;
    }

    .cta-buttons .btn {
        width: 100%;
        text-align: center;
    }

    .section-title {
        font-size: 2rem;
    }

    .timeline-item {
        padding: 1.5rem;
    }

    .education-content h3 {
        font-size: 1.3rem;
    }

    .footer-info p {
        font-size: 0.9rem;
    }

    .social-media-footer {
        gap: 0.8rem;
    }

    .social-media-footer a {
        width: 35px;
        height: 35px;
    }
}

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

    .text-animate h3 {
        font-size: 1.1rem;
    }

    .summary {
        font-size: 0.9rem;
        padding: 1rem;
    }

    .img-box {
        width: 200px;
        height: 200px;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .tech-stack span {
        font-size: 0.8rem;
        padding: 0.2rem 0.6rem;
        margin: 0.2rem;
    }

    .education-content h3 {
        font-size: 1.2rem;
    }

    .project-card img {
        height: 180px;
    }

    .footer-logo {
        font-size: 1.8rem;
    }

    .contact-info-footer {
        gap: 1rem;
    }

    .contact-info-footer p {
        font-size: 0.9rem;
    }
}

/* Cursor Effect */
.custom-cursor {
    width: 20px;
    height: 20px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.1s;
}

/* New Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, var(--primary-color), #fff);
    transform-origin: 0%;
    z-index: 1000;
}

/* New Loading Animation */
.loader {
    position: fixed;
    inset: 0;
    background: var(--bg-color);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

.loader::after {
    content: '';
    width: 50px;
    height: 50px;
    border: 3px solid #fff;
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: loading 0.75s ease infinite;
}

@keyframes loading {
    from { transform: rotate(0turn) }
    to { transform: rotate(1turn) }
}

/* New hover effects for social media icons */
.social-media a {
    position: relative;
    overflow: hidden;
}

.social-media a::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    z-index: -1;
}

.social-media a:hover::before {
    transform: translateY(0);
}

.social-media a:hover i {
    color: var(--bg-color);
    background: var(--primary-color);

}

/* Timeline fixes */
.timeline {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 0;
    overflow: hidden;
}

/* Add clearfix */
.clearfix {
    clear: both;
    height: 0;
    visibility: hidden;
}

/* Adjust section spacing */
section {
    min-height: auto;
    padding: 100px 9% 2rem;
    overflow: hidden;
}

.experience {
    margin-bottom: 4rem;
}

/* Timeline items */
.timeline-item {
    width: calc(50% - 40px);
    margin-bottom: 60px;
    position: relative;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 2rem;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(14, 255, 255, 0.1);
    transition: all 0.3s ease;
}

/* Projects section adjustment */
.projects {
    padding-top: 4rem;
    clear: both;
}
.projects img{
    padding: 1rem;
}
/* Responsive adjustments */
@media screen and (max-width: 768px) {
    .timeline-item {
        width: calc(100% - 70px);
        margin-left: 70px;
    }
    
    section {
        padding: 80px 4% 2rem;
    }
}

/* Navbar collapse fix for mobile */
.navbar-collapse {
    background: rgba(31, 36, 45, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem;
    border-radius: 0 0 10px 10px;
}

@media screen and (max-width: 991px) {
    .navbar-collapse {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        border-top: 1px solid rgba(14, 255, 255, 0.1);
    }
}

/* Advanced Animations and Effects */

/* Glowing cursor trail */
.cursor-trail {
    width: 20px;
    height: 20px;
    background: rgba(14, 255, 255, 0.3);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: 0.1s ease;
}

/* Advanced card hover effects */
.card-hover-effect {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.card-hover-effect::before,
.card-hover-effect::after {
    content: '';
    position: absolute;
    inset: -100%;
    background: linear-gradient(45deg, 
        transparent 25%, 
        rgba(14, 255, 255, 0.1) 50%, 
        transparent 75%
    );
    transition: 0.5s ease;
    animation: borderGlow 2s linear infinite;
}

/* Advanced text animations */
.animated-text {
    background: linear-gradient(
        45deg,
        var(--primary-color),
        #fff,
        var(--primary-color)
    );
    background-size: 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientFlow 5s linear infinite;
}

/* 3D Card Tilt Effect */
.tilt-card {
    transform-style: preserve-3d;
    transform: perspective(1000px);
}

.tilt-card-content {
    transform: translateZ(20px);
}

/* Advanced button hover effects */
.hover-btn {
    position: relative;
    overflow: hidden;
    background: transparent;
    border: 2px solid var(--primary-color);
    padding: 10px 30px;
    border-radius: 30px;
    transition: 0.5s;
}

.hover-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: var(--primary-color);
    z-index: -1;
    transition: 0.5s;
}

.hover-btn:hover::before {
    width: 100%;
}

/* Floating animation with shadow */
@keyframes floatWithShadow {
    0% {
        transform: translateY(0);
        box-shadow: 0 5px 15px rgba(14, 255, 255, 0.2);
    }
    50% {
        transform: translateY(-20px);
        box-shadow: 0 25px 15px rgba(14, 255, 255, 0.1);
    }
    100% {
        transform: translateY(0);
        box-shadow: 0 5px 15px rgba(14, 255, 255, 0.2);
    }
}

/* Advanced skill progress bars */
.skill-progress {
    position: relative;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.skill-progress::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: var(--progress);
    background: linear-gradient(90deg, var(--primary-color), #fff);
    animation: progressGlow 2s ease-in-out infinite;
}

/* Parallax scrolling effect */
.parallax {
    transform: translateZ(var(--parallax-depth)) scale(calc(1 + var(--parallax-depth) * -1));
    transition: transform 0.2s ease-out;
}

/* Advanced animations */
@keyframes progressGlow {
    0%, 100% { box-shadow: 0 0 10px var(--primary-color); }
    50% { box-shadow: 0 0 20px var(--primary-color); }
}

@keyframes borderGlow {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes gradientFlow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Glass morphism cards with advanced effects */
.glass-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}

.glass-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(
        circle at var(--x, 50%) var(--y, 50%),
        rgba(255, 255, 255, 0.1) 0%,
        transparent 50%
    );
    opacity: 0;
    transition: opacity 0.3s;
}

.glass-card:hover::before {
    opacity: 1;
}

/* Advanced loading animation */
.loader {
    width: 50px;
    height: 50px;
    border: 3px solid transparent;
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loader::before,
.loader::after {
    content: '';
    position: absolute;
    border: 3px solid transparent;
    border-radius: 50%;
}

.loader::before {
    inset: 3px;
    border-top-color: rgba(14, 255, 255, 0.5);
    animation: spin 2s linear infinite;
}

.loader::after {
    inset: 8px;
    border-top-color: rgba(14, 255, 255, 0.3);
    animation: spin 3s linear infinite;
}

/* Footer Section */
.footer {
    background: linear-gradient(0deg, rgba(14, 21, 27, 0.95) 0%, var(--bg-color) 100%);
    padding: 4rem 0 1rem;
    position: relative;
    border-top: 1px solid rgba(14, 255, 255, 0.1);
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
}

.footer-logo {
    font-size: 2rem;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 700;
    display: inline-block;
    margin-bottom: 1rem;
}

.footer-logo span {
    color: var(--primary-color);
}

.footer-info p {
    margin-bottom: 1.5rem;
    max-width: 90%;
}

.social-media-footer {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.social-media-footer a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    transition: 0.3s;
    color: var(--text-color);
    text-decoration: none;
    border: 1px solid rgba(14, 255, 255, 0.2);
}

.social-media-footer a:hover {
    background: var(--primary-color);
    color: var(--bg-color);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(14, 255, 255, 0.3);
}

.contact-form h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(14, 255, 255, 0.2);
    border-radius: 8px;
    color: var(--text-color);
    transition: 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 10px rgba(14, 255, 255, 0.3);
    outline: none;
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.btn-submit {
    background: linear-gradient(45deg, var(--primary-color), rgba(14, 255, 255, 0.7));
    border: none;
    padding: 0.8rem 2rem;
    color: var(--bg-color);
    font-weight: 600;
    border-radius: 30px;
    cursor: pointer;
    transition: 0.3s;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: var(--bg-color);
    transition: 0.5s;
    z-index: -1;
    border-radius: 30px;
}

.btn-submit:hover {
    color: var(--primary-color);
    box-shadow: 0 0 20px rgba(14, 255, 255, 0.5);
}

.btn-submit:hover::before {
    width: 100%;
}

.footer-bottom {
    margin-top: 3rem;
    padding-top: 1.5rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Enhanced nav styling */
.navbar a {
    font-size: 1.1rem;
    color: var(--text-color);
    text-decoration: none;
    margin-left: 2.5rem;
    transition: 0.3s;
    position: relative;
    overflow: hidden;
    padding: 0.5rem 0;
}

.navbar a.active {
    color: var(--primary-color);
}

.navbar a.active::after {
    width: 100%;
}

/* Enhanced project cards */
.project-card {
    position: relative;
    border: 1px solid rgba(14, 255, 255, 0.1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transform-style: preserve-3d;
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.project-card:hover {
    transform: rotateY(5deg) rotateX(5deg) translateY(-10px);
    box-shadow: 0 15px 25px rgba(14, 255, 255, 0.2);
}

.project-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(14, 255, 255, 0.1), transparent);
    pointer-events: none;
    transition: 0.6s;
    opacity: 0;
}

.project-card:hover::after {
    opacity: 1;
}

.project-info h3 {
    position: relative;
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.project-info h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 50px;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s;
}

.project-card:hover .project-info h3::after {
    width: 100px;
}

.links a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    margin-top: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    transition: 0.3s;
    color: var(--text-color);
    text-decoration: none;
    border: 1px solid rgba(14, 255, 255, 0.2);
}

.links a:hover {
    background: var(--primary-color);
    color: var(--bg-color);
    transform: translateY(-5px);
}

/* Enhanced Social Media Icons in Home Section */
.social-media {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.social-media a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    color: var(--text-color);
    text-decoration: none;
    border: 1px solid rgba(14, 255, 255, 0.2);
    position: relative;
}

.social-media a::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--primary-color);
    opacity: 0;
    transform: scale(0);
    transition: 0.4s;
}

.social-media a:hover {
    transform: translateY(-10px);
    color: var(--bg-color);
    box-shadow: 0 10px 20px rgba(14, 255, 255, 0.3);
}

.social-media a:hover::before {
    opacity: 1;
    transform: scale(1);
}

.social-media a i {
    font-size: 1.5rem;
    position: relative;
    z-index: 1;
    transition: 0.3s;
}

@media (max-width: 768px) {
    .footer-content .row {
        flex-direction: column;
    }
    
    .contact-form {
        margin-top: 2rem;
    }
}

/* Scroll to top button */
.scroll-top-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: var(--bg-color);
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(14, 255, 255, 0.3);
}

.scroll-top-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top-btn:hover {
    background: #fff;
    color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(14, 255, 255, 0.4);
}

/* Form message styles */
.form-message {
    padding: 0.8rem;
    margin-top: 1rem;
    border-radius: 5px;
    font-size: 0.9rem;
    animation: fadeSlideUp 0.3s ease forwards;
}

.form-message.success {
    background: rgba(46, 204, 113, 0.2);
    border: 1px solid rgba(46, 204, 113, 0.5);
    color: #2ecc71;
}

.form-message.error {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.5);
    color: #e74c3c;
}

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

/* Enhanced section transitions */
section {
    position: relative;
    transition: transform 0.5s ease, opacity 0.5s ease;
}

section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
}

/* Glass morphism cards */
.glass-effect {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}

/* Enhanced timeline */
.timeline::before {
    background: linear-gradient(
        to bottom,
        transparent,
        var(--primary-color) 10%,
        var(--primary-color) 90%,
        transparent
    );
    box-shadow: 0 0 15px rgba(14, 255, 255, 0.3);
}

/* Enhanced home section */
.home-content h1 {
    position: relative;
    display: inline-block;
}

.home-content h1::after {
    content: '|';
    position: absolute;
    right: -10px;
    top: 0;
    color: var(--primary-color);
    animation: blink 0.7s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Enhanced contact info */
.contact-info {
    margin: 1.5rem 0;
}

.contact-info p {
    display: flex;
    align-items: center;
    margin-bottom: 0.8rem;
}

.contact-info i {
    color: var(--primary-color);
    margin-right: 10px;
    font-size: 1.2rem;
}

/* Fix profile image display */
.profile-image-fix {
    width: 90% !important;
    height: 90% !important;
    object-fit: cover !important;
    object-position: center top !important;
    border: 4px solid var(--primary-color) !important;
    padding: 5px !important;
    background-color: rgba(31, 36, 45, 0.3) !important;
}

/* Mobile Menu Close Button */
.navbar-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    color: var(--text-color);
    font-size: 1.8rem;
    cursor: pointer;
    transition: color 0.3s;
    display: none;
}

.navbar-close:hover,
.navbar-close:focus {
    color: var(--primary-color);
    outline: none;
}

.navbar-collapse.show .navbar-close {
    display: block;
}

/* Fix for mobile menu scrolling */
body.menu-open {
    overflow: hidden;
}

/* Improve touch targets for mobile */
.nav-link {
    min-height: 44px;
    display: flex;
    align-items: center;
}

/* Ensure project cards work on mobile */
@media (max-width: 991px) {
    .project-card {
        transform: none !important;
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }
    
    .project-card:active {
        transform: scale(0.98) !important;
    }
    
    .scroll-top-btn {
        width: 45px;
        height: 45px;
    }
}
}