* { margin: 0; padding: 0; box-sizing: border-box; }
    html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
    body { 
      background-color: #0a0a0f; 
      color: #e2e8f0; 
      font-family: 'Inter', system-ui, sans-serif;
      overflow-x: hidden;
      -webkit-tap-highlight-color: transparent;
    }
    ::selection { background: rgba(0, 212, 255, 0.3); color: #fff; }
    ::-webkit-scrollbar { width: 4px; }
    ::-webkit-scrollbar-track { background: #0a0a0f; }
    ::-webkit-scrollbar-thumb { background: linear-gradient(180deg, #00d4ff, #a855f7); border-radius: 2px; }

    .glass-panel {
      background: rgba(10, 10, 15, 0.7);
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      border: 1px solid rgba(255, 255, 255, 0.05);
    }
    .glass-card {
      background: rgba(255, 255, 255, 0.03);
      backdrop-filter: blur(16px);
      -webkit-backdrop-filter: blur(16px);
      border: 1px solid rgba(255, 255, 255, 0.06);
      transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }
    .glass-card:hover, .glass-card:active {
      background: rgba(255, 255, 255, 0.06);
      border-color: rgba(0, 212, 255, 0.2);
      box-shadow: 0 0 40px rgba(0, 212, 255, 0.1);
    }
    .gradient-text {
      background: linear-gradient(135deg, #00d4ff, #a855f7, #ec4899);
      -webkit-background-clip: text;
      -webkit-text-fill-color: transparent;
      background-clip: text;
    }
    .holo-grid {
      background-image: 
        linear-gradient(rgba(0, 212, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 212, 255, 0.03) 1px, transparent 1px);
      background-size: 60px 60px;
    }
    .scan-line {
      position: absolute; left: 0; right: 0; height: 2px;
      background: linear-gradient(90deg, transparent, rgba(0, 212, 255, 0.5), transparent);
      animation: scan 4s linear infinite;
      pointer-events: none;
    }
    @keyframes scan { 0% { top: 0%; } 100% { top: 100%; } }
    @keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-20px); } }
    @keyframes pulse-glow { 0%, 100% { opacity: 0.4; } 50% { opacity: 0.8; } }
    @keyframes spin-slow { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
    @keyframes spin-reverse { from { transform: rotate(360deg); } to { transform: rotate(0deg); } }
    @keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
    @keyframes fadeInUp {
      from { opacity: 0; transform: translateY(40px); }
      to { opacity: 1; transform: translateY(0); }
    }
    @keyframes fadeIn {
      from { opacity: 0; }
      to { opacity: 1; }
    }
    @keyframes scaleIn {
      from { opacity: 0; transform: scale(0.9); }
      to { opacity: 1; transform: scale(1); }
    }
    @keyframes slideInLeft {
      from { opacity: 0; transform: translateX(-40px); }
      to { opacity: 1; transform: translateX(0); }
    }
    @keyframes slideInRight {
      from { opacity: 0; transform: translateX(40px); }
      to { opacity: 1; transform: translateX(0); }
    }
    @keyframes widthGrow {
      from { width: 0; }
    }

    .animate-fade-in-up {
      opacity: 0;
      animation: fadeInUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    }
    .animate-fade-in {
      opacity: 0;
      animation: fadeIn 0.8s ease forwards;
    }
    .animate-scale-in {
      opacity: 0;
      animation: scaleIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    }
    .animate-slide-left {
      opacity: 0;
      animation: slideInLeft 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    }
    .animate-slide-right {
      opacity: 0;
      animation: slideInRight 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    }

    .delay-100 { animation-delay: 0.1s; }
    .delay-200 { animation-delay: 0.2s; }
    .delay-300 { animation-delay: 0.3s; }
    .delay-400 { animation-delay: 0.4s; }
    .delay-500 { animation-delay: 0.5s; }
    .delay-600 { animation-delay: 0.6s; }
    .delay-700 { animation-delay: 0.7s; }
    .delay-800 { animation-delay: 0.8s; }
    .delay-1000 { animation-delay: 1s; }
    .delay-1200 { animation-delay: 1.2s; }

    .skill-bar-fill {
      animation: widthGrow 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    }

    .marquee-track {
      display: flex;
      gap: 1rem;
      animation: marquee 30s linear infinite;
    }
    .marquee-track:hover { animation-play-state: paused; }

    .nav-link.active {
      color: #00d4ff;
      background: rgba(255, 255, 255, 0.05);
    }

    #three-canvas {
      position: fixed;
      top: 0; left: 0;
      width: 100%; height: 100%;
      z-index: 0;
      pointer-events: none;
    }

    .loading-screen {
      position: fixed;
      inset: 0;
      z-index: 9999;
      background: #0a0a0f;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      transition: opacity 0.8s ease, visibility 0.8s ease;
    }
    .loading-screen.hidden {
      opacity: 0;
      visibility: hidden;
      pointer-events: none;
    }

    .mobile-menu {
      position: fixed;
      inset: 0;
      z-index: 40;
      background: rgba(10, 10, 15, 0.98);
      backdrop-filter: blur(20px);
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: 2rem;
      opacity: 0;
      pointer-events: none;
      transition: opacity 0.3s ease;
    }
    .mobile-menu.open {
      opacity: 1;
      pointer-events: auto;
    }

    .reveal {
      opacity: 0;
      transform: translateY(40px);
      transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .reveal.visible {
      opacity: 1;
      transform: translateY(0);
    }
    .reveal-left {
      opacity: 0;
      transform: translateX(-40px);
      transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .reveal-left.visible {
      opacity: 1;
      transform: translateX(0);
    }
    .reveal-right {
      opacity: 0;
      transform: translateX(40px);
      transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .reveal-right.visible {
      opacity: 1;
      transform: translateX(0);
    }

    input:focus, textarea:focus {
      outline: none;
      border-color: rgba(0, 212, 255, 0.3) !important;
    }

    @media (max-width: 640px) {
      .holo-grid { background-size: 40px 40px; }
    }
        /* Floating holographic panels */
    .holo-panel {
      position: absolute;
      background: rgba(0, 212, 255, 0.03);
      border: 1px solid rgba(0, 212, 255, 0.1);
      backdrop-filter: blur(8px);
      -webkit-backdrop-filter: blur(8px);
      border-radius: 12px;
      pointer-events: none;
      animation: float-holo 6s ease-in-out infinite;
    }
    @keyframes float-holo {
      0%, 100% { transform: translateY(0) rotateX(0deg) rotateY(0deg); }
      25% { transform: translateY(-15px) rotateX(2deg) rotateY(-2deg); }
      50% { transform: translateY(-5px) rotateX(-1deg) rotateY(2deg); }
      75% { transform: translateY(-20px) rotateX(1deg) rotateY(-1deg); }
    }

    /* Code element floating animation */
    .code-float {
      position: absolute;
      font-family: 'Space Grotesk', monospace;
      font-size: 11px;
      color: rgba(0, 212, 255, 0.25);
      pointer-events: none;
      white-space: nowrap;
      animation: code-float-anim 8s ease-in-out infinite;
    }
    @keyframes code-float-anim {
      0%, 100% { transform: translateY(0) translateX(0); opacity: 0.2; }
      33% { transform: translateY(-30px) translateX(10px); opacity: 0.4; }
      66% { transform: translateY(-15px) translateX(-10px); opacity: 0.15; }
    }

    /* Avatar container */
    #avatar-container {
      position: absolute;
      top: 50%;
      right: 5%;
      transform: translateY(-50%);
      width: 300px;
      height: 400px;
      z-index: 5;
      pointer-events: none;
      opacity: 0.6;
    }
    @media (max-width: 1024px) {
      #avatar-container { display: none; }
    }
    /* 3D Project Card Tilt Effect */
    .project-card {
      perspective: 1000px;
    }
    .project-card > .glass-card {
      transition: transform 0.3s ease, box-shadow 0.3s ease;
    }
    .project-card:hover > .glass-card {
      box-shadow: 0 0 40px rgba(0, 212, 255, 0.1);
    }

    /* Skill tag hover glow */
    .skill-tag {
      transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }
    .skill-tag:hover {
      border-color: rgba(0, 212, 255, 0.3);
      box-shadow: 0 0 20px rgba(0, 212, 255, 0.1);
      transform: translateY(-4px);
    }
    /* Terminal Styles */
    .terminal-body {
      min-height: 280px;
    }
    .terminal-line {
      opacity: 0;
      animation: terminalReveal 0.3s ease forwards;
    }
    .terminal-line:nth-child(1) { animation-delay: 0.2s; }
    .terminal-line:nth-child(2) { animation-delay: 0.6s; }
    .terminal-line:nth-child(3) { animation-delay: 1.2s; }
    .terminal-line:nth-child(4) { animation-delay: 1.6s; }
    .terminal-line:nth-child(5) { animation-delay: 1.8s; }
    .terminal-line:nth-child(6) { animation-delay: 2.0s; }
    .terminal-line:nth-child(7) { animation-delay: 2.2s; }
    .terminal-line:nth-child(8) { animation-delay: 2.8s; }
    .terminal-line:nth-child(9) { animation-delay: 3.2s; }
    .terminal-line:nth-child(10) { animation-delay: 3.6s; }
    .terminal-line:nth-child(11) { animation-delay: 4.0s; }
    .terminal-line:nth-child(12) { animation-delay: 4.5s; }

    @keyframes terminalReveal {
      from { opacity: 0; transform: translateX(-10px); }
      to { opacity: 1; transform: translateX(0); }
    }

    .terminal-cursor {
      animation: cursorBlink 1s step-end infinite;
    }
    @keyframes cursorBlink {
      0%, 100% { opacity: 1; }
      50% { opacity: 0; }
    }

    /* Scramble Text Effect */
    .scramble-text {
      font-family: 'Space Grotesk', monospace;
      letter-spacing: 0.1em;
    }

    /* Network Nodes */
    .network-node {
      animation: nodePulse 3s ease-in-out infinite;
    }
    .network-node:nth-child(2) { animation-delay: 0.5s; }
    .network-node:nth-child(3) { animation-delay: 1s; }
    .network-node:nth-child(4) { animation-delay: 1.5s; }
    .network-node:nth-child(5) { animation-delay: 2s; }

    @keyframes nodePulse {
      0%, 100% { transform: scale(1); opacity: 0.8; }
      50% { transform: scale(1.3); opacity: 1; }
    }

    /* Timeline mobile fix */
    @media (max-width: 1023px) {
      #journey .lg\:flex-row-reverse {
        flex-direction: row;
      }
    }

    /* Lab Article Hidden State */
       .lab-article.hidden {
      display: none !important;
    }

    /* What I'm Building progress bar animation */
    @keyframes progressGrow {
      from { width: 0; }
    }
    /* Glowing social icon hover effects */
    .social-glow-tiktok:hover {
      box-shadow: 0 0 30px rgba(236, 72, 153, 0.2), 0 0 60px rgba(236, 72, 153, 0.1);
    }
    .social-glow-snapchat:hover {
      box-shadow: 0 0 30px rgba(250, 204, 21, 0.2), 0 0 60px rgba(250, 204, 21, 0.1);
    }
    .social-glow-whatsapp:hover {
      box-shadow: 0 0 30px rgba(74, 222, 128, 0.2), 0 0 60px rgba(74, 222, 128, 0.1);
    }
    .social-glow-email:hover {
      box-shadow: 0 0 30px rgba(0, 212, 255, 0.2), 0 0 60px rgba(0, 212, 255, 0.1);
    }
    /* Lab Filter Active States */
    .lab-filter.active {
      background: rgba(0, 212, 255, 0.1);
      color: #00d4ff;
      border-color: rgba(0, 212, 255, 0.2);
    }
   
    /* Mobile tap feedback */
    @media (hover: none) {
      .project-card > .glass-card {
        transition: transform 0.2s ease, box-shadow 0.3s ease;
      }
      
      .project-card:active > .glass-card {
        transform: scale(0.98);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
      }
    }
    
    /* Tag hover glow within cards */
    .project-card .glass-card span[class*="rounded-lg"] {
      transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
    }
    
    /* Status indicator pulse */
    .project-card .animate-pulse {
      animation: pulse-glow 2s ease-in-out infinite;
    }
    
    /* Grid gap refinement on mobile */
    @media (max-width: 640px) {
      #projects .grid {
        gap: 1rem;
      }
      
      .project-card > .glass-card {
        padding: 1.25rem;
      }
    }
    
    /* ===== PROJECT CARD 3D TILT ===== */
    .tilt-card {
      perspective: 1000px;
      cursor: default;
    }
    
    .tilt-card > .glass-card {
      transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
                  box-shadow 0.5s cubic-bezier(0.22, 1, 0.36, 1),
                  border-color 0.3s ease;
      transform-style: preserve-3d;
      will-change: transform;
    }
    
    /* Desktop hover: subtle 3D tilt */
    @media (hover: hover) and (pointer: fine) {
      .tilt-card:hover > .glass-card {
        transform: rotateX(2deg) rotateY(-2deg) translateZ(20px) scale(1.01);
        box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4),
                    0 0 40px rgba(0, 212, 255, 0.1);
      }
      
      .tilt-card:active > .glass-card {
        transform: rotateX(1deg) rotateY(-1deg) translateZ(10px) scale(0.995);
        transition-duration: 0.2s;
      }
    }
    
    /* Mobile: tap feedback with brief tilt */
    @media (hover: none) {
      .tilt-card {
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
      }
      
      .tilt-card.tapped > .glass-card {
        transform: rotateX(3deg) rotateY(-3deg) translateZ(15px) scale(1.01);
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3),
                    0 0 30px rgba(0, 212, 255, 0.08);
        transition-duration: 0.25s;
      }
    }
    
    /* Preserve existing glow on hover */
    .tilt-card > .glass-card:hover {
      border-color: rgba(255, 255, 255, 0.12);
    }
    
    /* Featured Pulse card cyan glow */
    .project-card:nth-child(4) .glass-card {
      border-color: rgba(0, 240, 255, 0.08);
    }
    
    .project-card:nth-child(4):hover .glass-card {
      border-color: rgba(0, 240, 255, 0.25);
      box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4),
                  0 0 50px rgba(0, 240, 255, 0.12);
    }
    
    /* Mobile grid gap */
    @media (max-width: 640px) {
      #projects .grid {
        gap: 1rem;
      }
    }
