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

/* CSS Reset & Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Color Palette - Dark Mode with Vibrant Accents */
  --color-bg-primary: hsl(230, 21%, 11%);
  --color-bg-secondary: hsl(230, 17%, 14%);
  --color-bg-tertiary: hsl(230, 15%, 18%);

  --color-accent-primary: hsl(280, 85%, 65%);
  --color-accent-secondary: hsl(200, 85%, 55%);
  --color-accent-gradient: linear-gradient(135deg, hsl(280, 85%, 65%), hsl(200, 85%, 55%));

  --color-text-primary: hsl(0, 0%, 98%);
  --color-text-secondary: hsl(220, 15%, 70%);
  --color-text-muted: hsl(220, 15%, 55%);

  --color-border: hsla(220, 15%, 35%, 0.3);
  --color-glass-bg: hsla(230, 17%, 14%, 0.7);
  --color-glass-border: hsla(255, 85%, 65%, 0.2);

  /* Typography */
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 2rem;
  --font-size-4xl: 2.5rem;
  --font-size-5xl: 3.5rem;

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 0.75rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --spacing-3xl: 4rem;
  --spacing-4xl: 6rem;

  /* Border Radius */
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.3);
  --shadow-glow: 0 0 40px rgba(160, 80, 255, 0.3);

  /* Transitions */
  --transition-fast: 150ms ease-in-out;
  --transition-base: 250ms ease-in-out;
  --transition-slow: 400ms ease-in-out;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  line-height: 1.7;
  color: var(--color-text-primary);
  background: var(--color-bg-primary);
  overflow-x: hidden;
  position: relative;
}

/* Animated Background */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(circle at 20% 50%, hsla(280, 85%, 65%, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, hsla(200, 85%, 55%, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 40% 90%, hsla(320, 85%, 60%, 0.1) 0%, transparent 50%);
  z-index: -1;
  animation: backgroundShift 20s ease-in-out infinite;
}

@keyframes backgroundShift {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.8;
    transform: scale(1.1);
  }
}

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

h1 {
  font-size: var(--font-size-5xl);
}

h2 {
  font-size: var(--font-size-4xl);
}

h3 {
  font-size: var(--font-size-3xl);
}

h4 {
  font-size: var(--font-size-2xl);
}

h5 {
  font-size: var(--font-size-xl);
}

h6 {
  font-size: var(--font-size-lg);
}

a {
  color: var(--color-accent-secondary);
  text-decoration: none;
  transition: color var(--transition-base);
}

a:hover {
  color: var(--color-accent-primary);
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: var(--spacing-lg) var(--spacing-xl);
  background: var(--color-glass-bg);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-glass-border);
  transition: all var(--transition-base);
}

.navbar.scrolled {
  padding: var(--spacing-md) var(--spacing-xl);
  box-shadow: var(--shadow-lg);
}

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

.nav-logo {
  font-family: var(--font-heading);
  font-size: var(--font-size-xl);
  font-weight: 700;
  background: var(--color-accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-menu {
  display: flex;
  gap: var(--spacing-xl);
  list-style: none;
}

.nav-link {
  color: var(--color-text-secondary);
  font-weight: 500;
  position: relative;
  transition: color var(--transition-base);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-accent-gradient);
  transition: width var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-text-primary);
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--spacing-xs);
}

.nav-toggle span {
  width: 25px;
  height: 2px;
  background: var(--color-text-primary);
  transition: all var(--transition-base);
}

/* Container & Layout */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-xl);
}

section {
  padding: var(--spacing-4xl) 0;
  position: relative;
}

/* Glass Card Component */
.glass-card {
  background: var(--color-glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-glass-border);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-accent-primary), transparent);
  opacity: 0;
  transition: opacity var(--transition-base);
}

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

.glass-card:hover::before {
  opacity: 1;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  padding-top: 80px;
}

.hero-content {
  animation: fadeInUp 1s ease-out;
}

.hero-avatar {
  width: 180px;
  height: 180px;
  border-radius: var(--radius-full);
  margin: 0 auto var(--spacing-xl);
  border: 4px solid var(--color-glass-border);
  box-shadow: var(--shadow-glow);
  animation: float 6s ease-in-out infinite;
  object-fit: cover;
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-20px);
  }
}

