/* ═══════════════════════════════════════════════════════
   INVENIO 2026 – Team Page Stylesheet
   Theme: Dark Futuristic Galaxy / Cosmic
   ═══════════════════════════════════════════════════════ */

/* ─── CSS Variables ─── */
:root {
  /* Core palette – derived from the grainy indigo/purple/black gradient bg */
  --color-bg-deep:       #07060F;
  --color-bg-dark:       #0D0B1A;
  --color-bg-mid:        #160F2E;
  --color-accent-cyan:   #7C6FFF;   /* indigo-violet (replaces cyan) */
  --color-accent-light:  #A89BFF;   /* periwinkle highlight */
  --color-accent-purple: #C084FC;   /* orchid lavender */
  --color-accent-pink:   #E2B4FF;   /* soft pink-lavender */
  --color-text-primary:  #EDE9FF;
  --color-text-muted:    #9490B8;
  --color-white:         #ffffff;

  /* Glass */
  --glass-bg:            rgba(18, 10, 40, 0.55);
  --glass-border:        rgba(124, 111, 255, 0.22);
  --glass-blur:          18px;

  /* Glow */
  --glow-cyan:           0 0 24px rgba(124, 111, 255, 0.40);
  --glow-cyan-strong:    0 0 44px rgba(124, 111, 255, 0.60);
  --glow-purple:         0 0 24px rgba(192, 132, 252, 0.45);

  /* Typography */
  --font-display:  'Orbitron', 'Rajdhani', sans-serif;
  --font-body:     'Inter', sans-serif;

  /* Spacing */
  --container-max: 1280px;
  --section-gap:   5rem;

  /* Transitions */
  --ease-smooth:   cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --transition-fast: 200ms var(--ease-smooth);
  --transition-med:  350ms var(--ease-smooth);

  /* Nav */
  --nav-h: 72px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  /* Grainy indigo/purple/black gradient background image */
  background: url('bg.jpg') center center / cover fixed no-repeat;
  background-color: var(--color-bg-deep); /* fallback */
  color: var(--color-text-primary);
  font-family: var(--font-body);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Subtle dark overlay so text stays readable over bright image areas */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: rgba(5, 4, 14, 0.45);
  z-index: 0;
  pointer-events: none;
}

img { display: block; max-width: 100%; }
a  { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font: inherit; }

/* ═══════════════════════════════════════════════════════
   BLACK HOLE EFFECT — CSS begins here
   Decorative top-left corner element. Adjust glow colors
   by changing the --bh-* variables below.
   ═══════════════════════════════════════════════════════ */

/* ── Black hole CSS variables ── */
:root {
  --bh-size:           300px;   /* overall diameter of the BH widget   */
  --bh-glow-primary:   #7C6FFF; /* indigo-violet — main accretion glow  */
  --bh-glow-secondary: #C084FC; /* orchid lavender — inner ring glow    */
  --bh-glow-hot:       #E2B4FF; /* soft pink-lavender — photon sphere   */
  --bh-glow-periwinkle:#A89BFF; /* mid ring highlight                   */
}

@media (max-width: 900px)  { :root { --bh-size: 220px; } }
@media (max-width: 520px)  { :root { --bh-size: 160px; } }

/* ── Outer container ── */
.blackhole {
  position: fixed;
  top:  0;
  left: 0;
  width:  var(--bh-size);
  height: var(--bh-size);
  /* above star canvas (0) and nebula (1), below page content (2+) */
  z-index: 1;
  pointer-events: none;
  overflow: visible;   /* rings and particles bleed outside the box */
}

