/* ═══════════════════════════════════════════════
   AMAN KHAN PORTFOLIO — style.css
   Theme: Navy Blue · Purple · White | Light & Dark Mode
   ═══════════════════════════════════════════════ */

/* ─── Dark Theme Variables (default) ────────────────── */
:root,
[data-theme="dark"] {
  --bg-primary:    #030712;
  --bg-secondary:  #0a0f2e;
  --bg-tertiary:   #0d1340;
  --bg-section-alt: rgba(10,15,46,0.4);

  --text-primary:  #ffffff;
  --text-secondary: rgba(255,255,255,0.70);
  --text-muted:    rgba(255,255,255,0.40);

  --purple-600: #7c3aed;
  --purple-500: #8b5cf6;
  --purple-400: #a78bfa;
  --purple-300: #c4b5fd;
  --indigo-500: #6366f1;
  --indigo-400: #818cf8;

  --glass-bg:     rgba(255,255,255,0.06);
  --glass-border: rgba(255,255,255,0.12);
  --glass-shadow: 0 8px 32px rgba(0,0,0,0.40);

  --gradient-bg:   linear-gradient(135deg,#030712 0%,#0a0f2e 35%,#1a0a3e 65%,#0d0a2e 100%);
  --gradient-text: linear-gradient(135deg,#a78bfa,#818cf8,#c4b5fd);
  --gradient-purple: linear-gradient(135deg,#7c3aed,#6366f1);

  --tag-bg:     rgba(124,58,237,0.12);
  --tag-border: rgba(124,58,237,0.30);
  --tag-color:  #c4b5fd;

  --input-bg:   rgba(255,255,255,0.05);
  --card-hover-border: rgba(124,58,237,0.45);

  --nav-scrolled-bg: rgba(3,7,18,0.88);
  --footer-bg:       rgba(3,7,18,0.65);

  --timeline-line: linear-gradient(to bottom,#7c3aed,transparent);
  --dot-border:    #030712;

  /* icon in navbar */
  --icon-sun-display:  block;
  --icon-moon-display: none;
}

/* ─── Light Theme Variables ────────────────────────── */
[data-theme="light"] {
  --bg-primary:    #f0f2ff;
  --bg-secondary:  #e8ecff;
  --bg-tertiary:   #dce2ff;
  --bg-section-alt: rgba(224,229,255,0.6);

  --text-primary:  #0d0f2b;
  --text-secondary: rgba(13,15,43,0.70);
  --text-muted:    rgba(13,15,43,0.45);

  --purple-600: #6d28d9;
  --purple-500: #7c3aed;
  --purple-400: #8b5cf6;
  --purple-300: #7c3aed;
  --indigo-500: #4f46e5;
  --indigo-400: #6366f1;

  --glass-bg:     rgba(255,255,255,0.60);
  --glass-border: rgba(109,40,217,0.18);
  --glass-shadow: 0 8px 32px rgba(109,40,217,0.12);

  --gradient-bg:   linear-gradient(135deg,#e8ecff 0%,#ede9ff 40%,#ddd6fe 70%,#e8ecff 100%);
  --gradient-text: linear-gradient(135deg,#6d28d9,#4f46e5,#7c3aed);
  --gradient-purple: linear-gradient(135deg,#7c3aed,#6366f1);

  --tag-bg:     rgba(109,40,217,0.10);
  --tag-border: rgba(109,40,217,0.25);
  --tag-color:  #5b21b6;

  --input-bg:   rgba(255,255,255,0.80);
  --card-hover-border: rgba(109,40,217,0.45);

  --nav-scrolled-bg: rgba(240,242,255,0.92);
  --footer-bg:       rgba(224,229,255,0.80);

  --timeline-line: linear-gradient(to bottom,#7c3aed,rgba(109,40,217,0.1));
  --dot-border:    #e8ecff;

  --icon-sun-display:  none;
  --icon-moon-display: block;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  /* overflow-x must live on html, NOT body — body overflow breaks
     position:fixed in Safari / GitHub Pages (creates new stacking ctx) */
  overflow-x: hidden;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--gradient-bg);
  color: var(--text-primary);
  min-height: 100vh;
  /* cursor: none applied only on non-touch devices via JS */
  line-height: 1.6;
  transition: background 0.4s ease, color 0.3s ease;
}

/* Hide native cursor only when JS has confirmed a mouse device */
body.has-mouse { cursor: none; }
body.has-mouse a,
body.has-mouse button,
body.has-mouse [role="button"],
body.has-mouse input,
body.has-mouse textarea,
body.has-mouse select,
body.has-mouse label { cursor: none; }

/* ─── Scrollbar ─────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--purple-600); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--purple-400); }

/* ─── Custom Cursor ──────────────────────────── */
/*
  Key fixes for GitHub Pages / production:
  1. NO mix-blend-mode — causes invisible cursor on many bg colours
  2. Start opacity:0, fade in on first mousemove (avoids (0,0) flash)
  3. position:fixed works because overflow-x is now on <html> not <body>
*/
.cursor {
  width: 14px; height: 14px;
  background: var(--purple-400);
  border-radius: 50%;
  position: fixed;
  top: -100px; left: -100px;        /* off-screen until first move */
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  opacity: 0;                        /* hidden until JS activates */
  transition: width 0.25s ease, height 0.25s ease,
              opacity 0.3s ease, background 0.25s ease;
  will-change: left, top;
}
.cursor.cursor-active { opacity: 1; } /* JS adds this on first move */

.cursor-trail {
  width: 38px; height: 38px;
  border: 2px solid var(--purple-400);
  border-radius: 50%;
  position: fixed;
  top: -100px; left: -100px;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.3s ease, width 0.25s ease,
              height 0.25s ease, border-color 0.25s ease;
  will-change: left, top;
}
.cursor-trail.cursor-active { opacity: 0.55; }

.cursor.cursor-hover       { width: 22px;  height: 22px; }
.cursor-trail.cursor-hover { width: 54px;  height: 54px; opacity: 0.25; }

/* ─── Background Canvas ─────────────────────── */
#bgCanvas {
  position: fixed;
  inset: 0;
  /* z-index MUST be negative so it is always behind every page element.
     A fixed canvas at z-index:0 can overtake in-flow content in Safari
     and GitHub Pages / production builds. */
  z-index: -1;
  pointer-events: none;
  transition: opacity 0.4s;
}
[data-theme="light"] #bgCanvas { opacity: 0.35; }

/* ─── Utility ───────────────────────────────── */
.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.glass-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--glass-shadow);
  border-radius: 24px;
  transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
}

/* ─── Reveal Animations ─────────────────────── */
.reveal-up, .reveal-right {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal-right { transform: translateX(60px); }
.reveal-up.in-view, .reveal-right.in-view { opacity: 1; transform: none; }

.hero-content .reveal-up:nth-child(1) { transition-delay: 0.1s; }
.hero-content .reveal-up:nth-child(2) { transition-delay: 0.2s; }
.hero-content .reveal-up:nth-child(3) { transition-delay: 0.3s; }
.hero-content .reveal-up:nth-child(4) { transition-delay: 0.4s; }
.hero-content .reveal-up:nth-child(5) { transition-delay: 0.5s; }
.hero-content .reveal-up:nth-child(6) { transition-delay: 0.6s; }

/* ─── Buttons ───────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 50px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
  cursor: pointer;
  border: none;
  position: relative;
  overflow: hidden;
}
.btn svg { width: 18px; height: 18px; }
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  opacity: 0;
  transition: opacity 0.3s;
}
.btn:hover::before { opacity: 1; }
.btn-primary {
  background: var(--gradient-purple);
  color: #fff;
  box-shadow: 0 4px 20px rgba(124,58,237,0.45);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(124,58,237,0.65);
}
.btn-ghost {
  background: var(--glass-bg);
  color: var(--text-primary);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(10px);
}
.btn-ghost:hover {
  background: var(--glass-bg);
  border-color: var(--purple-400);
  transform: translateY(-2px);
}
.btn-full { width: 100%; justify-content: center; }

/* ─── THEME TOGGLE ──────────────────────────── */
.theme-toggle {
  width: 42px; height: 42px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  transition: all 0.3s ease;
  flex-shrink: 0;
}
.theme-toggle:hover {
  background: rgba(124,58,237,0.2);
  border-color: var(--purple-400);
  transform: rotate(20deg) scale(1.1);
}
.theme-toggle svg { width: 18px; height: 18px; }

/* Show sun in dark mode, moon in light mode */
[data-theme="dark"]  .icon-sun  { display: block; }
[data-theme="dark"]  .icon-moon { display: none; }
[data-theme="light"] .icon-sun  { display: none; }
[data-theme="light"] .icon-moon { display: block; }

/* ─── NAVBAR ────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 9000;   /* well above canvas(-1), cursor(9998/9999), sections */
  padding: 16px 0;
  transition: all 0.3s ease;
}
.navbar.scrolled {
  background: var(--nav-scrolled-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--glass-border);
  padding: 12px 0;
  box-shadow: 0 4px 24px rgba(0,0,0,0.15);
}
.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--text-primary);
  text-decoration: none;
}
.logo-bracket { color: var(--purple-400); }

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
}
.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  position: relative;
  transition: color 0.3s;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 2px;
  background: var(--gradient-purple);
  border-radius: 1px;
  transition: width 0.3s;
}
.nav-link:hover, .nav-link.active { color: var(--text-primary); }
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  background: var(--text-primary);
  border-radius: 1px;
  transition: all 0.3s ease;
}
.nav-toggle.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

