/* Import modern fonts with performance optimization */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@300;400;500;600;700&family=Inter:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* CSS Custom Properties for better maintainability */
:root {
    --primary-color: #00adee;
    --secondary-color: #388bfd;
    --accent-color: #00bfff;
    --bg-primary: #0f0f23;
    --bg-secondary: #000000;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --border-color: rgba(0, 173, 238, 0.2);
    --shadow-color: rgba(0, 173, 238, 0.3);
    --gradient-primary: linear-gradient(135deg, #00adee 0%, #388bfd 100%);
    --border-radius: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --max-width: 1400px;
    --section-padding: 80px 0;
    --container-padding: 0 20px;
}

/* Performance-optimized base styles */
*, *::before, *::after {
    box-sizing: border-box;
}

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--text-primary);
    background: 
        radial-gradient(ellipse at center, var(--bg-primary) 0%, var(--bg-secondary) 70%),
        linear-gradient(45deg, #000511 0%, #0a0a1f 50%, var(--bg-secondary) 100%);
    background-attachment: fixed;
    overflow-x: hidden;
    position: relative;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
}

/* Mobile-first approach: reduce animations on smaller screens */
@media (max-width: 768px) {
    body {
        background-attachment: scroll; /* Better performance on mobile */
    }
}

/* Enhanced Animated Starfield with Nebula Effects */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 120%;
    height: 120%;
    background-image: 
        /* Main stars - white/bright */
        radial-gradient(2px 2px at 25px 15px, rgba(255,255,255,0.9), transparent),
        radial-gradient(1px 1px at 80px 45px, rgba(255,255,255,0.7), transparent),
        radial-gradient(1.5px 1.5px at 120px 85px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 180px 25px, rgba(255,255,255,0.6), transparent),
        radial-gradient(2px 2px at 220px 75px, rgba(255,255,255,1), transparent),
        
        /* Colored stars - blue/cyan spectrum */
        radial-gradient(1px 1px at 35px 65px, rgba(0,173,238,0.8), transparent),
        radial-gradient(1.5px 1.5px at 95px 20px, rgba(56,139,253,0.7), transparent),
        radial-gradient(1px 1px at 145px 55px, rgba(0,191,255,0.9), transparent),
        radial-gradient(2px 2px at 195px 90px, rgba(30,144,255,0.6), transparent),
        
        /* Distant stars - smaller */
        radial-gradient(0.5px 0.5px at 60px 10px, rgba(255,255,255,0.5), transparent),
        radial-gradient(0.5px 0.5px at 110px 40px, rgba(0,173,238,0.4), transparent),
        radial-gradient(0.5px 0.5px at 160px 70px, rgba(255,255,255,0.3), transparent),
        radial-gradient(0.5px 0.5px at 210px 35px, rgba(56,139,253,0.4), transparent);
    
    background-repeat: repeat;
    background-size: 300px 200px;
    animation: starfieldFloat 25s linear infinite;
    pointer-events: none;
    z-index: 1;
    opacity: 0.8;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 130%;
    height: 130%;
    background-image: 
        /* Nebula clouds */
        radial-gradient(ellipse 400px 200px at 20% 30%, rgba(0,173,238,0.03), transparent),
        radial-gradient(ellipse 300px 150px at 80% 70%, rgba(56,139,253,0.04), transparent),
        radial-gradient(ellipse 500px 250px at 50% 10%, rgba(30,144,255,0.02), transparent),
        radial-gradient(ellipse 350px 180px at 10% 80%, rgba(0,191,255,0.025), transparent),
        
        /* Twinkling stars layer */
        radial-gradient(1px 1px at 45px 25px, rgba(0,173,238,0.9), transparent),
        radial-gradient(1.5px 1.5px at 85px 65px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 135px 35px, rgba(56,139,253,0.7), transparent),
        radial-gradient(2px 2px at 175px 75px, rgba(0,191,255,0.9), transparent),
        radial-gradient(1px 1px at 215px 45px, rgba(255,255,255,0.6), transparent),
        
        /* Shooting star trails */
        linear-gradient(45deg, transparent 40%, rgba(0,173,238,0.1) 50%, transparent 60%),
        linear-gradient(125deg, transparent 40%, rgba(255,255,255,0.08) 50%, transparent 60%);
    
    background-repeat: repeat;
    background-size: 400px 300px;
    animation: nebulaFlow 35s linear infinite reverse;
    pointer-events: none;
    z-index: 1;
    opacity: 0.7;
}

