/* ==========================================
   1. BASE RESET & VARIABLES
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-green: #00ff88;
    --secondary-green: #4ade80;
    --accent-blue: #3b82f6;
    --accent-purple: #8b5cf6;
    --dark-bg: #0f0f23;
    --darker-bg: #0a0a1a;
    --card-bg: #1a1a2e;
    --surface: #16213e;
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    --border: rgba(255, 255, 255, 0.1);
    --glow: 0 0 20px rgba(0, 255, 136, 0.3);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Inter', sans-serif;
    background: linear-gradient(135deg, var(--dark-bg), var(--darker-bg));
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    cursor: none; /* Hide default cursor */
}

/* Ensure default cursor on mobile devices */
@media (max-width: 1024px) {
    body { cursor: auto; }
    .cursor-dot, .cursor-outline { display: none; }
}

a, button, input, textarea, .glass-card, .project-card, .skill-card {
    cursor: none; /* Hide default cursor on interactables */
}

@media (max-width: 1024px) {
    a, button, input, textarea, .glass-card, .project-card, .skill-card { cursor: auto; }
}

/* Accessibility: Focus States for Keyboard Navigation */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
    outline: 2px solid var(--primary-green) !important;
    outline-offset: 4px !important;
    box-shadow: 0 0 15px rgba(0, 255, 136, 0.5);
    border-radius: 4px;
}

/* Custom Cursor Styles */
.cursor-dot, .cursor-outline {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 999999;
    pointer-events: none;
}

.cursor-dot {
    width: 8px;
    height: 8px;
    background: var(--primary-green);
    box-shadow: 0 0 10px var(--primary-green);
}

.cursor-outline {
    width: 40px;
    height: 40px;
    border: 2px solid rgba(0, 255, 136, 0.5);
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

.cursor-hover {
    width: 60px;
    height: 60px;
    background-color: rgba(0, 255, 136, 0.1);
    border-color: transparent;
}

/* Missing Fluid Canvas Base CSS */
.fluid-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* Particle Background */
.background-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    pointer-events: none;
    will-change: transform;
}

/* Cyberpunk Glitch Effect */
.glitch { position: relative; }
.glitch::before, .glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary-green) 50%, var(--accent-blue) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0;
    pointer-events: none;
}
.glitch:hover::before {
    opacity: 0.8;
    left: 3px;
    text-shadow: -2px 0 var(--accent-purple);
    clip-path: inset(24% 0 61% 0);
    animation: glitch-anim 0.3s infinite linear alternate-reverse;
}
.glitch:hover::after {
    opacity: 0.8;
    left: -3px;
    text-shadow: -2px 0 var(--accent-blue);
    clip-path: inset(12% 0 12% 0);
    animation: glitch-anim 0.3s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% { clip-path: inset(20% 0 80% 0); transform: translate(-2px, 2px); }
    20% { clip-path: inset(60% 0 10% 0); transform: translate(2px, -2px); }
    40% { clip-path: inset(40% 0 50% 0); transform: translate(2px, 2px); }
    60% { clip-path: inset(80% 0 5% 0); transform: translate(-2px, -2px); }
    80% { clip-path: inset(10% 0 70% 0); transform: translate(2px, 2px); }
    100% { clip-path: inset(30% 0 50% 0); transform: translate(-2px, -2px); }
}

/* Overdrive and Cyber Theme Variables */
body.theme-overdrive {
    --primary-green: #ff00ff;
    --secondary-green: #ff66ff;
    --accent-blue: #00ffff;
    --accent-purple: #ff0055;
    --glow: 0 0 20px rgba(255, 0, 255, 0.3);
}

body.theme-cyber {
    --primary-green: #fcee0a;
    --secondary-green: #ffb800;
    --accent-blue: #00ffcc;
    --accent-purple: #ff003c;
    --glow: 0 0 20px rgba(252, 238, 10, 0.3);
}

.shake-effect { animation: screenShake 0.4s cubic-bezier(.36,.07,.19,.97) both; }

@keyframes screenShake {
    10%, 90% { transform: translate3d(-2px, 2px, 0); }
    20%, 80% { transform: translate3d(4px, -2px, 0); }
    30%, 50%, 70% { transform: translate3d(-8px, 4px, 0); }
    40%, 60% { transform: translate3d(8px, -4px, 0); }
}

/* Theme Switcher */
.theme-switcher-container {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 1001;
    width: 40px;
    height: 60px;
}

@media (max-width: 768px) {
    .theme-switcher-container {
        top: 5.5rem; 
        right: 1rem;
        transform: scale(0.85);
        transform-origin: top right;
    }
}