.hero-title {
  margin-bottom: var(--spacing-md);
  background: var(--color-accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: var(--font-size-2xl);
  color: var(--color-text-secondary);
  margin-bottom: var(--spacing-lg);
  font-weight: 400;
}

.hero-description {
  max-width: 700px;
  margin: 0 auto var(--spacing-2xl);
  color: var(--color-text-muted);
  font-size: var(--font-size-lg);
}

.hero-cta {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
  flex-wrap: wrap;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md) var(--spacing-xl);
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: var(--font-size-base);
  cursor: pointer;
  transition: all var(--transition-base);
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: var(--color-accent-gradient);
  color: white;
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
  color: white;
}

.btn-secondary {
  background: transparent;
  color: var(--color-text-primary);
  border: 2px solid var(--color-glass-border);
}

.btn-secondary:hover {
  border-color: var(--color-accent-primary);
  background: var(--color-glass-bg);
  color: var(--color-text-primary);
}

/* Section Headers */
.section-header {
  text-align: center;
  margin-bottom: var(--spacing-3xl);
  animation: fadeInUp 0.8s ease-out;
}

.section-title {
  margin-bottom: var(--spacing-md);
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--color-accent-gradient);
  border-radius: var(--radius-full);
}

.section-subtitle {
  color: var(--color-text-muted);
  font-size: var(--font-size-lg);
  max-width: 600px;
  margin: var(--spacing-xl) auto 0;
}

/* Timeline */
.timeline {
  position: relative;
  padding: var(--spacing-xl) 0;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--color-border);
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  margin-bottom: var(--spacing-3xl);
  position: relative;
  opacity: 0;
  transform: translateY(30px);
  transition: all var(--transition-slow);
}

.timeline-item.visible {
  opacity: 1;
  transform: translateY(0);
}

.timeline-item:nth-child(odd) {
  flex-direction: row-reverse;
}

.timeline-item:nth-child(odd) .timeline-content {
  padding-left: var(--spacing-2xl);
}

.timeline-item:nth-child(even) .timeline-content {
  padding-right: var(--spacing-2xl);
}

.timeline-content {
  width: calc(50% - var(--spacing-xl));
  position: relative;
}

.timeline-marker {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  background: var(--color-accent-gradient);
  border-radius: var(--radius-full);
  border: 4px solid var(--color-bg-primary);
  box-shadow: var(--shadow-glow);
  z-index: 10;
}

.timeline-date {
  font-size: var(--font-size-sm);
  color: var(--color-accent-secondary);
  font-weight: 600;
  margin-bottom: var(--spacing-sm);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.timeline-title {
  font-size: var(--font-size-xl);
  margin-bottom: var(--spacing-xs);
}

.timeline-company {
  color: var(--color-accent-primary);
  font-weight: 600;
  margin-bottom: var(--spacing-sm);
}

.timeline-location {
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
  margin-bottom: var(--spacing-md);
}

.timeline-description {
  color: var(--color-text-secondary);
  line-height: 1.8;
}

.timeline-description ul {
  list-style: none;
  margin-top: var(--spacing-md);
}

.timeline-description li {
  position: relative;
  padding-left: var(--spacing-lg);
  margin-bottom: var(--spacing-sm);
}

.timeline-description li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--color-accent-primary);
  font-weight: bold;
  font-size: 1.2em;
  line-height: 1.5;
}

/* Grid Layouts */
.grid {
  display: grid;
  gap: var(--spacing-xl);
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

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

/* Education & Certification Cards */
.education-card,
.cert-card,
.project-card {
  opacity: 0;
  transform: translateY(30px);
  transition: all var(--transition-slow);
}

.education-card.visible,
.cert-card.visible,
.project-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.card-header {
  margin-bottom: var(--spacing-md);
}

.card-title {
  font-size: var(--font-size-xl);
  margin-bottom: var(--spacing-xs);
}

.card-subtitle {
  color: var(--color-accent-secondary);
  font-weight: 600;
  margin-bottom: var(--spacing-xs);
}

.card-meta {
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
}

.card-content {
  color: var(--color-text-secondary);
  line-height: 1.8;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-xs);
  margin-top: var(--spacing-md);
  color: var(--color-accent-secondary);
  font-weight: 500;
  font-size: var(--font-size-sm);
}

.card-link:hover {
  gap: var(--spacing-sm);
}

/* Contact Section */
.contact {
  text-align: center;
}

.contact-info {
  display: flex;
  justify-content: center;
  gap: var(--spacing-md);
  justify-content: center;
  margin-top: var(--spacing-xl);
}

