/* ========================================
   RESET & BASE STYLES
   ======================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

/* Responsive base font scaling */
@media (max-width: 320px) {
  html { font-size: 14px; }
}

@media (min-width: 321px) and (max-width: 480px) {
  html { font-size: 15px; }
}

@media (min-width: 1440px) {
  html { font-size: 18px; }
}

body {
  font-family: 'Inter', sans-serif;
  background: #ffffff;
  color: #1f2937;
  overflow-x: hidden;
  line-height: 1.6;
}

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
}

a {
  text-decoration: none;
  color: inherit;
}

.main-wrapper {
  min-height: 100vh;
  background: white;
  overflow-x: hidden;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(16px, 5vw, 24px);
  width: 100%;
}

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

@media (min-width: 1440px) {
  .container {
    max-width: 1400px;
  }
}

/* ========================================
   NAVIGATION
   ======================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: all 0.3s ease;
  padding: clamp(10px, 2vh, 14px) 0;
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.5);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.navbar-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar-logo {
  font-family: 'Inter', sans-serif;
  font-size: 24px;
  font-weight: 700;
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.navbar-logo:hover {
  transform: scale(1.05);
}

.navbar-menu {
  display: flex;
  gap: 32px;
}

.nav-link {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 500;
  color: #374151;
  position: relative;
  padding: 8px 0;
  transition: all 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  transition: width 0.3s ease;
}

.nav-link:hover {
  color: #2563eb;
  transform: scale(1.1);
}

.nav-link:hover::after {
  width: 100%;
}

.navbar-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  width: 28px;
  height: 24px;
  position: relative;
  z-index: 1001;
}

.navbar-toggle span {
  width: 100%;
  height: 3px;
  background: #374151;
  border-radius: 2px;
  transition: all 0.3s ease;
}

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

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

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

.mobile-menu {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  padding: 80px 24px 24px;
  transform: translateY(-100%);
  transition: transform 0.3s ease;
  border-bottom: 1px solid rgba(229, 231, 235, 0.5);
  z-index: 999;
}

.mobile-menu.active {
  transform: translateY(0);
}

.mobile-nav-link {
  display: block;
  width: 100%;
  padding: 16px;
  text-align: left;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 500;
  color: #374151;
  transition: all 0.3s ease;
}

.mobile-nav-link:hover {
  color: #2563eb;
  background: rgba(37, 99, 235, 0.05);
  border-radius: 12px;
}

/* Navbar responsive breakpoints */
@media (max-width: 320px) {
  .navbar-logo {
    font-size: 18px;
  }
  .navbar-container {
    padding: 12px 16px;
  }
}

@media (max-width: 480px) {
  .navbar-logo {
    font-size: 20px;
  }
}

@media (max-width: 768px) {
  .navbar-menu {
    display: none;
  }

  .navbar-toggle {
    display: flex;
  }

  .mobile-menu {
    display: block;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .nav-link {
    font-size: 15px;
    gap: 24px;
  }
}

/* ========================================
   HERO SECTION
   ======================================== */
.hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0f172a 0%, #581c87 50%, #0f172a 100%);
  overflow: hidden;
  padding: clamp(100px, 15vh, 120px) 0 clamp(60px, 10vh, 80px);
}

@media (max-width: 768px) {
  .hero-section {
    min-height: auto;
    padding: 100px 0 60px;
  }
}

@media (max-width: 480px) {
  .hero-section {
    padding: 90px 0 50px;
  }
}

/* Floating Shapes */
.floating-shapes {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.floating-shape {
  position: absolute;
  width: 256px;
  height: 256px;
  border-radius: 50%;
  opacity: 0.1;
  animation: float 8s ease-in-out infinite;
}

.shape-1 {
  background: radial-gradient(circle, rgba(99, 102, 241, 0.3), transparent);
  top: 10%;
  left: 5%;
  animation-delay: 0s;
}

.shape-2 {
  background: radial-gradient(circle, rgba(139, 92, 246, 0.3), transparent);
  top: 60%;
  left: 10%;
  animation-delay: 2s;
}

.shape-3 {
  background: radial-gradient(circle, rgba(168, 85, 247, 0.3), transparent);
  top: 30%;
  right: 10%;
  animation-delay: 4s;
}

.shape-4 {
  background: radial-gradient(circle, rgba(59, 130, 246, 0.3), transparent);
  bottom: 20%;
  right: 20%;
  animation-delay: 1s;
}

.shape-5 {
  background: radial-gradient(circle, rgba(16, 185, 129, 0.3), transparent);
  top: 50%;
  left: 50%;
  animation-delay: 3s;
}

.shape-6 {
  background: radial-gradient(circle, rgba(236, 72, 153, 0.3), transparent);
  bottom: 10%;
  left: 30%;
  animation-delay: 5s;
}

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

/* Grid Background */
.grid-background {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(to right, rgba(79, 79, 79, 0.18) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(79, 79, 79, 0.18) 1px, transparent 1px);
  background-size: 14px 24px;
}

/* Gradient Overlays */
.gradient-overlay {
  position: absolute;
  width: 384px;
  height: 384px;
  border-radius: 50%;
  filter: blur(96px);
}

.overlay-1 {
  top: 0;
  left: 0;
  background: rgba(59, 130, 246, 0.3);
}

.overlay-2 {
  bottom: 0;
  right: 0;
  background: rgba(168, 85, 247, 0.3);
}

/* Hero Container */
.hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  align-items: center;
}

@media (min-width: 768px) {
  .hero-grid {
    grid-template-columns: 1fr 1fr;
    gap: 48px;
  }
}

@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1.2fr 1fr;
    gap: 64px;
  }
}

.hero-content {
  text-align: left;
  opacity: 0;
  animation: fadeInUp 0.8s ease forwards;
}

.animate-in {
  opacity: 0;
  animation: fadeInUp 0.8s ease forwards;
}