/* ── Spiraling particle canvas ── */
.blackhole__canvas {
  position: absolute;
  top:  50%;
  left: 50%;
  /* 2× the widget size so particles can spiral from further out */
  width:  calc(var(--bh-size) * 2);
  height: calc(var(--bh-size) * 2);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

/* ── Gravitational lensing halo ──
   A softly blurred radial gradient that widens the apparent glow
   and hints at light being bent around the black hole. */
.blackhole__lensing {
  position: absolute;
  top:  50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width:  calc(var(--bh-size) * 1.7);
  height: calc(var(--bh-size) * 1.7);
  border-radius: 50%;
  background: radial-gradient(
    circle,
    transparent 28%,
    rgba(124, 111, 255, 0.05) 46%,
    rgba(192, 132, 252, 0.07) 60%,
    rgba(124, 111, 255, 0.03) 72%,
    transparent 85%
  );
  filter: blur(10px);
  animation: bhLensRotate 80s linear infinite;
}

/* ── Accretion disk container ── */
.blackhole__disk {
  position: absolute;
  top:  50%;
  left: 50%;
  width:  100%;
  height: 100%;
}

/* ── Shared ring base style ── */
.blackhole__disk-ring {
  position: absolute;
  top:  50%;
  left: 50%;
  border-radius: 50%;
  border: 2px solid transparent;
}

/* ── Outer disk ring — widest, most diffuse, slowest rotation ── */
.blackhole__disk-ring--outer {
  width:  calc(var(--bh-size) * 0.88);
  height: calc(var(--bh-size) * 0.29);   /* flat oval = viewed-from-above disk */
  border-color: rgba(124, 111, 255, 0.22);
  box-shadow:
    0 0 14px rgba(124, 111, 255, 0.14),
    inset 0 0 8px rgba(124, 111, 255, 0.07);
  filter: blur(2px);
  animation: bhDiskCW 20s linear infinite;
}

/* ── Mid disk ring ── */
.blackhole__disk-ring--mid {
  width:  calc(var(--bh-size) * 0.66);
  height: calc(var(--bh-size) * 0.22);
  border-color: rgba(168, 155, 255, 0.32);
  box-shadow:
    0 0 18px rgba(168, 155, 255, 0.22),
    inset 0 0 10px rgba(168, 155, 255, 0.10);
  filter: blur(1.5px);
  animation: bhDiskCCW 13s linear infinite;
}

/* ── Inner disk ring — hottest, brightest, fastest ── */
.blackhole__disk-ring--inner {
  width:  calc(var(--bh-size) * 0.46);
  height: calc(var(--bh-size) * 0.155);
  border-color: rgba(192, 132, 252, 0.52);
  box-shadow:
    0 0 22px rgba(192, 132, 252, 0.36),
    0 0 46px rgba(124, 111, 255, 0.18),
    inset 0 0 14px rgba(226, 180, 255, 0.16);
  filter: blur(0.8px);
  animation: bhDiskCW 7.5s linear infinite;
}

/* ── Event horizon ── */
.blackhole__horizon {
  position: absolute;
  top:  50%;
  left: 50%;
  /* 0.32 × bhSize diameter = radius is 0.16 × bhSize */
  width:  calc(var(--bh-size) * 0.32);
  height: calc(var(--bh-size) * 0.32);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  /* True black centre fading to near-black at edge */
  background: radial-gradient(
    circle,
    #000000 0%,
    #020108 50%,
    rgba(4, 2, 18, 0.96) 80%,
    transparent 100%
  );
  box-shadow:
    0 0 28px 8px rgba(0, 0, 0, 0.85),   /* kill light behind it */
    0 0  8px 2px rgba(192, 132, 252, 0.08); /* faint purple edge hint */
  z-index: 2; /* sits above the particle canvas within the .blackhole stacking context */
}

/* ── Photon sphere — the luminous razor-thin ring at the horizon boundary ── */
.blackhole__photon-sphere {
  position: absolute;
  top:  50%;
  left: 50%;
  /* Slightly larger than the horizon */
  width:  calc(var(--bh-size) * 0.38);
  height: calc(var(--bh-size) * 0.38);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1px solid rgba(226, 180, 255, 0.30);
  box-shadow:
    0 0 12px 3px rgba(192, 132, 252, 0.25),
    0 0 28px 6px rgba(124, 111, 255, 0.12),
    inset 0 0 6px rgba(226, 180, 255, 0.10);
  animation: bhPhotonPulse 4s ease-in-out infinite alternate;
  z-index: 3;
}

/* ── Disk ring rotation keyframes ── */
@keyframes bhDiskCW {
  from { transform: translate(-50%, -50%) rotate(0deg);   }
  to   { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes bhDiskCCW {
  from { transform: translate(-50%, -50%) rotate(0deg);    }
  to   { transform: translate(-50%, -50%) rotate(-360deg); }
}

/* Lensing halo slow drift */
@keyframes bhLensRotate {
  from { transform: translate(-50%, -50%) rotate(0deg);   }
  to   { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Photon sphere subtle breathe */
@keyframes bhPhotonPulse {
  from { opacity: 0.55; box-shadow: 0 0 10px 2px rgba(192,132,252,0.20), 0 0 24px 5px rgba(124,111,255,0.10); }
  to   { opacity: 0.90; box-shadow: 0 0 18px 5px rgba(192,132,252,0.38), 0 0 40px 9px rgba(124,111,255,0.20); }
}

/* ── Respect reduced-motion preference ── */
@media (prefers-reduced-motion: reduce) {
  .blackhole__disk-ring--outer,
  .blackhole__disk-ring--mid,
  .blackhole__disk-ring--inner,
  .blackhole__lensing,
  .blackhole__photon-sphere {
    animation: none;
  }
}

/* ═══════════════════════════════════════════════════════
   BLACK HOLE EFFECT — CSS ends here
   ═══════════════════════════════════════════════════════ */

/* ─── Star Canvas (background) ─── */
#starCanvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ─── Nebula Gradients ─── */
.nebula {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.nebula__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.22;
  animation: nebulaDrift 18s ease-in-out infinite alternate;
}

.nebula__orb--1 {
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, #C084FC 0%, #160F2E 70%, transparent 100%);
  top: -200px;
  left: -200px;
  animation-duration: 22s;
  opacity: 0.15;
}

.nebula__orb--2 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, #7C6FFF 0%, #160F2E 70%, transparent 100%);
  bottom: 10%;
  right: -100px;
  animation-duration: 28s;
  animation-delay: -8s;
  opacity: 0.14;
}

.nebula__orb--3 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #E2B4FF 0%, #07060F 80%, transparent 100%);
  top: 50%;
  left: 40%;
  animation-duration: 33s;
  animation-delay: -14s;
  opacity: 0.08;
}

@keyframes nebulaDrift {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(40px, 30px) scale(1.08); }
  100% { transform: translate(-30px, 50px) scale(0.95); }
}

/* ─── Container ─── */
.container {
  position: relative;
  z-index: 2;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ═══════════════════════ HEADER / NAV ═══════════════════════ */
/* 1. Global Reset (Top Gap aur Border Remove karne ke liye) */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  margin: 0 !important;
  padding: 0 !important;
  width: 100%;
}

/* 2. Header Base Styling */
.site-header {
  position: fixed;
  top: 0 !important;
  left: 0;
  right: 0;
  margin-top: 0 !important;
  padding-top: 0 !important;
  z-index: 1000;
  height: var(--nav-h, 70px);
  background: rgba(11, 16, 38, 0.75);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: none !important;
  border-bottom: 1px solid rgba(124, 111, 255, 0.12);
  transition: background var(--transition-med, 0.3s ease);
}

/* 3. Navigation Container */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-h, 70px);
  max-width: var(--container-max, 1200px);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* 4. Logo Styling */
.nav__logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display, sans-serif);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--color-text-primary, #ffffff);
  text-decoration: none;
  transition: color var(--transition-fast, 0.2s ease);
}