@keyframes starfieldFloat {
    0% {
        transform: translate(0, 0) rotate(0deg);
        opacity: 0.8;
    }
    25% {
        opacity: 0.6;
        transform: translate(-50px, -30px) rotate(1deg);
    }
    50% {
        transform: translate(-100px, -60px) rotate(0deg);
        opacity: 1;
    }
    75% {
        opacity: 0.7;
        transform: translate(-150px, -90px) rotate(-1deg);
    }
    100% {
        transform: translate(-200px, -120px) rotate(0deg);
        opacity: 0.8;
    }
}

@keyframes nebulaFlow {
    0% {
        transform: translate(0, 0) scale(1) rotate(0deg);
        opacity: 0.7;
    }
    25% {
        transform: translate(30px, -20px) scale(1.05) rotate(0.5deg);
        opacity: 0.5;
    }
    50% {
        transform: translate(60px, -40px) scale(1.1) rotate(1deg);
        opacity: 0.8;
    }
    75% {
        transform: translate(90px, -60px) scale(1.05) rotate(0.5deg);
        opacity: 0.6;
    }
    100% {
        transform: translate(120px, -80px) scale(1) rotate(0deg);
        opacity: 0.7;
    }
}

#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

#navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 4%;
    background: rgba(10, 12, 16, 0.95);
    backdrop-filter: blur(15px);
    position: fixed;
    width: 92%;
    top: 0;
    z-index: 10;
    box-sizing: border-box;
    border-bottom: 1px solid rgba(0, 173, 238, 0.2);
}

.nav-brand { 
    font-size: 24px; 
    font-weight: 700; 
    font-family: 'Space Grotesk', sans-serif;
    color: #00adee;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 25px;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
    justify-content: center;
}

.nav-link {
    text-decoration: none;
    color: #fff;
    position: relative;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    padding: 8px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    display: block;
    margin-top: 5px;
    right: 0;
    background: #00adee;
    transition: width .3s ease;
    transition-delay: .2s;
}

.nav-link:hover::after {
    width: 100%;
    left: 0;
    background: #00adee;
}

.hamburger {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    z-index: 11;
}

.hamburger span {
    height: 3px;
    width: 25px;
    background: #00adee;
    border-radius: 5px;
    transition: 0.3s;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-6px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-6px, -6px);
}

.section {
    padding: 80px 20px;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    text-align: center;
}

.section-title {
    font-size: 36px;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.hero-content {
    margin-top: 100px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    width: 100%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 40px;
    text-align: center;
}

/* Floating Profile Image */
.floating-profile {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.profile-image-new {
    width: 280px;
    height: 280px;
    object-fit: cover;
    border-radius: 20px;
    position: relative;
    z-index: 3;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Enhanced visibility with subtle backdrop and glow */
    backdrop-filter: blur(1px);
    box-shadow: 
        0 20px 60px rgba(0, 173, 238, 0.3),
        0 10px 30px rgba(0, 173, 238, 0.2),
        0 0 0 2px rgba(255, 255, 255, 0.1),
        inset 0 0 0 1px rgba(255, 255, 255, 0.2);
    
    /* Floating animation */
    animation: profileFloat 6s ease-in-out infinite;
    
    /* Subtle brightness and contrast boost for dark images */
    filter: brightness(1.1) contrast(1.05) saturate(1.1);
    
    /* Ensure proper sizing on all screens */
    max-width: 100%;
    height: auto;
    aspect-ratio: 1;
}

.profile-image-new::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: linear-gradient(
        45deg,
        rgba(0, 173, 238, 0.3) 0%,
        rgba(56, 139, 253, 0.2) 25%,
        rgba(0, 173, 238, 0.3) 50%,
        rgba(56, 139, 253, 0.2) 75%,
        rgba(0, 173, 238, 0.3) 100%
    );
    border-radius: 25px;
    z-index: -1;
    animation: profileGlow 4s ease-in-out infinite alternate;
    opacity: 0.6;
}

.profile-image-new::after {
    content: '';
    position: absolute;
    top: -20px;
    left: -20px;
    right: -20px;
    bottom: -20px;
    background: radial-gradient(
        ellipse at center,
        rgba(0, 173, 238, 0.15) 0%,
        rgba(0, 173, 238, 0.08) 30%,
        transparent 70%
    );
    border-radius: 35px;
    z-index: -2;
    animation: profileGlow 8s ease-in-out infinite alternate reverse;
}

@keyframes profileFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg) scale(1);
    }
    25% {
        transform: translateY(-8px) rotate(1deg) scale(1.02);
    }
    50% {
        transform: translateY(-15px) rotate(0deg) scale(1.05);
    }
    75% {
        transform: translateY(-8px) rotate(-1deg) scale(1.02);
    }
}