.delay-300 {
  animation-delay: 0.3s;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hero Badge */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: clamp(6px, 2vw, 8px);
  padding: clamp(6px, 2vw, 8px) clamp(12px, 4vw, 16px);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 9999px;
  margin-bottom: clamp(16px, 4vw, 24px);
  animation: fadeInDown 0.8s ease 0.2s forwards;
  opacity: 0;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sparkle {
  font-size: 18px;
}

.hero-badge span:last-child {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
}

/* Hero Title */
.hero-title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(32px, 8vw, 56px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: clamp(16px, 3vw, 24px);
}

.text-white {
  color: white;
}

.gradient-text {
  background: linear-gradient(135deg, #60a5fa 0%, #a78bfa 50%, #f472b6 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Hero Subtitle */
.hero-subtitle {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(20px, 5vw, 32px);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 16px;
}
/* Typing cursor for hero subtitle */
.typed-cursor {
  display: inline-block;
  margin-left: 6px;
  color: #7c3aed;
  font-weight: 700;
  animation: blink 1s steps(2, start) infinite;
}

@keyframes blink {
  to { visibility: hidden; }
}

/* Hero Description */
.hero-description {
  font-family: 'Inter', sans-serif;
  font-size: clamp(16px, 3.5vw, 20px);
  color: rgba(255, 255, 255, 0.7);
  max-width: min(560px, 100%);
  margin-bottom: clamp(24px, 4vw, 32px);
  line-height: 1.6;
}

/* Hero Buttons */
.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 32px;
  align-items: center;
}

.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: clamp(12px, 3vw, 16px) clamp(20px, 5vw, 32px);
  font-family: 'Inter', sans-serif;
  font-size: clamp(14px, 2.5vw, 16px);
  font-weight: 600;
  border-radius: 9999px;
  transition: all 0.3s ease;
  position: relative;
  overflow: visible;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  outline: none;
  flex-shrink: 0;
}

.btn-primary {
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  color: white;
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #7c3aed 0%, #ec4899 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.btn-primary:hover::before {
  opacity: 1;
}

.btn-primary span,
.btn-primary svg {
  position: relative;
  z-index: 1;
}

.btn-primary:hover {
  transform: scale(1.05);
}

.arrow-icon {
  transition: transform 0.3s ease;
}

.btn-primary:hover .arrow-icon {
  transform: translateX(4px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.05);
}

/* Hero Download button - innovative hover animation */
.hero-buttons .btn-secondary {
  --accent: rgba(124,58,237,0.12);
  overflow: visible;
  transition: transform 0.36s cubic-bezier(.2,.9,.2,1), box-shadow 0.36s ease, background 0.36s ease;
}
.hero-buttons .btn-secondary::after {
  content: '';
  position: absolute;
  top: -40%;
  left: -30%;
  width: 160%;
  height: 200%;
  background: linear-gradient(120deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0.18) 40%, rgba(255,255,255,0.06) 70%);
  transform: translateX(-120%) rotate(-12deg);
  transition: transform 0.6s cubic-bezier(.2,.9,.2,1), opacity 0.4s ease;
  pointer-events: none;
  mix-blend-mode: screen;
}
.hero-buttons .btn-secondary:hover::after {
  transform: translateX(0) rotate(-12deg);
  opacity: 1;
}
.hero-buttons .btn-secondary span {
  position: relative;
  display: inline-block;
  transition: transform 0.36s cubic-bezier(.2,.9,.2,1);
  white-space: nowrap;
  overflow: visible;
}
.hero-buttons .btn-secondary svg {
  position: relative;
  transition: transform 0.5s cubic-bezier(.2,.9,.2,1), filter 0.36s ease;
  flex-shrink: 0;
}
.hero-buttons .btn-secondary:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 18px 40px rgba(124,58,237,0.16), 0 6px 18px rgba(16,24,40,0.08);
}
.hero-buttons .btn-secondary:hover span {
  transform: translateX(10px);
}
.hero-buttons .btn-secondary:hover svg {
  transform: translateX(12px) rotate(12deg) translateZ(0);
  filter: drop-shadow(0 6px 14px rgba(124,58,237,0.18));
}
.hero-buttons .btn-secondary:focus-visible {
  outline: 3px solid rgba(124,58,237,0.18);
  outline-offset: 4px;
}

/* Neon-style Download button (inspired by attached image) */
.neon-btn {
  --neon1: #60a5fa; /* sky */
  --neon2: #7c3aed; /* purple */
  --neon3: #f472b6; /* pink */
  color: #e6f0ff;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  border: 1px solid rgba(255,255,255,0.06);
  position: relative;
  overflow: visible;
  z-index: 1;
  transition: transform 0.28s cubic-bezier(.2,.9,.2,1), box-shadow 0.28s ease, color 0.18s ease;
  padding: 12px 22px; /* medium size */
  font-size: 15px;
  gap: 8px;
  -webkit-tap-highlight-color: transparent;
}

.neon-btn::before {
  /* soft multi-color blurred glow behind the button */
  content: '';
  position: absolute;
  top: -10px;
  left: -14px;
  right: -14px;
  bottom: -10px;
  border-radius: 9999px;
  background: linear-gradient(90deg, var(--neon1), var(--neon2), var(--neon3));
  filter: blur(18px);
  opacity: 0.28;
  z-index: -2;
  pointer-events: none;
  transition: opacity 0.28s ease, transform 0.36s ease;
}

.neon-btn::after {
  /* crisp inner stroke to define the button edge */
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 2px;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  z-index: -1;
  pointer-events: none;
}

.neon-btn .icon-glow {
  transition: filter 0.36s ease, transform 0.36s ease;
}

.neon-btn svg {
  color: currentColor;
  filter: drop-shadow(0 6px 18px rgba(124,58,237,0.18));
  width: 18px;
  height: 18px;
}

.neon-btn {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

.neon-btn span {
  white-space: nowrap;
}

.neon-btn svg {
  flex-shrink: 0;
}

.neon-btn:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 12px 40px rgba(124,58,237,0.12), 0 6px 20px rgba(96,165,250,0.06);
}

.neon-btn:hover::before {
  opacity: 0.9;
  transform: scale(1.03);
}

.neon-btn:hover svg {
  filter: drop-shadow(0 10px 32px rgba(124,58,237,0.36));
  transform: translateX(12px) rotate(8deg);
}

.neon-btn:active {
  transform: translateY(-1px) scale(0.995);
}

.neon-btn:focus-visible {
  outline: 3px solid rgba(124,58,237,0.28);
  outline-offset: 6px;
}

/* subtle animated sheen moving across when hovered */
.neon-btn .neon-sheen {
  position: absolute;
  top: -30%;
  left: -40%;
  width: 180%;
  height: 220%;
  background: linear-gradient(120deg, rgba(255,255,255,0.02) 0%, rgba(255,255,255,0.18) 45%, rgba(255,255,255,0.02) 70%);
  transform: translateX(-140%) rotate(-12deg);
  transition: transform 0.9s cubic-bezier(.2,.9,.2,1), opacity 0.4s ease;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0.85;
  z-index: 0;
}

.neon-btn:hover .neon-sheen {
  transform: translateX(0) rotate(-12deg);
}

/* Apply neon look on contact panel download button (rounded rectangle) */
.btn-download.neon-btn {
  border-radius: 14px;
  padding: 12px 22px;
  background: transparent;
  color: #e6f0ff;
  width: auto; /* don't force full-width */
  display: inline-flex;
}


/* Make skills Show more button more visible (centered, colored)
   Targets the toggle inserted after the skills grid */
.skills-toggle .btn-secondary {
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  color: #fff;
  border: none;
  padding: 12px 24px;
  box-shadow: 0 8px 30px rgba(37,99,235,0.18);
}
.skills-toggle .btn-secondary:hover {
  transform: scale(1.04);
  box-shadow: 0 12px 40px rgba(37,99,235,0.22);
}

/* Center the skills toggle wrapper and ensure small spacing for the button */
.skills-toggle {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin-top: 24px;
}
.skills-toggle .btn-secondary {
  margin: 2px;
}

/* Social Links */
.hero-social {
  display: flex;
  gap: clamp(10px, 3vw, 16px);
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
}

