* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0a0a0b;
    --bg-secondary: #1a1a1f;
    --bg-tertiary: #252530;
    --purple-primary: #8b5cf6;
    --purple-secondary: #a855f7;
    --purple-accent: #c084fc;
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
}

/* Main scrollbar for webkit browsers (Chrome, Safari, Edge) */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 10px;
    border: 1px solid var(--bg-tertiary);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    border-radius: 10px;
    border: 2px solid var(--bg-secondary);
    transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--purple-secondary), var(--purple-accent));
    border-color: var(--bg-primary);
    transform: scale(1.1);
}

::-webkit-scrollbar-thumb:active {
    background: var(--purple-accent);
}

::-webkit-scrollbar-corner {
    background: var(--bg-secondary);
}

.modal-screenshot {
    width: 100%;
    margin: 15px 0;
    text-align: center;
}

.modal-project-image {
    width: 100%;
    max-width: 850px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

/* Modal scrollbar - slightly smaller */
.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: 8px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    border-radius: 8px;
    border: 1px solid var(--bg-tertiary);
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--purple-secondary), var(--purple-accent));
    transform: scale(1.2);
}

/* Firefox scrollbar styling */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--purple-primary) var(--bg-secondary);
}

/* Carousel scrollbar - hidden but functional */
.carousel::-webkit-scrollbar {
    height: 4px;
}

.carousel::-webkit-scrollbar-track {
    background: transparent;
}

.carousel::-webkit-scrollbar-thumb {
    background: var(--purple-primary);
    border-radius: 4px;
    opacity: 0.5;
}

.carousel::-webkit-scrollbar-thumb:hover {
    opacity: 1;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Animated Background - Geometric Pattern */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: 
        linear-gradient(135deg, rgba(139, 92, 246, 0.03) 0%, transparent 50%),
        linear-gradient(-135deg, rgba(168, 85, 247, 0.03) 0%, transparent 50%);
}

.bg-animation::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 200%;
    height: 200%;
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(139, 92, 246, 0.1) 1px, transparent 1px),
        radial-gradient(circle at 75% 75%, rgba(168, 85, 247, 0.1) 1px, transparent 1px);
    background-size: 100px 100px, 150px 150px;
    animation: geometricMove 30s linear infinite;
}

.bg-animation::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(0deg, transparent 24%, rgba(139, 92, 246, 0.05) 25%, rgba(139, 92, 246, 0.05) 26%, transparent 27%, transparent 74%, rgba(139, 92, 246, 0.05) 75%, rgba(139, 92, 246, 0.05) 76%, transparent 77%),
        linear-gradient(90deg, transparent 24%, rgba(168, 85, 247, 0.05) 25%, rgba(168, 85, 247, 0.05) 26%, transparent 27%, transparent 74%, rgba(168, 85, 247, 0.05) 75%, rgba(168, 85, 247, 0.05) 76%, transparent 77%);
    background-size: 200px 200px;
    animation: gridMove 25s linear infinite reverse;
}

@keyframes geometricMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(-100px, -100px); }
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(200px, 200px); }
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(26, 26, 31, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.logo {
    height: 50px;
    width: 50px;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:hover {
    color: var(--purple-accent);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--purple-primary);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 2rem;
    position: relative;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--text-primary), var(--purple-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

.hero-content h1::after {
    content: '✨';
    position: absolute;
    right: -40px;
    top: 10px;
    animation: sparkle 3s ease-in-out infinite;
}

@keyframes sparkle {
    0%, 100% { transform: rotate(0deg) scale(1); opacity: 1; }
    50% { transform: rotate(180deg) scale(1.2); opacity: 0.8; }
}

.hero-content .tagline {
    font-size: 1.5rem;
    color: var(--purple-primary);
    margin-bottom: 1rem;
    font-weight: 300;
    position: relative;
}

.hero-content .tagline::before {
    content: '{ ';
    color: var(--purple-accent);
    font-weight: bold;
}

.hero-content .tagline::after {
    content: ' }';
    color: var(--purple-accent);
    font-weight: bold;
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2rem;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    color: white;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--purple-accent);
    border: 2px solid var(--purple-primary);
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.2);
}

.btn-secondary:hover {
    background: var(--purple-primary);
    color: white;
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.4);
}

/* Sections */
section {
    padding: 5rem 2rem;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    overflow-x: hidden;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text-primary);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--purple-primary);
}

/* About Section */
.about {
    background: var(--bg-secondary);
    padding: 5rem 2rem;
    max-width: 100%;
    margin: 0;
}