/* ─── SECTION BASE ──────────────────────────── */
.section {
  position: relative;
  z-index: 10;        /* above canvas(-1) */
  isolation: isolate; /* new stacking context per section */
  padding: 100px 0;
}
.section-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}
.section-header {
  text-align: center;
  margin-bottom: 64px;
}
.section-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--purple-400);
  margin-bottom: 12px;
}
.section-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(2rem,5vw,3rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 12px;
  color: var(--text-primary);
}
.section-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto;
}

/* ─── HERO ──────────────────────────────────── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 100px 2rem 60px;
  max-width: 1200px;
  margin: 0 auto;
  gap: 3rem;
  position: relative;
  z-index: 10;          /* above canvas(-1), below navbar(9000) */
  isolation: isolate;   /* creates new stacking context; content never clips */
}
.hero-content { flex: 1; max-width: 620px; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(124,58,237,0.14);
  border: 1px solid rgba(124,58,237,0.38);
  border-radius: 50px;
  padding: 8px 18px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--purple-300);
  margin-bottom: 24px;
}
.badge-dot {
  width: 8px; height: 8px;
  background: #4ade80;
  border-radius: 50%;
  animation: pulseDot 2s infinite;
}
@keyframes pulseDot {
  0%,100% { opacity:1; transform:scale(1); }
  50%      { opacity:0.6; transform:scale(0.8); }
}

