/* ===== Adaptive Holographic Systems Lab — Stylesheet ===== */

/* ---------- Reset & Base ---------- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-primary:    #050508;
  --bg-secondary:  #0c0c14;
  --bg-card:       #10101c;
  --bg-card-hover: #161628;
  --border:        #1a1a30;
  --text:          #e0e0e8;
  --text-muted:    #8888a0;
  --text-heading:  #ffffff;
  --accent:        #00b4d8;
  --accent-dim:    #007a94;
  --accent-glow:   rgba(0, 180, 216, 0.12);
  --font-sans:     'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-mono:     'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  --max-width:     1140px;
  --nav-height:    72px;
}

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

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--accent); color: #000; }

img { max-width: 100%; display: block; }

a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: #33cfef; }

/* ---------- Typography ---------- */
h1, h2, h3, h4 { color: var(--text-heading); font-weight: 600; line-height: 1.25; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); letter-spacing: -0.01em; }
h3 { font-size: 1.15rem; }

.section-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

/* ---------- Layout ---------- */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 2rem; }

section {
  padding: 6rem 0;
  position: relative;
}

section + section { border-top: 1px solid var(--border); }

/* ---------- Navigation ---------- */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  background: rgba(5, 5, 8, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  z-index: 1000;
  transition: background .3s;
}

nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-heading);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.nav-brand img {
  height: 38px;
  width: auto;
}

.nav-links { display: flex; gap: 2rem; list-style: none; }

.nav-links a {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition: color .2s;
  position: relative;
}

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

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 1px;
  background: var(--accent);
  transition: width .3s;
}

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

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: transform .3s, opacity .3s;
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: var(--nav-height);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -40%; left: 50%;
  transform: translateX(-50%);
  width: 800px; height: 800px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
}

.hero-logo {
  width: min(840px, 80vw);
  margin: 0 auto 2.5rem;
  filter: drop-shadow(0 0 60px rgba(0, 180, 216, 0.08));
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--text-muted);
  max-width: 640px;
  margin: 1.5rem auto 0;
  line-height: 1.8;
}

.hero-tagline {
  display: inline-block;
  margin-top: 2.5rem;
  padding: 0.6rem 1.8rem;
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-glow);
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.about-text p { margin-bottom: 1.25rem; }

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2.5rem;
}

.stat {
  text-align: center;
  padding: 1.5rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  display: block;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.25rem;
}

/* ---------- Research ---------- */
.research-intro {
  max-width: 720px;
  margin-bottom: 3rem;
}

.research-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem;
  transition: border-color .3s, transform .3s, box-shadow .3s;
}

.card:hover {
  border-color: var(--accent-dim);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0, 180, 216, 0.06);
}

.card-icon {
  width: 48px; height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--accent-glow);
  color: var(--accent);
  font-size: 1.3rem;
  margin-bottom: 1.25rem;
}

.card h3 { margin-bottom: 0.75rem; }

.card p { font-size: 0.92rem; color: var(--text-muted); }

/* ---------- Equations ---------- */
.equations-section {
  background: var(--bg-secondary);
}

.eq-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 2.5rem;
}

.eq-block {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem;
}

.eq-block h3 {
  font-size: 0.95rem;
  margin-bottom: 1rem;
  color: var(--accent);
}

.eq-formula {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  color: var(--text-heading);
  background: rgba(0, 180, 216, 0.04);
  border: 1px solid rgba(0, 180, 216, 0.1);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin-bottom: 1rem;
  overflow-x: auto;
  text-align: center;
  letter-spacing: 0.02em;
}

.eq-block p { font-size: 0.85rem; color: var(--text-muted); line-height: 1.7; }

/* ---------- Publications ---------- */
.pub-list { list-style: none; }

.pub-item {
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--border);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1.5rem;
  align-items: start;
}

.pub-year {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  padding-top: 0.15rem;
  min-width: 3.5rem;
}

.pub-title {
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.3rem;
}

.pub-authors {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.pub-venue {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-style: italic;
  margin-top: 0.2rem;
}

.pub-tag {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.3rem 0.75rem;
  border-radius: 100px;
  border: 1px solid var(--border);
  color: var(--text-muted);
  white-space: nowrap;
  align-self: center;
}

/* ---------- Team ---------- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.team-member {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem;
  text-align: center;
  transition: border-color .3s;
}

.team-member:hover { border-color: var(--accent-dim); }

.team-avatar {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-dim), var(--accent));
  margin: 0 auto 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  font-weight: 700;
  color: #fff;
}

.team-name {
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.25rem;
}

.team-role {
  font-size: 0.8rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.5rem;
}

.team-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---------- Contact / Footer ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
}

.contact-info p {
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.contact-info strong {
  color: var(--text-heading);
}

footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-muted);
}

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

/* ---------- Utility ---------- */
.accent { color: var(--accent); }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mt-2 { margin-top: 1rem; }
.mt-4 { margin-top: 2rem; }

/* ---------- Scroll-triggered animation ---------- */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .about-grid,
  .eq-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .stat-row {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }

  section { padding: 4rem 0; }
}

@media (max-width: 700px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: var(--nav-height);
    left: 0; right: 0;
    background: rgba(5, 5, 8, 0.96);
    backdrop-filter: blur(16px);
    padding: 2rem;
    gap: 1.5rem;
    border-bottom: 1px solid var(--border);
  }

  .nav-toggle { display: flex; }

  .research-cards {
    grid-template-columns: 1fr;
  }

  .pub-item {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .pub-tag { justify-self: start; }

  .stat-row {
    grid-template-columns: 1fr;
  }

  .hero-logo { width: min(600px, 85vw); }
}
