:root {
  --bg: #07070b;
  --bg-2: #0f111a;
  --surface: rgba(255, 255, 255, 0.06);
  --surface-2: rgba(255, 255, 255, 0.1);
  --border: rgba(255, 255, 255, 0.15);
  --text: #f4f5ff;
  --muted: #b3b6c9;
  --accent: #ffb347;
  --accent-2: #64c7ff;
  --accent-3: #a38bff;
  --shadow: 0 24px 60px rgba(7, 7, 11, 0.55);
  --grid-dot: rgba(255, 255, 255, 0.08);
  --grid-opacity: 0.35;
  --header-bg: rgba(7, 7, 11, 0.6);
  --header-border: rgba(255, 255, 255, 0.05);
  --radius: 18px;
  --font-display: "Space Grotesk", sans-serif;
  --font-body: "DM Sans", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: radial-gradient(circle at top, rgba(163, 139, 255, 0.18), transparent 45%),
    radial-gradient(circle at 20% 30%, rgba(100, 199, 255, 0.2), transparent 45%),
    radial-gradient(circle at 80% 0%, rgba(255, 179, 71, 0.18), transparent 35%),
    linear-gradient(140deg, var(--bg) 0%, var(--bg-2) 100%);
  color: var(--text);
  min-height: 100vh;
}

body[data-theme="light"] {
  --bg: #fdfdff;
  --bg-2: #f8f9fc;
  --surface: rgba(255, 255, 255, 0.85);
  --surface-2: rgba(255, 255, 255, 0.95);
  --border: rgba(15, 18, 30, 0.08);
  --text: #1a1b2e;
  --muted: #5a6175;
  --accent: #ff6b35;
  --accent-2: #4a90e2;
  --accent-3: #8b7cf8;
  --shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
  --grid-dot: rgba(0, 0, 0, 0.06);
  --grid-opacity: 0.15;
  --header-bg: rgba(255, 255, 255, 0.85);
  --header-border: rgba(15, 18, 30, 0.06);
  background: radial-gradient(circle at 20% 20%, rgba(139, 124, 248, 0.12), transparent 50%),
    radial-gradient(circle at 80% 30%, rgba(74, 144, 226, 0.1), transparent 50%),
    radial-gradient(circle at 60% 80%, rgba(255, 107, 53, 0.08), transparent 40%),
    linear-gradient(135deg, #fdfdff 0%, #f8f9fc 100%);
}

/* Light Theme Specific Enhancements */
body[data-theme="light"] .skill-category {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(15, 18, 30, 0.05);
  backdrop-filter: blur(20px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06), 0 2px 8px rgba(0, 0, 0, 0.02);
}

body[data-theme="light"] .skill-filter-btn {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(15, 18, 30, 0.05);
  backdrop-filter: blur(20px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
}

body[data-theme="light"] .skill-filter-btn:hover,
body[data-theme="light"] .skill-filter-btn.active {
  background: var(--accent-2);
  color: white;
  box-shadow: 0 6px 20px rgba(74, 144, 226, 0.2);
}

body[data-theme="light"] .site-header {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(15, 18, 30, 0.06);
  backdrop-filter: blur(20px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

body[data-theme="light"] .project-card {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(15, 18, 30, 0.06);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
}

body[data-theme="light"] .project-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

body[data-theme="light"] .skill-progress {
  background: linear-gradient(90deg, var(--accent-2), var(--accent-3));
  box-shadow: 0 2px 8px rgba(74, 144, 226, 0.2);
}

body[data-theme="light"] .contact-form {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(15, 18, 30, 0.05);
  backdrop-filter: blur(20px);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06);
}

body[data-theme="torch"] {
  --bg: #05050a;
  --bg-2: #0b0d14;
  --surface: rgba(255, 255, 255, 0.05);
  --surface-2: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.12);
  --accent: #ffd27a;
  --accent-2: #7ad6ff;
  --accent-3: #b09cff;
  --shadow: 0 28px 70px rgba(2, 2, 6, 0.7);
  --grid-opacity: 0.25;
  --header-bg: rgba(5, 5, 10, 0.7);
  --header-border: rgba(255, 255, 255, 0.05);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background-image: radial-gradient(var(--grid-dot) 1px, transparent 0);
  background-size: 36px 36px;
  opacity: var(--grid-opacity);
  pointer-events: none;
  z-index: 0;
}

.orb {
  position: fixed;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.35;
  z-index: 0;
  animation: float 12s ease-in-out infinite;
}

.orb-one {
  background: rgba(255, 179, 71, 0.6);
  top: 10%;
  left: -60px;
}

.orb-two {
  background: rgba(100, 199, 255, 0.6);
  bottom: 20%;
  right: -100px;
  animation-delay: 2s;
}

.orb-three {
  background: rgba(163, 139, 255, 0.5);
  top: 65%;
  left: 35%;
  animation-delay: 4s;
}

#torch-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
  background: radial-gradient(
    circle at var(--torch-x, 50%) var(--torch-y, 40%),
    rgba(255, 255, 255, 0.12) 0px,
    rgba(7, 7, 11, 0.2) 140px,
    rgba(7, 7, 11, 0.85) 280px,
    rgba(7, 7, 11, 0.95) 100%
  );
  z-index: 9;
}

body[data-theme="torch"] #torch-overlay {
  opacity: 1;
}