.hero-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(2.2rem,6vw,4rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 18px;
  color: var(--text-primary);
}
.greeting {
  display: block;
  font-size: 0.5em;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 4px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.hero-role {
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}
.typewriter { color: var(--purple-400); font-weight: 600; }
.cursor-blink {
  color: var(--purple-400);
  animation: blink 1s step-end infinite;
}
@keyframes blink { 0%,100% { opacity:1; } 50% { opacity:0; } }

.hero-tagline {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 500px;
  line-height: 1.7;
  margin-bottom: 32px;
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 40px; }
.hero-stats { display: flex; align-items: center; gap: 24px; }
.stat { text-align: center; }
.stat-num {
  display: block;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.stat-label { font-size: 0.78rem; color: var(--text-muted); }
.stat-divider { width: 1px; height: 40px; background: var(--glass-border); }

/* ─── Orbit 3D Badge ─────────────────────────── */
.hero-visual {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.orbit-container {
  position: relative;
  width: 320px; height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.orbit-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(139,92,246,0.25);
  animation: orbitSpin linear infinite;
}
.ring-1 { width: 260px; height: 260px; animation-duration: 12s; border-color: rgba(139,92,246,0.3); }
.ring-2 { width: 310px; height: 310px; animation-duration: 18s; animation-direction: reverse; border-color: rgba(99,102,241,0.2); border-style: dashed; }
.ring-3 { width: 180px; height: 180px; animation-duration: 8s; border-color: rgba(167,139,250,0.2); }
@keyframes orbitSpin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

.avatar-badge {
  width: 140px; height: 140px;
  background: linear-gradient(135deg,rgba(124,58,237,0.3),rgba(99,102,241,0.3));
  border: 1px solid rgba(167,139,250,0.4);
  border-radius: 50%;
  backdrop-filter: blur(20px);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 60px rgba(124,58,237,0.4), inset 0 0 30px rgba(139,92,246,0.1);
  animation: badgeFloat 4s ease-in-out infinite;
  z-index: 2;
}
@keyframes badgeFloat {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}
.avatar-inner { text-align: center; }
.avatar-icon svg { width: 60px; height: 60px; margin-bottom: 4px; }
.avatar-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--purple-300);
}

.orbit-item {
  position: absolute;
  width: 44px; height: 44px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(10px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-400);
  animation: floatItem 6s ease-in-out infinite;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  z-index: 3;
}
.orbit-item svg { width: 20px; height: 20px; }
.oi-1 { top: 5px; left: 50%; transform: translateX(-50%); animation-delay: 0s; }
.oi-2 { right: 10px; top: 50%; transform: translateY(-50%); animation-delay: 1.5s; }
.oi-3 { bottom: 5px; left: 50%; transform: translateX(-50%); animation-delay: 3s; }
.oi-4 { left: 10px; top: 50%; transform: translateY(-50%); animation-delay: 4.5s; }
@keyframes floatItem {
  0%,100% { box-shadow: 0 4px 16px rgba(0,0,0,0.2); }
  50%      { box-shadow: 0 4px 24px rgba(124,58,237,0.5); }
}

/* ─── Scroll Indicator ───────────────────────── */
.scroll-indicator {
  position: absolute;
  bottom: 30px; left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  animation: fadeInScroll 1s 1.5s forwards;
  opacity: 0;
}
@keyframes fadeInScroll { to { opacity: 0.5; } }
.scroll-indicator span { font-size: 0.7rem; letter-spacing: 2px; text-transform: uppercase; color: var(--text-muted); }
.scroll-line {
  width: 1px; height: 40px;
  background: linear-gradient(to bottom,var(--purple-400),transparent);
  animation: scrollLineAnim 2s ease-in-out infinite;
}
@keyframes scrollLineAnim {
  0%  { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform: scaleY(1); transform-origin: bottom; }
  100%{ transform: scaleY(0); transform-origin: bottom; }
}

/* ─── ABOUT ─────────────────────────────────── */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: start;
}
.about-text { padding: 40px; display: flex; flex-direction: column; gap: 16px; }
.about-text p { color: var(--text-secondary); line-height: 1.8; }
.about-text p strong { color: var(--text-primary); font-weight: 600; }