.nav__logo:hover { 
  color: var(--color-accent-cyan, #00f2fe); 
}

.nav__logo-img {
  height: 45px;
  width: auto;
  object-fit: contain;
  display: block;
}

/* 5. Navigation Links */
.nav__links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

/* Contact is shown as its own pill button (.nav__mail) on desktop,
   so hide the duplicate "Contact" entry from the links list there.
   On mobile the pill is removed, so this becomes the only way to
   reach Contact from the burger menu. */
.nav__links-contact { display: none; }

.nav__links a {
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text-muted, #a0a5b5);
  text-decoration: none;
  transition: color var(--transition-fast, 0.2s ease);
  position: relative;
}

.nav__links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--color-accent-cyan, #00f2fe);
  transition: width var(--transition-med, 0.3s ease);
}

.nav__links a:hover,
.nav__links a.nav__link--active {
  color: var(--color-accent-cyan, #00f2fe);
}

.nav__links a:hover::after,
.nav__links a.nav__link--active::after {
  width: 100%;
}

/* 6. Contact Mail Button */
.nav__mail { 
  display: flex; 
  align-items: center; 
  gap: 0.45rem; 
  padding: 0.5rem 1.1rem; 
  margin-left: 1.5rem; 
  font-size: 0.8rem; 
  font-weight: 600; 
  letter-spacing: 0.04em; 
  text-transform: uppercase; 
  color: #0B1026; 
  background: linear-gradient(135deg, #7C6FFF, #C084FC); 
  border-radius: 999px; 
  box-shadow: 0 0 24px rgba(124, 111, 255, 0.4); 
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease; 
  white-space: nowrap; 
}

.nav__mail:hover { 
  transform: translateY(-2px) scale(1.03); 
  box-shadow: 0 0 44px rgba(124, 111, 255, 0.6); 
}

.nav__mail svg { 
  flex-shrink: 0; 
}

/* 7. Mobile Burger Menu */
.nav__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
  background: transparent;
  border: none;
  cursor: pointer;
}

.nav__burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text-primary, #ffffff);
  border-radius: 2px;
  transition: transform var(--transition-med, 0.3s ease), opacity var(--transition-fast, 0.2s ease);
}

