/* Modern Responsive Design - Mobile First */
/* Unified CSS for both mobile and desktop */

/* CSS Custom Properties (Variables) */
:root {
  /* Enhanced VS Code Dark Theme Colors */
  --primary-bg: #1a1a1a;
  --secondary-bg: #282828;
  --tertiary-bg: #323232;
  --card-bg: #282828;
  --surface-bg: #383838;
  --overlay-bg: rgba(26, 26, 26, 0.95);
  
  --text-primary: #e6e6e6;
  --text-secondary: #b4b4b4;
  --text-muted: #888888;
  --text-accent: #569cd6;
  --text-highlight: #dcdcaa;
  --text-keyword: #c586c0;
  --text-string: #ce9178;
  --text-comment: #6a9955;
  --text-number: #b5cea8;
  
  --accent-primary: #0078d4;
  --accent-secondary: #106ebe;
  --accent-tertiary: #1177bb;
  --accent-quaternary: #0066cc;
  --accent-warning: #ffcc02;
  --accent-error: #f44747;
  --accent-success: #89d185;
  
  --border-color: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.12);
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-strong: rgba(255, 255, 255, 0.06);
  
  /* Minimal Gradient System */
  --gradient-primary: var(--accent-primary);
  --gradient-secondary: var(--accent-secondary);
  --gradient-tertiary: var(--accent-tertiary);
  --gradient-surface: var(--tertiary-bg);
  --gradient-glow: radial-gradient(circle at center, rgba(108, 138, 173, 0.05) 0%, transparent 70%);
  --gradient-text: var(--text-primary);
  
  /* Mouse-responsive gradients */
  --gradient-interactive: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
  --gradient-hover: linear-gradient(135deg, var(--accent-secondary) 0%, var(--accent-neon) 100%);
  
  /* Dynamic Spacing System */
  --space-xs: clamp(0.25rem, 1vw, 0.5rem);
  --space-sm: clamp(0.5rem, 2vw, 1rem);
  --space-md: clamp(1rem, 3vw, 1.5rem);
  --space-lg: clamp(1.5rem, 4vw, 2.5rem);
  --space-xl: clamp(2rem, 5vw, 3.5rem);
  --space-2xl: clamp(3rem, 6vw, 5rem);
  --space-3xl: clamp(4rem, 8vw, 7rem);
  --space-4xl: clamp(5rem, 10vw, 9rem);
  
  /* Container Spacing */
  --container-padding: clamp(1rem, 4vw, 2rem);
  --container-gap: clamp(1.5rem, 5vw, 3rem);
  
  /* Section Spacing */
  --section-padding-y: clamp(3rem, 8vw, 6rem);
  --section-padding-x: var(--container-padding);
  --section-gap: clamp(2rem, 6vw, 4rem);
  
  /* Component Spacing */
  --card-padding: clamp(1.5rem, 4vw, 2.5rem);
  --card-gap: clamp(1rem, 3vw, 2rem);
  --button-padding-y: clamp(0.75rem, 2vw, 1rem);
  --button-padding-x: clamp(1.5rem, 4vw, 2rem);
  
  /* Typography - VS Code Inspired */
  --font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  --font-family-display: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  --font-weight-light: 300;
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-bold: 700;
  
  /* Responsive Font Sizes - Enhanced */
  --text-xs: clamp(0.75rem, 1.5vw + 0.5rem, 0.875rem);
  --text-sm: clamp(0.875rem, 2vw + 0.5rem, 1rem);
  --text-base: clamp(1rem, 2.5vw + 0.5rem, 1.25rem);
  --text-lg: clamp(1.125rem, 3vw + 0.5rem, 1.5rem);
  --text-xl: clamp(1.25rem, 3.5vw + 0.5rem, 1.75rem);
  --text-2xl: clamp(1.5rem, 4vw + 0.5rem, 2.25rem);
  --text-3xl: clamp(2rem, 5vw + 0.5rem, 2.75rem);
  --text-4xl: clamp(2.5rem, 6vw + 0.5rem, 3.5rem);
  --text-5xl: clamp(3rem, 7vw + 1rem, 5rem);
  
  /* Breakpoints */
  --mobile: 768px;
  --tablet: 1024px;
  --desktop: 1280px;
  
  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
  
  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.3);
  --shadow-xl: 0 16px 32px rgba(0, 0, 0, 0.4);
}

/* Reset and Base Styles */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 100%;
  cursor: auto; /* Standard cursor */
}

body {
  font-family: var(--font-family-display);
  font-weight: var(--font-weight-normal);
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--primary-bg);
  background-attachment: fixed;
  overflow-x: hidden;
  min-height: 100vh;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Cursor styles removed for performance */
.cursor,
.cursor-text {
  display: none !important;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-display);
  font-weight: var(--font-weight-light);
  line-height: 1.3;
  margin-bottom: var(--space-lg);
  color: var(--text-primary);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

h1 { font-size: var(--text-5xl); }
h2 { font-size: var(--text-4xl); }
h3 { font-size: var(--text-3xl); }
h4 { font-size: var(--text-2xl); }
h5 { font-size: var(--text-xl); }
h6 { font-size: var(--text-lg); }

p {
  font-size: var(--text-base);
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
  line-height: 1.8;
  font-family: var(--font-family-display);
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.3);
}

