/* ============================================
   BLACK & GREEN GLASSY MODERN THEME
   Next-generation glassmorphism design
   ============================================ */

/* Global Glassy Effects */
* {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Background with subtle animated gradient */
html {
    background: linear-gradient(135deg, #000000 0%, #0a0a0a 25%, #000000 50%, #0a0a0a 75%, #000000 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    min-height: 100vh;
}

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

/* Glassy Navbar */
header .navbar,
.showHeaderOnTop {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(34, 197, 94, 0.15);
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.05),
                0 0 0 1px rgba(34, 197, 94, 0.03) inset;
}

/* Navbar Brand with Subtle Green */
.navbar-brand {
    color: #4ade80 !important;
    text-shadow: 0 0 8px rgba(34, 197, 94, 0.2);
    font-weight: 600;
    letter-spacing: 1px;
}

/* Nav Links with Hover Effects */
header .navbar .navbar-nav a {
    color: rgba(255, 255, 255, 0.9) !important;
    position: relative;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    margin: 0 0.25rem;
}

header .navbar .navbar-nav a::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 8px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(34, 197, 94, 0.05));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s;
}

header .navbar .navbar-nav a:hover::before {
    opacity: 1;
}

header .navbar .navbar-nav a:hover {
    color: #4ade80 !important;
    background: rgba(34, 197, 94, 0.08);
    text-shadow: 0 0 6px rgba(34, 197, 94, 0.3);
}

/* Theme Toggle Button - Removed */

/* Hero Section - Glassy Card */
#hero {
    position: relative;
    overflow: hidden;
}

#hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(34, 197, 94, 0.05) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
    pointer-events: none;
}

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

#hero .content {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(34, 197, 94, 0.15);
    border-radius: 24px;
    padding: 3rem;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.05),
                0 0 0 1px rgba(34, 197, 94, 0.03) inset,
                0 0 60px rgba(34, 197, 94, 0.02);
}

#hero h2 {
    color: #4ade80 !important;
    text-shadow: 0 0 12px rgba(34, 197, 94, 0.25);
    font-weight: 700;
    letter-spacing: -1px;
    /* Reserve space to prevent layout shift - match font-size from theme */
    height: clamp(48px, 9.6vw, 96px);
    min-height: clamp(40px, 8vw, 80px);
    line-height: 1.2;
    margin: 0.5em 0;
    display: block;
    overflow: visible;
    /* Ensure it's visible */
    opacity: 1 !important;
    visibility: visible !important;
    /* Prevent layout shift */
    box-sizing: border-box;
}

#hero h3 {
    color: rgba(255, 255, 255, 0.6) !important;
    text-shadow: 0 0 6px rgba(34, 197, 94, 0.15);
}

#hero p {
    color: rgba(255, 255, 255, 0.85) !important;
    line-height: 1.8;
}

#hero .subtitle {
    color: rgba(74, 222, 128, 0.7) !important;
    text-shadow: 0 0 6px rgba(34, 197, 94, 0.2);
}

/* Hero Image with Subtle Glow */
#hero .image img {
    border: 2px solid rgba(34, 197, 94, 0.2) !important;
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.15),
                0 0 40px rgba(34, 197, 94, 0.1) !important;
    background: rgba(34, 197, 94, 0.03);
    opacity: 1 !important; /* Ensure image is always visible */
}

#hero .image img:hover {
    border-color: rgba(34, 197, 94, 0.35) !important;
    box-shadow: 0 0 25px rgba(34, 197, 94, 0.2),
                0 0 50px rgba(34, 197, 94, 0.15) !important;
    transform: scale(1.02);
}

/* Social Icons */
#hero a.btn.social-icon {
    background: rgba(34, 197, 94, 0.08) !important;
    border: 1px solid rgba(34, 197, 94, 0.2) !important;
    backdrop-filter: blur(10px);
    color: #4ade80 !important;
}

#hero a.btn.social-icon:hover {
    background: rgba(34, 197, 94, 0.12) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.2);
    transform: translateY(-2px);
}

/* About Section */
#about {
    position: relative;
}

#about .image img {
    border: 2px solid rgba(34, 197, 94, 0.15) !important;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.08) !important;
    background: rgba(34, 197, 94, 0.03);
}

