/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-color: #ffffff;
    --text-color: #4a4a4a; /* Neutral gray for body text */
    --primary-color: #213547; /* Slightly desaturated dark blue */
    --secondary-color: #2a7eaf; /* Slightly softer blue */
    --accent-color: #e74c3c;
    --section-bg: #f8f9fa;
    --card-bg: #ffffff;
    --border-color: #e9ecef;
}

body {
    font-family: 'Lato', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Theme Toggle */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.theme-toggle button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.theme-toggle button:hover {
    transform: scale(1.1);
}

.theme-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    display: none;
    min-width: 150px;
    margin-top: 10px;
}

.theme-dropdown.show {
    display: block;
}

.theme-option {
    padding: 12px 16px;
    cursor: pointer;
    transition: background-color 0.3s;
    color: var(--text-color);
}

.theme-option:hover {
    background-color: var(--section-bg);
}

.theme-option:first-child {
    border-radius: 8px 8px 0 0;
}

.theme-option:last-child {
    border-radius: 0 0 8px 8px;
}

/* Navigation */
.navbar {
    background: var(--card-bg);
    padding: 1rem 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 999;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

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

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
}

.nav-logo h2 {
    color: var(--primary-color);
    font-size: 1.5rem;
    font-weight: bold;
}

.logo-img {
    height: 40px;
    width: auto;
    max-width: 150px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.logo-img:hover {
    transform: scale(1.05);
}

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

.nav-menu a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-color);
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 120px 0 80px;
    text-align: center;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: bold;
}

.hero h2 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.bio-text {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    line-height: 1.8;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    margin-bottom: 2rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    padding: 0.5rem 0;
}

.hero-buttons .btn {
    flex: 1;
    min-width: 140px;
    max-width: 180px;
    text-align: center;
    white-space: nowrap;
}

.btn {
    display: inline-block;
    padding: 14px 24px;
    margin: 0.25rem 0;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
    font-size: 0.9rem;
}

.btn.primary {
    background: var(--accent-color);
    color: white;
}

.btn.primary:hover {
    background: transparent;
    border-color: var(--accent-color);
    color: var(--accent-color);
}

.btn.secondary {
    background: transparent;
    color: white;
    border-color: white;
}

.btn.secondary:hover {
    background: white;
    color: var(--primary-color);
}

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

.social-links a {
    color: white;
    font-size: 1.5rem;
    transition: transform 0.3s;
}

.social-links a:hover {
    transform: scale(1.2);
}

/* About Section */
.about {
    padding: 80px 0;
    background: var(--section-bg);
}

.about h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    line-height: 1.8;
}

.about-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

.stat {
    text-align: center;
    padding: 2rem;
    background: var(--card-bg);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.stat h3 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat p {
    color: var(--text-color);
    font-weight: 500;
}

/* Skills Section */
.skills {
    padding: 80px 0;
    background: var(--bg-color);
}

.skills h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

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

.skill-category {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.skill-category h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-size: 1.3rem;
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill {
    background: var(--section-bg);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--text-color);
    border: 1px solid var(--border-color);
}

/* Projects Section */
.projects {
    padding: 80px 0;
    background: var(--section-bg);
}

.projects h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Distribute space and push buttons to bottom */
}

.project-buttons {
    margin-top: auto; /* Push buttons to the bottom */
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center; /* Center buttons if they wrap */
}

.project-buttons .btn {
    flex-grow: 1; /* Allow buttons to grow and fill space */
    text-align: center;
}


.project-card:hover {
    transform: translateY(-5px);
}

.project-header {
    margin-bottom: 1rem;
}

