/* Enhanced Portfolio Styles */

/* Loading Animation */
#page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

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

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
    margin: 0 auto 20px;
}

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

/* Fade-in animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

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

/* Enhanced banner styles */
#banner {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%),
                url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="25" cy="75" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    position: relative;
    overflow: hidden;
}

#banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
}

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

/* Enhanced typing effect */
.headtext {
    display: inline-block;
    border-right: 2px solid rgba(255, 255, 255, 0.8);
    animation: blink 1s infinite;
    min-height: 1.2em;
}

@keyframes blink {
    0%, 50% { border-color: rgba(255, 255, 255, 0.8); }
    51%, 100% { border-color: transparent; }
}

#text1, #text3, #text4, #text5, #text6 {
    display: none;
}

#text1 {
    display: inline;
    font-weight: bold;
    background: linear-gradient(45deg, #FFD700, #FFA500);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
}

#text3 {
    display: inline;
}

/* Enhanced skill icons */
.zoom-img img {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.skill-icon.animate-in {
    animation: skillFloat 0.6s ease forwards;
}

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

.zoom-img img:hover {
    transform: translateY(-10px) scale(1.1) rotate(5deg);
    filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.4)) brightness(1.1);
}

/* Enhanced project cards */
.work-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 20px;
    margin: 10px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

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

.work-item:hover::before {
    left: 100%;
}

.work-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Enhanced buttons */
.button {
    position: relative;
    overflow: hidden;
    background: linear-gradient(45deg, #667eea, #764ba2);
    border: none;
    border-radius: 25px;
    padding: 12px 30px;
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    background: linear-gradient(45deg, #764ba2, #667eea);
}

.button:active {
    transform: translateY(0);
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    transform: scale(0);
    animation: ripple-animation 0.6s linear;
    pointer-events: none;
}

@keyframes ripple-animation {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Enhanced spotlight sections */
.spotlight {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 20px;
    padding: 40px;
    margin: 20px 0;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.spotlight:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* Enhanced icons */
.icons.major a {
    display: inline-block;
    transition: all 0.3s ease;
    position: relative;
}

.icons.major a::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.2) 0%, transparent 70%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
}

.icons.major a:hover::before {
    width: 80px;
    height: 80px;
}

.icons.major a:hover {
    transform: scale(1.1) rotate(5deg);
}

/* Animated background gradient */
body {
    background: linear-gradient(-45deg, #1a1a2e, #16213e, #0f3460, #533483);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

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

/* Enhanced navigation */
#nav ul li a {
    transition: all 0.3s ease;
    position: relative;
}

#nav ul li a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(45deg, #FFD700, #FFA500);
    transform: translateX(-50%);
    transition: width 0.3s ease;
}

#nav ul li a:hover::after {
    width: 100%;
}

/* Enhanced scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #764ba2, #667eea);
}

/* Mobile responsiveness enhancements */
@media (max-width: 768px) {
    .work-item {
        margin: 5px 0;
        padding: 15px;
    }
    
    .zoom-img img {
        height: 40px;
        margin: 5px;
    }
    
    #gltf-viewer {
        width: 300px !important;
        height: 225px !important;
    }
    
    .headtext {
        font-size: 1.2em;
    }
}

/* Enhanced section transitions */
section {
    position: relative;
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
}

/* Floating elements */
.floating {
    animation: float 6s ease-in-out infinite;
}

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

/* Add floating class to 3D viewer */
#gltf-viewer {
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Badge styles for work experience */
.badge {
    display: inline-block;
    padding: 4px 12px;
    margin: 2px 4px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    font-size: 0.8em;
    border-radius: 20px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

/* Enhanced Skills Section */
.skills-category {
    margin: 30px 0;
    text-align: center;
}

.skills-category h4 {
    color: #fff;
    font-size: 1.2em;
    margin-bottom: 20px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.skill-item {
    display: inline-block;
    margin: 15px;
    text-align: center;
    transition: all 0.3s ease;
    padding: 15px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-width: 100px;
}

.skill-item:hover {
    transform: translateY(-5px) scale(1.05);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.skill-item span {
    display: block;
    margin-top: 10px;
    font-size: 0.9em;
    color: #fff;
    font-weight: 500;
}

.skill-item i {
    transition: all 0.3s ease;
}

.skill-item:hover i {
    transform: scale(1.1);
    filter: brightness(1.2);
}