#about h3 {
    color: rgba(74, 222, 128, 0.85) !important;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

#about .content {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(34, 197, 94, 0.12);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.05);
}

#about ul li::before {
    color: #4ade80 !important;
    text-shadow: 0 0 6px rgba(34, 197, 94, 0.3);
}

#about a {
    color: #4ade80 !important;
}

#about a::after {
    background: linear-gradient(90deg, #4ade80, rgba(34, 197, 94, 0.4)) !important;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.3);
}

/* Projects Section - Glassy Cards */
#projects h3 {
    color: rgba(74, 222, 128, 0.85) !important;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

#projects .card {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.05),
                0 0 0 1px rgba(34, 197, 94, 0.03) inset !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

#projects .card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(34, 197, 94, 0.06), transparent);
    transition: left 0.5s;
}

#projects .card:hover::before {
    left: 100%;
}

#projects .card:hover {
    transform: translateY(-10px) scale(1.02) !important;
    border-color: rgba(34, 197, 94, 0.25) !important;
    box-shadow: 0 12px 48px rgba(34, 197, 94, 0.1),
                0 0 0 1px rgba(34, 197, 94, 0.06) inset,
                0 0 60px rgba(34, 197, 94, 0.08) !important;
}

#projects .card-img-top {
    border-bottom: 1px solid rgba(34, 197, 94, 0.15);
}

#projects .badge {
    background: rgba(34, 197, 94, 0.1) !important;
    color: #4ade80 !important;
    border: 1px solid rgba(34, 197, 94, 0.2);
    backdrop-filter: blur(10px);
    font-weight: 500;
}

#projects a {
    color: #4ade80 !important;
}

#projects .float-end .btn {
    background: rgba(34, 197, 94, 0.08) !important;
    border-color: rgba(34, 197, 94, 0.2) !important;
    color: #4ade80 !important;
    backdrop-filter: blur(10px);
}

#projects .float-end .btn:hover {
    background: rgba(34, 197, 94, 0.12) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.2);
}

/* Achievements Section */
#achievements h3 {
    color: rgba(74, 222, 128, 0.85) !important;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

#achievements .card {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.05) !important;
}

#achievements .card:hover {
    border-color: rgba(34, 197, 94, 0.25) !important;
    box-shadow: 0 12px 48px rgba(34, 197, 94, 0.1) !important;
    transform: translateY(-5px);
}

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

#contact h3 {
    color: rgba(74, 222, 128, 0.85) !important;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
    margin-bottom: 2rem;
}

#contact .container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#contact .text-center {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#contact .btn {
    background: rgba(34, 197, 94, 0.08) !important;
    border-color: rgba(34, 197, 94, 0.2) !important;
    color: #4ade80 !important;
    backdrop-filter: blur(10px);
    font-weight: 600;
    letter-spacing: 0.5px;
}

#contact .btn:hover {
    background: rgba(34, 197, 94, 0.12) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
    box-shadow: 0 0 15px rgba(34, 197, 94, 0.25),
                0 0 30px rgba(34, 197, 94, 0.15);
    transform: translateY(-2px);
}

#contact form .form-control {
    background: rgba(0, 0, 0, 0.3) !important;
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(10px);
}

#contact form .form-control:focus {
    background: rgba(0, 0, 0, 0.4) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.2),
                0 0 0 3px rgba(34, 197, 94, 0.08);
    outline: none;
}

/* Experience Section */
#experience h3 {
    color: rgba(74, 222, 128, 0.85) !important;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

#experience .experience-container {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.05) !important;
}

#experience .nav-item .nav-link.active {
    border-bottom-color: #4ade80 !important;
    color: #4ade80 !important;
    text-shadow: 0 0 6px rgba(34, 197, 94, 0.3);
}

#experience .nav-item .nav-link:hover {
    border-bottom-color: rgba(34, 197, 94, 0.3) !important;
    color: rgba(74, 222, 128, 0.7) !important;
}

/* Education Section */
#education .container > h3 {
    color: rgba(74, 222, 128, 0.85) !important;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

#education .card {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.05) !important;
}

#education .card:hover {
    border-color: rgba(34, 197, 94, 0.25) !important;
    box-shadow: 0 12px 48px rgba(34, 197, 94, 0.1) !important;
}

