/* ═══════════════════════════════════════════
   STEM NEXUS AFRICA — team.css
   Team + Contact · Brutalist Block Edition
═══════════════════════════════════════════ */

/* ─── TEAM SECTION ───────────────────────── */
.team-section {
  background: #222233;
  position: relative;
  overflow: hidden;
}

/* Subtle grid texture behind the cards */
.team-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,153,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,153,255,0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

/* ─── SECTION HEADER (dark) ──────────────── */
.team-section .section-header { margin-bottom: 64px; position: relative; }
.team-section .section-tag { color: #0099FF; }
.team-section .section-headline { color: var(--white); }

/* ─── TEAM GRID ──────────────────────────── */
.team-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3px;
  background: #0099FF;
  position: relative;
}

/* ─── TEAM CARD ──────────────────────────── */
.team-card {
  position: relative;
  overflow: hidden;
  background: #2a2a3a;
  cursor: pointer;
  height: 580px;
}

/* ── Photo layer ── */
.team-card__photo {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  transition: transform 0.55s cubic-bezier(.4,0,.2,1), filter 0.55s cubic-bezier(.4,0,.2,1);
  filter: grayscale(20%) brightness(0.88);
}
.team-card:hover .team-card__photo {
  transform: scale(1.06);
  filter: grayscale(0%) brightness(0.55);
}

/* Individual photos */
.team-card--hilary .team-card__photo  { background-image: url('../assets/hillaystem.jpeg'); }
.team-card--collins .team-card__photo { background-image: url('../assets/collins.jpeg'); }

/* ── Permanent bottom gradient ── */
.team-card__gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(34,34,51,0.96) 0%,
    rgba(34,34,51,0.60) 35%,
    rgba(34,34,51,0.0) 65%
  );
  transition: opacity 0.4s ease;
}
.team-card:hover .team-card__gradient {
  background: linear-gradient(
    to top,
    rgba(34,34,51,0.98) 0%,
    rgba(34,34,51,0.82) 50%,
    rgba(34,34,51,0.35) 100%
  );
}

/* ── Blue accent bar — left edge ── */
.team-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: #0099FF;
  z-index: 4;
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.4s cubic-bezier(.4,0,.2,1);
}
.team-card:hover::before { transform: scaleY(1); }

/* ── Card number badge (top-right) ── */
.team-card__number {
  position: absolute;
  top: 24px; right: 24px;
  font-family: var(--font-head);
  font-size: 4rem;
  font-weight: 900;
  line-height: 1;
  color: rgba(255,255,255,0.06);
  letter-spacing: -0.04em;
  z-index: 3;
  transition: color 0.4s ease;
  pointer-events: none;
}
.team-card:hover .team-card__number { color: rgba(0,153,255,0.18); }

/* ── Role badge (top-left) ── */
.team-card__role-badge {
  position: absolute;
  top: 24px; left: 24px;
  background: #0099FF;
  color: #fff;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 6px 14px;
  z-index: 5;
}

/* ── Bottom info block ── */
.team-card__body {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 32px 32px 36px;
  z-index: 5;
}

/* Name */
.team-card__body h3 {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.95;
  color: var(--white);
  margin-bottom: 0;
  padding-bottom: 12px;
  border-bottom: 2px solid #0099FF;
  margin-bottom: 16px;
}

/* Bio — hidden by default, slides up on hover */
.team-card__bio {
  color: rgba(255,255,255,0.72);
  font-size: 0.88rem;
  line-height: 1.65;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(10px);
  transition:
    max-height 0.45s cubic-bezier(.4,0,.2,1),
    opacity 0.35s ease 0.05s,
    transform 0.35s ease 0.05s;
  margin-bottom: 0;
}
.team-card:hover .team-card__bio {
  max-height: 120px;
  opacity: 1;
  transform: translateY(0);
  margin-bottom: 20px;
}

/* Tags */
.team-card__dept {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition:
    max-height 0.45s cubic-bezier(.4,0,.2,1) 0.08s,
    opacity 0.35s ease 0.12s;
}
.team-card:hover .team-card__dept {
  max-height: 80px;
  opacity: 1;
  margin-bottom: 20px;
}
.team-card__dept span {
  font-family: var(--font-head);
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: rgba(0,153,255,0.15);
  border: 1px solid rgba(0,153,255,0.4);
  color: #6ec6ff;
  padding: 4px 10px;
}