.about-content {
    display: flex;
    flex-direction: row;
    gap: 3rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.about-image {
    width: 900px;
    height: 100%;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 6rem;
    color: white;
    position: relative;
    animation: float-profile 6s ease-in-out infinite;
    box-shadow: 0 20px 40px rgba(139, 92, 246, 0.3);
    border: solid 8px rgba(47, 15, 121, 0.699);
    overflow: hidden;
}

.about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 50%;
}

.about-image img::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple-accent), var(--purple-primary));
    z-index: -1;
    opacity: 0.7;
    animation: pulse 4s ease-in-out infinite;
}

@keyframes float-profile {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.7; }
    50% { transform: scale(1.1); opacity: 0.9; }
}

.about-text strong {
    color: var(--purple-accent);
}

.about-text p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

/* Skills Section */
section#skills {
    padding-bottom: 0 !important;
}

.skills-container {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.skill-category {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid var(--bg-tertiary);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    flex: 1 1 300px;
    width: 100%;
}

.skill-category::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--purple-primary), var(--purple-accent));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.skill-category:hover::before {
    transform: scaleX(1);
}

.skill-category:hover {
    transform: translateY(-10px) rotate(1deg);
    box-shadow: 0 20px 40px rgba(139, 92, 246, 0.3);
    border-color: var(--purple-primary);
}

.skill-category h3 {
    color: var(--purple-accent);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
}

.skill-category h3 i {
    font-size: 1.5rem;
    animation: wiggle 2s ease-in-out infinite;
}

@keyframes wiggle {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(5deg); }
    75% { transform: rotate(-5deg); }
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.skill-tag {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: 25px;
    font-size: 0.9rem;
    border: 1px solid var(--purple-primary);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.skill-tag::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: var(--purple-primary);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.4s ease;
    z-index: -1;
}

.skill-tag:hover::before {
    width: 200px;
    height: 200px;
}

.skill-tag:hover {
    color: white;
    transform: scale(1.1) rotate(-2deg);
    border-color: var(--purple-accent);
}

/* Experience Section */
.experience {
    background: var(--bg-secondary);
    padding: 5rem 2rem;
    max-width: 100%;
    margin: 0;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background: var(--purple-primary);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background: var(--purple-primary);
    border: 4px solid var(--bg-primary);
    top: 15px;
    border-radius: 50%;
    z-index: 1;
}

.left {
    left: 0;
}

.right {
    left: 50%;
}

.left::after {
    right: -10px;
}

.right::after {
    left: -10px;
}

.timeline-content {
    padding: 20px 30px;
    background: var(--bg-tertiary);
    position: relative;
    border-radius: 12px;
    border: 1px solid var(--purple-primary);
}

.timeline-content h3 {
    color: var(--purple-accent);
    margin-bottom: 5px;
}

.timeline-content .company {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.timeline-content .duration {
    color: var(--purple-primary);
    font-size: 0.8rem;
    margin-bottom: 15px;
}

/* Projects Section */
.projects-container {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.project-card {
    background: var(--bg-secondary);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--bg-tertiary);
    transition: all 0.4s ease;
    position: relative;
    flex: 1 1 350px;
    max-width: 400px;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(168, 85, 247, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
    pointer-events: none;
}

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

.project-card:hover {
    transform: translateY(-15px) rotate(2deg);
    box-shadow: 0 25px 50px rgba(139, 92, 246, 0.4);
    border-color: var(--purple-accent);
}

.project-image {
    height: 200px;
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    position: relative;
    overflow: hidden;
}

.project-image::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shine 3s ease-in-out infinite;
}

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

.project-image i {
    z-index: 2;
    position: relative;
    animation: projectIcon 4s ease-in-out infinite;
}

@keyframes projectIcon {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.1) rotate(10deg); }
}

.project-content {
    padding: 1.5rem;
}

.project-content h3 {
    color: var(--purple-accent);
    margin-bottom: 0.5rem;
}

.project-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 1rem;
}

.tech-tag {
    background: var(--bg-tertiary);
    color: var(--purple-accent);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
}

/* FIXED: Additional CSS for Load More functionality */
.hidden-project {
    display: none;
}

.hidden-project.show {
    display: block;
    opacity: 1;
    height: auto;
    width: 100%;
    /* animation: fadeInUp 0.6s ease-out forwards; */
}

/* Make sure hover effects work on shown hidden projects */
.hidden-project.show:hover {
    transform: translateY(-15px) rotate(2deg) !important;
    box-shadow: 0 25px 50px rgba(139, 92, 246, 0.4) !important;
    border-color: var(--purple-accent) !important;
}