.danger-cover {
    position: absolute;
    top: -10px; left: 0; width: 100%; height: 50px;
    border: 2px solid #ff4444; background: rgba(255, 68, 68, 0.2);
    backdrop-filter: blur(5px); transform-origin: top;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer; z-index: 2;
    border-radius: 4px;
}
.danger-cover.open { transform: rotateX(100deg); }
.theme-switch-btn {
    position: absolute; bottom: 0; left: 5px; width: 30px; height: 50px;
    background: #222; border-radius: 5px; cursor: pointer;
    box-shadow: inset 0 0 10px #000; border: 2px solid #444;
}
.theme-switch-btn::after {
    content: ''; position: absolute; bottom: 5px; left: 5px; width: 16px; height: 20px;
    background: #ff4444; border-radius: 3px; transition: transform 0.2s;
    box-shadow: inset 0 0 5px rgba(0,0,0,0.5);
}
.theme-switch-btn.on::after { transform: translateY(-20px); background: var(--primary-green); box-shadow: 0 0 10px var(--primary-green); }

/* Hacker Console Overlay */
.game-console {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.95); z-index: 20000; display: flex;
    align-items: center; justify-content: center; opacity: 0; pointer-events: none;
    transition: opacity 0.3s;
}
.game-console.active { opacity: 1; pointer-events: all; cursor: auto; }
.arcade-screen {
    background: #050505; border: 2px solid var(--primary-green);
    padding: 30px; border-radius: 10px; text-align: center;
    box-shadow: 0 0 40px rgba(0, 255, 136, 0.2);
}
.arcade-header { color: var(--primary-green); margin-bottom: 20px; font-family: monospace; font-size: 1.2rem; text-shadow: 0 0 5px var(--primary-green); }
#snakeCanvas { background: #000; border: 1px solid rgba(255, 255, 255, 0.1); box-shadow: inset 0 0 20px #000; }
.game-message { color: var(--accent-blue); font-family: monospace; margin-top: 15px; font-size: 1.1rem; min-height: 24px; text-shadow: 0 0 5px var(--accent-blue); }

/* Bulletproof Pure CSS Loader */
.loading-screen {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: var(--darker-bg); display: flex; align-items: center;
    justify-content: center; z-index: 99999;
    animation: hideLoader 0.5s ease-in 2.5s forwards;
}

@keyframes hideLoader {
    0% { opacity: 1; visibility: visible; }
    100% { opacity: 0; visibility: hidden; pointer-events: none; z-index: -100; display: none; }
}

.scanner-box {
    width: 250px; height: 60px; border: 2px solid rgba(0, 255, 136, 0.3);
    border-radius: 8px; display: flex; align-items: center; justify-content: center;
    position: relative; overflow: hidden; background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.1);
}

.scanner-text {
    color: var(--primary-green); font-family: 'Courier New', monospace;
    font-size: 1.5rem; font-weight: bold; letter-spacing: 5px; z-index: 2;
    text-shadow: 0 0 10px var(--primary-green); animation: textPulse 1s infinite alternate;
}

.scanner-laser {
    position: absolute; top: 0; left: -100%; width: 50%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 136, 0.8), transparent);
    z-index: 1; animation: laserScan 1.5s ease-in-out infinite;
}

@keyframes laserScan { 0% { left: -100%; } 100% { left: 200%; } }
@keyframes textPulse { 0% { opacity: 0.7; } 100% { opacity: 1; } }

/* Scrollytelling Reveal Animation */
.reveal-element {
    opacity: 0;
    transform: translateY(80px) rotateX(15deg) scale(0.95);
    transition: all 0.9s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    will-change: transform, opacity;
}

.reveal-element.show {
    opacity: 1;
    transform: translateY(0) rotateX(0deg) scale(1);
}