body[data-theme="torch"] .orb {
  opacity: 0.18;
}

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

.container {
  width: min(1100px, 92vw);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.site-header {
  position: sticky;
  top: 12px;
  z-index: 10;
  backdrop-filter: blur(16px);
  background: var(--header-bg);
  border: 1px solid var(--header-border);
  border-radius: 50px;
  margin: 0 20px;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 20px;
  gap: 16px;
}

.logo {
  font-family: var(--font-display);
  font-size: 1rem;
  text-decoration: none;
  color: var(--text);
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 12px;
}

.profile-img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border);
}

.nav-links {
  display: flex;
  gap: 18px;
}

/* Hide mobile menu by default on desktop */
@media (min-width: 769px) {
  .mobile-menu-toggle {
    display: none !important;
  }
}

.nav-links a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 500;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

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

.theme-control {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
}

/* Mobile menu styles */
.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  gap: 4px;
  z-index: 1001;
}

.mobile-menu-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: all 0.3s ease;
  border-radius: 2px;
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

.mobile-theme-control {
  display: none;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  gap: 6px;
  width: 100%;
}

.mobile-theme-control .theme-btn {
  flex: 1;
}

.desktop-theme {
  display: inline-flex;
}

.desktop-talk-btn {
  display: inline-flex;
}

/* Mobile responsive navigation */
@media (max-width: 768px) {
  /* FORCE HIDE Let's talk button on mobile */
  .btn.ghost,
  .desktop-talk-btn,
  a[href="#contact"].btn {
    display: none !important;
    visibility: hidden !important;
  }
  
  /* Mobile header styling */
  .site-header {
    background: rgba(15, 17, 26, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.75rem 0;
    position: sticky;
    top: 0;
    z-index: 999;
  }
  
  .nav {
    padding: 0 1rem;
    align-items: center;
    justify-content: space-between;
    display: flex;
    width: 100%;
    max-width: 100%;
  }
  
  .logo-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
    min-width: 0; /* Allows flex item to shrink */
  }
  
  .profile-img {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 2px solid var(--accent);
    flex-shrink: 0;
  }
  
  .logo {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  
  .mobile-menu-toggle {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px;
    cursor: pointer;
    gap: 3px;
    z-index: 1001;
    transition: all 0.3s ease;
    flex-shrink: 0;
    margin-left: 0.75rem;
  }
  
  .mobile-menu-toggle:hover {
    background: var(--surface-2);
    border-color: var(--accent);
  }
  
  .mobile-menu-toggle span {
    width: 20px;
    height: 2px;
    background: var(--text);
    transition: all 0.3s ease;
    border-radius: 1px;
  }
  
  .mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  
  .mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  
  .mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }
  
  .desktop-theme {
    display: none;
  }
  
  .nav-links {
    position: fixed !important;
    top: 0;
    right: -100%;
    width: 300px;
    height: 100vh;
    background: var(--bg);
    border-left: 1px solid var(--border);
    flex-direction: column;
    align-items: flex-start;
    padding: 80px 2rem 2rem;
    gap: 1.5rem;
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    overflow-y: auto;
    box-shadow: -20px 0 40px rgba(0, 0, 0, 0.6);
  }
  
  .nav-links.active {
    right: 0 !important;
    display: flex !important;
  }
  
  .nav-links a {
    font-size: 1rem;
    padding: 0.8rem 0;
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.2s ease;
  }
  
  .nav-links a:hover {
    padding-left: 0.5rem;
    color: var(--accent);
  }
  
  .mobile-theme-control {
    display: flex;
    width: 100%;
    background: var(--surface);
    border-radius: 12px;
    padding: 0.5rem;
    margin-top: 1rem;
  }
  
  .mobile-theme-control .theme-btn {
    border-radius: 8px;
  }
  
  /* Hide desktop "Let's talk" button on mobile */
  .desktop-talk-btn,
  .btn.ghost[href="#contact"] {
    display: none !important;
  }
  
  /* Clean mobile logo */
  .logo-container {
    display: flex;
    align-items: center;
    gap: 12px;
  }
  
  .profile-img {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 2px solid var(--border);
  }
  
  .logo {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
  }
  
  /* Enhanced hamburger */
  .mobile-menu-toggle {
    background: var(--surface-2);
    border-radius: 8px;
    padding: 10px;
    border: 1px solid var(--border);
  }
  
  .mobile-menu-toggle span {
    width: 20px;
    height: 2px;
    background: var(--text);
  }
}

