/* Futuristic 3D Loader Styles */
.futuristic-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: radial-gradient(ellipse at center, #0a0a1a 0%, #000000 70%, #000000 100%);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  perspective: 1000px;
  transform-style: preserve-3d;
}

/* Hide scrollbar when loader is active */
body.loading {
  overflow: hidden;
}

.futuristic-loader::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 30% 30%, rgba(126, 239, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(255, 56, 251, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 50% 50%, rgba(37, 178, 243, 0.05) 0%, transparent 50%);
  animation: loader-bg-pulse 4s ease-in-out infinite;
}

@keyframes loader-bg-pulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.05); }
}

.loader-container {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* Holographic Sphere */
.holographic-sphere {
  position: relative;
  width: 200px;
  height: 200px;
  margin-bottom: 60px;
}


.sphere-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  border: 2px solid transparent;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: ring-rotate 6s linear infinite reverse;
}

.ring-1 {
  width: 120px;
  height: 120px;
  border-color: #7eefff;
  box-shadow: 0 0 20px #7eefff;
  animation-duration: 4s;
}

.ring-2 {
  width: 160px;
  height: 160px;
  border-color: #ff38fb;
  box-shadow: 0 0 25px #ff38fb;
  animation-duration: 6s;
  animation-direction: normal;
}

.ring-3 {
  width: 200px;
  height: 200px;
  border-color: #25b2f3;
  box-shadow: 0 0 30px #25b2f3;
  animation-duration: 8s;
}