@media (max-width: 360px) {
  .hero-social {
    gap: 8px;
    justify-content: center;
  }
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(40px, 10vw, 48px);
  height: clamp(40px, 10vw, 48px);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  color: white;
  transition: all 0.3s ease;
}

.social-icon:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1) rotate(5deg);
}
.social-icon:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1) rotate(5deg);
}

/* WhatsApp specific style for hero + footer icons: circular, green background */
.social-icon[aria-label="WhatsApp"],
.footer-social-icon[aria-label="WhatsApp"] {
  background: linear-gradient(135deg, #25D366 0%, #16A34A 100%);
  color: #ffffff;
  width: 48px;
  height: 48px;
  padding: 8px;
  border-radius: 50%; /* circular */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 30px rgba(37, 211, 102, 0.14);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.social-icon[aria-label="WhatsApp"] svg,
.footer-social-icon[aria-label="WhatsApp"] svg {
  width: 20px;
  height: 20px;
  fill: white;
}

.social-icon[aria-label="WhatsApp"]:hover,
.footer-social-icon[aria-label="WhatsApp"]:hover {
  transform: translateY(-3px) scale(1.06);
  box-shadow: 0 18px 48px rgba(16, 163, 82, 0.22);
}

/* Platform-specific social icon colors (hero + footer) */
.social-icon[aria-label="GitHub"],
.footer-social-icon[aria-label="GitHub"] {
  background: linear-gradient(135deg, #111827 0%, #1f2937 100%);
  color: #ffffff;
  width: 48px;
  height: 48px;
  padding: 8px;
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(0,0,0,0.28);
}

.social-icon[aria-label="LinkedIn"],
.footer-social-icon[aria-label="LinkedIn"] {
  background: linear-gradient(135deg, #0A66C2 0%, #004182 100%);
  color: #ffffff;
  width: 48px;
  height: 48px;
  padding: 8px;
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(10,102,194,0.18);
}

.social-icon[aria-label="Instagram"],
.footer-social-icon[aria-label="Instagram"] {
  background: radial-gradient(circle at 30% 10%, #feda75 0%, #f58529 25%, #dd2a7b 50%, #8134af 75%, #515bd4 100%);
  color: #ffffff;
  width: 48px;
  height: 48px;
  padding: 8px;
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(217,80,128,0.14);
}

.social-icon[aria-label="Twitter"],
.footer-social-icon[aria-label="Twitter"] {
  background: linear-gradient(135deg, #1DA1F2 0%, #0d95e8 100%);
  color: #ffffff;
  width: 48px;
  height: 48px;
  padding: 8px;
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(29,161,242,0.16);
}

.social-icon[aria-label="Email"],
.footer-social-icon[aria-label="Email"] {
  background: linear-gradient(135deg, #6b7280 0%, #374151 100%);
  color: #ffffff;
  width: 48px;
  height: 48px;
  padding: 8px;
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(55,65,81,0.14);
}

/* Shared hover for platform icons */
.social-icon[aria-label],
.footer-social-icon[aria-label] {
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.social-icon[aria-label]:hover,
.footer-social-icon[aria-label]:hover {
  transform: translateY(-3px) scale(1.06);
  filter: saturate(1.05);
}

/* ========================================
   3D PYTHON CUBE
   ======================================== */
.cube-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1000px;
  max-width: 100%;
  width: 100%;
}

@media (max-width: 768px) {
  .cube-wrapper {
    order: -1;
    margin-bottom: 20px;
  }
}

@media (max-width: 480px) {
  .cube-wrapper {
    max-width: 280px;
    margin: 0 auto 20px;
  }
}

.python-cube-container {
  position: relative;
  width: min(320px, 90vw);
  height: min(320px, 90vw);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Orbit Rings */
.orbit-ring {
  position: absolute;
  border: 2px solid;
  border-radius: 50%;
  animation: rotate 20s linear infinite;
}

.ring-1 {
  width: 384px;
  height: 384px;
  border-color: rgba(96, 165, 250, 0.3);
  animation-duration: 20s;
}

.ring-2 {
  width: 320px;
  height: 320px;
  border-color: rgba(168, 85, 247, 0.3);
  animation-duration: 15s;
  animation-direction: reverse;
}

.ring-3 {
  width: 256px;
  height: 256px;
  border-color: rgba(244, 114, 182, 0.3);
  animation-duration: 10s;
}

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

/* Floating Particles */
.orbit-particle {
  position: absolute;
  width: 8px;
  height: 8px;
  background: linear-gradient(135deg, #60a5fa 0%, #a78bfa 100%);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

.p-0 { left: 50%; top: 10%; animation-delay: 0s; }
.p-1 { left: 76%; top: 24%; animation-delay: 0.2s; }
.p-2 { left: 90%; top: 50%; animation-delay: 0.4s; }
.p-3 { left: 76%; top: 76%; animation-delay: 0.6s; }
.p-4 { left: 50%; top: 90%; animation-delay: 0.8s; }
.p-5 { left: 24%; top: 76%; animation-delay: 1s; }
.p-6 { left: 10%; top: 50%; animation-delay: 1.2s; }
.p-7 { left: 24%; top: 24%; animation-delay: 1.4s; }

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

/* 3D Cube */
.cube-3d {
  position: relative;
  width: min(288px, 85vw);
  height: min(288px, 85vw);
  transform-style: preserve-3d;
  animation: cubeRotate 20s linear infinite;
  transition: transform 0.5s ease;
}

.cube-3d:hover {
  animation-play-state: paused;
}

@keyframes cubeRotate {
  0% {
    transform: rotateX(15deg) rotateY(0deg);
  }
  100% {
    transform: rotateX(15deg) rotateY(360deg);
  }
}

.cube-face {
  position: absolute;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(147, 51, 234, 0.15) 100%);
  backdrop-filter: blur(20px);
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: clamp(12px, 3vw, 24px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  backface-visibility: hidden;
  box-shadow: 0 8px 32px 0 rgba(59, 130, 246, 0.37);
}

.face-front {
  transform: translateZ(144px);
}

.face-right {
  transform: rotateY(90deg) translateZ(144px);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(5, 150, 105, 0.15) 100%);
}

.face-back {
  transform: rotateY(180deg) translateZ(144px);
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.15) 0%, rgba(168, 85, 247, 0.15) 100%);
}

.face-left {
  transform: rotateY(-90deg) translateZ(144px);
  background: linear-gradient(135deg, rgba(34, 139, 34, 0.15) 0%, rgba(0, 100, 0, 0.15) 100%);
}

.face-top {
  transform: rotateX(90deg) translateZ(144px);
  background: linear-gradient(135deg, rgba(236, 72, 153, 0.15) 0%, rgba(219, 39, 119, 0.15) 100%);
}

.face-bottom {
  transform: rotateX(-90deg) translateZ(144px);
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.15) 0%, rgba(234, 88, 12, 0.15) 100%);
}

.py-logo {
  font-family: 'Poppins', sans-serif;
  font-size: 80px;
  font-weight: 700;
  background: linear-gradient(135deg, #60a5fa 0%, #3b82f6 50%, #2563eb 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  position: relative;
  animation: glow 2s ease-in-out infinite;
}

@keyframes glow {
  0%, 100% {
    filter: drop-shadow(0 0 20px rgba(59, 130, 246, 0.5));
  }
  50% {
    filter: drop-shadow(0 0 40px rgba(59, 130, 246, 0.8));
  }
}

.py-dot {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 24px;
  height: 24px;
  background: #fbbf24;
  border-radius: 50%;
  animation: dotPulse 1.5s ease-in-out infinite;
}

@keyframes dotPulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 10px rgba(250, 204, 21, 0.5);
  }
  50% {
    transform: scale(1.2);
    box-shadow: 0 0 20px rgba(250, 204, 21, 0.8);
  }
}

.face-emoji {
  font-size: 24px;
  font-weight: 700;
  color: #10b981;
  margin-bottom: 8px;
  animation: fadeInOut 2s ease-in-out infinite;
}

.face-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  text-align: center;
  font-family: 'monospace';
  line-height: 1.4;
}

.face-code {
  font-size: 14px;
  color: #c084fc;
  font-family: 'monospace';
  line-height: 1.6;
  animation: fadeInOut 3s ease-in-out infinite;
}

.face-title {
  font-family: 'Poppins', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: #f472b6;
  animation: scaleUp 2s ease-in-out infinite;
}

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

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

/* Central Glow */
.central-glow {
  position: absolute;
  width: 256px;
  height: 256px;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(168, 85, 247, 0.2) 50%, rgba(236, 72, 153, 0.2) 100%);
  border-radius: 50%;
  filter: blur(64px);
  animation: glowPulse 4s ease-in-out infinite;
  pointer-events: none;
}

@keyframes glowPulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.3;
  }
  50% {
    transform: scale(1.2);
    opacity: 0.6;
  }
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollBounce 1.5s ease-in-out infinite;
}

