/* NEEDLE - Scientific ML Project Stylesheet */

/* ============================================
   CSS VARIABLES & THEMING
   ============================================ */

:root {
  /* Light Theme Colors */
  --bg-primary: #ffffff;
  --bg-secondary: #f8f9fa;
  --bg-accent: #e8edf2;
  --text-primary: #1a1a1a;
  --text-secondary: #4a4a4a;
  --text-muted: #6a6a6a;
  --accent-primary: #0066cc;
  --accent-secondary: #0052a3;
  --accent-glow: rgba(0, 102, 204, 0.2);
  --border-color: #d0d7de;
  --shadow-color: rgba(0, 0, 0, 0.1);
  
  /* Particle collision colors */
  --particle-blue: #00d4ff;
  --particle-orange: #ff6b35;
  --particle-purple: #a855f7;
  
  /* Typography */
  /*--font-display: 'Space Mono', 'Courier New', monospace;
  --font-body: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-accent: 'JetBrains Mono', monospace;*/


  /* Classic Academic Typography */
  --font-display: 'Merriweather', Georgia, serif;
  --font-body: 'Source Serif Pro', Georgia, serif;
  --font-accent: 'Crimson Text', 'Times New Roman', serif;
}

[data-theme="dark"] {
  --bg-primary: #0d1117;
  --bg-secondary: #161b22;
  --bg-accent: #1c2128;
  --text-primary: #e6edf3;
  --text-secondary: #c9d1d9;
  --text-muted: #8b949e;
  --accent-primary: #58a6ff;
  --accent-secondary: #1f6feb;
  --accent-glow: rgba(88, 166, 255, 0.3);
  --border-color: #30363d;
  --shadow-color: rgba(0, 0, 0, 0.4);
}

/* ============================================
   GLOBAL RESET & BASE STYLES
   ============================================ */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 16px;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  background: linear-gradient(135deg, var(--accent-primary), var(--particle-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--text-primary);
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--text-secondary);
}

p {
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
}

a {
  color: var(--accent-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--accent-secondary);
  text-decoration: underline;
}

/* ============================================
   NAVIGATION
   ============================================ */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--bg-primary);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.nav-logo-image {
  height: 36px;
  width: auto;
  transition: transform 0.3s ease;
}

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

.nav-logo-text {
  background: linear-gradient(135deg, var(--accent-primary), var(--particle-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-logo span {
  background: linear-gradient(135deg, var(--accent-primary), var(--particle-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: all 0.2s ease;
  position: relative;
}

.nav-link:hover {
  color: var(--accent-primary);
  text-decoration: none;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-primary);
  transition: width 0.3s ease;
}

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

.theme-toggle {
  background: var(--bg-accent);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.theme-toggle:hover {
  background: var(--accent-primary);
  transform: rotate(180deg);
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 6rem 2rem 2rem;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(ellipse at center, var(--bg-secondary) 0%, var(--bg-primary) 100%);
  z-index: 0;
}

.hero-background::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    radial-gradient(circle at 20% 30%, var(--particle-blue) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, var(--particle-orange) 0%, transparent 50%),
    radial-gradient(circle at 50% 50%, var(--particle-purple) 0%, transparent 60%);
  opacity: 0.03;
  animation: particleFloat 20s ease-in-out infinite;
}

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

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 900px;
}

.hero-logo {
  width: 150px;
  height: 150px;
  margin: 0 auto 2rem;
  /*  background: linear-gradient(135deg, var(--accent-primary), var(--particle-purple));*/
  background: transparent;  /* Remove gradient background */
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 3rem;
  color: white;
  box-shadow: 0 20px 60px var(--accent-glow);
  animation: logoFloat 3s ease-in-out infinite;
}

.hero-logo-image {
  width: 80%;
  height: 80%;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

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

.hero-title {
  margin-bottom: 1.5rem;
  animation: fadeInUp 0.8s ease-out;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-weight: 400;
  animation: fadeInUp 0.8s ease-out 0.2s backwards;
}

.hero-cta {
  display: inline-flex;
  gap: 1rem;
  animation: fadeInUp 0.8s ease-out 0.4s backwards;
}

.btn {
  padding: 1rem 2rem;
  border-radius: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-primary), var(--particle-purple));
  color: white;
  box-shadow: 0 4px 15px var(--accent-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px var(--accent-glow);
}

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

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

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

/* ============================================
   SECTIONS
   ============================================ */

section {
  padding: 5rem 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-title {
  position: relative;
  display: inline-block;
  padding-bottom: 1rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-primary), var(--particle-purple));
  border-radius: 2px;
}

/* ============================================
   TEAM SECTION
   ============================================ */

.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.team-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.team-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-primary), var(--particle-purple));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.team-card:hover::before {
  transform: scaleX(1);
}