.nav__burger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__burger.active span:nth-child(2) { opacity: 0; }
.nav__burger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
/* ═══════════════════════ HERO ═══════════════════════ */
.hero {
  position: relative;
  z-index: 2;
  min-height: 58vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-h) + 5rem) 1.5rem 4rem;
  overflow: hidden;
}

.hero__content {
  position: relative;
  z-index: 3;
  max-width: 760px;
  animation: heroFadeUp 1s var(--ease-smooth) both;
}

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

.hero__eyebrow {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent-cyan);
  margin-bottom: 1rem;
  opacity: 0.85;
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--color-white);
  margin-bottom: 1.25rem;
  text-shadow: 0 0 60px rgba(124, 111, 255, 0.2);
}

.hero__title--accent {
  background: linear-gradient(135deg, var(--color-accent-cyan) 0%, var(--color-accent-purple) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 0 20px rgba(124, 111, 255, 0.4));
}

.hero__subtitle {
  font-size: 1.2rem;
  color: var(--color-text-muted);
  font-weight: 300;
  letter-spacing: 0.02em;
}

.hero__divider {
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-accent-cyan), transparent);
  margin: 2rem auto 0;
  border-radius: 999px;
  box-shadow: var(--glow-cyan);
}

/* Hero floating particles */
.hero__particles {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.hero-particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--color-accent-cyan);
  border-radius: 50%;
  opacity: 0;
  animation: floatParticle var(--dur, 6s) var(--delay, 0s) ease-in-out infinite;
  filter: blur(1px);
  box-shadow: 0 0 6px var(--color-accent-cyan);
}

@keyframes floatParticle {
  0%   { opacity: 0;    transform: translateY(0)      scale(0.5); }
  20%  { opacity: 0.8;                                             }
  80%  { opacity: 0.4;                                             }
  100% { opacity: 0;    transform: translateY(-120px) scale(1.2); }
}

/* ═══════════════════════ SEARCH ═══════════════════════ */
.search-section {
  position: relative;
  z-index: 2;
  padding: 0 0 2.5rem;
}

.search-box {
  position: relative;
  max-width: 560px;
  margin: 0 auto;
  display: flex;
  align-items: center;
}

.search-box__icon {
  position: absolute;
  left: 1.1rem;
  color: var(--color-accent-cyan);
  pointer-events: none;
  opacity: 0.7;
  flex-shrink: 0;
}

