/* 
  =========================================
  Dinesh Balaji K - Premium Portfolio CSS
  Theme: Cyber Modern Glassmorphism (Awwwards/Stripe Inspired)
  =========================================
*/

/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@300;400;500;600;700&family=Inter:wght@300;400;500;600;700;800&family=Sora:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@400;500;600;700&display=swap');

/* CSS Variables for Theme Management */
:root {
  /* Colors - Honey Bee Dark Theme (Default) */
  --bg-color: #0c0b05;
  --bg-secondary: #16140b;
  --card-bg: rgba(255, 215, 0, 0.02);
  --card-bg-hover: rgba(255, 215, 0, 0.06);
  --card-border: rgba(255, 215, 0, 0.05);
  --card-border-hover: rgba(255, 179, 0, 0.22);
  --text-color: #fffdf0;
  --text-secondary: #c9bf9e;
  --shadow-color: rgba(0, 0, 0, 0.6);
  
  /* Honey Bee Accent Colors */
  --primary: #ffb300;
  --primary-rgb: 255, 179, 0;
  --accent: #ff8f00;
  --accent-rgb: 255, 143, 0;
  --highlight: #ffd54f;
  --success: #00d084;
  --dark-glow: radial-gradient(circle at 50% 50%, rgba(255, 179, 0, 0.08) 0%, transparent 60%);
  --accent-glow: radial-gradient(circle at 50% 50%, rgba(255, 143, 0, 0.1) 0%, transparent 70%);

  /* Typography */
  --font-heading: 'Sora', 'Space Grotesk', 'Inter', sans-serif;
  --font-body: 'Inter', 'IBM Plex Sans', sans-serif;

  /* Layout Constants */
  --container-max-width: 1200px;
  --border-radius-sm: 8px;
  --border-radius-md: 16px;
  --border-radius-lg: 24px;
  
  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-normal: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 0.8s cubic-bezier(0.16, 1, 0.3, 1);

  /* Scroll Progress */
  --scroll-progress: 0%;
}

/* Honey Bee Light Theme Overrides */
[data-theme="light"] {
  --bg-color: #fffdf6;
  --bg-secondary: #fbf6e3;
  --card-bg: rgba(94, 76, 20, 0.02);
  --card-bg-hover: rgba(94, 76, 20, 0.06);
  --card-border: rgba(94, 76, 20, 0.07);
  --card-border-hover: rgba(255, 179, 0, 0.32);
  --text-color: #2b2310;
  --text-secondary: #756a4e;
  --shadow-color: rgba(94, 76, 20, 0.08);
  --dark-glow: radial-gradient(circle at 50% 50%, rgba(255, 179, 0, 0.04) 0%, transparent 60%);
  --accent-glow: radial-gradient(circle at 50% 50%, rgba(255, 143, 0, 0.04) 0%, transparent 70%);
}

/* Global resets & scroll behavior */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-padding-top: 80px;
  overflow-x: hidden;
}

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  font-family: var(--font-body);
  line-height: 1.6;
  transition: background-color var(--transition-normal), color var(--transition-normal);
}

/* Official Lenis CSS Overrides */
html.lenis, html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overflow: clip;
}

.lenis.lenis-stopped {
  overflow: hidden;
}

.lenis.lenis-scrolling iframe {
  pointer-events: none;
}

/* Smooth selection colors */
::selection {
  background-color: rgba(79, 140, 255, 0.3);
  color: var(--text-color);
}

/* Hide scrollbar but keep functionality for customized aesthetic */
body::-webkit-scrollbar {
  width: 6px;
}
body::-webkit-scrollbar-track {
  background: var(--bg-color);
}
body::-webkit-scrollbar-thumb {
  background: var(--card-border-hover);
  border-radius: 10px;
}
body::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

/* Base structural styles */
section {
  padding: 100px 20px;
  position: relative;
  width: 100%;
}

.container {
  max-width: var(--container-max-width);
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

/* Typography styles */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

.hero-location-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  margin-bottom: 18px;
  border-radius: 999px;
  background: rgba(255, 179, 0, 0.12);
  border: 1px solid rgba(255, 179, 0, 0.2);
  color: var(--text-secondary);
  font-size: 0.92rem;
  width: fit-content;
}