#education .row .index {
    background: linear-gradient(135deg, #4ade80, rgba(34, 197, 94, 0.7)) !important;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.3);
}

/* Footer */
footer {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(34, 197, 94, 0.15);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(34, 197, 94, 0.4), rgba(34, 197, 94, 0.25));
    border-radius: 10px;
    border: 2px solid rgba(0, 0, 0, 0.3);
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.2);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(34, 197, 94, 0.5), rgba(34, 197, 94, 0.35));
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.3);
}

/* Selection */
::selection {
    background: rgba(34, 197, 94, 0.25) !important;
    color: #4ade80 !important;
}

/* Links */
a {
    color: #4ade80 !important;
    text-decoration: none;
}

a:hover {
    color: #6ee7b7 !important;
    text-shadow: 0 0 6px rgba(34, 197, 94, 0.3);
}

/* Text Colors Override - Only apply to dark theme when needed */
body.dark .text-secondary {
    color: rgba(255, 255, 255, 0.6) !important;
}

/* Dropdown Menu */
.dropdown-menu {
    background: rgba(0, 0, 0, 0.6) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.08) !important;
}

.dropdown-item {
    color: rgba(255, 255, 255, 0.9) !important;
}

.dropdown-item:hover,
.dropdown-item:focus {
    background: rgba(34, 197, 94, 0.1) !important;
    color: #4ade80 !important;
}

/* Search */
#search {
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(10px);
}

#search:focus {
    border-color: rgba(34, 197, 94, 0.3) !important;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.2) !important;
    outline: none;
}

#search-content {
    background: rgba(0, 0, 0, 0.6) !important;
    backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.08) !important;
}

/* Smooth Animations */
@keyframes fadeInGlow {
    from {
        opacity: 0;
        filter: blur(10px);
    }
    to {
        opacity: 1;
        filter: blur(0);
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    #hero .content {
        padding: 2rem 1.5rem;
    }
    
    #about .content {
        padding: 1.5rem;
    }
    
    #projects .card {
        margin-bottom: 1.5rem;
    }
}

/* Additional Glow Effects */
#hero h2,
.navbar-brand,
#about h3,
#projects h3,
#achievements h3,
#contact h3 {
    animation: pulseGlow 3s ease-in-out infinite;
}

@keyframes pulseGlow {
    0%, 100% {
        text-shadow: 0 0 10px rgba(34, 197, 94, 0.2),
                     0 0 20px rgba(34, 197, 94, 0.1);
    }
    50% {
        text-shadow: 0 0 12px rgba(34, 197, 94, 0.3),
                     0 0 25px rgba(34, 197, 94, 0.15),
                     0 0 35px rgba(34, 197, 94, 0.1);
    }
}

/* Card Content Styling */
#projects .card-body,
#projects .card-footer {
    background: transparent !important;
    color: rgba(255, 255, 255, 0.9) !important;
}

#projects .card-title {
    color: #4ade80 !important;
    text-shadow: 0 0 8px rgba(34, 197, 94, 0.2);
}

#projects .card-text {
    color: rgba(255, 255, 255, 0.8) !important;
}

/* Section Spacing with Glow Dividers */
section {
    position: relative;
    padding: 4rem 0;
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(34, 197, 94, 0.3), transparent);
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.25);
}

/* Enhanced Button Styles */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(34, 197, 94, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

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

/* Loading Animation for Images - Removed to prevent disappearing images */

/* Enhanced Focus States */
*:focus-visible {
    outline: 2px solid rgba(34, 197, 94, 0.3);
    outline-offset: 2px;
    box-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

/* Container Enhancements */
.container,
.container-fluid {
    position: relative;
}

/* Subtle Grid Pattern Overlay */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(34, 197, 94, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(34, 197, 94, 0.02) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 0;
}

#content {
    position: relative;
    z-index: 1;
}

/* ============================================
   SCROLL-TRIGGERED ANIMATIONS
   Product landing page style effects
   ============================================ */

/* Fade in animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.fade-in-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.fade-in-right {
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Scale in animation */
.scale-in {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Hero section enhancements */
#hero {
    position: relative;
    overflow: hidden;
    min-height: 90vh;
    display: flex;
    align-items: center;
}

#hero .content {
    position: relative;
    z-index: 2;
}