/* Animated Background Pattern */
body::before {
    content: '';
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: 
        radial-gradient(circle at 25% 25%, rgba(0, 255, 136, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(59, 130, 246, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 75% 25%, rgba(139, 92, 246, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 25% 75%, rgba(0, 255, 136, 0.05) 0%, transparent 50%);
    z-index: -3;
    animation: floatBg 30s ease-in-out infinite;
}

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

/* Navigation */
nav {
    position: fixed; top: 2rem; left: 50%; transform: translateX(-50%);
    z-index: 1000; background: rgba(26, 26, 46, 0.8); backdrop-filter: blur(20px);
    border: 1px solid var(--border); border-radius: 50px; padding: 1rem 2rem;
    box-shadow: var(--shadow); width: 90%; max-width: 1000px;
}

.nav-container { display: flex; align-items: center; justify-content: space-between; }
.logo { font-size: 1.2rem; font-weight: 800; background: linear-gradient(135deg, var(--primary-green), var(--accent-blue)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.nav-links { display: flex; list-style: none; gap: 2rem; }
.nav-links a { text-decoration: none; color: var(--text-secondary); font-weight: 500; font-size: 0.9rem; transition: all 0.3s ease; padding: 0.5rem 1rem; border-radius: 20px; position: relative; }
.nav-links a:hover, .nav-links a.active { color: var(--primary-green); background: rgba(0, 255, 136, 0.1); }
.mobile-toggle { display: none; background: none; border: none; color: var(--text-primary); font-size: 1.2rem; cursor: pointer; }

/* Hero Section */
.hero { min-height: 100vh; display: flex; align-items: center; justify-content: center; text-align: center; padding: 0 2rem; position: relative; }
.hero-content { max-width: 1200px; animation: fadeInUp 1s ease-out; display: flex; flex-direction: column; align-items: center; z-index: 1; }
.hero-title { font-size: clamp(2.5rem, 8vw, 5rem); font-weight: 900; line-height: 1.1; margin-bottom: 1.5rem; background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary-green) 50%, var(--accent-blue) 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-subtitle { font-size: clamp(1.2rem, 3vw, 1.8rem); color: var(--text-secondary); font-weight: 300; margin-bottom: 2rem; }
.hero-description { font-size: 1.1rem; color: var(--text-muted); max-width: 600px; margin: 0 auto 3rem; line-height: 1.8; }
.cta-group { display: flex; gap: 1.5rem; justify-content: center; margin-bottom: 4rem; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; gap: 0.7rem; padding: 1rem 2rem; border-radius: 50px; text-decoration: none; font-weight: 600; font-size: 1rem; transition: all 0.3s ease; border: none; cursor: pointer; position: relative; overflow: hidden; }
.btn-primary { background: linear-gradient(135deg, var(--primary-green), var(--secondary-green)); color: var(--darker-bg); box-shadow: var(--glow); }
.btn-secondary { background: rgba(255, 255, 255, 0.1); color: var(--text-primary); border: 1px solid var(--border); backdrop-filter: blur(10px); }
.btn:hover { transform: translateY(-3px); }
.btn-primary:hover { box-shadow: 0 0 30px rgba(0, 255, 136, 0.5); }
.btn-secondary:hover { background: rgba(255, 255, 255, 0.15); }

/* Stats Grid */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; max-width: 800px; width: 100%; margin: 0 auto; }
.stat-card { background: rgba(26, 26, 46, 0.6); backdrop-filter: blur(20px); border: 1px solid var(--border); border-radius: 20px; padding: 2rem; text-align: center; transition: all 0.3s ease; }
.stat-card:hover { transform: translateY(-5px); border-color: var(--primary-green); box-shadow: var(--glow); }
.stat-number { font-size: 2.5rem; font-weight: 800; background: linear-gradient(135deg, var(--primary-green), var(--accent-blue)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; display: block; margin-bottom: 0.5rem; }
.stat-label { color: var(--text-secondary); font-size: 0.9rem; font-weight: 500; }

/* Home Featured Project (Top Project Card UI Fix) */
.home-featured-project {
    display: flex;
    align-items: stretch;
    text-align: left;
    padding: 0;
    overflow: hidden;
    background: rgba(10, 10, 26, 0.6);
    border-radius: 24px;
    border: 1px solid var(--border);
    backdrop-filter: blur(20px);
}
.home-featured-image {
    flex: 1;
    min-width: 50%;
    position: relative;
    overflow: hidden;
}
.home-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.home-featured-project:hover .home-featured-image img {
    transform: scale(1.08);
}
.home-featured-content {
    flex: 1;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: linear-gradient(135deg, rgba(26,26,46,0.8), rgba(10,10,26,0.9));
}
.home-featured-content .badge {
    background: rgba(0, 255, 136, 0.15);
    color: var(--primary-green);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 1px;
    border: 1px solid rgba(0, 255, 136, 0.3);
    display: inline-block;
    margin-bottom: 1.5rem;
    align-self: flex-start;
}
.home-featured-content h3 { font-size: 2.2rem; margin-bottom: 0.5rem; color: var(--text-primary); font-weight: 800; }
.home-featured-content .subtitle { color: var(--accent-blue); font-weight: 600; margin-bottom: 1.5rem; font-size: 1.1rem; }
.home-featured-content p { color: var(--text-secondary); margin-bottom: 2rem; line-height: 1.7; font-size: 1.05rem; }
.home-featured-content .tech-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2rem; }
.home-featured-content .tech-tag { background: rgba(255, 255, 255, 0.05); color: var(--text-primary); padding: 5px 12px; border-radius: 8px; font-size: 0.85rem; border: 1px solid var(--border); }

@media (max-width: 768px) {
    .home-featured-project { flex-direction: column; }
    .home-featured-image { min-height: 250px; min-width: 100%; }
    .home-featured-image img { position: relative; }
    .home-featured-content { padding: 2rem; }
}

/* Page Sections */
.page-section { display: none; min-height: 100vh; padding: 8rem 2rem 4rem; position: relative; z-index: 1;}
.page-section.active { display: block; animation: slideIn 0.6s ease-out; }
.container { max-width: 1200px; margin: 0 auto; }
.section-title { font-size: 2.5rem; font-weight: 800; text-align: center; margin-bottom: 3rem; background: linear-gradient(135deg, var(--primary-green), var(--accent-blue)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* Cards */
.glass-card { background: rgba(26, 26, 46, 0.6); backdrop-filter: blur(20px); border: 1px solid var(--border); border-radius: 24px; padding: 2.5rem; transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease; margin-bottom: 2rem; will-change: transform; }
.glass-card:hover { border-color: var(--primary-green); box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4); }

/* Weather Node Holographic UI Fix */
.weather-node {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(26, 26, 46, 0.5);
    border: 1px solid var(--border);
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}
.weather-node:hover { border-color: var(--primary-green); box-shadow: 0 0 20px rgba(0, 255, 136, 0.1); }
.weather-node::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-green), transparent);
    animation: scanline 3s linear infinite;
}
@keyframes scanline { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
.weather-info h4 { font-size: 0.9rem; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.3rem;}
.weather-info p { font-size: 2.2rem; font-weight: 800; color: var(--text-primary); margin: 0.2rem 0; text-shadow: 0 0 15px rgba(255,255,255,0.2); }
.weather-info span { font-size: 0.85rem; color: var(--primary-green); font-family: 'Courier New', monospace; font-weight: 600; }
.weather-hologram { position: relative; width: 70px; height: 70px; display: flex; align-items: center; justify-content: center; }
.weather-hologram i { font-size: 3rem; z-index: 2; animation: floatIcon 3s ease-in-out infinite; }
@keyframes floatIcon { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.hologram-base { position: absolute; bottom: -15px; width: 50px; height: 12px; background: radial-gradient(ellipse at center, var(--primary-green) 0%, transparent 70%); opacity: 0.5; animation: pulseBase 3s ease-in-out infinite; }
@keyframes pulseBase { 0%, 100% { transform: scale(1); opacity: 0.5; } 50% { transform: scale(1.4); opacity: 0.2; } }
.weather-day i { color: #fcee0a; text-shadow: 0 0 25px rgba(252, 238, 10, 0.6); }
.weather-day .hologram-base { background: radial-gradient(ellipse at center, #fcee0a 0%, transparent 70%); }
.weather-night i { color: #00ffff; text-shadow: 0 0 25px rgba(0, 255, 255, 0.6); }
.weather-night .hologram-base { background: radial-gradient(ellipse at center, #00ffff 0%, transparent 70%); }

/* Skills Section */
.globe-tooltip-btn { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); background: rgba(0, 255, 136, 0.15); border: 2px dashed var(--primary-green); padding: 10px 25px; border-radius: 8px; color: var(--primary-green); font-family: 'Courier New', monospace; font-weight: bold; letter-spacing: 2px; text-transform: uppercase; pointer-events: auto; z-index: 10; text-shadow: 0 0 10px var(--primary-green); box-shadow: inset 0 0 10px rgba(0,255,136,0.3); transition: all 0.3s ease; }
.globe-tooltip-btn:hover { background: rgba(0, 255, 136, 0.3); box-shadow: inset 0 0 20px rgba(0,255,136,0.5), 0 0 15px rgba(0,255,136,0.4); transform: translateX(-50%) scale(1.05); }
.skills-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 2rem; margin-top: 2rem; }
.skill-card { background: rgba(26, 26, 46, 0.6); backdrop-filter: blur(20px); border: 1px solid var(--border); border-radius: 24px; padding: 2rem; text-align: center; transition: transform 0.4s ease, border-color 0.4s ease; position: relative; overflow: hidden; will-change: transform; }
.skill-card::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(0, 255, 136, 0.1), transparent); transition: left 0.8s ease; }
.skill-card:hover::before { left: 100%; }
.skill-card:hover { border-color: var(--primary-green); }
.skill-icon { font-size: 3rem; background: linear-gradient(135deg, var(--primary-green), var(--accent-purple)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; margin-bottom: 1.5rem; }
.skill-title { font-size: 1.2rem; font-weight: 700; color: var(--text-primary); margin-bottom: 1rem; }
.skill-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; }
.skill-tag { background: rgba(0, 255, 136, 0.15); border: 1px solid rgba(0, 255, 136, 0.3); color: var(--primary-green); padding: 0.3rem 0.8rem; border-radius: 15px; font-size: 0.85rem; font-weight: 500; }

/* Redesigned Bento Box Projects Grid */
.bento-projects-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 1.5rem;
    margin-top: 3rem;
    grid-auto-rows: 350px;
}

.bento-card {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--card-bg);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    cursor: none;
    grid-column: span 12; /* Default for mobile */
}

/* Dynamic Asymmetric Grid Layout for Desktop */
@media (min-width: 768px) {
    .bento-card:nth-child(1) { grid-column: span 8; } /* Large featured top left */
    .bento-card:nth-child(2) { grid-column: span 4; } /* Side compact top right */
    .bento-card:nth-child(3) { grid-column: span 4; } /* 3 equal cols below */
    .bento-card:nth-child(4) { grid-column: span 4; }
    .bento-card:nth-child(5) { grid-column: span 4; }
}

@media (min-width: 1024px) {
     .bento-projects-grid { gap: 2rem; grid-auto-rows: 400px; }
}

.bento-card:hover {
    transform: translateY(-8px) scale(1.01);
    border-color: var(--primary-green);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5), inset 0 0 20px rgba(0, 255, 136, 0.1);
    z-index: 10;
}

.bento-bg {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover; z-index: 1; transition: transform 0.8s ease, filter 0.8s ease, opacity 0.5s;
    filter: brightness(0.5) grayscale(20%) contrast(1.2);
    opacity: 0.8;
}

.bento-card:hover .bento-bg { 
    transform: scale(1.08); 
    filter: brightness(0.3) grayscale(0%);
    opacity: 1;
}

.bento-overlay { 
    position: absolute; inset: 0; 
    background: linear-gradient(to top, rgba(10,10,26,0.95) 0%, rgba(10,10,26,0.6) 50%, transparent 100%); 
    z-index: 2; 
}

.bento-content { 
    position: relative; z-index: 3; padding: 2.5rem; 
    transform: translateY(80px); 
    transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275); 
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.bento-card:hover .bento-content { transform: translateY(0); }

.bento-badge { 
    background: rgba(0, 255, 136, 0.1); color: var(--primary-green); 
    padding: 6px 14px; border-radius: 20px; font-size: 0.75rem; 
    font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; 
    margin-bottom: auto; /* Push badge to top */
    align-self: flex-start;
    backdrop-filter: blur(10px); border: 1px solid rgba(0, 255, 136, 0.3); 
    transition: box-shadow 0.3s;
}

.bento-card:hover .bento-badge { box-shadow: 0 0 15px rgba(0, 255, 136, 0.4); }

.bento-title { 
    font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 800; color: var(--text-primary); 
    margin-bottom: 0.5rem; text-shadow: 0 2px 10px rgba(0,0,0,0.8); 
    margin-top: 1rem;
}

.bento-desc { 
    color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 1.5rem; 
    line-height: 1.6; opacity: 0; transition: opacity 0.5s ease; 
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; 
}

.bento-card:hover .bento-desc { opacity: 1; }

.bento-tech { 
    display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: 1.5rem; 
    opacity: 0; transform: translateY(10px); transition: all 0.5s ease 0.1s; 
}

.bento-card:hover .bento-tech { opacity: 1; transform: translateY(0); }

.bento-tech-tag { 
    background: rgba(255, 255, 255, 0.05); color: var(--text-primary); 
    font-size: 0.75rem; padding: 5px 12px; border-radius: 8px; 
    backdrop-filter: blur(5px); border: 1px solid rgba(255,255,255,0.1); 
}

.bento-links { 
    display: flex; gap: 1rem; opacity: 0; transform: translateY(10px); 
    transition: all 0.5s ease 0.2s; 
}

.bento-card:hover .bento-links { opacity: 1; transform: translateY(0); }

.bento-link { 
    display: flex; align-items: center; gap: 8px; color: var(--darker-bg); 
    background: var(--primary-green); padding: 10px 20px; border-radius: 12px; 
    font-weight: 700; font-size: 0.85rem; text-decoration: none; transition: all 0.3s; 
}

.bento-link:hover { 
    background: var(--text-primary); transform: translateY(-2px); 
    box-shadow: 0 5px 15px rgba(0,255,136,0.4); 
}

.bento-link.secondary { 
    background: rgba(255, 255, 255, 0.05); color: var(--text-primary); 
    border: 1px solid rgba(255,255,255,0.2); 
}

.bento-link.secondary:hover { 
    background: rgba(255, 255, 255, 0.15); box-shadow: 0 5px 15px rgba(255,255,255,0.1); 
}

/* About Section */
.about-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 3rem; margin-top: 2rem; }
.profile-section { position: sticky; top: 120px; height: fit-content; }
.profile-avatar { width: 180px; height: 180px; background: linear-gradient(135deg, var(--primary-green), var(--accent-blue)); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 4rem; color: var(--darker-bg); margin: 0 auto 2rem; position: relative; }
.profile-avatar::before { content: ''; position: absolute; inset: -4px; background: linear-gradient(135deg, var(--primary-green), var(--accent-blue)); border-radius: 50%; z-index: -1; filter: blur(8px); opacity: 0.7; }
.timeline { position: relative; padding-left: 2rem; }
.timeline::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: linear-gradient(to bottom, var(--primary-green), var(--accent-blue)); }
.timeline-item { position: relative; margin-bottom: 2.5rem; padding-left: 2rem; transition: all 0.3s ease; }
.timeline-item:hover { transform: translateX(10px); }
.timeline-item::before { content: ''; position: absolute; left: -6px; top: 0.5rem; width: 12px; height: 12px; background: var(--darker-bg); border: 2px solid var(--primary-green); border-radius: 50%; box-shadow: 0 0 10px rgba(0, 255, 136, 0.5); transition: all 0.3s ease; }
.timeline-item:hover::before { background: var(--primary-green); box-shadow: 0 0 20px var(--primary-green); }
.timeline-date { color: var(--primary-green); font-size: 0.9rem; font-weight: 600; margin-bottom: 0.5rem; }
.timeline-title { font-size: 1.1rem; font-weight: 700; color: var(--text-primary); margin-bottom: 0.3rem; }
.timeline-location { color: var(--text-secondary); font-style: italic; margin-bottom: 0.5rem; }

/* Contact Section */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; margin-top: 2rem; }
.contact-info { display: flex; flex-direction: column; gap: 1.5rem; }
.contact-item { display: flex; align-items: center; gap: 1rem; padding: 1.5rem; background: rgba(26, 26, 46, 0.6); border: 1px solid var(--border); border-radius: 20px; transition: all 0.3s ease; }
.contact-item:hover { border-color: var(--primary-green); transform: translateX(5px); }
.contact-icon { width: 50px; height: 50px; background: linear-gradient(135deg, var(--primary-green), var(--accent-blue)); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--darker-bg); font-size: 1.2rem; }
.contact-form { background: rgba(26, 26, 46, 0.6); backdrop-filter: blur(20px); border: 1px solid var(--border); border-radius: 24px; padding: 2.5rem; }
.form-group { margin-bottom: 1.5rem; }
.form-label { display: block; color: var(--text-primary); font-weight: 600; margin-bottom: 0.5rem; font-size: 0.9rem; }
.form-input { width: 100%; padding: 1rem; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border); border-radius: 15px; color: var(--text-primary); font-size: 1rem; transition: all 0.3s ease; }
.form-input:focus { outline: none; border-color: var(--primary-green); box-shadow: 0 0 0 3px rgba(0, 255, 136, 0.1); }
.form-input::placeholder { color: var(--text-muted); }