.hidden-project.show:hover::before {
    opacity: 1 !important;
}

.load-more-container {
    display: flex;
    justify-content: center;
    margin-top: 3rem;
}

.load-more-btn {
    padding: 15px 30px;
    font-size: 1.1rem;
    position: relative;
    overflow: hidden;
}

.load-more-btn.hidden {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    pointer-events: none;
}

.load-more-btn i {
    transition: transform 0.3s ease;
}

.load-more-btn:hover i {
    transform: rotate(180deg);
}

/* Loading animation for the button */
.load-more-btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.load-more-btn.loading i,
.load-more-btn.loading span {
    opacity: 0;
}

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

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

/* Recommendations Carousel */
.recommendations {
    background: var(--bg-secondary);
    padding: 5rem 2rem;
    max-width: 100% !important;
}

.carousel-container {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.carousel {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    gap: 2rem;
    padding: 1rem 0;
    scrollbar-width: none; /* Firefox */
}

.carousel::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.recommendation-card {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: space-between;
    min-width: 100%;
    scroll-snap-align: start;
    background: var(--bg-tertiary);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid var(--purple-primary);
    position: relative;
}

.recommendation-card::before {
    content: '"';
    position: absolute;
    top: 10px;
    left: 10px;
    font-size: 4rem;
    color: var(--purple-primary);
    opacity: 0.2;
    font-family: serif;
    line-height: 1;
}

.recommendation-content {
    margin-bottom: 1.5rem;
    font-style: italic;
    color: var(--text-secondary);
    position: relative;
    z-index: 1;
}

.recommender {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.recommender-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--purple-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
}

.recommender-info h4 {
    color: var(--text-primary);
    margin-bottom: 0.2rem;
}

.recommender-info p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.carousel-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.carousel-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 1px solid var(--purple-primary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-dot.active {
    background: var(--purple-primary);
    transform: scale(1.2);
}

/* Contact Section */
.contact {
    text-align: center;
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.contact-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 1.5rem;
    border-radius: 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--bg-tertiary);
    position: relative;
    overflow: hidden;
    flex: 1 1 150px;
    max-width: 200px;
    width: 120px;
}

.contact-link::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-accent));
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.4s ease;
    z-index: -1;
}

.contact-link:hover::before {
    width: 300px;
    height: 300px;
}

.contact-link:hover {
    color: white;
    transform: translateY(-10px) scale(1.05);
    border-color: var(--purple-accent);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.3);
}

.contact-link i {
    font-size: 2.5rem;
    color: var(--purple-primary);
    transition: all 0.3s ease;
    animation: contactFloat 3s ease-in-out infinite;
}

.contact-link:hover i {
    color: white;
    transform: scale(1.2) rotate(10deg);
}

.contact-info-1, .contact-info-2 {
    display: flex;
    gap: 2rem;
}

@keyframes contactFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

/* Footer */
footer {
    background: var(--bg-secondary);
    text-align: center;
    padding: 2rem;
    margin-top: 3rem;
    border-top: 1px solid var(--bg-tertiary);
}

/* Add this CSS to your existing styles */
.go-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.go-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.go-to-top:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.4);
}

.go-to-top:active {
    transform: translateY(-1px) scale(1.05);
}

.go-to-top i {
    animation: bounce-arrow 2s ease-in-out infinite;
}

@keyframes bounce-arrow {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-3px); }
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    animation: modalFadeIn 0.3s ease-out;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.modal-content {
    background: var(--bg-secondary);
    border-radius: 20px;
    border: 1px solid var(--purple-primary);
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: scale(0.7);
    opacity: 0;
    transition: all 0.3s ease-out;
}

.modal.show .modal-content {
    transform: scale(1);
    opacity: 1;
}

.modal-header {
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid var(--bg-tertiary);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.modal-title {
    color: var(--purple-accent);
    font-size: 1.8rem;
    margin: 0;
    flex: 1;
}

.modal-subtitle {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-style: italic;
    margin: 0.5rem 0 0 0;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 2rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    margin-left: 1rem;
}

.modal-close:hover {
    background: var(--purple-primary);
    color: white;
    transform: rotate(90deg);
}

.modal-body {
    padding: 1rem 2rem 2rem;
}

.modal-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}

.modal-image::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shine 3s ease-in-out infinite;
}

.modal-description {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1rem;
    line-height: 1.6;
}

.modal-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 1.5rem;
}