.search-box__input {
  width: 100%;
  padding: 0.9rem 3rem 0.9rem 3.2rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  backdrop-filter: blur(var(--glass-blur));
  color: var(--color-text-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.search-box__input::placeholder {
  color: var(--color-text-muted);
  opacity: 0.6;
}

.search-box__input:focus {
  border-color: var(--color-accent-cyan);
  box-shadow: 0 0 0 3px rgba(124, 111, 255, 0.12), var(--glow-cyan);
}

/* Clear button */
.search-box__clear {
  position: absolute;
  right: 1.1rem;
  color: var(--color-text-muted);
  opacity: 0;
  cursor: pointer;
  font-size: 0.85rem;
  transition: opacity var(--transition-fast), color var(--transition-fast);
  user-select: none;
}

.search-box__clear.visible {
  opacity: 0.6;
}

.search-box__clear:hover { color: var(--color-accent-cyan); opacity: 1; }

.search-results-count {
  text-align: center;
  margin-top: 0.75rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  min-height: 1.2em;
}

/* ═══════════════════════ MAIN ═══════════════════════ */
.main {
  position: relative;
  z-index: 2;
  padding-bottom: var(--section-gap);
}

/* ═══════════════════════ TEAM SECTION ═══════════════════════ */
.team-section {
  margin-bottom: var(--section-gap);
  transition: opacity var(--transition-med);
}

.team-section.hidden {
  display: none;
}

/* Section header */
.team-section__header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  margin-bottom: 2.25rem;
}

.team-section__title {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 700;
  color: var(--color-text-primary);
  letter-spacing: 0.04em;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  white-space: nowrap;
}

.team-section__badge {
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--color-accent-cyan);
  background: rgba(124, 111, 255, 0.1);
  border: 1px solid rgba(124, 111, 255, 0.25);
  border-radius: 50px;
  padding: 0.2em 0.7em;
  letter-spacing: 0.08em;
}

/* Create symmetric lines on both sides */
.team-section__header::before,
.team-section__line {
  content: '';
  flex: 1;
  height: 1px;
}

.team-section__header::before {
  background: linear-gradient(90deg, transparent 0%, rgba(124, 111, 255, 0.3) 100%);
}

.team-section__line {
  background: linear-gradient(90deg, rgba(124, 111, 255, 0.3) 0%, transparent 100%);
}
/* ═══════════════════════ CARDS GRID ═══════════════════════ */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}

/* ═══════════════════════ MEMBER CARD ═══════════════════════ */
.member-card {
  position: relative;
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 3 / 4;        /* portrait photo card */
  background: var(--color-bg-mid);

  /* Scroll reveal – start hidden */
  opacity: 0;
  transform: translateY(30px);

  transition:
    transform var(--transition-med),
    box-shadow var(--transition-med),
    border-color var(--transition-med);
}

.member-card.revealed {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.55s var(--ease-smooth),
    transform 0.55s var(--ease-smooth),
    box-shadow var(--transition-med),
    border-color var(--transition-med);
}

/* Hover lift + glow */
.member-card:hover {
  transform: translateY(-6px) scale(1.02);
  border-color: rgba(124, 111, 255, 0.6);
  box-shadow: var(--glow-cyan-strong), 0 24px 60px rgba(0, 0, 0, 0.6);
}

.member-card--faculty:hover {
  border-color: rgba(167, 139, 250, 0.6);
  box-shadow: var(--glow-purple), 0 24px 60px rgba(0, 0, 0, 0.6);
}

.member-card--tech:hover {
  border-color: rgba(160, 140, 255, 0.6);
  box-shadow: 0 0 40px rgba(160, 140, 255, 0.5), 0 24px 60px rgba(0, 0, 0, 0.6);
}

/* ── Photo fills entire card ── */
.member-card__avatar-wrap {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.member-card__avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  transition: transform 0.55s var(--ease-smooth);
}

.member-card:hover .member-card__avatar {
  transform: scale(1.08);
}

/* Ring is now a subtle top-edge glow on hover */
.member-card__avatar-ring { display: none; }

/* ── Glow overlay (radial, top) ── */
.member-card__glow {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(ellipse at 50% -10%, rgba(124, 111, 255, 0.18) 0%, transparent 60%);
  opacity: 0;
  transition: opacity var(--transition-med);
  pointer-events: none;
  z-index: 2;
}

.member-card:hover .member-card__glow { opacity: 1; }

/* ── Contact overlay (slides up on hover) ── */
.member-card__body {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 3;

  /* Frosted-glass panel */
  background: linear-gradient(
    to top,
    rgba(7, 12, 28, 0.97) 0%,
    rgba(11, 16, 38, 0.92) 55%,
    rgba(11, 16, 38, 0.0) 100%
  );
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);

  padding: 2rem 1.2rem 1.2rem;
  text-align: center;

  /* Hidden below the card, slides up on hover */
  transform: translateY(100%);
  opacity: 0;
  transition:
    transform 0.38s var(--ease-smooth),
    opacity   0.30s var(--ease-smooth);
}

.member-card:hover .member-card__body {
  transform: translateY(0);
  opacity: 1;
}