/* Social links */
.team-card__social {
  display: flex;
  gap: 8px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition:
    max-height 0.4s cubic-bezier(.4,0,.2,1) 0.14s,
    opacity 0.3s ease 0.18s;
}
.team-card:hover .team-card__social {
  max-height: 56px;
  opacity: 1;
}
.team-card__social a {
  width: 36px; height: 36px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  display: flex; align-items: center; justify-content: center;
  color: var(--white);
  text-decoration: none;
  font-size: 0.9rem;
  transition: background var(--transition), border-color var(--transition), color var(--transition);
}
.team-card__social a:hover {
  background: #0099FF;
  border-color: #0099FF;
  color: #fff;
}

/* ─── CONTACT SECTION ────────────────────── */
.contact-section { background: #2a2a3a; }
.contact-section .section-tag { color: #0099FF; }
.contact-section .section-headline { color: var(--white); }

.contact-info-col { padding-right: 0; }
.contact-info-block {
  background: #323244;
  border: 1px solid var(--grey-2);
  border-right: none;
  padding: 48px 40px;
  height: 100%;
}
.contact-info-item {
  display: flex; gap: 16px; align-items: flex-start;
  margin-bottom: 32px;
}
.ci-icon {
  width: 44px; height: 44px; background: #0099FF;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; flex-shrink: 0; color: #fff;
}
.contact-info-item h5 {
  font-family: var(--font-head); font-weight: 700; font-size: 0.85rem;
  letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 4px; color: var(--white);
}
.contact-info-item p { color: var(--grey); font-size: 0.88rem; margin: 0; }
.contact-social { display: flex; gap: 10px; margin-top: 8px; }
.contact-social a {
  width: 40px; height: 40px;
  background: #2a2a3a;
  border: 1px solid var(--grey-2);
  display: flex; align-items: center; justify-content: center;
  color: var(--grey); text-decoration: none; font-size: 1rem;
  transition: all var(--transition);
}
.contact-social a:hover { background: #0099FF; border-color: #0099FF; color: #fff; }

.contact-form-col { padding-left: 0; }
.contact-form-block {
  background: #323244;
  border: 1px solid var(--grey-2);
  padding: 48px 40px;
  height: 100%;
}
.form-group-sna label {
  font-family: var(--font-head); font-weight: 700; font-size: 0.78rem;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--grey); display: block; margin-bottom: 8px;
}
.sna-input {
  width: 100%;
  background: #2a2a3a;
  border: 1px solid var(--grey-2);
  color: var(--white);
  padding: 12px 16px;
  font-family: var(--font-body); font-size: 0.92rem;
  outline: none;
  transition: border-color var(--transition);
  display: block; margin-bottom: 0;
  -webkit-appearance: none;
}
.sna-input:focus { border-color: #0099FF; }
.sna-input::placeholder { color: rgba(160,160,176,0.45); }
.sna-select { cursor: pointer; }
.sna-select option { background: #2a2a3a; color: var(--white); }
.sna-textarea { resize: vertical; min-height: 120px; }
.submit-btn {
  background: #0099FF; color: #fff; border: none;
  font-family: var(--font-head); font-weight: 700;
  font-size: 1rem; letter-spacing: 0.1em; text-transform: uppercase;
  padding: 16px; width: 100%; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: background var(--transition);
}
.submit-btn:hover { background: #007acc; }

/* ─── RESPONSIVE ─────────────────────────── */
@media (max-width: 991px) {
  .team-grid {
    grid-template-columns: 1fr;
    gap: 3px;
  }
  .team-card { height: 520px; }

  .contact-info-block { height: auto; border-right: 1px solid var(--grey-2); border-bottom: none; }
  .contact-form-block { border-top: none; height: auto; }
}

@media (max-width: 575px) {
  .team-card { height: 460px; }
  .team-card__body { padding: 24px 20px 28px; }
  .team-card__body h3 { font-size: 1.9rem; }
  .contact-info-block, .contact-form-block { padding: 28px 20px; }
  .contact-info-block { border-right: 1px solid var(--grey-2); }
}