.modal-tech-tag {
    background: var(--bg-tertiary);
    color: var(--purple-accent);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    border: 1px solid var(--purple-primary);
}

.modal-features {
    margin-bottom: 1.5rem;
}

.modal-features h4 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-features ul {
    list-style: none;
    padding: 0;
}

.modal-features li {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
    font-size: 1rem;
}

.modal-features li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--purple-accent);
    font-weight: bold;
}

.modal-links {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.modal-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    font-size: 0.9rem;
}

.modal-btn-primary {
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-secondary));
    color: white;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

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

.modal-btn:hover {
    transform: translateY(-2px) scale(1.05);
}

/* Make project images clickable */
.project-image {
    cursor: pointer;
    transition: transform 0.3s ease;
}

.project-image:hover {
    transform: scale(1.05);
}

/* Add a subtle indicator that images are clickable */
.project-card::after {
    /* content: '🔍'; */
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(139, 92, 246, 0.9);
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s ease;
}

.project-card:hover::after {
    opacity: 1;
    transform: scale(1);
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* Loading animation */
.fade-in {
    animation: fadeInUp 0.6s ease-out;
}

.project-description {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    max-height: 3em;
    line-height: 1.5em;
    position: relative;
    white-space: normal;
}

.project-description::after {
    color: #a855f7; /* purple accent */
    font-weight: 500;
}
@media (max-width: 1024px) {
    .about-content {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    #about .section-title {
        margin-bottom: 3.5rem;
    }

    .about-image {
        width: 300px;
    }

    .projects-container {
        flex-direction: column;
        align-items: center;
    }
    
    .project-card {
        flex: 1 1 100%;
        max-width: 600px;
        width: 100%;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .projects-container {
        display: grid;
        grid-template-columns: 1fr;
        gap: 2rem;
        justify-items: center;
    }
    
    .project-card {
        width: 100%;
        max-width: 600px;
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .about, .experience, .recommendations {
        margin: 0 !important;
        padding: 3rem 2rem;
    }

    section {
        width: 100%;
        margin: 0;
        padding: 3rem 2rem;
    }

    .nav-links, #navbar {
        display: none;
    }

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

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

    .project-card {
        max-width: 100%;
    }
    
    .contact-link {
        flex: 1 1 100%;
        width: 90px;
    }

    .skill-category {
        flex: 1 1 100%;
    }

    .timeline::after {
        left: 31px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }

    .timeline-item::after {
        left: 21px;
    }

    .right {
        left: 0%;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .go-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
    
    .modal {
        padding: 1rem;
    }
    
    .modal-header,
    .modal-body {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
    
    .modal-title {
        font-size: 1.5rem;
    }
    
    .modal-links {
        flex-direction: column;
        align-items: center;
    }
    
    .modal-btn {
        width: 100%;
        justify-content: center;
    }
    
    ::-webkit-scrollbar {
        width: 0px;
        background: transparent;
    }
    
    .modal-content::-webkit-scrollbar {
        width: 0px;
        background: transparent;
    }
    
    /* Fix for background animation on mobile */
    .bg-animation::before {
        animation: geometricMove 60s linear infinite;
    }
    
    .bg-animation::after {
        animation: gridMove 50s linear infinite reverse;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .nav-container {
        padding: 0 1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }

    .hero-content h1 {
        font-size: clamp(2.2rem, 6vw, 3rem);
    }

    .hero-content .tagline {
        font-size: 1.3rem;
    }

    .hero-content p {
        font-size: 1rem;
    }
    
    .about-image {
        width: 250px;
    }
    
    /* Further reduce animation intensity on very small devices */
    .bg-animation::before {
        animation-duration: 120s;
    }
    
    .bg-animation::after {
        animation-duration: 100s;
    }

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

@media (max-width: 376px) {
    .hero-content h1 {
        font-size: clamp(2rem, 7vw, 2.5rem);
        line-height: 3rem;
    }
    .hero-content .tagline {
        font-size: 1rem;
    }
    .hero-content p, .about-text p, .modal-description, .timeline-content p, .recommendation-content, .modal-features li, .project-description {
        font-size: 0.95rem;
    }
    .hero {
        padding: 0 1rem;
    }
    .about, .experience, .recommendations {
        margin: 0 !important;
        padding: 3rem 1rem;
    }
    section {
        padding: 3rem 1rem;
    }
    .section-title{
        font-size: 1.8rem;
    }
    .modal-title {
        font-size: 1.2rem;
    }
    .about-image {
        width: 200px;
    }
}