@keyframes scrollBounce {
  0%, 100% {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
  }
  50% {
    transform: translateX(-50%) translateY(-10px);
    opacity: 0.5;
  }
}

.scroll-mouse {
  width: 24px;
  height: 40px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
}

.scroll-wheel {
  width: 6px;
  height: 12px;
  background: white;
  border-radius: 3px;
  animation: wheelScroll 1.5s ease-in-out infinite;
}

@keyframes wheelScroll {
  0% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(12px);
  }
  100% {
    transform: translateY(0);
  }
}

/* ========================================
   SECTION STYLES
   ======================================== */
.section {
  position: relative;
  padding: 128px 0;
  overflow: hidden;
}

.about-section {
  background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
}

.skills-section {
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 100%);
}

.projects-section {
  background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
}

.experience-section {
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 100%);
}

.contact-section {
  background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
}

/* Section Background Blobs */
.section-bg-blob,
.section-radial,
.project-blob,
.contact-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(96px);
  opacity: 0.3;
}

/* Make decorative blobs non-interactive so they don't block form inputs */
.contact-section .contact-blob {
  pointer-events: none;
}

.blob-1 {
  top: 80px;
  right: 0;
  width: 384px;
  height: 384px;
  background: #dbeafe;
}

.blob-2 {
  bottom: 80px;
  left: 0;
  width: 384px;
  height: 384px;
  background: #e9d5ff;
}

.radial-1,
.radial-2 {
  width: 100%;
  height: 100%;
}

.radial-1 {
  background: radial-gradient(circle at 30% 50%, rgba(99, 102, 241, 0.05), transparent 50%);
}

.radial-2 {
  background: radial-gradient(circle at 70% 50%, rgba(168, 85, 247, 0.05), transparent 50%);
}

.pb1 {
  top: 80px;
  left: 40px;
  width: 288px;
  height: 288px;
  background: #dbeafe;
}

.pb2 {
  bottom: 80px;
  right: 40px;
  width: 288px;
  height: 288px;
  background: #e9d5ff;
}

.cb1 {
  top: 80px;
  left: 0;
  width: 384px;
  height: 384px;
  background: #dbeafe;
}

.cb2 {
  bottom: 80px;
  right: 0;
  width: 384px;
  height: 384px;
  background: #e9d5ff;
}

/* Section Header */
.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-badge {
  display: inline-block;
  padding: 8px 16px;
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
  transition: transform 0.3s ease;
}

.section-badge:hover {
  transform: scale(1.05);
}

.badge-blue {
  background: #dbeafe;
  color: #2563eb;
}

.badge-purple {
  background: #e9d5ff;
  color: #7c3aed;
}

.badge-green {
  background: #d1fae5;
  color: #059669;
}

.badge-orange {
  background: #fed7aa;
  color: #ea580c;
}

.badge-pink {
  background: #fce7f3;
  color: #db2777;
}

.section-title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(28px, 6vw, 48px);
  font-weight: 800;
  background: linear-gradient(135deg, #1f2937 0%, #6b7280 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 16px;
}

.section-divider {
  width: 96px;
  height: 4px;
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  margin: 0 auto;
  border-radius: 9999px;
}

.section-subtitle {
  font-size: 20px;
  color: #6b7280;
  margin-top: 24px;
  font-family: 'Inter', sans-serif;
}

/* ========================================
   ABOUT SECTION
   ======================================== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
  margin-bottom: 64px;
}

.feature-card {
  position: relative;
  background: white;
  border-radius: 16px;
  padding: 32px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(243, 244, 246, 1);
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.feature-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.6s ease;
}

.feature-card:hover .feature-icon {
  transform: rotate(360deg) scale(1.1);
}

.icon-blue {
  background: linear-gradient(135deg, #3b82f6 0%, #06b6d4 100%);
  color: white;
}

.icon-purple {
  background: linear-gradient(135deg, #7c3aed 0%, #ec4899 100%);
  color: white;
}

.icon-orange {
  background: linear-gradient(135deg, #f97316 0%, #ef4444 100%);
  color: white;
}

.icon-green {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: white;
}

.feature-title {
  font-family: 'Poppins', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 8px;
}

.feature-desc {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #6b7280;
  line-height: 1.6;
}

.about-text-box {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 48px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(243, 244, 246, 1);
  max-width: 1000px;
  margin: 0 auto;
}

.about-text {
  font-family: 'Inter', sans-serif;
  font-size: 20px;
  color: #374151;
  line-height: 1.8;
  margin-bottom: 24px;
}

.about-text:last-child {
  margin-bottom: 0;
}

.highlight-blue {
  font-weight: 700;
  color: #2563eb;
}

.highlight-purple {
  font-weight: 700;
  color: #7c3aed;
}

.highlight-bold {
  font-weight: 700;
}

/* ========================================
   SKILLS SECTION
   ======================================== */