.project-header h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.project-tech {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.project-tech span {
    background: var(--primary-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
}

.project-card p {
    margin: 1rem 0;
    line-height: 1.6;
}

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

.project-features li {
    padding: 0.3rem 0;
    color: var(--text-color);
}

.project-features li::before {
    content: "✓";
    color: var(--secondary-color);
    font-weight: bold;
    margin-right: 0.5rem;
}

.projects .btn.secondary {
    background: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.projects .btn.secondary:hover {
    background: var(--primary-color);
    color: white;
}

/* Experience Section */
.experience {
    padding: 80px 0;
    background: var(--bg-color);
}

.experience h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

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

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
    background: var(--primary-color);
}

.timeline-item {
    position: relative;
    margin: 2rem 0;
    padding: 0 2rem;
}

.timeline-item:nth-child(odd) {
    text-align: right;
}

.timeline-item:nth-child(even) {
    text-align: left;
}

.timeline-date {
    background: var(--primary-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 1rem;
    font-weight: 500;
}

.timeline-content {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.timeline-content h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.timeline-content p {
    color: var(--secondary-color);
    margin-bottom: 1rem;
    font-weight: 500;
}

.timeline-content ul {
    list-style: none;
    padding: 0;
}

.timeline-content li {
    padding: 0.3rem 0;
    color: var(--text-color);
}

.timeline-content li::before {
    content: "▸";
    color: var(--secondary-color);
    font-weight: bold;
    margin-right: 0.5rem;
}

/* Services Section */
.services {
    padding: 80px 0;
    background: var(--section-bg);
}

.services h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.service-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.service-card p {
    line-height: 1.6;
    color: var(--text-color);
}

/* Lead Magnet Section */
.lead-magnet {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    color: white;
    text-align: center;
}

.lead-magnet h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: white;
}

.lead-magnet-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
}

.lead-magnet-text h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.lead-magnet-text p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.lead-magnet-form {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    color: var(--text-color);
}

.lead-magnet-form h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

/* Responsive adjustments for Lead Magnet */
@media (max-width: 768px) {
    .lead-magnet-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* Contact Section */
.contact {
    padding: 80px 0;
    background: var(--bg-color);
}

.contact h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.contact-info p {
    margin-bottom: 2rem;
    line-height: 1.6;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

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

.contact-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
    width: 30px;
}

.contact-item h4 {
    color: var(--primary-color);
    margin-bottom: 0.3rem;
}

.contact-form {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

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

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

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
    background: var(--bg-color);
    color: var(--text-color);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Footer */
.footer {
    background: var(--primary-color);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: white;
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s;
}

.footer-section ul li a:hover {
    opacity: 1;
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    color: white;
    font-size: 1.5rem;
    transition: transform 0.3s;
}

.footer-social a:hover {
    transform: scale(1.2);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    opacity: 0.7;
}

.footer-logo {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 1rem;
}

.footer-logo-img {
    height: 30px;
    width: auto;
    max-width: 120px;
    object-fit: contain;
    vertical-align: middle;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.footer-logo-img:hover {
    opacity: 1;
}

/* Theme Styles */

/* Professional Theme (Default) */
body.professional {
    --bg-color: #ffffff;
    --text-color: #333333;
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --section-bg: #f8f9fa;
    --card-bg: #ffffff;
    --border-color: #e9ecef;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Modern Theme */
body.modern {
    --bg-color: #fafafa;
    --text-color: #2e2e2e;
    --primary-color: #1a237e;
    --secondary-color: #00acc1;
    --accent-color: #ff5722;
    --section-bg: #f5f5f5;
    --card-bg: #ffffff;
    --border-color: #e0e0e0;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}

/* Creative Theme */
body.creative {
    --bg-color: #fff8e1;
    --text-color: #3e2723;
    --primary-color: #e65100;
    --secondary-color: #8bc34a;
    --accent-color: #e91e63;
    --section-bg: #fff3e0;
    --card-bg: #ffffff;
    --border-color: #ffcc02;
    font-family: 'Comic Sans MS', cursive, sans-serif;
}

/* Dark Theme */
body.dark {
    --bg-color: #1a1a1a;
    --text-color: #e0e0e0;
    --primary-color: #64b5f6;
    --secondary-color: #81c784;
    --accent-color: #ff7043;
    --section-bg: #2d2d2d;
    --card-bg: #333333;
    --border-color: #555555;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        background: var(--card-bg);
        position: absolute;
        top: 100%;
        left: 0;
        padding: 1rem 0;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu li {
        text-align: center;
        margin: 0.5rem 0;
    }
    
    .hamburger {
        display: flex;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .timeline::before {
        left: 0;
    }
    
    .timeline-item {
        text-align: left;
        padding-left: 2rem;
    }
    
    .timeline-item:nth-child(odd) {
        text-align: left;
    }
}

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

/* Scroll Reveal Animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: all 0.6s ease-out;
}

.fade-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.fade-in-right {
    opacity: 0;
    transform: translateX(30px);
    transition: all 0.6s ease-out;
}

.fade-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Enhanced Card Hover Effects with Glow */
.skill-category,
.project-card,
.experience-card,
.service-card {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1), 0 1px 3px rgba(0, 0, 0, 0.08); /* Softer shadows */
}

.skill-card:hover,
.project-card:hover,
.experience-card:hover,
.service-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15), 0 3px 6px rgba(0, 0, 0, 0.1); /* Enhanced hover shadows */
}

/* Glowing border effect */
.skill-category:hover,
.project-card:hover,
.service-card:hover {
    border: 1px solid var(--primary-color);
    box-shadow: 0 0 20px rgba(44, 62, 80, 0.3);
}

/* Progress Bar Animations */
.progress-bar {
    position: relative;
    overflow: hidden;
}

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

.progress-bar.animate::before {
    left: 100%;
}

/* Button Hover Enhancements */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.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 ease;
}

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

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* Loading Animation for Contact Form */
.btn-loading {
    position: relative;
    color: transparent !important;
}

.btn-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

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

/* Pulse Animation for CTA Elements */
.pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(var(--primary-color-rgb), 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(var(--primary-color-rgb), 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(var(--primary-color-rgb), 0);
    }
}

/* Mobile styles for hero buttons */
@media (max-width: 768px) {
    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 0.8rem;
    }
    
    .hero-buttons .btn {
        min-width: 200px;
        max-width: 250px;
    }
}

/* Particle Animation Background */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 30%, rgba(255,255,255,0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 70%, rgba(255,255,255,0.05) 0%, transparent 50%),
                radial-gradient(circle at 40% 80%, rgba(255,255,255,0.08) 0%, transparent 50%);
    animation: float 6s ease-in-out infinite;
    pointer-events: none;
}

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

/* Hero Title Animation */
.hero h1 {
    animation: fadeInSlideUp 1s ease-out forwards;
}

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

/* Counter Animation for Stats */
.stat h3 {
    animation: countUp 2s ease-out forwards;
}

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

/* Skill Tag Hover Animation */
.skill {
    transition: all 0.3s ease;
    position: relative;
}

.skill:hover {
    transform: translateY(-3px);
    background: var(--primary-color);
    color: white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* Project Tech Badge Animation */
.project-tech span {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.project-tech span::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 ease;
}

.project-tech span:hover::before {
    left: 100%;
}

.project-tech span:hover {
    transform: scale(1.1);
    box-shadow: 0 3px 10px rgba(0,0,0,0.3);
}

/* Service Icon Rotation Animation */
.service-icon {
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    transform: rotateY(360deg);
    color: var(--accent-color);
}

/* Timeline Item Slide Animation */
.timeline-item {
    opacity: 0;
    transform: translateX(-50px);
    animation: slideInTimeline 0.6s ease forwards;
}

.timeline-item:nth-child(even) {
    transform: translateX(50px);
}

@keyframes slideInTimeline {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Form Input Focus Animation */
.form-group {
    position: relative;
}

.form-group input:focus,
.form-group textarea:focus {
    transform: scale(1.02);
    box-shadow: 0 0 0 3px rgba(44, 62, 80, 0.1);
    transition: all 0.3s ease;
}

/* Navigation Scroll Effect */
.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

/* Parallax Effect for Sections */
.section-parallax {
    position: relative;
    overflow: hidden;
}

.section-parallax::before {
    content: '';
    position: absolute;
    top: -20%;
    left: -20%;
    width: 140%;
    height: 140%;
    background: radial-gradient(circle, rgba(52, 152, 219, 0.03) 0%, transparent 70%);
    animation: parallaxRotate 20s linear infinite;
    pointer-events: none;
}

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

/* Staggered Animation for Grid Items */
.skills-grid .skill-category,
.projects-grid .project-card,
.services-grid .service-card {
    opacity: 0;
    transform: translateY(30px);
    animation: staggeredFadeIn 0.6s ease forwards;
}

.skills-grid .skill-category:nth-child(1),
.projects-grid .project-card:nth-child(1),
.services-grid .service-card:nth-child(1) {
    animation-delay: 0.1s;
}

.skills-grid .skill-category:nth-child(2),
.projects-grid .project-card:nth-child(2),
.services-grid .service-card:nth-child(2) {
    animation-delay: 0.2s;
}

.skills-grid .skill-category:nth-child(3),
.projects-grid .project-card:nth-child(3),
.services-grid .service-card:nth-child(3) {
    animation-delay: 0.3s;
}

.skills-grid .skill-category:nth-child(4),
.projects-grid .project-card:nth-child(4),
.services-grid .service-card:nth-child(4) {
    animation-delay: 0.4s;
}

.skills-grid .skill-category:nth-child(5),
.projects-grid .project-card:nth-child(5),
.services-grid .service-card:nth-child(5) {
    animation-delay: 0.5s;
}

.skills-grid .skill-category:nth-child(6),
.projects-grid .project-card:nth-child(6),
.services-grid .service-card:nth-child(6) {
    animation-delay: 0.6s;
}

@keyframes staggeredFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(44, 62, 80, 0.1);
    z-index: 9999;
}

.scroll-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    width: 0%;
    transition: width 0.3s ease;
}

/* Floating Action Button */
.floating-contact {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: var(--accent-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s ease;
    animation: floatingPulse 2s ease-in-out infinite;
}

.floating-contact:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(0,0,0,0.4);
}

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

/* Glitch Effect for Creative Theme */
body.creative .hero h1 {
    position: relative;
}

body.creative .hero h1::before,
body.creative .hero h1::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

body.creative .hero h1::before {
    animation: glitch-1 0.5s infinite;
    color: #ff00ff;
    z-index: -1;
}

body.creative .hero h1::after {
    animation: glitch-2 0.5s infinite;
    color: #00ffff;
    z-index: -2;
}

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

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

/* Matrix Rain Effect for Dark Theme */
body.dark .hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, transparent 0%, rgba(0,255,0,0.03) 100%);
    background-size: 20px 20px;
    animation: matrixRain 3s linear infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes matrixRain {
    0% { background-position: 0 0; }
    100% { background-position: 0 20px; }
}

/* Morphing Button Effect */
.btn-morph {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-morph::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.5s ease;
}

.btn-morph:hover::before {
    width: 300px;
    height: 300px;
}

/* Text Reveal Animation */
.text-reveal {
    position: relative;
    overflow: hidden;
}

.text-reveal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary-color);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.text-reveal.animate::before {
    transform: translateX(100%);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.6);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: var(--card-bg);
    margin: 10% auto;
    padding: 30px;
    border-radius: 10px;
    max-width: 800px;
    width: 90%;
    position: relative;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}