.hero-location-pill svg {
  width: 18px;
  height: 18px;
  color: var(--primary);
  flex-shrink: 0;
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 50%, var(--highlight) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  display: inline-block;
}

.neon-text-glow {
  text-shadow: 0 0 20px rgba(0, 229, 255, 0.4);
}

.subtitle {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 10px auto 40px auto;
  text-align: center;
}

.section-title {
  font-size: 2.8rem;
  text-align: center;
  margin-bottom: 10px;
  letter-spacing: -0.5px;
}

/* Background Glow Effects */
.bg-glow-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
  pointer-events: none;
}

.bg-glow-circle {
  position: absolute;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.35;
  mix-blend-mode: screen;
  pointer-events: none;
}

.bg-glow-1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
  top: 10%;
  right: -10%;
}

.bg-glow-2 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
  bottom: 20%;
  left: -15%;
}

.bg-glow-3 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--highlight) 0%, transparent 70%);
  top: 50%;
  right: 20%;
  opacity: 0.15;
}

/* Custom Interactive Cursor Glow */
.cursor-glow {
  position: fixed;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(79, 140, 255, 0.08) 0%, rgba(139, 92, 246, 0.04) 35%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.3s ease, height 0.3s ease;
  mix-blend-mode: screen;
  display: none; /* Enabled via JS on desktop */
}

/* Top Reading Progress Bar */
.reading-progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(to right, var(--primary), var(--accent), var(--highlight));
  width: var(--scroll-progress);
  z-index: 1001;
  transition: width 0.1s linear;
}

/* Custom Preloader */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-color);
  z-index: 99999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.loader-logo {
  font-family: var(--font-heading);
  font-size: 5rem;
  font-weight: 800;
  color: var(--text-color);
  position: relative;
  margin-bottom: 20px;
  letter-spacing: -2px;
  animation: logoPulse 2s infinite ease-in-out;
}

.loader-logo span {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  position: relative;
  z-index: 2;
}

.loader-logo::after {
  content: 'D';
  position: absolute;
  left: 0;
  top: 0;
  z-index: 1;
  filter: blur(20px);
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0.8;
}

.loader-progress-container {
  width: 250px;
  height: 2px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 15px;
  position: relative;
}

.loader-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(to right, var(--primary), var(--accent));
  transition: width 0.1s linear;
}

.loader-percentage {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.loader-logs {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--primary);
  margin-top: 15px;
  height: 20px;
  text-align: center;
  opacity: 0.7;
}

/* Navigation System */
nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 40px;
  z-index: 1000;
  transition: background-color var(--transition-normal), border-bottom var(--transition-normal), backdrop-filter var(--transition-normal), height var(--transition-normal);
  border-bottom: 1px solid transparent;
}

nav.scrolled {
  background-color: rgba(12, 11, 5, 0.8);
  backdrop-filter: blur(12px);
  height: 70px;
  border-bottom: 1px solid var(--card-border);
}

[data-theme="light"] nav.scrolled {
  background-color: rgba(255, 253, 246, 0.8);
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 800;
  text-decoration: none;
  color: var(--text-color);
  letter-spacing: -1px;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 30px;
  align-items: center;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color var(--transition-fast);
  position: relative;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-color);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0%;
  height: 2px;
  background: linear-gradient(to right, var(--primary), var(--accent));
  transition: width var(--transition-fast);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-controls {
  display: flex;
  align-items: center;
  gap: 15px;
}

/* Premium Buttons & UI Actions */
.btn-icon {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--text-color);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  backdrop-filter: blur(4px);
}

.btn-icon:hover {
  background: var(--card-bg-hover);
  border-color: var(--card-border-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px var(--shadow-color);
  color: var(--primary);
}

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  cursor: pointer;
  z-index: 1002;
}

.hamburger span {
  width: 100%;
  height: 2px;
  background-color: var(--text-color);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Glass Cards and Containers */
.glass-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  backdrop-filter: blur(12px) saturate(180%);
  border-radius: var(--border-radius-md);
  padding: 30px;
  box-shadow: 0 8px 32px 0 var(--shadow-color);
  transition: border-color var(--transition-normal), background var(--transition-normal), transform var(--transition-normal), box-shadow var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, transparent 100%);
  pointer-events: none;
  z-index: 1;
}