a {
  color: var(--accent-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--accent-secondary);
}

/* Enhanced Layout Components */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.container-sm {
  max-width: 800px;
}

.container-lg {
  max-width: 1400px;
}

.container-xl {
  max-width: 1600px;
}

.section {
  padding: var(--section-padding-y) var(--section-padding-x);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 100%;
  z-index: 1;
  background: rgba(26, 26, 26, 0.85);
  backdrop-filter: blur(1px);
}

.section:first-child {
  min-height: 100vh;
}

.section-compact {
  min-height: auto;
  padding: var(--space-2xl) var(--section-padding-x);
}

.section-hero {
  min-height: 100vh;
  padding: var(--space-4xl) var(--section-padding-x);
}

/* Responsive Container Adjustments */
@media (min-width: 768px) {
  .container {
    padding: 0 var(--space-xl);
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 0 var(--space-2xl);
  }
}

@media (min-width: 1440px) {
  .container {
    max-width: 1400px;
    padding: 0 var(--space-3xl);
  }
}

@media (min-width: 1920px) {
  .container {
    max-width: 1600px;
    padding: 0 var(--space-4xl);
  }
}

/* Modern Side Navigation */
.side-navigation {
  position: fixed;
  left: 24px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 9999;
  background: var(--surface-bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 1rem 0.5rem;
  backdrop-filter: blur(16px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.nav-dots {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

.nav-dot {
  position: relative;
  display: flex;
  align-items: center;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 12px;
}

.nav-dot-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-muted);
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.nav-dot.active .nav-dot-indicator {
  background: var(--accent-primary);
  width: 12px;
  height: 12px;
  border-color: rgba(0, 120, 212, 0.3);
  box-shadow: 0 0 12px rgba(0, 120, 212, 0.4);
}

.nav-dot:hover .nav-dot-indicator {
  background: var(--text-secondary);
  width: 10px;
  height: 10px;
  transform: scale(1.1);
}

.nav-dot-label {
  position: absolute;
  left: 100%;
  margin-left: 1rem;
  background: var(--surface-bg);
  color: var(--text-primary);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transform: translateX(-8px);
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  z-index: 10000;
}

.nav-dot:hover .nav-dot-label {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .side-navigation {
    left: 12px;
    padding: 0.75rem 0.375rem;
  }
  
  .nav-dots {
    gap: 0.75rem;
  }
  
  .nav-dot-label {
    display: none;
  }
}

/* Navigation progress indicator */
.nav-progress {
  position: absolute;
  left: -1px;
  top: 0;
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, 
    var(--accent-primary) 0%, 
    var(--accent-secondary) 50%, 
    var(--accent-primary) 100%);
  border-radius: 1px;
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.3s ease;
}

.side-navigation:hover .nav-progress {
  transform: scaleY(1);
}

/* Enhanced Center-Focused Animated Background */
.animated-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
  background: var(--primary-bg);
}

/* Minimal Background Effects */
.simple-bg-effect {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(108, 138, 173, 0.03) 0%, transparent 70%);
  border-radius: 50%;
  animation: gentlePulse 8s ease-in-out infinite;
}

@keyframes gentlePulse {
  0%, 100% { 
    transform: translate(-50%, -50%) scale(1); 
    opacity: 0.3; 
  }
  50% { 
    transform: translate(-50%, -50%) scale(1.1); 
    opacity: 0.1; 
  }
}

/* Enhanced Code Matrix Background */
.code-matrix {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: clamp(10px, 1vw, 12px);
  line-height: 1.6;
  overflow: hidden;
  opacity: 0.08;
  pointer-events: none;
  z-index: 0;
}

.code-line {
  position: absolute;
  white-space: nowrap;
  opacity: 0;
  will-change: transform, opacity;
  transform: translate3d(0, 0, 0);
  font-weight: 400;
}

/* VS Code Syntax Highlighting */
.code-line .keyword {
  color: var(--text-keyword); /* Purple - C586C0 */
}

.code-line .register,
.code-line .access {
  color: var(--text-accent); /* Blue - 569CD6 */
}

.code-line .immediate,
.code-line .number {
  color: var(--text-number); /* Light green - B5CEA8 */
}

.code-line .string {
  color: var(--text-string); /* Orange - CE9178 */
}

.code-line .comment {
  color: var(--text-comment); /* Green - 6A9955 */
  font-style: italic;
}

.code-line .function {
  color: var(--text-highlight); /* Yellow - DCDCAA */
}

.code-line .type {
  color: #4ec9b0; /* Teal */
}

.code-line .label {
  color: var(--text-secondary); /* Light blue - 9CDCFE */
}

.code-line .address {
  color: #d4d4d4; /* Light gray */
}

.code-line .hex {
  color: #b5cea8; /* Light green */
  font-family: 'Consolas', monospace;
}

/* Enhanced Code Animations */
@keyframes matrixFlow1 {
  0% {
    transform: translate(-150%, 120vh) rotate(-20deg);
    opacity: 0;
  }
  5% {
    opacity: 0.4;
  }
  95% {
    opacity: 0.4;
  }
  100% {
    transform: translate(120vw, -150px) rotate(-20deg);
    opacity: 0;
  }
}