@keyframes profileGlow {
    0% {
        opacity: 0.4;
        transform: scale(0.98);
    }
    100% {
        opacity: 0.8;
        transform: scale(1.02);
    }
}

.profile-image-new:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 
        0 30px 80px rgba(0, 173, 238, 0.4),
        0 15px 40px rgba(0, 173, 238, 0.3),
        0 0 0 3px rgba(255, 255, 255, 0.2),
        inset 0 0 0 2px rgba(255, 255, 255, 0.3);
    filter: brightness(1.15) contrast(1.1) saturate(1.15);
}

.glitch-text {
    font-size: 48px;
    letter-spacing: 2px;
    position: relative;
    color: #fff;
    animation: glitch 2s infinite;
}

.glitch-text::after, .glitch-text::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch-text::after {
    left: 2px;
    text-shadow: -1px 0 red;
    clip: rect(24px, 550px, 90px, 0);
    animation: glitch-anim-2 2s infinite linear alternate-reverse;
}

.glitch-text::before {
    left: -2px;
    text-shadow: 1px 0 blue;
    clip: rect(85px, 550px, 140px, 0);
    animation: glitch-anim 2s infinite linear alternate-reverse;
}

@keyframes glitch {
    0% {
        transform: skew(0.3deg);
    }
    2% {
        transform: skew(0.3deg) translate(1px, 0);
    }
    4% {
        transform: skew(0.3deg) translate(-1px, 0);
    }
    6% {
        transform: skew(0.3deg) translate(1.5px, 0);
    }
    8% {
        transform: skew(0.3deg) translate(-1.5px, 0);
    }
    10% {
        transform: skew(0.3deg) translate(2px, 0);
    }
    12% {
        transform: skew(0.3deg) translate(-2px, 0);
    }
    100% {
        transform: skew(0.3deg);
    }
}

@keyframes glitch-anim {
    0% {
        clip: rect(44px, 550px, 56px, 0);
    }
    5% {
        clip: rect(85px, 550px, 140px, 0);
    }
    10% {
        clip: rect(28px, 550px, 74px, 0);
    }
    15% {
        clip: rect(65px, 550px, 108px, 0);
    }
    20% {
        clip: rect(128px, 550px, 110px, 0);
    }
    100% {
        clip: rect(24px, 550px, 90px, 0);
    }
}

@keyframes glitch-anim-2 {
    0% {
        clip: rect(6px, 550px, 56px, 0);
    }
    5% {
        clip: rect(48px, 550px, 100px, 0);
    }
    10% {
        clip: rect(84px, 550px, 80px, 0);
    }
    15% {
        clip: rect(19px, 550px, 85px, 0);
    }
    20% {
        clip: rect(120px, 550px, 85px, 0);
    }
    100% {
        clip: rect(6px, 550px, 56px, 0);
    }
}

.btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 30px;
    text-transform: uppercase;
    margin: 10px;
    transition: background 0.3s ease;
    cursor: pointer;
    background: #00adee;
    color: #fff;
    text-decoration: none;
}

.btn-primary {
    background: #0066cc;
}

.btn-secondary {
    background: #555;
}

.btn:hover {
    background: #004f9c;
}

/* Loading Screen */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0a0c10;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 1s ease;
}

.loading-animation {
    text-align: center;
}