.tech-stack-3d {
  position: relative;
  display: flex;
  justify-content: center;
  margin-bottom: 96px;
  padding: 100px 0;
  background: linear-gradient(90deg, #1e3a8a 0%, #312e81 30%, #581c87 70%, #6b21a8 100%);
  border-radius: 32px;
  overflow: visible;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.tech-orbit {
  position: relative;
  width: 550px;
  height: 550px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tech-glow {
  position: absolute;
  width: 450px;
  height: 450px;
  background: transparent;
  border: 3px solid rgba(168, 85, 247, 0.4);
  border-radius: 50%;
  box-shadow: 
    0 0 40px rgba(168, 85, 247, 0.6),
    0 0 80px rgba(147, 51, 234, 0.4),
    inset 0 0 60px rgba(168, 85, 247, 0.2);
  animation: glowPulse 3s ease-in-out infinite;
}

.tech-ring {
  position: absolute;
  border: 2px solid;
  border-radius: 50%;
  opacity: 0.08;
}

.tr1 {
  width: 500px;
  height: 500px;
  border-color: rgba(168, 85, 247, 0.3);
  animation: rotate 40s linear infinite;
}

.tr2 {
  width: 420px;
  height: 420px;
  border-color: rgba(147, 51, 234, 0.3);
  animation: rotate 30s linear infinite reverse;
}

.tr3 {
  width: 360px;
  height: 360px;
  border-color: rgba(126, 34, 206, 0.3);
  animation: rotate 25s linear infinite;
}

.tech-icon-orbital {
  position: absolute;
  width: 90px;
  height: 90px;
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 700;
  color: white;
  box-shadow: 
    0 15px 35px rgba(0, 0, 0, 0.5),
    0 5px 15px rgba(0, 0, 0, 0.3),
    inset 0 -8px 16px rgba(0, 0, 0, 0.2),
    inset 0 2px 8px rgba(255, 255, 255, 0.15);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  transform-style: preserve-3d;
  backface-visibility: visible;
}

.tech-icon-orbital:hover {
  transform: scale(1.15) translateZ(20px) !important;
  box-shadow: 
    0 20px 50px rgba(0, 0, 0, 0.6),
    0 10px 25px rgba(0, 0, 0, 0.4),
    inset 0 -8px 16px rgba(0, 0, 0, 0.2),
    inset 0 2px 8px rgba(255, 255, 255, 0.2);
}

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

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: clamp(24px, 4vw, 32px);
  margin-bottom: 64px;
}

@media (max-width: 480px) {
  .skills-grid {
    grid-template-columns: 1fr;
  }
}

.skill-card {
  position: relative;
  background: white;
  border-radius: 24px;
  padding: 40px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  border: 1px solid #f3f4f6;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

.skill-card:hover {
  transform: translateY(-12px);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.15);
}

.skill-icon-wrapper {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  transition: transform 0.4s ease;
}

.skill-card:hover .skill-icon-wrapper {
  transform: scale(1.1) rotate(5deg);
}

.skill-icon-wrapper svg {
  color: white;
}

.skill-name {
  font-family: 'Poppins', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #1f2937;
  text-align: center;
  margin-bottom: 16px;
}

.skill-progress {
  position: relative;
  width: 100%;
  height: 12px;
  background: #e5e7eb;
  border-radius: 9999px;
  overflow: hidden;
  margin-bottom: 12px;
}

.skill-progress-bar {
  height: 100%;
  border-radius: 9999px;
  transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1) 0.3s;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.2);
}

.skill-level {
  font-family: 'Poppins', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: #6b7280;
  text-align: center;
}

.additional-skills {
  text-align: center;
}

.additional-title {
  font-family: 'Poppins', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 32px;
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  max-width: 900px;
  margin: 0 auto;
}

.tech-tag {
  padding: 12px 24px;
  background: white;
  border: 2px solid #e5e7eb;
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #374151;
  transition: all 0.3s ease;
  opacity: 0;
  animation: fadeInUp 0.5s ease forwards;
}

.tech-tag:hover {
  transform: translateY(-4px);
  border-color: #7c3aed;
  color: #7c3aed;
  box-shadow: 0 8px 16px rgba(124, 58, 237, 0.2);
}

/* ========================================
   PROJECTS SECTION
   ======================================== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr));
  gap: clamp(32px, 5vw, 48px);
}

@media (max-width: 480px) {
  .projects-grid {
    grid-template-columns: 1fr;
  }
}

.projects-toggle {
  display: flex;
  justify-content: center;
  margin-top: 28px;
}

.projects-toggle #projectsToggleBtn {
  padding: 12px 22px;
  border-radius: 12px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  border: none;
  color: #ffffff;
  font-weight: 700;
  backdrop-filter: blur(6px);
  box-shadow: 0 8px 30px rgba(37, 99, 235, 0.18), 0 4px 12px rgba(124, 58, 237, 0.08);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.projects-toggle #projectsToggleBtn:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 14px 40px rgba(37, 99, 235, 0.22), 0 8px 20px rgba(124, 58, 237, 0.12);
}

.project-card {
  perspective: 1000px;
  height: clamp(500px, 120vw, 600px);
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

@media (max-width: 480px) {
  .project-card {
    height: auto;
    min-height: 500px;
  }
}

.project-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
  -webkit-transform-style: preserve-3d;
  will-change: transform;
  outline: none;
}

.project-card:hover .project-card-inner {
  transform: rotateY(180deg);
  -webkit-transform: rotateY(180deg);
}

.project-card-front,
.project-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  -moz-backface-visibility: hidden;
  border-radius: 24px;
  overflow: hidden;
  outline: none;
}

.project-card-front {
  background: white;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  transform: translateZ(1px);
  -webkit-transform: translateZ(1px);
}

.project-icon-container {
  position: relative;
  height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Thumbnail image inside project icon container */
.project-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-3d-icon {
  font-size: 120px;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.3));
  animation: float 4s ease-in-out infinite;
}

.project-stats {
  position: absolute;
  top: 20px;
  left: 20px;
  display: flex;
  gap: 12px;
}

.stat-badge {
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: #1f2937;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.flip-hint {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 8px 20px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #7c3aed;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  gap: 8px;
}

.project-content {
  padding: 32px;
}

.project-title {
  font-family: 'Poppins', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 16px;
}

.project-description {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: #6b7280;
  line-height: 1.7;
  margin-bottom: 24px;
}

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

.tech-badge {
  padding: 6px 14px;
  background: #f3f4f6;
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #6b7280;
}

/* Project Card Back */
.project-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  -moz-backface-visibility: hidden;
  transform: rotateY(180deg) translateZ(1px);
  -webkit-transform: rotateY(180deg) translateZ(1px);
  color: white;
  padding: 40px;
  display: flex;
  flex-direction: column;
  border-radius: 24px;
  overflow: hidden;
  outline: none;
  justify-content: space-between;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.project-back-content {
  flex: 1;
}

.project-back-title {
  font-family: 'Poppins', sans-serif;
  font-size: 32px;
  font-weight: 800;
  color: white;
  margin-bottom: 16px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

.project-back-description {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.95);
  line-height: 1.7;
  margin-bottom: 24px;
}

.project-features {
  margin-bottom: 24px;
}