.glass-card:hover {
  transform: translateY(-6px);
  border-color: var(--card-border-hover);
  background: var(--card-bg-hover);
  box-shadow: 0 12px 40px 0 rgba(79, 140, 255, 0.1);
}

/* Hero Section */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 130px 20px 80px 20px;
  overflow: hidden;
}

.hero-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 50px;
  width: 100%;
}

.hero-content {
  flex: 1;
  max-width: 600px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(79, 140, 255, 0.1);
  border: 1px solid rgba(79, 140, 255, 0.2);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 25px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.hero-badge span {
  display: inline-block;
  width: 8px;
  height: 8px;
  background-color: var(--success);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--success);
  animation: pulseGlow 1.5s infinite;
}

.hero-title {
  font-size: 4rem;
  line-height: 1.1;
  font-weight: 800;
  margin-bottom: 20px;
  letter-spacing: -2px;
}

.hero-title span.gradient-text {
  display: inline;
}

.hero-description {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 35px;
}

.typewriter-container {
  display: block;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--primary);
}

.typewriter-cursor {
  display: inline-block;
  width: 2px;
  background-color: var(--primary);
  margin-left: 2px;
  animation: cursorBlink 0.8s infinite;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

/* Premium Buttons */
.btn {
  padding: 14px 28px;
  border-radius: var(--border-radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  color: #fff;
  border: none;
  box-shadow: 0 8px 24px rgba(79, 140, 255, 0.25);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(79, 140, 255, 0.4);
}

.btn-secondary {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--text-color);
  backdrop-filter: blur(4px);
}

.btn-secondary:hover {
  background: var(--card-bg-hover);
  border-color: var(--card-border-hover);
  transform: translateY(-3px);
}

.hero-socials {
  display: flex;
  gap: 15px;
}

.hero-visual {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  max-width: 500px;
}

/* Laptop Mockup Visual */
.laptop-mockup {
  width: 100%;
  height: 320px;
  background: #1e1e2f;
  border: 12px solid #333;
  border-radius: 16px 16px 0 0;
  position: relative;
  box-shadow: 0 25px 50px -12px var(--shadow-color);
  overflow: hidden;
}

.laptop-screen {
  width: 100%;
  height: 100%;
  padding: 15px;
  font-family: monospace;
  font-size: 0.8rem;
  color: #a5b4c3;
  overflow-y: auto;
}

.laptop-base {
  width: 112%;
  height: 16px;
  background: #555;
  border-radius: 0 0 16px 16px;
  position: absolute;
  bottom: -16px;
  left: -6%;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
}

.laptop-notch {
  width: 80px;
  height: 6px;
  background: #333;
  border-radius: 0 0 8px 8px;
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
}

.floating-tech-nodes {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 5;
}

.tech-node {
  position: absolute;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  padding: 8px 16px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.3);
  animation: floatNode 4s infinite ease-in-out;
  backdrop-filter: blur(8px);
}

