/* ==========================================================================
   05 · Leadership
   Tabs (Board of Directors / Management Team) with a sliding pill and two
   tab panels of member cards. Behaviour: assets/js/sections/leadership.js
   ========================================================================== */
.leadership {
  padding: 80px 0 96px;
  background: var(--white);
}
@media (min-width: 768px) {
  .leadership {
    padding: 100px 0 150px;
  }
}

/* ---- Heading row ---- */
.leadership__head {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
@media (min-width: 1024px) {
  .leadership__head {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}
.leadership__title {
  margin-top: 28px;
  font-weight: var(--fw-regular);
  font-size: 40px;
  line-height: 1.15;
  letter-spacing: -0.04em;
  color: var(--navy);
}
.leadership__br {
  display: none;
}
@media (min-width: 768px) {
  .leadership__title {
    font-size: 64px;
    line-height: 76px;
  }
  .leadership__br {
    display: block;
  }
}
.leadership__text {
  max-width: 460px;
  font-weight: var(--fw-news);
  font-size: 16px;
  line-height: 20px;
  color: #797c80;
}

/* ---- Tabs ---- */
.leadership__tabs {
  margin-top: 28px;
}
.leadership__tablist {
  position: relative;
  display: inline-flex;
  max-width: 100%;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
}
/* Navy pill; leadership.js sets --pill-x / --pill-w from the selected tab. */
.leadership__pill {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 0;
  width: var(--pill-w, 0);
  border-radius: 999px;
  background: var(--navy);
  translate: var(--pill-x, 0) 0;
  transition:
    translate 0.45s var(--ease-out-expo),
    width 0.45s var(--ease-out-expo);
}
.leadership__pill.is-instant {
  transition: none;
}
.leadership__tab {
  position: relative;
  padding: 12px 22px;
  border-radius: 999px;
  font-size: 16px;
  line-height: 20px;
  white-space: nowrap;
  color: var(--navy);
  transition: color 0.3s;
}
.leadership__tab:hover {
  color: var(--royal);
}
.leadership__tab[aria-selected="true"] {
  color: var(--white);
}
.leadership__tab-label {
  position: relative;
}
@media (max-width: 639.98px) {
  .leadership__tab {
    padding-inline: 16px;
    font-size: 15px;
  }
}

/* ---- Panels ---- */
.leadership__panel {
  margin-top: 28px;
  border-radius: 22px;
}
.leadership__panel:focus-visible {
  outline-offset: 4px;
}

.leadership__grid {
  gap: 12px;
}
/* Board: Figma's fixed 434px columns */
.leadership__grid--fixed {
  display: grid;
}
@media (min-width: 576px) {
  .leadership__grid--fixed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1024px) {
  .leadership__grid--fixed {
    grid-template-columns: repeat(3, minmax(0, 434px));
  }
}
/* Management: cards stretch to fill each row */
.leadership__grid--fluid {
  display: flex;
  flex-wrap: wrap;
}
.leadership__grid--fluid > .leadership__card {
  flex: 1 0 0;
  min-width: min(300px, 100%);
}

/* Hidden until leadership.js staggers them in (JS + GSAP only). */
.js .leadership__card {
  opacity: 0;
}

/* ---- Member card ---- */
.leadership__card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: 240px;
  padding: 24px;
  border-radius: 22px;
  background: var(--surface-soft);
  transition:
    translate 0.5s var(--ease-out-expo),
    box-shadow 0.5s var(--ease-out-expo);
}
@media (max-width: 1023.98px) {
  .leadership__card {
    align-items: center;
    text-align: center;
  }
}
.leadership__card:hover {
  translate: 0 -4px;
  box-shadow: 0 24px 40px -28px rgba(32, 73, 137, 0.45);
}
.leadership__photo {
  position: relative;
  flex-shrink: 0;
  width: 118px;
  height: 118px;
  margin-bottom: auto;
  overflow: hidden;
  border-radius: 12px;
  background-color: var(--backdrop, transparent);
}
.leadership__photo-zoom {
  position: absolute;
  inset: 0;
  transition: scale 0.7s var(--ease-out-expo);
}
.leadership__card:hover .leadership__photo-zoom {
  scale: 1.06;
}
/* Figma crop: per-member geometry in --l/--t/--w/--h */
.leadership__photo-crop {
  position: absolute;
  top: var(--t);
  left: var(--l);
  width: var(--w);
  height: var(--h);
}
.leadership__photo-crop img,
.leadership__photo-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
}
.leadership__photo-img--cover {
  object-position: bottom;
}
.leadership__photo-img--contain {
  object-fit: contain;
}
.leadership__role {
  margin-top: 6px; /* the Figma spacer adds one extra flex gap above the role */
  font-size: 12px;
  line-height: 16px;
  color: var(--royal);
  text-transform: uppercase;
}
.leadership__name {
  font-size: 20px;
  line-height: 26px;
  letter-spacing: -0.02em;
  color: var(--navy);
}