.features-title {
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: white;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.features-grid-2col {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
}

.feature-dot {
  width: 6px;
  height: 6px;
  background: white;
  border-radius: 50%;
  flex-shrink: 0;
}

.project-tech-list {
  margin-bottom: 24px;
}

.tech-list-title {
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: white;
  margin-bottom: 12px;
}

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

.tech-list-badge {
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: white;
}

.project-buttons {
  display: flex;
  gap: 16px;
}

.btn-code,
.btn-demo {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 12px;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 600;
  transition: all 0.3s ease;
  cursor: pointer;
}

.btn-code {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: white;
}

.btn-code:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
}

.btn-demo {
  background: white;
  color: #1f2937;
}

.btn-demo:hover {
  background: rgba(255, 255, 255, 0.9);
  transform: translateY(-2px);
}

/* ========================================
   EXPERIENCE SECTION
   ======================================== */
.experience-pattern {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(to right, rgba(229, 231, 235, 0.3) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(229, 231, 235, 0.3) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.5;
}

.timeline {
  position: relative;
  max-width: 1100px;
  margin: 0 auto;
  padding: clamp(24px, 5vw, 40px) 0;
}

@media (max-width: 768px) {
  .timeline::before {
    left: 20px !important;
  }
  
  .timeline-item {
    padding-left: 0;
  }
}

/* Company logo shown above timeline items */
.timeline-company-logo {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}
.timeline-company-logo img {
  width: 96px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

/* Align logos to left or right inside timeline-content depending on side */
.timeline-company-logo.align-left {
  justify-content: flex-start;
}
.timeline-company-logo.align-right {
  justify-content: flex-end;
}

.timeline-line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #3b82f6 0%, #7c3aed 50%, #ec4899 100%);
  transform: translateX(-50%);
  z-index: 0;
}

.timeline-item {
  position: relative;
  margin-bottom: 60px;
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
  min-height: auto;
}

@media (max-width: 768px) {
  .timeline-item {
    min-height: auto;
    margin-bottom: 40px;
  }
}

.timeline-item:nth-child(odd) .timeline-content {
  margin-right: calc(50% + 40px);
  text-align: right;
}

.timeline-item:nth-child(even) .timeline-content {
  margin-left: calc(50% + 40px);
  text-align: left;
}

.timeline-marker {
  position: absolute;
  left: 50%;
  top: 20px;
  width: 20px;
  height: 20px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: white;
  border: 4px solid;
  z-index: 2;
  box-shadow: 0 0 0 6px rgba(255, 255, 255, 1);
}

.timeline-content {
  position: relative;
  background: white;
  border-radius: 16px;
  padding: 32px 36px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .timeline-content {
    padding: 20px 16px;
    border-radius: 12px;
  }
}

.timeline-content:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

.timeline-date {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: white;
  color: #3b82f6;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 12px;
}

.timeline-date svg {
  color: #3b82f6;
}

.timeline-role {
  font-family: 'Poppins', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 10px;
  line-height: 1.3;
}

.timeline-company {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
}

.timeline-company svg {
  color: #6b7280;
  flex-shrink: 0;
}

.timeline-item:nth-child(odd) .timeline-company {
  justify-content: flex-end;
}

.timeline-location {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 16px;
}

.timeline-location svg {
  flex-shrink: 0;
}

.timeline-item:nth-child(odd) .timeline-location {
  justify-content: flex-end;
}

.timeline-description {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #6b7280;
  line-height: 1.7;
  margin-bottom: 20px;
}

.timeline-achievements {
  margin-top: 20px;
}

.timeline-achievements-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: #059669;
  margin-bottom: 14px;
}

.timeline-achievements-title svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.timeline-item:nth-child(odd) .timeline-achievements-title {
  justify-content: flex-end;
}

.timeline-achievements-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.timeline-achievements-list li {
  position: relative;
  padding-left: 20px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  color: #4b5563;
  line-height: 1.8;
  margin-bottom: 10px;
}

.timeline-item:nth-child(odd) .timeline-achievements-list li {
  padding-left: 0;
  padding-right: 20px;
  text-align: right;
}

.timeline-achievements-list li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 9px;
  width: 6px;
  height: 6px;
  background: #3b82f6;
  border-radius: 50%;
}

.timeline-item:nth-child(odd) .timeline-achievements-list li::before {
  left: auto;
  right: 4px;
}

/* ========================================
   CONTACT SECTION
   ======================================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: clamp(32px, 6vw, 64px);
  align-items: start;
}

@media (max-width: 1024px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

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

.contact-item {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 24px;
  background: white;
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  border: 1px solid #f3f4f6;
  transition: all 0.3s ease;
}

.contact-item:hover {
  transform: translateX(8px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

.contact-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.contact-label {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #9ca3af;
  margin-bottom: 4px;
}

.contact-value {
  font-family: 'Poppins', sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: #1f2937;
}

.btn-download {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 18px 32px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: white;
  border-radius: 16px;
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.3);
  cursor: pointer;
}

.btn-download:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(37, 99, 235, 0.4);
}

.contact-form {
  background: white;
  border-radius: clamp(16px, 3vw, 24px);
  padding: clamp(24px, 5vw, 48px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  border: 1px solid #f3f4f6;
  position: relative;
  z-index: 5;
}

@media (max-width: 480px) {
  .contact-form {
    padding: 24px 20px;
  }
}

.form-group {
  margin-bottom: 24px;
}

.form-group label {
  display: block;
  font-family: 'Poppins', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 16px 20px;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: #1f2937;
  background: #f9fafb;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  transition: all 0.3s ease;
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
  background: white;
  border-color: #7c3aed;
  box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.1);
}

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

/* Improve mobile typing: prevent iOS zoom on focus and ensure textarea is tappable */
@media (max-width: 768px) {
  .form-group textarea {
    font-size: 16px; /* iOS won't zoom when font-size >= 16px */
    padding: 18px 18px;
    -webkit-text-size-adjust: 100%;
  }
}

.btn-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 18px 32px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: white;
  border-radius: 16px;
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.3);
  cursor: pointer;
}

.btn-submit:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(37, 99, 235, 0.4);
}

/* ========================================
   FOOTER
   ======================================== */
.footer {
  position: relative;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 50%, #581c87 100%);
  color: white;
  padding: 80px 0 32px;
  overflow: hidden;
}

.footer-pattern {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.3;
}

.footer-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(96px);
  opacity: 0.1;
}

.fb1 {
  top: 0;
  left: 0;
  width: 384px;
  height: 384px;
  background: #3b82f6;
}

.fb2 {
  bottom: 0;
  right: 0;
  width: 384px;
  height: 384px;
  background: #a855f7;
}

.footer-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr));
  gap: clamp(32px, 5vw, 64px);
  margin-bottom: 48px;
  z-index: 1;
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

.footer-brand {
  max-width: 400px;
}

.footer-logo {
  font-family: 'Poppins', sans-serif;
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, #60a5fa, #a78bfa, #f472b6);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 16px;
}

.footer-text {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.7;
  margin-bottom: 24px;
}

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

.footer-social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  color: white;
  transition: all 0.3s ease;
}

.footer-social-icon:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-4px);
}

.footer-heading {
  font-family: 'Poppins', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: white;
  margin-bottom: 24px;
}

.footer-nav {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-nav li button {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.7);
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: left;
}