/* Always show name + role at bottom edge even without hover */
.member-card__name {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0.03em;
  margin-bottom: 0.25rem;
  text-shadow: 0 1px 8px rgba(0,0,0,0.8);
}

.member-card__role {
  font-size: 0.72rem;
  color: var(--color-accent-cyan);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.9rem;
  text-shadow: 0 0 12px rgba(124, 111, 255, 0.5);
}

.member-card--faculty .member-card__role {
  color: var(--color-accent-purple);
  text-shadow: 0 0 12px rgba(167, 139, 250, 0.5);
}

/* Thin divider line above socials */
.member-card__body::before {
  content: '';
  display: block;
  width: 40px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-accent-cyan), transparent);
  margin: 0 auto 0.85rem;
  opacity: 0.7;
}

/* Socials */
.member-card__socials {
  display: flex;
  justify-content: center;
  gap: 0.65rem;
}

.social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--color-text-muted);
  transition:
    color var(--transition-fast),
    background var(--transition-fast),
    border-color var(--transition-fast),
    transform var(--transition-fast);
}

.social-btn:hover {
  transform: scale(1.18) translateY(-2px);
}

.social-btn--email:hover {
  color: var(--color-accent-cyan);
  background: rgba(124, 111, 255, 0.15);
  border-color: rgba(124, 111, 255, 0.45);
}

.social-btn--linkedin:hover {
  color: #5ba4cf;
  background: rgba(91, 164, 207, 0.15);
  border-color: rgba(91, 164, 207, 0.45);
}

.social-btn--instagram:hover {
  color: #c77dff;
  background: rgba(199, 125, 255, 0.12);
  border-color: rgba(199, 125, 255, 0.4);
}

/* ═══════════════════════ NO RESULTS ═══════════════════════ */
.no-results {
  text-align: center;
  padding: 5rem 1rem;
  animation: heroFadeUp 0.4s var(--ease-smooth) both;
}

.no-results__icon { font-size: 3rem; margin-bottom: 1rem; }

.no-results__text {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--color-text-primary);
  margin-bottom: 0.4rem;
}

.no-results__sub {
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

/* Footer & back-to-top styles now live in footer.js (single unified footer component). */

/* ═══════════════════════ RESPONSIVE ═══════════════════════ */
@media (max-width: 1024px) {
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }
}

@media (max-width: 768px) {
  :root {
    --section-gap: 3.5rem;
  }

  /* Nav */
  /* The mail/contact pill was showing as a stray floating box on mobile
     (icon only, since the text was hidden) — remove it completely on
     mobile; Contact is still reachable from the nav links. */
  .nav__mail { display: none; }
  .nav__links-contact { display: block; }
  .nav__links {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: rgba(11, 16, 38, 0.97);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 2rem 1.5rem;
    gap: 1.5rem;
    transform: translateY(-110%);
    transition: transform var(--transition-med);
    border-bottom: 1px solid rgba(124, 111, 255, 0.12);
  }

  .nav__links.open {
    transform: translateY(0);
  }

  .nav__burger {
    display: flex;
  }

  /* Hero */
  .hero__title {
    font-size: clamp(2.2rem, 10vw, 3.5rem);
  }

  /* Cards – smaller grid */
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
  }

  /* Small "tap" hint badge on the photo, only shown on touch screens
     (see .is-touch on <html>, set by team.js) until the card is tapped */
  .is-touch .member-card__tap-hint {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    z-index: 4;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.6rem;
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--color-text-primary);
    background: rgba(11, 16, 38, 0.65);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    backdrop-filter: blur(6px);
    pointer-events: none;
    opacity: 1;
    transition: opacity var(--transition-fast);
  }

  .is-touch .member-card.is-active .member-card__tap-hint {
    opacity: 0;
  }
}

/* Touch devices: no :hover, so tapping the photo toggles the overlay
   (name / role / email) via the .is-active class added in team.js */
.member-card.is-active .member-card__body {
  transform: translateY(0);
  opacity: 1;
}

.member-card.is-active .member-card__glow {
  opacity: 1;
}

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

  .member-card__name {
    font-size: 0.8rem;
  }

  .member-card__role {
    font-size: 0.65rem;
    margin-bottom: 0.6rem;
  }

  .social-btn {
    width: 28px;
    height: 28px;
  }
}

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

