/* =========================================
   MSA 2027 — COMMITTEES
   ========================================= */

:root {
  --committee-red: #a50021;
  --committee-navy: #0c1829;
  --committee-muted: #667184;
  --committee-paper: #f7f8fa;
  --committee-border: #e6e8ec;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  color: var(--committee-navy);
}

.committee-hero {
  position: relative;
  overflow: hidden;
  background: #101d30;
  color: white;
}

.committee-hero::before {
  content: "";
  position: absolute;
  width: 650px;
  height: 650px;
  right: -240px;
  top: -250px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 50%;
  box-shadow:
    0 0 0 95px rgba(255, 255, 255, 0.018),
    0 0 0 190px rgba(255, 255, 255, 0.013);
  pointer-events: none;
}

.committee-hero::after {
  content: "";
  position: absolute;
  width: 340px;
  height: 340px;
  right: 12%;
  bottom: -260px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  pointer-events: none;
}

.committee-hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(230px, 0.5fr);
  gap: 65px;
  align-items: end;
  padding-top: 125px;
  padding-bottom: 115px;
}

.committee-eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.committee-eyebrow {
  color: #ffb3bf;
  margin-bottom: 28px;
}

.eyebrow-line {
  width: 30px;
  height: 2px;
  background: #ed3353;
}

.committee-hero h1 {
  font-size: clamp(48px, 6.5vw, 91px);
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.065em;
  margin: 0 0 30px;
}

.committee-hero h1 span {
  color: #ff7086;
}

.committee-hero-content > p {
  max-width: 610px;
  font-size: 16px;
  line-height: 1.9;
  color: #bfc9d6;
  margin-bottom: 34px;
}

.committee-primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 35px;
  padding: 17px 23px;
  background: var(--committee-red);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 13px;
  transition:
    background 0.25s,
    transform 0.25s;
}

.committee-primary-link:hover {
  background: #c5002b;
  color: #fff;
  transform: translateY(-3px);
}

.committee-primary-link span {
  font-size: 21px;
  font-weight: 400;
}

.committee-hero-aside {
  border-left: 1px solid rgba(255, 255, 255, 0.18);
  padding-left: 30px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 265px;
}

.hero-aside-top {
  display: flex;
  align-items: center;
  gap: 14px;
}

.hero-aside-top > span {
  font-size: 94px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.09em;
  color: #fff;
}

.hero-aside-top small {
  color: #b7c2d0;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.7;
}

.hero-aside-bottom {
  display: flex;
  align-items: center;
  gap: 15px;
}

.hero-circle {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  font-size: 22px;
}

.hero-aside-bottom p {
  font-size: 12px;
  line-height: 1.6;
  color: #c0cad7;
  margin: 0;
}

.hero-bottom-line {
  border-top: 1px solid rgba(255, 255, 255, 0.13);
}

.hero-bottom-line .container {
  display: flex;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
  font-size: 10px;
  letter-spacing: 0.17em;
  font-weight: 700;
  color: #aab7c9;
}

/* INTRO */

.committee-intro {
  padding: 115px 0 105px;
  background: #fff;
}

.intro-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 90px;
  align-items: center;
}

.section-kicker {
  color: var(--committee-red);
}

.committee-intro h2,
.directory-heading h2 {
  font-size: clamp(34px, 4.2vw, 59px);
  line-height: 1.13;
  font-weight: 800;
  letter-spacing: -0.055em;
  margin-top: 20px;
}

.committee-intro h2 em,
.directory-heading h2 em {
  font-style: normal;
  color: var(--committee-red);
}

.intro-description > p {
  color: var(--committee-muted);
  line-height: 1.9;
  font-size: 15px;
  margin-bottom: 30px;
}

.intro-stats {
  display: flex;
  gap: 65px;
  border-top: 1px solid var(--committee-border);
  padding-top: 23px;
}

.intro-stats > div {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.intro-stats strong {
  font-size: 34px;
  line-height: 1;
  letter-spacing: -0.055em;
}

.intro-stats span {
  color: var(--committee-muted);
  font-size: 12px;
}

/* DIRECTORY */

.committee-directory {
  padding: 85px 0 120px;
  background: var(--committee-paper);
  scroll-margin-top: 90px;
}

.directory-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  border-bottom: 1px solid #dce0e6;
  margin-bottom: 65px;
}