.footer-nav li button:hover {
  color: white;
  transform: translateX(4px);
}

.footer-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: white;
  border-radius: 12px;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 600;
  transition: all 0.3s ease;
  cursor: pointer;
  margin-top: 16px;
}

.footer-btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.4);
}

.footer-bottom {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 1;
}

@media (max-width: 480px) {
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
}

.footer-copyright {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
}

.heart {
  color: #ef4444;
  animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
  0%, 100% {
    transform: scale(1);
  }
  25% {
    transform: scale(1.2);
  }
  50% {
    transform: scale(1);
  }
}

.footer-rights {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
}

/* ========================================
   SCROLL TO TOP BUTTON
   ======================================== */
.scroll-top-btn {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.4);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 1000;
}

.scroll-top-btn.visible {
  opacity: 1;
  pointer-events: all;
}

.scroll-top-btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(37, 99, 235, 0.5);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

/* Extra Small Mobile (320px - 360px) */
@media (max-width: 360px) {
  .hero-badge {
    padding: 6px 12px;
    font-size: 12px;
  }
  
  .hero-badge span:last-child {
    font-size: 11px;
  }
  
  .hero-title {
    font-size: 28px;
    margin-bottom: 12px;
  }
  
  .hero-subtitle {
    font-size: 18px;
  }
  
  .hero-description {
    font-size: 14px;
    margin-bottom: 20px;
  }
  
  .hero-buttons {
    flex-direction: column;
    width: 100%;
    gap: 12px;
    align-items: center;
    justify-content: center;
  }
  
  .btn-primary,
  .btn-secondary {
    width: auto;
    justify-content: center;
    padding: 14px 24px;
    font-size: 14px;
    min-height: 48px;
    flex-shrink: 0;
  }
  
  .btn-secondary svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
  }
  
  .btn-secondary span {
    display: inline-block;
    white-space: nowrap;
  }
  
  .social-icon {
    width: 40px;
    height: 40px;
  }
  
  .section-title {
    font-size: 24px;
  }
  
  .section-badge {
    font-size: 11px;
    padding: 6px 12px;
  }
  
  .feature-card,
  .skill-card,
  .project-card {
    padding: 20px;
  }
  
  .feature-icon {
    width: 48px;
    height: 48px;
  }
  
  .feature-title,
  .skill-name {
    font-size: 16px;
  }
  
  .contact-form {
    padding: 20px 16px;
  }
  
  .contact-item {
    padding: 16px;
    gap: 14px;
    flex-direction: row;
    align-items: center;
  }
  
  .contact-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
  }
  
  .contact-icon svg {
    width: 24px;
    height: 24px;
  }
  
  .contact-label {
    font-size: 12px;
  }
  
  .contact-value {
    font-size: 14px;
    word-break: break-word;
  }
  
  .form-group input,
  .form-group textarea {
    padding: 12px 16px;
    font-size: 15px;
  }
  
  .footer-grid {
    gap: 32px;
  }
  
  .btn-download {
    padding: 14px 24px;
    font-size: 14px;
    width: 100%;
    max-width: 100%;
  }
  
  .section-title {
    font-size: 24px;
    margin-bottom: 16px;
  }
  
  .section-badge {
    font-size: 11px;
    padding: 6px 12px;
    margin-bottom: 12px;
  }
  
  .timeline-date {
    font-size: 13px;
    padding: 5px 10px;
  }
  
  .timeline-role {
    font-size: 18px;
    margin-bottom: 8px;
  }
  
  .timeline-company {
    font-size: 14px;
  }
}

/* Small Mobile (361px - 480px) */
@media (min-width: 361px) and (max-width: 480px) {
  .hero-title {
    font-size: 32px;
  }
  
  .hero-subtitle {
    font-size: 20px;
  }
  
  .hero-description {
    font-size: 15px;
  }
  
  .section-title {
    font-size: 28px;
  }
  
  .hero-buttons {
    flex-direction: column;
    gap: 12px;
    width: 100%;
    align-items: center;
    justify-content: center;
  }
  
  .btn-primary,
  .btn-secondary {
    width: auto;
    min-height: 48px;
    padding: 14px 28px;
    font-size: 15px;
    justify-content: center;
  }
  
  .contact-item {
    padding: 18px 16px;
    gap: 16px;
  }
  
  .contact-icon {
    width: 56px;
    height: 56px;
  }
  
  .contact-value {
    font-size: 15px;
  }
  
  .timeline-content {
    padding: 22px 18px;
  }
  
  .timeline-item:nth-child(odd) .timeline-content,
  .timeline-item:nth-child(even) .timeline-content {
    margin: 0 12px 0 45px;
  }
}

/* Medium Mobile (481px - 767px) */
@media (min-width: 481px) and (max-width: 767px) {
  .hero-title {
    font-size: 36px;
  }
  
  .hero-subtitle {
    font-size: 24px;
  }
  
  .section-title {
    font-size: 32px;
  }
  
  .hero-buttons {
    flex-direction: row;
    gap: 14px;
    justify-content: flex-start;
  }
  
  .btn-primary,
  .btn-secondary {
    width: auto;
    padding: 14px 24px;
    font-size: 15px;
    min-height: 48px;
  }
  
  .features-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }
  
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* Tablet (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .container {
    max-width: 720px;
  }
  
  .hero-grid {
    gap: 48px;
  }
  
  .hero-buttons {
    flex-direction: row;
    gap: 16px;
    justify-content: flex-start;
  }
  
  .btn-primary,
  .btn-secondary {
    width: auto;
    padding: 14px 28px;
    font-size: 15px;
  }
  
  .section-title {
    font-size: 40px;
  }
  
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .skills-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
  
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }
  
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

/* Large Tablet / Small Laptop (1024px - 1279px) */
@media (min-width: 1024px) and (max-width: 1279px) {
  .container {
    max-width: 960px;
  }
  
  .hero-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  .hero-buttons {
    flex-direction: row;
    gap: 16px;
    justify-content: flex-start;
  }
  
  .btn-primary,
  .btn-secondary {
    width: auto;
    padding: 15px 32px;
    font-size: 16px;
  }
  
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Large Desktop (1280px - 1439px) */
@media (min-width: 1280px) and (max-width: 1439px) {
  .container {
    max-width: 1140px;
  }
}

/* Extra Large Desktop (1440px+) */
@media (min-width: 1440px) {
  .container {
    max-width: 1400px;
    padding: 0 32px;
  }
  
  .hero-buttons {
    flex-direction: row;
    gap: 20px;
    justify-content: flex-start;
  }
  
  .btn-primary,
  .btn-secondary {
    width: auto;
    padding: 16px 36px;
    font-size: 16px;
  }
  
  .hero-title {
    font-size: 64px;
  }
  
  .hero-subtitle {
    font-size: 36px;
  }
  
  .section-title {
    font-size: 52px;
  }
  
  .features-grid,
  .skills-grid {
    gap: 32px;
  }
  
  .projects-grid {
    gap: 56px;
  }
}

@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 64px;
  }
  
  .cube-wrapper {
    order: -1;
  }
  
  .projects-grid {
    grid-template-columns: 1fr;
  }
  
  .contact-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  
  .timeline-line {
    left: 20px;
  }
  
  .timeline-item {
    margin-bottom: 32px;
  }
  
  .timeline-item:nth-child(odd) .timeline-content,
  .timeline-item:nth-child(even) .timeline-content {
    margin: 0 12px 0 45px;
    text-align: left;
  }
  
  .timeline-item:nth-child(odd) .timeline-company,
  .timeline-item:nth-child(odd) .timeline-location,
  .timeline-item:nth-child(odd) .timeline-achievements-title {
    justify-content: flex-start;
  }
  
  .timeline-item:nth-child(odd) .timeline-achievements-list li {
    padding-left: 20px;
    padding-right: 0;
    text-align: left;
  }
  
  .timeline-item:nth-child(odd) .timeline-achievements-list li::before {
    left: 4px;
    right: auto;
  }
  
  .timeline-marker {
    left: 20px;
    transform: translateX(-50%);
    width: 16px;
    height: 16px;
  }
}