.neural-network {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.node {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #00adee;
    animation: pulse 1.5s ease-in-out infinite;
}

.node:nth-child(1) { animation-delay: 0s; }
.node:nth-child(2) { animation-delay: 0.3s; }
.node:nth-child(3) { animation-delay: 0.6s; }

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

/* AI Avatar */
.ai-avatar {
    position: relative;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.avatar-ring {
    position: absolute;
    width: 220px;
    height: 220px;
    border: 2px solid #00adee;
    border-radius: 50%;
    animation: rotate 10s linear infinite;
}

.avatar-core {
    position: absolute;
    width: 180px;
    height: 180px;
    border: 1px solid #004f9c;
    border-radius: 50%;
    animation: rotate 15s linear infinite reverse;
}

.profile-img {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    object-fit: cover;
    z-index: 2;
}

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

/* Typing Animation */
.typing-text {
    font-size: 24px;
    margin: 20px 0;
    height: 30px;
}

.cursor {
    display: inline-block;
    background-color: #00adee;
    margin-left: 3px;
    width: 3px;
    animation: blink 1s infinite;
}

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

/* Code Interface */
.code-interface {
    background: rgba(13, 17, 23, 0.95);
    border-radius: 12px;
    border: 1px solid rgba(56, 139, 253, 0.3);
    margin: 20px 0;
    max-width: 600px;
    box-shadow: 
        0 8px 32px rgba(13, 17, 23, 0.6),
        0 0 0 1px rgba(56, 139, 253, 0.1);
    backdrop-filter: blur(16px);
    position: relative;
    overflow: hidden;
    font-family: 'JetBrains Mono', 'Fira Code', 'Monaco', 'Cascadia Code', monospace;
    animation: codeInterfaceGlow 3s ease-in-out infinite alternate;
}

@keyframes codeInterfaceGlow {
    0% {
        box-shadow: 
            0 8px 32px rgba(13, 17, 23, 0.6),
            0 0 0 1px rgba(56, 139, 253, 0.1),
            0 0 20px rgba(0, 173, 238, 0.1);
    }
    100% {
        box-shadow: 
            0 8px 32px rgba(13, 17, 23, 0.6),
            0 0 0 1px rgba(56, 139, 253, 0.2),
            0 0 30px rgba(0, 173, 238, 0.2);
    }
}

.code-header {
    background: rgba(22, 27, 34, 0.8);
    padding: 12px 16px;
    border-bottom: 1px solid rgba(56, 139, 253, 0.2);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.window-controls {
    display: flex;
    gap: 8px;
    align-items: center;
}

.control {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.control.close {
    background: #ff5f57;
    box-shadow: 0 0 8px rgba(255, 95, 87, 0.3);
}

.control.minimize {
    background: #ffbd2e;
    box-shadow: 0 0 8px rgba(255, 189, 46, 0.3);
}

.control.maximize {
    background: #28ca42;
    box-shadow: 0 0 8px rgba(40, 202, 66, 0.3);
}

.tab-bar {
    display: flex;
    gap: 4px;
}

.tab {
    background: rgba(56, 139, 253, 0.1);
    color: rgba(255, 255, 255, 0.7);
    padding: 6px 12px;
    border-radius: 6px 6px 0 0;
    font-size: 12px;
    font-weight: 500;
    border: 1px solid rgba(56, 139, 253, 0.2);
    border-bottom: none;
    transition: all 0.3s ease;
    position: relative;
}

.tab.active {
    background: rgba(0, 173, 238, 0.2);
    color: #00adee;
    border-color: rgba(0, 173, 238, 0.4);
}

.tab::after {
    content: '';
    position: absolute;
    top: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: #00adee;
    transition: width 0.3s ease;
}

.tab.active::after {
    width: 80%;
}

.code-content {
    display: flex;
    background: rgba(13, 17, 23, 0.9);
    min-height: 220px;
    position: relative;
}

.line-numbers {
    background: rgba(22, 27, 34, 0.6);
    padding: 16px 12px;
    border-right: 1px solid rgba(56, 139, 253, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 40px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
    user-select: none;
}

.line-numbers span {
    height: 20px;
    display: flex;
    align-items: center;
    position: relative;
}

.line-numbers span::before {
    content: '';
    position: absolute;
    right: -12px;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 12px;
    background: rgba(56, 139, 253, 0.1);
}

.code-text {
    padding: 16px;
    flex: 1;
    font-size: 13px;
    line-height: 20px;
    color: #e6edf3;
}

.code-line {
    height: 20px;
    display: flex;
    align-items: center;
    position: relative;
}

.code-line:hover {
    background: rgba(56, 139, 253, 0.05);
}

/* Syntax Highlighting */
.keyword {
    color: #ff7b72;
    font-weight: 600;
}

.variable {
    color: #79c0ff;
}

.operator {
    color: #ff7b72;
}

.punctuation {
    color: #e6edf3;
}

.property {
    color: #79c0ff;
    font-style: italic;
}

.string {
    color: #a5d6ff;
}

.method {
    color: #d2a8ff;
    font-weight: 500;
}

.comment {
    color: #8b949e;
    font-style: italic;
}

.cursor-blink {
    color: #00adee;
    animation: cursorBlink 1s infinite;
    font-weight: bold;
}

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

/* Code Interface Responsive */
@media (max-width: 768px) {
    .code-interface {
        margin: 15px auto;
        max-width: calc(100vw - 40px);
        width: calc(100% - 40px);
        border-radius: 8px;
        box-sizing: border-box;
        overflow-x: auto;
        position: relative;
        left: 0;
        right: 0;
    }
    
    .code-content {
        min-height: 200px;
        overflow-x: auto;
    }
    
    .code-text {
        font-size: 12px;
        padding: 12px;
        white-space: nowrap;
        overflow-x: auto;
        min-width: max-content;
    }
    
    .tab {
        font-size: 11px;
        padding: 4px 8px;
    }
    
    .line-numbers {
        padding: 12px 8px;
        min-width: 32px;
        font-size: 11px;
        flex-shrink: 0;
    }
    
    .code-line {
        white-space: nowrap;
        min-width: max-content;
    }
}

/* Hero Description */
.hero-description {
    font-size: 18px;
    line-height: 1.6;
    margin: 30px 0;
    opacity: 0.9;
    font-family: 'Roboto', sans-serif;
}

/* Social Links */
.social-links {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    justify-content: center;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: #00adee;
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 173, 238, 0.3);
}

/* Modern Technologies Section */
#technologies {
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);
    position: relative;
    overflow: hidden;
    padding: 100px 20px;
    width: 100%;
    max-width: none;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.tech-flow-container {
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 1400px;
    padding: 40px 0;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tech-flow {
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: 60px;
    min-width: 200%;
    animation: flowLeft 20s linear infinite;
}

.tech-icon {
    font-size: 3rem;
    color: #00adee;
    transition: transform 0.3s ease;
}

.tech-icon:hover {
    transform: scale(1.2);
}

@keyframes flowLeft {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}


#technologies::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><radialGradient id="g" cx="50%" cy="50%" r="50%"><stop offset="0%" stop-color="%2300adee" stop-opacity="0.1"/><stop offset="100%" stop-color="%2300adee" stop-opacity="0"/></radialGradient></defs><circle cx="200" cy="200" r="3" fill="%2300adee" opacity="0.3"><animate attributeName="opacity" values="0.3;1;0.3" dur="3s" repeatCount="indefinite"/></circle><circle cx="800" cy="300" r="2" fill="%2300adee" opacity="0.2"><animate attributeName="opacity" values="0.2;0.8;0.2" dur="4s" repeatCount="indefinite"/></circle><circle cx="600" cy="700" r="2.5" fill="%2300adee" opacity="0.4"><animate attributeName="opacity" values="0.4;1;0.4" dur="2.5s" repeatCount="indefinite"/></circle><circle cx="100" cy="600" r="2" fill="%2300adee" opacity="0.25"><animate attributeName="opacity" values="0.25;0.75;0.25" dur="3.5s" repeatCount="indefinite"/></circle><circle cx="900" cy="800" r="3" fill="%2300adee" opacity="0.3"><animate attributeName="opacity" values="0.3;0.9;0.3" dur="2.8s" repeatCount="indefinite"/></circle></svg>') no-repeat center;
    background-size: cover;
    opacity: 0.3;
    z-index: 1;
}

.tech-header {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.tech-main-title {
    font-size: 3rem;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    background: linear-gradient(135deg, #00adee, #ffffff, #00adee);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    animation: glow 3s ease-in-out infinite alternate;
    text-align: center;
    width: 100%;
}

@keyframes glow {
    from {
        text-shadow: 0 0 20px rgba(0, 173, 238, 0.3);
    }
    to {
        text-shadow: 0 0 30px rgba(0, 173, 238, 0.6), 0 0 40px rgba(0, 173, 238, 0.4);
    }
}

.tech-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
    font-family: 'Inter', sans-serif;
    text-align: center;
    width: 100%;
}


/* Floating particles animation */
#technologies::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 25% 25%, rgba(0, 173, 238, 0.05) 0%, transparent 50%),
                radial-gradient(circle at 75% 75%, rgba(0, 173, 238, 0.05) 0%, transparent 50%),
                radial-gradient(circle at 50% 50%, rgba(0, 173, 238, 0.03) 0%, transparent 50%);
    animation: float 20s ease-in-out infinite;
    z-index: 1;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(-10px, -10px) rotate(90deg);
    }
    50% {
        transform: translate(10px, 5px) rotate(180deg);
    }
    75% {
        transform: translate(-5px, 10px) rotate(270deg);
    }
}

/* About Section */
#about {
    padding: 80px 20px;
    background: rgba(0, 0, 0, 0.02);
    text-align: center;
}

#about .section-title {
    text-align: center;
    font-size: 2.5rem;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    color: #00adee;
    margin-bottom: 3rem;
    text-transform: uppercase;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.about-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(0, 173, 238, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 220px;
}

.about-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 173, 238, 0.05), transparent);
    transition: left 0.6s ease;
}