.committee-tabs {
  display: flex;
  gap: 38px;
}

.committee-tab {
  position: relative;
  border: 0;
  background: transparent;
  color: #7b8493;
  font-size: 14px;
  font-weight: 700;
  padding: 18px 0 22px;
  transition: color 0.2s;
}

.committee-tab:hover,
.committee-tab.active {
  color: var(--committee-navy);
}

.committee-tab.active::after {
  content: "";
  position: absolute;
  height: 3px;
  background: var(--committee-red);
  bottom: -1px;
  left: 0;
  right: 0;
}

.committee-tab span {
  margin-left: 7px;
  color: #9aa3b0;
  font-size: 11px;
}

.committee-search {
  display: flex;
  align-items: center;
  gap: 11px;
  color: #7e8795;
  padding: 0 0 15px;
  min-width: 265px;
}

.committee-search input {
  width: 100%;
  background: transparent;
  border: 0;
  outline: none;
  color: var(--committee-navy);
  font-size: 12px;
}

.committee-search:focus-within {
  color: var(--committee-red);
}

.committee-search input::placeholder {
  color: #9099a6;
}

.directory-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 35px;
  margin-bottom: 42px;
}

.directory-heading h2 {
  margin-bottom: 0;
}

.directory-heading > p {
  max-width: 355px;
  font-size: 13px;
  color: var(--committee-muted);
  line-height: 1.85;
  margin-bottom: 3px;
}

.committee-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 26px;
}

.committee-card {
  min-width: 0;
  background: #fff;
  border: 1px solid #e9ebef;
  overflow: hidden;
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 0.65s ease,
    transform 0.65s cubic-bezier(0.2, 0.75, 0.2, 1),
    box-shadow 0.3s ease,
    border-color 0.3s ease;
  transition-delay: var(--card-delay, 0ms);
}

.committee-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.committee-card:hover {
  border-color: #d9dde4;
  box-shadow: 0 24px 55px rgba(16, 29, 48, 0.09);
  transform: translateY(-7px);
}

.committee-photo {
  position: relative;
  aspect-ratio: 4 / 4.5;
  overflow: hidden;
  background: #e9edf2;
}

.committee-photo img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center 22%;
  filter: saturate(0.8);
  transition:
    transform 0.65s ease,
    filter 0.4s ease;
}

.committee-card:hover .committee-photo img {
  transform: scale(1.065);
  filter: saturate(1);
}

.committee-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(12, 24, 41, 0.14), transparent 55%);
  pointer-events: none;
}

.committee-number {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 1;
  padding: 7px 10px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--committee-navy);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.committee-card-body {
  padding: 24px 22px 20px;
}

.committee-card-role {
  display: block;
  color: var(--committee-red);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  margin-bottom: 11px;
}

.committee-card h3 {
  font-size: 19px;
  line-height: 1.3;
  font-weight: 800;
  letter-spacing: -0.035em;
  margin: 0 0 10px;
  overflow-wrap: anywhere;
}

.committee-institution {
  font-size: 12px;
  line-height: 1.7;
  color: var(--committee-muted);
  min-height: 62px;
  margin: 0 0 22px;
}

.committee-profile-button {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 0 0;
  border: 0;
  border-top: 1px solid #eceef1;
  background: transparent;
  color: var(--committee-navy);
  font-size: 12px;
  font-weight: 800;
  text-align: left;
  transition: color 0.2s;
}

.committee-profile-button span {
  font-size: 20px;
  font-weight: 400;
  transition: transform 0.2s;
}

.committee-profile-button:hover {
  color: var(--committee-red);
}

.committee-profile-button:hover span {
  transform: translate(3px, -3px);
}

.committee-empty {
  text-align: center;
  color: var(--committee-muted);
  padding: 55px 15px;
  font-size: 15px;
}

/* MODAL */

.committee-modal .modal-dialog {
  max-width: 920px;
}

.committee-modal .modal-content {
  border: 0;
  border-radius: 0;
  overflow: hidden;
  position: relative;
}