@keyframes matrixFlow2 {
  0% {
    transform: translate(120vw, 120vh) rotate(18deg);
    opacity: 0;
  }
  5% {
    opacity: 0.35;
  }
  95% {
    opacity: 0.35;
  }
  100% {
    transform: translate(-150%, -150px) rotate(18deg);
    opacity: 0;
  }
}

@keyframes matrixFlow3 {
  0% {
    transform: translate(-150%, -150px) rotate(-12deg);
    opacity: 0;
  }
  5% {
    opacity: 0.3;
  }
  95% {
    opacity: 0.3;
  }
  100% {
    transform: translate(120vw, 120vh) rotate(-12deg);
    opacity: 0;
  }
}

@keyframes matrixVertical {
  0% {
    transform: translateY(-120px);
    opacity: 0;
  }
  5% {
    opacity: 0.25;
  }
  95% {
    opacity: 0.25;
  }
  100% {
    transform: translateY(calc(100vh + 120px));
    opacity: 0;
  }
}

@keyframes matrixHorizontal {
  0% {
    transform: translateX(-200%);
    opacity: 0;
  }
  5% {
    opacity: 0.2;
  }
  95% {
    opacity: 0.2;
  }
  100% {
    transform: translateX(200%);
    opacity: 0;
  }
}

/* Assembly code animations */
.code-line.assembly:nth-child(1),
.code-line.assembly:nth-child(2),
.code-line.assembly:nth-child(3),
.code-line.assembly:nth-child(4),
.code-line.assembly:nth-child(5),
.code-line.assembly:nth-child(6) {
  animation: matrixFlow1 28s linear infinite;
}

/* Smali code animations */
.code-line.smali:nth-child(7),
.code-line.smali:nth-child(8),
.code-line.smali:nth-child(9),
.code-line.smali:nth-child(10),
.code-line.smali:nth-child(11),
.code-line.smali:nth-child(12),
.code-line.smali:nth-child(13),
.code-line.smali:nth-child(14) {
  animation: matrixFlow2 32s linear infinite;
}

/* System call animations */
.code-line.syscall:nth-child(15),
.code-line.syscall:nth-child(16),
.code-line.syscall:nth-child(17) {
  animation: matrixVertical 25s linear infinite;
}

/* Memory address animations */
.code-line.memory:nth-child(18),
.code-line.memory:nth-child(19),
.code-line.memory:nth-child(20) {
  animation: matrixHorizontal 30s linear infinite;
}

/* Opcode animations */
.code-line.opcode:nth-child(21),
.code-line.opcode:nth-child(22),
.code-line.opcode:nth-child(23),
.code-line.opcode:nth-child(24) {
  animation: matrixFlow3 26s linear infinite;
}

/* Staggered animation delays */
.code-line:nth-child(1) { animation-delay: 0s; }
.code-line:nth-child(2) { animation-delay: -3s; }
.code-line:nth-child(3) { animation-delay: -6s; }
.code-line:nth-child(4) { animation-delay: -9s; }
.code-line:nth-child(5) { animation-delay: -12s; }
.code-line:nth-child(6) { animation-delay: -15s; }
.code-line:nth-child(7) { animation-delay: -18s; }
.code-line:nth-child(8) { animation-delay: -21s; }
.code-line:nth-child(9) { animation-delay: -24s; }
.code-line:nth-child(10) { animation-delay: -2s; }
.code-line:nth-child(11) { animation-delay: -5s; }
.code-line:nth-child(12) { animation-delay: -8s; }
.code-line:nth-child(13) { animation-delay: -11s; }
.code-line:nth-child(14) { animation-delay: -14s; }
.code-line:nth-child(15) { animation-delay: -17s; }
.code-line:nth-child(16) { animation-delay: -20s; }
.code-line:nth-child(17) { animation-delay: -23s; }
.code-line:nth-child(18) { animation-delay: -1s; }
.code-line:nth-child(19) { animation-delay: -4s; }
.code-line:nth-child(20) { animation-delay: -7s; }
.code-line:nth-child(21) { animation-delay: -10s; }
.code-line:nth-child(22) { animation-delay: -13s; }
.code-line:nth-child(23) { animation-delay: -16s; }
.code-line:nth-child(24) { animation-delay: -19s; }

/* Additional flying animations for variety */
@keyframes flyingCodeVertical {
  0% {
    transform: translateY(-100px);
    opacity: 0;
  }
  10% {
    opacity: 0.25;
  }
  90% {
    opacity: 0.25;
  }
  100% {
    transform: translateY(100vh);
    opacity: 0;
  }
}

@keyframes flyingCodeHorizontal {
  0% {
    transform: translateX(-100%);
    opacity: 0;
  }
  10% {
    opacity: 0.2;
  }
  90% {
    opacity: 0.2;
  }
  100% {
    transform: translateX(100vw);
    opacity: 0;
  }
}


/* Binary Data Streams */
.binary-streams {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.04;
  z-index: -1;
}

.binary-stream {
  position: absolute;
  font-family: 'Courier New', monospace;
  font-size: clamp(8px, 1vw, 12px);
  color: var(--accent-secondary);
  animation: binaryFlow 15s linear infinite;
  white-space: nowrap;
  letter-spacing: 2px;
  transform: translate3d(0, 0, 0);
  will-change: transform;
}

