/* -------------------------------------------------------------------------- */
/* 1. Design System & Variables                                               */
/* -------------------------------------------------------------------------- */
:root {
  --bg-main: #030712;
  --bg-card: rgba(255, 255, 255, 0.03);
  --border-color: rgba(255, 255, 255, 0.08);
  --text-primary: #f9fafb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;

  --color-primary: #3b82f6;
  --color-secondary: #8b5cf6;
  --gradient-text: linear-gradient(135deg, #60a5fa 0%, #a855f7 100%);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* -------------------------------------------------------------------------- */
/* 2. Global Resets & Base Styles                                             */
/* -------------------------------------------------------------------------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  font-family: "Plus Jakarta Sans", sans-serif;
  overflow-x: hidden;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Ambient glow accents */
body::before,
body::after {
  content: "";
  position: fixed;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  filter: blur(160px);
  z-index: -1;
  pointer-events: none;
}
body::before {
  background: rgba(59, 130, 246, 0.12);
  top: -200px;
  right: -100px;
}
body::after {
  background: rgba(139, 92, 246, 0.08);
  bottom: -200px;
  left: -100px;
}

.container {
  width: 90%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
}

/* -------------------------------------------------------------------------- */
/* 3. Navigation Bar & Header Elements                                        */
/* -------------------------------------------------------------------------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background: rgba(3, 7, 18, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 40px;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  text-decoration: none;
  color: var(--text-primary);
  letter-spacing: -0.5px;
}

.logo .dot {
  color: var(--color-primary);
}

.nav-links .nav-item {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  margin-left: 30px;
  transition: var(--transition-smooth);
  display: inline-block;
}

.nav-links .nav-item:hover {
  color: var(--text-primary);
  transform: translateY(-1px);
}

/* -------------------------------------------------------------------------- */
/* 4. Hero Section & Badges                                                   */
/* -------------------------------------------------------------------------- */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Upgraded Live Status Pulse Badge */
.badge-container {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(59, 130, 246, 0.08);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.2);
  padding: 6px 16px;
  border-radius: 30px;
  margin-bottom: 24px;
}

.badge-pulse {
  width: 8px;
  height: 8px;
  background: #3b82f6;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7);
  animation: pulse-glow 2s infinite;
}

.badge-text {
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.5px;
}

@keyframes pulse-glow {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(59, 130, 246, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
  }
}

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

.hero-section h1 .highlight {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  max-width: 680px;
  font-size: 1.25rem;
  color: var(--text-secondary);
  font-weight: 400;
  line-height: 1.7;
  margin-bottom: 35px;
}

/* Button Structural Management */
.buttons-group {
  display: flex;
  gap: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--radius-md);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition-smooth);
  cursor: pointer;
}

.btn-primary {
  background: var(--color-primary);
  color: white;
  box-shadow: 0 4px 20px rgba(59, 130, 246, 0.25);
  border: none;
}

.btn-primary:hover {
  background: #2563eb;
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* -------------------------------------------------------------------------- */
/* 5. Structural App Sections                                                 */
/* -------------------------------------------------------------------------- */
.section {
  padding: 100px 0;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
  margin-bottom: 50px;
  text-align: center;
  letter-spacing: -0.5px;
}

/* -------------------------------------------------------------------------- */
/* 6. Stats & Highlights                                                      */
/* -------------------------------------------------------------------------- */
.highlights-section .stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
}

.stats-grid .stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 30px 20px;
  border-radius: var(--radius-md);
  text-align: center;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.stat-card:hover {
  border-color: rgba(59, 130, 246, 0.3);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-4px);
}

.stat-card .stat-icon {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.stat-card:hover .stat-icon {
  color: var(--color-primary);
}

.stat-card .stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 6px;
}

.stat-card .stat-label {
  color: var(--text-secondary);
  font-size: 0.95rem;
  font-weight: 500;
}

/* -------------------------------------------------------------------------- */
/* 7. Tech Stack Tags                                                         */
/* -------------------------------------------------------------------------- */
.skills-section .skills-flex {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  max-width: 800px;
  margin: 0 auto;
}

.skills-flex .skill-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 100px;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition-smooth);
}

.skills-flex .skill-tag i {
  font-size: 1rem;
}

.skills-flex .skill-tag:hover {
  color: var(--text-primary);
  background: rgba(59, 130, 246, 0.1);
  border-color: var(--color-primary);
  transform: scale(1.05);
}

/* -------------------------------------------------------------------------- */
/* 8. NEW FEATURE: Experience & Education Timeline                            */
/* -------------------------------------------------------------------------- */
.timeline-section .timeline {
  position: relative;
  max-width: 700px;
  margin: 0 auto;
  padding-left: 30px;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 4px;
  width: 2px;
  height: 100%;
  background: var(--border-color);
}

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

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

.timeline-dot {
  position: absolute;
  left: -31px;
  top: 8px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2);
}

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

.timeline-content {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 24px;
  border-radius: var(--radius-md);
  backdrop-filter: blur(8px);
}

.timeline-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.timeline-institution {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 12px;
}

/* -------------------------------------------------------------------------- */
/* 9. Project Grid Card System                                               */
/* -------------------------------------------------------------------------- */
.projects-section .projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.projects-grid .project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 32px;
  border-radius: var(--radius-lg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
}

.project-card:hover {
  transform: translateY(-6px);
  border-color: rgba(139, 92, 246, 0.4);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
  background: rgba(255, 255, 255, 0.05);
}

/* Upgraded Interactive Header Action bar inside card */
.project-card .project-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.project-header .project-icon {
  font-size: 2rem;
  margin-bottom: 0; /* Override old margin */
}

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

.project-links a {
  color: var(--text-muted);
  font-size: 1.2rem;
  transition: var(--transition-smooth);
}

.project-links a:hover {
  color: var(--text-primary);
  transform: scale(1.1);
}

.project-card h3 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.3px;
}

.project-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* -------------------------------------------------------------------------- */
/* 10. Contact Section Card                                                   */
/* -------------------------------------------------------------------------- */
.contact-section .contact-card {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.04) 0%,
    rgba(255, 255, 255, 0.01) 100%
  );
  border: 1px solid var(--border-color);
  padding: 50px 30px;
  border-radius: var(--radius-lg);
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.contact-card .contact-text {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 30px;
}

.contact-card .contact-methods {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
}

.contact-methods .contact-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 1.1rem;
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 1px dashed var(--text-muted);
  transition: var(--transition-smooth);
}

.contact-methods .contact-link i {
  color: var(--color-primary);
}

.contact-methods .contact-link:hover {
  color: var(--color-primary);
  border-bottom-color: var(--color-primary);
  transform: translateY(-1px);
}

/* -------------------------------------------------------------------------- */
/* 11. Footer Setup                                                           */
/* -------------------------------------------------------------------------- */
footer {
  padding: 40px 0;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

footer p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* -------------------------------------------------------------------------- */
/* 12. Responsive Media Rules & Utility Classes                                */
/* -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .nav-container {
    padding: 0 20px;
  }

  .nav-links {
    display: none; /* Can be adapted with JavaScript hamburger layout if needed */
  }

  .hero-section h1 {
    font-size: 2.8rem;
  }

  .hero-section .hero-subtitle {
    font-size: 1.1rem;
  }

  .buttons-group {
    flex-direction: column;
    width: 100%;
    max-width: 280px;
  }

  .buttons-group .btn {
    width: 100%;
  }

  .section {
    padding: 60px 0;
  }
}

.mini-text {
  margin-top: 15px;
  color: #60a5fa;
  font-size: 0.95rem;
  font-weight: 600;
}