.tech-node.react { top: -20px; left: 10%; animation-delay: 0s; color: #00d8ff; }
.tech-node.node { bottom: -10px; left: -10px; animation-delay: 1.5s; color: #68a063; }
.tech-node.mongo { top: 30%; right: -20px; animation-delay: 0.7s; color: #4db33d; }
.tech-node.ai { bottom: 15%; right: 10%; animation-delay: 2.2s; color: var(--highlight); }

/* Scroll Down Indicator */
.scroll-down {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  z-index: 10;
}

.scroll-down span {
  width: 20px;
  height: 35px;
  border: 2px solid var(--text-secondary);
  border-radius: 20px;
  position: relative;
  display: inline-block;
}

.scroll-down span::before {
  content: '';
  width: 4px;
  height: 6px;
  background-color: var(--primary);
  border-radius: 50%;
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollDownIndicator 1.5s infinite;
}

/* Statistics Section */
#stats {
  padding: 60px 20px;
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--card-border);
  border-bottom: 1px solid var(--card-border);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 30px;
  text-align: center;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-num {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, #fff 30%, var(--primary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 10px;
}

[data-theme="light"] .stat-num {
  background: linear-gradient(135deg, #0f172a 30%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* About Section & Timeline */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1.8fr;
  gap: 60px;
}

.about-bio {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.about-bio h3 {
  font-size: 1.8rem;
  margin-bottom: 5px;
}

.timeline {
  position: relative;
  padding-left: 30px;
  margin-top: 15px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 8px;
  top: 0;
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, var(--primary), var(--accent), transparent);
}

.timeline-item {
  position: relative;
  margin-bottom: 40px;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -30px;
  top: 6px;
  width: 18px;
  height: 18px;
  background-color: var(--bg-color);
  border: 3px solid var(--primary);
  border-radius: 50%;
  z-index: 2;
  box-shadow: 0 0 10px rgba(79, 140, 255, 0.5);
  transition: background-color 0.3s ease;
}

.timeline-item:hover .timeline-dot {
  background-color: var(--highlight);
  border-color: var(--highlight);
}

.timeline-year {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 5px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.timeline-title {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--text-color);
}

.timeline-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

/* Skills Section */
.skills-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.skills-category h3 {
  font-size: 1.4rem;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-color);
}

.skill-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.skill-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.skill-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
}

.skill-name {
  font-weight: 600;
  color: var(--text-color);
  display: flex;
  align-items: center;
  gap: 8px;
}

.skill-val {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.skill-progress-bg {
  width: 100%;
  height: 6px;
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  overflow: hidden;
}

[data-theme="light"] .skill-progress-bg {
  background-color: rgba(15, 23, 42, 0.08);
}

.skill-progress-fill {
  height: 100%;
  background: linear-gradient(to right, var(--primary), var(--accent));
  border-radius: 10px;
  width: 0%; /* Animate via JS */
  transition: width 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Tech Stack Connection Network Graph */
#tech-graph-section {
  background-color: var(--bg-secondary);
  overflow: hidden;
}

.tech-graph-container {
  position: relative;
  width: 100%;
  height: 450px;
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid var(--card-border);
  border-radius: var(--border-radius-md);
  margin-top: 40px;
  overflow: hidden;
}

#tech-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.graph-overlay-text {
  position: absolute;
  top: 20px;
  left: 20px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}

.graph-overlay-text span {
  display: inline-block;
  width: 6px;
  height: 6px;
  background-color: var(--highlight);
  border-radius: 50%;
  animation: pulseGlow 1s infinite alternate;
}

/* Experience Section */
.exp-timeline {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-top: 40px;
}

.exp-card {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 40px;
  position: relative;
}

.exp-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.exp-date {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  color: var(--primary);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.exp-company {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-color);
}

.exp-location {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.exp-detail h3 {
  font-size: 1.4rem;
  margin-bottom: 15px;
  color: var(--text-color);
}

.exp-detail p {
  color: var(--text-secondary);
  margin-bottom: 15px;
}

.exp-detail ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.exp-detail li {
  position: relative;
  padding-left: 20px;
  color: var(--text-secondary);
}

.exp-detail li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--primary);
  font-weight: bold;
}

.exp-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 15px;
}

.tag {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--card-border);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 500;
}

[data-theme="light"] .tag {
  background: rgba(15, 23, 42, 0.04);
}

/* Services Section */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
}

.service-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: rgba(79, 140, 255, 0.1);
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--primary);
  margin-bottom: 20px;
}

.service-card h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.service-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* Projects Section (Search, Filtering, Case Study Modal) */
.projects-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
  gap: 20px;
  flex-wrap: wrap;
}

.search-box {
  position: relative;
  max-width: 400px;
  width: 100%;
}

.search-box input {
  width: 100%;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  padding: 12px 20px 12px 45px;
  border-radius: var(--border-radius-sm);
  color: var(--text-color);
  font-size: 0.95rem;
  transition: all var(--transition-fast);
  backdrop-filter: blur(4px);
}

.search-box input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 15px rgba(79, 140, 255, 0.15);
}

.search-box svg {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  pointer-events: none;
  width: 18px;
  height: 18px;
}

.filter-tags {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.filter-btn {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--text-secondary);
  padding: 8px 18px;
  border-radius: 50px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition-fast);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  transform: translateY(-1px);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.project-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.project-img-wrapper {
  width: 100%;
  height: 200px;
  background: #151d30;
  border-radius: var(--border-radius-sm);
  margin-bottom: 20px;
  overflow: hidden;
  position: relative;
}