.social-link {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: var(--color-glass-bg);
  border: 1px solid var(--color-glass-border);
  box-shadow: var(--shadow-glow);
  color: white;
}

.social-link div {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Footer */
.footer {
  padding: var(--spacing-2xl) 0;
  text-align: center;
  border-top: 1px solid var(--color-border);
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

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

/* Responsive Design */
@media (max-width: 768px) {
  :root {
    --font-size-5xl: 2.5rem;
    --font-size-4xl: 2rem;
    --font-size-3xl: 1.75rem;
  }

  .nav-menu {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--color-glass-bg);
    backdrop-filter: blur(20px);
    padding: var(--spacing-xl);
    gap: var(--spacing-md);
    transform: translateY(-100%);
    opacity: 0;
    transition: all var(--transition-base);
    border-bottom: 1px solid var(--color-glass-border);
  }

  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
  }

  .nav-toggle {
    display: flex;
  }

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

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

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

  .timeline::before {
    left: 0;
  }

  .timeline-item {
    flex-direction: column !important;
  }

  .timeline-content {
    width: 100%;
    padding-left: var(--spacing-2xl);
    text-align: left !important;
  }

  .timeline-marker {
    left: 0;
    transform: translateX(-50%);
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
  }

  .btn {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }

  .contact-info {
    flex-direction: column;
    gap: var(--spacing-md);
  }
}

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

  section {
    padding: var(--spacing-3xl) 0;
  }

  .glass-card {
    padding: var(--spacing-lg);
  }

  .hero-avatar {
    width: 140px;
    height: 140px;
  }
}

/* Utility Classes */
.text-gradient {
  background: var(--color-accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.mt-1 {
  margin-top: var(--spacing-xs);
}

.mt-2 {
  margin-top: var(--spacing-sm);
}

.mt-3 {
  margin-top: var(--spacing-md);
}

.mt-4 {
  margin-top: var(--spacing-lg);
}

.mt-5 {
  margin-top: var(--spacing-xl);
}

.mb-1 {
  margin-bottom: var(--spacing-xs);
}

.mb-2 {
  margin-bottom: var(--spacing-sm);
}

.mb-3 {
  margin-bottom: var(--spacing-md);
}

.mb-4 {
  margin-bottom: var(--spacing-lg);
}

.mb-5 {
  margin-bottom: var(--spacing-xl);
}

.social-link svg {
  fill: white !important;
  width: 24px;
  height: 24px;
}

.social-link:hover {
  background: var(--color-accent-gradient);
  border-color: transparent;
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

.social-links {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
  margin-top: var(--spacing-xl);
}

.contact-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-lg);
  min-width: 200px;
}

.contact-icon {
  margin-bottom: var(--spacing-sm);
}

.contact-icon svg {
  stroke: var(--color-accent-primary);
  filter: drop-shadow(0 0 8px rgba(160, 80, 255, 0.3));
  transition: all var(--transition-base);
}

.contact-item:hover .contact-icon svg {
  stroke: var(--color-accent-secondary);
  filter: drop-shadow(0 0 12px rgba(80, 181, 255, 0.5));
}

.contact-label {
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.contact-value {
  color: var(--color-text-primary);
  font-weight: 500;
}
/* Mobile Menu Fix - Added to fix hamburger menu */
@media (max-width: 768px) {
  .nav-menu {
    position: fixed !important;
    top: 70px !important;
    left: 0 !important;
    right: 0 !important;
    flex-direction: column !important;
    background: var(--color-glass-bg) !important;
    backdrop-filter: blur(20px) !important;
    padding: var(--spacing-xl) !important;
    gap: var(--spacing-md) !important;
    transform: translateY(-100%) !important;
    opacity: 0 !important;
    transition: all var(--transition-base) !important;
    border-bottom: 1px solid var(--color-glass-border) !important;
    z-index: 999 !important;
  }
  
  .nav-menu.active {
    transform: translateY(0) !important;
    opacity: 1 !important;
  }
}

/* Navbar z-index fix - ensure it's above all content */
.navbar {
  z-index: 1000 !important;
}

.nav-toggle {
  z-index: 1001 !important;
  position: relative !important;
}

/* Fix hamburger X animation alignment */
.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px) !important;
}

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

/* Better hamburger X animation - perfect alignment */
.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px) !important;
}

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

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px) !important;
}

/* Fine-tuned hamburger X animation */
.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5.5px, 5.5px) !important;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5.5px, -5.5px) !important;
}