.about-card:hover::before {
    left: 100%;
}

.about-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 15px 35px rgba(0, 173, 238, 0.15);
    border-color: rgba(0, 173, 238, 0.4);
}

.card-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
    filter: drop-shadow(0 0 10px rgba(0, 173, 238, 0.3));
}

.about-card h3 {
    color: #00adee;
    margin-bottom: 1rem;
    font-size: 1.25rem;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
    line-height: 1.3;
}

.about-card p {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    opacity: 0.85;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    margin: 0;
    flex-grow: 1;
    display: flex;
    align-items: center;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
    margin-top: 50px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.skill-category {
    background: rgba(255, 255, 255, 0.05);
    padding: 25px 20px;
    border-radius: 15px;
    border: 1px solid rgba(0, 173, 238, 0.3);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.skill-category::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #00adee, transparent);
    animation: scan 4s linear infinite;
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 173, 238, 0.15);
    border-color: #00adee;
}

.skill-category h3 {
    color: #00adee;
    margin-bottom: 15px;
    text-align: center;
    font-size: 16px;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
}

.skill-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.skill-tag {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.skill-tag:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

.project-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    overflow: hidden;
    border: 1px solid rgba(0, 173, 238, 0.3);
    transition: all 0.3s ease;
    position: relative;
    height: fit-content;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 173, 238, 0.2);
}