/* Social Links */
.social-grid { display: flex; justify-content: center; gap: 1rem; margin: 1.5rem 0 2rem; }
.social-link { width: 50px; height: 50px; background: rgba(26, 26, 46, 0.6); border: 1px solid var(--border); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); text-decoration: none; font-size: 1.3rem; transition: all 0.3s ease; }
.social-link:hover { transform: translateY(-3px); border-color: var(--primary-green); color: var(--primary-green); box-shadow: var(--glow); }

/* Animations */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }

/* GitHub Cityscape Tooltip */
.city-tooltip {
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    background: rgba(10, 10, 26, 0.95);
    border: 1px solid var(--primary-green);
    padding: 10px 15px;
    border-radius: 8px;
    color: var(--text-primary);
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.2s ease;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5), 0 0 15px rgba(0, 255, 136, 0.1);
    backdrop-filter: blur(10px);
    will-change: transform;
}
.city-tooltip strong { color: var(--primary-green); display: block; margin-bottom: 4px; font-size: 0.95rem; }
.city-tooltip small { color: var(--text-secondary); }

/* Cinematic View Transitions */
::view-transition-old(root),
::view-transition-new(root) {
    animation-duration: 0.6s;
    animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Matrix Overlay */
.matrix-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #000; z-index: 10000; display: flex; justify-content: center; align-items: center; opacity: 0; pointer-events: none; transition: opacity 0.5s; }
.matrix-overlay.active { opacity: 1; pointer-events: all; cursor: pointer; }
#matrixCanvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; opacity: 0.4; }
.terminal-text { position: relative; z-index: 2; color: #0f0; font-family: 'Courier New', Courier, monospace; font-size: clamp(1.2rem, 3vw, 2rem); text-shadow: 0 0 10px #0f0; text-align: left; min-width: 300px; }

/* Music Player */
.music-player-container { position: fixed; bottom: 2rem; right: 2rem; z-index: 1000; display: flex; flex-direction: column; align-items: flex-end; gap: 1rem; }
@media (min-width: 769px) {
    .music-toggle-btn { display: none !important; }
    .music-panel { transform: none !important; opacity: 1 !important; pointer-events: all !important; position: fixed !important; bottom: 2rem !important; right: 2rem !important; }
}
@media (max-width: 768px) {
    .music-toggle-btn { width: 100px; height: 35px; border-radius: 20px; background: rgba(26, 26, 46, 0.8); backdrop-filter: blur(20px); border: 1px solid var(--border); cursor: pointer; box-shadow: var(--glow); transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); display: flex; align-items: center; justify-content: space-around; padding: 0 10px; }
    .music-toggle-btn i { display: none; }
    .music-toggle-btn::before { content: ''; width: 40px; height: 4px; background: var(--primary-green); border-radius: 2px; box-shadow: 0 0 10px var(--primary-green); }
    .music-toggle-btn:hover, .music-toggle-btn:active { width: 120px; background: rgba(0, 255, 136, 0.15); }
}
.music-panel { width: 280px; padding: 1.5rem !important; margin-bottom: 0 !important; transform: translateY(120%) scale(0.9); opacity: 0; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); pointer-events: none; position: absolute; bottom: 50px; right: 0; background: rgba(26, 26, 46, 0.95) !important; backdrop-filter: blur(25px) !important; box-shadow: 0 20px 50px rgba(0,0,0,0.5) !important; border-radius: 12px; border: 1px solid var(--border);}
.music-panel.active { transform: translateY(0) scale(1); opacity: 1; pointer-events: all; }
@media (max-width: 768px) { .music-player-container:has(.music-panel.active) .music-toggle-btn { opacity: 0; pointer-events: none; transform: translateY(20px); } }
.music-info { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.2rem; border-bottom: 1px solid var(--border); padding-bottom: 1rem; }
.rotating-disc { font-size: 2.5rem; color: var(--primary-green); animation: spin 4s linear infinite; animation-play-state: paused; }
.rotating-disc.playing { animation-play-state: running; }
@keyframes spin { 100% { transform: rotate(360deg); } }
.track-details { display: flex; flex-direction: column; overflow: hidden; }
.track-name { color: var(--text-primary); font-weight: 700; font-size: 0.95rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track-artist { color: var(--primary-green); font-size: 0.75rem; }
.music-controls { display: flex; justify-content: center; align-items: center; gap: 1.2rem; margin-bottom: 1rem; }
.music-btn { background: none; border: none; color: var(--text-secondary); font-size: 1.1rem; cursor: pointer; transition: color 0.3s ease, transform 0.2s ease; display: flex; align-items: center; justify-content: center; }
.music-btn:hover { color: var(--primary-green); transform: scale(1.1); }
.play-btn { width: 40px; height: 40px; border-radius: 50%; background: rgba(255, 255, 255, 0.1); color: var(--text-primary); display: flex; align-items: center; justify-content: center; border: 1px solid var(--border); }
.play-btn:hover { background: var(--primary-green); color: var(--darker-bg); }
.volume-control { display: flex; align-items: center; gap: 0.8rem; color: var(--text-muted); font-size: 0.8rem; }
.volume-control input[type="range"] { flex: 1; -webkit-appearance: none; height: 4px; background: rgba(255, 255, 255, 0.1); border-radius: 2px; outline: none; }
.volume-control input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; border-radius: 50%; background: var(--primary-green); cursor: pointer; }