.committee-modal-close {
  position: absolute;
  top: 17px;
  right: 17px;
  z-index: 5;
  border: 0;
  width: 38px;
  height: 38px;
  background: #f1f3f5;
  color: #142237;
  font-size: 26px;
  line-height: 1;
  transition: background 0.2s;
}

.committee-modal-close:hover {
  background: #e3e6eb;
}

.committee-modal-layout {
  display: grid;
  grid-template-columns: 38% 62%;
}

.committee-modal-photo {
  background: #e8ebef;
  min-height: 520px;
}

.committee-modal-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.committee-modal-details {
  padding: 65px 46px 55px;
}

.committee-modal-details h2 {
  font-size: clamp(28px, 3vw, 39px);
  font-weight: 800;
  letter-spacing: -0.05em;
  margin: 16px 0;
}

.committee-modal-institution {
  color: var(--committee-muted);
  line-height: 1.7;
  font-size: 14px;
}

.committee-modal-divider {
  height: 1px;
  background: var(--committee-border);
  margin: 28px 0;
}

.committee-modal-details h3 {
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 14px;
}

#committeeModalBio {
  font-size: 13px;
  line-height: 1.9;
  color: #596577;
  white-space: pre-line;
}

/* CLOSING */

.committee-closing {
  background: #101d30;
  color: #fff;
  padding: 110px 0;
  text-align: center;
}

.committee-closing .section-kicker {
  color: #ff8195;
}

.closing-content h2 {
  font-size: clamp(35px, 5vw, 65px);
  font-weight: 800;
  line-height: 1.16;
  letter-spacing: -0.055em;
  margin: 25px 0 36px;
}

.closing-content h2 span {
  color: #ff8195;
}

.closing-content > a {
  display: inline-flex;
  align-items: center;
  gap: 45px;
  background: #fff;
  color: #101d30;
  text-decoration: none;
  padding: 17px 24px;
  font-size: 13px;
  font-weight: 800;
  transition:
    transform 0.25s,
    background 0.25s;
}

.closing-content > a:hover {
  transform: translateY(-3px);
  background: #f3f3f3;
}

.closing-content > a span {
  font-size: 20px;
}

/* SCROLL REVEALS */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.8s ease,
    transform 0.8s cubic-bezier(0.2, 0.75, 0.2, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* RESPONSIVE */

@media (max-width: 1199px) {
  .committee-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .committee-hero-inner {
    padding-top: 105px;
  }
}

@media (max-width: 991px) {
  .committee-hero-inner {
    grid-template-columns: 1fr;
    gap: 45px;
  }

  .committee-hero-aside {
    display: none;
  }

  .intro-layout {
    gap: 40px;
  }

  .committee-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .directory-toolbar {
    flex-wrap: wrap;
  }

  .committee-search {
    min-width: 100%;
  }
}

@media (max-width: 767px) {
  .committee-hero-inner {
    padding-top: 85px;
    padding-bottom: 80px;
  }

  .committee-hero h1 {
    font-size: clamp(42px, 10vw, 64px);
  }

  .committee-hero-content > p {
    font-size: 14px;
  }

  .committee-intro {
    padding: 75px 0;
  }

  .intro-layout {
    grid-template-columns: 1fr;
  }

  .committee-directory {
    padding: 65px 0 85px;
  }

  .directory-heading {
    display: block;
  }

  .directory-heading > p {
    margin-top: 20px;
  }

  .committee-tabs {
    gap: 22px;
  }

  .committee-tab {
    font-size: 12px;
  }

  .committee-modal-layout {
    grid-template-columns: 1fr;
  }

  .committee-modal-photo {
    height: 250px;
    min-height: 0;
  }

  .committee-modal-details {
    padding: 35px 25px;
  }

  .committee-closing {
    padding: 85px 0;
  }
}

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

  .committee-photo {
    aspect-ratio: 4 / 3.5;
  }

  .committee-institution {
    min-height: 0;
  }

  .hero-bottom-line .container {
    font-size: 9px;
    gap: 10px;
  }

  .intro-stats {
    gap: 35px;
  }
}

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

  .reveal,
  .committee-card {
    opacity: 1;
    transform: none;
  }
}

/* Keep filtered members and inactive panels hidden */
.committee-card[hidden],
.committee-panel[hidden],
.committee-empty[hidden] {
  display: none !important;
}