@keyframes ring-rotate {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.sphere-particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.sphere-particles::before,
.sphere-particles::after {
  content: '';
  position: absolute;
  width: 4px;
  height: 4px;
  background: #7eefff;
  border-radius: 50%;
  box-shadow: 0 0 10px #7eefff;
  animation: particle-orbit 3s linear infinite;
  filter: blur(0.5px);
}

.sphere-particles::before {
  top: 20px;
  left: 50%;
  animation-delay: 0s;
}

.sphere-particles::after {
  bottom: 20px;
  left: 50%;
  animation-delay: 1.5s;
}

@keyframes particle-orbit {
  0% { transform: rotate(0deg) translateX(60px) rotate(0deg); }
  100% { transform: rotate(360deg) translateX(60px) rotate(-360deg); }
}

/* Animated Circuits */
.circuit-grid {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.circuit-line {
  position: absolute;
  background: linear-gradient(90deg, transparent, #7eefff, transparent);
  height: 2px;
  box-shadow: 0 0 10px #7eefff;
  animation: circuit-pulse 2s ease-in-out infinite;
}

.line-1 {
  top: 20%;
  left: 10%;
  width: 200px;
  animation-delay: 0s;
}

.line-2 {
  top: 60%;
  right: 15%;
  width: 180px;
  animation-delay: 0.5s;
}

.line-3 {
  bottom: 30%;
  left: 20%;
  width: 150px;
  animation-delay: 1s;
}

.line-4 {
  top: 40%;
  right: 25%;
  width: 120px;
  animation-delay: 1.5s;
}

@keyframes circuit-pulse {
  0%, 100% { opacity: 0.3; transform: scaleX(0.8); }
  50% { opacity: 1; transform: scaleX(1); }
}

.circuit-node {
  position: absolute;
  width: 8px;
  height: 8px;
  background: #ff38fb;
  border-radius: 50%;
  box-shadow: 0 0 15px #ff38fb;
  animation: node-pulse 1.5s ease-in-out infinite;
}

.node-1 { top: 15%; left: 15%; animation-delay: 0s; }
.node-2 { top: 25%; right: 20%; animation-delay: 0.3s; }
.node-3 { bottom: 25%; left: 25%; animation-delay: 0.6s; }
.node-4 { bottom: 35%; right: 30%; animation-delay: 0.9s; }
.node-5 { top: 50%; left: 10%; animation-delay: 1.2s; }
.node-6 { top: 70%; right: 15%; animation-delay: 1.5s; }

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

/* Neon Light Trails */
.neon-trails {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.trail {
  position: absolute;
  width: 3px;
  height: 100px;
  background: linear-gradient(to bottom, #7eefff, transparent);
  border-radius: 2px;
  box-shadow: 0 0 20px #7eefff;
  animation: trail-move 4s linear infinite;
}

.trail-1 {
  left: 20%;
  animation-delay: 0s;
}

.trail-2 {
  left: 40%;
  animation-delay: 1s;
}

.trail-3 {
  left: 60%;
  animation-delay: 2s;
}

.trail-4 {
  left: 80%;
  animation-delay: 3s;
}

@keyframes trail-move {
  0% { transform: translateY(-100px); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateY(100vh); opacity: 0; }
}

/* Shimmering Particles */
.particle-field {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.particle {
  position: absolute;
  width: 3px;
  height: 3px;
  background: #25b2f3;
  border-radius: 50%;
  box-shadow: 0 0 8px #25b2f3;
  animation: particle-float-loader 6s ease-in-out infinite;
}

.p1 { top: 10%; left: 10%; animation-delay: 0s; }
.p2 { top: 20%; left: 80%; animation-delay: 0.4s; }
.p3 { top: 30%; left: 30%; animation-delay: 0.8s; }
.p4 { top: 40%; left: 70%; animation-delay: 1.2s; }
.p5 { top: 50%; left: 20%; animation-delay: 1.6s; }
.p6 { top: 60%; left: 60%; animation-delay: 2s; }
.p7 { top: 70%; left: 40%; animation-delay: 2.4s; }
.p8 { top: 80%; left: 80%; animation-delay: 2.8s; }
.p9 { top: 15%; left: 50%; animation-delay: 3.2s; }
.p10 { top: 25%; left: 15%; animation-delay: 3.6s; }
.p11 { top: 35%; left: 85%; animation-delay: 4s; }
.p12 { top: 45%; left: 45%; animation-delay: 4.4s; }
.p13 { top: 55%; left: 75%; animation-delay: 4.8s; }
.p14 { top: 65%; left: 25%; animation-delay: 5.2s; }
.p15 { top: 75%; left: 65%; animation-delay: 5.6s; }

@keyframes particle-float-loader {
  0%, 100% { 
    transform: translateY(0px) translateX(0px); 
    opacity: 0.3; 
  }
  25% { 
    transform: translateY(-20px) translateX(10px); 
    opacity: 1; 
  }
  50% { 
    transform: translateY(-10px) translateX(-15px); 
    opacity: 0.7; 
  }
  75% { 
    transform: translateY(-30px) translateX(5px); 
    opacity: 0.9; 
  }
}

/* Loading Text */
.loading-text {
  display: flex;
  gap: 8px;
  margin-bottom: 40px;
  font-family: 'Orbitron', monospace;
  font-size: 18px;
  font-weight: 700;
  color: #7eefff;
  text-shadow: 0 0 10px #7eefff;
}

.loading-char {
  animation: char-pulse 1.5s ease-in-out infinite;
  opacity: 0.5;
}

.loading-char:nth-child(1) { animation-delay: 0s; }
.loading-char:nth-child(2) { animation-delay: 0.1s; }
.loading-char:nth-child(3) { animation-delay: 0.2s; }
.loading-char:nth-child(4) { animation-delay: 0.3s; }
.loading-char:nth-child(5) { animation-delay: 0.4s; }
.loading-char:nth-child(6) { animation-delay: 0.5s; }
.loading-char:nth-child(7) { animation-delay: 0.6s; }
.loading-char:nth-child(8) { animation-delay: 0.7s; }
.loading-char:nth-child(9) { animation-delay: 0.8s; }
.loading-char:nth-child(10) { animation-delay: 0.9s; }
.loading-char:nth-child(11) { animation-delay: 1s; }
.loading-char:nth-child(12) { animation-delay: 1.1s; }
.loading-char:nth-child(13) { animation-delay: 1.2s; }
.loading-char:nth-child(14) { animation-delay: 1.3s; }
.loading-char:nth-child(15) { animation-delay: 1.4s; }

@keyframes char-pulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.2); }
}

/* Progress Bar */
.progress-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.progress-bar {
  width: 300px;
  height: 6px;
  background: rgba(126, 239, 255, 0.2);
  border-radius: 3px;
  overflow: hidden;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #7eefff, #ff38fb, #25b2f3);
  border-radius: 3px;
  box-shadow: 0 0 10px #7eefff;
  animation: progress-fill 3s ease-in-out forwards;
}

@keyframes progress-fill {
  0% { width: 0%; }
  100% { width: 100%; }
}

.progress-text {
  font-family: 'Share Tech Mono', monospace;
  font-size: 14px;
  color: #7eefff;
  text-shadow: 0 0 5px #7eefff;
  animation: text-flicker 0.5s ease-in-out infinite;
}

@keyframes text-flicker {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* Main Content (initially hidden) */
.main-content {
  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.main-content.loaded {
  opacity: 1;
}

/* Minimal, sharp, modern terminal styles */
:root {
  --primary: #7eefff;
  --secondary: #ff38fb;
  --highlight: #25b2f3;
  --bg-dark: #090921;
}
body {
  font-family: 'Inter', Arial, sans-serif;
  background: linear-gradient(135deg, #0a0618 0%, #12002a 100%);
  color: #e6faff;
  margin: 0;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}
/* Futuristic background elements */
#particles-bg, #neon-grid, #neon-lines {
  position: fixed;
  top: 0; left: 0; width: 100vw; height: 100vh;
  z-index: 0;
  pointer-events: none;
  display: block;
}
/* Advanced Custom Cursor */
.cursor {
  position: fixed;
  top: 0; left: 0;
  width: 22px; height: 22px;
  background: radial-gradient(circle, #7eefff 0%, #ff38fb 80%);
  border-radius: 50%;
  pointer-events: none;
  transform: translate(-50%, -50%);
  mix-blend-mode: lighten;
  opacity: 0.9;
  z-index: 1001;
  box-shadow: 0 0 4px #7eefff44, 0 0 4px #ff38fb33;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  animation: cursor-pulse 2s ease-in-out infinite;
}
@keyframes cursor-pulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); }
  50% { transform: translate(-50%, -50%) scale(1.1); }
}
.cursor-hover {
  transform: translate(-50%, -50%) scale(1.25) !important;
  box-shadow: 0 0 12px #7eefff, 0 0 24px #ff38fb, 0 0 8px #25b2f3;
  opacity: 1;
}
.cursor-active {
  transform: translate(-50%, -50%) scale(0.92) !important;
  box-shadow: 0 0 18px #ff38fb, 0 0 32px #7eefff, 0 0 12px #25b2f3;
  opacity: 1;
}
/* Enhanced Navigation */
nav {
  width: 100%;
  height: 48px;
  background: linear-gradient(180deg, rgba(6, 10, 20, 0.86), rgba(6, 10, 20, 0.72));
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0; left: 0; z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
  font-weight: 600;
  letter-spacing: 0.05em;
  font-size: 14px;
  border-bottom: 1px solid rgba(126, 239, 255, 0.2);
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.24);
}
nav .nav-link {
  color: #f8f8f2;
  text-decoration: none;
  padding: 6px 14px;
  border-radius: 4px;
  transition: all 0.2s ease;
  margin: 0 4px;
  border: none;
  outline: none;
  background: none;
  cursor: pointer;
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
  font-weight: 600;
  letter-spacing: 0.05em;
  font-size: 14px;
  position: relative;
  overflow: hidden;
}
nav .nav-link::before {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #7eefff, #ff38fb);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}
nav .nav-link:hover::before,
nav .nav-link.active::before {
  width: 100%;
}
nav .nav-link:hover, nav .nav-link.active {
  color: #7eefff;
  background: rgba(126,239,255,0.1);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(126, 239, 255, 0.3);
}

/* Neon sliding effect for navigation links */
nav .nav-link::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(126, 239, 255, 0.6), 
    rgba(255, 56, 251, 0.6), 
    rgba(126, 239, 255, 0.6), 
    transparent);
  transition: left 0.6s ease;
  box-shadow: 0 0 20px rgba(126, 239, 255, 0.4);
  opacity: 0;
}

nav .nav-link:hover::after {
  left: 100%;
  opacity: 1;
}
/* Enhanced Header */
header {
  text-align: center;
  margin: 1.1rem 0 0.7rem 0;
  padding: 0;
  z-index: 2;
  position: relative;
}
header p {
  margin-top: 1.2rem;
  color: var(--secondary);
  font-size: 1.15em;
  font-family: 'Share Tech Mono', monospace;
  font-weight: normal;
  animation: neon-pulse 3s ease-in-out infinite;
}
@keyframes neon-pulse {
  0%, 100% { opacity: 0.8; }
  50% { opacity: 1; }
}
/* Main content */
main {
  max-width: 980px;
  margin: auto;
  padding: 1rem;
  position: relative;
  z-index: 2;
}
/* Real Terminal Styling - Authentic Terminal Appearance */
.terminal {
  background: #0c0c0c;
  color: #f8f8f2;
  border-radius: 6px;
  max-width: 100%;
  margin: 1.2rem auto;
  font-size: clamp(0.98rem, 2.8vw, 1.08em) !important;
  border: 1px solid #333;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
  transition: all 0.2s ease;
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
}
.terminal::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: 
    linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.02) 50%, transparent 70%);
  animation: scan-line 4s linear infinite;
  pointer-events: none;
  z-index: 1;
}
@keyframes scan-line {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100%); }
}
.terminal:hover {
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
  transform: translateY(-1px);
}
.terminal-header {
  background: #2d2d2d;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  border-radius: 6px 6px 0 0;
  border-bottom: 1px solid #444;
  position: relative;
  z-index: 2;
  font-size: 12px;
}
.terminal-header::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  animation: header-scan 3s linear infinite;
}
@keyframes header-scan {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}
.terminal-header .dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
  transition: all 0.2s ease;
  position: relative;
}
.terminal-header .dot::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 0; height: 0;
  background: currentColor;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.2s ease;
  opacity: 0;
}
.terminal-header .dot:hover::after {
  width: 16px; height: 16px;
  opacity: 0.2;
}
.terminal-header .dot:hover {
  transform: scale(1.1);
}
.terminal-header .dot.red { background: #ff5f56; }
.terminal-header .dot.yellow { background: #ffbd2e; }
.terminal-header .dot.green { background: #27c93f; }
.terminal-header .title {
  margin-left: 8px;
  color: #ccc;
  font-size: clamp(0.95rem, 2.2vw, 1.12rem) !important;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 500;
  position: relative;
  z-index: 2;
}
.terminal-body {
  padding: 16px 20px 12px 20px;
  min-height: 120px;
  font-size: clamp(0.98rem, 2.5vw, 1.08em) !important;
  line-height: 1.7;
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
  color: #f8f8f2;
  background: #0c0c0c;
  border-radius: 0 0 6px 6px;
  position: relative;
  z-index: 2;
}
.terminal-body *,
.terminal-body *:hover,
.terminal-body *:focus,
.terminal-body *:active {
  text-shadow: none !important;
  filter: none !important;
  color: #f8f8f2 !important;
  background: none !important;
  box-shadow: none !important;
}
.terminal-body .prompt {
  font-weight: bold;
  margin-right: 0.5em;
  color: #66d9ef;
  letter-spacing: 0.05em;
}
.terminal-body .output {
  color: #f8f8f2;
  white-space: pre-line;
  margin-left: 1.4em;
  font-size: 14px;
  letter-spacing: 0.02em;
  margin-bottom: 0.18em;
}
.terminal-body .output .var,
.terminal-body .output .skill {
  color: #a6e22e;
  font-weight: bold;
}
.terminal-body .output span.cmd { color: #f92672; font-weight: bold;}
.terminal-body .output span.proj { color: #fd971f; font-weight: bold;}
/* Real Terminal Commands */
.commands {
  margin-top: 1.2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

/* Neon sliding effect for all terminal buttons */
.commands button,
.tools-tech-commands button,
.projects-commands button,
.contact-commands button {
  position: relative;
  overflow: hidden;
}

.commands button::after,
.tools-tech-commands button::after,
.projects-commands button::after,
.contact-commands button::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(126, 239, 255, 0.8), 
    rgba(255, 56, 251, 0.8), 
    rgba(126, 239, 255, 0.8), 
    transparent);
  transition: left 0.8s ease;
  box-shadow: 0 0 25px rgba(126, 239, 255, 0.6);
  opacity: 0;
}

.commands button:hover::after,
.tools-tech-commands button:hover::after,
.projects-commands button:hover::after,
.contact-commands button:hover::after {
  left: 100%;
  opacity: 1;
}

/* Pulsing neon border effect */
.commands button:hover,
.tools-tech-commands button:hover,
.projects-commands button:hover,
.contact-commands button:hover {
  animation: neon-pulse-border 1.5s ease-in-out infinite;
}

@keyframes neon-pulse-border {
  0%, 100% { 
    border-color: #7eefff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 15px rgba(126, 239, 255, 0.3);
  }
  50% { 
    border-color: #ff38fb;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 20px rgba(255, 56, 251, 0.4);
  }
}
.commands button {
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
  font-size: 13px;
  font-weight: 500;
  background: #2d2d2d;
  color: #f8f8f2;
  border: 1px solid #444;
  padding: 6px 12px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  outline: none;
  position: relative;
  overflow: hidden;
}
.commands button::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(126, 239, 255, 0.6), 
    rgba(255, 56, 251, 0.6), 
    rgba(126, 239, 255, 0.6), 
    transparent);
  transition: left 0.6s ease;
  box-shadow: 0 0 20px rgba(126, 239, 255, 0.4);
}
.commands button:hover::before {
  left: 100%;
}
.commands button:hover, .commands button:focus {
  background: #3d3d3d;
  color: #ffffff;
  border-color: #7eefff;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 15px rgba(126, 239, 255, 0.3);
}
/* Real Terminal Command Sections */
.tools-tech-commands,
.projects-commands,
.contact-commands {
  display: flex;
  gap: 0.8rem;
  margin: 1.2em 0 0.5em 0;
  justify-content: flex-start;
  flex-wrap: wrap;
}
.tools-tech-commands button,
.projects-commands button,
.contact-commands button {
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
  font-size: 13px;
  font-weight: 500;
  background: #2d2d2d;
  color: #f8f8f2;
  border: 1px solid #444;
  border-radius: 4px;
  padding: 6px 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  outline: none;
  letter-spacing: 0.02em;
  margin-bottom: 0.2em;
  position: relative;
  overflow: hidden;
}
.tools-tech-commands button::before,
.projects-commands button::before,
.contact-commands button::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(126, 239, 255, 0.6), 
    rgba(255, 56, 251, 0.6), 
    rgba(126, 239, 255, 0.6), 
    transparent);
  transition: left 0.6s ease;
  box-shadow: 0 0 20px rgba(126, 239, 255, 0.4);
}
.tools-tech-commands button:hover::before,
.projects-commands button:hover::before,
.contact-commands button:hover::before {
  left: 100%;
}
.tools-tech-commands button:hover,
.projects-commands button:hover,
.contact-commands button:hover,
.tools-tech-commands button.active,
.projects-commands button.active,
.contact-commands button.active {
  background: #3d3d3d;
  color: #ffffff;
  border-color: #7eefff;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 15px rgba(126, 239, 255, 0.3);
}
.tools-tech-output,
.projects-output {
  min-height: 7em;
  margin-top: 0.5em;
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
  color: #f8f8f2;
}
.about-output {
  min-height: 0;
  margin-top: 0.5em;
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Source Code Pro', monospace;
  color: #f8f8f2;
}