/* ========================================
   Submission Modal
   ======================================== */
.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}
.modal.show {
  display: flex;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2,6,23,0.6);
  backdrop-filter: blur(4px);
}
.modal-card {
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border-radius: 16px;
  padding: 28px 24px;
  width: 92%;
  max-width: 420px;
  box-shadow: 0 20px 50px rgba(2,6,23,0.25);
  text-align: center;
  transform: translateY(12px);
  animation: modalPop 260ms ease-out forwards;
}
.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 18px;
  cursor: pointer;
}
.modal-illustration {
  font-size: 48px;
  margin-bottom: 12px;
}
.modal-card h3 {
  margin: 0 0 8px 0;
  font-family: 'Poppins', sans-serif;
  font-size: 20px;
}
.modal-text {
  color: #475569;
  margin-bottom: 18px;
}
.modal-actions {
  display: flex;
  justify-content: center;
}
@keyframes modalPop {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 40px;
  }
  
  .hero-subtitle {
    font-size: 24px;
  }
  
  .section-title {
    font-size: 36px;
  }
  
  .skills-grid {
    grid-template-columns: 1fr;
  }
  
  .project-card {
    height: auto;
    min-height: 500px;
    max-height: 600px;
  }
  
  /* Make project card back scrollable on mobile to show all content including buttons */
  .project-card-back {
    padding: 24px;
    overflow-y: auto;
    overflow-x: hidden;
  }
  
  /* Reduce back side content sizes for mobile */
  .project-back-title {
    font-size: 24px;
    margin-bottom: 12px;
  }
  
  .project-back-description {
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: 16px;
  }
  
  .features-title,
  .tech-list-title {
    font-size: 14px;
    margin-bottom: 10px;
  }
  
  .feature-item {
    font-size: 12px;
  }
  
  .features-grid-2col {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .project-features {
    margin-bottom: 16px;
  }
  
  .project-tech-list {
    margin-bottom: 16px;
  }
  
  .tech-list-badge {
    padding: 4px 10px;
    font-size: 11px;
  }
  
  /* Ensure buttons are always visible at bottom */
  .project-buttons {
    margin-top: 16px;
    gap: 12px;
    flex-shrink: 0;
  }
  
  .btn-code,
  .btn-demo {
    padding: 10px 16px;
    font-size: 13px;
  }
  
  .contact-form {
    padding: 32px 24px;
  }
  
  .tech-stack-3d {
    padding: 60px 20px;
  }
  
  .tech-orbit {
    width: 350px;
    height: 350px;
  }
  
  .tech-icon-orbital {
    width: 60px;
    height: 60px;
    font-size: 20px;
  }
  
  /* Mobile form improvements */
  .form-group textarea {
    font-size: 16px; /* Prevent zoom on iOS */
    padding: 18px 20px;
  }
}

/* ========================================
   iOS & MOBILE OPTIMIZATIONS
   ======================================== */

/* Prevent horizontal scroll on all devices */
html {
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

body {
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Fix iOS input zoom */
@media (max-width: 768px) {
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  textarea,
  select {
    font-size: 16px !important;
  }
}

/* Improve touch targets for mobile */
@media (max-width: 768px) {
  button,
  a,
  .btn-primary,
  .btn-secondary,
  .nav-link,
  .social-icon {
    min-height: 44px;
    min-width: 44px;
  }
}

/* Fix viewport height for iOS Safari */
@supports (-webkit-touch-callout: none) {
  .hero-section {
    min-height: -webkit-fill-available;
  }
  
  /* Fix iOS rendering issues */
  .timeline-item {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
  }
  
  .timeline-content {
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
  }
}

/* Improve scrolling performance */
* {
  -webkit-overflow-scrolling: touch;
}

/* Fix text rendering on mobile */
@media (max-width: 768px) {
  body {
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
  }
}

/* Additional safety for button text */
.btn-primary span,
.btn-secondary span {
  display: inline-block;
  white-space: nowrap;
  overflow: visible;
}

/* Ensure SVG icons don't shrink */
.btn-primary svg,
.btn-secondary svg {
  flex-shrink: 0;
  min-width: 18px;
  min-height: 18px;
}

/* Ensure proper stacking on mobile */
@media (max-width: 768px) {
  .hero-content {
    order: 2;
  }
  
  .cube-wrapper {
    order: 1;
  }
}

/* Fix button SVG sizing on all devices */
.btn-primary svg,
.btn-secondary svg {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  min-width: 18px;
  min-height: 18px;
}

@media (max-width: 360px) {
  .btn-primary svg,
  .btn-secondary svg {
    width: 16px;
    height: 16px;
    min-width: 16px;
    min-height: 16px;
  }
  
  .btn-primary,
  .btn-secondary {
    gap: 6px;
  }
}

/* Improve neon button mobile appearance */
@media (max-width: 480px) {
  .neon-btn {
    padding: 13px 18px;
    font-size: 14px;
  }
  
  .neon-btn::before {
    filter: blur(12px);
  }
  
  /* Ensure timeline is visible */
  .timeline {
    padding: 20px 0;
    overflow: visible;
  }
  
  .timeline-item {
    overflow: visible;
  }
  
  /* Fix contact section spacing */
  .contact-info {
    gap: 16px;
  }
  
  /* Fix section padding */
  section {
    padding: 60px 0;
  }
  
  .experience-section {
    padding: 60px 0;
    overflow: visible;
  }
}

/* Fix container edge spacing on very small screens */
@media (max-width: 360px) {
  .container {
    padding: 0 12px;
  }
  
  .hero-section {
    padding: 85px 0 45px;
  }
}

/* Landscape phone optimization */
@media (max-width: 896px) and (orientation: landscape) {
  .hero-section {
    min-height: auto;
    padding: 80px 0 40px;
  }
  
  .hero-grid {
    gap: 24px;
  }
  
  .cube-wrapper {
    max-width: 200px;
  }
}

/* High DPI screen optimization */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  body {
    -webkit-font-smoothing: subpixel-antialiased;
  }
}