.team-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px var(--shadow-color);
  border-color: var(--accent-primary);
}

.team-image {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 1.5rem;
  display: block;
  border: 3px solid var(--accent-primary);
  box-shadow: 0 4px 15px var(--accent-glow);
}

.team-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
  text-align: center;
}

.team-title {
  font-family: var(--font-accent);
  font-size: 0.9rem;
  color: var(--accent-primary);
  text-align: center;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.team-role {
  font-size: 0.95rem;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 1rem;
  font-style: italic;
}

.team-description {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.team-affiliation {
  font-size: 0.85rem;
  color: var(--text-muted);
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

/* ============================================
   PROJECT SECTION
   ============================================ */

.project-content {
  max-width: 900px;
  margin: 0 auto;
}

.project-intro {
  font-size: 1.2rem;
  line-height: 1.8;
  margin-bottom: 3rem;
  padding: 2rem;
  background: var(--bg-secondary);
  border-left: 4px solid var(--accent-primary);
  border-radius: 8px;
}

.status-grid {
  display: grid;
  gap: 2rem;
  margin-top: 3rem;
}

.status-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2rem;
  transition: all 0.3s ease;
}

.status-card:hover {
  border-color: var(--accent-primary);
  box-shadow: 0 4px 15px var(--shadow-color);
}

.status-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.status-icon {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--accent-primary), var(--particle-purple));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.status-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--text-primary);
}

.status-body {
  color: var(--text-secondary);
  line-height: 1.7;
}

.status-body ul {
  margin: 1rem 0;
  padding-left: 1.5rem;
}

.status-body li {
  margin-bottom: 0.5rem;
}

/* ============================================
   FOOTER
   ============================================ */

.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 3rem 2rem 2rem;
  text-align: center;
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
}

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

.footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-top: 1rem;
  list-style: none;
}

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

@media (max-width: 768px) {
  .nav-menu {
    gap: 1rem;
  }
  
  .nav-link {
    font-size: 0.85rem;
  }
  
  .hero {
    padding: 5rem 1rem 2rem;
  }
  
  .hero-cta {
    flex-direction: column;
  }
  
  .team-grid {
    grid-template-columns: 1fr;
  }
  
  section {
    padding: 3rem 1rem;
  }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

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

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }

.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }

/* ============================================
   PARTICLE CHAMBER EFFECT
   ============================================ */

#particle-chamber-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none; /* Allow clicking through canvas */
  z-index: 1; /* Below header but above background */
  opacity: 0.8; /* Subtle effect */
}

/* Ensure header is above particle effect */
.navbar {
  position: fixed;
  z-index: 1000; /* Higher than canvas */
}

/* Ensure content is above particle effect */
main {
  position: relative;
  z-index: 10;
}

/* ============================================
   DROPDOWN NAVIGATION
   ============================================ */

.nav-dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  box-shadow: 0 8px 24px var(--shadow-color);
  list-style: none;
  padding: 0.5rem 0;
  margin-top: 0.5rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 1001;
}

.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-link {
  display: block;
  padding: 0.75rem 1.5rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s ease;
  text-transform: none;
  letter-spacing: 0.02em;
}

.dropdown-link:hover {
  background: var(--bg-accent);
  color: var(--accent-primary);
  text-decoration: none;
  padding-left: 1.75rem;
}

/* Dropdown arrow indicator */
.nav-dropdown > .nav-link::after {
  content: ' ▾';
  font-size: 0.8em;
  margin-left: 0.25rem;
  opacity: 0.7;
}