/* Animated multi-layered background gradients */
body::before, body::after {
  content: '';
  position: fixed;
  top: 0; left: 0; width: 100vw; height: 100vh;
  z-index: -2;
  pointer-events: none;
  transition: opacity 0.7s;
}
body::before {
  background: linear-gradient(120deg, #090921 0%, #180034 100%);
  opacity: 1;
  animation: bg-gradient-move 18s ease-in-out infinite alternate;
}
body::after {
  background: radial-gradient(circle at 20% 80%, rgba(126,239,255,0.13) 0%, transparent 60%),
              radial-gradient(circle at 80% 20%, rgba(255,56,251,0.11) 0%, transparent 60%),
              radial-gradient(circle at 40% 40%, rgba(37,178,243,0.07) 0%, transparent 60%);
  opacity: 0.7;
  animation: bg-radial-move 22s ease-in-out infinite alternate;
}
@keyframes bg-gradient-move {
  0% { filter: hue-rotate(0deg) brightness(1); }
  100% { filter: hue-rotate(30deg) brightness(1.08); }
}
@keyframes bg-radial-move {
  0% { filter: blur(0px) brightness(1); }
  100% { filter: blur(2px) brightness(1.1); }
}

/* Neon grid overlay */
#neon-grid {
  mix-blend-mode: lighten;
  opacity: .22;
  z-index: 0;
  pointer-events: none;
}
#neon-lines {
  z-index: 1;
  opacity: 0.6;
  pointer-events: none;
  mix-blend-mode: lighten;
}