.about-links { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.social-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
}
.social-chip svg { width: 16px; height: 16px; }
.social-chip:hover {
  background: rgba(124,58,237,0.18);
  border-color: rgba(124,58,237,0.5);
  color: var(--purple-400);
  transform: translateY(-2px);
}

.about-details { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.detail-card {
  padding: 24px;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  transition: all 0.3s ease;
}
.detail-card:hover { transform: translateY(-4px); border-color: var(--card-hover-border); }
.detail-icon {
  width: 40px; height: 40px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--purple-400);
}
.detail-icon svg { width: 20px; height: 20px; }
.detail-card h4 { font-size: 0.78rem; color: var(--purple-400); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 4px; }
.detail-card p { font-weight: 600; font-size: 0.95rem; color: var(--text-primary); margin-bottom: 2px; }
.detail-card span { font-size: 0.8rem; color: var(--text-muted); }

/* ─── SKILLS ─────────────────────────────────── */
.skills-section { background: var(--bg-section-alt); }
.skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 48px;
}
.skill-group { padding: 32px; transition: all 0.3s ease; }
.skill-group:hover { transform: translateY(-4px); border-color: var(--card-hover-border); }
.skill-group-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--text-primary);
}
.skill-group-icon {
  width: 34px; height: 34px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-400);
  flex-shrink: 0;
}
.skill-group-icon svg { width: 17px; height: 17px; }

/* Skill bars */
.skill-bars { display: flex; flex-direction: column; gap: 16px; }
.skill-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-secondary);
}
.skill-pct { color: var(--purple-400); }
.skill-bar-track {
  height: 6px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 3px;
  overflow: hidden;
}
.skill-bar-fill {
  height: 100%;
  width: 0;
  background: var(--gradient-purple);
  border-radius: 3px;
  transition: width 1.2s cubic-bezier(0.4,0,0.2,1);
  box-shadow: 0 0 10px rgba(124,58,237,0.5);
}

/* Skill tags */
.skill-tags { display: flex; flex-wrap: wrap; gap: 10px; }
.skill-tag {
  padding: 7px 14px;
  background: var(--tag-bg);
  border: 1px solid var(--tag-border);
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--tag-color);
  transition: all 0.3s ease;
  cursor: default;
}
.skill-tag:hover {
  background: rgba(124,58,237,0.22);
  border-color: var(--purple-400);
  color: var(--text-primary);
  transform: translateY(-2px);
}

/* Certifications */
.certs-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 20px;
  text-align: center;
  color: var(--purple-400);
}
.certs-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.cert-card {
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all 0.3s ease;
}
.cert-card:hover { transform: translateY(-4px); border-color: rgba(99,102,241,0.5); }
.cert-icon {
  width: 44px; height: 44px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-400);
  flex-shrink: 0;
}
.cert-icon svg { width: 22px; height: 22px; }
.cert-card h4 { font-size: 0.87rem; font-weight: 600; margin-bottom: 4px; color: var(--text-primary); }
.cert-card span { font-size: 0.75rem; color: var(--text-muted); }