/* AI Terminal */
.ai-container { position: fixed; bottom: 2rem; left: 2rem; z-index: 1000; }
.ai-orb-btn { width: 60px; height: 60px; border-radius: 50%; background: rgba(26, 26, 46, 0.8); border: 1px solid rgba(0, 255, 136, 0.5); cursor: pointer; position: relative; display: flex; align-items: center; justify-content: center; transition: transform 0.3s ease; }
.ai-orb-btn:hover { transform: scale(1.1); }
.orb-core { width: 20px; height: 20px; background: var(--primary-green); border-radius: 50%; box-shadow: 0 0 20px var(--primary-green); animation: orbPulse 2s infinite alternate; }
.orb-ring { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); border-radius: 50%; border: 1px solid rgba(0, 255, 136, 0.3); }
.orb-ring-1 { width: 40px; height: 40px; animation: ping 2s infinite; }
.orb-ring-2 { width: 50px; height: 50px; animation: ping 2.5s infinite 0.5s; }
.orb-icon { position: absolute; color: var(--darker-bg); font-size: 1rem; z-index: 2; }
@keyframes orbPulse { 0% { transform: scale(0.8); opacity: 0.8; box-shadow: 0 0 10px var(--primary-green); } 100% { transform: scale(1.2); opacity: 1; box-shadow: 0 0 30px var(--primary-green); } }
@keyframes ping { 0% { transform: translate(-50%, -50%) scale(0.5); opacity: 1; } 100% { transform: translate(-50%, -50%) scale(1.5); opacity: 0; } }
.ai-chat-panel { position: absolute; bottom: 80px; left: 0; width: 320px; background: rgba(26, 26, 46, 0.95) !important; backdrop-filter: blur(25px) !important; padding: 1.5rem !important; border-radius: 20px; box-shadow: 0 20px 50px rgba(0,0,0,0.5) !important; transform: translateY(120%) scale(0.9) rotate(-5deg); opacity: 0; pointer-events: none; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); display: flex; flex-direction: column; gap: 1rem; transform-origin: bottom left; border: 1px solid var(--border); }
.ai-chat-panel.active { transform: translateY(0) scale(1) rotate(0deg); opacity: 1; pointer-events: all; }
.ai-chat-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border); padding-bottom: 0.5rem; color: var(--text-primary); }
.ai-close-btn { background: none; border: none; color: var(--text-secondary); cursor: pointer; transition: color 0.3s; }
.ai-close-btn:hover { color: #ff4444; }
.ai-chat-box { max-height: 200px; overflow-y: auto; display: flex; flex-direction: column; gap: 0.8rem; padding-right: 0.5rem; }
.ai-chat-box::-webkit-scrollbar { width: 4px; }
.ai-chat-box::-webkit-scrollbar-thumb { background: rgba(0,255,136,0.3); border-radius: 2px; }
.chat-msg { display: flex; gap: 0.5rem; font-size: 0.85rem; line-height: 1.4; animation: fadeInUp 0.3s ease-out; }
.ai-msg .msg-content { background: rgba(0, 255, 136, 0.1); color: var(--text-primary); padding: 0.6rem 0.8rem; border-radius: 0 10px 10px 10px; border-left: 2px solid var(--primary-green); }
.user-msg { flex-direction: row-reverse; }
.user-msg .msg-content { background: rgba(59, 130, 246, 0.15); color: var(--text-primary); padding: 0.6rem 0.8rem; border-radius: 10px 0 10px 10px; border-right: 2px solid var(--accent-blue); text-align: right; }
.ai-prompts { display: flex; flex-direction: column; gap: 0.5rem; }
.ai-prompt-btn { background: rgba(0,255,136,0.1); border: 1px solid rgba(0,255,136,0.3); color: var(--primary-green); padding: 5px 10px; border-radius: 10px; font-size: 0.8rem; cursor: pointer; transition: all 0.3s; }
.ai-prompt-btn:hover { background: var(--primary-green); color: var(--darker-bg); }

/* Secrets Panel */
.secrets-container { position: fixed; top: 50%; left: 2rem; transform: translateY(-50%); z-index: 1000; }
@media (max-width: 768px) { .secrets-container { left: 1rem; } }
.secrets-orb-btn { width: 50px; height: 50px; border-radius: 50%; background: rgba(26, 26, 46, 0.8); border: 1px solid rgba(139, 92, 246, 0.5); cursor: pointer; position: relative; display: flex; align-items: center; justify-content: center; transition: transform 0.3s ease; }
.secrets-orb-btn:hover { transform: scale(1.1); }
.secrets-orb-btn .orb-core { background: var(--accent-purple); box-shadow: 0 0 20px var(--accent-purple); animation: orbPulsePurple 2s infinite alternate; }
@keyframes orbPulsePurple { 0% { transform: scale(0.8); opacity: 0.8; box-shadow: 0 0 10px var(--accent-purple); } 100% { transform: scale(1.2); opacity: 1; box-shadow: 0 0 30px var(--accent-purple); } }
.secrets-panel { position: absolute; top: -50px; left: 70px; width: 320px; background: rgba(26, 26, 46, 0.95) !important; backdrop-filter: blur(25px) !important; padding: 1.5rem !important; border-radius: 20px; border: 1px solid var(--border); box-shadow: 0 20px 50px rgba(0,0,0,0.5) !important; transform: translateX(-20px) scale(0.9); opacity: 0; pointer-events: none; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); transform-origin: left center; }
.secrets-panel.active { transform: translateX(0) scale(1); opacity: 1; pointer-events: all; }
@media (max-width: 480px) { .secrets-panel { width: 280px; } }

/* Responsive Layouts */
@media (max-width: 1024px) {
    .about-grid, .contact-grid { grid-template-columns: 1fr; gap: 2rem; }
    .profile-section { position: static; }
}
@media (max-width: 768px) {
    nav { top: 1rem; left: 1rem; right: 1rem; width: auto; transform: none; padding: 1rem; }
    .nav-links { display: none; }
    .nav-links.active { display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0; background: rgba(26, 26, 46, 0.98); border: 1px solid var(--border); border-radius: 20px; padding: 1rem; margin-top: 0.5rem; gap: 0.5rem; backdrop-filter: blur(20px); box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
    .mobile-toggle { display: block; }
    .hero-title { font-size: 2.5rem; }
    .cta-group { flex-direction: column; align-items: center; }
    .stats-grid { grid-template-columns: repeat(3, 1fr); gap: 1rem; }
    @media (max-width: 480px) { .stats-grid { grid-template-columns: 1fr; } }
    .skills-grid, .projects-grid { grid-template-columns: 1fr; }
    .page-section { padding: 6rem 1rem 2rem; }
}