.binary-stream:nth-child(1) {
  top: 20%;
  left: -100%;
  animation-delay: 0s;
}

.binary-stream:nth-child(2) {
  top: 40%;
  left: -100%;
  animation-delay: -3s;
}

.binary-stream:nth-child(3) {
  top: 60%;
  left: -100%;
  animation-delay: -6s;
}

.binary-stream:nth-child(4) {
  top: 80%;
  left: -100%;
  animation-delay: -9s;
}

.binary-stream:nth-child(5) {
  top: 10%;
  left: -100%;
  animation-delay: -12s;
}

@keyframes binaryFlow {
  0% { transform: translateX(0); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateX(120vw); opacity: 0; }
}

/* Hex Annotations */
.hex-annotations {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hex-value {
  position: absolute;
  font-family: 'Courier New', monospace;
  font-size: clamp(10px, 1.5vw, 16px);
  font-weight: 500;
  color: rgba(16, 185, 129, 0.15);
  animation: hexPulse 6s ease-in-out infinite;
  transform: translate3d(0, 0, 0);
  will-change: transform, opacity;
}

.hex-value:nth-child(1) { top: 10%; right: 10%; animation-delay: 0s; }
.hex-value:nth-child(2) { top: 30%; right: 70%; animation-delay: -1s; }
.hex-value:nth-child(3) { top: 50%; right: 20%; animation-delay: -2s; }
.hex-value:nth-child(4) { top: 70%; right: 80%; animation-delay: -3s; }
.hex-value:nth-child(5) { top: 90%; right: 40%; animation-delay: -4s; }
.hex-value:nth-child(6) { top: 60%; right: 60%; animation-delay: -5s; }

@keyframes hexPulse {
  0%, 100% { opacity: 0.15; transform: scale(1) rotate(0deg); }
  25% { opacity: 0.25; transform: scale(1.05) rotate(1deg); }
  50% { opacity: 0.1; transform: scale(0.95) rotate(-1deg); }
  75% { opacity: 0.2; transform: scale(1.02) rotate(0.5deg); }
}

/* Memory Addresses */
.memory-addresses {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.memory-addresses div {
  position: absolute;
  font-family: 'Courier New', monospace;
  font-size: clamp(8px, 1vw, 12px);
  color: rgba(139, 92, 246, 0.1);
  animation: memoryGlow 10s ease-in-out infinite;
  transform: translate3d(0, 0, 0);
  will-change: transform, opacity;
}

.memory-addresses div:nth-child(1) { top: 8%; left: 5%; animation-delay: 0s; }
.memory-addresses div:nth-child(2) { top: 25%; left: 85%; animation-delay: -2s; }
.memory-addresses div:nth-child(3) { top: 45%; left: 10%; animation-delay: -4s; }
.memory-addresses div:nth-child(4) { top: 65%; left: 90%; animation-delay: -6s; }
.memory-addresses div:nth-child(5) { top: 85%; left: 15%; animation-delay: -8s; }

@keyframes memoryGlow {
  0%, 100% { opacity: 0.1; text-shadow: 0 0 5px rgba(139, 92, 246, 0.2); }
  50% { opacity: 0.2; text-shadow: 0 0 15px rgba(139, 92, 246, 0.4); }
}

.floating-particles {
  position: absolute;
  width: 100%;
  height: 100%;
}

.particle {
  position: absolute;
  width: 3px;
  height: 3px;
  background: var(--gradient-primary);
  border-radius: 50%;
  animation: particleFloat 8s ease-in-out infinite;
  opacity: 0;
  box-shadow: 0 0 10px var(--accent-neon);
}

/* Enhanced particle system with mouse interaction */
.particle-interactive {
  transition: all 0.3s ease;
}

.particle-interactive:hover {
  transform: scale(2);
  opacity: 1 !important;
  box-shadow: 0 0 20px var(--accent-primary);
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; animation-duration: 6s; }
.particle:nth-child(2) { left: 20%; animation-delay: 1s; animation-duration: 8s; }
.particle:nth-child(3) { left: 30%; animation-delay: 2s; animation-duration: 7s; }
.particle:nth-child(4) { left: 40%; animation-delay: 0.5s; animation-duration: 9s; }
.particle:nth-child(5) { left: 50%; animation-delay: 1.5s; animation-duration: 5s; }
.particle:nth-child(6) { left: 60%; animation-delay: 3s; animation-duration: 7s; }
.particle:nth-child(7) { left: 70%; animation-delay: 2.5s; animation-duration: 8s; }
.particle:nth-child(8) { left: 80%; animation-delay: 4s; animation-duration: 6s; }
.particle:nth-child(9) { left: 90%; animation-delay: 3.5s; animation-duration: 9s; }

@keyframes particleFloat {
  0%, 100% {
    transform: translateY(100vh) translateX(0) scale(0) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.8;
    transform: translateY(90vh) translateX(10px) scale(0.5) rotate(45deg);
  }
  25% {
    opacity: 1;
    transform: translateY(75vh) translateX(-5px) scale(1) rotate(90deg);
  }
  50% {
    transform: translateY(50vh) translateX(15px) scale(1.2) rotate(180deg);
    opacity: 0.9;
  }
  75% {
    opacity: 0.7;
    transform: translateY(25vh) translateX(-10px) scale(1) rotate(270deg);
  }
  90% {
    opacity: 0.5;
    transform: translateY(10vh) translateX(5px) scale(0.8) rotate(315deg);
  }
}

/* Mouse trail removed for performance */

.gradient-orbs {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.orb {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(102, 126, 234, 0.1) 0%, transparent 70%);
  animation: drift 20s ease-in-out infinite;
  filter: blur(1px);
}

.orb-1 {
  width: 300px;
  height: 300px;
  top: 10%;
  left: -150px;
  animation-delay: 0s;
}

.orb-2 {
  width: 200px;
  height: 200px;
  top: 60%;
  right: -100px;
  animation-delay: 10s;
}

.orb-3 {
  width: 400px;
  height: 400px;
  bottom: 10%;
  left: 50%;
  animation-delay: 15s;
}

@keyframes drift {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(30px, -30px) scale(1.1);
  }
  66% {
    transform: translate(-20px, 20px) scale(0.9);
  }
}

/* Subtle grid pattern */
.grid-pattern {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(102, 126, 234, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(102, 126, 234, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  animation: gridShift 30s linear infinite;
}

@keyframes gridShift {
  0% {
    transform: translate(0, 0);
  }
  100% {
    transform: translate(50px, 50px);
  }
}

/* Perfect Center-Focused Hero Section */
.hero {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  text-align: center;
  position: relative;
  background: transparent;
  padding: 0;
  width: 100%;
}

/* Removed centering dot for cleaner look */

.hero::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60vw;
  height: 60vh;
  background: var(--gradient-glow);
  border-radius: 50%;
  opacity: 0.08;
  animation: heroGlow 12s ease-in-out infinite;
  z-index: -1;
}

@keyframes heroGlow {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.1;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.2);
    opacity: 0.2;
  }
}