.project-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-img-wrapper img {
  transform: scale(1.08);
}

.project-meta-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.project-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-color);
}

.project-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 20px;
  flex-grow: 1;
}

.project-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
}

.project-links {
  display: flex;
  gap: 12px;
}

/* Lightbox Modal (Generic wrapper for Case Studies and Certificates) */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(12, 11, 5, 0.9);
  backdrop-filter: blur(12px);
  z-index: 2000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 20px;
}

.modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background-color: var(--bg-secondary);
  border: 1px solid var(--card-border);
  border-radius: var(--border-radius-md);
  max-width: 800px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  transform: scale(0.95);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.modal-content img {
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  display: block;
  border-radius: 8px;
}

.modal.active .modal-content {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--text-color);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background-color: rgba(255, 0, 0, 0.1);
  color: #ff5f56;
  border-color: rgba(255, 0, 0, 0.2);
}

.case-study-title {
  font-size: 2.2rem;
  margin-bottom: 25px;
}

.case-study-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 25px;
}

.case-study-section h4 {
  font-size: 1.1rem;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.case-study-section p,
.case-study-section ul {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.case-study-section ul {
  padding-left: 20px;
}

.case-study-section li {
  margin-bottom: 6px;
}

/* GitHub Stats Widgets */
.github-grid {
  display: grid;
  grid-template-columns: 1.3fr 1.7fr;
  gap: 40px;
  align-items: center;
}

.github-stats-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.github-stat-card {
  padding: 20px;
  text-align: center;
}

.github-stat-card svg {
  color: var(--primary);
  width: 30px;
  height: 30px;
  margin-bottom: 10px;
}

.github-stat-card h4 {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 5px;
}

.github-stat-card p {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.github-chart-container {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.github-contrib-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.github-calendar {
  display: grid;
  grid-template-columns: repeat(27, 1fr); /* Compact scroll representation */
  gap: 4px;
}

.calendar-cell {
  aspect-ratio: 1;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 2px;
  transition: transform 0.2s ease;
}

[data-theme="light"] .calendar-cell {
  background-color: rgba(15, 23, 42, 0.05);
}

.calendar-cell:hover {
  transform: scale(1.3);
  z-index: 2;
}

/* Color densities representing activity levels */
.density-0 { background-color: rgba(255,255,255,0.03); }
.density-1 { background-color: rgba(79, 140, 255, 0.2); }
.density-2 { background-color: rgba(79, 140, 255, 0.5); }
.density-3 { background-color: rgba(139, 92, 246, 0.7); }
.density-4 { background-color: var(--highlight); }

[data-theme="light"] .density-0 { background-color: rgba(15,23,42,0.03); }
[data-theme="light"] .density-1 { background-color: rgba(79, 140, 255, 0.15); }
[data-theme="light"] .density-2 { background-color: rgba(79, 140, 255, 0.4); }
[data-theme="light"] .density-3 { background-color: rgba(139, 92, 246, 0.6); }
[data-theme="light"] .density-4 { background-color: var(--primary); }

/* Certificates, Education and Achievements Components */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.achievement-card {
  padding: 25px;
}

.achievement-tag {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.certificates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 25px;
}

.certificate-card {
  padding: 0;
  cursor: pointer;
}

.certificate-thumb {
  width: 100%;
  height: 180px;
  background: #111a2e;
  border-radius: var(--border-radius-md) var(--border-radius-md) 0 0;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.certificate-thumb svg {
  color: var(--primary);
  width: 48px;
  height: 48px;
  transition: transform var(--transition-normal);
}

.certificate-card:hover .certificate-thumb svg {
  transform: scale(1.15) rotate(5deg);
}

.certificate-body {
  padding: 20px;
}

.certificate-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 5px;
}

.certificate-issuer {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

/* Testimonials Slider */
.testimonials-slider-container {
  overflow: hidden;
  position: relative;
  width: 100%;
  margin-top: 40px;
}

.testimonials-track {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  width: 100%;
}

.testimonial-slide {
  min-width: 100%;
  padding: 0 10px;
}

.testimonial-card {
  max-width: 800px;
  margin: 0 auto;
  padding: 40px;
  text-align: center;
}

.testimonial-quote {
  font-size: 1.25rem;
  font-style: italic;
  margin-bottom: 25px;
  position: relative;
}

.testimonial-quote::before {
  content: '“';
  font-size: 4rem;
  position: absolute;
  top: -30px;
  left: -20px;
  color: rgba(79, 140, 255, 0.1);
}

.testimonial-author {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-color);
}

.testimonial-role {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.testimonials-nav {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 25px;
}

/* Contact Portal & Map Section */
.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1.8fr;
  gap: 50px;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.contact-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: rgba(79, 140, 255, 0.1);
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--primary);
  flex-shrink: 0;
}

.contact-text h4 {
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.contact-text p,
.contact-text a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
}

.contact-text a:hover {
  color: var(--primary);
}

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

.form-group {
  position: relative;
}

.form-group input,
.form-group textarea {
  width: 100%;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  padding: 15px 20px;
  border-radius: var(--border-radius-sm);
  color: var(--text-color);
  font-size: 0.95rem;
  transition: all var(--transition-fast);
}

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

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 15px rgba(79, 140, 255, 0.1);
}

.form-feedback {
  font-size: 0.9rem;
  margin-top: 10px;
  display: none;
}

.form-feedback.success {
  color: var(--success);
  display: block;
}

.form-feedback.error {
  color: #ff5f56;
  display: block;
}

.map-container {
  height: 250px;
  border: 1px solid var(--card-border);
  border-radius: var(--border-radius-sm);
  overflow: hidden;
  margin-top: 30px;
  position: relative;
}

.map-placeholder {
  width: 100%;
  height: 100%;
  background-color: var(--bg-secondary);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: var(--text-secondary);
  text-align: center;
  padding: 20px;
  position: relative;
  overflow: hidden;
}

.radar-ring {
  position: absolute;
  border: 1px solid rgba(255, 179, 0, 0.3);
  border-radius: 50%;
  animation: radarPulse 2.8s infinite ease-out;
}

.radar-ring-1 {
  width: 70px;
  height: 70px;
}

.radar-ring-2 {
  width: 110px;
  height: 110px;
  animation-delay: 0.8s;
}

.radar-ring-3 {
  width: 150px;
  height: 150px;
  animation-delay: 1.6s;
}

.radar-core {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 20px rgba(255, 179, 0, 0.8);
  position: relative;
  z-index: 1;
}

.radar-line {
  position: absolute;
  width: 120px;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 179, 0, 0.85), transparent);
  transform: rotate(-25deg);
  top: 45%;
  left: 50%;
  transform-origin: left center;
  animation: radarSweep 2.4s linear infinite;
}