.theme-btn {
  border: none;
  background: transparent;
  color: var(--muted);
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  font-family: var(--font-body);
}

.theme-btn.active,
.theme-btn:hover {
  background: var(--surface-2);
  color: var(--text);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--accent), #ffd57b);
  color: #14141c;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 10px 24px rgba(255, 179, 71, 0.2);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(255, 179, 71, 0.35);
}

.btn.ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
  box-shadow: none;
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 32px;
  padding: 90px 0 70px;
  align-items: center;
}

.kicker {
  text-transform: uppercase;
  letter-spacing: 3px;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 12px;
}

.hero-text h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 4vw, 3.7rem);
  line-height: 1.08;
  margin-bottom: 18px;
}

.subtitle {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.6;
  max-width: 540px;
}

.hero-actions {
  margin: 24px 0 32px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.hero-stats div {
  background: var(--surface);
  padding: 16px;
  border-radius: 14px;
  border: 1px solid var(--border);
}

.hero-stats span {
  font-family: var(--font-display);
  font-size: 1.4rem;
}

.hero-stats p {
  color: var(--muted);
  font-size: 0.9rem;
}

.hero-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--muted);
}

.badge {
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(100, 199, 255, 0.18);
  color: #a9e0ff;
  border: 1px solid rgba(100, 199, 255, 0.5);
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 8px;
  height: 8px;
  background: #00ff88;
  border-radius: 50%;
  animation: blink 2s infinite;
  box-shadow: 0 0 8px rgba(0, 255, 136, 0.6);
}

@keyframes blink {
  0%, 50% {
    opacity: 1;
  }
  51%, 100% {
    opacity: 0.3;
  }
}

.experience-item {
  margin-top: 1rem;
  padding: 0.5rem 0;
}

.experience-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.75rem;
  gap: 1rem;
}

.company-info {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
}

.company-logo {
  width: 64px;
  height: 64px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.company-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.company-details h3 {
  color: var(--text);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 0.2rem 0;
}

.position {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0;
}

.experience-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.2rem;
  text-align: right;
}

.duration {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 500;
}

.location {
  color: var(--muted);
  font-size: 0.75rem;
}

.technologies {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-bottom: 0.75rem;
}

.tech-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.25rem 0.5rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 500;
}

.tech-tag i {
  font-size: 0.8rem;
  color: var(--accent-2);
}

.experience-details {
  margin: 0;
  padding-left: 1rem;
}

.experience-details li {
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.4;
  margin-bottom: 0.3rem;
}

.education-info {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.education-info p {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0;
}

@media (max-width: 768px) {
  .experience-header {
    flex-direction: column;
    gap: 0.75rem;
  }
  
  .experience-meta {
    align-items: flex-start;
  }
  
  .technologies {
    gap: 0.4rem;
  }
  
  .tech-tag {
    padding: 0.3rem 0.6rem;
    font-size: 0.75rem;
  }
}

.card-body h2 {
  font-family: var(--font-display);
  font-size: 1.6rem;
}

.card-body p {
  color: var(--muted);
  line-height: 1.6;
  margin: 10px 0 16px;
}

.card-body ul {
  list-style: none;
  display: grid;
  gap: 10px;
  color: var(--muted);
}

.card-footer {
  display: flex;
  justify-content: space-between;
  font-weight: 600;
}

.link {
  color: var(--accent-2);
  text-decoration: none;
}

.section {
  padding: 70px 0;
}

.section-header h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  margin-bottom: 16px;
}