.hero-content {
  max-width: 800px;
  z-index: 3;
  position: relative;
  animation: none;
  padding: var(--space-3xl) var(--space-xl);
  background: rgba(26, 26, 26, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(16px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: auto;
}

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

.hero-content:hover {
  transform: translateY(-5px);
  transition: all 0.3s ease;
}

.hero-avatar {
  width: clamp(150px, 20vw, 200px);
  height: clamp(150px, 20vw, 200px);
  border-radius: 50%;
  margin: 0 auto var(--space-xl);
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  position: relative;
  background: var(--secondary-bg);
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-avatar::before {
  content: '';
  position: absolute;
  top: -3px;
  left: -3px;
  right: -3px;
  bottom: -3px;
  border-radius: 50%;
  background: linear-gradient(45deg, var(--accent-primary), var(--accent-secondary), var(--accent-primary));
  z-index: -1;
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.hero-avatar:hover::before {
  opacity: 1;
  animation: rotateBorder 3s linear infinite;
}

.hero-avatar:hover {
  transform: scale(1.05);
  box-shadow: 0 16px 48px rgba(102, 126, 234, 0.3);
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all var(--transition-normal);
  filter: grayscale(20%) contrast(1.1);
}

.hero-avatar:hover img {
  filter: grayscale(0%) contrast(1.2) brightness(1.1);
  transform: scale(1.02);
}

@keyframes rotateBorder {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.hero-title {
  font-size: var(--text-4xl);
  font-weight: var(--font-weight-light);
  margin: 0 auto var(--space-lg);
  color: var(--text-primary);
  letter-spacing: -0.02em;
  position: relative;
  text-align: center;
  width: 100%;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  z-index: 10;
}

.hero-title::before {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: -1;
}

.hero-title:hover::before {
  opacity: 0.5;
}

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

.hero-subtitle {
  font-size: var(--text-lg);
  color: var(--text-secondary);
  margin: 0 auto var(--space-xl);
  font-weight: var(--font-weight-light);
  letter-spacing: 0.5px;
  opacity: 0.9;
  text-align: center;
  width: 100%;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  z-index: 10;
}

.hero-description {
  font-size: var(--text-base);
  max-width: clamp(300px, 80vw, 600px);
  margin: 0 auto var(--space-2xl);
  line-height: 1.9;
  color: var(--text-secondary);
  font-weight: var(--font-weight-light);
  text-align: center;
  width: 100%;
  opacity: 0.95;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  z-index: 10;
}

/* Enhanced Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-lg);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-size: var(--text-sm);
  font-weight: var(--font-weight-normal);
  font-family: var(--font-family);
  cursor: pointer;
  transition: all var(--transition-normal);
  text-decoration: none;
  min-height: 44px;
  justify-content: center;
  position: relative;
  overflow: hidden;
  letter-spacing: 0.02em;
  background: var(--surface-bg);
}

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

.btn:hover::before {
  left: 100%;
}

.btn-primary {
  background: var(--accent-primary);
  color: #ffffff;
  border-color: var(--accent-primary);
  box-shadow: 0 2px 8px rgba(0, 122, 204, 0.2);
}

.btn-primary:hover {
  background: var(--accent-secondary);
  border-color: var(--accent-secondary);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 122, 204, 0.3);
}

.btn-secondary {
  background: var(--secondary-bg);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--tertiary-bg);
  border-color: var(--border-strong);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.btn-tertiary {
  background: var(--gradient-tertiary);
  color: var(--text-primary);
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.2);
  border: 1px solid rgba(6, 182, 212, 0.2);
}

.btn-tertiary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(6, 182, 212, 0.3);
}

.btn-group {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  flex-wrap: wrap;
}

/* Enhanced Cards */
.card {
  background: var(--secondary-bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: var(--card-padding);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  z-index: 2;
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--gradient-primary);
  transform: scaleX(0);
  transition: transform var(--transition-normal);
  border-radius: 20px 20px 0 0;
}

.card:hover::before {
  transform: scaleX(1);
}

.card-elevated {
  background: var(--surface-bg);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.card-elevated:hover {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.card-glass {
  background: var(--glass-strong);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-strong);
}

.card-compact {
  padding: var(--space-lg);
  border-radius: 16px;
}

/* Enhanced Grid System */
.grid {
  display: grid;
  gap: var(--card-gap);
  margin: var(--section-gap) 0;
}

.grid-1 {
  grid-template-columns: 1fr;
}

.grid-2 {
  grid-template-columns: 1fr;
  gap: var(--space-lg);
}

.grid-3 {
  grid-template-columns: 1fr;
  gap: var(--space-lg);
}

.grid-4 {
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

.grid-auto {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--card-gap);
}

.grid-auto-sm {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-md);
}

/* Responsive Grid Breakpoints */
@media (min-width: 640px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-xl);
  }
  
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-lg);
  }
}

@media (min-width: 768px) {
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-xl);
  }
}