.close-btn {
    color: var(--text-color);
    position: absolute;
    top: 15px;
    right: 25px;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}

.close-btn:hover {
    color: var(--accent-color);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

#modal-body h1, #modal-body h2, #modal-body h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

#modal-body ul {
    list-style-position: inside;
    padding-left: 1.5rem;
}

#modal-body li {
    margin-bottom: 0.5rem;
}

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

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out;
    z-index: 9999;
}

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

/* Scroll Reveal Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s ease-out;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: all 1s ease-out;
}

.reveal-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(30px);
    transition: all 1s ease-out;
}

.reveal-right.visible {
    opacity: 1;
    transform: translateX(0);
}

.zoom-in {
    opacity: 0;
    transform: scale(0.9);
    transition: all 1s ease-out;
}

.zoom-in.visible {
    opacity: 1;
    transform: scale(1);
}

/* Staggered Animation for Grid Items */
.stagger-reveal > * {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.stagger-reveal.visible > *:nth-child(1) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.1s;
}

.stagger-reveal.visible > *:nth-child(2) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.2s;
}

.stagger-reveal.visible > *:nth-child(3) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.3s;
}

.stagger-reveal.visible > *:nth-child(4) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.4s;
}

.stagger-reveal.visible > *:nth-child(5) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.5s;
}

.stagger-reveal.visible > *:nth-child(6) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.6s;
}


/* Scroll Progress Bar */
.scroll-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: transparent;
    z-index: 10000;
}

.scroll-progress-bar {
    height: 100%;
    background: var(--accent-color);
    width: 0%;
}