.two-col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  color: var(--muted);
  line-height: 1.7;
}

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

.card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: var(--shadow);
}

.card h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
}

.card p {
  color: var(--muted);
  line-height: 1.6;
}

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

.tags span {
  font-size: 0.8rem;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.pill-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.pill {
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.08);
  font-weight: 500;
}

.contact-card {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 28px;
  box-shadow: var(--shadow);
}

.contact-card p {
  color: var(--muted);
  line-height: 1.6;
}

.contact-actions {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.contact-details {
  display: grid;
  gap: 12px;
  font-size: 0.95rem;
}

.site-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  margin-top: 60px;
  padding: 24px 0 40px;
}

.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer-links a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-separator {
  color: var(--muted);
  opacity: 0.5;
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Typing Animation */
.typing-effect {
  border-right: 2px solid var(--accent);
  animation: blink-cursor 0.8s infinite;
}

.typing-effect .typed-line {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  width: 0;
  animation: typing-line 2s steps(40, end) forwards;
}

.typing-effect .typed-line:nth-child(1) {
  animation-delay: 0s;
}

.typing-effect .typed-line:nth-child(2) {
  animation-delay: 2.2s;
}

.typing-effect .typed-line:nth-child(3) {
  animation-delay: 4.4s;
}

.typing-effect .typed-line:nth-child(4) {
  animation-delay: 6.6s;
}

@keyframes typing-line {
  0% {
    width: 0;
    opacity: 1;
  }
  100% {
    width: 100%;
    opacity: 1;
  }
}

@keyframes blink-cursor {
  0%, 50% {
    border-color: var(--accent);
  }
  51%, 100% {
    border-color: transparent;
  }
}

.typing-subtitle {
  opacity: 0;
  animation: fade-in-typing 3s steps(30, end) 8.8s both;
}

@keyframes fade-in-typing {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

/* Enhanced Project Section */
.project-filters {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 8px 16px;
  border: 2px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  border-radius: 25px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: var(--font-body);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--accent);
  color: #14141c;
  border-color: var(--accent);
  transform: translateY(-2px);
}

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

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 1;
  transform: scale(1);
}

.project-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.3);
  border-color: var(--accent);
  z-index: 10;
  position: relative;
}

.project-card.filtered-out {
  opacity: 0;
  transform: scale(0.8);
  pointer-events: none;
}

.project-image {
  position: relative;
  height: 160px;
  overflow: hidden;
  transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card:hover .project-image {
  height: 280px;
}

.project-screenshot {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  object-position: center top;
}

.project-card:hover .project-screenshot {
  transform: scale(1.02);
  object-fit: contain;
}

.project-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 2rem;
  color: white;
  font-family: var(--font-display);
}

.ai-gradient {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.netflix-gradient {
  background: linear-gradient(135deg, #e53e3e 0%, #dd1818 100%);
}

.health-gradient {
  background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
}

.tools-gradient {
  background: linear-gradient(135deg, #4299e1 0%, #3182ce 100%);
}

.project-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.95), rgba(0, 0, 0, 0.7), transparent);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  opacity: 0;
  transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(4px);
  padding: 20px;
  height: 80px;
}

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

.project-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: 2px solid white;
  background: transparent;
  color: white;
  border-radius: 6px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-body);
}

.project-btn:hover {
  background: white;
  color: #000;
}

.project-content {
  padding: 24px;
}

.project-content h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  margin-bottom: 12px;
  color: var(--text);
}

.project-content p {
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 16px;
}

.project-stats {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
  font-size: 0.85rem;
}

.stat {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
}