@media (min-width: 1024px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-2xl);
  }
  
  .grid-4 {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-xl);
  }
}

@media (min-width: 1280px) {
  .grid-4 {
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-xl);
  }
}

/* Grid Item Alignment */
.grid-center {
  place-items: center;
}

.grid-start {
  place-items: start;
}

.grid-stretch {
  place-items: stretch;
}

/* Enhanced Skills Section */
.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin: var(--space-lg) 0;
}

/* Modern Projects Grid */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

/* Enhanced Project Cards */
.project-card {
  background: var(--secondary-bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  z-index: 2;
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  min-height: 400px;
}

.project-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3);
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-card:hover::before {
  opacity: 1;
}

/* Project Card Header */
.project-card-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.5rem 1.5rem 0 1.5rem;
  margin-bottom: 1rem;
}

.project-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  background: var(--accent-primary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 120, 212, 0.3);
}

.project-icon i {
  color: white;
  font-size: 1.2rem;
}

.project-category-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  min-height: 48px;
}

.project-category {
  background: var(--surface-bg);
  color: var(--accent-primary);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

/* Project Card Content */
.project-card-content {
  flex: 1;
  padding: 0 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.project-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.3;
}

.project-description {
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
  flex: 1;
}

/* Tech Stack Section */
.project-tech-section {
  margin-top: auto;
}

.tech-label {
  display: block;
  font-size: 0.875rem;
  color: var(--text-accent);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.project-tech-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.project-tech-tag {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  padding: 0.25rem 0.75rem;
  border-radius: 16px;
  font-size: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.2s ease;
  font-weight: 400;
}

.project-tech-tag:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  border-color: rgba(255, 255, 255, 0.15);
}

/* Project Card Actions */
.project-card-actions {
  padding: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  margin-top: 1rem;
}

.project-link-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.75rem 1.5rem;
  background: var(--accent-primary);
  color: white;
  text-decoration: none;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 120, 212, 0.2);
}

.project-link-btn:hover {
  background: var(--accent-secondary);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 120, 212, 0.3);
  color: white;
}

/* Responsive Design */
@media (max-width: 768px) {
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .project-card {
    min-height: 350px;
  }
  
  .project-card-header {
    padding: 1.25rem 1.25rem 0 1.25rem;
  }
  
  .project-card-content {
    padding: 0 1.25rem;
  }
  
  .project-card-actions {
    padding: 1.25rem;
  }
}

.skill-tag {
  background: transparent;
  color: var(--text-muted);
  padding: var(--space-xs) var(--space-md);
  border-radius: 4px;
  font-size: var(--text-sm);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all var(--transition-fast);
  cursor: default;
  font-weight: var(--font-weight-light);
  position: relative;
  overflow: hidden;
}

.skill-tag::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  transition: left 0.3s ease;
  z-index: -1;
}

.skill-tag:hover::before {
  left: 0;
}

.skill-tag:hover {
  color: var(--text-secondary);
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.03);
}

.skill-category {
  margin-bottom: var(--space-xl);
}

.skill-category h4 {
  color: var(--accent-primary);
  margin-bottom: var(--space-md);
  font-size: var(--text-lg);
  font-weight: var(--font-weight-medium);
}

/* Experience Timeline */
.timeline {
  position: relative;
  padding-left: var(--space-xl);
}

.timeline::before {
  content: '';
  position: absolute;
  left: 12px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, var(--accent-primary), var(--accent-secondary));
}

.timeline-item {
  position: relative;
  margin-bottom: var(--space-2xl);
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -18px;
  top: 8px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent-primary);
  border: 3px solid var(--primary-bg);
}

.timeline-item h4 {
  color: var(--accent-primary);
  margin-bottom: var(--space-xs);
}