#hero .image {
    position: relative;
    z-index: 2;
}

/* Enhanced parallax effect */
#hero::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(34, 197, 94, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulse 4s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

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

/* Floating particles */
.floating-particle {
    will-change: transform;
}

/* Enhanced card hover effects */
#projects .card {
    transform-style: preserve-3d;
    perspective: 1000px;
}

#projects .card:hover {
    transform: translateY(-10px) scale(1.02) rotateX(2deg) !important;
}

/* Staggered animation delays */
#projects .card:nth-child(1) { animation-delay: 0s; }
#projects .card:nth-child(2) { animation-delay: 0.1s; }
#projects .card:nth-child(3) { animation-delay: 0.2s; }
#projects .card:nth-child(4) { animation-delay: 0.3s; }
#projects .card:nth-child(5) { animation-delay: 0.4s; }
#projects .card:nth-child(6) { animation-delay: 0.5s; }
#projects .card:nth-child(7) { animation-delay: 0.6s; }
#projects .card:nth-child(8) { animation-delay: 0.7s; }
#projects .card:nth-child(9) { animation-delay: 0.8s; }
#projects .card:nth-child(10) { animation-delay: 0.9s; }

/* Skills list animation */
#about ul li {
    opacity: 0;
    transform: translateX(-20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

#about ul li.animate-in {
    opacity: 1;
    transform: translateX(0);
}

/* Enhanced navbar on scroll */
header .navbar {
    transition: backdrop-filter 0.3s ease, box-shadow 0.3s ease;
}

/* Smooth section transitions */
section {
    position: relative;
    overflow: hidden;
}

section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(34, 197, 94, 0.3), transparent);
    opacity: 0;
    transition: opacity 0.5s ease;
}

section.animate-in::after {
    opacity: 1;
}

/* Enhanced button ripple effect */
.btn {
    position: relative;
    overflow: hidden;
}

/* Text reveal animation */
@keyframes textReveal {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#hero h2 {
    animation: textReveal 1s ease-out forwards;
    /* Reserve space even during animation to prevent layout shift */
    min-height: clamp(40px, 8vw, 80px);
    line-height: 1.2;
    margin: 0.5em 0;
    /* Always maintain space - use height instead of min-height for more stability */
    height: clamp(48px, 9.6vw, 96px);
    display: block;
    /* Use visibility instead of opacity to maintain space during animation */
    visibility: visible !important;
    opacity: 1 !important;
    /* Prevent collapse */
    overflow: visible;
}

#hero h3 {
    animation: textReveal 1s ease-out 0.2s both;
}

#hero p {
    animation: textReveal 1s ease-out 0.4s both;
}

/* Glow pulse for headings */
@keyframes glowPulse {
    0%, 100% {
        text-shadow: 0 0 12px rgba(34, 197, 94, 0.25),
                     0 0 24px rgba(34, 197, 94, 0.15);
    }
    50% {
        text-shadow: 0 0 16px rgba(34, 197, 94, 0.4),
                     0 0 32px rgba(34, 197, 94, 0.25),
                     0 0 48px rgba(34, 197, 94, 0.15);
    }
}

#hero h2,
.navbar-brand {
    animation: glowPulse 3s ease-in-out infinite;
}

/* Enhanced image hover */
#hero .image img {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.5s ease;
}

#hero .image:hover img {
    transform: scale(1.05) rotate(1deg);
}

/* Social icons animation */
#hero a.btn.social-icon {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#hero a.btn.social-icon:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 10px 30px rgba(34, 197, 94, 0.3);
}

/* Smooth scroll padding */
html {
    scroll-padding-top: 80px;
}

/* Loading state */
.page-loading {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.page-loaded {
    opacity: 1;
}

/* Enhanced glassmorphism depth */
#hero .content,
#projects .card,
#about .content {
    position: relative;
}

#hero .content::before,
#projects .card::before,
#about .content::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(34, 197, 94, 0.05));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

#hero .content:hover::before,
#projects .card:hover::before,
#about .content:hover::before {
    opacity: 1;
}

/* Performance optimizations */
* {
    will-change: auto;
}

.fade-in-up,
.fade-in-left,
.fade-in-right,
.scale-in {
    will-change: transform, opacity;
}