.tech-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tech-tag {
  padding: 4px 10px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 0.75rem;
  color: var(--text);
  font-weight: 500;
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

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

.modal-content {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

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

.modal-header {
  padding: 24px 24px 16px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--text);
}

.modal-close {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: color 0.2s ease;
}

.modal-close:hover {
  color: var(--text);
}

.modal-body {
  padding: 24px;
}

.modal-body p {
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 20px;
}

.modal-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

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

/* Interactive Skills Section */
.skill-filters {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.skill-filter-btn {
  padding: 8px 18px;
  border: 1px solid var(--header-border);
  background: var(--header-bg);
  color: var(--muted);
  border-radius: 25px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: var(--font-body);
  font-size: 0.85rem;
  backdrop-filter: blur(16px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.skill-filter-btn:hover,
.skill-filter-btn.active {
  background: var(--accent-2);
  border-color: var(--accent-2);
  color: var(--text);
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.skills-container {
  display: grid;
  gap: 40px;
  margin-bottom: 50px;
}

.skill-category {
  transition: all 0.4s ease;
  opacity: 1;
  transform: translateY(0);
  background: var(--header-bg);
  border: 1px solid var(--header-border);
  border-radius: 24px;
  padding: 24px;
  margin-bottom: 24px;
  backdrop-filter: blur(16px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.skill-category.hidden {
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
}

.skill-category-title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--text);
  margin-bottom: 20px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
}

.skill-bars {
  display: grid;
  gap: 20px;
}

.skill-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  transition: all 0.3s ease;
}

.skill-item:hover {
  transform: translateX(8px);
  box-shadow: var(--shadow);
  border-color: var(--accent-2);
}

.skill-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.skill-name-container {
  display: flex;
  align-items: center;
  gap: 12px;
}

.skill-icon {
  width: 24px;
  height: 24px;
  object-fit: contain;
  filter: brightness(1.1);
}

.skill-name {
  font-weight: 600;
  color: var(--text);
  font-size: 1rem;
}

.skill-level {
  font-weight: 600;
  color: var(--accent);
  font-size: 0.9rem;
}

.skill-bar {
  height: 8px;
  background: var(--surface-2);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}

.skill-progress {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-2), var(--accent-3));
  border-radius: 4px;
  width: 0%;
  transition: width 2s ease;
  position: relative;
}

.skill-progress::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 4px;
  height: 100%;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 2px;
}

.skill-progress.animate {
  animation: pulse 0.5s ease;
}

@keyframes pulse {
  0%, 100% { transform: scaleY(1); }
  50% { transform: scaleY(1.1); }
}

/* GitHub Stats */
.github-stats {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  margin-top: 40px;
}

.github-stats h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--text);
  text-align: center;
  margin-bottom: 30px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.stat-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

.stat-icon {
  font-size: 2rem;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border-radius: 10px;
}

.stat-info {
  flex: 1;
}

.stat-number {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}

.stat-label {
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 4px;
}

/* Coding Platforms */
.coding-platforms {
  margin-top: 40px;
  display: grid;
  gap: 30px;
}

.platform-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 30px;
  backdrop-filter: blur(16px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.platform-section:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
  border-color: var(--accent-2);
}

.platform-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 25px;
  flex-wrap: wrap;
  gap: 15px;
}

.platform-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.platform-header h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--text);
  margin: 0;
}

.platform-logo {
  width: 32px;
  height: 32px;
  object-fit: contain;
  filter: brightness(1.1);
}

.platform-logo-codechef {
  height: 24px;
  width: auto;
}

.platform-link {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-2);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  padding: 8px 16px;
  border: 1px solid var(--accent-2);
  border-radius: 20px;
  transition: all 0.3s ease;
}

.platform-link:hover {
  background: var(--accent-2);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(74, 144, 226, 0.3);
}

.platform-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
}

.platform-stat {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all 0.3s ease;
}

.platform-stat:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.platform-stat .stat-icon {
  font-size: 1.8rem;
  width: 45px;
  height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border-radius: 10px;
}

.platform-stat .stat-info {
  flex: 1;
}

.platform-stat .stat-number {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
}