/* Floating AI Chat Assistant Widget */
.ai-chat-widget {
  z-index: 1500;
}

.ai-chat-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 1600;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  border: none;
  color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  box-shadow: 0 8px 32px rgba(79, 140, 255, 0.3);
  transition: all var(--transition-normal);
}

.ai-chat-btn:hover {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 12px 40px rgba(79, 140, 255, 0.5);
}

.ai-chat-btn svg {
  width: 26px;
  height: 26px;
}

.ai-chat-btn::after {
  content: '';
  position: absolute;
  width: 12px;
  height: 12px;
  background-color: var(--success);
  border-radius: 50%;
  border: 2px solid var(--bg-color);
  top: 2px;
  right: 2px;
  animation: pulseGlow 1.5s infinite;
}

.ai-chat-box {
  position: fixed;
  bottom: 105px;
  right: 30px;
  z-index: 1500;
  width: 400px;
  height: 580px;
  max-height: calc(100vh - 130px);
  border-radius: var(--border-radius-md);
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.95);
  transition: opacity var(--transition-normal), visibility var(--transition-normal), transform var(--transition-normal);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18);
  background-color: #ffffff !important;
  border: 1px solid #e8eaed;
}

.ai-chat-widget.active .ai-chat-box {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.ai-chat-header {
  padding: 20px;
  border-bottom: 1px solid #e8eaed;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffffff;
  border-top-left-radius: var(--border-radius-md);
  border-top-right-radius: var(--border-radius-md);
}

.ai-chat-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ai-chat-title h4 {
  font-size: 1rem;
  color: #202124 !important;
}

.ai-chat-title span {
  font-size: 0.75rem;
  color: #137333 !important;
  display: flex;
  align-items: center;
  gap: 4px;
}

.ai-chat-title span::before {
  content: '';
  width: 6px;
  height: 6px;
  background-color: #137333 !important;
  border-radius: 50%;
}

.ai-chat-messages {
  flex-grow: 1;
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 15px;
  scrollbar-width: thin;
  background-color: #ffffff;
}

.chat-bubble {
  max-width: 85%;
  padding: 12px 16px;
  border-radius: 18px;
  font-size: 0.9rem;
  line-height: 1.4;
  position: relative;
  word-wrap: break-word;
  word-break: break-word;
  overflow-wrap: break-word;
}

.chat-bubble.ai {
  background: #f1f3f4;
  border: 1px solid #e8eaed;
  color: #202124 !important;
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.chat-bubble.ai a {
  color: #1a73e8 !important;
  text-decoration: underline;
  font-weight: 500;
}

.chat-bubble.user {
  background: linear-gradient(135deg, #ffb300 0%, #ff8f00 100%);
  color: #ffffff !important;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.chat-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 20px;
  border-top: 1px solid #e8eaed;
  background-color: #ffffff;
}

.suggestion-btn {
  background: #ffffff;
  border: 1px solid #dadce0;
  color: #5f6368 !important;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.suggestion-btn:hover {
  background: #f8f9fa;
  border-color: #ffb300;
  color: #ffb300 !important;
}

.ai-chat-input-wrapper {
  padding: 15px 20px;
  border-top: 1px solid #e8eaed;
  display: flex;
  gap: 10px;
  background-color: #ffffff;
  border-bottom-left-radius: var(--border-radius-md);
  border-bottom-right-radius: var(--border-radius-md);
}

.ai-chat-input-wrapper input {
  flex-grow: 1;
  background: #f1f3f4;
  border: 1px solid #dadce0;
  border-radius: 20px;
  padding: 10px 15px;
  color: #202124 !important;
  font-size: 0.85rem;
}

.ai-chat-input-wrapper input:focus {
  outline: none;
  border-color: #ffb300;
  background-color: #ffffff;
}

/* Floating Audio Control Panel */
.audio-controller {
  position: fixed;
  bottom: 30px;
  left: 30px;
  z-index: 1500;
  display: flex;
  align-items: center;
  gap: 10px;
}

.audio-toggle-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--text-color);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  box-shadow: 0 4px 12px var(--shadow-color);
  backdrop-filter: blur(8px);
  transition: all var(--transition-fast);
}

.audio-toggle-btn:hover {
  background: var(--card-bg-hover);
  border-color: var(--primary);
  color: var(--primary);
  transform: scale(1.05);
}

.audio-waveform {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 20px;
  padding: 0 5px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.audio-waveform.active {
  opacity: 1;
}

.waveform-bar {
  width: 3px;
  background: linear-gradient(to top, var(--primary), var(--highlight));
  border-radius: 3px;
  height: 5px;
  transition: height 0.1s ease;
}

.audio-waveform.active .waveform-bar {
  animation: bounceBar 0.8s infinite ease-in-out alternate;
}

.audio-waveform.active .waveform-bar:nth-child(2) { animation-delay: 0.15s; }
.audio-waveform.active .waveform-bar:nth-child(3) { animation-delay: 0.3s; }
.audio-waveform.active .waveform-bar:nth-child(4) { animation-delay: 0.45s; }

/* Keyboard Shortcut Command Center Trigger overlay */
.keyboard-shortcuts-helper {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  background: rgba(5, 8, 22, 0.8);
  border: 1px solid var(--card-border);
  backdrop-filter: blur(8px);
  padding: 6px 14px;
  border-radius: 30px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  pointer-events: none;
  box-shadow: 0 4px 12px var(--shadow-color);
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0.8;
}

.shortcut-kbd {
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: bold;
  color: var(--text-color);
}

/* Footer Section */
footer {
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--card-border);
  padding: 50px 20px;
  text-align: center;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 32px;
  text-align: left;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--card-border);
}