.project-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.project-content {
    padding: 25px;
}

.project-title {
    color: #00adee;
    margin-bottom: 10px;
    font-size: 18px;
}

.project-description {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin-bottom: 20px;
    opacity: 0.9;
}

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

.tech-tag {
    background: rgba(0, 173, 238, 0.2);
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 11px;
    border: 1px solid #00adee;
}

/* Blog Cards */
.blogs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

.blog-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 25px;
    border: 1px solid rgba(0, 173, 238, 0.3);
    transition: all 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 173, 238, 0.2);
}

.blog-title {
    color: #00adee;
    margin-bottom: 10px;
    font-size: 16px;
    text-decoration: none;
}

.blog-title:hover {
    color: #fff;
}

.blog-excerpt {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin-bottom: 15px;
    opacity: 0.8;
}

.blog-date {
    font-size: 12px;
    opacity: 0.6;
}

/* Contact Form */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    margin-top: 50px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

.contact-info h3 {
    color: #00adee;
    margin-bottom: 20px;
}

.contact-info p {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin-bottom: 30px;
    opacity: 0.9;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
    font-family: 'Roboto', sans-serif;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.form-group {
    position: relative;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(0, 173, 238, 0.3);
    border-radius: 10px;
    color: #fff;
    font-family: 'Roboto', sans-serif;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #00adee;
    box-shadow: 0 0 20px rgba(0, 173, 238, 0.3);
}

.form-group label {
    position: absolute;
    top: 15px;
    left: 15px;
    color: rgba(255, 255, 255, 0.6);
    pointer-events: none;
    transition: all 0.3s ease;
    font-family: 'Roboto', sans-serif;
}

.form-group input:focus + label,
.form-group textarea:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:not(:placeholder-shown) + label {
    top: -8px;
    left: 10px;
    font-size: 12px;
    color: #00adee;
    background: #0e1117;
    padding: 0 5px;
}

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

.btn-full {
    width: 100%;
    position: relative;
    overflow: hidden;
}

.btn-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Scroll Indicator */
.scroll-indicator {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    z-index: 100;
    pointer-events: none;
}

.scroll-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #00adee;
    margin: 0 auto 10px;
    animation: bounce 2s infinite;
}

.scroll-text {
    font-size: 12px;
    opacity: 0.7;
    font-family: 'Roboto', sans-serif;
}

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

/* Footer */
.footer {
    background: rgba(10, 12, 16, 0.9);
    padding: 30px 0;
    text-align: center;
    border-top: 1px solid rgba(0, 173, 238, 0.3);
}

.footer p {
    font-family: 'Roboto', sans-serif;
    opacity: 0.7;
    margin: 0;
}