.platform-stat .stat-label {
  color: var(--muted);
  font-size: 0.8rem;
  margin-top: 4px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .skill-filters {
    gap: 6px;
  }
  
  .skill-filter-btn {
    padding: 5px 10px;
    font-size: 0.8rem;
  }
  
  .skill-item {
    padding: 16px;
  }
  
  .stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
  }
  
  .stat-card {
    padding: 16px;
    gap: 12px;
  }
  
  .stat-icon {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
  }
  
  .stat-number {
    font-size: 1.5rem;
  }
  
  .platform-header {
    flex-direction: column;
    align-items: stretch;
    gap: 15px;
  }
  
  .platform-title {
    justify-content: center;
  }
  
  .platform-link {
    justify-content: center;
  }
  
  .platform-stats {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .platform-stat {
    padding: 16px;
    gap: 12px;
  }
}

/* Scroll Progress Indicator */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--surface);
  z-index: 1001;
}

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

/* Enhanced reveal animations */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Smooth section transitions */
.section {
  transition: transform 0.3s ease;
}

/* Enhanced orb animations */
.orb {
  position: fixed;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.4;
  z-index: 0;
  animation: float 15s ease-in-out infinite;
  pointer-events: none;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(30px, -30px) rotate(120deg); }
  66% { transform: translate(-20px, 20px) rotate(240deg); }
}

/* Enhanced Contact Section */
.contact-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}

.contact-info .contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
}

.contact-actions {
  display: flex;
  gap: 12px;
  margin: 24px 0;
  flex-wrap: wrap;
}

.contact-actions .btn {
  padding: 10px 16px;
  font-size: 0.9rem;
}

.contact-details {
  margin-top: 30px;
  display: grid;
  gap: 20px;
}

.contact-detail-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: all 0.3s ease;
}

.contact-detail-item:hover {
  transform: translateX(8px);
  border-color: var(--accent);
}

.contact-icon {
  font-size: 1.5rem;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border-radius: 8px;
}

.contact-detail-item strong {
  display: block;
  color: var(--text);
  margin-bottom: 4px;
  font-weight: 600;
}

.contact-detail-item p {
  color: var(--muted);
  margin: 0;
  font-size: 0.9rem;
}

/* Interactive Contact Form */
.form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  position: relative;
}

.form-card h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--text);
  margin-bottom: 24px;
  text-align: center;
}

.contact-form {
  display: grid;
  gap: 20px;
}

.form-group {
  display: grid;
  gap: 8px;
}

.form-group label {
  font-weight: 600;
  color: var(--text);
  font-size: 0.9rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 12px 16px;
  background: var(--bg-2);
  border: 2px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: var(--font-body);
  transition: all 0.3s ease;
  resize: vertical;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--surface-2);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(255, 179, 71, 0.1);
}

.form-group textarea {
  min-height: 120px;
  font-family: var(--font-body);
}

.form-error {
  color: #ef4444;
  font-size: 0.8rem;
  min-height: 16px;
  opacity: 0;
  transform: translateY(-4px);
  transition: all 0.3s ease;
}

.form-error.show {
  opacity: 1;
  transform: translateY(0);
}

.submit-btn {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #14141c;
  border: none;
  padding: 14px 24px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  justify-self: start;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.btn-loading {
  display: flex;
  align-items: center;
  gap: 8px;
}

.spinner {
  animation: spin 2s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.form-success {
  margin-top: 20px;
  padding: 16px 20px;
  background: linear-gradient(135deg, #10B981, #059669);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 12px;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(16, 185, 129, 0.2);
  opacity: 0;
  transform: translateY(10px);
  animation: slideInSuccess 0.5s ease forwards;
}

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

.success-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.success-icon {
  color: white;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.success-text {
  text-align: left;
}

.form-success h4 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: white;
  margin: 0 0 4px 0;
  font-weight: 600;
}

.form-success p {
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.4;
}

/* Responsive Design */
@media (max-width: 768px) {
  .contact-container {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .contact-actions {
    gap: 8px;
  }
  
  .contact-actions .btn {
    padding: 8px 14px;
    font-size: 0.85rem;
  }
  
  .form-card {
    padding: 20px;
  }
  
  .contact-detail-item {
    padding: 12px;
  }
}

@media (max-width: 900px) {
  .nav-links {
    display: none;
  }

  .nav {
    flex-wrap: wrap;
  }

  .theme-btn {
    padding: 6px 10px;
    font-size: 0.75rem;
  }

  .hero-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .nav {
    padding: 16px 0;
  }

  .hero {
    padding: 70px 0 50px;
  }

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

  .card-footer {
    flex-direction: column;
    gap: 8px;
  }
}