/* Section fade-in animation */
section {
  opacity: 0;
  transform: translateY(50px) scale(0.97);
  animation: section-fadein 1.2s cubic-bezier(.4,1.4,.6,1) forwards;
  filter: blur(5px);
}
@keyframes section-fadein {
  to {
    opacity: 1;
    transform: none;
    filter: blur(0);
  }
}

/* Responsive */
@media (max-width: 700px) {
  .terminal { font-size: 13px; }
  .terminal-header .title { font-size: 11px; }
  .terminal-body { font-size: 13px; padding: 12px 16px 8px 16px; }
  nav { gap: 1rem; font-size: 13px; }
  nav .nav-link { font-size: 13px; padding: 6px 12px; }
}


/* Futuristic Button Styles */
.commands button, .tools-tech-commands button, .projects-commands button, .contact-commands button {
  font-family: 'Share Tech Mono', 'JetBrains Mono', monospace;
  font-size: 1.13em;
  font-weight: bold;
  background: linear-gradient(90deg, rgba(126,239,255,0.13), rgba(255,56,251,0.13));
  color: #7eefff;
  border: 1.5px solid #23234a;
  border-radius: 8px;
  padding: 0.38em 1.2em;
  cursor: pointer;
  transition: all 0.33s cubic-bezier(.4,1.4,.6,1);
  outline: none;
  letter-spacing: 0.04em;
  margin-bottom: 0.2em;
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 12px 0 rgba(126,239,255,0.08);
  z-index: 2;
}
.commands button::after, .tools-tech-commands button::after, .projects-commands button::after, .contact-commands button::after {
  content: '';
  position: absolute;
  left: 50%; top: 50%;
  width: 0; height: 0;
  background: radial-gradient(circle, #7eefff44 10%, #ff38fb22 60%, transparent 100%);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  opacity: 0;
  transition: width 0.5s, height 0.5s, opacity 0.5s;
  z-index: 1;
}
.commands button:hover::after, .tools-tech-commands button:hover::after, .projects-commands button:hover::after, .contact-commands button:hover::after {
  width: 300px;
  height: 300px;
  opacity: 0.18;
}
.commands button:hover, .tools-tech-commands button:hover, .projects-commands button:hover, .contact-commands button:hover {
  background: linear-gradient(90deg, #7eefff22 0%, #ff38fb22 100%);
  color: #ff38fb;
  border-color: #7eefff;
  box-shadow: 0 6px 24px 0 #7eefff33, 0 2px 8px 0 #ff38fb22;
  transform: translateY(-2px) scale(1.04);
}
.commands button:active, .tools-tech-commands button:active, .projects-commands button:active, .contact-commands button:active {
  filter: brightness(1.18) blur(0.2px);
  box-shadow: 0 2px 8px #ff38fb22;
}

/* Glowing Card Styles */

/* Animated SVG/Icon Effects */
.fab {
  transition: color 0.3s, filter 0.3s, transform 0.3s;
  filter: drop-shadow(0 0 2px #7eefff) drop-shadow(0 0 4px #ff38fb);
}
.fab:hover {
  color: #ff38fb;
  filter: drop-shadow(0 0 6px #ff38fb) drop-shadow(0 0 12px #7eefff);
  transform: scale(1.18) rotate(-6deg);
}


/* Futuristic Scrollbar */
::-webkit-scrollbar {
  width: 10px;
  background: #181828;
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(120deg, #7eefff 0%, #ff38fb 100%);
  border-radius: 8px;
  box-shadow: 0 0 8px #7eefff44;
}
::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(120deg, #ff38fb 0%, #7eefff 100%);
}


/* Glitch/Scanline Text Effects */
/* Stronger glitch effect for .glitch-text */
.glitch-text {
  position: relative;
  color: #7eefff;
  font-family: 'Orbitron', 'Share Tech Mono', monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  animation: glitch-flicker 1.2s infinite linear alternate;
  font-weight: 700;
  font-size: 3.2rem;
  z-index: 2;
}
.glitch-text::before, .glitch-text::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.85;
  pointer-events: none;
  mix-blend-mode: lighten;
  line-height: 1;
}
.glitch-text::before {
  color: #ff38fb;
  z-index: 3;
  left: 3.5px;
  text-shadow: 2px 0 8px #ff38fb, 0 0 6px #ff38fb;
  animation: glitch-anim-1 0.19s infinite linear alternate-reverse;
}
.glitch-text::after {
  color: #7eefff;
  z-index: 3;
  left: -3.5px;
  text-shadow: -2px 0 8px #7eefff, 0 0 6px #7eefff;
  animation: glitch-anim-2 0.17s infinite linear alternate;
}
@keyframes glitch-flicker {
  0%, 100% { opacity: 1; }
  20% { opacity: 0.7; }
  22% { opacity: 1; }
  25% { opacity: 0.5; }
  30% { opacity: 1; }
  45% { opacity: 0.8; }
  50% { opacity: 0.6; }
  55% { opacity: 0.8; }
  60% { opacity: 1; }
  80% { opacity: 0.7; }
}
@keyframes glitch-anim-1 {
  0%   { clip-path: inset(0 0 100% 0); transform: translate(0,0) skew(0deg); }
  10%  { clip-path: inset(6% 0 58% 0); transform: translate(-4px,1px) skew(-2deg); }
  20%  { clip-path: inset(14% 0 46% 0); transform: translate(4px,-2px) skew(2deg); }
  30%  { clip-path: inset(22% 0 34% 0); transform: translate(-2px,2px) skew(-4deg); }
  40%  { clip-path: inset(30% 0 26% 0); transform: translate(2px,-2px) skew(4deg); }
  50%  { clip-path: inset(38% 0 18% 0); transform: translate(-4px,1px) skew(-2deg); }
  60%  { clip-path: inset(46% 0 12% 0); transform: translate(4px,-2px) skew(2deg); }
  70%  { clip-path: inset(54% 0 8% 0); transform: translate(-2px,2px) skew(-4deg); }
  80%  { clip-path: inset(62% 0 4% 0); transform: translate(2px,-2px) skew(4deg); }
  90%  { clip-path: inset(70% 0 0 0); transform: translate(-4px,1px) skew(-2deg); }
  100% { clip-path: inset(0 0 100% 0); transform: translate(0,0) skew(0deg); }
}
@keyframes glitch-anim-2 {
  0%   { clip-path: inset(0 0 100% 0); transform: translate(0,0) skew(0deg); }
  8%   { clip-path: inset(8% 0 72% 0); transform: translate(4px,-2px) skew(2deg); }
  16%  { clip-path: inset(16% 0 62% 0); transform: translate(-4px,2px) skew(-2deg); }
  24%  { clip-path: inset(24% 0 52% 0); transform: translate(2px,4px) skew(4deg); }
  32%  { clip-path: inset(32% 0 42% 0); transform: translate(-2px,-4px) skew(-4deg); }
  40%  { clip-path: inset(40% 0 34% 0); transform: translate(4px,2px) skew(2deg); }
  48%  { clip-path: inset(48% 0 26% 0); transform: translate(-4px,-2px) skew(-2deg); }
  56%  { clip-path: inset(56% 0 18% 0); transform: translate(2px,4px) skew(4deg); }
  64%  { clip-path: inset(64% 0 10% 0); transform: translate(-2px,-4px) skew(-4deg); }
  72%  { clip-path: inset(72% 0 4% 0); transform: translate(4px,2px) skew(2deg); }
  80%  { clip-path: inset(80% 0 0 0); transform: translate(-4px,-2px) skew(-2deg); }
  88%  { clip-path: inset(10% 0 70% 0); transform: translate(2px,4px) skew(4deg); }
  96%  { clip-path: inset(18% 0 60% 0); transform: translate(-2px,-4px) skew(-4deg); }
  100% { clip-path: inset(0 0 100% 0); transform: translate(0,0) skew(0deg); }
}


.glitch-text {
  display: inline-block;
  color: #7eefff;
  font-family: 'Orbitron', 'Share Tech Mono', monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  animation: glitch-flicker 1.2s infinite linear alternate;
  font-weight: 700;
  font-size: 3.2rem;
  z-index: 2;
}
.glitch-text:hover {
  background: rgba(126, 63, 255, 0.22);
  box-shadow: 0 0 12px #7e3fff, 0 0 18px #ff38fb33;
  border-radius: 6px;
  padding: 0.1em 0.4em;
  transition: background 0.18s, box-shadow 0.18s, border-radius 0.18s, padding 0.18s;
}


/* Advanced Animation Library */
@keyframes neon-pulse {
  0%, 100% { 
    box-shadow: 0 0 5px #7eefff, 0 0 10px #7eefff, 0 0 15px #7eefff;
  }
  50% { 
    box-shadow: 0 0 10px #7eefff, 0 0 20px #7eefff, 0 0 30px #7eefff;
  }
}
/* Neon title line effect for fit-content width */
.neon-title-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: fit-content;
  margin: 0 auto 0.75rem auto;
  position: relative;
  z-index: 2;
}
.neon-title {
  background: #181828;
  color: #7eefff;
  font-family: 'Share Tech Mono', monospace;
  font-size: 1.35rem;
  padding: 0.18em 1.1em;
  border-radius: 4px;
  position: relative;
  z-index: 2;
  box-shadow: 0 0 12px #7eefff, 0 0 24px #7eefff44;
  letter-spacing: 0.04em;
  font-weight: 600;
}
.neon-title-container::before,
.neon-title-container::after {
  content: '';
  display: block;
  position: absolute;
  left: 0; right: 0;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, #7eefff, transparent);
  filter: blur(2px);
  z-index: 1;
}
.neon-title-container::before { top: 0; }
.neon-title-container::after { bottom: 0; }

footer {
  width: 100%;
  text-align: center;
  margin: 2.5rem 0 0 0;
  padding: 1.2rem 0 0.7rem 0;
  background: none;
  position: relative;
  z-index: 2;
}
footer p {
  display: inline-block;
  color: #7eefff;
  font-family: 'Share Tech Mono', monospace;
  font-size: 1.08em;
  letter-spacing: 0.04em;
  position: relative;
  background: #181828;
  border-radius: 4px;
  padding: 0.3em 1.2em;
  overflow: hidden;
}
footer p::before, footer p::after {
  content: '';
  position: absolute;
  top: 0; width: 50%; height: 100%;
  opacity: 0.7;
  z-index: 1;
  pointer-events: none;
}
footer p::before {
  left: 0;
  background: linear-gradient(90deg, #7eefff, transparent);
  animation: footer-neon-slide-left 2.2s cubic-bezier(.4,1.4,.6,1) infinite;
}
footer p::after {
  right: 0;
  background: linear-gradient(270deg, #ff38fb, transparent);
  animation: footer-neon-slide-right 2.2s cubic-bezier(.4,1.4,.6,1) infinite;
}
@keyframes footer-neon-slide-left {
  0% { left: -50%; opacity: 0; }
  30% { left: 0; opacity: 0.7; }
  60% { left: 0; opacity: 0.7; }
  100% { left: 0; opacity: 0; }
}
@keyframes footer-neon-slide-right {
  0% { right: -50%; opacity: 0; }
  30% { right: 0; opacity: 0.7; }
  60% { right: 0; opacity: 0.7; }
  100% { right: 0; opacity: 0; }
}

/* Animated Neon Particles Overlay */
.particle-system {
  position: fixed;
  top: 0; left: 0; width: 100vw; height: 100vh;
  pointer-events: none;
  z-index: 0;
}
.particle {
  position: absolute;
  width: 2.5px;
  height: 2.5px;
  border-radius: 50%;
  background: #7eefff;
  opacity: 0.7;
  animation: particle-float 10s linear infinite;
}
.particle:nth-child(odd) {
  background: #ff38fb;
  animation-duration: 14s;
}
.particle:nth-child(3n) {
  background: #25b2f3;
  animation-duration: 12s;
}
@keyframes particle-float {
  0% {
    transform: translateY(100vh) translateX(var(--x-start, 0px));
    opacity: 0;
  }
  10% {
    opacity: 0.7;
  }
  90% {
    opacity: 0.7;
  }
  100% {
    transform: translateY(-10vh) translateX(var(--x-end, 100px));
    opacity: 0;
  }
}

nav, header, main, footer, .terminal {
  position: relative;
  z-index: 2;
}

/* Responsive ZEROCIPHERX glitch text */
.glitch-text {
  font-size: clamp(1.6rem, 7vw, 3.2rem);
  padding: 0.08em 0.2em;
}

/* Responsive terminal */
.terminal {
  font-size: clamp(0.95rem, 2.8vw, 1.08em);
  max-width: 98vw;
}
.terminal-header .title {
  font-size: clamp(0.85rem, 2.2vw, 1.12rem);
}
.terminal-body {
  font-size: clamp(0.93rem, 2.5vw, 1.08em);
  padding: clamp(0.7rem, 3vw, 1.2rem) clamp(0.6rem, 3vw, 1.1rem) clamp(0.3rem, 2vw, 0.5rem) clamp(0.6rem, 3vw, 1.1rem);
}

/* Responsive terminal buttons */
.commands button,
.tools-tech-commands button,
.projects-commands button,
.contact-commands button {
  font-size: clamp(0.95rem, 2.5vw, 1.13em);
  padding: clamp(0.28rem, 1.5vw, 0.38rem) clamp(0.7rem, 3vw, 1.1rem);
}

/* Responsive header and neon title */
header {
  margin: clamp(0.75rem, 4vw, 1.1rem) 0 clamp(0.45rem, 2.5vw, 0.7rem) 0;
}
.neon-title {
  font-size: clamp(1.05rem, 4vw, 1.35rem);
  padding: 0.18em clamp(0.7em, 3vw, 1.1em);
}

/* Responsive footer */
footer {
  margin: clamp(1.2rem, 6vw, 2.5rem) 0 0 0;
  padding: clamp(0.7rem, 3vw, 1.2rem) 0 clamp(0.3rem, 2vw, 0.7rem) 0;
}
footer p {
  font-size: clamp(0.93rem, 2.5vw, 1.08em);
  padding: 0.3em clamp(0.7em, 3vw, 1.2em);
}

@media (max-width: 700px) {
  nav { gap: 0.7rem; font-size: 13px; }
  nav .nav-link { font-size: 13px; padding: 6px 10px; }
  .neon-title { font-size: 1rem; }
  .terminal { font-size: 0.93rem; }
  .terminal-header .title { font-size: 0.85rem; }
  .terminal-body { font-size: 0.93rem; padding: 0.7rem 0.6rem 0.3rem 0.6rem; }
  .commands button,
  .tools-tech-commands button,
  .projects-commands button,
  .contact-commands button { font-size: 0.95rem; padding: 0.28rem 0.7rem; }
  footer p { font-size: 0.93rem; padding: 0.3em 0.7em; }
}

#sphere3d {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 80px;
  height: 80px;
  transform: translate(-50%, -50%);
  z-index: 2;
  border-radius: 50%;
  background: transparent;
  pointer-events: none;
}

/* --- Mobile-First Stability Overrides --- */
/* Keep full-screen effects stable on mobile browsers with dynamic toolbars */
.futuristic-loader,
#particles-bg,
#neon-grid,
#neon-lines,
.particle-system {
  height: 100dvh;
}

/* Prevent long content from overflowing terminal cards */
.terminal-body,
.terminal-body .output,
.tools-tech-output,
.projects-output,
.contact-output {
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* Responsive navigation without clipping when links wrap */
nav {
  height: auto;
  min-height: 48px;
  padding: 0.45rem 0.75rem;
  flex-wrap: wrap;
}

/* Better touch target sizes */
nav .nav-link {
  min-height: 34px;
}

.commands button,
.tools-tech-commands button,
.projects-commands button,
.contact-commands button {
  min-height: 40px;
}

/* Tablet and down */
@media (max-width: 900px) {
  main {
    padding: 0.8rem;
  }

  .terminal {
    margin: 1.2rem auto;
  }

  .terminal-body .output {
    margin-left: 0.6em;
  }
}

/* Phone */
@media (max-width: 700px) {
  .holographic-sphere {
    width: 160px;
    height: 160px;
    margin-bottom: 36px;
  }

  .ring-1 { width: 96px; height: 96px; }
  .ring-2 { width: 128px; height: 128px; }
  .ring-3 { width: 160px; height: 160px; }

  .loading-text {
    font-size: 14px;
    gap: 5px;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 90vw;
  }

  .progress-bar {
    width: min(86vw, 300px);
  }

  nav {
    justify-content: center;
    gap: 0.38rem;
    min-height: 46px;
    padding-top: 0.2rem;
    padding-bottom: 0.2rem;
  }

  nav .nav-link {
    padding: 0.34rem 0.6rem;
    font-size: 0.79rem;
    margin: 0 1px;
    border-radius: 8px;
  }

  .commands,
  .tools-tech-commands,
  .projects-commands,
  .contact-commands {
    gap: 0.5rem;
  }

  .commands button,
  .tools-tech-commands button,
  .projects-commands button,
  .contact-commands button {
    flex: 1 1 calc(50% - 0.5rem);
    text-align: center;
    min-width: 0;
  }

  .terminal-header {
    padding: 8px 10px;
  }

  .terminal-header .title {
    margin-left: 6px;
    font-size: 0.82rem !important;
  }

  .terminal-body {
    line-height: 1.55;
  }

  footer {
    padding-left: 0.6rem;
    padding-right: 0.6rem;
  }

  header {
    margin: 0.75rem 0 0.65rem 0;
  }
}

/* Small phones */
@media (max-width: 480px) {
  .commands button,
  .tools-tech-commands button,
  .projects-commands button,
  .contact-commands button {
    flex-basis: 100%;
    width: 100%;
  }

  .terminal-body .output {
    margin-left: 0;
    font-size: 0.92rem;
  }

  .loading-text {
    font-size: 12.5px;
    letter-spacing: 0.02em;
  }

  .progress-text {
    font-size: 12px;
  }

  #sphere3d {
    width: 62px;
    height: 62px;
  }
}

/* Touch devices: disable custom cursor visuals and hover-only effects */
@media (hover: none), (pointer: coarse) {
  .cursor {
    display: none !important;
  }

  nav .nav-link::after,
  .commands button::after,
  .tools-tech-commands button::after,
  .projects-commands button::after,
  .contact-commands button::after {
    display: none;
  }
}

/* Final compact header tuning (kept at file end to win cascade) */
nav {
  height: 44px !important;
  min-height: 44px !important;
  padding: 0 0.75rem !important;
  flex-wrap: nowrap !important;
}

nav .nav-link {
  padding: 0.28rem 0.7rem !important;
  min-height: 30px !important;
  font-size: 0.95rem;
}

header {
  margin: 0.55rem 0 0.4rem 0 !important;
}

.neon-title-container {
  margin: 0 auto 0.45rem auto !important;
}

.terminal {
  margin: 0.95rem auto !important;
}

@media (max-width: 900px) {
  nav {
    height: auto !important;
    min-height: 44px !important;
    flex-wrap: wrap !important;
    padding: 0.2rem 0.55rem !important;
  }

  nav .nav-link {
    font-size: 0.84rem !important;
  }
}

/* Unified logo glitch: same rendering model on desktop + mobile */
.glitch-text {
  position: relative !important;
  display: inline-block !important;
  width: max-content;
  margin-inline: auto;
  white-space: nowrap;
  line-height: 1;
  overflow: visible;
  color: #7eefff;
  font-family: 'Orbitron', 'Share Tech Mono', monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  animation: glitch-flicker 1.2s infinite linear alternate;
  font-size: clamp(2rem, 8.5vw, 3.2rem) !important;
  z-index: 2;
}

.glitch-text::before,
.glitch-text::after {
  content: attr(data-text);
  display: block;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100%;
  height: 100%;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  white-space: inherit;
  line-height: inherit;
  pointer-events: none;
  opacity: 0.85;
  mix-blend-mode: lighten;
}

.glitch-text::before {
  color: #ff38fb;
  transform: translateX(3.5px);
  text-shadow: 2px 0 8px #ff38fb, 0 0 6px #ff38fb;
  animation: glitch-anim-1 0.19s infinite linear alternate-reverse;
}

.glitch-text::after {
  color: #7eefff;
  transform: translateX(-3.5px);
  text-shadow: -2px 0 8px #7eefff, 0 0 6px #7eefff;
  animation: glitch-anim-2 0.17s infinite linear alternate;
}