.timeline-item h5 {
  color: var(--text-primary);
  margin-bottom: var(--space-xs);
}

.timeline-date {
  color: var(--text-muted);
  font-size: var(--text-sm);
  margin-bottom: var(--space-sm);
}

/* Enhanced Contact Section */
.contact-links {
  display: flex;
  gap: var(--space-lg);
  justify-content: center;
  flex-wrap: wrap;
  margin: var(--space-2xl) 0;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-lg);
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  color: var(--text-secondary);
  transition: all var(--transition-normal);
  min-height: 44px;
  font-weight: var(--font-weight-light);
  position: relative;
  overflow: hidden;
}

.contact-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  transition: left 0.4s ease;
  z-index: -1;
}

.contact-link:hover::before {
  left: 0;
}

.contact-link:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.contact-link i {
  font-size: var(--text-lg);
  opacity: 0.9;
}

.contact-link:hover i {
  opacity: 1;
}

/* Footer */
.footer {
  background: var(--secondary-bg);
  border-top: 1px solid var(--border-color);
  padding: var(--space-xl) 0;
  text-align: center;
}

.footer p {
  color: var(--text-muted);
  font-size: var(--text-sm);
}

/* Scroll Progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  z-index: 1001;
}

.scroll-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
  width: 0%;
  transition: width 0.1s ease;
}

/* Scroll to Top Button */
.scroll-to-top {
  position: fixed;
  bottom: var(--space-lg);
  right: var(--space-lg);
  width: 44px;
  height: 44px;
  border-radius: 6px;
  background: var(--secondary-bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
  z-index: 9000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(8px);
}

.scroll-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-to-top:hover {
  transform: translateY(-1px);
  background: var(--tertiary-bg);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.12);
}

/* Loading Screen */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--primary-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity var(--transition-slow);
}