/* Professional Cursor Effects */
.btn, .social-link, .nav-link, .project-card, .skill-tag {
    cursor: pointer;
    transition: all 0.3s ease;
}

/* Subtle rocket effect only on key interactive elements */
.btn:hover, .social-link:hover {
    cursor: url('data:image/svg+xml;utf8,\u003csvg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="%2300adee" stroke="%23ffffff" stroke-width="1"\u003e\u003cpath d="M4.5 16.5c-1.5 1.5-2 3.5-2 3.5s2-0.5 3.5-2c1.5-1.5 1.5-3.5 0-5s-3.5-1.5-5 0z"/\u003e\u003cpath d="M12 15l-3-3a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.35 22.35 0 0 1-4 2z"/\u003e\u003cpath d="M9 12H4s.55-3.03 2-4c1.62-1.08 5 0 5 0"/\u003e\u003cpath d="M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5"/\u003e\u003c/svg\u003e') 10 10, pointer;
}

/* Keep standard cursor for text and general navigation */
body {
    cursor: default;
}

.nav-link:hover, .project-card:hover {
    cursor: pointer;
}

/* Special hover effect for CTA buttons */
.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 173, 238, 0.3);
}

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

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

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    body::before,
    body::after {
        animation: none;
    }
}

/* Focus styles for accessibility */
.btn:focus,
.nav-link:focus,
.social-link:focus,
button:focus,
input:focus,
textarea:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #00ff00;
        --text-primary: #ffffff;
        --bg-primary: #000000;
    }
}

/* Responsive Navigation */
@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 70px;
        right: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: rgba(10, 12, 16, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 40px;
        transition: right 0.3s ease;
        z-index: 1000;
        margin: 0;
        padding: 0;
        list-style: none;
    }
    
    .nav-links.active {
        right: 0;
    }
    
    .nav-links li {
        margin: 0;
        padding: 0;
    }
    
    .nav-link {
        font-size: 20px;
        padding: 15px 30px;
        color: #ffffff;
        text-decoration: none;
        font-weight: 500;
        letter-spacing: 1px;
        transition: all 0.3s ease;
        position: relative;
        display: block;
        text-align: center;
    }
    
    .nav-link:hover {
        color: #00adee;
        transform: translateY(-2px);
    }
    
    .nav-link.active {
        color: #00adee;
    }
    
    .hamburger {
        display: flex;
        position: relative;
        z-index: 1001;
    }
    
    .hamburger span {
        transition: all 0.3s ease;
    }
    
    .hamburger.active span:nth-child(1) {
        transform: rotate(-45deg) translate(-6px, 6px);
        background: #00adee;
    }
    
    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }
    
    .hamburger.active span:nth-child(3) {
        transform: rotate(45deg) translate(-6px, -6px);
        background: #00adee;
    }
    
    #navbar {
        padding: 15px 20px;
        width: calc(100% - 40px);
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 1000;
    }
    
    /* Ensure desktop nav links are not affected */
    @media (min-width: 769px) {
        .nav-links {
            position: static;
            background: none;
            backdrop-filter: none;
            flex-direction: row;
            justify-content: flex-end;
            align-items: center;
            gap: 25px;
            height: auto;
            width: auto;
            right: auto;
            top: auto;
            z-index: auto;
        }
        
        .hamburger {
            display: none;
        }
    }
}

/* Mobile-first responsive breakpoints */