.fade-in-up.animate-in,
.fade-in-left.animate-in,
.fade-in-right.animate-in,
.scale-in.animate-in {
    will-change: auto;
}

/* ============================================
   ADDITIONAL IMPRESSIVE EFFECTS
   ============================================ */

/* Gradient text animation */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

#hero h2 {
    color: #4ade80 !important;
    text-shadow: 0 0 12px rgba(34, 197, 94, 0.25),
                 0 0 24px rgba(34, 197, 94, 0.15);
    font-weight: 700;
    letter-spacing: -1px;
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

/* 3D tilt effect on cards */
#projects .card {
    transform-style: preserve-3d;
    transition: transform 0.3s ease;
}

#projects .card:hover {
    transform: translateY(-10px) rotateX(2deg) rotateY(2deg) !important;
}

/* Magnetic hover effect for buttons */
.btn,
a.btn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn:hover,
a.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(34, 197, 94, 0.3);
}

/* Shimmer effect on cards */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

#projects .card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(34, 197, 94, 0.1),
        transparent
    );
    transition: left 0.5s;
}

#projects .card:hover::after {
    left: 100%;
}

/* Enhanced badge animations */
#projects .badge {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

#projects .badge::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(34, 197, 94, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

#projects .card:hover .badge::before {
    width: 300px;
    height: 300px;
}

#projects .card:hover .badge {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(34, 197, 94, 0.3);
}

/* Floating animation for hero image */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

#hero .image img {
    animation: float 6s ease-in-out infinite;
}

/* Text gradient on scroll */
#hero .subtitle {
    background: linear-gradient(135deg, rgba(74, 222, 128, 0.7), rgba(34, 197, 94, 0.9));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Enhanced section headers */
section h3 {
    position: relative;
    display: inline-block;
}

section h3::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #4ade80, transparent);
    transition: width 0.8s ease;
}

section.animate-in h3::after {
    width: 100%;
}

/* Smooth reveal for project images */
#projects .card-img-top {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                filter 0.5s ease;
    filter: brightness(0.9);
}

#projects .card:hover .card-img-top {
    filter: brightness(1.1);
    transform: scale(1.15) !important;
}

/* Enhanced navbar brand glow */
.navbar-brand {
    position: relative;
}

.navbar-brand::after {
    content: '';
    position: absolute;
    inset: -5px;
    border-radius: 8px;
    background: rgba(34, 197, 94, 0.1);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.navbar-brand:hover::after {
    opacity: 1;
}

/* Scroll progress indicator */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, #4ade80, #22c55e);
    z-index: 9999;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px rgba(34, 197, 94, 0.5);
}

/* Enhanced contact form */
#contact form .form-control {
    transition: all 0.3s ease;
}

#contact form .form-control:focus {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(34, 197, 94, 0.2) !important;
}

/* Particle container positioning */
#particles-container {
    z-index: 0;
}

/* Smooth page load */
body {
    opacity: 0;
    animation: fadeIn 0.5s ease-in forwards;
}

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

/* Enhanced about section image */
#about .image img {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#about:hover .image img {
    transform: scale(1.05) rotate(2deg);
}

/* Staggered text reveal - but ensure h2 reserves space */
#hero .content > *:not(h2) {
    opacity: 0;
    animation: textReveal 0.8s ease-out forwards;
}

#hero .content > h2 {
    /* Reserve space immediately to prevent layout shift */
    height: clamp(48px, 9.6vw, 96px);
    min-height: clamp(40px, 8vw, 80px);
    line-height: 1.2;
    margin: 0.5em 0;
    opacity: 1 !important;
    visibility: visible !important;
    animation: textReveal 0.8s ease-out forwards;
    /* Ensure it takes up space even before animation */
    display: block;
    overflow: visible;
    /* Prevent any layout shift */
    box-sizing: border-box;
}

#hero .content > *:nth-child(1) { animation-delay: 0.1s; }
#hero .content > *:nth-child(2) { animation-delay: 0.3s; }
#hero .content > *:nth-child(3) { animation-delay: 0.5s; }
#hero .content > *:nth-child(4) { animation-delay: 0.7s; }
#hero .content > *:nth-child(5) { animation-delay: 0.9s; }