/* ─── PROJECTS ───────────────────────────────── */
.projects-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 24px; }
.project-card {
  padding: 32px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.project-card:hover { transform: translateY(-8px); border-color: var(--card-hover-border); }
.project-glow {
  position: absolute;
  top: -60px; right: -60px;
  width: 180px; height: 180px;
  background: radial-gradient(circle,rgba(124,58,237,0.12) 0%,transparent 70%);
  pointer-events: none;
  transition: opacity 0.3s;
}
.project-card:hover .project-glow { opacity: 0.9; }

.project-header { display: flex; align-items: center; justify-content: space-between; }
.project-icon {
  width: 50px; height: 50px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-400);
}
.project-icon svg { width: 26px; height: 26px; }
.project-badges { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}
.badge-ml  { background: rgba(124,58,237,0.15); color: #c4b5fd; border: 1px solid rgba(124,58,237,0.35); }
.badge-py  { background: rgba(59,130,246,0.15);  color: #93c5fd; border: 1px solid rgba(59,130,246,0.35); }
.badge-java{ background: rgba(245,158,11,0.15);  color: #fcd34d; border: 1px solid rgba(245,158,11,0.35); }
.badge-db  { background: rgba(16,185,129,0.15);  color: #6ee7b7; border: 1px solid rgba(16,185,129,0.35); }
.badge-ai  { background: rgba(239,68,68,0.15);   color: #fca5a5; border: 1px solid rgba(239,68,68,0.35); }
.badge-featured {
  background: linear-gradient(135deg,rgba(124,58,237,0.25),rgba(99,102,241,0.25));
  color: var(--purple-300);
  border: 1px solid rgba(124,58,237,0.45);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
}

.project-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-primary);
}
.project-sub { font-weight: 400; font-size: 0.85em; color: var(--purple-400); display: block; margin-top: 2px; }
.project-desc { font-size: 0.9rem; color: var(--text-secondary); line-height: 1.7; flex: 1; }
.project-desc strong { color: var(--purple-400); }

.project-tech { display: flex; flex-wrap: wrap; gap: 8px; }
.tech-chip {
  padding: 4px 12px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-secondary);
}
.project-footer {
  display: flex;
  justify-content: flex-end;
  padding-top: 8px;
  border-top: 1px solid var(--glass-border);
}
.accuracy-badge { text-align: center; }
.accuracy-num {
  display: block;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.accuracy-badge > span:last-child { font-size: 0.7rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; }
.featured-project {
  background: linear-gradient(135deg,rgba(124,58,237,0.08),rgba(99,102,241,0.04));
  border-color: rgba(124,58,237,0.28);
}

/* ─── EXPERIENCE / TIMELINE ─────────────────── */
.experience-section { background: var(--bg-section-alt); }
.timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 32px;
  padding-left: 40px;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 12px; top: 0; bottom: 0;
  width: 2px;
  background: var(--timeline-line);
}
.timeline-item { position: relative; }
.timeline-dot {
  position: absolute;
  left: -34px; top: 28px;
  width: 14px; height: 14px;
  background: var(--gradient-purple);
  border-radius: 50%;
  border: 3px solid var(--dot-border);
  box-shadow: 0 0 12px rgba(124,58,237,0.6);
}
.timeline-card { padding: 32px; transition: all 0.3s ease; }
.timeline-card:hover { transform: translateX(8px); border-color: var(--card-hover-border); }

.timeline-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.timeline-role {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-primary);
}
.timeline-company { color: var(--purple-400); font-size: 0.9rem; font-weight: 500; }
.timeline-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  padding: 6px 14px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}
.timeline-points {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--text-secondary);
  font-size: 0.9rem;
}
.timeline-points li { display: flex; align-items: flex-start; gap: 8px; }
.timeline-points li::before { content: '▸'; color: var(--purple-400); flex-shrink: 0; margin-top: 2px; }