/* ═══════════════════════ ACCESSIBILITY ═══════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus visible */
:focus-visible {
  outline: 2px solid var(--color-accent-cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ═══════════════════════ TEAM CAROUSEL (footer.js-style: added via team.js) ═══════════════════════ */
/* Header row above each section: prev/next arrows + progress dots + "View All" toggle */
.team-carousel__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  flex-wrap: wrap;
  margin: -1.1rem 0 1.6rem;
}

.team-carousel__arrow {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border);
  color: var(--color-text-primary);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast), opacity var(--transition-fast);
}

.team-carousel__arrow:hover {
  background: var(--color-accent-cyan);
  border-color: transparent;
  color: #fff;
  transform: scale(1.08);
}

.team-carousel__arrow:active { transform: scale(0.95); }

.team-carousel__dots {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.team-carousel__dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  cursor: pointer;
  transition: background var(--transition-fast), width var(--transition-fast), border-radius var(--transition-fast);
}

.team-carousel__dot:hover { background: rgba(255, 255, 255, 0.45); }

.team-carousel__dot.is-active {
  width: 22px;
  border-radius: 5px;
  background: var(--color-accent-cyan);
}

.team-carousel__viewall {
  margin-left: 0.6rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.55rem 1.1rem;
  border-radius: 50px;
  background: rgba(124, 111, 255, 0.1);
  border: 1px solid rgba(124, 111, 255, 0.3);
  color: var(--color-accent-cyan);
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
  white-space: nowrap;
}

.team-carousel__viewall:hover {
  background: rgba(124, 111, 255, 0.22);
  border-color: rgba(124, 111, 255, 0.55);
}

.team-carousel__viewall[aria-pressed="true"] {
  background: var(--color-accent-cyan);
  color: #08101f;
  border-color: transparent;
}

/* Viewport clips the sliding track; native horizontal scroll = free touch-swipe on phones */
.team-carousel__viewport {
  position: relative;
  outline: none;
}

/* Sliding mode: the .cards-grid itself becomes the track */
.cards-grid.team-carousel__track {
  display: flex;
  overflow-x: auto;
  overflow-y: visible;
  gap: 1.5rem;
  scroll-snap-type: x proximity; /* gentle snap that won't fight the slow auto-drift */
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 0.4rem 0.2rem 1rem;
  margin: -0.4rem -0.2rem -1rem;
}

.cards-grid.team-carousel__track::-webkit-scrollbar { display: none; }

.cards-grid.team-carousel__track > .member-card {
  flex: 0 0 220px;
  scroll-snap-align: start;
}

/* "View All" expanded mode: back to a normal wrapping grid, everyone visible at once */
.team-section.is-expanded .cards-grid.team-carousel__track {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  overflow: visible;
  scroll-snap-type: none;
  padding: 0;
  margin: 0;
}

.team-section.is-expanded .team-carousel__arrow,
.team-section.is-expanded .team-carousel__dots {
  display: none;
}

/* Edge fade hint so people know there's more to swipe/scroll through */
.team-carousel__viewport::before,
.team-carousel__viewport::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 1rem;
  width: 28px;
  pointer-events: none;
  z-index: 4;
  opacity: 1;
  transition: opacity var(--transition-fast);
}
.team-carousel__viewport::before {
  left: 0;
  background: linear-gradient(90deg, var(--color-bg-deep, #05070f) 0%, transparent 100%);
}
.team-carousel__viewport::after {
  right: 0;
  background: linear-gradient(270deg, var(--color-bg-deep, #05070f) 0%, transparent 100%);
}
.team-section.is-expanded .team-carousel__viewport::before,
.team-section.is-expanded .team-carousel__viewport::after {
  display: none;
}

@media (max-width: 768px) {
  .cards-grid.team-carousel__track > .member-card {
    flex: 0 0 68vw;
    max-width: 280px;
  }
  .team-carousel__controls { gap: 0.6rem; margin: -0.6rem 0 1.2rem; }
  .team-carousel__arrow { width: 36px; height: 36px; font-size: 1.15rem; }
  .team-carousel__viewall { margin-left: 0.3rem; padding: 0.5rem 0.9rem; }
}

@media (max-width: 420px) {
  .cards-grid.team-carousel__track > .member-card {
    flex: 0 0 80vw;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cards-grid.team-carousel__track { scroll-behavior: auto; }
}