.footer-brand,
.footer-links-col,
.footer-contact-col,
.footer-availability-col,
.footer-social-col {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.footer-brand p,
.footer-links-col ul,
.footer-contact-col ul,
.footer-availability-col ul,
.footer-note {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

.footer-links-col h4,
.footer-contact-col h4,
.footer-availability-col h4,
.footer-social-col h4 {
  margin-bottom: 4px;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary);
}

.footer-links-col ul,
.footer-contact-col ul,
.footer-availability-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0;
}

.footer-links-col a,
.footer-contact-col a {
  text-decoration: none;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
}

.footer-links-col a:hover,
.footer-contact-col a:hover {
  color: var(--primary);
}

.footer-socials {
  display: flex;
  gap: 12px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 30px;
  flex-wrap: wrap;
  gap: 15px;
  text-align: left;
}

.footer-bottom p {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin: 0;
}

.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 105px; /* Offset next to the AI chatbot */
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--text-color);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  box-shadow: 0 4px 12px var(--shadow-color);
  backdrop-filter: blur(8px);
  z-index: 1400;
  transition: all var(--transition-fast);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--card-bg-hover);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-3px);
}

/* Animation Keyframes */
@keyframes logoPulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 10px rgba(79, 140, 255, 0)); }
  50% { transform: scale(1.05); filter: drop-shadow(0 0 20px rgba(79, 140, 255, 0.4)); }
}