/* ─── CONTACT ─────────────────────────────────── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 32px;
  align-items: start;
}
.contact-info { padding: 40px; }
.contact-info h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-primary);
}
.contact-info p { color: var(--text-secondary); line-height: 1.8; margin-bottom: 32px; font-size: 0.95rem; }
.contact-methods { display: flex; flex-direction: column; gap: 16px; }
.contact-method {
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
  color: var(--text-primary);
  padding: 16px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  transition: all 0.3s ease;
}
.contact-method:hover {
  background: rgba(124,58,237,0.1);
  border-color: var(--card-hover-border);
  transform: translateX(4px);
}
.cm-icon {
  width: 42px; height: 42px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-400);
  flex-shrink: 0;
}
.cm-icon svg { width: 20px; height: 20px; }
.cm-label { display: block; font-size: 0.72rem; color: var(--text-muted); letter-spacing: 1px; text-transform: uppercase; margin-bottom: 2px; }
.cm-value { font-size: 0.9rem; font-weight: 500; color: var(--text-primary); }

/* Form */
.contact-form { padding: 40px; display: flex; flex-direction: column; gap: 20px; }
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-group label { font-size: 0.85rem; font-weight: 500; color: var(--text-secondary); }
.form-group input,
.form-group textarea {
  background: var(--input-bg);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  padding: 14px 16px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  outline: none;
  resize: vertical;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-muted); }
.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--purple-500);
  background: rgba(124,58,237,0.07);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.14);
}
.form-success {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: rgba(74,222,128,0.1);
  border: 1px solid rgba(74,222,128,0.3);
  border-radius: 10px;
  font-size: 0.9rem;
  color: #4ade80;
}
.form-success.show { display: flex; }

/* ─── FOOTER ─────────────────────────────────── */
.footer {
  position: relative;
  z-index: 10;
  padding: 40px 2rem;
  border-top: 1px solid var(--glass-border);
  background: var(--footer-bg);
  backdrop-filter: blur(10px);
}
.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-logo { font-family: 'Space Grotesk', sans-serif; font-size: 1.3rem; font-weight: 800; color: var(--text-primary); }
.footer-copy { font-size: 0.85rem; color: var(--text-muted); }
.footer-links { display: flex; gap: 20px; }
.footer-links a { font-size: 0.85rem; color: var(--text-muted); text-decoration: none; transition: color 0.3s; }
.footer-links a:hover { color: var(--purple-400); }

/* ─── 3D TILT ─────────────────────────────────── */
.tilt-card { transform-style: preserve-3d; will-change: transform; }

/* ─── RESPONSIVE ──────────────────────────────── */
@media (max-width: 1024px) {
  .projects-grid { grid-template-columns: 1fr 1fr; }
  .certs-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .hero { flex-direction: column; text-align: center; padding-top: 120px; }
  .hero-tagline { margin: 0 auto 32px; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero-visual { order: -1; }
  .orbit-container { width: 240px; height: 240px; }
  .ring-1 { width: 200px; height: 200px; }
  .ring-2 { width: 230px; height: 230px; }
  .ring-3 { width: 140px; height: 140px; }
  .avatar-badge { width: 110px; height: 110px; }

  .about-grid { grid-template-columns: 1fr; }
  .about-details { grid-template-columns: 1fr 1fr; }
  .skills-grid { grid-template-columns: 1fr; }
  .projects-grid { grid-template-columns: 1fr; }
  .certs-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--nav-scrolled-bg);
    backdrop-filter: blur(24px);
    flex-direction: column;
    padding: 24px;
    gap: 0;
    border-bottom: 1px solid var(--glass-border);
  }
  .nav-links.open { display: flex; }
  .nav-links li { border-bottom: 1px solid var(--glass-border); }
  .nav-link { display: block; padding: 14px 0; }
  .nav-toggle { display: flex; }

  .footer-content { flex-direction: column; text-align: center; }
  .timeline { padding-left: 24px; }
  /* On touch/mobile screens restore the native cursor */
  body.has-mouse { cursor: auto; }
  body.has-mouse a, body.has-mouse button,
  body.has-mouse input, body.has-mouse textarea,
  body.has-mouse label { cursor: auto; }
  .cursor, .cursor-trail { display: none !important; }
}
@media (max-width: 480px) {
  .section { padding: 70px 0; }
  .about-text { padding: 28px 20px; }
  .about-details { grid-template-columns: 1fr; }
  .contact-info, .contact-form { padding: 28px 20px; }
  .hero-stats { gap: 16px; }
}

/* ─── Shake animation ─────────────────────────── */
@keyframes shake {
  0%,100% { transform: translateX(0); }
  20%      { transform: translateX(-8px); }
  40%      { transform: translateX(8px); }
  60%      { transform: translateX(-4px); }
  80%      { transform: translateX(4px); }
}