.loading-screen.hidden {
  opacity: 0;
  pointer-events: none;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid var(--border-color);
  border-top: 3px solid var(--accent-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.slide-in-left {
  opacity: 0;
  transform: translateX(-30px);
  animation: slideInLeft 0.6s ease forwards;
}

@keyframes slideInLeft {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.slide-in-right {
  opacity: 0;
  transform: translateX(30px);
  animation: slideInRight 0.6s ease forwards;
}

@keyframes slideInRight {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Advanced Dynamic Display Handling */

/* Container Queries for Modern Browsers */
@container (max-width: 480px) {
  .hero-content {
    padding: var(--space-lg);
  }
  
  .btn-group {
    flex-direction: column;
    align-items: center;
    gap: var(--space-md);
  }
  
  .btn {
    width: 100%;
    max-width: 280px;
  }
  
  .card {
    padding: var(--space-lg);
  }
}

/* Enhanced Responsive Spacing */
@media (max-width: 375px) {
  :root {
    --section-padding-y: clamp(2rem, 6vw, 3rem);
    --card-padding: clamp(1rem, 3vw, 1.5rem);
    --container-padding: clamp(0.75rem, 3vw, 1rem);
  }
  
  .section {
    padding: var(--section-padding-y) var(--container-padding);
  }
}

@media (min-width: 376px) and (max-width: 640px) {
  :root {
    --section-padding-y: clamp(2.5rem, 7vw, 4rem);
    --card-padding: clamp(1.25rem, 3.5vw, 2rem);
  }
}

/* Responsive Breakpoint Classes */
.mobile-only {
  display: block;
}

.tablet-up {
  display: none;
}

.desktop-up {
  display: none;
}

@media (min-width: 641px) and (max-width: 768px) {
  :root {
    --section-padding-y: clamp(3rem, 8vw, 5rem);
    --card-padding: clamp(1.5rem, 4vw, 2.25rem);
    --container-padding: clamp(1.25rem, 4vw, 1.75rem);
  }
  
  .grid-auto {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  }
}

@media (min-width: 768px) {
  :root {
    --section-padding-y: clamp(4rem, 8vw, 6rem);
    --card-padding: clamp(2rem, 4vw, 2.5rem);
    --container-padding: clamp(1.5rem, 4vw, 2rem);
  }
  
  .mobile-only {
    display: none;
  }
  
  .tablet-up {
    display: block;
  }
  
  .hero-content {
    padding: var(--space-2xl) var(--space-xl);
  }
  
  .btn-group {
    flex-direction: row;
    justify-content: center;
    gap: var(--space-lg);
  }
}

@media (min-width: 1024px) {
  :root {
    --section-padding-y: clamp(5rem, 8vw, 7rem);
    --card-padding: clamp(2.25rem, 4vw, 3rem);
    --container-padding: clamp(2rem, 4vw, 2.5rem);
  }
  
  .desktop-up {
    display: block;
  }
  
  .container {
    padding: 0 var(--container-padding);
  }
  
  .hero-content {
    padding: var(--space-3xl) var(--space-2xl);
  }
}

@media (min-width: 1440px) {
  :root {
    --section-padding-y: clamp(6rem, 8vw, 8rem);
    --card-padding: clamp(2.5rem, 4vw, 3.5rem);
    --container-padding: clamp(2.5rem, 4vw, 3rem);
  }
  
  .container {
    max-width: 1400px;
    padding: 0 var(--container-padding);
  }
  
  .hero-content {
    max-width: 900px;
    padding: var(--space-4xl) var(--space-3xl);
  }
}

/* Ultra-wide display optimization */
@media (min-width: 1920px) {
  :root {
    --section-padding-y: clamp(7rem, 8vw, 10rem);
    --card-padding: clamp(3rem, 4vw, 4rem);
    --container-padding: clamp(3rem, 4vw, 4rem);
  }
  
  .container {
    max-width: 1600px;
    padding: 0 var(--container-padding);
  }
  
  .section {
    padding: var(--section-padding-y) 0;
  }
  
  .hero-content {
    padding: var(--space-4xl) var(--space-4xl);
  }
}

/* Small mobile devices */
@media (max-width: 375px) {
  .hero-avatar {
    width: clamp(120px, 25vw, 160px);
    height: clamp(120px, 25vw, 160px);
  }
  
  .btn {
    padding: var(--space-sm) var(--space-lg);
    font-size: var(--text-sm);
    min-height: 48px;
  }
  
  .contact-links {
    flex-direction: column;
    align-items: center;
    gap: var(--space-md);
  }
  
  .contact-link {
    width: 100%;
    max-width: 280px;
    min-height: 48px;
    padding: var(--space-md);
  }
  
  /* Ensure mobile menu is accessible */
  .mobile-menu-btn {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }
  
  .mobile-nav-links a {
    min-height: 56px;
    padding: var(--space-md) var(--space-lg);
  }
}

/* Tablet portrait */
@media (min-width: 768px) and (max-width: 1024px) {
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .hero-avatar {
    width: clamp(180px, 18vw, 200px);
    height: clamp(180px, 18vw, 200px);
  }
}

/* Large desktop */
@media (min-width: 1440px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Print optimizations */
@media print {
  .animated-bg,
  .floating-particles,
  .gradient-orbs,
  .grid-pattern {
    display: none !important;
  }
  
  .hero-title {
    background: none !important;
    -webkit-text-fill-color: initial !important;
    color: #000 !important;
  }
}

/* Scroll-triggered Animations */
.animate-in {
  animation: slideInUp 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes slideInUp {
  0% {
    opacity: 0;
    transform: translateY(60px) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.card {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.3s ease;
}

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

.skill-tag {
  opacity: 0;
  transform: translateY(20px) scale(0.9);
  transition: all 0.3s ease;
}

.skill-tag.animate-in {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Staggered animation delays */
.card:nth-child(1) { animation-delay: 0.1s; }
.card:nth-child(2) { animation-delay: 0.2s; }
.card:nth-child(3) { animation-delay: 0.3s; }
.card:nth-child(4) { animation-delay: 0.4s; }

.skill-tag:nth-child(1) { animation-delay: 0.05s; }
.skill-tag:nth-child(2) { animation-delay: 0.1s; }
.skill-tag:nth-child(3) { animation-delay: 0.15s; }
.skill-tag:nth-child(4) { animation-delay: 0.2s; }
.skill-tag:nth-child(5) { animation-delay: 0.25s; }

/* Enhanced hover effects for better interactivity */
.card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 60px rgba(59, 130, 246, 0.2);
}

.skill-tag:hover {
  transform: translateY(-4px) scale(1.1);
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.3);
}

/* Mobile Touch Improvements */
@media (max-width: 768px) {
  /* Disable custom cursor on mobile */
  html {
    cursor: auto !important;
  }
  
  .cursor,
  .cursor-follower {
    display: none !important;
  }
  
  /* Disable text selection on touch elements */
  .mobile-menu-btn,
  .mobile-nav-links a,
  .btn {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
  }
  
  /* Improve touch feedback */
  .btn:active,
  .mobile-nav-links a:active,
  .contact-link:active {
    transform: scale(0.98);
    transition: transform 0.1s ease;
  }
  
  /* Ensure minimum touch target sizes */
  .btn,
  .contact-link,
  .mobile-nav-links a {
    min-height: 44px;
    min-width: 44px;
  }
  
  /* Improve scroll behavior */
  html {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Add subtle vibration effect for supported devices */
  .mobile-menu-btn:active {
    animation: vibrate 0.1s ease-in-out;
  }
  
  @keyframes vibrate {
    0% { transform: translateX(0); }
    25% { transform: translateX(-1px); }
    50% { transform: translateX(1px); }
    75% { transform: translateX(-1px); }
    100% { transform: translateX(0); }
  }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-0 { margin-bottom: 0; }
.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }

.mt-0 { margin-top: 0; }
.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }

.hidden { display: none; }
.visible { display: block; }

/* High Performance Optimizations */
.gpu-accelerated {
  transform: translate3d(0, 0, 0);
  will-change: transform;
  backface-visibility: hidden;
}

/* Accessibility */
@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;
  }
}

/* Focus styles */
.btn:focus,
.nav-links a:focus,
.mobile-nav-links a:focus,
.contact-link:focus {
  outline: 2px solid var(--accent-primary);
  outline-offset: 2px;
}

/* Print styles */
@media print {
  .header,
  .mobile-nav,
  .scroll-to-top,
  .scroll-progress {
    display: none;
  }
  
  body {
    background: white;
    color: black;
  }
  
  .section {
    break-inside: avoid;
  }
}