@keyframes pulseGlow {
  0% { transform: scale(0.9); opacity: 0.6; box-shadow: 0 0 0 0 rgba(79, 140, 255, 0.4); }
  70% { transform: scale(1.1); opacity: 1; box-shadow: 0 0 10px 4px rgba(79, 140, 255, 0.1); }
  100% { transform: scale(0.9); opacity: 0.6; box-shadow: 0 0 0 0 rgba(79, 140, 255, 0); }
}

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

@keyframes scrollDownIndicator {
  0% { top: 6px; opacity: 1; height: 6px; }
  50% { top: 18px; opacity: 0.5; height: 10px; }
  100% { top: 6px; opacity: 0; height: 6px; }
}

@keyframes floatNode {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(2deg); }
}

@keyframes bounceBar {
  0% { height: 5px; }
  100% { height: 20px; }
}

@keyframes radarPulse {
  0% { transform: scale(0.8); opacity: 0.7; }
  100% { transform: scale(1.18); opacity: 0; }
}

@keyframes radarSweep {
  0% { transform: rotate(-25deg) translateX(-8px); }
  100% { transform: rotate(-25deg) translateX(120px); }
}

/* Responsive Breakpoints */
@media (max-width: 1024px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .exp-card {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .github-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  /* Mobile Menu Styles triggered at 1024px */
  nav {
    padding: 0 20px;
  }
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background-color: var(--bg-secondary);
    border-left: 1px solid var(--card-border);
    flex-direction: column;
    justify-content: center;
    gap: 40px;
    z-index: 1001;
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .nav-links.active {
    right: 0;
  }
  .hamburger {
    display: flex;
  }
  .hamburger.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }
  .hamburger.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
  
  #hero {
    min-height: auto;
    padding: 140px 20px 80px 20px;
  }
  .hero-wrapper {
    flex-direction: column;
    text-align: center;
    gap: 40px;
  }
  .hero-content {
    max-width: 100%;
  }
  .hero-buttons {
    justify-content: center;
  }
  .hero-socials {
    justify-content: center;
  }
  .hero-visual {
    width: 100%;
  }
  .laptop-mockup {
    height: 250px;
  }
  .tech-node {
    padding: 6px 12px;
    font-size: 0.8rem;
  }
  .tech-node.react { left: 5%; }
  .tech-node.node { left: -5%; }
  .tech-node.mongo { right: -5%; }
  
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .ai-chat-btn {
    bottom: 20px !important;
    right: 20px !important;
  }
  .ai-chat-box {
    bottom: 95px !important;
    right: 20px !important;
    width: calc(100vw - 40px);
    height: 420px;
  }
  .audio-controller {
    bottom: 20px;
    left: 20px;
  }
  .back-to-top {
    bottom: 20px;
    right: 90px;
  }
  .keyboard-shortcuts-helper {
    display: none;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2.8rem;
  }
  .section-title {
    font-size: 2.2rem;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  .github-stats-cards {
    grid-template-columns: 1fr;
  }
}