/* Small mobile devices */
@media (max-width: 480px) {
    :root {
        --section-padding: 60px 0;
        --container-padding: 0 15px;
    }
    
    .hero-content {
        flex-direction: column;
        text-align: center;
        margin-top: 80px;
        gap: 30px;
        padding: 0 15px;
    }
    
    .glitch-text {
        font-size: 28px;
        line-height: 1.2;
    }
    
    .hero-description {
        font-size: 16px;
        margin: 20px 0;
        padding: 0 10px;
    }
    
    .profile-image-new {
        width: 200px;
        height: 200px;
        border-radius: 12px;
    }
    
    .code-interface {
        margin: 10px auto;
        border-radius: 6px;
        max-width: calc(100vw - 30px);
        width: calc(100% - 30px);
        overflow-x: auto;
    }
    
    .code-text {
        font-size: 11px;
        padding: 10px;
    }
    
    .social-links {
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .social-link {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    
    .btn {
        padding: 12px 25px;
        margin: 5px;
        font-size: 14px;
    }
}

/* Tablet devices */
@media (min-width: 481px) and (max-width: 768px) {
    .hero-content {
        flex-direction: column;
        text-align: center;
        gap: 40px;
    }
    
    .glitch-text {
        font-size: 36px;
    }
    
    .profile-image-new {
        width: 240px;
        height: 240px;
        border-radius: 15px;
    }
}

/* Desktop-first improvements */
@media (min-width: 769px) {
    .hero-content {
        justify-content: center;
        gap: 60px;
        padding: 0 40px;
        align-items: center;
        text-align: center;
    }
    
    .hero-info {
        flex: 1;
        max-width: 600px;
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .hero-visual {
        flex: 0 0 auto;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .hero-description {
        text-align: center;
        max-width: 500px;
    }
    
    .social-links {
        justify-content: center;
    }
}

/* General mobile styles */
@media (max-width: 768px) {
    .hero-content {
        flex-direction: column;
        text-align: center;
        padding: 0 20px;
        gap: 30px;
        justify-content: center;
    }
    
    .hero-info,
    .hero-visual {
        max-width: 100%;
        width: 100%;
    }
    
    .section {
        padding: var(--section-padding);
    }
    
    .container {
        padding: var(--container-padding);
    }
    
    /* About section mobile */
    .about-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        max-width: 100%;
    }
    
    .about-card {
        min-height: 180px;
        padding: 1.5rem;
    }
    
    #about {
        padding: 60px 15px;
    }
    
    .section-title {
        font-size: 28px;
    }
    
    /* Skills section mobile */
    .skills-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        max-width: 100%;
    }
    
    .skill-category {
        padding: 20px 15px;
    }
    
    /* Projects section mobile */
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 25px;
        padding: 0 15px;
    }
    
    /* Technologies section mobile */
    .tech-main-title {
        font-size: 2rem;
        text-align: center;
    }
    
    .tech-subtitle {
        font-size: 1rem;
        text-align: center;
        padding: 0 15px;
    }
    
    .tech-header {
        padding: 0 15px;
        margin-bottom: 40px;
    }
    
    .tech-flow-container {
        padding: 30px 0;
    }
    
    .tech-flow {
        gap: 35px;
        animation: flowLeft 15s linear infinite;
        justify-content: center;
    }
    
    .tech-icon {
        font-size: 2.2rem;
    }
    
    #technologies {
        padding: 80px 15px;
        text-align: center;
    }
    
    /* Contact section mobile */
    .contact-content {
        grid-template-columns: 1fr;
        gap: 30px;
        margin-top: 40px;
    }
    
    .contact-info {
        text-align: center;
    }
    
    .contact-details {
        align-items: center;
    }
    
    .form-group input,
    .form-group textarea {
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* Large tablet and small desktop */
@media (min-width: 769px) and (max-width: 1024px) {
    .hero-content {
        gap: 40px;
    }
    
    .about-grid {
        grid-template-columns: repeat(2, 1fr);
        max-width: 800px;
    }
    
    .skills-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Extra small screens (landscape phones) */
@media (max-width: 480px) and (orientation: landscape) {
    .hero-content {
        margin-top: 60px;
        padding: 0 20px;
    }
    
    .profile-image-new {
        width: 160px;
        height: 160px;
    }
    
    .code-interface {
        max-width: calc(100vw - 40px);
        width: calc(100% - 40px);
        margin: 10px auto;
        overflow-x: auto;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .social-link,
    .nav-link,
    .project-card {
        min-height: 44px; /* Minimum touch target size */
    }
    
    .social-link {
        width: 50px;
        height: 50px;
    }
    
    /* Remove hover effects on touch devices */
    .btn:hover,
    .social-link:hover,
    .about-card:hover,
    .skill-category:hover,
    .project-card:hover {
        transform: none;
        box-shadow: initial;
    }
}

/* Print styles */
@media print {
    body::before,
    body::after,
    #bg-canvas,
    .loading-screen,
    .hamburger,
    .scroll-indicator,
    .btn,
    .social-links,
    #navbar {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .section {
        break-inside: avoid;
        page-break-inside: avoid;
    }
    
    .hero-description,
    .about-card,
    .skill-category {
        color: black !important;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: light) {
    /* Optional: Add light mode styles if needed */
}

/* Reduced transparency for better readability */
@media (prefers-reduced-transparency: reduce) {
    .code-interface,
    .about-card,
    .skill-category,
    .project-card,
    #navbar {
        backdrop-filter: none;
        background: rgba(0, 0, 0, 0.9);
    }
}
